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
8948 (*) LIB_PREFIX='lib'
8951 cf_prefix=$LIB_PREFIX
8953 elif test $with_lib_prefix = no
8957 LIB_PREFIX=$with_lib_prefix
8962 ###############################################################################
8964 if test X"$CC_G_OPT" = X"" ; then
8966 test -n "$GCC" && test "${ac_cv_prog_cc_g}" != yes && CC_G_OPT=''
8969 echo "$as_me:8969: checking for default loader flags" >&5
8970 echo $ECHO_N "checking for default loader flags... $ECHO_C" >&6
8971 case $DFT_LWR_MODEL in
8972 (normal) LD_MODEL='' ;;
8973 (debug) LD_MODEL=$CC_G_OPT ;;
8974 (profile) LD_MODEL='-pg';;
8975 (shared) LD_MODEL='' ;;
8977 echo "$as_me:8977: result: $LD_MODEL" >&5
8978 echo "${ECHO_T}$LD_MODEL" >&6
8981 echo "$as_me:8981: checking for an rpath option" >&5
8982 echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6
8983 case $cf_cv_system_name in
8985 if test "$GCC" = yes; then
8986 LD_RPATH_OPT="-Wl,-rpath,"
8988 LD_RPATH_OPT="-rpath "
8991 (linux*|gnu*|k*bsd*-gnu)
8992 LD_RPATH_OPT="-Wl,-rpath,"
8994 (openbsd[2-9].*|mirbsd*)
8995 LD_RPATH_OPT="-Wl,-rpath,"
8997 (dragonfly*|freebsd*)
8998 LD_RPATH_OPT="-rpath "
9001 LD_RPATH_OPT="-Wl,-rpath,"
9004 LD_RPATH_OPT="-rpath "
9012 echo "$as_me:9012: result: $LD_RPATH_OPT" >&5
9013 echo "${ECHO_T}$LD_RPATH_OPT" >&6
9015 case "x$LD_RPATH_OPT" in
9017 echo "$as_me:9017: checking if we need a space after rpath option" >&5
9018 echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6
9019 cf_save_LIBS="$LIBS"
9021 cf_add_libs="${LD_RPATH_OPT}$libdir"
9022 # Filter out duplicates - this happens with badly-designed ".pc" files...
9023 for cf_add_1lib in $LIBS
9025 for cf_add_2lib in $cf_add_libs
9027 if test "x$cf_add_1lib" = "x$cf_add_2lib"
9033 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
9037 cat >conftest.$ac_ext <<_ACEOF
9038 #line 9038 "configure"
9039 #include "confdefs.h"
9049 rm -f conftest.$ac_objext conftest$ac_exeext
9050 if { (eval echo "$as_me:9050: \"$ac_link\"") >&5
9051 (eval $ac_link) 2>&5
9053 echo "$as_me:9053: \$? = $ac_status" >&5
9054 (exit $ac_status); } &&
9055 { ac_try='test -s conftest$ac_exeext'
9056 { (eval echo "$as_me:9056: \"$ac_try\"") >&5
9059 echo "$as_me:9059: \$? = $ac_status" >&5
9060 (exit $ac_status); }; }; then
9063 echo "$as_me: failed program was:" >&5
9064 cat conftest.$ac_ext >&5
9067 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9068 LIBS="$cf_save_LIBS"
9069 echo "$as_me:9069: result: $cf_rpath_space" >&5
9070 echo "${ECHO_T}$cf_rpath_space" >&6
9071 test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
9079 INSTALL_LIB="-m 644"
9080 : ${rel_builddir:=.}
9086 cf_cv_do_symlinks=no
9088 test "$cf_cv_enable_rpath" = yes && cf_ld_rpath_opt="$LD_RPATH_OPT"
9090 echo "$as_me:9090: checking if release/abi version should be used for shared libs" >&5
9091 echo $ECHO_N "checking if release/abi version should be used for shared libs... $ECHO_C" >&6
9093 # Check whether --with-shlib-version or --without-shlib-version was given.
9094 if test "${with_shlib_version+set}" = set; then
9095 withval="$with_shlib_version"
9096 test -z "$withval" && withval=auto
9099 cf_cv_shlib_version=auto
9102 cf_cv_shlib_version=$withval
9105 echo "$as_me:9105: result: $withval" >&5
9106 echo "${ECHO_T}$withval" >&6
9107 { { echo "$as_me:9107: error: option value must be one of: rel, abi, or auto" >&5
9108 echo "$as_me: error: option value must be one of: rel, abi, or auto" >&2;}
9109 { (exit 1); exit 1; }; }
9114 cf_cv_shlib_version=auto
9116 echo "$as_me:9116: result: $cf_cv_shlib_version" >&5
9117 echo "${ECHO_T}$cf_cv_shlib_version" >&6
9122 # Some less-capable ports of gcc support only -fpic
9124 if test "$GCC" = yes
9126 echo "$as_me:9126: checking which $CC option to use" >&5
9127 echo $ECHO_N "checking which $CC option to use... $ECHO_C" >&6
9128 cf_save_CFLAGS="$CFLAGS"
9129 for CC_SHARED_OPTS in -fPIC -fpic ''
9131 CFLAGS="$cf_save_CFLAGS $CC_SHARED_OPTS"
9132 cat >conftest.$ac_ext <<_ACEOF
9133 #line 9133 "configure"
9134 #include "confdefs.h"
9144 rm -f conftest.$ac_objext
9145 if { (eval echo "$as_me:9145: \"$ac_compile\"") >&5
9146 (eval $ac_compile) 2>&5
9148 echo "$as_me:9148: \$? = $ac_status" >&5
9149 (exit $ac_status); } &&
9150 { ac_try='test -s conftest.$ac_objext'
9151 { (eval echo "$as_me:9151: \"$ac_try\"") >&5
9154 echo "$as_me:9154: \$? = $ac_status" >&5
9155 (exit $ac_status); }; }; then
9158 echo "$as_me: failed program was:" >&5
9159 cat conftest.$ac_ext >&5
9161 rm -f conftest.$ac_objext conftest.$ac_ext
9163 echo "$as_me:9163: result: $CC_SHARED_OPTS" >&5
9164 echo "${ECHO_T}$CC_SHARED_OPTS" >&6
9165 CFLAGS="$cf_save_CFLAGS"
9168 cf_cv_shlib_version_infix=no
9170 case $cf_cv_system_name in
9171 (aix4.3-9*|aix[5-7]*)
9172 if test "$GCC" = yes; then
9173 CC_SHARED_OPTS='-Wl,-brtl'
9174 MK_SHARED_LIB='${CC} -shared -Wl,-brtl -Wl,-blibpath:${RPATH_LIST}:/usr/lib -o $@'
9176 CC_SHARED_OPTS='-brtl'
9177 # as well as '-qpic=large -G' or perhaps "-bM:SRE -bnoentry -bexpall"
9178 MK_SHARED_LIB='${CC} -G -Wl,-brtl -Wl,-blibpath:${RPATH_LIST}:/usr/lib -o $@'
9182 MK_SHARED_LIB='${CC} ${CFLAGS} -o $@ -Xlinker -soname=`basename $@` -nostart -e 0'
9186 MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}'
9187 RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a"
9188 cf_cv_shlib_version=cygdll
9189 cf_cv_shlib_version_infix=cygdll
9192 cat >mk_shared_lib.sh <<-CF_EOF
9195 IMPORT_LIB=\`echo "\$1" | sed -e 's/cyg/lib/' -e 's/[0-9]*\.dll$/.dll.a/'\`
9198 Linking shared library
9199 ** SHARED_LIB \$SHARED_LIB
9200 ** IMPORT_LIB \$IMPORT_LIB
9202 exec \$* -shared -Wl,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB}
9204 chmod +x mk_shared_lib.sh
9208 MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}'
9209 RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a"
9210 cf_cv_shlib_version=msysdll
9211 cf_cv_shlib_version_infix=msysdll
9214 cat >mk_shared_lib.sh <<-CF_EOF
9217 IMPORT_LIB=\`echo "\$1" | sed -e 's/msys-/lib/' -e 's/[0-9]*\.dll$/.dll.a/'\`
9220 Linking shared library
9221 ** SHARED_LIB \$SHARED_LIB
9222 ** IMPORT_LIB \$IMPORT_LIB
9224 exec \$* -shared -Wl,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB}
9226 chmod +x mk_shared_lib.sh
9229 cf_try_cflags="no-cpp-precomp"
9230 CC_SHARED_OPTS="-dynamic"
9231 MK_SHARED_LIB='${CC} ${CFLAGS} -dynamiclib -install_name ${libdir}/`basename $@` -compatibility_version ${ABI_VERSION} -current_version ${ABI_VERSION} -o $@'
9232 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=abi
9233 cf_cv_shlib_version_infix=yes
9234 echo "$as_me:9234: checking if ld -search_paths_first works" >&5
9235 echo $ECHO_N "checking if ld -search_paths_first works... $ECHO_C" >&6
9236 if test "${cf_cv_ldflags_search_paths_first+set}" = set; then
9237 echo $ECHO_N "(cached) $ECHO_C" >&6
9240 cf_save_LDFLAGS=$LDFLAGS
9241 LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
9242 cat >conftest.$ac_ext <<_ACEOF
9243 #line 9243 "configure"
9244 #include "confdefs.h"
9254 rm -f conftest.$ac_objext conftest$ac_exeext
9255 if { (eval echo "$as_me:9255: \"$ac_link\"") >&5
9256 (eval $ac_link) 2>&5
9258 echo "$as_me:9258: \$? = $ac_status" >&5
9259 (exit $ac_status); } &&
9260 { ac_try='test -s conftest$ac_exeext'
9261 { (eval echo "$as_me:9261: \"$ac_try\"") >&5
9264 echo "$as_me:9264: \$? = $ac_status" >&5
9265 (exit $ac_status); }; }; then
9266 cf_cv_ldflags_search_paths_first=yes
9268 echo "$as_me: failed program was:" >&5
9269 cat conftest.$ac_ext >&5
9270 cf_cv_ldflags_search_paths_first=no
9272 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9273 LDFLAGS=$cf_save_LDFLAGS
9275 echo "$as_me:9275: result: $cf_cv_ldflags_search_paths_first" >&5
9276 echo "${ECHO_T}$cf_cv_ldflags_search_paths_first" >&6
9277 if test $cf_cv_ldflags_search_paths_first = yes; then
9278 LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
9282 # HP-UX 8.07 ld lacks "+b" option used for libdir search-list
9283 if test "$GCC" != yes; then
9286 MK_SHARED_LIB='${LD} -b -o $@'
9287 INSTALL_LIB="-m 555"
9290 # (tested with gcc 2.7.2 -- I don't have c89)
9291 if test "$GCC" = yes; then
9292 LD_SHARED_OPTS='-Xlinker +b -Xlinker ${libdir}'
9295 LD_SHARED_OPTS='-Wl,+b,${libdir}'
9297 MK_SHARED_LIB='${LD} +b ${libdir} -b -o $@'
9298 # HP-UX shared libraries must be executable, and should be
9299 # readonly to exploit a quirk in the memory manager.
9300 INSTALL_LIB="-m 555"
9303 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9304 if test "$cf_cv_shlib_version" = rel; then
9305 cf_shared_soname='`basename .${REL_VERSION}`.${ABI_VERSION}'
9307 cf_shared_soname='`basename `'
9310 MK_SHARED_LIB='${CC} -shared -Wl,-rpath,${RPATH_LIST} -Wl,-h,'$cf_shared_soname' -o '
9313 if test "$cf_cv_enable_rpath" = yes ; then
9314 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9316 # tested with IRIX 5.2 and 'cc'.
9317 if test "$GCC" != yes; then
9318 CC_SHARED_OPTS='-KPIC'
9319 MK_SHARED_LIB='${CC} -shared -rdata_shared -soname `basename $@` -o $@'
9321 MK_SHARED_LIB='${CC} -shared -Wl,-soname,`basename $@` -o $@'
9323 cf_cv_rm_so_locs=yes
9325 (linux*|gnu*|k*bsd*-gnu)
9326 if test "$DFT_LWR_MODEL" = "shared" ; then
9327 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
9328 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9330 if test "$cf_cv_enable_rpath" = yes ; then
9331 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9334 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9335 if test "$cf_cv_shlib_version" = rel; then
9336 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9338 cf_cv_shared_soname='`basename $@`'
9341 MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
9344 cf_cv_shlib_version=mingw
9345 cf_cv_shlib_version_infix=mingw
9348 if test "$DFT_LWR_MODEL" = "shared" ; then
9349 LOCAL_LDFLAGS="-Wl,--enable-auto-import"
9350 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9351 EXTRA_LDFLAGS="-Wl,--enable-auto-import $EXTRA_LDFLAGS"
9354 MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}'
9355 RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a"
9356 cat >mk_shared_lib.sh <<-CF_EOF
9359 IMPORT_LIB=\`echo "\$1" | sed -e 's/[0-9]*\.dll$/.dll.a/'\`
9362 Linking shared library
9363 ** SHARED_LIB \$SHARED_LIB
9364 ** IMPORT_LIB \$IMPORT_LIB
9366 exec \$* -shared -Wl,--enable-auto-import,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB}
9368 chmod +x mk_shared_lib.sh
9370 (openbsd[2-9].*|mirbsd*)
9371 if test "$DFT_LWR_MODEL" = "shared" ; then
9372 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
9373 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9375 if test "$cf_cv_enable_rpath" = yes ; then
9376 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9378 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
9380 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9381 if test "$cf_cv_shlib_version" = rel; then
9382 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9384 cf_cv_shared_soname='`basename $@`'
9387 MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-Bshareable,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
9389 (nto-qnx*|openbsd*|freebsd[12].*)
9390 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
9391 MK_SHARED_LIB='${LD} -Bshareable -o $@'
9392 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9394 (dragonfly*|freebsd*)
9395 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
9396 if test "$DFT_LWR_MODEL" = "shared" && test "$cf_cv_enable_rpath" = yes ; then
9397 LOCAL_LDFLAGS="${cf_ld_rpath_opt}\$(LOCAL_LIBDIR)"
9398 LOCAL_LDFLAGS2="${cf_ld_rpath_opt}\${RPATH_LIST} $LOCAL_LDFLAGS"
9399 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9402 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9403 if test "$cf_cv_shlib_version" = rel; then
9404 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9406 cf_cv_shared_soname='`basename $@`'
9409 MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
9412 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
9413 if test "$DFT_LWR_MODEL" = "shared" && test "$cf_cv_enable_rpath" = yes ; then
9414 LOCAL_LDFLAGS="${cf_ld_rpath_opt}\$(LOCAL_LIBDIR)"
9415 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9416 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9417 if test "$cf_cv_shlib_version" = auto; then
9418 if test -f /usr/libexec/ld.elf_so; then
9419 cf_cv_shlib_version=abi
9421 cf_cv_shlib_version=rel
9425 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9426 if test "$cf_cv_shlib_version" = rel; then
9427 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9429 cf_cv_shared_soname='`basename $@`'
9432 MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname' -o $@'
9434 MK_SHARED_LIB='${CC} -Wl,-shared -Wl,-Bshareable -o $@'
9438 # tested with OSF/1 V3.2 and 'cc'
9439 # tested with OSF/1 V3.2 and gcc 2.6.3 (but the c++ demo didn't
9440 # link with shared libs).
9441 MK_SHARED_LIB='${LD} -set_version ${REL_VERSION}:${ABI_VERSION} -expect_unresolved "*" -shared -soname `basename $@`'
9444 MK_SHARED_LIB="${MK_SHARED_LIB} -msym"
9447 MK_SHARED_LIB="${MK_SHARED_LIB}"' -o $@'
9448 if test "$DFT_LWR_MODEL" = "shared" ; then
9449 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
9450 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9452 cf_cv_rm_so_locs=yes
9454 (sco3.2v5*) # also uw2* and UW7: hops 13-Apr-98
9455 # tested with osr5.0.5
9456 if test "$GCC" != yes; then
9457 CC_SHARED_OPTS='-belf -KPIC'
9459 MK_SHARED_LIB='${LD} -dy -G -h `basename $@ .${REL_VERSION}`.${ABI_VERSION} -o $@'
9460 if test "$cf_cv_enable_rpath" = yes ; then
9461 # only way is to set LD_RUN_PATH but no switch for it
9464 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9465 LINK_PROGS='LD_RUN_PATH=${libdir}'
9466 LINK_TESTS='Pwd=`pwd`;LD_RUN_PATH=`dirname $${Pwd}`/lib'
9469 # tested with SunOS 4.1.1 and gcc 2.7.0
9470 if test "$GCC" != yes; then
9471 CC_SHARED_OPTS='-KPIC'
9473 MK_SHARED_LIB='${LD} -assert pure-text -o $@'
9474 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9477 # tested with SunOS 5.5.1 (solaris 2.5.1) and gcc 2.7.2
9478 # tested with SunOS 5.10 (solaris 10) and gcc 3.4.3
9479 if test "$DFT_LWR_MODEL" = "shared" ; then
9480 LOCAL_LDFLAGS="-R \$(LOCAL_LIBDIR):\${libdir}"
9481 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9483 if test "$cf_cv_enable_rpath" = yes ; then
9484 EXTRA_LDFLAGS="-R \${libdir} $EXTRA_LDFLAGS"
9487 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9488 if test "$cf_cv_shlib_version" = rel; then
9489 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9491 cf_cv_shared_soname='`basename $@`'
9494 if test "$GCC" != yes; then
9495 cf_save_CFLAGS="$CFLAGS"
9496 for cf_shared_opts in -xcode=pic32 -xcode=pic13 -KPIC -Kpic -O
9498 CFLAGS="$cf_shared_opts $cf_save_CFLAGS"
9499 cat >conftest.$ac_ext <<_ACEOF
9500 #line 9500 "configure"
9501 #include "confdefs.h"
9511 rm -f conftest.$ac_objext
9512 if { (eval echo "$as_me:9512: \"$ac_compile\"") >&5
9513 (eval $ac_compile) 2>&5
9515 echo "$as_me:9515: \$? = $ac_status" >&5
9516 (exit $ac_status); } &&
9517 { ac_try='test -s conftest.$ac_objext'
9518 { (eval echo "$as_me:9518: \"$ac_try\"") >&5
9521 echo "$as_me:9521: \$? = $ac_status" >&5
9522 (exit $ac_status); }; }; then
9525 echo "$as_me: failed program was:" >&5
9526 cat conftest.$ac_ext >&5
9528 rm -f conftest.$ac_objext conftest.$ac_ext
9530 CFLAGS="$cf_save_CFLAGS"
9531 CC_SHARED_OPTS=$cf_shared_opts
9532 MK_SHARED_LIB='${CC} -dy -G -h '$cf_cv_shared_soname' -o $@'
9534 MK_SHARED_LIB='${CC} -shared -dy -G -h '$cf_cv_shared_soname' -o $@'
9537 (sysv5uw7*|unix_sv*)
9538 # tested with UnixWare 7.1.0 (gcc 2.95.2 and cc)
9539 if test "$GCC" != yes; then
9540 CC_SHARED_OPTS='-KPIC'
9542 MK_SHARED_LIB='${LD} -d y -G -o $@'
9545 CC_SHARED_OPTS='unknown'
9546 MK_SHARED_LIB='echo unknown'
9550 # This works if the last tokens in $MK_SHARED_LIB are the -o target.
9551 case "$cf_cv_shlib_version" in
9553 case "$MK_SHARED_LIB" in
9555 test "$cf_cv_do_symlinks" = no && cf_cv_do_symlinks=yes
9558 { echo "$as_me:9558: WARNING: ignored --with-shlib-version" >&5
9559 echo "$as_me: WARNING: ignored --with-shlib-version" >&2;}
9565 if test -n "$cf_try_cflags"
9567 cat > conftest.$ac_ext <<EOF
9568 #line 9568 "${as_me:-configure}"
9570 int main(int argc, char *argv[])
9573 return (argv[argc-1] == 0) ;
9576 cf_save_CFLAGS="$CFLAGS"
9577 for cf_opt in $cf_try_cflags
9579 CFLAGS="$cf_save_CFLAGS -$cf_opt"
9580 echo "$as_me:9580: checking if CFLAGS option -$cf_opt works" >&5
9581 echo $ECHO_N "checking if CFLAGS option -$cf_opt works... $ECHO_C" >&6
9582 if { (eval echo "$as_me:9582: \"$ac_compile\"") >&5
9583 (eval $ac_compile) 2>&5
9585 echo "$as_me:9585: \$? = $ac_status" >&5
9586 (exit $ac_status); }; then
9587 echo "$as_me:9587: result: yes" >&5
9588 echo "${ECHO_T}yes" >&6
9589 cf_save_CFLAGS="$CFLAGS"
9591 echo "$as_me:9591: result: no" >&5
9592 echo "${ECHO_T}no" >&6
9595 CFLAGS="$cf_save_CFLAGS"
9598 # RPATH_LIST is a colon-separated list of directories
9599 test -n "$cf_ld_rpath_opt" && MK_SHARED_LIB="$MK_SHARED_LIB $cf_ld_rpath_opt\${RPATH_LIST}"
9600 test -z "$RPATH_LIST" && RPATH_LIST="\${libdir}"
9602 test $cf_cv_rm_so_locs = yes && RM_SHARED_OPTS="$RM_SHARED_OPTS so_locations"
9604 test -n "$verbose" && echo " CC_SHARED_OPTS: $CC_SHARED_OPTS" 1>&6
9606 echo "${as_me:-configure}:9606: testing CC_SHARED_OPTS: $CC_SHARED_OPTS ..." 1>&5
9608 test -n "$verbose" && echo " MK_SHARED_LIB: $MK_SHARED_LIB" 1>&6
9610 echo "${as_me:-configure}:9610: testing MK_SHARED_LIB: $MK_SHARED_LIB ..." 1>&5
9612 # The test/sample programs in the original tree link using rpath option.
9613 # Make it optional for packagers.
9614 if test -n "$LOCAL_LDFLAGS"
9616 echo "$as_me:9616: checking if you want to link sample programs with rpath option" >&5
9617 echo $ECHO_N "checking if you want to link sample programs with rpath option... $ECHO_C" >&6
9619 # Check whether --enable-rpath-link or --disable-rpath-link was given.
9620 if test "${enable_rpath_link+set}" = set; then
9621 enableval="$enable_rpath_link"
9622 with_rpath_link=$enableval
9626 echo "$as_me:9626: result: $with_rpath_link" >&5
9627 echo "${ECHO_T}$with_rpath_link" >&6
9628 if test "$with_rpath_link" = no
9635 ###############################################################################
9637 ### use option --enable-broken-linker to force on use of broken-linker support
9638 echo "$as_me:9638: checking if you want broken-linker support code" >&5
9639 echo $ECHO_N "checking if you want broken-linker support code... $ECHO_C" >&6
9641 # Check whether --enable-broken_linker or --disable-broken_linker was given.
9642 if test "${enable_broken_linker+set}" = set; then
9643 enableval="$enable_broken_linker"
9644 with_broken_linker=$enableval
9646 with_broken_linker=${BROKEN_LINKER:-no}
9648 echo "$as_me:9648: result: $with_broken_linker" >&5
9649 echo "${ECHO_T}$with_broken_linker" >&6
9652 if test "$with_broken_linker" = yes ; then
9653 cat >>confdefs.h <<\EOF
9654 #define BROKEN_LINKER 1
9658 elif test "$DFT_LWR_MODEL" = shared ; then
9659 case $cf_cv_system_name in
9661 cat >>confdefs.h <<\EOF
9662 #define BROKEN_LINKER 1
9666 test -n "$verbose" && echo " cygwin linker is broken anyway" 1>&6
9668 echo "${as_me:-configure}:9668: testing cygwin linker is broken anyway ..." 1>&5
9674 # Check to define _XOPEN_SOURCE "automatically"
9677 cf_POSIX_C_SOURCE=199506L
9682 cf_xopen_source="-D_ALL_SOURCE"
9688 cf_xopen_source="-D_APPLE_C_SOURCE"
9691 cf_xopen_source="-D_DARWIN_C_SOURCE"
9694 (freebsd*|dragonfly*)
9695 # 5.x headers associate
9696 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
9697 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
9698 cf_POSIX_C_SOURCE=200112L
9700 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
9703 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
9706 cf_xopen_source="-D_HPUX_SOURCE"
9709 cf_xopen_source="-D_SGI_SOURCE"
9712 (linux*|gnu*|mint*|k*bsd*-gnu)
9714 echo "$as_me:9714: checking if we must define _GNU_SOURCE" >&5
9715 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
9716 if test "${cf_cv_gnu_source+set}" = set; then
9717 echo $ECHO_N "(cached) $ECHO_C" >&6
9720 cat >conftest.$ac_ext <<_ACEOF
9721 #line 9721 "configure"
9722 #include "confdefs.h"
9723 #include <sys/types.h>
9728 #ifndef _XOPEN_SOURCE
9735 rm -f conftest.$ac_objext
9736 if { (eval echo "$as_me:9736: \"$ac_compile\"") >&5
9737 (eval $ac_compile) 2>&5
9739 echo "$as_me:9739: \$? = $ac_status" >&5
9740 (exit $ac_status); } &&
9741 { ac_try='test -s conftest.$ac_objext'
9742 { (eval echo "$as_me:9742: \"$ac_try\"") >&5
9745 echo "$as_me:9745: \$? = $ac_status" >&5
9746 (exit $ac_status); }; }; then
9749 echo "$as_me: failed program was:" >&5
9750 cat conftest.$ac_ext >&5
9752 CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
9753 cat >conftest.$ac_ext <<_ACEOF
9754 #line 9754 "configure"
9755 #include "confdefs.h"
9756 #include <sys/types.h>
9761 #ifdef _XOPEN_SOURCE
9768 rm -f conftest.$ac_objext
9769 if { (eval echo "$as_me:9769: \"$ac_compile\"") >&5
9770 (eval $ac_compile) 2>&5
9772 echo "$as_me:9772: \$? = $ac_status" >&5
9773 (exit $ac_status); } &&
9774 { ac_try='test -s conftest.$ac_objext'
9775 { (eval echo "$as_me:9775: \"$ac_try\"") >&5
9778 echo "$as_me:9778: \$? = $ac_status" >&5
9779 (exit $ac_status); }; }; then
9782 echo "$as_me: failed program was:" >&5
9783 cat conftest.$ac_ext >&5
9784 cf_cv_gnu_source=yes
9786 rm -f conftest.$ac_objext conftest.$ac_ext
9790 rm -f conftest.$ac_objext conftest.$ac_ext
9793 echo "$as_me:9793: result: $cf_cv_gnu_source" >&5
9794 echo "${ECHO_T}$cf_cv_gnu_source" >&6
9795 test "$cf_cv_gnu_source" = yes && CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
9799 cf_xopen_source="-D_NETBSD_SOURCE" # POSIX.1-2001 features are ifdef'd with this...
9802 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
9805 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
9807 cf_save_CFLAGS="$CFLAGS"
9808 cf_save_CPPFLAGS="$CPPFLAGS"
9810 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
9811 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
9812 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
9814 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
9815 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
9816 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
9818 echo "$as_me:9818: checking if we should define _POSIX_C_SOURCE" >&5
9819 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
9820 if test "${cf_cv_posix_c_source+set}" = set; then
9821 echo $ECHO_N "(cached) $ECHO_C" >&6
9824 echo "${as_me:-configure}:9824: testing if the symbol is already defined go no further ..." 1>&5
9826 cat >conftest.$ac_ext <<_ACEOF
9827 #line 9827 "configure"
9828 #include "confdefs.h"
9829 #include <sys/types.h>
9834 #ifndef _POSIX_C_SOURCE
9841 rm -f conftest.$ac_objext
9842 if { (eval echo "$as_me:9842: \"$ac_compile\"") >&5
9843 (eval $ac_compile) 2>&5
9845 echo "$as_me:9845: \$? = $ac_status" >&5
9846 (exit $ac_status); } &&
9847 { ac_try='test -s conftest.$ac_objext'
9848 { (eval echo "$as_me:9848: \"$ac_try\"") >&5
9851 echo "$as_me:9851: \$? = $ac_status" >&5
9852 (exit $ac_status); }; }; then
9853 cf_cv_posix_c_source=no
9855 echo "$as_me: failed program was:" >&5
9856 cat conftest.$ac_ext >&5
9857 cf_want_posix_source=no
9858 case .$cf_POSIX_C_SOURCE in
9860 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
9863 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
9864 cf_want_posix_source=yes
9867 cf_want_posix_source=yes
9870 if test "$cf_want_posix_source" = yes ; then
9871 cat >conftest.$ac_ext <<_ACEOF
9872 #line 9872 "configure"
9873 #include "confdefs.h"
9874 #include <sys/types.h>
9879 #ifdef _POSIX_SOURCE
9886 rm -f conftest.$ac_objext
9887 if { (eval echo "$as_me:9887: \"$ac_compile\"") >&5
9888 (eval $ac_compile) 2>&5
9890 echo "$as_me:9890: \$? = $ac_status" >&5
9891 (exit $ac_status); } &&
9892 { ac_try='test -s conftest.$ac_objext'
9893 { (eval echo "$as_me:9893: \"$ac_try\"") >&5
9896 echo "$as_me:9896: \$? = $ac_status" >&5
9897 (exit $ac_status); }; }; then
9900 echo "$as_me: failed program was:" >&5
9901 cat conftest.$ac_ext >&5
9902 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
9904 rm -f conftest.$ac_objext conftest.$ac_ext
9907 echo "${as_me:-configure}:9907: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
9909 CFLAGS="$cf_trim_CFLAGS"
9910 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
9912 echo "${as_me:-configure}:9912: testing if the second compile does not leave our definition intact error ..." 1>&5
9914 cat >conftest.$ac_ext <<_ACEOF
9915 #line 9915 "configure"
9916 #include "confdefs.h"
9917 #include <sys/types.h>
9922 #ifndef _POSIX_C_SOURCE
9929 rm -f conftest.$ac_objext
9930 if { (eval echo "$as_me:9930: \"$ac_compile\"") >&5
9931 (eval $ac_compile) 2>&5
9933 echo "$as_me:9933: \$? = $ac_status" >&5
9934 (exit $ac_status); } &&
9935 { ac_try='test -s conftest.$ac_objext'
9936 { (eval echo "$as_me:9936: \"$ac_try\"") >&5
9939 echo "$as_me:9939: \$? = $ac_status" >&5
9940 (exit $ac_status); }; }; then
9943 echo "$as_me: failed program was:" >&5
9944 cat conftest.$ac_ext >&5
9945 cf_cv_posix_c_source=no
9947 rm -f conftest.$ac_objext conftest.$ac_ext
9948 CFLAGS="$cf_save_CFLAGS"
9949 CPPFLAGS="$cf_save_CPPFLAGS"
9952 rm -f conftest.$ac_objext conftest.$ac_ext
9955 echo "$as_me:9955: result: $cf_cv_posix_c_source" >&5
9956 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
9958 if test "$cf_cv_posix_c_source" != no ; then
9959 CFLAGS="$cf_trim_CFLAGS"
9960 CPPFLAGS="$cf_trim_CPPFLAGS"
9965 cf_new_extra_cppflags=
9967 for cf_add_cflags in $cf_cv_posix_c_source
9969 case $cf_fix_cppflags in
9971 case $cf_add_cflags in
9972 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
9973 case $cf_add_cflags in
9975 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
9977 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9978 && test -z "${cf_tst_cflags}" \
9979 && cf_fix_cppflags=yes
9981 if test $cf_fix_cppflags = yes ; then
9982 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
9984 elif test "${cf_tst_cflags}" = "\"'" ; then
9985 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
9994 case $cf_add_cflags in
9996 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
9998 CPPFLAGS=`echo "$CPPFLAGS" | \
9999 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10000 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10004 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10009 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10014 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10016 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10018 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10019 && test -z "${cf_tst_cflags}" \
10020 && cf_fix_cppflags=no
10025 if test -n "$cf_new_cflags" ; then
10027 CFLAGS="$CFLAGS $cf_new_cflags"
10030 if test -n "$cf_new_cppflags" ; then
10032 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10035 if test -n "$cf_new_extra_cppflags" ; then
10037 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10044 cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
10047 # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw
10048 cf_xopen_source="-D_BSD_SOURCE"
10049 cf_XOPEN_SOURCE=600
10052 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
10055 cf_xopen_source="-D_OSF_SOURCE"
10058 cf_xopen_source="-D_QNX_SOURCE"
10061 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
10064 cf_xopen_source="-D__EXTENSIONS__"
10065 cf_cv_xopen_source=broken
10067 (sysv4.2uw2.*) # Novell/SCO UnixWare 2.x (tested on 2.1.2)
10073 echo "$as_me:10073: checking if we should define _XOPEN_SOURCE" >&5
10074 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
10075 if test "${cf_cv_xopen_source+set}" = set; then
10076 echo $ECHO_N "(cached) $ECHO_C" >&6
10079 cat >conftest.$ac_ext <<_ACEOF
10080 #line 10080 "configure"
10081 #include "confdefs.h"
10083 #include <stdlib.h>
10084 #include <string.h>
10085 #include <sys/types.h>
10091 #ifndef _XOPEN_SOURCE
10098 rm -f conftest.$ac_objext
10099 if { (eval echo "$as_me:10099: \"$ac_compile\"") >&5
10100 (eval $ac_compile) 2>&5
10102 echo "$as_me:10102: \$? = $ac_status" >&5
10103 (exit $ac_status); } &&
10104 { ac_try='test -s conftest.$ac_objext'
10105 { (eval echo "$as_me:10105: \"$ac_try\"") >&5
10106 (eval $ac_try) 2>&5
10108 echo "$as_me:10108: \$? = $ac_status" >&5
10109 (exit $ac_status); }; }; then
10110 cf_cv_xopen_source=no
10112 echo "$as_me: failed program was:" >&5
10113 cat conftest.$ac_ext >&5
10114 cf_save="$CPPFLAGS"
10115 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
10116 cat >conftest.$ac_ext <<_ACEOF
10117 #line 10117 "configure"
10118 #include "confdefs.h"
10120 #include <stdlib.h>
10121 #include <string.h>
10122 #include <sys/types.h>
10128 #ifdef _XOPEN_SOURCE
10135 rm -f conftest.$ac_objext
10136 if { (eval echo "$as_me:10136: \"$ac_compile\"") >&5
10137 (eval $ac_compile) 2>&5
10139 echo "$as_me:10139: \$? = $ac_status" >&5
10140 (exit $ac_status); } &&
10141 { ac_try='test -s conftest.$ac_objext'
10142 { (eval echo "$as_me:10142: \"$ac_try\"") >&5
10143 (eval $ac_try) 2>&5
10145 echo "$as_me:10145: \$? = $ac_status" >&5
10146 (exit $ac_status); }; }; then
10147 cf_cv_xopen_source=no
10149 echo "$as_me: failed program was:" >&5
10150 cat conftest.$ac_ext >&5
10151 cf_cv_xopen_source=$cf_XOPEN_SOURCE
10153 rm -f conftest.$ac_objext conftest.$ac_ext
10154 CPPFLAGS="$cf_save"
10157 rm -f conftest.$ac_objext conftest.$ac_ext
10160 echo "$as_me:10160: result: $cf_cv_xopen_source" >&5
10161 echo "${ECHO_T}$cf_cv_xopen_source" >&6
10163 if test "$cf_cv_xopen_source" != no ; then
10165 CFLAGS=`echo "$CFLAGS" | \
10166 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10167 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
10169 CPPFLAGS=`echo "$CPPFLAGS" | \
10170 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10171 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
10173 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
10178 cf_new_extra_cppflags=
10180 for cf_add_cflags in $cf_temp_xopen_source
10182 case $cf_fix_cppflags in
10184 case $cf_add_cflags in
10185 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10186 case $cf_add_cflags in
10188 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10190 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10191 && test -z "${cf_tst_cflags}" \
10192 && cf_fix_cppflags=yes
10194 if test $cf_fix_cppflags = yes ; then
10195 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10197 elif test "${cf_tst_cflags}" = "\"'" ; then
10198 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10203 case "$CPPFLAGS" in
10207 case $cf_add_cflags in
10209 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10211 CPPFLAGS=`echo "$CPPFLAGS" | \
10212 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10213 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10217 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10222 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10227 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10229 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10231 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10232 && test -z "${cf_tst_cflags}" \
10233 && cf_fix_cppflags=no
10238 if test -n "$cf_new_cflags" ; then
10240 CFLAGS="$CFLAGS $cf_new_cflags"
10243 if test -n "$cf_new_cppflags" ; then
10245 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10248 if test -n "$cf_new_extra_cppflags" ; then
10250 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10255 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
10257 cf_save_CFLAGS="$CFLAGS"
10258 cf_save_CPPFLAGS="$CPPFLAGS"
10260 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
10261 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10262 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
10264 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
10265 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10266 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
10268 echo "$as_me:10268: checking if we should define _POSIX_C_SOURCE" >&5
10269 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
10270 if test "${cf_cv_posix_c_source+set}" = set; then
10271 echo $ECHO_N "(cached) $ECHO_C" >&6
10274 echo "${as_me:-configure}:10274: testing if the symbol is already defined go no further ..." 1>&5
10276 cat >conftest.$ac_ext <<_ACEOF
10277 #line 10277 "configure"
10278 #include "confdefs.h"
10279 #include <sys/types.h>
10284 #ifndef _POSIX_C_SOURCE
10291 rm -f conftest.$ac_objext
10292 if { (eval echo "$as_me:10292: \"$ac_compile\"") >&5
10293 (eval $ac_compile) 2>&5
10295 echo "$as_me:10295: \$? = $ac_status" >&5
10296 (exit $ac_status); } &&
10297 { ac_try='test -s conftest.$ac_objext'
10298 { (eval echo "$as_me:10298: \"$ac_try\"") >&5
10299 (eval $ac_try) 2>&5
10301 echo "$as_me:10301: \$? = $ac_status" >&5
10302 (exit $ac_status); }; }; then
10303 cf_cv_posix_c_source=no
10305 echo "$as_me: failed program was:" >&5
10306 cat conftest.$ac_ext >&5
10307 cf_want_posix_source=no
10308 case .$cf_POSIX_C_SOURCE in
10310 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
10313 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
10314 cf_want_posix_source=yes
10317 cf_want_posix_source=yes
10320 if test "$cf_want_posix_source" = yes ; then
10321 cat >conftest.$ac_ext <<_ACEOF
10322 #line 10322 "configure"
10323 #include "confdefs.h"
10324 #include <sys/types.h>
10329 #ifdef _POSIX_SOURCE
10336 rm -f conftest.$ac_objext
10337 if { (eval echo "$as_me:10337: \"$ac_compile\"") >&5
10338 (eval $ac_compile) 2>&5
10340 echo "$as_me:10340: \$? = $ac_status" >&5
10341 (exit $ac_status); } &&
10342 { ac_try='test -s conftest.$ac_objext'
10343 { (eval echo "$as_me:10343: \"$ac_try\"") >&5
10344 (eval $ac_try) 2>&5
10346 echo "$as_me:10346: \$? = $ac_status" >&5
10347 (exit $ac_status); }; }; then
10350 echo "$as_me: failed program was:" >&5
10351 cat conftest.$ac_ext >&5
10352 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
10354 rm -f conftest.$ac_objext conftest.$ac_ext
10357 echo "${as_me:-configure}:10357: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
10359 CFLAGS="$cf_trim_CFLAGS"
10360 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
10362 echo "${as_me:-configure}:10362: testing if the second compile does not leave our definition intact error ..." 1>&5
10364 cat >conftest.$ac_ext <<_ACEOF
10365 #line 10365 "configure"
10366 #include "confdefs.h"
10367 #include <sys/types.h>
10372 #ifndef _POSIX_C_SOURCE
10379 rm -f conftest.$ac_objext
10380 if { (eval echo "$as_me:10380: \"$ac_compile\"") >&5
10381 (eval $ac_compile) 2>&5
10383 echo "$as_me:10383: \$? = $ac_status" >&5
10384 (exit $ac_status); } &&
10385 { ac_try='test -s conftest.$ac_objext'
10386 { (eval echo "$as_me:10386: \"$ac_try\"") >&5
10387 (eval $ac_try) 2>&5
10389 echo "$as_me:10389: \$? = $ac_status" >&5
10390 (exit $ac_status); }; }; then
10393 echo "$as_me: failed program was:" >&5
10394 cat conftest.$ac_ext >&5
10395 cf_cv_posix_c_source=no
10397 rm -f conftest.$ac_objext conftest.$ac_ext
10398 CFLAGS="$cf_save_CFLAGS"
10399 CPPFLAGS="$cf_save_CPPFLAGS"
10402 rm -f conftest.$ac_objext conftest.$ac_ext
10405 echo "$as_me:10405: result: $cf_cv_posix_c_source" >&5
10406 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
10408 if test "$cf_cv_posix_c_source" != no ; then
10409 CFLAGS="$cf_trim_CFLAGS"
10410 CPPFLAGS="$cf_trim_CPPFLAGS"
10415 cf_new_extra_cppflags=
10417 for cf_add_cflags in $cf_cv_posix_c_source
10419 case $cf_fix_cppflags in
10421 case $cf_add_cflags in
10422 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10423 case $cf_add_cflags in
10425 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10427 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10428 && test -z "${cf_tst_cflags}" \
10429 && cf_fix_cppflags=yes
10431 if test $cf_fix_cppflags = yes ; then
10432 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10434 elif test "${cf_tst_cflags}" = "\"'" ; then
10435 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10440 case "$CPPFLAGS" in
10444 case $cf_add_cflags in
10446 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10448 CPPFLAGS=`echo "$CPPFLAGS" | \
10449 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10450 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10454 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10459 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10464 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10466 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10468 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10469 && test -z "${cf_tst_cflags}" \
10470 && cf_fix_cppflags=no
10475 if test -n "$cf_new_cflags" ; then
10477 CFLAGS="$CFLAGS $cf_new_cflags"
10480 if test -n "$cf_new_cppflags" ; then
10482 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10485 if test -n "$cf_new_extra_cppflags" ; then
10487 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10495 if test -n "$cf_xopen_source" ; then
10500 cf_new_extra_cppflags=
10502 for cf_add_cflags in $cf_xopen_source
10504 case $cf_fix_cppflags in
10506 case $cf_add_cflags in
10507 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10508 case $cf_add_cflags in
10510 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10512 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10513 && test -z "${cf_tst_cflags}" \
10514 && cf_fix_cppflags=yes
10516 if test $cf_fix_cppflags = yes ; then
10517 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10519 elif test "${cf_tst_cflags}" = "\"'" ; then
10520 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10525 case "$CPPFLAGS" in
10529 case $cf_add_cflags in
10531 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10533 CPPFLAGS=`echo "$CPPFLAGS" | \
10534 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10535 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10539 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10544 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10549 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10551 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10553 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10554 && test -z "${cf_tst_cflags}" \
10555 && cf_fix_cppflags=no
10560 if test -n "$cf_new_cflags" ; then
10561 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
10563 echo "${as_me:-configure}:10563: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
10565 CFLAGS="$CFLAGS $cf_new_cflags"
10568 if test -n "$cf_new_cppflags" ; then
10569 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
10571 echo "${as_me:-configure}:10571: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
10573 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10576 if test -n "$cf_new_extra_cppflags" ; then
10577 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
10579 echo "${as_me:-configure}:10579: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
10581 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10586 if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
10587 echo "$as_me:10587: checking if _XOPEN_SOURCE really is set" >&5
10588 echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
10589 cat >conftest.$ac_ext <<_ACEOF
10590 #line 10590 "configure"
10591 #include "confdefs.h"
10592 #include <stdlib.h>
10597 #ifndef _XOPEN_SOURCE
10604 rm -f conftest.$ac_objext
10605 if { (eval echo "$as_me:10605: \"$ac_compile\"") >&5
10606 (eval $ac_compile) 2>&5
10608 echo "$as_me:10608: \$? = $ac_status" >&5
10609 (exit $ac_status); } &&
10610 { ac_try='test -s conftest.$ac_objext'
10611 { (eval echo "$as_me:10611: \"$ac_try\"") >&5
10612 (eval $ac_try) 2>&5
10614 echo "$as_me:10614: \$? = $ac_status" >&5
10615 (exit $ac_status); }; }; then
10616 cf_XOPEN_SOURCE_set=yes
10618 echo "$as_me: failed program was:" >&5
10619 cat conftest.$ac_ext >&5
10620 cf_XOPEN_SOURCE_set=no
10622 rm -f conftest.$ac_objext conftest.$ac_ext
10623 echo "$as_me:10623: result: $cf_XOPEN_SOURCE_set" >&5
10624 echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
10625 if test $cf_XOPEN_SOURCE_set = yes
10627 cat >conftest.$ac_ext <<_ACEOF
10628 #line 10628 "configure"
10629 #include "confdefs.h"
10630 #include <stdlib.h>
10635 #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
10642 rm -f conftest.$ac_objext
10643 if { (eval echo "$as_me:10643: \"$ac_compile\"") >&5
10644 (eval $ac_compile) 2>&5
10646 echo "$as_me:10646: \$? = $ac_status" >&5
10647 (exit $ac_status); } &&
10648 { ac_try='test -s conftest.$ac_objext'
10649 { (eval echo "$as_me:10649: \"$ac_try\"") >&5
10650 (eval $ac_try) 2>&5
10652 echo "$as_me:10652: \$? = $ac_status" >&5
10653 (exit $ac_status); }; }; then
10654 cf_XOPEN_SOURCE_set_ok=yes
10656 echo "$as_me: failed program was:" >&5
10657 cat conftest.$ac_ext >&5
10658 cf_XOPEN_SOURCE_set_ok=no
10660 rm -f conftest.$ac_objext conftest.$ac_ext
10661 if test $cf_XOPEN_SOURCE_set_ok = no
10663 { echo "$as_me:10663: WARNING: _XOPEN_SOURCE is lower than requested" >&5
10664 echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
10668 echo "$as_me:10668: checking if we should define _XOPEN_SOURCE" >&5
10669 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
10670 if test "${cf_cv_xopen_source+set}" = set; then
10671 echo $ECHO_N "(cached) $ECHO_C" >&6
10674 cat >conftest.$ac_ext <<_ACEOF
10675 #line 10675 "configure"
10676 #include "confdefs.h"
10678 #include <stdlib.h>
10679 #include <string.h>
10680 #include <sys/types.h>
10686 #ifndef _XOPEN_SOURCE
10693 rm -f conftest.$ac_objext
10694 if { (eval echo "$as_me:10694: \"$ac_compile\"") >&5
10695 (eval $ac_compile) 2>&5
10697 echo "$as_me:10697: \$? = $ac_status" >&5
10698 (exit $ac_status); } &&
10699 { ac_try='test -s conftest.$ac_objext'
10700 { (eval echo "$as_me:10700: \"$ac_try\"") >&5
10701 (eval $ac_try) 2>&5
10703 echo "$as_me:10703: \$? = $ac_status" >&5
10704 (exit $ac_status); }; }; then
10705 cf_cv_xopen_source=no
10707 echo "$as_me: failed program was:" >&5
10708 cat conftest.$ac_ext >&5
10709 cf_save="$CPPFLAGS"
10710 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
10711 cat >conftest.$ac_ext <<_ACEOF
10712 #line 10712 "configure"
10713 #include "confdefs.h"
10715 #include <stdlib.h>
10716 #include <string.h>
10717 #include <sys/types.h>
10723 #ifdef _XOPEN_SOURCE
10730 rm -f conftest.$ac_objext
10731 if { (eval echo "$as_me:10731: \"$ac_compile\"") >&5
10732 (eval $ac_compile) 2>&5
10734 echo "$as_me:10734: \$? = $ac_status" >&5
10735 (exit $ac_status); } &&
10736 { ac_try='test -s conftest.$ac_objext'
10737 { (eval echo "$as_me:10737: \"$ac_try\"") >&5
10738 (eval $ac_try) 2>&5
10740 echo "$as_me:10740: \$? = $ac_status" >&5
10741 (exit $ac_status); }; }; then
10742 cf_cv_xopen_source=no
10744 echo "$as_me: failed program was:" >&5
10745 cat conftest.$ac_ext >&5
10746 cf_cv_xopen_source=$cf_XOPEN_SOURCE
10748 rm -f conftest.$ac_objext conftest.$ac_ext
10749 CPPFLAGS="$cf_save"
10752 rm -f conftest.$ac_objext conftest.$ac_ext
10755 echo "$as_me:10755: result: $cf_cv_xopen_source" >&5
10756 echo "${ECHO_T}$cf_cv_xopen_source" >&6
10758 if test "$cf_cv_xopen_source" != no ; then
10760 CFLAGS=`echo "$CFLAGS" | \
10761 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10762 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
10764 CPPFLAGS=`echo "$CPPFLAGS" | \
10765 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10766 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
10768 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
10773 cf_new_extra_cppflags=
10775 for cf_add_cflags in $cf_temp_xopen_source
10777 case $cf_fix_cppflags in
10779 case $cf_add_cflags in
10780 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10781 case $cf_add_cflags in
10783 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10785 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10786 && test -z "${cf_tst_cflags}" \
10787 && cf_fix_cppflags=yes
10789 if test $cf_fix_cppflags = yes ; then
10790 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10792 elif test "${cf_tst_cflags}" = "\"'" ; then
10793 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10798 case "$CPPFLAGS" in
10802 case $cf_add_cflags in
10804 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10806 CPPFLAGS=`echo "$CPPFLAGS" | \
10807 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10808 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10812 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10817 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10822 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10824 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10826 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10827 && test -z "${cf_tst_cflags}" \
10828 && cf_fix_cppflags=no
10833 if test -n "$cf_new_cflags" ; then
10835 CFLAGS="$CFLAGS $cf_new_cflags"
10838 if test -n "$cf_new_cppflags" ; then
10840 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10843 if test -n "$cf_new_extra_cppflags" ; then
10845 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10853 # Check whether --enable-largefile or --disable-largefile was given.
10854 if test "${enable_largefile+set}" = set; then
10855 enableval="$enable_largefile"
10858 if test "$enable_largefile" != no; then
10860 echo "$as_me:10860: checking for special C compiler options needed for large files" >&5
10861 echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
10862 if test "${ac_cv_sys_largefile_CC+set}" = set; then
10863 echo $ECHO_N "(cached) $ECHO_C" >&6
10865 ac_cv_sys_largefile_CC=no
10866 if test "$GCC" != yes; then
10869 # IRIX 6.2 and later do not support large files by default,
10870 # so use the C compiler's -n32 option if that helps.
10871 cat >conftest.$ac_ext <<_ACEOF
10872 #line 10872 "configure"
10873 #include "confdefs.h"
10874 #include <sys/types.h>
10875 /* Check that off_t can represent 2**63 - 1 correctly.
10876 We can't simply define LARGE_OFF_T to be 9223372036854775807,
10877 since some C++ compilers masquerading as C compilers
10878 incorrectly reject 9223372036854775807. */
10879 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
10880 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
10881 && LARGE_OFF_T % 2147483647 == 1)
10891 rm -f conftest.$ac_objext
10892 if { (eval echo "$as_me:10892: \"$ac_compile\"") >&5
10893 (eval $ac_compile) 2>&5
10895 echo "$as_me:10895: \$? = $ac_status" >&5
10896 (exit $ac_status); } &&
10897 { ac_try='test -s conftest.$ac_objext'
10898 { (eval echo "$as_me:10898: \"$ac_try\"") >&5
10899 (eval $ac_try) 2>&5
10901 echo "$as_me:10901: \$? = $ac_status" >&5
10902 (exit $ac_status); }; }; then
10905 echo "$as_me: failed program was:" >&5
10906 cat conftest.$ac_ext >&5
10908 rm -f conftest.$ac_objext
10910 rm -f conftest.$ac_objext
10911 if { (eval echo "$as_me:10911: \"$ac_compile\"") >&5
10912 (eval $ac_compile) 2>&5
10914 echo "$as_me:10914: \$? = $ac_status" >&5
10915 (exit $ac_status); } &&
10916 { ac_try='test -s conftest.$ac_objext'
10917 { (eval echo "$as_me:10917: \"$ac_try\"") >&5
10918 (eval $ac_try) 2>&5
10920 echo "$as_me:10920: \$? = $ac_status" >&5
10921 (exit $ac_status); }; }; then
10922 ac_cv_sys_largefile_CC=' -n32'; break
10924 echo "$as_me: failed program was:" >&5
10925 cat conftest.$ac_ext >&5
10927 rm -f conftest.$ac_objext
10931 rm -f conftest.$ac_ext
10934 echo "$as_me:10934: result: $ac_cv_sys_largefile_CC" >&5
10935 echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
10936 if test "$ac_cv_sys_largefile_CC" != no; then
10937 CC=$CC$ac_cv_sys_largefile_CC
10940 echo "$as_me:10940: checking for _FILE_OFFSET_BITS value needed for large files" >&5
10941 echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
10942 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
10943 echo $ECHO_N "(cached) $ECHO_C" >&6
10946 ac_cv_sys_file_offset_bits=no
10947 cat >conftest.$ac_ext <<_ACEOF
10948 #line 10948 "configure"
10949 #include "confdefs.h"
10950 #include <sys/types.h>
10951 /* Check that off_t can represent 2**63 - 1 correctly.
10952 We can't simply define LARGE_OFF_T to be 9223372036854775807,
10953 since some C++ compilers masquerading as C compilers
10954 incorrectly reject 9223372036854775807. */
10955 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
10956 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
10957 && LARGE_OFF_T % 2147483647 == 1)
10967 rm -f conftest.$ac_objext
10968 if { (eval echo "$as_me:10968: \"$ac_compile\"") >&5
10969 (eval $ac_compile) 2>&5
10971 echo "$as_me:10971: \$? = $ac_status" >&5
10972 (exit $ac_status); } &&
10973 { ac_try='test -s conftest.$ac_objext'
10974 { (eval echo "$as_me:10974: \"$ac_try\"") >&5
10975 (eval $ac_try) 2>&5
10977 echo "$as_me:10977: \$? = $ac_status" >&5
10978 (exit $ac_status); }; }; then
10981 echo "$as_me: failed program was:" >&5
10982 cat conftest.$ac_ext >&5
10984 rm -f conftest.$ac_objext conftest.$ac_ext
10985 cat >conftest.$ac_ext <<_ACEOF
10986 #line 10986 "configure"
10987 #include "confdefs.h"
10988 #define _FILE_OFFSET_BITS 64
10989 #include <sys/types.h>
10990 /* Check that off_t can represent 2**63 - 1 correctly.
10991 We can't simply define LARGE_OFF_T to be 9223372036854775807,
10992 since some C++ compilers masquerading as C compilers
10993 incorrectly reject 9223372036854775807. */
10994 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
10995 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
10996 && LARGE_OFF_T % 2147483647 == 1)
11006 rm -f conftest.$ac_objext
11007 if { (eval echo "$as_me:11007: \"$ac_compile\"") >&5
11008 (eval $ac_compile) 2>&5
11010 echo "$as_me:11010: \$? = $ac_status" >&5
11011 (exit $ac_status); } &&
11012 { ac_try='test -s conftest.$ac_objext'
11013 { (eval echo "$as_me:11013: \"$ac_try\"") >&5
11014 (eval $ac_try) 2>&5
11016 echo "$as_me:11016: \$? = $ac_status" >&5
11017 (exit $ac_status); }; }; then
11018 ac_cv_sys_file_offset_bits=64; break
11020 echo "$as_me: failed program was:" >&5
11021 cat conftest.$ac_ext >&5
11023 rm -f conftest.$ac_objext conftest.$ac_ext
11027 echo "$as_me:11027: result: $ac_cv_sys_file_offset_bits" >&5
11028 echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
11029 if test "$ac_cv_sys_file_offset_bits" != no; then
11031 cat >>confdefs.h <<EOF
11032 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
11037 echo "$as_me:11037: checking for _LARGE_FILES value needed for large files" >&5
11038 echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
11039 if test "${ac_cv_sys_large_files+set}" = set; then
11040 echo $ECHO_N "(cached) $ECHO_C" >&6
11043 ac_cv_sys_large_files=no
11044 cat >conftest.$ac_ext <<_ACEOF
11045 #line 11045 "configure"
11046 #include "confdefs.h"
11047 #include <sys/types.h>
11048 /* Check that off_t can represent 2**63 - 1 correctly.
11049 We can't simply define LARGE_OFF_T to be 9223372036854775807,
11050 since some C++ compilers masquerading as C compilers
11051 incorrectly reject 9223372036854775807. */
11052 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
11053 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
11054 && LARGE_OFF_T % 2147483647 == 1)
11064 rm -f conftest.$ac_objext
11065 if { (eval echo "$as_me:11065: \"$ac_compile\"") >&5
11066 (eval $ac_compile) 2>&5
11068 echo "$as_me:11068: \$? = $ac_status" >&5
11069 (exit $ac_status); } &&
11070 { ac_try='test -s conftest.$ac_objext'
11071 { (eval echo "$as_me:11071: \"$ac_try\"") >&5
11072 (eval $ac_try) 2>&5
11074 echo "$as_me:11074: \$? = $ac_status" >&5
11075 (exit $ac_status); }; }; then
11078 echo "$as_me: failed program was:" >&5
11079 cat conftest.$ac_ext >&5
11081 rm -f conftest.$ac_objext conftest.$ac_ext
11082 cat >conftest.$ac_ext <<_ACEOF
11083 #line 11083 "configure"
11084 #include "confdefs.h"
11085 #define _LARGE_FILES 1
11086 #include <sys/types.h>
11087 /* Check that off_t can represent 2**63 - 1 correctly.
11088 We can't simply define LARGE_OFF_T to be 9223372036854775807,
11089 since some C++ compilers masquerading as C compilers
11090 incorrectly reject 9223372036854775807. */
11091 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
11092 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
11093 && LARGE_OFF_T % 2147483647 == 1)
11103 rm -f conftest.$ac_objext
11104 if { (eval echo "$as_me:11104: \"$ac_compile\"") >&5
11105 (eval $ac_compile) 2>&5
11107 echo "$as_me:11107: \$? = $ac_status" >&5
11108 (exit $ac_status); } &&
11109 { ac_try='test -s conftest.$ac_objext'
11110 { (eval echo "$as_me:11110: \"$ac_try\"") >&5
11111 (eval $ac_try) 2>&5
11113 echo "$as_me:11113: \$? = $ac_status" >&5
11114 (exit $ac_status); }; }; then
11115 ac_cv_sys_large_files=1; break
11117 echo "$as_me: failed program was:" >&5
11118 cat conftest.$ac_ext >&5
11120 rm -f conftest.$ac_objext conftest.$ac_ext
11124 echo "$as_me:11124: result: $ac_cv_sys_large_files" >&5
11125 echo "${ECHO_T}$ac_cv_sys_large_files" >&6
11126 if test "$ac_cv_sys_large_files" != no; then
11128 cat >>confdefs.h <<EOF
11129 #define _LARGE_FILES $ac_cv_sys_large_files
11136 if test "$enable_largefile" != no ; then
11137 echo "$as_me:11137: checking for _LARGEFILE_SOURCE value needed for large files" >&5
11138 echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
11139 if test "${ac_cv_sys_largefile_source+set}" = set; then
11140 echo $ECHO_N "(cached) $ECHO_C" >&6
11143 ac_cv_sys_largefile_source=no
11144 cat >conftest.$ac_ext <<_ACEOF
11145 #line 11145 "configure"
11146 #include "confdefs.h"
11156 rm -f conftest.$ac_objext
11157 if { (eval echo "$as_me:11157: \"$ac_compile\"") >&5
11158 (eval $ac_compile) 2>&5
11160 echo "$as_me:11160: \$? = $ac_status" >&5
11161 (exit $ac_status); } &&
11162 { ac_try='test -s conftest.$ac_objext'
11163 { (eval echo "$as_me:11163: \"$ac_try\"") >&5
11164 (eval $ac_try) 2>&5
11166 echo "$as_me:11166: \$? = $ac_status" >&5
11167 (exit $ac_status); }; }; then
11170 echo "$as_me: failed program was:" >&5
11171 cat conftest.$ac_ext >&5
11173 rm -f conftest.$ac_objext conftest.$ac_ext
11174 cat >conftest.$ac_ext <<_ACEOF
11175 #line 11175 "configure"
11176 #include "confdefs.h"
11177 #define _LARGEFILE_SOURCE 1
11187 rm -f conftest.$ac_objext
11188 if { (eval echo "$as_me:11188: \"$ac_compile\"") >&5
11189 (eval $ac_compile) 2>&5
11191 echo "$as_me:11191: \$? = $ac_status" >&5
11192 (exit $ac_status); } &&
11193 { ac_try='test -s conftest.$ac_objext'
11194 { (eval echo "$as_me:11194: \"$ac_try\"") >&5
11195 (eval $ac_try) 2>&5
11197 echo "$as_me:11197: \$? = $ac_status" >&5
11198 (exit $ac_status); }; }; then
11199 ac_cv_sys_largefile_source=1; break
11201 echo "$as_me: failed program was:" >&5
11202 cat conftest.$ac_ext >&5
11204 rm -f conftest.$ac_objext conftest.$ac_ext
11208 echo "$as_me:11208: result: $ac_cv_sys_largefile_source" >&5
11209 echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
11210 if test "$ac_cv_sys_largefile_source" != no; then
11212 cat >>confdefs.h <<EOF
11213 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
11219 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
11220 # in glibc 2.1.3, but that breaks too many other things.
11221 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
11222 echo "$as_me:11222: checking for fseeko" >&5
11223 echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
11224 if test "${ac_cv_func_fseeko+set}" = set; then
11225 echo $ECHO_N "(cached) $ECHO_C" >&6
11227 cat >conftest.$ac_ext <<_ACEOF
11228 #line 11228 "configure"
11229 #include "confdefs.h"
11234 return fseeko && fseeko (stdin, 0, 0);
11239 rm -f conftest.$ac_objext conftest$ac_exeext
11240 if { (eval echo "$as_me:11240: \"$ac_link\"") >&5
11241 (eval $ac_link) 2>&5
11243 echo "$as_me:11243: \$? = $ac_status" >&5
11244 (exit $ac_status); } &&
11245 { ac_try='test -s conftest$ac_exeext'
11246 { (eval echo "$as_me:11246: \"$ac_try\"") >&5
11247 (eval $ac_try) 2>&5
11249 echo "$as_me:11249: \$? = $ac_status" >&5
11250 (exit $ac_status); }; }; then
11251 ac_cv_func_fseeko=yes
11253 echo "$as_me: failed program was:" >&5
11254 cat conftest.$ac_ext >&5
11255 ac_cv_func_fseeko=no
11257 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11259 echo "$as_me:11259: result: $ac_cv_func_fseeko" >&5
11260 echo "${ECHO_T}$ac_cv_func_fseeko" >&6
11261 if test $ac_cv_func_fseeko = yes; then
11263 cat >>confdefs.h <<\EOF
11264 #define HAVE_FSEEKO 1
11269 # Normally we would collect these definitions in the config.h,
11270 # but (like _XOPEN_SOURCE), some environments rely on having these
11271 # defined before any of the system headers are included. Another
11272 # case comes up with C++, e.g., on AIX the compiler compiles the
11273 # header files by themselves before looking at the body files it is
11274 # told to compile. For ncurses, those header files do not include
11276 test "$ac_cv_sys_large_files" != no && CPPFLAGS="$CPPFLAGS -D_LARGE_FILES "
11277 test "$ac_cv_sys_largefile_source" != no && CPPFLAGS="$CPPFLAGS -D_LARGEFILE_SOURCE "
11278 test "$ac_cv_sys_file_offset_bits" != no && CPPFLAGS="$CPPFLAGS -D_FILE_OFFSET_BITS=$ac_cv_sys_file_offset_bits "
11280 echo "$as_me:11280: checking whether to use struct dirent64" >&5
11281 echo $ECHO_N "checking whether to use struct dirent64... $ECHO_C" >&6
11282 if test "${cf_cv_struct_dirent64+set}" = set; then
11283 echo $ECHO_N "(cached) $ECHO_C" >&6
11286 cat >conftest.$ac_ext <<_ACEOF
11287 #line 11287 "configure"
11288 #include "confdefs.h"
11290 #include <sys/types.h>
11291 #include <dirent.h>
11297 /* if transitional largefile support is setup, this is true */
11298 extern struct dirent64 * readdir(DIR *);
11299 struct dirent64 *x = readdir((DIR *)0);
11300 struct dirent *y = readdir((DIR *)0);
11307 rm -f conftest.$ac_objext
11308 if { (eval echo "$as_me:11308: \"$ac_compile\"") >&5
11309 (eval $ac_compile) 2>&5
11311 echo "$as_me:11311: \$? = $ac_status" >&5
11312 (exit $ac_status); } &&
11313 { ac_try='test -s conftest.$ac_objext'
11314 { (eval echo "$as_me:11314: \"$ac_try\"") >&5
11315 (eval $ac_try) 2>&5
11317 echo "$as_me:11317: \$? = $ac_status" >&5
11318 (exit $ac_status); }; }; then
11319 cf_cv_struct_dirent64=yes
11321 echo "$as_me: failed program was:" >&5
11322 cat conftest.$ac_ext >&5
11323 cf_cv_struct_dirent64=no
11325 rm -f conftest.$ac_objext conftest.$ac_ext
11328 echo "$as_me:11328: result: $cf_cv_struct_dirent64" >&5
11329 echo "${ECHO_T}$cf_cv_struct_dirent64" >&6
11330 test "$cf_cv_struct_dirent64" = yes &&
11331 cat >>confdefs.h <<\EOF
11332 #define HAVE_STRUCT_DIRENT64 1
11337 ### Enable compiling-in rcs id's
11338 echo "$as_me:11338: checking if RCS identifiers should be compiled-in" >&5
11339 echo $ECHO_N "checking if RCS identifiers should be compiled-in... $ECHO_C" >&6
11341 # Check whether --with-rcs-ids or --without-rcs-ids was given.
11342 if test "${with_rcs_ids+set}" = set; then
11343 withval="$with_rcs_ids"
11344 with_rcs_ids=$withval
11348 echo "$as_me:11348: result: $with_rcs_ids" >&5
11349 echo "${ECHO_T}$with_rcs_ids" >&6
11350 test "$with_rcs_ids" = yes &&
11351 cat >>confdefs.h <<\EOF
11352 #define USE_RCS_IDS 1
11355 ###############################################################################
11357 ### Note that some functions (such as const) are normally disabled anyway.
11358 echo "$as_me:11358: checking if you want to build with function extensions" >&5
11359 echo $ECHO_N "checking if you want to build with function extensions... $ECHO_C" >&6
11361 # Check whether --enable-ext-funcs or --disable-ext-funcs was given.
11362 if test "${enable_ext_funcs+set}" = set; then
11363 enableval="$enable_ext_funcs"
11364 with_ext_funcs=$enableval
11368 echo "$as_me:11368: result: $with_ext_funcs" >&5
11369 echo "${ECHO_T}$with_ext_funcs" >&6
11370 if test "$with_ext_funcs" = yes ; then
11371 NCURSES_EXT_FUNCS=1
11373 cat >>confdefs.h <<\EOF
11374 #define HAVE_USE_DEFAULT_COLORS 1
11377 cat >>confdefs.h <<\EOF
11378 #define NCURSES_EXT_FUNCS 1
11382 NCURSES_EXT_FUNCS=0
11385 ### use option --enable-const to turn on use of const beyond that in XSI.
11386 echo "$as_me:11386: checking for extended use of const keyword" >&5
11387 echo $ECHO_N "checking for extended use of const keyword... $ECHO_C" >&6
11389 # Check whether --enable-const or --disable-const was given.
11390 if test "${enable_const+set}" = set; then
11391 enableval="$enable_const"
11392 with_ext_const=$enableval
11396 echo "$as_me:11396: result: $with_ext_const" >&5
11397 echo "${ECHO_T}$with_ext_const" >&6
11398 NCURSES_CONST='/*nothing*/'
11399 if test "$with_ext_const" = yes ; then
11400 NCURSES_CONST=const
11403 ###############################################################################
11404 # These options are relatively safe to experiment with.
11406 echo "$as_me:11406: checking if you want all development code" >&5
11407 echo $ECHO_N "checking if you want all development code... $ECHO_C" >&6
11409 # Check whether --with-develop or --without-develop was given.
11410 if test "${with_develop+set}" = set; then
11411 withval="$with_develop"
11412 with_develop=$withval
11416 echo "$as_me:11416: result: $with_develop" >&5
11417 echo "${ECHO_T}$with_develop" >&6
11419 ###############################################################################
11420 # These are just experimental, probably should not be in a package:
11422 # This is still experimental (20080329), but should ultimately be moved to
11423 # the script-block --with-normal, etc.
11425 echo "$as_me:11425: checking if you want to link with the pthread library" >&5
11426 echo $ECHO_N "checking if you want to link with the pthread library... $ECHO_C" >&6
11428 # Check whether --with-pthread or --without-pthread was given.
11429 if test "${with_pthread+set}" = set; then
11430 withval="$with_pthread"
11431 with_pthread=$withval
11435 echo "$as_me:11435: result: $with_pthread" >&5
11436 echo "${ECHO_T}$with_pthread" >&6
11438 if test "$with_pthread" != no ; then
11439 echo "$as_me:11439: checking for pthread.h" >&5
11440 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
11441 if test "${ac_cv_header_pthread_h+set}" = set; then
11442 echo $ECHO_N "(cached) $ECHO_C" >&6
11444 cat >conftest.$ac_ext <<_ACEOF
11445 #line 11445 "configure"
11446 #include "confdefs.h"
11447 #include <pthread.h>
11449 if { (eval echo "$as_me:11449: \"$ac_cpp conftest.$ac_ext\"") >&5
11450 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11452 egrep -v '^ *\+' conftest.er1 >conftest.err
11454 cat conftest.err >&5
11455 echo "$as_me:11455: \$? = $ac_status" >&5
11456 (exit $ac_status); } >/dev/null; then
11457 if test -s conftest.err; then
11458 ac_cpp_err=$ac_c_preproc_warn_flag
11465 if test -z "$ac_cpp_err"; then
11466 ac_cv_header_pthread_h=yes
11468 echo "$as_me: failed program was:" >&5
11469 cat conftest.$ac_ext >&5
11470 ac_cv_header_pthread_h=no
11472 rm -f conftest.err conftest.$ac_ext
11474 echo "$as_me:11474: result: $ac_cv_header_pthread_h" >&5
11475 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
11476 if test $ac_cv_header_pthread_h = yes; then
11478 cat >>confdefs.h <<\EOF
11479 #define HAVE_PTHREADS_H 1
11482 for cf_lib_pthread in pthread c_r
11484 echo "$as_me:11484: checking if we can link with the $cf_lib_pthread library" >&5
11485 echo $ECHO_N "checking if we can link with the $cf_lib_pthread library... $ECHO_C" >&6
11486 cf_save_LIBS="$LIBS"
11488 cf_add_libs="-l$cf_lib_pthread"
11489 # Filter out duplicates - this happens with badly-designed ".pc" files...
11490 for cf_add_1lib in $LIBS
11492 for cf_add_2lib in $cf_add_libs
11494 if test "x$cf_add_1lib" = "x$cf_add_2lib"
11500 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
11502 LIBS="$cf_add_libs"
11504 cat >conftest.$ac_ext <<_ACEOF
11505 #line 11505 "configure"
11506 #include "confdefs.h"
11508 #include <pthread.h>
11514 int rc = pthread_create(0,0,0,0);
11515 int r2 = pthread_mutexattr_settype(0, 0);
11521 rm -f conftest.$ac_objext conftest$ac_exeext
11522 if { (eval echo "$as_me:11522: \"$ac_link\"") >&5
11523 (eval $ac_link) 2>&5
11525 echo "$as_me:11525: \$? = $ac_status" >&5
11526 (exit $ac_status); } &&
11527 { ac_try='test -s conftest$ac_exeext'
11528 { (eval echo "$as_me:11528: \"$ac_try\"") >&5
11529 (eval $ac_try) 2>&5
11531 echo "$as_me:11531: \$? = $ac_status" >&5
11532 (exit $ac_status); }; }; then
11535 echo "$as_me: failed program was:" >&5
11536 cat conftest.$ac_ext >&5
11539 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11540 LIBS="$cf_save_LIBS"
11541 echo "$as_me:11541: result: $with_pthread" >&5
11542 echo "${ECHO_T}$with_pthread" >&6
11543 test "$with_pthread" = yes && break
11546 if test "$with_pthread" = yes ; then
11548 cf_add_libs="-l$cf_lib_pthread"
11549 # Filter out duplicates - this happens with badly-designed ".pc" files...
11550 for cf_add_1lib in $LIBS
11552 for cf_add_2lib in $cf_add_libs
11554 if test "x$cf_add_1lib" = "x$cf_add_2lib"
11560 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
11562 LIBS="$cf_add_libs"
11564 cat >>confdefs.h <<\EOF
11565 #define HAVE_LIBPTHREADS 1
11569 { { echo "$as_me:11569: error: Cannot link with pthread library" >&5
11570 echo "$as_me: error: Cannot link with pthread library" >&2;}
11571 { (exit 1); exit 1; }; }
11578 echo "$as_me:11578: checking if you want to use weak-symbols for pthreads" >&5
11579 echo $ECHO_N "checking if you want to use weak-symbols for pthreads... $ECHO_C" >&6
11581 # Check whether --enable-weak-symbols or --disable-weak-symbols was given.
11582 if test "${enable_weak_symbols+set}" = set; then
11583 enableval="$enable_weak_symbols"
11584 use_weak_symbols=$withval
11586 use_weak_symbols=no
11588 echo "$as_me:11588: result: $use_weak_symbols" >&5
11589 echo "${ECHO_T}$use_weak_symbols" >&6
11590 if test "$use_weak_symbols" = yes ; then
11592 echo "$as_me:11592: checking if $CC supports weak symbols" >&5
11593 echo $ECHO_N "checking if $CC supports weak symbols... $ECHO_C" >&6
11594 if test "${cf_cv_weak_symbols+set}" = set; then
11595 echo $ECHO_N "(cached) $ECHO_C" >&6
11598 cat >conftest.$ac_ext <<_ACEOF
11599 #line 11599 "configure"
11600 #include "confdefs.h"
11607 #if defined(__GNUC__)
11608 # if defined __USE_ISOC99
11609 # define _cat_pragma(exp) _Pragma(#exp)
11610 # define _weak_pragma(exp) _cat_pragma(weak name)
11612 # define _weak_pragma(exp)
11614 # define _declare(name) __extension__ extern __typeof__(name) name
11615 # define weak_symbol(name) _weak_pragma(name) _declare(name) __attribute__((weak))
11618 weak_symbol(fopen);
11624 rm -f conftest.$ac_objext
11625 if { (eval echo "$as_me:11625: \"$ac_compile\"") >&5
11626 (eval $ac_compile) 2>&5
11628 echo "$as_me:11628: \$? = $ac_status" >&5
11629 (exit $ac_status); } &&
11630 { ac_try='test -s conftest.$ac_objext'
11631 { (eval echo "$as_me:11631: \"$ac_try\"") >&5
11632 (eval $ac_try) 2>&5
11634 echo "$as_me:11634: \$? = $ac_status" >&5
11635 (exit $ac_status); }; }; then
11636 cf_cv_weak_symbols=yes
11638 echo "$as_me: failed program was:" >&5
11639 cat conftest.$ac_ext >&5
11640 cf_cv_weak_symbols=no
11642 rm -f conftest.$ac_objext conftest.$ac_ext
11645 echo "$as_me:11645: result: $cf_cv_weak_symbols" >&5
11646 echo "${ECHO_T}$cf_cv_weak_symbols" >&6
11649 cf_cv_weak_symbols=no
11652 if test $cf_cv_weak_symbols = yes ; then
11654 cat >>confdefs.h <<\EOF
11655 #define USE_WEAK_SYMBOLS 1
11661 if test "$with_pthread" = "yes" ; then
11663 cat >>confdefs.h <<\EOF
11664 #define USE_PTHREADS 1
11667 enable_reentrant=yes
11668 if test $cf_cv_weak_symbols = yes ; then
11673 # OpenSUSE is installing ncurses6, using reentrant option.
11674 echo "$as_me:11674: checking for _nc_TABSIZE" >&5
11675 echo $ECHO_N "checking for _nc_TABSIZE... $ECHO_C" >&6
11676 if test "${ac_cv_func__nc_TABSIZE+set}" = set; then
11677 echo $ECHO_N "(cached) $ECHO_C" >&6
11679 cat >conftest.$ac_ext <<_ACEOF
11680 #line 11680 "configure"
11681 #include "confdefs.h"
11682 /* System header to define __stub macros and hopefully few prototypes,
11683 which can conflict with char _nc_TABSIZE (); below. */
11684 #include <assert.h>
11685 /* Override any gcc2 internal prototype to avoid an error. */
11689 /* We use char because int might match the return type of a gcc2
11690 builtin and then its argument prototype would still apply. */
11691 char _nc_TABSIZE ();
11697 /* The GNU C library defines this for functions which it implements
11698 to always fail with ENOSYS. Some functions are actually named
11699 something starting with __ and the normal name is an alias. */
11700 #if defined (__stub__nc_TABSIZE) || defined (__stub____nc_TABSIZE)
11703 f = _nc_TABSIZE; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
11710 rm -f conftest.$ac_objext conftest$ac_exeext
11711 if { (eval echo "$as_me:11711: \"$ac_link\"") >&5
11712 (eval $ac_link) 2>&5
11714 echo "$as_me:11714: \$? = $ac_status" >&5
11715 (exit $ac_status); } &&
11716 { ac_try='test -s conftest$ac_exeext'
11717 { (eval echo "$as_me:11717: \"$ac_try\"") >&5
11718 (eval $ac_try) 2>&5
11720 echo "$as_me:11720: \$? = $ac_status" >&5
11721 (exit $ac_status); }; }; then
11722 ac_cv_func__nc_TABSIZE=yes
11724 echo "$as_me: failed program was:" >&5
11725 cat conftest.$ac_ext >&5
11726 ac_cv_func__nc_TABSIZE=no
11728 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11730 echo "$as_me:11730: result: $ac_cv_func__nc_TABSIZE" >&5
11731 echo "${ECHO_T}$ac_cv_func__nc_TABSIZE" >&6
11732 if test $ac_cv_func__nc_TABSIZE = yes; then
11733 assume_reentrant=yes
11735 assume_reentrant=no
11738 # Reentrant code has to be opaque; there's little advantage to making ncurses
11739 # opaque outside of that, so there is no --enable-opaque option. We can use
11740 # this option without --with-pthreads, but this will be always set for
11742 echo "$as_me:11742: checking if you want experimental reentrant code" >&5
11743 echo $ECHO_N "checking if you want experimental reentrant code... $ECHO_C" >&6
11745 # Check whether --enable-reentrant or --disable-reentrant was given.
11746 if test "${enable_reentrant+set}" = set; then
11747 enableval="$enable_reentrant"
11748 with_reentrant=$enableval
11750 with_reentrant=$assume_reentrant
11752 echo "$as_me:11752: result: $with_reentrant" >&5
11753 echo "${ECHO_T}$with_reentrant" >&6
11754 if test "$with_reentrant" = yes ; then
11755 cf_cv_enable_reentrant=1
11756 if test $cf_cv_weak_symbols = yes ; then
11758 # remove pthread library from $LIBS
11759 LIBS=`echo "$LIBS" | sed -e 's/-lpthread[ ]//g' -e 's/-lpthread$//'`
11761 elif test "$assume_reentrant" = no ; then
11762 LIB_SUFFIX="t${LIB_SUFFIX}"
11765 cat >>confdefs.h <<\EOF
11766 #define USE_REENTRANT 1
11770 cf_cv_enable_reentrant=0
11773 ### Allow using a different wrap-prefix
11774 if test "$cf_cv_enable_reentrant" != 0 || test "$BROKEN_LINKER" = 1 ; then
11775 echo "$as_me:11775: checking for prefix used to wrap public variables" >&5
11776 echo $ECHO_N "checking for prefix used to wrap public variables... $ECHO_C" >&6
11778 # Check whether --with-wrap-prefix or --without-wrap-prefix was given.
11779 if test "${with_wrap_prefix+set}" = set; then
11780 withval="$with_wrap_prefix"
11781 NCURSES_WRAP_PREFIX=$withval
11783 NCURSES_WRAP_PREFIX=_nc_
11785 echo "$as_me:11785: result: $NCURSES_WRAP_PREFIX" >&5
11786 echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
11788 NCURSES_WRAP_PREFIX=_nc_
11791 cat >>confdefs.h <<EOF
11792 #define NCURSES_WRAP_PREFIX "$NCURSES_WRAP_PREFIX"
11795 ###############################################################################
11797 ### use option --disable-echo to suppress full display compiling commands
11799 echo "$as_me:11799: checking if you want to see long compiling messages" >&5
11800 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
11802 # Check whether --enable-echo or --disable-echo was given.
11803 if test "${enable_echo+set}" = set; then
11804 enableval="$enable_echo"
11805 test "$enableval" != no && enableval=yes
11806 if test "$enableval" != "yes" ; then
11809 ECHO_LD='@echo linking $@;'
11810 RULE_CC='@echo compiling $<'
11811 SHOW_CC='@echo compiling $@'
11833 echo "$as_me:11833: result: $enableval" >&5
11834 echo "${ECHO_T}$enableval" >&6
11836 ### use option --enable-warnings to turn on all gcc warnings
11837 echo "$as_me:11837: checking if you want to see compiler warnings" >&5
11838 echo $ECHO_N "checking if you want to see compiler warnings... $ECHO_C" >&6
11840 # Check whether --enable-warnings or --disable-warnings was given.
11841 if test "${enable_warnings+set}" = set; then
11842 enableval="$enable_warnings"
11843 with_warnings=$enableval
11845 echo "$as_me:11845: result: $with_warnings" >&5
11846 echo "${ECHO_T}$with_warnings" >&6
11848 if test "x$with_warnings" = "xyes"; then
11850 ADAFLAGS="$ADAFLAGS -gnatg"
11854 if test "$GCC" = yes ; then
11857 echo "$as_me:11857: checking if this is really Intel C compiler" >&5
11858 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
11859 cf_save_CFLAGS="$CFLAGS"
11860 CFLAGS="$CFLAGS -no-gcc"
11861 cat >conftest.$ac_ext <<_ACEOF
11862 #line 11862 "configure"
11863 #include "confdefs.h"
11869 #ifdef __INTEL_COMPILER
11878 rm -f conftest.$ac_objext
11879 if { (eval echo "$as_me:11879: \"$ac_compile\"") >&5
11880 (eval $ac_compile) 2>&5
11882 echo "$as_me:11882: \$? = $ac_status" >&5
11883 (exit $ac_status); } &&
11884 { ac_try='test -s conftest.$ac_objext'
11885 { (eval echo "$as_me:11885: \"$ac_try\"") >&5
11886 (eval $ac_try) 2>&5
11888 echo "$as_me:11888: \$? = $ac_status" >&5
11889 (exit $ac_status); }; }; then
11891 cf_save_CFLAGS="$cf_save_CFLAGS -we147"
11894 echo "$as_me: failed program was:" >&5
11895 cat conftest.$ac_ext >&5
11897 rm -f conftest.$ac_objext conftest.$ac_ext
11898 CFLAGS="$cf_save_CFLAGS"
11899 echo "$as_me:11899: result: $INTEL_COMPILER" >&5
11900 echo "${ECHO_T}$INTEL_COMPILER" >&6
11907 if test "$GCC" = yes ; then
11908 echo "$as_me:11908: checking if this is really Clang C compiler" >&5
11909 echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6
11910 cf_save_CFLAGS="$CFLAGS"
11911 CFLAGS="$CFLAGS -Qunused-arguments"
11912 cat >conftest.$ac_ext <<_ACEOF
11913 #line 11913 "configure"
11914 #include "confdefs.h"
11929 rm -f conftest.$ac_objext
11930 if { (eval echo "$as_me:11930: \"$ac_compile\"") >&5
11931 (eval $ac_compile) 2>&5
11933 echo "$as_me:11933: \$? = $ac_status" >&5
11934 (exit $ac_status); } &&
11935 { ac_try='test -s conftest.$ac_objext'
11936 { (eval echo "$as_me:11936: \"$ac_try\"") >&5
11937 (eval $ac_try) 2>&5
11939 echo "$as_me:11939: \$? = $ac_status" >&5
11940 (exit $ac_status); }; }; then
11942 cf_save_CFLAGS="$cf_save_CFLAGS -Qunused-arguments"
11945 echo "$as_me: failed program was:" >&5
11946 cat conftest.$ac_ext >&5
11948 rm -f conftest.$ac_objext conftest.$ac_ext
11949 CFLAGS="$cf_save_CFLAGS"
11950 echo "$as_me:11950: result: $CLANG_COMPILER" >&5
11951 echo "${ECHO_T}$CLANG_COMPILER" >&6
11954 cat > conftest.$ac_ext <<EOF
11955 #line 11955 "${as_me:-configure}"
11956 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
11959 if test "$INTEL_COMPILER" = yes
11961 # The "-wdXXX" options suppress warnings:
11962 # remark #1419: external declaration in primary source file
11963 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
11964 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
11965 # remark #193: zero used for undefined preprocessing identifier
11966 # remark #593: variable "curs_sb_left_arrow" was set but never used
11967 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
11968 # remark #869: parameter "tw" was never referenced
11969 # remark #981: operands are evaluated in unspecified order
11970 # warning #279: controlling expression is constant
11972 { echo "$as_me:11972: checking for $CC warning options..." >&5
11973 echo "$as_me: checking for $CC warning options..." >&6;}
11974 cf_save_CFLAGS="$CFLAGS"
11975 EXTRA_CFLAGS="-Wall"
11987 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
11988 if { (eval echo "$as_me:11988: \"$ac_compile\"") >&5
11989 (eval $ac_compile) 2>&5
11991 echo "$as_me:11991: \$? = $ac_status" >&5
11992 (exit $ac_status); }; then
11993 test -n "$verbose" && echo "$as_me:11993: result: ... -$cf_opt" >&5
11994 echo "${ECHO_T}... -$cf_opt" >&6
11995 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
11998 CFLAGS="$cf_save_CFLAGS"
12000 elif test "$GCC" = yes
12002 { echo "$as_me:12002: checking for $CC warning options..." >&5
12003 echo "$as_me: checking for $CC warning options..." >&6;}
12004 cf_save_CFLAGS="$CFLAGS"
12007 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
12008 cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs"
12009 test "x$CLANG_COMPILER" = xyes && cf_gcc_warnings=
12010 for cf_opt in W Wall \
12011 Wbad-function-cast \
12014 Wdeclaration-after-statement \
12017 Wmissing-declarations \
12018 Wmissing-prototypes \
12022 Wstrict-prototypes \
12023 Wundef $cf_gcc_warnings $cf_warn_CONST Wno-unknown-pragmas Wswitch-enum
12025 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
12026 if { (eval echo "$as_me:12026: \"$ac_compile\"") >&5
12027 (eval $ac_compile) 2>&5
12029 echo "$as_me:12029: \$? = $ac_status" >&5
12030 (exit $ac_status); }; then
12031 test -n "$verbose" && echo "$as_me:12031: result: ... -$cf_opt" >&5
12032 echo "${ECHO_T}... -$cf_opt" >&6
12035 CPPFLAGS="$CPPFLAGS -DXTSTRINGDEFINES"
12038 case $GCC_VERSION in
12040 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
12042 echo "${as_me:-configure}:12042: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
12048 case $GCC_VERSION in
12050 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
12052 echo "${as_me:-configure}:12052: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
12058 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
12061 CFLAGS="$cf_save_CFLAGS"
12067 if test "$GCC" = yes
12069 cat > conftest.i <<EOF
12071 #define GCC_PRINTF 0
12074 #define GCC_SCANF 0
12076 #ifndef GCC_NORETURN
12077 #define GCC_NORETURN /* nothing */
12080 #define GCC_UNUSED /* nothing */
12083 if test "$GCC" = yes
12085 { echo "$as_me:12085: checking for $CC __attribute__ directives..." >&5
12086 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
12087 cat > conftest.$ac_ext <<EOF
12088 #line 12088 "${as_me:-configure}"
12089 #include "confdefs.h"
12090 #include "conftest.h"
12091 #include "conftest.i"
12093 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
12095 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
12098 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
12100 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
12102 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
12103 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
12104 extern void foo(void) GCC_NORETURN;
12105 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
12107 cf_printf_attribute=no
12108 cf_scanf_attribute=no
12109 for cf_attribute in scanf printf unused noreturn
12112 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
12114 cf_directive="__attribute__(($cf_attribute))"
12115 echo "checking for $CC $cf_directive" 1>&5
12117 case $cf_attribute in
12119 cf_printf_attribute=yes
12120 cat >conftest.h <<EOF
12121 #define GCC_$cf_ATTRIBUTE 1
12125 cf_scanf_attribute=yes
12126 cat >conftest.h <<EOF
12127 #define GCC_$cf_ATTRIBUTE 1
12131 cat >conftest.h <<EOF
12132 #define GCC_$cf_ATTRIBUTE $cf_directive
12137 if { (eval echo "$as_me:12137: \"$ac_compile\"") >&5
12138 (eval $ac_compile) 2>&5
12140 echo "$as_me:12140: \$? = $ac_status" >&5
12141 (exit $ac_status); }; then
12142 test -n "$verbose" && echo "$as_me:12142: result: ... $cf_attribute" >&5
12143 echo "${ECHO_T}... $cf_attribute" >&6
12144 cat conftest.h >>confdefs.h
12145 case $cf_attribute in
12148 cat >>confdefs.h <<EOF
12149 #define GCC_NORETURN $cf_directive
12154 cf_value='/* nothing */'
12155 if test "$cf_printf_attribute" != no ; then
12156 cf_value='__attribute__((format(printf,fmt,var)))'
12158 cat >>confdefs.h <<\EOF
12159 #define GCC_PRINTF 1
12164 cat >>confdefs.h <<EOF
12165 #define GCC_PRINTFLIKE(fmt,var) $cf_value
12170 cf_value='/* nothing */'
12171 if test "$cf_scanf_attribute" != no ; then
12172 cf_value='__attribute__((format(scanf,fmt,var)))'
12174 cat >>confdefs.h <<\EOF
12175 #define GCC_SCANF 1
12180 cat >>confdefs.h <<EOF
12181 #define GCC_SCANFLIKE(fmt,var) $cf_value
12187 cat >>confdefs.h <<EOF
12188 #define GCC_UNUSED $cf_directive
12196 fgrep define conftest.i >>confdefs.h
12201 ### use option --enable-assertions to turn on generation of assertion code
12202 echo "$as_me:12202: checking if you want to enable runtime assertions" >&5
12203 echo $ECHO_N "checking if you want to enable runtime assertions... $ECHO_C" >&6
12205 # Check whether --enable-assertions or --disable-assertions was given.
12206 if test "${enable_assertions+set}" = set; then
12207 enableval="$enable_assertions"
12208 with_assertions=$enableval
12212 echo "$as_me:12212: result: $with_assertions" >&5
12213 echo "${ECHO_T}$with_assertions" >&6
12216 if test "$with_assertions" = no
12218 CPPFLAGS="$CPPFLAGS -DNDEBUG"
12221 ADAFLAGS="$ADAFLAGS -gnata"
12226 ### use option --disable-leaks to suppress "permanent" leaks, for testing
12228 cat >>confdefs.h <<\EOF
12229 #define HAVE_NC_ALLOC_H 1
12232 ### use option --enable-expanded to generate certain macros as functions
12234 # Check whether --enable-expanded or --disable-expanded was given.
12235 if test "${enable_expanded+set}" = set; then
12236 enableval="$enable_expanded"
12237 test "$enableval" = yes &&
12238 cat >>confdefs.h <<\EOF
12239 #define NCURSES_EXPANDED 1
12244 ### use option --disable-macros to suppress macros in favor of functions
12246 # Check whether --enable-macros or --disable-macros was given.
12247 if test "${enable_macros+set}" = set; then
12248 enableval="$enable_macros"
12249 test "$enableval" = no &&
12250 cat >>confdefs.h <<\EOF
12251 #define NCURSES_NOMACROS 1
12256 # Normally we only add trace() to the debug-library. Allow this to be
12257 # extended to all models of the ncurses library:
12259 case "$CFLAGS $CPPFLAGS" in
12265 echo "$as_me:12265: checking whether to add trace feature to all models" >&5
12266 echo $ECHO_N "checking whether to add trace feature to all models... $ECHO_C" >&6
12268 # Check whether --with-trace or --without-trace was given.
12269 if test "${with_trace+set}" = set; then
12270 withval="$with_trace"
12271 cf_with_trace=$withval
12273 cf_with_trace=$cf_all_traces
12275 echo "$as_me:12275: result: $cf_with_trace" >&5
12276 echo "${ECHO_T}$cf_with_trace" >&6
12278 if test "$cf_with_trace" = yes ; then
12284 cf_new_extra_cppflags=
12286 for cf_add_cflags in -DTRACE
12288 case $cf_fix_cppflags in
12290 case $cf_add_cflags in
12291 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12292 case $cf_add_cflags in
12294 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12296 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12297 && test -z "${cf_tst_cflags}" \
12298 && cf_fix_cppflags=yes
12300 if test $cf_fix_cppflags = yes ; then
12301 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12303 elif test "${cf_tst_cflags}" = "\"'" ; then
12304 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12309 case "$CPPFLAGS" in
12313 case $cf_add_cflags in
12315 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12317 CPPFLAGS=`echo "$CPPFLAGS" | \
12318 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12319 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12323 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
12328 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
12333 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12335 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12337 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12338 && test -z "${cf_tst_cflags}" \
12339 && cf_fix_cppflags=no
12344 if test -n "$cf_new_cflags" ; then
12346 CFLAGS="$CFLAGS $cf_new_cflags"
12349 if test -n "$cf_new_cppflags" ; then
12351 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
12354 if test -n "$cf_new_extra_cppflags" ; then
12356 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
12363 echo "$as_me:12363: checking if we want to use GNAT projects" >&5
12364 echo $ECHO_N "checking if we want to use GNAT projects... $ECHO_C" >&6
12366 # Check whether --enable-gnat-projects or --disable-gnat-projects was given.
12367 if test "${enable_gnat_projects+set}" = set; then
12368 enableval="$enable_gnat_projects"
12369 test "$enableval" != no && enableval=yes
12370 if test "$enableval" != "yes" ; then
12371 enable_gnat_projects=no
12373 enable_gnat_projects=yes
12377 enable_gnat_projects=yes
12380 echo "$as_me:12380: result: $enable_gnat_projects" >&5
12381 echo "${ECHO_T}$enable_gnat_projects" >&6
12383 ### Checks for libraries.
12384 case $cf_cv_system_name in
12388 echo "$as_me:12388: checking for gettimeofday" >&5
12389 echo $ECHO_N "checking for gettimeofday... $ECHO_C" >&6
12390 if test "${ac_cv_func_gettimeofday+set}" = set; then
12391 echo $ECHO_N "(cached) $ECHO_C" >&6
12393 cat >conftest.$ac_ext <<_ACEOF
12394 #line 12394 "configure"
12395 #include "confdefs.h"
12396 /* System header to define __stub macros and hopefully few prototypes,
12397 which can conflict with char gettimeofday (); below. */
12398 #include <assert.h>
12399 /* Override any gcc2 internal prototype to avoid an error. */
12403 /* We use char because int might match the return type of a gcc2
12404 builtin and then its argument prototype would still apply. */
12405 char gettimeofday ();
12411 /* The GNU C library defines this for functions which it implements
12412 to always fail with ENOSYS. Some functions are actually named
12413 something starting with __ and the normal name is an alias. */
12414 #if defined (__stub_gettimeofday) || defined (__stub___gettimeofday)
12417 f = gettimeofday; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
12424 rm -f conftest.$ac_objext conftest$ac_exeext
12425 if { (eval echo "$as_me:12425: \"$ac_link\"") >&5
12426 (eval $ac_link) 2>&5
12428 echo "$as_me:12428: \$? = $ac_status" >&5
12429 (exit $ac_status); } &&
12430 { ac_try='test -s conftest$ac_exeext'
12431 { (eval echo "$as_me:12431: \"$ac_try\"") >&5
12432 (eval $ac_try) 2>&5
12434 echo "$as_me:12434: \$? = $ac_status" >&5
12435 (exit $ac_status); }; }; then
12436 ac_cv_func_gettimeofday=yes
12438 echo "$as_me: failed program was:" >&5
12439 cat conftest.$ac_ext >&5
12440 ac_cv_func_gettimeofday=no
12442 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12444 echo "$as_me:12444: result: $ac_cv_func_gettimeofday" >&5
12445 echo "${ECHO_T}$ac_cv_func_gettimeofday" >&6
12446 if test $ac_cv_func_gettimeofday = yes; then
12447 cat >>confdefs.h <<\EOF
12448 #define HAVE_GETTIMEOFDAY 1
12453 echo "$as_me:12453: checking for gettimeofday in -lbsd" >&5
12454 echo $ECHO_N "checking for gettimeofday in -lbsd... $ECHO_C" >&6
12455 if test "${ac_cv_lib_bsd_gettimeofday+set}" = set; then
12456 echo $ECHO_N "(cached) $ECHO_C" >&6
12458 ac_check_lib_save_LIBS=$LIBS
12460 cat >conftest.$ac_ext <<_ACEOF
12461 #line 12461 "configure"
12462 #include "confdefs.h"
12464 /* Override any gcc2 internal prototype to avoid an error. */
12468 /* We use char because int might match the return type of a gcc2
12469 builtin and then its argument prototype would still apply. */
12470 char gettimeofday ();
12479 rm -f conftest.$ac_objext conftest$ac_exeext
12480 if { (eval echo "$as_me:12480: \"$ac_link\"") >&5
12481 (eval $ac_link) 2>&5
12483 echo "$as_me:12483: \$? = $ac_status" >&5
12484 (exit $ac_status); } &&
12485 { ac_try='test -s conftest$ac_exeext'
12486 { (eval echo "$as_me:12486: \"$ac_try\"") >&5
12487 (eval $ac_try) 2>&5
12489 echo "$as_me:12489: \$? = $ac_status" >&5
12490 (exit $ac_status); }; }; then
12491 ac_cv_lib_bsd_gettimeofday=yes
12493 echo "$as_me: failed program was:" >&5
12494 cat conftest.$ac_ext >&5
12495 ac_cv_lib_bsd_gettimeofday=no
12497 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12498 LIBS=$ac_check_lib_save_LIBS
12500 echo "$as_me:12500: result: $ac_cv_lib_bsd_gettimeofday" >&5
12501 echo "${ECHO_T}$ac_cv_lib_bsd_gettimeofday" >&6
12502 if test $ac_cv_lib_bsd_gettimeofday = yes; then
12504 cat >>confdefs.h <<\EOF
12505 #define HAVE_GETTIMEOFDAY 1
12515 ### Checks for header files.
12516 echo "$as_me:12516: checking for ANSI C header files" >&5
12517 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
12518 if test "${ac_cv_header_stdc+set}" = set; then
12519 echo $ECHO_N "(cached) $ECHO_C" >&6
12521 cat >conftest.$ac_ext <<_ACEOF
12522 #line 12522 "configure"
12523 #include "confdefs.h"
12524 #include <stdlib.h>
12525 #include <stdarg.h>
12526 #include <string.h>
12530 if { (eval echo "$as_me:12530: \"$ac_cpp conftest.$ac_ext\"") >&5
12531 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12533 egrep -v '^ *\+' conftest.er1 >conftest.err
12535 cat conftest.err >&5
12536 echo "$as_me:12536: \$? = $ac_status" >&5
12537 (exit $ac_status); } >/dev/null; then
12538 if test -s conftest.err; then
12539 ac_cpp_err=$ac_c_preproc_warn_flag
12546 if test -z "$ac_cpp_err"; then
12547 ac_cv_header_stdc=yes
12549 echo "$as_me: failed program was:" >&5
12550 cat conftest.$ac_ext >&5
12551 ac_cv_header_stdc=no
12553 rm -f conftest.err conftest.$ac_ext
12555 if test $ac_cv_header_stdc = yes; then
12556 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
12557 cat >conftest.$ac_ext <<_ACEOF
12558 #line 12558 "configure"
12559 #include "confdefs.h"
12560 #include <string.h>
12563 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12564 egrep "memchr" >/dev/null 2>&1; then
12567 ac_cv_header_stdc=no
12573 if test $ac_cv_header_stdc = yes; then
12574 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
12575 cat >conftest.$ac_ext <<_ACEOF
12576 #line 12576 "configure"
12577 #include "confdefs.h"
12578 #include <stdlib.h>
12581 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12582 egrep "free" >/dev/null 2>&1; then
12585 ac_cv_header_stdc=no
12591 if test $ac_cv_header_stdc = yes; then
12592 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
12593 if test "$cross_compiling" = yes; then
12596 cat >conftest.$ac_ext <<_ACEOF
12597 #line 12597 "configure"
12598 #include "confdefs.h"
12600 #if ((' ' & 0x0FF) == 0x020)
12601 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
12602 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
12604 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
12605 || ('j' <= (c) && (c) <= 'r') \
12606 || ('s' <= (c) && (c) <= 'z'))
12607 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
12610 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
12615 for (i = 0; i < 256; i++)
12616 if (XOR (islower (i), ISLOWER (i))
12617 || toupper (i) != TOUPPER (i))
12618 $ac_main_return(2);
12619 $ac_main_return (0);
12622 rm -f conftest$ac_exeext
12623 if { (eval echo "$as_me:12623: \"$ac_link\"") >&5
12624 (eval $ac_link) 2>&5
12626 echo "$as_me:12626: \$? = $ac_status" >&5
12627 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12628 { (eval echo "$as_me:12628: \"$ac_try\"") >&5
12629 (eval $ac_try) 2>&5
12631 echo "$as_me:12631: \$? = $ac_status" >&5
12632 (exit $ac_status); }; }; then
12635 echo "$as_me: program exited with status $ac_status" >&5
12636 echo "$as_me: failed program was:" >&5
12637 cat conftest.$ac_ext >&5
12638 ac_cv_header_stdc=no
12640 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12644 echo "$as_me:12644: result: $ac_cv_header_stdc" >&5
12645 echo "${ECHO_T}$ac_cv_header_stdc" >&6
12646 if test $ac_cv_header_stdc = yes; then
12648 cat >>confdefs.h <<\EOF
12649 #define STDC_HEADERS 1
12654 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
12656 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
12657 inttypes.h stdint.h unistd.h
12659 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12660 echo "$as_me:12660: checking for $ac_header" >&5
12661 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12662 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12663 echo $ECHO_N "(cached) $ECHO_C" >&6
12665 cat >conftest.$ac_ext <<_ACEOF
12666 #line 12666 "configure"
12667 #include "confdefs.h"
12668 $ac_includes_default
12669 #include <$ac_header>
12671 rm -f conftest.$ac_objext
12672 if { (eval echo "$as_me:12672: \"$ac_compile\"") >&5
12673 (eval $ac_compile) 2>&5
12675 echo "$as_me:12675: \$? = $ac_status" >&5
12676 (exit $ac_status); } &&
12677 { ac_try='test -s conftest.$ac_objext'
12678 { (eval echo "$as_me:12678: \"$ac_try\"") >&5
12679 (eval $ac_try) 2>&5
12681 echo "$as_me:12681: \$? = $ac_status" >&5
12682 (exit $ac_status); }; }; then
12683 eval "$as_ac_Header=yes"
12685 echo "$as_me: failed program was:" >&5
12686 cat conftest.$ac_ext >&5
12687 eval "$as_ac_Header=no"
12689 rm -f conftest.$ac_objext conftest.$ac_ext
12691 echo "$as_me:12691: result: `eval echo '${'$as_ac_Header'}'`" >&5
12692 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12693 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12694 cat >>confdefs.h <<EOF
12695 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12701 echo "$as_me:12701: checking for signed char" >&5
12702 echo $ECHO_N "checking for signed char... $ECHO_C" >&6
12703 if test "${ac_cv_type_signed_char+set}" = set; then
12704 echo $ECHO_N "(cached) $ECHO_C" >&6
12706 cat >conftest.$ac_ext <<_ACEOF
12707 #line 12707 "configure"
12708 #include "confdefs.h"
12709 $ac_includes_default
12713 if ((signed char *) 0)
12715 if (sizeof (signed char))
12721 rm -f conftest.$ac_objext
12722 if { (eval echo "$as_me:12722: \"$ac_compile\"") >&5
12723 (eval $ac_compile) 2>&5
12725 echo "$as_me:12725: \$? = $ac_status" >&5
12726 (exit $ac_status); } &&
12727 { ac_try='test -s conftest.$ac_objext'
12728 { (eval echo "$as_me:12728: \"$ac_try\"") >&5
12729 (eval $ac_try) 2>&5
12731 echo "$as_me:12731: \$? = $ac_status" >&5
12732 (exit $ac_status); }; }; then
12733 ac_cv_type_signed_char=yes
12735 echo "$as_me: failed program was:" >&5
12736 cat conftest.$ac_ext >&5
12737 ac_cv_type_signed_char=no
12739 rm -f conftest.$ac_objext conftest.$ac_ext
12741 echo "$as_me:12741: result: $ac_cv_type_signed_char" >&5
12742 echo "${ECHO_T}$ac_cv_type_signed_char" >&6
12744 echo "$as_me:12744: checking size of signed char" >&5
12745 echo $ECHO_N "checking size of signed char... $ECHO_C" >&6
12746 if test "${ac_cv_sizeof_signed_char+set}" = set; then
12747 echo $ECHO_N "(cached) $ECHO_C" >&6
12749 if test "$ac_cv_type_signed_char" = yes; then
12750 if test "$cross_compiling" = yes; then
12751 # Depending upon the size, compute the lo and hi bounds.
12752 cat >conftest.$ac_ext <<_ACEOF
12753 #line 12753 "configure"
12754 #include "confdefs.h"
12755 $ac_includes_default
12759 int _array_ [1 - 2 * !((sizeof (signed char)) >= 0)]
12764 rm -f conftest.$ac_objext
12765 if { (eval echo "$as_me:12765: \"$ac_compile\"") >&5
12766 (eval $ac_compile) 2>&5
12768 echo "$as_me:12768: \$? = $ac_status" >&5
12769 (exit $ac_status); } &&
12770 { ac_try='test -s conftest.$ac_objext'
12771 { (eval echo "$as_me:12771: \"$ac_try\"") >&5
12772 (eval $ac_try) 2>&5
12774 echo "$as_me:12774: \$? = $ac_status" >&5
12775 (exit $ac_status); }; }; then
12778 cat >conftest.$ac_ext <<_ACEOF
12779 #line 12779 "configure"
12780 #include "confdefs.h"
12781 $ac_includes_default
12785 int _array_ [1 - 2 * !((sizeof (signed char)) <= $ac_mid)]
12790 rm -f conftest.$ac_objext
12791 if { (eval echo "$as_me:12791: \"$ac_compile\"") >&5
12792 (eval $ac_compile) 2>&5
12794 echo "$as_me:12794: \$? = $ac_status" >&5
12795 (exit $ac_status); } &&
12796 { ac_try='test -s conftest.$ac_objext'
12797 { (eval echo "$as_me:12797: \"$ac_try\"") >&5
12798 (eval $ac_try) 2>&5
12800 echo "$as_me:12800: \$? = $ac_status" >&5
12801 (exit $ac_status); }; }; then
12802 ac_hi=$ac_mid; break
12804 echo "$as_me: failed program was:" >&5
12805 cat conftest.$ac_ext >&5
12806 ac_lo=`expr $ac_mid + 1`; ac_mid=`expr 2 '*' $ac_mid + 1`
12808 rm -f conftest.$ac_objext conftest.$ac_ext
12811 echo "$as_me: failed program was:" >&5
12812 cat conftest.$ac_ext >&5
12815 cat >conftest.$ac_ext <<_ACEOF
12816 #line 12816 "configure"
12817 #include "confdefs.h"
12818 $ac_includes_default
12822 int _array_ [1 - 2 * !((sizeof (signed char)) >= $ac_mid)]
12827 rm -f conftest.$ac_objext
12828 if { (eval echo "$as_me:12828: \"$ac_compile\"") >&5
12829 (eval $ac_compile) 2>&5
12831 echo "$as_me:12831: \$? = $ac_status" >&5
12832 (exit $ac_status); } &&
12833 { ac_try='test -s conftest.$ac_objext'
12834 { (eval echo "$as_me:12834: \"$ac_try\"") >&5
12835 (eval $ac_try) 2>&5
12837 echo "$as_me:12837: \$? = $ac_status" >&5
12838 (exit $ac_status); }; }; then
12839 ac_lo=$ac_mid; break
12841 echo "$as_me: failed program was:" >&5
12842 cat conftest.$ac_ext >&5
12843 ac_hi=`expr $ac_mid - 1`; ac_mid=`expr 2 '*' $ac_mid`
12845 rm -f conftest.$ac_objext conftest.$ac_ext
12848 rm -f conftest.$ac_objext conftest.$ac_ext
12849 # Binary search between lo and hi bounds.
12850 while test "x$ac_lo" != "x$ac_hi"; do
12851 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
12852 cat >conftest.$ac_ext <<_ACEOF
12853 #line 12853 "configure"
12854 #include "confdefs.h"
12855 $ac_includes_default
12859 int _array_ [1 - 2 * !((sizeof (signed char)) <= $ac_mid)]
12864 rm -f conftest.$ac_objext
12865 if { (eval echo "$as_me:12865: \"$ac_compile\"") >&5
12866 (eval $ac_compile) 2>&5
12868 echo "$as_me:12868: \$? = $ac_status" >&5
12869 (exit $ac_status); } &&
12870 { ac_try='test -s conftest.$ac_objext'
12871 { (eval echo "$as_me:12871: \"$ac_try\"") >&5
12872 (eval $ac_try) 2>&5
12874 echo "$as_me:12874: \$? = $ac_status" >&5
12875 (exit $ac_status); }; }; then
12878 echo "$as_me: failed program was:" >&5
12879 cat conftest.$ac_ext >&5
12880 ac_lo=`expr $ac_mid + 1`
12882 rm -f conftest.$ac_objext conftest.$ac_ext
12884 ac_cv_sizeof_signed_char=$ac_lo
12886 if test "$cross_compiling" = yes; then
12887 { { echo "$as_me:12887: error: cannot run test program while cross compiling" >&5
12888 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
12889 { (exit 1); exit 1; }; }
12891 cat >conftest.$ac_ext <<_ACEOF
12892 #line 12892 "configure"
12893 #include "confdefs.h"
12894 $ac_includes_default
12898 FILE *f = fopen ("conftest.val", "w");
12900 $ac_main_return (1);
12901 fprintf (f, "%d", (sizeof (signed char)));
12907 rm -f conftest$ac_exeext
12908 if { (eval echo "$as_me:12908: \"$ac_link\"") >&5
12909 (eval $ac_link) 2>&5
12911 echo "$as_me:12911: \$? = $ac_status" >&5
12912 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12913 { (eval echo "$as_me:12913: \"$ac_try\"") >&5
12914 (eval $ac_try) 2>&5
12916 echo "$as_me:12916: \$? = $ac_status" >&5
12917 (exit $ac_status); }; }; then
12918 ac_cv_sizeof_signed_char=`cat conftest.val`
12920 echo "$as_me: program exited with status $ac_status" >&5
12921 echo "$as_me: failed program was:" >&5
12922 cat conftest.$ac_ext >&5
12924 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12929 ac_cv_sizeof_signed_char=0
12932 echo "$as_me:12932: result: $ac_cv_sizeof_signed_char" >&5
12933 echo "${ECHO_T}$ac_cv_sizeof_signed_char" >&6
12934 cat >>confdefs.h <<EOF
12935 #define SIZEOF_SIGNED_CHAR $ac_cv_sizeof_signed_char
12938 echo "$as_me:12938: checking for ANSI C header files" >&5
12939 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
12940 if test "${ac_cv_header_stdc+set}" = set; then
12941 echo $ECHO_N "(cached) $ECHO_C" >&6
12943 cat >conftest.$ac_ext <<_ACEOF
12944 #line 12944 "configure"
12945 #include "confdefs.h"
12946 #include <stdlib.h>
12947 #include <stdarg.h>
12948 #include <string.h>
12952 if { (eval echo "$as_me:12952: \"$ac_cpp conftest.$ac_ext\"") >&5
12953 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12955 egrep -v '^ *\+' conftest.er1 >conftest.err
12957 cat conftest.err >&5
12958 echo "$as_me:12958: \$? = $ac_status" >&5
12959 (exit $ac_status); } >/dev/null; then
12960 if test -s conftest.err; then
12961 ac_cpp_err=$ac_c_preproc_warn_flag
12968 if test -z "$ac_cpp_err"; then
12969 ac_cv_header_stdc=yes
12971 echo "$as_me: failed program was:" >&5
12972 cat conftest.$ac_ext >&5
12973 ac_cv_header_stdc=no
12975 rm -f conftest.err conftest.$ac_ext
12977 if test $ac_cv_header_stdc = yes; then
12978 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
12979 cat >conftest.$ac_ext <<_ACEOF
12980 #line 12980 "configure"
12981 #include "confdefs.h"
12982 #include <string.h>
12985 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12986 egrep "memchr" >/dev/null 2>&1; then
12989 ac_cv_header_stdc=no
12995 if test $ac_cv_header_stdc = yes; then
12996 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
12997 cat >conftest.$ac_ext <<_ACEOF
12998 #line 12998 "configure"
12999 #include "confdefs.h"
13000 #include <stdlib.h>
13003 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13004 egrep "free" >/dev/null 2>&1; then
13007 ac_cv_header_stdc=no
13013 if test $ac_cv_header_stdc = yes; then
13014 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
13015 if test "$cross_compiling" = yes; then
13018 cat >conftest.$ac_ext <<_ACEOF
13019 #line 13019 "configure"
13020 #include "confdefs.h"
13022 #if ((' ' & 0x0FF) == 0x020)
13023 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
13024 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
13026 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
13027 || ('j' <= (c) && (c) <= 'r') \
13028 || ('s' <= (c) && (c) <= 'z'))
13029 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
13032 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
13037 for (i = 0; i < 256; i++)
13038 if (XOR (islower (i), ISLOWER (i))
13039 || toupper (i) != TOUPPER (i))
13040 $ac_main_return(2);
13041 $ac_main_return (0);
13044 rm -f conftest$ac_exeext
13045 if { (eval echo "$as_me:13045: \"$ac_link\"") >&5
13046 (eval $ac_link) 2>&5
13048 echo "$as_me:13048: \$? = $ac_status" >&5
13049 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13050 { (eval echo "$as_me:13050: \"$ac_try\"") >&5
13051 (eval $ac_try) 2>&5
13053 echo "$as_me:13053: \$? = $ac_status" >&5
13054 (exit $ac_status); }; }; then
13057 echo "$as_me: program exited with status $ac_status" >&5
13058 echo "$as_me: failed program was:" >&5
13059 cat conftest.$ac_ext >&5
13060 ac_cv_header_stdc=no
13062 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13066 echo "$as_me:13066: result: $ac_cv_header_stdc" >&5
13067 echo "${ECHO_T}$ac_cv_header_stdc" >&6
13068 if test $ac_cv_header_stdc = yes; then
13070 cat >>confdefs.h <<\EOF
13071 #define STDC_HEADERS 1
13076 ac_header_dirent=no
13077 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
13078 as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
13079 echo "$as_me:13079: checking for $ac_hdr that defines DIR" >&5
13080 echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
13081 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13082 echo $ECHO_N "(cached) $ECHO_C" >&6
13084 cat >conftest.$ac_ext <<_ACEOF
13085 #line 13085 "configure"
13086 #include "confdefs.h"
13087 #include <sys/types.h>
13099 rm -f conftest.$ac_objext
13100 if { (eval echo "$as_me:13100: \"$ac_compile\"") >&5
13101 (eval $ac_compile) 2>&5
13103 echo "$as_me:13103: \$? = $ac_status" >&5
13104 (exit $ac_status); } &&
13105 { ac_try='test -s conftest.$ac_objext'
13106 { (eval echo "$as_me:13106: \"$ac_try\"") >&5
13107 (eval $ac_try) 2>&5
13109 echo "$as_me:13109: \$? = $ac_status" >&5
13110 (exit $ac_status); }; }; then
13111 eval "$as_ac_Header=yes"
13113 echo "$as_me: failed program was:" >&5
13114 cat conftest.$ac_ext >&5
13115 eval "$as_ac_Header=no"
13117 rm -f conftest.$ac_objext conftest.$ac_ext
13119 echo "$as_me:13119: result: `eval echo '${'$as_ac_Header'}'`" >&5
13120 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13121 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13122 cat >>confdefs.h <<EOF
13123 #define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
13126 ac_header_dirent=$ac_hdr; break
13130 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
13131 if test $ac_header_dirent = dirent.h; then
13132 echo "$as_me:13132: checking for opendir in -ldir" >&5
13133 echo $ECHO_N "checking for opendir in -ldir... $ECHO_C" >&6
13134 if test "${ac_cv_lib_dir_opendir+set}" = set; then
13135 echo $ECHO_N "(cached) $ECHO_C" >&6
13137 ac_check_lib_save_LIBS=$LIBS
13139 cat >conftest.$ac_ext <<_ACEOF
13140 #line 13140 "configure"
13141 #include "confdefs.h"
13143 /* Override any gcc2 internal prototype to avoid an error. */
13147 /* We use char because int might match the return type of a gcc2
13148 builtin and then its argument prototype would still apply. */
13158 rm -f conftest.$ac_objext conftest$ac_exeext
13159 if { (eval echo "$as_me:13159: \"$ac_link\"") >&5
13160 (eval $ac_link) 2>&5
13162 echo "$as_me:13162: \$? = $ac_status" >&5
13163 (exit $ac_status); } &&
13164 { ac_try='test -s conftest$ac_exeext'
13165 { (eval echo "$as_me:13165: \"$ac_try\"") >&5
13166 (eval $ac_try) 2>&5
13168 echo "$as_me:13168: \$? = $ac_status" >&5
13169 (exit $ac_status); }; }; then
13170 ac_cv_lib_dir_opendir=yes
13172 echo "$as_me: failed program was:" >&5
13173 cat conftest.$ac_ext >&5
13174 ac_cv_lib_dir_opendir=no
13176 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13177 LIBS=$ac_check_lib_save_LIBS
13179 echo "$as_me:13179: result: $ac_cv_lib_dir_opendir" >&5
13180 echo "${ECHO_T}$ac_cv_lib_dir_opendir" >&6
13181 if test $ac_cv_lib_dir_opendir = yes; then
13186 echo "$as_me:13186: checking for opendir in -lx" >&5
13187 echo $ECHO_N "checking for opendir in -lx... $ECHO_C" >&6
13188 if test "${ac_cv_lib_x_opendir+set}" = set; then
13189 echo $ECHO_N "(cached) $ECHO_C" >&6
13191 ac_check_lib_save_LIBS=$LIBS
13193 cat >conftest.$ac_ext <<_ACEOF
13194 #line 13194 "configure"
13195 #include "confdefs.h"
13197 /* Override any gcc2 internal prototype to avoid an error. */
13201 /* We use char because int might match the return type of a gcc2
13202 builtin and then its argument prototype would still apply. */
13212 rm -f conftest.$ac_objext conftest$ac_exeext
13213 if { (eval echo "$as_me:13213: \"$ac_link\"") >&5
13214 (eval $ac_link) 2>&5
13216 echo "$as_me:13216: \$? = $ac_status" >&5
13217 (exit $ac_status); } &&
13218 { ac_try='test -s conftest$ac_exeext'
13219 { (eval echo "$as_me:13219: \"$ac_try\"") >&5
13220 (eval $ac_try) 2>&5
13222 echo "$as_me:13222: \$? = $ac_status" >&5
13223 (exit $ac_status); }; }; then
13224 ac_cv_lib_x_opendir=yes
13226 echo "$as_me: failed program was:" >&5
13227 cat conftest.$ac_ext >&5
13228 ac_cv_lib_x_opendir=no
13230 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13231 LIBS=$ac_check_lib_save_LIBS
13233 echo "$as_me:13233: result: $ac_cv_lib_x_opendir" >&5
13234 echo "${ECHO_T}$ac_cv_lib_x_opendir" >&6
13235 if test $ac_cv_lib_x_opendir = yes; then
13241 echo "$as_me:13241: checking whether time.h and sys/time.h may both be included" >&5
13242 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
13243 if test "${ac_cv_header_time+set}" = set; then
13244 echo $ECHO_N "(cached) $ECHO_C" >&6
13246 cat >conftest.$ac_ext <<_ACEOF
13247 #line 13247 "configure"
13248 #include "confdefs.h"
13249 #include <sys/types.h>
13250 #include <sys/time.h>
13256 if ((struct tm *) 0)
13262 rm -f conftest.$ac_objext
13263 if { (eval echo "$as_me:13263: \"$ac_compile\"") >&5
13264 (eval $ac_compile) 2>&5
13266 echo "$as_me:13266: \$? = $ac_status" >&5
13267 (exit $ac_status); } &&
13268 { ac_try='test -s conftest.$ac_objext'
13269 { (eval echo "$as_me:13269: \"$ac_try\"") >&5
13270 (eval $ac_try) 2>&5
13272 echo "$as_me:13272: \$? = $ac_status" >&5
13273 (exit $ac_status); }; }; then
13274 ac_cv_header_time=yes
13276 echo "$as_me: failed program was:" >&5
13277 cat conftest.$ac_ext >&5
13278 ac_cv_header_time=no
13280 rm -f conftest.$ac_objext conftest.$ac_ext
13282 echo "$as_me:13282: result: $ac_cv_header_time" >&5
13283 echo "${ECHO_T}$ac_cv_header_time" >&6
13284 if test $ac_cv_header_time = yes; then
13286 cat >>confdefs.h <<\EOF
13287 #define TIME_WITH_SYS_TIME 1
13292 ### checks for compiler characteristics
13294 ac_cpp='$CPP $CPPFLAGS'
13295 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
13296 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
13297 ac_compiler_gnu=$ac_cv_c_compiler_gnu
13298 ac_main_return=return
13300 echo "$as_me:13300: checking for an ANSI C-conforming const" >&5
13301 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
13302 if test "${ac_cv_c_const+set}" = set; then
13303 echo $ECHO_N "(cached) $ECHO_C" >&6
13305 cat >conftest.$ac_ext <<_ACEOF
13306 #line 13306 "configure"
13307 #include "confdefs.h"
13312 /* FIXME: Include the comments suggested by Paul. */
13313 #ifndef __cplusplus
13314 /* Ultrix mips cc rejects this. */
13315 typedef int charset[2];
13317 /* SunOS 4.1.1 cc rejects this. */
13318 char const *const *ccp;
13320 /* NEC SVR4.0.2 mips cc rejects this. */
13321 struct point {int x, y;};
13322 static struct point const zero = {0,0};
13323 /* AIX XL C 1.02.0.0 rejects this.
13324 It does not let you subtract one const X* pointer from another in
13325 an arm of an if-expression whose if-part is not a constant
13327 const char *g = "string";
13328 ccp = &g + (g ? g-g : 0);
13329 /* HPUX 7.0 cc rejects these. */
13332 ccp = (char const *const *) p;
13333 { /* SCO 3.2v4 cc rejects this. */
13335 char const *s = 0 ? (char *) 0 : (char const *) 0;
13339 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
13340 int x[] = {25, 17};
13341 const int *foo = &x[0];
13344 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
13345 typedef const int *iptr;
13349 { /* AIX XL C 1.02.0.0 rejects this saying
13350 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
13351 struct s { int j; const int *ap[3]; };
13352 struct s *b; b->j = 5;
13354 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
13355 const int foo = 10;
13363 rm -f conftest.$ac_objext
13364 if { (eval echo "$as_me:13364: \"$ac_compile\"") >&5
13365 (eval $ac_compile) 2>&5
13367 echo "$as_me:13367: \$? = $ac_status" >&5
13368 (exit $ac_status); } &&
13369 { ac_try='test -s conftest.$ac_objext'
13370 { (eval echo "$as_me:13370: \"$ac_try\"") >&5
13371 (eval $ac_try) 2>&5
13373 echo "$as_me:13373: \$? = $ac_status" >&5
13374 (exit $ac_status); }; }; then
13377 echo "$as_me: failed program was:" >&5
13378 cat conftest.$ac_ext >&5
13381 rm -f conftest.$ac_objext conftest.$ac_ext
13383 echo "$as_me:13383: result: $ac_cv_c_const" >&5
13384 echo "${ECHO_T}$ac_cv_c_const" >&6
13385 if test $ac_cv_c_const = no; then
13387 cat >>confdefs.h <<\EOF
13393 ### Checks for external-data
13395 echo "$as_me:13395: checking if data-only library module links" >&5
13396 echo $ECHO_N "checking if data-only library module links... $ECHO_C" >&6
13397 if test "${cf_cv_link_dataonly+set}" = set; then
13398 echo $ECHO_N "(cached) $ECHO_C" >&6
13402 cat >conftest.$ac_ext <<EOF
13403 #line 13403 "configure"
13404 int testdata[3] = { 123, 456, 789 };
13406 if { (eval echo "$as_me:13406: \"$ac_compile\"") >&5
13407 (eval $ac_compile) 2>&5
13409 echo "$as_me:13409: \$? = $ac_status" >&5
13410 (exit $ac_status); } ; then
13411 mv conftest.o data.o && \
13412 ( $AR $ARFLAGS conftest.a data.o ) 2>&5 1>/dev/null
13414 rm -f conftest.$ac_ext data.o
13415 cat >conftest.$ac_ext <<EOF
13416 #line 13416 "configure"
13420 ${cf_cv_main_return:-return}(1); /* I'm told this linker is broken */
13422 extern int testdata[3];
13423 return testdata[0] == 123
13424 && testdata[1] == 456
13425 && testdata[2] == 789;
13429 if { (eval echo "$as_me:13429: \"$ac_compile\"") >&5
13430 (eval $ac_compile) 2>&5
13432 echo "$as_me:13432: \$? = $ac_status" >&5
13433 (exit $ac_status); }; then
13434 mv conftest.o func.o && \
13435 ( $AR $ARFLAGS conftest.a func.o ) 2>&5 1>/dev/null
13437 rm -f conftest.$ac_ext func.o
13438 ( eval $RANLIB conftest.a ) 2>&5 >/dev/null
13439 cf_saveLIBS="$LIBS"
13440 LIBS="conftest.a $LIBS"
13441 if test "$cross_compiling" = yes; then
13442 cf_cv_link_dataonly=unknown
13444 cat >conftest.$ac_ext <<_ACEOF
13445 #line 13445 "configure"
13446 #include "confdefs.h"
13450 extern int testfunc();
13451 ${cf_cv_main_return:-return} (!testfunc());
13455 rm -f conftest$ac_exeext
13456 if { (eval echo "$as_me:13456: \"$ac_link\"") >&5
13457 (eval $ac_link) 2>&5
13459 echo "$as_me:13459: \$? = $ac_status" >&5
13460 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13461 { (eval echo "$as_me:13461: \"$ac_try\"") >&5
13462 (eval $ac_try) 2>&5
13464 echo "$as_me:13464: \$? = $ac_status" >&5
13465 (exit $ac_status); }; }; then
13466 cf_cv_link_dataonly=yes
13468 echo "$as_me: program exited with status $ac_status" >&5
13469 echo "$as_me: failed program was:" >&5
13470 cat conftest.$ac_ext >&5
13471 cf_cv_link_dataonly=no
13473 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13475 LIBS="$cf_saveLIBS"
13479 echo "$as_me:13479: result: $cf_cv_link_dataonly" >&5
13480 echo "${ECHO_T}$cf_cv_link_dataonly" >&6
13482 if test "$cf_cv_link_dataonly" = no ; then
13484 cat >>confdefs.h <<\EOF
13485 #define BROKEN_LINKER 1
13491 ### Checks for library functions.
13493 echo "$as_me:13493: checking for working mkstemp" >&5
13494 echo $ECHO_N "checking for working mkstemp... $ECHO_C" >&6
13495 if test "${cf_cv_func_mkstemp+set}" = set; then
13496 echo $ECHO_N "(cached) $ECHO_C" >&6
13500 if test "$cross_compiling" = yes; then
13501 cf_cv_func_mkstemp=maybe
13503 cat >conftest.$ac_ext <<_ACEOF
13504 #line 13504 "configure"
13505 #include "confdefs.h"
13507 #include <sys/types.h>
13508 #include <stdlib.h>
13510 #include <string.h>
13511 #include <sys/stat.h>
13514 char *tmpl = "conftestXXXXXX";
13522 for (n = 0; n < 2; ++n) {
13523 strcpy(name[n], tmpl);
13524 if ((fd = mkstemp(name[n])) >= 0) {
13525 if (!strcmp(name[n], tmpl)
13526 || stat(name[n], &sb) != 0
13527 || (sb.st_mode & S_IFMT) != S_IFREG
13528 || (sb.st_mode & 077) != 0) {
13535 && !strcmp(name[0], name[1]))
13537 ${cf_cv_main_return:-return}(result);
13541 rm -f conftest$ac_exeext
13542 if { (eval echo "$as_me:13542: \"$ac_link\"") >&5
13543 (eval $ac_link) 2>&5
13545 echo "$as_me:13545: \$? = $ac_status" >&5
13546 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13547 { (eval echo "$as_me:13547: \"$ac_try\"") >&5
13548 (eval $ac_try) 2>&5
13550 echo "$as_me:13550: \$? = $ac_status" >&5
13551 (exit $ac_status); }; }; then
13552 cf_cv_func_mkstemp=yes
13555 echo "$as_me: program exited with status $ac_status" >&5
13556 echo "$as_me: failed program was:" >&5
13557 cat conftest.$ac_ext >&5
13558 cf_cv_func_mkstemp=no
13561 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13565 echo "$as_me:13565: result: $cf_cv_func_mkstemp" >&5
13566 echo "${ECHO_T}$cf_cv_func_mkstemp" >&6
13567 if test "x$cf_cv_func_mkstemp" = xmaybe ; then
13568 echo "$as_me:13568: checking for mkstemp" >&5
13569 echo $ECHO_N "checking for mkstemp... $ECHO_C" >&6
13570 if test "${ac_cv_func_mkstemp+set}" = set; then
13571 echo $ECHO_N "(cached) $ECHO_C" >&6
13573 cat >conftest.$ac_ext <<_ACEOF
13574 #line 13574 "configure"
13575 #include "confdefs.h"
13576 /* System header to define __stub macros and hopefully few prototypes,
13577 which can conflict with char mkstemp (); below. */
13578 #include <assert.h>
13579 /* Override any gcc2 internal prototype to avoid an error. */
13583 /* We use char because int might match the return type of a gcc2
13584 builtin and then its argument prototype would still apply. */
13591 /* The GNU C library defines this for functions which it implements
13592 to always fail with ENOSYS. Some functions are actually named
13593 something starting with __ and the normal name is an alias. */
13594 #if defined (__stub_mkstemp) || defined (__stub___mkstemp)
13597 f = mkstemp; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
13604 rm -f conftest.$ac_objext conftest$ac_exeext
13605 if { (eval echo "$as_me:13605: \"$ac_link\"") >&5
13606 (eval $ac_link) 2>&5
13608 echo "$as_me:13608: \$? = $ac_status" >&5
13609 (exit $ac_status); } &&
13610 { ac_try='test -s conftest$ac_exeext'
13611 { (eval echo "$as_me:13611: \"$ac_try\"") >&5
13612 (eval $ac_try) 2>&5
13614 echo "$as_me:13614: \$? = $ac_status" >&5
13615 (exit $ac_status); }; }; then
13616 ac_cv_func_mkstemp=yes
13618 echo "$as_me: failed program was:" >&5
13619 cat conftest.$ac_ext >&5
13620 ac_cv_func_mkstemp=no
13622 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13624 echo "$as_me:13624: result: $ac_cv_func_mkstemp" >&5
13625 echo "${ECHO_T}$ac_cv_func_mkstemp" >&6
13628 if test "x$cf_cv_func_mkstemp" = xyes || test "x$ac_cv_func_mkstemp" = xyes ; then
13630 cat >>confdefs.h <<\EOF
13631 #define HAVE_MKSTEMP 1
13636 if test -z "$cf_user_CFLAGS" && test "$with_no_leaks" = no ; then
13637 CFLAGS=`echo ${CFLAGS} | sed -e 's%-g %%' -e 's%-g$%%'`
13638 CXXFLAGS=`echo ${CXXFLAGS} | sed -e 's%-g %%' -e 's%-g$%%'`
13642 if test "$cf_with_ada" != "no" ; then
13644 cf_ada_make=gnatmake
13645 # Extract the first word of "$cf_ada_make", so it can be a program name with args.
13646 set dummy $cf_ada_make; ac_word=$2
13647 echo "$as_me:13647: checking for $ac_word" >&5
13648 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
13649 if test "${ac_cv_prog_gnat_exists+set}" = set; then
13650 echo $ECHO_N "(cached) $ECHO_C" >&6
13652 if test -n "$gnat_exists"; then
13653 ac_cv_prog_gnat_exists="$gnat_exists" # Let the user override the test.
13655 ac_save_IFS=$IFS; IFS=$ac_path_separator
13657 for ac_dir in $ac_dummy; do
13659 test -z "$ac_dir" && ac_dir=.
13660 $as_executable_p "$ac_dir/$ac_word" || continue
13661 ac_cv_prog_gnat_exists="yes"
13662 echo "$as_me:13662: found $ac_dir/$ac_word" >&5
13666 test -z "$ac_cv_prog_gnat_exists" && ac_cv_prog_gnat_exists="no"
13669 gnat_exists=$ac_cv_prog_gnat_exists
13670 if test -n "$gnat_exists"; then
13671 echo "$as_me:13671: result: $gnat_exists" >&5
13672 echo "${ECHO_T}$gnat_exists" >&6
13674 echo "$as_me:13674: result: no" >&5
13675 echo "${ECHO_T}no" >&6
13678 if test "$ac_cv_prog_gnat_exists" = no; then
13680 cf_cv_prog_gnat_correct=no
13683 echo "$as_me:13683: checking for gnat version" >&5
13684 echo $ECHO_N "checking for gnat version... $ECHO_C" >&6
13685 cf_gnat_version=`${cf_ada_make:-gnatmake} -v 2>&1 | \
13686 grep '[0-9].[0-9][0-9]*' |\
13687 sed -e '2,$d' -e 's/[^0-9 \.]//g' -e 's/^[ ]*//' -e 's/ .*//'`
13688 echo "$as_me:13688: result: $cf_gnat_version" >&5
13689 echo "${ECHO_T}$cf_gnat_version" >&6
13691 case $cf_gnat_version in
13692 (3.1[1-9]*|3.[2-9]*|[4-9].*|20[0-9][0-9])
13693 cf_cv_prog_gnat_correct=yes
13696 { echo "$as_me:13696: WARNING: Unsupported GNAT version $cf_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&5
13697 echo "$as_me: WARNING: Unsupported GNAT version $cf_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&2;}
13698 cf_cv_prog_gnat_correct=no
13702 # Extract the first word of "m4", so it can be a program name with args.
13703 set dummy m4; ac_word=$2
13704 echo "$as_me:13704: checking for $ac_word" >&5
13705 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
13706 if test "${ac_cv_prog_M4_exists+set}" = set; then
13707 echo $ECHO_N "(cached) $ECHO_C" >&6
13709 if test -n "$M4_exists"; then
13710 ac_cv_prog_M4_exists="$M4_exists" # Let the user override the test.
13712 ac_save_IFS=$IFS; IFS=$ac_path_separator
13714 for ac_dir in $ac_dummy; do
13716 test -z "$ac_dir" && ac_dir=.
13717 $as_executable_p "$ac_dir/$ac_word" || continue
13718 ac_cv_prog_M4_exists="yes"
13719 echo "$as_me:13719: found $ac_dir/$ac_word" >&5
13723 test -z "$ac_cv_prog_M4_exists" && ac_cv_prog_M4_exists="no"
13726 M4_exists=$ac_cv_prog_M4_exists
13727 if test -n "$M4_exists"; then
13728 echo "$as_me:13728: result: $M4_exists" >&5
13729 echo "${ECHO_T}$M4_exists" >&6
13731 echo "$as_me:13731: result: no" >&5
13732 echo "${ECHO_T}no" >&6
13735 if test "$ac_cv_prog_M4_exists" = no; then
13736 cf_cv_prog_gnat_correct=no
13737 echo Ada95 binding required program m4 not found. Ada95 binding disabled.
13739 if test "$cf_cv_prog_gnat_correct" = yes; then
13740 echo "$as_me:13740: checking if GNAT works" >&5
13741 echo $ECHO_N "checking if GNAT works... $ECHO_C" >&6
13743 rm -rf conftest* *~conftest*
13744 cat >>conftest.ads <<CF_EOF
13745 procedure conftest;
13747 cat >>conftest.adb <<CF_EOF
13750 procedure conftest is
13752 Text_IO.Put ("Hello World");
13754 GNAT.OS_Lib.OS_Exit (0);
13757 if ( $cf_ada_make $ADAFLAGS conftest 1>&5 2>&1 ) ; then
13758 if ( ./conftest 1>&5 2>&1 ) ; then
13759 cf_cv_prog_gnat_correct=yes
13761 cf_cv_prog_gnat_correct=no
13764 cf_cv_prog_gnat_correct=no
13766 rm -rf conftest* *~conftest*
13768 echo "$as_me:13768: result: $cf_cv_prog_gnat_correct" >&5
13769 echo "${ECHO_T}$cf_cv_prog_gnat_correct" >&6
13773 if test "$cf_cv_prog_gnat_correct" = yes; then
13775 echo "$as_me:13775: checking optimization options for ADAFLAGS" >&5
13776 echo $ECHO_N "checking optimization options for ADAFLAGS... $ECHO_C" >&6
13780 ADAFLAGS="$ADAFLAGS -g"
13786 cf_O_flag=`echo "$CFLAGS" |sed -e 's/^.*-O/-O/' -e 's/[ ].*//'`
13788 ADAFLAGS="$ADAFLAGS $cf_O_flag"
13792 echo "$as_me:13792: result: $ADAFLAGS" >&5
13793 echo "${ECHO_T}$ADAFLAGS" >&6
13795 echo "$as_me:13795: checking if GNATPREP supports -T option" >&5
13796 echo $ECHO_N "checking if GNATPREP supports -T option... $ECHO_C" >&6
13797 if test "${cf_cv_gnatprep_opt_t+set}" = set; then
13798 echo $ECHO_N "(cached) $ECHO_C" >&6
13801 cf_cv_gnatprep_opt_t=no
13802 gnatprep -T 2>/dev/null >/dev/null && cf_cv_gnatprep_opt_t=yes
13805 echo "$as_me:13805: result: $cf_cv_gnatprep_opt_t" >&5
13806 echo "${ECHO_T}$cf_cv_gnatprep_opt_t" >&6
13807 test "$cf_cv_gnatprep_opt_t" = yes && GNATPREP_OPTS="-T $GNATPREP_OPTS"
13809 echo "$as_me:13809: checking if GNAT supports generics" >&5
13810 echo $ECHO_N "checking if GNAT supports generics... $ECHO_C" >&6
13811 case $cf_gnat_version in
13813 cf_gnat_generics=yes
13816 cf_gnat_generics=no
13819 echo "$as_me:13819: result: $cf_gnat_generics" >&5
13820 echo "${ECHO_T}$cf_gnat_generics" >&6
13822 if test "$cf_gnat_generics" = yes
13824 cf_compile_generics=generics
13825 cf_generic_objects="\${GENOBJS}"
13827 cf_compile_generics=
13828 cf_generic_objects=
13831 echo "$as_me:13831: checking if GNAT supports SIGINT" >&5
13832 echo $ECHO_N "checking if GNAT supports SIGINT... $ECHO_C" >&6
13833 if test "${cf_cv_gnat_sigint+set}" = set; then
13834 echo $ECHO_N "(cached) $ECHO_C" >&6
13837 rm -rf conftest* *~conftest*
13838 cat >>conftest.ads <<CF_EOF
13839 with Ada.Interrupts.Names;
13841 package ConfTest is
13843 pragma Warnings (Off); -- the next pragma exists since 3.11p
13844 pragma Unreserve_All_Interrupts;
13845 pragma Warnings (On);
13847 protected Process is
13849 function Continue return Boolean;
13850 pragma Attach_Handler (Stop, Ada.Interrupts.Names.SIGINT);
13852 Done : Boolean := False;
13857 cat >>conftest.adb <<CF_EOF
13858 package body ConfTest is
13859 protected body Process is
13864 function Continue return Boolean is
13871 if ( $cf_ada_make $ADAFLAGS conftest 1>&5 2>&1 ) ; then
13872 cf_cv_gnat_sigint=yes
13874 cf_cv_gnat_sigint=no
13876 rm -rf conftest* *~conftest*
13879 echo "$as_me:13879: result: $cf_cv_gnat_sigint" >&5
13880 echo "${ECHO_T}$cf_cv_gnat_sigint" >&6
13882 if test $cf_cv_gnat_sigint = yes ; then
13885 USE_GNAT_SIGINT="#"
13888 cf_gnat_libraries=no
13889 cf_gnat_projects=no
13891 if test "$enable_gnat_projects" != no ; then
13892 echo "$as_me:13892: checking if GNAT supports project files" >&5
13893 echo $ECHO_N "checking if GNAT supports project files... $ECHO_C" >&6
13894 case $cf_gnat_version in
13898 case $cf_cv_system_name in
13902 mkdir conftest.src conftest.bin conftest.lib
13904 rm -rf conftest* *~conftest*
13905 cat >>library.gpr <<CF_EOF
13907 Kind := External ("LIB_KIND");
13908 for Library_Name use "ConfTest";
13909 for Object_Dir use ".";
13910 for Library_ALI_Dir use External("LIBRARY_DIR");
13911 for Library_Version use External ("SONAME");
13912 for Library_Kind use Kind;
13913 for Library_Dir use External("BUILD_DIR");
13914 Source_Dir := External ("SOURCE_DIR");
13915 for Source_Dirs use (Source_Dir);
13918 cat >>confpackage.ads <<CF_EOF
13919 package ConfPackage is
13920 procedure conftest;
13923 cat >>confpackage.adb <<CF_EOF
13925 package body ConfPackage is
13926 procedure conftest is
13928 Text_IO.Put ("Hello World");
13933 if ( $cf_ada_make $ADAFLAGS \
13935 -XBUILD_DIR=`cd ../conftest.bin;pwd` \
13936 -XLIBRARY_DIR=`cd ../conftest.lib;pwd` \
13937 -XSOURCE_DIR=`pwd` \
13938 -XSONAME=libConfTest.so.1 \
13939 -XLIB_KIND=static 1>&5 2>&1 ) ; then
13940 cf_gnat_projects=yes
13943 if test -f conftest.lib/confpackage.ali
13945 cf_gnat_libraries=yes
13947 rm -rf conftest* *~conftest*
13952 echo "$as_me:13952: result: $cf_gnat_projects" >&5
13953 echo "${ECHO_T}$cf_gnat_projects" >&6
13954 fi # enable_gnat_projects
13956 if test $cf_gnat_projects = yes
13958 echo "$as_me:13958: checking if GNAT supports libraries" >&5
13959 echo $ECHO_N "checking if GNAT supports libraries... $ECHO_C" >&6
13960 echo "$as_me:13960: result: $cf_gnat_libraries" >&5
13961 echo "${ECHO_T}$cf_gnat_libraries" >&6
13964 if test "$cf_gnat_projects" = yes
13966 USE_OLD_MAKERULES="#"
13967 USE_GNAT_PROJECTS=""
13969 USE_OLD_MAKERULES=""
13970 USE_GNAT_PROJECTS="#"
13973 if test "$cf_gnat_libraries" = yes
13975 USE_GNAT_LIBRARIES=""
13977 USE_GNAT_LIBRARIES="#"
13980 echo "$as_me:13980: checking for ada-compiler" >&5
13981 echo $ECHO_N "checking for ada-compiler... $ECHO_C" >&6
13983 # Check whether --with-ada-compiler or --without-ada-compiler was given.
13984 if test "${with_ada_compiler+set}" = set; then
13985 withval="$with_ada_compiler"
13986 cf_ada_compiler=$withval
13988 cf_ada_compiler=gnatmake
13991 echo "$as_me:13991: result: $cf_ada_compiler" >&5
13992 echo "${ECHO_T}$cf_ada_compiler" >&6
13994 cf_ada_package=terminal_interface
13996 echo "$as_me:13996: checking for ada-include" >&5
13997 echo $ECHO_N "checking for ada-include... $ECHO_C" >&6
13999 # Check whether --with-ada-include or --without-ada-include was given.
14000 if test "${with_ada_include+set}" = set; then
14001 withval="$with_ada_include"
14004 withval="${ADA_INCLUDE:-$prefix/share/ada/adainclude}"
14005 fi; if test -n "$prefix/share/ada/adainclude" ; then
14007 if test "x$prefix" != xNONE; then
14008 cf_path_syntax="$prefix"
14010 cf_path_syntax="$ac_default_prefix"
14013 case ".$withval" in
14014 (.\$\(*\)*|.\'*\'*)
14018 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
14020 (.\${*prefix}*|.\${*dir}*)
14021 eval withval="$withval"
14022 case ".$withval" in
14024 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
14029 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
14032 { { echo "$as_me:14032: error: expected a pathname, not \"$withval\"" >&5
14033 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
14034 { (exit 1); exit 1; }; }
14039 eval ADA_INCLUDE="$withval"
14041 echo "$as_me:14041: result: $ADA_INCLUDE" >&5
14042 echo "${ECHO_T}$ADA_INCLUDE" >&6
14044 echo "$as_me:14044: checking for ada-objects" >&5
14045 echo $ECHO_N "checking for ada-objects... $ECHO_C" >&6
14047 # Check whether --with-ada-objects or --without-ada-objects was given.
14048 if test "${with_ada_objects+set}" = set; then
14049 withval="$with_ada_objects"
14052 withval="${ADA_OBJECTS:-$prefix/lib/ada/adalib}"
14053 fi; if test -n "$prefix/lib/ada/adalib" ; then
14055 if test "x$prefix" != xNONE; then
14056 cf_path_syntax="$prefix"
14058 cf_path_syntax="$ac_default_prefix"
14061 case ".$withval" in
14062 (.\$\(*\)*|.\'*\'*)
14066 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
14068 (.\${*prefix}*|.\${*dir}*)
14069 eval withval="$withval"
14070 case ".$withval" in
14072 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
14077 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
14080 { { echo "$as_me:14080: error: expected a pathname, not \"$withval\"" >&5
14081 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
14082 { (exit 1); exit 1; }; }
14087 eval ADA_OBJECTS="$withval"
14089 echo "$as_me:14089: result: $ADA_OBJECTS" >&5
14090 echo "${ECHO_T}$ADA_OBJECTS" >&6
14092 echo "$as_me:14092: checking if an Ada95 shared-library should be built" >&5
14093 echo $ECHO_N "checking if an Ada95 shared-library should be built... $ECHO_C" >&6
14095 # Check whether --with-ada-sharedlib or --without-ada-sharedlib was given.
14096 if test "${with_ada_sharedlib+set}" = set; then
14097 withval="$with_ada_sharedlib"
14098 with_ada_sharedlib=$withval
14100 with_ada_sharedlib=no
14102 echo "$as_me:14102: result: $with_ada_sharedlib" >&5
14103 echo "${ECHO_T}$with_ada_sharedlib" >&6
14105 ADA_SHAREDLIB='lib$(LIB_NAME).so.1'
14106 MAKE_ADA_SHAREDLIB="#"
14108 if test "x$with_ada_sharedlib" != xno
14110 MAKE_ADA_SHAREDLIB=
14111 if test "x$with_ada_sharedlib" != xyes
14113 ADA_SHAREDLIB="$with_ada_sharedlib"
14118 { { echo "$as_me:14118: error: No usable Ada compiler found" >&5
14119 echo "$as_me: error: No usable Ada compiler found" >&2;}
14120 { (exit 1); exit 1; }; }
14123 { { echo "$as_me:14123: error: The Ada compiler is needed for this package" >&5
14124 echo "$as_me: error: The Ada compiler is needed for this package" >&2;}
14125 { (exit 1); exit 1; }; }
14128 ################################################################################
14135 ### Construct the list of include-directories to be generated
14137 if test "$srcdir" != "."; then
14138 CPPFLAGS="-I\${srcdir}/../include $CPPFLAGS"
14140 CPPFLAGS="-I../include $CPPFLAGS"
14141 if test "$srcdir" != "."; then
14142 CPPFLAGS="-I\${srcdir} $CPPFLAGS"
14144 CPPFLAGS="-I. $CPPFLAGS"
14146 ACPPFLAGS="-I. -I../include -I../../include $ACPPFLAGS"
14147 if test "$srcdir" != "."; then
14148 ACPPFLAGS="-I\${srcdir}/../../include $ACPPFLAGS"
14150 if test "$GCC" != yes; then
14151 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
14152 elif test "$includedir" != "/usr/include"; then
14153 if test "$includedir" = '${prefix}/include' ; then
14154 if test x$prefix != x/usr ; then
14155 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
14158 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
14162 ### Build up pieces for makefile rules
14163 echo "$as_me:14163: checking default library suffix" >&5
14164 echo $ECHO_N "checking default library suffix... $ECHO_C" >&6
14166 case $DFT_LWR_MODEL in
14167 (libtool) DFT_ARG_SUFFIX='' ;;
14168 (normal) DFT_ARG_SUFFIX='' ;;
14169 (debug) DFT_ARG_SUFFIX='_g' ;;
14170 (profile) DFT_ARG_SUFFIX='_p' ;;
14171 (shared) DFT_ARG_SUFFIX='' ;;
14173 test -n "$LIB_SUFFIX" && DFT_ARG_SUFFIX="${LIB_SUFFIX}${DFT_ARG_SUFFIX}"
14174 echo "$as_me:14174: result: $DFT_ARG_SUFFIX" >&5
14175 echo "${ECHO_T}$DFT_ARG_SUFFIX" >&6
14177 echo "$as_me:14177: checking default library-dependency suffix" >&5
14178 echo $ECHO_N "checking default library-dependency suffix... $ECHO_C" >&6
14180 case X$DFT_LWR_MODEL in
14182 DFT_LIB_SUFFIX='.la'
14183 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14186 DFT_LIB_SUFFIX='_g.a'
14187 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14190 DFT_LIB_SUFFIX='_p.a'
14191 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14194 case $cf_cv_system_name in
14196 DFT_LIB_SUFFIX='.so'
14197 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14199 (cygwin*|msys*|mingw*)
14200 DFT_LIB_SUFFIX='.dll'
14201 DFT_DEP_SUFFIX='.dll.a'
14204 DFT_LIB_SUFFIX='.dylib'
14205 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14210 DFT_LIB_SUFFIX='.so'
14211 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14214 DFT_LIB_SUFFIX='.sl'
14215 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14220 DFT_LIB_SUFFIX='.so'
14221 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14226 DFT_LIB_SUFFIX='.a'
14227 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14230 if test -n "${LIB_SUFFIX}${EXTRA_SUFFIX}"
14232 DFT_LIB_SUFFIX="${LIB_SUFFIX}${EXTRA_SUFFIX}${DFT_LIB_SUFFIX}"
14233 DFT_DEP_SUFFIX="${LIB_SUFFIX}${EXTRA_SUFFIX}${DFT_DEP_SUFFIX}"
14235 echo "$as_me:14235: result: $DFT_DEP_SUFFIX" >&5
14236 echo "${ECHO_T}$DFT_DEP_SUFFIX" >&6
14238 echo "$as_me:14238: checking default object directory" >&5
14239 echo $ECHO_N "checking default object directory... $ECHO_C" >&6
14241 case $DFT_LWR_MODEL in
14242 (libtool) DFT_OBJ_SUBDIR='obj_lo' ;;
14243 (normal) DFT_OBJ_SUBDIR='objects' ;;
14244 (debug) DFT_OBJ_SUBDIR='obj_g' ;;
14245 (profile) DFT_OBJ_SUBDIR='obj_p' ;;
14247 case $cf_cv_system_name in
14249 DFT_OBJ_SUBDIR='objects' ;;
14251 DFT_OBJ_SUBDIR='obj_s' ;;
14254 echo "$as_me:14254: result: $DFT_OBJ_SUBDIR" >&5
14255 echo "${ECHO_T}$DFT_OBJ_SUBDIR" >&6
14257 ### Set up low-level terminfo dependencies for makefiles.
14259 if test "$DFT_LWR_MODEL" = shared ; then
14260 case $cf_cv_system_name in
14262 # "lib" files have ".dll.a" suffix, "cyg" files have ".dll"
14265 # "lib" files have ".dll.a" suffix, "msys-" files have ".dll"
14270 USE_CFG_SUFFIX=${DFT_ARG_SUFFIX}
14272 ### Construct the list of subdirectories for which we'll customize makefiles
14273 ### with the appropriate compile-rules.
14275 SUB_MAKEFILES="gen/adacurses${USE_ARG_SUFFIX}-config:gen/adacurses-config.in"
14277 cat >>confdefs.h <<EOF
14278 #define NCURSES_PATHSEP '$PATH_SEPARATOR'
14281 ### Now that we're done running tests, add the compiler-warnings, if any
14286 cf_new_extra_cppflags=
14288 for cf_add_cflags in $EXTRA_CFLAGS
14290 case $cf_fix_cppflags in
14292 case $cf_add_cflags in
14293 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14294 case $cf_add_cflags in
14296 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14298 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14299 && test -z "${cf_tst_cflags}" \
14300 && cf_fix_cppflags=yes
14302 if test $cf_fix_cppflags = yes ; then
14303 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
14305 elif test "${cf_tst_cflags}" = "\"'" ; then
14306 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
14311 case "$CPPFLAGS" in
14315 case $cf_add_cflags in
14317 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14319 CPPFLAGS=`echo "$CPPFLAGS" | \
14320 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14321 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14325 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
14330 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
14335 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
14337 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14339 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14340 && test -z "${cf_tst_cflags}" \
14341 && cf_fix_cppflags=no
14346 if test -n "$cf_new_cflags" ; then
14348 CFLAGS="$CFLAGS $cf_new_cflags"
14351 if test -n "$cf_new_cppflags" ; then
14353 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
14356 if test -n "$cf_new_extra_cppflags" ; then
14358 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
14361 ################################################################################
14367 NCURSES_SHLIB2="sh -c"
14369 ADA_SUBDIRS="include gen src doc"
14370 if test "x$cf_with_tests" != "xno" ; then
14371 ADA_SUBDIRS="$ADA_SUBDIRS samples"
14373 for cf_dir in $ADA_SUBDIRS
14375 SUB_MAKEFILES="$SUB_MAKEFILES $cf_dir/Makefile"
14382 # match layout used by make-tar.sh
14383 ADAHTML_DIR=../doc/ada
14385 if test "x$cross_compiling" = xyes ; then
14386 ADAGEN_LDFLAGS='$(CROSS_LDFLAGS)'
14388 ADAGEN_LDFLAGS='$(NATIVE_LDFLAGS)'
14391 ac_config_files="$ac_config_files $SUB_MAKEFILES doc/adacurses${DFT_ARG_SUFFIX}-config.1:doc/MKada_config.in Makefile"
14392 ac_config_commands="$ac_config_commands default"
14393 cat >confcache <<\_ACEOF
14394 # This file is a shell script that caches the results of configure
14395 # tests run on this system so they can be shared between configure
14396 # scripts and configure runs, see configure's option --config-cache.
14397 # It is not useful on other systems. If it contains results you don't
14398 # want to keep, you may remove or edit it.
14400 # config.status only pays attention to the cache file if you give it
14401 # the --recheck option to rerun configure.
14403 # `ac_cv_env_foo' variables (set or unset) will be overriden when
14404 # loading this file, other *unset* `ac_cv_foo' will be assigned the
14405 # following values.
14409 # The following way of writing the cache mishandles newlines in values,
14410 # but we know of no workaround that is simple, portable, and efficient.
14411 # So, don't put newlines in cache variables' values.
14412 # Ultrix sh set writes to stderr and can't be redirected directly,
14413 # and sets the high bit in the cache file unless we assign to the vars.
14416 case `(ac_space=' '; set | grep ac_space) 2>&1` in
14418 # `set' does not quote correctly, so add quotes (double-quote
14419 # substitution turns \\\\ into \\, and sed turns \\ into \).
14422 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
14425 # `set' quotes correctly as required by POSIX, so do not add quotes.
14427 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
14434 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
14436 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
14438 if cmp -s $cache_file confcache; then :; else
14439 if test -w $cache_file; then
14440 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
14441 cat confcache >$cache_file
14443 echo "not updating unwritable cache $cache_file"
14448 test "x$prefix" = xNONE && prefix=$ac_default_prefix
14449 # Let make expand exec_prefix.
14450 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
14452 # VPATH may cause trouble with some makes, so we remove $(srcdir),
14453 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
14454 # trailing colons and then remove the whole line if VPATH becomes empty
14455 # (actually we leave an empty line to preserve line numbers).
14456 if test "x$srcdir" = x.; then
14457 ac_vpsub='/^[ ]*VPATH[ ]*=/{
14458 s/:*\$(srcdir):*/:/;
14459 s/:*\${srcdir}:*/:/;
14461 s/^\([^=]*=[ ]*\):*/\1/;
14467 DEFS=-DHAVE_CONFIG_H
14469 : ${CONFIG_STATUS=./config.status}
14470 ac_clean_files_save=$ac_clean_files
14471 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
14472 { echo "$as_me:14472: creating $CONFIG_STATUS" >&5
14473 echo "$as_me: creating $CONFIG_STATUS" >&6;}
14474 cat >$CONFIG_STATUS <<_ACEOF
14476 # Generated automatically by configure.
14477 # Run this file to recreate the current configuration.
14478 # Compiler output produced by configure, useful for debugging
14479 # configure, is in config.log if it exists.
14482 SHELL=\${CONFIG_SHELL-$SHELL}
14483 ac_cs_invocation="\$0 \$@"
14487 cat >>$CONFIG_STATUS <<\_ACEOF
14488 # Be Bourne compatible
14489 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
14492 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
14496 # Name of the executable.
14497 as_me=`echo "$0" |sed 's,.*[\\/],,'`
14499 if expr a : '\(a\)' >/dev/null 2>&1; then
14505 rm -f conf$$ conf$$.exe conf$$.file
14507 if ln -s conf$$.file conf$$ 2>/dev/null; then
14508 # We could just check for DJGPP; but this test a) works b) is more generic
14509 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
14510 if test -f conf$$.exe; then
14511 # Don't use ln at all; we don't have any links
14516 elif ln conf$$.file conf$$ 2>/dev/null; then
14521 rm -f conf$$ conf$$.exe conf$$.file
14523 as_executable_p="test -f"
14525 # Support unset when possible.
14526 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
14533 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
14534 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
14535 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
14536 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
14537 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
14538 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
14539 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
14540 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
14543 # We need space, tab and new line, in precisely that order.
14549 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
14555 # Files that config.status was made for.
14556 if test -n "$ac_config_files"; then
14557 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
14560 if test -n "$ac_config_headers"; then
14561 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
14564 if test -n "$ac_config_links"; then
14565 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
14568 if test -n "$ac_config_commands"; then
14569 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
14572 cat >>$CONFIG_STATUS <<\EOF
14575 \`$as_me' instantiates files from templates according to the
14576 current configuration.
14578 Usage: $0 [OPTIONS] [FILE]...
14580 -h, --help print this help, then exit
14581 -V, --version print version number, then exit
14582 -d, --debug don't remove temporary files
14583 --recheck update $as_me by reconfiguring in the same conditions
14584 --file=FILE[:TEMPLATE]
14585 instantiate the configuration file FILE
14586 --header=FILE[:TEMPLATE]
14587 instantiate the configuration header FILE
14589 Configuration files:
14592 Configuration headers:
14595 Configuration commands:
14598 Report bugs to <dickey@invisible-island.net>."
14601 cat >>$CONFIG_STATUS <<EOF
14604 configured by $0, generated by GNU Autoconf 2.52.20150926,
14605 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
14607 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
14608 Free Software Foundation, Inc.
14609 This config.status script is free software; the Free Software Foundation
14610 gives unlimited permission to copy, distribute and modify it."
14615 cat >>$CONFIG_STATUS <<\EOF
14616 # If no file are specified by the user, then we need to provide default
14617 # value. By we need to know if files were specified by the user.
14623 ac_option=`expr "x$1" : 'x\([^=]*\)='`
14624 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
14626 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
14630 *) # This is not an option, so the user has probably given explicit
14632 ac_need_defaults=false;;
14636 # Handling of the options.
14638 cat >>$CONFIG_STATUS <<EOF
14639 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
14640 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
14641 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
14643 cat >>$CONFIG_STATUS <<\EOF
14644 --version | --vers* | -V )
14645 echo "$ac_cs_version"; exit 0 ;;
14647 # Conflict between --help and --header
14648 { { echo "$as_me:14648: error: ambiguous option: $1
14649 Try \`$0 --help' for more information." >&5
14650 echo "$as_me: error: ambiguous option: $1
14651 Try \`$0 --help' for more information." >&2;}
14652 { (exit 1); exit 1; }; };;
14653 --help | --hel | -h )
14654 echo "$ac_cs_usage"; exit 0 ;;
14655 --debug | --d* | -d )
14657 --file | --fil | --fi | --f )
14659 CONFIG_FILES="$CONFIG_FILES $1"
14660 ac_need_defaults=false;;
14661 --header | --heade | --head | --hea )
14663 CONFIG_HEADERS="$CONFIG_HEADERS $1"
14664 ac_need_defaults=false;;
14666 # This is an error.
14667 -*) { { echo "$as_me:14667: error: unrecognized option: $1
14668 Try \`$0 --help' for more information." >&5
14669 echo "$as_me: error: unrecognized option: $1
14670 Try \`$0 --help' for more information." >&2;}
14671 { (exit 1); exit 1; }; } ;;
14673 *) ac_config_targets="$ac_config_targets $1" ;;
14682 ## ----------------------- ##
14683 ## Running config.status. ##
14684 ## ----------------------- ##
14686 This file was extended by $as_me 2.52.20150926, executed with
14687 CONFIG_FILES = $CONFIG_FILES
14688 CONFIG_HEADERS = $CONFIG_HEADERS
14689 CONFIG_LINKS = $CONFIG_LINKS
14690 CONFIG_COMMANDS = $CONFIG_COMMANDS
14691 > $ac_cs_invocation
14692 on `(hostname || uname -n) 2>/dev/null | sed 1q`
14697 cat >>$CONFIG_STATUS <<EOF
14699 # INIT-COMMANDS section.
14702 ### Special initialization commands, used to pass information from the
14703 ### configuration-run into config.status
14706 DFT_ARG_SUFFIX="$DFT_ARG_SUFFIX"
14707 DFT_LWR_MODEL="$DFT_LWR_MODEL"
14708 LIB_NAME="$LIB_NAME"
14709 LIB_PREFIX="$LIB_PREFIX"
14710 LIB_SUFFIX="$LIB_SUFFIX"
14712 NCURSES_MAJOR="$NCURSES_MAJOR"
14713 NCURSES_MINOR="$NCURSES_MINOR"
14714 NCURSES_PATCH="$NCURSES_PATCH"
14715 USE_OLD_MAKERULES="$USE_OLD_MAKERULES"
14716 cf_cv_abi_version="$cf_cv_abi_version"
14717 cf_cv_rel_version="$cf_cv_rel_version"
14718 cf_cv_rm_so_locs="$cf_cv_rm_so_locs"
14719 cf_cv_shared_soname='$cf_cv_shared_soname'
14720 cf_cv_shlib_version="$cf_cv_shlib_version"
14721 cf_cv_shlib_version_infix="$cf_cv_shlib_version_infix"
14722 cf_cv_system_name="$cf_cv_system_name"
14728 cat >>$CONFIG_STATUS <<\EOF
14729 for ac_config_target in $ac_config_targets
14731 case "$ac_config_target" in
14732 # Handling of arguments.
14733 "$SUB_MAKEFILES" ) CONFIG_FILES="$CONFIG_FILES $SUB_MAKEFILES" ;;
14734 "doc/adacurses${DFT_ARG_SUFFIX}-config.1" ) CONFIG_FILES="$CONFIG_FILES doc/adacurses${DFT_ARG_SUFFIX}-config.1:doc/MKada_config.in" ;;
14735 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
14736 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
14737 "include/ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/ncurses_cfg.h:include/ncurses_cfg.hin" ;;
14738 *) { { echo "$as_me:14738: error: invalid argument: $ac_config_target" >&5
14739 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
14740 { (exit 1); exit 1; }; };;
14744 # If the user did not use the arguments to specify the items to instantiate,
14745 # then the envvar interface is used. Set only those that are not.
14746 # We use the long form for the default assignment because of an extremely
14747 # bizarre bug on SunOS 4.1.3.
14748 if $ac_need_defaults; then
14749 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
14750 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
14751 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
14754 # Create a temporary directory, and hook for its removal unless debugging.
14757 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
14758 trap '{ (exit 1); exit 1; }' 1 2 13 15
14761 # Create a (secure) tmp directory for tmp files.
14764 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
14765 test -n "$tmp" && test -d "$tmp"
14768 tmp=$TMPDIR/cs$$-$RANDOM
14769 (umask 077 && mkdir $tmp)
14772 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
14773 { (exit 1); exit 1; }
14778 cat >>$CONFIG_STATUS <<EOF
14781 # CONFIG_FILES section.
14784 # No need to generate the scripts if there are no CONFIG_FILES.
14785 # This happens for instance when ./config.status config.h
14786 if test -n "\$CONFIG_FILES"; then
14787 # Protect against being on the right side of a sed subst in config.status.
14788 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
14789 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
14790 s,@SHELL@,$SHELL,;t t
14791 s,@exec_prefix@,$exec_prefix,;t t
14792 s,@prefix@,$prefix,;t t
14793 s,@program_transform_name@,$program_transform_name,;t t
14794 s,@bindir@,$bindir,;t t
14795 s,@sbindir@,$sbindir,;t t
14796 s,@libexecdir@,$libexecdir,;t t
14797 s,@datarootdir@,$datarootdir,;t t
14798 s,@datadir@,$datadir,;t t
14799 s,@sysconfdir@,$sysconfdir,;t t
14800 s,@sharedstatedir@,$sharedstatedir,;t t
14801 s,@localstatedir@,$localstatedir,;t t
14802 s,@libdir@,$libdir,;t t
14803 s,@includedir@,$includedir,;t t
14804 s,@oldincludedir@,$oldincludedir,;t t
14805 s,@infodir@,$infodir,;t t
14806 s,@mandir@,$mandir,;t t
14807 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
14808 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
14809 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
14810 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
14811 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
14812 s,@build_alias@,$build_alias,;t t
14813 s,@host_alias@,$host_alias,;t t
14814 s,@target_alias@,$target_alias,;t t
14815 s,@ECHO_C@,$ECHO_C,;t t
14816 s,@ECHO_N@,$ECHO_N,;t t
14817 s,@ECHO_T@,$ECHO_T,;t t
14818 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
14819 s,@DEFS@,$DEFS,;t t
14820 s,@LIBS@,$LIBS,;t t
14821 s,@top_builddir@,$top_builddir,;t t
14822 s,@build@,$build,;t t
14823 s,@build_cpu@,$build_cpu,;t t
14824 s,@build_vendor@,$build_vendor,;t t
14825 s,@build_os@,$build_os,;t t
14826 s,@host@,$host,;t t
14827 s,@host_cpu@,$host_cpu,;t t
14828 s,@host_vendor@,$host_vendor,;t t
14829 s,@host_os@,$host_os,;t t
14830 s,@target@,$target,;t t
14831 s,@target_cpu@,$target_cpu,;t t
14832 s,@target_vendor@,$target_vendor,;t t
14833 s,@target_os@,$target_os,;t t
14835 s,@CFLAGS@,$CFLAGS,;t t
14836 s,@LDFLAGS@,$LDFLAGS,;t t
14837 s,@CPPFLAGS@,$CPPFLAGS,;t t
14838 s,@ac_ct_CC@,$ac_ct_CC,;t t
14839 s,@EXEEXT@,$EXEEXT,;t t
14840 s,@OBJEXT@,$OBJEXT,;t t
14841 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
14844 s,@EGREP@,$EGREP,;t t
14845 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
14846 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
14847 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
14848 s,@LN_S@,$LN_S,;t t
14849 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
14850 s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t
14851 s,@PKG_CONFIG_LIBDIR@,$PKG_CONFIG_LIBDIR,;t t
14852 s,@SET_MAKE@,$SET_MAKE,;t t
14853 s,@CTAGS@,$CTAGS,;t t
14854 s,@ETAGS@,$ETAGS,;t t
14855 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
14856 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
14857 s,@cf_cv_makeflags@,$cf_cv_makeflags,;t t
14858 s,@RANLIB@,$RANLIB,;t t
14859 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
14861 s,@ac_ct_LD@,$ac_ct_LD,;t t
14863 s,@ac_ct_AR@,$ac_ct_AR,;t t
14864 s,@ARFLAGS@,$ARFLAGS,;t t
14865 s,@DESTDIR@,$DESTDIR,;t t
14866 s,@BUILD_CC@,$BUILD_CC,;t t
14867 s,@BUILD_CPP@,$BUILD_CPP,;t t
14868 s,@BUILD_CFLAGS@,$BUILD_CFLAGS,;t t
14869 s,@BUILD_CPPFLAGS@,$BUILD_CPPFLAGS,;t t
14870 s,@BUILD_LDFLAGS@,$BUILD_LDFLAGS,;t t
14871 s,@BUILD_LIBS@,$BUILD_LIBS,;t t
14872 s,@BUILD_EXEEXT@,$BUILD_EXEEXT,;t t
14873 s,@BUILD_OBJEXT@,$BUILD_OBJEXT,;t t
14874 s,@DFT_LWR_MODEL@,$DFT_LWR_MODEL,;t t
14875 s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t
14876 s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
14877 s,@ac_ct_NCURSES_CONFIG@,$ac_ct_NCURSES_CONFIG,;t t
14878 s,@NCURSES_MAJOR@,$NCURSES_MAJOR,;t t
14879 s,@NCURSES_MINOR@,$NCURSES_MINOR,;t t
14880 s,@NCURSES_PATCH@,$NCURSES_PATCH,;t t
14881 s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t
14882 s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t
14883 s,@cf_cv_builtin_bool@,$cf_cv_builtin_bool,;t t
14884 s,@cf_cv_header_stdbool_h@,$cf_cv_header_stdbool_h,;t t
14885 s,@cf_cv_type_of_bool@,$cf_cv_type_of_bool,;t t
14886 s,@LIB_PREFIX@,$LIB_PREFIX,;t t
14887 s,@LIB_SUFFIX@,$LIB_SUFFIX,;t t
14888 s,@CC_G_OPT@,$CC_G_OPT,;t t
14889 s,@LD_MODEL@,$LD_MODEL,;t t
14890 s,@shlibdir@,$shlibdir,;t t
14891 s,@MAKE_DLLS@,$MAKE_DLLS,;t t
14892 s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t
14893 s,@LD_RPATH_OPT@,$LD_RPATH_OPT,;t t
14894 s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t
14895 s,@MK_SHARED_LIB@,$MK_SHARED_LIB,;t t
14896 s,@RM_SHARED_OPTS@,$RM_SHARED_OPTS,;t t
14897 s,@LINK_PROGS@,$LINK_PROGS,;t t
14898 s,@LINK_TESTS@,$LINK_TESTS,;t t
14899 s,@EXTRA_LDFLAGS@,$EXTRA_LDFLAGS,;t t
14900 s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
14901 s,@LOCAL_LDFLAGS2@,$LOCAL_LDFLAGS2,;t t
14902 s,@INSTALL_LIB@,$INSTALL_LIB,;t t
14903 s,@RPATH_LIST@,$RPATH_LIST,;t t
14904 s,@BROKEN_LINKER@,$BROKEN_LINKER,;t t
14905 s,@NCURSES_EXT_FUNCS@,$NCURSES_EXT_FUNCS,;t t
14906 s,@NCURSES_CONST@,$NCURSES_CONST,;t t
14907 s,@PTHREAD@,$PTHREAD,;t t
14908 s,@cf_cv_enable_reentrant@,$cf_cv_enable_reentrant,;t t
14909 s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
14910 s,@ECHO_LT@,$ECHO_LT,;t t
14911 s,@ECHO_LD@,$ECHO_LD,;t t
14912 s,@RULE_CC@,$RULE_CC,;t t
14913 s,@SHOW_CC@,$SHOW_CC,;t t
14914 s,@ECHO_CC@,$ECHO_CC,;t t
14915 s,@ADAFLAGS@,$ADAFLAGS,;t t
14916 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
14917 s,@ADA_TRACE@,$ADA_TRACE,;t t
14918 s,@gnat_exists@,$gnat_exists,;t t
14919 s,@M4_exists@,$M4_exists,;t t
14920 s,@cf_ada_make@,$cf_ada_make,;t t
14921 s,@GNATPREP_OPTS@,$GNATPREP_OPTS,;t t
14922 s,@cf_compile_generics@,$cf_compile_generics,;t t
14923 s,@cf_generic_objects@,$cf_generic_objects,;t t
14924 s,@USE_GNAT_SIGINT@,$USE_GNAT_SIGINT,;t t
14925 s,@USE_OLD_MAKERULES@,$USE_OLD_MAKERULES,;t t
14926 s,@USE_GNAT_PROJECTS@,$USE_GNAT_PROJECTS,;t t
14927 s,@USE_GNAT_LIBRARIES@,$USE_GNAT_LIBRARIES,;t t
14928 s,@cf_ada_compiler@,$cf_ada_compiler,;t t
14929 s,@cf_ada_package@,$cf_ada_package,;t t
14930 s,@ADA_INCLUDE@,$ADA_INCLUDE,;t t
14931 s,@ADA_OBJECTS@,$ADA_OBJECTS,;t t
14932 s,@ADA_SHAREDLIB@,$ADA_SHAREDLIB,;t t
14933 s,@MAKE_ADA_SHAREDLIB@,$MAKE_ADA_SHAREDLIB,;t t
14934 s,@TINFO_LDFLAGS2@,$TINFO_LDFLAGS2,;t t
14935 s,@TINFO_LIBS@,$TINFO_LIBS,;t t
14936 s,@ACPPFLAGS@,$ACPPFLAGS,;t t
14937 s,@DFT_ARG_SUFFIX@,$DFT_ARG_SUFFIX,;t t
14938 s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t
14939 s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t
14940 s,@USE_CFG_SUFFIX@,$USE_CFG_SUFFIX,;t t
14941 s,@TEST_ARG2@,$TEST_ARG2,;t t
14942 s,@TEST_LIBS2@,$TEST_LIBS2,;t t
14943 s,@NCURSES_SHLIB2@,$NCURSES_SHLIB2,;t t
14944 s,@ADA_SUBDIRS@,$ADA_SUBDIRS,;t t
14945 s,@NCURSES_TREE@,$NCURSES_TREE,;t t
14946 s,@EXTERNAL_TREE@,$EXTERNAL_TREE,;t t
14947 s,@ADAHTML_DIR@,$ADAHTML_DIR,;t t
14948 s,@ADAGEN_LDFLAGS@,$ADAGEN_LDFLAGS,;t t
14953 cat >>$CONFIG_STATUS <<\EOF
14954 # Split the substitutions into bite-sized pieces for seds with
14955 # small command number limits, like on Digital OSF/1 and HP-UX.
14956 ac_max_sed_lines=48
14957 ac_sed_frag=1 # Number of current file.
14958 ac_beg=1 # First line for current file.
14959 ac_end=$ac_max_sed_lines # Line after last line for current file.
14962 while $ac_more_lines; do
14963 if test $ac_beg -gt 1; then
14964 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
14966 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
14968 if test ! -s $tmp/subs.frag; then
14969 ac_more_lines=false
14971 # The purpose of the label and of the branching condition is to
14972 # speed up the sed processing (if there are no `@' at all, there
14973 # is no need to browse any of the substitutions).
14974 # These are the two extra sed commands mentioned above.
14976 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
14977 # It is possible to make a multiline substitution using escaped newlines.
14978 # Ensure that we do not split the substitution between script fragments.
14980 ac_END=`expr $ac_end + $ac_max_sed_lines`
14981 sed "1,${ac_BEG}d; ${ac_END}p; q" $tmp/subs.sed >$tmp/subs.next
14982 if test -s $tmp/subs.next; then
14983 grep '^s,@[^@,][^@,]*@,.*\\$' $tmp/subs.next >$tmp/subs.edit
14984 if test ! -s $tmp/subs.edit; then
14985 grep "^s,@[^@,][^@,]*@,.*,;t t$" $tmp/subs.next >$tmp/subs.edit
14986 if test ! -s $tmp/subs.edit; then
14987 if test $ac_beg -gt 1; then
14988 ac_end=`expr $ac_end - 1`
14995 if test -z "$ac_sed_cmds"; then
14996 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
14998 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
15000 ac_sed_frag=`expr $ac_sed_frag + 1`
15002 ac_end=`expr $ac_end + $ac_max_sed_lines`
15005 if test -z "$ac_sed_cmds"; then
15008 fi # test -n "$CONFIG_FILES"
15011 cat >>$CONFIG_STATUS <<\EOF
15012 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
15013 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
15015 - | *:- | *:-:* ) # input from stdin
15017 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15018 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15019 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15020 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15021 * ) ac_file_in=$ac_file.in ;;
15024 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
15025 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15026 X"$ac_file" : 'X\(//\)[^/]' \| \
15027 X"$ac_file" : 'X\(//\)$' \| \
15028 X"$ac_file" : 'X\(/\)' \| \
15029 . : '\(.\)' 2>/dev/null ||
15031 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
15032 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
15033 /^X\(\/\/\)$/{ s//\1/; q; }
15034 /^X\(\/\).*/{ s//\1/; q; }
15036 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
15037 { case "$ac_dir" in
15038 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
15042 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
15043 case $as_mkdir_dir in
15044 # Skip DOS drivespec
15045 ?:) as_incr_dir=$as_mkdir_dir ;;
15047 as_incr_dir=$as_incr_dir/$as_mkdir_dir
15048 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
15053 ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
15054 # A "../" for each directory in $ac_dir_suffix.
15055 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
15057 ac_dir_suffix= ac_dots=
15062 if test -z "$ac_dots"; then
15065 ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
15067 [\\/]* | ?:[\\/]* )
15068 ac_srcdir=$srcdir$ac_dir_suffix;
15069 ac_top_srcdir=$srcdir ;;
15070 *) # Relative path.
15071 ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
15072 ac_top_srcdir=$ac_dots$srcdir ;;
15076 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
15077 *) ac_INSTALL=$ac_dots$INSTALL ;;
15080 if test x"$ac_file" != x-; then
15081 { echo "$as_me:15081: creating $ac_file" >&5
15082 echo "$as_me: creating $ac_file" >&6;}
15085 # Let's still pretend it is `configure' which instantiates (i.e., don't
15086 # use $as_me), people would be surprised to read:
15087 # /* config.h. Generated automatically by config.status. */
15088 configure_input="Generated automatically from `echo $ac_file_in |
15089 sed 's,.*/,,'` by configure."
15091 # First look for the input files in the build tree, otherwise in the
15093 ac_file_inputs=`IFS=:
15094 for f in $ac_file_in; do
15096 -) echo $tmp/stdin ;;
15098 # Absolute (can't be DOS-style, as IFS=:)
15099 test -f "$f" || { { echo "$as_me:15099: error: cannot find input file: $f" >&5
15100 echo "$as_me: error: cannot find input file: $f" >&2;}
15101 { (exit 1); exit 1; }; }
15104 if test -f "$f"; then
15107 elif test -f "$srcdir/$f"; then
15112 { { echo "$as_me:15112: error: cannot find input file: $f" >&5
15113 echo "$as_me: error: cannot find input file: $f" >&2;}
15114 { (exit 1); exit 1; }; }
15117 done` || { (exit 1); exit 1; }
15119 cat >>$CONFIG_STATUS <<\EOF
15120 ac_warn_datarootdir=no
15121 if test x"$ac_file" != x-; then
15122 for ac_item in $ac_file_inputs
15124 ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' $ac_item`
15125 if test -n "$ac_seen"; then
15126 ac_used=`grep '@datarootdir@' $ac_item`
15127 if test -z "$ac_used"; then
15128 { echo "$as_me:15128: WARNING: datarootdir was used implicitly but not set:
15130 echo "$as_me: WARNING: datarootdir was used implicitly but not set:
15132 ac_warn_datarootdir=yes
15135 ac_seen=`grep '${datarootdir}' $ac_item`
15136 if test -n "$ac_seen"; then
15137 { echo "$as_me:15137: WARNING: datarootdir was used explicitly but not set:
15139 echo "$as_me: WARNING: datarootdir was used explicitly but not set:
15141 ac_warn_datarootdir=yes
15146 if test "x$ac_warn_datarootdir" = xyes; then
15147 ac_sed_cmds="$ac_sed_cmds | sed -e 's,@datarootdir@,\${prefix}/share,g' -e 's,\${datarootdir},\${prefix}/share,g'"
15151 cat >>$CONFIG_STATUS <<EOF
15155 cat >>$CONFIG_STATUS <<\EOF
15157 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
15158 s,@configure_input@,$configure_input,;t t
15159 s,@srcdir@,$ac_srcdir,;t t
15160 s,@top_srcdir@,$ac_top_srcdir,;t t
15161 s,@INSTALL@,$ac_INSTALL,;t t
15162 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
15164 if test x"$ac_file" != x-; then
15165 cp $tmp/out $ac_file
15167 for ac_name in prefix exec_prefix datarootdir
15169 ac_seen=`fgrep -n '${'$ac_name'[:=].*}' $ac_file`
15170 if test -n "$ac_seen"; then
15171 ac_init=`egrep '[ ]*'$ac_name'[ ]*=' $ac_file`
15172 if test -z "$ac_init"; then
15173 ac_seen=`echo "$ac_seen" |sed -e 's,^,'$ac_file':,'`
15174 { echo "$as_me:15174: WARNING: Variable $ac_name is used but was not set:
15176 echo "$as_me: WARNING: Variable $ac_name is used but was not set:
15181 egrep -n '@[a-z_][a-z_0-9]+@' $ac_file >$tmp/out
15182 egrep -n '@[A-Z_][A-Z_0-9]+@' $ac_file >>$tmp/out
15183 if test -s $tmp/out; then
15184 ac_seen=`sed -e 's,^,'$ac_file':,' < $tmp/out`
15185 { echo "$as_me:15185: WARNING: Some variables may not be substituted:
15187 echo "$as_me: WARNING: Some variables may not be substituted:
15197 cat >>$CONFIG_STATUS <<\EOF
15200 # CONFIG_HEADER section.
15203 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
15204 # NAME is the cpp macro being defined and VALUE is the value it is being given.
15206 # ac_d sets the value in "#define NAME VALUE" lines.
15207 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
15208 ac_dB='[ ].*$,\1#\2'
15211 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
15212 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
15213 ac_iB='\([ ]\),\1#\2define\3'
15216 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
15217 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
15218 ac_uB='$,\1#\2define\3'
15222 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
15223 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
15225 - | *:- | *:-:* ) # input from stdin
15227 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15228 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15229 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15230 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15231 * ) ac_file_in=$ac_file.in ;;
15234 test x"$ac_file" != x- && { echo "$as_me:15234: creating $ac_file" >&5
15235 echo "$as_me: creating $ac_file" >&6;}
15237 # First look for the input files in the build tree, otherwise in the
15239 ac_file_inputs=`IFS=:
15240 for f in $ac_file_in; do
15242 -) echo $tmp/stdin ;;
15244 # Absolute (can't be DOS-style, as IFS=:)
15245 test -f "$f" || { { echo "$as_me:15245: error: cannot find input file: $f" >&5
15246 echo "$as_me: error: cannot find input file: $f" >&2;}
15247 { (exit 1); exit 1; }; }
15250 if test -f "$f"; then
15253 elif test -f "$srcdir/$f"; then
15258 { { echo "$as_me:15258: error: cannot find input file: $f" >&5
15259 echo "$as_me: error: cannot find input file: $f" >&2;}
15260 { (exit 1); exit 1; }; }
15263 done` || { (exit 1); exit 1; }
15264 # Remove the trailing spaces.
15265 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
15269 # Transform confdefs.h into a list of #define's. We won't use it as a sed
15270 # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to
15271 # be either 'cat' or 'sort'.
15272 cat confdefs.h | uniq >conftest.vals
15274 # Break up conftest.vals because some shells have a limit on
15275 # the size of here documents, and old seds have small limits too.
15277 rm -f conftest.tail
15278 echo ' rm -f conftest.frag' >> $CONFIG_STATUS
15279 while grep . conftest.vals >/dev/null
15281 # Write chunks of a limited-size here document to conftest.frag.
15282 echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS
15283 sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS
15284 echo 'CEOF' >> $CONFIG_STATUS
15285 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
15286 rm -f conftest.vals
15287 mv conftest.tail conftest.vals
15289 rm -f conftest.vals
15291 # Run sed to substitute the contents of conftest.frag into $tmp/in at the
15293 echo ' cat >> conftest.edit <<CEOF
15294 /@DEFS@/r conftest.frag
15297 sed -f conftest.edit $tmp/in > $tmp/out
15299 mv $tmp/out $tmp/in
15300 rm -f conftest.edit conftest.frag
15301 ' >> $CONFIG_STATUS
15303 cat >>$CONFIG_STATUS <<\EOF
15304 # Let's still pretend it is `configure' which instantiates (i.e., don't
15305 # use $as_me), people would be surprised to read:
15306 # /* config.h. Generated automatically by config.status. */
15307 if test x"$ac_file" = x-; then
15308 echo "/* Generated automatically by configure. */" >$tmp/config.h
15310 echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h
15312 cat $tmp/in >>$tmp/config.h
15314 if test x"$ac_file" != x-; then
15315 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
15316 { echo "$as_me:15316: $ac_file is unchanged" >&5
15317 echo "$as_me: $ac_file is unchanged" >&6;}
15319 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15320 X"$ac_file" : 'X\(//\)[^/]' \| \
15321 X"$ac_file" : 'X\(//\)$' \| \
15322 X"$ac_file" : 'X\(/\)' \| \
15323 . : '\(.\)' 2>/dev/null ||
15325 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
15326 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
15327 /^X\(\/\/\)$/{ s//\1/; q; }
15328 /^X\(\/\).*/{ s//\1/; q; }
15330 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
15331 { case "$ac_dir" in
15332 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
15336 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
15337 case $as_mkdir_dir in
15338 # Skip DOS drivespec
15339 ?:) as_incr_dir=$as_mkdir_dir ;;
15341 as_incr_dir=$as_incr_dir/$as_mkdir_dir
15342 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
15349 mv $tmp/config.h $ac_file
15353 rm -f $tmp/config.h
15357 cat >>$CONFIG_STATUS <<\EOF
15359 # CONFIG_COMMANDS section.
15361 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
15362 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
15363 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
15367 if test -z "$USE_OLD_MAKERULES" ; then
15368 $AWK -f $srcdir/mk-1st.awk <$srcdir/src/modules >>src/Makefile
15375 cat >>$CONFIG_STATUS <<\EOF
15377 { (exit 0); exit 0; }
15379 chmod +x $CONFIG_STATUS
15380 ac_clean_files=$ac_clean_files_save
15382 # configure is writing to config.log, and then calls config.status.
15383 # config.status does its own redirection, appending to config.log.
15384 # Unfortunately, on DOS this fails, as config.log is still kept open
15385 # by configure, so config.status won't be able to write to it; its
15386 # output is simply discarded. So we exec the FD to /dev/null,
15387 # effectively closing config.log, so it can be properly (re)opened and
15388 # appended to by config.status. When coming back to configure, we
15389 # need to make the FD available again.
15390 if test "$no_create" != yes; then
15393 $SHELL $CONFIG_STATUS || ac_cs_success=false
15395 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
15396 # would make configure fail if this is the last instruction.
15397 $ac_cs_success || { (exit 1); exit 1; }
15399 ${MAKE:-make} preinstall