2 # From configure.in Revision: 1.61 .
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_flags=`echo "$CC" | sed -e 's/^[^ ]*[ ]//'`
1841 CC=`echo "$CC" | sed -e 's/[ ].*//'`
1846 cf_new_extra_cppflags=
1848 for cf_add_cflags in $cf_flags
1850 case $cf_fix_cppflags in
1852 case $cf_add_cflags in
1853 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
1854 case $cf_add_cflags in
1856 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
1858 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
1859 && test -z "${cf_tst_cflags}" \
1860 && cf_fix_cppflags=yes
1862 if test $cf_fix_cppflags = yes ; then
1863 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
1865 elif test "${cf_tst_cflags}" = "\"'" ; then
1866 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
1875 case $cf_add_cflags in
1877 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
1879 CPPFLAGS=`echo "$CPPFLAGS" | \
1880 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
1881 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
1885 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
1890 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
1895 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
1897 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
1899 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
1900 && test -z "${cf_tst_cflags}" \
1901 && cf_fix_cppflags=no
1906 if test -n "$cf_new_cflags" ; then
1908 CFLAGS="$CFLAGS $cf_new_cflags"
1911 if test -n "$cf_new_cppflags" ; then
1913 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
1916 if test -n "$cf_new_extra_cppflags" ; then
1918 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
1923 echo "$as_me:1923: result: ok" >&5
1924 echo "${ECHO_T}ok" >&6
1929 ac_cpp='$CPP $CPPFLAGS'
1930 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1931 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1932 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1933 ac_main_return=return
1934 echo "$as_me:1934: checking how to run the C preprocessor" >&5
1935 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
1936 # On Suns, sometimes $CPP names a directory.
1937 if test -n "$CPP" && test -d "$CPP"; then
1940 if test -z "$CPP"; then
1941 if test "${ac_cv_prog_CPP+set}" = set; then
1942 echo $ECHO_N "(cached) $ECHO_C" >&6
1944 # Double quotes because CPP needs to be expanded
1945 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
1948 for ac_c_preproc_warn_flag in '' yes
1950 # Use a header file that comes with gcc, so configuring glibc
1951 # with a fresh cross-compiler works.
1952 # On the NeXT, cc -E runs the code through the compiler's parser,
1953 # not just through cpp. "Syntax error" is here to catch this case.
1954 cat >conftest.$ac_ext <<_ACEOF
1955 #line 1955 "configure"
1956 #include "confdefs.h"
1960 if { (eval echo "$as_me:1960: \"$ac_cpp conftest.$ac_ext\"") >&5
1961 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1963 egrep -v '^ *\+' conftest.er1 >conftest.err
1965 cat conftest.err >&5
1966 echo "$as_me:1966: \$? = $ac_status" >&5
1967 (exit $ac_status); } >/dev/null; then
1968 if test -s conftest.err; then
1969 ac_cpp_err=$ac_c_preproc_warn_flag
1976 if test -z "$ac_cpp_err"; then
1979 echo "$as_me: failed program was:" >&5
1980 cat conftest.$ac_ext >&5
1981 # Broken: fails on valid input.
1984 rm -f conftest.err conftest.$ac_ext
1986 # OK, works on sane cases. Now check whether non-existent headers
1987 # can be detected and how.
1988 cat >conftest.$ac_ext <<_ACEOF
1989 #line 1989 "configure"
1990 #include "confdefs.h"
1991 #include <ac_nonexistent.h>
1993 if { (eval echo "$as_me:1993: \"$ac_cpp conftest.$ac_ext\"") >&5
1994 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1996 egrep -v '^ *\+' conftest.er1 >conftest.err
1998 cat conftest.err >&5
1999 echo "$as_me:1999: \$? = $ac_status" >&5
2000 (exit $ac_status); } >/dev/null; then
2001 if test -s conftest.err; then
2002 ac_cpp_err=$ac_c_preproc_warn_flag
2009 if test -z "$ac_cpp_err"; then
2010 # Broken: success on invalid input.
2013 echo "$as_me: failed program was:" >&5
2014 cat conftest.$ac_ext >&5
2015 # Passes both tests.
2019 rm -f conftest.err conftest.$ac_ext
2022 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2023 rm -f conftest.err conftest.$ac_ext
2024 if $ac_preproc_ok; then
2036 echo "$as_me:2036: result: $CPP" >&5
2037 echo "${ECHO_T}$CPP" >&6
2039 for ac_c_preproc_warn_flag in '' yes
2041 # Use a header file that comes with gcc, so configuring glibc
2042 # with a fresh cross-compiler works.
2043 # On the NeXT, cc -E runs the code through the compiler's parser,
2044 # not just through cpp. "Syntax error" is here to catch this case.
2045 cat >conftest.$ac_ext <<_ACEOF
2046 #line 2046 "configure"
2047 #include "confdefs.h"
2051 if { (eval echo "$as_me:2051: \"$ac_cpp conftest.$ac_ext\"") >&5
2052 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2054 egrep -v '^ *\+' conftest.er1 >conftest.err
2056 cat conftest.err >&5
2057 echo "$as_me:2057: \$? = $ac_status" >&5
2058 (exit $ac_status); } >/dev/null; then
2059 if test -s conftest.err; then
2060 ac_cpp_err=$ac_c_preproc_warn_flag
2067 if test -z "$ac_cpp_err"; then
2070 echo "$as_me: failed program was:" >&5
2071 cat conftest.$ac_ext >&5
2072 # Broken: fails on valid input.
2075 rm -f conftest.err conftest.$ac_ext
2077 # OK, works on sane cases. Now check whether non-existent headers
2078 # can be detected and how.
2079 cat >conftest.$ac_ext <<_ACEOF
2080 #line 2080 "configure"
2081 #include "confdefs.h"
2082 #include <ac_nonexistent.h>
2084 if { (eval echo "$as_me:2084: \"$ac_cpp conftest.$ac_ext\"") >&5
2085 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2087 egrep -v '^ *\+' conftest.er1 >conftest.err
2089 cat conftest.err >&5
2090 echo "$as_me:2090: \$? = $ac_status" >&5
2091 (exit $ac_status); } >/dev/null; then
2092 if test -s conftest.err; then
2093 ac_cpp_err=$ac_c_preproc_warn_flag
2100 if test -z "$ac_cpp_err"; then
2101 # Broken: success on invalid input.
2104 echo "$as_me: failed program was:" >&5
2105 cat conftest.$ac_ext >&5
2106 # Passes both tests.
2110 rm -f conftest.err conftest.$ac_ext
2113 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2114 rm -f conftest.err conftest.$ac_ext
2115 if $ac_preproc_ok; then
2118 { { echo "$as_me:2118: error: C preprocessor \"$CPP\" fails sanity check" >&5
2119 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2120 { (exit 1); exit 1; }; }
2124 ac_cpp='$CPP $CPPFLAGS'
2125 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2126 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2127 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2128 ac_main_return=return
2130 if test $ac_cv_c_compiler_gnu = yes; then
2131 echo "$as_me:2131: checking whether $CC needs -traditional" >&5
2132 echo $ECHO_N "checking whether $CC needs -traditional... $ECHO_C" >&6
2133 if test "${ac_cv_prog_gcc_traditional+set}" = set; then
2134 echo $ECHO_N "(cached) $ECHO_C" >&6
2136 ac_pattern="Autoconf.*'x'"
2137 cat >conftest.$ac_ext <<_ACEOF
2138 #line 2138 "configure"
2139 #include "confdefs.h"
2141 int Autoconf = TIOCGETP;
2143 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2144 egrep "$ac_pattern" >/dev/null 2>&1; then
2145 ac_cv_prog_gcc_traditional=yes
2147 ac_cv_prog_gcc_traditional=no
2151 if test $ac_cv_prog_gcc_traditional = no; then
2152 cat >conftest.$ac_ext <<_ACEOF
2153 #line 2153 "configure"
2154 #include "confdefs.h"
2156 int Autoconf = TCGETA;
2158 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2159 egrep "$ac_pattern" >/dev/null 2>&1; then
2160 ac_cv_prog_gcc_traditional=yes
2166 echo "$as_me:2166: result: $ac_cv_prog_gcc_traditional" >&5
2167 echo "${ECHO_T}$ac_cv_prog_gcc_traditional" >&6
2168 if test $ac_cv_prog_gcc_traditional = yes; then
2169 CC="$CC -traditional"
2173 echo "$as_me:2173: checking whether $CC understands -c and -o together" >&5
2174 echo $ECHO_N "checking whether $CC understands -c and -o together... $ECHO_C" >&6
2175 if test "${cf_cv_prog_CC_c_o+set}" = set; then
2176 echo $ECHO_N "(cached) $ECHO_C" >&6
2179 cat > conftest.$ac_ext <<CF_EOF
2183 ${cf_cv_main_return:-return}(0);
2186 # We do the test twice because some compilers refuse to overwrite an
2187 # existing .o file with -o, though they will create one.
2188 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
2189 if { (eval echo "$as_me:2189: \"$ac_try\"") >&5
2192 echo "$as_me:2192: \$? = $ac_status" >&5
2193 (exit $ac_status); } &&
2194 test -f conftest2.$ac_objext && { (eval echo "$as_me:2194: \"$ac_try\"") >&5
2197 echo "$as_me:2197: \$? = $ac_status" >&5
2198 (exit $ac_status); };
2200 eval cf_cv_prog_CC_c_o=yes
2202 eval cf_cv_prog_CC_c_o=no
2207 if test $cf_cv_prog_CC_c_o = yes; then
2208 echo "$as_me:2208: result: yes" >&5
2209 echo "${ECHO_T}yes" >&6
2211 echo "$as_me:2211: result: no" >&5
2212 echo "${ECHO_T}no" >&6
2215 test "$program_prefix" != NONE &&
2216 program_transform_name="s,^,$program_prefix,;$program_transform_name"
2217 # Use a double $ so make ignores it.
2218 test "$program_suffix" != NONE &&
2219 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
2220 # Double any \ or $. echo might interpret backslashes.
2221 # By default was `s,x,x', remove it if useless.
2222 cat <<\_ACEOF >conftest.sed
2223 s/[\\$]/&&/g;s/;s,x,x,$//
2225 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
2228 for ac_prog in mawk gawk nawk awk
2230 # Extract the first word of "$ac_prog", so it can be a program name with args.
2231 set dummy $ac_prog; ac_word=$2
2232 echo "$as_me:2232: checking for $ac_word" >&5
2233 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2234 if test "${ac_cv_prog_AWK+set}" = set; then
2235 echo $ECHO_N "(cached) $ECHO_C" >&6
2237 if test -n "$AWK"; then
2238 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2240 ac_save_IFS=$IFS; IFS=$ac_path_separator
2242 for ac_dir in $ac_dummy; do
2244 test -z "$ac_dir" && ac_dir=.
2245 $as_executable_p "$ac_dir/$ac_word" || continue
2246 ac_cv_prog_AWK="$ac_prog"
2247 echo "$as_me:2247: found $ac_dir/$ac_word" >&5
2254 if test -n "$AWK"; then
2255 echo "$as_me:2255: result: $AWK" >&5
2256 echo "${ECHO_T}$AWK" >&6
2258 echo "$as_me:2258: result: no" >&5
2259 echo "${ECHO_T}no" >&6
2262 test -n "$AWK" && break
2265 test -z "$AWK" && { { echo "$as_me:2265: error: No awk program found" >&5
2266 echo "$as_me: error: No awk program found" >&2;}
2267 { (exit 1); exit 1; }; }
2269 echo "$as_me:2269: checking for egrep" >&5
2270 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
2271 if test "${ac_cv_prog_egrep+set}" = set; then
2272 echo $ECHO_N "(cached) $ECHO_C" >&6
2274 if echo a | (grep -E '(a|b)') >/dev/null 2>&1
2275 then ac_cv_prog_egrep='grep -E'
2276 else ac_cv_prog_egrep='egrep'
2279 echo "$as_me:2279: result: $ac_cv_prog_egrep" >&5
2280 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
2281 EGREP=$ac_cv_prog_egrep
2283 test -z "$EGREP" && { { echo "$as_me:2283: error: No egrep program found" >&5
2284 echo "$as_me: error: No egrep program found" >&2;}
2285 { (exit 1); exit 1; }; }
2287 # Find a good install program. We prefer a C program (faster),
2288 # so one script is as good as another. But avoid the broken or
2289 # incompatible versions:
2290 # SysV /etc/install, /usr/sbin/install
2291 # SunOS /usr/etc/install
2292 # IRIX /sbin/install
2294 # AmigaOS /C/install, which installs bootblocks on floppy discs
2295 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2296 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2297 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2298 # ./install, which can be erroneously created by make from ./install.sh.
2299 echo "$as_me:2299: checking for a BSD compatible install" >&5
2300 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2301 if test -z "$INSTALL"; then
2302 if test "${ac_cv_path_install+set}" = set; then
2303 echo $ECHO_N "(cached) $ECHO_C" >&6
2305 ac_save_IFS=$IFS; IFS=$ac_path_separator
2306 for ac_dir in $PATH; do
2308 # Account for people who put trailing slashes in PATH elements.
2310 / | ./ | .// | /cC/* \
2311 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2314 # OSF1 and SCO ODT 3.0 have their own names for install.
2315 # Don't use installbsd from OSF since it installs stuff as root
2317 for ac_prog in ginstall scoinst install; do
2318 if $as_executable_p "$ac_dir/$ac_prog"; then
2319 if test $ac_prog = install &&
2320 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2321 # AIX install. It has an incompatible calling convention.
2323 elif test $ac_prog = install &&
2324 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2325 # program-specific install script used by HP pwplus--don't use.
2328 ac_cv_path_install="$ac_dir/$ac_prog -c"
2338 if test "${ac_cv_path_install+set}" = set; then
2339 INSTALL=$ac_cv_path_install
2341 # As a last resort, use the slow shell script. We don't cache a
2342 # path for INSTALL within a source directory, because that will
2343 # break other packages using the cache if that directory is
2344 # removed, or if the path is relative.
2345 INSTALL=$ac_install_sh
2348 echo "$as_me:2348: result: $INSTALL" >&5
2349 echo "${ECHO_T}$INSTALL" >&6
2351 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2352 # It thinks the first close brace ends the variable substitution.
2353 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2355 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2357 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2359 echo "$as_me:2359: checking whether ln -s works" >&5
2360 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
2362 if test "$LN_S" = "ln -s"; then
2363 echo "$as_me:2363: result: yes" >&5
2364 echo "${ECHO_T}yes" >&6
2366 echo "$as_me:2366: result: no, using $LN_S" >&5
2367 echo "${ECHO_T}no, using $LN_S" >&6
2370 echo "$as_me:2370: checking if $LN_S -f options work" >&5
2371 echo $ECHO_N "checking if $LN_S -f options work... $ECHO_C" >&6
2373 rm -f conf$$.src conf$$dst
2375 echo first >conf$$.src
2376 if $LN_S -f conf$$.src conf$$.dst 2>/dev/null; then
2381 rm -f conf$$.dst conf$$src
2382 echo "$as_me:2382: result: $cf_prog_ln_sf" >&5
2383 echo "${ECHO_T}$cf_prog_ln_sf" >&6
2385 test "$cf_prog_ln_sf" = yes && LN_S="$LN_S -f"
2387 echo "$as_me:2387: checking for long file names" >&5
2388 echo $ECHO_N "checking for long file names... $ECHO_C" >&6
2389 if test "${ac_cv_sys_long_file_names+set}" = set; then
2390 echo $ECHO_N "(cached) $ECHO_C" >&6
2392 ac_cv_sys_long_file_names=yes
2393 # Test for long file names in all the places we know might matter:
2394 # . the current directory, where building will happen
2395 # $prefix/lib where we will be installing things
2396 # $exec_prefix/lib likewise
2397 # eval it to expand exec_prefix.
2398 # $TMPDIR if set, where it might want to write temporary files
2399 # if $TMPDIR is not set:
2400 # /tmp where it might want to write temporary files
2403 if test -n "$TMPDIR" && test -d "$TMPDIR" && test -w "$TMPDIR"; then
2406 ac_tmpdirs='/tmp /var/tmp /usr/tmp'
2408 for ac_dir in . $ac_tmpdirs `eval echo $prefix/lib $exec_prefix/lib` ; do
2409 test -d $ac_dir || continue
2410 test -w $ac_dir || continue # It is less confusing to not echo anything here.
2411 ac_xdir=$ac_dir/cf$$
2412 (umask 077 && mkdir $ac_xdir 2>/dev/null) || continue
2413 ac_tf1=$ac_xdir/conftest9012345
2414 ac_tf2=$ac_xdir/conftest9012346
2415 (echo 1 >$ac_tf1) 2>/dev/null
2416 (echo 2 >$ac_tf2) 2>/dev/null
2417 ac_val=`cat $ac_tf1 2>/dev/null`
2418 if test ! -f $ac_tf1 || test "$ac_val" != 1; then
2419 ac_cv_sys_long_file_names=no
2420 rm -rf $ac_xdir 2>/dev/null
2423 rm -rf $ac_xdir 2>/dev/null
2426 echo "$as_me:2426: result: $ac_cv_sys_long_file_names" >&5
2427 echo "${ECHO_T}$ac_cv_sys_long_file_names" >&6
2428 if test $ac_cv_sys_long_file_names = yes; then
2430 cat >>confdefs.h <<\EOF
2431 #define HAVE_LONG_FILE_NAMES 1
2436 # if we find pkg-config, check if we should install the ".pc" files.
2438 echo "$as_me:2438: checking if you want to use pkg-config" >&5
2439 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
2441 # Check whether --with-pkg-config or --without-pkg-config was given.
2442 if test "${with_pkg_config+set}" = set; then
2443 withval="$with_pkg_config"
2444 cf_pkg_config=$withval
2448 echo "$as_me:2448: result: $cf_pkg_config" >&5
2449 echo "${ECHO_T}$cf_pkg_config" >&6
2451 case $cf_pkg_config in
2457 if test -n "$ac_tool_prefix"; then
2458 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
2459 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
2460 echo "$as_me:2460: checking for $ac_word" >&5
2461 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2462 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
2463 echo $ECHO_N "(cached) $ECHO_C" >&6
2467 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
2470 ac_save_IFS=$IFS; IFS=$ac_path_separator
2472 for ac_dir in $ac_dummy; do
2474 test -z "$ac_dir" && ac_dir=.
2475 if $as_executable_p "$ac_dir/$ac_word"; then
2476 ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
2477 echo "$as_me:2477: found $ac_dir/$ac_word" >&5
2485 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
2487 if test -n "$PKG_CONFIG"; then
2488 echo "$as_me:2488: result: $PKG_CONFIG" >&5
2489 echo "${ECHO_T}$PKG_CONFIG" >&6
2491 echo "$as_me:2491: result: no" >&5
2492 echo "${ECHO_T}no" >&6
2496 if test -z "$ac_cv_path_PKG_CONFIG"; then
2497 ac_pt_PKG_CONFIG=$PKG_CONFIG
2498 # Extract the first word of "pkg-config", so it can be a program name with args.
2499 set dummy pkg-config; ac_word=$2
2500 echo "$as_me:2500: checking for $ac_word" >&5
2501 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2502 if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
2503 echo $ECHO_N "(cached) $ECHO_C" >&6
2505 case $ac_pt_PKG_CONFIG in
2507 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
2510 ac_save_IFS=$IFS; IFS=$ac_path_separator
2512 for ac_dir in $ac_dummy; do
2514 test -z "$ac_dir" && ac_dir=.
2515 if $as_executable_p "$ac_dir/$ac_word"; then
2516 ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
2517 echo "$as_me:2517: found $ac_dir/$ac_word" >&5
2522 test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none"
2526 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
2528 if test -n "$ac_pt_PKG_CONFIG"; then
2529 echo "$as_me:2529: result: $ac_pt_PKG_CONFIG" >&5
2530 echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
2532 echo "$as_me:2532: result: no" >&5
2533 echo "${ECHO_T}no" >&6
2536 PKG_CONFIG=$ac_pt_PKG_CONFIG
2538 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
2547 test -z "$PKG_CONFIG" && PKG_CONFIG=none
2548 if test "$PKG_CONFIG" != none ; then
2550 if test "x$prefix" != xNONE; then
2551 cf_path_syntax="$prefix"
2553 cf_path_syntax="$ac_default_prefix"
2556 case ".$PKG_CONFIG" in
2561 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
2563 (.\${*prefix}*|.\${*dir}*)
2564 eval PKG_CONFIG="$PKG_CONFIG"
2565 case ".$PKG_CONFIG" in
2567 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
2572 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
2575 { { echo "$as_me:2575: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
2576 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
2577 { (exit 1); exit 1; }; }
2581 elif test "x$cf_pkg_config" != xno ; then
2582 { echo "$as_me:2582: WARNING: pkg-config is not installed" >&5
2583 echo "$as_me: WARNING: pkg-config is not installed" >&2;}
2588 echo "$as_me:2588: checking for pkg-config library directory" >&5
2589 echo $ECHO_N "checking for pkg-config library directory... $ECHO_C" >&6
2592 echo "$as_me:2592: checking for $PKG_CONFIG library directory" >&5
2593 echo $ECHO_N "checking for $PKG_CONFIG library directory... $ECHO_C" >&6
2597 PKG_CONFIG_LIBDIR=no
2599 # Check whether --with-pkg-config-libdir or --without-pkg-config-libdir was given.
2600 if test "${with_pkg_config_libdir+set}" = set; then
2601 withval="$with_pkg_config_libdir"
2602 PKG_CONFIG_LIBDIR=$withval
2604 test "x$PKG_CONFIG" != xnone && PKG_CONFIG_LIBDIR=yes
2607 case x$PKG_CONFIG_LIBDIR in
2611 # Look for the library directory using the same prefix as the executable
2612 if test "x$PKG_CONFIG" = xnone
2616 cf_path=`echo "$PKG_CONFIG" | sed -e 's,/[^/]*/[^/]*$,,'`
2619 # If you don't like using the default architecture, you have to specify the
2620 # intended library directory and corresponding compiler/linker options.
2622 # This case allows for Debian's 2014-flavor of multiarch, along with the
2623 # most common variations before that point. Some other variants spell the
2624 # directory differently, e.g., "pkg-config", and put it in unusual places.
2625 # pkg-config has always been poorly standardized, which is ironic...
2626 case x`(arch) 2>/dev/null` in
2629 $cf_path/lib/*64-linux-gnu \
2637 $cf_path/lib/*-linux-gnu \
2645 test -n "$verbose" && echo " list..." 1>&6
2647 echo "${as_me:-configure}:2647: testing list... ..." 1>&5
2649 for cf_config in $cf_search_path
2651 test -n "$verbose" && echo " checking $cf_config/pkgconfig" 1>&6
2653 echo "${as_me:-configure}:2653: testing checking $cf_config/pkgconfig ..." 1>&5
2655 if test -d $cf_config/pkgconfig
2657 PKG_CONFIG_LIBDIR=$cf_config/pkgconfig
2658 echo "$as_me:2658: checking done" >&5
2659 echo $ECHO_N "checking done... $ECHO_C" >&6
2668 if test "x$PKG_CONFIG_LIBDIR" != xno ; then
2669 echo "$as_me:2669: result: $PKG_CONFIG_LIBDIR" >&5
2670 echo "${ECHO_T}$PKG_CONFIG_LIBDIR" >&6
2673 echo "$as_me:2673: checking if you want to build test-programs" >&5
2674 echo $ECHO_N "checking if you want to build test-programs... $ECHO_C" >&6
2676 # Check whether --with-tests or --without-tests was given.
2677 if test "${with_tests+set}" = set; then
2678 withval="$with_tests"
2679 cf_with_tests=$withval
2683 echo "$as_me:2683: result: $cf_with_tests" >&5
2684 echo "${ECHO_T}$cf_with_tests" >&6
2686 echo "$as_me:2686: checking if we should assume mixed-case filenames" >&5
2687 echo $ECHO_N "checking if we should assume mixed-case filenames... $ECHO_C" >&6
2689 # Check whether --enable-mixed-case or --disable-mixed-case was given.
2690 if test "${enable_mixed_case+set}" = set; then
2691 enableval="$enable_mixed_case"
2692 enable_mixedcase=$enableval
2694 enable_mixedcase=auto
2696 echo "$as_me:2696: result: $enable_mixedcase" >&5
2697 echo "${ECHO_T}$enable_mixedcase" >&6
2698 if test "$enable_mixedcase" = "auto" ; then
2700 echo "$as_me:2700: checking if filesystem supports mixed-case filenames" >&5
2701 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
2702 if test "${cf_cv_mixedcase+set}" = set; then
2703 echo $ECHO_N "(cached) $ECHO_C" >&6
2706 if test "$cross_compiling" = yes ; then
2707 case $target_alias in
2708 (*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*)
2716 rm -f conftest CONFTEST
2718 if test -f CONFTEST ; then
2723 rm -f conftest CONFTEST
2727 echo "$as_me:2727: result: $cf_cv_mixedcase" >&5
2728 echo "${ECHO_T}$cf_cv_mixedcase" >&6
2729 test "$cf_cv_mixedcase" = yes &&
2730 cat >>confdefs.h <<\EOF
2731 #define MIXEDCASE_FILENAMES 1
2735 cf_cv_mixedcase=$enable_mixedcase
2736 if test "$enable_mixedcase" = "yes" ; then
2737 cat >>confdefs.h <<\EOF
2738 #define MIXEDCASE_FILENAMES 1
2744 # do this after mixed-case option (tags/TAGS is not as important as tic).
2745 echo "$as_me:2745: checking whether ${MAKE-make} sets \${MAKE}" >&5
2746 echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
2747 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
2748 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
2749 echo $ECHO_N "(cached) $ECHO_C" >&6
2751 cat >conftest.make <<\EOF
2753 @echo 'ac_maketemp="${MAKE}"'
2755 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
2756 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
2757 if test -n "$ac_maketemp"; then
2758 eval ac_cv_prog_make_${ac_make}_set=yes
2760 eval ac_cv_prog_make_${ac_make}_set=no
2764 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
2765 echo "$as_me:2765: result: yes" >&5
2766 echo "${ECHO_T}yes" >&6
2769 echo "$as_me:2769: result: no" >&5
2770 echo "${ECHO_T}no" >&6
2771 SET_MAKE="MAKE=${MAKE-make}"
2774 for ac_prog in exctags ctags
2776 # Extract the first word of "$ac_prog", so it can be a program name with args.
2777 set dummy $ac_prog; ac_word=$2
2778 echo "$as_me:2778: checking for $ac_word" >&5
2779 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2780 if test "${ac_cv_prog_CTAGS+set}" = set; then
2781 echo $ECHO_N "(cached) $ECHO_C" >&6
2783 if test -n "$CTAGS"; then
2784 ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
2786 ac_save_IFS=$IFS; IFS=$ac_path_separator
2788 for ac_dir in $ac_dummy; do
2790 test -z "$ac_dir" && ac_dir=.
2791 $as_executable_p "$ac_dir/$ac_word" || continue
2792 ac_cv_prog_CTAGS="$ac_prog"
2793 echo "$as_me:2793: found $ac_dir/$ac_word" >&5
2799 CTAGS=$ac_cv_prog_CTAGS
2800 if test -n "$CTAGS"; then
2801 echo "$as_me:2801: result: $CTAGS" >&5
2802 echo "${ECHO_T}$CTAGS" >&6
2804 echo "$as_me:2804: result: no" >&5
2805 echo "${ECHO_T}no" >&6
2808 test -n "$CTAGS" && break
2811 for ac_prog in exetags etags
2813 # Extract the first word of "$ac_prog", so it can be a program name with args.
2814 set dummy $ac_prog; ac_word=$2
2815 echo "$as_me:2815: checking for $ac_word" >&5
2816 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2817 if test "${ac_cv_prog_ETAGS+set}" = set; then
2818 echo $ECHO_N "(cached) $ECHO_C" >&6
2820 if test -n "$ETAGS"; then
2821 ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
2823 ac_save_IFS=$IFS; IFS=$ac_path_separator
2825 for ac_dir in $ac_dummy; do
2827 test -z "$ac_dir" && ac_dir=.
2828 $as_executable_p "$ac_dir/$ac_word" || continue
2829 ac_cv_prog_ETAGS="$ac_prog"
2830 echo "$as_me:2830: found $ac_dir/$ac_word" >&5
2836 ETAGS=$ac_cv_prog_ETAGS
2837 if test -n "$ETAGS"; then
2838 echo "$as_me:2838: result: $ETAGS" >&5
2839 echo "${ECHO_T}$ETAGS" >&6
2841 echo "$as_me:2841: result: no" >&5
2842 echo "${ECHO_T}no" >&6
2845 test -n "$ETAGS" && break
2848 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
2849 set dummy ${CTAGS:-ctags}; ac_word=$2
2850 echo "$as_me:2850: checking for $ac_word" >&5
2851 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2852 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
2853 echo $ECHO_N "(cached) $ECHO_C" >&6
2855 if test -n "$MAKE_LOWER_TAGS"; then
2856 ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
2858 ac_save_IFS=$IFS; IFS=$ac_path_separator
2860 for ac_dir in $ac_dummy; do
2862 test -z "$ac_dir" && ac_dir=.
2863 $as_executable_p "$ac_dir/$ac_word" || continue
2864 ac_cv_prog_MAKE_LOWER_TAGS="yes"
2865 echo "$as_me:2865: found $ac_dir/$ac_word" >&5
2869 test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
2872 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
2873 if test -n "$MAKE_LOWER_TAGS"; then
2874 echo "$as_me:2874: result: $MAKE_LOWER_TAGS" >&5
2875 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
2877 echo "$as_me:2877: result: no" >&5
2878 echo "${ECHO_T}no" >&6
2881 if test "$cf_cv_mixedcase" = yes ; then
2882 # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
2883 set dummy ${ETAGS:-etags}; ac_word=$2
2884 echo "$as_me:2884: checking for $ac_word" >&5
2885 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2886 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
2887 echo $ECHO_N "(cached) $ECHO_C" >&6
2889 if test -n "$MAKE_UPPER_TAGS"; then
2890 ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
2892 ac_save_IFS=$IFS; IFS=$ac_path_separator
2894 for ac_dir in $ac_dummy; do
2896 test -z "$ac_dir" && ac_dir=.
2897 $as_executable_p "$ac_dir/$ac_word" || continue
2898 ac_cv_prog_MAKE_UPPER_TAGS="yes"
2899 echo "$as_me:2899: found $ac_dir/$ac_word" >&5
2903 test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
2906 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
2907 if test -n "$MAKE_UPPER_TAGS"; then
2908 echo "$as_me:2908: result: $MAKE_UPPER_TAGS" >&5
2909 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
2911 echo "$as_me:2911: result: no" >&5
2912 echo "${ECHO_T}no" >&6
2919 if test "$MAKE_UPPER_TAGS" = yes ; then
2925 if test "$MAKE_LOWER_TAGS" = yes ; then
2931 echo "$as_me:2931: checking for makeflags variable" >&5
2932 echo $ECHO_N "checking for makeflags variable... $ECHO_C" >&6
2933 if test "${cf_cv_makeflags+set}" = set; then
2934 echo $ECHO_N "(cached) $ECHO_C" >&6
2938 for cf_option in '-${MAKEFLAGS}' '${MFLAGS}'
2940 cat >cf_makeflags.tmp <<CF_EOF
2943 @ echo '.$cf_option'
2945 cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp 2>/dev/null | fgrep -v "ing directory" | sed -e 's,[ ]*$,,'`
2946 case "$cf_result" in
2948 cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp CC=cc 2>/dev/null`
2949 case "$cf_result" in
2950 (.*CC=*) cf_cv_makeflags=
2952 (*) cf_cv_makeflags=$cf_option
2958 (*) echo "given option \"$cf_option\", no match \"$cf_result\""
2962 rm -f cf_makeflags.tmp
2965 echo "$as_me:2965: result: $cf_cv_makeflags" >&5
2966 echo "${ECHO_T}$cf_cv_makeflags" >&6
2968 if test -n "$ac_tool_prefix"; then
2969 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
2970 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
2971 echo "$as_me:2971: checking for $ac_word" >&5
2972 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2973 if test "${ac_cv_prog_RANLIB+set}" = set; then
2974 echo $ECHO_N "(cached) $ECHO_C" >&6
2976 if test -n "$RANLIB"; then
2977 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
2979 ac_save_IFS=$IFS; IFS=$ac_path_separator
2981 for ac_dir in $ac_dummy; do
2983 test -z "$ac_dir" && ac_dir=.
2984 $as_executable_p "$ac_dir/$ac_word" || continue
2985 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
2986 echo "$as_me:2986: found $ac_dir/$ac_word" >&5
2992 RANLIB=$ac_cv_prog_RANLIB
2993 if test -n "$RANLIB"; then
2994 echo "$as_me:2994: result: $RANLIB" >&5
2995 echo "${ECHO_T}$RANLIB" >&6
2997 echo "$as_me:2997: result: no" >&5
2998 echo "${ECHO_T}no" >&6
3002 if test -z "$ac_cv_prog_RANLIB"; then
3003 ac_ct_RANLIB=$RANLIB
3004 # Extract the first word of "ranlib", so it can be a program name with args.
3005 set dummy ranlib; ac_word=$2
3006 echo "$as_me:3006: checking for $ac_word" >&5
3007 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3008 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
3009 echo $ECHO_N "(cached) $ECHO_C" >&6
3011 if test -n "$ac_ct_RANLIB"; then
3012 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
3014 ac_save_IFS=$IFS; IFS=$ac_path_separator
3016 for ac_dir in $ac_dummy; do
3018 test -z "$ac_dir" && ac_dir=.
3019 $as_executable_p "$ac_dir/$ac_word" || continue
3020 ac_cv_prog_ac_ct_RANLIB="ranlib"
3021 echo "$as_me:3021: found $ac_dir/$ac_word" >&5
3025 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB="':'"
3028 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
3029 if test -n "$ac_ct_RANLIB"; then
3030 echo "$as_me:3030: result: $ac_ct_RANLIB" >&5
3031 echo "${ECHO_T}$ac_ct_RANLIB" >&6
3033 echo "$as_me:3033: result: no" >&5
3034 echo "${ECHO_T}no" >&6
3037 RANLIB=$ac_ct_RANLIB
3039 RANLIB="$ac_cv_prog_RANLIB"
3042 if test -n "$ac_tool_prefix"; then
3043 # Extract the first word of "${ac_tool_prefix}ld", so it can be a program name with args.
3044 set dummy ${ac_tool_prefix}ld; ac_word=$2
3045 echo "$as_me:3045: checking for $ac_word" >&5
3046 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3047 if test "${ac_cv_prog_LD+set}" = set; then
3048 echo $ECHO_N "(cached) $ECHO_C" >&6
3050 if test -n "$LD"; then
3051 ac_cv_prog_LD="$LD" # Let the user override the test.
3053 ac_save_IFS=$IFS; IFS=$ac_path_separator
3055 for ac_dir in $ac_dummy; do
3057 test -z "$ac_dir" && ac_dir=.
3058 $as_executable_p "$ac_dir/$ac_word" || continue
3059 ac_cv_prog_LD="${ac_tool_prefix}ld"
3060 echo "$as_me:3060: found $ac_dir/$ac_word" >&5
3067 if test -n "$LD"; then
3068 echo "$as_me:3068: result: $LD" >&5
3069 echo "${ECHO_T}$LD" >&6
3071 echo "$as_me:3071: result: no" >&5
3072 echo "${ECHO_T}no" >&6
3076 if test -z "$ac_cv_prog_LD"; then
3078 # Extract the first word of "ld", so it can be a program name with args.
3079 set dummy ld; ac_word=$2
3080 echo "$as_me:3080: checking for $ac_word" >&5
3081 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3082 if test "${ac_cv_prog_ac_ct_LD+set}" = set; then
3083 echo $ECHO_N "(cached) $ECHO_C" >&6
3085 if test -n "$ac_ct_LD"; then
3086 ac_cv_prog_ac_ct_LD="$ac_ct_LD" # Let the user override the test.
3088 ac_save_IFS=$IFS; IFS=$ac_path_separator
3090 for ac_dir in $ac_dummy; do
3092 test -z "$ac_dir" && ac_dir=.
3093 $as_executable_p "$ac_dir/$ac_word" || continue
3094 ac_cv_prog_ac_ct_LD="ld"
3095 echo "$as_me:3095: found $ac_dir/$ac_word" >&5
3099 test -z "$ac_cv_prog_ac_ct_LD" && ac_cv_prog_ac_ct_LD="ld"
3102 ac_ct_LD=$ac_cv_prog_ac_ct_LD
3103 if test -n "$ac_ct_LD"; then
3104 echo "$as_me:3104: result: $ac_ct_LD" >&5
3105 echo "${ECHO_T}$ac_ct_LD" >&6
3107 echo "$as_me:3107: result: no" >&5
3108 echo "${ECHO_T}no" >&6
3116 if test -n "$ac_tool_prefix"; then
3117 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
3118 set dummy ${ac_tool_prefix}ar; ac_word=$2
3119 echo "$as_me:3119: checking for $ac_word" >&5
3120 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3121 if test "${ac_cv_prog_AR+set}" = set; then
3122 echo $ECHO_N "(cached) $ECHO_C" >&6
3124 if test -n "$AR"; then
3125 ac_cv_prog_AR="$AR" # Let the user override the test.
3127 ac_save_IFS=$IFS; IFS=$ac_path_separator
3129 for ac_dir in $ac_dummy; do
3131 test -z "$ac_dir" && ac_dir=.
3132 $as_executable_p "$ac_dir/$ac_word" || continue
3133 ac_cv_prog_AR="${ac_tool_prefix}ar"
3134 echo "$as_me:3134: found $ac_dir/$ac_word" >&5
3141 if test -n "$AR"; then
3142 echo "$as_me:3142: result: $AR" >&5
3143 echo "${ECHO_T}$AR" >&6
3145 echo "$as_me:3145: result: no" >&5
3146 echo "${ECHO_T}no" >&6
3150 if test -z "$ac_cv_prog_AR"; then
3152 # Extract the first word of "ar", so it can be a program name with args.
3153 set dummy ar; ac_word=$2
3154 echo "$as_me:3154: checking for $ac_word" >&5
3155 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3156 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
3157 echo $ECHO_N "(cached) $ECHO_C" >&6
3159 if test -n "$ac_ct_AR"; then
3160 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
3162 ac_save_IFS=$IFS; IFS=$ac_path_separator
3164 for ac_dir in $ac_dummy; do
3166 test -z "$ac_dir" && ac_dir=.
3167 $as_executable_p "$ac_dir/$ac_word" || continue
3168 ac_cv_prog_ac_ct_AR="ar"
3169 echo "$as_me:3169: found $ac_dir/$ac_word" >&5
3173 test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="ar"
3176 ac_ct_AR=$ac_cv_prog_ac_ct_AR
3177 if test -n "$ac_ct_AR"; then
3178 echo "$as_me:3178: result: $ac_ct_AR" >&5
3179 echo "${ECHO_T}$ac_ct_AR" >&6
3181 echo "$as_me:3181: result: no" >&5
3182 echo "${ECHO_T}no" >&6
3190 if test -n "$ac_tool_prefix"; then
3191 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
3192 set dummy ${ac_tool_prefix}ar; ac_word=$2
3193 echo "$as_me:3193: checking for $ac_word" >&5
3194 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3195 if test "${ac_cv_prog_AR+set}" = set; then
3196 echo $ECHO_N "(cached) $ECHO_C" >&6
3198 if test -n "$AR"; then
3199 ac_cv_prog_AR="$AR" # Let the user override the test.
3201 ac_save_IFS=$IFS; IFS=$ac_path_separator
3203 for ac_dir in $ac_dummy; do
3205 test -z "$ac_dir" && ac_dir=.
3206 $as_executable_p "$ac_dir/$ac_word" || continue
3207 ac_cv_prog_AR="${ac_tool_prefix}ar"
3208 echo "$as_me:3208: found $ac_dir/$ac_word" >&5
3215 if test -n "$AR"; then
3216 echo "$as_me:3216: result: $AR" >&5
3217 echo "${ECHO_T}$AR" >&6
3219 echo "$as_me:3219: result: no" >&5
3220 echo "${ECHO_T}no" >&6
3224 if test -z "$ac_cv_prog_AR"; then
3226 # Extract the first word of "ar", so it can be a program name with args.
3227 set dummy ar; ac_word=$2
3228 echo "$as_me:3228: checking for $ac_word" >&5
3229 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3230 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
3231 echo $ECHO_N "(cached) $ECHO_C" >&6
3233 if test -n "$ac_ct_AR"; then
3234 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
3236 ac_save_IFS=$IFS; IFS=$ac_path_separator
3238 for ac_dir in $ac_dummy; do
3240 test -z "$ac_dir" && ac_dir=.
3241 $as_executable_p "$ac_dir/$ac_word" || continue
3242 ac_cv_prog_ac_ct_AR="ar"
3243 echo "$as_me:3243: found $ac_dir/$ac_word" >&5
3247 test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="ar"
3250 ac_ct_AR=$ac_cv_prog_ac_ct_AR
3251 if test -n "$ac_ct_AR"; then
3252 echo "$as_me:3252: result: $ac_ct_AR" >&5
3253 echo "${ECHO_T}$ac_ct_AR" >&6
3255 echo "$as_me:3255: result: no" >&5
3256 echo "${ECHO_T}no" >&6
3264 echo "$as_me:3264: checking for options to update archives" >&5
3265 echo $ECHO_N "checking for options to update archives... $ECHO_C" >&6
3266 if test "${cf_cv_ar_flags+set}" = set; then
3267 echo $ECHO_N "(cached) $ECHO_C" >&6
3270 cf_cv_ar_flags=unknown
3271 for cf_ar_flags in -curvU -curv curv -crv crv -cqv cqv -rv rv
3274 # check if $ARFLAGS already contains this choice
3275 if test "x$ARFLAGS" != "x" ; then
3276 cf_check_ar_flags=`echo "x$ARFLAGS" | sed -e "s/$cf_ar_flags\$//" -e "s/$cf_ar_flags / /"`
3277 if test "x$ARFLAGS" != "$cf_check_ar_flags" ; then
3283 rm -f conftest.$ac_cv_objext
3286 cat >conftest.$ac_ext <<EOF
3287 #line 3287 "configure"
3288 int testdata[3] = { 123, 456, 789 };
3290 if { (eval echo "$as_me:3290: \"$ac_compile\"") >&5
3291 (eval $ac_compile) 2>&5
3293 echo "$as_me:3293: \$? = $ac_status" >&5
3294 (exit $ac_status); } ; then
3295 echo "$AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext" >&5
3296 $AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext 2>&5 1>/dev/null
3297 if test -f conftest.a ; then
3298 cf_cv_ar_flags=$cf_ar_flags
3302 test -n "$verbose" && echo " cannot compile test-program" 1>&6
3304 echo "${as_me:-configure}:3304: testing cannot compile test-program ..." 1>&5
3309 rm -f conftest.a conftest.$ac_ext conftest.$ac_cv_objext
3312 echo "$as_me:3312: result: $cf_cv_ar_flags" >&5
3313 echo "${ECHO_T}$cf_cv_ar_flags" >&6
3315 if test -n "$ARFLAGS" ; then
3316 if test -n "$cf_cv_ar_flags" ; then
3317 ARFLAGS="$ARFLAGS $cf_cv_ar_flags"
3320 ARFLAGS=$cf_cv_ar_flags
3323 echo "$as_me:3323: checking for PATH separator" >&5
3324 echo $ECHO_N "checking for PATH separator... $ECHO_C" >&6
3325 case $cf_cv_system_name in
3326 (os2*) PATH_SEPARATOR=';' ;;
3327 (*) ${PATH_SEPARATOR:=':'} ;;
3330 echo "$as_me:3330: result: $PATH_SEPARATOR" >&5
3331 echo "${ECHO_T}$PATH_SEPARATOR" >&6
3333 echo "$as_me:3333: checking if you have specified an install-prefix" >&5
3334 echo $ECHO_N "checking if you have specified an install-prefix... $ECHO_C" >&6
3336 # Check whether --with-install-prefix or --without-install-prefix was given.
3337 if test "${with_install_prefix+set}" = set; then
3338 withval="$with_install_prefix"
3342 (*) DESTDIR="$withval"
3346 echo "$as_me:3346: result: $DESTDIR" >&5
3347 echo "${ECHO_T}$DESTDIR" >&6
3349 ###############################################################################
3351 # If we're cross-compiling, allow the user to override the tools and their
3352 # options. The configure script is oriented toward identifying the host
3353 # compiler, etc., but we need a build compiler to generate parts of the source.
3355 if test "$cross_compiling" = yes ; then
3357 # defaults that we might want to override
3358 : ${BUILD_CFLAGS:=''}
3359 : ${BUILD_CPPFLAGS:=''}
3360 : ${BUILD_LDFLAGS:=''}
3362 : ${BUILD_EXEEXT:='$x'}
3363 : ${BUILD_OBJEXT:='o'}
3365 # Check whether --with-build-cc or --without-build-cc was given.
3366 if test "${with_build_cc+set}" = set; then
3367 withval="$with_build_cc"
3370 for ac_prog in gcc cc cl
3372 # Extract the first word of "$ac_prog", so it can be a program name with args.
3373 set dummy $ac_prog; ac_word=$2
3374 echo "$as_me:3374: checking for $ac_word" >&5
3375 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3376 if test "${ac_cv_prog_BUILD_CC+set}" = set; then
3377 echo $ECHO_N "(cached) $ECHO_C" >&6
3379 if test -n "$BUILD_CC"; then
3380 ac_cv_prog_BUILD_CC="$BUILD_CC" # Let the user override the test.
3382 ac_save_IFS=$IFS; IFS=$ac_path_separator
3384 for ac_dir in $ac_dummy; do
3386 test -z "$ac_dir" && ac_dir=.
3387 $as_executable_p "$ac_dir/$ac_word" || continue
3388 ac_cv_prog_BUILD_CC="$ac_prog"
3389 echo "$as_me:3389: found $ac_dir/$ac_word" >&5
3395 BUILD_CC=$ac_cv_prog_BUILD_CC
3396 if test -n "$BUILD_CC"; then
3397 echo "$as_me:3397: result: $BUILD_CC" >&5
3398 echo "${ECHO_T}$BUILD_CC" >&6
3400 echo "$as_me:3400: result: no" >&5
3401 echo "${ECHO_T}no" >&6
3404 test -n "$BUILD_CC" && break
3408 echo "$as_me:3408: checking for native build C compiler" >&5
3409 echo $ECHO_N "checking for native build C compiler... $ECHO_C" >&6
3410 echo "$as_me:3410: result: $BUILD_CC" >&5
3411 echo "${ECHO_T}$BUILD_CC" >&6
3413 echo "$as_me:3413: checking for native build C preprocessor" >&5
3414 echo $ECHO_N "checking for native build C preprocessor... $ECHO_C" >&6
3416 # Check whether --with-build-cpp or --without-build-cpp was given.
3417 if test "${with_build_cpp+set}" = set; then
3418 withval="$with_build_cpp"
3419 BUILD_CPP="$withval"
3421 BUILD_CPP='${BUILD_CC} -E'
3423 echo "$as_me:3423: result: $BUILD_CPP" >&5
3424 echo "${ECHO_T}$BUILD_CPP" >&6
3426 echo "$as_me:3426: checking for native build C flags" >&5
3427 echo $ECHO_N "checking for native build C flags... $ECHO_C" >&6
3429 # Check whether --with-build-cflags or --without-build-cflags was given.
3430 if test "${with_build_cflags+set}" = set; then
3431 withval="$with_build_cflags"
3432 BUILD_CFLAGS="$withval"
3434 echo "$as_me:3434: result: $BUILD_CFLAGS" >&5
3435 echo "${ECHO_T}$BUILD_CFLAGS" >&6
3437 echo "$as_me:3437: checking for native build C preprocessor-flags" >&5
3438 echo $ECHO_N "checking for native build C preprocessor-flags... $ECHO_C" >&6
3440 # Check whether --with-build-cppflags or --without-build-cppflags was given.
3441 if test "${with_build_cppflags+set}" = set; then
3442 withval="$with_build_cppflags"
3443 BUILD_CPPFLAGS="$withval"
3445 echo "$as_me:3445: result: $BUILD_CPPFLAGS" >&5
3446 echo "${ECHO_T}$BUILD_CPPFLAGS" >&6
3448 echo "$as_me:3448: checking for native build linker-flags" >&5
3449 echo $ECHO_N "checking for native build linker-flags... $ECHO_C" >&6
3451 # Check whether --with-build-ldflags or --without-build-ldflags was given.
3452 if test "${with_build_ldflags+set}" = set; then
3453 withval="$with_build_ldflags"
3454 BUILD_LDFLAGS="$withval"
3456 echo "$as_me:3456: result: $BUILD_LDFLAGS" >&5
3457 echo "${ECHO_T}$BUILD_LDFLAGS" >&6
3459 echo "$as_me:3459: checking for native build linker-libraries" >&5
3460 echo $ECHO_N "checking for native build linker-libraries... $ECHO_C" >&6
3462 # Check whether --with-build-libs or --without-build-libs was given.
3463 if test "${with_build_libs+set}" = set; then
3464 withval="$with_build_libs"
3465 BUILD_LIBS="$withval"
3467 echo "$as_me:3467: result: $BUILD_LIBS" >&5
3468 echo "${ECHO_T}$BUILD_LIBS" >&6
3470 # this assumes we're on Unix.
3474 : ${BUILD_CC:='${CC}'}
3476 if ( test "$BUILD_CC" = "$CC" || test "$BUILD_CC" = '${CC}' ) ; then
3477 { { echo "$as_me:3477: error: Cross-build requires two compilers.
3478 Use --with-build-cc to specify the native compiler." >&5
3479 echo "$as_me: error: Cross-build requires two compilers.
3480 Use --with-build-cc to specify the native compiler." >&2;}
3481 { (exit 1); exit 1; }; }
3485 : ${BUILD_CC:='${CC}'}
3486 : ${BUILD_CPP:='${CPP}'}
3487 : ${BUILD_CFLAGS:='${CFLAGS}'}
3488 : ${BUILD_CPPFLAGS:='${CPPFLAGS}'}
3489 : ${BUILD_LDFLAGS:='${LDFLAGS}'}
3490 : ${BUILD_LIBS:='${LIBS}'}
3491 : ${BUILD_EXEEXT:='$x'}
3492 : ${BUILD_OBJEXT:='o'}
3495 ###############################################################################
3497 ### Options to allow the user to specify the set of libraries which are used.
3498 ### Use "--without-normal --with-shared" to allow the default model to be
3499 ### shared, for example.
3502 echo "$as_me:3502: checking if you want to build shared C-objects" >&5
3503 echo $ECHO_N "checking if you want to build shared C-objects... $ECHO_C" >&6
3505 # Check whether --with-shared or --without-shared was given.
3506 if test "${with_shared+set}" = set; then
3507 withval="$with_shared"
3508 with_shared=$withval
3512 echo "$as_me:3512: result: $with_shared" >&5
3513 echo "${ECHO_T}$with_shared" >&6
3514 test "$with_shared" = "yes" && cf_list_models="$cf_list_models shared"
3516 echo "$as_me:3516: checking for specified models" >&5
3517 echo $ECHO_N "checking for specified models... $ECHO_C" >&6
3518 test -z "$cf_list_models" && cf_list_models=normal
3519 echo "$as_me:3519: result: $cf_list_models" >&5
3520 echo "${ECHO_T}$cf_list_models" >&6
3522 ### Use the first model as the default, and save its suffix for use in building
3523 ### up test-applications.
3524 echo "$as_me:3524: checking for default model" >&5
3525 echo $ECHO_N "checking for default model... $ECHO_C" >&6
3526 DFT_LWR_MODEL=`echo "$cf_list_models" | $AWK '{print $1}'`
3527 echo "$as_me:3527: result: $DFT_LWR_MODEL" >&5
3528 echo "${ECHO_T}$DFT_LWR_MODEL" >&6
3530 DFT_UPR_MODEL=`echo "$DFT_LWR_MODEL" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
3532 echo "$as_me:3532: checking for specific curses-directory" >&5
3533 echo $ECHO_N "checking for specific curses-directory... $ECHO_C" >&6
3535 # Check whether --with-curses-dir or --without-curses-dir was given.
3536 if test "${with_curses_dir+set}" = set; then
3537 withval="$with_curses_dir"
3538 cf_cv_curses_dir=$withval
3542 echo "$as_me:3542: result: $cf_cv_curses_dir" >&5
3543 echo "${ECHO_T}$cf_cv_curses_dir" >&6
3545 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
3548 if test "x$prefix" != xNONE; then
3549 cf_path_syntax="$prefix"
3551 cf_path_syntax="$ac_default_prefix"
3559 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
3561 (.\${*prefix}*|.\${*dir}*)
3562 eval withval="$withval"
3565 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
3570 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
3573 { { echo "$as_me:3573: error: expected a pathname, not \"$withval\"" >&5
3574 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
3575 { (exit 1); exit 1; }; }
3579 if test -d "$cf_cv_curses_dir"
3582 if test -n "$cf_cv_curses_dir/include" ; then
3583 for cf_add_incdir in $cf_cv_curses_dir/include
3585 while test $cf_add_incdir != /usr/include
3587 if test -d $cf_add_incdir
3590 if test -n "$CFLAGS$CPPFLAGS" ; then
3591 # a loop is needed to ensure we can add subdirs of existing dirs
3592 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
3593 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
3594 cf_have_incdir=yes; break
3599 if test "$cf_have_incdir" = no ; then
3600 if test "$cf_add_incdir" = /usr/local/include ; then
3601 if test "$GCC" = yes
3603 cf_save_CPPFLAGS=$CPPFLAGS
3604 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
3605 cat >conftest.$ac_ext <<_ACEOF
3606 #line 3606 "configure"
3607 #include "confdefs.h"
3617 rm -f conftest.$ac_objext
3618 if { (eval echo "$as_me:3618: \"$ac_compile\"") >&5
3619 (eval $ac_compile) 2>&5
3621 echo "$as_me:3621: \$? = $ac_status" >&5
3622 (exit $ac_status); } &&
3623 { ac_try='test -s conftest.$ac_objext'
3624 { (eval echo "$as_me:3624: \"$ac_try\"") >&5
3627 echo "$as_me:3627: \$? = $ac_status" >&5
3628 (exit $ac_status); }; }; then
3631 echo "$as_me: failed program was:" >&5
3632 cat conftest.$ac_ext >&5
3635 rm -f conftest.$ac_objext conftest.$ac_ext
3636 CPPFLAGS=$cf_save_CPPFLAGS
3641 if test "$cf_have_incdir" = no ; then
3642 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
3644 echo "${as_me:-configure}:3644: testing adding $cf_add_incdir to include-path ..." 1>&5
3646 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
3648 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
3649 test "$cf_top_incdir" = "$cf_add_incdir" && break
3650 cf_add_incdir="$cf_top_incdir"
3661 if test -n "$cf_cv_curses_dir/lib" ; then
3662 for cf_add_libdir in $cf_cv_curses_dir/lib
3664 if test $cf_add_libdir = /usr/lib ; then
3666 elif test -d $cf_add_libdir
3669 if test -n "$LDFLAGS$LIBS" ; then
3670 # a loop is needed to ensure we can add subdirs of existing dirs
3671 for cf_test_libdir in $LDFLAGS $LIBS ; do
3672 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
3673 cf_have_libdir=yes; break
3677 if test "$cf_have_libdir" = no ; then
3678 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
3680 echo "${as_me:-configure}:3680: testing adding $cf_add_libdir to library-path ..." 1>&5
3682 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
3691 cf_ncuconfig_root=ncurses
3692 cf_have_ncuconfig=no
3694 if test "x${PKG_CONFIG:=none}" != xnone; then
3695 echo "$as_me:3695: checking pkg-config for $cf_ncuconfig_root" >&5
3696 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
3697 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
3698 echo "$as_me:3698: result: yes" >&5
3699 echo "${ECHO_T}yes" >&6
3701 echo "$as_me:3701: checking if the $cf_ncuconfig_root package files work" >&5
3702 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
3703 cf_have_ncuconfig=unknown
3705 cf_save_CPPFLAGS="$CPPFLAGS"
3706 cf_save_LIBS="$LIBS"
3708 CPPFLAGS="$CPPFLAGS `$PKG_CONFIG --cflags $cf_ncuconfig_root`"
3710 cf_add_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
3711 # Filter out duplicates - this happens with badly-designed ".pc" files...
3712 for cf_add_1lib in $LIBS
3714 for cf_add_2lib in $cf_add_libs
3716 if test "x$cf_add_1lib" = "x$cf_add_2lib"
3722 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
3726 cat >conftest.$ac_ext <<_ACEOF
3727 #line 3727 "configure"
3728 #include "confdefs.h"
3729 #include <${cf_cv_ncurses_header:-curses.h}>
3733 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
3738 rm -f conftest.$ac_objext conftest$ac_exeext
3739 if { (eval echo "$as_me:3739: \"$ac_link\"") >&5
3740 (eval $ac_link) 2>&5
3742 echo "$as_me:3742: \$? = $ac_status" >&5
3743 (exit $ac_status); } &&
3744 { ac_try='test -s conftest$ac_exeext'
3745 { (eval echo "$as_me:3745: \"$ac_try\"") >&5
3748 echo "$as_me:3748: \$? = $ac_status" >&5
3749 (exit $ac_status); }; }; then
3750 if test "$cross_compiling" = yes; then
3751 cf_have_ncuconfig=maybe
3753 cat >conftest.$ac_ext <<_ACEOF
3754 #line 3754 "configure"
3755 #include "confdefs.h"
3756 #include <${cf_cv_ncurses_header:-curses.h}>
3758 { char *xx = curses_version(); return (xx == 0); }
3760 rm -f conftest$ac_exeext
3761 if { (eval echo "$as_me:3761: \"$ac_link\"") >&5
3762 (eval $ac_link) 2>&5
3764 echo "$as_me:3764: \$? = $ac_status" >&5
3765 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3766 { (eval echo "$as_me:3766: \"$ac_try\"") >&5
3769 echo "$as_me:3769: \$? = $ac_status" >&5
3770 (exit $ac_status); }; }; then
3771 cf_have_ncuconfig=yes
3773 echo "$as_me: program exited with status $ac_status" >&5
3774 echo "$as_me: failed program was:" >&5
3775 cat conftest.$ac_ext >&5
3776 cf_have_ncuconfig=no
3778 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
3781 echo "$as_me: failed program was:" >&5
3782 cat conftest.$ac_ext >&5
3783 cf_have_ncuconfig=no
3785 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3786 echo "$as_me:3786: result: $cf_have_ncuconfig" >&5
3787 echo "${ECHO_T}$cf_have_ncuconfig" >&6
3788 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
3789 if test "$cf_have_ncuconfig" != "yes"
3791 CPPFLAGS="$cf_save_CPPFLAGS"
3792 LIBS="$cf_save_LIBS"
3793 NCURSES_CONFIG_PKG=none
3796 cat >>confdefs.h <<\EOF
3800 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
3804 echo "$as_me:3804: result: no" >&5
3805 echo "${ECHO_T}no" >&6
3806 NCURSES_CONFIG_PKG=none
3809 NCURSES_CONFIG_PKG=none
3812 if test "x$cf_have_ncuconfig" = "xno"; then
3813 echo "Looking for ${cf_ncuconfig_root}-config"
3815 if test -n "$ac_tool_prefix"; then
3816 for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
3818 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3819 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3820 echo "$as_me:3820: checking for $ac_word" >&5
3821 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3822 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
3823 echo $ECHO_N "(cached) $ECHO_C" >&6
3825 if test -n "$NCURSES_CONFIG"; then
3826 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
3828 ac_save_IFS=$IFS; IFS=$ac_path_separator
3830 for ac_dir in $ac_dummy; do
3832 test -z "$ac_dir" && ac_dir=.
3833 $as_executable_p "$ac_dir/$ac_word" || continue
3834 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
3835 echo "$as_me:3835: found $ac_dir/$ac_word" >&5
3841 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
3842 if test -n "$NCURSES_CONFIG"; then
3843 echo "$as_me:3843: result: $NCURSES_CONFIG" >&5
3844 echo "${ECHO_T}$NCURSES_CONFIG" >&6
3846 echo "$as_me:3846: result: no" >&5
3847 echo "${ECHO_T}no" >&6
3850 test -n "$NCURSES_CONFIG" && break
3853 if test -z "$NCURSES_CONFIG"; then
3854 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
3855 for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
3857 # Extract the first word of "$ac_prog", so it can be a program name with args.
3858 set dummy $ac_prog; ac_word=$2
3859 echo "$as_me:3859: checking for $ac_word" >&5
3860 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3861 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
3862 echo $ECHO_N "(cached) $ECHO_C" >&6
3864 if test -n "$ac_ct_NCURSES_CONFIG"; then
3865 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
3867 ac_save_IFS=$IFS; IFS=$ac_path_separator
3869 for ac_dir in $ac_dummy; do
3871 test -z "$ac_dir" && ac_dir=.
3872 $as_executable_p "$ac_dir/$ac_word" || continue
3873 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
3874 echo "$as_me:3874: found $ac_dir/$ac_word" >&5
3880 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
3881 if test -n "$ac_ct_NCURSES_CONFIG"; then
3882 echo "$as_me:3882: result: $ac_ct_NCURSES_CONFIG" >&5
3883 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
3885 echo "$as_me:3885: result: no" >&5
3886 echo "${ECHO_T}no" >&6
3889 test -n "$ac_ct_NCURSES_CONFIG" && break
3891 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
3893 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
3896 if test "$NCURSES_CONFIG" != none ; then
3898 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
3900 cf_add_libs="`$NCURSES_CONFIG --libs`"
3901 # Filter out duplicates - this happens with badly-designed ".pc" files...
3902 for cf_add_1lib in $LIBS
3904 for cf_add_2lib in $cf_add_libs
3906 if test "x$cf_add_1lib" = "x$cf_add_2lib"
3912 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
3916 # even with config script, some packages use no-override for curses.h
3918 echo "$as_me:3918: checking if we have identified curses headers" >&5
3919 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
3920 if test "${cf_cv_ncurses_header+set}" = set; then
3921 echo $ECHO_N "(cached) $ECHO_C" >&6
3924 cf_cv_ncurses_header=none
3926 ncurses.h ncurses/ncurses.h \
3927 curses.h ncurses/curses.h
3929 cat >conftest.$ac_ext <<_ACEOF
3930 #line 3930 "configure"
3931 #include "confdefs.h"
3932 #include <${cf_header}>
3936 initscr(); tgoto("?", 0,0)
3941 rm -f conftest.$ac_objext
3942 if { (eval echo "$as_me:3942: \"$ac_compile\"") >&5
3943 (eval $ac_compile) 2>&5
3945 echo "$as_me:3945: \$? = $ac_status" >&5
3946 (exit $ac_status); } &&
3947 { ac_try='test -s conftest.$ac_objext'
3948 { (eval echo "$as_me:3948: \"$ac_try\"") >&5
3951 echo "$as_me:3951: \$? = $ac_status" >&5
3952 (exit $ac_status); }; }; then
3953 cf_cv_ncurses_header=$cf_header; break
3955 echo "$as_me: failed program was:" >&5
3956 cat conftest.$ac_ext >&5
3958 rm -f conftest.$ac_objext conftest.$ac_ext
3962 echo "$as_me:3962: result: $cf_cv_ncurses_header" >&5
3963 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
3965 if test "$cf_cv_ncurses_header" = none ; then
3966 { { echo "$as_me:3966: error: No curses header-files found" >&5
3967 echo "$as_me: error: No curses header-files found" >&2;}
3968 { (exit 1); exit 1; }; }
3971 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
3973 for ac_header in $cf_cv_ncurses_header
3975 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3976 echo "$as_me:3976: checking for $ac_header" >&5
3977 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3978 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3979 echo $ECHO_N "(cached) $ECHO_C" >&6
3981 cat >conftest.$ac_ext <<_ACEOF
3982 #line 3982 "configure"
3983 #include "confdefs.h"
3984 #include <$ac_header>
3986 if { (eval echo "$as_me:3986: \"$ac_cpp conftest.$ac_ext\"") >&5
3987 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3989 egrep -v '^ *\+' conftest.er1 >conftest.err
3991 cat conftest.err >&5
3992 echo "$as_me:3992: \$? = $ac_status" >&5
3993 (exit $ac_status); } >/dev/null; then
3994 if test -s conftest.err; then
3995 ac_cpp_err=$ac_c_preproc_warn_flag
4002 if test -z "$ac_cpp_err"; then
4003 eval "$as_ac_Header=yes"
4005 echo "$as_me: failed program was:" >&5
4006 cat conftest.$ac_ext >&5
4007 eval "$as_ac_Header=no"
4009 rm -f conftest.err conftest.$ac_ext
4011 echo "$as_me:4011: result: `eval echo '${'$as_ac_Header'}'`" >&5
4012 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4013 if test `eval echo '${'$as_ac_Header'}'` = yes; then
4014 cat >>confdefs.h <<EOF
4015 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4021 cat >>confdefs.h <<\EOF
4025 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
4027 cat >>confdefs.h <<EOF
4028 #define $cf_nculib_ROOT 1
4031 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
4035 cf_ncuhdr_root=ncurses
4037 test -n "$cf_cv_curses_dir" && \
4038 test "$cf_cv_curses_dir" != "no" && { \
4040 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
4041 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
4043 while test $cf_add_incdir != /usr/include
4045 if test -d $cf_add_incdir
4048 if test -n "$CFLAGS$CPPFLAGS" ; then
4049 # a loop is needed to ensure we can add subdirs of existing dirs
4050 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
4051 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
4052 cf_have_incdir=yes; break
4057 if test "$cf_have_incdir" = no ; then
4058 if test "$cf_add_incdir" = /usr/local/include ; then
4059 if test "$GCC" = yes
4061 cf_save_CPPFLAGS=$CPPFLAGS
4062 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4063 cat >conftest.$ac_ext <<_ACEOF
4064 #line 4064 "configure"
4065 #include "confdefs.h"
4075 rm -f conftest.$ac_objext
4076 if { (eval echo "$as_me:4076: \"$ac_compile\"") >&5
4077 (eval $ac_compile) 2>&5
4079 echo "$as_me:4079: \$? = $ac_status" >&5
4080 (exit $ac_status); } &&
4081 { ac_try='test -s conftest.$ac_objext'
4082 { (eval echo "$as_me:4082: \"$ac_try\"") >&5
4085 echo "$as_me:4085: \$? = $ac_status" >&5
4086 (exit $ac_status); }; }; then
4089 echo "$as_me: failed program was:" >&5
4090 cat conftest.$ac_ext >&5
4093 rm -f conftest.$ac_objext conftest.$ac_ext
4094 CPPFLAGS=$cf_save_CPPFLAGS
4099 if test "$cf_have_incdir" = no ; then
4100 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
4102 echo "${as_me:-configure}:4102: testing adding $cf_add_incdir to include-path ..." 1>&5
4104 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4106 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
4107 test "$cf_top_incdir" = "$cf_add_incdir" && break
4108 cf_add_incdir="$cf_top_incdir"
4121 echo "$as_me:4121: checking for $cf_ncuhdr_root header in include-path" >&5
4122 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
4123 if test "${cf_cv_ncurses_h+set}" = set; then
4124 echo $ECHO_N "(cached) $ECHO_C" >&6
4127 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
4128 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
4129 for cf_header in $cf_header_list
4132 cat >conftest.$ac_ext <<_ACEOF
4133 #line 4133 "configure"
4134 #include "confdefs.h"
4136 #include <$cf_header>
4141 #ifdef NCURSES_VERSION
4143 printf("%s\n", NCURSES_VERSION);
4156 rm -f conftest.$ac_objext
4157 if { (eval echo "$as_me:4157: \"$ac_compile\"") >&5
4158 (eval $ac_compile) 2>&5
4160 echo "$as_me:4160: \$? = $ac_status" >&5
4161 (exit $ac_status); } &&
4162 { ac_try='test -s conftest.$ac_objext'
4163 { (eval echo "$as_me:4163: \"$ac_try\"") >&5
4166 echo "$as_me:4166: \$? = $ac_status" >&5
4167 (exit $ac_status); }; }; then
4168 cf_cv_ncurses_h=$cf_header
4171 echo "$as_me: failed program was:" >&5
4172 cat conftest.$ac_ext >&5
4175 rm -f conftest.$ac_objext conftest.$ac_ext
4177 test "$cf_cv_ncurses_h" != no && break
4181 echo "$as_me:4181: result: $cf_cv_ncurses_h" >&5
4182 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
4184 if test "$cf_cv_ncurses_h" != no ; then
4185 cf_cv_ncurses_header=$cf_cv_ncurses_h
4188 echo "$as_me:4188: checking for $cf_ncuhdr_root include-path" >&5
4189 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
4190 if test "${cf_cv_ncurses_h2+set}" = set; then
4191 echo $ECHO_N "(cached) $ECHO_C" >&6
4194 test -n "$verbose" && echo
4198 # collect the current set of include-directories from compiler flags
4199 cf_header_path_list=""
4200 if test -n "${CFLAGS}${CPPFLAGS}" ; then
4201 for cf_header_path in $CPPFLAGS $CFLAGS
4203 case $cf_header_path in
4205 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
4207 test "x$cf_header_path" != "xNONE" && \
4208 test -d "$cf_header_path" && \
4210 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
4211 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
4212 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
4213 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
4214 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
4215 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"
4218 cf_header_path_list="$cf_header_path_list $cf_search"
4224 # add the variations for the package we are looking for
4228 test "x$prefix" != "xNONE" && \
4229 test -d "$prefix" && \
4231 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
4232 test -d $prefix/include && cf_search="$cf_search $prefix/include"
4233 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
4234 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
4235 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
4236 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
4239 for cf_subdir_prefix in \
4248 test "x$cf_subdir_prefix" != "x$prefix" && \
4249 test -d "$cf_subdir_prefix" && \
4250 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
4251 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
4252 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
4253 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
4254 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
4255 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
4256 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"
4261 test "$includedir" != NONE && \
4262 test "$includedir" != "/usr/include" && \
4263 test -d "$includedir" && {
4264 test -d $includedir && cf_search="$cf_search $includedir"
4265 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
4268 test "$oldincludedir" != NONE && \
4269 test "$oldincludedir" != "/usr/include" && \
4270 test -d "$oldincludedir" && {
4271 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
4272 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
4275 cf_search="$cf_search $cf_header_path_list"
4277 test -n "$verbose" && echo search path $cf_search
4278 cf_save2_CPPFLAGS="$CPPFLAGS"
4279 for cf_incdir in $cf_search
4282 if test -n "$cf_incdir" ; then
4283 for cf_add_incdir in $cf_incdir
4285 while test $cf_add_incdir != /usr/include
4287 if test -d $cf_add_incdir
4290 if test -n "$CFLAGS$CPPFLAGS" ; then
4291 # a loop is needed to ensure we can add subdirs of existing dirs
4292 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
4293 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
4294 cf_have_incdir=yes; break
4299 if test "$cf_have_incdir" = no ; then
4300 if test "$cf_add_incdir" = /usr/local/include ; then
4301 if test "$GCC" = yes
4303 cf_save_CPPFLAGS=$CPPFLAGS
4304 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4305 cat >conftest.$ac_ext <<_ACEOF
4306 #line 4306 "configure"
4307 #include "confdefs.h"
4317 rm -f conftest.$ac_objext
4318 if { (eval echo "$as_me:4318: \"$ac_compile\"") >&5
4319 (eval $ac_compile) 2>&5
4321 echo "$as_me:4321: \$? = $ac_status" >&5
4322 (exit $ac_status); } &&
4323 { ac_try='test -s conftest.$ac_objext'
4324 { (eval echo "$as_me:4324: \"$ac_try\"") >&5
4327 echo "$as_me:4327: \$? = $ac_status" >&5
4328 (exit $ac_status); }; }; then
4331 echo "$as_me: failed program was:" >&5
4332 cat conftest.$ac_ext >&5
4335 rm -f conftest.$ac_objext conftest.$ac_ext
4336 CPPFLAGS=$cf_save_CPPFLAGS
4341 if test "$cf_have_incdir" = no ; then
4342 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
4344 echo "${as_me:-configure}:4344: testing adding $cf_add_incdir to include-path ..." 1>&5
4346 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4348 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
4349 test "$cf_top_incdir" = "$cf_add_incdir" && break
4350 cf_add_incdir="$cf_top_incdir"
4366 cat >conftest.$ac_ext <<_ACEOF
4367 #line 4367 "configure"
4368 #include "confdefs.h"
4370 #include <$cf_header>
4375 #ifdef NCURSES_VERSION
4377 printf("%s\n", NCURSES_VERSION);
4390 rm -f conftest.$ac_objext
4391 if { (eval echo "$as_me:4391: \"$ac_compile\"") >&5
4392 (eval $ac_compile) 2>&5
4394 echo "$as_me:4394: \$? = $ac_status" >&5
4395 (exit $ac_status); } &&
4396 { ac_try='test -s conftest.$ac_objext'
4397 { (eval echo "$as_me:4397: \"$ac_try\"") >&5
4400 echo "$as_me:4400: \$? = $ac_status" >&5
4401 (exit $ac_status); }; }; then
4402 cf_cv_ncurses_h2=$cf_header
4405 echo "$as_me: failed program was:" >&5
4406 cat conftest.$ac_ext >&5
4409 rm -f conftest.$ac_objext conftest.$ac_ext
4411 if test "$cf_cv_ncurses_h2" != no ; then
4412 cf_cv_ncurses_h2=$cf_incdir/$cf_header
4413 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
4416 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
4418 CPPFLAGS="$cf_save2_CPPFLAGS"
4419 test "$cf_cv_ncurses_h2" != no && break
4421 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:4421: error: not found" >&5
4422 echo "$as_me: error: not found" >&2;}
4423 { (exit 1); exit 1; }; }
4426 echo "$as_me:4426: result: $cf_cv_ncurses_h2" >&5
4427 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
4429 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
4430 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
4431 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
4432 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
4435 if test -n "$cf_1st_incdir" ; then
4436 for cf_add_incdir in $cf_1st_incdir
4438 while test $cf_add_incdir != /usr/include
4440 if test -d $cf_add_incdir
4443 if test -n "$CFLAGS$CPPFLAGS" ; then
4444 # a loop is needed to ensure we can add subdirs of existing dirs
4445 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
4446 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
4447 cf_have_incdir=yes; break
4452 if test "$cf_have_incdir" = no ; then
4453 if test "$cf_add_incdir" = /usr/local/include ; then
4454 if test "$GCC" = yes
4456 cf_save_CPPFLAGS=$CPPFLAGS
4457 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4458 cat >conftest.$ac_ext <<_ACEOF
4459 #line 4459 "configure"
4460 #include "confdefs.h"
4470 rm -f conftest.$ac_objext
4471 if { (eval echo "$as_me:4471: \"$ac_compile\"") >&5
4472 (eval $ac_compile) 2>&5
4474 echo "$as_me:4474: \$? = $ac_status" >&5
4475 (exit $ac_status); } &&
4476 { ac_try='test -s conftest.$ac_objext'
4477 { (eval echo "$as_me:4477: \"$ac_try\"") >&5
4480 echo "$as_me:4480: \$? = $ac_status" >&5
4481 (exit $ac_status); }; }; then
4484 echo "$as_me: failed program was:" >&5
4485 cat conftest.$ac_ext >&5
4488 rm -f conftest.$ac_objext conftest.$ac_ext
4489 CPPFLAGS=$cf_save_CPPFLAGS
4494 if test "$cf_have_incdir" = no ; then
4495 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
4497 echo "${as_me:-configure}:4497: testing adding $cf_add_incdir to include-path ..." 1>&5
4499 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4501 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
4502 test "$cf_top_incdir" = "$cf_add_incdir" && break
4503 cf_add_incdir="$cf_top_incdir"
4516 # Set definitions to allow ifdef'ing for ncurses.h
4518 case $cf_cv_ncurses_header in
4521 cat >>confdefs.h <<\EOF
4522 #define HAVE_NCURSES_H 1
4528 case $cf_cv_ncurses_header in
4529 (ncurses/curses.h|ncurses/ncurses.h)
4531 cat >>confdefs.h <<\EOF
4532 #define HAVE_NCURSES_NCURSES_H 1
4536 (ncursesw/curses.h|ncursesw/ncurses.h)
4538 cat >>confdefs.h <<\EOF
4539 #define HAVE_NCURSESW_NCURSES_H 1
4545 echo "$as_me:4545: checking for terminfo header" >&5
4546 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
4547 if test "${cf_cv_term_header+set}" = set; then
4548 echo $ECHO_N "(cached) $ECHO_C" >&6
4551 case ${cf_cv_ncurses_header} in
4552 (*/ncurses.h|*/ncursesw.h)
4553 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
4556 cf_term_header=term.h
4560 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
4562 cat >conftest.$ac_ext <<_ACEOF
4563 #line 4563 "configure"
4564 #include "confdefs.h"
4566 #include <${cf_cv_ncurses_header:-curses.h}>
4572 int x = auto_left_margin
4577 rm -f conftest.$ac_objext
4578 if { (eval echo "$as_me:4578: \"$ac_compile\"") >&5
4579 (eval $ac_compile) 2>&5
4581 echo "$as_me:4581: \$? = $ac_status" >&5
4582 (exit $ac_status); } &&
4583 { ac_try='test -s conftest.$ac_objext'
4584 { (eval echo "$as_me:4584: \"$ac_try\"") >&5
4587 echo "$as_me:4587: \$? = $ac_status" >&5
4588 (exit $ac_status); }; }; then
4590 cf_cv_term_header="$cf_test"
4592 echo "$as_me: failed program was:" >&5
4593 cat conftest.$ac_ext >&5
4595 cf_cv_term_header=unknown
4598 rm -f conftest.$ac_objext conftest.$ac_ext
4599 test "$cf_cv_term_header" != unknown && break
4603 echo "$as_me:4603: result: $cf_cv_term_header" >&5
4604 echo "${ECHO_T}$cf_cv_term_header" >&6
4606 # Set definitions to allow ifdef'ing to accommodate subdirectories
4608 case $cf_cv_term_header in
4611 cat >>confdefs.h <<\EOF
4612 #define HAVE_TERM_H 1
4618 case $cf_cv_term_header in
4621 cat >>confdefs.h <<\EOF
4622 #define HAVE_NCURSES_TERM_H 1
4628 cat >>confdefs.h <<\EOF
4629 #define HAVE_NCURSESW_TERM_H 1
4635 # some applications need this, but should check for NCURSES_VERSION
4637 cat >>confdefs.h <<\EOF
4641 echo "$as_me:4641: checking for ncurses version" >&5
4642 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
4643 if test "${cf_cv_ncurses_version+set}" = set; then
4644 echo $ECHO_N "(cached) $ECHO_C" >&6
4647 cf_cv_ncurses_version=no
4650 if test "$cross_compiling" = yes; then
4652 # This will not work if the preprocessor splits the line after the
4653 # Autoconf token. The 'unproto' program does that.
4654 cat > conftest.$ac_ext <<EOF
4655 #include <${cf_cv_ncurses_header:-curses.h}>
4657 #ifdef NCURSES_VERSION
4658 Autoconf NCURSES_VERSION
4666 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
4667 { (eval echo "$as_me:4667: \"$cf_try\"") >&5
4670 echo "$as_me:4670: \$? = $ac_status" >&5
4671 (exit $ac_status); }
4672 if test -f conftest.out ; then
4673 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
4674 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
4679 cat >conftest.$ac_ext <<_ACEOF
4680 #line 4680 "configure"
4681 #include "confdefs.h"
4683 #include <${cf_cv_ncurses_header:-curses.h}>
4687 FILE *fp = fopen("$cf_tempfile", "w");
4688 #ifdef NCURSES_VERSION
4689 # ifdef NCURSES_VERSION_PATCH
4690 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
4692 fprintf(fp, "%s\n", NCURSES_VERSION);
4696 fprintf(fp, "old\n");
4701 ${cf_cv_main_return:-return}(0);
4704 rm -f conftest$ac_exeext
4705 if { (eval echo "$as_me:4705: \"$ac_link\"") >&5
4706 (eval $ac_link) 2>&5
4708 echo "$as_me:4708: \$? = $ac_status" >&5
4709 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4710 { (eval echo "$as_me:4710: \"$ac_try\"") >&5
4713 echo "$as_me:4713: \$? = $ac_status" >&5
4714 (exit $ac_status); }; }; then
4716 cf_cv_ncurses_version=`cat $cf_tempfile`
4718 echo "$as_me: program exited with status $ac_status" >&5
4719 echo "$as_me: failed program was:" >&5
4720 cat conftest.$ac_ext >&5
4722 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4727 echo "$as_me:4727: result: $cf_cv_ncurses_version" >&5
4728 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
4729 test "$cf_cv_ncurses_version" = no ||
4730 cat >>confdefs.h <<\EOF
4734 cf_nculib_root=ncurses
4735 # This works, except for the special case where we find gpm, but
4736 # ncurses is in a nonstandard location via $LIBS, and we really want
4739 cf_ncurses_SAVE="$LIBS"
4740 echo "$as_me:4740: checking for Gpm_Open in -lgpm" >&5
4741 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
4742 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
4743 echo $ECHO_N "(cached) $ECHO_C" >&6
4745 ac_check_lib_save_LIBS=$LIBS
4747 cat >conftest.$ac_ext <<_ACEOF
4748 #line 4748 "configure"
4749 #include "confdefs.h"
4751 /* Override any gcc2 internal prototype to avoid an error. */
4755 /* We use char because int might match the return type of a gcc2
4756 builtin and then its argument prototype would still apply. */
4766 rm -f conftest.$ac_objext conftest$ac_exeext
4767 if { (eval echo "$as_me:4767: \"$ac_link\"") >&5
4768 (eval $ac_link) 2>&5
4770 echo "$as_me:4770: \$? = $ac_status" >&5
4771 (exit $ac_status); } &&
4772 { ac_try='test -s conftest$ac_exeext'
4773 { (eval echo "$as_me:4773: \"$ac_try\"") >&5
4776 echo "$as_me:4776: \$? = $ac_status" >&5
4777 (exit $ac_status); }; }; then
4778 ac_cv_lib_gpm_Gpm_Open=yes
4780 echo "$as_me: failed program was:" >&5
4781 cat conftest.$ac_ext >&5
4782 ac_cv_lib_gpm_Gpm_Open=no
4784 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4785 LIBS=$ac_check_lib_save_LIBS
4787 echo "$as_me:4787: result: $ac_cv_lib_gpm_Gpm_Open" >&5
4788 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
4789 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
4790 echo "$as_me:4790: checking for initscr in -lgpm" >&5
4791 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
4792 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
4793 echo $ECHO_N "(cached) $ECHO_C" >&6
4795 ac_check_lib_save_LIBS=$LIBS
4797 cat >conftest.$ac_ext <<_ACEOF
4798 #line 4798 "configure"
4799 #include "confdefs.h"
4801 /* Override any gcc2 internal prototype to avoid an error. */
4805 /* We use char because int might match the return type of a gcc2
4806 builtin and then its argument prototype would still apply. */
4816 rm -f conftest.$ac_objext conftest$ac_exeext
4817 if { (eval echo "$as_me:4817: \"$ac_link\"") >&5
4818 (eval $ac_link) 2>&5
4820 echo "$as_me:4820: \$? = $ac_status" >&5
4821 (exit $ac_status); } &&
4822 { ac_try='test -s conftest$ac_exeext'
4823 { (eval echo "$as_me:4823: \"$ac_try\"") >&5
4826 echo "$as_me:4826: \$? = $ac_status" >&5
4827 (exit $ac_status); }; }; then
4828 ac_cv_lib_gpm_initscr=yes
4830 echo "$as_me: failed program was:" >&5
4831 cat conftest.$ac_ext >&5
4832 ac_cv_lib_gpm_initscr=no
4834 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4835 LIBS=$ac_check_lib_save_LIBS
4837 echo "$as_me:4837: result: $ac_cv_lib_gpm_initscr" >&5
4838 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
4839 if test $ac_cv_lib_gpm_initscr = yes; then
4840 LIBS="$cf_ncurses_SAVE"
4842 cf_ncurses_LIBS="-lgpm"
4849 # This is only necessary if you are linking against an obsolete
4850 # version of ncurses (but it should do no harm, since it's static).
4851 if test "$cf_nculib_root" = ncurses ; then
4852 echo "$as_me:4852: checking for tgoto in -lmytinfo" >&5
4853 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
4854 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
4855 echo $ECHO_N "(cached) $ECHO_C" >&6
4857 ac_check_lib_save_LIBS=$LIBS
4858 LIBS="-lmytinfo $LIBS"
4859 cat >conftest.$ac_ext <<_ACEOF
4860 #line 4860 "configure"
4861 #include "confdefs.h"
4863 /* Override any gcc2 internal prototype to avoid an error. */
4867 /* We use char because int might match the return type of a gcc2
4868 builtin and then its argument prototype would still apply. */
4878 rm -f conftest.$ac_objext conftest$ac_exeext
4879 if { (eval echo "$as_me:4879: \"$ac_link\"") >&5
4880 (eval $ac_link) 2>&5
4882 echo "$as_me:4882: \$? = $ac_status" >&5
4883 (exit $ac_status); } &&
4884 { ac_try='test -s conftest$ac_exeext'
4885 { (eval echo "$as_me:4885: \"$ac_try\"") >&5
4888 echo "$as_me:4888: \$? = $ac_status" >&5
4889 (exit $ac_status); }; }; then
4890 ac_cv_lib_mytinfo_tgoto=yes
4892 echo "$as_me: failed program was:" >&5
4893 cat conftest.$ac_ext >&5
4894 ac_cv_lib_mytinfo_tgoto=no
4896 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4897 LIBS=$ac_check_lib_save_LIBS
4899 echo "$as_me:4899: result: $ac_cv_lib_mytinfo_tgoto" >&5
4900 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
4901 if test $ac_cv_lib_mytinfo_tgoto = yes; then
4902 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
4909 cf_add_libs="$cf_ncurses_LIBS"
4910 # Filter out duplicates - this happens with badly-designed ".pc" files...
4911 for cf_add_1lib in $LIBS
4913 for cf_add_2lib in $cf_add_libs
4915 if test "x$cf_add_1lib" = "x$cf_add_2lib"
4921 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
4925 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
4928 cf_add_libs="-l$cf_nculib_root"
4929 # Filter out duplicates - this happens with badly-designed ".pc" files...
4930 for cf_add_1lib in $LIBS
4932 for cf_add_2lib in $cf_add_libs
4934 if test "x$cf_add_1lib" = "x$cf_add_2lib"
4940 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
4946 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
4948 echo "$as_me:4948: checking for initscr" >&5
4949 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
4950 if test "${ac_cv_func_initscr+set}" = set; then
4951 echo $ECHO_N "(cached) $ECHO_C" >&6
4953 cat >conftest.$ac_ext <<_ACEOF
4954 #line 4954 "configure"
4955 #include "confdefs.h"
4956 /* System header to define __stub macros and hopefully few prototypes,
4957 which can conflict with char initscr (); below. */
4959 /* Override any gcc2 internal prototype to avoid an error. */
4963 /* We use char because int might match the return type of a gcc2
4964 builtin and then its argument prototype would still apply. */
4971 /* The GNU C library defines this for functions which it implements
4972 to always fail with ENOSYS. Some functions are actually named
4973 something starting with __ and the normal name is an alias. */
4974 #if defined (__stub_initscr) || defined (__stub___initscr)
4977 f = initscr; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
4984 rm -f conftest.$ac_objext conftest$ac_exeext
4985 if { (eval echo "$as_me:4985: \"$ac_link\"") >&5
4986 (eval $ac_link) 2>&5
4988 echo "$as_me:4988: \$? = $ac_status" >&5
4989 (exit $ac_status); } &&
4990 { ac_try='test -s conftest$ac_exeext'
4991 { (eval echo "$as_me:4991: \"$ac_try\"") >&5
4994 echo "$as_me:4994: \$? = $ac_status" >&5
4995 (exit $ac_status); }; }; then
4996 ac_cv_func_initscr=yes
4998 echo "$as_me: failed program was:" >&5
4999 cat conftest.$ac_ext >&5
5000 ac_cv_func_initscr=no
5002 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5004 echo "$as_me:5004: result: $ac_cv_func_initscr" >&5
5005 echo "${ECHO_T}$ac_cv_func_initscr" >&6
5006 if test $ac_cv_func_initscr = yes; then
5007 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
5010 cf_save_LIBS="$LIBS"
5011 echo "$as_me:5011: checking for initscr in -l$cf_nculib_root" >&5
5012 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
5013 LIBS="-l$cf_nculib_root $LIBS"
5014 cat >conftest.$ac_ext <<_ACEOF
5015 #line 5015 "configure"
5016 #include "confdefs.h"
5017 #include <${cf_cv_ncurses_header:-curses.h}>
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 echo "$as_me:5038: result: yes" >&5
5039 echo "${ECHO_T}yes" >&6
5040 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
5043 echo "$as_me: failed program was:" >&5
5044 cat conftest.$ac_ext >&5
5045 echo "$as_me:5045: result: no" >&5
5046 echo "${ECHO_T}no" >&6
5049 cf_library_path_list=""
5050 if test -n "${LDFLAGS}${LIBS}" ; then
5051 for cf_library_path in $LDFLAGS $LIBS
5053 case $cf_library_path in
5055 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
5057 test "x$cf_library_path" != "xNONE" && \
5058 test -d "$cf_library_path" && \
5060 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
5061 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
5062 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
5063 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
5064 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
5065 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"
5068 cf_library_path_list="$cf_library_path_list $cf_search"
5076 test "x$prefix" != "xNONE" && \
5077 test -d "$prefix" && \
5079 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
5080 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
5081 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
5082 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
5083 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
5084 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
5087 for cf_subdir_prefix in \
5096 test "x$cf_subdir_prefix" != "x$prefix" && \
5097 test -d "$cf_subdir_prefix" && \
5098 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
5099 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
5100 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
5101 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
5102 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
5103 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
5104 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"
5109 cf_search="$cf_library_path_list $cf_search"
5111 for cf_libdir in $cf_search
5113 echo "$as_me:5113: checking for -l$cf_nculib_root in $cf_libdir" >&5
5114 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
5115 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
5116 cat >conftest.$ac_ext <<_ACEOF
5117 #line 5117 "configure"
5118 #include "confdefs.h"
5119 #include <${cf_cv_ncurses_header:-curses.h}>
5128 rm -f conftest.$ac_objext conftest$ac_exeext
5129 if { (eval echo "$as_me:5129: \"$ac_link\"") >&5
5130 (eval $ac_link) 2>&5
5132 echo "$as_me:5132: \$? = $ac_status" >&5
5133 (exit $ac_status); } &&
5134 { ac_try='test -s conftest$ac_exeext'
5135 { (eval echo "$as_me:5135: \"$ac_try\"") >&5
5138 echo "$as_me:5138: \$? = $ac_status" >&5
5139 (exit $ac_status); }; }; then
5140 echo "$as_me:5140: result: yes" >&5
5141 echo "${ECHO_T}yes" >&6
5142 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
5145 echo "$as_me: failed program was:" >&5
5146 cat conftest.$ac_ext >&5
5147 echo "$as_me:5147: result: no" >&5
5148 echo "${ECHO_T}no" >&6
5149 LIBS="$cf_save_LIBS"
5151 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5155 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5159 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
5161 if test $cf_found_library = no ; then
5162 { { echo "$as_me:5162: error: Cannot link $cf_nculib_root library" >&5
5163 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
5164 { (exit 1); exit 1; }; }
5169 if test -n "$cf_ncurses_LIBS" ; then
5170 echo "$as_me:5170: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
5171 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
5172 cf_ncurses_SAVE="$LIBS"
5173 for p in $cf_ncurses_LIBS ; do
5174 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
5175 if test "$q" != "$LIBS" ; then
5179 cat >conftest.$ac_ext <<_ACEOF
5180 #line 5180 "configure"
5181 #include "confdefs.h"
5182 #include <${cf_cv_ncurses_header:-curses.h}>
5186 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
5191 rm -f conftest.$ac_objext conftest$ac_exeext
5192 if { (eval echo "$as_me:5192: \"$ac_link\"") >&5
5193 (eval $ac_link) 2>&5
5195 echo "$as_me:5195: \$? = $ac_status" >&5
5196 (exit $ac_status); } &&
5197 { ac_try='test -s conftest$ac_exeext'
5198 { (eval echo "$as_me:5198: \"$ac_try\"") >&5
5201 echo "$as_me:5201: \$? = $ac_status" >&5
5202 (exit $ac_status); }; }; then
5203 echo "$as_me:5203: result: yes" >&5
5204 echo "${ECHO_T}yes" >&6
5206 echo "$as_me: failed program was:" >&5
5207 cat conftest.$ac_ext >&5
5208 echo "$as_me:5208: result: no" >&5
5209 echo "${ECHO_T}no" >&6
5210 LIBS="$cf_ncurses_SAVE"
5212 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5215 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
5217 cat >>confdefs.h <<EOF
5218 #define $cf_nculib_ROOT 1
5226 echo "$as_me:5226: checking if you want wide-character code" >&5
5227 echo $ECHO_N "checking if you want wide-character code... $ECHO_C" >&6
5229 # Check whether --enable-widec or --disable-widec was given.
5230 if test "${enable_widec+set}" = set; then
5231 enableval="$enable_widec"
5232 with_widec=$enableval
5236 echo "$as_me:5236: result: $with_widec" >&5
5237 echo "${ECHO_T}$with_widec" >&6
5238 if test "$with_widec" = yes ; then
5240 echo "$as_me:5240: checking for multibyte character support" >&5
5241 echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
5242 if test "${cf_cv_utf8_lib+set}" = set; then
5243 echo $ECHO_N "(cached) $ECHO_C" >&6
5246 cf_save_LIBS="$LIBS"
5247 cat >conftest.$ac_ext <<_ACEOF
5248 #line 5248 "configure"
5249 #include "confdefs.h"
5260 rm -f conftest.$ac_objext conftest$ac_exeext
5261 if { (eval echo "$as_me:5261: \"$ac_link\"") >&5
5262 (eval $ac_link) 2>&5
5264 echo "$as_me:5264: \$? = $ac_status" >&5
5265 (exit $ac_status); } &&
5266 { ac_try='test -s conftest$ac_exeext'
5267 { (eval echo "$as_me:5267: \"$ac_try\"") >&5
5270 echo "$as_me:5270: \$? = $ac_status" >&5
5271 (exit $ac_status); }; }; then
5274 echo "$as_me: failed program was:" >&5
5275 cat conftest.$ac_ext >&5
5277 # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
5278 # will be set on completion of the AC_TRY_LINK below.
5279 cf_cv_header_path_utf8=
5280 cf_cv_library_path_utf8=
5282 echo "${as_me:-configure}:5282: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
5284 cf_save_LIBS="$LIBS"
5286 cat >conftest.$ac_ext <<_ACEOF
5287 #line 5287 "configure"
5288 #include "confdefs.h"
5290 #include <libutf8.h>
5299 rm -f conftest.$ac_objext conftest$ac_exeext
5300 if { (eval echo "$as_me:5300: \"$ac_link\"") >&5
5301 (eval $ac_link) 2>&5
5303 echo "$as_me:5303: \$? = $ac_status" >&5
5304 (exit $ac_status); } &&
5305 { ac_try='test -s conftest$ac_exeext'
5306 { (eval echo "$as_me:5306: \"$ac_try\"") >&5
5309 echo "$as_me:5309: \$? = $ac_status" >&5
5310 (exit $ac_status); }; }; then
5312 cf_cv_find_linkage_utf8=yes
5313 cf_cv_header_path_utf8=/usr/include
5314 cf_cv_library_path_utf8=/usr/lib
5317 echo "$as_me: failed program was:" >&5
5318 cat conftest.$ac_ext >&5
5320 LIBS="-lutf8 $cf_save_LIBS"
5322 cat >conftest.$ac_ext <<_ACEOF
5323 #line 5323 "configure"
5324 #include "confdefs.h"
5326 #include <libutf8.h>
5335 rm -f conftest.$ac_objext conftest$ac_exeext
5336 if { (eval echo "$as_me:5336: \"$ac_link\"") >&5
5337 (eval $ac_link) 2>&5
5339 echo "$as_me:5339: \$? = $ac_status" >&5
5340 (exit $ac_status); } &&
5341 { ac_try='test -s conftest$ac_exeext'
5342 { (eval echo "$as_me:5342: \"$ac_try\"") >&5
5345 echo "$as_me:5345: \$? = $ac_status" >&5
5346 (exit $ac_status); }; }; then
5348 cf_cv_find_linkage_utf8=yes
5349 cf_cv_header_path_utf8=/usr/include
5350 cf_cv_library_path_utf8=/usr/lib
5351 cf_cv_library_file_utf8="-lutf8"
5354 echo "$as_me: failed program was:" >&5
5355 cat conftest.$ac_ext >&5
5357 cf_cv_find_linkage_utf8=no
5358 LIBS="$cf_save_LIBS"
5360 test -n "$verbose" && echo " find linkage for utf8 library" 1>&6
5362 echo "${as_me:-configure}:5362: testing find linkage for utf8 library ..." 1>&5
5364 echo "${as_me:-configure}:5364: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
5366 cf_save_CPPFLAGS="$CPPFLAGS"
5367 cf_test_CPPFLAGS="$CPPFLAGS"
5371 # collect the current set of include-directories from compiler flags
5372 cf_header_path_list=""
5373 if test -n "${CFLAGS}${CPPFLAGS}" ; then
5374 for cf_header_path in $CPPFLAGS $CFLAGS
5376 case $cf_header_path in
5378 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
5380 test "x$cf_header_path" != "xNONE" && \
5381 test -d "$cf_header_path" && \
5383 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
5384 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
5385 test -d $cf_header_path/include/utf8 && cf_search="$cf_search $cf_header_path/include/utf8"
5386 test -d $cf_header_path/include/utf8/include && cf_search="$cf_search $cf_header_path/include/utf8/include"
5387 test -d $cf_header_path/utf8/include && cf_search="$cf_search $cf_header_path/utf8/include"
5388 test -d $cf_header_path/utf8/include/utf8 && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
5391 cf_header_path_list="$cf_header_path_list $cf_search"
5397 # add the variations for the package we are looking for
5401 test "x$prefix" != "xNONE" && \
5402 test -d "$prefix" && \
5404 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
5405 test -d $prefix/include && cf_search="$cf_search $prefix/include"
5406 test -d $prefix/include/utf8 && cf_search="$cf_search $prefix/include/utf8"
5407 test -d $prefix/include/utf8/include && cf_search="$cf_search $prefix/include/utf8/include"
5408 test -d $prefix/utf8/include && cf_search="$cf_search $prefix/utf8/include"
5409 test -d $prefix/utf8/include/utf8 && cf_search="$cf_search $prefix/utf8/include/utf8"
5412 for cf_subdir_prefix in \
5421 test "x$cf_subdir_prefix" != "x$prefix" && \
5422 test -d "$cf_subdir_prefix" && \
5423 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
5424 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
5425 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
5426 test -d $cf_subdir_prefix/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/include/utf8"
5427 test -d $cf_subdir_prefix/include/utf8/include && cf_search="$cf_search $cf_subdir_prefix/include/utf8/include"
5428 test -d $cf_subdir_prefix/utf8/include && cf_search="$cf_search $cf_subdir_prefix/utf8/include"
5429 test -d $cf_subdir_prefix/utf8/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/include/utf8"
5434 test "$includedir" != NONE && \
5435 test "$includedir" != "/usr/include" && \
5436 test -d "$includedir" && {
5437 test -d $includedir && cf_search="$cf_search $includedir"
5438 test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8"
5441 test "$oldincludedir" != NONE && \
5442 test "$oldincludedir" != "/usr/include" && \
5443 test -d "$oldincludedir" && {
5444 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
5445 test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8"
5448 cf_search="$cf_search $cf_header_path_list"
5450 for cf_cv_header_path_utf8 in $cf_search
5452 if test -d $cf_cv_header_path_utf8 ; then
5453 test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6
5455 echo "${as_me:-configure}:5455: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
5457 CPPFLAGS="$cf_save_CPPFLAGS -I$cf_cv_header_path_utf8"
5458 cat >conftest.$ac_ext <<_ACEOF
5459 #line 5459 "configure"
5460 #include "confdefs.h"
5462 #include <libutf8.h>
5471 rm -f conftest.$ac_objext
5472 if { (eval echo "$as_me:5472: \"$ac_compile\"") >&5
5473 (eval $ac_compile) 2>&5
5475 echo "$as_me:5475: \$? = $ac_status" >&5
5476 (exit $ac_status); } &&
5477 { ac_try='test -s conftest.$ac_objext'
5478 { (eval echo "$as_me:5478: \"$ac_try\"") >&5
5481 echo "$as_me:5481: \$? = $ac_status" >&5
5482 (exit $ac_status); }; }; then
5484 test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
5486 echo "${as_me:-configure}:5486: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
5488 cf_cv_find_linkage_utf8=maybe
5489 cf_test_CPPFLAGS="$CPPFLAGS"
5492 echo "$as_me: failed program was:" >&5
5493 cat conftest.$ac_ext >&5
5495 CPPFLAGS="$cf_save_CPPFLAGS"
5498 rm -f conftest.$ac_objext conftest.$ac_ext
5502 if test "$cf_cv_find_linkage_utf8" = maybe ; then
5504 echo "${as_me:-configure}:5504: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
5506 cf_save_LIBS="$LIBS"
5507 cf_save_LDFLAGS="$LDFLAGS"
5509 if test "$cf_cv_find_linkage_utf8" != yes ; then
5512 cf_library_path_list=""
5513 if test -n "${LDFLAGS}${LIBS}" ; then
5514 for cf_library_path in $LDFLAGS $LIBS
5516 case $cf_library_path in
5518 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
5520 test "x$cf_library_path" != "xNONE" && \
5521 test -d "$cf_library_path" && \
5523 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
5524 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
5525 test -d $cf_library_path/lib/utf8 && cf_search="$cf_search $cf_library_path/lib/utf8"
5526 test -d $cf_library_path/lib/utf8/lib && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
5527 test -d $cf_library_path/utf8/lib && cf_search="$cf_search $cf_library_path/utf8/lib"
5528 test -d $cf_library_path/utf8/lib/utf8 && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
5531 cf_library_path_list="$cf_library_path_list $cf_search"
5539 test "x$prefix" != "xNONE" && \
5540 test -d "$prefix" && \
5542 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
5543 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
5544 test -d $prefix/lib/utf8 && cf_search="$cf_search $prefix/lib/utf8"
5545 test -d $prefix/lib/utf8/lib && cf_search="$cf_search $prefix/lib/utf8/lib"
5546 test -d $prefix/utf8/lib && cf_search="$cf_search $prefix/utf8/lib"
5547 test -d $prefix/utf8/lib/utf8 && cf_search="$cf_search $prefix/utf8/lib/utf8"
5550 for cf_subdir_prefix in \
5559 test "x$cf_subdir_prefix" != "x$prefix" && \
5560 test -d "$cf_subdir_prefix" && \
5561 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
5562 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
5563 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
5564 test -d $cf_subdir_prefix/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/lib/utf8"
5565 test -d $cf_subdir_prefix/lib/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/lib/utf8/lib"
5566 test -d $cf_subdir_prefix/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/utf8/lib"
5567 test -d $cf_subdir_prefix/utf8/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/lib/utf8"
5572 cf_search="$cf_library_path_list $cf_search"
5574 for cf_cv_library_path_utf8 in $cf_search
5576 if test -d $cf_cv_library_path_utf8 ; then
5577 test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6
5579 echo "${as_me:-configure}:5579: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
5581 CPPFLAGS="$cf_test_CPPFLAGS"
5582 LIBS="-lutf8 $cf_save_LIBS"
5583 LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
5584 cat >conftest.$ac_ext <<_ACEOF
5585 #line 5585 "configure"
5586 #include "confdefs.h"
5588 #include <libutf8.h>
5597 rm -f conftest.$ac_objext conftest$ac_exeext
5598 if { (eval echo "$as_me:5598: \"$ac_link\"") >&5
5599 (eval $ac_link) 2>&5
5601 echo "$as_me:5601: \$? = $ac_status" >&5
5602 (exit $ac_status); } &&
5603 { ac_try='test -s conftest$ac_exeext'
5604 { (eval echo "$as_me:5604: \"$ac_try\"") >&5
5607 echo "$as_me:5607: \$? = $ac_status" >&5
5608 (exit $ac_status); }; }; then
5610 test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
5612 echo "${as_me:-configure}:5612: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
5614 cf_cv_find_linkage_utf8=yes
5615 cf_cv_library_file_utf8="-lutf8"
5618 echo "$as_me: failed program was:" >&5
5619 cat conftest.$ac_ext >&5
5621 CPPFLAGS="$cf_save_CPPFLAGS"
5622 LIBS="$cf_save_LIBS"
5623 LDFLAGS="$cf_save_LDFLAGS"
5626 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5629 CPPFLAGS="$cf_save_CPPFLAGS"
5630 LDFLAGS="$cf_save_LDFLAGS"
5634 cf_cv_find_linkage_utf8=no
5638 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5641 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5643 LIBS="$cf_save_LIBS"
5645 if test "$cf_cv_find_linkage_utf8" = yes ; then
5646 cf_cv_utf8_lib=add-on
5652 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5654 echo "$as_me:5654: result: $cf_cv_utf8_lib" >&5
5655 echo "${ECHO_T}$cf_cv_utf8_lib" >&6
5657 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
5659 if test "$cf_cv_utf8_lib" = "add-on" ; then
5661 cat >>confdefs.h <<\EOF
5662 #define HAVE_LIBUTF8_H 1
5665 if test -n "$cf_cv_header_path_utf8" ; then
5666 for cf_add_incdir in $cf_cv_header_path_utf8
5668 while test $cf_add_incdir != /usr/include
5670 if test -d $cf_add_incdir
5673 if test -n "$CFLAGS$CPPFLAGS" ; then
5674 # a loop is needed to ensure we can add subdirs of existing dirs
5675 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5676 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5677 cf_have_incdir=yes; break
5682 if test "$cf_have_incdir" = no ; then
5683 if test "$cf_add_incdir" = /usr/local/include ; then
5684 if test "$GCC" = yes
5686 cf_save_CPPFLAGS=$CPPFLAGS
5687 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5688 cat >conftest.$ac_ext <<_ACEOF
5689 #line 5689 "configure"
5690 #include "confdefs.h"
5700 rm -f conftest.$ac_objext
5701 if { (eval echo "$as_me:5701: \"$ac_compile\"") >&5
5702 (eval $ac_compile) 2>&5
5704 echo "$as_me:5704: \$? = $ac_status" >&5
5705 (exit $ac_status); } &&
5706 { ac_try='test -s conftest.$ac_objext'
5707 { (eval echo "$as_me:5707: \"$ac_try\"") >&5
5710 echo "$as_me:5710: \$? = $ac_status" >&5
5711 (exit $ac_status); }; }; then
5714 echo "$as_me: failed program was:" >&5
5715 cat conftest.$ac_ext >&5
5718 rm -f conftest.$ac_objext conftest.$ac_ext
5719 CPPFLAGS=$cf_save_CPPFLAGS
5724 if test "$cf_have_incdir" = no ; then
5725 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5727 echo "${as_me:-configure}:5727: testing adding $cf_add_incdir to include-path ..." 1>&5
5729 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5731 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
5732 test "$cf_top_incdir" = "$cf_add_incdir" && break
5733 cf_add_incdir="$cf_top_incdir"
5744 if test -n "$cf_cv_library_path_utf8" ; then
5745 for cf_add_libdir in $cf_cv_library_path_utf8
5747 if test $cf_add_libdir = /usr/lib ; then
5749 elif test -d $cf_add_libdir
5752 if test -n "$LDFLAGS$LIBS" ; then
5753 # a loop is needed to ensure we can add subdirs of existing dirs
5754 for cf_test_libdir in $LDFLAGS $LIBS ; do
5755 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5756 cf_have_libdir=yes; break
5760 if test "$cf_have_libdir" = no ; then
5761 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5763 echo "${as_me:-configure}:5763: testing adding $cf_add_libdir to library-path ..." 1>&5
5765 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5771 cf_add_libs="$cf_cv_library_file_utf8"
5772 # Filter out duplicates - this happens with badly-designed ".pc" files...
5773 for cf_add_1lib in $LIBS
5775 for cf_add_2lib in $cf_add_libs
5777 if test "x$cf_add_1lib" = "x$cf_add_2lib"
5783 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
5789 cf_ncuconfig_root=ncursesw
5790 cf_have_ncuconfig=no
5792 if test "x${PKG_CONFIG:=none}" != xnone; then
5793 echo "$as_me:5793: checking pkg-config for $cf_ncuconfig_root" >&5
5794 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
5795 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
5796 echo "$as_me:5796: result: yes" >&5
5797 echo "${ECHO_T}yes" >&6
5799 echo "$as_me:5799: checking if the $cf_ncuconfig_root package files work" >&5
5800 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
5801 cf_have_ncuconfig=unknown
5803 cf_save_CPPFLAGS="$CPPFLAGS"
5804 cf_save_LIBS="$LIBS"
5806 CPPFLAGS="$CPPFLAGS `$PKG_CONFIG --cflags $cf_ncuconfig_root`"
5808 cf_add_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
5809 # Filter out duplicates - this happens with badly-designed ".pc" files...
5810 for cf_add_1lib in $LIBS
5812 for cf_add_2lib in $cf_add_libs
5814 if test "x$cf_add_1lib" = "x$cf_add_2lib"
5820 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
5824 cat >conftest.$ac_ext <<_ACEOF
5825 #line 5825 "configure"
5826 #include "confdefs.h"
5827 #include <${cf_cv_ncurses_header:-curses.h}>
5831 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
5836 rm -f conftest.$ac_objext conftest$ac_exeext
5837 if { (eval echo "$as_me:5837: \"$ac_link\"") >&5
5838 (eval $ac_link) 2>&5
5840 echo "$as_me:5840: \$? = $ac_status" >&5
5841 (exit $ac_status); } &&
5842 { ac_try='test -s conftest$ac_exeext'
5843 { (eval echo "$as_me:5843: \"$ac_try\"") >&5
5846 echo "$as_me:5846: \$? = $ac_status" >&5
5847 (exit $ac_status); }; }; then
5848 if test "$cross_compiling" = yes; then
5849 cf_have_ncuconfig=maybe
5851 cat >conftest.$ac_ext <<_ACEOF
5852 #line 5852 "configure"
5853 #include "confdefs.h"
5854 #include <${cf_cv_ncurses_header:-curses.h}>
5856 { char *xx = curses_version(); return (xx == 0); }
5858 rm -f conftest$ac_exeext
5859 if { (eval echo "$as_me:5859: \"$ac_link\"") >&5
5860 (eval $ac_link) 2>&5
5862 echo "$as_me:5862: \$? = $ac_status" >&5
5863 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5864 { (eval echo "$as_me:5864: \"$ac_try\"") >&5
5867 echo "$as_me:5867: \$? = $ac_status" >&5
5868 (exit $ac_status); }; }; then
5869 cf_have_ncuconfig=yes
5871 echo "$as_me: program exited with status $ac_status" >&5
5872 echo "$as_me: failed program was:" >&5
5873 cat conftest.$ac_ext >&5
5874 cf_have_ncuconfig=no
5876 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5879 echo "$as_me: failed program was:" >&5
5880 cat conftest.$ac_ext >&5
5881 cf_have_ncuconfig=no
5883 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5884 echo "$as_me:5884: result: $cf_have_ncuconfig" >&5
5885 echo "${ECHO_T}$cf_have_ncuconfig" >&6
5886 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
5887 if test "$cf_have_ncuconfig" != "yes"
5889 CPPFLAGS="$cf_save_CPPFLAGS"
5890 LIBS="$cf_save_LIBS"
5891 NCURSES_CONFIG_PKG=none
5894 cat >>confdefs.h <<\EOF
5898 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
5902 echo "$as_me:5902: result: no" >&5
5903 echo "${ECHO_T}no" >&6
5904 NCURSES_CONFIG_PKG=none
5907 NCURSES_CONFIG_PKG=none
5910 if test "x$cf_have_ncuconfig" = "xno"; then
5911 echo "Looking for ${cf_ncuconfig_root}-config"
5913 if test -n "$ac_tool_prefix"; then
5914 for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
5916 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5917 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5918 echo "$as_me:5918: checking for $ac_word" >&5
5919 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5920 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
5921 echo $ECHO_N "(cached) $ECHO_C" >&6
5923 if test -n "$NCURSES_CONFIG"; then
5924 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
5926 ac_save_IFS=$IFS; IFS=$ac_path_separator
5928 for ac_dir in $ac_dummy; do
5930 test -z "$ac_dir" && ac_dir=.
5931 $as_executable_p "$ac_dir/$ac_word" || continue
5932 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
5933 echo "$as_me:5933: found $ac_dir/$ac_word" >&5
5939 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
5940 if test -n "$NCURSES_CONFIG"; then
5941 echo "$as_me:5941: result: $NCURSES_CONFIG" >&5
5942 echo "${ECHO_T}$NCURSES_CONFIG" >&6
5944 echo "$as_me:5944: result: no" >&5
5945 echo "${ECHO_T}no" >&6
5948 test -n "$NCURSES_CONFIG" && break
5951 if test -z "$NCURSES_CONFIG"; then
5952 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
5953 for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
5955 # Extract the first word of "$ac_prog", so it can be a program name with args.
5956 set dummy $ac_prog; ac_word=$2
5957 echo "$as_me:5957: checking for $ac_word" >&5
5958 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5959 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
5960 echo $ECHO_N "(cached) $ECHO_C" >&6
5962 if test -n "$ac_ct_NCURSES_CONFIG"; then
5963 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
5965 ac_save_IFS=$IFS; IFS=$ac_path_separator
5967 for ac_dir in $ac_dummy; do
5969 test -z "$ac_dir" && ac_dir=.
5970 $as_executable_p "$ac_dir/$ac_word" || continue
5971 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
5972 echo "$as_me:5972: found $ac_dir/$ac_word" >&5
5978 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
5979 if test -n "$ac_ct_NCURSES_CONFIG"; then
5980 echo "$as_me:5980: result: $ac_ct_NCURSES_CONFIG" >&5
5981 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
5983 echo "$as_me:5983: result: no" >&5
5984 echo "${ECHO_T}no" >&6
5987 test -n "$ac_ct_NCURSES_CONFIG" && break
5989 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
5991 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
5994 if test "$NCURSES_CONFIG" != none ; then
5996 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
5998 cf_add_libs="`$NCURSES_CONFIG --libs`"
5999 # Filter out duplicates - this happens with badly-designed ".pc" files...
6000 for cf_add_1lib in $LIBS
6002 for cf_add_2lib in $cf_add_libs
6004 if test "x$cf_add_1lib" = "x$cf_add_2lib"
6010 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
6014 # even with config script, some packages use no-override for curses.h
6016 echo "$as_me:6016: checking if we have identified curses headers" >&5
6017 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
6018 if test "${cf_cv_ncurses_header+set}" = set; then
6019 echo $ECHO_N "(cached) $ECHO_C" >&6
6022 cf_cv_ncurses_header=none
6024 ncurses.h ncursesw/ncurses.h \
6025 curses.h ncursesw/curses.h
6027 cat >conftest.$ac_ext <<_ACEOF
6028 #line 6028 "configure"
6029 #include "confdefs.h"
6030 #include <${cf_header}>
6034 initscr(); tgoto("?", 0,0)
6039 rm -f conftest.$ac_objext
6040 if { (eval echo "$as_me:6040: \"$ac_compile\"") >&5
6041 (eval $ac_compile) 2>&5
6043 echo "$as_me:6043: \$? = $ac_status" >&5
6044 (exit $ac_status); } &&
6045 { ac_try='test -s conftest.$ac_objext'
6046 { (eval echo "$as_me:6046: \"$ac_try\"") >&5
6049 echo "$as_me:6049: \$? = $ac_status" >&5
6050 (exit $ac_status); }; }; then
6051 cf_cv_ncurses_header=$cf_header; break
6053 echo "$as_me: failed program was:" >&5
6054 cat conftest.$ac_ext >&5
6056 rm -f conftest.$ac_objext conftest.$ac_ext
6060 echo "$as_me:6060: result: $cf_cv_ncurses_header" >&5
6061 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
6063 if test "$cf_cv_ncurses_header" = none ; then
6064 { { echo "$as_me:6064: error: No curses header-files found" >&5
6065 echo "$as_me: error: No curses header-files found" >&2;}
6066 { (exit 1); exit 1; }; }
6069 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
6071 for ac_header in $cf_cv_ncurses_header
6073 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6074 echo "$as_me:6074: checking for $ac_header" >&5
6075 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6076 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6077 echo $ECHO_N "(cached) $ECHO_C" >&6
6079 cat >conftest.$ac_ext <<_ACEOF
6080 #line 6080 "configure"
6081 #include "confdefs.h"
6082 #include <$ac_header>
6084 if { (eval echo "$as_me:6084: \"$ac_cpp conftest.$ac_ext\"") >&5
6085 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6087 egrep -v '^ *\+' conftest.er1 >conftest.err
6089 cat conftest.err >&5
6090 echo "$as_me:6090: \$? = $ac_status" >&5
6091 (exit $ac_status); } >/dev/null; then
6092 if test -s conftest.err; then
6093 ac_cpp_err=$ac_c_preproc_warn_flag
6100 if test -z "$ac_cpp_err"; then
6101 eval "$as_ac_Header=yes"
6103 echo "$as_me: failed program was:" >&5
6104 cat conftest.$ac_ext >&5
6105 eval "$as_ac_Header=no"
6107 rm -f conftest.err conftest.$ac_ext
6109 echo "$as_me:6109: result: `eval echo '${'$as_ac_Header'}'`" >&5
6110 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6111 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6112 cat >>confdefs.h <<EOF
6113 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6119 cat >>confdefs.h <<\EOF
6123 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
6125 cat >>confdefs.h <<EOF
6126 #define $cf_nculib_ROOT 1
6129 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
6133 cf_ncuhdr_root=ncursesw
6135 test -n "$cf_cv_curses_dir" && \
6136 test "$cf_cv_curses_dir" != "no" && { \
6138 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
6139 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
6141 while test $cf_add_incdir != /usr/include
6143 if test -d $cf_add_incdir
6146 if test -n "$CFLAGS$CPPFLAGS" ; then
6147 # a loop is needed to ensure we can add subdirs of existing dirs
6148 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6149 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6150 cf_have_incdir=yes; break
6155 if test "$cf_have_incdir" = no ; then
6156 if test "$cf_add_incdir" = /usr/local/include ; then
6157 if test "$GCC" = yes
6159 cf_save_CPPFLAGS=$CPPFLAGS
6160 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6161 cat >conftest.$ac_ext <<_ACEOF
6162 #line 6162 "configure"
6163 #include "confdefs.h"
6173 rm -f conftest.$ac_objext
6174 if { (eval echo "$as_me:6174: \"$ac_compile\"") >&5
6175 (eval $ac_compile) 2>&5
6177 echo "$as_me:6177: \$? = $ac_status" >&5
6178 (exit $ac_status); } &&
6179 { ac_try='test -s conftest.$ac_objext'
6180 { (eval echo "$as_me:6180: \"$ac_try\"") >&5
6183 echo "$as_me:6183: \$? = $ac_status" >&5
6184 (exit $ac_status); }; }; then
6187 echo "$as_me: failed program was:" >&5
6188 cat conftest.$ac_ext >&5
6191 rm -f conftest.$ac_objext conftest.$ac_ext
6192 CPPFLAGS=$cf_save_CPPFLAGS
6197 if test "$cf_have_incdir" = no ; then
6198 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6200 echo "${as_me:-configure}:6200: testing adding $cf_add_incdir to include-path ..." 1>&5
6202 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6204 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6205 test "$cf_top_incdir" = "$cf_add_incdir" && break
6206 cf_add_incdir="$cf_top_incdir"
6219 echo "$as_me:6219: checking for $cf_ncuhdr_root header in include-path" >&5
6220 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
6221 if test "${cf_cv_ncurses_h+set}" = set; then
6222 echo $ECHO_N "(cached) $ECHO_C" >&6
6225 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
6226 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
6227 for cf_header in $cf_header_list
6230 cat >conftest.$ac_ext <<_ACEOF
6231 #line 6231 "configure"
6232 #include "confdefs.h"
6234 #define _XOPEN_SOURCE_EXTENDED
6235 #undef HAVE_LIBUTF8_H /* in case we used CF_UTF8_LIB */
6236 #define HAVE_LIBUTF8_H /* to force ncurses' header file to use cchar_t */
6238 #include <$cf_header>
6243 #ifdef NCURSES_VERSION
6249 printf("%s\n", NCURSES_VERSION);
6262 rm -f conftest.$ac_objext
6263 if { (eval echo "$as_me:6263: \"$ac_compile\"") >&5
6264 (eval $ac_compile) 2>&5
6266 echo "$as_me:6266: \$? = $ac_status" >&5
6267 (exit $ac_status); } &&
6268 { ac_try='test -s conftest.$ac_objext'
6269 { (eval echo "$as_me:6269: \"$ac_try\"") >&5
6272 echo "$as_me:6272: \$? = $ac_status" >&5
6273 (exit $ac_status); }; }; then
6274 cf_cv_ncurses_h=$cf_header
6277 echo "$as_me: failed program was:" >&5
6278 cat conftest.$ac_ext >&5
6281 rm -f conftest.$ac_objext conftest.$ac_ext
6283 test "$cf_cv_ncurses_h" != no && break
6287 echo "$as_me:6287: result: $cf_cv_ncurses_h" >&5
6288 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
6290 if test "$cf_cv_ncurses_h" != no ; then
6291 cf_cv_ncurses_header=$cf_cv_ncurses_h
6294 echo "$as_me:6294: checking for $cf_ncuhdr_root include-path" >&5
6295 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
6296 if test "${cf_cv_ncurses_h2+set}" = set; then
6297 echo $ECHO_N "(cached) $ECHO_C" >&6
6300 test -n "$verbose" && echo
6304 # collect the current set of include-directories from compiler flags
6305 cf_header_path_list=""
6306 if test -n "${CFLAGS}${CPPFLAGS}" ; then
6307 for cf_header_path in $CPPFLAGS $CFLAGS
6309 case $cf_header_path in
6311 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
6313 test "x$cf_header_path" != "xNONE" && \
6314 test -d "$cf_header_path" && \
6316 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
6317 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
6318 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
6319 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
6320 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
6321 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"
6324 cf_header_path_list="$cf_header_path_list $cf_search"
6330 # add the variations for the package we are looking for
6334 test "x$prefix" != "xNONE" && \
6335 test -d "$prefix" && \
6337 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
6338 test -d $prefix/include && cf_search="$cf_search $prefix/include"
6339 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
6340 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
6341 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
6342 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6345 for cf_subdir_prefix in \
6354 test "x$cf_subdir_prefix" != "x$prefix" && \
6355 test -d "$cf_subdir_prefix" && \
6356 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
6357 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
6358 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
6359 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
6360 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
6361 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
6362 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"
6367 test "$includedir" != NONE && \
6368 test "$includedir" != "/usr/include" && \
6369 test -d "$includedir" && {
6370 test -d $includedir && cf_search="$cf_search $includedir"
6371 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
6374 test "$oldincludedir" != NONE && \
6375 test "$oldincludedir" != "/usr/include" && \
6376 test -d "$oldincludedir" && {
6377 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
6378 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
6381 cf_search="$cf_search $cf_header_path_list"
6383 test -n "$verbose" && echo search path $cf_search
6384 cf_save2_CPPFLAGS="$CPPFLAGS"
6385 for cf_incdir in $cf_search
6388 if test -n "$cf_incdir" ; then
6389 for cf_add_incdir in $cf_incdir
6391 while test $cf_add_incdir != /usr/include
6393 if test -d $cf_add_incdir
6396 if test -n "$CFLAGS$CPPFLAGS" ; then
6397 # a loop is needed to ensure we can add subdirs of existing dirs
6398 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6399 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6400 cf_have_incdir=yes; break
6405 if test "$cf_have_incdir" = no ; then
6406 if test "$cf_add_incdir" = /usr/local/include ; then
6407 if test "$GCC" = yes
6409 cf_save_CPPFLAGS=$CPPFLAGS
6410 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6411 cat >conftest.$ac_ext <<_ACEOF
6412 #line 6412 "configure"
6413 #include "confdefs.h"
6423 rm -f conftest.$ac_objext
6424 if { (eval echo "$as_me:6424: \"$ac_compile\"") >&5
6425 (eval $ac_compile) 2>&5
6427 echo "$as_me:6427: \$? = $ac_status" >&5
6428 (exit $ac_status); } &&
6429 { ac_try='test -s conftest.$ac_objext'
6430 { (eval echo "$as_me:6430: \"$ac_try\"") >&5
6433 echo "$as_me:6433: \$? = $ac_status" >&5
6434 (exit $ac_status); }; }; then
6437 echo "$as_me: failed program was:" >&5
6438 cat conftest.$ac_ext >&5
6441 rm -f conftest.$ac_objext conftest.$ac_ext
6442 CPPFLAGS=$cf_save_CPPFLAGS
6447 if test "$cf_have_incdir" = no ; then
6448 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6450 echo "${as_me:-configure}:6450: testing adding $cf_add_incdir to include-path ..." 1>&5
6452 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6454 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6455 test "$cf_top_incdir" = "$cf_add_incdir" && break
6456 cf_add_incdir="$cf_top_incdir"
6472 cat >conftest.$ac_ext <<_ACEOF
6473 #line 6473 "configure"
6474 #include "confdefs.h"
6476 #include <$cf_header>
6481 #ifdef NCURSES_VERSION
6483 printf("%s\n", NCURSES_VERSION);
6496 rm -f conftest.$ac_objext
6497 if { (eval echo "$as_me:6497: \"$ac_compile\"") >&5
6498 (eval $ac_compile) 2>&5
6500 echo "$as_me:6500: \$? = $ac_status" >&5
6501 (exit $ac_status); } &&
6502 { ac_try='test -s conftest.$ac_objext'
6503 { (eval echo "$as_me:6503: \"$ac_try\"") >&5
6506 echo "$as_me:6506: \$? = $ac_status" >&5
6507 (exit $ac_status); }; }; then
6508 cf_cv_ncurses_h2=$cf_header
6511 echo "$as_me: failed program was:" >&5
6512 cat conftest.$ac_ext >&5
6515 rm -f conftest.$ac_objext conftest.$ac_ext
6517 if test "$cf_cv_ncurses_h2" != no ; then
6518 cf_cv_ncurses_h2=$cf_incdir/$cf_header
6519 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
6522 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
6524 CPPFLAGS="$cf_save2_CPPFLAGS"
6525 test "$cf_cv_ncurses_h2" != no && break
6527 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:6527: error: not found" >&5
6528 echo "$as_me: error: not found" >&2;}
6529 { (exit 1); exit 1; }; }
6532 echo "$as_me:6532: result: $cf_cv_ncurses_h2" >&5
6533 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
6535 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
6536 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
6537 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
6538 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
6541 if test -n "$cf_1st_incdir" ; then
6542 for cf_add_incdir in $cf_1st_incdir
6544 while test $cf_add_incdir != /usr/include
6546 if test -d $cf_add_incdir
6549 if test -n "$CFLAGS$CPPFLAGS" ; then
6550 # a loop is needed to ensure we can add subdirs of existing dirs
6551 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6552 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6553 cf_have_incdir=yes; break
6558 if test "$cf_have_incdir" = no ; then
6559 if test "$cf_add_incdir" = /usr/local/include ; then
6560 if test "$GCC" = yes
6562 cf_save_CPPFLAGS=$CPPFLAGS
6563 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6564 cat >conftest.$ac_ext <<_ACEOF
6565 #line 6565 "configure"
6566 #include "confdefs.h"
6576 rm -f conftest.$ac_objext
6577 if { (eval echo "$as_me:6577: \"$ac_compile\"") >&5
6578 (eval $ac_compile) 2>&5
6580 echo "$as_me:6580: \$? = $ac_status" >&5
6581 (exit $ac_status); } &&
6582 { ac_try='test -s conftest.$ac_objext'
6583 { (eval echo "$as_me:6583: \"$ac_try\"") >&5
6586 echo "$as_me:6586: \$? = $ac_status" >&5
6587 (exit $ac_status); }; }; then
6590 echo "$as_me: failed program was:" >&5
6591 cat conftest.$ac_ext >&5
6594 rm -f conftest.$ac_objext conftest.$ac_ext
6595 CPPFLAGS=$cf_save_CPPFLAGS
6600 if test "$cf_have_incdir" = no ; then
6601 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6603 echo "${as_me:-configure}:6603: testing adding $cf_add_incdir to include-path ..." 1>&5
6605 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6607 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6608 test "$cf_top_incdir" = "$cf_add_incdir" && break
6609 cf_add_incdir="$cf_top_incdir"
6622 # Set definitions to allow ifdef'ing for ncurses.h
6624 case $cf_cv_ncurses_header in
6627 cat >>confdefs.h <<\EOF
6628 #define HAVE_NCURSES_H 1
6634 case $cf_cv_ncurses_header in
6635 (ncurses/curses.h|ncurses/ncurses.h)
6637 cat >>confdefs.h <<\EOF
6638 #define HAVE_NCURSES_NCURSES_H 1
6642 (ncursesw/curses.h|ncursesw/ncurses.h)
6644 cat >>confdefs.h <<\EOF
6645 #define HAVE_NCURSESW_NCURSES_H 1
6651 echo "$as_me:6651: checking for terminfo header" >&5
6652 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
6653 if test "${cf_cv_term_header+set}" = set; then
6654 echo $ECHO_N "(cached) $ECHO_C" >&6
6657 case ${cf_cv_ncurses_header} in
6658 (*/ncurses.h|*/ncursesw.h)
6659 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
6662 cf_term_header=term.h
6666 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
6668 cat >conftest.$ac_ext <<_ACEOF
6669 #line 6669 "configure"
6670 #include "confdefs.h"
6672 #include <${cf_cv_ncurses_header:-curses.h}>
6678 int x = auto_left_margin
6683 rm -f conftest.$ac_objext
6684 if { (eval echo "$as_me:6684: \"$ac_compile\"") >&5
6685 (eval $ac_compile) 2>&5
6687 echo "$as_me:6687: \$? = $ac_status" >&5
6688 (exit $ac_status); } &&
6689 { ac_try='test -s conftest.$ac_objext'
6690 { (eval echo "$as_me:6690: \"$ac_try\"") >&5
6693 echo "$as_me:6693: \$? = $ac_status" >&5
6694 (exit $ac_status); }; }; then
6696 cf_cv_term_header="$cf_test"
6698 echo "$as_me: failed program was:" >&5
6699 cat conftest.$ac_ext >&5
6701 cf_cv_term_header=unknown
6704 rm -f conftest.$ac_objext conftest.$ac_ext
6705 test "$cf_cv_term_header" != unknown && break
6709 echo "$as_me:6709: result: $cf_cv_term_header" >&5
6710 echo "${ECHO_T}$cf_cv_term_header" >&6
6712 # Set definitions to allow ifdef'ing to accommodate subdirectories
6714 case $cf_cv_term_header in
6717 cat >>confdefs.h <<\EOF
6718 #define HAVE_TERM_H 1
6724 case $cf_cv_term_header in
6727 cat >>confdefs.h <<\EOF
6728 #define HAVE_NCURSES_TERM_H 1
6734 cat >>confdefs.h <<\EOF
6735 #define HAVE_NCURSESW_TERM_H 1
6741 # some applications need this, but should check for NCURSES_VERSION
6743 cat >>confdefs.h <<\EOF
6747 echo "$as_me:6747: checking for ncurses version" >&5
6748 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
6749 if test "${cf_cv_ncurses_version+set}" = set; then
6750 echo $ECHO_N "(cached) $ECHO_C" >&6
6753 cf_cv_ncurses_version=no
6756 if test "$cross_compiling" = yes; then
6758 # This will not work if the preprocessor splits the line after the
6759 # Autoconf token. The 'unproto' program does that.
6760 cat > conftest.$ac_ext <<EOF
6761 #include <${cf_cv_ncurses_header:-curses.h}>
6763 #ifdef NCURSES_VERSION
6764 Autoconf NCURSES_VERSION
6772 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
6773 { (eval echo "$as_me:6773: \"$cf_try\"") >&5
6776 echo "$as_me:6776: \$? = $ac_status" >&5
6777 (exit $ac_status); }
6778 if test -f conftest.out ; then
6779 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
6780 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
6785 cat >conftest.$ac_ext <<_ACEOF
6786 #line 6786 "configure"
6787 #include "confdefs.h"
6789 #include <${cf_cv_ncurses_header:-curses.h}>
6793 FILE *fp = fopen("$cf_tempfile", "w");
6794 #ifdef NCURSES_VERSION
6795 # ifdef NCURSES_VERSION_PATCH
6796 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
6798 fprintf(fp, "%s\n", NCURSES_VERSION);
6802 fprintf(fp, "old\n");
6807 ${cf_cv_main_return:-return}(0);
6810 rm -f conftest$ac_exeext
6811 if { (eval echo "$as_me:6811: \"$ac_link\"") >&5
6812 (eval $ac_link) 2>&5
6814 echo "$as_me:6814: \$? = $ac_status" >&5
6815 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6816 { (eval echo "$as_me:6816: \"$ac_try\"") >&5
6819 echo "$as_me:6819: \$? = $ac_status" >&5
6820 (exit $ac_status); }; }; then
6822 cf_cv_ncurses_version=`cat $cf_tempfile`
6824 echo "$as_me: program exited with status $ac_status" >&5
6825 echo "$as_me: failed program was:" >&5
6826 cat conftest.$ac_ext >&5
6828 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6833 echo "$as_me:6833: result: $cf_cv_ncurses_version" >&5
6834 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
6835 test "$cf_cv_ncurses_version" = no ||
6836 cat >>confdefs.h <<\EOF
6840 cf_nculib_root=ncursesw
6841 # This works, except for the special case where we find gpm, but
6842 # ncurses is in a nonstandard location via $LIBS, and we really want
6845 cf_ncurses_SAVE="$LIBS"
6846 echo "$as_me:6846: checking for Gpm_Open in -lgpm" >&5
6847 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
6848 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
6849 echo $ECHO_N "(cached) $ECHO_C" >&6
6851 ac_check_lib_save_LIBS=$LIBS
6853 cat >conftest.$ac_ext <<_ACEOF
6854 #line 6854 "configure"
6855 #include "confdefs.h"
6857 /* Override any gcc2 internal prototype to avoid an error. */
6861 /* We use char because int might match the return type of a gcc2
6862 builtin and then its argument prototype would still apply. */
6872 rm -f conftest.$ac_objext conftest$ac_exeext
6873 if { (eval echo "$as_me:6873: \"$ac_link\"") >&5
6874 (eval $ac_link) 2>&5
6876 echo "$as_me:6876: \$? = $ac_status" >&5
6877 (exit $ac_status); } &&
6878 { ac_try='test -s conftest$ac_exeext'
6879 { (eval echo "$as_me:6879: \"$ac_try\"") >&5
6882 echo "$as_me:6882: \$? = $ac_status" >&5
6883 (exit $ac_status); }; }; then
6884 ac_cv_lib_gpm_Gpm_Open=yes
6886 echo "$as_me: failed program was:" >&5
6887 cat conftest.$ac_ext >&5
6888 ac_cv_lib_gpm_Gpm_Open=no
6890 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6891 LIBS=$ac_check_lib_save_LIBS
6893 echo "$as_me:6893: result: $ac_cv_lib_gpm_Gpm_Open" >&5
6894 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
6895 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
6896 echo "$as_me:6896: checking for initscr in -lgpm" >&5
6897 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
6898 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
6899 echo $ECHO_N "(cached) $ECHO_C" >&6
6901 ac_check_lib_save_LIBS=$LIBS
6903 cat >conftest.$ac_ext <<_ACEOF
6904 #line 6904 "configure"
6905 #include "confdefs.h"
6907 /* Override any gcc2 internal prototype to avoid an error. */
6911 /* We use char because int might match the return type of a gcc2
6912 builtin and then its argument prototype would still apply. */
6922 rm -f conftest.$ac_objext conftest$ac_exeext
6923 if { (eval echo "$as_me:6923: \"$ac_link\"") >&5
6924 (eval $ac_link) 2>&5
6926 echo "$as_me:6926: \$? = $ac_status" >&5
6927 (exit $ac_status); } &&
6928 { ac_try='test -s conftest$ac_exeext'
6929 { (eval echo "$as_me:6929: \"$ac_try\"") >&5
6932 echo "$as_me:6932: \$? = $ac_status" >&5
6933 (exit $ac_status); }; }; then
6934 ac_cv_lib_gpm_initscr=yes
6936 echo "$as_me: failed program was:" >&5
6937 cat conftest.$ac_ext >&5
6938 ac_cv_lib_gpm_initscr=no
6940 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6941 LIBS=$ac_check_lib_save_LIBS
6943 echo "$as_me:6943: result: $ac_cv_lib_gpm_initscr" >&5
6944 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
6945 if test $ac_cv_lib_gpm_initscr = yes; then
6946 LIBS="$cf_ncurses_SAVE"
6948 cf_ncurses_LIBS="-lgpm"
6955 # This is only necessary if you are linking against an obsolete
6956 # version of ncurses (but it should do no harm, since it's static).
6957 if test "$cf_nculib_root" = ncurses ; then
6958 echo "$as_me:6958: checking for tgoto in -lmytinfo" >&5
6959 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
6960 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
6961 echo $ECHO_N "(cached) $ECHO_C" >&6
6963 ac_check_lib_save_LIBS=$LIBS
6964 LIBS="-lmytinfo $LIBS"
6965 cat >conftest.$ac_ext <<_ACEOF
6966 #line 6966 "configure"
6967 #include "confdefs.h"
6969 /* Override any gcc2 internal prototype to avoid an error. */
6973 /* We use char because int might match the return type of a gcc2
6974 builtin and then its argument prototype would still apply. */
6984 rm -f conftest.$ac_objext conftest$ac_exeext
6985 if { (eval echo "$as_me:6985: \"$ac_link\"") >&5
6986 (eval $ac_link) 2>&5
6988 echo "$as_me:6988: \$? = $ac_status" >&5
6989 (exit $ac_status); } &&
6990 { ac_try='test -s conftest$ac_exeext'
6991 { (eval echo "$as_me:6991: \"$ac_try\"") >&5
6994 echo "$as_me:6994: \$? = $ac_status" >&5
6995 (exit $ac_status); }; }; then
6996 ac_cv_lib_mytinfo_tgoto=yes
6998 echo "$as_me: failed program was:" >&5
6999 cat conftest.$ac_ext >&5
7000 ac_cv_lib_mytinfo_tgoto=no
7002 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7003 LIBS=$ac_check_lib_save_LIBS
7005 echo "$as_me:7005: result: $ac_cv_lib_mytinfo_tgoto" >&5
7006 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
7007 if test $ac_cv_lib_mytinfo_tgoto = yes; then
7008 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
7015 cf_add_libs="$cf_ncurses_LIBS"
7016 # Filter out duplicates - this happens with badly-designed ".pc" files...
7017 for cf_add_1lib in $LIBS
7019 for cf_add_2lib in $cf_add_libs
7021 if test "x$cf_add_1lib" = "x$cf_add_2lib"
7027 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
7031 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
7034 cf_add_libs="-l$cf_nculib_root"
7035 # Filter out duplicates - this happens with badly-designed ".pc" files...
7036 for cf_add_1lib in $LIBS
7038 for cf_add_2lib in $cf_add_libs
7040 if test "x$cf_add_1lib" = "x$cf_add_2lib"
7046 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
7052 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
7054 echo "$as_me:7054: checking for initscr" >&5
7055 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
7056 if test "${ac_cv_func_initscr+set}" = set; then
7057 echo $ECHO_N "(cached) $ECHO_C" >&6
7059 cat >conftest.$ac_ext <<_ACEOF
7060 #line 7060 "configure"
7061 #include "confdefs.h"
7062 /* System header to define __stub macros and hopefully few prototypes,
7063 which can conflict with char initscr (); below. */
7065 /* Override any gcc2 internal prototype to avoid an error. */
7069 /* We use char because int might match the return type of a gcc2
7070 builtin and then its argument prototype would still apply. */
7077 /* The GNU C library defines this for functions which it implements
7078 to always fail with ENOSYS. Some functions are actually named
7079 something starting with __ and the normal name is an alias. */
7080 #if defined (__stub_initscr) || defined (__stub___initscr)
7083 f = initscr; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
7090 rm -f conftest.$ac_objext conftest$ac_exeext
7091 if { (eval echo "$as_me:7091: \"$ac_link\"") >&5
7092 (eval $ac_link) 2>&5
7094 echo "$as_me:7094: \$? = $ac_status" >&5
7095 (exit $ac_status); } &&
7096 { ac_try='test -s conftest$ac_exeext'
7097 { (eval echo "$as_me:7097: \"$ac_try\"") >&5
7100 echo "$as_me:7100: \$? = $ac_status" >&5
7101 (exit $ac_status); }; }; then
7102 ac_cv_func_initscr=yes
7104 echo "$as_me: failed program was:" >&5
7105 cat conftest.$ac_ext >&5
7106 ac_cv_func_initscr=no
7108 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7110 echo "$as_me:7110: result: $ac_cv_func_initscr" >&5
7111 echo "${ECHO_T}$ac_cv_func_initscr" >&6
7112 if test $ac_cv_func_initscr = yes; then
7113 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7116 cf_save_LIBS="$LIBS"
7117 echo "$as_me:7117: checking for initscr in -l$cf_nculib_root" >&5
7118 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
7119 LIBS="-l$cf_nculib_root $LIBS"
7120 cat >conftest.$ac_ext <<_ACEOF
7121 #line 7121 "configure"
7122 #include "confdefs.h"
7123 #include <${cf_cv_ncurses_header:-curses.h}>
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 echo "$as_me:7144: result: yes" >&5
7145 echo "${ECHO_T}yes" >&6
7146 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7149 echo "$as_me: failed program was:" >&5
7150 cat conftest.$ac_ext >&5
7151 echo "$as_me:7151: result: no" >&5
7152 echo "${ECHO_T}no" >&6
7155 cf_library_path_list=""
7156 if test -n "${LDFLAGS}${LIBS}" ; then
7157 for cf_library_path in $LDFLAGS $LIBS
7159 case $cf_library_path in
7161 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
7163 test "x$cf_library_path" != "xNONE" && \
7164 test -d "$cf_library_path" && \
7166 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
7167 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
7168 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
7169 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
7170 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
7171 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"
7174 cf_library_path_list="$cf_library_path_list $cf_search"
7182 test "x$prefix" != "xNONE" && \
7183 test -d "$prefix" && \
7185 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
7186 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
7187 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
7188 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
7189 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
7190 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
7193 for cf_subdir_prefix in \
7202 test "x$cf_subdir_prefix" != "x$prefix" && \
7203 test -d "$cf_subdir_prefix" && \
7204 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
7205 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
7206 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
7207 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
7208 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
7209 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
7210 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"
7215 cf_search="$cf_library_path_list $cf_search"
7217 for cf_libdir in $cf_search
7219 echo "$as_me:7219: checking for -l$cf_nculib_root in $cf_libdir" >&5
7220 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
7221 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
7222 cat >conftest.$ac_ext <<_ACEOF
7223 #line 7223 "configure"
7224 #include "confdefs.h"
7225 #include <${cf_cv_ncurses_header:-curses.h}>
7234 rm -f conftest.$ac_objext conftest$ac_exeext
7235 if { (eval echo "$as_me:7235: \"$ac_link\"") >&5
7236 (eval $ac_link) 2>&5
7238 echo "$as_me:7238: \$? = $ac_status" >&5
7239 (exit $ac_status); } &&
7240 { ac_try='test -s conftest$ac_exeext'
7241 { (eval echo "$as_me:7241: \"$ac_try\"") >&5
7244 echo "$as_me:7244: \$? = $ac_status" >&5
7245 (exit $ac_status); }; }; then
7246 echo "$as_me:7246: result: yes" >&5
7247 echo "${ECHO_T}yes" >&6
7248 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7251 echo "$as_me: failed program was:" >&5
7252 cat conftest.$ac_ext >&5
7253 echo "$as_me:7253: result: no" >&5
7254 echo "${ECHO_T}no" >&6
7255 LIBS="$cf_save_LIBS"
7257 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7261 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7265 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
7267 if test $cf_found_library = no ; then
7268 { { echo "$as_me:7268: error: Cannot link $cf_nculib_root library" >&5
7269 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
7270 { (exit 1); exit 1; }; }
7275 if test -n "$cf_ncurses_LIBS" ; then
7276 echo "$as_me:7276: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
7277 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
7278 cf_ncurses_SAVE="$LIBS"
7279 for p in $cf_ncurses_LIBS ; do
7280 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
7281 if test "$q" != "$LIBS" ; then
7285 cat >conftest.$ac_ext <<_ACEOF
7286 #line 7286 "configure"
7287 #include "confdefs.h"
7288 #include <${cf_cv_ncurses_header:-curses.h}>
7292 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
7297 rm -f conftest.$ac_objext conftest$ac_exeext
7298 if { (eval echo "$as_me:7298: \"$ac_link\"") >&5
7299 (eval $ac_link) 2>&5
7301 echo "$as_me:7301: \$? = $ac_status" >&5
7302 (exit $ac_status); } &&
7303 { ac_try='test -s conftest$ac_exeext'
7304 { (eval echo "$as_me:7304: \"$ac_try\"") >&5
7307 echo "$as_me:7307: \$? = $ac_status" >&5
7308 (exit $ac_status); }; }; then
7309 echo "$as_me:7309: result: yes" >&5
7310 echo "${ECHO_T}yes" >&6
7312 echo "$as_me: failed program was:" >&5
7313 cat conftest.$ac_ext >&5
7314 echo "$as_me:7314: result: no" >&5
7315 echo "${ECHO_T}no" >&6
7316 LIBS="$cf_ncurses_SAVE"
7318 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7321 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
7323 cat >>confdefs.h <<EOF
7324 #define $cf_nculib_ROOT 1
7334 cf_ncuconfig_root=ncurses
7335 cf_have_ncuconfig=no
7337 if test "x${PKG_CONFIG:=none}" != xnone; then
7338 echo "$as_me:7338: checking pkg-config for $cf_ncuconfig_root" >&5
7339 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
7340 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
7341 echo "$as_me:7341: result: yes" >&5
7342 echo "${ECHO_T}yes" >&6
7344 echo "$as_me:7344: checking if the $cf_ncuconfig_root package files work" >&5
7345 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
7346 cf_have_ncuconfig=unknown
7348 cf_save_CPPFLAGS="$CPPFLAGS"
7349 cf_save_LIBS="$LIBS"
7351 CPPFLAGS="$CPPFLAGS `$PKG_CONFIG --cflags $cf_ncuconfig_root`"
7353 cf_add_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
7354 # Filter out duplicates - this happens with badly-designed ".pc" files...
7355 for cf_add_1lib in $LIBS
7357 for cf_add_2lib in $cf_add_libs
7359 if test "x$cf_add_1lib" = "x$cf_add_2lib"
7365 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
7369 cat >conftest.$ac_ext <<_ACEOF
7370 #line 7370 "configure"
7371 #include "confdefs.h"
7372 #include <${cf_cv_ncurses_header:-curses.h}>
7376 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
7381 rm -f conftest.$ac_objext conftest$ac_exeext
7382 if { (eval echo "$as_me:7382: \"$ac_link\"") >&5
7383 (eval $ac_link) 2>&5
7385 echo "$as_me:7385: \$? = $ac_status" >&5
7386 (exit $ac_status); } &&
7387 { ac_try='test -s conftest$ac_exeext'
7388 { (eval echo "$as_me:7388: \"$ac_try\"") >&5
7391 echo "$as_me:7391: \$? = $ac_status" >&5
7392 (exit $ac_status); }; }; then
7393 if test "$cross_compiling" = yes; then
7394 cf_have_ncuconfig=maybe
7396 cat >conftest.$ac_ext <<_ACEOF
7397 #line 7397 "configure"
7398 #include "confdefs.h"
7399 #include <${cf_cv_ncurses_header:-curses.h}>
7401 { char *xx = curses_version(); return (xx == 0); }
7403 rm -f conftest$ac_exeext
7404 if { (eval echo "$as_me:7404: \"$ac_link\"") >&5
7405 (eval $ac_link) 2>&5
7407 echo "$as_me:7407: \$? = $ac_status" >&5
7408 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7409 { (eval echo "$as_me:7409: \"$ac_try\"") >&5
7412 echo "$as_me:7412: \$? = $ac_status" >&5
7413 (exit $ac_status); }; }; then
7414 cf_have_ncuconfig=yes
7416 echo "$as_me: program exited with status $ac_status" >&5
7417 echo "$as_me: failed program was:" >&5
7418 cat conftest.$ac_ext >&5
7419 cf_have_ncuconfig=no
7421 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7424 echo "$as_me: failed program was:" >&5
7425 cat conftest.$ac_ext >&5
7426 cf_have_ncuconfig=no
7428 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7429 echo "$as_me:7429: result: $cf_have_ncuconfig" >&5
7430 echo "${ECHO_T}$cf_have_ncuconfig" >&6
7431 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
7432 if test "$cf_have_ncuconfig" != "yes"
7434 CPPFLAGS="$cf_save_CPPFLAGS"
7435 LIBS="$cf_save_LIBS"
7436 NCURSES_CONFIG_PKG=none
7439 cat >>confdefs.h <<\EOF
7443 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
7447 echo "$as_me:7447: result: no" >&5
7448 echo "${ECHO_T}no" >&6
7449 NCURSES_CONFIG_PKG=none
7452 NCURSES_CONFIG_PKG=none
7455 if test "x$cf_have_ncuconfig" = "xno"; then
7456 echo "Looking for ${cf_ncuconfig_root}-config"
7458 if test -n "$ac_tool_prefix"; then
7459 for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
7461 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
7462 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
7463 echo "$as_me:7463: checking for $ac_word" >&5
7464 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7465 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
7466 echo $ECHO_N "(cached) $ECHO_C" >&6
7468 if test -n "$NCURSES_CONFIG"; then
7469 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
7471 ac_save_IFS=$IFS; IFS=$ac_path_separator
7473 for ac_dir in $ac_dummy; do
7475 test -z "$ac_dir" && ac_dir=.
7476 $as_executable_p "$ac_dir/$ac_word" || continue
7477 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
7478 echo "$as_me:7478: found $ac_dir/$ac_word" >&5
7484 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
7485 if test -n "$NCURSES_CONFIG"; then
7486 echo "$as_me:7486: result: $NCURSES_CONFIG" >&5
7487 echo "${ECHO_T}$NCURSES_CONFIG" >&6
7489 echo "$as_me:7489: result: no" >&5
7490 echo "${ECHO_T}no" >&6
7493 test -n "$NCURSES_CONFIG" && break
7496 if test -z "$NCURSES_CONFIG"; then
7497 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
7498 for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
7500 # Extract the first word of "$ac_prog", so it can be a program name with args.
7501 set dummy $ac_prog; ac_word=$2
7502 echo "$as_me:7502: checking for $ac_word" >&5
7503 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7504 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
7505 echo $ECHO_N "(cached) $ECHO_C" >&6
7507 if test -n "$ac_ct_NCURSES_CONFIG"; then
7508 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
7510 ac_save_IFS=$IFS; IFS=$ac_path_separator
7512 for ac_dir in $ac_dummy; do
7514 test -z "$ac_dir" && ac_dir=.
7515 $as_executable_p "$ac_dir/$ac_word" || continue
7516 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
7517 echo "$as_me:7517: found $ac_dir/$ac_word" >&5
7523 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
7524 if test -n "$ac_ct_NCURSES_CONFIG"; then
7525 echo "$as_me:7525: result: $ac_ct_NCURSES_CONFIG" >&5
7526 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
7528 echo "$as_me:7528: result: no" >&5
7529 echo "${ECHO_T}no" >&6
7532 test -n "$ac_ct_NCURSES_CONFIG" && break
7534 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
7536 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
7539 if test "$NCURSES_CONFIG" != none ; then
7541 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
7543 cf_add_libs="`$NCURSES_CONFIG --libs`"
7544 # Filter out duplicates - this happens with badly-designed ".pc" files...
7545 for cf_add_1lib in $LIBS
7547 for cf_add_2lib in $cf_add_libs
7549 if test "x$cf_add_1lib" = "x$cf_add_2lib"
7555 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
7559 # even with config script, some packages use no-override for curses.h
7561 echo "$as_me:7561: checking if we have identified curses headers" >&5
7562 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
7563 if test "${cf_cv_ncurses_header+set}" = set; then
7564 echo $ECHO_N "(cached) $ECHO_C" >&6
7567 cf_cv_ncurses_header=none
7569 ncurses.h ncurses/ncurses.h \
7570 curses.h ncurses/curses.h
7572 cat >conftest.$ac_ext <<_ACEOF
7573 #line 7573 "configure"
7574 #include "confdefs.h"
7575 #include <${cf_header}>
7579 initscr(); tgoto("?", 0,0)
7584 rm -f conftest.$ac_objext
7585 if { (eval echo "$as_me:7585: \"$ac_compile\"") >&5
7586 (eval $ac_compile) 2>&5
7588 echo "$as_me:7588: \$? = $ac_status" >&5
7589 (exit $ac_status); } &&
7590 { ac_try='test -s conftest.$ac_objext'
7591 { (eval echo "$as_me:7591: \"$ac_try\"") >&5
7594 echo "$as_me:7594: \$? = $ac_status" >&5
7595 (exit $ac_status); }; }; then
7596 cf_cv_ncurses_header=$cf_header; break
7598 echo "$as_me: failed program was:" >&5
7599 cat conftest.$ac_ext >&5
7601 rm -f conftest.$ac_objext conftest.$ac_ext
7605 echo "$as_me:7605: result: $cf_cv_ncurses_header" >&5
7606 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
7608 if test "$cf_cv_ncurses_header" = none ; then
7609 { { echo "$as_me:7609: error: No curses header-files found" >&5
7610 echo "$as_me: error: No curses header-files found" >&2;}
7611 { (exit 1); exit 1; }; }
7614 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
7616 for ac_header in $cf_cv_ncurses_header
7618 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7619 echo "$as_me:7619: checking for $ac_header" >&5
7620 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7621 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7622 echo $ECHO_N "(cached) $ECHO_C" >&6
7624 cat >conftest.$ac_ext <<_ACEOF
7625 #line 7625 "configure"
7626 #include "confdefs.h"
7627 #include <$ac_header>
7629 if { (eval echo "$as_me:7629: \"$ac_cpp conftest.$ac_ext\"") >&5
7630 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7632 egrep -v '^ *\+' conftest.er1 >conftest.err
7634 cat conftest.err >&5
7635 echo "$as_me:7635: \$? = $ac_status" >&5
7636 (exit $ac_status); } >/dev/null; then
7637 if test -s conftest.err; then
7638 ac_cpp_err=$ac_c_preproc_warn_flag
7645 if test -z "$ac_cpp_err"; then
7646 eval "$as_ac_Header=yes"
7648 echo "$as_me: failed program was:" >&5
7649 cat conftest.$ac_ext >&5
7650 eval "$as_ac_Header=no"
7652 rm -f conftest.err conftest.$ac_ext
7654 echo "$as_me:7654: result: `eval echo '${'$as_ac_Header'}'`" >&5
7655 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7656 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7657 cat >>confdefs.h <<EOF
7658 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7664 cat >>confdefs.h <<\EOF
7668 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
7670 cat >>confdefs.h <<EOF
7671 #define $cf_nculib_ROOT 1
7674 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
7678 cf_ncuhdr_root=ncurses
7680 test -n "$cf_cv_curses_dir" && \
7681 test "$cf_cv_curses_dir" != "no" && { \
7683 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
7684 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
7686 while test $cf_add_incdir != /usr/include
7688 if test -d $cf_add_incdir
7691 if test -n "$CFLAGS$CPPFLAGS" ; then
7692 # a loop is needed to ensure we can add subdirs of existing dirs
7693 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7694 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7695 cf_have_incdir=yes; break
7700 if test "$cf_have_incdir" = no ; then
7701 if test "$cf_add_incdir" = /usr/local/include ; then
7702 if test "$GCC" = yes
7704 cf_save_CPPFLAGS=$CPPFLAGS
7705 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7706 cat >conftest.$ac_ext <<_ACEOF
7707 #line 7707 "configure"
7708 #include "confdefs.h"
7718 rm -f conftest.$ac_objext
7719 if { (eval echo "$as_me:7719: \"$ac_compile\"") >&5
7720 (eval $ac_compile) 2>&5
7722 echo "$as_me:7722: \$? = $ac_status" >&5
7723 (exit $ac_status); } &&
7724 { ac_try='test -s conftest.$ac_objext'
7725 { (eval echo "$as_me:7725: \"$ac_try\"") >&5
7728 echo "$as_me:7728: \$? = $ac_status" >&5
7729 (exit $ac_status); }; }; then
7732 echo "$as_me: failed program was:" >&5
7733 cat conftest.$ac_ext >&5
7736 rm -f conftest.$ac_objext conftest.$ac_ext
7737 CPPFLAGS=$cf_save_CPPFLAGS
7742 if test "$cf_have_incdir" = no ; then
7743 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7745 echo "${as_me:-configure}:7745: testing adding $cf_add_incdir to include-path ..." 1>&5
7747 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7749 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7750 test "$cf_top_incdir" = "$cf_add_incdir" && break
7751 cf_add_incdir="$cf_top_incdir"
7764 echo "$as_me:7764: checking for $cf_ncuhdr_root header in include-path" >&5
7765 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
7766 if test "${cf_cv_ncurses_h+set}" = set; then
7767 echo $ECHO_N "(cached) $ECHO_C" >&6
7770 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
7771 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
7772 for cf_header in $cf_header_list
7775 cat >conftest.$ac_ext <<_ACEOF
7776 #line 7776 "configure"
7777 #include "confdefs.h"
7779 #include <$cf_header>
7784 #ifdef NCURSES_VERSION
7786 printf("%s\n", NCURSES_VERSION);
7799 rm -f conftest.$ac_objext
7800 if { (eval echo "$as_me:7800: \"$ac_compile\"") >&5
7801 (eval $ac_compile) 2>&5
7803 echo "$as_me:7803: \$? = $ac_status" >&5
7804 (exit $ac_status); } &&
7805 { ac_try='test -s conftest.$ac_objext'
7806 { (eval echo "$as_me:7806: \"$ac_try\"") >&5
7809 echo "$as_me:7809: \$? = $ac_status" >&5
7810 (exit $ac_status); }; }; then
7811 cf_cv_ncurses_h=$cf_header
7814 echo "$as_me: failed program was:" >&5
7815 cat conftest.$ac_ext >&5
7818 rm -f conftest.$ac_objext conftest.$ac_ext
7820 test "$cf_cv_ncurses_h" != no && break
7824 echo "$as_me:7824: result: $cf_cv_ncurses_h" >&5
7825 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
7827 if test "$cf_cv_ncurses_h" != no ; then
7828 cf_cv_ncurses_header=$cf_cv_ncurses_h
7831 echo "$as_me:7831: checking for $cf_ncuhdr_root include-path" >&5
7832 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
7833 if test "${cf_cv_ncurses_h2+set}" = set; then
7834 echo $ECHO_N "(cached) $ECHO_C" >&6
7837 test -n "$verbose" && echo
7841 # collect the current set of include-directories from compiler flags
7842 cf_header_path_list=""
7843 if test -n "${CFLAGS}${CPPFLAGS}" ; then
7844 for cf_header_path in $CPPFLAGS $CFLAGS
7846 case $cf_header_path in
7848 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
7850 test "x$cf_header_path" != "xNONE" && \
7851 test -d "$cf_header_path" && \
7853 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
7854 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
7855 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
7856 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
7857 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
7858 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"
7861 cf_header_path_list="$cf_header_path_list $cf_search"
7867 # add the variations for the package we are looking for
7871 test "x$prefix" != "xNONE" && \
7872 test -d "$prefix" && \
7874 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
7875 test -d $prefix/include && cf_search="$cf_search $prefix/include"
7876 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
7877 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
7878 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
7879 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
7882 for cf_subdir_prefix in \
7891 test "x$cf_subdir_prefix" != "x$prefix" && \
7892 test -d "$cf_subdir_prefix" && \
7893 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
7894 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
7895 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
7896 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
7897 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
7898 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
7899 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"
7904 test "$includedir" != NONE && \
7905 test "$includedir" != "/usr/include" && \
7906 test -d "$includedir" && {
7907 test -d $includedir && cf_search="$cf_search $includedir"
7908 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
7911 test "$oldincludedir" != NONE && \
7912 test "$oldincludedir" != "/usr/include" && \
7913 test -d "$oldincludedir" && {
7914 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
7915 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
7918 cf_search="$cf_search $cf_header_path_list"
7920 test -n "$verbose" && echo search path $cf_search
7921 cf_save2_CPPFLAGS="$CPPFLAGS"
7922 for cf_incdir in $cf_search
7925 if test -n "$cf_incdir" ; then
7926 for cf_add_incdir in $cf_incdir
7928 while test $cf_add_incdir != /usr/include
7930 if test -d $cf_add_incdir
7933 if test -n "$CFLAGS$CPPFLAGS" ; then
7934 # a loop is needed to ensure we can add subdirs of existing dirs
7935 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7936 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7937 cf_have_incdir=yes; break
7942 if test "$cf_have_incdir" = no ; then
7943 if test "$cf_add_incdir" = /usr/local/include ; then
7944 if test "$GCC" = yes
7946 cf_save_CPPFLAGS=$CPPFLAGS
7947 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7948 cat >conftest.$ac_ext <<_ACEOF
7949 #line 7949 "configure"
7950 #include "confdefs.h"
7960 rm -f conftest.$ac_objext
7961 if { (eval echo "$as_me:7961: \"$ac_compile\"") >&5
7962 (eval $ac_compile) 2>&5
7964 echo "$as_me:7964: \$? = $ac_status" >&5
7965 (exit $ac_status); } &&
7966 { ac_try='test -s conftest.$ac_objext'
7967 { (eval echo "$as_me:7967: \"$ac_try\"") >&5
7970 echo "$as_me:7970: \$? = $ac_status" >&5
7971 (exit $ac_status); }; }; then
7974 echo "$as_me: failed program was:" >&5
7975 cat conftest.$ac_ext >&5
7978 rm -f conftest.$ac_objext conftest.$ac_ext
7979 CPPFLAGS=$cf_save_CPPFLAGS
7984 if test "$cf_have_incdir" = no ; then
7985 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7987 echo "${as_me:-configure}:7987: testing adding $cf_add_incdir to include-path ..." 1>&5
7989 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7991 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7992 test "$cf_top_incdir" = "$cf_add_incdir" && break
7993 cf_add_incdir="$cf_top_incdir"
8009 cat >conftest.$ac_ext <<_ACEOF
8010 #line 8010 "configure"
8011 #include "confdefs.h"
8013 #include <$cf_header>
8018 #ifdef NCURSES_VERSION
8020 printf("%s\n", NCURSES_VERSION);
8033 rm -f conftest.$ac_objext
8034 if { (eval echo "$as_me:8034: \"$ac_compile\"") >&5
8035 (eval $ac_compile) 2>&5
8037 echo "$as_me:8037: \$? = $ac_status" >&5
8038 (exit $ac_status); } &&
8039 { ac_try='test -s conftest.$ac_objext'
8040 { (eval echo "$as_me:8040: \"$ac_try\"") >&5
8043 echo "$as_me:8043: \$? = $ac_status" >&5
8044 (exit $ac_status); }; }; then
8045 cf_cv_ncurses_h2=$cf_header
8048 echo "$as_me: failed program was:" >&5
8049 cat conftest.$ac_ext >&5
8052 rm -f conftest.$ac_objext conftest.$ac_ext
8054 if test "$cf_cv_ncurses_h2" != no ; then
8055 cf_cv_ncurses_h2=$cf_incdir/$cf_header
8056 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
8059 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
8061 CPPFLAGS="$cf_save2_CPPFLAGS"
8062 test "$cf_cv_ncurses_h2" != no && break
8064 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:8064: error: not found" >&5
8065 echo "$as_me: error: not found" >&2;}
8066 { (exit 1); exit 1; }; }
8069 echo "$as_me:8069: result: $cf_cv_ncurses_h2" >&5
8070 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
8072 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
8073 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
8074 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
8075 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
8078 if test -n "$cf_1st_incdir" ; then
8079 for cf_add_incdir in $cf_1st_incdir
8081 while test $cf_add_incdir != /usr/include
8083 if test -d $cf_add_incdir
8086 if test -n "$CFLAGS$CPPFLAGS" ; then
8087 # a loop is needed to ensure we can add subdirs of existing dirs
8088 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8089 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8090 cf_have_incdir=yes; break
8095 if test "$cf_have_incdir" = no ; then
8096 if test "$cf_add_incdir" = /usr/local/include ; then
8097 if test "$GCC" = yes
8099 cf_save_CPPFLAGS=$CPPFLAGS
8100 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8101 cat >conftest.$ac_ext <<_ACEOF
8102 #line 8102 "configure"
8103 #include "confdefs.h"
8113 rm -f conftest.$ac_objext
8114 if { (eval echo "$as_me:8114: \"$ac_compile\"") >&5
8115 (eval $ac_compile) 2>&5
8117 echo "$as_me:8117: \$? = $ac_status" >&5
8118 (exit $ac_status); } &&
8119 { ac_try='test -s conftest.$ac_objext'
8120 { (eval echo "$as_me:8120: \"$ac_try\"") >&5
8123 echo "$as_me:8123: \$? = $ac_status" >&5
8124 (exit $ac_status); }; }; then
8127 echo "$as_me: failed program was:" >&5
8128 cat conftest.$ac_ext >&5
8131 rm -f conftest.$ac_objext conftest.$ac_ext
8132 CPPFLAGS=$cf_save_CPPFLAGS
8137 if test "$cf_have_incdir" = no ; then
8138 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8140 echo "${as_me:-configure}:8140: testing adding $cf_add_incdir to include-path ..." 1>&5
8142 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8144 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8145 test "$cf_top_incdir" = "$cf_add_incdir" && break
8146 cf_add_incdir="$cf_top_incdir"
8159 # Set definitions to allow ifdef'ing for ncurses.h
8161 case $cf_cv_ncurses_header in
8164 cat >>confdefs.h <<\EOF
8165 #define HAVE_NCURSES_H 1
8171 case $cf_cv_ncurses_header in
8172 (ncurses/curses.h|ncurses/ncurses.h)
8174 cat >>confdefs.h <<\EOF
8175 #define HAVE_NCURSES_NCURSES_H 1
8179 (ncursesw/curses.h|ncursesw/ncurses.h)
8181 cat >>confdefs.h <<\EOF
8182 #define HAVE_NCURSESW_NCURSES_H 1
8188 echo "$as_me:8188: checking for terminfo header" >&5
8189 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
8190 if test "${cf_cv_term_header+set}" = set; then
8191 echo $ECHO_N "(cached) $ECHO_C" >&6
8194 case ${cf_cv_ncurses_header} in
8195 (*/ncurses.h|*/ncursesw.h)
8196 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
8199 cf_term_header=term.h
8203 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
8205 cat >conftest.$ac_ext <<_ACEOF
8206 #line 8206 "configure"
8207 #include "confdefs.h"
8209 #include <${cf_cv_ncurses_header:-curses.h}>
8215 int x = auto_left_margin
8220 rm -f conftest.$ac_objext
8221 if { (eval echo "$as_me:8221: \"$ac_compile\"") >&5
8222 (eval $ac_compile) 2>&5
8224 echo "$as_me:8224: \$? = $ac_status" >&5
8225 (exit $ac_status); } &&
8226 { ac_try='test -s conftest.$ac_objext'
8227 { (eval echo "$as_me:8227: \"$ac_try\"") >&5
8230 echo "$as_me:8230: \$? = $ac_status" >&5
8231 (exit $ac_status); }; }; then
8233 cf_cv_term_header="$cf_test"
8235 echo "$as_me: failed program was:" >&5
8236 cat conftest.$ac_ext >&5
8238 cf_cv_term_header=unknown
8241 rm -f conftest.$ac_objext conftest.$ac_ext
8242 test "$cf_cv_term_header" != unknown && break
8246 echo "$as_me:8246: result: $cf_cv_term_header" >&5
8247 echo "${ECHO_T}$cf_cv_term_header" >&6
8249 # Set definitions to allow ifdef'ing to accommodate subdirectories
8251 case $cf_cv_term_header in
8254 cat >>confdefs.h <<\EOF
8255 #define HAVE_TERM_H 1
8261 case $cf_cv_term_header in
8264 cat >>confdefs.h <<\EOF
8265 #define HAVE_NCURSES_TERM_H 1
8271 cat >>confdefs.h <<\EOF
8272 #define HAVE_NCURSESW_TERM_H 1
8278 # some applications need this, but should check for NCURSES_VERSION
8280 cat >>confdefs.h <<\EOF
8284 echo "$as_me:8284: checking for ncurses version" >&5
8285 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
8286 if test "${cf_cv_ncurses_version+set}" = set; then
8287 echo $ECHO_N "(cached) $ECHO_C" >&6
8290 cf_cv_ncurses_version=no
8293 if test "$cross_compiling" = yes; then
8295 # This will not work if the preprocessor splits the line after the
8296 # Autoconf token. The 'unproto' program does that.
8297 cat > conftest.$ac_ext <<EOF
8298 #include <${cf_cv_ncurses_header:-curses.h}>
8300 #ifdef NCURSES_VERSION
8301 Autoconf NCURSES_VERSION
8309 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
8310 { (eval echo "$as_me:8310: \"$cf_try\"") >&5
8313 echo "$as_me:8313: \$? = $ac_status" >&5
8314 (exit $ac_status); }
8315 if test -f conftest.out ; then
8316 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
8317 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
8322 cat >conftest.$ac_ext <<_ACEOF
8323 #line 8323 "configure"
8324 #include "confdefs.h"
8326 #include <${cf_cv_ncurses_header:-curses.h}>
8330 FILE *fp = fopen("$cf_tempfile", "w");
8331 #ifdef NCURSES_VERSION
8332 # ifdef NCURSES_VERSION_PATCH
8333 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
8335 fprintf(fp, "%s\n", NCURSES_VERSION);
8339 fprintf(fp, "old\n");
8344 ${cf_cv_main_return:-return}(0);
8347 rm -f conftest$ac_exeext
8348 if { (eval echo "$as_me:8348: \"$ac_link\"") >&5
8349 (eval $ac_link) 2>&5
8351 echo "$as_me:8351: \$? = $ac_status" >&5
8352 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8353 { (eval echo "$as_me:8353: \"$ac_try\"") >&5
8356 echo "$as_me:8356: \$? = $ac_status" >&5
8357 (exit $ac_status); }; }; then
8359 cf_cv_ncurses_version=`cat $cf_tempfile`
8361 echo "$as_me: program exited with status $ac_status" >&5
8362 echo "$as_me: failed program was:" >&5
8363 cat conftest.$ac_ext >&5
8365 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8370 echo "$as_me:8370: result: $cf_cv_ncurses_version" >&5
8371 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
8372 test "$cf_cv_ncurses_version" = no ||
8373 cat >>confdefs.h <<\EOF
8377 cf_nculib_root=ncurses
8378 # This works, except for the special case where we find gpm, but
8379 # ncurses is in a nonstandard location via $LIBS, and we really want
8382 cf_ncurses_SAVE="$LIBS"
8383 echo "$as_me:8383: checking for Gpm_Open in -lgpm" >&5
8384 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
8385 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
8386 echo $ECHO_N "(cached) $ECHO_C" >&6
8388 ac_check_lib_save_LIBS=$LIBS
8390 cat >conftest.$ac_ext <<_ACEOF
8391 #line 8391 "configure"
8392 #include "confdefs.h"
8394 /* Override any gcc2 internal prototype to avoid an error. */
8398 /* We use char because int might match the return type of a gcc2
8399 builtin and then its argument prototype would still apply. */
8409 rm -f conftest.$ac_objext conftest$ac_exeext
8410 if { (eval echo "$as_me:8410: \"$ac_link\"") >&5
8411 (eval $ac_link) 2>&5
8413 echo "$as_me:8413: \$? = $ac_status" >&5
8414 (exit $ac_status); } &&
8415 { ac_try='test -s conftest$ac_exeext'
8416 { (eval echo "$as_me:8416: \"$ac_try\"") >&5
8419 echo "$as_me:8419: \$? = $ac_status" >&5
8420 (exit $ac_status); }; }; then
8421 ac_cv_lib_gpm_Gpm_Open=yes
8423 echo "$as_me: failed program was:" >&5
8424 cat conftest.$ac_ext >&5
8425 ac_cv_lib_gpm_Gpm_Open=no
8427 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8428 LIBS=$ac_check_lib_save_LIBS
8430 echo "$as_me:8430: result: $ac_cv_lib_gpm_Gpm_Open" >&5
8431 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
8432 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
8433 echo "$as_me:8433: checking for initscr in -lgpm" >&5
8434 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
8435 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
8436 echo $ECHO_N "(cached) $ECHO_C" >&6
8438 ac_check_lib_save_LIBS=$LIBS
8440 cat >conftest.$ac_ext <<_ACEOF
8441 #line 8441 "configure"
8442 #include "confdefs.h"
8444 /* Override any gcc2 internal prototype to avoid an error. */
8448 /* We use char because int might match the return type of a gcc2
8449 builtin and then its argument prototype would still apply. */
8459 rm -f conftest.$ac_objext conftest$ac_exeext
8460 if { (eval echo "$as_me:8460: \"$ac_link\"") >&5
8461 (eval $ac_link) 2>&5
8463 echo "$as_me:8463: \$? = $ac_status" >&5
8464 (exit $ac_status); } &&
8465 { ac_try='test -s conftest$ac_exeext'
8466 { (eval echo "$as_me:8466: \"$ac_try\"") >&5
8469 echo "$as_me:8469: \$? = $ac_status" >&5
8470 (exit $ac_status); }; }; then
8471 ac_cv_lib_gpm_initscr=yes
8473 echo "$as_me: failed program was:" >&5
8474 cat conftest.$ac_ext >&5
8475 ac_cv_lib_gpm_initscr=no
8477 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8478 LIBS=$ac_check_lib_save_LIBS
8480 echo "$as_me:8480: result: $ac_cv_lib_gpm_initscr" >&5
8481 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
8482 if test $ac_cv_lib_gpm_initscr = yes; then
8483 LIBS="$cf_ncurses_SAVE"
8485 cf_ncurses_LIBS="-lgpm"
8492 # This is only necessary if you are linking against an obsolete
8493 # version of ncurses (but it should do no harm, since it's static).
8494 if test "$cf_nculib_root" = ncurses ; then
8495 echo "$as_me:8495: checking for tgoto in -lmytinfo" >&5
8496 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
8497 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
8498 echo $ECHO_N "(cached) $ECHO_C" >&6
8500 ac_check_lib_save_LIBS=$LIBS
8501 LIBS="-lmytinfo $LIBS"
8502 cat >conftest.$ac_ext <<_ACEOF
8503 #line 8503 "configure"
8504 #include "confdefs.h"
8506 /* Override any gcc2 internal prototype to avoid an error. */
8510 /* We use char because int might match the return type of a gcc2
8511 builtin and then its argument prototype would still apply. */
8521 rm -f conftest.$ac_objext conftest$ac_exeext
8522 if { (eval echo "$as_me:8522: \"$ac_link\"") >&5
8523 (eval $ac_link) 2>&5
8525 echo "$as_me:8525: \$? = $ac_status" >&5
8526 (exit $ac_status); } &&
8527 { ac_try='test -s conftest$ac_exeext'
8528 { (eval echo "$as_me:8528: \"$ac_try\"") >&5
8531 echo "$as_me:8531: \$? = $ac_status" >&5
8532 (exit $ac_status); }; }; then
8533 ac_cv_lib_mytinfo_tgoto=yes
8535 echo "$as_me: failed program was:" >&5
8536 cat conftest.$ac_ext >&5
8537 ac_cv_lib_mytinfo_tgoto=no
8539 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8540 LIBS=$ac_check_lib_save_LIBS
8542 echo "$as_me:8542: result: $ac_cv_lib_mytinfo_tgoto" >&5
8543 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
8544 if test $ac_cv_lib_mytinfo_tgoto = yes; then
8545 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
8552 cf_add_libs="$cf_ncurses_LIBS"
8553 # Filter out duplicates - this happens with badly-designed ".pc" files...
8554 for cf_add_1lib in $LIBS
8556 for cf_add_2lib in $cf_add_libs
8558 if test "x$cf_add_1lib" = "x$cf_add_2lib"
8564 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
8568 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
8571 cf_add_libs="-l$cf_nculib_root"
8572 # Filter out duplicates - this happens with badly-designed ".pc" files...
8573 for cf_add_1lib in $LIBS
8575 for cf_add_2lib in $cf_add_libs
8577 if test "x$cf_add_1lib" = "x$cf_add_2lib"
8583 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
8589 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
8591 echo "$as_me:8591: checking for initscr" >&5
8592 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
8593 if test "${ac_cv_func_initscr+set}" = set; then
8594 echo $ECHO_N "(cached) $ECHO_C" >&6
8596 cat >conftest.$ac_ext <<_ACEOF
8597 #line 8597 "configure"
8598 #include "confdefs.h"
8599 /* System header to define __stub macros and hopefully few prototypes,
8600 which can conflict with char initscr (); below. */
8602 /* Override any gcc2 internal prototype to avoid an error. */
8606 /* We use char because int might match the return type of a gcc2
8607 builtin and then its argument prototype would still apply. */
8614 /* The GNU C library defines this for functions which it implements
8615 to always fail with ENOSYS. Some functions are actually named
8616 something starting with __ and the normal name is an alias. */
8617 #if defined (__stub_initscr) || defined (__stub___initscr)
8620 f = initscr; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
8627 rm -f conftest.$ac_objext conftest$ac_exeext
8628 if { (eval echo "$as_me:8628: \"$ac_link\"") >&5
8629 (eval $ac_link) 2>&5
8631 echo "$as_me:8631: \$? = $ac_status" >&5
8632 (exit $ac_status); } &&
8633 { ac_try='test -s conftest$ac_exeext'
8634 { (eval echo "$as_me:8634: \"$ac_try\"") >&5
8637 echo "$as_me:8637: \$? = $ac_status" >&5
8638 (exit $ac_status); }; }; then
8639 ac_cv_func_initscr=yes
8641 echo "$as_me: failed program was:" >&5
8642 cat conftest.$ac_ext >&5
8643 ac_cv_func_initscr=no
8645 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8647 echo "$as_me:8647: result: $ac_cv_func_initscr" >&5
8648 echo "${ECHO_T}$ac_cv_func_initscr" >&6
8649 if test $ac_cv_func_initscr = yes; then
8650 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8653 cf_save_LIBS="$LIBS"
8654 echo "$as_me:8654: checking for initscr in -l$cf_nculib_root" >&5
8655 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
8656 LIBS="-l$cf_nculib_root $LIBS"
8657 cat >conftest.$ac_ext <<_ACEOF
8658 #line 8658 "configure"
8659 #include "confdefs.h"
8660 #include <${cf_cv_ncurses_header:-curses.h}>
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 echo "$as_me:8681: result: yes" >&5
8682 echo "${ECHO_T}yes" >&6
8683 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8686 echo "$as_me: failed program was:" >&5
8687 cat conftest.$ac_ext >&5
8688 echo "$as_me:8688: result: no" >&5
8689 echo "${ECHO_T}no" >&6
8692 cf_library_path_list=""
8693 if test -n "${LDFLAGS}${LIBS}" ; then
8694 for cf_library_path in $LDFLAGS $LIBS
8696 case $cf_library_path in
8698 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
8700 test "x$cf_library_path" != "xNONE" && \
8701 test -d "$cf_library_path" && \
8703 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
8704 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
8705 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
8706 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
8707 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
8708 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"
8711 cf_library_path_list="$cf_library_path_list $cf_search"
8719 test "x$prefix" != "xNONE" && \
8720 test -d "$prefix" && \
8722 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
8723 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
8724 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
8725 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
8726 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
8727 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
8730 for cf_subdir_prefix in \
8739 test "x$cf_subdir_prefix" != "x$prefix" && \
8740 test -d "$cf_subdir_prefix" && \
8741 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
8742 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
8743 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
8744 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
8745 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
8746 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
8747 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"
8752 cf_search="$cf_library_path_list $cf_search"
8754 for cf_libdir in $cf_search
8756 echo "$as_me:8756: checking for -l$cf_nculib_root in $cf_libdir" >&5
8757 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
8758 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
8759 cat >conftest.$ac_ext <<_ACEOF
8760 #line 8760 "configure"
8761 #include "confdefs.h"
8762 #include <${cf_cv_ncurses_header:-curses.h}>
8771 rm -f conftest.$ac_objext conftest$ac_exeext
8772 if { (eval echo "$as_me:8772: \"$ac_link\"") >&5
8773 (eval $ac_link) 2>&5
8775 echo "$as_me:8775: \$? = $ac_status" >&5
8776 (exit $ac_status); } &&
8777 { ac_try='test -s conftest$ac_exeext'
8778 { (eval echo "$as_me:8778: \"$ac_try\"") >&5
8781 echo "$as_me:8781: \$? = $ac_status" >&5
8782 (exit $ac_status); }; }; then
8783 echo "$as_me:8783: result: yes" >&5
8784 echo "${ECHO_T}yes" >&6
8785 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8788 echo "$as_me: failed program was:" >&5
8789 cat conftest.$ac_ext >&5
8790 echo "$as_me:8790: result: no" >&5
8791 echo "${ECHO_T}no" >&6
8792 LIBS="$cf_save_LIBS"
8794 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8798 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8802 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
8804 if test $cf_found_library = no ; then
8805 { { echo "$as_me:8805: error: Cannot link $cf_nculib_root library" >&5
8806 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
8807 { (exit 1); exit 1; }; }
8812 if test -n "$cf_ncurses_LIBS" ; then
8813 echo "$as_me:8813: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
8814 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
8815 cf_ncurses_SAVE="$LIBS"
8816 for p in $cf_ncurses_LIBS ; do
8817 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
8818 if test "$q" != "$LIBS" ; then
8822 cat >conftest.$ac_ext <<_ACEOF
8823 #line 8823 "configure"
8824 #include "confdefs.h"
8825 #include <${cf_cv_ncurses_header:-curses.h}>
8829 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
8834 rm -f conftest.$ac_objext conftest$ac_exeext
8835 if { (eval echo "$as_me:8835: \"$ac_link\"") >&5
8836 (eval $ac_link) 2>&5
8838 echo "$as_me:8838: \$? = $ac_status" >&5
8839 (exit $ac_status); } &&
8840 { ac_try='test -s conftest$ac_exeext'
8841 { (eval echo "$as_me:8841: \"$ac_try\"") >&5
8844 echo "$as_me:8844: \$? = $ac_status" >&5
8845 (exit $ac_status); }; }; then
8846 echo "$as_me:8846: result: yes" >&5
8847 echo "${ECHO_T}yes" >&6
8849 echo "$as_me: failed program was:" >&5
8850 cat conftest.$ac_ext >&5
8851 echo "$as_me:8851: result: no" >&5
8852 echo "${ECHO_T}no" >&6
8853 LIBS="$cf_ncurses_SAVE"
8855 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8858 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
8860 cat >>confdefs.h <<EOF
8861 #define $cf_nculib_ROOT 1
8871 if test "$NCURSES_CONFIG_PKG" != none ; then
8872 cf_version=`$PKG_CONFIG --modversion $NCURSES_CONFIG_PKG 2>/dev/null`
8874 NCURSES_MAJOR=`echo "$cf_version" | sed -e 's/\..*//'`
8875 NCURSES_MINOR=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.//' -e 's/\..*//'`
8876 NCURSES_PATCH=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.[0-9][0-9]*\.//'`
8878 cf_cv_abi_version=`$PKG_CONFIG --variable=abi_version $NCURSES_CONFIG_PKG 2>/dev/null`
8879 if test -z "$cf_cv_abi_version"
8881 cf_cv_abi_version=`$PKG_CONFIG --variable=major_version $NCURSES_CONFIG_PKG 2>/dev/null`
8884 elif test "$NCURSES_CONFIG" != none ; then
8886 cf_version=`$NCURSES_CONFIG --version 2>/dev/null`
8888 NCURSES_MAJOR=`echo "$cf_version" | sed -e 's/\..*//'`
8889 NCURSES_MINOR=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.//' -e 's/\..*//'`
8890 NCURSES_PATCH=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.[0-9][0-9]*\.//'`
8892 # ABI version is not available from headers
8893 cf_cv_abi_version=`$NCURSES_CONFIG --abi-version 2>/dev/null`
8897 for cf_name in MAJOR MINOR PATCH
8899 cat >conftest.$ac_ext <<CF_EOF
8900 #include <${cf_cv_ncurses_header:-curses.h}>
8901 AUTOCONF_$cf_name NCURSES_VERSION_$cf_name
8903 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | fgrep AUTOCONF_$cf_name >conftest.out"
8904 { (eval echo "$as_me:8904: \"$cf_try\"") >&5
8907 echo "$as_me:8907: \$? = $ac_status" >&5
8908 (exit $ac_status); }
8909 if test -f conftest.out ; then
8910 cf_result=`cat conftest.out | sed -e "s/^.*AUTOCONF_$cf_name[ ][ ]*//"`
8911 eval NCURSES_$cf_name=\"$cf_result\"
8912 # cat conftest.$ac_ext
8917 cf_cv_abi_version=${NCURSES_MAJOR}
8921 cf_cv_rel_version=${NCURSES_MAJOR}.${NCURSES_MINOR}
8923 cf_cv_timestamp=`date`
8925 echo "$as_me:8925: result: Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&5
8926 echo "${ECHO_T}Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&6
8928 echo "$as_me:8928: checking if you want to have a library-prefix" >&5
8929 echo $ECHO_N "checking if you want to have a library-prefix... $ECHO_C" >&6
8931 # Check whether --with-lib-prefix or --without-lib-prefix was given.
8932 if test "${with_lib_prefix+set}" = set; then
8933 withval="$with_lib_prefix"
8934 with_lib_prefix=$withval
8936 with_lib_prefix=auto
8938 echo "$as_me:8938: result: $with_lib_prefix" >&5
8939 echo "${ECHO_T}$with_lib_prefix" >&6
8941 if test $with_lib_prefix = auto
8944 case $cf_cv_system_name in
8946 if test "$DFT_LWR_MODEL" = libtool; then
8952 (*) LIB_PREFIX='lib'
8955 cf_prefix=$LIB_PREFIX
8957 elif test $with_lib_prefix = no
8961 LIB_PREFIX=$with_lib_prefix
8966 ###############################################################################
8968 if test X"$CC_G_OPT" = X"" ; then
8970 test -n "$GCC" && test "${ac_cv_prog_cc_g}" != yes && CC_G_OPT=''
8973 echo "$as_me:8973: checking for default loader flags" >&5
8974 echo $ECHO_N "checking for default loader flags... $ECHO_C" >&6
8975 case $DFT_LWR_MODEL in
8976 (normal) LD_MODEL='' ;;
8977 (debug) LD_MODEL=$CC_G_OPT ;;
8978 (profile) LD_MODEL='-pg';;
8979 (shared) LD_MODEL='' ;;
8981 echo "$as_me:8981: result: $LD_MODEL" >&5
8982 echo "${ECHO_T}$LD_MODEL" >&6
8985 echo "$as_me:8985: checking for an rpath option" >&5
8986 echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6
8987 case $cf_cv_system_name in
8989 if test "$GCC" = yes; then
8990 LD_RPATH_OPT="-Wl,-rpath,"
8992 LD_RPATH_OPT="-rpath "
8995 (linux*|gnu*|k*bsd*-gnu)
8996 LD_RPATH_OPT="-Wl,-rpath,"
8998 (openbsd[2-9].*|mirbsd*)
8999 LD_RPATH_OPT="-Wl,-rpath,"
9001 (dragonfly*|freebsd*)
9002 LD_RPATH_OPT="-rpath "
9005 LD_RPATH_OPT="-Wl,-rpath,"
9008 LD_RPATH_OPT="-rpath "
9016 echo "$as_me:9016: result: $LD_RPATH_OPT" >&5
9017 echo "${ECHO_T}$LD_RPATH_OPT" >&6
9019 case "x$LD_RPATH_OPT" in
9021 echo "$as_me:9021: checking if we need a space after rpath option" >&5
9022 echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6
9023 cf_save_LIBS="$LIBS"
9025 cf_add_libs="${LD_RPATH_OPT}$libdir"
9026 # Filter out duplicates - this happens with badly-designed ".pc" files...
9027 for cf_add_1lib in $LIBS
9029 for cf_add_2lib in $cf_add_libs
9031 if test "x$cf_add_1lib" = "x$cf_add_2lib"
9037 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
9041 cat >conftest.$ac_ext <<_ACEOF
9042 #line 9042 "configure"
9043 #include "confdefs.h"
9053 rm -f conftest.$ac_objext conftest$ac_exeext
9054 if { (eval echo "$as_me:9054: \"$ac_link\"") >&5
9055 (eval $ac_link) 2>&5
9057 echo "$as_me:9057: \$? = $ac_status" >&5
9058 (exit $ac_status); } &&
9059 { ac_try='test -s conftest$ac_exeext'
9060 { (eval echo "$as_me:9060: \"$ac_try\"") >&5
9063 echo "$as_me:9063: \$? = $ac_status" >&5
9064 (exit $ac_status); }; }; then
9067 echo "$as_me: failed program was:" >&5
9068 cat conftest.$ac_ext >&5
9071 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9072 LIBS="$cf_save_LIBS"
9073 echo "$as_me:9073: result: $cf_rpath_space" >&5
9074 echo "${ECHO_T}$cf_rpath_space" >&6
9075 test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
9083 INSTALL_LIB="-m 644"
9084 : ${rel_builddir:=.}
9090 cf_cv_do_symlinks=no
9092 test "$cf_cv_enable_rpath" = yes && cf_ld_rpath_opt="$LD_RPATH_OPT"
9094 echo "$as_me:9094: checking if release/abi version should be used for shared libs" >&5
9095 echo $ECHO_N "checking if release/abi version should be used for shared libs... $ECHO_C" >&6
9097 # Check whether --with-shlib-version or --without-shlib-version was given.
9098 if test "${with_shlib_version+set}" = set; then
9099 withval="$with_shlib_version"
9100 test -z "$withval" && withval=auto
9103 cf_cv_shlib_version=auto
9106 cf_cv_shlib_version=$withval
9109 echo "$as_me:9109: result: $withval" >&5
9110 echo "${ECHO_T}$withval" >&6
9111 { { echo "$as_me:9111: error: option value must be one of: rel, abi, or auto" >&5
9112 echo "$as_me: error: option value must be one of: rel, abi, or auto" >&2;}
9113 { (exit 1); exit 1; }; }
9118 cf_cv_shlib_version=auto
9120 echo "$as_me:9120: result: $cf_cv_shlib_version" >&5
9121 echo "${ECHO_T}$cf_cv_shlib_version" >&6
9126 # Some less-capable ports of gcc support only -fpic
9128 if test "$GCC" = yes
9130 echo "$as_me:9130: checking which $CC option to use" >&5
9131 echo $ECHO_N "checking which $CC option to use... $ECHO_C" >&6
9132 cf_save_CFLAGS="$CFLAGS"
9133 for CC_SHARED_OPTS in -fPIC -fpic ''
9135 CFLAGS="$cf_save_CFLAGS $CC_SHARED_OPTS"
9136 cat >conftest.$ac_ext <<_ACEOF
9137 #line 9137 "configure"
9138 #include "confdefs.h"
9148 rm -f conftest.$ac_objext
9149 if { (eval echo "$as_me:9149: \"$ac_compile\"") >&5
9150 (eval $ac_compile) 2>&5
9152 echo "$as_me:9152: \$? = $ac_status" >&5
9153 (exit $ac_status); } &&
9154 { ac_try='test -s conftest.$ac_objext'
9155 { (eval echo "$as_me:9155: \"$ac_try\"") >&5
9158 echo "$as_me:9158: \$? = $ac_status" >&5
9159 (exit $ac_status); }; }; then
9162 echo "$as_me: failed program was:" >&5
9163 cat conftest.$ac_ext >&5
9165 rm -f conftest.$ac_objext conftest.$ac_ext
9167 echo "$as_me:9167: result: $CC_SHARED_OPTS" >&5
9168 echo "${ECHO_T}$CC_SHARED_OPTS" >&6
9169 CFLAGS="$cf_save_CFLAGS"
9172 cf_cv_shlib_version_infix=no
9174 case $cf_cv_system_name in
9175 (aix4.3-9*|aix[5-7]*)
9176 if test "$GCC" = yes; then
9177 CC_SHARED_OPTS='-Wl,-brtl'
9178 MK_SHARED_LIB='${CC} -shared -Wl,-brtl -Wl,-blibpath:${RPATH_LIST}:/usr/lib -o $@'
9180 CC_SHARED_OPTS='-brtl'
9181 # as well as '-qpic=large -G' or perhaps "-bM:SRE -bnoentry -bexpall"
9182 MK_SHARED_LIB='${CC} -G -Wl,-brtl -Wl,-blibpath:${RPATH_LIST}:/usr/lib -o $@'
9186 MK_SHARED_LIB='${CC} ${CFLAGS} -o $@ -Xlinker -soname=`basename $@` -nostart -e 0'
9190 MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}'
9191 RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a"
9192 cf_cv_shlib_version=cygdll
9193 cf_cv_shlib_version_infix=cygdll
9196 cat >mk_shared_lib.sh <<-CF_EOF
9199 IMPORT_LIB=\`echo "\$1" | sed -e 's/cyg/lib/' -e 's/[0-9]*\.dll$/.dll.a/'\`
9202 Linking shared library
9203 ** SHARED_LIB \$SHARED_LIB
9204 ** IMPORT_LIB \$IMPORT_LIB
9206 exec \$* -shared -Wl,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB}
9208 chmod +x mk_shared_lib.sh
9212 MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}'
9213 RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a"
9214 cf_cv_shlib_version=msysdll
9215 cf_cv_shlib_version_infix=msysdll
9218 cat >mk_shared_lib.sh <<-CF_EOF
9221 IMPORT_LIB=\`echo "\$1" | sed -e 's/msys-/lib/' -e 's/[0-9]*\.dll$/.dll.a/'\`
9224 Linking shared library
9225 ** SHARED_LIB \$SHARED_LIB
9226 ** IMPORT_LIB \$IMPORT_LIB
9228 exec \$* -shared -Wl,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB}
9230 chmod +x mk_shared_lib.sh
9233 cf_try_cflags="no-cpp-precomp"
9234 CC_SHARED_OPTS="-dynamic"
9235 MK_SHARED_LIB='${CC} ${CFLAGS} -dynamiclib -install_name ${libdir}/`basename $@` -compatibility_version ${ABI_VERSION} -current_version ${ABI_VERSION} -o $@'
9236 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=abi
9237 cf_cv_shlib_version_infix=yes
9238 echo "$as_me:9238: checking if ld -search_paths_first works" >&5
9239 echo $ECHO_N "checking if ld -search_paths_first works... $ECHO_C" >&6
9240 if test "${cf_cv_ldflags_search_paths_first+set}" = set; then
9241 echo $ECHO_N "(cached) $ECHO_C" >&6
9244 cf_save_LDFLAGS=$LDFLAGS
9245 LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
9246 cat >conftest.$ac_ext <<_ACEOF
9247 #line 9247 "configure"
9248 #include "confdefs.h"
9258 rm -f conftest.$ac_objext conftest$ac_exeext
9259 if { (eval echo "$as_me:9259: \"$ac_link\"") >&5
9260 (eval $ac_link) 2>&5
9262 echo "$as_me:9262: \$? = $ac_status" >&5
9263 (exit $ac_status); } &&
9264 { ac_try='test -s conftest$ac_exeext'
9265 { (eval echo "$as_me:9265: \"$ac_try\"") >&5
9268 echo "$as_me:9268: \$? = $ac_status" >&5
9269 (exit $ac_status); }; }; then
9270 cf_cv_ldflags_search_paths_first=yes
9272 echo "$as_me: failed program was:" >&5
9273 cat conftest.$ac_ext >&5
9274 cf_cv_ldflags_search_paths_first=no
9276 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9277 LDFLAGS=$cf_save_LDFLAGS
9279 echo "$as_me:9279: result: $cf_cv_ldflags_search_paths_first" >&5
9280 echo "${ECHO_T}$cf_cv_ldflags_search_paths_first" >&6
9281 if test $cf_cv_ldflags_search_paths_first = yes; then
9282 LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
9286 # HP-UX 8.07 ld lacks "+b" option used for libdir search-list
9287 if test "$GCC" != yes; then
9290 MK_SHARED_LIB='${LD} -b -o $@'
9291 INSTALL_LIB="-m 555"
9294 # (tested with gcc 2.7.2 -- I don't have c89)
9295 if test "$GCC" = yes; then
9296 LD_SHARED_OPTS='-Xlinker +b -Xlinker ${libdir}'
9299 LD_SHARED_OPTS='-Wl,+b,${libdir}'
9301 MK_SHARED_LIB='${LD} +b ${libdir} -b -o $@'
9302 # HP-UX shared libraries must be executable, and should be
9303 # readonly to exploit a quirk in the memory manager.
9304 INSTALL_LIB="-m 555"
9307 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9308 if test "$cf_cv_shlib_version" = rel; then
9309 cf_shared_soname='`basename .${REL_VERSION}`.${ABI_VERSION}'
9311 cf_shared_soname='`basename `'
9314 MK_SHARED_LIB='${CC} -shared -Wl,-rpath,${RPATH_LIST} -Wl,-h,'$cf_shared_soname' -o '
9317 if test "$cf_cv_enable_rpath" = yes ; then
9318 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9320 # tested with IRIX 5.2 and 'cc'.
9321 if test "$GCC" != yes; then
9322 CC_SHARED_OPTS='-KPIC'
9323 MK_SHARED_LIB='${CC} -shared -rdata_shared -soname `basename $@` -o $@'
9325 MK_SHARED_LIB='${CC} -shared -Wl,-soname,`basename $@` -o $@'
9327 cf_cv_rm_so_locs=yes
9329 (linux*|gnu*|k*bsd*-gnu)
9330 if test "$DFT_LWR_MODEL" = "shared" ; then
9331 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
9332 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9334 if test "$cf_cv_enable_rpath" = yes ; then
9335 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9338 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9339 if test "$cf_cv_shlib_version" = rel; then
9340 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9342 cf_cv_shared_soname='`basename $@`'
9345 MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
9348 cf_cv_shlib_version=mingw
9349 cf_cv_shlib_version_infix=mingw
9352 if test "$DFT_LWR_MODEL" = "shared" ; then
9353 LOCAL_LDFLAGS="-Wl,--enable-auto-import"
9354 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9355 EXTRA_LDFLAGS="-Wl,--enable-auto-import $EXTRA_LDFLAGS"
9358 MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}'
9359 RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a"
9360 cat >mk_shared_lib.sh <<-CF_EOF
9363 IMPORT_LIB=\`echo "\$1" | sed -e 's/[0-9]*\.dll$/.dll.a/'\`
9366 Linking shared library
9367 ** SHARED_LIB \$SHARED_LIB
9368 ** IMPORT_LIB \$IMPORT_LIB
9370 exec \$* -shared -Wl,--enable-auto-import,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB}
9372 chmod +x mk_shared_lib.sh
9374 (openbsd[2-9].*|mirbsd*)
9375 if test "$DFT_LWR_MODEL" = "shared" ; then
9376 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
9377 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9379 if test "$cf_cv_enable_rpath" = yes ; then
9380 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9382 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
9384 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9385 if test "$cf_cv_shlib_version" = rel; then
9386 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9388 cf_cv_shared_soname='`basename $@`'
9391 MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-Bshareable,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
9393 (nto-qnx*|openbsd*|freebsd[12].*)
9394 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
9395 MK_SHARED_LIB='${LD} -Bshareable -o $@'
9396 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9398 (dragonfly*|freebsd*)
9399 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
9400 if test "$DFT_LWR_MODEL" = "shared" && test "$cf_cv_enable_rpath" = yes ; then
9401 LOCAL_LDFLAGS="${cf_ld_rpath_opt}\$(LOCAL_LIBDIR)"
9402 LOCAL_LDFLAGS2="${cf_ld_rpath_opt}\${RPATH_LIST} $LOCAL_LDFLAGS"
9403 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9406 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9407 if test "$cf_cv_shlib_version" = rel; then
9408 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9410 cf_cv_shared_soname='`basename $@`'
9413 MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
9416 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
9417 if test "$DFT_LWR_MODEL" = "shared" && test "$cf_cv_enable_rpath" = yes ; then
9418 LOCAL_LDFLAGS="${cf_ld_rpath_opt}\$(LOCAL_LIBDIR)"
9419 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9420 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9421 if test "$cf_cv_shlib_version" = auto; then
9422 if test -f /usr/libexec/ld.elf_so; then
9423 cf_cv_shlib_version=abi
9425 cf_cv_shlib_version=rel
9429 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9430 if test "$cf_cv_shlib_version" = rel; then
9431 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9433 cf_cv_shared_soname='`basename $@`'
9436 MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname' -o $@'
9438 MK_SHARED_LIB='${CC} -Wl,-shared -Wl,-Bshareable -o $@'
9442 # tested with OSF/1 V3.2 and 'cc'
9443 # tested with OSF/1 V3.2 and gcc 2.6.3 (but the c++ demo didn't
9444 # link with shared libs).
9445 MK_SHARED_LIB='${LD} -set_version ${REL_VERSION}:${ABI_VERSION} -expect_unresolved "*" -shared -soname `basename $@`'
9448 MK_SHARED_LIB="${MK_SHARED_LIB} -msym"
9451 MK_SHARED_LIB="${MK_SHARED_LIB}"' -o $@'
9452 if test "$DFT_LWR_MODEL" = "shared" ; then
9453 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
9454 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9456 cf_cv_rm_so_locs=yes
9458 (sco3.2v5*) # also uw2* and UW7: hops 13-Apr-98
9459 # tested with osr5.0.5
9460 if test "$GCC" != yes; then
9461 CC_SHARED_OPTS='-belf -KPIC'
9463 MK_SHARED_LIB='${LD} -dy -G -h `basename $@ .${REL_VERSION}`.${ABI_VERSION} -o $@'
9464 if test "$cf_cv_enable_rpath" = yes ; then
9465 # only way is to set LD_RUN_PATH but no switch for it
9468 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9469 LINK_PROGS='LD_RUN_PATH=${libdir}'
9470 LINK_TESTS='Pwd=`pwd`;LD_RUN_PATH=`dirname $${Pwd}`/lib'
9473 # tested with SunOS 4.1.1 and gcc 2.7.0
9474 if test "$GCC" != yes; then
9475 CC_SHARED_OPTS='-KPIC'
9477 MK_SHARED_LIB='${LD} -assert pure-text -o $@'
9478 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9481 # tested with SunOS 5.5.1 (solaris 2.5.1) and gcc 2.7.2
9482 # tested with SunOS 5.10 (solaris 10) and gcc 3.4.3
9483 if test "$DFT_LWR_MODEL" = "shared" ; then
9484 LOCAL_LDFLAGS="-R \$(LOCAL_LIBDIR):\${libdir}"
9485 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9487 if test "$cf_cv_enable_rpath" = yes ; then
9488 EXTRA_LDFLAGS="-R \${libdir} $EXTRA_LDFLAGS"
9491 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9492 if test "$cf_cv_shlib_version" = rel; then
9493 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9495 cf_cv_shared_soname='`basename $@`'
9498 if test "$GCC" != yes; then
9499 cf_save_CFLAGS="$CFLAGS"
9500 for cf_shared_opts in -xcode=pic32 -xcode=pic13 -KPIC -Kpic -O
9502 CFLAGS="$cf_shared_opts $cf_save_CFLAGS"
9503 cat >conftest.$ac_ext <<_ACEOF
9504 #line 9504 "configure"
9505 #include "confdefs.h"
9515 rm -f conftest.$ac_objext
9516 if { (eval echo "$as_me:9516: \"$ac_compile\"") >&5
9517 (eval $ac_compile) 2>&5
9519 echo "$as_me:9519: \$? = $ac_status" >&5
9520 (exit $ac_status); } &&
9521 { ac_try='test -s conftest.$ac_objext'
9522 { (eval echo "$as_me:9522: \"$ac_try\"") >&5
9525 echo "$as_me:9525: \$? = $ac_status" >&5
9526 (exit $ac_status); }; }; then
9529 echo "$as_me: failed program was:" >&5
9530 cat conftest.$ac_ext >&5
9532 rm -f conftest.$ac_objext conftest.$ac_ext
9534 CFLAGS="$cf_save_CFLAGS"
9535 CC_SHARED_OPTS=$cf_shared_opts
9536 MK_SHARED_LIB='${CC} -dy -G -h '$cf_cv_shared_soname' -o $@'
9538 MK_SHARED_LIB='${CC} -shared -dy -G -h '$cf_cv_shared_soname' -o $@'
9541 (sysv5uw7*|unix_sv*)
9542 # tested with UnixWare 7.1.0 (gcc 2.95.2 and cc)
9543 if test "$GCC" != yes; then
9544 CC_SHARED_OPTS='-KPIC'
9546 MK_SHARED_LIB='${LD} -d y -G -o $@'
9549 CC_SHARED_OPTS='unknown'
9550 MK_SHARED_LIB='echo unknown'
9554 # This works if the last tokens in $MK_SHARED_LIB are the -o target.
9555 case "$cf_cv_shlib_version" in
9557 case "$MK_SHARED_LIB" in
9559 test "$cf_cv_do_symlinks" = no && cf_cv_do_symlinks=yes
9562 { echo "$as_me:9562: WARNING: ignored --with-shlib-version" >&5
9563 echo "$as_me: WARNING: ignored --with-shlib-version" >&2;}
9569 if test -n "$cf_try_cflags"
9571 cat > conftest.$ac_ext <<EOF
9572 #line 9572 "${as_me:-configure}"
9574 int main(int argc, char *argv[])
9577 return (argv[argc-1] == 0) ;
9580 cf_save_CFLAGS="$CFLAGS"
9581 for cf_opt in $cf_try_cflags
9583 CFLAGS="$cf_save_CFLAGS -$cf_opt"
9584 echo "$as_me:9584: checking if CFLAGS option -$cf_opt works" >&5
9585 echo $ECHO_N "checking if CFLAGS option -$cf_opt works... $ECHO_C" >&6
9586 if { (eval echo "$as_me:9586: \"$ac_compile\"") >&5
9587 (eval $ac_compile) 2>&5
9589 echo "$as_me:9589: \$? = $ac_status" >&5
9590 (exit $ac_status); }; then
9591 echo "$as_me:9591: result: yes" >&5
9592 echo "${ECHO_T}yes" >&6
9593 cf_save_CFLAGS="$CFLAGS"
9595 echo "$as_me:9595: result: no" >&5
9596 echo "${ECHO_T}no" >&6
9599 CFLAGS="$cf_save_CFLAGS"
9602 # RPATH_LIST is a colon-separated list of directories
9603 test -n "$cf_ld_rpath_opt" && MK_SHARED_LIB="$MK_SHARED_LIB $cf_ld_rpath_opt\${RPATH_LIST}"
9604 test -z "$RPATH_LIST" && RPATH_LIST="\${libdir}"
9606 test $cf_cv_rm_so_locs = yes && RM_SHARED_OPTS="$RM_SHARED_OPTS so_locations"
9608 test -n "$verbose" && echo " CC_SHARED_OPTS: $CC_SHARED_OPTS" 1>&6
9610 echo "${as_me:-configure}:9610: testing CC_SHARED_OPTS: $CC_SHARED_OPTS ..." 1>&5
9612 test -n "$verbose" && echo " MK_SHARED_LIB: $MK_SHARED_LIB" 1>&6
9614 echo "${as_me:-configure}:9614: testing MK_SHARED_LIB: $MK_SHARED_LIB ..." 1>&5
9616 # The test/sample programs in the original tree link using rpath option.
9617 # Make it optional for packagers.
9618 if test -n "$LOCAL_LDFLAGS"
9620 echo "$as_me:9620: checking if you want to link sample programs with rpath option" >&5
9621 echo $ECHO_N "checking if you want to link sample programs with rpath option... $ECHO_C" >&6
9623 # Check whether --enable-rpath-link or --disable-rpath-link was given.
9624 if test "${enable_rpath_link+set}" = set; then
9625 enableval="$enable_rpath_link"
9626 with_rpath_link=$enableval
9630 echo "$as_me:9630: result: $with_rpath_link" >&5
9631 echo "${ECHO_T}$with_rpath_link" >&6
9632 if test "$with_rpath_link" = no
9639 ###############################################################################
9641 ### use option --enable-broken-linker to force on use of broken-linker support
9642 echo "$as_me:9642: checking if you want broken-linker support code" >&5
9643 echo $ECHO_N "checking if you want broken-linker support code... $ECHO_C" >&6
9645 # Check whether --enable-broken_linker or --disable-broken_linker was given.
9646 if test "${enable_broken_linker+set}" = set; then
9647 enableval="$enable_broken_linker"
9648 with_broken_linker=$enableval
9650 with_broken_linker=${BROKEN_LINKER:-no}
9652 echo "$as_me:9652: result: $with_broken_linker" >&5
9653 echo "${ECHO_T}$with_broken_linker" >&6
9656 if test "$with_broken_linker" = yes ; then
9657 cat >>confdefs.h <<\EOF
9658 #define BROKEN_LINKER 1
9662 elif test "$DFT_LWR_MODEL" = shared ; then
9663 case $cf_cv_system_name in
9665 cat >>confdefs.h <<\EOF
9666 #define BROKEN_LINKER 1
9670 test -n "$verbose" && echo " cygwin linker is broken anyway" 1>&6
9672 echo "${as_me:-configure}:9672: testing cygwin linker is broken anyway ..." 1>&5
9678 # Check to define _XOPEN_SOURCE "automatically"
9681 cf_POSIX_C_SOURCE=199506L
9686 cf_xopen_source="-D_ALL_SOURCE"
9692 cf_xopen_source="-D_APPLE_C_SOURCE"
9695 cf_xopen_source="-D_DARWIN_C_SOURCE"
9698 (freebsd*|dragonfly*)
9699 # 5.x headers associate
9700 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
9701 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
9702 cf_POSIX_C_SOURCE=200112L
9704 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
9707 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
9710 cf_xopen_source="-D_HPUX_SOURCE"
9713 cf_xopen_source="-D_SGI_SOURCE"
9716 (linux*|gnu*|mint*|k*bsd*-gnu)
9718 echo "$as_me:9718: checking if we must define _GNU_SOURCE" >&5
9719 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
9720 if test "${cf_cv_gnu_source+set}" = set; then
9721 echo $ECHO_N "(cached) $ECHO_C" >&6
9724 cat >conftest.$ac_ext <<_ACEOF
9725 #line 9725 "configure"
9726 #include "confdefs.h"
9727 #include <sys/types.h>
9732 #ifndef _XOPEN_SOURCE
9739 rm -f conftest.$ac_objext
9740 if { (eval echo "$as_me:9740: \"$ac_compile\"") >&5
9741 (eval $ac_compile) 2>&5
9743 echo "$as_me:9743: \$? = $ac_status" >&5
9744 (exit $ac_status); } &&
9745 { ac_try='test -s conftest.$ac_objext'
9746 { (eval echo "$as_me:9746: \"$ac_try\"") >&5
9749 echo "$as_me:9749: \$? = $ac_status" >&5
9750 (exit $ac_status); }; }; then
9753 echo "$as_me: failed program was:" >&5
9754 cat conftest.$ac_ext >&5
9756 CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
9757 cat >conftest.$ac_ext <<_ACEOF
9758 #line 9758 "configure"
9759 #include "confdefs.h"
9760 #include <sys/types.h>
9765 #ifdef _XOPEN_SOURCE
9772 rm -f conftest.$ac_objext
9773 if { (eval echo "$as_me:9773: \"$ac_compile\"") >&5
9774 (eval $ac_compile) 2>&5
9776 echo "$as_me:9776: \$? = $ac_status" >&5
9777 (exit $ac_status); } &&
9778 { ac_try='test -s conftest.$ac_objext'
9779 { (eval echo "$as_me:9779: \"$ac_try\"") >&5
9782 echo "$as_me:9782: \$? = $ac_status" >&5
9783 (exit $ac_status); }; }; then
9786 echo "$as_me: failed program was:" >&5
9787 cat conftest.$ac_ext >&5
9788 cf_cv_gnu_source=yes
9790 rm -f conftest.$ac_objext conftest.$ac_ext
9794 rm -f conftest.$ac_objext conftest.$ac_ext
9797 echo "$as_me:9797: result: $cf_cv_gnu_source" >&5
9798 echo "${ECHO_T}$cf_cv_gnu_source" >&6
9799 test "$cf_cv_gnu_source" = yes && CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
9803 cf_xopen_source="-D_NETBSD_SOURCE" # POSIX.1-2001 features are ifdef'd with this...
9806 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
9809 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
9811 cf_save_CFLAGS="$CFLAGS"
9812 cf_save_CPPFLAGS="$CPPFLAGS"
9814 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
9815 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
9816 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
9818 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
9819 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
9820 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
9822 echo "$as_me:9822: checking if we should define _POSIX_C_SOURCE" >&5
9823 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
9824 if test "${cf_cv_posix_c_source+set}" = set; then
9825 echo $ECHO_N "(cached) $ECHO_C" >&6
9828 echo "${as_me:-configure}:9828: testing if the symbol is already defined go no further ..." 1>&5
9830 cat >conftest.$ac_ext <<_ACEOF
9831 #line 9831 "configure"
9832 #include "confdefs.h"
9833 #include <sys/types.h>
9838 #ifndef _POSIX_C_SOURCE
9845 rm -f conftest.$ac_objext
9846 if { (eval echo "$as_me:9846: \"$ac_compile\"") >&5
9847 (eval $ac_compile) 2>&5
9849 echo "$as_me:9849: \$? = $ac_status" >&5
9850 (exit $ac_status); } &&
9851 { ac_try='test -s conftest.$ac_objext'
9852 { (eval echo "$as_me:9852: \"$ac_try\"") >&5
9855 echo "$as_me:9855: \$? = $ac_status" >&5
9856 (exit $ac_status); }; }; then
9857 cf_cv_posix_c_source=no
9859 echo "$as_me: failed program was:" >&5
9860 cat conftest.$ac_ext >&5
9861 cf_want_posix_source=no
9862 case .$cf_POSIX_C_SOURCE in
9864 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
9867 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
9868 cf_want_posix_source=yes
9871 cf_want_posix_source=yes
9874 if test "$cf_want_posix_source" = yes ; then
9875 cat >conftest.$ac_ext <<_ACEOF
9876 #line 9876 "configure"
9877 #include "confdefs.h"
9878 #include <sys/types.h>
9883 #ifdef _POSIX_SOURCE
9890 rm -f conftest.$ac_objext
9891 if { (eval echo "$as_me:9891: \"$ac_compile\"") >&5
9892 (eval $ac_compile) 2>&5
9894 echo "$as_me:9894: \$? = $ac_status" >&5
9895 (exit $ac_status); } &&
9896 { ac_try='test -s conftest.$ac_objext'
9897 { (eval echo "$as_me:9897: \"$ac_try\"") >&5
9900 echo "$as_me:9900: \$? = $ac_status" >&5
9901 (exit $ac_status); }; }; then
9904 echo "$as_me: failed program was:" >&5
9905 cat conftest.$ac_ext >&5
9906 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
9908 rm -f conftest.$ac_objext conftest.$ac_ext
9911 echo "${as_me:-configure}:9911: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
9913 CFLAGS="$cf_trim_CFLAGS"
9914 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
9916 echo "${as_me:-configure}:9916: testing if the second compile does not leave our definition intact error ..." 1>&5
9918 cat >conftest.$ac_ext <<_ACEOF
9919 #line 9919 "configure"
9920 #include "confdefs.h"
9921 #include <sys/types.h>
9926 #ifndef _POSIX_C_SOURCE
9933 rm -f conftest.$ac_objext
9934 if { (eval echo "$as_me:9934: \"$ac_compile\"") >&5
9935 (eval $ac_compile) 2>&5
9937 echo "$as_me:9937: \$? = $ac_status" >&5
9938 (exit $ac_status); } &&
9939 { ac_try='test -s conftest.$ac_objext'
9940 { (eval echo "$as_me:9940: \"$ac_try\"") >&5
9943 echo "$as_me:9943: \$? = $ac_status" >&5
9944 (exit $ac_status); }; }; then
9947 echo "$as_me: failed program was:" >&5
9948 cat conftest.$ac_ext >&5
9949 cf_cv_posix_c_source=no
9951 rm -f conftest.$ac_objext conftest.$ac_ext
9952 CFLAGS="$cf_save_CFLAGS"
9953 CPPFLAGS="$cf_save_CPPFLAGS"
9956 rm -f conftest.$ac_objext conftest.$ac_ext
9959 echo "$as_me:9959: result: $cf_cv_posix_c_source" >&5
9960 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
9962 if test "$cf_cv_posix_c_source" != no ; then
9963 CFLAGS="$cf_trim_CFLAGS"
9964 CPPFLAGS="$cf_trim_CPPFLAGS"
9969 cf_new_extra_cppflags=
9971 for cf_add_cflags in $cf_cv_posix_c_source
9973 case $cf_fix_cppflags in
9975 case $cf_add_cflags in
9976 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
9977 case $cf_add_cflags in
9979 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
9981 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9982 && test -z "${cf_tst_cflags}" \
9983 && cf_fix_cppflags=yes
9985 if test $cf_fix_cppflags = yes ; then
9986 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
9988 elif test "${cf_tst_cflags}" = "\"'" ; then
9989 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
9998 case $cf_add_cflags in
10000 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10002 CPPFLAGS=`echo "$CPPFLAGS" | \
10003 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10004 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10008 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10013 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10018 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10020 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10022 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10023 && test -z "${cf_tst_cflags}" \
10024 && cf_fix_cppflags=no
10029 if test -n "$cf_new_cflags" ; then
10031 CFLAGS="$CFLAGS $cf_new_cflags"
10034 if test -n "$cf_new_cppflags" ; then
10036 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10039 if test -n "$cf_new_extra_cppflags" ; then
10041 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10048 cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
10051 # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw
10052 cf_xopen_source="-D_BSD_SOURCE"
10053 cf_XOPEN_SOURCE=600
10056 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
10062 cf_xopen_source="-D_OSF_SOURCE"
10065 cf_xopen_source="-D_QNX_SOURCE"
10068 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
10071 cf_xopen_source="-D__EXTENSIONS__"
10072 cf_cv_xopen_source=broken
10074 (sysv4.2uw2.*) # Novell/SCO UnixWare 2.x (tested on 2.1.2)
10080 echo "$as_me:10080: checking if we should define _XOPEN_SOURCE" >&5
10081 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
10082 if test "${cf_cv_xopen_source+set}" = set; then
10083 echo $ECHO_N "(cached) $ECHO_C" >&6
10086 cat >conftest.$ac_ext <<_ACEOF
10087 #line 10087 "configure"
10088 #include "confdefs.h"
10090 #include <stdlib.h>
10091 #include <string.h>
10092 #include <sys/types.h>
10098 #ifndef _XOPEN_SOURCE
10105 rm -f conftest.$ac_objext
10106 if { (eval echo "$as_me:10106: \"$ac_compile\"") >&5
10107 (eval $ac_compile) 2>&5
10109 echo "$as_me:10109: \$? = $ac_status" >&5
10110 (exit $ac_status); } &&
10111 { ac_try='test -s conftest.$ac_objext'
10112 { (eval echo "$as_me:10112: \"$ac_try\"") >&5
10113 (eval $ac_try) 2>&5
10115 echo "$as_me:10115: \$? = $ac_status" >&5
10116 (exit $ac_status); }; }; then
10117 cf_cv_xopen_source=no
10119 echo "$as_me: failed program was:" >&5
10120 cat conftest.$ac_ext >&5
10121 cf_save="$CPPFLAGS"
10122 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
10123 cat >conftest.$ac_ext <<_ACEOF
10124 #line 10124 "configure"
10125 #include "confdefs.h"
10127 #include <stdlib.h>
10128 #include <string.h>
10129 #include <sys/types.h>
10135 #ifdef _XOPEN_SOURCE
10142 rm -f conftest.$ac_objext
10143 if { (eval echo "$as_me:10143: \"$ac_compile\"") >&5
10144 (eval $ac_compile) 2>&5
10146 echo "$as_me:10146: \$? = $ac_status" >&5
10147 (exit $ac_status); } &&
10148 { ac_try='test -s conftest.$ac_objext'
10149 { (eval echo "$as_me:10149: \"$ac_try\"") >&5
10150 (eval $ac_try) 2>&5
10152 echo "$as_me:10152: \$? = $ac_status" >&5
10153 (exit $ac_status); }; }; then
10154 cf_cv_xopen_source=no
10156 echo "$as_me: failed program was:" >&5
10157 cat conftest.$ac_ext >&5
10158 cf_cv_xopen_source=$cf_XOPEN_SOURCE
10160 rm -f conftest.$ac_objext conftest.$ac_ext
10161 CPPFLAGS="$cf_save"
10164 rm -f conftest.$ac_objext conftest.$ac_ext
10167 echo "$as_me:10167: result: $cf_cv_xopen_source" >&5
10168 echo "${ECHO_T}$cf_cv_xopen_source" >&6
10170 if test "$cf_cv_xopen_source" != no ; then
10172 CFLAGS=`echo "$CFLAGS" | \
10173 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10174 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
10176 CPPFLAGS=`echo "$CPPFLAGS" | \
10177 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10178 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
10180 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
10185 cf_new_extra_cppflags=
10187 for cf_add_cflags in $cf_temp_xopen_source
10189 case $cf_fix_cppflags in
10191 case $cf_add_cflags in
10192 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10193 case $cf_add_cflags in
10195 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10197 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10198 && test -z "${cf_tst_cflags}" \
10199 && cf_fix_cppflags=yes
10201 if test $cf_fix_cppflags = yes ; then
10202 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10204 elif test "${cf_tst_cflags}" = "\"'" ; then
10205 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10210 case "$CPPFLAGS" in
10214 case $cf_add_cflags in
10216 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10218 CPPFLAGS=`echo "$CPPFLAGS" | \
10219 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10220 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10224 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10229 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10234 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10236 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10238 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10239 && test -z "${cf_tst_cflags}" \
10240 && cf_fix_cppflags=no
10245 if test -n "$cf_new_cflags" ; then
10247 CFLAGS="$CFLAGS $cf_new_cflags"
10250 if test -n "$cf_new_cppflags" ; then
10252 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10255 if test -n "$cf_new_extra_cppflags" ; then
10257 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10262 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
10264 cf_save_CFLAGS="$CFLAGS"
10265 cf_save_CPPFLAGS="$CPPFLAGS"
10267 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
10268 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10269 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
10271 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
10272 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10273 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
10275 echo "$as_me:10275: checking if we should define _POSIX_C_SOURCE" >&5
10276 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
10277 if test "${cf_cv_posix_c_source+set}" = set; then
10278 echo $ECHO_N "(cached) $ECHO_C" >&6
10281 echo "${as_me:-configure}:10281: testing if the symbol is already defined go no further ..." 1>&5
10283 cat >conftest.$ac_ext <<_ACEOF
10284 #line 10284 "configure"
10285 #include "confdefs.h"
10286 #include <sys/types.h>
10291 #ifndef _POSIX_C_SOURCE
10298 rm -f conftest.$ac_objext
10299 if { (eval echo "$as_me:10299: \"$ac_compile\"") >&5
10300 (eval $ac_compile) 2>&5
10302 echo "$as_me:10302: \$? = $ac_status" >&5
10303 (exit $ac_status); } &&
10304 { ac_try='test -s conftest.$ac_objext'
10305 { (eval echo "$as_me:10305: \"$ac_try\"") >&5
10306 (eval $ac_try) 2>&5
10308 echo "$as_me:10308: \$? = $ac_status" >&5
10309 (exit $ac_status); }; }; then
10310 cf_cv_posix_c_source=no
10312 echo "$as_me: failed program was:" >&5
10313 cat conftest.$ac_ext >&5
10314 cf_want_posix_source=no
10315 case .$cf_POSIX_C_SOURCE in
10317 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
10320 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
10321 cf_want_posix_source=yes
10324 cf_want_posix_source=yes
10327 if test "$cf_want_posix_source" = yes ; then
10328 cat >conftest.$ac_ext <<_ACEOF
10329 #line 10329 "configure"
10330 #include "confdefs.h"
10331 #include <sys/types.h>
10336 #ifdef _POSIX_SOURCE
10343 rm -f conftest.$ac_objext
10344 if { (eval echo "$as_me:10344: \"$ac_compile\"") >&5
10345 (eval $ac_compile) 2>&5
10347 echo "$as_me:10347: \$? = $ac_status" >&5
10348 (exit $ac_status); } &&
10349 { ac_try='test -s conftest.$ac_objext'
10350 { (eval echo "$as_me:10350: \"$ac_try\"") >&5
10351 (eval $ac_try) 2>&5
10353 echo "$as_me:10353: \$? = $ac_status" >&5
10354 (exit $ac_status); }; }; then
10357 echo "$as_me: failed program was:" >&5
10358 cat conftest.$ac_ext >&5
10359 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
10361 rm -f conftest.$ac_objext conftest.$ac_ext
10364 echo "${as_me:-configure}:10364: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
10366 CFLAGS="$cf_trim_CFLAGS"
10367 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
10369 echo "${as_me:-configure}:10369: testing if the second compile does not leave our definition intact error ..." 1>&5
10371 cat >conftest.$ac_ext <<_ACEOF
10372 #line 10372 "configure"
10373 #include "confdefs.h"
10374 #include <sys/types.h>
10379 #ifndef _POSIX_C_SOURCE
10386 rm -f conftest.$ac_objext
10387 if { (eval echo "$as_me:10387: \"$ac_compile\"") >&5
10388 (eval $ac_compile) 2>&5
10390 echo "$as_me:10390: \$? = $ac_status" >&5
10391 (exit $ac_status); } &&
10392 { ac_try='test -s conftest.$ac_objext'
10393 { (eval echo "$as_me:10393: \"$ac_try\"") >&5
10394 (eval $ac_try) 2>&5
10396 echo "$as_me:10396: \$? = $ac_status" >&5
10397 (exit $ac_status); }; }; then
10400 echo "$as_me: failed program was:" >&5
10401 cat conftest.$ac_ext >&5
10402 cf_cv_posix_c_source=no
10404 rm -f conftest.$ac_objext conftest.$ac_ext
10405 CFLAGS="$cf_save_CFLAGS"
10406 CPPFLAGS="$cf_save_CPPFLAGS"
10409 rm -f conftest.$ac_objext conftest.$ac_ext
10412 echo "$as_me:10412: result: $cf_cv_posix_c_source" >&5
10413 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
10415 if test "$cf_cv_posix_c_source" != no ; then
10416 CFLAGS="$cf_trim_CFLAGS"
10417 CPPFLAGS="$cf_trim_CPPFLAGS"
10422 cf_new_extra_cppflags=
10424 for cf_add_cflags in $cf_cv_posix_c_source
10426 case $cf_fix_cppflags in
10428 case $cf_add_cflags in
10429 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10430 case $cf_add_cflags in
10432 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10434 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10435 && test -z "${cf_tst_cflags}" \
10436 && cf_fix_cppflags=yes
10438 if test $cf_fix_cppflags = yes ; then
10439 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10441 elif test "${cf_tst_cflags}" = "\"'" ; then
10442 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10447 case "$CPPFLAGS" in
10451 case $cf_add_cflags in
10453 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10455 CPPFLAGS=`echo "$CPPFLAGS" | \
10456 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10457 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10461 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10466 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10471 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10473 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10475 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10476 && test -z "${cf_tst_cflags}" \
10477 && cf_fix_cppflags=no
10482 if test -n "$cf_new_cflags" ; then
10484 CFLAGS="$CFLAGS $cf_new_cflags"
10487 if test -n "$cf_new_cppflags" ; then
10489 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10492 if test -n "$cf_new_extra_cppflags" ; then
10494 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10502 if test -n "$cf_xopen_source" ; then
10507 cf_new_extra_cppflags=
10509 for cf_add_cflags in $cf_xopen_source
10511 case $cf_fix_cppflags in
10513 case $cf_add_cflags in
10514 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10515 case $cf_add_cflags in
10517 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10519 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10520 && test -z "${cf_tst_cflags}" \
10521 && cf_fix_cppflags=yes
10523 if test $cf_fix_cppflags = yes ; then
10524 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10526 elif test "${cf_tst_cflags}" = "\"'" ; then
10527 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10532 case "$CPPFLAGS" in
10536 case $cf_add_cflags in
10538 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10540 CPPFLAGS=`echo "$CPPFLAGS" | \
10541 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10542 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10546 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10551 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10556 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10558 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10560 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10561 && test -z "${cf_tst_cflags}" \
10562 && cf_fix_cppflags=no
10567 if test -n "$cf_new_cflags" ; then
10568 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
10570 echo "${as_me:-configure}:10570: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
10572 CFLAGS="$CFLAGS $cf_new_cflags"
10575 if test -n "$cf_new_cppflags" ; then
10576 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
10578 echo "${as_me:-configure}:10578: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
10580 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10583 if test -n "$cf_new_extra_cppflags" ; then
10584 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
10586 echo "${as_me:-configure}:10586: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
10588 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10593 if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
10594 echo "$as_me:10594: checking if _XOPEN_SOURCE really is set" >&5
10595 echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
10596 cat >conftest.$ac_ext <<_ACEOF
10597 #line 10597 "configure"
10598 #include "confdefs.h"
10599 #include <stdlib.h>
10604 #ifndef _XOPEN_SOURCE
10611 rm -f conftest.$ac_objext
10612 if { (eval echo "$as_me:10612: \"$ac_compile\"") >&5
10613 (eval $ac_compile) 2>&5
10615 echo "$as_me:10615: \$? = $ac_status" >&5
10616 (exit $ac_status); } &&
10617 { ac_try='test -s conftest.$ac_objext'
10618 { (eval echo "$as_me:10618: \"$ac_try\"") >&5
10619 (eval $ac_try) 2>&5
10621 echo "$as_me:10621: \$? = $ac_status" >&5
10622 (exit $ac_status); }; }; then
10623 cf_XOPEN_SOURCE_set=yes
10625 echo "$as_me: failed program was:" >&5
10626 cat conftest.$ac_ext >&5
10627 cf_XOPEN_SOURCE_set=no
10629 rm -f conftest.$ac_objext conftest.$ac_ext
10630 echo "$as_me:10630: result: $cf_XOPEN_SOURCE_set" >&5
10631 echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
10632 if test $cf_XOPEN_SOURCE_set = yes
10634 cat >conftest.$ac_ext <<_ACEOF
10635 #line 10635 "configure"
10636 #include "confdefs.h"
10637 #include <stdlib.h>
10642 #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
10649 rm -f conftest.$ac_objext
10650 if { (eval echo "$as_me:10650: \"$ac_compile\"") >&5
10651 (eval $ac_compile) 2>&5
10653 echo "$as_me:10653: \$? = $ac_status" >&5
10654 (exit $ac_status); } &&
10655 { ac_try='test -s conftest.$ac_objext'
10656 { (eval echo "$as_me:10656: \"$ac_try\"") >&5
10657 (eval $ac_try) 2>&5
10659 echo "$as_me:10659: \$? = $ac_status" >&5
10660 (exit $ac_status); }; }; then
10661 cf_XOPEN_SOURCE_set_ok=yes
10663 echo "$as_me: failed program was:" >&5
10664 cat conftest.$ac_ext >&5
10665 cf_XOPEN_SOURCE_set_ok=no
10667 rm -f conftest.$ac_objext conftest.$ac_ext
10668 if test $cf_XOPEN_SOURCE_set_ok = no
10670 { echo "$as_me:10670: WARNING: _XOPEN_SOURCE is lower than requested" >&5
10671 echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
10675 echo "$as_me:10675: checking if we should define _XOPEN_SOURCE" >&5
10676 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
10677 if test "${cf_cv_xopen_source+set}" = set; then
10678 echo $ECHO_N "(cached) $ECHO_C" >&6
10681 cat >conftest.$ac_ext <<_ACEOF
10682 #line 10682 "configure"
10683 #include "confdefs.h"
10685 #include <stdlib.h>
10686 #include <string.h>
10687 #include <sys/types.h>
10693 #ifndef _XOPEN_SOURCE
10700 rm -f conftest.$ac_objext
10701 if { (eval echo "$as_me:10701: \"$ac_compile\"") >&5
10702 (eval $ac_compile) 2>&5
10704 echo "$as_me:10704: \$? = $ac_status" >&5
10705 (exit $ac_status); } &&
10706 { ac_try='test -s conftest.$ac_objext'
10707 { (eval echo "$as_me:10707: \"$ac_try\"") >&5
10708 (eval $ac_try) 2>&5
10710 echo "$as_me:10710: \$? = $ac_status" >&5
10711 (exit $ac_status); }; }; then
10712 cf_cv_xopen_source=no
10714 echo "$as_me: failed program was:" >&5
10715 cat conftest.$ac_ext >&5
10716 cf_save="$CPPFLAGS"
10717 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
10718 cat >conftest.$ac_ext <<_ACEOF
10719 #line 10719 "configure"
10720 #include "confdefs.h"
10722 #include <stdlib.h>
10723 #include <string.h>
10724 #include <sys/types.h>
10730 #ifdef _XOPEN_SOURCE
10737 rm -f conftest.$ac_objext
10738 if { (eval echo "$as_me:10738: \"$ac_compile\"") >&5
10739 (eval $ac_compile) 2>&5
10741 echo "$as_me:10741: \$? = $ac_status" >&5
10742 (exit $ac_status); } &&
10743 { ac_try='test -s conftest.$ac_objext'
10744 { (eval echo "$as_me:10744: \"$ac_try\"") >&5
10745 (eval $ac_try) 2>&5
10747 echo "$as_me:10747: \$? = $ac_status" >&5
10748 (exit $ac_status); }; }; then
10749 cf_cv_xopen_source=no
10751 echo "$as_me: failed program was:" >&5
10752 cat conftest.$ac_ext >&5
10753 cf_cv_xopen_source=$cf_XOPEN_SOURCE
10755 rm -f conftest.$ac_objext conftest.$ac_ext
10756 CPPFLAGS="$cf_save"
10759 rm -f conftest.$ac_objext conftest.$ac_ext
10762 echo "$as_me:10762: result: $cf_cv_xopen_source" >&5
10763 echo "${ECHO_T}$cf_cv_xopen_source" >&6
10765 if test "$cf_cv_xopen_source" != no ; then
10767 CFLAGS=`echo "$CFLAGS" | \
10768 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10769 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
10771 CPPFLAGS=`echo "$CPPFLAGS" | \
10772 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10773 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
10775 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
10780 cf_new_extra_cppflags=
10782 for cf_add_cflags in $cf_temp_xopen_source
10784 case $cf_fix_cppflags in
10786 case $cf_add_cflags in
10787 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10788 case $cf_add_cflags in
10790 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10792 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10793 && test -z "${cf_tst_cflags}" \
10794 && cf_fix_cppflags=yes
10796 if test $cf_fix_cppflags = yes ; then
10797 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10799 elif test "${cf_tst_cflags}" = "\"'" ; then
10800 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10805 case "$CPPFLAGS" in
10809 case $cf_add_cflags in
10811 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10813 CPPFLAGS=`echo "$CPPFLAGS" | \
10814 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10815 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10819 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10824 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10829 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10831 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10833 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10834 && test -z "${cf_tst_cflags}" \
10835 && cf_fix_cppflags=no
10840 if test -n "$cf_new_cflags" ; then
10842 CFLAGS="$CFLAGS $cf_new_cflags"
10845 if test -n "$cf_new_cppflags" ; then
10847 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10850 if test -n "$cf_new_extra_cppflags" ; then
10852 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10860 # Check whether --enable-largefile or --disable-largefile was given.
10861 if test "${enable_largefile+set}" = set; then
10862 enableval="$enable_largefile"
10865 if test "$enable_largefile" != no; then
10867 echo "$as_me:10867: checking for special C compiler options needed for large files" >&5
10868 echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
10869 if test "${ac_cv_sys_largefile_CC+set}" = set; then
10870 echo $ECHO_N "(cached) $ECHO_C" >&6
10872 ac_cv_sys_largefile_CC=no
10873 if test "$GCC" != yes; then
10876 # IRIX 6.2 and later do not support large files by default,
10877 # so use the C compiler's -n32 option if that helps.
10878 cat >conftest.$ac_ext <<_ACEOF
10879 #line 10879 "configure"
10880 #include "confdefs.h"
10881 #include <sys/types.h>
10882 /* Check that off_t can represent 2**63 - 1 correctly.
10883 We can't simply define LARGE_OFF_T to be 9223372036854775807,
10884 since some C++ compilers masquerading as C compilers
10885 incorrectly reject 9223372036854775807. */
10886 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
10887 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
10888 && LARGE_OFF_T % 2147483647 == 1)
10898 rm -f conftest.$ac_objext
10899 if { (eval echo "$as_me:10899: \"$ac_compile\"") >&5
10900 (eval $ac_compile) 2>&5
10902 echo "$as_me:10902: \$? = $ac_status" >&5
10903 (exit $ac_status); } &&
10904 { ac_try='test -s conftest.$ac_objext'
10905 { (eval echo "$as_me:10905: \"$ac_try\"") >&5
10906 (eval $ac_try) 2>&5
10908 echo "$as_me:10908: \$? = $ac_status" >&5
10909 (exit $ac_status); }; }; then
10912 echo "$as_me: failed program was:" >&5
10913 cat conftest.$ac_ext >&5
10915 rm -f conftest.$ac_objext
10917 rm -f conftest.$ac_objext
10918 if { (eval echo "$as_me:10918: \"$ac_compile\"") >&5
10919 (eval $ac_compile) 2>&5
10921 echo "$as_me:10921: \$? = $ac_status" >&5
10922 (exit $ac_status); } &&
10923 { ac_try='test -s conftest.$ac_objext'
10924 { (eval echo "$as_me:10924: \"$ac_try\"") >&5
10925 (eval $ac_try) 2>&5
10927 echo "$as_me:10927: \$? = $ac_status" >&5
10928 (exit $ac_status); }; }; then
10929 ac_cv_sys_largefile_CC=' -n32'; break
10931 echo "$as_me: failed program was:" >&5
10932 cat conftest.$ac_ext >&5
10934 rm -f conftest.$ac_objext
10938 rm -f conftest.$ac_ext
10941 echo "$as_me:10941: result: $ac_cv_sys_largefile_CC" >&5
10942 echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
10943 if test "$ac_cv_sys_largefile_CC" != no; then
10944 CC=$CC$ac_cv_sys_largefile_CC
10947 echo "$as_me:10947: checking for _FILE_OFFSET_BITS value needed for large files" >&5
10948 echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
10949 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
10950 echo $ECHO_N "(cached) $ECHO_C" >&6
10953 ac_cv_sys_file_offset_bits=no
10954 cat >conftest.$ac_ext <<_ACEOF
10955 #line 10955 "configure"
10956 #include "confdefs.h"
10957 #include <sys/types.h>
10958 /* Check that off_t can represent 2**63 - 1 correctly.
10959 We can't simply define LARGE_OFF_T to be 9223372036854775807,
10960 since some C++ compilers masquerading as C compilers
10961 incorrectly reject 9223372036854775807. */
10962 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
10963 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
10964 && LARGE_OFF_T % 2147483647 == 1)
10974 rm -f conftest.$ac_objext
10975 if { (eval echo "$as_me:10975: \"$ac_compile\"") >&5
10976 (eval $ac_compile) 2>&5
10978 echo "$as_me:10978: \$? = $ac_status" >&5
10979 (exit $ac_status); } &&
10980 { ac_try='test -s conftest.$ac_objext'
10981 { (eval echo "$as_me:10981: \"$ac_try\"") >&5
10982 (eval $ac_try) 2>&5
10984 echo "$as_me:10984: \$? = $ac_status" >&5
10985 (exit $ac_status); }; }; then
10988 echo "$as_me: failed program was:" >&5
10989 cat conftest.$ac_ext >&5
10991 rm -f conftest.$ac_objext conftest.$ac_ext
10992 cat >conftest.$ac_ext <<_ACEOF
10993 #line 10993 "configure"
10994 #include "confdefs.h"
10995 #define _FILE_OFFSET_BITS 64
10996 #include <sys/types.h>
10997 /* Check that off_t can represent 2**63 - 1 correctly.
10998 We can't simply define LARGE_OFF_T to be 9223372036854775807,
10999 since some C++ compilers masquerading as C compilers
11000 incorrectly reject 9223372036854775807. */
11001 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
11002 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
11003 && LARGE_OFF_T % 2147483647 == 1)
11013 rm -f conftest.$ac_objext
11014 if { (eval echo "$as_me:11014: \"$ac_compile\"") >&5
11015 (eval $ac_compile) 2>&5
11017 echo "$as_me:11017: \$? = $ac_status" >&5
11018 (exit $ac_status); } &&
11019 { ac_try='test -s conftest.$ac_objext'
11020 { (eval echo "$as_me:11020: \"$ac_try\"") >&5
11021 (eval $ac_try) 2>&5
11023 echo "$as_me:11023: \$? = $ac_status" >&5
11024 (exit $ac_status); }; }; then
11025 ac_cv_sys_file_offset_bits=64; break
11027 echo "$as_me: failed program was:" >&5
11028 cat conftest.$ac_ext >&5
11030 rm -f conftest.$ac_objext conftest.$ac_ext
11034 echo "$as_me:11034: result: $ac_cv_sys_file_offset_bits" >&5
11035 echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
11036 if test "$ac_cv_sys_file_offset_bits" != no; then
11038 cat >>confdefs.h <<EOF
11039 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
11044 echo "$as_me:11044: checking for _LARGE_FILES value needed for large files" >&5
11045 echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
11046 if test "${ac_cv_sys_large_files+set}" = set; then
11047 echo $ECHO_N "(cached) $ECHO_C" >&6
11050 ac_cv_sys_large_files=no
11051 cat >conftest.$ac_ext <<_ACEOF
11052 #line 11052 "configure"
11053 #include "confdefs.h"
11054 #include <sys/types.h>
11055 /* Check that off_t can represent 2**63 - 1 correctly.
11056 We can't simply define LARGE_OFF_T to be 9223372036854775807,
11057 since some C++ compilers masquerading as C compilers
11058 incorrectly reject 9223372036854775807. */
11059 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
11060 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
11061 && LARGE_OFF_T % 2147483647 == 1)
11071 rm -f conftest.$ac_objext
11072 if { (eval echo "$as_me:11072: \"$ac_compile\"") >&5
11073 (eval $ac_compile) 2>&5
11075 echo "$as_me:11075: \$? = $ac_status" >&5
11076 (exit $ac_status); } &&
11077 { ac_try='test -s conftest.$ac_objext'
11078 { (eval echo "$as_me:11078: \"$ac_try\"") >&5
11079 (eval $ac_try) 2>&5
11081 echo "$as_me:11081: \$? = $ac_status" >&5
11082 (exit $ac_status); }; }; then
11085 echo "$as_me: failed program was:" >&5
11086 cat conftest.$ac_ext >&5
11088 rm -f conftest.$ac_objext conftest.$ac_ext
11089 cat >conftest.$ac_ext <<_ACEOF
11090 #line 11090 "configure"
11091 #include "confdefs.h"
11092 #define _LARGE_FILES 1
11093 #include <sys/types.h>
11094 /* Check that off_t can represent 2**63 - 1 correctly.
11095 We can't simply define LARGE_OFF_T to be 9223372036854775807,
11096 since some C++ compilers masquerading as C compilers
11097 incorrectly reject 9223372036854775807. */
11098 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
11099 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
11100 && LARGE_OFF_T % 2147483647 == 1)
11110 rm -f conftest.$ac_objext
11111 if { (eval echo "$as_me:11111: \"$ac_compile\"") >&5
11112 (eval $ac_compile) 2>&5
11114 echo "$as_me:11114: \$? = $ac_status" >&5
11115 (exit $ac_status); } &&
11116 { ac_try='test -s conftest.$ac_objext'
11117 { (eval echo "$as_me:11117: \"$ac_try\"") >&5
11118 (eval $ac_try) 2>&5
11120 echo "$as_me:11120: \$? = $ac_status" >&5
11121 (exit $ac_status); }; }; then
11122 ac_cv_sys_large_files=1; break
11124 echo "$as_me: failed program was:" >&5
11125 cat conftest.$ac_ext >&5
11127 rm -f conftest.$ac_objext conftest.$ac_ext
11131 echo "$as_me:11131: result: $ac_cv_sys_large_files" >&5
11132 echo "${ECHO_T}$ac_cv_sys_large_files" >&6
11133 if test "$ac_cv_sys_large_files" != no; then
11135 cat >>confdefs.h <<EOF
11136 #define _LARGE_FILES $ac_cv_sys_large_files
11143 if test "$enable_largefile" != no ; then
11144 echo "$as_me:11144: checking for _LARGEFILE_SOURCE value needed for large files" >&5
11145 echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
11146 if test "${ac_cv_sys_largefile_source+set}" = set; then
11147 echo $ECHO_N "(cached) $ECHO_C" >&6
11150 ac_cv_sys_largefile_source=no
11151 cat >conftest.$ac_ext <<_ACEOF
11152 #line 11152 "configure"
11153 #include "confdefs.h"
11163 rm -f conftest.$ac_objext
11164 if { (eval echo "$as_me:11164: \"$ac_compile\"") >&5
11165 (eval $ac_compile) 2>&5
11167 echo "$as_me:11167: \$? = $ac_status" >&5
11168 (exit $ac_status); } &&
11169 { ac_try='test -s conftest.$ac_objext'
11170 { (eval echo "$as_me:11170: \"$ac_try\"") >&5
11171 (eval $ac_try) 2>&5
11173 echo "$as_me:11173: \$? = $ac_status" >&5
11174 (exit $ac_status); }; }; then
11177 echo "$as_me: failed program was:" >&5
11178 cat conftest.$ac_ext >&5
11180 rm -f conftest.$ac_objext conftest.$ac_ext
11181 cat >conftest.$ac_ext <<_ACEOF
11182 #line 11182 "configure"
11183 #include "confdefs.h"
11184 #define _LARGEFILE_SOURCE 1
11194 rm -f conftest.$ac_objext
11195 if { (eval echo "$as_me:11195: \"$ac_compile\"") >&5
11196 (eval $ac_compile) 2>&5
11198 echo "$as_me:11198: \$? = $ac_status" >&5
11199 (exit $ac_status); } &&
11200 { ac_try='test -s conftest.$ac_objext'
11201 { (eval echo "$as_me:11201: \"$ac_try\"") >&5
11202 (eval $ac_try) 2>&5
11204 echo "$as_me:11204: \$? = $ac_status" >&5
11205 (exit $ac_status); }; }; then
11206 ac_cv_sys_largefile_source=1; break
11208 echo "$as_me: failed program was:" >&5
11209 cat conftest.$ac_ext >&5
11211 rm -f conftest.$ac_objext conftest.$ac_ext
11215 echo "$as_me:11215: result: $ac_cv_sys_largefile_source" >&5
11216 echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
11217 if test "$ac_cv_sys_largefile_source" != no; then
11219 cat >>confdefs.h <<EOF
11220 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
11226 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
11227 # in glibc 2.1.3, but that breaks too many other things.
11228 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
11229 echo "$as_me:11229: checking for fseeko" >&5
11230 echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
11231 if test "${ac_cv_func_fseeko+set}" = set; then
11232 echo $ECHO_N "(cached) $ECHO_C" >&6
11234 cat >conftest.$ac_ext <<_ACEOF
11235 #line 11235 "configure"
11236 #include "confdefs.h"
11241 return fseeko && fseeko (stdin, 0, 0);
11246 rm -f conftest.$ac_objext conftest$ac_exeext
11247 if { (eval echo "$as_me:11247: \"$ac_link\"") >&5
11248 (eval $ac_link) 2>&5
11250 echo "$as_me:11250: \$? = $ac_status" >&5
11251 (exit $ac_status); } &&
11252 { ac_try='test -s conftest$ac_exeext'
11253 { (eval echo "$as_me:11253: \"$ac_try\"") >&5
11254 (eval $ac_try) 2>&5
11256 echo "$as_me:11256: \$? = $ac_status" >&5
11257 (exit $ac_status); }; }; then
11258 ac_cv_func_fseeko=yes
11260 echo "$as_me: failed program was:" >&5
11261 cat conftest.$ac_ext >&5
11262 ac_cv_func_fseeko=no
11264 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11266 echo "$as_me:11266: result: $ac_cv_func_fseeko" >&5
11267 echo "${ECHO_T}$ac_cv_func_fseeko" >&6
11268 if test $ac_cv_func_fseeko = yes; then
11270 cat >>confdefs.h <<\EOF
11271 #define HAVE_FSEEKO 1
11276 # Normally we would collect these definitions in the config.h,
11277 # but (like _XOPEN_SOURCE), some environments rely on having these
11278 # defined before any of the system headers are included. Another
11279 # case comes up with C++, e.g., on AIX the compiler compiles the
11280 # header files by themselves before looking at the body files it is
11281 # told to compile. For ncurses, those header files do not include
11283 test "$ac_cv_sys_large_files" != no && CPPFLAGS="$CPPFLAGS -D_LARGE_FILES "
11284 test "$ac_cv_sys_largefile_source" != no && CPPFLAGS="$CPPFLAGS -D_LARGEFILE_SOURCE "
11285 test "$ac_cv_sys_file_offset_bits" != no && CPPFLAGS="$CPPFLAGS -D_FILE_OFFSET_BITS=$ac_cv_sys_file_offset_bits "
11287 echo "$as_me:11287: checking whether to use struct dirent64" >&5
11288 echo $ECHO_N "checking whether to use struct dirent64... $ECHO_C" >&6
11289 if test "${cf_cv_struct_dirent64+set}" = set; then
11290 echo $ECHO_N "(cached) $ECHO_C" >&6
11293 cat >conftest.$ac_ext <<_ACEOF
11294 #line 11294 "configure"
11295 #include "confdefs.h"
11297 #include <sys/types.h>
11298 #include <dirent.h>
11304 /* if transitional largefile support is setup, this is true */
11305 extern struct dirent64 * readdir(DIR *);
11306 struct dirent64 *x = readdir((DIR *)0);
11307 struct dirent *y = readdir((DIR *)0);
11314 rm -f conftest.$ac_objext
11315 if { (eval echo "$as_me:11315: \"$ac_compile\"") >&5
11316 (eval $ac_compile) 2>&5
11318 echo "$as_me:11318: \$? = $ac_status" >&5
11319 (exit $ac_status); } &&
11320 { ac_try='test -s conftest.$ac_objext'
11321 { (eval echo "$as_me:11321: \"$ac_try\"") >&5
11322 (eval $ac_try) 2>&5
11324 echo "$as_me:11324: \$? = $ac_status" >&5
11325 (exit $ac_status); }; }; then
11326 cf_cv_struct_dirent64=yes
11328 echo "$as_me: failed program was:" >&5
11329 cat conftest.$ac_ext >&5
11330 cf_cv_struct_dirent64=no
11332 rm -f conftest.$ac_objext conftest.$ac_ext
11335 echo "$as_me:11335: result: $cf_cv_struct_dirent64" >&5
11336 echo "${ECHO_T}$cf_cv_struct_dirent64" >&6
11337 test "$cf_cv_struct_dirent64" = yes &&
11338 cat >>confdefs.h <<\EOF
11339 #define HAVE_STRUCT_DIRENT64 1
11344 ### Enable compiling-in rcs id's
11345 echo "$as_me:11345: checking if RCS identifiers should be compiled-in" >&5
11346 echo $ECHO_N "checking if RCS identifiers should be compiled-in... $ECHO_C" >&6
11348 # Check whether --with-rcs-ids or --without-rcs-ids was given.
11349 if test "${with_rcs_ids+set}" = set; then
11350 withval="$with_rcs_ids"
11351 with_rcs_ids=$withval
11355 echo "$as_me:11355: result: $with_rcs_ids" >&5
11356 echo "${ECHO_T}$with_rcs_ids" >&6
11357 test "$with_rcs_ids" = yes &&
11358 cat >>confdefs.h <<\EOF
11359 #define USE_RCS_IDS 1
11362 ###############################################################################
11364 ### Note that some functions (such as const) are normally disabled anyway.
11365 echo "$as_me:11365: checking if you want to build with function extensions" >&5
11366 echo $ECHO_N "checking if you want to build with function extensions... $ECHO_C" >&6
11368 # Check whether --enable-ext-funcs or --disable-ext-funcs was given.
11369 if test "${enable_ext_funcs+set}" = set; then
11370 enableval="$enable_ext_funcs"
11371 with_ext_funcs=$enableval
11375 echo "$as_me:11375: result: $with_ext_funcs" >&5
11376 echo "${ECHO_T}$with_ext_funcs" >&6
11377 if test "$with_ext_funcs" = yes ; then
11378 NCURSES_EXT_FUNCS=1
11380 cat >>confdefs.h <<\EOF
11381 #define HAVE_USE_DEFAULT_COLORS 1
11384 cat >>confdefs.h <<\EOF
11385 #define NCURSES_EXT_FUNCS 1
11389 NCURSES_EXT_FUNCS=0
11392 ### use option --enable-const to turn on use of const beyond that in XSI.
11393 echo "$as_me:11393: checking for extended use of const keyword" >&5
11394 echo $ECHO_N "checking for extended use of const keyword... $ECHO_C" >&6
11396 # Check whether --enable-const or --disable-const was given.
11397 if test "${enable_const+set}" = set; then
11398 enableval="$enable_const"
11399 with_ext_const=$enableval
11403 echo "$as_me:11403: result: $with_ext_const" >&5
11404 echo "${ECHO_T}$with_ext_const" >&6
11405 NCURSES_CONST='/*nothing*/'
11406 if test "$with_ext_const" = yes ; then
11407 NCURSES_CONST=const
11410 ###############################################################################
11411 # These options are relatively safe to experiment with.
11413 echo "$as_me:11413: checking if you want all development code" >&5
11414 echo $ECHO_N "checking if you want all development code... $ECHO_C" >&6
11416 # Check whether --with-develop or --without-develop was given.
11417 if test "${with_develop+set}" = set; then
11418 withval="$with_develop"
11419 with_develop=$withval
11423 echo "$as_me:11423: result: $with_develop" >&5
11424 echo "${ECHO_T}$with_develop" >&6
11426 ###############################################################################
11427 # These are just experimental, probably should not be in a package:
11429 # This is still experimental (20080329), but should ultimately be moved to
11430 # the script-block --with-normal, etc.
11432 echo "$as_me:11432: checking if you want to link with the pthread library" >&5
11433 echo $ECHO_N "checking if you want to link with the pthread library... $ECHO_C" >&6
11435 # Check whether --with-pthread or --without-pthread was given.
11436 if test "${with_pthread+set}" = set; then
11437 withval="$with_pthread"
11438 with_pthread=$withval
11442 echo "$as_me:11442: result: $with_pthread" >&5
11443 echo "${ECHO_T}$with_pthread" >&6
11445 if test "$with_pthread" != no ; then
11446 echo "$as_me:11446: checking for pthread.h" >&5
11447 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
11448 if test "${ac_cv_header_pthread_h+set}" = set; then
11449 echo $ECHO_N "(cached) $ECHO_C" >&6
11451 cat >conftest.$ac_ext <<_ACEOF
11452 #line 11452 "configure"
11453 #include "confdefs.h"
11454 #include <pthread.h>
11456 if { (eval echo "$as_me:11456: \"$ac_cpp conftest.$ac_ext\"") >&5
11457 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11459 egrep -v '^ *\+' conftest.er1 >conftest.err
11461 cat conftest.err >&5
11462 echo "$as_me:11462: \$? = $ac_status" >&5
11463 (exit $ac_status); } >/dev/null; then
11464 if test -s conftest.err; then
11465 ac_cpp_err=$ac_c_preproc_warn_flag
11472 if test -z "$ac_cpp_err"; then
11473 ac_cv_header_pthread_h=yes
11475 echo "$as_me: failed program was:" >&5
11476 cat conftest.$ac_ext >&5
11477 ac_cv_header_pthread_h=no
11479 rm -f conftest.err conftest.$ac_ext
11481 echo "$as_me:11481: result: $ac_cv_header_pthread_h" >&5
11482 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
11483 if test $ac_cv_header_pthread_h = yes; then
11485 cat >>confdefs.h <<\EOF
11486 #define HAVE_PTHREADS_H 1
11489 for cf_lib_pthread in pthread c_r
11491 echo "$as_me:11491: checking if we can link with the $cf_lib_pthread library" >&5
11492 echo $ECHO_N "checking if we can link with the $cf_lib_pthread library... $ECHO_C" >&6
11493 cf_save_LIBS="$LIBS"
11495 cf_add_libs="-l$cf_lib_pthread"
11496 # Filter out duplicates - this happens with badly-designed ".pc" files...
11497 for cf_add_1lib in $LIBS
11499 for cf_add_2lib in $cf_add_libs
11501 if test "x$cf_add_1lib" = "x$cf_add_2lib"
11507 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
11509 LIBS="$cf_add_libs"
11511 cat >conftest.$ac_ext <<_ACEOF
11512 #line 11512 "configure"
11513 #include "confdefs.h"
11515 #include <pthread.h>
11521 int rc = pthread_create(0,0,0,0);
11522 int r2 = pthread_mutexattr_settype(0, 0);
11528 rm -f conftest.$ac_objext conftest$ac_exeext
11529 if { (eval echo "$as_me:11529: \"$ac_link\"") >&5
11530 (eval $ac_link) 2>&5
11532 echo "$as_me:11532: \$? = $ac_status" >&5
11533 (exit $ac_status); } &&
11534 { ac_try='test -s conftest$ac_exeext'
11535 { (eval echo "$as_me:11535: \"$ac_try\"") >&5
11536 (eval $ac_try) 2>&5
11538 echo "$as_me:11538: \$? = $ac_status" >&5
11539 (exit $ac_status); }; }; then
11542 echo "$as_me: failed program was:" >&5
11543 cat conftest.$ac_ext >&5
11546 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11547 LIBS="$cf_save_LIBS"
11548 echo "$as_me:11548: result: $with_pthread" >&5
11549 echo "${ECHO_T}$with_pthread" >&6
11550 test "$with_pthread" = yes && break
11553 if test "$with_pthread" = yes ; then
11555 cf_add_libs="-l$cf_lib_pthread"
11556 # Filter out duplicates - this happens with badly-designed ".pc" files...
11557 for cf_add_1lib in $LIBS
11559 for cf_add_2lib in $cf_add_libs
11561 if test "x$cf_add_1lib" = "x$cf_add_2lib"
11567 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
11569 LIBS="$cf_add_libs"
11571 cat >>confdefs.h <<\EOF
11572 #define HAVE_LIBPTHREADS 1
11576 { { echo "$as_me:11576: error: Cannot link with pthread library" >&5
11577 echo "$as_me: error: Cannot link with pthread library" >&2;}
11578 { (exit 1); exit 1; }; }
11585 echo "$as_me:11585: checking if you want to use weak-symbols for pthreads" >&5
11586 echo $ECHO_N "checking if you want to use weak-symbols for pthreads... $ECHO_C" >&6
11588 # Check whether --enable-weak-symbols or --disable-weak-symbols was given.
11589 if test "${enable_weak_symbols+set}" = set; then
11590 enableval="$enable_weak_symbols"
11591 use_weak_symbols=$withval
11593 use_weak_symbols=no
11595 echo "$as_me:11595: result: $use_weak_symbols" >&5
11596 echo "${ECHO_T}$use_weak_symbols" >&6
11597 if test "$use_weak_symbols" = yes ; then
11599 echo "$as_me:11599: checking if $CC supports weak symbols" >&5
11600 echo $ECHO_N "checking if $CC supports weak symbols... $ECHO_C" >&6
11601 if test "${cf_cv_weak_symbols+set}" = set; then
11602 echo $ECHO_N "(cached) $ECHO_C" >&6
11605 cat >conftest.$ac_ext <<_ACEOF
11606 #line 11606 "configure"
11607 #include "confdefs.h"
11614 #if defined(__GNUC__)
11615 # if defined __USE_ISOC99
11616 # define _cat_pragma(exp) _Pragma(#exp)
11617 # define _weak_pragma(exp) _cat_pragma(weak name)
11619 # define _weak_pragma(exp)
11621 # define _declare(name) __extension__ extern __typeof__(name) name
11622 # define weak_symbol(name) _weak_pragma(name) _declare(name) __attribute__((weak))
11625 weak_symbol(fopen);
11631 rm -f conftest.$ac_objext
11632 if { (eval echo "$as_me:11632: \"$ac_compile\"") >&5
11633 (eval $ac_compile) 2>&5
11635 echo "$as_me:11635: \$? = $ac_status" >&5
11636 (exit $ac_status); } &&
11637 { ac_try='test -s conftest.$ac_objext'
11638 { (eval echo "$as_me:11638: \"$ac_try\"") >&5
11639 (eval $ac_try) 2>&5
11641 echo "$as_me:11641: \$? = $ac_status" >&5
11642 (exit $ac_status); }; }; then
11643 cf_cv_weak_symbols=yes
11645 echo "$as_me: failed program was:" >&5
11646 cat conftest.$ac_ext >&5
11647 cf_cv_weak_symbols=no
11649 rm -f conftest.$ac_objext conftest.$ac_ext
11652 echo "$as_me:11652: result: $cf_cv_weak_symbols" >&5
11653 echo "${ECHO_T}$cf_cv_weak_symbols" >&6
11656 cf_cv_weak_symbols=no
11659 if test $cf_cv_weak_symbols = yes ; then
11661 cat >>confdefs.h <<\EOF
11662 #define USE_WEAK_SYMBOLS 1
11668 if test "$with_pthread" = "yes" ; then
11670 cat >>confdefs.h <<\EOF
11671 #define USE_PTHREADS 1
11674 enable_reentrant=yes
11675 if test $cf_cv_weak_symbols = yes ; then
11680 # OpenSUSE is installing ncurses6, using reentrant option.
11681 echo "$as_me:11681: checking for _nc_TABSIZE" >&5
11682 echo $ECHO_N "checking for _nc_TABSIZE... $ECHO_C" >&6
11683 if test "${ac_cv_func__nc_TABSIZE+set}" = set; then
11684 echo $ECHO_N "(cached) $ECHO_C" >&6
11686 cat >conftest.$ac_ext <<_ACEOF
11687 #line 11687 "configure"
11688 #include "confdefs.h"
11689 /* System header to define __stub macros and hopefully few prototypes,
11690 which can conflict with char _nc_TABSIZE (); below. */
11691 #include <assert.h>
11692 /* Override any gcc2 internal prototype to avoid an error. */
11696 /* We use char because int might match the return type of a gcc2
11697 builtin and then its argument prototype would still apply. */
11698 char _nc_TABSIZE ();
11704 /* The GNU C library defines this for functions which it implements
11705 to always fail with ENOSYS. Some functions are actually named
11706 something starting with __ and the normal name is an alias. */
11707 #if defined (__stub__nc_TABSIZE) || defined (__stub____nc_TABSIZE)
11710 f = _nc_TABSIZE; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
11717 rm -f conftest.$ac_objext conftest$ac_exeext
11718 if { (eval echo "$as_me:11718: \"$ac_link\"") >&5
11719 (eval $ac_link) 2>&5
11721 echo "$as_me:11721: \$? = $ac_status" >&5
11722 (exit $ac_status); } &&
11723 { ac_try='test -s conftest$ac_exeext'
11724 { (eval echo "$as_me:11724: \"$ac_try\"") >&5
11725 (eval $ac_try) 2>&5
11727 echo "$as_me:11727: \$? = $ac_status" >&5
11728 (exit $ac_status); }; }; then
11729 ac_cv_func__nc_TABSIZE=yes
11731 echo "$as_me: failed program was:" >&5
11732 cat conftest.$ac_ext >&5
11733 ac_cv_func__nc_TABSIZE=no
11735 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11737 echo "$as_me:11737: result: $ac_cv_func__nc_TABSIZE" >&5
11738 echo "${ECHO_T}$ac_cv_func__nc_TABSIZE" >&6
11739 if test $ac_cv_func__nc_TABSIZE = yes; then
11740 assume_reentrant=yes
11742 assume_reentrant=no
11745 # Reentrant code has to be opaque; there's little advantage to making ncurses
11746 # opaque outside of that, so there is no --enable-opaque option. We can use
11747 # this option without --with-pthreads, but this will be always set for
11749 echo "$as_me:11749: checking if you want experimental reentrant code" >&5
11750 echo $ECHO_N "checking if you want experimental reentrant code... $ECHO_C" >&6
11752 # Check whether --enable-reentrant or --disable-reentrant was given.
11753 if test "${enable_reentrant+set}" = set; then
11754 enableval="$enable_reentrant"
11755 with_reentrant=$enableval
11757 with_reentrant=$assume_reentrant
11759 echo "$as_me:11759: result: $with_reentrant" >&5
11760 echo "${ECHO_T}$with_reentrant" >&6
11761 if test "$with_reentrant" = yes ; then
11762 cf_cv_enable_reentrant=1
11763 if test $cf_cv_weak_symbols = yes ; then
11765 # remove pthread library from $LIBS
11766 LIBS=`echo "$LIBS" | sed -e 's/-lpthread[ ]//g' -e 's/-lpthread$//'`
11768 elif test "$assume_reentrant" = no ; then
11769 LIB_SUFFIX="t${LIB_SUFFIX}"
11772 cat >>confdefs.h <<\EOF
11773 #define USE_REENTRANT 1
11777 cf_cv_enable_reentrant=0
11780 ### Allow using a different wrap-prefix
11781 if test "$cf_cv_enable_reentrant" != 0 || test "$BROKEN_LINKER" = 1 ; then
11782 echo "$as_me:11782: checking for prefix used to wrap public variables" >&5
11783 echo $ECHO_N "checking for prefix used to wrap public variables... $ECHO_C" >&6
11785 # Check whether --with-wrap-prefix or --without-wrap-prefix was given.
11786 if test "${with_wrap_prefix+set}" = set; then
11787 withval="$with_wrap_prefix"
11788 NCURSES_WRAP_PREFIX=$withval
11790 NCURSES_WRAP_PREFIX=_nc_
11792 echo "$as_me:11792: result: $NCURSES_WRAP_PREFIX" >&5
11793 echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
11795 NCURSES_WRAP_PREFIX=_nc_
11798 cat >>confdefs.h <<EOF
11799 #define NCURSES_WRAP_PREFIX "$NCURSES_WRAP_PREFIX"
11802 ###############################################################################
11804 ### use option --disable-echo to suppress full display compiling commands
11806 echo "$as_me:11806: checking if you want to see long compiling messages" >&5
11807 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
11809 # Check whether --enable-echo or --disable-echo was given.
11810 if test "${enable_echo+set}" = set; then
11811 enableval="$enable_echo"
11812 test "$enableval" != no && enableval=yes
11813 if test "$enableval" != "yes" ; then
11816 ECHO_LD='@echo linking $@;'
11817 RULE_CC='@echo compiling $<'
11818 SHOW_CC='@echo compiling $@'
11840 echo "$as_me:11840: result: $enableval" >&5
11841 echo "${ECHO_T}$enableval" >&6
11843 ### use option --enable-warnings to turn on all gcc warnings
11844 echo "$as_me:11844: checking if you want to see compiler warnings" >&5
11845 echo $ECHO_N "checking if you want to see compiler warnings... $ECHO_C" >&6
11847 # Check whether --enable-warnings or --disable-warnings was given.
11848 if test "${enable_warnings+set}" = set; then
11849 enableval="$enable_warnings"
11850 with_warnings=$enableval
11852 echo "$as_me:11852: result: $with_warnings" >&5
11853 echo "${ECHO_T}$with_warnings" >&6
11855 if test "x$with_warnings" = "xyes"; then
11857 ADAFLAGS="$ADAFLAGS -gnatg"
11861 if test "$GCC" = yes ; then
11864 echo "$as_me:11864: checking if this is really Intel C compiler" >&5
11865 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
11866 cf_save_CFLAGS="$CFLAGS"
11867 CFLAGS="$CFLAGS -no-gcc"
11868 cat >conftest.$ac_ext <<_ACEOF
11869 #line 11869 "configure"
11870 #include "confdefs.h"
11876 #ifdef __INTEL_COMPILER
11885 rm -f conftest.$ac_objext
11886 if { (eval echo "$as_me:11886: \"$ac_compile\"") >&5
11887 (eval $ac_compile) 2>&5
11889 echo "$as_me:11889: \$? = $ac_status" >&5
11890 (exit $ac_status); } &&
11891 { ac_try='test -s conftest.$ac_objext'
11892 { (eval echo "$as_me:11892: \"$ac_try\"") >&5
11893 (eval $ac_try) 2>&5
11895 echo "$as_me:11895: \$? = $ac_status" >&5
11896 (exit $ac_status); }; }; then
11898 cf_save_CFLAGS="$cf_save_CFLAGS -we147"
11901 echo "$as_me: failed program was:" >&5
11902 cat conftest.$ac_ext >&5
11904 rm -f conftest.$ac_objext conftest.$ac_ext
11905 CFLAGS="$cf_save_CFLAGS"
11906 echo "$as_me:11906: result: $INTEL_COMPILER" >&5
11907 echo "${ECHO_T}$INTEL_COMPILER" >&6
11914 if test "$GCC" = yes ; then
11915 echo "$as_me:11915: checking if this is really Clang C compiler" >&5
11916 echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6
11917 cf_save_CFLAGS="$CFLAGS"
11918 CFLAGS="$CFLAGS -Qunused-arguments"
11919 cat >conftest.$ac_ext <<_ACEOF
11920 #line 11920 "configure"
11921 #include "confdefs.h"
11936 rm -f conftest.$ac_objext
11937 if { (eval echo "$as_me:11937: \"$ac_compile\"") >&5
11938 (eval $ac_compile) 2>&5
11940 echo "$as_me:11940: \$? = $ac_status" >&5
11941 (exit $ac_status); } &&
11942 { ac_try='test -s conftest.$ac_objext'
11943 { (eval echo "$as_me:11943: \"$ac_try\"") >&5
11944 (eval $ac_try) 2>&5
11946 echo "$as_me:11946: \$? = $ac_status" >&5
11947 (exit $ac_status); }; }; then
11949 cf_save_CFLAGS="$cf_save_CFLAGS -Qunused-arguments"
11952 echo "$as_me: failed program was:" >&5
11953 cat conftest.$ac_ext >&5
11955 rm -f conftest.$ac_objext conftest.$ac_ext
11956 CFLAGS="$cf_save_CFLAGS"
11957 echo "$as_me:11957: result: $CLANG_COMPILER" >&5
11958 echo "${ECHO_T}$CLANG_COMPILER" >&6
11961 cat > conftest.$ac_ext <<EOF
11962 #line 11962 "${as_me:-configure}"
11963 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
11966 if test "$INTEL_COMPILER" = yes
11968 # The "-wdXXX" options suppress warnings:
11969 # remark #1419: external declaration in primary source file
11970 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
11971 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
11972 # remark #193: zero used for undefined preprocessing identifier
11973 # remark #593: variable "curs_sb_left_arrow" was set but never used
11974 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
11975 # remark #869: parameter "tw" was never referenced
11976 # remark #981: operands are evaluated in unspecified order
11977 # warning #279: controlling expression is constant
11979 { echo "$as_me:11979: checking for $CC warning options..." >&5
11980 echo "$as_me: checking for $CC warning options..." >&6;}
11981 cf_save_CFLAGS="$CFLAGS"
11982 EXTRA_CFLAGS="-Wall"
11994 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
11995 if { (eval echo "$as_me:11995: \"$ac_compile\"") >&5
11996 (eval $ac_compile) 2>&5
11998 echo "$as_me:11998: \$? = $ac_status" >&5
11999 (exit $ac_status); }; then
12000 test -n "$verbose" && echo "$as_me:12000: result: ... -$cf_opt" >&5
12001 echo "${ECHO_T}... -$cf_opt" >&6
12002 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
12005 CFLAGS="$cf_save_CFLAGS"
12007 elif test "$GCC" = yes
12009 { echo "$as_me:12009: checking for $CC warning options..." >&5
12010 echo "$as_me: checking for $CC warning options..." >&6;}
12011 cf_save_CFLAGS="$CFLAGS"
12014 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
12015 cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs"
12016 test "x$CLANG_COMPILER" = xyes && cf_gcc_warnings=
12017 for cf_opt in W Wall \
12018 Wbad-function-cast \
12021 Wdeclaration-after-statement \
12024 Wmissing-declarations \
12025 Wmissing-prototypes \
12029 Wstrict-prototypes \
12030 Wundef $cf_gcc_warnings $cf_warn_CONST Wno-unknown-pragmas Wswitch-enum
12032 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
12033 if { (eval echo "$as_me:12033: \"$ac_compile\"") >&5
12034 (eval $ac_compile) 2>&5
12036 echo "$as_me:12036: \$? = $ac_status" >&5
12037 (exit $ac_status); }; then
12038 test -n "$verbose" && echo "$as_me:12038: result: ... -$cf_opt" >&5
12039 echo "${ECHO_T}... -$cf_opt" >&6
12042 CPPFLAGS="$CPPFLAGS -DXTSTRINGDEFINES"
12045 case $GCC_VERSION in
12047 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
12049 echo "${as_me:-configure}:12049: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
12055 case $GCC_VERSION in
12057 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
12059 echo "${as_me:-configure}:12059: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
12065 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
12068 CFLAGS="$cf_save_CFLAGS"
12074 if test "$GCC" = yes
12076 cat > conftest.i <<EOF
12078 #define GCC_PRINTF 0
12081 #define GCC_SCANF 0
12083 #ifndef GCC_NORETURN
12084 #define GCC_NORETURN /* nothing */
12087 #define GCC_UNUSED /* nothing */
12090 if test "$GCC" = yes
12092 { echo "$as_me:12092: checking for $CC __attribute__ directives..." >&5
12093 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
12094 cat > conftest.$ac_ext <<EOF
12095 #line 12095 "${as_me:-configure}"
12096 #include "confdefs.h"
12097 #include "conftest.h"
12098 #include "conftest.i"
12100 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
12102 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
12105 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
12107 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
12109 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
12110 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
12111 extern void foo(void) GCC_NORETURN;
12112 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
12114 cf_printf_attribute=no
12115 cf_scanf_attribute=no
12116 for cf_attribute in scanf printf unused noreturn
12119 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
12121 cf_directive="__attribute__(($cf_attribute))"
12122 echo "checking for $CC $cf_directive" 1>&5
12124 case $cf_attribute in
12126 cf_printf_attribute=yes
12127 cat >conftest.h <<EOF
12128 #define GCC_$cf_ATTRIBUTE 1
12132 cf_scanf_attribute=yes
12133 cat >conftest.h <<EOF
12134 #define GCC_$cf_ATTRIBUTE 1
12138 cat >conftest.h <<EOF
12139 #define GCC_$cf_ATTRIBUTE $cf_directive
12144 if { (eval echo "$as_me:12144: \"$ac_compile\"") >&5
12145 (eval $ac_compile) 2>&5
12147 echo "$as_me:12147: \$? = $ac_status" >&5
12148 (exit $ac_status); }; then
12149 test -n "$verbose" && echo "$as_me:12149: result: ... $cf_attribute" >&5
12150 echo "${ECHO_T}... $cf_attribute" >&6
12151 cat conftest.h >>confdefs.h
12152 case $cf_attribute in
12155 cat >>confdefs.h <<EOF
12156 #define GCC_NORETURN $cf_directive
12161 cf_value='/* nothing */'
12162 if test "$cf_printf_attribute" != no ; then
12163 cf_value='__attribute__((format(printf,fmt,var)))'
12165 cat >>confdefs.h <<\EOF
12166 #define GCC_PRINTF 1
12171 cat >>confdefs.h <<EOF
12172 #define GCC_PRINTFLIKE(fmt,var) $cf_value
12177 cf_value='/* nothing */'
12178 if test "$cf_scanf_attribute" != no ; then
12179 cf_value='__attribute__((format(scanf,fmt,var)))'
12181 cat >>confdefs.h <<\EOF
12182 #define GCC_SCANF 1
12187 cat >>confdefs.h <<EOF
12188 #define GCC_SCANFLIKE(fmt,var) $cf_value
12194 cat >>confdefs.h <<EOF
12195 #define GCC_UNUSED $cf_directive
12203 fgrep define conftest.i >>confdefs.h
12208 ### use option --enable-assertions to turn on generation of assertion code
12209 echo "$as_me:12209: checking if you want to enable runtime assertions" >&5
12210 echo $ECHO_N "checking if you want to enable runtime assertions... $ECHO_C" >&6
12212 # Check whether --enable-assertions or --disable-assertions was given.
12213 if test "${enable_assertions+set}" = set; then
12214 enableval="$enable_assertions"
12215 with_assertions=$enableval
12219 echo "$as_me:12219: result: $with_assertions" >&5
12220 echo "${ECHO_T}$with_assertions" >&6
12223 if test "$with_assertions" = no
12225 CPPFLAGS="$CPPFLAGS -DNDEBUG"
12228 ADAFLAGS="$ADAFLAGS -gnata"
12233 ### use option --disable-leaks to suppress "permanent" leaks, for testing
12235 cat >>confdefs.h <<\EOF
12236 #define HAVE_NC_ALLOC_H 1
12239 ### use option --enable-expanded to generate certain macros as functions
12241 # Check whether --enable-expanded or --disable-expanded was given.
12242 if test "${enable_expanded+set}" = set; then
12243 enableval="$enable_expanded"
12244 test "$enableval" = yes &&
12245 cat >>confdefs.h <<\EOF
12246 #define NCURSES_EXPANDED 1
12251 ### use option --disable-macros to suppress macros in favor of functions
12253 # Check whether --enable-macros or --disable-macros was given.
12254 if test "${enable_macros+set}" = set; then
12255 enableval="$enable_macros"
12256 test "$enableval" = no &&
12257 cat >>confdefs.h <<\EOF
12258 #define NCURSES_NOMACROS 1
12263 # Normally we only add trace() to the debug-library. Allow this to be
12264 # extended to all models of the ncurses library:
12266 case "$CFLAGS $CPPFLAGS" in
12272 echo "$as_me:12272: checking whether to add trace feature to all models" >&5
12273 echo $ECHO_N "checking whether to add trace feature to all models... $ECHO_C" >&6
12275 # Check whether --with-trace or --without-trace was given.
12276 if test "${with_trace+set}" = set; then
12277 withval="$with_trace"
12278 cf_with_trace=$withval
12280 cf_with_trace=$cf_all_traces
12282 echo "$as_me:12282: result: $cf_with_trace" >&5
12283 echo "${ECHO_T}$cf_with_trace" >&6
12285 if test "$cf_with_trace" = yes ; then
12291 cf_new_extra_cppflags=
12293 for cf_add_cflags in -DTRACE
12295 case $cf_fix_cppflags in
12297 case $cf_add_cflags in
12298 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12299 case $cf_add_cflags in
12301 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12303 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12304 && test -z "${cf_tst_cflags}" \
12305 && cf_fix_cppflags=yes
12307 if test $cf_fix_cppflags = yes ; then
12308 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12310 elif test "${cf_tst_cflags}" = "\"'" ; then
12311 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12316 case "$CPPFLAGS" in
12320 case $cf_add_cflags in
12322 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12324 CPPFLAGS=`echo "$CPPFLAGS" | \
12325 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12326 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12330 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
12335 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
12340 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12342 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12344 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12345 && test -z "${cf_tst_cflags}" \
12346 && cf_fix_cppflags=no
12351 if test -n "$cf_new_cflags" ; then
12353 CFLAGS="$CFLAGS $cf_new_cflags"
12356 if test -n "$cf_new_cppflags" ; then
12358 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
12361 if test -n "$cf_new_extra_cppflags" ; then
12363 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
12370 echo "$as_me:12370: checking if we want to use GNAT projects" >&5
12371 echo $ECHO_N "checking if we want to use GNAT projects... $ECHO_C" >&6
12373 # Check whether --enable-gnat-projects or --disable-gnat-projects was given.
12374 if test "${enable_gnat_projects+set}" = set; then
12375 enableval="$enable_gnat_projects"
12376 test "$enableval" != no && enableval=yes
12377 if test "$enableval" != "yes" ; then
12378 enable_gnat_projects=no
12380 enable_gnat_projects=yes
12384 enable_gnat_projects=yes
12387 echo "$as_me:12387: result: $enable_gnat_projects" >&5
12388 echo "${ECHO_T}$enable_gnat_projects" >&6
12390 ### Checks for libraries.
12391 case $cf_cv_system_name in
12395 echo "$as_me:12395: checking for gettimeofday" >&5
12396 echo $ECHO_N "checking for gettimeofday... $ECHO_C" >&6
12397 if test "${ac_cv_func_gettimeofday+set}" = set; then
12398 echo $ECHO_N "(cached) $ECHO_C" >&6
12400 cat >conftest.$ac_ext <<_ACEOF
12401 #line 12401 "configure"
12402 #include "confdefs.h"
12403 /* System header to define __stub macros and hopefully few prototypes,
12404 which can conflict with char gettimeofday (); below. */
12405 #include <assert.h>
12406 /* Override any gcc2 internal prototype to avoid an error. */
12410 /* We use char because int might match the return type of a gcc2
12411 builtin and then its argument prototype would still apply. */
12412 char gettimeofday ();
12418 /* The GNU C library defines this for functions which it implements
12419 to always fail with ENOSYS. Some functions are actually named
12420 something starting with __ and the normal name is an alias. */
12421 #if defined (__stub_gettimeofday) || defined (__stub___gettimeofday)
12424 f = gettimeofday; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
12431 rm -f conftest.$ac_objext conftest$ac_exeext
12432 if { (eval echo "$as_me:12432: \"$ac_link\"") >&5
12433 (eval $ac_link) 2>&5
12435 echo "$as_me:12435: \$? = $ac_status" >&5
12436 (exit $ac_status); } &&
12437 { ac_try='test -s conftest$ac_exeext'
12438 { (eval echo "$as_me:12438: \"$ac_try\"") >&5
12439 (eval $ac_try) 2>&5
12441 echo "$as_me:12441: \$? = $ac_status" >&5
12442 (exit $ac_status); }; }; then
12443 ac_cv_func_gettimeofday=yes
12445 echo "$as_me: failed program was:" >&5
12446 cat conftest.$ac_ext >&5
12447 ac_cv_func_gettimeofday=no
12449 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12451 echo "$as_me:12451: result: $ac_cv_func_gettimeofday" >&5
12452 echo "${ECHO_T}$ac_cv_func_gettimeofday" >&6
12453 if test $ac_cv_func_gettimeofday = yes; then
12454 cat >>confdefs.h <<\EOF
12455 #define HAVE_GETTIMEOFDAY 1
12460 echo "$as_me:12460: checking for gettimeofday in -lbsd" >&5
12461 echo $ECHO_N "checking for gettimeofday in -lbsd... $ECHO_C" >&6
12462 if test "${ac_cv_lib_bsd_gettimeofday+set}" = set; then
12463 echo $ECHO_N "(cached) $ECHO_C" >&6
12465 ac_check_lib_save_LIBS=$LIBS
12467 cat >conftest.$ac_ext <<_ACEOF
12468 #line 12468 "configure"
12469 #include "confdefs.h"
12471 /* Override any gcc2 internal prototype to avoid an error. */
12475 /* We use char because int might match the return type of a gcc2
12476 builtin and then its argument prototype would still apply. */
12477 char gettimeofday ();
12486 rm -f conftest.$ac_objext conftest$ac_exeext
12487 if { (eval echo "$as_me:12487: \"$ac_link\"") >&5
12488 (eval $ac_link) 2>&5
12490 echo "$as_me:12490: \$? = $ac_status" >&5
12491 (exit $ac_status); } &&
12492 { ac_try='test -s conftest$ac_exeext'
12493 { (eval echo "$as_me:12493: \"$ac_try\"") >&5
12494 (eval $ac_try) 2>&5
12496 echo "$as_me:12496: \$? = $ac_status" >&5
12497 (exit $ac_status); }; }; then
12498 ac_cv_lib_bsd_gettimeofday=yes
12500 echo "$as_me: failed program was:" >&5
12501 cat conftest.$ac_ext >&5
12502 ac_cv_lib_bsd_gettimeofday=no
12504 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12505 LIBS=$ac_check_lib_save_LIBS
12507 echo "$as_me:12507: result: $ac_cv_lib_bsd_gettimeofday" >&5
12508 echo "${ECHO_T}$ac_cv_lib_bsd_gettimeofday" >&6
12509 if test $ac_cv_lib_bsd_gettimeofday = yes; then
12511 cat >>confdefs.h <<\EOF
12512 #define HAVE_GETTIMEOFDAY 1
12522 ### Checks for header files.
12523 echo "$as_me:12523: checking for ANSI C header files" >&5
12524 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
12525 if test "${ac_cv_header_stdc+set}" = set; then
12526 echo $ECHO_N "(cached) $ECHO_C" >&6
12528 cat >conftest.$ac_ext <<_ACEOF
12529 #line 12529 "configure"
12530 #include "confdefs.h"
12531 #include <stdlib.h>
12532 #include <stdarg.h>
12533 #include <string.h>
12537 if { (eval echo "$as_me:12537: \"$ac_cpp conftest.$ac_ext\"") >&5
12538 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12540 egrep -v '^ *\+' conftest.er1 >conftest.err
12542 cat conftest.err >&5
12543 echo "$as_me:12543: \$? = $ac_status" >&5
12544 (exit $ac_status); } >/dev/null; then
12545 if test -s conftest.err; then
12546 ac_cpp_err=$ac_c_preproc_warn_flag
12553 if test -z "$ac_cpp_err"; then
12554 ac_cv_header_stdc=yes
12556 echo "$as_me: failed program was:" >&5
12557 cat conftest.$ac_ext >&5
12558 ac_cv_header_stdc=no
12560 rm -f conftest.err conftest.$ac_ext
12562 if test $ac_cv_header_stdc = yes; then
12563 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
12564 cat >conftest.$ac_ext <<_ACEOF
12565 #line 12565 "configure"
12566 #include "confdefs.h"
12567 #include <string.h>
12570 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12571 egrep "memchr" >/dev/null 2>&1; then
12574 ac_cv_header_stdc=no
12580 if test $ac_cv_header_stdc = yes; then
12581 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
12582 cat >conftest.$ac_ext <<_ACEOF
12583 #line 12583 "configure"
12584 #include "confdefs.h"
12585 #include <stdlib.h>
12588 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12589 egrep "free" >/dev/null 2>&1; then
12592 ac_cv_header_stdc=no
12598 if test $ac_cv_header_stdc = yes; then
12599 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
12600 if test "$cross_compiling" = yes; then
12603 cat >conftest.$ac_ext <<_ACEOF
12604 #line 12604 "configure"
12605 #include "confdefs.h"
12607 #if ((' ' & 0x0FF) == 0x020)
12608 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
12609 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
12611 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
12612 || ('j' <= (c) && (c) <= 'r') \
12613 || ('s' <= (c) && (c) <= 'z'))
12614 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
12617 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
12622 for (i = 0; i < 256; i++)
12623 if (XOR (islower (i), ISLOWER (i))
12624 || toupper (i) != TOUPPER (i))
12625 $ac_main_return(2);
12626 $ac_main_return (0);
12629 rm -f conftest$ac_exeext
12630 if { (eval echo "$as_me:12630: \"$ac_link\"") >&5
12631 (eval $ac_link) 2>&5
12633 echo "$as_me:12633: \$? = $ac_status" >&5
12634 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12635 { (eval echo "$as_me:12635: \"$ac_try\"") >&5
12636 (eval $ac_try) 2>&5
12638 echo "$as_me:12638: \$? = $ac_status" >&5
12639 (exit $ac_status); }; }; then
12642 echo "$as_me: program exited with status $ac_status" >&5
12643 echo "$as_me: failed program was:" >&5
12644 cat conftest.$ac_ext >&5
12645 ac_cv_header_stdc=no
12647 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12651 echo "$as_me:12651: result: $ac_cv_header_stdc" >&5
12652 echo "${ECHO_T}$ac_cv_header_stdc" >&6
12653 if test $ac_cv_header_stdc = yes; then
12655 cat >>confdefs.h <<\EOF
12656 #define STDC_HEADERS 1
12661 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
12663 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
12664 inttypes.h stdint.h unistd.h
12666 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12667 echo "$as_me:12667: checking for $ac_header" >&5
12668 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12669 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12670 echo $ECHO_N "(cached) $ECHO_C" >&6
12672 cat >conftest.$ac_ext <<_ACEOF
12673 #line 12673 "configure"
12674 #include "confdefs.h"
12675 $ac_includes_default
12676 #include <$ac_header>
12678 rm -f conftest.$ac_objext
12679 if { (eval echo "$as_me:12679: \"$ac_compile\"") >&5
12680 (eval $ac_compile) 2>&5
12682 echo "$as_me:12682: \$? = $ac_status" >&5
12683 (exit $ac_status); } &&
12684 { ac_try='test -s conftest.$ac_objext'
12685 { (eval echo "$as_me:12685: \"$ac_try\"") >&5
12686 (eval $ac_try) 2>&5
12688 echo "$as_me:12688: \$? = $ac_status" >&5
12689 (exit $ac_status); }; }; then
12690 eval "$as_ac_Header=yes"
12692 echo "$as_me: failed program was:" >&5
12693 cat conftest.$ac_ext >&5
12694 eval "$as_ac_Header=no"
12696 rm -f conftest.$ac_objext conftest.$ac_ext
12698 echo "$as_me:12698: result: `eval echo '${'$as_ac_Header'}'`" >&5
12699 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12700 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12701 cat >>confdefs.h <<EOF
12702 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12708 echo "$as_me:12708: checking for signed char" >&5
12709 echo $ECHO_N "checking for signed char... $ECHO_C" >&6
12710 if test "${ac_cv_type_signed_char+set}" = set; then
12711 echo $ECHO_N "(cached) $ECHO_C" >&6
12713 cat >conftest.$ac_ext <<_ACEOF
12714 #line 12714 "configure"
12715 #include "confdefs.h"
12716 $ac_includes_default
12720 if ((signed char *) 0)
12722 if (sizeof (signed char))
12728 rm -f conftest.$ac_objext
12729 if { (eval echo "$as_me:12729: \"$ac_compile\"") >&5
12730 (eval $ac_compile) 2>&5
12732 echo "$as_me:12732: \$? = $ac_status" >&5
12733 (exit $ac_status); } &&
12734 { ac_try='test -s conftest.$ac_objext'
12735 { (eval echo "$as_me:12735: \"$ac_try\"") >&5
12736 (eval $ac_try) 2>&5
12738 echo "$as_me:12738: \$? = $ac_status" >&5
12739 (exit $ac_status); }; }; then
12740 ac_cv_type_signed_char=yes
12742 echo "$as_me: failed program was:" >&5
12743 cat conftest.$ac_ext >&5
12744 ac_cv_type_signed_char=no
12746 rm -f conftest.$ac_objext conftest.$ac_ext
12748 echo "$as_me:12748: result: $ac_cv_type_signed_char" >&5
12749 echo "${ECHO_T}$ac_cv_type_signed_char" >&6
12751 echo "$as_me:12751: checking size of signed char" >&5
12752 echo $ECHO_N "checking size of signed char... $ECHO_C" >&6
12753 if test "${ac_cv_sizeof_signed_char+set}" = set; then
12754 echo $ECHO_N "(cached) $ECHO_C" >&6
12756 if test "$ac_cv_type_signed_char" = yes; then
12757 if test "$cross_compiling" = yes; then
12758 # Depending upon the size, compute the lo and hi bounds.
12759 cat >conftest.$ac_ext <<_ACEOF
12760 #line 12760 "configure"
12761 #include "confdefs.h"
12762 $ac_includes_default
12766 int _array_ [1 - 2 * !((sizeof (signed char)) >= 0)]
12771 rm -f conftest.$ac_objext
12772 if { (eval echo "$as_me:12772: \"$ac_compile\"") >&5
12773 (eval $ac_compile) 2>&5
12775 echo "$as_me:12775: \$? = $ac_status" >&5
12776 (exit $ac_status); } &&
12777 { ac_try='test -s conftest.$ac_objext'
12778 { (eval echo "$as_me:12778: \"$ac_try\"") >&5
12779 (eval $ac_try) 2>&5
12781 echo "$as_me:12781: \$? = $ac_status" >&5
12782 (exit $ac_status); }; }; then
12785 cat >conftest.$ac_ext <<_ACEOF
12786 #line 12786 "configure"
12787 #include "confdefs.h"
12788 $ac_includes_default
12792 int _array_ [1 - 2 * !((sizeof (signed char)) <= $ac_mid)]
12797 rm -f conftest.$ac_objext
12798 if { (eval echo "$as_me:12798: \"$ac_compile\"") >&5
12799 (eval $ac_compile) 2>&5
12801 echo "$as_me:12801: \$? = $ac_status" >&5
12802 (exit $ac_status); } &&
12803 { ac_try='test -s conftest.$ac_objext'
12804 { (eval echo "$as_me:12804: \"$ac_try\"") >&5
12805 (eval $ac_try) 2>&5
12807 echo "$as_me:12807: \$? = $ac_status" >&5
12808 (exit $ac_status); }; }; then
12809 ac_hi=$ac_mid; break
12811 echo "$as_me: failed program was:" >&5
12812 cat conftest.$ac_ext >&5
12813 ac_lo=`expr $ac_mid + 1`; ac_mid=`expr 2 '*' $ac_mid + 1`
12815 rm -f conftest.$ac_objext conftest.$ac_ext
12818 echo "$as_me: failed program was:" >&5
12819 cat conftest.$ac_ext >&5
12822 cat >conftest.$ac_ext <<_ACEOF
12823 #line 12823 "configure"
12824 #include "confdefs.h"
12825 $ac_includes_default
12829 int _array_ [1 - 2 * !((sizeof (signed char)) >= $ac_mid)]
12834 rm -f conftest.$ac_objext
12835 if { (eval echo "$as_me:12835: \"$ac_compile\"") >&5
12836 (eval $ac_compile) 2>&5
12838 echo "$as_me:12838: \$? = $ac_status" >&5
12839 (exit $ac_status); } &&
12840 { ac_try='test -s conftest.$ac_objext'
12841 { (eval echo "$as_me:12841: \"$ac_try\"") >&5
12842 (eval $ac_try) 2>&5
12844 echo "$as_me:12844: \$? = $ac_status" >&5
12845 (exit $ac_status); }; }; then
12846 ac_lo=$ac_mid; break
12848 echo "$as_me: failed program was:" >&5
12849 cat conftest.$ac_ext >&5
12850 ac_hi=`expr $ac_mid - 1`; ac_mid=`expr 2 '*' $ac_mid`
12852 rm -f conftest.$ac_objext conftest.$ac_ext
12855 rm -f conftest.$ac_objext conftest.$ac_ext
12856 # Binary search between lo and hi bounds.
12857 while test "x$ac_lo" != "x$ac_hi"; do
12858 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
12859 cat >conftest.$ac_ext <<_ACEOF
12860 #line 12860 "configure"
12861 #include "confdefs.h"
12862 $ac_includes_default
12866 int _array_ [1 - 2 * !((sizeof (signed char)) <= $ac_mid)]
12871 rm -f conftest.$ac_objext
12872 if { (eval echo "$as_me:12872: \"$ac_compile\"") >&5
12873 (eval $ac_compile) 2>&5
12875 echo "$as_me:12875: \$? = $ac_status" >&5
12876 (exit $ac_status); } &&
12877 { ac_try='test -s conftest.$ac_objext'
12878 { (eval echo "$as_me:12878: \"$ac_try\"") >&5
12879 (eval $ac_try) 2>&5
12881 echo "$as_me:12881: \$? = $ac_status" >&5
12882 (exit $ac_status); }; }; then
12885 echo "$as_me: failed program was:" >&5
12886 cat conftest.$ac_ext >&5
12887 ac_lo=`expr $ac_mid + 1`
12889 rm -f conftest.$ac_objext conftest.$ac_ext
12891 ac_cv_sizeof_signed_char=$ac_lo
12893 if test "$cross_compiling" = yes; then
12894 { { echo "$as_me:12894: error: cannot run test program while cross compiling" >&5
12895 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
12896 { (exit 1); exit 1; }; }
12898 cat >conftest.$ac_ext <<_ACEOF
12899 #line 12899 "configure"
12900 #include "confdefs.h"
12901 $ac_includes_default
12905 FILE *f = fopen ("conftest.val", "w");
12907 $ac_main_return (1);
12908 fprintf (f, "%d", (sizeof (signed char)));
12914 rm -f conftest$ac_exeext
12915 if { (eval echo "$as_me:12915: \"$ac_link\"") >&5
12916 (eval $ac_link) 2>&5
12918 echo "$as_me:12918: \$? = $ac_status" >&5
12919 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12920 { (eval echo "$as_me:12920: \"$ac_try\"") >&5
12921 (eval $ac_try) 2>&5
12923 echo "$as_me:12923: \$? = $ac_status" >&5
12924 (exit $ac_status); }; }; then
12925 ac_cv_sizeof_signed_char=`cat conftest.val`
12927 echo "$as_me: program exited with status $ac_status" >&5
12928 echo "$as_me: failed program was:" >&5
12929 cat conftest.$ac_ext >&5
12931 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12936 ac_cv_sizeof_signed_char=0
12939 echo "$as_me:12939: result: $ac_cv_sizeof_signed_char" >&5
12940 echo "${ECHO_T}$ac_cv_sizeof_signed_char" >&6
12941 cat >>confdefs.h <<EOF
12942 #define SIZEOF_SIGNED_CHAR $ac_cv_sizeof_signed_char
12945 echo "$as_me:12945: checking for ANSI C header files" >&5
12946 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
12947 if test "${ac_cv_header_stdc+set}" = set; then
12948 echo $ECHO_N "(cached) $ECHO_C" >&6
12950 cat >conftest.$ac_ext <<_ACEOF
12951 #line 12951 "configure"
12952 #include "confdefs.h"
12953 #include <stdlib.h>
12954 #include <stdarg.h>
12955 #include <string.h>
12959 if { (eval echo "$as_me:12959: \"$ac_cpp conftest.$ac_ext\"") >&5
12960 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12962 egrep -v '^ *\+' conftest.er1 >conftest.err
12964 cat conftest.err >&5
12965 echo "$as_me:12965: \$? = $ac_status" >&5
12966 (exit $ac_status); } >/dev/null; then
12967 if test -s conftest.err; then
12968 ac_cpp_err=$ac_c_preproc_warn_flag
12975 if test -z "$ac_cpp_err"; then
12976 ac_cv_header_stdc=yes
12978 echo "$as_me: failed program was:" >&5
12979 cat conftest.$ac_ext >&5
12980 ac_cv_header_stdc=no
12982 rm -f conftest.err conftest.$ac_ext
12984 if test $ac_cv_header_stdc = yes; then
12985 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
12986 cat >conftest.$ac_ext <<_ACEOF
12987 #line 12987 "configure"
12988 #include "confdefs.h"
12989 #include <string.h>
12992 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12993 egrep "memchr" >/dev/null 2>&1; then
12996 ac_cv_header_stdc=no
13002 if test $ac_cv_header_stdc = yes; then
13003 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
13004 cat >conftest.$ac_ext <<_ACEOF
13005 #line 13005 "configure"
13006 #include "confdefs.h"
13007 #include <stdlib.h>
13010 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13011 egrep "free" >/dev/null 2>&1; then
13014 ac_cv_header_stdc=no
13020 if test $ac_cv_header_stdc = yes; then
13021 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
13022 if test "$cross_compiling" = yes; then
13025 cat >conftest.$ac_ext <<_ACEOF
13026 #line 13026 "configure"
13027 #include "confdefs.h"
13029 #if ((' ' & 0x0FF) == 0x020)
13030 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
13031 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
13033 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
13034 || ('j' <= (c) && (c) <= 'r') \
13035 || ('s' <= (c) && (c) <= 'z'))
13036 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
13039 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
13044 for (i = 0; i < 256; i++)
13045 if (XOR (islower (i), ISLOWER (i))
13046 || toupper (i) != TOUPPER (i))
13047 $ac_main_return(2);
13048 $ac_main_return (0);
13051 rm -f conftest$ac_exeext
13052 if { (eval echo "$as_me:13052: \"$ac_link\"") >&5
13053 (eval $ac_link) 2>&5
13055 echo "$as_me:13055: \$? = $ac_status" >&5
13056 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13057 { (eval echo "$as_me:13057: \"$ac_try\"") >&5
13058 (eval $ac_try) 2>&5
13060 echo "$as_me:13060: \$? = $ac_status" >&5
13061 (exit $ac_status); }; }; then
13064 echo "$as_me: program exited with status $ac_status" >&5
13065 echo "$as_me: failed program was:" >&5
13066 cat conftest.$ac_ext >&5
13067 ac_cv_header_stdc=no
13069 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13073 echo "$as_me:13073: result: $ac_cv_header_stdc" >&5
13074 echo "${ECHO_T}$ac_cv_header_stdc" >&6
13075 if test $ac_cv_header_stdc = yes; then
13077 cat >>confdefs.h <<\EOF
13078 #define STDC_HEADERS 1
13083 ac_header_dirent=no
13084 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
13085 as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
13086 echo "$as_me:13086: checking for $ac_hdr that defines DIR" >&5
13087 echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
13088 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13089 echo $ECHO_N "(cached) $ECHO_C" >&6
13091 cat >conftest.$ac_ext <<_ACEOF
13092 #line 13092 "configure"
13093 #include "confdefs.h"
13094 #include <sys/types.h>
13106 rm -f conftest.$ac_objext
13107 if { (eval echo "$as_me:13107: \"$ac_compile\"") >&5
13108 (eval $ac_compile) 2>&5
13110 echo "$as_me:13110: \$? = $ac_status" >&5
13111 (exit $ac_status); } &&
13112 { ac_try='test -s conftest.$ac_objext'
13113 { (eval echo "$as_me:13113: \"$ac_try\"") >&5
13114 (eval $ac_try) 2>&5
13116 echo "$as_me:13116: \$? = $ac_status" >&5
13117 (exit $ac_status); }; }; then
13118 eval "$as_ac_Header=yes"
13120 echo "$as_me: failed program was:" >&5
13121 cat conftest.$ac_ext >&5
13122 eval "$as_ac_Header=no"
13124 rm -f conftest.$ac_objext conftest.$ac_ext
13126 echo "$as_me:13126: result: `eval echo '${'$as_ac_Header'}'`" >&5
13127 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13128 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13129 cat >>confdefs.h <<EOF
13130 #define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
13133 ac_header_dirent=$ac_hdr; break
13137 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
13138 if test $ac_header_dirent = dirent.h; then
13139 echo "$as_me:13139: checking for opendir in -ldir" >&5
13140 echo $ECHO_N "checking for opendir in -ldir... $ECHO_C" >&6
13141 if test "${ac_cv_lib_dir_opendir+set}" = set; then
13142 echo $ECHO_N "(cached) $ECHO_C" >&6
13144 ac_check_lib_save_LIBS=$LIBS
13146 cat >conftest.$ac_ext <<_ACEOF
13147 #line 13147 "configure"
13148 #include "confdefs.h"
13150 /* Override any gcc2 internal prototype to avoid an error. */
13154 /* We use char because int might match the return type of a gcc2
13155 builtin and then its argument prototype would still apply. */
13165 rm -f conftest.$ac_objext conftest$ac_exeext
13166 if { (eval echo "$as_me:13166: \"$ac_link\"") >&5
13167 (eval $ac_link) 2>&5
13169 echo "$as_me:13169: \$? = $ac_status" >&5
13170 (exit $ac_status); } &&
13171 { ac_try='test -s conftest$ac_exeext'
13172 { (eval echo "$as_me:13172: \"$ac_try\"") >&5
13173 (eval $ac_try) 2>&5
13175 echo "$as_me:13175: \$? = $ac_status" >&5
13176 (exit $ac_status); }; }; then
13177 ac_cv_lib_dir_opendir=yes
13179 echo "$as_me: failed program was:" >&5
13180 cat conftest.$ac_ext >&5
13181 ac_cv_lib_dir_opendir=no
13183 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13184 LIBS=$ac_check_lib_save_LIBS
13186 echo "$as_me:13186: result: $ac_cv_lib_dir_opendir" >&5
13187 echo "${ECHO_T}$ac_cv_lib_dir_opendir" >&6
13188 if test $ac_cv_lib_dir_opendir = yes; then
13193 echo "$as_me:13193: checking for opendir in -lx" >&5
13194 echo $ECHO_N "checking for opendir in -lx... $ECHO_C" >&6
13195 if test "${ac_cv_lib_x_opendir+set}" = set; then
13196 echo $ECHO_N "(cached) $ECHO_C" >&6
13198 ac_check_lib_save_LIBS=$LIBS
13200 cat >conftest.$ac_ext <<_ACEOF
13201 #line 13201 "configure"
13202 #include "confdefs.h"
13204 /* Override any gcc2 internal prototype to avoid an error. */
13208 /* We use char because int might match the return type of a gcc2
13209 builtin and then its argument prototype would still apply. */
13219 rm -f conftest.$ac_objext conftest$ac_exeext
13220 if { (eval echo "$as_me:13220: \"$ac_link\"") >&5
13221 (eval $ac_link) 2>&5
13223 echo "$as_me:13223: \$? = $ac_status" >&5
13224 (exit $ac_status); } &&
13225 { ac_try='test -s conftest$ac_exeext'
13226 { (eval echo "$as_me:13226: \"$ac_try\"") >&5
13227 (eval $ac_try) 2>&5
13229 echo "$as_me:13229: \$? = $ac_status" >&5
13230 (exit $ac_status); }; }; then
13231 ac_cv_lib_x_opendir=yes
13233 echo "$as_me: failed program was:" >&5
13234 cat conftest.$ac_ext >&5
13235 ac_cv_lib_x_opendir=no
13237 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13238 LIBS=$ac_check_lib_save_LIBS
13240 echo "$as_me:13240: result: $ac_cv_lib_x_opendir" >&5
13241 echo "${ECHO_T}$ac_cv_lib_x_opendir" >&6
13242 if test $ac_cv_lib_x_opendir = yes; then
13248 echo "$as_me:13248: checking whether time.h and sys/time.h may both be included" >&5
13249 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
13250 if test "${ac_cv_header_time+set}" = set; then
13251 echo $ECHO_N "(cached) $ECHO_C" >&6
13253 cat >conftest.$ac_ext <<_ACEOF
13254 #line 13254 "configure"
13255 #include "confdefs.h"
13256 #include <sys/types.h>
13257 #include <sys/time.h>
13263 if ((struct tm *) 0)
13269 rm -f conftest.$ac_objext
13270 if { (eval echo "$as_me:13270: \"$ac_compile\"") >&5
13271 (eval $ac_compile) 2>&5
13273 echo "$as_me:13273: \$? = $ac_status" >&5
13274 (exit $ac_status); } &&
13275 { ac_try='test -s conftest.$ac_objext'
13276 { (eval echo "$as_me:13276: \"$ac_try\"") >&5
13277 (eval $ac_try) 2>&5
13279 echo "$as_me:13279: \$? = $ac_status" >&5
13280 (exit $ac_status); }; }; then
13281 ac_cv_header_time=yes
13283 echo "$as_me: failed program was:" >&5
13284 cat conftest.$ac_ext >&5
13285 ac_cv_header_time=no
13287 rm -f conftest.$ac_objext conftest.$ac_ext
13289 echo "$as_me:13289: result: $ac_cv_header_time" >&5
13290 echo "${ECHO_T}$ac_cv_header_time" >&6
13291 if test $ac_cv_header_time = yes; then
13293 cat >>confdefs.h <<\EOF
13294 #define TIME_WITH_SYS_TIME 1
13299 ### checks for compiler characteristics
13301 ac_cpp='$CPP $CPPFLAGS'
13302 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
13303 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
13304 ac_compiler_gnu=$ac_cv_c_compiler_gnu
13305 ac_main_return=return
13307 echo "$as_me:13307: checking for an ANSI C-conforming const" >&5
13308 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
13309 if test "${ac_cv_c_const+set}" = set; then
13310 echo $ECHO_N "(cached) $ECHO_C" >&6
13312 cat >conftest.$ac_ext <<_ACEOF
13313 #line 13313 "configure"
13314 #include "confdefs.h"
13319 /* FIXME: Include the comments suggested by Paul. */
13320 #ifndef __cplusplus
13321 /* Ultrix mips cc rejects this. */
13322 typedef int charset[2];
13324 /* SunOS 4.1.1 cc rejects this. */
13325 char const *const *ccp;
13327 /* NEC SVR4.0.2 mips cc rejects this. */
13328 struct point {int x, y;};
13329 static struct point const zero = {0,0};
13330 /* AIX XL C 1.02.0.0 rejects this.
13331 It does not let you subtract one const X* pointer from another in
13332 an arm of an if-expression whose if-part is not a constant
13334 const char *g = "string";
13335 ccp = &g + (g ? g-g : 0);
13336 /* HPUX 7.0 cc rejects these. */
13339 ccp = (char const *const *) p;
13340 { /* SCO 3.2v4 cc rejects this. */
13342 char const *s = 0 ? (char *) 0 : (char const *) 0;
13346 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
13347 int x[] = {25, 17};
13348 const int *foo = &x[0];
13351 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
13352 typedef const int *iptr;
13356 { /* AIX XL C 1.02.0.0 rejects this saying
13357 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
13358 struct s { int j; const int *ap[3]; };
13359 struct s *b; b->j = 5;
13361 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
13362 const int foo = 10;
13370 rm -f conftest.$ac_objext
13371 if { (eval echo "$as_me:13371: \"$ac_compile\"") >&5
13372 (eval $ac_compile) 2>&5
13374 echo "$as_me:13374: \$? = $ac_status" >&5
13375 (exit $ac_status); } &&
13376 { ac_try='test -s conftest.$ac_objext'
13377 { (eval echo "$as_me:13377: \"$ac_try\"") >&5
13378 (eval $ac_try) 2>&5
13380 echo "$as_me:13380: \$? = $ac_status" >&5
13381 (exit $ac_status); }; }; then
13384 echo "$as_me: failed program was:" >&5
13385 cat conftest.$ac_ext >&5
13388 rm -f conftest.$ac_objext conftest.$ac_ext
13390 echo "$as_me:13390: result: $ac_cv_c_const" >&5
13391 echo "${ECHO_T}$ac_cv_c_const" >&6
13392 if test $ac_cv_c_const = no; then
13394 cat >>confdefs.h <<\EOF
13400 ### Checks for external-data
13402 echo "$as_me:13402: checking if data-only library module links" >&5
13403 echo $ECHO_N "checking if data-only library module links... $ECHO_C" >&6
13404 if test "${cf_cv_link_dataonly+set}" = set; then
13405 echo $ECHO_N "(cached) $ECHO_C" >&6
13409 cat >conftest.$ac_ext <<EOF
13410 #line 13410 "configure"
13411 int testdata[3] = { 123, 456, 789 };
13413 if { (eval echo "$as_me:13413: \"$ac_compile\"") >&5
13414 (eval $ac_compile) 2>&5
13416 echo "$as_me:13416: \$? = $ac_status" >&5
13417 (exit $ac_status); } ; then
13418 mv conftest.o data.o && \
13419 ( $AR $ARFLAGS conftest.a data.o ) 2>&5 1>/dev/null
13421 rm -f conftest.$ac_ext data.o
13422 cat >conftest.$ac_ext <<EOF
13423 #line 13423 "configure"
13427 ${cf_cv_main_return:-return}(1); /* I'm told this linker is broken */
13429 extern int testdata[3];
13430 return testdata[0] == 123
13431 && testdata[1] == 456
13432 && testdata[2] == 789;
13436 if { (eval echo "$as_me:13436: \"$ac_compile\"") >&5
13437 (eval $ac_compile) 2>&5
13439 echo "$as_me:13439: \$? = $ac_status" >&5
13440 (exit $ac_status); }; then
13441 mv conftest.o func.o && \
13442 ( $AR $ARFLAGS conftest.a func.o ) 2>&5 1>/dev/null
13444 rm -f conftest.$ac_ext func.o
13445 ( eval $RANLIB conftest.a ) 2>&5 >/dev/null
13446 cf_saveLIBS="$LIBS"
13447 LIBS="conftest.a $LIBS"
13448 if test "$cross_compiling" = yes; then
13449 cf_cv_link_dataonly=unknown
13451 cat >conftest.$ac_ext <<_ACEOF
13452 #line 13452 "configure"
13453 #include "confdefs.h"
13457 extern int testfunc();
13458 ${cf_cv_main_return:-return} (!testfunc());
13462 rm -f conftest$ac_exeext
13463 if { (eval echo "$as_me:13463: \"$ac_link\"") >&5
13464 (eval $ac_link) 2>&5
13466 echo "$as_me:13466: \$? = $ac_status" >&5
13467 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13468 { (eval echo "$as_me:13468: \"$ac_try\"") >&5
13469 (eval $ac_try) 2>&5
13471 echo "$as_me:13471: \$? = $ac_status" >&5
13472 (exit $ac_status); }; }; then
13473 cf_cv_link_dataonly=yes
13475 echo "$as_me: program exited with status $ac_status" >&5
13476 echo "$as_me: failed program was:" >&5
13477 cat conftest.$ac_ext >&5
13478 cf_cv_link_dataonly=no
13480 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13482 LIBS="$cf_saveLIBS"
13486 echo "$as_me:13486: result: $cf_cv_link_dataonly" >&5
13487 echo "${ECHO_T}$cf_cv_link_dataonly" >&6
13489 if test "$cf_cv_link_dataonly" = no ; then
13491 cat >>confdefs.h <<\EOF
13492 #define BROKEN_LINKER 1
13498 ### Checks for library functions.
13500 echo "$as_me:13500: checking for working mkstemp" >&5
13501 echo $ECHO_N "checking for working mkstemp... $ECHO_C" >&6
13502 if test "${cf_cv_func_mkstemp+set}" = set; then
13503 echo $ECHO_N "(cached) $ECHO_C" >&6
13507 if test "$cross_compiling" = yes; then
13508 cf_cv_func_mkstemp=maybe
13510 cat >conftest.$ac_ext <<_ACEOF
13511 #line 13511 "configure"
13512 #include "confdefs.h"
13514 #include <sys/types.h>
13515 #include <stdlib.h>
13517 #include <string.h>
13518 #include <sys/stat.h>
13521 char *tmpl = "conftestXXXXXX";
13529 for (n = 0; n < 2; ++n) {
13530 strcpy(name[n], tmpl);
13531 if ((fd = mkstemp(name[n])) >= 0) {
13532 if (!strcmp(name[n], tmpl)
13533 || stat(name[n], &sb) != 0
13534 || (sb.st_mode & S_IFMT) != S_IFREG
13535 || (sb.st_mode & 077) != 0) {
13542 && !strcmp(name[0], name[1]))
13544 ${cf_cv_main_return:-return}(result);
13548 rm -f conftest$ac_exeext
13549 if { (eval echo "$as_me:13549: \"$ac_link\"") >&5
13550 (eval $ac_link) 2>&5
13552 echo "$as_me:13552: \$? = $ac_status" >&5
13553 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13554 { (eval echo "$as_me:13554: \"$ac_try\"") >&5
13555 (eval $ac_try) 2>&5
13557 echo "$as_me:13557: \$? = $ac_status" >&5
13558 (exit $ac_status); }; }; then
13559 cf_cv_func_mkstemp=yes
13562 echo "$as_me: program exited with status $ac_status" >&5
13563 echo "$as_me: failed program was:" >&5
13564 cat conftest.$ac_ext >&5
13565 cf_cv_func_mkstemp=no
13568 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13572 echo "$as_me:13572: result: $cf_cv_func_mkstemp" >&5
13573 echo "${ECHO_T}$cf_cv_func_mkstemp" >&6
13574 if test "x$cf_cv_func_mkstemp" = xmaybe ; then
13575 echo "$as_me:13575: checking for mkstemp" >&5
13576 echo $ECHO_N "checking for mkstemp... $ECHO_C" >&6
13577 if test "${ac_cv_func_mkstemp+set}" = set; then
13578 echo $ECHO_N "(cached) $ECHO_C" >&6
13580 cat >conftest.$ac_ext <<_ACEOF
13581 #line 13581 "configure"
13582 #include "confdefs.h"
13583 /* System header to define __stub macros and hopefully few prototypes,
13584 which can conflict with char mkstemp (); below. */
13585 #include <assert.h>
13586 /* Override any gcc2 internal prototype to avoid an error. */
13590 /* We use char because int might match the return type of a gcc2
13591 builtin and then its argument prototype would still apply. */
13598 /* The GNU C library defines this for functions which it implements
13599 to always fail with ENOSYS. Some functions are actually named
13600 something starting with __ and the normal name is an alias. */
13601 #if defined (__stub_mkstemp) || defined (__stub___mkstemp)
13604 f = mkstemp; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
13611 rm -f conftest.$ac_objext conftest$ac_exeext
13612 if { (eval echo "$as_me:13612: \"$ac_link\"") >&5
13613 (eval $ac_link) 2>&5
13615 echo "$as_me:13615: \$? = $ac_status" >&5
13616 (exit $ac_status); } &&
13617 { ac_try='test -s conftest$ac_exeext'
13618 { (eval echo "$as_me:13618: \"$ac_try\"") >&5
13619 (eval $ac_try) 2>&5
13621 echo "$as_me:13621: \$? = $ac_status" >&5
13622 (exit $ac_status); }; }; then
13623 ac_cv_func_mkstemp=yes
13625 echo "$as_me: failed program was:" >&5
13626 cat conftest.$ac_ext >&5
13627 ac_cv_func_mkstemp=no
13629 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13631 echo "$as_me:13631: result: $ac_cv_func_mkstemp" >&5
13632 echo "${ECHO_T}$ac_cv_func_mkstemp" >&6
13635 if test "x$cf_cv_func_mkstemp" = xyes || test "x$ac_cv_func_mkstemp" = xyes ; then
13637 cat >>confdefs.h <<\EOF
13638 #define HAVE_MKSTEMP 1
13643 if test -z "$cf_user_CFLAGS" && test "$with_no_leaks" = no ; then
13644 CFLAGS=`echo ${CFLAGS} | sed -e 's%-g %%' -e 's%-g$%%'`
13645 CXXFLAGS=`echo ${CXXFLAGS} | sed -e 's%-g %%' -e 's%-g$%%'`
13649 if test "$cf_with_ada" != "no" ; then
13651 cf_ada_make=gnatmake
13652 # Extract the first word of "$cf_ada_make", so it can be a program name with args.
13653 set dummy $cf_ada_make; ac_word=$2
13654 echo "$as_me:13654: checking for $ac_word" >&5
13655 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
13656 if test "${ac_cv_prog_gnat_exists+set}" = set; then
13657 echo $ECHO_N "(cached) $ECHO_C" >&6
13659 if test -n "$gnat_exists"; then
13660 ac_cv_prog_gnat_exists="$gnat_exists" # Let the user override the test.
13662 ac_save_IFS=$IFS; IFS=$ac_path_separator
13664 for ac_dir in $ac_dummy; do
13666 test -z "$ac_dir" && ac_dir=.
13667 $as_executable_p "$ac_dir/$ac_word" || continue
13668 ac_cv_prog_gnat_exists="yes"
13669 echo "$as_me:13669: found $ac_dir/$ac_word" >&5
13673 test -z "$ac_cv_prog_gnat_exists" && ac_cv_prog_gnat_exists="no"
13676 gnat_exists=$ac_cv_prog_gnat_exists
13677 if test -n "$gnat_exists"; then
13678 echo "$as_me:13678: result: $gnat_exists" >&5
13679 echo "${ECHO_T}$gnat_exists" >&6
13681 echo "$as_me:13681: result: no" >&5
13682 echo "${ECHO_T}no" >&6
13685 if test "$ac_cv_prog_gnat_exists" = no; then
13687 cf_cv_prog_gnat_correct=no
13690 echo "$as_me:13690: checking for gnat version" >&5
13691 echo $ECHO_N "checking for gnat version... $ECHO_C" >&6
13692 cf_gnat_version=`${cf_ada_make:-gnatmake} -v 2>&1 | \
13693 grep '[0-9].[0-9][0-9]*' |\
13694 sed -e '2,$d' -e 's/[^0-9 \.]//g' -e 's/^[ ]*//' -e 's/ .*//'`
13695 echo "$as_me:13695: result: $cf_gnat_version" >&5
13696 echo "${ECHO_T}$cf_gnat_version" >&6
13698 case $cf_gnat_version in
13699 (3.1[1-9]*|3.[2-9]*|[4-9].*|20[0-9][0-9])
13700 cf_cv_prog_gnat_correct=yes
13703 { echo "$as_me:13703: WARNING: Unsupported GNAT version $cf_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&5
13704 echo "$as_me: WARNING: Unsupported GNAT version $cf_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&2;}
13705 cf_cv_prog_gnat_correct=no
13709 # Extract the first word of "m4", so it can be a program name with args.
13710 set dummy m4; ac_word=$2
13711 echo "$as_me:13711: checking for $ac_word" >&5
13712 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
13713 if test "${ac_cv_prog_M4_exists+set}" = set; then
13714 echo $ECHO_N "(cached) $ECHO_C" >&6
13716 if test -n "$M4_exists"; then
13717 ac_cv_prog_M4_exists="$M4_exists" # Let the user override the test.
13719 ac_save_IFS=$IFS; IFS=$ac_path_separator
13721 for ac_dir in $ac_dummy; do
13723 test -z "$ac_dir" && ac_dir=.
13724 $as_executable_p "$ac_dir/$ac_word" || continue
13725 ac_cv_prog_M4_exists="yes"
13726 echo "$as_me:13726: found $ac_dir/$ac_word" >&5
13730 test -z "$ac_cv_prog_M4_exists" && ac_cv_prog_M4_exists="no"
13733 M4_exists=$ac_cv_prog_M4_exists
13734 if test -n "$M4_exists"; then
13735 echo "$as_me:13735: result: $M4_exists" >&5
13736 echo "${ECHO_T}$M4_exists" >&6
13738 echo "$as_me:13738: result: no" >&5
13739 echo "${ECHO_T}no" >&6
13742 if test "$ac_cv_prog_M4_exists" = no; then
13743 cf_cv_prog_gnat_correct=no
13744 echo Ada95 binding required program m4 not found. Ada95 binding disabled.
13746 if test "$cf_cv_prog_gnat_correct" = yes; then
13747 echo "$as_me:13747: checking if GNAT works" >&5
13748 echo $ECHO_N "checking if GNAT works... $ECHO_C" >&6
13750 rm -rf conftest* *~conftest*
13751 cat >>conftest.ads <<CF_EOF
13752 procedure conftest;
13754 cat >>conftest.adb <<CF_EOF
13757 procedure conftest is
13759 Text_IO.Put ("Hello World");
13761 GNAT.OS_Lib.OS_Exit (0);
13764 if ( $cf_ada_make $ADAFLAGS conftest 1>&5 2>&1 ) ; then
13765 if ( ./conftest 1>&5 2>&1 ) ; then
13766 cf_cv_prog_gnat_correct=yes
13768 cf_cv_prog_gnat_correct=no
13771 cf_cv_prog_gnat_correct=no
13773 rm -rf conftest* *~conftest*
13775 echo "$as_me:13775: result: $cf_cv_prog_gnat_correct" >&5
13776 echo "${ECHO_T}$cf_cv_prog_gnat_correct" >&6
13780 if test "$cf_cv_prog_gnat_correct" = yes; then
13782 echo "$as_me:13782: checking optimization options for ADAFLAGS" >&5
13783 echo $ECHO_N "checking optimization options for ADAFLAGS... $ECHO_C" >&6
13787 ADAFLAGS="$ADAFLAGS -g"
13793 cf_O_flag=`echo "$CFLAGS" |sed -e 's/^.*-O/-O/' -e 's/[ ].*//'`
13795 ADAFLAGS="$ADAFLAGS $cf_O_flag"
13799 echo "$as_me:13799: result: $ADAFLAGS" >&5
13800 echo "${ECHO_T}$ADAFLAGS" >&6
13802 echo "$as_me:13802: checking if GNATPREP supports -T option" >&5
13803 echo $ECHO_N "checking if GNATPREP supports -T option... $ECHO_C" >&6
13804 if test "${cf_cv_gnatprep_opt_t+set}" = set; then
13805 echo $ECHO_N "(cached) $ECHO_C" >&6
13808 cf_cv_gnatprep_opt_t=no
13809 gnatprep -T 2>/dev/null >/dev/null && cf_cv_gnatprep_opt_t=yes
13812 echo "$as_me:13812: result: $cf_cv_gnatprep_opt_t" >&5
13813 echo "${ECHO_T}$cf_cv_gnatprep_opt_t" >&6
13814 test "$cf_cv_gnatprep_opt_t" = yes && GNATPREP_OPTS="-T $GNATPREP_OPTS"
13816 echo "$as_me:13816: checking if GNAT supports generics" >&5
13817 echo $ECHO_N "checking if GNAT supports generics... $ECHO_C" >&6
13818 case $cf_gnat_version in
13820 cf_gnat_generics=yes
13823 cf_gnat_generics=no
13826 echo "$as_me:13826: result: $cf_gnat_generics" >&5
13827 echo "${ECHO_T}$cf_gnat_generics" >&6
13829 if test "$cf_gnat_generics" = yes
13831 cf_compile_generics=generics
13832 cf_generic_objects="\${GENOBJS}"
13834 cf_compile_generics=
13835 cf_generic_objects=
13838 echo "$as_me:13838: checking if GNAT supports SIGINT" >&5
13839 echo $ECHO_N "checking if GNAT supports SIGINT... $ECHO_C" >&6
13840 if test "${cf_cv_gnat_sigint+set}" = set; then
13841 echo $ECHO_N "(cached) $ECHO_C" >&6
13844 rm -rf conftest* *~conftest*
13845 cat >>conftest.ads <<CF_EOF
13846 with Ada.Interrupts.Names;
13848 package ConfTest is
13850 pragma Warnings (Off); -- the next pragma exists since 3.11p
13851 pragma Unreserve_All_Interrupts;
13852 pragma Warnings (On);
13854 protected Process is
13856 function Continue return Boolean;
13857 pragma Attach_Handler (Stop, Ada.Interrupts.Names.SIGINT);
13859 Done : Boolean := False;
13864 cat >>conftest.adb <<CF_EOF
13865 package body ConfTest is
13866 protected body Process is
13871 function Continue return Boolean is
13878 if ( $cf_ada_make $ADAFLAGS conftest 1>&5 2>&1 ) ; then
13879 cf_cv_gnat_sigint=yes
13881 cf_cv_gnat_sigint=no
13883 rm -rf conftest* *~conftest*
13886 echo "$as_me:13886: result: $cf_cv_gnat_sigint" >&5
13887 echo "${ECHO_T}$cf_cv_gnat_sigint" >&6
13889 if test $cf_cv_gnat_sigint = yes ; then
13892 USE_GNAT_SIGINT="#"
13895 cf_gnat_libraries=no
13896 cf_gnat_projects=no
13898 if test "$enable_gnat_projects" != no ; then
13899 echo "$as_me:13899: checking if GNAT supports project files" >&5
13900 echo $ECHO_N "checking if GNAT supports project files... $ECHO_C" >&6
13901 case $cf_gnat_version in
13905 case $cf_cv_system_name in
13909 mkdir conftest.src conftest.bin conftest.lib
13911 rm -rf conftest* *~conftest*
13912 cat >>library.gpr <<CF_EOF
13914 Kind := External ("LIB_KIND");
13915 for Library_Name use "ConfTest";
13916 for Object_Dir use ".";
13917 for Library_ALI_Dir use External("LIBRARY_DIR");
13918 for Library_Version use External ("SONAME");
13919 for Library_Kind use Kind;
13920 for Library_Dir use External("BUILD_DIR");
13921 Source_Dir := External ("SOURCE_DIR");
13922 for Source_Dirs use (Source_Dir);
13925 cat >>confpackage.ads <<CF_EOF
13926 package ConfPackage is
13927 procedure conftest;
13930 cat >>confpackage.adb <<CF_EOF
13932 package body ConfPackage is
13933 procedure conftest is
13935 Text_IO.Put ("Hello World");
13940 if ( $cf_ada_make $ADAFLAGS \
13942 -XBUILD_DIR=`cd ../conftest.bin;pwd` \
13943 -XLIBRARY_DIR=`cd ../conftest.lib;pwd` \
13944 -XSOURCE_DIR=`pwd` \
13945 -XSONAME=libConfTest.so.1 \
13946 -XLIB_KIND=static 1>&5 2>&1 ) ; then
13947 cf_gnat_projects=yes
13950 if test -f conftest.lib/confpackage.ali
13952 cf_gnat_libraries=yes
13954 rm -rf conftest* *~conftest*
13959 echo "$as_me:13959: result: $cf_gnat_projects" >&5
13960 echo "${ECHO_T}$cf_gnat_projects" >&6
13961 fi # enable_gnat_projects
13963 if test $cf_gnat_projects = yes
13965 echo "$as_me:13965: checking if GNAT supports libraries" >&5
13966 echo $ECHO_N "checking if GNAT supports libraries... $ECHO_C" >&6
13967 echo "$as_me:13967: result: $cf_gnat_libraries" >&5
13968 echo "${ECHO_T}$cf_gnat_libraries" >&6
13971 if test "$cf_gnat_projects" = yes
13973 USE_OLD_MAKERULES="#"
13974 USE_GNAT_PROJECTS=""
13976 USE_OLD_MAKERULES=""
13977 USE_GNAT_PROJECTS="#"
13980 if test "$cf_gnat_libraries" = yes
13982 USE_GNAT_LIBRARIES=""
13984 USE_GNAT_LIBRARIES="#"
13987 echo "$as_me:13987: checking for ada-compiler" >&5
13988 echo $ECHO_N "checking for ada-compiler... $ECHO_C" >&6
13990 # Check whether --with-ada-compiler or --without-ada-compiler was given.
13991 if test "${with_ada_compiler+set}" = set; then
13992 withval="$with_ada_compiler"
13993 cf_ada_compiler=$withval
13995 cf_ada_compiler=gnatmake
13998 echo "$as_me:13998: result: $cf_ada_compiler" >&5
13999 echo "${ECHO_T}$cf_ada_compiler" >&6
14001 cf_ada_package=terminal_interface
14003 echo "$as_me:14003: checking for ada-include" >&5
14004 echo $ECHO_N "checking for ada-include... $ECHO_C" >&6
14006 # Check whether --with-ada-include or --without-ada-include was given.
14007 if test "${with_ada_include+set}" = set; then
14008 withval="$with_ada_include"
14011 withval="${ADA_INCLUDE:-$prefix/share/ada/adainclude}"
14012 fi; if test -n "$prefix/share/ada/adainclude" ; then
14014 if test "x$prefix" != xNONE; then
14015 cf_path_syntax="$prefix"
14017 cf_path_syntax="$ac_default_prefix"
14020 case ".$withval" in
14021 (.\$\(*\)*|.\'*\'*)
14025 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
14027 (.\${*prefix}*|.\${*dir}*)
14028 eval withval="$withval"
14029 case ".$withval" in
14031 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
14036 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
14039 { { echo "$as_me:14039: error: expected a pathname, not \"$withval\"" >&5
14040 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
14041 { (exit 1); exit 1; }; }
14046 eval ADA_INCLUDE="$withval"
14048 echo "$as_me:14048: result: $ADA_INCLUDE" >&5
14049 echo "${ECHO_T}$ADA_INCLUDE" >&6
14051 echo "$as_me:14051: checking for ada-objects" >&5
14052 echo $ECHO_N "checking for ada-objects... $ECHO_C" >&6
14054 # Check whether --with-ada-objects or --without-ada-objects was given.
14055 if test "${with_ada_objects+set}" = set; then
14056 withval="$with_ada_objects"
14059 withval="${ADA_OBJECTS:-$prefix/lib/ada/adalib}"
14060 fi; if test -n "$prefix/lib/ada/adalib" ; then
14062 if test "x$prefix" != xNONE; then
14063 cf_path_syntax="$prefix"
14065 cf_path_syntax="$ac_default_prefix"
14068 case ".$withval" in
14069 (.\$\(*\)*|.\'*\'*)
14073 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
14075 (.\${*prefix}*|.\${*dir}*)
14076 eval withval="$withval"
14077 case ".$withval" in
14079 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
14084 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
14087 { { echo "$as_me:14087: error: expected a pathname, not \"$withval\"" >&5
14088 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
14089 { (exit 1); exit 1; }; }
14094 eval ADA_OBJECTS="$withval"
14096 echo "$as_me:14096: result: $ADA_OBJECTS" >&5
14097 echo "${ECHO_T}$ADA_OBJECTS" >&6
14099 echo "$as_me:14099: checking if an Ada95 shared-library should be built" >&5
14100 echo $ECHO_N "checking if an Ada95 shared-library should be built... $ECHO_C" >&6
14102 # Check whether --with-ada-sharedlib or --without-ada-sharedlib was given.
14103 if test "${with_ada_sharedlib+set}" = set; then
14104 withval="$with_ada_sharedlib"
14105 with_ada_sharedlib=$withval
14107 with_ada_sharedlib=no
14109 echo "$as_me:14109: result: $with_ada_sharedlib" >&5
14110 echo "${ECHO_T}$with_ada_sharedlib" >&6
14112 ADA_SHAREDLIB='lib$(LIB_NAME).so.1'
14113 MAKE_ADA_SHAREDLIB="#"
14115 if test "x$with_ada_sharedlib" != xno
14117 MAKE_ADA_SHAREDLIB=
14118 if test "x$with_ada_sharedlib" != xyes
14120 ADA_SHAREDLIB="$with_ada_sharedlib"
14125 { { echo "$as_me:14125: error: No usable Ada compiler found" >&5
14126 echo "$as_me: error: No usable Ada compiler found" >&2;}
14127 { (exit 1); exit 1; }; }
14130 { { echo "$as_me:14130: error: The Ada compiler is needed for this package" >&5
14131 echo "$as_me: error: The Ada compiler is needed for this package" >&2;}
14132 { (exit 1); exit 1; }; }
14135 ################################################################################
14142 ### Construct the list of include-directories to be generated
14144 if test "$srcdir" != "."; then
14145 CPPFLAGS="-I\${srcdir}/../include $CPPFLAGS"
14147 CPPFLAGS="-I../include $CPPFLAGS"
14148 if test "$srcdir" != "."; then
14149 CPPFLAGS="-I\${srcdir} $CPPFLAGS"
14151 CPPFLAGS="-I. $CPPFLAGS"
14153 ACPPFLAGS="-I. -I../include -I../../include $ACPPFLAGS"
14154 if test "$srcdir" != "."; then
14155 ACPPFLAGS="-I\${srcdir}/../../include $ACPPFLAGS"
14157 if test "$GCC" != yes; then
14158 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
14159 elif test "$includedir" != "/usr/include"; then
14160 if test "$includedir" = '${prefix}/include' ; then
14161 if test x$prefix != x/usr ; then
14162 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
14165 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
14169 ### Build up pieces for makefile rules
14170 echo "$as_me:14170: checking default library suffix" >&5
14171 echo $ECHO_N "checking default library suffix... $ECHO_C" >&6
14173 case $DFT_LWR_MODEL in
14174 (libtool) DFT_ARG_SUFFIX='' ;;
14175 (normal) DFT_ARG_SUFFIX='' ;;
14176 (debug) DFT_ARG_SUFFIX='_g' ;;
14177 (profile) DFT_ARG_SUFFIX='_p' ;;
14178 (shared) DFT_ARG_SUFFIX='' ;;
14180 test -n "$LIB_SUFFIX" && DFT_ARG_SUFFIX="${LIB_SUFFIX}${DFT_ARG_SUFFIX}"
14181 echo "$as_me:14181: result: $DFT_ARG_SUFFIX" >&5
14182 echo "${ECHO_T}$DFT_ARG_SUFFIX" >&6
14184 echo "$as_me:14184: checking default library-dependency suffix" >&5
14185 echo $ECHO_N "checking default library-dependency suffix... $ECHO_C" >&6
14187 case X$DFT_LWR_MODEL in
14189 DFT_LIB_SUFFIX='.la'
14190 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14193 DFT_LIB_SUFFIX='_g.a'
14194 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14197 DFT_LIB_SUFFIX='_p.a'
14198 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14201 case $cf_cv_system_name in
14203 DFT_LIB_SUFFIX='.so'
14204 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14206 (cygwin*|msys*|mingw*)
14207 DFT_LIB_SUFFIX='.dll'
14208 DFT_DEP_SUFFIX='.dll.a'
14211 DFT_LIB_SUFFIX='.dylib'
14212 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14217 DFT_LIB_SUFFIX='.so'
14218 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14221 DFT_LIB_SUFFIX='.sl'
14222 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14227 DFT_LIB_SUFFIX='.so'
14228 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14233 DFT_LIB_SUFFIX='.a'
14234 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14237 if test -n "${LIB_SUFFIX}${EXTRA_SUFFIX}"
14239 DFT_LIB_SUFFIX="${LIB_SUFFIX}${EXTRA_SUFFIX}${DFT_LIB_SUFFIX}"
14240 DFT_DEP_SUFFIX="${LIB_SUFFIX}${EXTRA_SUFFIX}${DFT_DEP_SUFFIX}"
14242 echo "$as_me:14242: result: $DFT_DEP_SUFFIX" >&5
14243 echo "${ECHO_T}$DFT_DEP_SUFFIX" >&6
14245 echo "$as_me:14245: checking default object directory" >&5
14246 echo $ECHO_N "checking default object directory... $ECHO_C" >&6
14248 case $DFT_LWR_MODEL in
14249 (libtool) DFT_OBJ_SUBDIR='obj_lo' ;;
14250 (normal) DFT_OBJ_SUBDIR='objects' ;;
14251 (debug) DFT_OBJ_SUBDIR='obj_g' ;;
14252 (profile) DFT_OBJ_SUBDIR='obj_p' ;;
14254 case $cf_cv_system_name in
14256 DFT_OBJ_SUBDIR='objects' ;;
14258 DFT_OBJ_SUBDIR='obj_s' ;;
14261 echo "$as_me:14261: result: $DFT_OBJ_SUBDIR" >&5
14262 echo "${ECHO_T}$DFT_OBJ_SUBDIR" >&6
14264 ### Set up low-level terminfo dependencies for makefiles.
14266 if test "$DFT_LWR_MODEL" = shared ; then
14267 case $cf_cv_system_name in
14269 # "lib" files have ".dll.a" suffix, "cyg" files have ".dll"
14272 # "lib" files have ".dll.a" suffix, "msys-" files have ".dll"
14277 USE_CFG_SUFFIX=${DFT_ARG_SUFFIX}
14279 ### Construct the list of subdirectories for which we'll customize makefiles
14280 ### with the appropriate compile-rules.
14282 SUB_MAKEFILES="gen/adacurses${USE_ARG_SUFFIX}-config:gen/adacurses-config.in"
14284 cat >>confdefs.h <<EOF
14285 #define NCURSES_PATHSEP '$PATH_SEPARATOR'
14288 ### Now that we're done running tests, add the compiler-warnings, if any
14293 cf_new_extra_cppflags=
14295 for cf_add_cflags in $EXTRA_CFLAGS
14297 case $cf_fix_cppflags in
14299 case $cf_add_cflags in
14300 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14301 case $cf_add_cflags in
14303 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14305 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14306 && test -z "${cf_tst_cflags}" \
14307 && cf_fix_cppflags=yes
14309 if test $cf_fix_cppflags = yes ; then
14310 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
14312 elif test "${cf_tst_cflags}" = "\"'" ; then
14313 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
14318 case "$CPPFLAGS" in
14322 case $cf_add_cflags in
14324 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14326 CPPFLAGS=`echo "$CPPFLAGS" | \
14327 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14328 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14332 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
14337 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
14342 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
14344 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14346 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14347 && test -z "${cf_tst_cflags}" \
14348 && cf_fix_cppflags=no
14353 if test -n "$cf_new_cflags" ; then
14355 CFLAGS="$CFLAGS $cf_new_cflags"
14358 if test -n "$cf_new_cppflags" ; then
14360 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
14363 if test -n "$cf_new_extra_cppflags" ; then
14365 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
14368 ################################################################################
14374 NCURSES_SHLIB2="sh -c"
14376 ADA_SUBDIRS="include gen src doc"
14377 if test "x$cf_with_tests" != "xno" ; then
14378 ADA_SUBDIRS="$ADA_SUBDIRS samples"
14380 for cf_dir in $ADA_SUBDIRS
14382 SUB_MAKEFILES="$SUB_MAKEFILES $cf_dir/Makefile"
14389 # match layout used by make-tar.sh
14390 ADAHTML_DIR=../doc/ada
14392 if test "x$cross_compiling" = xyes ; then
14393 ADAGEN_LDFLAGS='$(CROSS_LDFLAGS)'
14395 ADAGEN_LDFLAGS='$(NATIVE_LDFLAGS)'
14398 ac_config_files="$ac_config_files $SUB_MAKEFILES doc/adacurses${DFT_ARG_SUFFIX}-config.1:doc/MKada_config.in Makefile"
14399 ac_config_commands="$ac_config_commands default"
14400 cat >confcache <<\_ACEOF
14401 # This file is a shell script that caches the results of configure
14402 # tests run on this system so they can be shared between configure
14403 # scripts and configure runs, see configure's option --config-cache.
14404 # It is not useful on other systems. If it contains results you don't
14405 # want to keep, you may remove or edit it.
14407 # config.status only pays attention to the cache file if you give it
14408 # the --recheck option to rerun configure.
14410 # `ac_cv_env_foo' variables (set or unset) will be overriden when
14411 # loading this file, other *unset* `ac_cv_foo' will be assigned the
14412 # following values.
14416 # The following way of writing the cache mishandles newlines in values,
14417 # but we know of no workaround that is simple, portable, and efficient.
14418 # So, don't put newlines in cache variables' values.
14419 # Ultrix sh set writes to stderr and can't be redirected directly,
14420 # and sets the high bit in the cache file unless we assign to the vars.
14423 case `(ac_space=' '; set | grep ac_space) 2>&1` in
14425 # `set' does not quote correctly, so add quotes (double-quote
14426 # substitution turns \\\\ into \\, and sed turns \\ into \).
14429 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
14432 # `set' quotes correctly as required by POSIX, so do not add quotes.
14434 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
14441 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
14443 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
14445 if cmp -s $cache_file confcache; then :; else
14446 if test -w $cache_file; then
14447 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
14448 cat confcache >$cache_file
14450 echo "not updating unwritable cache $cache_file"
14455 test "x$prefix" = xNONE && prefix=$ac_default_prefix
14456 # Let make expand exec_prefix.
14457 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
14459 # VPATH may cause trouble with some makes, so we remove $(srcdir),
14460 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
14461 # trailing colons and then remove the whole line if VPATH becomes empty
14462 # (actually we leave an empty line to preserve line numbers).
14463 if test "x$srcdir" = x.; then
14464 ac_vpsub='/^[ ]*VPATH[ ]*=/{
14465 s/:*\$(srcdir):*/:/;
14466 s/:*\${srcdir}:*/:/;
14468 s/^\([^=]*=[ ]*\):*/\1/;
14474 DEFS=-DHAVE_CONFIG_H
14476 : ${CONFIG_STATUS=./config.status}
14477 ac_clean_files_save=$ac_clean_files
14478 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
14479 { echo "$as_me:14479: creating $CONFIG_STATUS" >&5
14480 echo "$as_me: creating $CONFIG_STATUS" >&6;}
14481 cat >$CONFIG_STATUS <<_ACEOF
14483 # Generated automatically by configure.
14484 # Run this file to recreate the current configuration.
14485 # Compiler output produced by configure, useful for debugging
14486 # configure, is in config.log if it exists.
14489 SHELL=\${CONFIG_SHELL-$SHELL}
14490 ac_cs_invocation="\$0 \$@"
14494 cat >>$CONFIG_STATUS <<\_ACEOF
14495 # Be Bourne compatible
14496 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
14499 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
14503 # Name of the executable.
14504 as_me=`echo "$0" |sed 's,.*[\\/],,'`
14506 if expr a : '\(a\)' >/dev/null 2>&1; then
14512 rm -f conf$$ conf$$.exe conf$$.file
14514 if ln -s conf$$.file conf$$ 2>/dev/null; then
14515 # We could just check for DJGPP; but this test a) works b) is more generic
14516 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
14517 if test -f conf$$.exe; then
14518 # Don't use ln at all; we don't have any links
14523 elif ln conf$$.file conf$$ 2>/dev/null; then
14528 rm -f conf$$ conf$$.exe conf$$.file
14530 as_executable_p="test -f"
14532 # Support unset when possible.
14533 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
14540 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
14541 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
14542 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
14543 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
14544 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
14545 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
14546 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
14547 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
14550 # We need space, tab and new line, in precisely that order.
14556 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
14562 # Files that config.status was made for.
14563 if test -n "$ac_config_files"; then
14564 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
14567 if test -n "$ac_config_headers"; then
14568 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
14571 if test -n "$ac_config_links"; then
14572 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
14575 if test -n "$ac_config_commands"; then
14576 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
14579 cat >>$CONFIG_STATUS <<\EOF
14582 \`$as_me' instantiates files from templates according to the
14583 current configuration.
14585 Usage: $0 [OPTIONS] [FILE]...
14587 -h, --help print this help, then exit
14588 -V, --version print version number, then exit
14589 -d, --debug don't remove temporary files
14590 --recheck update $as_me by reconfiguring in the same conditions
14591 --file=FILE[:TEMPLATE]
14592 instantiate the configuration file FILE
14593 --header=FILE[:TEMPLATE]
14594 instantiate the configuration header FILE
14596 Configuration files:
14599 Configuration headers:
14602 Configuration commands:
14605 Report bugs to <dickey@invisible-island.net>."
14608 cat >>$CONFIG_STATUS <<EOF
14611 configured by $0, generated by GNU Autoconf 2.52.20150926,
14612 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
14614 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
14615 Free Software Foundation, Inc.
14616 This config.status script is free software; the Free Software Foundation
14617 gives unlimited permission to copy, distribute and modify it."
14622 cat >>$CONFIG_STATUS <<\EOF
14623 # If no file are specified by the user, then we need to provide default
14624 # value. By we need to know if files were specified by the user.
14630 ac_option=`expr "x$1" : 'x\([^=]*\)='`
14631 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
14633 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
14637 *) # This is not an option, so the user has probably given explicit
14639 ac_need_defaults=false;;
14643 # Handling of the options.
14645 cat >>$CONFIG_STATUS <<EOF
14646 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
14647 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
14648 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
14650 cat >>$CONFIG_STATUS <<\EOF
14651 --version | --vers* | -V )
14652 echo "$ac_cs_version"; exit 0 ;;
14654 # Conflict between --help and --header
14655 { { echo "$as_me:14655: error: ambiguous option: $1
14656 Try \`$0 --help' for more information." >&5
14657 echo "$as_me: error: ambiguous option: $1
14658 Try \`$0 --help' for more information." >&2;}
14659 { (exit 1); exit 1; }; };;
14660 --help | --hel | -h )
14661 echo "$ac_cs_usage"; exit 0 ;;
14662 --debug | --d* | -d )
14664 --file | --fil | --fi | --f )
14666 CONFIG_FILES="$CONFIG_FILES $1"
14667 ac_need_defaults=false;;
14668 --header | --heade | --head | --hea )
14670 CONFIG_HEADERS="$CONFIG_HEADERS $1"
14671 ac_need_defaults=false;;
14673 # This is an error.
14674 -*) { { echo "$as_me:14674: error: unrecognized option: $1
14675 Try \`$0 --help' for more information." >&5
14676 echo "$as_me: error: unrecognized option: $1
14677 Try \`$0 --help' for more information." >&2;}
14678 { (exit 1); exit 1; }; } ;;
14680 *) ac_config_targets="$ac_config_targets $1" ;;
14689 ## ----------------------- ##
14690 ## Running config.status. ##
14691 ## ----------------------- ##
14693 This file was extended by $as_me 2.52.20150926, executed with
14694 CONFIG_FILES = $CONFIG_FILES
14695 CONFIG_HEADERS = $CONFIG_HEADERS
14696 CONFIG_LINKS = $CONFIG_LINKS
14697 CONFIG_COMMANDS = $CONFIG_COMMANDS
14698 > $ac_cs_invocation
14699 on `(hostname || uname -n) 2>/dev/null | sed 1q`
14704 cat >>$CONFIG_STATUS <<EOF
14706 # INIT-COMMANDS section.
14709 ### Special initialization commands, used to pass information from the
14710 ### configuration-run into config.status
14713 DFT_ARG_SUFFIX="$DFT_ARG_SUFFIX"
14714 DFT_LWR_MODEL="$DFT_LWR_MODEL"
14715 LIB_NAME="$LIB_NAME"
14716 LIB_PREFIX="$LIB_PREFIX"
14717 LIB_SUFFIX="$LIB_SUFFIX"
14719 NCURSES_MAJOR="$NCURSES_MAJOR"
14720 NCURSES_MINOR="$NCURSES_MINOR"
14721 NCURSES_PATCH="$NCURSES_PATCH"
14722 USE_OLD_MAKERULES="$USE_OLD_MAKERULES"
14723 cf_cv_abi_version="$cf_cv_abi_version"
14724 cf_cv_rel_version="$cf_cv_rel_version"
14725 cf_cv_rm_so_locs="$cf_cv_rm_so_locs"
14726 cf_cv_shared_soname='$cf_cv_shared_soname'
14727 cf_cv_shlib_version="$cf_cv_shlib_version"
14728 cf_cv_shlib_version_infix="$cf_cv_shlib_version_infix"
14729 cf_cv_system_name="$cf_cv_system_name"
14735 cat >>$CONFIG_STATUS <<\EOF
14736 for ac_config_target in $ac_config_targets
14738 case "$ac_config_target" in
14739 # Handling of arguments.
14740 "$SUB_MAKEFILES" ) CONFIG_FILES="$CONFIG_FILES $SUB_MAKEFILES" ;;
14741 "doc/adacurses${DFT_ARG_SUFFIX}-config.1" ) CONFIG_FILES="$CONFIG_FILES doc/adacurses${DFT_ARG_SUFFIX}-config.1:doc/MKada_config.in" ;;
14742 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
14743 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
14744 "include/ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/ncurses_cfg.h:include/ncurses_cfg.hin" ;;
14745 *) { { echo "$as_me:14745: error: invalid argument: $ac_config_target" >&5
14746 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
14747 { (exit 1); exit 1; }; };;
14751 # If the user did not use the arguments to specify the items to instantiate,
14752 # then the envvar interface is used. Set only those that are not.
14753 # We use the long form for the default assignment because of an extremely
14754 # bizarre bug on SunOS 4.1.3.
14755 if $ac_need_defaults; then
14756 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
14757 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
14758 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
14761 # Create a temporary directory, and hook for its removal unless debugging.
14764 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
14765 trap '{ (exit 1); exit 1; }' 1 2 13 15
14768 # Create a (secure) tmp directory for tmp files.
14771 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
14772 test -n "$tmp" && test -d "$tmp"
14775 tmp=$TMPDIR/cs$$-$RANDOM
14776 (umask 077 && mkdir $tmp)
14779 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
14780 { (exit 1); exit 1; }
14785 cat >>$CONFIG_STATUS <<EOF
14788 # CONFIG_FILES section.
14791 # No need to generate the scripts if there are no CONFIG_FILES.
14792 # This happens for instance when ./config.status config.h
14793 if test -n "\$CONFIG_FILES"; then
14794 # Protect against being on the right side of a sed subst in config.status.
14795 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
14796 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
14797 s,@SHELL@,$SHELL,;t t
14798 s,@exec_prefix@,$exec_prefix,;t t
14799 s,@prefix@,$prefix,;t t
14800 s,@program_transform_name@,$program_transform_name,;t t
14801 s,@bindir@,$bindir,;t t
14802 s,@sbindir@,$sbindir,;t t
14803 s,@libexecdir@,$libexecdir,;t t
14804 s,@datarootdir@,$datarootdir,;t t
14805 s,@datadir@,$datadir,;t t
14806 s,@sysconfdir@,$sysconfdir,;t t
14807 s,@sharedstatedir@,$sharedstatedir,;t t
14808 s,@localstatedir@,$localstatedir,;t t
14809 s,@libdir@,$libdir,;t t
14810 s,@includedir@,$includedir,;t t
14811 s,@oldincludedir@,$oldincludedir,;t t
14812 s,@infodir@,$infodir,;t t
14813 s,@mandir@,$mandir,;t t
14814 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
14815 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
14816 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
14817 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
14818 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
14819 s,@build_alias@,$build_alias,;t t
14820 s,@host_alias@,$host_alias,;t t
14821 s,@target_alias@,$target_alias,;t t
14822 s,@ECHO_C@,$ECHO_C,;t t
14823 s,@ECHO_N@,$ECHO_N,;t t
14824 s,@ECHO_T@,$ECHO_T,;t t
14825 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
14826 s,@DEFS@,$DEFS,;t t
14827 s,@LIBS@,$LIBS,;t t
14828 s,@top_builddir@,$top_builddir,;t t
14829 s,@build@,$build,;t t
14830 s,@build_cpu@,$build_cpu,;t t
14831 s,@build_vendor@,$build_vendor,;t t
14832 s,@build_os@,$build_os,;t t
14833 s,@host@,$host,;t t
14834 s,@host_cpu@,$host_cpu,;t t
14835 s,@host_vendor@,$host_vendor,;t t
14836 s,@host_os@,$host_os,;t t
14837 s,@target@,$target,;t t
14838 s,@target_cpu@,$target_cpu,;t t
14839 s,@target_vendor@,$target_vendor,;t t
14840 s,@target_os@,$target_os,;t t
14842 s,@CFLAGS@,$CFLAGS,;t t
14843 s,@LDFLAGS@,$LDFLAGS,;t t
14844 s,@CPPFLAGS@,$CPPFLAGS,;t t
14845 s,@ac_ct_CC@,$ac_ct_CC,;t t
14846 s,@EXEEXT@,$EXEEXT,;t t
14847 s,@OBJEXT@,$OBJEXT,;t t
14848 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
14851 s,@EGREP@,$EGREP,;t t
14852 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
14853 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
14854 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
14855 s,@LN_S@,$LN_S,;t t
14856 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
14857 s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t
14858 s,@PKG_CONFIG_LIBDIR@,$PKG_CONFIG_LIBDIR,;t t
14859 s,@SET_MAKE@,$SET_MAKE,;t t
14860 s,@CTAGS@,$CTAGS,;t t
14861 s,@ETAGS@,$ETAGS,;t t
14862 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
14863 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
14864 s,@cf_cv_makeflags@,$cf_cv_makeflags,;t t
14865 s,@RANLIB@,$RANLIB,;t t
14866 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
14868 s,@ac_ct_LD@,$ac_ct_LD,;t t
14870 s,@ac_ct_AR@,$ac_ct_AR,;t t
14871 s,@ARFLAGS@,$ARFLAGS,;t t
14872 s,@DESTDIR@,$DESTDIR,;t t
14873 s,@BUILD_CC@,$BUILD_CC,;t t
14874 s,@BUILD_CPP@,$BUILD_CPP,;t t
14875 s,@BUILD_CFLAGS@,$BUILD_CFLAGS,;t t
14876 s,@BUILD_CPPFLAGS@,$BUILD_CPPFLAGS,;t t
14877 s,@BUILD_LDFLAGS@,$BUILD_LDFLAGS,;t t
14878 s,@BUILD_LIBS@,$BUILD_LIBS,;t t
14879 s,@BUILD_EXEEXT@,$BUILD_EXEEXT,;t t
14880 s,@BUILD_OBJEXT@,$BUILD_OBJEXT,;t t
14881 s,@DFT_LWR_MODEL@,$DFT_LWR_MODEL,;t t
14882 s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t
14883 s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
14884 s,@ac_ct_NCURSES_CONFIG@,$ac_ct_NCURSES_CONFIG,;t t
14885 s,@NCURSES_MAJOR@,$NCURSES_MAJOR,;t t
14886 s,@NCURSES_MINOR@,$NCURSES_MINOR,;t t
14887 s,@NCURSES_PATCH@,$NCURSES_PATCH,;t t
14888 s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t
14889 s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t
14890 s,@cf_cv_builtin_bool@,$cf_cv_builtin_bool,;t t
14891 s,@cf_cv_header_stdbool_h@,$cf_cv_header_stdbool_h,;t t
14892 s,@cf_cv_type_of_bool@,$cf_cv_type_of_bool,;t t
14893 s,@LIB_PREFIX@,$LIB_PREFIX,;t t
14894 s,@LIB_SUFFIX@,$LIB_SUFFIX,;t t
14895 s,@CC_G_OPT@,$CC_G_OPT,;t t
14896 s,@LD_MODEL@,$LD_MODEL,;t t
14897 s,@shlibdir@,$shlibdir,;t t
14898 s,@MAKE_DLLS@,$MAKE_DLLS,;t t
14899 s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t
14900 s,@LD_RPATH_OPT@,$LD_RPATH_OPT,;t t
14901 s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t
14902 s,@MK_SHARED_LIB@,$MK_SHARED_LIB,;t t
14903 s,@RM_SHARED_OPTS@,$RM_SHARED_OPTS,;t t
14904 s,@LINK_PROGS@,$LINK_PROGS,;t t
14905 s,@LINK_TESTS@,$LINK_TESTS,;t t
14906 s,@EXTRA_LDFLAGS@,$EXTRA_LDFLAGS,;t t
14907 s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
14908 s,@LOCAL_LDFLAGS2@,$LOCAL_LDFLAGS2,;t t
14909 s,@INSTALL_LIB@,$INSTALL_LIB,;t t
14910 s,@RPATH_LIST@,$RPATH_LIST,;t t
14911 s,@BROKEN_LINKER@,$BROKEN_LINKER,;t t
14912 s,@NCURSES_EXT_FUNCS@,$NCURSES_EXT_FUNCS,;t t
14913 s,@NCURSES_CONST@,$NCURSES_CONST,;t t
14914 s,@PTHREAD@,$PTHREAD,;t t
14915 s,@cf_cv_enable_reentrant@,$cf_cv_enable_reentrant,;t t
14916 s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
14917 s,@ECHO_LT@,$ECHO_LT,;t t
14918 s,@ECHO_LD@,$ECHO_LD,;t t
14919 s,@RULE_CC@,$RULE_CC,;t t
14920 s,@SHOW_CC@,$SHOW_CC,;t t
14921 s,@ECHO_CC@,$ECHO_CC,;t t
14922 s,@ADAFLAGS@,$ADAFLAGS,;t t
14923 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
14924 s,@ADA_TRACE@,$ADA_TRACE,;t t
14925 s,@gnat_exists@,$gnat_exists,;t t
14926 s,@M4_exists@,$M4_exists,;t t
14927 s,@cf_ada_make@,$cf_ada_make,;t t
14928 s,@GNATPREP_OPTS@,$GNATPREP_OPTS,;t t
14929 s,@cf_compile_generics@,$cf_compile_generics,;t t
14930 s,@cf_generic_objects@,$cf_generic_objects,;t t
14931 s,@USE_GNAT_SIGINT@,$USE_GNAT_SIGINT,;t t
14932 s,@USE_OLD_MAKERULES@,$USE_OLD_MAKERULES,;t t
14933 s,@USE_GNAT_PROJECTS@,$USE_GNAT_PROJECTS,;t t
14934 s,@USE_GNAT_LIBRARIES@,$USE_GNAT_LIBRARIES,;t t
14935 s,@cf_ada_compiler@,$cf_ada_compiler,;t t
14936 s,@cf_ada_package@,$cf_ada_package,;t t
14937 s,@ADA_INCLUDE@,$ADA_INCLUDE,;t t
14938 s,@ADA_OBJECTS@,$ADA_OBJECTS,;t t
14939 s,@ADA_SHAREDLIB@,$ADA_SHAREDLIB,;t t
14940 s,@MAKE_ADA_SHAREDLIB@,$MAKE_ADA_SHAREDLIB,;t t
14941 s,@TINFO_LDFLAGS2@,$TINFO_LDFLAGS2,;t t
14942 s,@TINFO_LIBS@,$TINFO_LIBS,;t t
14943 s,@ACPPFLAGS@,$ACPPFLAGS,;t t
14944 s,@DFT_ARG_SUFFIX@,$DFT_ARG_SUFFIX,;t t
14945 s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t
14946 s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t
14947 s,@USE_CFG_SUFFIX@,$USE_CFG_SUFFIX,;t t
14948 s,@TEST_ARG2@,$TEST_ARG2,;t t
14949 s,@TEST_LIBS2@,$TEST_LIBS2,;t t
14950 s,@NCURSES_SHLIB2@,$NCURSES_SHLIB2,;t t
14951 s,@ADA_SUBDIRS@,$ADA_SUBDIRS,;t t
14952 s,@NCURSES_TREE@,$NCURSES_TREE,;t t
14953 s,@EXTERNAL_TREE@,$EXTERNAL_TREE,;t t
14954 s,@ADAHTML_DIR@,$ADAHTML_DIR,;t t
14955 s,@ADAGEN_LDFLAGS@,$ADAGEN_LDFLAGS,;t t
14960 cat >>$CONFIG_STATUS <<\EOF
14961 # Split the substitutions into bite-sized pieces for seds with
14962 # small command number limits, like on Digital OSF/1 and HP-UX.
14963 ac_max_sed_lines=48
14964 ac_sed_frag=1 # Number of current file.
14965 ac_beg=1 # First line for current file.
14966 ac_end=$ac_max_sed_lines # Line after last line for current file.
14969 while $ac_more_lines; do
14970 if test $ac_beg -gt 1; then
14971 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
14973 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
14975 if test ! -s $tmp/subs.frag; then
14976 ac_more_lines=false
14978 # The purpose of the label and of the branching condition is to
14979 # speed up the sed processing (if there are no `@' at all, there
14980 # is no need to browse any of the substitutions).
14981 # These are the two extra sed commands mentioned above.
14983 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
14984 # It is possible to make a multiline substitution using escaped newlines.
14985 # Ensure that we do not split the substitution between script fragments.
14987 ac_END=`expr $ac_end + $ac_max_sed_lines`
14988 sed "1,${ac_BEG}d; ${ac_END}p; q" $tmp/subs.sed >$tmp/subs.next
14989 if test -s $tmp/subs.next; then
14990 grep '^s,@[^@,][^@,]*@,.*\\$' $tmp/subs.next >$tmp/subs.edit
14991 if test ! -s $tmp/subs.edit; then
14992 grep "^s,@[^@,][^@,]*@,.*,;t t$" $tmp/subs.next >$tmp/subs.edit
14993 if test ! -s $tmp/subs.edit; then
14994 if test $ac_beg -gt 1; then
14995 ac_end=`expr $ac_end - 1`
15002 if test -z "$ac_sed_cmds"; then
15003 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
15005 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
15007 ac_sed_frag=`expr $ac_sed_frag + 1`
15009 ac_end=`expr $ac_end + $ac_max_sed_lines`
15012 if test -z "$ac_sed_cmds"; then
15015 fi # test -n "$CONFIG_FILES"
15018 cat >>$CONFIG_STATUS <<\EOF
15019 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
15020 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
15022 - | *:- | *:-:* ) # input from stdin
15024 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15025 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15026 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15027 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15028 * ) ac_file_in=$ac_file.in ;;
15031 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
15032 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15033 X"$ac_file" : 'X\(//\)[^/]' \| \
15034 X"$ac_file" : 'X\(//\)$' \| \
15035 X"$ac_file" : 'X\(/\)' \| \
15036 . : '\(.\)' 2>/dev/null ||
15038 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
15039 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
15040 /^X\(\/\/\)$/{ s//\1/; q; }
15041 /^X\(\/\).*/{ s//\1/; q; }
15043 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
15044 { case "$ac_dir" in
15045 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
15049 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
15050 case $as_mkdir_dir in
15051 # Skip DOS drivespec
15052 ?:) as_incr_dir=$as_mkdir_dir ;;
15054 as_incr_dir=$as_incr_dir/$as_mkdir_dir
15055 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
15060 ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
15061 # A "../" for each directory in $ac_dir_suffix.
15062 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
15064 ac_dir_suffix= ac_dots=
15069 if test -z "$ac_dots"; then
15072 ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
15074 [\\/]* | ?:[\\/]* )
15075 ac_srcdir=$srcdir$ac_dir_suffix;
15076 ac_top_srcdir=$srcdir ;;
15077 *) # Relative path.
15078 ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
15079 ac_top_srcdir=$ac_dots$srcdir ;;
15083 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
15084 *) ac_INSTALL=$ac_dots$INSTALL ;;
15087 if test x"$ac_file" != x-; then
15088 { echo "$as_me:15088: creating $ac_file" >&5
15089 echo "$as_me: creating $ac_file" >&6;}
15092 # Let's still pretend it is `configure' which instantiates (i.e., don't
15093 # use $as_me), people would be surprised to read:
15094 # /* config.h. Generated automatically by config.status. */
15095 configure_input="Generated automatically from `echo $ac_file_in |
15096 sed 's,.*/,,'` by configure."
15098 # First look for the input files in the build tree, otherwise in the
15100 ac_file_inputs=`IFS=:
15101 for f in $ac_file_in; do
15103 -) echo $tmp/stdin ;;
15105 # Absolute (can't be DOS-style, as IFS=:)
15106 test -f "$f" || { { echo "$as_me:15106: error: cannot find input file: $f" >&5
15107 echo "$as_me: error: cannot find input file: $f" >&2;}
15108 { (exit 1); exit 1; }; }
15111 if test -f "$f"; then
15114 elif test -f "$srcdir/$f"; then
15119 { { echo "$as_me:15119: error: cannot find input file: $f" >&5
15120 echo "$as_me: error: cannot find input file: $f" >&2;}
15121 { (exit 1); exit 1; }; }
15124 done` || { (exit 1); exit 1; }
15126 cat >>$CONFIG_STATUS <<\EOF
15127 ac_warn_datarootdir=no
15128 if test x"$ac_file" != x-; then
15129 for ac_item in $ac_file_inputs
15131 ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' $ac_item`
15132 if test -n "$ac_seen"; then
15133 ac_used=`grep '@datarootdir@' $ac_item`
15134 if test -z "$ac_used"; then
15135 { echo "$as_me:15135: WARNING: datarootdir was used implicitly but not set:
15137 echo "$as_me: WARNING: datarootdir was used implicitly but not set:
15139 ac_warn_datarootdir=yes
15142 ac_seen=`grep '${datarootdir}' $ac_item`
15143 if test -n "$ac_seen"; then
15144 { echo "$as_me:15144: WARNING: datarootdir was used explicitly but not set:
15146 echo "$as_me: WARNING: datarootdir was used explicitly but not set:
15148 ac_warn_datarootdir=yes
15153 if test "x$ac_warn_datarootdir" = xyes; then
15154 ac_sed_cmds="$ac_sed_cmds | sed -e 's,@datarootdir@,\${prefix}/share,g' -e 's,\${datarootdir},\${prefix}/share,g'"
15158 cat >>$CONFIG_STATUS <<EOF
15162 cat >>$CONFIG_STATUS <<\EOF
15164 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
15165 s,@configure_input@,$configure_input,;t t
15166 s,@srcdir@,$ac_srcdir,;t t
15167 s,@top_srcdir@,$ac_top_srcdir,;t t
15168 s,@INSTALL@,$ac_INSTALL,;t t
15169 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
15171 if test x"$ac_file" != x-; then
15172 cp $tmp/out $ac_file
15174 for ac_name in prefix exec_prefix datarootdir
15176 ac_seen=`fgrep -n '${'$ac_name'[:=].*}' $ac_file`
15177 if test -n "$ac_seen"; then
15178 ac_init=`egrep '[ ]*'$ac_name'[ ]*=' $ac_file`
15179 if test -z "$ac_init"; then
15180 ac_seen=`echo "$ac_seen" |sed -e 's,^,'$ac_file':,'`
15181 { echo "$as_me:15181: WARNING: Variable $ac_name is used but was not set:
15183 echo "$as_me: WARNING: Variable $ac_name is used but was not set:
15188 egrep -n '@[a-z_][a-z_0-9]+@' $ac_file >$tmp/out
15189 egrep -n '@[A-Z_][A-Z_0-9]+@' $ac_file >>$tmp/out
15190 if test -s $tmp/out; then
15191 ac_seen=`sed -e 's,^,'$ac_file':,' < $tmp/out`
15192 { echo "$as_me:15192: WARNING: Some variables may not be substituted:
15194 echo "$as_me: WARNING: Some variables may not be substituted:
15204 cat >>$CONFIG_STATUS <<\EOF
15207 # CONFIG_HEADER section.
15210 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
15211 # NAME is the cpp macro being defined and VALUE is the value it is being given.
15213 # ac_d sets the value in "#define NAME VALUE" lines.
15214 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
15215 ac_dB='[ ].*$,\1#\2'
15218 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
15219 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
15220 ac_iB='\([ ]\),\1#\2define\3'
15223 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
15224 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
15225 ac_uB='$,\1#\2define\3'
15229 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
15230 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
15232 - | *:- | *:-:* ) # input from stdin
15234 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15235 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15236 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15237 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15238 * ) ac_file_in=$ac_file.in ;;
15241 test x"$ac_file" != x- && { echo "$as_me:15241: creating $ac_file" >&5
15242 echo "$as_me: creating $ac_file" >&6;}
15244 # First look for the input files in the build tree, otherwise in the
15246 ac_file_inputs=`IFS=:
15247 for f in $ac_file_in; do
15249 -) echo $tmp/stdin ;;
15251 # Absolute (can't be DOS-style, as IFS=:)
15252 test -f "$f" || { { echo "$as_me:15252: error: cannot find input file: $f" >&5
15253 echo "$as_me: error: cannot find input file: $f" >&2;}
15254 { (exit 1); exit 1; }; }
15257 if test -f "$f"; then
15260 elif test -f "$srcdir/$f"; then
15265 { { echo "$as_me:15265: error: cannot find input file: $f" >&5
15266 echo "$as_me: error: cannot find input file: $f" >&2;}
15267 { (exit 1); exit 1; }; }
15270 done` || { (exit 1); exit 1; }
15271 # Remove the trailing spaces.
15272 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
15276 # Transform confdefs.h into a list of #define's. We won't use it as a sed
15277 # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to
15278 # be either 'cat' or 'sort'.
15279 cat confdefs.h | uniq >conftest.vals
15281 # Break up conftest.vals because some shells have a limit on
15282 # the size of here documents, and old seds have small limits too.
15284 rm -f conftest.tail
15285 echo ' rm -f conftest.frag' >> $CONFIG_STATUS
15286 while grep . conftest.vals >/dev/null
15288 # Write chunks of a limited-size here document to conftest.frag.
15289 echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS
15290 sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS
15291 echo 'CEOF' >> $CONFIG_STATUS
15292 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
15293 rm -f conftest.vals
15294 mv conftest.tail conftest.vals
15296 rm -f conftest.vals
15298 # Run sed to substitute the contents of conftest.frag into $tmp/in at the
15300 echo ' cat >> conftest.edit <<CEOF
15301 /@DEFS@/r conftest.frag
15304 sed -f conftest.edit $tmp/in > $tmp/out
15306 mv $tmp/out $tmp/in
15307 rm -f conftest.edit conftest.frag
15308 ' >> $CONFIG_STATUS
15310 cat >>$CONFIG_STATUS <<\EOF
15311 # Let's still pretend it is `configure' which instantiates (i.e., don't
15312 # use $as_me), people would be surprised to read:
15313 # /* config.h. Generated automatically by config.status. */
15314 if test x"$ac_file" = x-; then
15315 echo "/* Generated automatically by configure. */" >$tmp/config.h
15317 echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h
15319 cat $tmp/in >>$tmp/config.h
15321 if test x"$ac_file" != x-; then
15322 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
15323 { echo "$as_me:15323: $ac_file is unchanged" >&5
15324 echo "$as_me: $ac_file is unchanged" >&6;}
15326 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15327 X"$ac_file" : 'X\(//\)[^/]' \| \
15328 X"$ac_file" : 'X\(//\)$' \| \
15329 X"$ac_file" : 'X\(/\)' \| \
15330 . : '\(.\)' 2>/dev/null ||
15332 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
15333 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
15334 /^X\(\/\/\)$/{ s//\1/; q; }
15335 /^X\(\/\).*/{ s//\1/; q; }
15337 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
15338 { case "$ac_dir" in
15339 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
15343 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
15344 case $as_mkdir_dir in
15345 # Skip DOS drivespec
15346 ?:) as_incr_dir=$as_mkdir_dir ;;
15348 as_incr_dir=$as_incr_dir/$as_mkdir_dir
15349 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
15356 mv $tmp/config.h $ac_file
15360 rm -f $tmp/config.h
15364 cat >>$CONFIG_STATUS <<\EOF
15366 # CONFIG_COMMANDS section.
15368 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
15369 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
15370 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
15374 if test -z "$USE_OLD_MAKERULES" ; then
15375 $AWK -f $srcdir/mk-1st.awk <$srcdir/src/modules >>src/Makefile
15382 cat >>$CONFIG_STATUS <<\EOF
15384 { (exit 0); exit 0; }
15386 chmod +x $CONFIG_STATUS
15387 ac_clean_files=$ac_clean_files_save
15389 # configure is writing to config.log, and then calls config.status.
15390 # config.status does its own redirection, appending to config.log.
15391 # Unfortunately, on DOS this fails, as config.log is still kept open
15392 # by configure, so config.status won't be able to write to it; its
15393 # output is simply discarded. So we exec the FD to /dev/null,
15394 # effectively closing config.log, so it can be properly (re)opened and
15395 # appended to by config.status. When coming back to configure, we
15396 # need to make the FD available again.
15397 if test "$no_create" != yes; then
15400 $SHELL $CONFIG_STATUS || ac_cs_success=false
15402 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
15403 # would make configure fail if this is the last instruction.
15404 $ac_cs_success || { (exit 1); exit 1; }
15406 ${MAKE:-make} preinstall