2 # From configure.in Revision: 1.26 .
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated by Autoconf 2.52.20101002.
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"
110 # Initialize some variables set by options.
112 ac_init_version=false
113 # The variables have the same names as the options, with
114 # dashes changed to underlines.
122 program_transform_name=s,x,x,
130 # Installation directory options.
131 # These are left unexpanded so users can "make install exec_prefix=/foo"
132 # and all the variables that are supposed to be based on exec_prefix
133 # by default will actually change.
134 # Use braces instead of parens because sh, perl, etc. also accept them.
135 bindir='${exec_prefix}/bin'
136 sbindir='${exec_prefix}/sbin'
137 libexecdir='${exec_prefix}/libexec'
138 datadir='${prefix}/share'
139 sysconfdir='${prefix}/etc'
140 sharedstatedir='${prefix}/com'
141 localstatedir='${prefix}/var'
142 libdir='${exec_prefix}/lib'
143 includedir='${prefix}/include'
144 oldincludedir='/usr/include'
145 infodir='${prefix}/info'
146 mandir='${prefix}/man'
148 # Identity of this package.
158 # If the previous option needs an argument, assign it.
159 if test -n "$ac_prev"; then
160 eval "$ac_prev=\$ac_option"
165 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
167 # Accept the important Cygnus configure options, so we can diagnose typos.
171 -bindir | --bindir | --bindi | --bind | --bin | --bi)
173 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
176 -build | --build | --buil | --bui | --bu)
177 ac_prev=build_alias ;;
178 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
179 build_alias=$ac_optarg ;;
181 -cache-file | --cache-file | --cache-fil | --cache-fi \
182 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
183 ac_prev=cache_file ;;
184 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
185 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
186 cache_file=$ac_optarg ;;
189 cache_file=config.cache ;;
191 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
193 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
195 datadir=$ac_optarg ;;
197 -disable-* | --disable-*)
198 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
199 # Reject names that are not valid shell variable names.
200 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
201 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
202 { (exit 1); exit 1; }; }
203 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
204 eval "enable_$ac_feature=no" ;;
206 -enable-* | --enable-*)
207 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
208 # Reject names that are not valid shell variable names.
209 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
210 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
211 { (exit 1); exit 1; }; }
212 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
214 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
217 eval "enable_$ac_feature='$ac_optarg'" ;;
219 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
220 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
221 | --exec | --exe | --ex)
222 ac_prev=exec_prefix ;;
223 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
224 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
225 | --exec=* | --exe=* | --ex=*)
226 exec_prefix=$ac_optarg ;;
228 -gas | --gas | --ga | --g)
229 # Obsolete; use --with-gas.
232 -help | --help | --hel | --he | -h)
234 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
235 ac_init_help=recursive ;;
236 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
237 ac_init_help=short ;;
239 -host | --host | --hos | --ho)
240 ac_prev=host_alias ;;
241 -host=* | --host=* | --hos=* | --ho=*)
242 host_alias=$ac_optarg ;;
244 -includedir | --includedir | --includedi | --included | --include \
245 | --includ | --inclu | --incl | --inc)
246 ac_prev=includedir ;;
247 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
248 | --includ=* | --inclu=* | --incl=* | --inc=*)
249 includedir=$ac_optarg ;;
251 -infodir | --infodir | --infodi | --infod | --info | --inf)
253 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
254 infodir=$ac_optarg ;;
256 -libdir | --libdir | --libdi | --libd)
258 -libdir=* | --libdir=* | --libdi=* | --libd=*)
261 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
262 | --libexe | --libex | --libe)
263 ac_prev=libexecdir ;;
264 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
265 | --libexe=* | --libex=* | --libe=*)
266 libexecdir=$ac_optarg ;;
268 -localstatedir | --localstatedir | --localstatedi | --localstated \
269 | --localstate | --localstat | --localsta | --localst \
270 | --locals | --local | --loca | --loc | --lo)
271 ac_prev=localstatedir ;;
272 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
273 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
274 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
275 localstatedir=$ac_optarg ;;
277 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
279 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
283 # Obsolete; use --without-fp.
286 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
290 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
291 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
294 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
295 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
296 | --oldin | --oldi | --old | --ol | --o)
297 ac_prev=oldincludedir ;;
298 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
299 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
300 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
301 oldincludedir=$ac_optarg ;;
303 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
305 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
308 -program-prefix | --program-prefix | --program-prefi | --program-pref \
309 | --program-pre | --program-pr | --program-p)
310 ac_prev=program_prefix ;;
311 -program-prefix=* | --program-prefix=* | --program-prefi=* \
312 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
313 program_prefix=$ac_optarg ;;
315 -program-suffix | --program-suffix | --program-suffi | --program-suff \
316 | --program-suf | --program-su | --program-s)
317 ac_prev=program_suffix ;;
318 -program-suffix=* | --program-suffix=* | --program-suffi=* \
319 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
320 program_suffix=$ac_optarg ;;
322 -program-transform-name | --program-transform-name \
323 | --program-transform-nam | --program-transform-na \
324 | --program-transform-n | --program-transform- \
325 | --program-transform | --program-transfor \
326 | --program-transfo | --program-transf \
327 | --program-trans | --program-tran \
328 | --progr-tra | --program-tr | --program-t)
329 ac_prev=program_transform_name ;;
330 -program-transform-name=* | --program-transform-name=* \
331 | --program-transform-nam=* | --program-transform-na=* \
332 | --program-transform-n=* | --program-transform-=* \
333 | --program-transform=* | --program-transfor=* \
334 | --program-transfo=* | --program-transf=* \
335 | --program-trans=* | --program-tran=* \
336 | --progr-tra=* | --program-tr=* | --program-t=*)
337 program_transform_name=$ac_optarg ;;
339 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
340 | -silent | --silent | --silen | --sile | --sil)
343 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
345 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
347 sbindir=$ac_optarg ;;
349 -sharedstatedir | --sharedstatedir | --sharedstatedi \
350 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
351 | --sharedst | --shareds | --shared | --share | --shar \
353 ac_prev=sharedstatedir ;;
354 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
355 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
356 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
358 sharedstatedir=$ac_optarg ;;
360 -site | --site | --sit)
362 -site=* | --site=* | --sit=*)
365 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
367 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
370 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
371 | --syscon | --sysco | --sysc | --sys | --sy)
372 ac_prev=sysconfdir ;;
373 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
374 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
375 sysconfdir=$ac_optarg ;;
377 -target | --target | --targe | --targ | --tar | --ta | --t)
378 ac_prev=target_alias ;;
379 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
380 target_alias=$ac_optarg ;;
382 -v | -verbose | --verbose | --verbos | --verbo | --verb)
385 -version | --version | --versio | --versi | --vers | -V)
389 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
390 # Reject names that are not valid shell variable names.
391 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
392 { echo "$as_me: error: invalid package name: $ac_package" >&2
393 { (exit 1); exit 1; }; }
394 ac_package=`echo $ac_package| sed 's/-/_/g'`
396 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
399 eval "with_$ac_package='$ac_optarg'" ;;
401 -without-* | --without-*)
402 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
403 # Reject names that are not valid shell variable names.
404 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
405 { echo "$as_me: error: invalid package name: $ac_package" >&2
406 { (exit 1); exit 1; }; }
407 ac_package=`echo $ac_package | sed 's/-/_/g'`
408 eval "with_$ac_package=no" ;;
411 # Obsolete; use --with-x.
414 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
415 | --x-incl | --x-inc | --x-in | --x-i)
416 ac_prev=x_includes ;;
417 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
418 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
419 x_includes=$ac_optarg ;;
421 -x-libraries | --x-libraries | --x-librarie | --x-librari \
422 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
423 ac_prev=x_libraries ;;
424 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
425 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
426 x_libraries=$ac_optarg ;;
428 -*) { echo "$as_me: error: unrecognized option: $ac_option
429 Try \`$0 --help' for more information." >&2
430 { (exit 1); exit 1; }; }
434 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
435 # Reject names that are not valid shell variable names.
436 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
437 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
438 { (exit 1); exit 1; }; }
439 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
440 eval "$ac_envvar='$ac_optarg'"
444 # FIXME: should be removed in autoconf 3.0.
445 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
446 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
447 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
448 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
454 if test -n "$ac_prev"; then
455 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
456 { echo "$as_me: error: missing argument to $ac_option" >&2
457 { (exit 1); exit 1; }; }
460 # Be sure to have absolute paths.
461 for ac_var in exec_prefix prefix
463 eval ac_val=$`echo $ac_var`
465 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
466 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
467 { (exit 1); exit 1; }; };;
471 # Be sure to have absolute paths.
472 for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
473 localstatedir libdir includedir oldincludedir infodir mandir
475 eval ac_val=$`echo $ac_var`
477 [\\/$]* | ?:[\\/]* ) ;;
478 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
479 { (exit 1); exit 1; }; };;
483 # There might be people who depend on the old broken behavior: `$host'
484 # used to hold the argument of --host etc.
489 # FIXME: should be removed in autoconf 3.0.
490 if test "x$host_alias" != x; then
491 if test "x$build_alias" = x; then
492 cross_compiling=maybe
493 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
494 If a cross compiler is detected then cross compile mode will be used." >&2
495 elif test "x$build_alias" != "x$host_alias"; then
501 test -n "$host_alias" && ac_tool_prefix=$host_alias-
503 test "$silent" = yes && exec 6>/dev/null
505 # Find the source files, if location was not specified.
506 if test -z "$srcdir"; then
507 ac_srcdir_defaulted=yes
508 # Try the directory containing this script, then its parent.
510 ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
511 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
513 if test ! -r $srcdir/$ac_unique_file; then
517 ac_srcdir_defaulted=no
519 if test ! -r $srcdir/$ac_unique_file; then
520 if test "$ac_srcdir_defaulted" = yes; then
521 { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
522 { (exit 1); exit 1; }; }
524 { echo "$as_me: error: cannot find sources in $srcdir" >&2
525 { (exit 1); exit 1; }; }
528 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
529 ac_env_build_alias_set=${build_alias+set}
530 ac_env_build_alias_value=$build_alias
531 ac_cv_env_build_alias_set=${build_alias+set}
532 ac_cv_env_build_alias_value=$build_alias
533 ac_env_host_alias_set=${host_alias+set}
534 ac_env_host_alias_value=$host_alias
535 ac_cv_env_host_alias_set=${host_alias+set}
536 ac_cv_env_host_alias_value=$host_alias
537 ac_env_target_alias_set=${target_alias+set}
538 ac_env_target_alias_value=$target_alias
539 ac_cv_env_target_alias_set=${target_alias+set}
540 ac_cv_env_target_alias_value=$target_alias
541 ac_env_CC_set=${CC+set}
543 ac_cv_env_CC_set=${CC+set}
544 ac_cv_env_CC_value=$CC
545 ac_env_CFLAGS_set=${CFLAGS+set}
546 ac_env_CFLAGS_value=$CFLAGS
547 ac_cv_env_CFLAGS_set=${CFLAGS+set}
548 ac_cv_env_CFLAGS_value=$CFLAGS
549 ac_env_LDFLAGS_set=${LDFLAGS+set}
550 ac_env_LDFLAGS_value=$LDFLAGS
551 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
552 ac_cv_env_LDFLAGS_value=$LDFLAGS
553 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
554 ac_env_CPPFLAGS_value=$CPPFLAGS
555 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
556 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
557 ac_env_CPP_set=${CPP+set}
558 ac_env_CPP_value=$CPP
559 ac_cv_env_CPP_set=${CPP+set}
560 ac_cv_env_CPP_value=$CPP
563 # Report the --help message.
565 if test "$ac_init_help" = "long"; then
566 # Omit some internal or obsolete options to make the list less imposing.
567 # This message is too long to be a string in the A/UX 3.1 sh.
569 \`configure' configures this package to adapt to many kinds of systems.
571 Usage: $0 [OPTION]... [VAR=VALUE]...
573 To assign environment variables (e.g., CC, CFLAGS...), specify them as
574 VAR=VALUE. See below for descriptions of some of the useful variables.
576 Defaults for the options are specified in brackets.
579 -h, --help display this help and exit
580 --help=short display options specific to this package
581 --help=recursive display the short help of all the included packages
582 -V, --version display version information and exit
583 -q, --quiet, --silent do not print \`checking...' messages
584 --cache-file=FILE cache test results in FILE [disabled]
585 -C, --config-cache alias for \`--cache-file=config.cache'
586 -n, --no-create do not create output files
587 --srcdir=DIR find the sources in DIR [configure dir or \`..']
592 Installation directories:
593 --prefix=PREFIX install architecture-independent files in PREFIX
595 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
598 By default, \`make install' will install all the files in
599 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
600 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
601 for instance \`--prefix=\$HOME'.
603 For better control, use the options below.
605 Fine tuning of the installation directories:
606 --bindir=DIR user executables [EPREFIX/bin]
607 --sbindir=DIR system admin executables [EPREFIX/sbin]
608 --libexecdir=DIR program executables [EPREFIX/libexec]
609 --datadir=DIR read-only architecture-independent data [PREFIX/share]
610 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
611 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
612 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
613 --libdir=DIR object code libraries [EPREFIX/lib]
614 --includedir=DIR C header files [PREFIX/include]
615 --oldincludedir=DIR C header files for non-gcc [/usr/include]
616 --infodir=DIR info documentation [PREFIX/info]
617 --mandir=DIR man documentation [PREFIX/man]
623 --program-prefix=PREFIX prepend PREFIX to installed program names
624 --program-suffix=SUFFIX append SUFFIX to installed program names
625 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
628 --build=BUILD configure for building on BUILD [guessed]
629 --host=HOST build programs to run on HOST [BUILD]
630 --target=TARGET configure for building compilers for TARGET [HOST]
634 if test -n "$ac_init_help"; then
639 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
640 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
643 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
644 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
646 --with-system-type=XXX test: override derived host system-type
647 --with-pkg-config{=path} enable/disable use of pkg-config
648 --enable-pc-files generate and install .pc files for pkg-config
649 --without-tests suppress build with test-programs
650 --enable-mixed-case tic should assume mixed-case filenames
651 --with-install-prefix prefixes actual install-location ($DESTDIR)
652 Build-Tools Needed to Compile Temporary Applications for Cross-compiling:
653 --with-build-cc=XXX the build C compiler ($BUILD_CC)
654 --with-build-cpp=XXX the build C preprocessor ($BUILD_CPP)
655 --with-build-cflags=XXX the build C compiler-flags ($BUILD_CFLAGS)
656 --with-build-cppflags=XXX the build C preprocessor-flags ($BUILD_CPPFLAGS)
657 --with-build-ldflags=XXX the build linker-flags ($BUILD_LDFLAGS)
658 --with-build-libs=XXX the build libraries (${BUILD_LIBS})
659 Options to Specify the Libraries Built/Used:
660 --enable-widec compile with wide-char/UTF-8 code
661 --with-curses-dir=DIR directory in which (n)curses is installed
662 --with-shlib-version=X Specify rel or abi version for shared libs
663 Fine-Tuning Your Configuration:
664 --enable-broken_linker compile with broken-linker support code
665 --disable-largefile omit support for large files
666 --with-rcs-ids compile-in RCS identifiers
668 --disable-ext-funcs disable function-extensions
669 --enable-const compile with extra/non-standard const
671 --without-develop disable development options
673 --with-pthread use POSIX thread library
674 --enable-weak-symbols enable weak-symbols for pthreads
675 --enable-reentrant compile with experimental reentrant code
676 --with-wrap-prefix=XXX override prefix used for public variables
677 Testing/development Options:
678 --enable-echo build: display "compiling" commands (default)
679 --enable-warnings build: turn on GCC compiler warnings
680 --enable-assertions test: turn on generation of assertion code
681 --enable-expanded test: generate functions for certain macros
682 --disable-macros test: use functions rather than macros
683 --with-trace test: add trace() function to all models of ncurses
684 Ada95 Binding Options:
685 --with-ada-compiler=CMD specify Ada95 compiler command (default gnatmake)
686 --with-ada-include=DIR Ada includes are in DIR (default: PREFIX/share/ada/adainclude)
687 --with-ada-objects=DIR Ada objects are in DIR (default: PREFIX/lib/ada/adalib)
688 --with-ada-sharedlib=XX build Ada95 shared-library
690 Some influential environment variables:
691 CC C compiler command
692 CFLAGS C compiler flags
693 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
694 nonstandard directory <lib dir>
695 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
696 headers in a nonstandard directory <include dir>
699 Use these variables to override the choices made by `configure' or to help
700 it to find libraries and programs with nonstandard names/locations.
705 if test "$ac_init_help" = "recursive"; then
706 # If there are subdirs, report their specific --help.
708 for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
710 # A "../" for each directory in /$ac_subdir.
711 ac_dots=`echo $ac_subdir |
712 sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
715 .) # No --srcdir option. We are building in place.
716 ac_sub_srcdir=$srcdir ;;
717 [\\/]* | ?:[\\/]* ) # Absolute path.
718 ac_sub_srcdir=$srcdir/$ac_subdir ;;
720 ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
723 # Check for guested configure; otherwise get Cygnus style configure.
724 if test -f $ac_sub_srcdir/configure.gnu; then
726 $SHELL $ac_sub_srcdir/configure.gnu --help=recursive
727 elif test -f $ac_sub_srcdir/configure; then
729 $SHELL $ac_sub_srcdir/configure --help=recursive
730 elif test -f $ac_sub_srcdir/configure.ac ||
731 test -f $ac_sub_srcdir/configure.in; then
735 echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
741 test -n "$ac_init_help" && exit 0
742 if $ac_init_version; then
745 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
746 Free Software Foundation, Inc.
747 This configure script is free software; the Free Software Foundation
748 gives unlimited permission to copy, distribute and modify it.
754 This file contains any messages produced by compilers while
755 running configure, to aid debugging if configure makes a mistake.
757 It was created by $as_me, which was
758 generated by GNU Autoconf 2.52.20101002. Invocation command line was
769 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
770 uname -m = `(uname -m) 2>/dev/null || echo unknown`
771 uname -r = `(uname -r) 2>/dev/null || echo unknown`
772 uname -s = `(uname -s) 2>/dev/null || echo unknown`
773 uname -v = `(uname -v) 2>/dev/null || echo unknown`
775 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
776 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
778 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
779 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
780 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
781 hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
782 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
783 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
784 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
798 # Keep a trace of the command line.
799 # Strip out --no-create and --no-recursion so they do not pile up.
800 # Also quote any args containing shell meta-characters.
806 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
807 | --no-cr | --no-c) ;;
808 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
809 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
810 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
811 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
812 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
814 *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
817 # Get rid of the leading space.
820 # When interrupted or exit'd, cleanup temporary files, and complete
821 # config.log. We remove comments because anyway the quotes in there
822 # would cause problems or look ugly.
824 # Save into config.log some information that might help in debugging.
826 echo "## ----------------- ##" >&5
827 echo "## Cache variables. ##" >&5
828 echo "## ----------------- ##" >&5
830 # The following way of writing the cache mishandles newlines in values,
833 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
836 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
837 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
841 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
845 sed "/^$/d" confdefs.h >conftest.log
846 if test -s conftest.log; then
848 echo "## ------------ ##" >&5
849 echo "## confdefs.h. ##" >&5
850 echo "## ------------ ##" >&5
855 test "$ac_signal" != 0 &&
856 echo "$as_me: caught signal $ac_signal" >&5
857 echo "$as_me: exit $exit_status" >&5
858 rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
861 for ac_signal in 1 2 13 15; do
862 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
866 # confdefs.h avoids OS command line length limits that DEFS can exceed.
867 rm -rf conftest* confdefs.h
868 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
871 # Let the site file select an alternate cache file if it wants to.
872 # Prefer explicitly selected file to automatically selected ones.
873 if test -z "$CONFIG_SITE"; then
874 if test "x$prefix" != xNONE; then
875 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
877 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
880 for ac_site_file in $CONFIG_SITE; do
881 if test -r "$ac_site_file"; then
882 { echo "$as_me:882: loading site script $ac_site_file" >&5
883 echo "$as_me: loading site script $ac_site_file" >&6;}
884 cat "$ac_site_file" >&5
889 if test -r "$cache_file"; then
890 # Some versions of bash will fail to source /dev/null (special
891 # files actually), so we avoid doing that.
892 if test -f "$cache_file"; then
893 { echo "$as_me:893: loading cache $cache_file" >&5
894 echo "$as_me: loading cache $cache_file" >&6;}
896 [\\/]* | ?:[\\/]* ) . $cache_file;;
901 { echo "$as_me:901: creating cache $cache_file" >&5
902 echo "$as_me: creating cache $cache_file" >&6;}
906 # Check that the precious variables saved in the cache have kept the same
908 ac_cache_corrupted=false
909 for ac_var in `(set) 2>&1 |
910 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
911 eval ac_old_set=\$ac_cv_env_${ac_var}_set
912 eval ac_new_set=\$ac_env_${ac_var}_set
913 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
914 eval ac_new_val="\$ac_env_${ac_var}_value"
915 case $ac_old_set,$ac_new_set in
917 { echo "$as_me:917: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
918 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
919 ac_cache_corrupted=: ;;
921 { echo "$as_me:921: error: \`$ac_var' was not set in the previous run" >&5
922 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
923 ac_cache_corrupted=: ;;
926 if test "x$ac_old_val" != "x$ac_new_val"; then
927 { echo "$as_me:927: error: \`$ac_var' has changed since the previous run:" >&5
928 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
929 { echo "$as_me:929: former value: $ac_old_val" >&5
930 echo "$as_me: former value: $ac_old_val" >&2;}
931 { echo "$as_me:931: current value: $ac_new_val" >&5
932 echo "$as_me: current value: $ac_new_val" >&2;}
936 # Pass precious variables to config.status. It doesn't matter if
937 # we pass some twice (in addition to the command line arguments).
938 if test "$ac_new_set" = set; then
940 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
941 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
942 ac_configure_args="$ac_configure_args '$ac_arg'"
944 *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
949 if $ac_cache_corrupted; then
950 { echo "$as_me:950: error: changes in the environment can compromise the build" >&5
951 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
952 { { echo "$as_me:952: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
953 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
954 { (exit 1); exit 1; }; }
958 ac_cpp='$CPP $CPPFLAGS'
959 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
960 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
961 ac_compiler_gnu=$ac_cv_c_compiler_gnu
962 ac_main_return=return
964 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
965 *c*,-n*) ECHO_N= ECHO_C='
967 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
968 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
970 echo "#! $SHELL" >conftest.sh
971 echo "exit 0" >>conftest.sh
973 if { (echo "$as_me:973: PATH=\".;.\"; conftest.sh") >&5
974 (PATH=".;."; conftest.sh) 2>&5
976 echo "$as_me:976: \$? = $ac_status" >&5
977 (exit $ac_status); }; then
978 ac_path_separator=';'
982 PATH_SEPARATOR="$ac_path_separator"
985 ac_config_headers="$ac_config_headers include/ncurses_cfg.h:include/ncurses_cfg.hin"
990 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
991 if test -f $ac_dir/install-sh; then
993 ac_install_sh="$ac_aux_dir/install-sh -c"
995 elif test -f $ac_dir/install.sh; then
997 ac_install_sh="$ac_aux_dir/install.sh -c"
999 elif test -f $ac_dir/shtool; then
1001 ac_install_sh="$ac_aux_dir/shtool install -c"
1005 if test -z "$ac_aux_dir"; then
1006 { { echo "$as_me:1006: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1007 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1008 { (exit 1); exit 1; }; }
1010 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1011 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1012 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1014 # Make sure we can run config.sub.
1015 $ac_config_sub sun4 >/dev/null 2>&1 ||
1016 { { echo "$as_me:1016: error: cannot run $ac_config_sub" >&5
1017 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1018 { (exit 1); exit 1; }; }
1020 echo "$as_me:1020: checking build system type" >&5
1021 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1022 if test "${ac_cv_build+set}" = set; then
1023 echo $ECHO_N "(cached) $ECHO_C" >&6
1025 ac_cv_build_alias=$build_alias
1026 test -z "$ac_cv_build_alias" &&
1027 ac_cv_build_alias=`$ac_config_guess`
1028 test -z "$ac_cv_build_alias" &&
1029 { { echo "$as_me:1029: error: cannot guess build type; you must specify one" >&5
1030 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1031 { (exit 1); exit 1; }; }
1032 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1033 { { echo "$as_me:1033: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1034 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1035 { (exit 1); exit 1; }; }
1038 echo "$as_me:1038: result: $ac_cv_build" >&5
1039 echo "${ECHO_T}$ac_cv_build" >&6
1041 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1042 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1043 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1045 echo "$as_me:1045: checking host system type" >&5
1046 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1047 if test "${ac_cv_host+set}" = set; then
1048 echo $ECHO_N "(cached) $ECHO_C" >&6
1050 ac_cv_host_alias=$host_alias
1051 test -z "$ac_cv_host_alias" &&
1052 ac_cv_host_alias=$ac_cv_build_alias
1053 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1054 { { echo "$as_me:1054: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1055 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1056 { (exit 1); exit 1; }; }
1059 echo "$as_me:1059: result: $ac_cv_host" >&5
1060 echo "${ECHO_T}$ac_cv_host" >&6
1062 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1063 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1064 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1066 if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then
1067 echo "$as_me:1067: checking target system type" >&5
1068 echo $ECHO_N "checking target system type... $ECHO_C" >&6
1069 if test "${ac_cv_target+set}" = set; then
1070 echo $ECHO_N "(cached) $ECHO_C" >&6
1072 ac_cv_target_alias=$target_alias
1073 test "x$ac_cv_target_alias" = "x" &&
1074 ac_cv_target_alias=$ac_cv_host_alias
1075 ac_cv_target=`$ac_config_sub $ac_cv_target_alias` ||
1076 { { echo "$as_me:1076: error: $ac_config_sub $ac_cv_target_alias failed" >&5
1077 echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
1078 { (exit 1); exit 1; }; }
1081 echo "$as_me:1081: result: $ac_cv_target" >&5
1082 echo "${ECHO_T}$ac_cv_target" >&6
1083 target=$ac_cv_target
1084 target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1085 target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1086 target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1088 # The aliases save the names the user supplied, while $host etc.
1089 # will get canonicalized.
1090 test -n "$target_alias" &&
1091 test "$program_prefix$program_suffix$program_transform_name" = \
1093 program_prefix=${target_alias}-
1094 system_name="$host_os"
1096 system_name="`(uname -s -r) 2>/dev/null`"
1097 if test -z "$system_name" ; then
1098 system_name="`(hostname) 2>/dev/null`"
1101 test -n "$system_name" && cat >>confdefs.h <<EOF
1102 #define SYSTEM_NAME "$system_name"
1105 if test "${cf_cv_system_name+set}" = set; then
1106 echo $ECHO_N "(cached) $ECHO_C" >&6
1108 cf_cv_system_name="$system_name"
1111 test -z "$system_name" && system_name="$cf_cv_system_name"
1112 test -n "$cf_cv_system_name" && echo "$as_me:1112: result: Configuring for $cf_cv_system_name" >&5
1113 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1115 if test ".$system_name" != ".$cf_cv_system_name" ; then
1116 echo "$as_me:1116: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1117 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1118 { { echo "$as_me:1118: error: \"Please remove config.cache and try again.\"" >&5
1119 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1120 { (exit 1); exit 1; }; }
1123 # Check whether --with-system-type or --without-system-type was given.
1124 if test "${with_system_type+set}" = set; then
1125 withval="$with_system_type"
1126 { echo "$as_me:1126: WARNING: overriding system type to $withval" >&5
1127 echo "$as_me: WARNING: overriding system type to $withval" >&2;}
1128 cf_cv_system_name=$withval
1131 ### Save the given $CFLAGS to allow user-override.
1132 cf_user_CFLAGS="$CFLAGS"
1134 ### Default install-location
1136 echo "$as_me:1136: checking for prefix" >&5
1137 echo $ECHO_N "checking for prefix... $ECHO_C" >&6
1138 if test "x$prefix" = "xNONE" ; then
1139 case "$cf_cv_system_name" in
1140 # non-vendor systems don't have a conflict
1141 openbsd*|freebsd*|linux*|cygwin*|k*bsd*-gnu)
1144 *) prefix=$ac_default_prefix
1148 echo "$as_me:1148: result: $prefix" >&5
1149 echo "${ECHO_T}$prefix" >&6
1151 if test "x$prefix" = "xNONE" ; then
1152 echo "$as_me:1152: checking for default include-directory" >&5
1153 echo $ECHO_N "checking for default include-directory... $ECHO_C" >&6
1154 test -n "$verbose" && echo 1>&6
1157 $includedir/ncurses \
1159 $prefix/include/ncurses \
1160 /usr/local/include \
1161 /usr/local/include/ncurses \
1163 /usr/include/ncurses
1165 cf_dir=`eval echo $cf_symbol`
1166 if test -f $cf_dir/curses.h ; then
1167 if ( fgrep NCURSES_VERSION $cf_dir/curses.h 2>&1 >/dev/null ) ; then
1168 includedir="$cf_symbol"
1169 test -n "$verbose" && echo $ac_n " found " 1>&6
1173 test -n "$verbose" && echo " tested $cf_dir" 1>&6
1175 echo "$as_me:1175: result: $includedir" >&5
1176 echo "${ECHO_T}$includedir" >&6
1179 ### Checks for programs.
1181 ac_cpp='$CPP $CPPFLAGS'
1182 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1183 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1184 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1185 ac_main_return=return
1186 if test -n "$ac_tool_prefix"; then
1187 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1188 set dummy ${ac_tool_prefix}gcc; ac_word=$2
1189 echo "$as_me:1189: checking for $ac_word" >&5
1190 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1191 if test "${ac_cv_prog_CC+set}" = set; then
1192 echo $ECHO_N "(cached) $ECHO_C" >&6
1194 if test -n "$CC"; then
1195 ac_cv_prog_CC="$CC" # Let the user override the test.
1197 ac_save_IFS=$IFS; IFS=$ac_path_separator
1199 for ac_dir in $ac_dummy; do
1201 test -z "$ac_dir" && ac_dir=.
1202 $as_executable_p "$ac_dir/$ac_word" || continue
1203 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1204 echo "$as_me:1204: found $ac_dir/$ac_word" >&5
1211 if test -n "$CC"; then
1212 echo "$as_me:1212: result: $CC" >&5
1213 echo "${ECHO_T}$CC" >&6
1215 echo "$as_me:1215: result: no" >&5
1216 echo "${ECHO_T}no" >&6
1220 if test -z "$ac_cv_prog_CC"; then
1222 # Extract the first word of "gcc", so it can be a program name with args.
1223 set dummy gcc; ac_word=$2
1224 echo "$as_me:1224: checking for $ac_word" >&5
1225 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1226 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1227 echo $ECHO_N "(cached) $ECHO_C" >&6
1229 if test -n "$ac_ct_CC"; then
1230 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1232 ac_save_IFS=$IFS; IFS=$ac_path_separator
1234 for ac_dir in $ac_dummy; do
1236 test -z "$ac_dir" && ac_dir=.
1237 $as_executable_p "$ac_dir/$ac_word" || continue
1238 ac_cv_prog_ac_ct_CC="gcc"
1239 echo "$as_me:1239: found $ac_dir/$ac_word" >&5
1245 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1246 if test -n "$ac_ct_CC"; then
1247 echo "$as_me:1247: result: $ac_ct_CC" >&5
1248 echo "${ECHO_T}$ac_ct_CC" >&6
1250 echo "$as_me:1250: result: no" >&5
1251 echo "${ECHO_T}no" >&6
1259 if test -z "$CC"; then
1260 if test -n "$ac_tool_prefix"; then
1261 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1262 set dummy ${ac_tool_prefix}cc; ac_word=$2
1263 echo "$as_me:1263: checking for $ac_word" >&5
1264 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1265 if test "${ac_cv_prog_CC+set}" = set; then
1266 echo $ECHO_N "(cached) $ECHO_C" >&6
1268 if test -n "$CC"; then
1269 ac_cv_prog_CC="$CC" # Let the user override the test.
1271 ac_save_IFS=$IFS; IFS=$ac_path_separator
1273 for ac_dir in $ac_dummy; do
1275 test -z "$ac_dir" && ac_dir=.
1276 $as_executable_p "$ac_dir/$ac_word" || continue
1277 ac_cv_prog_CC="${ac_tool_prefix}cc"
1278 echo "$as_me:1278: found $ac_dir/$ac_word" >&5
1285 if test -n "$CC"; then
1286 echo "$as_me:1286: result: $CC" >&5
1287 echo "${ECHO_T}$CC" >&6
1289 echo "$as_me:1289: result: no" >&5
1290 echo "${ECHO_T}no" >&6
1294 if test -z "$ac_cv_prog_CC"; then
1296 # Extract the first word of "cc", so it can be a program name with args.
1297 set dummy cc; ac_word=$2
1298 echo "$as_me:1298: checking for $ac_word" >&5
1299 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1300 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1301 echo $ECHO_N "(cached) $ECHO_C" >&6
1303 if test -n "$ac_ct_CC"; then
1304 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1306 ac_save_IFS=$IFS; IFS=$ac_path_separator
1308 for ac_dir in $ac_dummy; do
1310 test -z "$ac_dir" && ac_dir=.
1311 $as_executable_p "$ac_dir/$ac_word" || continue
1312 ac_cv_prog_ac_ct_CC="cc"
1313 echo "$as_me:1313: found $ac_dir/$ac_word" >&5
1319 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1320 if test -n "$ac_ct_CC"; then
1321 echo "$as_me:1321: result: $ac_ct_CC" >&5
1322 echo "${ECHO_T}$ac_ct_CC" >&6
1324 echo "$as_me:1324: result: no" >&5
1325 echo "${ECHO_T}no" >&6
1334 if test -z "$CC"; then
1335 # Extract the first word of "cc", so it can be a program name with args.
1336 set dummy cc; ac_word=$2
1337 echo "$as_me:1337: checking for $ac_word" >&5
1338 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1339 if test "${ac_cv_prog_CC+set}" = set; then
1340 echo $ECHO_N "(cached) $ECHO_C" >&6
1342 if test -n "$CC"; then
1343 ac_cv_prog_CC="$CC" # Let the user override the test.
1346 ac_save_IFS=$IFS; IFS=$ac_path_separator
1348 for ac_dir in $ac_dummy; do
1350 test -z "$ac_dir" && ac_dir=.
1351 $as_executable_p "$ac_dir/$ac_word" || continue
1352 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1353 ac_prog_rejected=yes
1357 echo "$as_me:1357: found $ac_dir/$ac_word" >&5
1361 if test $ac_prog_rejected = yes; then
1362 # We found a bogon in the path, so make sure we never use it.
1363 set dummy $ac_cv_prog_CC
1365 if test $# != 0; then
1366 # We chose a different compiler from the bogus one.
1367 # However, it has the same basename, so the bogon will be chosen
1368 # first if we set CC to just the basename; use the full file name.
1370 set dummy "$ac_dir/$ac_word" ${1+"$@"}
1378 if test -n "$CC"; then
1379 echo "$as_me:1379: result: $CC" >&5
1380 echo "${ECHO_T}$CC" >&6
1382 echo "$as_me:1382: result: no" >&5
1383 echo "${ECHO_T}no" >&6
1387 if test -z "$CC"; then
1388 if test -n "$ac_tool_prefix"; then
1391 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1392 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1393 echo "$as_me:1393: checking for $ac_word" >&5
1394 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1395 if test "${ac_cv_prog_CC+set}" = set; then
1396 echo $ECHO_N "(cached) $ECHO_C" >&6
1398 if test -n "$CC"; then
1399 ac_cv_prog_CC="$CC" # Let the user override the test.
1401 ac_save_IFS=$IFS; IFS=$ac_path_separator
1403 for ac_dir in $ac_dummy; do
1405 test -z "$ac_dir" && ac_dir=.
1406 $as_executable_p "$ac_dir/$ac_word" || continue
1407 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1408 echo "$as_me:1408: found $ac_dir/$ac_word" >&5
1415 if test -n "$CC"; then
1416 echo "$as_me:1416: result: $CC" >&5
1417 echo "${ECHO_T}$CC" >&6
1419 echo "$as_me:1419: result: no" >&5
1420 echo "${ECHO_T}no" >&6
1423 test -n "$CC" && break
1426 if test -z "$CC"; then
1430 # Extract the first word of "$ac_prog", so it can be a program name with args.
1431 set dummy $ac_prog; ac_word=$2
1432 echo "$as_me:1432: checking for $ac_word" >&5
1433 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1434 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1435 echo $ECHO_N "(cached) $ECHO_C" >&6
1437 if test -n "$ac_ct_CC"; then
1438 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1440 ac_save_IFS=$IFS; IFS=$ac_path_separator
1442 for ac_dir in $ac_dummy; do
1444 test -z "$ac_dir" && ac_dir=.
1445 $as_executable_p "$ac_dir/$ac_word" || continue
1446 ac_cv_prog_ac_ct_CC="$ac_prog"
1447 echo "$as_me:1447: found $ac_dir/$ac_word" >&5
1453 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1454 if test -n "$ac_ct_CC"; then
1455 echo "$as_me:1455: result: $ac_ct_CC" >&5
1456 echo "${ECHO_T}$ac_ct_CC" >&6
1458 echo "$as_me:1458: result: no" >&5
1459 echo "${ECHO_T}no" >&6
1462 test -n "$ac_ct_CC" && break
1470 test -z "$CC" && { { echo "$as_me:1470: error: no acceptable cc found in \$PATH" >&5
1471 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1472 { (exit 1); exit 1; }; }
1474 # Provide some information about the compiler.
1475 echo "$as_me:1475:" \
1476 "checking for C compiler version" >&5
1477 ac_compiler=`set X $ac_compile; echo $2`
1478 { (eval echo "$as_me:1478: \"$ac_compiler --version </dev/null >&5\"") >&5
1479 (eval $ac_compiler --version </dev/null >&5) 2>&5
1481 echo "$as_me:1481: \$? = $ac_status" >&5
1482 (exit $ac_status); }
1483 { (eval echo "$as_me:1483: \"$ac_compiler -v </dev/null >&5\"") >&5
1484 (eval $ac_compiler -v </dev/null >&5) 2>&5
1486 echo "$as_me:1486: \$? = $ac_status" >&5
1487 (exit $ac_status); }
1488 { (eval echo "$as_me:1488: \"$ac_compiler -V </dev/null >&5\"") >&5
1489 (eval $ac_compiler -V </dev/null >&5) 2>&5
1491 echo "$as_me:1491: \$? = $ac_status" >&5
1492 (exit $ac_status); }
1494 cat >conftest.$ac_ext <<_ACEOF
1495 #line 1495 "configure"
1496 #include "confdefs.h"
1506 ac_clean_files_save=$ac_clean_files
1507 ac_clean_files="$ac_clean_files a.out a.exe"
1508 # Try to create an executable without -o first, disregard a.out.
1509 # It will help us diagnose broken compilers, and finding out an intuition
1511 echo "$as_me:1511: checking for C compiler default output" >&5
1512 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1513 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1514 if { (eval echo "$as_me:1514: \"$ac_link_default\"") >&5
1515 (eval $ac_link_default) 2>&5
1517 echo "$as_me:1517: \$? = $ac_status" >&5
1518 (exit $ac_status); }; then
1519 # Find the output, starting from the most likely. This scheme is
1520 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1522 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1523 ls a.out conftest 2>/dev/null;
1524 ls a.* conftest.* 2>/dev/null`; do
1526 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1527 a.out ) # We found the default executable, but exeext='' is most
1530 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1531 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1538 echo "$as_me: failed program was:" >&5
1539 cat conftest.$ac_ext >&5
1540 { { echo "$as_me:1540: error: C compiler cannot create executables" >&5
1541 echo "$as_me: error: C compiler cannot create executables" >&2;}
1542 { (exit 77); exit 77; }; }
1545 ac_exeext=$ac_cv_exeext
1546 echo "$as_me:1546: result: $ac_file" >&5
1547 echo "${ECHO_T}$ac_file" >&6
1549 # Check the compiler produces executables we can run. If not, either
1550 # the compiler is broken, or we cross compile.
1551 echo "$as_me:1551: checking whether the C compiler works" >&5
1552 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1553 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1554 # If not cross compiling, check that we can run a simple program.
1555 if test "$cross_compiling" != yes; then
1556 if { ac_try='./$ac_file'
1557 { (eval echo "$as_me:1557: \"$ac_try\"") >&5
1560 echo "$as_me:1560: \$? = $ac_status" >&5
1561 (exit $ac_status); }; }; then
1564 if test "$cross_compiling" = maybe; then
1567 { { echo "$as_me:1567: error: cannot run C compiled programs.
1568 If you meant to cross compile, use \`--host'." >&5
1569 echo "$as_me: error: cannot run C compiled programs.
1570 If you meant to cross compile, use \`--host'." >&2;}
1571 { (exit 1); exit 1; }; }
1575 echo "$as_me:1575: result: yes" >&5
1576 echo "${ECHO_T}yes" >&6
1578 rm -f a.out a.exe conftest$ac_cv_exeext
1579 ac_clean_files=$ac_clean_files_save
1580 # Check the compiler produces executables we can run. If not, either
1581 # the compiler is broken, or we cross compile.
1582 echo "$as_me:1582: checking whether we are cross compiling" >&5
1583 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1584 echo "$as_me:1584: result: $cross_compiling" >&5
1585 echo "${ECHO_T}$cross_compiling" >&6
1587 echo "$as_me:1587: checking for executable suffix" >&5
1588 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1589 if { (eval echo "$as_me:1589: \"$ac_link\"") >&5
1590 (eval $ac_link) 2>&5
1592 echo "$as_me:1592: \$? = $ac_status" >&5
1593 (exit $ac_status); }; then
1594 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1595 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1596 # work properly (i.e., refer to `conftest.exe'), while it won't with
1598 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1600 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1601 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1608 { { echo "$as_me:1608: error: cannot compute EXEEXT: cannot compile and link" >&5
1609 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1610 { (exit 1); exit 1; }; }
1613 rm -f conftest$ac_cv_exeext
1614 echo "$as_me:1614: result: $ac_cv_exeext" >&5
1615 echo "${ECHO_T}$ac_cv_exeext" >&6
1617 rm -f conftest.$ac_ext
1618 EXEEXT=$ac_cv_exeext
1620 echo "$as_me:1620: checking for object suffix" >&5
1621 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1622 if test "${ac_cv_objext+set}" = set; then
1623 echo $ECHO_N "(cached) $ECHO_C" >&6
1625 cat >conftest.$ac_ext <<_ACEOF
1626 #line 1626 "configure"
1627 #include "confdefs.h"
1637 rm -f conftest.o conftest.obj
1638 if { (eval echo "$as_me:1638: \"$ac_compile\"") >&5
1639 (eval $ac_compile) 2>&5
1641 echo "$as_me:1641: \$? = $ac_status" >&5
1642 (exit $ac_status); }; then
1643 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1645 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1646 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1651 echo "$as_me: failed program was:" >&5
1652 cat conftest.$ac_ext >&5
1653 { { echo "$as_me:1653: error: cannot compute OBJEXT: cannot compile" >&5
1654 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1655 { (exit 1); exit 1; }; }
1658 rm -f conftest.$ac_cv_objext conftest.$ac_ext
1660 echo "$as_me:1660: result: $ac_cv_objext" >&5
1661 echo "${ECHO_T}$ac_cv_objext" >&6
1662 OBJEXT=$ac_cv_objext
1664 echo "$as_me:1664: checking whether we are using the GNU C compiler" >&5
1665 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1666 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1667 echo $ECHO_N "(cached) $ECHO_C" >&6
1669 cat >conftest.$ac_ext <<_ACEOF
1670 #line 1670 "configure"
1671 #include "confdefs.h"
1684 rm -f conftest.$ac_objext
1685 if { (eval echo "$as_me:1685: \"$ac_compile\"") >&5
1686 (eval $ac_compile) 2>&5
1688 echo "$as_me:1688: \$? = $ac_status" >&5
1689 (exit $ac_status); } &&
1690 { ac_try='test -s conftest.$ac_objext'
1691 { (eval echo "$as_me:1691: \"$ac_try\"") >&5
1694 echo "$as_me:1694: \$? = $ac_status" >&5
1695 (exit $ac_status); }; }; then
1698 echo "$as_me: failed program was:" >&5
1699 cat conftest.$ac_ext >&5
1702 rm -f conftest.$ac_objext conftest.$ac_ext
1703 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1706 echo "$as_me:1706: result: $ac_cv_c_compiler_gnu" >&5
1707 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1708 GCC=`test $ac_compiler_gnu = yes && echo yes`
1709 ac_test_CFLAGS=${CFLAGS+set}
1710 ac_save_CFLAGS=$CFLAGS
1712 echo "$as_me:1712: checking whether $CC accepts -g" >&5
1713 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1714 if test "${ac_cv_prog_cc_g+set}" = set; then
1715 echo $ECHO_N "(cached) $ECHO_C" >&6
1717 cat >conftest.$ac_ext <<_ACEOF
1718 #line 1718 "configure"
1719 #include "confdefs.h"
1729 rm -f conftest.$ac_objext
1730 if { (eval echo "$as_me:1730: \"$ac_compile\"") >&5
1731 (eval $ac_compile) 2>&5
1733 echo "$as_me:1733: \$? = $ac_status" >&5
1734 (exit $ac_status); } &&
1735 { ac_try='test -s conftest.$ac_objext'
1736 { (eval echo "$as_me:1736: \"$ac_try\"") >&5
1739 echo "$as_me:1739: \$? = $ac_status" >&5
1740 (exit $ac_status); }; }; then
1743 echo "$as_me: failed program was:" >&5
1744 cat conftest.$ac_ext >&5
1747 rm -f conftest.$ac_objext conftest.$ac_ext
1749 echo "$as_me:1749: result: $ac_cv_prog_cc_g" >&5
1750 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1751 if test "$ac_test_CFLAGS" = set; then
1752 CFLAGS=$ac_save_CFLAGS
1753 elif test $ac_cv_prog_cc_g = yes; then
1754 if test "$GCC" = yes; then
1760 if test "$GCC" = yes; then
1766 # Some people use a C++ compiler to compile C. Since we use `exit',
1767 # in C++ we need to declare it. In case someone uses the same compiler
1768 # for both compiling C and C++ we need to have the C++ compiler decide
1769 # the declaration of exit, since it's the most demanding environment.
1770 cat >conftest.$ac_ext <<_ACEOF
1775 rm -f conftest.$ac_objext
1776 if { (eval echo "$as_me:1776: \"$ac_compile\"") >&5
1777 (eval $ac_compile) 2>&5
1779 echo "$as_me:1779: \$? = $ac_status" >&5
1780 (exit $ac_status); } &&
1781 { ac_try='test -s conftest.$ac_objext'
1782 { (eval echo "$as_me:1782: \"$ac_try\"") >&5
1785 echo "$as_me:1785: \$? = $ac_status" >&5
1786 (exit $ac_status); }; }; then
1787 for ac_declaration in \
1789 '#include <stdlib.h>' \
1790 'extern "C" void std::exit (int) throw (); using std::exit;' \
1791 'extern "C" void std::exit (int); using std::exit;' \
1792 'extern "C" void exit (int) throw ();' \
1793 'extern "C" void exit (int);' \
1796 cat >conftest.$ac_ext <<_ACEOF
1797 #line 1797 "configure"
1798 #include "confdefs.h"
1809 rm -f conftest.$ac_objext
1810 if { (eval echo "$as_me:1810: \"$ac_compile\"") >&5
1811 (eval $ac_compile) 2>&5
1813 echo "$as_me:1813: \$? = $ac_status" >&5
1814 (exit $ac_status); } &&
1815 { ac_try='test -s conftest.$ac_objext'
1816 { (eval echo "$as_me:1816: \"$ac_try\"") >&5
1819 echo "$as_me:1819: \$? = $ac_status" >&5
1820 (exit $ac_status); }; }; then
1823 echo "$as_me: failed program was:" >&5
1824 cat conftest.$ac_ext >&5
1827 rm -f conftest.$ac_objext conftest.$ac_ext
1828 cat >conftest.$ac_ext <<_ACEOF
1829 #line 1829 "configure"
1830 #include "confdefs.h"
1840 rm -f conftest.$ac_objext
1841 if { (eval echo "$as_me:1841: \"$ac_compile\"") >&5
1842 (eval $ac_compile) 2>&5
1844 echo "$as_me:1844: \$? = $ac_status" >&5
1845 (exit $ac_status); } &&
1846 { ac_try='test -s conftest.$ac_objext'
1847 { (eval echo "$as_me:1847: \"$ac_try\"") >&5
1850 echo "$as_me:1850: \$? = $ac_status" >&5
1851 (exit $ac_status); }; }; then
1854 echo "$as_me: failed program was:" >&5
1855 cat conftest.$ac_ext >&5
1857 rm -f conftest.$ac_objext conftest.$ac_ext
1860 if test -n "$ac_declaration"; then
1861 echo '#ifdef __cplusplus' >>confdefs.h
1862 echo $ac_declaration >>confdefs.h
1863 echo '#endif' >>confdefs.h
1867 echo "$as_me: failed program was:" >&5
1868 cat conftest.$ac_ext >&5
1870 rm -f conftest.$ac_objext conftest.$ac_ext
1872 ac_cpp='$CPP $CPPFLAGS'
1873 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1874 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1875 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1876 ac_main_return=return
1879 if test "$GCC" = yes ; then
1880 echo "$as_me:1880: checking version of $CC" >&5
1881 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
1882 GCC_VERSION="`${CC} --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(GCC) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
1883 test -z "$GCC_VERSION" && GCC_VERSION=unknown
1884 echo "$as_me:1884: result: $GCC_VERSION" >&5
1885 echo "${ECHO_T}$GCC_VERSION" >&6
1889 ac_cpp='$CPP $CPPFLAGS'
1890 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1891 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1892 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1893 ac_main_return=return
1894 echo "$as_me:1894: checking how to run the C preprocessor" >&5
1895 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
1896 # On Suns, sometimes $CPP names a directory.
1897 if test -n "$CPP" && test -d "$CPP"; then
1900 if test -z "$CPP"; then
1901 if test "${ac_cv_prog_CPP+set}" = set; then
1902 echo $ECHO_N "(cached) $ECHO_C" >&6
1904 # Double quotes because CPP needs to be expanded
1905 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
1908 for ac_c_preproc_warn_flag in '' yes
1910 # Use a header file that comes with gcc, so configuring glibc
1911 # with a fresh cross-compiler works.
1912 # On the NeXT, cc -E runs the code through the compiler's parser,
1913 # not just through cpp. "Syntax error" is here to catch this case.
1914 cat >conftest.$ac_ext <<_ACEOF
1915 #line 1915 "configure"
1916 #include "confdefs.h"
1920 if { (eval echo "$as_me:1920: \"$ac_cpp conftest.$ac_ext\"") >&5
1921 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1923 egrep -v '^ *\+' conftest.er1 >conftest.err
1925 cat conftest.err >&5
1926 echo "$as_me:1926: \$? = $ac_status" >&5
1927 (exit $ac_status); } >/dev/null; then
1928 if test -s conftest.err; then
1929 ac_cpp_err=$ac_c_preproc_warn_flag
1936 if test -z "$ac_cpp_err"; then
1939 echo "$as_me: failed program was:" >&5
1940 cat conftest.$ac_ext >&5
1941 # Broken: fails on valid input.
1944 rm -f conftest.err conftest.$ac_ext
1946 # OK, works on sane cases. Now check whether non-existent headers
1947 # can be detected and how.
1948 cat >conftest.$ac_ext <<_ACEOF
1949 #line 1949 "configure"
1950 #include "confdefs.h"
1951 #include <ac_nonexistent.h>
1953 if { (eval echo "$as_me:1953: \"$ac_cpp conftest.$ac_ext\"") >&5
1954 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1956 egrep -v '^ *\+' conftest.er1 >conftest.err
1958 cat conftest.err >&5
1959 echo "$as_me:1959: \$? = $ac_status" >&5
1960 (exit $ac_status); } >/dev/null; then
1961 if test -s conftest.err; then
1962 ac_cpp_err=$ac_c_preproc_warn_flag
1969 if test -z "$ac_cpp_err"; then
1970 # Broken: success on invalid input.
1973 echo "$as_me: failed program was:" >&5
1974 cat conftest.$ac_ext >&5
1975 # Passes both tests.
1979 rm -f conftest.err conftest.$ac_ext
1982 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
1983 rm -f conftest.err conftest.$ac_ext
1984 if $ac_preproc_ok; then
1996 echo "$as_me:1996: result: $CPP" >&5
1997 echo "${ECHO_T}$CPP" >&6
1999 for ac_c_preproc_warn_flag in '' yes
2001 # Use a header file that comes with gcc, so configuring glibc
2002 # with a fresh cross-compiler works.
2003 # On the NeXT, cc -E runs the code through the compiler's parser,
2004 # not just through cpp. "Syntax error" is here to catch this case.
2005 cat >conftest.$ac_ext <<_ACEOF
2006 #line 2006 "configure"
2007 #include "confdefs.h"
2011 if { (eval echo "$as_me:2011: \"$ac_cpp conftest.$ac_ext\"") >&5
2012 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2014 egrep -v '^ *\+' conftest.er1 >conftest.err
2016 cat conftest.err >&5
2017 echo "$as_me:2017: \$? = $ac_status" >&5
2018 (exit $ac_status); } >/dev/null; then
2019 if test -s conftest.err; then
2020 ac_cpp_err=$ac_c_preproc_warn_flag
2027 if test -z "$ac_cpp_err"; then
2030 echo "$as_me: failed program was:" >&5
2031 cat conftest.$ac_ext >&5
2032 # Broken: fails on valid input.
2035 rm -f conftest.err conftest.$ac_ext
2037 # OK, works on sane cases. Now check whether non-existent headers
2038 # can be detected and how.
2039 cat >conftest.$ac_ext <<_ACEOF
2040 #line 2040 "configure"
2041 #include "confdefs.h"
2042 #include <ac_nonexistent.h>
2044 if { (eval echo "$as_me:2044: \"$ac_cpp conftest.$ac_ext\"") >&5
2045 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2047 egrep -v '^ *\+' conftest.er1 >conftest.err
2049 cat conftest.err >&5
2050 echo "$as_me:2050: \$? = $ac_status" >&5
2051 (exit $ac_status); } >/dev/null; then
2052 if test -s conftest.err; then
2053 ac_cpp_err=$ac_c_preproc_warn_flag
2060 if test -z "$ac_cpp_err"; then
2061 # Broken: success on invalid input.
2064 echo "$as_me: failed program was:" >&5
2065 cat conftest.$ac_ext >&5
2066 # Passes both tests.
2070 rm -f conftest.err conftest.$ac_ext
2073 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2074 rm -f conftest.err conftest.$ac_ext
2075 if $ac_preproc_ok; then
2078 { { echo "$as_me:2078: error: C preprocessor \"$CPP\" fails sanity check" >&5
2079 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2080 { (exit 1); exit 1; }; }
2084 ac_cpp='$CPP $CPPFLAGS'
2085 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2086 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2087 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2088 ac_main_return=return
2090 if test $ac_cv_c_compiler_gnu = yes; then
2091 echo "$as_me:2091: checking whether $CC needs -traditional" >&5
2092 echo $ECHO_N "checking whether $CC needs -traditional... $ECHO_C" >&6
2093 if test "${ac_cv_prog_gcc_traditional+set}" = set; then
2094 echo $ECHO_N "(cached) $ECHO_C" >&6
2096 ac_pattern="Autoconf.*'x'"
2097 cat >conftest.$ac_ext <<_ACEOF
2098 #line 2098 "configure"
2099 #include "confdefs.h"
2101 int Autoconf = TIOCGETP;
2103 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2104 egrep "$ac_pattern" >/dev/null 2>&1; then
2105 ac_cv_prog_gcc_traditional=yes
2107 ac_cv_prog_gcc_traditional=no
2111 if test $ac_cv_prog_gcc_traditional = no; then
2112 cat >conftest.$ac_ext <<_ACEOF
2113 #line 2113 "configure"
2114 #include "confdefs.h"
2116 int Autoconf = TCGETA;
2118 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2119 egrep "$ac_pattern" >/dev/null 2>&1; then
2120 ac_cv_prog_gcc_traditional=yes
2126 echo "$as_me:2126: result: $ac_cv_prog_gcc_traditional" >&5
2127 echo "${ECHO_T}$ac_cv_prog_gcc_traditional" >&6
2128 if test $ac_cv_prog_gcc_traditional = yes; then
2129 CC="$CC -traditional"
2133 echo "$as_me:2133: checking whether $CC understands -c and -o together" >&5
2134 echo $ECHO_N "checking whether $CC understands -c and -o together... $ECHO_C" >&6
2135 if test "${cf_cv_prog_CC_c_o+set}" = set; then
2136 echo $ECHO_N "(cached) $ECHO_C" >&6
2139 cat > conftest.$ac_ext <<CF_EOF
2143 ${cf_cv_main_return:-return}(0);
2146 # We do the test twice because some compilers refuse to overwrite an
2147 # existing .o file with -o, though they will create one.
2148 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
2149 if { (eval echo "$as_me:2149: \"$ac_try\"") >&5
2152 echo "$as_me:2152: \$? = $ac_status" >&5
2153 (exit $ac_status); } &&
2154 test -f conftest2.$ac_objext && { (eval echo "$as_me:2154: \"$ac_try\"") >&5
2157 echo "$as_me:2157: \$? = $ac_status" >&5
2158 (exit $ac_status); };
2160 eval cf_cv_prog_CC_c_o=yes
2162 eval cf_cv_prog_CC_c_o=no
2167 if test $cf_cv_prog_CC_c_o = yes; then
2168 echo "$as_me:2168: result: yes" >&5
2169 echo "${ECHO_T}yes" >&6
2171 echo "$as_me:2171: result: no" >&5
2172 echo "${ECHO_T}no" >&6
2175 echo "$as_me:2175: checking for POSIXized ISC" >&5
2176 echo $ECHO_N "checking for POSIXized ISC... $ECHO_C" >&6
2177 if test -d /etc/conf/kconfig.d &&
2178 grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
2180 echo "$as_me:2180: result: yes" >&5
2181 echo "${ECHO_T}yes" >&6
2182 ISC=yes # If later tests want to check for ISC.
2184 cat >>confdefs.h <<\EOF
2185 #define _POSIX_SOURCE 1
2188 if test "$GCC" = yes; then
2194 echo "$as_me:2194: result: no" >&5
2195 echo "${ECHO_T}no" >&6
2199 echo "$as_me:2199: checking for ${CC:-cc} option to accept ANSI C" >&5
2200 echo $ECHO_N "checking for ${CC:-cc} option to accept ANSI C... $ECHO_C" >&6
2201 if test "${cf_cv_ansi_cc+set}" = set; then
2202 echo $ECHO_N "(cached) $ECHO_C" >&6
2206 cf_save_CFLAGS="$CFLAGS"
2207 cf_save_CPPFLAGS="$CPPFLAGS"
2208 # Don't try gcc -ansi; that turns off useful extensions and
2209 # breaks some systems' header files.
2210 # AIX -qlanglvl=ansi
2211 # Ultrix and OSF/1 -std1
2212 # HP-UX -Aa -D_HPUX_SOURCE
2214 # UnixWare 1.2 (cannot use -Xc, since ANSI/POSIX clashes)
2215 for cf_arg in "-DCC_HAS_PROTOS" \
2220 "-Aa -D_HPUX_SOURCE" \
2227 cf_new_extra_cppflags=
2229 for cf_add_cflags in $cf_arg
2231 case $cf_fix_cppflags in
2233 case $cf_add_cflags in #(vi
2234 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
2235 case $cf_add_cflags in
2237 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2239 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2240 && test -z "${cf_tst_cflags}" \
2241 && cf_fix_cppflags=yes
2243 if test $cf_fix_cppflags = yes ; then
2244 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2246 elif test "${cf_tst_cflags}" = "\"'" ; then
2247 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2253 *$cf_add_cflags) #(vi
2256 case $cf_add_cflags in #(vi
2258 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2260 CPPFLAGS=`echo "$CPPFLAGS" | \
2261 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2262 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2266 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
2271 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
2276 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2278 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2280 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2281 && test -z "${cf_tst_cflags}" \
2282 && cf_fix_cppflags=no
2287 if test -n "$cf_new_cflags" ; then
2289 CFLAGS="$CFLAGS $cf_new_cflags"
2292 if test -n "$cf_new_cppflags" ; then
2294 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
2297 if test -n "$cf_new_extra_cppflags" ; then
2299 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
2302 cat >conftest.$ac_ext <<_ACEOF
2303 #line 2303 "configure"
2304 #include "confdefs.h"
2306 #ifndef CC_HAS_PROTOS
2307 #if !defined(__STDC__) || (__STDC__ != 1)
2316 int test (int i, double x);
2317 struct s1 {int (*f) (int a);};
2318 struct s2 {int (*f) (double a);};
2323 rm -f conftest.$ac_objext
2324 if { (eval echo "$as_me:2324: \"$ac_compile\"") >&5
2325 (eval $ac_compile) 2>&5
2327 echo "$as_me:2327: \$? = $ac_status" >&5
2328 (exit $ac_status); } &&
2329 { ac_try='test -s conftest.$ac_objext'
2330 { (eval echo "$as_me:2330: \"$ac_try\"") >&5
2333 echo "$as_me:2333: \$? = $ac_status" >&5
2334 (exit $ac_status); }; }; then
2335 cf_cv_ansi_cc="$cf_arg"; break
2337 echo "$as_me: failed program was:" >&5
2338 cat conftest.$ac_ext >&5
2340 rm -f conftest.$ac_objext conftest.$ac_ext
2342 CFLAGS="$cf_save_CFLAGS"
2343 CPPFLAGS="$cf_save_CPPFLAGS"
2346 echo "$as_me:2346: result: $cf_cv_ansi_cc" >&5
2347 echo "${ECHO_T}$cf_cv_ansi_cc" >&6
2349 if test "$cf_cv_ansi_cc" != "no"; then
2350 if test ".$cf_cv_ansi_cc" != ".-DCC_HAS_PROTOS"; then
2355 cf_new_extra_cppflags=
2357 for cf_add_cflags in $cf_cv_ansi_cc
2359 case $cf_fix_cppflags in
2361 case $cf_add_cflags in #(vi
2362 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
2363 case $cf_add_cflags in
2365 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2367 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2368 && test -z "${cf_tst_cflags}" \
2369 && cf_fix_cppflags=yes
2371 if test $cf_fix_cppflags = yes ; then
2372 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2374 elif test "${cf_tst_cflags}" = "\"'" ; then
2375 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2381 *$cf_add_cflags) #(vi
2384 case $cf_add_cflags in #(vi
2386 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2388 CPPFLAGS=`echo "$CPPFLAGS" | \
2389 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2390 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2394 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
2399 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
2404 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2406 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2408 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2409 && test -z "${cf_tst_cflags}" \
2410 && cf_fix_cppflags=no
2415 if test -n "$cf_new_cflags" ; then
2417 CFLAGS="$CFLAGS $cf_new_cflags"
2420 if test -n "$cf_new_cppflags" ; then
2422 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
2425 if test -n "$cf_new_extra_cppflags" ; then
2427 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
2431 cat >>confdefs.h <<\EOF
2432 #define CC_HAS_PROTOS 1
2438 if test "$cf_cv_ansi_cc" = "no"; then
2439 { { echo "$as_me:2439: error: Your compiler does not appear to recognize prototypes.
2440 You have the following choices:
2441 a. adjust your compiler options
2442 b. get an up-to-date compiler
2443 c. use a wrapper such as unproto" >&5
2444 echo "$as_me: error: Your compiler does not appear to recognize prototypes.
2445 You have the following choices:
2446 a. adjust your compiler options
2447 b. get an up-to-date compiler
2448 c. use a wrapper such as unproto" >&2;}
2449 { (exit 1); exit 1; }; }
2452 case $cf_cv_system_name in
2454 CFLAGS="$CFLAGS -Zmt"
2455 CPPFLAGS="$CPPFLAGS -D__ST_MT_ERRNO__"
2456 CXXFLAGS="$CXXFLAGS -Zmt"
2457 # autoconf's macro sets -Zexe and suffix both, which conflict:w
2458 LDFLAGS="$LDFLAGS -Zmt -Zcrtdll"
2465 test -n "$PROG_EXT" && cat >>confdefs.h <<EOF
2466 #define PROG_EXT "$PROG_EXT"
2469 test "$program_prefix" != NONE &&
2470 program_transform_name="s,^,$program_prefix,;$program_transform_name"
2471 # Use a double $ so make ignores it.
2472 test "$program_suffix" != NONE &&
2473 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
2474 # Double any \ or $. echo might interpret backslashes.
2475 # By default was `s,x,x', remove it if useless.
2476 cat <<\_ACEOF >conftest.sed
2477 s/[\\$]/&&/g;s/;s,x,x,$//
2479 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
2482 for ac_prog in mawk gawk nawk awk
2484 # Extract the first word of "$ac_prog", so it can be a program name with args.
2485 set dummy $ac_prog; ac_word=$2
2486 echo "$as_me:2486: checking for $ac_word" >&5
2487 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2488 if test "${ac_cv_prog_AWK+set}" = set; then
2489 echo $ECHO_N "(cached) $ECHO_C" >&6
2491 if test -n "$AWK"; then
2492 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2494 ac_save_IFS=$IFS; IFS=$ac_path_separator
2496 for ac_dir in $ac_dummy; do
2498 test -z "$ac_dir" && ac_dir=.
2499 $as_executable_p "$ac_dir/$ac_word" || continue
2500 ac_cv_prog_AWK="$ac_prog"
2501 echo "$as_me:2501: found $ac_dir/$ac_word" >&5
2508 if test -n "$AWK"; then
2509 echo "$as_me:2509: result: $AWK" >&5
2510 echo "${ECHO_T}$AWK" >&6
2512 echo "$as_me:2512: result: no" >&5
2513 echo "${ECHO_T}no" >&6
2516 test -n "$AWK" && break
2519 test -z "$AWK" && { { echo "$as_me:2519: error: No awk program found" >&5
2520 echo "$as_me: error: No awk program found" >&2;}
2521 { (exit 1); exit 1; }; }
2523 echo "$as_me:2523: checking for egrep" >&5
2524 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
2525 if test "${ac_cv_prog_egrep+set}" = set; then
2526 echo $ECHO_N "(cached) $ECHO_C" >&6
2528 if echo a | (grep -E '(a|b)') >/dev/null 2>&1
2529 then ac_cv_prog_egrep='grep -E'
2530 else ac_cv_prog_egrep='egrep'
2533 echo "$as_me:2533: result: $ac_cv_prog_egrep" >&5
2534 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
2535 EGREP=$ac_cv_prog_egrep
2537 test -z "$EGREP" && { { echo "$as_me:2537: error: No egrep program found" >&5
2538 echo "$as_me: error: No egrep program found" >&2;}
2539 { (exit 1); exit 1; }; }
2541 # Find a good install program. We prefer a C program (faster),
2542 # so one script is as good as another. But avoid the broken or
2543 # incompatible versions:
2544 # SysV /etc/install, /usr/sbin/install
2545 # SunOS /usr/etc/install
2546 # IRIX /sbin/install
2548 # AmigaOS /C/install, which installs bootblocks on floppy discs
2549 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2550 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2551 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2552 # ./install, which can be erroneously created by make from ./install.sh.
2553 echo "$as_me:2553: checking for a BSD compatible install" >&5
2554 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2555 if test -z "$INSTALL"; then
2556 if test "${ac_cv_path_install+set}" = set; then
2557 echo $ECHO_N "(cached) $ECHO_C" >&6
2559 ac_save_IFS=$IFS; IFS=$ac_path_separator
2560 for ac_dir in $PATH; do
2562 # Account for people who put trailing slashes in PATH elements.
2564 / | ./ | .// | /cC/* \
2565 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2568 # OSF1 and SCO ODT 3.0 have their own names for install.
2569 # Don't use installbsd from OSF since it installs stuff as root
2571 for ac_prog in ginstall scoinst install; do
2572 if $as_executable_p "$ac_dir/$ac_prog"; then
2573 if test $ac_prog = install &&
2574 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2575 # AIX install. It has an incompatible calling convention.
2577 elif test $ac_prog = install &&
2578 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2579 # program-specific install script used by HP pwplus--don't use.
2582 ac_cv_path_install="$ac_dir/$ac_prog -c"
2592 if test "${ac_cv_path_install+set}" = set; then
2593 INSTALL=$ac_cv_path_install
2595 # As a last resort, use the slow shell script. We don't cache a
2596 # path for INSTALL within a source directory, because that will
2597 # break other packages using the cache if that directory is
2598 # removed, or if the path is relative.
2599 INSTALL=$ac_install_sh
2602 echo "$as_me:2602: result: $INSTALL" >&5
2603 echo "${ECHO_T}$INSTALL" >&6
2605 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2606 # It thinks the first close brace ends the variable substitution.
2607 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2609 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2611 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2613 echo "$as_me:2613: checking whether ln -s works" >&5
2614 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
2616 if test "$LN_S" = "ln -s"; then
2617 echo "$as_me:2617: result: yes" >&5
2618 echo "${ECHO_T}yes" >&6
2620 echo "$as_me:2620: result: no, using $LN_S" >&5
2621 echo "${ECHO_T}no, using $LN_S" >&6
2624 echo "$as_me:2624: checking if $LN_S -f options work" >&5
2625 echo $ECHO_N "checking if $LN_S -f options work... $ECHO_C" >&6
2627 rm -f conf$$.src conf$$dst
2629 echo first >conf$$.src
2630 if $LN_S -f conf$$.src conf$$.dst 2>/dev/null; then
2635 rm -f conf$$.dst conf$$src
2636 echo "$as_me:2636: result: $cf_prog_ln_sf" >&5
2637 echo "${ECHO_T}$cf_prog_ln_sf" >&6
2639 test "$cf_prog_ln_sf" = yes && LN_S="$LN_S -f"
2641 echo "$as_me:2641: checking for long file names" >&5
2642 echo $ECHO_N "checking for long file names... $ECHO_C" >&6
2643 if test "${ac_cv_sys_long_file_names+set}" = set; then
2644 echo $ECHO_N "(cached) $ECHO_C" >&6
2646 ac_cv_sys_long_file_names=yes
2647 # Test for long file names in all the places we know might matter:
2648 # . the current directory, where building will happen
2649 # $prefix/lib where we will be installing things
2650 # $exec_prefix/lib likewise
2651 # eval it to expand exec_prefix.
2652 # $TMPDIR if set, where it might want to write temporary files
2653 # if $TMPDIR is not set:
2654 # /tmp where it might want to write temporary files
2657 if test -n "$TMPDIR" && test -d "$TMPDIR" && test -w "$TMPDIR"; then
2660 ac_tmpdirs='/tmp /var/tmp /usr/tmp'
2662 for ac_dir in . $ac_tmpdirs `eval echo $prefix/lib $exec_prefix/lib` ; do
2663 test -d $ac_dir || continue
2664 test -w $ac_dir || continue # It is less confusing to not echo anything here.
2665 ac_xdir=$ac_dir/cf$$
2666 (umask 077 && mkdir $ac_xdir 2>/dev/null) || continue
2667 ac_tf1=$ac_xdir/conftest9012345
2668 ac_tf2=$ac_xdir/conftest9012346
2669 (echo 1 >$ac_tf1) 2>/dev/null
2670 (echo 2 >$ac_tf2) 2>/dev/null
2671 ac_val=`cat $ac_tf1 2>/dev/null`
2672 if test ! -f $ac_tf1 || test "$ac_val" != 1; then
2673 ac_cv_sys_long_file_names=no
2674 rm -rf $ac_xdir 2>/dev/null
2677 rm -rf $ac_xdir 2>/dev/null
2680 echo "$as_me:2680: result: $ac_cv_sys_long_file_names" >&5
2681 echo "${ECHO_T}$ac_cv_sys_long_file_names" >&6
2682 if test $ac_cv_sys_long_file_names = yes; then
2684 cat >>confdefs.h <<\EOF
2685 #define HAVE_LONG_FILE_NAMES 1
2690 # if we find pkg-config, check if we should install the ".pc" files.
2692 echo "$as_me:2692: checking if you want to use pkg-config" >&5
2693 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
2695 # Check whether --with-pkg-config or --without-pkg-config was given.
2696 if test "${with_pkg_config+set}" = set; then
2697 withval="$with_pkg_config"
2698 cf_pkg_config=$withval
2702 echo "$as_me:2702: result: $cf_pkg_config" >&5
2703 echo "${ECHO_T}$cf_pkg_config" >&6
2705 case $cf_pkg_config in #(vi
2710 if test -n "$ac_tool_prefix"; then
2711 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
2712 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
2713 echo "$as_me:2713: checking for $ac_word" >&5
2714 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2715 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
2716 echo $ECHO_N "(cached) $ECHO_C" >&6
2720 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
2723 ac_save_IFS=$IFS; IFS=$ac_path_separator
2725 for ac_dir in $ac_dummy; do
2727 test -z "$ac_dir" && ac_dir=.
2728 if $as_executable_p "$ac_dir/$ac_word"; then
2729 ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
2730 echo "$as_me:2730: found $ac_dir/$ac_word" >&5
2738 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
2740 if test -n "$PKG_CONFIG"; then
2741 echo "$as_me:2741: result: $PKG_CONFIG" >&5
2742 echo "${ECHO_T}$PKG_CONFIG" >&6
2744 echo "$as_me:2744: result: no" >&5
2745 echo "${ECHO_T}no" >&6
2749 if test -z "$ac_cv_path_PKG_CONFIG"; then
2750 ac_pt_PKG_CONFIG=$PKG_CONFIG
2751 # Extract the first word of "pkg-config", so it can be a program name with args.
2752 set dummy pkg-config; ac_word=$2
2753 echo "$as_me:2753: checking for $ac_word" >&5
2754 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2755 if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
2756 echo $ECHO_N "(cached) $ECHO_C" >&6
2758 case $ac_pt_PKG_CONFIG in
2760 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
2763 ac_save_IFS=$IFS; IFS=$ac_path_separator
2765 for ac_dir in $ac_dummy; do
2767 test -z "$ac_dir" && ac_dir=.
2768 if $as_executable_p "$ac_dir/$ac_word"; then
2769 ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
2770 echo "$as_me:2770: found $ac_dir/$ac_word" >&5
2775 test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none"
2779 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
2781 if test -n "$ac_pt_PKG_CONFIG"; then
2782 echo "$as_me:2782: result: $ac_pt_PKG_CONFIG" >&5
2783 echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
2785 echo "$as_me:2785: result: no" >&5
2786 echo "${ECHO_T}no" >&6
2789 PKG_CONFIG=$ac_pt_PKG_CONFIG
2791 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
2800 test -z "$PKG_CONFIG" && PKG_CONFIG=none
2801 if test "$PKG_CONFIG" != none ; then
2803 if test "x$prefix" != xNONE; then
2804 cf_path_syntax="$prefix"
2806 cf_path_syntax="$ac_default_prefix"
2809 case ".$PKG_CONFIG" in #(vi
2810 .\$\(*\)*|.\'*\'*) #(vi
2814 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
2817 eval PKG_CONFIG="$PKG_CONFIG"
2818 case ".$PKG_CONFIG" in #(vi
2820 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
2825 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
2828 { { echo "$as_me:2828: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
2829 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
2830 { (exit 1); exit 1; }; }
2836 if test "$PKG_CONFIG" != no ; then
2837 echo "$as_me:2837: checking if we should install .pc files for $PKG_CONFIG" >&5
2838 echo $ECHO_N "checking if we should install .pc files for $PKG_CONFIG... $ECHO_C" >&6
2840 # Leave this as something that can be overridden in the environment.
2841 if test -z "$PKG_CONFIG_LIBDIR" ; then
2842 PKG_CONFIG_LIBDIR=`echo "$PKG_CONFIG" | sed -e 's,/[^/]*/[^/]*$,,'`/lib/pkgconfig
2844 PKG_CONFIG_LIBDIR=`echo "$PKG_CONFIG_LIBDIR" | sed -e 's/^://' -e 's/:.*//'`
2845 if test -n "$PKG_CONFIG_LIBDIR" && test -d "$PKG_CONFIG_LIBDIR" ; then
2847 # Check whether --enable-pc-files or --disable-pc-files was given.
2848 if test "${enable_pc_files+set}" = set; then
2849 enableval="$enable_pc_files"
2850 enable_pc_files=$enableval
2854 echo "$as_me:2854: result: $enable_pc_files" >&5
2855 echo "${ECHO_T}$enable_pc_files" >&6
2857 echo "$as_me:2857: result: no" >&5
2858 echo "${ECHO_T}no" >&6
2859 { echo "$as_me:2859: WARNING: did not find library $PKG_CONFIG_LIBDIR" >&5
2860 echo "$as_me: WARNING: did not find library $PKG_CONFIG_LIBDIR" >&2;}
2865 echo "$as_me:2865: checking if you want to build test-programs" >&5
2866 echo $ECHO_N "checking if you want to build test-programs... $ECHO_C" >&6
2868 # Check whether --with-tests or --without-tests was given.
2869 if test "${with_tests+set}" = set; then
2870 withval="$with_tests"
2871 cf_with_tests=$withval
2875 echo "$as_me:2875: result: $cf_with_tests" >&5
2876 echo "${ECHO_T}$cf_with_tests" >&6
2878 echo "$as_me:2878: checking if we should assume mixed-case filenames" >&5
2879 echo $ECHO_N "checking if we should assume mixed-case filenames... $ECHO_C" >&6
2881 # Check whether --enable-mixed-case or --disable-mixed-case was given.
2882 if test "${enable_mixed_case+set}" = set; then
2883 enableval="$enable_mixed_case"
2884 enable_mixedcase=$enableval
2886 enable_mixedcase=auto
2888 echo "$as_me:2888: result: $enable_mixedcase" >&5
2889 echo "${ECHO_T}$enable_mixedcase" >&6
2890 if test "$enable_mixedcase" = "auto" ; then
2892 echo "$as_me:2892: checking if filesystem supports mixed-case filenames" >&5
2893 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
2894 if test "${cf_cv_mixedcase+set}" = set; then
2895 echo $ECHO_N "(cached) $ECHO_C" >&6
2898 if test "$cross_compiling" = yes ; then
2899 case $target_alias in #(vi
2900 *-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-mingw32*|*-uwin*) #(vi
2908 rm -f conftest CONFTEST
2910 if test -f CONFTEST ; then
2915 rm -f conftest CONFTEST
2919 echo "$as_me:2919: result: $cf_cv_mixedcase" >&5
2920 echo "${ECHO_T}$cf_cv_mixedcase" >&6
2921 test "$cf_cv_mixedcase" = yes && cat >>confdefs.h <<\EOF
2922 #define MIXEDCASE_FILENAMES 1
2926 cf_cv_mixedcase=$enable_mixedcase
2927 if test "$enable_mixedcase" = "yes" ; then
2928 cat >>confdefs.h <<\EOF
2929 #define MIXEDCASE_FILENAMES 1
2935 # do this after mixed-case option (tags/TAGS is not as important as tic).
2936 echo "$as_me:2936: checking whether ${MAKE-make} sets \${MAKE}" >&5
2937 echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
2938 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
2939 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
2940 echo $ECHO_N "(cached) $ECHO_C" >&6
2942 cat >conftest.make <<\EOF
2944 @echo 'ac_maketemp="${MAKE}"'
2946 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
2947 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
2948 if test -n "$ac_maketemp"; then
2949 eval ac_cv_prog_make_${ac_make}_set=yes
2951 eval ac_cv_prog_make_${ac_make}_set=no
2955 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
2956 echo "$as_me:2956: result: yes" >&5
2957 echo "${ECHO_T}yes" >&6
2960 echo "$as_me:2960: result: no" >&5
2961 echo "${ECHO_T}no" >&6
2962 SET_MAKE="MAKE=${MAKE-make}"
2965 for ac_prog in exctags ctags
2967 # Extract the first word of "$ac_prog", so it can be a program name with args.
2968 set dummy $ac_prog; ac_word=$2
2969 echo "$as_me:2969: checking for $ac_word" >&5
2970 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2971 if test "${ac_cv_prog_CTAGS+set}" = set; then
2972 echo $ECHO_N "(cached) $ECHO_C" >&6
2974 if test -n "$CTAGS"; then
2975 ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
2977 ac_save_IFS=$IFS; IFS=$ac_path_separator
2979 for ac_dir in $ac_dummy; do
2981 test -z "$ac_dir" && ac_dir=.
2982 $as_executable_p "$ac_dir/$ac_word" || continue
2983 ac_cv_prog_CTAGS="$ac_prog"
2984 echo "$as_me:2984: found $ac_dir/$ac_word" >&5
2990 CTAGS=$ac_cv_prog_CTAGS
2991 if test -n "$CTAGS"; then
2992 echo "$as_me:2992: result: $CTAGS" >&5
2993 echo "${ECHO_T}$CTAGS" >&6
2995 echo "$as_me:2995: result: no" >&5
2996 echo "${ECHO_T}no" >&6
2999 test -n "$CTAGS" && break
3002 for ac_prog in exetags etags
3004 # Extract the first word of "$ac_prog", so it can be a program name with args.
3005 set dummy $ac_prog; 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_ETAGS+set}" = set; then
3009 echo $ECHO_N "(cached) $ECHO_C" >&6
3011 if test -n "$ETAGS"; then
3012 ac_cv_prog_ETAGS="$ETAGS" # 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_ETAGS="$ac_prog"
3021 echo "$as_me:3021: found $ac_dir/$ac_word" >&5
3027 ETAGS=$ac_cv_prog_ETAGS
3028 if test -n "$ETAGS"; then
3029 echo "$as_me:3029: result: $ETAGS" >&5
3030 echo "${ECHO_T}$ETAGS" >&6
3032 echo "$as_me:3032: result: no" >&5
3033 echo "${ECHO_T}no" >&6
3036 test -n "$ETAGS" && break
3039 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
3040 set dummy ${CTAGS:-ctags}; ac_word=$2
3041 echo "$as_me:3041: checking for $ac_word" >&5
3042 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3043 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
3044 echo $ECHO_N "(cached) $ECHO_C" >&6
3046 if test -n "$MAKE_LOWER_TAGS"; then
3047 ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
3049 ac_save_IFS=$IFS; IFS=$ac_path_separator
3051 for ac_dir in $ac_dummy; do
3053 test -z "$ac_dir" && ac_dir=.
3054 $as_executable_p "$ac_dir/$ac_word" || continue
3055 ac_cv_prog_MAKE_LOWER_TAGS="yes"
3056 echo "$as_me:3056: found $ac_dir/$ac_word" >&5
3060 test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
3063 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
3064 if test -n "$MAKE_LOWER_TAGS"; then
3065 echo "$as_me:3065: result: $MAKE_LOWER_TAGS" >&5
3066 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
3068 echo "$as_me:3068: result: no" >&5
3069 echo "${ECHO_T}no" >&6
3072 if test "$cf_cv_mixedcase" = yes ; then
3073 # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
3074 set dummy ${ETAGS:-etags}; ac_word=$2
3075 echo "$as_me:3075: checking for $ac_word" >&5
3076 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3077 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
3078 echo $ECHO_N "(cached) $ECHO_C" >&6
3080 if test -n "$MAKE_UPPER_TAGS"; then
3081 ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
3083 ac_save_IFS=$IFS; IFS=$ac_path_separator
3085 for ac_dir in $ac_dummy; do
3087 test -z "$ac_dir" && ac_dir=.
3088 $as_executable_p "$ac_dir/$ac_word" || continue
3089 ac_cv_prog_MAKE_UPPER_TAGS="yes"
3090 echo "$as_me:3090: found $ac_dir/$ac_word" >&5
3094 test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
3097 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
3098 if test -n "$MAKE_UPPER_TAGS"; then
3099 echo "$as_me:3099: result: $MAKE_UPPER_TAGS" >&5
3100 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
3102 echo "$as_me:3102: result: no" >&5
3103 echo "${ECHO_T}no" >&6
3110 if test "$MAKE_UPPER_TAGS" = yes ; then
3116 if test "$MAKE_LOWER_TAGS" = yes ; then
3122 echo "$as_me:3122: checking for makeflags variable" >&5
3123 echo $ECHO_N "checking for makeflags variable... $ECHO_C" >&6
3124 if test "${cf_cv_makeflags+set}" = set; then
3125 echo $ECHO_N "(cached) $ECHO_C" >&6
3129 for cf_option in '-${MAKEFLAGS}' '${MFLAGS}'
3131 cat >cf_makeflags.tmp <<CF_EOF
3134 @ echo '.$cf_option'
3136 cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp 2>/dev/null | sed -e 's,[ ]*$,,'`
3137 case "$cf_result" in
3139 cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp CC=cc 2>/dev/null`
3140 case "$cf_result" in
3141 .*CC=*) cf_cv_makeflags=
3143 *) cf_cv_makeflags=$cf_option
3149 *) echo "given option \"$cf_option\", no match \"$cf_result\""
3153 rm -f cf_makeflags.tmp
3156 echo "$as_me:3156: result: $cf_cv_makeflags" >&5
3157 echo "${ECHO_T}$cf_cv_makeflags" >&6
3159 if test -n "$ac_tool_prefix"; then
3160 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3161 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3162 echo "$as_me:3162: checking for $ac_word" >&5
3163 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3164 if test "${ac_cv_prog_RANLIB+set}" = set; then
3165 echo $ECHO_N "(cached) $ECHO_C" >&6
3167 if test -n "$RANLIB"; then
3168 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3170 ac_save_IFS=$IFS; IFS=$ac_path_separator
3172 for ac_dir in $ac_dummy; do
3174 test -z "$ac_dir" && ac_dir=.
3175 $as_executable_p "$ac_dir/$ac_word" || continue
3176 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3177 echo "$as_me:3177: found $ac_dir/$ac_word" >&5
3183 RANLIB=$ac_cv_prog_RANLIB
3184 if test -n "$RANLIB"; then
3185 echo "$as_me:3185: result: $RANLIB" >&5
3186 echo "${ECHO_T}$RANLIB" >&6
3188 echo "$as_me:3188: result: no" >&5
3189 echo "${ECHO_T}no" >&6
3193 if test -z "$ac_cv_prog_RANLIB"; then
3194 ac_ct_RANLIB=$RANLIB
3195 # Extract the first word of "ranlib", so it can be a program name with args.
3196 set dummy ranlib; ac_word=$2
3197 echo "$as_me:3197: checking for $ac_word" >&5
3198 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3199 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
3200 echo $ECHO_N "(cached) $ECHO_C" >&6
3202 if test -n "$ac_ct_RANLIB"; then
3203 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
3205 ac_save_IFS=$IFS; IFS=$ac_path_separator
3207 for ac_dir in $ac_dummy; do
3209 test -z "$ac_dir" && ac_dir=.
3210 $as_executable_p "$ac_dir/$ac_word" || continue
3211 ac_cv_prog_ac_ct_RANLIB="ranlib"
3212 echo "$as_me:3212: found $ac_dir/$ac_word" >&5
3216 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB="':'"
3219 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
3220 if test -n "$ac_ct_RANLIB"; then
3221 echo "$as_me:3221: result: $ac_ct_RANLIB" >&5
3222 echo "${ECHO_T}$ac_ct_RANLIB" >&6
3224 echo "$as_me:3224: result: no" >&5
3225 echo "${ECHO_T}no" >&6
3228 RANLIB=$ac_ct_RANLIB
3230 RANLIB="$ac_cv_prog_RANLIB"
3233 if test -n "$ac_tool_prefix"; then
3234 # Extract the first word of "${ac_tool_prefix}ld", so it can be a program name with args.
3235 set dummy ${ac_tool_prefix}ld; ac_word=$2
3236 echo "$as_me:3236: checking for $ac_word" >&5
3237 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3238 if test "${ac_cv_prog_LD+set}" = set; then
3239 echo $ECHO_N "(cached) $ECHO_C" >&6
3241 if test -n "$LD"; then
3242 ac_cv_prog_LD="$LD" # Let the user override the test.
3244 ac_save_IFS=$IFS; IFS=$ac_path_separator
3246 for ac_dir in $ac_dummy; do
3248 test -z "$ac_dir" && ac_dir=.
3249 $as_executable_p "$ac_dir/$ac_word" || continue
3250 ac_cv_prog_LD="${ac_tool_prefix}ld"
3251 echo "$as_me:3251: found $ac_dir/$ac_word" >&5
3258 if test -n "$LD"; then
3259 echo "$as_me:3259: result: $LD" >&5
3260 echo "${ECHO_T}$LD" >&6
3262 echo "$as_me:3262: result: no" >&5
3263 echo "${ECHO_T}no" >&6
3267 if test -z "$ac_cv_prog_LD"; then
3269 # Extract the first word of "ld", so it can be a program name with args.
3270 set dummy ld; ac_word=$2
3271 echo "$as_me:3271: checking for $ac_word" >&5
3272 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3273 if test "${ac_cv_prog_ac_ct_LD+set}" = set; then
3274 echo $ECHO_N "(cached) $ECHO_C" >&6
3276 if test -n "$ac_ct_LD"; then
3277 ac_cv_prog_ac_ct_LD="$ac_ct_LD" # Let the user override the test.
3279 ac_save_IFS=$IFS; IFS=$ac_path_separator
3281 for ac_dir in $ac_dummy; do
3283 test -z "$ac_dir" && ac_dir=.
3284 $as_executable_p "$ac_dir/$ac_word" || continue
3285 ac_cv_prog_ac_ct_LD="ld"
3286 echo "$as_me:3286: found $ac_dir/$ac_word" >&5
3290 test -z "$ac_cv_prog_ac_ct_LD" && ac_cv_prog_ac_ct_LD="ld"
3293 ac_ct_LD=$ac_cv_prog_ac_ct_LD
3294 if test -n "$ac_ct_LD"; then
3295 echo "$as_me:3295: result: $ac_ct_LD" >&5
3296 echo "${ECHO_T}$ac_ct_LD" >&6
3298 echo "$as_me:3298: result: no" >&5
3299 echo "${ECHO_T}no" >&6
3307 if test -n "$ac_tool_prefix"; then
3308 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
3309 set dummy ${ac_tool_prefix}ar; ac_word=$2
3310 echo "$as_me:3310: checking for $ac_word" >&5
3311 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3312 if test "${ac_cv_prog_AR+set}" = set; then
3313 echo $ECHO_N "(cached) $ECHO_C" >&6
3315 if test -n "$AR"; then
3316 ac_cv_prog_AR="$AR" # Let the user override the test.
3318 ac_save_IFS=$IFS; IFS=$ac_path_separator
3320 for ac_dir in $ac_dummy; do
3322 test -z "$ac_dir" && ac_dir=.
3323 $as_executable_p "$ac_dir/$ac_word" || continue
3324 ac_cv_prog_AR="${ac_tool_prefix}ar"
3325 echo "$as_me:3325: found $ac_dir/$ac_word" >&5
3332 if test -n "$AR"; then
3333 echo "$as_me:3333: result: $AR" >&5
3334 echo "${ECHO_T}$AR" >&6
3336 echo "$as_me:3336: result: no" >&5
3337 echo "${ECHO_T}no" >&6
3341 if test -z "$ac_cv_prog_AR"; then
3343 # Extract the first word of "ar", so it can be a program name with args.
3344 set dummy ar; ac_word=$2
3345 echo "$as_me:3345: checking for $ac_word" >&5
3346 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3347 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
3348 echo $ECHO_N "(cached) $ECHO_C" >&6
3350 if test -n "$ac_ct_AR"; then
3351 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
3353 ac_save_IFS=$IFS; IFS=$ac_path_separator
3355 for ac_dir in $ac_dummy; do
3357 test -z "$ac_dir" && ac_dir=.
3358 $as_executable_p "$ac_dir/$ac_word" || continue
3359 ac_cv_prog_ac_ct_AR="ar"
3360 echo "$as_me:3360: found $ac_dir/$ac_word" >&5
3364 test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="ar"
3367 ac_ct_AR=$ac_cv_prog_ac_ct_AR
3368 if test -n "$ac_ct_AR"; then
3369 echo "$as_me:3369: result: $ac_ct_AR" >&5
3370 echo "${ECHO_T}$ac_ct_AR" >&6
3372 echo "$as_me:3372: result: no" >&5
3373 echo "${ECHO_T}no" >&6
3381 if test -n "$ac_tool_prefix"; then
3382 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
3383 set dummy ${ac_tool_prefix}ar; ac_word=$2
3384 echo "$as_me:3384: checking for $ac_word" >&5
3385 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3386 if test "${ac_cv_prog_AR+set}" = set; then
3387 echo $ECHO_N "(cached) $ECHO_C" >&6
3389 if test -n "$AR"; then
3390 ac_cv_prog_AR="$AR" # Let the user override the test.
3392 ac_save_IFS=$IFS; IFS=$ac_path_separator
3394 for ac_dir in $ac_dummy; do
3396 test -z "$ac_dir" && ac_dir=.
3397 $as_executable_p "$ac_dir/$ac_word" || continue
3398 ac_cv_prog_AR="${ac_tool_prefix}ar"
3399 echo "$as_me:3399: found $ac_dir/$ac_word" >&5
3406 if test -n "$AR"; then
3407 echo "$as_me:3407: result: $AR" >&5
3408 echo "${ECHO_T}$AR" >&6
3410 echo "$as_me:3410: result: no" >&5
3411 echo "${ECHO_T}no" >&6
3415 if test -z "$ac_cv_prog_AR"; then
3417 # Extract the first word of "ar", so it can be a program name with args.
3418 set dummy ar; ac_word=$2
3419 echo "$as_me:3419: checking for $ac_word" >&5
3420 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3421 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
3422 echo $ECHO_N "(cached) $ECHO_C" >&6
3424 if test -n "$ac_ct_AR"; then
3425 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
3427 ac_save_IFS=$IFS; IFS=$ac_path_separator
3429 for ac_dir in $ac_dummy; do
3431 test -z "$ac_dir" && ac_dir=.
3432 $as_executable_p "$ac_dir/$ac_word" || continue
3433 ac_cv_prog_ac_ct_AR="ar"
3434 echo "$as_me:3434: found $ac_dir/$ac_word" >&5
3438 test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="ar"
3441 ac_ct_AR=$ac_cv_prog_ac_ct_AR
3442 if test -n "$ac_ct_AR"; then
3443 echo "$as_me:3443: result: $ac_ct_AR" >&5
3444 echo "${ECHO_T}$ac_ct_AR" >&6
3446 echo "$as_me:3446: result: no" >&5
3447 echo "${ECHO_T}no" >&6
3455 echo "$as_me:3455: checking for options to update archives" >&5
3456 echo $ECHO_N "checking for options to update archives... $ECHO_C" >&6
3457 if test "${cf_cv_ar_flags+set}" = set; then
3458 echo $ECHO_N "(cached) $ECHO_C" >&6
3461 cf_cv_ar_flags=unknown
3462 for cf_ar_flags in -curv curv -crv crv -cqv cqv -rv rv
3465 # check if $ARFLAGS already contains this choice
3466 if test "x$ARFLAGS" != "x" ; then
3467 cf_check_ar_flags=`echo "x$ARFLAGS" | sed -e "s/$cf_ar_flags\$//" -e "s/$cf_ar_flags / /"`
3468 if test "x$ARFLAGS" != "$cf_check_ar_flags" ; then
3474 rm -f conftest.$ac_cv_objext
3477 cat >conftest.$ac_ext <<EOF
3478 #line 3478 "configure"
3479 int testdata[3] = { 123, 456, 789 };
3481 if { (eval echo "$as_me:3481: \"$ac_compile\"") >&5
3482 (eval $ac_compile) 2>&5
3484 echo "$as_me:3484: \$? = $ac_status" >&5
3485 (exit $ac_status); } ; then
3486 echo "$AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext" >&5
3487 $AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext 2>&5 1>/dev/null
3488 if test -f conftest.a ; then
3489 cf_cv_ar_flags=$cf_ar_flags
3493 test -n "$verbose" && echo " cannot compile test-program" 1>&6
3495 echo "${as_me:-configure}:3495: testing cannot compile test-program ..." 1>&5
3500 rm -f conftest.a conftest.$ac_ext conftest.$ac_cv_objext
3503 echo "$as_me:3503: result: $cf_cv_ar_flags" >&5
3504 echo "${ECHO_T}$cf_cv_ar_flags" >&6
3506 if test -n "$ARFLAGS" ; then
3507 if test -n "$cf_cv_ar_flags" ; then
3508 ARFLAGS="$ARFLAGS $cf_cv_ar_flags"
3511 ARFLAGS=$cf_cv_ar_flags
3514 echo "$as_me:3514: checking if you have specified an install-prefix" >&5
3515 echo $ECHO_N "checking if you have specified an install-prefix... $ECHO_C" >&6
3517 # Check whether --with-install-prefix or --without-install-prefix was given.
3518 if test "${with_install_prefix+set}" = set; then
3519 withval="$with_install_prefix"
3520 case "$withval" in #(vi
3523 *) DESTDIR="$withval"
3527 echo "$as_me:3527: result: $DESTDIR" >&5
3528 echo "${ECHO_T}$DESTDIR" >&6
3530 ###############################################################################
3532 # If we're cross-compiling, allow the user to override the tools and their
3533 # options. The configure script is oriented toward identifying the host
3534 # compiler, etc., but we need a build compiler to generate parts of the source.
3536 if test "$cross_compiling" = yes ; then
3538 # defaults that we might want to override
3539 : ${BUILD_CFLAGS:=''}
3540 : ${BUILD_CPPFLAGS:=''}
3541 : ${BUILD_LDFLAGS:=''}
3543 : ${BUILD_EXEEXT:='$x'}
3544 : ${BUILD_OBJEXT:='o'}
3546 # Check whether --with-build-cc or --without-build-cc was given.
3547 if test "${with_build_cc+set}" = set; then
3548 withval="$with_build_cc"
3551 for ac_prog in gcc cc cl
3553 # Extract the first word of "$ac_prog", so it can be a program name with args.
3554 set dummy $ac_prog; ac_word=$2
3555 echo "$as_me:3555: checking for $ac_word" >&5
3556 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3557 if test "${ac_cv_prog_BUILD_CC+set}" = set; then
3558 echo $ECHO_N "(cached) $ECHO_C" >&6
3560 if test -n "$BUILD_CC"; then
3561 ac_cv_prog_BUILD_CC="$BUILD_CC" # Let the user override the test.
3563 ac_save_IFS=$IFS; IFS=$ac_path_separator
3565 for ac_dir in $ac_dummy; do
3567 test -z "$ac_dir" && ac_dir=.
3568 $as_executable_p "$ac_dir/$ac_word" || continue
3569 ac_cv_prog_BUILD_CC="$ac_prog"
3570 echo "$as_me:3570: found $ac_dir/$ac_word" >&5
3576 BUILD_CC=$ac_cv_prog_BUILD_CC
3577 if test -n "$BUILD_CC"; then
3578 echo "$as_me:3578: result: $BUILD_CC" >&5
3579 echo "${ECHO_T}$BUILD_CC" >&6
3581 echo "$as_me:3581: result: no" >&5
3582 echo "${ECHO_T}no" >&6
3585 test -n "$BUILD_CC" && break
3589 echo "$as_me:3589: checking for native build C compiler" >&5
3590 echo $ECHO_N "checking for native build C compiler... $ECHO_C" >&6
3591 echo "$as_me:3591: result: $BUILD_CC" >&5
3592 echo "${ECHO_T}$BUILD_CC" >&6
3594 echo "$as_me:3594: checking for native build C preprocessor" >&5
3595 echo $ECHO_N "checking for native build C preprocessor... $ECHO_C" >&6
3597 # Check whether --with-build-cpp or --without-build-cpp was given.
3598 if test "${with_build_cpp+set}" = set; then
3599 withval="$with_build_cpp"
3600 BUILD_CPP="$withval"
3602 BUILD_CPP='${BUILD_CC} -E'
3604 echo "$as_me:3604: result: $BUILD_CPP" >&5
3605 echo "${ECHO_T}$BUILD_CPP" >&6
3607 echo "$as_me:3607: checking for native build C flags" >&5
3608 echo $ECHO_N "checking for native build C flags... $ECHO_C" >&6
3610 # Check whether --with-build-cflags or --without-build-cflags was given.
3611 if test "${with_build_cflags+set}" = set; then
3612 withval="$with_build_cflags"
3613 BUILD_CFLAGS="$withval"
3615 echo "$as_me:3615: result: $BUILD_CFLAGS" >&5
3616 echo "${ECHO_T}$BUILD_CFLAGS" >&6
3618 echo "$as_me:3618: checking for native build C preprocessor-flags" >&5
3619 echo $ECHO_N "checking for native build C preprocessor-flags... $ECHO_C" >&6
3621 # Check whether --with-build-cppflags or --without-build-cppflags was given.
3622 if test "${with_build_cppflags+set}" = set; then
3623 withval="$with_build_cppflags"
3624 BUILD_CPPFLAGS="$withval"
3626 echo "$as_me:3626: result: $BUILD_CPPFLAGS" >&5
3627 echo "${ECHO_T}$BUILD_CPPFLAGS" >&6
3629 echo "$as_me:3629: checking for native build linker-flags" >&5
3630 echo $ECHO_N "checking for native build linker-flags... $ECHO_C" >&6
3632 # Check whether --with-build-ldflags or --without-build-ldflags was given.
3633 if test "${with_build_ldflags+set}" = set; then
3634 withval="$with_build_ldflags"
3635 BUILD_LDFLAGS="$withval"
3637 echo "$as_me:3637: result: $BUILD_LDFLAGS" >&5
3638 echo "${ECHO_T}$BUILD_LDFLAGS" >&6
3640 echo "$as_me:3640: checking for native build linker-libraries" >&5
3641 echo $ECHO_N "checking for native build linker-libraries... $ECHO_C" >&6
3643 # Check whether --with-build-libs or --without-build-libs was given.
3644 if test "${with_build_libs+set}" = set; then
3645 withval="$with_build_libs"
3646 BUILD_LIBS="$withval"
3648 echo "$as_me:3648: result: $BUILD_LIBS" >&5
3649 echo "${ECHO_T}$BUILD_LIBS" >&6
3651 # this assumes we're on Unix.
3655 : ${BUILD_CC:='${CC}'}
3657 if ( test "$BUILD_CC" = "$CC" || test "$BUILD_CC" = '${CC}' ) ; then
3658 { { echo "$as_me:3658: error: Cross-build requires two compilers.
3659 Use --with-build-cc to specify the native compiler." >&5
3660 echo "$as_me: error: Cross-build requires two compilers.
3661 Use --with-build-cc to specify the native compiler." >&2;}
3662 { (exit 1); exit 1; }; }
3666 : ${BUILD_CC:='${CC}'}
3667 : ${BUILD_CPP:='${CPP}'}
3668 : ${BUILD_CFLAGS:='${CFLAGS}'}
3669 : ${BUILD_CPPFLAGS:='${CPPFLAGS}'}
3670 : ${BUILD_LDFLAGS:='${LDFLAGS}'}
3671 : ${BUILD_LIBS:='${LIBS}'}
3672 : ${BUILD_EXEEXT:='$x'}
3673 : ${BUILD_OBJEXT:='o'}
3676 ###############################################################################
3678 ### Options to allow the user to specify the set of libraries which are used.
3679 ### Use "--without-normal --with-shared" to allow the default model to be
3680 ### shared, for example.
3682 echo "$as_me:3682: checking for specified models" >&5
3683 echo $ECHO_N "checking for specified models... $ECHO_C" >&6
3684 test -z "$cf_list_models" && cf_list_models=normal
3685 echo "$as_me:3685: result: $cf_list_models" >&5
3686 echo "${ECHO_T}$cf_list_models" >&6
3688 ### Use the first model as the default, and save its suffix for use in building
3689 ### up test-applications.
3690 echo "$as_me:3690: checking for default model" >&5
3691 echo $ECHO_N "checking for default model... $ECHO_C" >&6
3692 DFT_LWR_MODEL=`echo "$cf_list_models" | $AWK '{print $1}'`
3693 echo "$as_me:3693: result: $DFT_LWR_MODEL" >&5
3694 echo "${ECHO_T}$DFT_LWR_MODEL" >&6
3696 DFT_UPR_MODEL=`echo "$DFT_LWR_MODEL" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
3698 echo "$as_me:3698: checking for specific curses-directory" >&5
3699 echo $ECHO_N "checking for specific curses-directory... $ECHO_C" >&6
3701 # Check whether --with-curses-dir or --without-curses-dir was given.
3702 if test "${with_curses_dir+set}" = set; then
3703 withval="$with_curses_dir"
3704 cf_cv_curses_dir=$withval
3708 echo "$as_me:3708: result: $cf_cv_curses_dir" >&5
3709 echo "${ECHO_T}$cf_cv_curses_dir" >&6
3711 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
3714 if test "x$prefix" != xNONE; then
3715 cf_path_syntax="$prefix"
3717 cf_path_syntax="$ac_default_prefix"
3720 case ".$withval" in #(vi
3721 .\$\(*\)*|.\'*\'*) #(vi
3725 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
3728 eval withval="$withval"
3729 case ".$withval" in #(vi
3731 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
3736 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
3739 { { echo "$as_me:3739: error: expected a pathname, not \"$withval\"" >&5
3740 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
3741 { (exit 1); exit 1; }; }
3745 if test -d "$cf_cv_curses_dir"
3748 if test -n "$cf_cv_curses_dir/include" ; then
3749 for cf_add_incdir in $cf_cv_curses_dir/include
3751 while test $cf_add_incdir != /usr/include
3753 if test -d $cf_add_incdir
3756 if test -n "$CFLAGS$CPPFLAGS" ; then
3757 # a loop is needed to ensure we can add subdirs of existing dirs
3758 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
3759 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
3760 cf_have_incdir=yes; break
3765 if test "$cf_have_incdir" = no ; then
3766 if test "$cf_add_incdir" = /usr/local/include ; then
3767 if test "$GCC" = yes
3769 cf_save_CPPFLAGS=$CPPFLAGS
3770 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
3771 cat >conftest.$ac_ext <<_ACEOF
3772 #line 3772 "configure"
3773 #include "confdefs.h"
3783 rm -f conftest.$ac_objext
3784 if { (eval echo "$as_me:3784: \"$ac_compile\"") >&5
3785 (eval $ac_compile) 2>&5
3787 echo "$as_me:3787: \$? = $ac_status" >&5
3788 (exit $ac_status); } &&
3789 { ac_try='test -s conftest.$ac_objext'
3790 { (eval echo "$as_me:3790: \"$ac_try\"") >&5
3793 echo "$as_me:3793: \$? = $ac_status" >&5
3794 (exit $ac_status); }; }; then
3797 echo "$as_me: failed program was:" >&5
3798 cat conftest.$ac_ext >&5
3801 rm -f conftest.$ac_objext conftest.$ac_ext
3802 CPPFLAGS=$cf_save_CPPFLAGS
3807 if test "$cf_have_incdir" = no ; then
3808 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
3810 echo "${as_me:-configure}:3810: testing adding $cf_add_incdir to include-path ..." 1>&5
3812 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
3814 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
3815 test "$cf_top_incdir" = "$cf_add_incdir" && break
3816 cf_add_incdir="$cf_top_incdir"
3825 if test -n "$cf_cv_curses_dir/lib" ; then
3826 for cf_add_libdir in $cf_cv_curses_dir/lib
3828 if test $cf_add_libdir = /usr/lib ; then
3830 elif test -d $cf_add_libdir
3833 if test -n "$LDFLAGS$LIBS" ; then
3834 # a loop is needed to ensure we can add subdirs of existing dirs
3835 for cf_test_libdir in $LDFLAGS $LIBS ; do
3836 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
3837 cf_have_libdir=yes; break
3841 if test "$cf_have_libdir" = no ; then
3842 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
3844 echo "${as_me:-configure}:3844: testing adding $cf_add_libdir to library-path ..." 1>&5
3846 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
3855 echo "$as_me:3855: checking if you want wide-character code" >&5
3856 echo $ECHO_N "checking if you want wide-character code... $ECHO_C" >&6
3858 # Check whether --enable-widec or --disable-widec was given.
3859 if test "${enable_widec+set}" = set; then
3860 enableval="$enable_widec"
3861 with_widec=$enableval
3865 echo "$as_me:3865: result: $with_widec" >&5
3866 echo "${ECHO_T}$with_widec" >&6
3867 if test "$with_widec" = yes ; then
3869 echo "$as_me:3869: checking for multibyte character support" >&5
3870 echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
3871 if test "${cf_cv_utf8_lib+set}" = set; then
3872 echo $ECHO_N "(cached) $ECHO_C" >&6
3875 cf_save_LIBS="$LIBS"
3876 cat >conftest.$ac_ext <<_ACEOF
3877 #line 3877 "configure"
3878 #include "confdefs.h"
3889 rm -f conftest.$ac_objext conftest$ac_exeext
3890 if { (eval echo "$as_me:3890: \"$ac_link\"") >&5
3891 (eval $ac_link) 2>&5
3893 echo "$as_me:3893: \$? = $ac_status" >&5
3894 (exit $ac_status); } &&
3895 { ac_try='test -s conftest$ac_exeext'
3896 { (eval echo "$as_me:3896: \"$ac_try\"") >&5
3899 echo "$as_me:3899: \$? = $ac_status" >&5
3900 (exit $ac_status); }; }; then
3903 echo "$as_me: failed program was:" >&5
3904 cat conftest.$ac_ext >&5
3906 # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
3907 # will be set on completion of the AC_TRY_LINK below.
3908 cf_cv_header_path_utf8=
3909 cf_cv_library_path_utf8=
3911 echo "${as_me:-configure}:3911: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
3913 cf_save_LIBS="$LIBS"
3915 cat >conftest.$ac_ext <<_ACEOF
3916 #line 3916 "configure"
3917 #include "confdefs.h"
3919 #include <libutf8.h>
3928 rm -f conftest.$ac_objext conftest$ac_exeext
3929 if { (eval echo "$as_me:3929: \"$ac_link\"") >&5
3930 (eval $ac_link) 2>&5
3932 echo "$as_me:3932: \$? = $ac_status" >&5
3933 (exit $ac_status); } &&
3934 { ac_try='test -s conftest$ac_exeext'
3935 { (eval echo "$as_me:3935: \"$ac_try\"") >&5
3938 echo "$as_me:3938: \$? = $ac_status" >&5
3939 (exit $ac_status); }; }; then
3941 cf_cv_find_linkage_utf8=yes
3942 cf_cv_header_path_utf8=/usr/include
3943 cf_cv_library_path_utf8=/usr/lib
3946 echo "$as_me: failed program was:" >&5
3947 cat conftest.$ac_ext >&5
3949 LIBS="-lutf8 $cf_save_LIBS"
3951 cat >conftest.$ac_ext <<_ACEOF
3952 #line 3952 "configure"
3953 #include "confdefs.h"
3955 #include <libutf8.h>
3964 rm -f conftest.$ac_objext conftest$ac_exeext
3965 if { (eval echo "$as_me:3965: \"$ac_link\"") >&5
3966 (eval $ac_link) 2>&5
3968 echo "$as_me:3968: \$? = $ac_status" >&5
3969 (exit $ac_status); } &&
3970 { ac_try='test -s conftest$ac_exeext'
3971 { (eval echo "$as_me:3971: \"$ac_try\"") >&5
3974 echo "$as_me:3974: \$? = $ac_status" >&5
3975 (exit $ac_status); }; }; then
3977 cf_cv_find_linkage_utf8=yes
3978 cf_cv_header_path_utf8=/usr/include
3979 cf_cv_library_path_utf8=/usr/lib
3980 cf_cv_library_file_utf8="-lutf8"
3983 echo "$as_me: failed program was:" >&5
3984 cat conftest.$ac_ext >&5
3986 cf_cv_find_linkage_utf8=no
3987 LIBS="$cf_save_LIBS"
3989 test -n "$verbose" && echo " find linkage for utf8 library" 1>&6
3991 echo "${as_me:-configure}:3991: testing find linkage for utf8 library ..." 1>&5
3993 echo "${as_me:-configure}:3993: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
3995 cf_save_CPPFLAGS="$CPPFLAGS"
3996 cf_test_CPPFLAGS="$CPPFLAGS"
4000 # collect the current set of include-directories from compiler flags
4001 cf_header_path_list=""
4002 if test -n "${CFLAGS}${CPPFLAGS}" ; then
4003 for cf_header_path in $CPPFLAGS $CFLAGS
4005 case $cf_header_path in #(vi
4007 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
4009 test "$cf_header_path" != "NONE" && \
4010 test -d "$cf_header_path" && \
4012 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
4013 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
4014 test -d $cf_header_path/include/utf8 && cf_search="$cf_search $cf_header_path/include/utf8"
4015 test -d $cf_header_path/include/utf8/include && cf_search="$cf_search $cf_header_path/include/utf8/include"
4016 test -d $cf_header_path/utf8/include && cf_search="$cf_search $cf_header_path/utf8/include"
4017 test -d $cf_header_path/utf8/include/utf8 && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
4020 cf_header_path_list="$cf_header_path_list $cf_search"
4026 # add the variations for the package we are looking for
4030 test "/usr" != "$prefix" && \
4032 (test $prefix = NONE || test "/usr" != "$prefix") && {
4033 test -n "$verbose" && echo " ... testing for include-directories under /usr"
4034 test -d /usr/include && cf_search="$cf_search /usr/include"
4035 test -d /usr/include/utf8 && cf_search="$cf_search /usr/include/utf8"
4036 test -d /usr/include/utf8/include && cf_search="$cf_search /usr/include/utf8/include"
4037 test -d /usr/utf8/include && cf_search="$cf_search /usr/utf8/include"
4038 test -d /usr/utf8/include/utf8 && cf_search="$cf_search /usr/utf8/include/utf8"
4041 test "$prefix" != "NONE" && \
4042 test -d "$prefix" && \
4044 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
4045 test -d $prefix/include && cf_search="$cf_search $prefix/include"
4046 test -d $prefix/include/utf8 && cf_search="$cf_search $prefix/include/utf8"
4047 test -d $prefix/include/utf8/include && cf_search="$cf_search $prefix/include/utf8/include"
4048 test -d $prefix/utf8/include && cf_search="$cf_search $prefix/utf8/include"
4049 test -d $prefix/utf8/include/utf8 && cf_search="$cf_search $prefix/utf8/include/utf8"
4052 test "/usr/local" != "$prefix" && \
4053 test -d "/usr/local" && \
4054 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
4055 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
4056 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
4057 test -d /usr/local/include/utf8 && cf_search="$cf_search /usr/local/include/utf8"
4058 test -d /usr/local/include/utf8/include && cf_search="$cf_search /usr/local/include/utf8/include"
4059 test -d /usr/local/utf8/include && cf_search="$cf_search /usr/local/utf8/include"
4060 test -d /usr/local/utf8/include/utf8 && cf_search="$cf_search /usr/local/utf8/include/utf8"
4063 test "/opt" != "$prefix" && \
4065 (test $prefix = NONE || test "/opt" != "$prefix") && {
4066 test -n "$verbose" && echo " ... testing for include-directories under /opt"
4067 test -d /opt/include && cf_search="$cf_search /opt/include"
4068 test -d /opt/include/utf8 && cf_search="$cf_search /opt/include/utf8"
4069 test -d /opt/include/utf8/include && cf_search="$cf_search /opt/include/utf8/include"
4070 test -d /opt/utf8/include && cf_search="$cf_search /opt/utf8/include"
4071 test -d /opt/utf8/include/utf8 && cf_search="$cf_search /opt/utf8/include/utf8"
4074 test "$HOME" != "$prefix" && \
4075 test -d "$HOME" && \
4076 (test $prefix = NONE || test "$HOME" != "$prefix") && {
4077 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
4078 test -d $HOME/include && cf_search="$cf_search $HOME/include"
4079 test -d $HOME/include/utf8 && cf_search="$cf_search $HOME/include/utf8"
4080 test -d $HOME/include/utf8/include && cf_search="$cf_search $HOME/include/utf8/include"
4081 test -d $HOME/utf8/include && cf_search="$cf_search $HOME/utf8/include"
4082 test -d $HOME/utf8/include/utf8 && cf_search="$cf_search $HOME/utf8/include/utf8"
4085 test "$includedir" != NONE && \
4086 test "$includedir" != "/usr/include" && \
4087 test -d "$includedir" && {
4088 test -d $includedir && cf_search="$cf_search $includedir"
4089 test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8"
4092 test "$oldincludedir" != NONE && \
4093 test "$oldincludedir" != "/usr/include" && \
4094 test -d "$oldincludedir" && {
4095 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
4096 test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8"
4099 cf_search="$cf_search $cf_header_path_list"
4101 for cf_cv_header_path_utf8 in $cf_search
4103 if test -d $cf_cv_header_path_utf8 ; then
4104 test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6
4106 echo "${as_me:-configure}:4106: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
4108 CPPFLAGS="$cf_save_CPPFLAGS -I$cf_cv_header_path_utf8"
4109 cat >conftest.$ac_ext <<_ACEOF
4110 #line 4110 "configure"
4111 #include "confdefs.h"
4113 #include <libutf8.h>
4122 rm -f conftest.$ac_objext
4123 if { (eval echo "$as_me:4123: \"$ac_compile\"") >&5
4124 (eval $ac_compile) 2>&5
4126 echo "$as_me:4126: \$? = $ac_status" >&5
4127 (exit $ac_status); } &&
4128 { ac_try='test -s conftest.$ac_objext'
4129 { (eval echo "$as_me:4129: \"$ac_try\"") >&5
4132 echo "$as_me:4132: \$? = $ac_status" >&5
4133 (exit $ac_status); }; }; then
4135 test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
4137 echo "${as_me:-configure}:4137: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
4139 cf_cv_find_linkage_utf8=maybe
4140 cf_test_CPPFLAGS="$CPPFLAGS"
4143 echo "$as_me: failed program was:" >&5
4144 cat conftest.$ac_ext >&5
4146 CPPFLAGS="$cf_save_CPPFLAGS"
4149 rm -f conftest.$ac_objext conftest.$ac_ext
4153 if test "$cf_cv_find_linkage_utf8" = maybe ; then
4155 echo "${as_me:-configure}:4155: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
4157 cf_save_LIBS="$LIBS"
4158 cf_save_LDFLAGS="$LDFLAGS"
4160 if test "$cf_cv_find_linkage_utf8" != yes ; then
4163 cf_library_path_list=""
4164 if test -n "${LDFLAGS}${LIBS}" ; then
4165 for cf_library_path in $LDFLAGS $LIBS
4167 case $cf_library_path in #(vi
4169 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
4171 test "$cf_library_path" != "NONE" && \
4172 test -d "$cf_library_path" && \
4174 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
4175 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
4176 test -d $cf_library_path/lib/utf8 && cf_search="$cf_search $cf_library_path/lib/utf8"
4177 test -d $cf_library_path/lib/utf8/lib && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
4178 test -d $cf_library_path/utf8/lib && cf_search="$cf_search $cf_library_path/utf8/lib"
4179 test -d $cf_library_path/utf8/lib/utf8 && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
4182 cf_library_path_list="$cf_library_path_list $cf_search"
4190 test "/usr" != "$prefix" && \
4192 (test $prefix = NONE || test "/usr" != "$prefix") && {
4193 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
4194 test -d /usr/lib && cf_search="$cf_search /usr/lib"
4195 test -d /usr/lib/utf8 && cf_search="$cf_search /usr/lib/utf8"
4196 test -d /usr/lib/utf8/lib && cf_search="$cf_search /usr/lib/utf8/lib"
4197 test -d /usr/utf8/lib && cf_search="$cf_search /usr/utf8/lib"
4198 test -d /usr/utf8/lib/utf8 && cf_search="$cf_search /usr/utf8/lib/utf8"
4201 test "$prefix" != "NONE" && \
4202 test -d "$prefix" && \
4204 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
4205 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
4206 test -d $prefix/lib/utf8 && cf_search="$cf_search $prefix/lib/utf8"
4207 test -d $prefix/lib/utf8/lib && cf_search="$cf_search $prefix/lib/utf8/lib"
4208 test -d $prefix/utf8/lib && cf_search="$cf_search $prefix/utf8/lib"
4209 test -d $prefix/utf8/lib/utf8 && cf_search="$cf_search $prefix/utf8/lib/utf8"
4212 test "/usr/local" != "$prefix" && \
4213 test -d "/usr/local" && \
4214 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
4215 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
4216 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
4217 test -d /usr/local/lib/utf8 && cf_search="$cf_search /usr/local/lib/utf8"
4218 test -d /usr/local/lib/utf8/lib && cf_search="$cf_search /usr/local/lib/utf8/lib"
4219 test -d /usr/local/utf8/lib && cf_search="$cf_search /usr/local/utf8/lib"
4220 test -d /usr/local/utf8/lib/utf8 && cf_search="$cf_search /usr/local/utf8/lib/utf8"
4223 test "/opt" != "$prefix" && \
4225 (test $prefix = NONE || test "/opt" != "$prefix") && {
4226 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
4227 test -d /opt/lib && cf_search="$cf_search /opt/lib"
4228 test -d /opt/lib/utf8 && cf_search="$cf_search /opt/lib/utf8"
4229 test -d /opt/lib/utf8/lib && cf_search="$cf_search /opt/lib/utf8/lib"
4230 test -d /opt/utf8/lib && cf_search="$cf_search /opt/utf8/lib"
4231 test -d /opt/utf8/lib/utf8 && cf_search="$cf_search /opt/utf8/lib/utf8"
4234 test "$HOME" != "$prefix" && \
4235 test -d "$HOME" && \
4236 (test $prefix = NONE || test "$HOME" != "$prefix") && {
4237 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
4238 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
4239 test -d $HOME/lib/utf8 && cf_search="$cf_search $HOME/lib/utf8"
4240 test -d $HOME/lib/utf8/lib && cf_search="$cf_search $HOME/lib/utf8/lib"
4241 test -d $HOME/utf8/lib && cf_search="$cf_search $HOME/utf8/lib"
4242 test -d $HOME/utf8/lib/utf8 && cf_search="$cf_search $HOME/utf8/lib/utf8"
4245 cf_search="$cf_library_path_list $cf_search"
4247 for cf_cv_library_path_utf8 in $cf_search
4249 if test -d $cf_cv_library_path_utf8 ; then
4250 test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6
4252 echo "${as_me:-configure}:4252: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
4254 CPPFLAGS="$cf_test_CPPFLAGS"
4255 LIBS="-lutf8 $cf_save_LIBS"
4256 LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
4257 cat >conftest.$ac_ext <<_ACEOF
4258 #line 4258 "configure"
4259 #include "confdefs.h"
4261 #include <libutf8.h>
4270 rm -f conftest.$ac_objext conftest$ac_exeext
4271 if { (eval echo "$as_me:4271: \"$ac_link\"") >&5
4272 (eval $ac_link) 2>&5
4274 echo "$as_me:4274: \$? = $ac_status" >&5
4275 (exit $ac_status); } &&
4276 { ac_try='test -s conftest$ac_exeext'
4277 { (eval echo "$as_me:4277: \"$ac_try\"") >&5
4280 echo "$as_me:4280: \$? = $ac_status" >&5
4281 (exit $ac_status); }; }; then
4283 test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
4285 echo "${as_me:-configure}:4285: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
4287 cf_cv_find_linkage_utf8=yes
4288 cf_cv_library_file_utf8="-lutf8"
4291 echo "$as_me: failed program was:" >&5
4292 cat conftest.$ac_ext >&5
4294 CPPFLAGS="$cf_save_CPPFLAGS"
4295 LIBS="$cf_save_LIBS"
4296 LDFLAGS="$cf_save_LDFLAGS"
4299 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4302 CPPFLAGS="$cf_save_CPPFLAGS"
4303 LDFLAGS="$cf_save_LDFLAGS"
4307 cf_cv_find_linkage_utf8=no
4311 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4314 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4316 LIBS="$cf_save_LIBS"
4318 if test "$cf_cv_find_linkage_utf8" = yes ; then
4319 cf_cv_utf8_lib=add-on
4325 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4327 echo "$as_me:4327: result: $cf_cv_utf8_lib" >&5
4328 echo "${ECHO_T}$cf_cv_utf8_lib" >&6
4330 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
4332 if test "$cf_cv_utf8_lib" = "add-on" ; then
4333 cat >>confdefs.h <<\EOF
4334 #define HAVE_LIBUTF8_H 1
4337 if test -n "$cf_cv_header_path_utf8" ; then
4338 for cf_add_incdir in $cf_cv_header_path_utf8
4340 while test $cf_add_incdir != /usr/include
4342 if test -d $cf_add_incdir
4345 if test -n "$CFLAGS$CPPFLAGS" ; then
4346 # a loop is needed to ensure we can add subdirs of existing dirs
4347 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
4348 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
4349 cf_have_incdir=yes; break
4354 if test "$cf_have_incdir" = no ; then
4355 if test "$cf_add_incdir" = /usr/local/include ; then
4356 if test "$GCC" = yes
4358 cf_save_CPPFLAGS=$CPPFLAGS
4359 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4360 cat >conftest.$ac_ext <<_ACEOF
4361 #line 4361 "configure"
4362 #include "confdefs.h"
4372 rm -f conftest.$ac_objext
4373 if { (eval echo "$as_me:4373: \"$ac_compile\"") >&5
4374 (eval $ac_compile) 2>&5
4376 echo "$as_me:4376: \$? = $ac_status" >&5
4377 (exit $ac_status); } &&
4378 { ac_try='test -s conftest.$ac_objext'
4379 { (eval echo "$as_me:4379: \"$ac_try\"") >&5
4382 echo "$as_me:4382: \$? = $ac_status" >&5
4383 (exit $ac_status); }; }; then
4386 echo "$as_me: failed program was:" >&5
4387 cat conftest.$ac_ext >&5
4390 rm -f conftest.$ac_objext conftest.$ac_ext
4391 CPPFLAGS=$cf_save_CPPFLAGS
4396 if test "$cf_have_incdir" = no ; then
4397 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
4399 echo "${as_me:-configure}:4399: testing adding $cf_add_incdir to include-path ..." 1>&5
4401 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4403 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
4404 test "$cf_top_incdir" = "$cf_add_incdir" && break
4405 cf_add_incdir="$cf_top_incdir"
4414 if test -n "$cf_cv_library_path_utf8" ; then
4415 for cf_add_libdir in $cf_cv_library_path_utf8
4417 if test $cf_add_libdir = /usr/lib ; then
4419 elif test -d $cf_add_libdir
4422 if test -n "$LDFLAGS$LIBS" ; then
4423 # a loop is needed to ensure we can add subdirs of existing dirs
4424 for cf_test_libdir in $LDFLAGS $LIBS ; do
4425 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
4426 cf_have_libdir=yes; break
4430 if test "$cf_have_libdir" = no ; then
4431 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
4433 echo "${as_me:-configure}:4433: testing adding $cf_add_libdir to library-path ..." 1>&5
4435 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
4441 LIBS="$cf_cv_library_file_utf8 $LIBS"
4444 cf_ncuconfig_root=ncursesw
4446 echo "Looking for ${cf_ncuconfig_root}-config"
4447 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
4449 # Extract the first word of "$ac_prog", so it can be a program name with args.
4450 set dummy $ac_prog; ac_word=$2
4451 echo "$as_me:4451: checking for $ac_word" >&5
4452 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4453 if test "${ac_cv_path_NCURSES_CONFIG+set}" = set; then
4454 echo $ECHO_N "(cached) $ECHO_C" >&6
4456 case $NCURSES_CONFIG in
4458 ac_cv_path_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test with a path.
4461 ac_save_IFS=$IFS; IFS=$ac_path_separator
4463 for ac_dir in $ac_dummy; do
4465 test -z "$ac_dir" && ac_dir=.
4466 if $as_executable_p "$ac_dir/$ac_word"; then
4467 ac_cv_path_NCURSES_CONFIG="$ac_dir/$ac_word"
4468 echo "$as_me:4468: found $ac_dir/$ac_word" >&5
4476 NCURSES_CONFIG=$ac_cv_path_NCURSES_CONFIG
4478 if test -n "$NCURSES_CONFIG"; then
4479 echo "$as_me:4479: result: $NCURSES_CONFIG" >&5
4480 echo "${ECHO_T}$NCURSES_CONFIG" >&6
4482 echo "$as_me:4482: result: no" >&5
4483 echo "${ECHO_T}no" >&6
4486 test -n "$NCURSES_CONFIG" && break
4488 test -n "$NCURSES_CONFIG" || NCURSES_CONFIG="none"
4490 if test "$NCURSES_CONFIG" != none ; then
4492 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
4493 LIBS="`$NCURSES_CONFIG --libs` $LIBS"
4495 # even with config script, some packages use no-override for curses.h
4497 echo "$as_me:4497: checking if we have identified curses headers" >&5
4498 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
4499 if test "${cf_cv_ncurses_header+set}" = set; then
4500 echo $ECHO_N "(cached) $ECHO_C" >&6
4503 cf_cv_ncurses_header=none
4506 ncursesw/ncurses.h \
4510 cat >conftest.$ac_ext <<_ACEOF
4511 #line 4511 "configure"
4512 #include "confdefs.h"
4513 #include <${cf_header}>
4517 initscr(); tgoto("?", 0,0)
4522 rm -f conftest.$ac_objext
4523 if { (eval echo "$as_me:4523: \"$ac_compile\"") >&5
4524 (eval $ac_compile) 2>&5
4526 echo "$as_me:4526: \$? = $ac_status" >&5
4527 (exit $ac_status); } &&
4528 { ac_try='test -s conftest.$ac_objext'
4529 { (eval echo "$as_me:4529: \"$ac_try\"") >&5
4532 echo "$as_me:4532: \$? = $ac_status" >&5
4533 (exit $ac_status); }; }; then
4534 cf_cv_ncurses_header=$cf_header; break
4536 echo "$as_me: failed program was:" >&5
4537 cat conftest.$ac_ext >&5
4539 rm -f conftest.$ac_objext conftest.$ac_ext
4543 echo "$as_me:4543: result: $cf_cv_ncurses_header" >&5
4544 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
4546 if test "$cf_cv_ncurses_header" = none ; then
4547 { { echo "$as_me:4547: error: No curses header-files found" >&5
4548 echo "$as_me: error: No curses header-files found" >&2;}
4549 { (exit 1); exit 1; }; }
4552 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
4554 for ac_header in $cf_cv_ncurses_header
4556 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4557 echo "$as_me:4557: checking for $ac_header" >&5
4558 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4559 if eval "test \"\${$as_ac_Header+set}\" = set"; then
4560 echo $ECHO_N "(cached) $ECHO_C" >&6
4562 cat >conftest.$ac_ext <<_ACEOF
4563 #line 4563 "configure"
4564 #include "confdefs.h"
4565 #include <$ac_header>
4567 if { (eval echo "$as_me:4567: \"$ac_cpp conftest.$ac_ext\"") >&5
4568 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4570 egrep -v '^ *\+' conftest.er1 >conftest.err
4572 cat conftest.err >&5
4573 echo "$as_me:4573: \$? = $ac_status" >&5
4574 (exit $ac_status); } >/dev/null; then
4575 if test -s conftest.err; then
4576 ac_cpp_err=$ac_c_preproc_warn_flag
4583 if test -z "$ac_cpp_err"; then
4584 eval "$as_ac_Header=yes"
4586 echo "$as_me: failed program was:" >&5
4587 cat conftest.$ac_ext >&5
4588 eval "$as_ac_Header=no"
4590 rm -f conftest.err conftest.$ac_ext
4592 echo "$as_me:4592: result: `eval echo '${'$as_ac_Header'}'`" >&5
4593 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4594 if test `eval echo '${'$as_ac_Header'}'` = yes; then
4595 cat >>confdefs.h <<EOF
4596 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4602 cat >>confdefs.h <<\EOF
4606 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
4608 cat >>confdefs.h <<EOF
4609 #define $cf_nculib_ROOT 1
4612 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
4616 cf_ncuhdr_root=ncursesw
4618 test -n "$cf_cv_curses_dir" && \
4619 test "$cf_cv_curses_dir" != "no" && { \
4621 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
4622 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
4624 while test $cf_add_incdir != /usr/include
4626 if test -d $cf_add_incdir
4629 if test -n "$CFLAGS$CPPFLAGS" ; then
4630 # a loop is needed to ensure we can add subdirs of existing dirs
4631 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
4632 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
4633 cf_have_incdir=yes; break
4638 if test "$cf_have_incdir" = no ; then
4639 if test "$cf_add_incdir" = /usr/local/include ; then
4640 if test "$GCC" = yes
4642 cf_save_CPPFLAGS=$CPPFLAGS
4643 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4644 cat >conftest.$ac_ext <<_ACEOF
4645 #line 4645 "configure"
4646 #include "confdefs.h"
4656 rm -f conftest.$ac_objext
4657 if { (eval echo "$as_me:4657: \"$ac_compile\"") >&5
4658 (eval $ac_compile) 2>&5
4660 echo "$as_me:4660: \$? = $ac_status" >&5
4661 (exit $ac_status); } &&
4662 { ac_try='test -s conftest.$ac_objext'
4663 { (eval echo "$as_me:4663: \"$ac_try\"") >&5
4666 echo "$as_me:4666: \$? = $ac_status" >&5
4667 (exit $ac_status); }; }; then
4670 echo "$as_me: failed program was:" >&5
4671 cat conftest.$ac_ext >&5
4674 rm -f conftest.$ac_objext conftest.$ac_ext
4675 CPPFLAGS=$cf_save_CPPFLAGS
4680 if test "$cf_have_incdir" = no ; then
4681 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
4683 echo "${as_me:-configure}:4683: testing adding $cf_add_incdir to include-path ..." 1>&5
4685 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4687 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
4688 test "$cf_top_incdir" = "$cf_add_incdir" && break
4689 cf_add_incdir="$cf_top_incdir"
4700 echo "$as_me:4700: checking for $cf_ncuhdr_root header in include-path" >&5
4701 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
4702 if test "${cf_cv_ncurses_h+set}" = set; then
4703 echo $ECHO_N "(cached) $ECHO_C" >&6
4706 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
4707 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
4708 for cf_header in $cf_header_list
4711 cat >conftest.$ac_ext <<_ACEOF
4712 #line 4712 "configure"
4713 #include "confdefs.h"
4715 #define _XOPEN_SOURCE_EXTENDED
4716 #undef HAVE_LIBUTF8_H /* in case we used CF_UTF8_LIB */
4717 #define HAVE_LIBUTF8_H /* to force ncurses' header file to use cchar_t */
4719 #include <$cf_header>
4724 #ifdef NCURSES_VERSION
4730 printf("%s\n", NCURSES_VERSION);
4743 rm -f conftest.$ac_objext
4744 if { (eval echo "$as_me:4744: \"$ac_compile\"") >&5
4745 (eval $ac_compile) 2>&5
4747 echo "$as_me:4747: \$? = $ac_status" >&5
4748 (exit $ac_status); } &&
4749 { ac_try='test -s conftest.$ac_objext'
4750 { (eval echo "$as_me:4750: \"$ac_try\"") >&5
4753 echo "$as_me:4753: \$? = $ac_status" >&5
4754 (exit $ac_status); }; }; then
4755 cf_cv_ncurses_h=$cf_header
4758 echo "$as_me: failed program was:" >&5
4759 cat conftest.$ac_ext >&5
4762 rm -f conftest.$ac_objext conftest.$ac_ext
4764 test "$cf_cv_ncurses_h" != no && break
4768 echo "$as_me:4768: result: $cf_cv_ncurses_h" >&5
4769 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
4771 if test "$cf_cv_ncurses_h" != no ; then
4772 cf_cv_ncurses_header=$cf_cv_ncurses_h
4775 echo "$as_me:4775: checking for $cf_ncuhdr_root include-path" >&5
4776 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
4777 if test "${cf_cv_ncurses_h2+set}" = set; then
4778 echo $ECHO_N "(cached) $ECHO_C" >&6
4781 test -n "$verbose" && echo
4785 # collect the current set of include-directories from compiler flags
4786 cf_header_path_list=""
4787 if test -n "${CFLAGS}${CPPFLAGS}" ; then
4788 for cf_header_path in $CPPFLAGS $CFLAGS
4790 case $cf_header_path in #(vi
4792 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
4794 test "$cf_header_path" != "NONE" && \
4795 test -d "$cf_header_path" && \
4797 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
4798 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
4799 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
4800 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
4801 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
4802 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"
4805 cf_header_path_list="$cf_header_path_list $cf_search"
4811 # add the variations for the package we are looking for
4815 test "/usr" != "$prefix" && \
4817 (test $prefix = NONE || test "/usr" != "$prefix") && {
4818 test -n "$verbose" && echo " ... testing for include-directories under /usr"
4819 test -d /usr/include && cf_search="$cf_search /usr/include"
4820 test -d /usr/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/include/$cf_ncuhdr_root"
4821 test -d /usr/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/include/$cf_ncuhdr_root/include"
4822 test -d /usr/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/$cf_ncuhdr_root/include"
4823 test -d /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
4826 test "$prefix" != "NONE" && \
4827 test -d "$prefix" && \
4829 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
4830 test -d $prefix/include && cf_search="$cf_search $prefix/include"
4831 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
4832 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
4833 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
4834 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
4837 test "/usr/local" != "$prefix" && \
4838 test -d "/usr/local" && \
4839 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
4840 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
4841 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
4842 test -d /usr/local/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root"
4843 test -d /usr/local/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root/include"
4844 test -d /usr/local/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include"
4845 test -d /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
4848 test "/opt" != "$prefix" && \
4850 (test $prefix = NONE || test "/opt" != "$prefix") && {
4851 test -n "$verbose" && echo " ... testing for include-directories under /opt"
4852 test -d /opt/include && cf_search="$cf_search /opt/include"
4853 test -d /opt/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/include/$cf_ncuhdr_root"
4854 test -d /opt/include/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/include/$cf_ncuhdr_root/include"
4855 test -d /opt/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/$cf_ncuhdr_root/include"
4856 test -d /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
4859 test "$HOME" != "$prefix" && \
4860 test -d "$HOME" && \
4861 (test $prefix = NONE || test "$HOME" != "$prefix") && {
4862 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
4863 test -d $HOME/include && cf_search="$cf_search $HOME/include"
4864 test -d $HOME/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root"
4865 test -d $HOME/include/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root/include"
4866 test -d $HOME/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include"
4867 test -d $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
4870 test "$includedir" != NONE && \
4871 test "$includedir" != "/usr/include" && \
4872 test -d "$includedir" && {
4873 test -d $includedir && cf_search="$cf_search $includedir"
4874 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
4877 test "$oldincludedir" != NONE && \
4878 test "$oldincludedir" != "/usr/include" && \
4879 test -d "$oldincludedir" && {
4880 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
4881 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
4884 cf_search="$cf_search $cf_header_path_list"
4886 test -n "$verbose" && echo search path $cf_search
4887 cf_save2_CPPFLAGS="$CPPFLAGS"
4888 for cf_incdir in $cf_search
4891 if test -n "$cf_incdir" ; then
4892 for cf_add_incdir in $cf_incdir
4894 while test $cf_add_incdir != /usr/include
4896 if test -d $cf_add_incdir
4899 if test -n "$CFLAGS$CPPFLAGS" ; then
4900 # a loop is needed to ensure we can add subdirs of existing dirs
4901 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
4902 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
4903 cf_have_incdir=yes; break
4908 if test "$cf_have_incdir" = no ; then
4909 if test "$cf_add_incdir" = /usr/local/include ; then
4910 if test "$GCC" = yes
4912 cf_save_CPPFLAGS=$CPPFLAGS
4913 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4914 cat >conftest.$ac_ext <<_ACEOF
4915 #line 4915 "configure"
4916 #include "confdefs.h"
4926 rm -f conftest.$ac_objext
4927 if { (eval echo "$as_me:4927: \"$ac_compile\"") >&5
4928 (eval $ac_compile) 2>&5
4930 echo "$as_me:4930: \$? = $ac_status" >&5
4931 (exit $ac_status); } &&
4932 { ac_try='test -s conftest.$ac_objext'
4933 { (eval echo "$as_me:4933: \"$ac_try\"") >&5
4936 echo "$as_me:4936: \$? = $ac_status" >&5
4937 (exit $ac_status); }; }; then
4940 echo "$as_me: failed program was:" >&5
4941 cat conftest.$ac_ext >&5
4944 rm -f conftest.$ac_objext conftest.$ac_ext
4945 CPPFLAGS=$cf_save_CPPFLAGS
4950 if test "$cf_have_incdir" = no ; then
4951 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
4953 echo "${as_me:-configure}:4953: testing adding $cf_add_incdir to include-path ..." 1>&5
4955 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4957 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
4958 test "$cf_top_incdir" = "$cf_add_incdir" && break
4959 cf_add_incdir="$cf_top_incdir"
4973 cat >conftest.$ac_ext <<_ACEOF
4974 #line 4974 "configure"
4975 #include "confdefs.h"
4977 #include <$cf_header>
4982 #ifdef NCURSES_VERSION
4984 printf("%s\n", NCURSES_VERSION);
4997 rm -f conftest.$ac_objext
4998 if { (eval echo "$as_me:4998: \"$ac_compile\"") >&5
4999 (eval $ac_compile) 2>&5
5001 echo "$as_me:5001: \$? = $ac_status" >&5
5002 (exit $ac_status); } &&
5003 { ac_try='test -s conftest.$ac_objext'
5004 { (eval echo "$as_me:5004: \"$ac_try\"") >&5
5007 echo "$as_me:5007: \$? = $ac_status" >&5
5008 (exit $ac_status); }; }; then
5009 cf_cv_ncurses_h2=$cf_header
5012 echo "$as_me: failed program was:" >&5
5013 cat conftest.$ac_ext >&5
5016 rm -f conftest.$ac_objext conftest.$ac_ext
5018 if test "$cf_cv_ncurses_h2" != no ; then
5019 cf_cv_ncurses_h2=$cf_incdir/$cf_header
5020 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
5023 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
5025 CPPFLAGS="$cf_save2_CPPFLAGS"
5026 test "$cf_cv_ncurses_h2" != no && break
5028 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:5028: error: not found" >&5
5029 echo "$as_me: error: not found" >&2;}
5030 { (exit 1); exit 1; }; }
5033 echo "$as_me:5033: result: $cf_cv_ncurses_h2" >&5
5034 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
5036 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
5037 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
5038 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
5039 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
5042 if test -n "$cf_1st_incdir" ; then
5043 for cf_add_incdir in $cf_1st_incdir
5045 while test $cf_add_incdir != /usr/include
5047 if test -d $cf_add_incdir
5050 if test -n "$CFLAGS$CPPFLAGS" ; then
5051 # a loop is needed to ensure we can add subdirs of existing dirs
5052 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5053 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5054 cf_have_incdir=yes; break
5059 if test "$cf_have_incdir" = no ; then
5060 if test "$cf_add_incdir" = /usr/local/include ; then
5061 if test "$GCC" = yes
5063 cf_save_CPPFLAGS=$CPPFLAGS
5064 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5065 cat >conftest.$ac_ext <<_ACEOF
5066 #line 5066 "configure"
5067 #include "confdefs.h"
5077 rm -f conftest.$ac_objext
5078 if { (eval echo "$as_me:5078: \"$ac_compile\"") >&5
5079 (eval $ac_compile) 2>&5
5081 echo "$as_me:5081: \$? = $ac_status" >&5
5082 (exit $ac_status); } &&
5083 { ac_try='test -s conftest.$ac_objext'
5084 { (eval echo "$as_me:5084: \"$ac_try\"") >&5
5087 echo "$as_me:5087: \$? = $ac_status" >&5
5088 (exit $ac_status); }; }; then
5091 echo "$as_me: failed program was:" >&5
5092 cat conftest.$ac_ext >&5
5095 rm -f conftest.$ac_objext conftest.$ac_ext
5096 CPPFLAGS=$cf_save_CPPFLAGS
5101 if test "$cf_have_incdir" = no ; then
5102 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5104 echo "${as_me:-configure}:5104: testing adding $cf_add_incdir to include-path ..." 1>&5
5106 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5108 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
5109 test "$cf_top_incdir" = "$cf_add_incdir" && break
5110 cf_add_incdir="$cf_top_incdir"
5121 # Set definitions to allow ifdef'ing for ncurses.h
5123 case $cf_cv_ncurses_header in # (vi
5125 cat >>confdefs.h <<\EOF
5126 #define HAVE_NCURSES_H 1
5132 case $cf_cv_ncurses_header in # (vi
5133 ncurses/curses.h|ncurses/ncurses.h)
5134 cat >>confdefs.h <<\EOF
5135 #define HAVE_NCURSES_NCURSES_H 1
5139 ncursesw/curses.h|ncursesw/ncurses.h)
5140 cat >>confdefs.h <<\EOF
5141 #define HAVE_NCURSESW_NCURSES_H 1
5147 echo "$as_me:5147: checking for terminfo header" >&5
5148 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
5149 if test "${cf_cv_term_header+set}" = set; then
5150 echo $ECHO_N "(cached) $ECHO_C" >&6
5153 case ${cf_cv_ncurses_header} in #(vi
5154 */ncurses.h|*/ncursesw.h) #(vi
5155 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
5158 cf_term_header=term.h
5162 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
5164 cat >conftest.$ac_ext <<_ACEOF
5165 #line 5165 "configure"
5166 #include "confdefs.h"
5168 #include <${cf_cv_ncurses_header:-curses.h}>
5174 int x = auto_left_margin
5179 rm -f conftest.$ac_objext
5180 if { (eval echo "$as_me:5180: \"$ac_compile\"") >&5
5181 (eval $ac_compile) 2>&5
5183 echo "$as_me:5183: \$? = $ac_status" >&5
5184 (exit $ac_status); } &&
5185 { ac_try='test -s conftest.$ac_objext'
5186 { (eval echo "$as_me:5186: \"$ac_try\"") >&5
5189 echo "$as_me:5189: \$? = $ac_status" >&5
5190 (exit $ac_status); }; }; then
5192 cf_cv_term_header="$cf_test"
5194 echo "$as_me: failed program was:" >&5
5195 cat conftest.$ac_ext >&5
5197 cf_cv_term_header=unknown
5200 rm -f conftest.$ac_objext conftest.$ac_ext
5201 test "$cf_cv_term_header" != unknown && break
5205 echo "$as_me:5205: result: $cf_cv_term_header" >&5
5206 echo "${ECHO_T}$cf_cv_term_header" >&6
5208 # Set definitions to allow ifdef'ing to accommodate subdirectories
5210 case $cf_cv_term_header in # (vi
5212 cat >>confdefs.h <<\EOF
5213 #define HAVE_TERM_H 1
5219 case $cf_cv_term_header in # (vi
5220 ncurses/term.h) #(vi
5221 cat >>confdefs.h <<\EOF
5222 #define HAVE_NCURSES_TERM_H 1
5227 cat >>confdefs.h <<\EOF
5228 #define HAVE_NCURSESW_TERM_H 1
5234 # some applications need this, but should check for NCURSES_VERSION
5235 cat >>confdefs.h <<\EOF
5239 echo "$as_me:5239: checking for ncurses version" >&5
5240 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
5241 if test "${cf_cv_ncurses_version+set}" = set; then
5242 echo $ECHO_N "(cached) $ECHO_C" >&6
5245 cf_cv_ncurses_version=no
5248 if test "$cross_compiling" = yes; then
5250 # This will not work if the preprocessor splits the line after the
5251 # Autoconf token. The 'unproto' program does that.
5252 cat > conftest.$ac_ext <<EOF
5253 #include <${cf_cv_ncurses_header:-curses.h}>
5255 #ifdef NCURSES_VERSION
5256 Autoconf NCURSES_VERSION
5264 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
5265 { (eval echo "$as_me:5265: \"$cf_try\"") >&5
5268 echo "$as_me:5268: \$? = $ac_status" >&5
5269 (exit $ac_status); }
5270 if test -f conftest.out ; then
5271 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
5272 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
5277 cat >conftest.$ac_ext <<_ACEOF
5278 #line 5278 "configure"
5279 #include "confdefs.h"
5281 #include <${cf_cv_ncurses_header:-curses.h}>
5285 FILE *fp = fopen("$cf_tempfile", "w");
5286 #ifdef NCURSES_VERSION
5287 # ifdef NCURSES_VERSION_PATCH
5288 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
5290 fprintf(fp, "%s\n", NCURSES_VERSION);
5294 fprintf(fp, "old\n");
5299 ${cf_cv_main_return:-return}(0);
5302 rm -f conftest$ac_exeext
5303 if { (eval echo "$as_me:5303: \"$ac_link\"") >&5
5304 (eval $ac_link) 2>&5
5306 echo "$as_me:5306: \$? = $ac_status" >&5
5307 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5308 { (eval echo "$as_me:5308: \"$ac_try\"") >&5
5311 echo "$as_me:5311: \$? = $ac_status" >&5
5312 (exit $ac_status); }; }; then
5314 cf_cv_ncurses_version=`cat $cf_tempfile`
5316 echo "$as_me: program exited with status $ac_status" >&5
5317 echo "$as_me: failed program was:" >&5
5318 cat conftest.$ac_ext >&5
5320 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5325 echo "$as_me:5325: result: $cf_cv_ncurses_version" >&5
5326 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
5327 test "$cf_cv_ncurses_version" = no || cat >>confdefs.h <<\EOF
5331 cf_nculib_root=ncursesw
5332 # This works, except for the special case where we find gpm, but
5333 # ncurses is in a nonstandard location via $LIBS, and we really want
5336 cf_ncurses_SAVE="$LIBS"
5337 echo "$as_me:5337: checking for Gpm_Open in -lgpm" >&5
5338 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
5339 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
5340 echo $ECHO_N "(cached) $ECHO_C" >&6
5342 ac_check_lib_save_LIBS=$LIBS
5344 cat >conftest.$ac_ext <<_ACEOF
5345 #line 5345 "configure"
5346 #include "confdefs.h"
5348 /* Override any gcc2 internal prototype to avoid an error. */
5352 /* We use char because int might match the return type of a gcc2
5353 builtin and then its argument prototype would still apply. */
5363 rm -f conftest.$ac_objext conftest$ac_exeext
5364 if { (eval echo "$as_me:5364: \"$ac_link\"") >&5
5365 (eval $ac_link) 2>&5
5367 echo "$as_me:5367: \$? = $ac_status" >&5
5368 (exit $ac_status); } &&
5369 { ac_try='test -s conftest$ac_exeext'
5370 { (eval echo "$as_me:5370: \"$ac_try\"") >&5
5373 echo "$as_me:5373: \$? = $ac_status" >&5
5374 (exit $ac_status); }; }; then
5375 ac_cv_lib_gpm_Gpm_Open=yes
5377 echo "$as_me: failed program was:" >&5
5378 cat conftest.$ac_ext >&5
5379 ac_cv_lib_gpm_Gpm_Open=no
5381 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5382 LIBS=$ac_check_lib_save_LIBS
5384 echo "$as_me:5384: result: $ac_cv_lib_gpm_Gpm_Open" >&5
5385 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
5386 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
5387 echo "$as_me:5387: checking for initscr in -lgpm" >&5
5388 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
5389 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
5390 echo $ECHO_N "(cached) $ECHO_C" >&6
5392 ac_check_lib_save_LIBS=$LIBS
5394 cat >conftest.$ac_ext <<_ACEOF
5395 #line 5395 "configure"
5396 #include "confdefs.h"
5398 /* Override any gcc2 internal prototype to avoid an error. */
5402 /* We use char because int might match the return type of a gcc2
5403 builtin and then its argument prototype would still apply. */
5413 rm -f conftest.$ac_objext conftest$ac_exeext
5414 if { (eval echo "$as_me:5414: \"$ac_link\"") >&5
5415 (eval $ac_link) 2>&5
5417 echo "$as_me:5417: \$? = $ac_status" >&5
5418 (exit $ac_status); } &&
5419 { ac_try='test -s conftest$ac_exeext'
5420 { (eval echo "$as_me:5420: \"$ac_try\"") >&5
5423 echo "$as_me:5423: \$? = $ac_status" >&5
5424 (exit $ac_status); }; }; then
5425 ac_cv_lib_gpm_initscr=yes
5427 echo "$as_me: failed program was:" >&5
5428 cat conftest.$ac_ext >&5
5429 ac_cv_lib_gpm_initscr=no
5431 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5432 LIBS=$ac_check_lib_save_LIBS
5434 echo "$as_me:5434: result: $ac_cv_lib_gpm_initscr" >&5
5435 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
5436 if test $ac_cv_lib_gpm_initscr = yes; then
5437 LIBS="$cf_ncurses_SAVE"
5439 cf_ncurses_LIBS="-lgpm"
5444 case $host_os in #(vi
5446 # This is only necessary if you are linking against an obsolete
5447 # version of ncurses (but it should do no harm, since it's static).
5448 if test "$cf_nculib_root" = ncurses ; then
5449 echo "$as_me:5449: checking for tgoto in -lmytinfo" >&5
5450 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
5451 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
5452 echo $ECHO_N "(cached) $ECHO_C" >&6
5454 ac_check_lib_save_LIBS=$LIBS
5455 LIBS="-lmytinfo $LIBS"
5456 cat >conftest.$ac_ext <<_ACEOF
5457 #line 5457 "configure"
5458 #include "confdefs.h"
5460 /* Override any gcc2 internal prototype to avoid an error. */
5464 /* We use char because int might match the return type of a gcc2
5465 builtin and then its argument prototype would still apply. */
5475 rm -f conftest.$ac_objext conftest$ac_exeext
5476 if { (eval echo "$as_me:5476: \"$ac_link\"") >&5
5477 (eval $ac_link) 2>&5
5479 echo "$as_me:5479: \$? = $ac_status" >&5
5480 (exit $ac_status); } &&
5481 { ac_try='test -s conftest$ac_exeext'
5482 { (eval echo "$as_me:5482: \"$ac_try\"") >&5
5485 echo "$as_me:5485: \$? = $ac_status" >&5
5486 (exit $ac_status); }; }; then
5487 ac_cv_lib_mytinfo_tgoto=yes
5489 echo "$as_me: failed program was:" >&5
5490 cat conftest.$ac_ext >&5
5491 ac_cv_lib_mytinfo_tgoto=no
5493 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5494 LIBS=$ac_check_lib_save_LIBS
5496 echo "$as_me:5496: result: $ac_cv_lib_mytinfo_tgoto" >&5
5497 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
5498 if test $ac_cv_lib_mytinfo_tgoto = yes; then
5499 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
5506 LIBS="$cf_ncurses_LIBS $LIBS"
5508 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
5510 LIBS="-l$cf_nculib_root $LIBS"
5513 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
5515 echo "$as_me:5515: checking for initscr" >&5
5516 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
5517 if test "${ac_cv_func_initscr+set}" = set; then
5518 echo $ECHO_N "(cached) $ECHO_C" >&6
5520 cat >conftest.$ac_ext <<_ACEOF
5521 #line 5521 "configure"
5522 #include "confdefs.h"
5523 /* System header to define __stub macros and hopefully few prototypes,
5524 which can conflict with char initscr (); below. */
5526 /* Override any gcc2 internal prototype to avoid an error. */
5530 /* We use char because int might match the return type of a gcc2
5531 builtin and then its argument prototype would still apply. */
5538 /* The GNU C library defines this for functions which it implements
5539 to always fail with ENOSYS. Some functions are actually named
5540 something starting with __ and the normal name is an alias. */
5541 #if defined (__stub_initscr) || defined (__stub___initscr)
5551 rm -f conftest.$ac_objext conftest$ac_exeext
5552 if { (eval echo "$as_me:5552: \"$ac_link\"") >&5
5553 (eval $ac_link) 2>&5
5555 echo "$as_me:5555: \$? = $ac_status" >&5
5556 (exit $ac_status); } &&
5557 { ac_try='test -s conftest$ac_exeext'
5558 { (eval echo "$as_me:5558: \"$ac_try\"") >&5
5561 echo "$as_me:5561: \$? = $ac_status" >&5
5562 (exit $ac_status); }; }; then
5563 ac_cv_func_initscr=yes
5565 echo "$as_me: failed program was:" >&5
5566 cat conftest.$ac_ext >&5
5567 ac_cv_func_initscr=no
5569 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5571 echo "$as_me:5571: result: $ac_cv_func_initscr" >&5
5572 echo "${ECHO_T}$ac_cv_func_initscr" >&6
5573 if test $ac_cv_func_initscr = yes; then
5574 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
5577 cf_save_LIBS="$LIBS"
5578 echo "$as_me:5578: checking for initscr in -l$cf_nculib_root" >&5
5579 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
5580 LIBS="-l$cf_nculib_root $LIBS"
5581 cat >conftest.$ac_ext <<_ACEOF
5582 #line 5582 "configure"
5583 #include "confdefs.h"
5584 #include <${cf_cv_ncurses_header:-curses.h}>
5593 rm -f conftest.$ac_objext conftest$ac_exeext
5594 if { (eval echo "$as_me:5594: \"$ac_link\"") >&5
5595 (eval $ac_link) 2>&5
5597 echo "$as_me:5597: \$? = $ac_status" >&5
5598 (exit $ac_status); } &&
5599 { ac_try='test -s conftest$ac_exeext'
5600 { (eval echo "$as_me:5600: \"$ac_try\"") >&5
5603 echo "$as_me:5603: \$? = $ac_status" >&5
5604 (exit $ac_status); }; }; then
5605 echo "$as_me:5605: result: yes" >&5
5606 echo "${ECHO_T}yes" >&6
5607 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
5610 echo "$as_me: failed program was:" >&5
5611 cat conftest.$ac_ext >&5
5612 echo "$as_me:5612: result: no" >&5
5613 echo "${ECHO_T}no" >&6
5616 cf_library_path_list=""
5617 if test -n "${LDFLAGS}${LIBS}" ; then
5618 for cf_library_path in $LDFLAGS $LIBS
5620 case $cf_library_path in #(vi
5622 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
5624 test "$cf_library_path" != "NONE" && \
5625 test -d "$cf_library_path" && \
5627 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
5628 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
5629 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
5630 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
5631 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
5632 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"
5635 cf_library_path_list="$cf_library_path_list $cf_search"
5643 test "/usr" != "$prefix" && \
5645 (test $prefix = NONE || test "/usr" != "$prefix") && {
5646 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
5647 test -d /usr/lib && cf_search="$cf_search /usr/lib"
5648 test -d /usr/lib/$cf_nculib_root && cf_search="$cf_search /usr/lib/$cf_nculib_root"
5649 test -d /usr/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/lib/$cf_nculib_root/lib"
5650 test -d /usr/$cf_nculib_root/lib && cf_search="$cf_search /usr/$cf_nculib_root/lib"
5651 test -d /usr/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/$cf_nculib_root/lib/$cf_nculib_root"
5654 test "$prefix" != "NONE" && \
5655 test -d "$prefix" && \
5657 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
5658 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
5659 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
5660 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
5661 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
5662 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
5665 test "/usr/local" != "$prefix" && \
5666 test -d "/usr/local" && \
5667 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
5668 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
5669 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
5670 test -d /usr/local/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/lib/$cf_nculib_root"
5671 test -d /usr/local/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/lib/$cf_nculib_root/lib"
5672 test -d /usr/local/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/$cf_nculib_root/lib"
5673 test -d /usr/local/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/$cf_nculib_root/lib/$cf_nculib_root"
5676 test "/opt" != "$prefix" && \
5678 (test $prefix = NONE || test "/opt" != "$prefix") && {
5679 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
5680 test -d /opt/lib && cf_search="$cf_search /opt/lib"
5681 test -d /opt/lib/$cf_nculib_root && cf_search="$cf_search /opt/lib/$cf_nculib_root"
5682 test -d /opt/lib/$cf_nculib_root/lib && cf_search="$cf_search /opt/lib/$cf_nculib_root/lib"
5683 test -d /opt/$cf_nculib_root/lib && cf_search="$cf_search /opt/$cf_nculib_root/lib"
5684 test -d /opt/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /opt/$cf_nculib_root/lib/$cf_nculib_root"
5687 test "$HOME" != "$prefix" && \
5688 test -d "$HOME" && \
5689 (test $prefix = NONE || test "$HOME" != "$prefix") && {
5690 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
5691 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
5692 test -d $HOME/lib/$cf_nculib_root && cf_search="$cf_search $HOME/lib/$cf_nculib_root"
5693 test -d $HOME/lib/$cf_nculib_root/lib && cf_search="$cf_search $HOME/lib/$cf_nculib_root/lib"
5694 test -d $HOME/$cf_nculib_root/lib && cf_search="$cf_search $HOME/$cf_nculib_root/lib"
5695 test -d $HOME/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $HOME/$cf_nculib_root/lib/$cf_nculib_root"
5698 cf_search="$cf_library_path_list $cf_search"
5700 for cf_libdir in $cf_search
5702 echo "$as_me:5702: checking for -l$cf_nculib_root in $cf_libdir" >&5
5703 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
5704 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
5705 cat >conftest.$ac_ext <<_ACEOF
5706 #line 5706 "configure"
5707 #include "confdefs.h"
5708 #include <${cf_cv_ncurses_header:-curses.h}>
5717 rm -f conftest.$ac_objext conftest$ac_exeext
5718 if { (eval echo "$as_me:5718: \"$ac_link\"") >&5
5719 (eval $ac_link) 2>&5
5721 echo "$as_me:5721: \$? = $ac_status" >&5
5722 (exit $ac_status); } &&
5723 { ac_try='test -s conftest$ac_exeext'
5724 { (eval echo "$as_me:5724: \"$ac_try\"") >&5
5727 echo "$as_me:5727: \$? = $ac_status" >&5
5728 (exit $ac_status); }; }; then
5729 echo "$as_me:5729: result: yes" >&5
5730 echo "${ECHO_T}yes" >&6
5731 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
5734 echo "$as_me: failed program was:" >&5
5735 cat conftest.$ac_ext >&5
5736 echo "$as_me:5736: result: no" >&5
5737 echo "${ECHO_T}no" >&6
5738 LIBS="$cf_save_LIBS"
5740 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5744 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5748 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
5750 if test $cf_found_library = no ; then
5751 { { echo "$as_me:5751: error: Cannot link $cf_nculib_root library" >&5
5752 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
5753 { (exit 1); exit 1; }; }
5758 if test -n "$cf_ncurses_LIBS" ; then
5759 echo "$as_me:5759: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
5760 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
5761 cf_ncurses_SAVE="$LIBS"
5762 for p in $cf_ncurses_LIBS ; do
5763 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
5764 if test "$q" != "$LIBS" ; then
5768 cat >conftest.$ac_ext <<_ACEOF
5769 #line 5769 "configure"
5770 #include "confdefs.h"
5771 #include <${cf_cv_ncurses_header:-curses.h}>
5775 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
5780 rm -f conftest.$ac_objext conftest$ac_exeext
5781 if { (eval echo "$as_me:5781: \"$ac_link\"") >&5
5782 (eval $ac_link) 2>&5
5784 echo "$as_me:5784: \$? = $ac_status" >&5
5785 (exit $ac_status); } &&
5786 { ac_try='test -s conftest$ac_exeext'
5787 { (eval echo "$as_me:5787: \"$ac_try\"") >&5
5790 echo "$as_me:5790: \$? = $ac_status" >&5
5791 (exit $ac_status); }; }; then
5792 echo "$as_me:5792: result: yes" >&5
5793 echo "${ECHO_T}yes" >&6
5795 echo "$as_me: failed program was:" >&5
5796 cat conftest.$ac_ext >&5
5797 echo "$as_me:5797: result: no" >&5
5798 echo "${ECHO_T}no" >&6
5799 LIBS="$cf_ncurses_SAVE"
5801 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5804 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
5806 cat >>confdefs.h <<EOF
5807 #define $cf_nculib_ROOT 1
5814 cf_ncuconfig_root=ncurses
5816 echo "Looking for ${cf_ncuconfig_root}-config"
5817 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
5819 # Extract the first word of "$ac_prog", so it can be a program name with args.
5820 set dummy $ac_prog; ac_word=$2
5821 echo "$as_me:5821: checking for $ac_word" >&5
5822 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5823 if test "${ac_cv_path_NCURSES_CONFIG+set}" = set; then
5824 echo $ECHO_N "(cached) $ECHO_C" >&6
5826 case $NCURSES_CONFIG in
5828 ac_cv_path_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test with a path.
5831 ac_save_IFS=$IFS; IFS=$ac_path_separator
5833 for ac_dir in $ac_dummy; do
5835 test -z "$ac_dir" && ac_dir=.
5836 if $as_executable_p "$ac_dir/$ac_word"; then
5837 ac_cv_path_NCURSES_CONFIG="$ac_dir/$ac_word"
5838 echo "$as_me:5838: found $ac_dir/$ac_word" >&5
5846 NCURSES_CONFIG=$ac_cv_path_NCURSES_CONFIG
5848 if test -n "$NCURSES_CONFIG"; then
5849 echo "$as_me:5849: result: $NCURSES_CONFIG" >&5
5850 echo "${ECHO_T}$NCURSES_CONFIG" >&6
5852 echo "$as_me:5852: result: no" >&5
5853 echo "${ECHO_T}no" >&6
5856 test -n "$NCURSES_CONFIG" && break
5858 test -n "$NCURSES_CONFIG" || NCURSES_CONFIG="none"
5860 if test "$NCURSES_CONFIG" != none ; then
5862 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
5863 LIBS="`$NCURSES_CONFIG --libs` $LIBS"
5865 # even with config script, some packages use no-override for curses.h
5867 echo "$as_me:5867: checking if we have identified curses headers" >&5
5868 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
5869 if test "${cf_cv_ncurses_header+set}" = set; then
5870 echo $ECHO_N "(cached) $ECHO_C" >&6
5873 cf_cv_ncurses_header=none
5880 cat >conftest.$ac_ext <<_ACEOF
5881 #line 5881 "configure"
5882 #include "confdefs.h"
5883 #include <${cf_header}>
5887 initscr(); tgoto("?", 0,0)
5892 rm -f conftest.$ac_objext
5893 if { (eval echo "$as_me:5893: \"$ac_compile\"") >&5
5894 (eval $ac_compile) 2>&5
5896 echo "$as_me:5896: \$? = $ac_status" >&5
5897 (exit $ac_status); } &&
5898 { ac_try='test -s conftest.$ac_objext'
5899 { (eval echo "$as_me:5899: \"$ac_try\"") >&5
5902 echo "$as_me:5902: \$? = $ac_status" >&5
5903 (exit $ac_status); }; }; then
5904 cf_cv_ncurses_header=$cf_header; break
5906 echo "$as_me: failed program was:" >&5
5907 cat conftest.$ac_ext >&5
5909 rm -f conftest.$ac_objext conftest.$ac_ext
5913 echo "$as_me:5913: result: $cf_cv_ncurses_header" >&5
5914 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
5916 if test "$cf_cv_ncurses_header" = none ; then
5917 { { echo "$as_me:5917: error: No curses header-files found" >&5
5918 echo "$as_me: error: No curses header-files found" >&2;}
5919 { (exit 1); exit 1; }; }
5922 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
5924 for ac_header in $cf_cv_ncurses_header
5926 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5927 echo "$as_me:5927: checking for $ac_header" >&5
5928 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5929 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5930 echo $ECHO_N "(cached) $ECHO_C" >&6
5932 cat >conftest.$ac_ext <<_ACEOF
5933 #line 5933 "configure"
5934 #include "confdefs.h"
5935 #include <$ac_header>
5937 if { (eval echo "$as_me:5937: \"$ac_cpp conftest.$ac_ext\"") >&5
5938 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5940 egrep -v '^ *\+' conftest.er1 >conftest.err
5942 cat conftest.err >&5
5943 echo "$as_me:5943: \$? = $ac_status" >&5
5944 (exit $ac_status); } >/dev/null; then
5945 if test -s conftest.err; then
5946 ac_cpp_err=$ac_c_preproc_warn_flag
5953 if test -z "$ac_cpp_err"; then
5954 eval "$as_ac_Header=yes"
5956 echo "$as_me: failed program was:" >&5
5957 cat conftest.$ac_ext >&5
5958 eval "$as_ac_Header=no"
5960 rm -f conftest.err conftest.$ac_ext
5962 echo "$as_me:5962: result: `eval echo '${'$as_ac_Header'}'`" >&5
5963 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5964 if test `eval echo '${'$as_ac_Header'}'` = yes; then
5965 cat >>confdefs.h <<EOF
5966 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5972 cat >>confdefs.h <<\EOF
5976 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
5978 cat >>confdefs.h <<EOF
5979 #define $cf_nculib_ROOT 1
5982 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
5986 cf_ncuhdr_root=ncurses
5988 test -n "$cf_cv_curses_dir" && \
5989 test "$cf_cv_curses_dir" != "no" && { \
5991 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
5992 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
5994 while test $cf_add_incdir != /usr/include
5996 if test -d $cf_add_incdir
5999 if test -n "$CFLAGS$CPPFLAGS" ; then
6000 # a loop is needed to ensure we can add subdirs of existing dirs
6001 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6002 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6003 cf_have_incdir=yes; break
6008 if test "$cf_have_incdir" = no ; then
6009 if test "$cf_add_incdir" = /usr/local/include ; then
6010 if test "$GCC" = yes
6012 cf_save_CPPFLAGS=$CPPFLAGS
6013 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6014 cat >conftest.$ac_ext <<_ACEOF
6015 #line 6015 "configure"
6016 #include "confdefs.h"
6026 rm -f conftest.$ac_objext
6027 if { (eval echo "$as_me:6027: \"$ac_compile\"") >&5
6028 (eval $ac_compile) 2>&5
6030 echo "$as_me:6030: \$? = $ac_status" >&5
6031 (exit $ac_status); } &&
6032 { ac_try='test -s conftest.$ac_objext'
6033 { (eval echo "$as_me:6033: \"$ac_try\"") >&5
6036 echo "$as_me:6036: \$? = $ac_status" >&5
6037 (exit $ac_status); }; }; then
6040 echo "$as_me: failed program was:" >&5
6041 cat conftest.$ac_ext >&5
6044 rm -f conftest.$ac_objext conftest.$ac_ext
6045 CPPFLAGS=$cf_save_CPPFLAGS
6050 if test "$cf_have_incdir" = no ; then
6051 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6053 echo "${as_me:-configure}:6053: testing adding $cf_add_incdir to include-path ..." 1>&5
6055 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6057 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6058 test "$cf_top_incdir" = "$cf_add_incdir" && break
6059 cf_add_incdir="$cf_top_incdir"
6070 echo "$as_me:6070: checking for $cf_ncuhdr_root header in include-path" >&5
6071 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
6072 if test "${cf_cv_ncurses_h+set}" = set; then
6073 echo $ECHO_N "(cached) $ECHO_C" >&6
6076 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
6077 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
6078 for cf_header in $cf_header_list
6081 cat >conftest.$ac_ext <<_ACEOF
6082 #line 6082 "configure"
6083 #include "confdefs.h"
6085 #include <$cf_header>
6090 #ifdef NCURSES_VERSION
6092 printf("%s\n", NCURSES_VERSION);
6105 rm -f conftest.$ac_objext
6106 if { (eval echo "$as_me:6106: \"$ac_compile\"") >&5
6107 (eval $ac_compile) 2>&5
6109 echo "$as_me:6109: \$? = $ac_status" >&5
6110 (exit $ac_status); } &&
6111 { ac_try='test -s conftest.$ac_objext'
6112 { (eval echo "$as_me:6112: \"$ac_try\"") >&5
6115 echo "$as_me:6115: \$? = $ac_status" >&5
6116 (exit $ac_status); }; }; then
6117 cf_cv_ncurses_h=$cf_header
6120 echo "$as_me: failed program was:" >&5
6121 cat conftest.$ac_ext >&5
6124 rm -f conftest.$ac_objext conftest.$ac_ext
6126 test "$cf_cv_ncurses_h" != no && break
6130 echo "$as_me:6130: result: $cf_cv_ncurses_h" >&5
6131 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
6133 if test "$cf_cv_ncurses_h" != no ; then
6134 cf_cv_ncurses_header=$cf_cv_ncurses_h
6137 echo "$as_me:6137: checking for $cf_ncuhdr_root include-path" >&5
6138 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
6139 if test "${cf_cv_ncurses_h2+set}" = set; then
6140 echo $ECHO_N "(cached) $ECHO_C" >&6
6143 test -n "$verbose" && echo
6147 # collect the current set of include-directories from compiler flags
6148 cf_header_path_list=""
6149 if test -n "${CFLAGS}${CPPFLAGS}" ; then
6150 for cf_header_path in $CPPFLAGS $CFLAGS
6152 case $cf_header_path in #(vi
6154 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
6156 test "$cf_header_path" != "NONE" && \
6157 test -d "$cf_header_path" && \
6159 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
6160 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
6161 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
6162 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
6163 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
6164 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"
6167 cf_header_path_list="$cf_header_path_list $cf_search"
6173 # add the variations for the package we are looking for
6177 test "/usr" != "$prefix" && \
6179 (test $prefix = NONE || test "/usr" != "$prefix") && {
6180 test -n "$verbose" && echo " ... testing for include-directories under /usr"
6181 test -d /usr/include && cf_search="$cf_search /usr/include"
6182 test -d /usr/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/include/$cf_ncuhdr_root"
6183 test -d /usr/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/include/$cf_ncuhdr_root/include"
6184 test -d /usr/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/$cf_ncuhdr_root/include"
6185 test -d /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6188 test "$prefix" != "NONE" && \
6189 test -d "$prefix" && \
6191 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
6192 test -d $prefix/include && cf_search="$cf_search $prefix/include"
6193 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
6194 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
6195 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
6196 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6199 test "/usr/local" != "$prefix" && \
6200 test -d "/usr/local" && \
6201 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
6202 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
6203 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
6204 test -d /usr/local/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root"
6205 test -d /usr/local/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root/include"
6206 test -d /usr/local/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include"
6207 test -d /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6210 test "/opt" != "$prefix" && \
6212 (test $prefix = NONE || test "/opt" != "$prefix") && {
6213 test -n "$verbose" && echo " ... testing for include-directories under /opt"
6214 test -d /opt/include && cf_search="$cf_search /opt/include"
6215 test -d /opt/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/include/$cf_ncuhdr_root"
6216 test -d /opt/include/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/include/$cf_ncuhdr_root/include"
6217 test -d /opt/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/$cf_ncuhdr_root/include"
6218 test -d /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6221 test "$HOME" != "$prefix" && \
6222 test -d "$HOME" && \
6223 (test $prefix = NONE || test "$HOME" != "$prefix") && {
6224 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
6225 test -d $HOME/include && cf_search="$cf_search $HOME/include"
6226 test -d $HOME/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root"
6227 test -d $HOME/include/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root/include"
6228 test -d $HOME/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include"
6229 test -d $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6232 test "$includedir" != NONE && \
6233 test "$includedir" != "/usr/include" && \
6234 test -d "$includedir" && {
6235 test -d $includedir && cf_search="$cf_search $includedir"
6236 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
6239 test "$oldincludedir" != NONE && \
6240 test "$oldincludedir" != "/usr/include" && \
6241 test -d "$oldincludedir" && {
6242 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
6243 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
6246 cf_search="$cf_search $cf_header_path_list"
6248 test -n "$verbose" && echo search path $cf_search
6249 cf_save2_CPPFLAGS="$CPPFLAGS"
6250 for cf_incdir in $cf_search
6253 if test -n "$cf_incdir" ; then
6254 for cf_add_incdir in $cf_incdir
6256 while test $cf_add_incdir != /usr/include
6258 if test -d $cf_add_incdir
6261 if test -n "$CFLAGS$CPPFLAGS" ; then
6262 # a loop is needed to ensure we can add subdirs of existing dirs
6263 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6264 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6265 cf_have_incdir=yes; break
6270 if test "$cf_have_incdir" = no ; then
6271 if test "$cf_add_incdir" = /usr/local/include ; then
6272 if test "$GCC" = yes
6274 cf_save_CPPFLAGS=$CPPFLAGS
6275 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6276 cat >conftest.$ac_ext <<_ACEOF
6277 #line 6277 "configure"
6278 #include "confdefs.h"
6288 rm -f conftest.$ac_objext
6289 if { (eval echo "$as_me:6289: \"$ac_compile\"") >&5
6290 (eval $ac_compile) 2>&5
6292 echo "$as_me:6292: \$? = $ac_status" >&5
6293 (exit $ac_status); } &&
6294 { ac_try='test -s conftest.$ac_objext'
6295 { (eval echo "$as_me:6295: \"$ac_try\"") >&5
6298 echo "$as_me:6298: \$? = $ac_status" >&5
6299 (exit $ac_status); }; }; then
6302 echo "$as_me: failed program was:" >&5
6303 cat conftest.$ac_ext >&5
6306 rm -f conftest.$ac_objext conftest.$ac_ext
6307 CPPFLAGS=$cf_save_CPPFLAGS
6312 if test "$cf_have_incdir" = no ; then
6313 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6315 echo "${as_me:-configure}:6315: testing adding $cf_add_incdir to include-path ..." 1>&5
6317 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6319 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6320 test "$cf_top_incdir" = "$cf_add_incdir" && break
6321 cf_add_incdir="$cf_top_incdir"
6335 cat >conftest.$ac_ext <<_ACEOF
6336 #line 6336 "configure"
6337 #include "confdefs.h"
6339 #include <$cf_header>
6344 #ifdef NCURSES_VERSION
6346 printf("%s\n", NCURSES_VERSION);
6359 rm -f conftest.$ac_objext
6360 if { (eval echo "$as_me:6360: \"$ac_compile\"") >&5
6361 (eval $ac_compile) 2>&5
6363 echo "$as_me:6363: \$? = $ac_status" >&5
6364 (exit $ac_status); } &&
6365 { ac_try='test -s conftest.$ac_objext'
6366 { (eval echo "$as_me:6366: \"$ac_try\"") >&5
6369 echo "$as_me:6369: \$? = $ac_status" >&5
6370 (exit $ac_status); }; }; then
6371 cf_cv_ncurses_h2=$cf_header
6374 echo "$as_me: failed program was:" >&5
6375 cat conftest.$ac_ext >&5
6378 rm -f conftest.$ac_objext conftest.$ac_ext
6380 if test "$cf_cv_ncurses_h2" != no ; then
6381 cf_cv_ncurses_h2=$cf_incdir/$cf_header
6382 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
6385 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
6387 CPPFLAGS="$cf_save2_CPPFLAGS"
6388 test "$cf_cv_ncurses_h2" != no && break
6390 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:6390: error: not found" >&5
6391 echo "$as_me: error: not found" >&2;}
6392 { (exit 1); exit 1; }; }
6395 echo "$as_me:6395: result: $cf_cv_ncurses_h2" >&5
6396 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
6398 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
6399 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
6400 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
6401 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
6404 if test -n "$cf_1st_incdir" ; then
6405 for cf_add_incdir in $cf_1st_incdir
6407 while test $cf_add_incdir != /usr/include
6409 if test -d $cf_add_incdir
6412 if test -n "$CFLAGS$CPPFLAGS" ; then
6413 # a loop is needed to ensure we can add subdirs of existing dirs
6414 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6415 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6416 cf_have_incdir=yes; break
6421 if test "$cf_have_incdir" = no ; then
6422 if test "$cf_add_incdir" = /usr/local/include ; then
6423 if test "$GCC" = yes
6425 cf_save_CPPFLAGS=$CPPFLAGS
6426 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6427 cat >conftest.$ac_ext <<_ACEOF
6428 #line 6428 "configure"
6429 #include "confdefs.h"
6439 rm -f conftest.$ac_objext
6440 if { (eval echo "$as_me:6440: \"$ac_compile\"") >&5
6441 (eval $ac_compile) 2>&5
6443 echo "$as_me:6443: \$? = $ac_status" >&5
6444 (exit $ac_status); } &&
6445 { ac_try='test -s conftest.$ac_objext'
6446 { (eval echo "$as_me:6446: \"$ac_try\"") >&5
6449 echo "$as_me:6449: \$? = $ac_status" >&5
6450 (exit $ac_status); }; }; then
6453 echo "$as_me: failed program was:" >&5
6454 cat conftest.$ac_ext >&5
6457 rm -f conftest.$ac_objext conftest.$ac_ext
6458 CPPFLAGS=$cf_save_CPPFLAGS
6463 if test "$cf_have_incdir" = no ; then
6464 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6466 echo "${as_me:-configure}:6466: testing adding $cf_add_incdir to include-path ..." 1>&5
6468 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6470 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6471 test "$cf_top_incdir" = "$cf_add_incdir" && break
6472 cf_add_incdir="$cf_top_incdir"
6483 # Set definitions to allow ifdef'ing for ncurses.h
6485 case $cf_cv_ncurses_header in # (vi
6487 cat >>confdefs.h <<\EOF
6488 #define HAVE_NCURSES_H 1
6494 case $cf_cv_ncurses_header in # (vi
6495 ncurses/curses.h|ncurses/ncurses.h)
6496 cat >>confdefs.h <<\EOF
6497 #define HAVE_NCURSES_NCURSES_H 1
6501 ncursesw/curses.h|ncursesw/ncurses.h)
6502 cat >>confdefs.h <<\EOF
6503 #define HAVE_NCURSESW_NCURSES_H 1
6509 echo "$as_me:6509: checking for terminfo header" >&5
6510 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
6511 if test "${cf_cv_term_header+set}" = set; then
6512 echo $ECHO_N "(cached) $ECHO_C" >&6
6515 case ${cf_cv_ncurses_header} in #(vi
6516 */ncurses.h|*/ncursesw.h) #(vi
6517 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
6520 cf_term_header=term.h
6524 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
6526 cat >conftest.$ac_ext <<_ACEOF
6527 #line 6527 "configure"
6528 #include "confdefs.h"
6530 #include <${cf_cv_ncurses_header:-curses.h}>
6536 int x = auto_left_margin
6541 rm -f conftest.$ac_objext
6542 if { (eval echo "$as_me:6542: \"$ac_compile\"") >&5
6543 (eval $ac_compile) 2>&5
6545 echo "$as_me:6545: \$? = $ac_status" >&5
6546 (exit $ac_status); } &&
6547 { ac_try='test -s conftest.$ac_objext'
6548 { (eval echo "$as_me:6548: \"$ac_try\"") >&5
6551 echo "$as_me:6551: \$? = $ac_status" >&5
6552 (exit $ac_status); }; }; then
6554 cf_cv_term_header="$cf_test"
6556 echo "$as_me: failed program was:" >&5
6557 cat conftest.$ac_ext >&5
6559 cf_cv_term_header=unknown
6562 rm -f conftest.$ac_objext conftest.$ac_ext
6563 test "$cf_cv_term_header" != unknown && break
6567 echo "$as_me:6567: result: $cf_cv_term_header" >&5
6568 echo "${ECHO_T}$cf_cv_term_header" >&6
6570 # Set definitions to allow ifdef'ing to accommodate subdirectories
6572 case $cf_cv_term_header in # (vi
6574 cat >>confdefs.h <<\EOF
6575 #define HAVE_TERM_H 1
6581 case $cf_cv_term_header in # (vi
6582 ncurses/term.h) #(vi
6583 cat >>confdefs.h <<\EOF
6584 #define HAVE_NCURSES_TERM_H 1
6589 cat >>confdefs.h <<\EOF
6590 #define HAVE_NCURSESW_TERM_H 1
6596 # some applications need this, but should check for NCURSES_VERSION
6597 cat >>confdefs.h <<\EOF
6601 echo "$as_me:6601: checking for ncurses version" >&5
6602 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
6603 if test "${cf_cv_ncurses_version+set}" = set; then
6604 echo $ECHO_N "(cached) $ECHO_C" >&6
6607 cf_cv_ncurses_version=no
6610 if test "$cross_compiling" = yes; then
6612 # This will not work if the preprocessor splits the line after the
6613 # Autoconf token. The 'unproto' program does that.
6614 cat > conftest.$ac_ext <<EOF
6615 #include <${cf_cv_ncurses_header:-curses.h}>
6617 #ifdef NCURSES_VERSION
6618 Autoconf NCURSES_VERSION
6626 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
6627 { (eval echo "$as_me:6627: \"$cf_try\"") >&5
6630 echo "$as_me:6630: \$? = $ac_status" >&5
6631 (exit $ac_status); }
6632 if test -f conftest.out ; then
6633 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
6634 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
6639 cat >conftest.$ac_ext <<_ACEOF
6640 #line 6640 "configure"
6641 #include "confdefs.h"
6643 #include <${cf_cv_ncurses_header:-curses.h}>
6647 FILE *fp = fopen("$cf_tempfile", "w");
6648 #ifdef NCURSES_VERSION
6649 # ifdef NCURSES_VERSION_PATCH
6650 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
6652 fprintf(fp, "%s\n", NCURSES_VERSION);
6656 fprintf(fp, "old\n");
6661 ${cf_cv_main_return:-return}(0);
6664 rm -f conftest$ac_exeext
6665 if { (eval echo "$as_me:6665: \"$ac_link\"") >&5
6666 (eval $ac_link) 2>&5
6668 echo "$as_me:6668: \$? = $ac_status" >&5
6669 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6670 { (eval echo "$as_me:6670: \"$ac_try\"") >&5
6673 echo "$as_me:6673: \$? = $ac_status" >&5
6674 (exit $ac_status); }; }; then
6676 cf_cv_ncurses_version=`cat $cf_tempfile`
6678 echo "$as_me: program exited with status $ac_status" >&5
6679 echo "$as_me: failed program was:" >&5
6680 cat conftest.$ac_ext >&5
6682 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6687 echo "$as_me:6687: result: $cf_cv_ncurses_version" >&5
6688 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
6689 test "$cf_cv_ncurses_version" = no || cat >>confdefs.h <<\EOF
6693 cf_nculib_root=ncurses
6694 # This works, except for the special case where we find gpm, but
6695 # ncurses is in a nonstandard location via $LIBS, and we really want
6698 cf_ncurses_SAVE="$LIBS"
6699 echo "$as_me:6699: checking for Gpm_Open in -lgpm" >&5
6700 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
6701 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
6702 echo $ECHO_N "(cached) $ECHO_C" >&6
6704 ac_check_lib_save_LIBS=$LIBS
6706 cat >conftest.$ac_ext <<_ACEOF
6707 #line 6707 "configure"
6708 #include "confdefs.h"
6710 /* Override any gcc2 internal prototype to avoid an error. */
6714 /* We use char because int might match the return type of a gcc2
6715 builtin and then its argument prototype would still apply. */
6725 rm -f conftest.$ac_objext conftest$ac_exeext
6726 if { (eval echo "$as_me:6726: \"$ac_link\"") >&5
6727 (eval $ac_link) 2>&5
6729 echo "$as_me:6729: \$? = $ac_status" >&5
6730 (exit $ac_status); } &&
6731 { ac_try='test -s conftest$ac_exeext'
6732 { (eval echo "$as_me:6732: \"$ac_try\"") >&5
6735 echo "$as_me:6735: \$? = $ac_status" >&5
6736 (exit $ac_status); }; }; then
6737 ac_cv_lib_gpm_Gpm_Open=yes
6739 echo "$as_me: failed program was:" >&5
6740 cat conftest.$ac_ext >&5
6741 ac_cv_lib_gpm_Gpm_Open=no
6743 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6744 LIBS=$ac_check_lib_save_LIBS
6746 echo "$as_me:6746: result: $ac_cv_lib_gpm_Gpm_Open" >&5
6747 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
6748 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
6749 echo "$as_me:6749: checking for initscr in -lgpm" >&5
6750 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
6751 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
6752 echo $ECHO_N "(cached) $ECHO_C" >&6
6754 ac_check_lib_save_LIBS=$LIBS
6756 cat >conftest.$ac_ext <<_ACEOF
6757 #line 6757 "configure"
6758 #include "confdefs.h"
6760 /* Override any gcc2 internal prototype to avoid an error. */
6764 /* We use char because int might match the return type of a gcc2
6765 builtin and then its argument prototype would still apply. */
6775 rm -f conftest.$ac_objext conftest$ac_exeext
6776 if { (eval echo "$as_me:6776: \"$ac_link\"") >&5
6777 (eval $ac_link) 2>&5
6779 echo "$as_me:6779: \$? = $ac_status" >&5
6780 (exit $ac_status); } &&
6781 { ac_try='test -s conftest$ac_exeext'
6782 { (eval echo "$as_me:6782: \"$ac_try\"") >&5
6785 echo "$as_me:6785: \$? = $ac_status" >&5
6786 (exit $ac_status); }; }; then
6787 ac_cv_lib_gpm_initscr=yes
6789 echo "$as_me: failed program was:" >&5
6790 cat conftest.$ac_ext >&5
6791 ac_cv_lib_gpm_initscr=no
6793 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6794 LIBS=$ac_check_lib_save_LIBS
6796 echo "$as_me:6796: result: $ac_cv_lib_gpm_initscr" >&5
6797 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
6798 if test $ac_cv_lib_gpm_initscr = yes; then
6799 LIBS="$cf_ncurses_SAVE"
6801 cf_ncurses_LIBS="-lgpm"
6806 case $host_os in #(vi
6808 # This is only necessary if you are linking against an obsolete
6809 # version of ncurses (but it should do no harm, since it's static).
6810 if test "$cf_nculib_root" = ncurses ; then
6811 echo "$as_me:6811: checking for tgoto in -lmytinfo" >&5
6812 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
6813 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
6814 echo $ECHO_N "(cached) $ECHO_C" >&6
6816 ac_check_lib_save_LIBS=$LIBS
6817 LIBS="-lmytinfo $LIBS"
6818 cat >conftest.$ac_ext <<_ACEOF
6819 #line 6819 "configure"
6820 #include "confdefs.h"
6822 /* Override any gcc2 internal prototype to avoid an error. */
6826 /* We use char because int might match the return type of a gcc2
6827 builtin and then its argument prototype would still apply. */
6837 rm -f conftest.$ac_objext conftest$ac_exeext
6838 if { (eval echo "$as_me:6838: \"$ac_link\"") >&5
6839 (eval $ac_link) 2>&5
6841 echo "$as_me:6841: \$? = $ac_status" >&5
6842 (exit $ac_status); } &&
6843 { ac_try='test -s conftest$ac_exeext'
6844 { (eval echo "$as_me:6844: \"$ac_try\"") >&5
6847 echo "$as_me:6847: \$? = $ac_status" >&5
6848 (exit $ac_status); }; }; then
6849 ac_cv_lib_mytinfo_tgoto=yes
6851 echo "$as_me: failed program was:" >&5
6852 cat conftest.$ac_ext >&5
6853 ac_cv_lib_mytinfo_tgoto=no
6855 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6856 LIBS=$ac_check_lib_save_LIBS
6858 echo "$as_me:6858: result: $ac_cv_lib_mytinfo_tgoto" >&5
6859 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
6860 if test $ac_cv_lib_mytinfo_tgoto = yes; then
6861 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
6868 LIBS="$cf_ncurses_LIBS $LIBS"
6870 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
6872 LIBS="-l$cf_nculib_root $LIBS"
6875 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
6877 echo "$as_me:6877: checking for initscr" >&5
6878 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
6879 if test "${ac_cv_func_initscr+set}" = set; then
6880 echo $ECHO_N "(cached) $ECHO_C" >&6
6882 cat >conftest.$ac_ext <<_ACEOF
6883 #line 6883 "configure"
6884 #include "confdefs.h"
6885 /* System header to define __stub macros and hopefully few prototypes,
6886 which can conflict with char initscr (); below. */
6888 /* Override any gcc2 internal prototype to avoid an error. */
6892 /* We use char because int might match the return type of a gcc2
6893 builtin and then its argument prototype would still apply. */
6900 /* The GNU C library defines this for functions which it implements
6901 to always fail with ENOSYS. Some functions are actually named
6902 something starting with __ and the normal name is an alias. */
6903 #if defined (__stub_initscr) || defined (__stub___initscr)
6913 rm -f conftest.$ac_objext conftest$ac_exeext
6914 if { (eval echo "$as_me:6914: \"$ac_link\"") >&5
6915 (eval $ac_link) 2>&5
6917 echo "$as_me:6917: \$? = $ac_status" >&5
6918 (exit $ac_status); } &&
6919 { ac_try='test -s conftest$ac_exeext'
6920 { (eval echo "$as_me:6920: \"$ac_try\"") >&5
6923 echo "$as_me:6923: \$? = $ac_status" >&5
6924 (exit $ac_status); }; }; then
6925 ac_cv_func_initscr=yes
6927 echo "$as_me: failed program was:" >&5
6928 cat conftest.$ac_ext >&5
6929 ac_cv_func_initscr=no
6931 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6933 echo "$as_me:6933: result: $ac_cv_func_initscr" >&5
6934 echo "${ECHO_T}$ac_cv_func_initscr" >&6
6935 if test $ac_cv_func_initscr = yes; then
6936 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
6939 cf_save_LIBS="$LIBS"
6940 echo "$as_me:6940: checking for initscr in -l$cf_nculib_root" >&5
6941 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
6942 LIBS="-l$cf_nculib_root $LIBS"
6943 cat >conftest.$ac_ext <<_ACEOF
6944 #line 6944 "configure"
6945 #include "confdefs.h"
6946 #include <${cf_cv_ncurses_header:-curses.h}>
6955 rm -f conftest.$ac_objext conftest$ac_exeext
6956 if { (eval echo "$as_me:6956: \"$ac_link\"") >&5
6957 (eval $ac_link) 2>&5
6959 echo "$as_me:6959: \$? = $ac_status" >&5
6960 (exit $ac_status); } &&
6961 { ac_try='test -s conftest$ac_exeext'
6962 { (eval echo "$as_me:6962: \"$ac_try\"") >&5
6965 echo "$as_me:6965: \$? = $ac_status" >&5
6966 (exit $ac_status); }; }; then
6967 echo "$as_me:6967: result: yes" >&5
6968 echo "${ECHO_T}yes" >&6
6969 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
6972 echo "$as_me: failed program was:" >&5
6973 cat conftest.$ac_ext >&5
6974 echo "$as_me:6974: result: no" >&5
6975 echo "${ECHO_T}no" >&6
6978 cf_library_path_list=""
6979 if test -n "${LDFLAGS}${LIBS}" ; then
6980 for cf_library_path in $LDFLAGS $LIBS
6982 case $cf_library_path in #(vi
6984 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
6986 test "$cf_library_path" != "NONE" && \
6987 test -d "$cf_library_path" && \
6989 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
6990 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
6991 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
6992 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
6993 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
6994 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"
6997 cf_library_path_list="$cf_library_path_list $cf_search"
7005 test "/usr" != "$prefix" && \
7007 (test $prefix = NONE || test "/usr" != "$prefix") && {
7008 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
7009 test -d /usr/lib && cf_search="$cf_search /usr/lib"
7010 test -d /usr/lib/$cf_nculib_root && cf_search="$cf_search /usr/lib/$cf_nculib_root"
7011 test -d /usr/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/lib/$cf_nculib_root/lib"
7012 test -d /usr/$cf_nculib_root/lib && cf_search="$cf_search /usr/$cf_nculib_root/lib"
7013 test -d /usr/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/$cf_nculib_root/lib/$cf_nculib_root"
7016 test "$prefix" != "NONE" && \
7017 test -d "$prefix" && \
7019 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
7020 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
7021 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
7022 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
7023 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
7024 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
7027 test "/usr/local" != "$prefix" && \
7028 test -d "/usr/local" && \
7029 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
7030 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
7031 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
7032 test -d /usr/local/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/lib/$cf_nculib_root"
7033 test -d /usr/local/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/lib/$cf_nculib_root/lib"
7034 test -d /usr/local/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/$cf_nculib_root/lib"
7035 test -d /usr/local/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/$cf_nculib_root/lib/$cf_nculib_root"
7038 test "/opt" != "$prefix" && \
7040 (test $prefix = NONE || test "/opt" != "$prefix") && {
7041 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
7042 test -d /opt/lib && cf_search="$cf_search /opt/lib"
7043 test -d /opt/lib/$cf_nculib_root && cf_search="$cf_search /opt/lib/$cf_nculib_root"
7044 test -d /opt/lib/$cf_nculib_root/lib && cf_search="$cf_search /opt/lib/$cf_nculib_root/lib"
7045 test -d /opt/$cf_nculib_root/lib && cf_search="$cf_search /opt/$cf_nculib_root/lib"
7046 test -d /opt/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /opt/$cf_nculib_root/lib/$cf_nculib_root"
7049 test "$HOME" != "$prefix" && \
7050 test -d "$HOME" && \
7051 (test $prefix = NONE || test "$HOME" != "$prefix") && {
7052 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
7053 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
7054 test -d $HOME/lib/$cf_nculib_root && cf_search="$cf_search $HOME/lib/$cf_nculib_root"
7055 test -d $HOME/lib/$cf_nculib_root/lib && cf_search="$cf_search $HOME/lib/$cf_nculib_root/lib"
7056 test -d $HOME/$cf_nculib_root/lib && cf_search="$cf_search $HOME/$cf_nculib_root/lib"
7057 test -d $HOME/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $HOME/$cf_nculib_root/lib/$cf_nculib_root"
7060 cf_search="$cf_library_path_list $cf_search"
7062 for cf_libdir in $cf_search
7064 echo "$as_me:7064: checking for -l$cf_nculib_root in $cf_libdir" >&5
7065 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
7066 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
7067 cat >conftest.$ac_ext <<_ACEOF
7068 #line 7068 "configure"
7069 #include "confdefs.h"
7070 #include <${cf_cv_ncurses_header:-curses.h}>
7079 rm -f conftest.$ac_objext conftest$ac_exeext
7080 if { (eval echo "$as_me:7080: \"$ac_link\"") >&5
7081 (eval $ac_link) 2>&5
7083 echo "$as_me:7083: \$? = $ac_status" >&5
7084 (exit $ac_status); } &&
7085 { ac_try='test -s conftest$ac_exeext'
7086 { (eval echo "$as_me:7086: \"$ac_try\"") >&5
7089 echo "$as_me:7089: \$? = $ac_status" >&5
7090 (exit $ac_status); }; }; then
7091 echo "$as_me:7091: result: yes" >&5
7092 echo "${ECHO_T}yes" >&6
7093 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7096 echo "$as_me: failed program was:" >&5
7097 cat conftest.$ac_ext >&5
7098 echo "$as_me:7098: result: no" >&5
7099 echo "${ECHO_T}no" >&6
7100 LIBS="$cf_save_LIBS"
7102 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7106 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7110 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
7112 if test $cf_found_library = no ; then
7113 { { echo "$as_me:7113: error: Cannot link $cf_nculib_root library" >&5
7114 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
7115 { (exit 1); exit 1; }; }
7120 if test -n "$cf_ncurses_LIBS" ; then
7121 echo "$as_me:7121: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
7122 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
7123 cf_ncurses_SAVE="$LIBS"
7124 for p in $cf_ncurses_LIBS ; do
7125 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
7126 if test "$q" != "$LIBS" ; then
7130 cat >conftest.$ac_ext <<_ACEOF
7131 #line 7131 "configure"
7132 #include "confdefs.h"
7133 #include <${cf_cv_ncurses_header:-curses.h}>
7137 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
7142 rm -f conftest.$ac_objext conftest$ac_exeext
7143 if { (eval echo "$as_me:7143: \"$ac_link\"") >&5
7144 (eval $ac_link) 2>&5
7146 echo "$as_me:7146: \$? = $ac_status" >&5
7147 (exit $ac_status); } &&
7148 { ac_try='test -s conftest$ac_exeext'
7149 { (eval echo "$as_me:7149: \"$ac_try\"") >&5
7152 echo "$as_me:7152: \$? = $ac_status" >&5
7153 (exit $ac_status); }; }; then
7154 echo "$as_me:7154: result: yes" >&5
7155 echo "${ECHO_T}yes" >&6
7157 echo "$as_me: failed program was:" >&5
7158 cat conftest.$ac_ext >&5
7159 echo "$as_me:7159: result: no" >&5
7160 echo "${ECHO_T}no" >&6
7161 LIBS="$cf_ncurses_SAVE"
7163 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7166 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
7168 cat >>confdefs.h <<EOF
7169 #define $cf_nculib_ROOT 1
7176 if test "$NCURSES_CONFIG" != none ; then
7178 cf_version=`$NCURSES_CONFIG --version`
7180 NCURSES_MAJOR=`echo "$cf_version" | sed -e 's/\..*//'`
7181 NCURSES_MINOR=`echo "$cf_version" | sed -e 's/^[0-9]\+\.//' -e 's/\..*//'`
7182 NCURSES_PATCH=`echo "$cf_version" | sed -e 's/^[0-9]\+\.[0-9]\+\.//'`
7184 # ABI version is not available from headers
7185 cf_cv_abi_version=`$NCURSES_CONFIG --abi-version`
7189 for cf_name in MAJOR MINOR PATCH
7191 cat >conftest.$ac_ext <<CF_EOF
7192 #include <${cf_cv_ncurses_header:-curses.h}>
7193 AUTOCONF_$cf_name NCURSES_VERSION_$cf_name
7195 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | fgrep AUTOCONF_$cf_name >conftest.out"
7196 { (eval echo "$as_me:7196: \"$cf_try\"") >&5
7199 echo "$as_me:7199: \$? = $ac_status" >&5
7200 (exit $ac_status); }
7201 if test -f conftest.out ; then
7202 cf_result=`cat conftest.out | sed -e "s/^.*AUTOCONF_$cf_name[ ]\+//"`
7203 eval NCURSES_$cf_name=$cf_result
7204 cat conftest.$ac_ext
7209 cf_cv_abi_version=${NCURSES_MAJOR}
7213 cf_cv_rel_version=${NCURSES_MAJOR}.${NCURSES_MINOR}
7215 cf_cv_timestamp=`date`
7217 echo "$as_me:7217: result: Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&5
7218 echo "${ECHO_T}Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&6
7220 case $cf_cv_system_name in #(vi
7227 cf_prefix=$LIB_PREFIX
7229 LIB_PREFIX=$cf_prefix
7233 ###############################################################################
7235 if test X"$CC_G_OPT" = X"" ; then
7237 test -n "$GCC" && test "${ac_cv_prog_cc_g}" != yes && CC_G_OPT=''
7240 echo "$as_me:7240: checking for default loader flags" >&5
7241 echo $ECHO_N "checking for default loader flags... $ECHO_C" >&6
7242 case $DFT_LWR_MODEL in
7243 normal) LD_MODEL='' ;;
7244 debug) LD_MODEL=$CC_G_OPT ;;
7245 profile) LD_MODEL='-pg';;
7246 shared) LD_MODEL='' ;;
7248 echo "$as_me:7248: result: $LD_MODEL" >&5
7249 echo "${ECHO_T}$LD_MODEL" >&6
7252 echo "$as_me:7252: checking for an rpath option" >&5
7253 echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6
7254 case $cf_cv_system_name in #(vi
7256 if test "$GCC" = yes; then
7257 LD_RPATH_OPT="-Wl,-rpath,"
7259 LD_RPATH_OPT="-rpath "
7262 linux*|gnu*|k*bsd*-gnu) #(vi
7263 LD_RPATH_OPT="-Wl,-rpath,"
7265 openbsd[2-9].*) #(vi
7266 LD_RPATH_OPT="-Wl,-rpath,"
7269 LD_RPATH_OPT="-rpath "
7272 LD_RPATH_OPT="-Wl,-rpath,"
7275 LD_RPATH_OPT="-rpath "
7283 echo "$as_me:7283: result: $LD_RPATH_OPT" >&5
7284 echo "${ECHO_T}$LD_RPATH_OPT" >&6
7286 case "x$LD_RPATH_OPT" in #(vi
7288 echo "$as_me:7288: checking if we need a space after rpath option" >&5
7289 echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6
7290 cf_save_LIBS="$LIBS"
7291 LIBS="${LD_RPATH_OPT}$libdir $LIBS"
7292 cat >conftest.$ac_ext <<_ACEOF
7293 #line 7293 "configure"
7294 #include "confdefs.h"
7304 rm -f conftest.$ac_objext conftest$ac_exeext
7305 if { (eval echo "$as_me:7305: \"$ac_link\"") >&5
7306 (eval $ac_link) 2>&5
7308 echo "$as_me:7308: \$? = $ac_status" >&5
7309 (exit $ac_status); } &&
7310 { ac_try='test -s conftest$ac_exeext'
7311 { (eval echo "$as_me:7311: \"$ac_try\"") >&5
7314 echo "$as_me:7314: \$? = $ac_status" >&5
7315 (exit $ac_status); }; }; then
7318 echo "$as_me: failed program was:" >&5
7319 cat conftest.$ac_ext >&5
7322 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7323 LIBS="$cf_save_LIBS"
7324 echo "$as_me:7324: result: $cf_rpath_space" >&5
7325 echo "${ECHO_T}$cf_rpath_space" >&6
7326 test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
7333 INSTALL_LIB="-m 644"
7335 cf_cv_do_symlinks=no
7337 test "$cf_cv_enable_rpath" = yes && cf_ld_rpath_opt="$LD_RPATH_OPT"
7339 echo "$as_me:7339: checking if release/abi version should be used for shared libs" >&5
7340 echo $ECHO_N "checking if release/abi version should be used for shared libs... $ECHO_C" >&6
7342 # Check whether --with-shlib-version or --without-shlib-version was given.
7343 if test "${with_shlib_version+set}" = set; then
7344 withval="$with_shlib_version"
7345 test -z "$withval" && withval=auto
7346 case $withval in #(vi
7348 cf_cv_shlib_version=auto
7350 rel|abi|auto|no) #(vi
7351 cf_cv_shlib_version=$withval
7354 { { echo "$as_me:7354: error: option value must be one of: rel, abi, auto or no" >&5
7355 echo "$as_me: error: option value must be one of: rel, abi, auto or no" >&2;}
7356 { (exit 1); exit 1; }; }
7361 cf_cv_shlib_version=auto
7363 echo "$as_me:7363: result: $cf_cv_shlib_version" >&5
7364 echo "${ECHO_T}$cf_cv_shlib_version" >&6
7368 # Some less-capable ports of gcc support only -fpic
7370 if test "$GCC" = yes
7372 echo "$as_me:7372: checking which $CC option to use" >&5
7373 echo $ECHO_N "checking which $CC option to use... $ECHO_C" >&6
7374 cf_save_CFLAGS="$CFLAGS"
7375 for CC_SHARED_OPTS in -fPIC -fpic ''
7377 CFLAGS="$cf_save_CFLAGS $CC_SHARED_OPTS"
7378 cat >conftest.$ac_ext <<_ACEOF
7379 #line 7379 "configure"
7380 #include "confdefs.h"
7390 rm -f conftest.$ac_objext
7391 if { (eval echo "$as_me:7391: \"$ac_compile\"") >&5
7392 (eval $ac_compile) 2>&5
7394 echo "$as_me:7394: \$? = $ac_status" >&5
7395 (exit $ac_status); } &&
7396 { ac_try='test -s conftest.$ac_objext'
7397 { (eval echo "$as_me:7397: \"$ac_try\"") >&5
7400 echo "$as_me:7400: \$? = $ac_status" >&5
7401 (exit $ac_status); }; }; then
7404 echo "$as_me: failed program was:" >&5
7405 cat conftest.$ac_ext >&5
7407 rm -f conftest.$ac_objext conftest.$ac_ext
7409 echo "$as_me:7409: result: $CC_SHARED_OPTS" >&5
7410 echo "${ECHO_T}$CC_SHARED_OPTS" >&6
7411 CFLAGS="$cf_save_CFLAGS"
7414 cf_cv_shlib_version_infix=no
7416 case $cf_cv_system_name in #(vi
7418 if test "$GCC" = yes; then
7420 MK_SHARED_LIB='$(CC) -shared'
7424 MK_SHARED_LIB='${CC} ${CFLAGS} -o $@ -Xlinker -soname=`basename $@` -nostart -e 0'
7428 MK_SHARED_LIB='sh ../mk_shared_lib.sh $@ ${CC} ${CFLAGS}'
7429 cf_cv_shlib_version=cygdll
7430 cf_cv_shlib_version_infix=cygdll
7431 cat >mk_shared_lib.sh <<-CF_EOF
7434 IMPORT_LIB=\`echo "\$1" | sed -e 's/cyg/lib/' -e 's/[0-9]*\.dll$/.dll.a/'\`
7437 Linking shared library
7438 ** SHARED_LIB \$SHARED_LIB
7439 ** IMPORT_LIB \$IMPORT_LIB
7441 exec \$* -shared -Wl,--out-implib=../lib/\${IMPORT_LIB} -Wl,--export-all-symbols -o ../lib/\${SHARED_LIB}
7443 chmod +x mk_shared_lib.sh
7446 EXTRA_CFLAGS="-no-cpp-precomp"
7447 CC_SHARED_OPTS="-dynamic"
7448 MK_SHARED_LIB='${CC} ${CFLAGS} -dynamiclib -install_name ${libdir}/`basename $@` -compatibility_version ${ABI_VERSION} -current_version ${ABI_VERSION} -o $@'
7449 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=abi
7450 cf_cv_shlib_version_infix=yes
7451 echo "$as_me:7451: checking if ld -search_paths_first works" >&5
7452 echo $ECHO_N "checking if ld -search_paths_first works... $ECHO_C" >&6
7453 if test "${cf_cv_ldflags_search_paths_first+set}" = set; then
7454 echo $ECHO_N "(cached) $ECHO_C" >&6
7457 cf_save_LDFLAGS=$LDFLAGS
7458 LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
7459 cat >conftest.$ac_ext <<_ACEOF
7460 #line 7460 "configure"
7461 #include "confdefs.h"
7471 rm -f conftest.$ac_objext conftest$ac_exeext
7472 if { (eval echo "$as_me:7472: \"$ac_link\"") >&5
7473 (eval $ac_link) 2>&5
7475 echo "$as_me:7475: \$? = $ac_status" >&5
7476 (exit $ac_status); } &&
7477 { ac_try='test -s conftest$ac_exeext'
7478 { (eval echo "$as_me:7478: \"$ac_try\"") >&5
7481 echo "$as_me:7481: \$? = $ac_status" >&5
7482 (exit $ac_status); }; }; then
7483 cf_cv_ldflags_search_paths_first=yes
7485 echo "$as_me: failed program was:" >&5
7486 cat conftest.$ac_ext >&5
7487 cf_cv_ldflags_search_paths_first=no
7489 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7490 LDFLAGS=$cf_save_LDFLAGS
7492 echo "$as_me:7492: result: $cf_cv_ldflags_search_paths_first" >&5
7493 echo "${ECHO_T}$cf_cv_ldflags_search_paths_first" >&6
7494 if test $cf_cv_ldflags_search_paths_first = yes; then
7495 LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
7499 # (tested with gcc 2.7.2 -- I don't have c89)
7500 if test "$GCC" = yes; then
7501 LD_SHARED_OPTS='-Xlinker +b -Xlinker ${libdir}'
7504 LD_SHARED_OPTS='-Wl,+b,${libdir}'
7506 MK_SHARED_LIB='${LD} +b ${libdir} -b -o $@'
7507 # HP-UX shared libraries must be executable, and should be
7508 # readonly to exploit a quirk in the memory manager.
7509 INSTALL_LIB="-m 555"
7512 if test "$cf_cv_enable_rpath" = yes ; then
7513 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${libdir} $EXTRA_LDFLAGS"
7515 # tested with IRIX 5.2 and 'cc'.
7516 if test "$GCC" != yes; then
7517 CC_SHARED_OPTS='-KPIC'
7518 MK_SHARED_LIB='${CC} -shared -rdata_shared -soname `basename $@` -o $@'
7520 MK_SHARED_LIB='${CC} -shared -Wl,-soname,`basename $@` -o $@'
7522 cf_cv_rm_so_locs=yes
7524 linux*|gnu*|k*bsd*-gnu) #(vi
7525 if test "$DFT_LWR_MODEL" = "shared" ; then
7526 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
7527 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
7529 if test "$cf_cv_enable_rpath" = yes ; then
7530 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${libdir} $EXTRA_LDFLAGS"
7533 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
7534 if test "$cf_cv_shlib_version" = rel; then
7535 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
7537 cf_cv_shared_soname='`basename $@`'
7540 MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
7542 openbsd[2-9].*) #(vi
7543 if test "$DFT_LWR_MODEL" = "shared" ; then
7544 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
7545 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
7547 if test "$cf_cv_enable_rpath" = yes ; then
7548 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${libdir} $EXTRA_LDFLAGS"
7550 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
7552 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
7553 if test "$cf_cv_shlib_version" = rel; then
7554 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
7556 cf_cv_shared_soname='`basename $@`'
7559 MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-Bshareable,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
7561 nto-qnx*|openbsd*|freebsd[12].*) #(vi
7562 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
7563 MK_SHARED_LIB='${LD} -Bshareable -o $@'
7564 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
7567 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
7568 if test "$DFT_LWR_MODEL" = "shared" && test "$cf_cv_enable_rpath" = yes ; then
7569 LOCAL_LDFLAGS="${cf_ld_rpath_opt}\$(LOCAL_LIBDIR)"
7570 LOCAL_LDFLAGS2="${cf_ld_rpath_opt}\${libdir} $LOCAL_LDFLAGS"
7571 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${libdir} $EXTRA_LDFLAGS"
7574 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
7575 if test "$cf_cv_shlib_version" = rel; then
7576 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
7578 cf_cv_shared_soname='`basename $@`'
7581 MK_SHARED_LIB='${LD} -shared -Bshareable -soname=`basename $@` -o $@'
7584 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
7585 if test "$DFT_LWR_MODEL" = "shared" && test "$cf_cv_enable_rpath" = yes ; then
7586 LOCAL_LDFLAGS="${cf_ld_rpath_opt}\$(LOCAL_LIBDIR)"
7587 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
7588 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${libdir} $EXTRA_LDFLAGS"
7589 if test "$cf_cv_shlib_version" = auto; then
7590 if test -f /usr/libexec/ld.elf_so; then
7591 cf_cv_shlib_version=abi
7593 cf_cv_shlib_version=rel
7597 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
7598 if test "$cf_cv_shlib_version" = rel; then
7599 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
7601 cf_cv_shared_soname='`basename $@`'
7604 MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname' -o $@'
7606 MK_SHARED_LIB='${LD} -shared -Bshareable -o $@'
7610 # tested with OSF/1 V3.2 and 'cc'
7611 # tested with OSF/1 V3.2 and gcc 2.6.3 (but the c++ demo didn't
7612 # link with shared libs).
7613 MK_SHARED_LIB='${LD} -set_version ${REL_VERSION}:${ABI_VERSION} -expect_unresolved "*" -shared -soname `basename $@`'
7614 case $host_os in #(vi
7616 MK_SHARED_LIB="${MK_SHARED_LIB} -msym"
7619 MK_SHARED_LIB="${MK_SHARED_LIB}"' -o $@'
7620 if test "$DFT_LWR_MODEL" = "shared" ; then
7621 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
7622 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
7624 cf_cv_rm_so_locs=yes
7626 sco3.2v5*) # (also uw2* and UW7: hops 13-Apr-98
7627 # tested with osr5.0.5
7628 if test "$GCC" != yes; then
7629 CC_SHARED_OPTS='-belf -KPIC'
7631 MK_SHARED_LIB='${LD} -dy -G -h `basename $@ .${REL_VERSION}`.${ABI_VERSION} -o $@'
7632 if test "$cf_cv_enable_rpath" = yes ; then
7633 # only way is to set LD_RUN_PATH but no switch for it
7636 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
7637 LINK_PROGS='LD_RUN_PATH=${libdir}'
7638 LINK_TESTS='Pwd=`pwd`;LD_RUN_PATH=`dirname $${Pwd}`/lib'
7641 # tested with SunOS 4.1.1 and gcc 2.7.0
7642 if test "$GCC" != yes; then
7643 CC_SHARED_OPTS='-KPIC'
7645 MK_SHARED_LIB='${LD} -assert pure-text -o $@'
7646 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
7649 # tested with SunOS 5.5.1 (solaris 2.5.1) and gcc 2.7.2
7650 # tested with SunOS 5.10 (solaris 10) and gcc 3.4.3
7651 if test "$DFT_LWR_MODEL" = "shared" ; then
7652 LOCAL_LDFLAGS="-R \$(LOCAL_LIBDIR):\${libdir}"
7653 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
7655 if test "$cf_cv_enable_rpath" = yes ; then
7656 EXTRA_LDFLAGS="-R \${libdir} $EXTRA_LDFLAGS"
7659 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
7660 if test "$cf_cv_shlib_version" = rel; then
7661 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
7663 cf_cv_shared_soname='`basename $@`'
7666 if test "$GCC" != yes; then
7667 cf_save_CFLAGS="$CFLAGS"
7668 for cf_shared_opts in -xcode=pic32 -xcode=pic13 -KPIC -Kpic -O
7670 CFLAGS="$cf_shared_opts $cf_save_CFLAGS"
7671 cat >conftest.$ac_ext <<_ACEOF
7672 #line 7672 "configure"
7673 #include "confdefs.h"
7683 rm -f conftest.$ac_objext
7684 if { (eval echo "$as_me:7684: \"$ac_compile\"") >&5
7685 (eval $ac_compile) 2>&5
7687 echo "$as_me:7687: \$? = $ac_status" >&5
7688 (exit $ac_status); } &&
7689 { ac_try='test -s conftest.$ac_objext'
7690 { (eval echo "$as_me:7690: \"$ac_try\"") >&5
7693 echo "$as_me:7693: \$? = $ac_status" >&5
7694 (exit $ac_status); }; }; then
7697 echo "$as_me: failed program was:" >&5
7698 cat conftest.$ac_ext >&5
7700 rm -f conftest.$ac_objext conftest.$ac_ext
7702 CFLAGS="$cf_save_CFLAGS"
7703 CC_SHARED_OPTS=$cf_shared_opts
7704 MK_SHARED_LIB='${CC} -dy -G -h '$cf_cv_shared_soname' -o $@'
7706 MK_SHARED_LIB='${CC} -shared -dy -G -h '$cf_cv_shared_soname' -o $@'
7709 sysv5uw7*|unix_sv*) #(vi
7710 # tested with UnixWare 7.1.0 (gcc 2.95.2 and cc)
7711 if test "$GCC" != yes; then
7712 CC_SHARED_OPTS='-KPIC'
7714 MK_SHARED_LIB='${LD} -d y -G -o $@'
7717 CC_SHARED_OPTS='unknown'
7718 MK_SHARED_LIB='echo unknown'
7722 # This works if the last tokens in $MK_SHARED_LIB are the -o target.
7723 case "$cf_cv_shlib_version" in #(vi
7725 case "$MK_SHARED_LIB" in #(vi
7727 test "$cf_cv_do_symlinks" = no && cf_cv_do_symlinks=yes
7730 { echo "$as_me:7730: WARNING: ignored --with-shlib-version" >&5
7731 echo "$as_me: WARNING: ignored --with-shlib-version" >&2;}
7737 if test -n "$cf_ld_rpath_opt" ; then
7738 MK_SHARED_LIB="$MK_SHARED_LIB $cf_ld_rpath_opt\${libdir}"
7741 ###############################################################################
7743 case $cf_cv_system_name in
7744 os2*) PATH_SEPARATOR=';' ;;
7745 *) PATH_SEPARATOR=':' ;;
7748 ### use option --enable-broken-linker to force on use of broken-linker support
7749 echo "$as_me:7749: checking if you want broken-linker support code" >&5
7750 echo $ECHO_N "checking if you want broken-linker support code... $ECHO_C" >&6
7752 # Check whether --enable-broken_linker or --disable-broken_linker was given.
7753 if test "${enable_broken_linker+set}" = set; then
7754 enableval="$enable_broken_linker"
7755 with_broken_linker=$enableval
7757 with_broken_linker=${BROKEN_LINKER:-no}
7759 echo "$as_me:7759: result: $with_broken_linker" >&5
7760 echo "${ECHO_T}$with_broken_linker" >&6
7763 if test "$with_broken_linker" = yes ; then
7764 cat >>confdefs.h <<\EOF
7765 #define BROKEN_LINKER 1
7769 elif test "$DFT_LWR_MODEL" = shared ; then
7770 case $cf_cv_system_name in #(vi
7772 cat >>confdefs.h <<\EOF
7773 #define BROKEN_LINKER 1
7777 test -n "$verbose" && echo " cygwin linker is broken anyway" 1>&6
7779 echo "${as_me:-configure}:7779: testing cygwin linker is broken anyway ..." 1>&5
7785 # Check to define _XOPEN_SOURCE "automatically"
7788 cf_POSIX_C_SOURCE=199506L
7791 case $host_os in #(vi
7793 cf_xopen_source="-D_ALL_SOURCE"
7799 cf_xopen_source="-D_APPLE_C_SOURCE"
7802 cf_xopen_source="-D_DARWIN_C_SOURCE"
7804 freebsd*|dragonfly*) #(vi
7805 # 5.x headers associate
7806 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
7807 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
7808 cf_POSIX_C_SOURCE=200112L
7810 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
7813 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
7816 cf_xopen_source="-D_HPUX_SOURCE"
7819 cf_xopen_source="-D_SGI_SOURCE"
7821 linux*|gnu*|mint*|k*bsd*-gnu) #(vi
7823 echo "$as_me:7823: checking if we must define _GNU_SOURCE" >&5
7824 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
7825 if test "${cf_cv_gnu_source+set}" = set; then
7826 echo $ECHO_N "(cached) $ECHO_C" >&6
7829 cat >conftest.$ac_ext <<_ACEOF
7830 #line 7830 "configure"
7831 #include "confdefs.h"
7832 #include <sys/types.h>
7837 #ifndef _XOPEN_SOURCE
7844 rm -f conftest.$ac_objext
7845 if { (eval echo "$as_me:7845: \"$ac_compile\"") >&5
7846 (eval $ac_compile) 2>&5
7848 echo "$as_me:7848: \$? = $ac_status" >&5
7849 (exit $ac_status); } &&
7850 { ac_try='test -s conftest.$ac_objext'
7851 { (eval echo "$as_me:7851: \"$ac_try\"") >&5
7854 echo "$as_me:7854: \$? = $ac_status" >&5
7855 (exit $ac_status); }; }; then
7858 echo "$as_me: failed program was:" >&5
7859 cat conftest.$ac_ext >&5
7861 CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
7862 cat >conftest.$ac_ext <<_ACEOF
7863 #line 7863 "configure"
7864 #include "confdefs.h"
7865 #include <sys/types.h>
7870 #ifdef _XOPEN_SOURCE
7877 rm -f conftest.$ac_objext
7878 if { (eval echo "$as_me:7878: \"$ac_compile\"") >&5
7879 (eval $ac_compile) 2>&5
7881 echo "$as_me:7881: \$? = $ac_status" >&5
7882 (exit $ac_status); } &&
7883 { ac_try='test -s conftest.$ac_objext'
7884 { (eval echo "$as_me:7884: \"$ac_try\"") >&5
7887 echo "$as_me:7887: \$? = $ac_status" >&5
7888 (exit $ac_status); }; }; then
7891 echo "$as_me: failed program was:" >&5
7892 cat conftest.$ac_ext >&5
7893 cf_cv_gnu_source=yes
7895 rm -f conftest.$ac_objext conftest.$ac_ext
7899 rm -f conftest.$ac_objext conftest.$ac_ext
7902 echo "$as_me:7902: result: $cf_cv_gnu_source" >&5
7903 echo "${ECHO_T}$cf_cv_gnu_source" >&6
7904 test "$cf_cv_gnu_source" = yes && CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
7908 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <arpa/inet.h>
7911 # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
7914 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
7917 cf_xopen_source="-D_OSF_SOURCE"
7920 cf_xopen_source="-D_QNX_SOURCE"
7923 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
7925 solaris2.1[0-9]) #(vi
7926 cf_xopen_source="-D__EXTENSIONS__ -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
7928 solaris2.[1-9]) #(vi
7929 cf_xopen_source="-D__EXTENSIONS__"
7932 echo "$as_me:7932: checking if we should define _XOPEN_SOURCE" >&5
7933 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
7934 if test "${cf_cv_xopen_source+set}" = set; then
7935 echo $ECHO_N "(cached) $ECHO_C" >&6
7938 cat >conftest.$ac_ext <<_ACEOF
7939 #line 7939 "configure"
7940 #include "confdefs.h"
7941 #include <sys/types.h>
7946 #ifndef _XOPEN_SOURCE
7953 rm -f conftest.$ac_objext
7954 if { (eval echo "$as_me:7954: \"$ac_compile\"") >&5
7955 (eval $ac_compile) 2>&5
7957 echo "$as_me:7957: \$? = $ac_status" >&5
7958 (exit $ac_status); } &&
7959 { ac_try='test -s conftest.$ac_objext'
7960 { (eval echo "$as_me:7960: \"$ac_try\"") >&5
7963 echo "$as_me:7963: \$? = $ac_status" >&5
7964 (exit $ac_status); }; }; then
7965 cf_cv_xopen_source=no
7967 echo "$as_me: failed program was:" >&5
7968 cat conftest.$ac_ext >&5
7970 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
7971 cat >conftest.$ac_ext <<_ACEOF
7972 #line 7972 "configure"
7973 #include "confdefs.h"
7974 #include <sys/types.h>
7979 #ifdef _XOPEN_SOURCE
7986 rm -f conftest.$ac_objext
7987 if { (eval echo "$as_me:7987: \"$ac_compile\"") >&5
7988 (eval $ac_compile) 2>&5
7990 echo "$as_me:7990: \$? = $ac_status" >&5
7991 (exit $ac_status); } &&
7992 { ac_try='test -s conftest.$ac_objext'
7993 { (eval echo "$as_me:7993: \"$ac_try\"") >&5
7996 echo "$as_me:7996: \$? = $ac_status" >&5
7997 (exit $ac_status); }; }; then
7998 cf_cv_xopen_source=no
8000 echo "$as_me: failed program was:" >&5
8001 cat conftest.$ac_ext >&5
8002 cf_cv_xopen_source=$cf_XOPEN_SOURCE
8004 rm -f conftest.$ac_objext conftest.$ac_ext
8008 rm -f conftest.$ac_objext conftest.$ac_ext
8011 echo "$as_me:8011: result: $cf_cv_xopen_source" >&5
8012 echo "${ECHO_T}$cf_cv_xopen_source" >&6
8013 if test "$cf_cv_xopen_source" != no ; then
8015 CFLAGS=`echo "$CFLAGS" | \
8016 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
8017 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
8019 CPPFLAGS=`echo "$CPPFLAGS" | \
8020 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
8021 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
8023 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
8028 cf_new_extra_cppflags=
8030 for cf_add_cflags in $cf_temp_xopen_source
8032 case $cf_fix_cppflags in
8034 case $cf_add_cflags in #(vi
8035 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
8036 case $cf_add_cflags in
8038 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
8040 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
8041 && test -z "${cf_tst_cflags}" \
8042 && cf_fix_cppflags=yes
8044 if test $cf_fix_cppflags = yes ; then
8045 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
8047 elif test "${cf_tst_cflags}" = "\"'" ; then
8048 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
8054 *$cf_add_cflags) #(vi
8057 case $cf_add_cflags in #(vi
8059 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
8061 CPPFLAGS=`echo "$CPPFLAGS" | \
8062 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
8063 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
8067 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
8072 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
8077 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
8079 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
8081 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
8082 && test -z "${cf_tst_cflags}" \
8083 && cf_fix_cppflags=no
8088 if test -n "$cf_new_cflags" ; then
8090 CFLAGS="$CFLAGS $cf_new_cflags"
8093 if test -n "$cf_new_cppflags" ; then
8095 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
8098 if test -n "$cf_new_extra_cppflags" ; then
8100 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
8105 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
8107 cf_save_CFLAGS="$CFLAGS"
8108 cf_save_CPPFLAGS="$CPPFLAGS"
8110 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
8111 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
8112 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
8114 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
8115 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
8116 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
8118 echo "$as_me:8118: checking if we should define _POSIX_C_SOURCE" >&5
8119 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
8120 if test "${cf_cv_posix_c_source+set}" = set; then
8121 echo $ECHO_N "(cached) $ECHO_C" >&6
8124 echo "${as_me:-configure}:8124: testing if the symbol is already defined go no further ..." 1>&5
8126 cat >conftest.$ac_ext <<_ACEOF
8127 #line 8127 "configure"
8128 #include "confdefs.h"
8129 #include <sys/types.h>
8134 #ifndef _POSIX_C_SOURCE
8141 rm -f conftest.$ac_objext
8142 if { (eval echo "$as_me:8142: \"$ac_compile\"") >&5
8143 (eval $ac_compile) 2>&5
8145 echo "$as_me:8145: \$? = $ac_status" >&5
8146 (exit $ac_status); } &&
8147 { ac_try='test -s conftest.$ac_objext'
8148 { (eval echo "$as_me:8148: \"$ac_try\"") >&5
8151 echo "$as_me:8151: \$? = $ac_status" >&5
8152 (exit $ac_status); }; }; then
8153 cf_cv_posix_c_source=no
8155 echo "$as_me: failed program was:" >&5
8156 cat conftest.$ac_ext >&5
8157 cf_want_posix_source=no
8158 case .$cf_POSIX_C_SOURCE in #(vi
8160 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
8163 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
8164 cf_want_posix_source=yes
8167 cf_want_posix_source=yes
8170 if test "$cf_want_posix_source" = yes ; then
8171 cat >conftest.$ac_ext <<_ACEOF
8172 #line 8172 "configure"
8173 #include "confdefs.h"
8174 #include <sys/types.h>
8179 #ifdef _POSIX_SOURCE
8186 rm -f conftest.$ac_objext
8187 if { (eval echo "$as_me:8187: \"$ac_compile\"") >&5
8188 (eval $ac_compile) 2>&5
8190 echo "$as_me:8190: \$? = $ac_status" >&5
8191 (exit $ac_status); } &&
8192 { ac_try='test -s conftest.$ac_objext'
8193 { (eval echo "$as_me:8193: \"$ac_try\"") >&5
8196 echo "$as_me:8196: \$? = $ac_status" >&5
8197 (exit $ac_status); }; }; then
8200 echo "$as_me: failed program was:" >&5
8201 cat conftest.$ac_ext >&5
8202 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
8204 rm -f conftest.$ac_objext conftest.$ac_ext
8207 echo "${as_me:-configure}:8207: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
8209 CFLAGS="$cf_trim_CFLAGS"
8210 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
8212 echo "${as_me:-configure}:8212: testing if the second compile does not leave our definition intact error ..." 1>&5
8214 cat >conftest.$ac_ext <<_ACEOF
8215 #line 8215 "configure"
8216 #include "confdefs.h"
8217 #include <sys/types.h>
8222 #ifndef _POSIX_C_SOURCE
8229 rm -f conftest.$ac_objext
8230 if { (eval echo "$as_me:8230: \"$ac_compile\"") >&5
8231 (eval $ac_compile) 2>&5
8233 echo "$as_me:8233: \$? = $ac_status" >&5
8234 (exit $ac_status); } &&
8235 { ac_try='test -s conftest.$ac_objext'
8236 { (eval echo "$as_me:8236: \"$ac_try\"") >&5
8239 echo "$as_me:8239: \$? = $ac_status" >&5
8240 (exit $ac_status); }; }; then
8243 echo "$as_me: failed program was:" >&5
8244 cat conftest.$ac_ext >&5
8245 cf_cv_posix_c_source=no
8247 rm -f conftest.$ac_objext conftest.$ac_ext
8248 CFLAGS="$cf_save_CFLAGS"
8249 CPPFLAGS="$cf_save_CPPFLAGS"
8252 rm -f conftest.$ac_objext conftest.$ac_ext
8255 echo "$as_me:8255: result: $cf_cv_posix_c_source" >&5
8256 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
8258 if test "$cf_cv_posix_c_source" != no ; then
8259 CFLAGS="$cf_trim_CFLAGS"
8260 CPPFLAGS="$cf_trim_CPPFLAGS"
8265 cf_new_extra_cppflags=
8267 for cf_add_cflags in $cf_cv_posix_c_source
8269 case $cf_fix_cppflags in
8271 case $cf_add_cflags in #(vi
8272 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
8273 case $cf_add_cflags in
8275 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
8277 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
8278 && test -z "${cf_tst_cflags}" \
8279 && cf_fix_cppflags=yes
8281 if test $cf_fix_cppflags = yes ; then
8282 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
8284 elif test "${cf_tst_cflags}" = "\"'" ; then
8285 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
8291 *$cf_add_cflags) #(vi
8294 case $cf_add_cflags in #(vi
8296 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
8298 CPPFLAGS=`echo "$CPPFLAGS" | \
8299 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
8300 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
8304 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
8309 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
8314 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
8316 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
8318 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
8319 && test -z "${cf_tst_cflags}" \
8320 && cf_fix_cppflags=no
8325 if test -n "$cf_new_cflags" ; then
8327 CFLAGS="$CFLAGS $cf_new_cflags"
8330 if test -n "$cf_new_cppflags" ; then
8332 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
8335 if test -n "$cf_new_extra_cppflags" ; then
8337 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
8345 if test -n "$cf_xopen_source" ; then
8350 cf_new_extra_cppflags=
8352 for cf_add_cflags in $cf_xopen_source
8354 case $cf_fix_cppflags in
8356 case $cf_add_cflags in #(vi
8357 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
8358 case $cf_add_cflags in
8360 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
8362 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
8363 && test -z "${cf_tst_cflags}" \
8364 && cf_fix_cppflags=yes
8366 if test $cf_fix_cppflags = yes ; then
8367 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
8369 elif test "${cf_tst_cflags}" = "\"'" ; then
8370 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
8376 *$cf_add_cflags) #(vi
8379 case $cf_add_cflags in #(vi
8381 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
8383 CPPFLAGS=`echo "$CPPFLAGS" | \
8384 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
8385 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
8389 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
8394 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
8399 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
8401 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
8403 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
8404 && test -z "${cf_tst_cflags}" \
8405 && cf_fix_cppflags=no
8410 if test -n "$cf_new_cflags" ; then
8412 CFLAGS="$CFLAGS $cf_new_cflags"
8415 if test -n "$cf_new_cppflags" ; then
8417 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
8420 if test -n "$cf_new_extra_cppflags" ; then
8422 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
8427 # Check whether --enable-largefile or --disable-largefile was given.
8428 if test "${enable_largefile+set}" = set; then
8429 enableval="$enable_largefile"
8432 if test "$enable_largefile" != no; then
8434 echo "$as_me:8434: checking for special C compiler options needed for large files" >&5
8435 echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
8436 if test "${ac_cv_sys_largefile_CC+set}" = set; then
8437 echo $ECHO_N "(cached) $ECHO_C" >&6
8439 ac_cv_sys_largefile_CC=no
8440 if test "$GCC" != yes; then
8443 # IRIX 6.2 and later do not support large files by default,
8444 # so use the C compiler's -n32 option if that helps.
8445 cat >conftest.$ac_ext <<_ACEOF
8446 #line 8446 "configure"
8447 #include "confdefs.h"
8448 #include <sys/types.h>
8449 /* Check that off_t can represent 2**63 - 1 correctly.
8450 We can't simply define LARGE_OFF_T to be 9223372036854775807,
8451 since some C++ compilers masquerading as C compilers
8452 incorrectly reject 9223372036854775807. */
8453 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
8454 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
8455 && LARGE_OFF_T % 2147483647 == 1)
8465 rm -f conftest.$ac_objext
8466 if { (eval echo "$as_me:8466: \"$ac_compile\"") >&5
8467 (eval $ac_compile) 2>&5
8469 echo "$as_me:8469: \$? = $ac_status" >&5
8470 (exit $ac_status); } &&
8471 { ac_try='test -s conftest.$ac_objext'
8472 { (eval echo "$as_me:8472: \"$ac_try\"") >&5
8475 echo "$as_me:8475: \$? = $ac_status" >&5
8476 (exit $ac_status); }; }; then
8479 echo "$as_me: failed program was:" >&5
8480 cat conftest.$ac_ext >&5
8482 rm -f conftest.$ac_objext
8484 rm -f conftest.$ac_objext
8485 if { (eval echo "$as_me:8485: \"$ac_compile\"") >&5
8486 (eval $ac_compile) 2>&5
8488 echo "$as_me:8488: \$? = $ac_status" >&5
8489 (exit $ac_status); } &&
8490 { ac_try='test -s conftest.$ac_objext'
8491 { (eval echo "$as_me:8491: \"$ac_try\"") >&5
8494 echo "$as_me:8494: \$? = $ac_status" >&5
8495 (exit $ac_status); }; }; then
8496 ac_cv_sys_largefile_CC=' -n32'; break
8498 echo "$as_me: failed program was:" >&5
8499 cat conftest.$ac_ext >&5
8501 rm -f conftest.$ac_objext
8505 rm -f conftest.$ac_ext
8508 echo "$as_me:8508: result: $ac_cv_sys_largefile_CC" >&5
8509 echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
8510 if test "$ac_cv_sys_largefile_CC" != no; then
8511 CC=$CC$ac_cv_sys_largefile_CC
8514 echo "$as_me:8514: checking for _FILE_OFFSET_BITS value needed for large files" >&5
8515 echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
8516 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
8517 echo $ECHO_N "(cached) $ECHO_C" >&6
8520 ac_cv_sys_file_offset_bits=no
8521 cat >conftest.$ac_ext <<_ACEOF
8522 #line 8522 "configure"
8523 #include "confdefs.h"
8524 #include <sys/types.h>
8525 /* Check that off_t can represent 2**63 - 1 correctly.
8526 We can't simply define LARGE_OFF_T to be 9223372036854775807,
8527 since some C++ compilers masquerading as C compilers
8528 incorrectly reject 9223372036854775807. */
8529 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
8530 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
8531 && LARGE_OFF_T % 2147483647 == 1)
8541 rm -f conftest.$ac_objext
8542 if { (eval echo "$as_me:8542: \"$ac_compile\"") >&5
8543 (eval $ac_compile) 2>&5
8545 echo "$as_me:8545: \$? = $ac_status" >&5
8546 (exit $ac_status); } &&
8547 { ac_try='test -s conftest.$ac_objext'
8548 { (eval echo "$as_me:8548: \"$ac_try\"") >&5
8551 echo "$as_me:8551: \$? = $ac_status" >&5
8552 (exit $ac_status); }; }; then
8555 echo "$as_me: failed program was:" >&5
8556 cat conftest.$ac_ext >&5
8558 rm -f conftest.$ac_objext conftest.$ac_ext
8559 cat >conftest.$ac_ext <<_ACEOF
8560 #line 8560 "configure"
8561 #include "confdefs.h"
8562 #define _FILE_OFFSET_BITS 64
8563 #include <sys/types.h>
8564 /* Check that off_t can represent 2**63 - 1 correctly.
8565 We can't simply define LARGE_OFF_T to be 9223372036854775807,
8566 since some C++ compilers masquerading as C compilers
8567 incorrectly reject 9223372036854775807. */
8568 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
8569 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
8570 && LARGE_OFF_T % 2147483647 == 1)
8580 rm -f conftest.$ac_objext
8581 if { (eval echo "$as_me:8581: \"$ac_compile\"") >&5
8582 (eval $ac_compile) 2>&5
8584 echo "$as_me:8584: \$? = $ac_status" >&5
8585 (exit $ac_status); } &&
8586 { ac_try='test -s conftest.$ac_objext'
8587 { (eval echo "$as_me:8587: \"$ac_try\"") >&5
8590 echo "$as_me:8590: \$? = $ac_status" >&5
8591 (exit $ac_status); }; }; then
8592 ac_cv_sys_file_offset_bits=64; break
8594 echo "$as_me: failed program was:" >&5
8595 cat conftest.$ac_ext >&5
8597 rm -f conftest.$ac_objext conftest.$ac_ext
8601 echo "$as_me:8601: result: $ac_cv_sys_file_offset_bits" >&5
8602 echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
8603 if test "$ac_cv_sys_file_offset_bits" != no; then
8605 cat >>confdefs.h <<EOF
8606 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
8611 echo "$as_me:8611: checking for _LARGE_FILES value needed for large files" >&5
8612 echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
8613 if test "${ac_cv_sys_large_files+set}" = set; then
8614 echo $ECHO_N "(cached) $ECHO_C" >&6
8617 ac_cv_sys_large_files=no
8618 cat >conftest.$ac_ext <<_ACEOF
8619 #line 8619 "configure"
8620 #include "confdefs.h"
8621 #include <sys/types.h>
8622 /* Check that off_t can represent 2**63 - 1 correctly.
8623 We can't simply define LARGE_OFF_T to be 9223372036854775807,
8624 since some C++ compilers masquerading as C compilers
8625 incorrectly reject 9223372036854775807. */
8626 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
8627 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
8628 && LARGE_OFF_T % 2147483647 == 1)
8638 rm -f conftest.$ac_objext
8639 if { (eval echo "$as_me:8639: \"$ac_compile\"") >&5
8640 (eval $ac_compile) 2>&5
8642 echo "$as_me:8642: \$? = $ac_status" >&5
8643 (exit $ac_status); } &&
8644 { ac_try='test -s conftest.$ac_objext'
8645 { (eval echo "$as_me:8645: \"$ac_try\"") >&5
8648 echo "$as_me:8648: \$? = $ac_status" >&5
8649 (exit $ac_status); }; }; then
8652 echo "$as_me: failed program was:" >&5
8653 cat conftest.$ac_ext >&5
8655 rm -f conftest.$ac_objext conftest.$ac_ext
8656 cat >conftest.$ac_ext <<_ACEOF
8657 #line 8657 "configure"
8658 #include "confdefs.h"
8659 #define _LARGE_FILES 1
8660 #include <sys/types.h>
8661 /* Check that off_t can represent 2**63 - 1 correctly.
8662 We can't simply define LARGE_OFF_T to be 9223372036854775807,
8663 since some C++ compilers masquerading as C compilers
8664 incorrectly reject 9223372036854775807. */
8665 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
8666 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
8667 && LARGE_OFF_T % 2147483647 == 1)
8677 rm -f conftest.$ac_objext
8678 if { (eval echo "$as_me:8678: \"$ac_compile\"") >&5
8679 (eval $ac_compile) 2>&5
8681 echo "$as_me:8681: \$? = $ac_status" >&5
8682 (exit $ac_status); } &&
8683 { ac_try='test -s conftest.$ac_objext'
8684 { (eval echo "$as_me:8684: \"$ac_try\"") >&5
8687 echo "$as_me:8687: \$? = $ac_status" >&5
8688 (exit $ac_status); }; }; then
8689 ac_cv_sys_large_files=1; break
8691 echo "$as_me: failed program was:" >&5
8692 cat conftest.$ac_ext >&5
8694 rm -f conftest.$ac_objext conftest.$ac_ext
8698 echo "$as_me:8698: result: $ac_cv_sys_large_files" >&5
8699 echo "${ECHO_T}$ac_cv_sys_large_files" >&6
8700 if test "$ac_cv_sys_large_files" != no; then
8702 cat >>confdefs.h <<EOF
8703 #define _LARGE_FILES $ac_cv_sys_large_files
8710 if test "$enable_largefile" != no ; then
8711 echo "$as_me:8711: checking for _LARGEFILE_SOURCE value needed for large files" >&5
8712 echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
8713 if test "${ac_cv_sys_largefile_source+set}" = set; then
8714 echo $ECHO_N "(cached) $ECHO_C" >&6
8717 ac_cv_sys_largefile_source=no
8718 cat >conftest.$ac_ext <<_ACEOF
8719 #line 8719 "configure"
8720 #include "confdefs.h"
8730 rm -f conftest.$ac_objext
8731 if { (eval echo "$as_me:8731: \"$ac_compile\"") >&5
8732 (eval $ac_compile) 2>&5
8734 echo "$as_me:8734: \$? = $ac_status" >&5
8735 (exit $ac_status); } &&
8736 { ac_try='test -s conftest.$ac_objext'
8737 { (eval echo "$as_me:8737: \"$ac_try\"") >&5
8740 echo "$as_me:8740: \$? = $ac_status" >&5
8741 (exit $ac_status); }; }; then
8744 echo "$as_me: failed program was:" >&5
8745 cat conftest.$ac_ext >&5
8747 rm -f conftest.$ac_objext conftest.$ac_ext
8748 cat >conftest.$ac_ext <<_ACEOF
8749 #line 8749 "configure"
8750 #include "confdefs.h"
8751 #define _LARGEFILE_SOURCE 1
8761 rm -f conftest.$ac_objext
8762 if { (eval echo "$as_me:8762: \"$ac_compile\"") >&5
8763 (eval $ac_compile) 2>&5
8765 echo "$as_me:8765: \$? = $ac_status" >&5
8766 (exit $ac_status); } &&
8767 { ac_try='test -s conftest.$ac_objext'
8768 { (eval echo "$as_me:8768: \"$ac_try\"") >&5
8771 echo "$as_me:8771: \$? = $ac_status" >&5
8772 (exit $ac_status); }; }; then
8773 ac_cv_sys_largefile_source=1; break
8775 echo "$as_me: failed program was:" >&5
8776 cat conftest.$ac_ext >&5
8778 rm -f conftest.$ac_objext conftest.$ac_ext
8782 echo "$as_me:8782: result: $ac_cv_sys_largefile_source" >&5
8783 echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
8784 if test "$ac_cv_sys_largefile_source" != no; then
8786 cat >>confdefs.h <<EOF
8787 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
8793 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
8794 # in glibc 2.1.3, but that breaks too many other things.
8795 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
8796 echo "$as_me:8796: checking for fseeko" >&5
8797 echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
8798 if test "${ac_cv_func_fseeko+set}" = set; then
8799 echo $ECHO_N "(cached) $ECHO_C" >&6
8801 cat >conftest.$ac_ext <<_ACEOF
8802 #line 8802 "configure"
8803 #include "confdefs.h"
8808 return fseeko && fseeko (stdin, 0, 0);
8813 rm -f conftest.$ac_objext conftest$ac_exeext
8814 if { (eval echo "$as_me:8814: \"$ac_link\"") >&5
8815 (eval $ac_link) 2>&5
8817 echo "$as_me:8817: \$? = $ac_status" >&5
8818 (exit $ac_status); } &&
8819 { ac_try='test -s conftest$ac_exeext'
8820 { (eval echo "$as_me:8820: \"$ac_try\"") >&5
8823 echo "$as_me:8823: \$? = $ac_status" >&5
8824 (exit $ac_status); }; }; then
8825 ac_cv_func_fseeko=yes
8827 echo "$as_me: failed program was:" >&5
8828 cat conftest.$ac_ext >&5
8829 ac_cv_func_fseeko=no
8831 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8833 echo "$as_me:8833: result: $ac_cv_func_fseeko" >&5
8834 echo "${ECHO_T}$ac_cv_func_fseeko" >&6
8835 if test $ac_cv_func_fseeko = yes; then
8837 cat >>confdefs.h <<\EOF
8838 #define HAVE_FSEEKO 1
8843 # Normally we would collect these definitions in the config.h,
8844 # but (like _XOPEN_SOURCE), some environments rely on having these
8845 # defined before any of the system headers are included. Another
8846 # case comes up with C++, e.g., on AIX the compiler compiles the
8847 # header files by themselves before looking at the body files it is
8848 # told to compile. For ncurses, those header files do not include
8850 test "$ac_cv_sys_large_files" != no && CPPFLAGS="$CPPFLAGS -D_LARGE_FILES "
8851 test "$ac_cv_sys_largefile_source" != no && CPPFLAGS="$CPPFLAGS -D_LARGEFILE_SOURCE "
8852 test "$ac_cv_sys_file_offset_bits" != no && CPPFLAGS="$CPPFLAGS -D_FILE_OFFSET_BITS=$ac_cv_sys_file_offset_bits "
8854 echo "$as_me:8854: checking whether to use struct dirent64" >&5
8855 echo $ECHO_N "checking whether to use struct dirent64... $ECHO_C" >&6
8856 if test "${cf_cv_struct_dirent64+set}" = set; then
8857 echo $ECHO_N "(cached) $ECHO_C" >&6
8860 cat >conftest.$ac_ext <<_ACEOF
8861 #line 8861 "configure"
8862 #include "confdefs.h"
8864 #include <sys/types.h>
8871 /* if transitional largefile support is setup, this is true */
8872 extern struct dirent64 * readdir(DIR *);
8873 struct dirent64 *x = readdir((DIR *)0);
8874 struct dirent *y = readdir((DIR *)0);
8881 rm -f conftest.$ac_objext
8882 if { (eval echo "$as_me:8882: \"$ac_compile\"") >&5
8883 (eval $ac_compile) 2>&5
8885 echo "$as_me:8885: \$? = $ac_status" >&5
8886 (exit $ac_status); } &&
8887 { ac_try='test -s conftest.$ac_objext'
8888 { (eval echo "$as_me:8888: \"$ac_try\"") >&5
8891 echo "$as_me:8891: \$? = $ac_status" >&5
8892 (exit $ac_status); }; }; then
8893 cf_cv_struct_dirent64=yes
8895 echo "$as_me: failed program was:" >&5
8896 cat conftest.$ac_ext >&5
8897 cf_cv_struct_dirent64=no
8899 rm -f conftest.$ac_objext conftest.$ac_ext
8902 echo "$as_me:8902: result: $cf_cv_struct_dirent64" >&5
8903 echo "${ECHO_T}$cf_cv_struct_dirent64" >&6
8904 test "$cf_cv_struct_dirent64" = yes && cat >>confdefs.h <<\EOF
8905 #define HAVE_STRUCT_DIRENT64 1
8910 ### Enable compiling-in rcs id's
8911 echo "$as_me:8911: checking if RCS identifiers should be compiled-in" >&5
8912 echo $ECHO_N "checking if RCS identifiers should be compiled-in... $ECHO_C" >&6
8914 # Check whether --with-rcs-ids or --without-rcs-ids was given.
8915 if test "${with_rcs_ids+set}" = set; then
8916 withval="$with_rcs_ids"
8917 with_rcs_ids=$withval
8921 echo "$as_me:8921: result: $with_rcs_ids" >&5
8922 echo "${ECHO_T}$with_rcs_ids" >&6
8923 test "$with_rcs_ids" = yes && cat >>confdefs.h <<\EOF
8924 #define USE_RCS_IDS 1
8927 ###############################################################################
8929 ### Note that some functions (such as const) are normally disabled anyway.
8930 echo "$as_me:8930: checking if you want to build with function extensions" >&5
8931 echo $ECHO_N "checking if you want to build with function extensions... $ECHO_C" >&6
8933 # Check whether --enable-ext-funcs or --disable-ext-funcs was given.
8934 if test "${enable_ext_funcs+set}" = set; then
8935 enableval="$enable_ext_funcs"
8936 with_ext_funcs=$enableval
8940 echo "$as_me:8940: result: $with_ext_funcs" >&5
8941 echo "${ECHO_T}$with_ext_funcs" >&6
8942 if test "$with_ext_funcs" = yes ; then
8944 cat >>confdefs.h <<\EOF
8945 #define HAVE_USE_DEFAULT_COLORS 1
8948 cat >>confdefs.h <<\EOF
8949 #define NCURSES_EXT_FUNCS 1
8956 ### use option --enable-const to turn on use of const beyond that in XSI.
8957 echo "$as_me:8957: checking for extended use of const keyword" >&5
8958 echo $ECHO_N "checking for extended use of const keyword... $ECHO_C" >&6
8960 # Check whether --enable-const or --disable-const was given.
8961 if test "${enable_const+set}" = set; then
8962 enableval="$enable_const"
8963 with_ext_const=$enableval
8967 echo "$as_me:8967: result: $with_ext_const" >&5
8968 echo "${ECHO_T}$with_ext_const" >&6
8969 NCURSES_CONST='/*nothing*/'
8970 if test "$with_ext_const" = yes ; then
8974 ###############################################################################
8975 # These options are relatively safe to experiment with.
8977 echo "$as_me:8977: checking if you want all development code" >&5
8978 echo $ECHO_N "checking if you want all development code... $ECHO_C" >&6
8980 # Check whether --with-develop or --without-develop was given.
8981 if test "${with_develop+set}" = set; then
8982 withval="$with_develop"
8983 with_develop=$withval
8987 echo "$as_me:8987: result: $with_develop" >&5
8988 echo "${ECHO_T}$with_develop" >&6
8990 ###############################################################################
8991 # These are just experimental, probably should not be in a package:
8993 # This is still experimental (20080329), but should ultimately be moved to
8994 # the script-block --with-normal, etc.
8996 echo "$as_me:8996: checking if you want to link with the pthread library" >&5
8997 echo $ECHO_N "checking if you want to link with the pthread library... $ECHO_C" >&6
8999 # Check whether --with-pthread or --without-pthread was given.
9000 if test "${with_pthread+set}" = set; then
9001 withval="$with_pthread"
9002 with_pthread=$withval
9006 echo "$as_me:9006: result: $with_pthread" >&5
9007 echo "${ECHO_T}$with_pthread" >&6
9009 if test "$with_pthread" != no ; then
9010 echo "$as_me:9010: checking for pthread.h" >&5
9011 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
9012 if test "${ac_cv_header_pthread_h+set}" = set; then
9013 echo $ECHO_N "(cached) $ECHO_C" >&6
9015 cat >conftest.$ac_ext <<_ACEOF
9016 #line 9016 "configure"
9017 #include "confdefs.h"
9018 #include <pthread.h>
9020 if { (eval echo "$as_me:9020: \"$ac_cpp conftest.$ac_ext\"") >&5
9021 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9023 egrep -v '^ *\+' conftest.er1 >conftest.err
9025 cat conftest.err >&5
9026 echo "$as_me:9026: \$? = $ac_status" >&5
9027 (exit $ac_status); } >/dev/null; then
9028 if test -s conftest.err; then
9029 ac_cpp_err=$ac_c_preproc_warn_flag
9036 if test -z "$ac_cpp_err"; then
9037 ac_cv_header_pthread_h=yes
9039 echo "$as_me: failed program was:" >&5
9040 cat conftest.$ac_ext >&5
9041 ac_cv_header_pthread_h=no
9043 rm -f conftest.err conftest.$ac_ext
9045 echo "$as_me:9045: result: $ac_cv_header_pthread_h" >&5
9046 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
9047 if test $ac_cv_header_pthread_h = yes; then
9049 cat >>confdefs.h <<\EOF
9050 #define HAVE_PTHREADS_H 1
9053 echo "$as_me:9053: checking if we can link with the pthread library" >&5
9054 echo $ECHO_N "checking if we can link with the pthread library... $ECHO_C" >&6
9055 cf_save_LIBS="$LIBS"
9056 LIBS="-lpthread $LIBS"
9057 cat >conftest.$ac_ext <<_ACEOF
9058 #line 9058 "configure"
9059 #include "confdefs.h"
9061 #include <pthread.h>
9067 int rc = pthread_create(0,0,0,0);
9073 rm -f conftest.$ac_objext conftest$ac_exeext
9074 if { (eval echo "$as_me:9074: \"$ac_link\"") >&5
9075 (eval $ac_link) 2>&5
9077 echo "$as_me:9077: \$? = $ac_status" >&5
9078 (exit $ac_status); } &&
9079 { ac_try='test -s conftest$ac_exeext'
9080 { (eval echo "$as_me:9080: \"$ac_try\"") >&5
9083 echo "$as_me:9083: \$? = $ac_status" >&5
9084 (exit $ac_status); }; }; then
9087 echo "$as_me: failed program was:" >&5
9088 cat conftest.$ac_ext >&5
9091 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9092 LIBS="$cf_save_LIBS"
9093 echo "$as_me:9093: result: $with_pthread" >&5
9094 echo "${ECHO_T}$with_pthread" >&6
9096 if test "$with_pthread" = yes ; then
9097 LIBS="-lpthread $LIBS"
9098 cat >>confdefs.h <<\EOF
9099 #define HAVE_LIBPTHREADS 1
9103 { { echo "$as_me:9103: error: Cannot link with pthread library" >&5
9104 echo "$as_me: error: Cannot link with pthread library" >&2;}
9105 { (exit 1); exit 1; }; }
9112 echo "$as_me:9112: checking if you want to use weak-symbols for pthreads" >&5
9113 echo $ECHO_N "checking if you want to use weak-symbols for pthreads... $ECHO_C" >&6
9115 # Check whether --enable-weak-symbols or --disable-weak-symbols was given.
9116 if test "${enable_weak_symbols+set}" = set; then
9117 enableval="$enable_weak_symbols"
9118 use_weak_symbols=$withval
9122 echo "$as_me:9122: result: $use_weak_symbols" >&5
9123 echo "${ECHO_T}$use_weak_symbols" >&6
9124 if test "$use_weak_symbols" = yes ; then
9126 echo "$as_me:9126: checking if $CC supports weak symbols" >&5
9127 echo $ECHO_N "checking if $CC supports weak symbols... $ECHO_C" >&6
9128 if test "${cf_cv_weak_symbols+set}" = set; then
9129 echo $ECHO_N "(cached) $ECHO_C" >&6
9132 cat >conftest.$ac_ext <<_ACEOF
9133 #line 9133 "configure"
9134 #include "confdefs.h"
9141 #if defined(__GNUC__)
9142 # if defined __USE_ISOC99
9143 # define _cat_pragma(exp) _Pragma(#exp)
9144 # define _weak_pragma(exp) _cat_pragma(weak name)
9146 # define _weak_pragma(exp)
9148 # define _declare(name) __extension__ extern __typeof__(name) name
9149 # define weak_symbol(name) _weak_pragma(name) _declare(name) __attribute__((weak))
9158 rm -f conftest.$ac_objext
9159 if { (eval echo "$as_me:9159: \"$ac_compile\"") >&5
9160 (eval $ac_compile) 2>&5
9162 echo "$as_me:9162: \$? = $ac_status" >&5
9163 (exit $ac_status); } &&
9164 { ac_try='test -s conftest.$ac_objext'
9165 { (eval echo "$as_me:9165: \"$ac_try\"") >&5
9168 echo "$as_me:9168: \$? = $ac_status" >&5
9169 (exit $ac_status); }; }; then
9170 cf_cv_weak_symbols=yes
9172 echo "$as_me: failed program was:" >&5
9173 cat conftest.$ac_ext >&5
9174 cf_cv_weak_symbols=no
9176 rm -f conftest.$ac_objext conftest.$ac_ext
9179 echo "$as_me:9179: result: $cf_cv_weak_symbols" >&5
9180 echo "${ECHO_T}$cf_cv_weak_symbols" >&6
9183 cf_cv_weak_symbols=no
9186 if test $cf_cv_weak_symbols = yes ; then
9187 cat >>confdefs.h <<\EOF
9188 #define USE_WEAK_SYMBOLS 1
9194 if test "$with_pthread" = "yes" ; then
9195 cat >>confdefs.h <<\EOF
9196 #define USE_PTHREADS 1
9199 enable_reentrant=yes
9200 if test $cf_cv_weak_symbols = yes ; then
9205 # OpenSUSE is installing ncurses6, using reentrant option.
9206 echo "$as_me:9206: checking for _nc_TABSIZE" >&5
9207 echo $ECHO_N "checking for _nc_TABSIZE... $ECHO_C" >&6
9208 if test "${ac_cv_func__nc_TABSIZE+set}" = set; then
9209 echo $ECHO_N "(cached) $ECHO_C" >&6
9211 cat >conftest.$ac_ext <<_ACEOF
9212 #line 9212 "configure"
9213 #include "confdefs.h"
9214 /* System header to define __stub macros and hopefully few prototypes,
9215 which can conflict with char _nc_TABSIZE (); below. */
9217 /* Override any gcc2 internal prototype to avoid an error. */
9221 /* We use char because int might match the return type of a gcc2
9222 builtin and then its argument prototype would still apply. */
9223 char _nc_TABSIZE ();
9229 /* The GNU C library defines this for functions which it implements
9230 to always fail with ENOSYS. Some functions are actually named
9231 something starting with __ and the normal name is an alias. */
9232 #if defined (__stub__nc_TABSIZE) || defined (__stub____nc_TABSIZE)
9242 rm -f conftest.$ac_objext conftest$ac_exeext
9243 if { (eval echo "$as_me:9243: \"$ac_link\"") >&5
9244 (eval $ac_link) 2>&5
9246 echo "$as_me:9246: \$? = $ac_status" >&5
9247 (exit $ac_status); } &&
9248 { ac_try='test -s conftest$ac_exeext'
9249 { (eval echo "$as_me:9249: \"$ac_try\"") >&5
9252 echo "$as_me:9252: \$? = $ac_status" >&5
9253 (exit $ac_status); }; }; then
9254 ac_cv_func__nc_TABSIZE=yes
9256 echo "$as_me: failed program was:" >&5
9257 cat conftest.$ac_ext >&5
9258 ac_cv_func__nc_TABSIZE=no
9260 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9262 echo "$as_me:9262: result: $ac_cv_func__nc_TABSIZE" >&5
9263 echo "${ECHO_T}$ac_cv_func__nc_TABSIZE" >&6
9264 if test $ac_cv_func__nc_TABSIZE = yes; then
9265 assume_reentrant=yes
9270 # Reentrant code has to be opaque; there's little advantage to making ncurses
9271 # opaque outside of that, so there is no --enable-opaque option. We can use
9272 # this option without --with-pthreads, but this will be always set for
9274 echo "$as_me:9274: checking if you want experimental reentrant code" >&5
9275 echo $ECHO_N "checking if you want experimental reentrant code... $ECHO_C" >&6
9277 # Check whether --enable-reentrant or --disable-reentrant was given.
9278 if test "${enable_reentrant+set}" = set; then
9279 enableval="$enable_reentrant"
9280 with_reentrant=$enableval
9282 with_reentrant=$assume_reentrant
9284 echo "$as_me:9284: result: $with_reentrant" >&5
9285 echo "${ECHO_T}$with_reentrant" >&6
9286 if test "$with_reentrant" = yes ; then
9287 cf_cv_enable_reentrant=1
9288 if test $cf_cv_weak_symbols = yes ; then
9290 # remove pthread library from $LIBS
9291 LIBS=`echo "$LIBS" | sed -e 's/-lpthread[ ]//g' -e 's/-lpthread$//'`
9293 elif test "$assume_reentrant" = no ; then
9294 LIB_SUFFIX="t${LIB_SUFFIX}"
9296 cat >>confdefs.h <<\EOF
9297 #define USE_REENTRANT 1
9301 cf_cv_enable_reentrant=0
9304 ### Allow using a different wrap-prefix
9305 if test "$cf_cv_enable_reentrant" != 0 || test "$BROKEN_LINKER" = 1 ; then
9306 echo "$as_me:9306: checking for prefix used to wrap public variables" >&5
9307 echo $ECHO_N "checking for prefix used to wrap public variables... $ECHO_C" >&6
9309 # Check whether --with-wrap-prefix or --without-wrap-prefix was given.
9310 if test "${with_wrap_prefix+set}" = set; then
9311 withval="$with_wrap_prefix"
9312 NCURSES_WRAP_PREFIX=$withval
9314 NCURSES_WRAP_PREFIX=_nc_
9316 echo "$as_me:9316: result: $NCURSES_WRAP_PREFIX" >&5
9317 echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
9319 NCURSES_WRAP_PREFIX=_nc_
9322 cat >>confdefs.h <<EOF
9323 #define NCURSES_WRAP_PREFIX "$NCURSES_WRAP_PREFIX"
9326 ###############################################################################
9328 ### use option --disable-echo to suppress full display compiling commands
9329 echo "$as_me:9329: checking if you want to display full commands during build" >&5
9330 echo $ECHO_N "checking if you want to display full commands during build... $ECHO_C" >&6
9332 # Check whether --enable-echo or --disable-echo was given.
9333 if test "${enable_echo+set}" = set; then
9334 enableval="$enable_echo"
9335 with_echo=$enableval
9339 if test "$with_echo" = yes; then
9342 ECHO_LINK='@ echo linking $@ ... ;'
9344 echo "$as_me:9344: result: $with_echo" >&5
9345 echo "${ECHO_T}$with_echo" >&6
9347 ### use option --enable-warnings to turn on all gcc warnings
9348 echo "$as_me:9348: checking if you want to see compiler warnings" >&5
9349 echo $ECHO_N "checking if you want to see compiler warnings... $ECHO_C" >&6
9351 # Check whether --enable-warnings or --disable-warnings was given.
9352 if test "${enable_warnings+set}" = set; then
9353 enableval="$enable_warnings"
9354 with_warnings=$enableval
9356 echo "$as_me:9356: result: $with_warnings" >&5
9357 echo "${ECHO_T}$with_warnings" >&6
9359 if test "x$with_warnings" = "xyes"; then
9361 ADAFLAGS="$ADAFLAGS -gnatg"
9365 if test "$GCC" = yes ; then
9368 echo "$as_me:9368: checking if this is really Intel C compiler" >&5
9369 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
9370 cf_save_CFLAGS="$CFLAGS"
9371 CFLAGS="$CFLAGS -no-gcc"
9372 cat >conftest.$ac_ext <<_ACEOF
9373 #line 9373 "configure"
9374 #include "confdefs.h"
9380 #ifdef __INTEL_COMPILER
9389 rm -f conftest.$ac_objext
9390 if { (eval echo "$as_me:9390: \"$ac_compile\"") >&5
9391 (eval $ac_compile) 2>&5
9393 echo "$as_me:9393: \$? = $ac_status" >&5
9394 (exit $ac_status); } &&
9395 { ac_try='test -s conftest.$ac_objext'
9396 { (eval echo "$as_me:9396: \"$ac_try\"") >&5
9399 echo "$as_me:9399: \$? = $ac_status" >&5
9400 (exit $ac_status); }; }; then
9402 cf_save_CFLAGS="$cf_save_CFLAGS -we147 -no-gcc"
9405 echo "$as_me: failed program was:" >&5
9406 cat conftest.$ac_ext >&5
9408 rm -f conftest.$ac_objext conftest.$ac_ext
9409 CFLAGS="$cf_save_CFLAGS"
9410 echo "$as_me:9410: result: $INTEL_COMPILER" >&5
9411 echo "${ECHO_T}$INTEL_COMPILER" >&6
9416 cat > conftest.$ac_ext <<EOF
9417 #line 9417 "${as_me:-configure}"
9418 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
9421 if test "$INTEL_COMPILER" = yes
9423 # The "-wdXXX" options suppress warnings:
9424 # remark #1419: external declaration in primary source file
9425 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
9426 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
9427 # remark #193: zero used for undefined preprocessing identifier
9428 # remark #593: variable "curs_sb_left_arrow" was set but never used
9429 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
9430 # remark #869: parameter "tw" was never referenced
9431 # remark #981: operands are evaluated in unspecified order
9432 # warning #279: controlling expression is constant
9434 { echo "$as_me:9434: checking for $CC warning options..." >&5
9435 echo "$as_me: checking for $CC warning options..." >&6;}
9436 cf_save_CFLAGS="$CFLAGS"
9437 EXTRA_CFLAGS="-Wall"
9449 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
9450 if { (eval echo "$as_me:9450: \"$ac_compile\"") >&5
9451 (eval $ac_compile) 2>&5
9453 echo "$as_me:9453: \$? = $ac_status" >&5
9454 (exit $ac_status); }; then
9455 test -n "$verbose" && echo "$as_me:9455: result: ... -$cf_opt" >&5
9456 echo "${ECHO_T}... -$cf_opt" >&6
9457 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
9460 CFLAGS="$cf_save_CFLAGS"
9462 elif test "$GCC" = yes
9464 { echo "$as_me:9464: checking for $CC warning options..." >&5
9465 echo "$as_me: checking for $CC warning options..." >&6;}
9466 cf_save_CFLAGS="$CFLAGS"
9469 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
9470 for cf_opt in W Wall \
9471 Wbad-function-cast \
9475 Wmissing-declarations \
9476 Wmissing-prototypes \
9480 Wstrict-prototypes \
9481 Wundef $cf_warn_CONST Wdeclaration-after-statement Wextra Wno-unknown-pragmas Wswitch-enum
9483 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
9484 if { (eval echo "$as_me:9484: \"$ac_compile\"") >&5
9485 (eval $ac_compile) 2>&5
9487 echo "$as_me:9487: \$? = $ac_status" >&5
9488 (exit $ac_status); }; then
9489 test -n "$verbose" && echo "$as_me:9489: result: ... -$cf_opt" >&5
9490 echo "${ECHO_T}... -$cf_opt" >&6
9491 case $cf_opt in #(vi
9493 CPPFLAGS="$CPPFLAGS -DXTSTRINGDEFINES"
9496 case $GCC_VERSION in
9498 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
9500 echo "${as_me:-configure}:9500: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
9506 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
9509 CFLAGS="$cf_save_CFLAGS"
9515 if test "$GCC" = yes
9517 cat > conftest.i <<EOF
9519 #define GCC_PRINTF 0
9524 #ifndef GCC_NORETURN
9525 #define GCC_NORETURN /* nothing */
9528 #define GCC_UNUSED /* nothing */
9531 if test "$GCC" = yes
9533 { echo "$as_me:9533: checking for $CC __attribute__ directives..." >&5
9534 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
9535 cat > conftest.$ac_ext <<EOF
9536 #line 9536 "${as_me:-configure}"
9537 #include "confdefs.h"
9538 #include "conftest.h"
9539 #include "conftest.i"
9541 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
9543 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
9546 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
9548 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
9550 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
9551 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
9552 extern void foo(void) GCC_NORETURN;
9553 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
9555 cf_printf_attribute=no
9556 cf_scanf_attribute=no
9557 for cf_attribute in scanf printf unused noreturn
9560 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
9562 cf_directive="__attribute__(($cf_attribute))"
9563 echo "checking for $CC $cf_directive" 1>&5
9565 case $cf_attribute in #(vi
9567 cf_printf_attribute=yes
9568 cat >conftest.h <<EOF
9569 #define GCC_$cf_ATTRIBUTE 1
9573 cf_scanf_attribute=yes
9574 cat >conftest.h <<EOF
9575 #define GCC_$cf_ATTRIBUTE 1
9579 cat >conftest.h <<EOF
9580 #define GCC_$cf_ATTRIBUTE $cf_directive
9585 if { (eval echo "$as_me:9585: \"$ac_compile\"") >&5
9586 (eval $ac_compile) 2>&5
9588 echo "$as_me:9588: \$? = $ac_status" >&5
9589 (exit $ac_status); }; then
9590 test -n "$verbose" && echo "$as_me:9590: result: ... $cf_attribute" >&5
9591 echo "${ECHO_T}... $cf_attribute" >&6
9592 cat conftest.h >>confdefs.h
9593 case $cf_attribute in #(vi
9595 if test "$cf_printf_attribute" = no ; then
9596 cat >>confdefs.h <<EOF
9597 #define GCC_PRINTFLIKE(fmt,var) /* nothing */
9600 cat >>confdefs.h <<EOF
9601 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
9606 if test "$cf_scanf_attribute" = no ; then
9607 cat >>confdefs.h <<EOF
9608 #define GCC_SCANFLIKE(fmt,var) /* nothing */
9611 cat >>confdefs.h <<EOF
9612 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
9620 fgrep define conftest.i >>confdefs.h
9625 ### use option --enable-assertions to turn on generation of assertion code
9626 echo "$as_me:9626: checking if you want to enable runtime assertions" >&5
9627 echo $ECHO_N "checking if you want to enable runtime assertions... $ECHO_C" >&6
9629 # Check whether --enable-assertions or --disable-assertions was given.
9630 if test "${enable_assertions+set}" = set; then
9631 enableval="$enable_assertions"
9632 with_assertions=$enableval
9636 echo "$as_me:9636: result: $with_assertions" >&5
9637 echo "${ECHO_T}$with_assertions" >&6
9640 if test "$with_assertions" = no
9642 cat >>confdefs.h <<\EOF
9646 CPPFLAGS="$CPPFLAGS -DNDEBUG"
9649 ADAFLAGS="$ADAFLAGS -gnata"
9654 ### use option --disable-leaks to suppress "permanent" leaks, for testing
9655 cat >>confdefs.h <<\EOF
9656 #define HAVE_NC_ALLOC_H 1
9659 ### use option --enable-expanded to generate certain macros as functions
9661 # Check whether --enable-expanded or --disable-expanded was given.
9662 if test "${enable_expanded+set}" = set; then
9663 enableval="$enable_expanded"
9664 test "$enableval" = yes && cat >>confdefs.h <<\EOF
9665 #define NCURSES_EXPANDED 1
9670 ### use option --disable-macros to suppress macros in favor of functions
9672 # Check whether --enable-macros or --disable-macros was given.
9673 if test "${enable_macros+set}" = set; then
9674 enableval="$enable_macros"
9675 test "$enableval" = no && cat >>confdefs.h <<\EOF
9676 #define NCURSES_NOMACROS 1
9681 # Normally we only add trace() to the debug-library. Allow this to be
9682 # extended to all models of the ncurses library:
9684 case "$CFLAGS $CPPFLAGS" in
9690 echo "$as_me:9690: checking whether to add trace feature to all models" >&5
9691 echo $ECHO_N "checking whether to add trace feature to all models... $ECHO_C" >&6
9693 # Check whether --with-trace or --without-trace was given.
9694 if test "${with_trace+set}" = set; then
9695 withval="$with_trace"
9696 cf_with_trace=$withval
9698 cf_with_trace=$cf_all_traces
9700 echo "$as_me:9700: result: $cf_with_trace" >&5
9701 echo "${ECHO_T}$cf_with_trace" >&6
9703 if test "$cf_with_trace" = yes ; then
9709 cf_new_extra_cppflags=
9711 for cf_add_cflags in -DTRACE
9713 case $cf_fix_cppflags in
9715 case $cf_add_cflags in #(vi
9716 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
9717 case $cf_add_cflags in
9719 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
9721 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
9722 && test -z "${cf_tst_cflags}" \
9723 && cf_fix_cppflags=yes
9725 if test $cf_fix_cppflags = yes ; then
9726 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
9728 elif test "${cf_tst_cflags}" = "\"'" ; then
9729 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
9735 *$cf_add_cflags) #(vi
9738 case $cf_add_cflags in #(vi
9740 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
9742 CPPFLAGS=`echo "$CPPFLAGS" | \
9743 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
9744 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
9748 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
9753 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
9758 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
9760 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
9762 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
9763 && test -z "${cf_tst_cflags}" \
9764 && cf_fix_cppflags=no
9769 if test -n "$cf_new_cflags" ; then
9771 CFLAGS="$CFLAGS $cf_new_cflags"
9774 if test -n "$cf_new_cppflags" ; then
9776 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
9779 if test -n "$cf_new_extra_cppflags" ; then
9781 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
9788 ### Checks for libraries.
9789 case $cf_cv_system_name in #(vi
9793 echo "$as_me:9793: checking for gettimeofday" >&5
9794 echo $ECHO_N "checking for gettimeofday... $ECHO_C" >&6
9795 if test "${ac_cv_func_gettimeofday+set}" = set; then
9796 echo $ECHO_N "(cached) $ECHO_C" >&6
9798 cat >conftest.$ac_ext <<_ACEOF
9799 #line 9799 "configure"
9800 #include "confdefs.h"
9801 /* System header to define __stub macros and hopefully few prototypes,
9802 which can conflict with char gettimeofday (); below. */
9804 /* Override any gcc2 internal prototype to avoid an error. */
9808 /* We use char because int might match the return type of a gcc2
9809 builtin and then its argument prototype would still apply. */
9810 char gettimeofday ();
9816 /* The GNU C library defines this for functions which it implements
9817 to always fail with ENOSYS. Some functions are actually named
9818 something starting with __ and the normal name is an alias. */
9819 #if defined (__stub_gettimeofday) || defined (__stub___gettimeofday)
9829 rm -f conftest.$ac_objext conftest$ac_exeext
9830 if { (eval echo "$as_me:9830: \"$ac_link\"") >&5
9831 (eval $ac_link) 2>&5
9833 echo "$as_me:9833: \$? = $ac_status" >&5
9834 (exit $ac_status); } &&
9835 { ac_try='test -s conftest$ac_exeext'
9836 { (eval echo "$as_me:9836: \"$ac_try\"") >&5
9839 echo "$as_me:9839: \$? = $ac_status" >&5
9840 (exit $ac_status); }; }; then
9841 ac_cv_func_gettimeofday=yes
9843 echo "$as_me: failed program was:" >&5
9844 cat conftest.$ac_ext >&5
9845 ac_cv_func_gettimeofday=no
9847 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9849 echo "$as_me:9849: result: $ac_cv_func_gettimeofday" >&5
9850 echo "${ECHO_T}$ac_cv_func_gettimeofday" >&6
9851 if test $ac_cv_func_gettimeofday = yes; then
9852 cat >>confdefs.h <<\EOF
9853 #define HAVE_GETTIMEOFDAY 1
9858 echo "$as_me:9858: checking for gettimeofday in -lbsd" >&5
9859 echo $ECHO_N "checking for gettimeofday in -lbsd... $ECHO_C" >&6
9860 if test "${ac_cv_lib_bsd_gettimeofday+set}" = set; then
9861 echo $ECHO_N "(cached) $ECHO_C" >&6
9863 ac_check_lib_save_LIBS=$LIBS
9865 cat >conftest.$ac_ext <<_ACEOF
9866 #line 9866 "configure"
9867 #include "confdefs.h"
9869 /* Override any gcc2 internal prototype to avoid an error. */
9873 /* We use char because int might match the return type of a gcc2
9874 builtin and then its argument prototype would still apply. */
9875 char gettimeofday ();
9884 rm -f conftest.$ac_objext conftest$ac_exeext
9885 if { (eval echo "$as_me:9885: \"$ac_link\"") >&5
9886 (eval $ac_link) 2>&5
9888 echo "$as_me:9888: \$? = $ac_status" >&5
9889 (exit $ac_status); } &&
9890 { ac_try='test -s conftest$ac_exeext'
9891 { (eval echo "$as_me:9891: \"$ac_try\"") >&5
9894 echo "$as_me:9894: \$? = $ac_status" >&5
9895 (exit $ac_status); }; }; then
9896 ac_cv_lib_bsd_gettimeofday=yes
9898 echo "$as_me: failed program was:" >&5
9899 cat conftest.$ac_ext >&5
9900 ac_cv_lib_bsd_gettimeofday=no
9902 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9903 LIBS=$ac_check_lib_save_LIBS
9905 echo "$as_me:9905: result: $ac_cv_lib_bsd_gettimeofday" >&5
9906 echo "${ECHO_T}$ac_cv_lib_bsd_gettimeofday" >&6
9907 if test $ac_cv_lib_bsd_gettimeofday = yes; then
9908 cat >>confdefs.h <<\EOF
9909 #define HAVE_GETTIMEOFDAY 1
9919 ### Checks for header files.
9920 echo "$as_me:9920: checking for ANSI C header files" >&5
9921 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
9922 if test "${ac_cv_header_stdc+set}" = set; then
9923 echo $ECHO_N "(cached) $ECHO_C" >&6
9925 cat >conftest.$ac_ext <<_ACEOF
9926 #line 9926 "configure"
9927 #include "confdefs.h"
9934 if { (eval echo "$as_me:9934: \"$ac_cpp conftest.$ac_ext\"") >&5
9935 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9937 egrep -v '^ *\+' conftest.er1 >conftest.err
9939 cat conftest.err >&5
9940 echo "$as_me:9940: \$? = $ac_status" >&5
9941 (exit $ac_status); } >/dev/null; then
9942 if test -s conftest.err; then
9943 ac_cpp_err=$ac_c_preproc_warn_flag
9950 if test -z "$ac_cpp_err"; then
9951 ac_cv_header_stdc=yes
9953 echo "$as_me: failed program was:" >&5
9954 cat conftest.$ac_ext >&5
9955 ac_cv_header_stdc=no
9957 rm -f conftest.err conftest.$ac_ext
9959 if test $ac_cv_header_stdc = yes; then
9960 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
9961 cat >conftest.$ac_ext <<_ACEOF
9962 #line 9962 "configure"
9963 #include "confdefs.h"
9967 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9968 egrep "memchr" >/dev/null 2>&1; then
9971 ac_cv_header_stdc=no
9977 if test $ac_cv_header_stdc = yes; then
9978 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
9979 cat >conftest.$ac_ext <<_ACEOF
9980 #line 9980 "configure"
9981 #include "confdefs.h"
9985 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9986 egrep "free" >/dev/null 2>&1; then
9989 ac_cv_header_stdc=no
9995 if test $ac_cv_header_stdc = yes; then
9996 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
9997 if test "$cross_compiling" = yes; then
10000 cat >conftest.$ac_ext <<_ACEOF
10001 #line 10001 "configure"
10002 #include "confdefs.h"
10004 #if ((' ' & 0x0FF) == 0x020)
10005 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
10006 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
10008 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
10009 || ('j' <= (c) && (c) <= 'r') \
10010 || ('s' <= (c) && (c) <= 'z'))
10011 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
10014 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
10019 for (i = 0; i < 256; i++)
10020 if (XOR (islower (i), ISLOWER (i))
10021 || toupper (i) != TOUPPER (i))
10022 $ac_main_return(2);
10023 $ac_main_return (0);
10026 rm -f conftest$ac_exeext
10027 if { (eval echo "$as_me:10027: \"$ac_link\"") >&5
10028 (eval $ac_link) 2>&5
10030 echo "$as_me:10030: \$? = $ac_status" >&5
10031 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
10032 { (eval echo "$as_me:10032: \"$ac_try\"") >&5
10033 (eval $ac_try) 2>&5
10035 echo "$as_me:10035: \$? = $ac_status" >&5
10036 (exit $ac_status); }; }; then
10039 echo "$as_me: program exited with status $ac_status" >&5
10040 echo "$as_me: failed program was:" >&5
10041 cat conftest.$ac_ext >&5
10042 ac_cv_header_stdc=no
10044 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
10048 echo "$as_me:10048: result: $ac_cv_header_stdc" >&5
10049 echo "${ECHO_T}$ac_cv_header_stdc" >&6
10050 if test $ac_cv_header_stdc = yes; then
10052 cat >>confdefs.h <<\EOF
10053 #define STDC_HEADERS 1
10058 ac_header_dirent=no
10059 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
10060 as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
10061 echo "$as_me:10061: checking for $ac_hdr that defines DIR" >&5
10062 echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
10063 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10064 echo $ECHO_N "(cached) $ECHO_C" >&6
10066 cat >conftest.$ac_ext <<_ACEOF
10067 #line 10067 "configure"
10068 #include "confdefs.h"
10069 #include <sys/types.h>
10081 rm -f conftest.$ac_objext
10082 if { (eval echo "$as_me:10082: \"$ac_compile\"") >&5
10083 (eval $ac_compile) 2>&5
10085 echo "$as_me:10085: \$? = $ac_status" >&5
10086 (exit $ac_status); } &&
10087 { ac_try='test -s conftest.$ac_objext'
10088 { (eval echo "$as_me:10088: \"$ac_try\"") >&5
10089 (eval $ac_try) 2>&5
10091 echo "$as_me:10091: \$? = $ac_status" >&5
10092 (exit $ac_status); }; }; then
10093 eval "$as_ac_Header=yes"
10095 echo "$as_me: failed program was:" >&5
10096 cat conftest.$ac_ext >&5
10097 eval "$as_ac_Header=no"
10099 rm -f conftest.$ac_objext conftest.$ac_ext
10101 echo "$as_me:10101: result: `eval echo '${'$as_ac_Header'}'`" >&5
10102 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10103 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10104 cat >>confdefs.h <<EOF
10105 #define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
10108 ac_header_dirent=$ac_hdr; break
10112 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
10113 if test $ac_header_dirent = dirent.h; then
10114 echo "$as_me:10114: checking for opendir in -ldir" >&5
10115 echo $ECHO_N "checking for opendir in -ldir... $ECHO_C" >&6
10116 if test "${ac_cv_lib_dir_opendir+set}" = set; then
10117 echo $ECHO_N "(cached) $ECHO_C" >&6
10119 ac_check_lib_save_LIBS=$LIBS
10121 cat >conftest.$ac_ext <<_ACEOF
10122 #line 10122 "configure"
10123 #include "confdefs.h"
10125 /* Override any gcc2 internal prototype to avoid an error. */
10129 /* We use char because int might match the return type of a gcc2
10130 builtin and then its argument prototype would still apply. */
10140 rm -f conftest.$ac_objext conftest$ac_exeext
10141 if { (eval echo "$as_me:10141: \"$ac_link\"") >&5
10142 (eval $ac_link) 2>&5
10144 echo "$as_me:10144: \$? = $ac_status" >&5
10145 (exit $ac_status); } &&
10146 { ac_try='test -s conftest$ac_exeext'
10147 { (eval echo "$as_me:10147: \"$ac_try\"") >&5
10148 (eval $ac_try) 2>&5
10150 echo "$as_me:10150: \$? = $ac_status" >&5
10151 (exit $ac_status); }; }; then
10152 ac_cv_lib_dir_opendir=yes
10154 echo "$as_me: failed program was:" >&5
10155 cat conftest.$ac_ext >&5
10156 ac_cv_lib_dir_opendir=no
10158 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10159 LIBS=$ac_check_lib_save_LIBS
10161 echo "$as_me:10161: result: $ac_cv_lib_dir_opendir" >&5
10162 echo "${ECHO_T}$ac_cv_lib_dir_opendir" >&6
10163 if test $ac_cv_lib_dir_opendir = yes; then
10168 echo "$as_me:10168: checking for opendir in -lx" >&5
10169 echo $ECHO_N "checking for opendir in -lx... $ECHO_C" >&6
10170 if test "${ac_cv_lib_x_opendir+set}" = set; then
10171 echo $ECHO_N "(cached) $ECHO_C" >&6
10173 ac_check_lib_save_LIBS=$LIBS
10175 cat >conftest.$ac_ext <<_ACEOF
10176 #line 10176 "configure"
10177 #include "confdefs.h"
10179 /* Override any gcc2 internal prototype to avoid an error. */
10183 /* We use char because int might match the return type of a gcc2
10184 builtin and then its argument prototype would still apply. */
10194 rm -f conftest.$ac_objext conftest$ac_exeext
10195 if { (eval echo "$as_me:10195: \"$ac_link\"") >&5
10196 (eval $ac_link) 2>&5
10198 echo "$as_me:10198: \$? = $ac_status" >&5
10199 (exit $ac_status); } &&
10200 { ac_try='test -s conftest$ac_exeext'
10201 { (eval echo "$as_me:10201: \"$ac_try\"") >&5
10202 (eval $ac_try) 2>&5
10204 echo "$as_me:10204: \$? = $ac_status" >&5
10205 (exit $ac_status); }; }; then
10206 ac_cv_lib_x_opendir=yes
10208 echo "$as_me: failed program was:" >&5
10209 cat conftest.$ac_ext >&5
10210 ac_cv_lib_x_opendir=no
10212 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10213 LIBS=$ac_check_lib_save_LIBS
10215 echo "$as_me:10215: result: $ac_cv_lib_x_opendir" >&5
10216 echo "${ECHO_T}$ac_cv_lib_x_opendir" >&6
10217 if test $ac_cv_lib_x_opendir = yes; then
10223 echo "$as_me:10223: checking whether time.h and sys/time.h may both be included" >&5
10224 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
10225 if test "${ac_cv_header_time+set}" = set; then
10226 echo $ECHO_N "(cached) $ECHO_C" >&6
10228 cat >conftest.$ac_ext <<_ACEOF
10229 #line 10229 "configure"
10230 #include "confdefs.h"
10231 #include <sys/types.h>
10232 #include <sys/time.h>
10238 if ((struct tm *) 0)
10244 rm -f conftest.$ac_objext
10245 if { (eval echo "$as_me:10245: \"$ac_compile\"") >&5
10246 (eval $ac_compile) 2>&5
10248 echo "$as_me:10248: \$? = $ac_status" >&5
10249 (exit $ac_status); } &&
10250 { ac_try='test -s conftest.$ac_objext'
10251 { (eval echo "$as_me:10251: \"$ac_try\"") >&5
10252 (eval $ac_try) 2>&5
10254 echo "$as_me:10254: \$? = $ac_status" >&5
10255 (exit $ac_status); }; }; then
10256 ac_cv_header_time=yes
10258 echo "$as_me: failed program was:" >&5
10259 cat conftest.$ac_ext >&5
10260 ac_cv_header_time=no
10262 rm -f conftest.$ac_objext conftest.$ac_ext
10264 echo "$as_me:10264: result: $ac_cv_header_time" >&5
10265 echo "${ECHO_T}$ac_cv_header_time" >&6
10266 if test $ac_cv_header_time = yes; then
10268 cat >>confdefs.h <<\EOF
10269 #define TIME_WITH_SYS_TIME 1
10274 ### checks for compiler characteristics
10276 ac_cpp='$CPP $CPPFLAGS'
10277 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10278 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10279 ac_compiler_gnu=$ac_cv_c_compiler_gnu
10280 ac_main_return=return
10282 echo "$as_me:10282: checking for $CC option to accept ANSI C" >&5
10283 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
10284 if test "${ac_cv_prog_cc_stdc+set}" = set; then
10285 echo $ECHO_N "(cached) $ECHO_C" >&6
10287 ac_cv_prog_cc_stdc=no
10289 cat >conftest.$ac_ext <<_ACEOF
10290 #line 10290 "configure"
10291 #include "confdefs.h"
10292 #include <stdarg.h>
10294 #include <sys/types.h>
10295 #include <sys/stat.h>
10296 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
10297 struct buf { int x; };
10298 FILE * (*rcsopen) (struct buf *, struct stat *, int);
10299 static char *e (p, i)
10305 static char *f (char * (*g) (char **, int), char **p, ...)
10310 s = g (p, va_arg (v,int));
10314 int test (int i, double x);
10315 struct s1 {int (*f) (int a);};
10316 struct s2 {int (*f) (double a);};
10317 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
10323 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
10328 # Don't try gcc -ansi; that turns off useful extensions and
10329 # breaks some systems' header files.
10330 # AIX -qlanglvl=ansi
10331 # Ultrix and OSF/1 -std1
10332 # HP-UX 10.20 and later -Ae
10333 # HP-UX older versions -Aa -D_HPUX_SOURCE
10334 # SVR4 -Xc -D__EXTENSIONS__
10335 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
10337 CC="$ac_save_CC $ac_arg"
10338 rm -f conftest.$ac_objext
10339 if { (eval echo "$as_me:10339: \"$ac_compile\"") >&5
10340 (eval $ac_compile) 2>&5
10342 echo "$as_me:10342: \$? = $ac_status" >&5
10343 (exit $ac_status); } &&
10344 { ac_try='test -s conftest.$ac_objext'
10345 { (eval echo "$as_me:10345: \"$ac_try\"") >&5
10346 (eval $ac_try) 2>&5
10348 echo "$as_me:10348: \$? = $ac_status" >&5
10349 (exit $ac_status); }; }; then
10350 ac_cv_prog_cc_stdc=$ac_arg
10353 echo "$as_me: failed program was:" >&5
10354 cat conftest.$ac_ext >&5
10356 rm -f conftest.$ac_objext
10358 rm -f conftest.$ac_ext conftest.$ac_objext
10363 case "x$ac_cv_prog_cc_stdc" in
10365 echo "$as_me:10365: result: none needed" >&5
10366 echo "${ECHO_T}none needed" >&6 ;;
10368 echo "$as_me:10368: result: $ac_cv_prog_cc_stdc" >&5
10369 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
10370 CC="$CC $ac_cv_prog_cc_stdc" ;;
10373 echo "$as_me:10373: checking for an ANSI C-conforming const" >&5
10374 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
10375 if test "${ac_cv_c_const+set}" = set; then
10376 echo $ECHO_N "(cached) $ECHO_C" >&6
10378 cat >conftest.$ac_ext <<_ACEOF
10379 #line 10379 "configure"
10380 #include "confdefs.h"
10385 /* FIXME: Include the comments suggested by Paul. */
10386 #ifndef __cplusplus
10387 /* Ultrix mips cc rejects this. */
10388 typedef int charset[2];
10390 /* SunOS 4.1.1 cc rejects this. */
10391 char const *const *ccp;
10393 /* NEC SVR4.0.2 mips cc rejects this. */
10394 struct point {int x, y;};
10395 static struct point const zero = {0,0};
10396 /* AIX XL C 1.02.0.0 rejects this.
10397 It does not let you subtract one const X* pointer from another in
10398 an arm of an if-expression whose if-part is not a constant
10400 const char *g = "string";
10401 ccp = &g + (g ? g-g : 0);
10402 /* HPUX 7.0 cc rejects these. */
10405 ccp = (char const *const *) p;
10406 { /* SCO 3.2v4 cc rejects this. */
10408 char const *s = 0 ? (char *) 0 : (char const *) 0;
10412 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
10413 int x[] = {25, 17};
10414 const int *foo = &x[0];
10417 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
10418 typedef const int *iptr;
10422 { /* AIX XL C 1.02.0.0 rejects this saying
10423 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
10424 struct s { int j; const int *ap[3]; };
10425 struct s *b; b->j = 5;
10427 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
10428 const int foo = 10;
10436 rm -f conftest.$ac_objext
10437 if { (eval echo "$as_me:10437: \"$ac_compile\"") >&5
10438 (eval $ac_compile) 2>&5
10440 echo "$as_me:10440: \$? = $ac_status" >&5
10441 (exit $ac_status); } &&
10442 { ac_try='test -s conftest.$ac_objext'
10443 { (eval echo "$as_me:10443: \"$ac_try\"") >&5
10444 (eval $ac_try) 2>&5
10446 echo "$as_me:10446: \$? = $ac_status" >&5
10447 (exit $ac_status); }; }; then
10450 echo "$as_me: failed program was:" >&5
10451 cat conftest.$ac_ext >&5
10454 rm -f conftest.$ac_objext conftest.$ac_ext
10456 echo "$as_me:10456: result: $ac_cv_c_const" >&5
10457 echo "${ECHO_T}$ac_cv_c_const" >&6
10458 if test $ac_cv_c_const = no; then
10460 cat >>confdefs.h <<\EOF
10466 ### Checks for external-data
10468 echo "$as_me:10468: checking if data-only library module links" >&5
10469 echo $ECHO_N "checking if data-only library module links... $ECHO_C" >&6
10470 if test "${cf_cv_link_dataonly+set}" = set; then
10471 echo $ECHO_N "(cached) $ECHO_C" >&6
10475 cat >conftest.$ac_ext <<EOF
10476 #line 10476 "configure"
10477 int testdata[3] = { 123, 456, 789 };
10479 if { (eval echo "$as_me:10479: \"$ac_compile\"") >&5
10480 (eval $ac_compile) 2>&5
10482 echo "$as_me:10482: \$? = $ac_status" >&5
10483 (exit $ac_status); } ; then
10484 mv conftest.o data.o && \
10485 ( $AR $ARFLAGS conftest.a data.o ) 2>&5 1>/dev/null
10487 rm -f conftest.$ac_ext data.o
10488 cat >conftest.$ac_ext <<EOF
10489 #line 10489 "configure"
10493 ${cf_cv_main_return:-return}(1); /* I'm told this linker is broken */
10495 extern int testdata[3];
10496 return testdata[0] == 123
10497 && testdata[1] == 456
10498 && testdata[2] == 789;
10502 if { (eval echo "$as_me:10502: \"$ac_compile\"") >&5
10503 (eval $ac_compile) 2>&5
10505 echo "$as_me:10505: \$? = $ac_status" >&5
10506 (exit $ac_status); }; then
10507 mv conftest.o func.o && \
10508 ( $AR $ARFLAGS conftest.a func.o ) 2>&5 1>/dev/null
10510 rm -f conftest.$ac_ext func.o
10511 ( eval $RANLIB conftest.a ) 2>&5 >/dev/null
10512 cf_saveLIBS="$LIBS"
10513 LIBS="conftest.a $LIBS"
10514 if test "$cross_compiling" = yes; then
10515 cf_cv_link_dataonly=unknown
10517 cat >conftest.$ac_ext <<_ACEOF
10518 #line 10518 "configure"
10519 #include "confdefs.h"
10523 extern int testfunc();
10524 ${cf_cv_main_return:-return} (!testfunc());
10528 rm -f conftest$ac_exeext
10529 if { (eval echo "$as_me:10529: \"$ac_link\"") >&5
10530 (eval $ac_link) 2>&5
10532 echo "$as_me:10532: \$? = $ac_status" >&5
10533 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
10534 { (eval echo "$as_me:10534: \"$ac_try\"") >&5
10535 (eval $ac_try) 2>&5
10537 echo "$as_me:10537: \$? = $ac_status" >&5
10538 (exit $ac_status); }; }; then
10539 cf_cv_link_dataonly=yes
10541 echo "$as_me: program exited with status $ac_status" >&5
10542 echo "$as_me: failed program was:" >&5
10543 cat conftest.$ac_ext >&5
10544 cf_cv_link_dataonly=no
10546 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
10548 LIBS="$cf_saveLIBS"
10552 echo "$as_me:10552: result: $cf_cv_link_dataonly" >&5
10553 echo "${ECHO_T}$cf_cv_link_dataonly" >&6
10555 if test "$cf_cv_link_dataonly" = no ; then
10556 cat >>confdefs.h <<\EOF
10557 #define BROKEN_LINKER 1
10563 ### Checks for library functions.
10565 echo "$as_me:10565: checking for working mkstemp" >&5
10566 echo $ECHO_N "checking for working mkstemp... $ECHO_C" >&6
10567 if test "${cf_cv_func_mkstemp+set}" = set; then
10568 echo $ECHO_N "(cached) $ECHO_C" >&6
10572 if test "$cross_compiling" = yes; then
10573 echo "$as_me:10573: checking for mkstemp" >&5
10574 echo $ECHO_N "checking for mkstemp... $ECHO_C" >&6
10575 if test "${ac_cv_func_mkstemp+set}" = set; then
10576 echo $ECHO_N "(cached) $ECHO_C" >&6
10578 cat >conftest.$ac_ext <<_ACEOF
10579 #line 10579 "configure"
10580 #include "confdefs.h"
10581 /* System header to define __stub macros and hopefully few prototypes,
10582 which can conflict with char mkstemp (); below. */
10583 #include <assert.h>
10584 /* Override any gcc2 internal prototype to avoid an error. */
10588 /* We use char because int might match the return type of a gcc2
10589 builtin and then its argument prototype would still apply. */
10596 /* The GNU C library defines this for functions which it implements
10597 to always fail with ENOSYS. Some functions are actually named
10598 something starting with __ and the normal name is an alias. */
10599 #if defined (__stub_mkstemp) || defined (__stub___mkstemp)
10609 rm -f conftest.$ac_objext conftest$ac_exeext
10610 if { (eval echo "$as_me:10610: \"$ac_link\"") >&5
10611 (eval $ac_link) 2>&5
10613 echo "$as_me:10613: \$? = $ac_status" >&5
10614 (exit $ac_status); } &&
10615 { ac_try='test -s conftest$ac_exeext'
10616 { (eval echo "$as_me:10616: \"$ac_try\"") >&5
10617 (eval $ac_try) 2>&5
10619 echo "$as_me:10619: \$? = $ac_status" >&5
10620 (exit $ac_status); }; }; then
10621 ac_cv_func_mkstemp=yes
10623 echo "$as_me: failed program was:" >&5
10624 cat conftest.$ac_ext >&5
10625 ac_cv_func_mkstemp=no
10627 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10629 echo "$as_me:10629: result: $ac_cv_func_mkstemp" >&5
10630 echo "${ECHO_T}$ac_cv_func_mkstemp" >&6
10633 cat >conftest.$ac_ext <<_ACEOF
10634 #line 10634 "configure"
10635 #include "confdefs.h"
10637 #include <sys/types.h>
10638 #include <stdlib.h>
10640 #include <string.h>
10641 #include <sys/stat.h>
10644 char *tmpl = "conftestXXXXXX";
10652 for (n = 0; n < 2; ++n) {
10653 strcpy(name[n], tmpl);
10654 if ((fd = mkstemp(name[n])) >= 0) {
10655 if (!strcmp(name[n], tmpl)
10656 || stat(name[n], &sb) != 0
10657 || (sb.st_mode & S_IFMT) != S_IFREG
10658 || (sb.st_mode & 077) != 0) {
10665 && !strcmp(name[0], name[1]))
10667 ${cf_cv_main_return:-return}(result);
10671 rm -f conftest$ac_exeext
10672 if { (eval echo "$as_me:10672: \"$ac_link\"") >&5
10673 (eval $ac_link) 2>&5
10675 echo "$as_me:10675: \$? = $ac_status" >&5
10676 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
10677 { (eval echo "$as_me:10677: \"$ac_try\"") >&5
10678 (eval $ac_try) 2>&5
10680 echo "$as_me:10680: \$? = $ac_status" >&5
10681 (exit $ac_status); }; }; then
10682 cf_cv_func_mkstemp=yes
10685 echo "$as_me: program exited with status $ac_status" >&5
10686 echo "$as_me: failed program was:" >&5
10687 cat conftest.$ac_ext >&5
10688 cf_cv_func_mkstemp=no
10691 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
10695 echo "$as_me:10695: result: $cf_cv_func_mkstemp" >&5
10696 echo "${ECHO_T}$cf_cv_func_mkstemp" >&6
10697 if test "x$cf_cv_func_mkstemp" = xyes || test "x$ac_cv_func_mkstemp" = xyes ; then
10698 cat >>confdefs.h <<\EOF
10699 #define HAVE_MKSTEMP 1
10704 echo "$as_me:10704: checking return type of signal handlers" >&5
10705 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
10706 if test "${ac_cv_type_signal+set}" = set; then
10707 echo $ECHO_N "(cached) $ECHO_C" >&6
10709 cat >conftest.$ac_ext <<_ACEOF
10710 #line 10710 "configure"
10711 #include "confdefs.h"
10712 #include <sys/types.h>
10713 #include <signal.h>
10718 extern "C" void (*signal (int, void (*)(int)))(int);
10720 void (*signal ()) ();
10731 rm -f conftest.$ac_objext
10732 if { (eval echo "$as_me:10732: \"$ac_compile\"") >&5
10733 (eval $ac_compile) 2>&5
10735 echo "$as_me:10735: \$? = $ac_status" >&5
10736 (exit $ac_status); } &&
10737 { ac_try='test -s conftest.$ac_objext'
10738 { (eval echo "$as_me:10738: \"$ac_try\"") >&5
10739 (eval $ac_try) 2>&5
10741 echo "$as_me:10741: \$? = $ac_status" >&5
10742 (exit $ac_status); }; }; then
10743 ac_cv_type_signal=void
10745 echo "$as_me: failed program was:" >&5
10746 cat conftest.$ac_ext >&5
10747 ac_cv_type_signal=int
10749 rm -f conftest.$ac_objext conftest.$ac_ext
10751 echo "$as_me:10751: result: $ac_cv_type_signal" >&5
10752 echo "${ECHO_T}$ac_cv_type_signal" >&6
10754 cat >>confdefs.h <<EOF
10755 #define RETSIGTYPE $ac_cv_type_signal
10758 if test -z "$cf_user_CFLAGS" && test "$with_no_leaks" = no ; then
10759 CFLAGS=`echo ${CFLAGS} | sed -e 's%-g %%' -e 's%-g$%%'`
10760 CXXFLAGS=`echo ${CXXFLAGS} | sed -e 's%-g %%' -e 's%-g$%%'`
10763 if test "$cf_with_ada" != "no" ; then
10765 cf_ada_make=gnatmake
10766 # Extract the first word of "$cf_ada_make", so it can be a program name with args.
10767 set dummy $cf_ada_make; ac_word=$2
10768 echo "$as_me:10768: checking for $ac_word" >&5
10769 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
10770 if test "${ac_cv_prog_gnat_exists+set}" = set; then
10771 echo $ECHO_N "(cached) $ECHO_C" >&6
10773 if test -n "$gnat_exists"; then
10774 ac_cv_prog_gnat_exists="$gnat_exists" # Let the user override the test.
10776 ac_save_IFS=$IFS; IFS=$ac_path_separator
10778 for ac_dir in $ac_dummy; do
10780 test -z "$ac_dir" && ac_dir=.
10781 $as_executable_p "$ac_dir/$ac_word" || continue
10782 ac_cv_prog_gnat_exists="yes"
10783 echo "$as_me:10783: found $ac_dir/$ac_word" >&5
10787 test -z "$ac_cv_prog_gnat_exists" && ac_cv_prog_gnat_exists="no"
10790 gnat_exists=$ac_cv_prog_gnat_exists
10791 if test -n "$gnat_exists"; then
10792 echo "$as_me:10792: result: $gnat_exists" >&5
10793 echo "${ECHO_T}$gnat_exists" >&6
10795 echo "$as_me:10795: result: no" >&5
10796 echo "${ECHO_T}no" >&6
10799 if test "$ac_cv_prog_gnat_exists" = no; then
10803 echo "$as_me:10803: checking for gnat version" >&5
10804 echo $ECHO_N "checking for gnat version... $ECHO_C" >&6
10805 cf_gnat_version=`${cf_ada_make:-gnatmake} -v 2>&1 | \
10806 grep '[0-9].[0-9][0-9]*' |\
10807 sed -e '2,$d' -e 's/[^0-9 \.]//g' -e 's/^[ ]*//' -e 's/ .*//'`
10808 echo "$as_me:10808: result: $cf_gnat_version" >&5
10809 echo "${ECHO_T}$cf_gnat_version" >&6
10811 case $cf_gnat_version in #(vi
10812 3.1[1-9]*|3.[2-9]*|[4-9].*) #(vi
10813 cf_cv_prog_gnat_correct=yes
10816 { echo "$as_me:10816: WARNING: Unsupported GNAT version $cf_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&5
10817 echo "$as_me: WARNING: Unsupported GNAT version $cf_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&2;}
10818 cf_cv_prog_gnat_correct=no
10822 # Extract the first word of "m4", so it can be a program name with args.
10823 set dummy m4; ac_word=$2
10824 echo "$as_me:10824: checking for $ac_word" >&5
10825 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
10826 if test "${ac_cv_prog_M4_exists+set}" = set; then
10827 echo $ECHO_N "(cached) $ECHO_C" >&6
10829 if test -n "$M4_exists"; then
10830 ac_cv_prog_M4_exists="$M4_exists" # Let the user override the test.
10832 ac_save_IFS=$IFS; IFS=$ac_path_separator
10834 for ac_dir in $ac_dummy; do
10836 test -z "$ac_dir" && ac_dir=.
10837 $as_executable_p "$ac_dir/$ac_word" || continue
10838 ac_cv_prog_M4_exists="yes"
10839 echo "$as_me:10839: found $ac_dir/$ac_word" >&5
10843 test -z "$ac_cv_prog_M4_exists" && ac_cv_prog_M4_exists="no"
10846 M4_exists=$ac_cv_prog_M4_exists
10847 if test -n "$M4_exists"; then
10848 echo "$as_me:10848: result: $M4_exists" >&5
10849 echo "${ECHO_T}$M4_exists" >&6
10851 echo "$as_me:10851: result: no" >&5
10852 echo "${ECHO_T}no" >&6
10855 if test "$ac_cv_prog_M4_exists" = no; then
10856 cf_cv_prog_gnat_correct=no
10857 echo Ada95 binding required program m4 not found. Ada95 binding disabled.
10859 if test "$cf_cv_prog_gnat_correct" = yes; then
10860 echo "$as_me:10860: checking if GNAT works" >&5
10861 echo $ECHO_N "checking if GNAT works... $ECHO_C" >&6
10863 rm -rf conftest* *~conftest*
10864 cat >>conftest.ads <<CF_EOF
10865 procedure conftest;
10867 cat >>conftest.adb <<CF_EOF
10870 procedure conftest is
10872 Text_IO.Put ("Hello World");
10874 GNAT.OS_Lib.OS_Exit (0);
10877 if ( $cf_ada_make $ADAFLAGS conftest 1>&5 2>&1 ) ; then
10878 if ( ./conftest 1>&5 2>&1 ) ; then
10879 cf_cv_prog_gnat_correct=yes
10881 cf_cv_prog_gnat_correct=no
10884 cf_cv_prog_gnat_correct=no
10886 rm -rf conftest* *~conftest*
10888 echo "$as_me:10888: result: $cf_cv_prog_gnat_correct" >&5
10889 echo "${ECHO_T}$cf_cv_prog_gnat_correct" >&6
10893 if test "$cf_cv_prog_gnat_correct" = yes; then
10895 # make ADAFLAGS consistent with CFLAGS
10899 ADAFLAGS="$ADAFLAGS -g"
10906 ADAFLAGS="$ADAFLAGS -O3"
10911 echo "$as_me:10911: checking if GNAT supports generics" >&5
10912 echo $ECHO_N "checking if GNAT supports generics... $ECHO_C" >&6
10913 case $cf_gnat_version in #(vi
10914 3.[1-9]*|[4-9].*) #(vi
10915 cf_gnat_generics=yes
10918 cf_gnat_generics=no
10921 echo "$as_me:10921: result: $cf_gnat_generics" >&5
10922 echo "${ECHO_T}$cf_gnat_generics" >&6
10924 if test "$cf_gnat_generics" = yes
10926 cf_compile_generics=generics
10927 cf_generic_objects="\${GENOBJS}"
10929 cf_compile_generics=
10930 cf_generic_objects=
10933 echo "$as_me:10933: checking if GNAT pragma Unreferenced works" >&5
10934 echo $ECHO_N "checking if GNAT pragma Unreferenced works... $ECHO_C" >&6
10935 if test "${cf_cv_pragma_unreferenced+set}" = set; then
10936 echo $ECHO_N "(cached) $ECHO_C" >&6
10939 rm -rf conftest* *~conftest*
10940 cat >>conftest.ads <<CF_EOF
10941 procedure conftest;
10943 cat >>conftest.adb <<CF_EOF
10946 procedure conftest is
10948 pragma Unreferenced (test);
10951 Text_IO.Put ("Hello World");
10953 GNAT.OS_Lib.OS_Exit (0);
10956 if ( $cf_ada_make $ADAFLAGS conftest 1>&5 2>&1 ) ; then
10957 cf_cv_pragma_unreferenced=yes
10959 cf_cv_pragma_unreferenced=no
10961 rm -rf conftest* *~conftest*
10964 echo "$as_me:10964: result: $cf_cv_pragma_unreferenced" >&5
10965 echo "${ECHO_T}$cf_cv_pragma_unreferenced" >&6
10967 # if the pragma is supported, use it (needed in the Trace code).
10968 if test $cf_cv_pragma_unreferenced = yes ; then
10974 cf_gnat_libraries=no
10975 cf_gnat_projects=no
10977 echo "$as_me:10977: checking if GNAT supports project files" >&5
10978 echo $ECHO_N "checking if GNAT supports project files... $ECHO_C" >&6
10979 case $cf_gnat_version in #(vi
10983 case $cf_cv_system_name in #(vi
10987 mkdir conftest.src conftest.bin conftest.lib
10989 rm -rf conftest* *~conftest*
10990 cat >>library.gpr <<CF_EOF
10992 Kind := External ("LIB_KIND");
10993 for Library_Name use "ConfTest";
10994 for Object_Dir use ".";
10995 for Library_ALI_Dir use External("LIBRARY_DIR");
10996 for Library_Version use External ("SONAME");
10997 for Library_Kind use Kind;
10998 for Library_Dir use External("BUILD_DIR");
10999 Source_Dir := External ("SOURCE_DIR");
11000 for Source_Dirs use (Source_Dir);
11001 package Compiler is
11002 for Default_Switches ("Ada") use
11006 "-gnatVa", -- All validity checks
11007 "-gnatwa"); -- Activate all optional errors
11011 cat >>confpackage.ads <<CF_EOF
11012 package ConfPackage is
11013 procedure conftest;
11016 cat >>confpackage.adb <<CF_EOF
11018 package body ConfPackage is
11019 procedure conftest is
11021 Text_IO.Put ("Hello World");
11026 if ( $cf_ada_make $ADAFLAGS \
11028 -XBUILD_DIR=`cd ../conftest.bin;pwd` \
11029 -XLIBRARY_DIR=`cd ../conftest.lib;pwd` \
11030 -XSOURCE_DIR=`pwd` \
11031 -XSONAME=libConfTest.so.1 \
11032 -XLIB_KIND=static 1>&5 2>&1 ) ; then
11033 cf_gnat_projects=yes
11036 if test -f conftest.lib/confpackage.ali
11038 cf_gnat_libraries=yes
11040 rm -rf conftest* *~conftest*
11045 echo "$as_me:11045: result: $cf_gnat_projects" >&5
11046 echo "${ECHO_T}$cf_gnat_projects" >&6
11048 if test $cf_gnat_projects = yes
11050 echo "$as_me:11050: checking if GNAT supports libraries" >&5
11051 echo $ECHO_N "checking if GNAT supports libraries... $ECHO_C" >&6
11052 echo "$as_me:11052: result: $cf_gnat_libraries" >&5
11053 echo "${ECHO_T}$cf_gnat_libraries" >&6
11056 if test "$cf_gnat_projects" = yes
11058 USE_OLD_MAKERULES="#"
11059 USE_GNAT_PROJECTS=""
11061 USE_OLD_MAKERULES=""
11062 USE_GNAT_PROJECTS="#"
11065 if test "$cf_gnat_libraries" = yes
11067 USE_GNAT_LIBRARIES=""
11069 USE_GNAT_LIBRARIES="#"
11072 echo "$as_me:11072: checking for ada-compiler" >&5
11073 echo $ECHO_N "checking for ada-compiler... $ECHO_C" >&6
11075 # Check whether --with-ada-compiler or --without-ada-compiler was given.
11076 if test "${with_ada_compiler+set}" = set; then
11077 withval="$with_ada_compiler"
11078 cf_ada_compiler=$withval
11080 cf_ada_compiler=gnatmake
11083 echo "$as_me:11083: result: $cf_ada_compiler" >&5
11084 echo "${ECHO_T}$cf_ada_compiler" >&6
11086 cf_ada_package=terminal_interface
11088 echo "$as_me:11088: checking for ada-include" >&5
11089 echo $ECHO_N "checking for ada-include... $ECHO_C" >&6
11091 # Check whether --with-ada-include or --without-ada-include was given.
11092 if test "${with_ada_include+set}" = set; then
11093 withval="$with_ada_include"
11096 withval="${ADA_INCLUDE:-$prefix/share/ada/adainclude}"
11097 fi; if test -n "$prefix/share/ada/adainclude" ; then
11099 if test "x$prefix" != xNONE; then
11100 cf_path_syntax="$prefix"
11102 cf_path_syntax="$ac_default_prefix"
11105 case ".$withval" in #(vi
11106 .\$\(*\)*|.\'*\'*) #(vi
11110 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
11112 .\${*prefix}*) #(vi
11113 eval withval="$withval"
11114 case ".$withval" in #(vi
11116 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
11121 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
11124 { { echo "$as_me:11124: error: expected a pathname, not \"$withval\"" >&5
11125 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
11126 { (exit 1); exit 1; }; }
11131 ADA_INCLUDE="$withval"
11133 echo "$as_me:11133: result: $ADA_INCLUDE" >&5
11134 echo "${ECHO_T}$ADA_INCLUDE" >&6
11136 echo "$as_me:11136: checking for ada-objects" >&5
11137 echo $ECHO_N "checking for ada-objects... $ECHO_C" >&6
11139 # Check whether --with-ada-objects or --without-ada-objects was given.
11140 if test "${with_ada_objects+set}" = set; then
11141 withval="$with_ada_objects"
11144 withval="${ADA_OBJECTS:-$prefix/lib/ada/adalib}"
11145 fi; if test -n "$prefix/lib/ada/adalib" ; then
11147 if test "x$prefix" != xNONE; then
11148 cf_path_syntax="$prefix"
11150 cf_path_syntax="$ac_default_prefix"
11153 case ".$withval" in #(vi
11154 .\$\(*\)*|.\'*\'*) #(vi
11158 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
11160 .\${*prefix}*) #(vi
11161 eval withval="$withval"
11162 case ".$withval" in #(vi
11164 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
11169 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
11172 { { echo "$as_me:11172: error: expected a pathname, not \"$withval\"" >&5
11173 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
11174 { (exit 1); exit 1; }; }
11179 ADA_OBJECTS="$withval"
11181 echo "$as_me:11181: result: $ADA_OBJECTS" >&5
11182 echo "${ECHO_T}$ADA_OBJECTS" >&6
11184 echo "$as_me:11184: checking if an Ada95 shared-library should be built" >&5
11185 echo $ECHO_N "checking if an Ada95 shared-library should be built... $ECHO_C" >&6
11187 # Check whether --with-ada-sharedlib or --without-ada-sharedlib was given.
11188 if test "${with_ada_sharedlib+set}" = set; then
11189 withval="$with_ada_sharedlib"
11190 with_ada_sharedlib=$withval
11192 with_ada_sharedlib=no
11194 echo "$as_me:11194: result: $with_ada_sharedlib" >&5
11195 echo "${ECHO_T}$with_ada_sharedlib" >&6
11197 ADA_SHAREDLIB='lib$(LIB_NAME).so.1'
11198 MAKE_ADA_SHAREDLIB="#"
11200 if test "x$with_ada_sharedlib" != xno
11202 MAKE_ADA_SHAREDLIB=
11203 if test "x$with_ada_sharedlib" != xyes
11205 ADA_SHAREDLIB="$with_ada_sharedlib"
11210 { { echo "$as_me:11210: error: No usable Ada compiler found" >&5
11211 echo "$as_me: error: No usable Ada compiler found" >&2;}
11212 { (exit 1); exit 1; }; }
11215 { { echo "$as_me:11215: error: The Ada compiler is needed for this package" >&5
11216 echo "$as_me: error: The Ada compiler is needed for this package" >&2;}
11217 { (exit 1); exit 1; }; }
11220 ################################################################################
11225 ### Construct the list of include-directories to be generated
11227 CPPFLAGS="$CPPFLAGS -I. -I../include"
11228 if test "$srcdir" != "."; then
11229 CPPFLAGS="$CPPFLAGS -I\${srcdir}/../include"
11231 if test "$GCC" != yes; then
11232 CPPFLAGS="$CPPFLAGS -I\${includedir}"
11233 elif test "$includedir" != "/usr/include"; then
11234 if test "$includedir" = '${prefix}/include' ; then
11235 if test $prefix != /usr ; then
11236 CPPFLAGS="$CPPFLAGS -I\${includedir}"
11239 CPPFLAGS="$CPPFLAGS -I\${includedir}"
11243 ACPPFLAGS="-I. -I../include -I../../include $ACPPFLAGS"
11244 if test "$srcdir" != "."; then
11245 ACPPFLAGS="-I\${srcdir}/../../include $ACPPFLAGS"
11247 if test "$GCC" != yes; then
11248 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
11249 elif test "$includedir" != "/usr/include"; then
11250 if test "$includedir" = '${prefix}/include' ; then
11251 if test $prefix != /usr ; then
11252 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
11255 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
11259 ### Build up pieces for makefile rules
11260 echo "$as_me:11260: checking default library suffix" >&5
11261 echo $ECHO_N "checking default library suffix... $ECHO_C" >&6
11263 case $DFT_LWR_MODEL in
11264 libtool) DFT_ARG_SUFFIX='' ;;
11265 normal) DFT_ARG_SUFFIX='' ;;
11266 debug) DFT_ARG_SUFFIX='_g' ;;
11267 profile) DFT_ARG_SUFFIX='_p' ;;
11268 shared) DFT_ARG_SUFFIX='' ;;
11270 test -n "$LIB_SUFFIX" && DFT_ARG_SUFFIX="${LIB_SUFFIX}${DFT_ARG_SUFFIX}"
11271 echo "$as_me:11271: result: $DFT_ARG_SUFFIX" >&5
11272 echo "${ECHO_T}$DFT_ARG_SUFFIX" >&6
11274 echo "$as_me:11274: checking default library-dependency suffix" >&5
11275 echo $ECHO_N "checking default library-dependency suffix... $ECHO_C" >&6
11277 case $DFT_LWR_MODEL in #(vi
11279 DFT_LIB_SUFFIX='.la'
11280 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
11283 DFT_LIB_SUFFIX='.a'
11284 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
11287 DFT_LIB_SUFFIX='_g.a'
11288 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
11291 DFT_LIB_SUFFIX='_p.a'
11292 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
11295 case $cf_cv_system_name in
11297 DFT_LIB_SUFFIX='.a'
11298 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
11301 DFT_LIB_SUFFIX='.dll'
11302 DFT_DEP_SUFFIX='.dll.a'
11305 DFT_LIB_SUFFIX='.dylib'
11306 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
11311 DFT_LIB_SUFFIX='.so'
11312 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
11315 DFT_LIB_SUFFIX='.sl'
11316 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
11320 *) DFT_LIB_SUFFIX='.so'
11321 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
11325 test -n "$LIB_SUFFIX" && DFT_LIB_SUFFIX="${LIB_SUFFIX}${DFT_LIB_SUFFIX}"
11326 test -n "$LIB_SUFFIX" && DFT_DEP_SUFFIX="${LIB_SUFFIX}${DFT_DEP_SUFFIX}"
11327 echo "$as_me:11327: result: $DFT_DEP_SUFFIX" >&5
11328 echo "${ECHO_T}$DFT_DEP_SUFFIX" >&6
11330 echo "$as_me:11330: checking default object directory" >&5
11331 echo $ECHO_N "checking default object directory... $ECHO_C" >&6
11333 case $DFT_LWR_MODEL in
11334 libtool) DFT_OBJ_SUBDIR='obj_lo' ;;
11335 normal) DFT_OBJ_SUBDIR='objects' ;;
11336 debug) DFT_OBJ_SUBDIR='obj_g' ;;
11337 profile) DFT_OBJ_SUBDIR='obj_p' ;;
11339 case $cf_cv_system_name in #(vi
11341 DFT_OBJ_SUBDIR='objects' ;;
11343 DFT_OBJ_SUBDIR='obj_s' ;;
11346 echo "$as_me:11346: result: $DFT_OBJ_SUBDIR" >&5
11347 echo "${ECHO_T}$DFT_OBJ_SUBDIR" >&6
11349 ### Set up low-level terminfo dependencies for makefiles.
11351 if test "$DFT_LWR_MODEL" = shared ; then
11352 case $cf_cv_system_name in #(vi
11354 # "lib" files have ".dll.a" suffix, "cyg" files have ".dll"
11359 ### Construct the list of subdirectories for which we'll customize makefiles
11360 ### with the appropriate compile-rules.
11362 SUB_MAKEFILES="gen/adacurses${DFT_ARG_SUFFIX}-config:gen/adacurses-config.in"
11364 cat >>confdefs.h <<EOF
11365 #define NCURSES_PATHSEP '$PATH_SEPARATOR'
11368 ### Now that we're done running tests, add the compiler-warnings, if any
11373 cf_new_extra_cppflags=
11375 for cf_add_cflags in $EXTRA_CFLAGS
11377 case $cf_fix_cppflags in
11379 case $cf_add_cflags in #(vi
11380 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11381 case $cf_add_cflags in
11383 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11385 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11386 && test -z "${cf_tst_cflags}" \
11387 && cf_fix_cppflags=yes
11389 if test $cf_fix_cppflags = yes ; then
11390 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11392 elif test "${cf_tst_cflags}" = "\"'" ; then
11393 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11398 case "$CPPFLAGS" in
11399 *$cf_add_cflags) #(vi
11402 case $cf_add_cflags in #(vi
11404 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11406 CPPFLAGS=`echo "$CPPFLAGS" | \
11407 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11408 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11412 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11417 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11422 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11424 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11426 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11427 && test -z "${cf_tst_cflags}" \
11428 && cf_fix_cppflags=no
11433 if test -n "$cf_new_cflags" ; then
11435 CFLAGS="$CFLAGS $cf_new_cflags"
11438 if test -n "$cf_new_cppflags" ; then
11440 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11443 if test -n "$cf_new_extra_cppflags" ; then
11445 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11448 ################################################################################
11450 if test x"$enable_pc_files" = xyes ; then \
11451 SUB_MAKEFILES="$SUB_MAKEFILES misc/gen-pkgconfig:misc/gen-pkgconfig.in"
11457 ################################################################################
11463 NCURSES_SHLIB2="sh -c"
11465 ADA_SUBDIRS="include gen src doc"
11466 if test "x$cf_with_tests" != "xno" ; then
11467 ADA_SUBDIRS="$ADA_SUBDIRS samples"
11469 for cf_dir in $ADA_SUBDIRS
11471 SUB_MAKEFILES="$SUB_MAKEFILES $cf_dir/Makefile"
11478 # match layout used by make-tar.sh
11479 ADAHTML_DIR=../doc/ada
11481 ac_config_files="$ac_config_files $SUB_MAKEFILES doc/adacurses${DFT_ARG_SUFFIX}-config.1:doc/MKada_config.in Makefile"
11482 ac_config_commands="$ac_config_commands default"
11483 cat >confcache <<\_ACEOF
11484 # This file is a shell script that caches the results of configure
11485 # tests run on this system so they can be shared between configure
11486 # scripts and configure runs, see configure's option --config-cache.
11487 # It is not useful on other systems. If it contains results you don't
11488 # want to keep, you may remove or edit it.
11490 # config.status only pays attention to the cache file if you give it
11491 # the --recheck option to rerun configure.
11493 # `ac_cv_env_foo' variables (set or unset) will be overriden when
11494 # loading this file, other *unset* `ac_cv_foo' will be assigned the
11495 # following values.
11499 # The following way of writing the cache mishandles newlines in values,
11500 # but we know of no workaround that is simple, portable, and efficient.
11501 # So, don't put newlines in cache variables' values.
11502 # Ultrix sh set writes to stderr and can't be redirected directly,
11503 # and sets the high bit in the cache file unless we assign to the vars.
11506 case `(ac_space=' '; set | grep ac_space) 2>&1` in
11508 # `set' does not quote correctly, so add quotes (double-quote
11509 # substitution turns \\\\ into \\, and sed turns \\ into \).
11512 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
11515 # `set' quotes correctly as required by POSIX, so do not add quotes.
11517 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
11524 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
11526 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
11528 if cmp -s $cache_file confcache; then :; else
11529 if test -w $cache_file; then
11530 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
11531 cat confcache >$cache_file
11533 echo "not updating unwritable cache $cache_file"
11538 test "x$prefix" = xNONE && prefix=$ac_default_prefix
11539 # Let make expand exec_prefix.
11540 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
11542 # VPATH may cause trouble with some makes, so we remove $(srcdir),
11543 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
11544 # trailing colons and then remove the whole line if VPATH becomes empty
11545 # (actually we leave an empty line to preserve line numbers).
11546 if test "x$srcdir" = x.; then
11547 ac_vpsub='/^[ ]*VPATH[ ]*=/{
11548 s/:*\$(srcdir):*/:/;
11549 s/:*\${srcdir}:*/:/;
11551 s/^\([^=]*=[ ]*\):*/\1/;
11557 DEFS=-DHAVE_CONFIG_H
11559 : ${CONFIG_STATUS=./config.status}
11560 ac_clean_files_save=$ac_clean_files
11561 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
11562 { echo "$as_me:11562: creating $CONFIG_STATUS" >&5
11563 echo "$as_me: creating $CONFIG_STATUS" >&6;}
11564 cat >$CONFIG_STATUS <<_ACEOF
11566 # Generated automatically by configure.
11567 # Run this file to recreate the current configuration.
11568 # Compiler output produced by configure, useful for debugging
11569 # configure, is in config.log if it exists.
11572 SHELL=\${CONFIG_SHELL-$SHELL}
11573 ac_cs_invocation="\$0 \$@"
11577 cat >>$CONFIG_STATUS <<\_ACEOF
11578 # Be Bourne compatible
11579 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
11582 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
11586 # Name of the executable.
11587 as_me=`echo "$0" |sed 's,.*[\\/],,'`
11589 if expr a : '\(a\)' >/dev/null 2>&1; then
11595 rm -f conf$$ conf$$.exe conf$$.file
11597 if ln -s conf$$.file conf$$ 2>/dev/null; then
11598 # We could just check for DJGPP; but this test a) works b) is more generic
11599 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
11600 if test -f conf$$.exe; then
11601 # Don't use ln at all; we don't have any links
11606 elif ln conf$$.file conf$$ 2>/dev/null; then
11611 rm -f conf$$ conf$$.exe conf$$.file
11613 as_executable_p="test -f"
11615 # Support unset when possible.
11616 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
11623 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
11624 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
11625 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
11626 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
11627 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
11628 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
11629 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
11630 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
11633 # We need space, tab and new line, in precisely that order.
11639 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
11645 # Files that config.status was made for.
11646 if test -n "$ac_config_files"; then
11647 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
11650 if test -n "$ac_config_headers"; then
11651 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
11654 if test -n "$ac_config_links"; then
11655 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
11658 if test -n "$ac_config_commands"; then
11659 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
11662 cat >>$CONFIG_STATUS <<\EOF
11665 \`$as_me' instantiates files from templates according to the
11666 current configuration.
11668 Usage: $0 [OPTIONS] [FILE]...
11670 -h, --help print this help, then exit
11671 -V, --version print version number, then exit
11672 -d, --debug don't remove temporary files
11673 --recheck update $as_me by reconfiguring in the same conditions
11674 --file=FILE[:TEMPLATE]
11675 instantiate the configuration file FILE
11676 --header=FILE[:TEMPLATE]
11677 instantiate the configuration header FILE
11679 Configuration files:
11682 Configuration headers:
11685 Configuration commands:
11688 Report bugs to <dickey@invisible-island.net>."
11691 cat >>$CONFIG_STATUS <<EOF
11694 configured by $0, generated by GNU Autoconf 2.52.20101002,
11695 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
11697 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
11698 Free Software Foundation, Inc.
11699 This config.status script is free software; the Free Software Foundation
11700 gives unlimited permission to copy, distribute and modify it."
11705 cat >>$CONFIG_STATUS <<\EOF
11706 # If no file are specified by the user, then we need to provide default
11707 # value. By we need to know if files were specified by the user.
11713 ac_option=`expr "x$1" : 'x\([^=]*\)='`
11714 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
11716 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
11720 *) # This is not an option, so the user has probably given explicit
11722 ac_need_defaults=false;;
11726 # Handling of the options.
11728 cat >>$CONFIG_STATUS <<EOF
11729 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
11730 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
11731 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
11733 cat >>$CONFIG_STATUS <<\EOF
11734 --version | --vers* | -V )
11735 echo "$ac_cs_version"; exit 0 ;;
11737 # Conflict between --help and --header
11738 { { echo "$as_me:11738: error: ambiguous option: $1
11739 Try \`$0 --help' for more information." >&5
11740 echo "$as_me: error: ambiguous option: $1
11741 Try \`$0 --help' for more information." >&2;}
11742 { (exit 1); exit 1; }; };;
11743 --help | --hel | -h )
11744 echo "$ac_cs_usage"; exit 0 ;;
11745 --debug | --d* | -d )
11747 --file | --fil | --fi | --f )
11749 CONFIG_FILES="$CONFIG_FILES $1"
11750 ac_need_defaults=false;;
11751 --header | --heade | --head | --hea )
11753 CONFIG_HEADERS="$CONFIG_HEADERS $1"
11754 ac_need_defaults=false;;
11756 # This is an error.
11757 -*) { { echo "$as_me:11757: error: unrecognized option: $1
11758 Try \`$0 --help' for more information." >&5
11759 echo "$as_me: error: unrecognized option: $1
11760 Try \`$0 --help' for more information." >&2;}
11761 { (exit 1); exit 1; }; } ;;
11763 *) ac_config_targets="$ac_config_targets $1" ;;
11772 ## ----------------------- ##
11773 ## Running config.status. ##
11774 ## ----------------------- ##
11776 This file was extended by $as_me 2.52.20101002, executed with
11777 CONFIG_FILES = $CONFIG_FILES
11778 CONFIG_HEADERS = $CONFIG_HEADERS
11779 CONFIG_LINKS = $CONFIG_LINKS
11780 CONFIG_COMMANDS = $CONFIG_COMMANDS
11781 > $ac_cs_invocation
11782 on `(hostname || uname -n) 2>/dev/null | sed 1q`
11787 cat >>$CONFIG_STATUS <<EOF
11789 # INIT-COMMANDS section.
11792 ### Special initialization commands, used to pass information from the
11793 ### configuration-run into config.status
11796 DFT_ARG_SUFFIX="$DFT_ARG_SUFFIX"
11797 DFT_LWR_MODEL="$DFT_LWR_MODEL"
11798 ECHO_LINK="$ECHO_LINK"
11799 LIB_NAME="$LIB_NAME"
11800 LIB_SUFFIX="$LIB_SUFFIX"
11802 NCURSES_MAJOR="$NCURSES_MAJOR"
11803 NCURSES_MINOR="$NCURSES_MINOR"
11804 NCURSES_PATCH="$NCURSES_PATCH"
11805 USE_OLD_MAKERULES="$USE_OLD_MAKERULES"
11806 cf_cv_abi_version="$cf_cv_abi_version"
11807 cf_cv_rel_version="$cf_cv_rel_version"
11808 cf_cv_rm_so_locs="$cf_cv_rm_so_locs"
11809 cf_cv_shared_soname='$cf_cv_shared_soname'
11810 cf_cv_shlib_version="$cf_cv_shlib_version"
11811 cf_cv_shlib_version_infix="$cf_cv_shlib_version_infix"
11812 cf_cv_system_name="$cf_cv_system_name"
11818 cat >>$CONFIG_STATUS <<\EOF
11819 for ac_config_target in $ac_config_targets
11821 case "$ac_config_target" in
11822 # Handling of arguments.
11823 "$SUB_MAKEFILES" ) CONFIG_FILES="$CONFIG_FILES $SUB_MAKEFILES" ;;
11824 "doc/adacurses${DFT_ARG_SUFFIX}-config.1" ) CONFIG_FILES="$CONFIG_FILES doc/adacurses${DFT_ARG_SUFFIX}-config.1:doc/MKada_config.in" ;;
11825 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
11826 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
11827 "include/ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/ncurses_cfg.h:include/ncurses_cfg.hin" ;;
11828 *) { { echo "$as_me:11828: error: invalid argument: $ac_config_target" >&5
11829 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
11830 { (exit 1); exit 1; }; };;
11834 # If the user did not use the arguments to specify the items to instantiate,
11835 # then the envvar interface is used. Set only those that are not.
11836 # We use the long form for the default assignment because of an extremely
11837 # bizarre bug on SunOS 4.1.3.
11838 if $ac_need_defaults; then
11839 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
11840 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
11841 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
11844 # Create a temporary directory, and hook for its removal unless debugging.
11847 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
11848 trap '{ (exit 1); exit 1; }' 1 2 13 15
11851 # Create a (secure) tmp directory for tmp files.
11854 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
11855 test -n "$tmp" && test -d "$tmp"
11858 tmp=$TMPDIR/cs$$-$RANDOM
11859 (umask 077 && mkdir $tmp)
11862 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
11863 { (exit 1); exit 1; }
11868 cat >>$CONFIG_STATUS <<EOF
11871 # CONFIG_FILES section.
11874 # No need to generate the scripts if there are no CONFIG_FILES.
11875 # This happens for instance when ./config.status config.h
11876 if test -n "\$CONFIG_FILES"; then
11877 # Protect against being on the right side of a sed subst in config.status.
11878 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
11879 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
11880 s,@SHELL@,$SHELL,;t t
11881 s,@exec_prefix@,$exec_prefix,;t t
11882 s,@prefix@,$prefix,;t t
11883 s,@program_transform_name@,$program_transform_name,;t t
11884 s,@bindir@,$bindir,;t t
11885 s,@sbindir@,$sbindir,;t t
11886 s,@libexecdir@,$libexecdir,;t t
11887 s,@datadir@,$datadir,;t t
11888 s,@sysconfdir@,$sysconfdir,;t t
11889 s,@sharedstatedir@,$sharedstatedir,;t t
11890 s,@localstatedir@,$localstatedir,;t t
11891 s,@libdir@,$libdir,;t t
11892 s,@includedir@,$includedir,;t t
11893 s,@oldincludedir@,$oldincludedir,;t t
11894 s,@infodir@,$infodir,;t t
11895 s,@mandir@,$mandir,;t t
11896 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
11897 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
11898 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
11899 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
11900 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
11901 s,@build_alias@,$build_alias,;t t
11902 s,@host_alias@,$host_alias,;t t
11903 s,@target_alias@,$target_alias,;t t
11904 s,@ECHO_C@,$ECHO_C,;t t
11905 s,@ECHO_N@,$ECHO_N,;t t
11906 s,@ECHO_T@,$ECHO_T,;t t
11907 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
11908 s,@DEFS@,$DEFS,;t t
11909 s,@LIBS@,$LIBS,;t t
11910 s,@top_builddir@,$top_builddir,;t t
11911 s,@build@,$build,;t t
11912 s,@build_cpu@,$build_cpu,;t t
11913 s,@build_vendor@,$build_vendor,;t t
11914 s,@build_os@,$build_os,;t t
11915 s,@host@,$host,;t t
11916 s,@host_cpu@,$host_cpu,;t t
11917 s,@host_vendor@,$host_vendor,;t t
11918 s,@host_os@,$host_os,;t t
11919 s,@target@,$target,;t t
11920 s,@target_cpu@,$target_cpu,;t t
11921 s,@target_vendor@,$target_vendor,;t t
11922 s,@target_os@,$target_os,;t t
11924 s,@CFLAGS@,$CFLAGS,;t t
11925 s,@LDFLAGS@,$LDFLAGS,;t t
11926 s,@CPPFLAGS@,$CPPFLAGS,;t t
11927 s,@ac_ct_CC@,$ac_ct_CC,;t t
11928 s,@EXEEXT@,$EXEEXT,;t t
11929 s,@OBJEXT@,$OBJEXT,;t t
11931 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
11932 s,@PROG_EXT@,$PROG_EXT,;t t
11934 s,@EGREP@,$EGREP,;t t
11935 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
11936 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
11937 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
11938 s,@LN_S@,$LN_S,;t t
11939 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
11940 s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t
11941 s,@PKG_CONFIG_LIBDIR@,$PKG_CONFIG_LIBDIR,;t t
11942 s,@SET_MAKE@,$SET_MAKE,;t t
11943 s,@CTAGS@,$CTAGS,;t t
11944 s,@ETAGS@,$ETAGS,;t t
11945 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
11946 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
11947 s,@cf_cv_makeflags@,$cf_cv_makeflags,;t t
11948 s,@RANLIB@,$RANLIB,;t t
11949 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
11951 s,@ac_ct_LD@,$ac_ct_LD,;t t
11953 s,@ac_ct_AR@,$ac_ct_AR,;t t
11954 s,@ARFLAGS@,$ARFLAGS,;t t
11955 s,@DESTDIR@,$DESTDIR,;t t
11956 s,@BUILD_CC@,$BUILD_CC,;t t
11957 s,@BUILD_CPP@,$BUILD_CPP,;t t
11958 s,@BUILD_CFLAGS@,$BUILD_CFLAGS,;t t
11959 s,@BUILD_CPPFLAGS@,$BUILD_CPPFLAGS,;t t
11960 s,@BUILD_LDFLAGS@,$BUILD_LDFLAGS,;t t
11961 s,@BUILD_LIBS@,$BUILD_LIBS,;t t
11962 s,@BUILD_EXEEXT@,$BUILD_EXEEXT,;t t
11963 s,@BUILD_OBJEXT@,$BUILD_OBJEXT,;t t
11964 s,@DFT_LWR_MODEL@,$DFT_LWR_MODEL,;t t
11965 s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t
11966 s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
11967 s,@NCURSES_MAJOR@,$NCURSES_MAJOR,;t t
11968 s,@NCURSES_MINOR@,$NCURSES_MINOR,;t t
11969 s,@NCURSES_PATCH@,$NCURSES_PATCH,;t t
11970 s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t
11971 s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t
11972 s,@cf_cv_builtin_bool@,$cf_cv_builtin_bool,;t t
11973 s,@cf_cv_header_stdbool_h@,$cf_cv_header_stdbool_h,;t t
11974 s,@cf_cv_type_of_bool@,$cf_cv_type_of_bool,;t t
11975 s,@LIB_PREFIX@,$LIB_PREFIX,;t t
11976 s,@LIB_SUFFIX@,$LIB_SUFFIX,;t t
11977 s,@CC_G_OPT@,$CC_G_OPT,;t t
11978 s,@LD_MODEL@,$LD_MODEL,;t t
11979 s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t
11980 s,@LD_RPATH_OPT@,$LD_RPATH_OPT,;t t
11981 s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t
11982 s,@MK_SHARED_LIB@,$MK_SHARED_LIB,;t t
11983 s,@LINK_PROGS@,$LINK_PROGS,;t t
11984 s,@LINK_TESTS@,$LINK_TESTS,;t t
11985 s,@EXTRA_LDFLAGS@,$EXTRA_LDFLAGS,;t t
11986 s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
11987 s,@LOCAL_LDFLAGS2@,$LOCAL_LDFLAGS2,;t t
11988 s,@INSTALL_LIB@,$INSTALL_LIB,;t t
11989 s,@BROKEN_LINKER@,$BROKEN_LINKER,;t t
11990 s,@NCURSES_EXT_FUNCS@,$NCURSES_EXT_FUNCS,;t t
11991 s,@NCURSES_CONST@,$NCURSES_CONST,;t t
11992 s,@PTHREAD@,$PTHREAD,;t t
11993 s,@cf_cv_enable_reentrant@,$cf_cv_enable_reentrant,;t t
11994 s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
11995 s,@ECHO_LINK@,$ECHO_LINK,;t t
11996 s,@ADAFLAGS@,$ADAFLAGS,;t t
11997 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
11998 s,@ADA_TRACE@,$ADA_TRACE,;t t
11999 s,@gnat_exists@,$gnat_exists,;t t
12000 s,@M4_exists@,$M4_exists,;t t
12001 s,@cf_ada_make@,$cf_ada_make,;t t
12002 s,@cf_compile_generics@,$cf_compile_generics,;t t
12003 s,@cf_generic_objects@,$cf_generic_objects,;t t
12004 s,@PRAGMA_UNREF@,$PRAGMA_UNREF,;t t
12005 s,@USE_OLD_MAKERULES@,$USE_OLD_MAKERULES,;t t
12006 s,@USE_GNAT_PROJECTS@,$USE_GNAT_PROJECTS,;t t
12007 s,@USE_GNAT_LIBRARIES@,$USE_GNAT_LIBRARIES,;t t
12008 s,@cf_ada_compiler@,$cf_ada_compiler,;t t
12009 s,@cf_ada_package@,$cf_ada_package,;t t
12010 s,@ADA_INCLUDE@,$ADA_INCLUDE,;t t
12011 s,@ADA_OBJECTS@,$ADA_OBJECTS,;t t
12012 s,@ADA_SHAREDLIB@,$ADA_SHAREDLIB,;t t
12013 s,@MAKE_ADA_SHAREDLIB@,$MAKE_ADA_SHAREDLIB,;t t
12014 s,@TINFO_ARGS2@,$TINFO_ARGS2,;t t
12015 s,@ACPPFLAGS@,$ACPPFLAGS,;t t
12016 s,@DFT_ARG_SUFFIX@,$DFT_ARG_SUFFIX,;t t
12017 s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t
12018 s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t
12019 s,@MAKE_PC_FILES@,$MAKE_PC_FILES,;t t
12020 s,@cross_compiling@,$cross_compiling,;t t
12021 s,@TEST_ARG2@,$TEST_ARG2,;t t
12022 s,@TEST_LIBS2@,$TEST_LIBS2,;t t
12023 s,@NCURSES_SHLIB2@,$NCURSES_SHLIB2,;t t
12024 s,@ADA_SUBDIRS@,$ADA_SUBDIRS,;t t
12025 s,@NCURSES_TREE@,$NCURSES_TREE,;t t
12026 s,@EXTERNAL_TREE@,$EXTERNAL_TREE,;t t
12027 s,@ADAHTML_DIR@,$ADAHTML_DIR,;t t
12032 cat >>$CONFIG_STATUS <<\EOF
12033 # Split the substitutions into bite-sized pieces for seds with
12034 # small command number limits, like on Digital OSF/1 and HP-UX.
12035 ac_max_sed_lines=48
12036 ac_sed_frag=1 # Number of current file.
12037 ac_beg=1 # First line for current file.
12038 ac_end=$ac_max_sed_lines # Line after last line for current file.
12041 while $ac_more_lines; do
12042 if test $ac_beg -gt 1; then
12043 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
12045 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
12047 if test ! -s $tmp/subs.frag; then
12048 ac_more_lines=false
12050 # The purpose of the label and of the branching condition is to
12051 # speed up the sed processing (if there are no `@' at all, there
12052 # is no need to browse any of the substitutions).
12053 # These are the two extra sed commands mentioned above.
12055 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
12056 if test -z "$ac_sed_cmds"; then
12057 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
12059 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
12061 ac_sed_frag=`expr $ac_sed_frag + 1`
12063 ac_end=`expr $ac_end + $ac_max_sed_lines`
12066 if test -z "$ac_sed_cmds"; then
12069 fi # test -n "$CONFIG_FILES"
12072 cat >>$CONFIG_STATUS <<\EOF
12073 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
12074 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
12076 - | *:- | *:-:* ) # input from stdin
12078 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
12079 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
12080 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
12081 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
12082 * ) ac_file_in=$ac_file.in ;;
12085 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
12086 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
12087 X"$ac_file" : 'X\(//\)[^/]' \| \
12088 X"$ac_file" : 'X\(//\)$' \| \
12089 X"$ac_file" : 'X\(/\)' \| \
12090 . : '\(.\)' 2>/dev/null ||
12092 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
12093 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
12094 /^X\(\/\/\)$/{ s//\1/; q; }
12095 /^X\(\/\).*/{ s//\1/; q; }
12097 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
12098 { case "$ac_dir" in
12099 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
12103 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
12104 case $as_mkdir_dir in
12105 # Skip DOS drivespec
12106 ?:) as_incr_dir=$as_mkdir_dir ;;
12108 as_incr_dir=$as_incr_dir/$as_mkdir_dir
12109 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
12114 ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
12115 # A "../" for each directory in $ac_dir_suffix.
12116 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
12118 ac_dir_suffix= ac_dots=
12123 if test -z "$ac_dots"; then
12126 ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
12128 [\\/]* | ?:[\\/]* )
12129 ac_srcdir=$srcdir$ac_dir_suffix;
12130 ac_top_srcdir=$srcdir ;;
12131 *) # Relative path.
12132 ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
12133 ac_top_srcdir=$ac_dots$srcdir ;;
12137 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
12138 *) ac_INSTALL=$ac_dots$INSTALL ;;
12141 if test x"$ac_file" != x-; then
12142 { echo "$as_me:12142: creating $ac_file" >&5
12143 echo "$as_me: creating $ac_file" >&6;}
12146 # Let's still pretend it is `configure' which instantiates (i.e., don't
12147 # use $as_me), people would be surprised to read:
12148 # /* config.h. Generated automatically by config.status. */
12149 configure_input="Generated automatically from `echo $ac_file_in |
12150 sed 's,.*/,,'` by configure."
12152 # First look for the input files in the build tree, otherwise in the
12154 ac_file_inputs=`IFS=:
12155 for f in $ac_file_in; do
12157 -) echo $tmp/stdin ;;
12159 # Absolute (can't be DOS-style, as IFS=:)
12160 test -f "$f" || { { echo "$as_me:12160: error: cannot find input file: $f" >&5
12161 echo "$as_me: error: cannot find input file: $f" >&2;}
12162 { (exit 1); exit 1; }; }
12165 if test -f "$f"; then
12168 elif test -f "$srcdir/$f"; then
12173 { { echo "$as_me:12173: error: cannot find input file: $f" >&5
12174 echo "$as_me: error: cannot find input file: $f" >&2;}
12175 { (exit 1); exit 1; }; }
12178 done` || { (exit 1); exit 1; }
12180 cat >>$CONFIG_STATUS <<EOF
12184 cat >>$CONFIG_STATUS <<\EOF
12186 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
12187 s,@configure_input@,$configure_input,;t t
12188 s,@srcdir@,$ac_srcdir,;t t
12189 s,@top_srcdir@,$ac_top_srcdir,;t t
12190 s,@INSTALL@,$ac_INSTALL,;t t
12191 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
12193 if test x"$ac_file" != x-; then
12194 mv $tmp/out $ac_file
12202 cat >>$CONFIG_STATUS <<\EOF
12205 # CONFIG_HEADER section.
12208 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
12209 # NAME is the cpp macro being defined and VALUE is the value it is being given.
12211 # ac_d sets the value in "#define NAME VALUE" lines.
12212 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
12213 ac_dB='[ ].*$,\1#\2'
12216 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
12217 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
12218 ac_iB='\([ ]\),\1#\2define\3'
12221 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
12222 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
12223 ac_uB='$,\1#\2define\3'
12227 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
12228 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
12230 - | *:- | *:-:* ) # input from stdin
12232 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
12233 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
12234 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
12235 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
12236 * ) ac_file_in=$ac_file.in ;;
12239 test x"$ac_file" != x- && { echo "$as_me:12239: creating $ac_file" >&5
12240 echo "$as_me: creating $ac_file" >&6;}
12242 # First look for the input files in the build tree, otherwise in the
12244 ac_file_inputs=`IFS=:
12245 for f in $ac_file_in; do
12247 -) echo $tmp/stdin ;;
12249 # Absolute (can't be DOS-style, as IFS=:)
12250 test -f "$f" || { { echo "$as_me:12250: error: cannot find input file: $f" >&5
12251 echo "$as_me: error: cannot find input file: $f" >&2;}
12252 { (exit 1); exit 1; }; }
12255 if test -f "$f"; then
12258 elif test -f "$srcdir/$f"; then
12263 { { echo "$as_me:12263: error: cannot find input file: $f" >&5
12264 echo "$as_me: error: cannot find input file: $f" >&2;}
12265 { (exit 1); exit 1; }; }
12268 done` || { (exit 1); exit 1; }
12269 # Remove the trailing spaces.
12270 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
12274 # Transform confdefs.h into a list of #define's. We won't use it as a sed
12275 # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to
12276 # be either 'cat' or 'sort'.
12277 cat confdefs.h | uniq >conftest.vals
12279 # Break up conftest.vals because some shells have a limit on
12280 # the size of here documents, and old seds have small limits too.
12282 rm -f conftest.tail
12283 echo ' rm -f conftest.frag' >> $CONFIG_STATUS
12284 while grep . conftest.vals >/dev/null
12286 # Write chunks of a limited-size here document to conftest.frag.
12287 echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS
12288 sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS
12289 echo 'CEOF' >> $CONFIG_STATUS
12290 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
12291 rm -f conftest.vals
12292 mv conftest.tail conftest.vals
12294 rm -f conftest.vals
12296 # Run sed to substitute the contents of conftest.frag into $tmp/in at the
12298 echo ' cat >> conftest.edit <<CEOF
12299 /@DEFS@/r conftest.frag
12302 sed -f conftest.edit $tmp/in > $tmp/out
12304 mv $tmp/out $tmp/in
12305 rm -f conftest.edit conftest.frag
12306 ' >> $CONFIG_STATUS
12308 cat >>$CONFIG_STATUS <<\EOF
12309 # Let's still pretend it is `configure' which instantiates (i.e., don't
12310 # use $as_me), people would be surprised to read:
12311 # /* config.h. Generated automatically by config.status. */
12312 if test x"$ac_file" = x-; then
12313 echo "/* Generated automatically by configure. */" >$tmp/config.h
12315 echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h
12317 cat $tmp/in >>$tmp/config.h
12319 if test x"$ac_file" != x-; then
12320 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
12321 { echo "$as_me:12321: $ac_file is unchanged" >&5
12322 echo "$as_me: $ac_file is unchanged" >&6;}
12324 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
12325 X"$ac_file" : 'X\(//\)[^/]' \| \
12326 X"$ac_file" : 'X\(//\)$' \| \
12327 X"$ac_file" : 'X\(/\)' \| \
12328 . : '\(.\)' 2>/dev/null ||
12330 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
12331 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
12332 /^X\(\/\/\)$/{ s//\1/; q; }
12333 /^X\(\/\).*/{ s//\1/; q; }
12335 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
12336 { case "$ac_dir" in
12337 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
12341 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
12342 case $as_mkdir_dir in
12343 # Skip DOS drivespec
12344 ?:) as_incr_dir=$as_mkdir_dir ;;
12346 as_incr_dir=$as_incr_dir/$as_mkdir_dir
12347 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
12354 mv $tmp/config.h $ac_file
12358 rm -f $tmp/config.h
12362 cat >>$CONFIG_STATUS <<\EOF
12364 # CONFIG_COMMANDS section.
12366 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
12367 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
12368 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
12372 if test -z "$USE_OLD_MAKERULES" ; then
12373 $AWK -f $srcdir/mk-1st.awk <$srcdir/src/modules >>src/Makefile
12380 cat >>$CONFIG_STATUS <<\EOF
12382 { (exit 0); exit 0; }
12384 chmod +x $CONFIG_STATUS
12385 ac_clean_files=$ac_clean_files_save
12387 # configure is writing to config.log, and then calls config.status.
12388 # config.status does its own redirection, appending to config.log.
12389 # Unfortunately, on DOS this fails, as config.log is still kept open
12390 # by configure, so config.status won't be able to write to it; its
12391 # output is simply discarded. So we exec the FD to /dev/null,
12392 # effectively closing config.log, so it can be properly (re)opened and
12393 # appended to by config.status. When coming back to configure, we
12394 # need to make the FD available again.
12395 if test "$no_create" != yes; then
12398 $SHELL $CONFIG_STATUS || ac_cs_success=false
12400 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
12401 # would make configure fail if this is the last instruction.
12402 $ac_cs_success || { (exit 1); exit 1; }
12404 ${MAKE:-make} preinstall