2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.65.23-13e35 for gzip 1.4.
5 # Report bugs to <bug-gzip@gnu.org>.
8 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
9 # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software
13 # This configure script is free software; the Free Software Foundation
14 # gives unlimited permission to copy, distribute and modify it.
15 ## -------------------- ##
16 ## M4sh Initialization. ##
17 ## -------------------- ##
19 # Be more Bourne compatible
20 DUALCASE=1; export DUALCASE # for MKS sh
21 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
24 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
25 # is contrary to our usage. Disable this feature.
26 alias -g '${1+"$@"}'='"$@"'
29 case `(set -o) 2>/dev/null` in #(
41 # Printing a long string crashes Solaris 7 /usr/bin/printf.
42 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
43 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
44 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
45 # Prefer a ksh shell builtin over an external printf program on Solaris,
46 # but without wasting forks for bash or zsh.
47 if test -z "$BASH_VERSION$ZSH_VERSION" \
48 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
50 as_echo_n='print -rn --'
51 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
55 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
56 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
57 as_echo_n='/usr/ucb/echo -n'
59 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
64 expr "X$arg" : "X\\(.*\\)$as_nl";
65 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
67 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
70 as_echo_n='sh -c $as_echo_n_body as_echo'
73 as_echo='sh -c $as_echo_body as_echo'
76 # The user is always right.
77 if test "${PATH_SEPARATOR+set}" != set; then
79 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
80 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
87 # We need space, tab and new line, in precisely that order. Quoting is
88 # there to prevent editors from complaining about space-tab.
89 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
90 # splitting by setting IFS to empty value.)
93 # Find who we are. Look in the path if we contain no directory separator.
95 *[\\/]* ) as_myself=$0 ;;
96 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
100 test -z "$as_dir" && as_dir=.
101 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
107 # We did not find ourselves, most probably we were run as `sh COMMAND'
108 # in which case we are not to be found in the path.
109 if test "x$as_myself" = x; then
112 if test ! -f "$as_myself"; then
113 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
117 # Unset variables that we do not need and which cause bugs (e.g. in
118 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
119 # suppresses any "Segmentation fault" message there. '((' could
120 # trigger a bug in pdksh 5.2.14.
121 for as_var in BASH_ENV ENV MAIL MAILPATH
122 do eval test x\${$as_var+set} = xset \
123 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
136 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
138 if test "x$CONFIG_SHELL" = x; then
139 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
142 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
143 # is contrary to our usage. Disable this feature.
144 alias -g '\${1+\"\$@\"}'='\"\$@\"'
147 case \`(set -o) 2>/dev/null\` in #(
155 as_required="as_fn_return () { (exit \$1); }
156 as_fn_success () { as_fn_return 0; }
157 as_fn_failure () { as_fn_return 1; }
158 as_fn_ret_success () { return 0; }
159 as_fn_ret_failure () { return 1; }
162 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
163 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
164 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
165 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
166 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
169 exitcode=1; echo positional parameters were not saved.
171 test x\$exitcode = x0 || exit 1"
172 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
173 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
174 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
175 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
176 test \$(( 1 + 1 )) = 2 || exit 1"
177 if (eval "$as_required") 2>/dev/null; then :
182 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
185 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
187 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
190 test -z "$as_dir" && as_dir=.
194 for as_base in sh bash ksh sh5; do
195 # Try only shells that exist, to save several forks.
196 as_shell=$as_dir/$as_base
197 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
198 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
199 CONFIG_SHELL=$as_shell as_have_required=yes
200 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
208 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
209 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
210 CONFIG_SHELL=$SHELL as_have_required=yes
215 if test "x$CONFIG_SHELL" != x; then :
216 # We cannot yet assume a decent shell, so we have to provide a
217 # neutralization value for shells without unset; and this also
218 # works around shells that cannot unset nonexistent variables.
221 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
223 exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
226 if test x$as_have_required = xno; then :
227 $as_echo "$0: This script requires a shell more modern than all"
228 $as_echo "$0: the shells that I found on your system."
229 if test x${ZSH_VERSION+set} = xset ; then
230 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
231 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
233 $as_echo "$0: Please tell bug-autoconf@gnu.org and bug-gzip@gnu.org
234 $0: about your system, including any error possibly output
235 $0: before this message. Then install a modern shell, or
236 $0: manually run the script under such a shell if you do
243 SHELL=${CONFIG_SHELL-/bin/sh}
245 # Unset more variables known to interfere with behavior of common tools.
246 CLICOLOR_FORCE= GREP_OPTIONS=
247 unset CLICOLOR_FORCE GREP_OPTIONS
249 ## --------------------- ##
250 ## M4sh Shell Functions. ##
251 ## --------------------- ##
254 # Portably unset VAR.
257 { eval $1=; unset $1;}
261 # as_fn_set_status STATUS
262 # -----------------------
263 # Set $? to STATUS, without forking.
271 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
281 # Create "$as_dir" as a directory, including parents if necessary.
286 -*) as_dir=./$as_dir;;
288 test -d "$as_dir" || eval $as_mkdir_p || {
292 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
295 as_dirs="'$as_qdir' $as_dirs"
296 as_dir=`$as_dirname -- "$as_dir" ||
297 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
298 X"$as_dir" : 'X\(//\)[^/]' \| \
299 X"$as_dir" : 'X\(//\)$' \| \
300 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
301 $as_echo X"$as_dir" |
302 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
319 test -d "$as_dir" && break
321 test -z "$as_dirs" || eval "mkdir $as_dirs"
322 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
326 # as_fn_append VAR VALUE
327 # ----------------------
328 # Append the text in VALUE to the end of the definition contained in VAR. Take
329 # advantage of any shell optimizations that allow amortized linear growth over
330 # repeated appends, instead of the typical quadratic growth present in naive
332 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
333 eval 'as_fn_append ()
346 # Perform arithmetic evaluation on the ARGs, and store the result in the
347 # global $as_val. Take advantage of shells that can avoid forks. The arguments
348 # must be portable across $(()) and expr.
349 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
357 as_val=`expr "$@" || test $? -eq 1`
362 # as_fn_error ERROR [LINENO LOG_FD]
363 # ---------------------------------
364 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
365 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
366 # script with status $?, using 1 if that was 0.
369 as_status=$?; test $as_status -eq 0 && as_status=1
371 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
372 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
374 $as_echo "$as_me: error: $1" >&2
375 as_fn_exit $as_status
378 if expr a : '\(a\)' >/dev/null 2>&1 &&
379 test "X`expr 00001 : '.*\(...\)'`" = X001; then
385 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
391 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
397 as_me=`$as_basename -- "$0" ||
398 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
399 X"$0" : 'X\(//\)$' \| \
400 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
402 sed '/^.*\/\([^/][^/]*\)\/*$/{
416 # Avoid depending upon Character Ranges.
417 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
418 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
419 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
420 as_cr_digits='0123456789'
421 as_cr_alnum=$as_cr_Letters$as_cr_digits
424 as_lineno_1=$LINENO as_lineno_1a=$LINENO
425 as_lineno_2=$LINENO as_lineno_2a=$LINENO
426 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
427 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
428 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
440 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
444 chmod +x "$as_me.lineno" ||
445 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
447 # Don't try to exec as it changes $[0], causing all sort of problems
448 # (the dirname of $[0] is not the place where we might find the
449 # original and so on. Autoconf is especially sensitive to this).
451 # Exit status is that of the last command.
455 ECHO_C= ECHO_N= ECHO_T=
456 case `echo -n x` in #(((((
458 case `echo 'xy\c'` in
459 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
461 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
468 rm -f conf$$ conf$$.exe conf$$.file
469 if test -d conf$$.dir; then
470 rm -f conf$$.dir/conf$$.file
473 mkdir conf$$.dir 2>/dev/null
475 if (echo >conf$$.file) 2>/dev/null; then
476 if ln -s conf$$.file conf$$ 2>/dev/null; then
478 # ... but there are two gotchas:
479 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
480 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
481 # In both cases, we have to default to `cp -p'.
482 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
484 elif ln conf$$.file conf$$ 2>/dev/null; then
492 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
493 rmdir conf$$.dir 2>/dev/null
495 if mkdir -p . 2>/dev/null; then
496 as_mkdir_p='mkdir -p "$as_dir"'
498 test -d ./-p && rmdir ./-p
502 if test -x / >/dev/null 2>&1; then
505 if ls -dL / >/dev/null 2>&1; then
512 if test -d "$1"; then
518 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
519 ???[sx]*):;;*)false;;esac;fi
523 as_executable_p=$as_test_x
525 # Sed expression to map a string onto a valid CPP name.
526 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
528 # Sed expression to map a string onto a valid variable name.
529 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
532 test -n "$DJDIR" || exec 7<&0 </dev/null
536 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
537 # so uname gets run too.
538 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
543 ac_default_prefix=/usr/local
545 ac_config_libobj_dir=.
552 # Identity of this package.
554 PACKAGE_TARNAME='gzip'
555 PACKAGE_VERSION='1.4'
556 PACKAGE_STRING='gzip 1.4'
557 PACKAGE_BUGREPORT='bug-gzip@gnu.org'
560 ac_unique_file="gzip.c"
561 # Factoring default headers for most tests.
562 ac_includes_default="\
564 #ifdef HAVE_SYS_TYPES_H
565 # include <sys/types.h>
567 #ifdef HAVE_SYS_STAT_H
568 # include <sys/stat.h>
574 # ifdef HAVE_STDLIB_H
579 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
584 #ifdef HAVE_STRINGS_H
585 # include <strings.h>
587 #ifdef HAVE_INTTYPES_H
588 # include <inttypes.h>
599 gl_getopt_required=POSIX
600 gl_getopt_required=POSIX
601 ac_subst_vars='gltests_LTLIBOBJS
619 NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H
624 NEXT_AS_FIRST_DIRECTIVE_WCHAR_H
628 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
630 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
631 TIME_H_DEFINES_STRUCT_TIMESPEC
632 NEXT_AS_FIRST_DIRECTIVE_TIME_H
639 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
641 NEXT_AS_FIRST_DIRECTIVE_STRING_H
644 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
646 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
656 HAVE_SIGNED_SIG_ATOMIC_T
659 BITSIZEOF_SIG_ATOMIC_T
665 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
669 HAVE_UNSIGNED_LONG_LONG_INT
671 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
776 NEXT_AS_FIRST_DIRECTIVE_MATH_H
778 LOCALCHARSET_TESTS_ENVIRONMENT
786 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
792 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H
795 REPLACE_SIGNBIT_USING_GCC
866 APPLE_UNIVERSAL_BUILD
868 NEXT_AS_FIRST_DIRECTIVE_FLOAT_H
870 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H
878 REPLACE_STDIO_WRITE_FUNCS
887 REPLACE_OBSTACK_PRINTF
906 HAVE_DECL_OBSTACK_PRINTF
910 GNULIB_VSPRINTF_POSIX
914 GNULIB_VFPRINTF_POSIX
918 GNULIB_STDIO_H_SIGPIPE
931 GNULIB_OBSTACK_PRINTF_POSIX
932 GNULIB_OBSTACK_PRINTF
997 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H
999 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H
1001 PRAGMA_SYSTEM_HEADER
1002 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
1016 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
1017 UNISTD_H_HAVE_WINSOCK2_H
1044 HAVE_DECL_GETLOGIN_R
1075 GNULIB_UNISTD_H_SIGPIPE
1076 GNULIB_UNISTD_H_GETOPT
1095 GNULIB_GETDTABLESIZE
1096 GNULIB_GETDOMAINNAME
1115 REPLACE_CANONICALIZE_FILE_NAME
1118 HAVE_STRUCT_RANDOM_DATA
1133 HAVE_DECL_GETLOADAVG
1134 HAVE_CANONICALIZE_FILE_NAME
1143 GNULIB_REALLOC_POSIX
1154 GNULIB_CANONICALIZE_FILE_NAME
1160 GL_COND_LIBTOOL_FALSE
1161 GL_COND_LIBTOOL_TRUE
1193 AM_DEFAULT_VERBOSITY
1202 INSTALL_STRIP_PROGRAM
1244 program_transform_name
1257 enable_option_checking
1259 enable_dependency_tracking
1263 ac_precious_vars='build_alias
1274 # Initialize some variables set by options.
1276 ac_init_version=false
1277 ac_unrecognized_opts=
1278 ac_unrecognized_sep=
1279 # The variables have the same names as the options, with
1280 # dashes changed to underlines.
1281 cache_file=/dev/null
1288 program_transform_name=s,x,x,
1296 # Installation directory options.
1297 # These are left unexpanded so users can "make install exec_prefix=/foo"
1298 # and all the variables that are supposed to be based on exec_prefix
1299 # by default will actually change.
1300 # Use braces instead of parens because sh, perl, etc. also accept them.
1301 # (The list follows the same order as the GNU Coding Standards.)
1302 bindir='${exec_prefix}/bin'
1303 sbindir='${exec_prefix}/sbin'
1304 libexecdir='${exec_prefix}/libexec'
1305 datarootdir='${prefix}/share'
1306 datadir='${datarootdir}'
1307 sysconfdir='${prefix}/etc'
1308 sharedstatedir='${prefix}/com'
1309 localstatedir='${prefix}/var'
1310 includedir='${prefix}/include'
1311 oldincludedir='/usr/include'
1312 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1313 infodir='${datarootdir}/info'
1318 libdir='${exec_prefix}/lib'
1319 localedir='${datarootdir}/locale'
1320 mandir='${datarootdir}/man'
1326 # If the previous option needs an argument, assign it.
1327 if test -n "$ac_prev"; then
1328 eval $ac_prev=\$ac_option
1334 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1338 # Accept the important Cygnus configure options, so we can diagnose typos.
1340 case $ac_dashdash$ac_option in
1344 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1346 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1347 bindir=$ac_optarg ;;
1349 -build | --build | --buil | --bui | --bu)
1350 ac_prev=build_alias ;;
1351 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1352 build_alias=$ac_optarg ;;
1354 -cache-file | --cache-file | --cache-fil | --cache-fi \
1355 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1356 ac_prev=cache_file ;;
1357 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1358 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1359 cache_file=$ac_optarg ;;
1361 --config-cache | -C)
1362 cache_file=config.cache ;;
1364 -datadir | --datadir | --datadi | --datad)
1366 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1367 datadir=$ac_optarg ;;
1369 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1370 | --dataroo | --dataro | --datar)
1371 ac_prev=datarootdir ;;
1372 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1373 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1374 datarootdir=$ac_optarg ;;
1376 -disable-* | --disable-*)
1377 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1378 # Reject names that are not valid shell variable names.
1379 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1380 as_fn_error "invalid feature name: $ac_useropt"
1381 ac_useropt_orig=$ac_useropt
1382 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1383 case $ac_user_opts in
1385 "enable_$ac_useropt"
1387 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1388 ac_unrecognized_sep=', ';;
1390 eval enable_$ac_useropt=no ;;
1392 -docdir | --docdir | --docdi | --doc | --do)
1394 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1395 docdir=$ac_optarg ;;
1397 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1399 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1400 dvidir=$ac_optarg ;;
1402 -enable-* | --enable-*)
1403 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1404 # Reject names that are not valid shell variable names.
1405 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1406 as_fn_error "invalid feature name: $ac_useropt"
1407 ac_useropt_orig=$ac_useropt
1408 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1409 case $ac_user_opts in
1411 "enable_$ac_useropt"
1413 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1414 ac_unrecognized_sep=', ';;
1416 eval enable_$ac_useropt=\$ac_optarg ;;
1418 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1419 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1420 | --exec | --exe | --ex)
1421 ac_prev=exec_prefix ;;
1422 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1423 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1424 | --exec=* | --exe=* | --ex=*)
1425 exec_prefix=$ac_optarg ;;
1427 -gas | --gas | --ga | --g)
1428 # Obsolete; use --with-gas.
1431 -help | --help | --hel | --he | -h)
1432 ac_init_help=long ;;
1433 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1434 ac_init_help=recursive ;;
1435 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1436 ac_init_help=short ;;
1438 -host | --host | --hos | --ho)
1439 ac_prev=host_alias ;;
1440 -host=* | --host=* | --hos=* | --ho=*)
1441 host_alias=$ac_optarg ;;
1443 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1445 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1447 htmldir=$ac_optarg ;;
1449 -includedir | --includedir | --includedi | --included | --include \
1450 | --includ | --inclu | --incl | --inc)
1451 ac_prev=includedir ;;
1452 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1453 | --includ=* | --inclu=* | --incl=* | --inc=*)
1454 includedir=$ac_optarg ;;
1456 -infodir | --infodir | --infodi | --infod | --info | --inf)
1458 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1459 infodir=$ac_optarg ;;
1461 -libdir | --libdir | --libdi | --libd)
1463 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1464 libdir=$ac_optarg ;;
1466 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1467 | --libexe | --libex | --libe)
1468 ac_prev=libexecdir ;;
1469 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1470 | --libexe=* | --libex=* | --libe=*)
1471 libexecdir=$ac_optarg ;;
1473 -localedir | --localedir | --localedi | --localed | --locale)
1474 ac_prev=localedir ;;
1475 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1476 localedir=$ac_optarg ;;
1478 -localstatedir | --localstatedir | --localstatedi | --localstated \
1479 | --localstate | --localstat | --localsta | --localst | --locals)
1480 ac_prev=localstatedir ;;
1481 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1482 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1483 localstatedir=$ac_optarg ;;
1485 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1487 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1488 mandir=$ac_optarg ;;
1490 -nfp | --nfp | --nf)
1491 # Obsolete; use --without-fp.
1494 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1495 | --no-cr | --no-c | -n)
1498 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1499 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1502 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1503 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1504 | --oldin | --oldi | --old | --ol | --o)
1505 ac_prev=oldincludedir ;;
1506 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1507 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1508 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1509 oldincludedir=$ac_optarg ;;
1511 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1513 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1514 prefix=$ac_optarg ;;
1516 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1517 | --program-pre | --program-pr | --program-p)
1518 ac_prev=program_prefix ;;
1519 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1520 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1521 program_prefix=$ac_optarg ;;
1523 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1524 | --program-suf | --program-su | --program-s)
1525 ac_prev=program_suffix ;;
1526 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1527 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1528 program_suffix=$ac_optarg ;;
1530 -program-transform-name | --program-transform-name \
1531 | --program-transform-nam | --program-transform-na \
1532 | --program-transform-n | --program-transform- \
1533 | --program-transform | --program-transfor \
1534 | --program-transfo | --program-transf \
1535 | --program-trans | --program-tran \
1536 | --progr-tra | --program-tr | --program-t)
1537 ac_prev=program_transform_name ;;
1538 -program-transform-name=* | --program-transform-name=* \
1539 | --program-transform-nam=* | --program-transform-na=* \
1540 | --program-transform-n=* | --program-transform-=* \
1541 | --program-transform=* | --program-transfor=* \
1542 | --program-transfo=* | --program-transf=* \
1543 | --program-trans=* | --program-tran=* \
1544 | --progr-tra=* | --program-tr=* | --program-t=*)
1545 program_transform_name=$ac_optarg ;;
1547 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1549 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1550 pdfdir=$ac_optarg ;;
1552 -psdir | --psdir | --psdi | --psd | --ps)
1554 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1557 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1558 | -silent | --silent | --silen | --sile | --sil)
1561 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1563 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1565 sbindir=$ac_optarg ;;
1567 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1568 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1569 | --sharedst | --shareds | --shared | --share | --shar \
1571 ac_prev=sharedstatedir ;;
1572 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1573 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1574 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1576 sharedstatedir=$ac_optarg ;;
1578 -site | --site | --sit)
1580 -site=* | --site=* | --sit=*)
1583 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1585 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1586 srcdir=$ac_optarg ;;
1588 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1589 | --syscon | --sysco | --sysc | --sys | --sy)
1590 ac_prev=sysconfdir ;;
1591 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1592 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1593 sysconfdir=$ac_optarg ;;
1595 -target | --target | --targe | --targ | --tar | --ta | --t)
1596 ac_prev=target_alias ;;
1597 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1598 target_alias=$ac_optarg ;;
1600 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1603 -version | --version | --versio | --versi | --vers | -V)
1604 ac_init_version=: ;;
1607 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1608 # Reject names that are not valid shell variable names.
1609 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1610 as_fn_error "invalid package name: $ac_useropt"
1611 ac_useropt_orig=$ac_useropt
1612 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1613 case $ac_user_opts in
1617 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1618 ac_unrecognized_sep=', ';;
1620 eval with_$ac_useropt=\$ac_optarg ;;
1622 -without-* | --without-*)
1623 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1624 # Reject names that are not valid shell variable names.
1625 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1626 as_fn_error "invalid package name: $ac_useropt"
1627 ac_useropt_orig=$ac_useropt
1628 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1629 case $ac_user_opts in
1633 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1634 ac_unrecognized_sep=', ';;
1636 eval with_$ac_useropt=no ;;
1639 # Obsolete; use --with-x.
1642 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1643 | --x-incl | --x-inc | --x-in | --x-i)
1644 ac_prev=x_includes ;;
1645 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1646 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1647 x_includes=$ac_optarg ;;
1649 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1650 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1651 ac_prev=x_libraries ;;
1652 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1653 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1654 x_libraries=$ac_optarg ;;
1656 -*) as_fn_error "unrecognized option: \`$ac_option'
1657 Try \`$0 --help' for more information."
1661 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1662 # Reject names that are not valid shell variable names.
1663 case $ac_envvar in #(
1664 '' | [0-9]* | *[!_$as_cr_alnum]* )
1665 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1667 eval $ac_envvar=\$ac_optarg
1668 export $ac_envvar ;;
1671 # FIXME: should be removed in autoconf 3.0.
1672 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1673 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1674 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1675 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1681 if test -n "$ac_prev"; then
1682 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1683 as_fn_error "missing argument to $ac_option"
1686 if test -n "$ac_unrecognized_opts"; then
1687 case $enable_option_checking in
1689 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1690 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1694 # Check all directory arguments for consistency.
1695 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1696 datadir sysconfdir sharedstatedir localstatedir includedir \
1697 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1698 libdir localedir mandir
1700 eval ac_val=\$$ac_var
1701 # Remove trailing slashes.
1704 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1705 eval $ac_var=\$ac_val;;
1707 # Be sure to have absolute directory names.
1709 [\\/$]* | ?:[\\/]* ) continue;;
1710 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1712 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
1715 # There might be people who depend on the old broken behavior: `$host'
1716 # used to hold the argument of --host etc.
1717 # FIXME: To remove some day.
1720 target=$target_alias
1722 # FIXME: To remove some day.
1723 if test "x$host_alias" != x; then
1724 if test "x$build_alias" = x; then
1725 cross_compiling=maybe
1726 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1727 If a cross compiler is detected then cross compile mode will be used." >&2
1728 elif test "x$build_alias" != "x$host_alias"; then
1734 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1736 test "$silent" = yes && exec 6>/dev/null
1739 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1740 ac_ls_di=`ls -di .` &&
1741 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1742 as_fn_error "working directory cannot be determined"
1743 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1744 as_fn_error "pwd does not report name of working directory"
1747 # Find the source files, if location was not specified.
1748 if test -z "$srcdir"; then
1749 ac_srcdir_defaulted=yes
1750 # Try the directory containing this script, then the parent directory.
1751 ac_confdir=`$as_dirname -- "$as_myself" ||
1752 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1753 X"$as_myself" : 'X\(//\)[^/]' \| \
1754 X"$as_myself" : 'X\(//\)$' \| \
1755 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1756 $as_echo X"$as_myself" |
1757 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1775 if test ! -r "$srcdir/$ac_unique_file"; then
1779 ac_srcdir_defaulted=no
1781 if test ! -r "$srcdir/$ac_unique_file"; then
1782 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1783 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
1785 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1787 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
1789 # When building in place, set srcdir=.
1790 if test "$ac_abs_confdir" = "$ac_pwd"; then
1793 # Remove unnecessary trailing slashes from srcdir.
1794 # Double slashes in file names in object file debugging info
1795 # mess up M-x gdb in Emacs.
1797 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1799 for ac_var in $ac_precious_vars; do
1800 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1801 eval ac_env_${ac_var}_value=\$${ac_var}
1802 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1803 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1807 # Report the --help message.
1809 if test "$ac_init_help" = "long"; then
1810 # Omit some internal or obsolete options to make the list less imposing.
1811 # This message is too long to be a string in the A/UX 3.1 sh.
1813 \`configure' configures gzip 1.4 to adapt to many kinds of systems.
1815 Usage: $0 [OPTION]... [VAR=VALUE]...
1817 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1818 VAR=VALUE. See below for descriptions of some of the useful variables.
1820 Defaults for the options are specified in brackets.
1823 -h, --help display this help and exit
1824 --help=short display options specific to this package
1825 --help=recursive display the short help of all the included packages
1826 -V, --version display version information and exit
1827 -q, --quiet, --silent do not print \`checking...' messages
1828 --cache-file=FILE cache test results in FILE [disabled]
1829 -C, --config-cache alias for \`--cache-file=config.cache'
1830 -n, --no-create do not create output files
1831 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1833 Installation directories:
1834 --prefix=PREFIX install architecture-independent files in PREFIX
1835 [$ac_default_prefix]
1836 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1839 By default, \`make install' will install all the files in
1840 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1841 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1842 for instance \`--prefix=\$HOME'.
1844 For better control, use the options below.
1846 Fine tuning of the installation directories:
1847 --bindir=DIR user executables [EPREFIX/bin]
1848 --sbindir=DIR system admin executables [EPREFIX/sbin]
1849 --libexecdir=DIR program executables [EPREFIX/libexec]
1850 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1851 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1852 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1853 --libdir=DIR object code libraries [EPREFIX/lib]
1854 --includedir=DIR C header files [PREFIX/include]
1855 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1856 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1857 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1858 --infodir=DIR info documentation [DATAROOTDIR/info]
1859 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1860 --mandir=DIR man documentation [DATAROOTDIR/man]
1861 --docdir=DIR documentation root [DATAROOTDIR/doc/gzip]
1862 --htmldir=DIR html documentation [DOCDIR]
1863 --dvidir=DIR dvi documentation [DOCDIR]
1864 --pdfdir=DIR pdf documentation [DOCDIR]
1865 --psdir=DIR ps documentation [DOCDIR]
1871 --program-prefix=PREFIX prepend PREFIX to installed program names
1872 --program-suffix=SUFFIX append SUFFIX to installed program names
1873 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1876 --build=BUILD configure for building on BUILD [guessed]
1877 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1881 if test -n "$ac_init_help"; then
1882 case $ac_init_help in
1883 short | recursive ) echo "Configuration of gzip 1.4:";;
1888 --disable-option-checking ignore unrecognized --enable/--with options
1889 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1890 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1891 --enable-silent-rules less verbose build output (undo: `make V=1')
1892 --disable-silent-rules verbose build output (undo: `make V=0')
1893 --disable-dependency-tracking speeds up one-time build
1894 --enable-dependency-tracking do not reject slow dependency extractors
1895 --disable-largefile omit support for large files
1896 --enable-gcc-warnings turn on lots of GCC warnings (for developers)
1898 Some influential environment variables:
1899 CC C compiler command
1900 CFLAGS C compiler flags
1901 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1902 nonstandard directory <lib dir>
1903 LIBS libraries to pass to the linker, e.g. -l<library>
1904 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1905 you have headers in a nonstandard directory <include dir>
1908 Use these variables to override the choices made by `configure' or to help
1909 it to find libraries and programs with nonstandard names/locations.
1911 Report bugs to <bug-gzip@gnu.org>.
1916 if test "$ac_init_help" = "recursive"; then
1917 # If there are subdirs, report their specific --help.
1918 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1919 test -d "$ac_dir" ||
1920 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1925 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1927 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1928 # A ".." for each directory in $ac_dir_suffix.
1929 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1930 case $ac_top_builddir_sub in
1931 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1932 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1935 ac_abs_top_builddir=$ac_pwd
1936 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1937 # for backward compatibility:
1938 ac_top_builddir=$ac_top_build_prefix
1941 .) # We are building in place.
1943 ac_top_srcdir=$ac_top_builddir_sub
1944 ac_abs_top_srcdir=$ac_pwd ;;
1945 [\\/]* | ?:[\\/]* ) # Absolute name.
1946 ac_srcdir=$srcdir$ac_dir_suffix;
1947 ac_top_srcdir=$srcdir
1948 ac_abs_top_srcdir=$srcdir ;;
1950 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1951 ac_top_srcdir=$ac_top_build_prefix$srcdir
1952 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1954 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1956 cd "$ac_dir" || { ac_status=$?; continue; }
1957 # Check for guested configure.
1958 if test -f "$ac_srcdir/configure.gnu"; then
1960 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1961 elif test -f "$ac_srcdir/configure"; then
1963 $SHELL "$ac_srcdir/configure" --help=recursive
1965 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1967 cd "$ac_pwd" || { ac_status=$?; break; }
1971 test -n "$ac_init_help" && exit $ac_status
1972 if $ac_init_version; then
1975 generated by GNU Autoconf 2.65.23-13e35
1977 Copyright (C) 2010 Free Software Foundation, Inc.
1978 This configure script is free software; the Free Software Foundation
1979 gives unlimited permission to copy, distribute and modify it.
1984 ## ------------------------ ##
1985 ## Autoconf initialization. ##
1986 ## ------------------------ ##
1988 # ac_fn_c_try_compile LINENO
1989 # --------------------------
1990 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1991 ac_fn_c_try_compile ()
1993 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1994 rm -f conftest.$ac_objext
1995 if { { ac_try="$ac_compile"
1997 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1998 *) ac_try_echo=$ac_try;;
2000 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2001 $as_echo "$ac_try_echo"; } >&5
2002 (eval "$ac_compile") 2>conftest.err
2004 if test -s conftest.err; then
2005 grep -v '^ *+' conftest.err >conftest.er1
2006 cat conftest.er1 >&5
2007 mv -f conftest.er1 conftest.err
2009 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2010 test $ac_status = 0; } && {
2011 test -z "$ac_c_werror_flag" ||
2012 test ! -s conftest.err
2013 } && test -s conftest.$ac_objext; then :
2016 $as_echo "$as_me: failed program was:" >&5
2017 sed 's/^/| /' conftest.$ac_ext >&5
2021 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2022 as_fn_set_status $ac_retval
2024 } # ac_fn_c_try_compile
2026 # ac_fn_c_try_cpp LINENO
2027 # ----------------------
2028 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2031 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2032 if { { ac_try="$ac_cpp conftest.$ac_ext"
2034 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2035 *) ac_try_echo=$ac_try;;
2037 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2038 $as_echo "$ac_try_echo"; } >&5
2039 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2041 if test -s conftest.err; then
2042 grep -v '^ *+' conftest.err >conftest.er1
2043 cat conftest.er1 >&5
2044 mv -f conftest.er1 conftest.err
2046 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2047 test $ac_status = 0; } >/dev/null && {
2048 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2049 test ! -s conftest.err
2053 $as_echo "$as_me: failed program was:" >&5
2054 sed 's/^/| /' conftest.$ac_ext >&5
2058 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2059 as_fn_set_status $ac_retval
2063 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2064 # -------------------------------------------------------
2065 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2066 # the include files in INCLUDES and setting the cache variable VAR
2068 ac_fn_c_check_header_mongrel ()
2070 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2071 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2073 $as_echo_n "checking for $2... " >&6; }
2074 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2075 $as_echo_n "(cached) " >&6
2078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2079 $as_echo "$ac_res" >&6; }
2081 # Is the header compilable?
2082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2083 $as_echo_n "checking $2 usability... " >&6; }
2084 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2085 /* end confdefs.h. */
2089 if ac_fn_c_try_compile "$LINENO"; then :
2090 ac_header_compiler=yes
2092 ac_header_compiler=no
2094 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2096 $as_echo "$ac_header_compiler" >&6; }
2098 # Is the header present?
2099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2100 $as_echo_n "checking $2 presence... " >&6; }
2101 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2102 /* end confdefs.h. */
2105 if ac_fn_c_try_cpp "$LINENO"; then :
2106 ac_header_preproc=yes
2108 ac_header_preproc=no
2110 rm -f conftest.err conftest.$ac_ext
2111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2112 $as_echo "$ac_header_preproc" >&6; }
2114 # So? What about this header?
2115 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2117 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2118 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2119 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2120 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2123 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2124 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2125 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2126 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2127 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2128 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2129 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2130 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2131 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2132 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2134 ## ------------------------------- ##
2135 ## Report this to bug-gzip@gnu.org ##
2136 ## ------------------------------- ##
2138 ) | sed "s/^/$as_me: WARNING: /" >&2
2141 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2142 $as_echo_n "checking for $2... " >&6; }
2143 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2144 $as_echo_n "(cached) " >&6
2146 eval "$3=\$ac_header_compiler"
2149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2150 $as_echo "$ac_res" >&6; }
2152 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2154 } # ac_fn_c_check_header_mongrel
2156 # ac_fn_c_try_run LINENO
2157 # ----------------------
2158 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2159 # that executables *can* be run.
2162 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2163 if { { ac_try="$ac_link"
2165 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2166 *) ac_try_echo=$ac_try;;
2168 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2169 $as_echo "$ac_try_echo"; } >&5
2170 (eval "$ac_link") 2>&5
2172 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2173 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2174 { { case "(($ac_try" in
2175 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2176 *) ac_try_echo=$ac_try;;
2178 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2179 $as_echo "$ac_try_echo"; } >&5
2180 (eval "$ac_try") 2>&5
2182 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2183 test $ac_status = 0; }; }; then :
2186 $as_echo "$as_me: program exited with status $ac_status" >&5
2187 $as_echo "$as_me: failed program was:" >&5
2188 sed 's/^/| /' conftest.$ac_ext >&5
2190 ac_retval=$ac_status
2192 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2193 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2194 as_fn_set_status $ac_retval
2198 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2199 # -------------------------------------------------------
2200 # Tests whether HEADER exists and can be compiled using the include files in
2201 # INCLUDES, setting the cache variable VAR accordingly.
2202 ac_fn_c_check_header_compile ()
2204 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2205 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2206 $as_echo_n "checking for $2... " >&6; }
2207 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2208 $as_echo_n "(cached) " >&6
2210 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2211 /* end confdefs.h. */
2215 if ac_fn_c_try_compile "$LINENO"; then :
2220 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2224 $as_echo "$ac_res" >&6; }
2225 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2227 } # ac_fn_c_check_header_compile
2229 # ac_fn_c_try_link LINENO
2230 # -----------------------
2231 # Try to link conftest.$ac_ext, and return whether this succeeded.
2234 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2235 rm -f conftest.$ac_objext conftest$ac_exeext
2236 if { { ac_try="$ac_link"
2238 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2239 *) ac_try_echo=$ac_try;;
2241 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2242 $as_echo "$ac_try_echo"; } >&5
2243 (eval "$ac_link") 2>conftest.err
2245 if test -s conftest.err; then
2246 grep -v '^ *+' conftest.err >conftest.er1
2247 cat conftest.er1 >&5
2248 mv -f conftest.er1 conftest.err
2250 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2251 test $ac_status = 0; } && {
2252 test -z "$ac_c_werror_flag" ||
2253 test ! -s conftest.err
2254 } && test -s conftest$ac_exeext && {
2255 test "$cross_compiling" = yes ||
2256 $as_test_x conftest$ac_exeext
2260 $as_echo "$as_me: failed program was:" >&5
2261 sed 's/^/| /' conftest.$ac_ext >&5
2265 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2266 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2267 # interfere with the next link command; also delete a directory that is
2268 # left behind by Apple's compiler. We do this before executing the actions.
2269 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2270 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2271 as_fn_set_status $ac_retval
2273 } # ac_fn_c_try_link
2275 # ac_fn_c_check_func LINENO FUNC VAR
2276 # ----------------------------------
2277 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2278 ac_fn_c_check_func ()
2280 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2282 $as_echo_n "checking for $2... " >&6; }
2283 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2284 $as_echo_n "(cached) " >&6
2286 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2287 /* end confdefs.h. */
2288 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2289 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2290 #define $2 innocuous_$2
2292 /* System header to define __stub macros and hopefully few prototypes,
2293 which can conflict with char $2 (); below.
2294 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2295 <limits.h> exists even on freestanding compilers. */
2298 # include <limits.h>
2300 # include <assert.h>
2305 /* Override any GCC internal prototype to avoid an error.
2306 Use char because int might match the return type of a GCC
2307 builtin and then its argument prototype would still apply. */
2312 /* The GNU C library defines this for functions which it implements
2313 to always fail with ENOSYS. Some functions are actually named
2314 something starting with __ and the normal name is an alias. */
2315 #if defined __stub_$2 || defined __stub___$2
2327 if ac_fn_c_try_link "$LINENO"; then :
2332 rm -f core conftest.err conftest.$ac_objext \
2333 conftest$ac_exeext conftest.$ac_ext
2336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2337 $as_echo "$ac_res" >&6; }
2338 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2340 } # ac_fn_c_check_func
2342 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2343 # -------------------------------------------
2344 # Tests whether TYPE exists after having included INCLUDES, setting cache
2345 # variable VAR accordingly.
2346 ac_fn_c_check_type ()
2348 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2349 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2350 $as_echo_n "checking for $2... " >&6; }
2351 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2352 $as_echo_n "(cached) " >&6
2355 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2356 /* end confdefs.h. */
2367 if ac_fn_c_try_compile "$LINENO"; then :
2368 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2369 /* end confdefs.h. */
2380 if ac_fn_c_try_compile "$LINENO"; then :
2385 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2387 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2391 $as_echo "$ac_res" >&6; }
2392 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2394 } # ac_fn_c_check_type
2396 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2397 # ---------------------------------------------
2398 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2400 ac_fn_c_check_decl ()
2402 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2403 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
2404 $as_echo_n "checking whether $2 is declared... " >&6; }
2405 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2406 $as_echo_n "(cached) " >&6
2408 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2409 /* end confdefs.h. */
2422 if ac_fn_c_try_compile "$LINENO"; then :
2427 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2431 $as_echo "$ac_res" >&6; }
2432 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2434 } # ac_fn_c_check_decl
2436 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2437 # --------------------------------------------
2438 # Tries to find the compile-time value of EXPR in a program that includes
2439 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2441 ac_fn_c_compute_int ()
2443 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2444 if test "$cross_compiling" = yes; then
2445 # Depending upon the size, compute the lo and hi bounds.
2446 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2447 /* end confdefs.h. */
2452 static int test_array [1 - 2 * !(($2) >= 0)];
2459 if ac_fn_c_try_compile "$LINENO"; then :
2462 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2463 /* end confdefs.h. */
2468 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2475 if ac_fn_c_try_compile "$LINENO"; then :
2476 ac_hi=$ac_mid; break
2478 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2479 if test $ac_lo -le $ac_mid; then
2483 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2485 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2488 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2489 /* end confdefs.h. */
2494 static int test_array [1 - 2 * !(($2) < 0)];
2501 if ac_fn_c_try_compile "$LINENO"; then :
2504 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2505 /* end confdefs.h. */
2510 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2517 if ac_fn_c_try_compile "$LINENO"; then :
2518 ac_lo=$ac_mid; break
2520 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2521 if test $ac_mid -le $ac_hi; then
2525 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2527 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2532 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2534 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2535 # Binary search between lo and hi bounds.
2536 while test "x$ac_lo" != "x$ac_hi"; do
2537 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2538 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2539 /* end confdefs.h. */
2544 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2551 if ac_fn_c_try_compile "$LINENO"; then :
2554 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2556 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2559 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2563 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2564 /* end confdefs.h. */
2566 static long int longval () { return $2; }
2567 static unsigned long int ulongval () { return $2; }
2574 FILE *f = fopen ("conftest.val", "w");
2579 long int i = longval ();
2582 fprintf (f, "%ld", i);
2586 unsigned long int i = ulongval ();
2589 fprintf (f, "%lu", i);
2591 /* Do not output a trailing newline, as this causes \r\n confusion
2592 on some platforms. */
2593 return ferror (f) || fclose (f) != 0;
2599 if ac_fn_c_try_run "$LINENO"; then :
2600 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2604 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2605 conftest.$ac_objext conftest.beam conftest.$ac_ext
2609 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2610 as_fn_set_status $ac_retval
2612 } # ac_fn_c_compute_int
2614 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2615 # ----------------------------------------------------
2616 # Tries to find if the field MEMBER exists in type AGGR, after including
2617 # INCLUDES, setting cache variable VAR accordingly.
2618 ac_fn_c_check_member ()
2620 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2622 $as_echo_n "checking for $2.$3... " >&6; }
2623 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
2624 $as_echo_n "(cached) " >&6
2626 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2627 /* end confdefs.h. */
2639 if ac_fn_c_try_compile "$LINENO"; then :
2642 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2643 /* end confdefs.h. */
2649 if (sizeof ac_aggr.$3)
2655 if ac_fn_c_try_compile "$LINENO"; then :
2660 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2662 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2666 $as_echo "$ac_res" >&6; }
2667 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2669 } # ac_fn_c_check_member
2670 cat >config.log <<_ACEOF
2671 This file contains any messages produced by compilers while
2672 running configure, to aid debugging if configure makes a mistake.
2674 It was created by gzip $as_me 1.4, which was
2675 generated by GNU Autoconf 2.65.23-13e35. Invocation command line was
2687 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2688 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2689 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2690 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2691 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2693 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2694 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2696 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2697 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2698 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2699 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2700 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2701 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2702 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2706 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2710 test -z "$as_dir" && as_dir=.
2711 $as_echo "PATH: $as_dir"
2727 # Keep a trace of the command line.
2728 # Strip out --no-create and --no-recursion so they do not pile up.
2729 # Strip out --silent because we don't want to record it for future runs.
2730 # Also quote any args containing shell meta-characters.
2731 # Make two passes to allow for proper duplicate-argument suppression.
2735 ac_must_keep_next=false
2741 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2742 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2743 | -silent | --silent | --silen | --sile | --sil)
2746 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2749 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2751 as_fn_append ac_configure_args1 " '$ac_arg'"
2752 if test $ac_must_keep_next = true; then
2753 ac_must_keep_next=false # Got value, back to normal.
2756 *=* | --config-cache | -C | -disable-* | --disable-* \
2757 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2758 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2759 | -with-* | --with-* | -without-* | --without-* | --x)
2760 case "$ac_configure_args0 " in
2761 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2764 -* ) ac_must_keep_next=true ;;
2767 as_fn_append ac_configure_args " '$ac_arg'"
2772 { ac_configure_args0=; unset ac_configure_args0;}
2773 { ac_configure_args1=; unset ac_configure_args1;}
2775 # When interrupted or exit'd, cleanup temporary files, and complete
2776 # config.log. We remove comments because anyway the quotes in there
2777 # would cause problems or look ugly.
2778 # WARNING: Use '\'' to represent an apostrophe within the trap.
2779 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2780 trap 'exit_status=$?
2781 # Save into config.log some information that might help in debugging.
2786 ## ---------------- ##
2787 ## Cache variables. ##
2788 ## ---------------- ##
2791 # The following way of writing the cache mishandles newlines in values,
2793 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2794 eval ac_val=\$$ac_var
2798 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2799 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2802 _ | IFS | as_nl) ;; #(
2803 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2804 *) { eval $ac_var=; unset $ac_var;} ;;
2809 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2810 *${as_nl}ac_space=\ *)
2812 "s/'\''/'\''\\\\'\'''\''/g;
2813 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2816 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2824 ## ----------------- ##
2825 ## Output variables. ##
2826 ## ----------------- ##
2829 for ac_var in $ac_subst_vars
2831 eval ac_val=\$$ac_var
2833 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2835 $as_echo "$ac_var='\''$ac_val'\''"
2839 if test -n "$ac_subst_files"; then
2841 ## ------------------- ##
2842 ## File substitutions. ##
2843 ## ------------------- ##
2846 for ac_var in $ac_subst_files
2848 eval ac_val=\$$ac_var
2850 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2852 $as_echo "$ac_var='\''$ac_val'\''"
2857 if test -s confdefs.h; then
2867 test "$ac_signal" != 0 &&
2868 $as_echo "$as_me: caught signal $ac_signal"
2869 $as_echo "$as_me: exit $exit_status"
2871 rm -f core *.core core.conftest.* &&
2872 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2875 for ac_signal in 1 2 13 15; do
2876 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2880 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2881 rm -f -r conftest* confdefs.h
2883 $as_echo "/* confdefs.h */" > confdefs.h
2885 # Predefined preprocessor variables.
2887 cat >>confdefs.h <<_ACEOF
2888 #define PACKAGE_NAME "$PACKAGE_NAME"
2891 cat >>confdefs.h <<_ACEOF
2892 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2895 cat >>confdefs.h <<_ACEOF
2896 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2899 cat >>confdefs.h <<_ACEOF
2900 #define PACKAGE_STRING "$PACKAGE_STRING"
2903 cat >>confdefs.h <<_ACEOF
2904 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2907 cat >>confdefs.h <<_ACEOF
2908 #define PACKAGE_URL "$PACKAGE_URL"
2912 # Let the site file select an alternate cache file if it wants to.
2913 # Prefer an explicitly selected file to automatically selected ones.
2916 if test -n "$CONFIG_SITE"; then
2917 ac_site_file1=$CONFIG_SITE
2918 elif test "x$prefix" != xNONE; then
2919 ac_site_file1=$prefix/share/config.site
2920 ac_site_file2=$prefix/etc/config.site
2922 ac_site_file1=$ac_default_prefix/share/config.site
2923 ac_site_file2=$ac_default_prefix/etc/config.site
2925 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2927 test "x$ac_site_file" = xNONE && continue
2928 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2929 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2930 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2931 sed 's/^/| /' "$ac_site_file" >&5
2936 if test -r "$cache_file"; then
2937 # Some versions of bash will fail to source /dev/null (special files
2938 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2939 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2940 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2941 $as_echo "$as_me: loading cache $cache_file" >&6;}
2943 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2944 *) . "./$cache_file";;
2948 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2949 $as_echo "$as_me: creating cache $cache_file" >&6;}
2953 as_fn_append ac_func_list " chown"
2954 as_fn_append ac_func_list " fchown"
2955 as_fn_append ac_header_list " dirent.h"
2956 as_fn_append ac_func_list " dup2"
2957 as_fn_append ac_header_list " errno.h"
2958 as_fn_append ac_func_list " fchdir"
2959 as_fn_append ac_func_list " fcntl"
2960 as_fn_append ac_header_list " fcntl.h"
2961 as_fn_append ac_func_list " fdopendir"
2962 as_fn_append ac_header_list " float.h"
2963 as_fn_append ac_header_list " stdio_ext.h"
2964 as_fn_append ac_func_list " __fpending"
2965 as_fn_append ac_func_list " vasnprintf"
2966 as_fn_append ac_func_list " fpurge"
2967 as_fn_append ac_func_list " __fpurge"
2968 as_fn_append ac_func_list " __freading"
2969 gl_getopt_required=GNU
2970 as_fn_append ac_header_list " getopt.h"
2971 as_fn_append ac_func_list " gettimeofday"
2972 as_fn_append ac_func_list " nanotime"
2973 as_fn_append ac_header_list " sys/time.h"
2974 as_fn_append ac_func_list " lchmod"
2975 as_fn_append ac_func_list " lstat"
2976 as_fn_append ac_header_list " math.h"
2977 as_fn_append ac_func_list " mbsinit"
2978 as_fn_append ac_func_list " mbrtowc"
2979 as_fn_append ac_header_list " sys/mman.h"
2980 as_fn_append ac_func_list " mprotect"
2981 as_fn_append ac_header_list " unistd.h"
2983 as_fn_append ac_header_list " stddef.h"
2984 as_fn_append ac_header_list " stdint.h"
2985 as_fn_append ac_header_list " wchar.h"
2986 as_fn_append ac_header_list " stdio.h"
2987 as_fn_append ac_header_list " stdlib.h"
2988 as_fn_append ac_header_list " sys/socket.h"
2989 as_fn_append ac_header_list " string.h"
2990 as_fn_append ac_header_list " sys/stat.h"
2991 as_fn_append ac_header_list " time.h"
2992 as_fn_append ac_func_list " pipe"
2993 as_fn_append ac_header_list " utime.h"
2994 as_fn_append ac_func_list " futimes"
2995 as_fn_append ac_func_list " futimesat"
2996 as_fn_append ac_func_list " futimens"
2997 as_fn_append ac_func_list " utimensat"
2998 as_fn_append ac_func_list " lutimes"
2999 as_fn_append ac_func_list " iswcntrl"
3000 as_fn_append ac_header_list " wctype.h"
3001 as_fn_append ac_header_list " limits.h"
3002 as_fn_append ac_header_list " memory.h"
3003 as_fn_append ac_func_list " fchmod"
3004 as_fn_append ac_func_list " siginterrupt"
3005 # Check that the precious variables saved in the cache have kept the same
3007 ac_cache_corrupted=false
3008 for ac_var in $ac_precious_vars; do
3009 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3010 eval ac_new_set=\$ac_env_${ac_var}_set
3011 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3012 eval ac_new_val=\$ac_env_${ac_var}_value
3013 case $ac_old_set,$ac_new_set in
3015 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3016 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3017 ac_cache_corrupted=: ;;
3019 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3020 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3021 ac_cache_corrupted=: ;;
3024 if test "x$ac_old_val" != "x$ac_new_val"; then
3025 # differences in whitespace do not lead to failure.
3026 ac_old_val_w=`echo x $ac_old_val`
3027 ac_new_val_w=`echo x $ac_new_val`
3028 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3029 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3030 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3031 ac_cache_corrupted=:
3033 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3034 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3035 eval $ac_var=\$ac_old_val
3037 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3038 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3039 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3040 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3043 # Pass precious variables to config.status.
3044 if test "$ac_new_set" = set; then
3046 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3047 *) ac_arg=$ac_var=$ac_new_val ;;
3049 case " $ac_configure_args " in
3050 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3051 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3055 if $ac_cache_corrupted; then
3056 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3057 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3058 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3059 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3060 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3062 ## -------------------- ##
3063 ## Main body of script. ##
3064 ## -------------------- ##
3067 ac_cpp='$CPP $CPPFLAGS'
3068 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3069 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3070 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3076 for ac_dir in build-aux "$srcdir"/build-aux; do
3077 if test -f "$ac_dir/install-sh"; then
3079 ac_install_sh="$ac_aux_dir/install-sh -c"
3081 elif test -f "$ac_dir/install.sh"; then
3083 ac_install_sh="$ac_aux_dir/install.sh -c"
3085 elif test -f "$ac_dir/shtool"; then
3087 ac_install_sh="$ac_aux_dir/shtool install -c"
3091 if test -z "$ac_aux_dir"; then
3092 as_fn_error "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
3095 # These three variables are undocumented and unsupported,
3096 # and are intended to be withdrawn in a future Autoconf release.
3097 # They can cause serious problems if a builder's source tree is in a directory
3098 # whose full name contains unusual characters.
3099 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3100 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3101 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3104 ac_config_headers="$ac_config_headers lib/config.h:lib/config.hin"
3106 am__api_version='1.11a'
3108 # Find a good install program. We prefer a C program (faster),
3109 # so one script is as good as another. But avoid the broken or
3110 # incompatible versions:
3111 # SysV /etc/install, /usr/sbin/install
3112 # SunOS /usr/etc/install
3113 # IRIX /sbin/install
3115 # AmigaOS /C/install, which installs bootblocks on floppy discs
3116 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3117 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3118 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3119 # OS/2's system install, which has a completely different semantic
3120 # ./install, which can be erroneously created by make from ./install.sh.
3121 # Reject install programs that cannot install multiple files.
3122 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3123 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3124 if test -z "$INSTALL"; then
3125 if test "${ac_cv_path_install+set}" = set; then :
3126 $as_echo_n "(cached) " >&6
3128 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3132 test -z "$as_dir" && as_dir=.
3133 # Account for people who put trailing slashes in PATH elements.
3134 case $as_dir/ in #((
3135 ./ | .// | /[cC]/* | \
3136 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3137 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3140 # OSF1 and SCO ODT 3.0 have their own names for install.
3141 # Don't use installbsd from OSF since it installs stuff as root
3143 for ac_prog in ginstall scoinst install; do
3144 for ac_exec_ext in '' $ac_executable_extensions; do
3145 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3146 if test $ac_prog = install &&
3147 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3148 # AIX install. It has an incompatible calling convention.
3150 elif test $ac_prog = install &&
3151 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3152 # program-specific install script used by HP pwplus--don't use.
3155 rm -rf conftest.one conftest.two conftest.dir
3156 echo one > conftest.one
3157 echo two > conftest.two
3159 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3160 test -s conftest.one && test -s conftest.two &&
3161 test -s conftest.dir/conftest.one &&
3162 test -s conftest.dir/conftest.two
3164 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3177 rm -rf conftest.one conftest.two conftest.dir
3180 if test "${ac_cv_path_install+set}" = set; then
3181 INSTALL=$ac_cv_path_install
3183 # As a last resort, use the slow shell script. Don't cache a
3184 # value for INSTALL within a source directory, because that will
3185 # break other packages using the cache if that directory is
3186 # removed, or if the value is a relative name.
3187 INSTALL=$ac_install_sh
3190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3191 $as_echo "$INSTALL" >&6; }
3193 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3194 # It thinks the first close brace ends the variable substitution.
3195 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3197 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3199 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3201 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3202 $as_echo_n "checking whether build environment is sane... " >&6; }
3203 # Reject unsafe characters in $srcdir or the absolute working directory
3204 # name. Accept space and tab only in the latter.
3208 *[\\\"\#\$\&\'\`$am_lf]*)
3209 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
3212 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3213 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
3216 # Do `set' in a subshell so we don't clobber the current shell's
3217 # arguments. Must try -L first in case configure is actually a
3218 # symlink; some systems play weird games with the mod time of symlinks
3219 # (eg FreeBSD returns the mod time of the symlink's containing
3222 for am_try in 1 2; do
3223 echo timestamp > conftest.file
3224 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3225 if test "$*" = "X"; then
3227 set X `ls -t "$srcdir/configure" conftest.file`
3230 if test "$*" != "X $srcdir/configure conftest.file" \
3231 && test "$*" != "X conftest.file $srcdir/configure"; then
3233 # If neither matched, then we have a broken ls. This can happen
3234 # if, for instance, CONFIG_SHELL is bash and it inherits a
3235 # broken ls alias from the environment. This has actually
3236 # happened. Such a system could not be considered "sane".
3237 as_fn_error "ls -t appears to fail. Make sure there is not a broken
3238 alias in your environment" "$LINENO" 5
3240 if test "$2" = conftest.file || test $am_try -eq 2; then
3246 test "$2" = conftest.file
3252 as_fn_error "newly created file is older than distributed files!
3253 Check your system clock" "$LINENO" 5
3255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3256 $as_echo "yes" >&6; }
3257 test "$program_prefix" != NONE &&
3258 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3259 # Use a double $ so make ignores it.
3260 test "$program_suffix" != NONE &&
3261 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3262 # Double any \ or $.
3263 # By default was `s,x,x', remove it if useless.
3264 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3265 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3267 # expand $ac_aux_dir to an absolute path
3268 am_aux_dir=`cd $ac_aux_dir && pwd`
3270 if test x"${MISSING+set}" != xset; then
3273 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3275 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3278 # Use eval to expand $SHELL
3279 if eval "$MISSING --run true"; then
3280 am_missing_run="$MISSING --run "
3283 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3284 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
3287 if test x"${install_sh}" != xset; then
3290 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3292 install_sh="\${SHELL} $am_aux_dir/install-sh"
3296 # Installed binaries are usually stripped using `strip' when the user
3297 # run `make install-strip'. However `strip' might not be the right
3298 # tool to use in cross-compilation environments, therefore Automake
3299 # will honor the `STRIP' environment variable to overrule this program.
3300 if test "$cross_compiling" != no; then
3301 if test -n "$ac_tool_prefix"; then
3302 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3303 set dummy ${ac_tool_prefix}strip; ac_word=$2
3304 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3305 $as_echo_n "checking for $ac_word... " >&6; }
3306 if test "${ac_cv_prog_STRIP+set}" = set; then :
3307 $as_echo_n "(cached) " >&6
3309 if test -n "$STRIP"; then
3310 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3312 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3316 test -z "$as_dir" && as_dir=.
3317 for ac_exec_ext in '' $ac_executable_extensions; do
3318 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3319 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3320 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3329 STRIP=$ac_cv_prog_STRIP
3330 if test -n "$STRIP"; then
3331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3332 $as_echo "$STRIP" >&6; }
3334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3335 $as_echo "no" >&6; }
3340 if test -z "$ac_cv_prog_STRIP"; then
3342 # Extract the first word of "strip", so it can be a program name with args.
3343 set dummy strip; ac_word=$2
3344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3345 $as_echo_n "checking for $ac_word... " >&6; }
3346 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
3347 $as_echo_n "(cached) " >&6
3349 if test -n "$ac_ct_STRIP"; then
3350 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3352 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3356 test -z "$as_dir" && as_dir=.
3357 for ac_exec_ext in '' $ac_executable_extensions; do
3358 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3359 ac_cv_prog_ac_ct_STRIP="strip"
3360 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3369 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3370 if test -n "$ac_ct_STRIP"; then
3371 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3372 $as_echo "$ac_ct_STRIP" >&6; }
3374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3375 $as_echo "no" >&6; }
3378 if test "x$ac_ct_STRIP" = x; then
3381 case $cross_compiling:$ac_tool_warned in
3383 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3384 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3385 ac_tool_warned=yes ;;
3390 STRIP="$ac_cv_prog_STRIP"
3394 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3396 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3397 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3398 if test -z "$MKDIR_P"; then
3399 if test "${ac_cv_path_mkdir+set}" = set; then :
3400 $as_echo_n "(cached) " >&6
3402 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3403 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3406 test -z "$as_dir" && as_dir=.
3407 for ac_prog in mkdir gmkdir; do
3408 for ac_exec_ext in '' $ac_executable_extensions; do
3409 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3410 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3411 'mkdir (GNU coreutils) '* | \
3412 'mkdir (coreutils) '* | \
3413 'mkdir (fileutils) '4.1*)
3414 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3424 test -d ./--version && rmdir ./--version
3425 if test "${ac_cv_path_mkdir+set}" = set; then
3426 MKDIR_P="$ac_cv_path_mkdir -p"
3428 # As a last resort, use the slow shell script. Don't cache a
3429 # value for MKDIR_P within a source directory, because that will
3430 # break other packages using the cache if that directory is
3431 # removed, or if the value is a relative name.
3432 MKDIR_P="$ac_install_sh -d"
3435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3436 $as_echo "$MKDIR_P" >&6; }
3440 [\\/$]* | ?:[\\/]*) ;;
3441 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3444 for ac_prog in gawk mawk nawk awk
3446 # Extract the first word of "$ac_prog", so it can be a program name with args.
3447 set dummy $ac_prog; ac_word=$2
3448 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3449 $as_echo_n "checking for $ac_word... " >&6; }
3450 if test "${ac_cv_prog_AWK+set}" = set; then :
3451 $as_echo_n "(cached) " >&6
3453 if test -n "$AWK"; then
3454 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3456 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3460 test -z "$as_dir" && as_dir=.
3461 for ac_exec_ext in '' $ac_executable_extensions; do
3462 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3463 ac_cv_prog_AWK="$ac_prog"
3464 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3474 if test -n "$AWK"; then
3475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3476 $as_echo "$AWK" >&6; }
3478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3479 $as_echo "no" >&6; }
3483 test -n "$AWK" && break
3486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3487 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3489 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3490 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
3491 $as_echo_n "(cached) " >&6
3493 cat >conftest.make <<\_ACEOF
3496 @echo '@@@%%%=$(MAKE)=@@@%%%'
3498 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3499 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3501 eval ac_cv_prog_make_${ac_make}_set=yes;;
3503 eval ac_cv_prog_make_${ac_make}_set=no;;
3507 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3509 $as_echo "yes" >&6; }
3512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3513 $as_echo "no" >&6; }
3514 SET_MAKE="MAKE=${MAKE-make}"
3517 rm -rf .tst 2>/dev/null
3518 mkdir .tst 2>/dev/null
3519 if test -d .tst; then
3524 rmdir .tst 2>/dev/null
3526 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3527 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3528 # is not polluted with repeated "-I."
3529 am__isrc=' -I$(srcdir)'
3530 # test to see if srcdir already configured
3531 if test -f $srcdir/config.status; then
3532 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3536 # test whether we have cygpath
3537 if test -z "$CYGPATH_W"; then
3538 if (cygpath --version) >/dev/null 2>/dev/null; then
3539 CYGPATH_W='cygpath -w'
3546 # Define the identity of the package.
3551 cat >>confdefs.h <<_ACEOF
3552 #define PACKAGE "$PACKAGE"
3556 cat >>confdefs.h <<_ACEOF
3557 #define VERSION "$VERSION"
3560 # Some tools Automake needs.
3562 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3565 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3568 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3571 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3574 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3576 # We need awk for the "check" target. The system "awk" is bad on
3578 # Always define AMTAR for backward compatibility.
3580 AMTAR=${AMTAR-"${am_missing_run}tar"}
3582 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
3588 # Check whether --enable-silent-rules was given.
3589 if test "${enable_silent_rules+set}" = set; then :
3590 enableval=$enable_silent_rules;
3593 case $enable_silent_rules in
3594 yes) AM_DEFAULT_VERBOSITY=0;;
3595 no) AM_DEFAULT_VERBOSITY=1;;
3596 *) AM_DEFAULT_VERBOSITY=0;;
3599 # make --enable-silent-rules the default.
3601 DEPDIR="${am__leading_dot}deps"
3603 ac_config_commands="$ac_config_commands depfiles"
3606 am_make=${MAKE-make}
3607 cat > confinc << 'END'
3609 @echo this is the am__doit target
3612 # If we don't find an include directive, just comment out the code.
3613 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
3614 $as_echo_n "checking for style of include used by $am_make... " >&6; }
3618 # First try GNU make style include.
3619 echo "include confinc" > confmf
3620 # Ignore all kinds of additional output from `make'.
3621 case `$am_make -s -f confmf 2> /dev/null` in #(
3622 *the\ am__doit\ target*)
3628 # Now try BSD make style include.
3629 if test "$am__include" = "#"; then
3630 echo '.include "confinc"' > confmf
3631 case `$am_make -s -f confmf 2> /dev/null` in #(
3632 *the\ am__doit\ target*)
3633 am__include=.include
3641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
3642 $as_echo "$_am_result" >&6; }
3643 rm -f confinc confmf
3645 # Check whether --enable-dependency-tracking was given.
3646 if test "${enable_dependency_tracking+set}" = set; then :
3647 enableval=$enable_dependency_tracking;
3650 if test "x$enable_dependency_tracking" != xno; then
3651 am_depcomp="$ac_aux_dir/depcomp"
3654 if test "x$enable_dependency_tracking" != xno; then
3664 ac_cpp='$CPP $CPPFLAGS'
3665 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3666 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3667 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3668 if test -n "$ac_tool_prefix"; then
3669 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3670 set dummy ${ac_tool_prefix}gcc; ac_word=$2
3671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3672 $as_echo_n "checking for $ac_word... " >&6; }
3673 if test "${ac_cv_prog_CC+set}" = set; then :
3674 $as_echo_n "(cached) " >&6
3676 if test -n "$CC"; then
3677 ac_cv_prog_CC="$CC" # Let the user override the test.
3679 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3683 test -z "$as_dir" && as_dir=.
3684 for ac_exec_ext in '' $ac_executable_extensions; do
3685 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3686 ac_cv_prog_CC="${ac_tool_prefix}gcc"
3687 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3697 if test -n "$CC"; then
3698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3699 $as_echo "$CC" >&6; }
3701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3702 $as_echo "no" >&6; }
3707 if test -z "$ac_cv_prog_CC"; then
3709 # Extract the first word of "gcc", so it can be a program name with args.
3710 set dummy gcc; ac_word=$2
3711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3712 $as_echo_n "checking for $ac_word... " >&6; }
3713 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
3714 $as_echo_n "(cached) " >&6
3716 if test -n "$ac_ct_CC"; then
3717 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3719 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3723 test -z "$as_dir" && as_dir=.
3724 for ac_exec_ext in '' $ac_executable_extensions; do
3725 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3726 ac_cv_prog_ac_ct_CC="gcc"
3727 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3736 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3737 if test -n "$ac_ct_CC"; then
3738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3739 $as_echo "$ac_ct_CC" >&6; }
3741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3742 $as_echo "no" >&6; }
3745 if test "x$ac_ct_CC" = x; then
3748 case $cross_compiling:$ac_tool_warned in
3750 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3751 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3752 ac_tool_warned=yes ;;
3760 if test -z "$CC"; then
3761 if test -n "$ac_tool_prefix"; then
3762 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3763 set dummy ${ac_tool_prefix}cc; ac_word=$2
3764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3765 $as_echo_n "checking for $ac_word... " >&6; }
3766 if test "${ac_cv_prog_CC+set}" = set; then :
3767 $as_echo_n "(cached) " >&6
3769 if test -n "$CC"; then
3770 ac_cv_prog_CC="$CC" # Let the user override the test.
3772 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3776 test -z "$as_dir" && as_dir=.
3777 for ac_exec_ext in '' $ac_executable_extensions; do
3778 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3779 ac_cv_prog_CC="${ac_tool_prefix}cc"
3780 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3790 if test -n "$CC"; then
3791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3792 $as_echo "$CC" >&6; }
3794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3795 $as_echo "no" >&6; }
3801 if test -z "$CC"; then
3802 # Extract the first word of "cc", so it can be a program name with args.
3803 set dummy cc; ac_word=$2
3804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3805 $as_echo_n "checking for $ac_word... " >&6; }
3806 if test "${ac_cv_prog_CC+set}" = set; then :
3807 $as_echo_n "(cached) " >&6
3809 if test -n "$CC"; then
3810 ac_cv_prog_CC="$CC" # Let the user override the test.
3813 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3817 test -z "$as_dir" && as_dir=.
3818 for ac_exec_ext in '' $ac_executable_extensions; do
3819 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3820 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3821 ac_prog_rejected=yes
3825 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3832 if test $ac_prog_rejected = yes; then
3833 # We found a bogon in the path, so make sure we never use it.
3834 set dummy $ac_cv_prog_CC
3836 if test $# != 0; then
3837 # We chose a different compiler from the bogus one.
3838 # However, it has the same basename, so the bogon will be chosen
3839 # first if we set CC to just the basename; use the full file name.
3841 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3847 if test -n "$CC"; then
3848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3849 $as_echo "$CC" >&6; }
3851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3852 $as_echo "no" >&6; }
3857 if test -z "$CC"; then
3858 if test -n "$ac_tool_prefix"; then
3859 for ac_prog in cl.exe
3861 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3862 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3864 $as_echo_n "checking for $ac_word... " >&6; }
3865 if test "${ac_cv_prog_CC+set}" = set; then :
3866 $as_echo_n "(cached) " >&6
3868 if test -n "$CC"; then
3869 ac_cv_prog_CC="$CC" # Let the user override the test.
3871 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3875 test -z "$as_dir" && as_dir=.
3876 for ac_exec_ext in '' $ac_executable_extensions; do
3877 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3878 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3879 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3889 if test -n "$CC"; then
3890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3891 $as_echo "$CC" >&6; }
3893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3894 $as_echo "no" >&6; }
3898 test -n "$CC" && break
3901 if test -z "$CC"; then
3903 for ac_prog in cl.exe
3905 # Extract the first word of "$ac_prog", so it can be a program name with args.
3906 set dummy $ac_prog; ac_word=$2
3907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3908 $as_echo_n "checking for $ac_word... " >&6; }
3909 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
3910 $as_echo_n "(cached) " >&6
3912 if test -n "$ac_ct_CC"; then
3913 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3915 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3919 test -z "$as_dir" && as_dir=.
3920 for ac_exec_ext in '' $ac_executable_extensions; do
3921 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3922 ac_cv_prog_ac_ct_CC="$ac_prog"
3923 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3932 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3933 if test -n "$ac_ct_CC"; then
3934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3935 $as_echo "$ac_ct_CC" >&6; }
3937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3938 $as_echo "no" >&6; }
3942 test -n "$ac_ct_CC" && break
3945 if test "x$ac_ct_CC" = x; then
3948 case $cross_compiling:$ac_tool_warned in
3950 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3951 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3952 ac_tool_warned=yes ;;
3961 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3962 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3963 as_fn_error "no acceptable C compiler found in \$PATH
3964 See \`config.log' for more details." "$LINENO" 5; }
3966 # Provide some information about the compiler.
3967 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3970 for ac_option in --version -v -V -qversion; do
3971 { { ac_try="$ac_compiler $ac_option >&5"
3973 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3974 *) ac_try_echo=$ac_try;;
3976 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3977 $as_echo "$ac_try_echo"; } >&5
3978 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3980 if test -s conftest.err; then
3982 ... rest of stderr output deleted ...
3983 10q' conftest.err >conftest.er1
3984 cat conftest.er1 >&5
3986 rm -f conftest.er1 conftest.err
3987 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3988 test $ac_status = 0; }
3991 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3992 /* end confdefs.h. */
4002 ac_clean_files_save=$ac_clean_files
4003 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4004 # Try to create an executable without -o first, disregard a.out.
4005 # It will help us diagnose broken compilers, and finding out an intuition
4007 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4008 $as_echo_n "checking whether the C compiler works... " >&6; }
4009 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4011 # The possible output files:
4012 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4015 for ac_file in $ac_files
4018 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4019 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4024 if { { ac_try="$ac_link_default"
4026 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4027 *) ac_try_echo=$ac_try;;
4029 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4030 $as_echo "$ac_try_echo"; } >&5
4031 (eval "$ac_link_default") 2>&5
4033 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4034 test $ac_status = 0; }; then :
4035 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4036 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4037 # in a Makefile. We should not override ac_cv_exeext if it was cached,
4038 # so that the user can short-circuit this test for compilers unknown to
4040 for ac_file in $ac_files ''
4042 test -f "$ac_file" || continue
4044 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
4047 # We found the default executable, but exeext='' is most
4051 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
4053 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4055 # We set ac_cv_exeext here because the later test for it is not
4056 # safe: cross compilers may not add the suffix if given an `-o'
4057 # argument, so we may need to know it at that point already.
4058 # Even if this section looks crufty: it has the advantage of
4065 test "$ac_cv_exeext" = no && ac_cv_exeext=
4070 if test -z "$ac_file"; then :
4071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4072 $as_echo "no" >&6; }
4073 $as_echo "$as_me: failed program was:" >&5
4074 sed 's/^/| /' conftest.$ac_ext >&5
4076 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4077 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4078 { as_fn_set_status 77
4079 as_fn_error "C compiler cannot create executables
4080 See \`config.log' for more details." "$LINENO" 5; }; }
4082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4083 $as_echo "yes" >&6; }
4085 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
4086 $as_echo_n "checking for C compiler default output file name... " >&6; }
4087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
4088 $as_echo "$ac_file" >&6; }
4089 ac_exeext=$ac_cv_exeext
4091 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
4092 ac_clean_files=$ac_clean_files_save
4093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
4094 $as_echo_n "checking for suffix of executables... " >&6; }
4095 if { { ac_try="$ac_link"
4097 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4098 *) ac_try_echo=$ac_try;;
4100 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4101 $as_echo "$ac_try_echo"; } >&5
4102 (eval "$ac_link") 2>&5
4104 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4105 test $ac_status = 0; }; then :
4106 # If both `conftest.exe' and `conftest' are `present' (well, observable)
4107 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
4108 # work properly (i.e., refer to `conftest.exe'), while it won't with
4110 for ac_file in conftest.exe conftest conftest.*; do
4111 test -f "$ac_file" || continue
4113 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4114 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4120 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4121 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4122 as_fn_error "cannot compute suffix of executables: cannot compile and link
4123 See \`config.log' for more details." "$LINENO" 5; }
4125 rm -f conftest conftest$ac_cv_exeext
4126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4127 $as_echo "$ac_cv_exeext" >&6; }
4129 rm -f conftest.$ac_ext
4130 EXEEXT=$ac_cv_exeext
4132 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4133 /* end confdefs.h. */
4138 FILE *f = fopen ("conftest.out", "w");
4139 return ferror (f) || fclose (f) != 0;
4145 ac_clean_files="$ac_clean_files conftest.out"
4146 # Check that the compiler produces executables we can run. If not, either
4147 # the compiler is broken, or we cross compile.
4148 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4149 $as_echo_n "checking whether we are cross compiling... " >&6; }
4150 if test "$cross_compiling" != yes; then
4151 { { ac_try="$ac_link"
4153 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4154 *) ac_try_echo=$ac_try;;
4156 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4157 $as_echo "$ac_try_echo"; } >&5
4158 (eval "$ac_link") 2>&5
4160 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4161 test $ac_status = 0; }
4162 if { ac_try='./conftest$ac_cv_exeext'
4163 { { case "(($ac_try" in
4164 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4165 *) ac_try_echo=$ac_try;;
4167 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4168 $as_echo "$ac_try_echo"; } >&5
4169 (eval "$ac_try") 2>&5
4171 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4172 test $ac_status = 0; }; }; then
4175 if test "$cross_compiling" = maybe; then
4178 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4179 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4180 as_fn_error "cannot run C compiled programs.
4181 If you meant to cross compile, use \`--host'.
4182 See \`config.log' for more details." "$LINENO" 5; }
4186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4187 $as_echo "$cross_compiling" >&6; }
4189 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
4190 ac_clean_files=$ac_clean_files_save
4191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4192 $as_echo_n "checking for suffix of object files... " >&6; }
4193 if test "${ac_cv_objext+set}" = set; then :
4194 $as_echo_n "(cached) " >&6
4196 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4197 /* end confdefs.h. */
4207 rm -f conftest.o conftest.obj
4208 if { { ac_try="$ac_compile"
4210 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4211 *) ac_try_echo=$ac_try;;
4213 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4214 $as_echo "$ac_try_echo"; } >&5
4215 (eval "$ac_compile") 2>&5
4217 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4218 test $ac_status = 0; }; then :
4219 for ac_file in conftest.o conftest.obj conftest.*; do
4220 test -f "$ac_file" || continue;
4222 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
4223 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4228 $as_echo "$as_me: failed program was:" >&5
4229 sed 's/^/| /' conftest.$ac_ext >&5
4231 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4232 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4233 as_fn_error "cannot compute suffix of object files: cannot compile
4234 See \`config.log' for more details." "$LINENO" 5; }
4236 rm -f conftest.$ac_cv_objext conftest.$ac_ext
4238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4239 $as_echo "$ac_cv_objext" >&6; }
4240 OBJEXT=$ac_cv_objext
4242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4243 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4244 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
4245 $as_echo_n "(cached) " >&6
4247 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4248 /* end confdefs.h. */
4261 if ac_fn_c_try_compile "$LINENO"; then :
4266 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4267 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4271 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
4272 if test $ac_compiler_gnu = yes; then
4277 ac_test_CFLAGS=${CFLAGS+set}
4278 ac_save_CFLAGS=$CFLAGS
4279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4280 $as_echo_n "checking whether $CC accepts -g... " >&6; }
4281 if test "${ac_cv_prog_cc_g+set}" = set; then :
4282 $as_echo_n "(cached) " >&6
4284 ac_save_c_werror_flag=$ac_c_werror_flag
4285 ac_c_werror_flag=yes
4288 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4289 /* end confdefs.h. */
4299 if ac_fn_c_try_compile "$LINENO"; then :
4303 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4304 /* end confdefs.h. */
4314 if ac_fn_c_try_compile "$LINENO"; then :
4317 ac_c_werror_flag=$ac_save_c_werror_flag
4319 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4320 /* end confdefs.h. */
4330 if ac_fn_c_try_compile "$LINENO"; then :
4333 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4335 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4337 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4338 ac_c_werror_flag=$ac_save_c_werror_flag
4340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4341 $as_echo "$ac_cv_prog_cc_g" >&6; }
4342 if test "$ac_test_CFLAGS" = set; then
4343 CFLAGS=$ac_save_CFLAGS
4344 elif test $ac_cv_prog_cc_g = yes; then
4345 if test "$GCC" = yes; then
4351 if test "$GCC" = yes; then
4357 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4358 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4359 if test "${ac_cv_prog_cc_c89+set}" = set; then :
4360 $as_echo_n "(cached) " >&6
4362 ac_cv_prog_cc_c89=no
4364 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4365 /* end confdefs.h. */
4368 #include <sys/types.h>
4369 #include <sys/stat.h>
4370 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4371 struct buf { int x; };
4372 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4373 static char *e (p, i)
4379 static char *f (char * (*g) (char **, int), char **p, ...)
4384 s = g (p, va_arg (v,int));
4389 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
4390 function prototypes and stuff, but not '\xHH' hex character constants.
4391 These don't provoke an error unfortunately, instead are silently treated
4392 as 'x'. The following induces an error, until -std is added to get
4393 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
4394 array size at least. It's necessary to write '\x00'==0 to get something
4395 that's true only with -std. */
4396 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4398 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4399 inside strings and character constants. */
4401 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4403 int test (int i, double x);
4404 struct s1 {int (*f) (int a);};
4405 struct s2 {int (*f) (double a);};
4406 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4412 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4417 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4418 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4420 CC="$ac_save_CC $ac_arg"
4421 if ac_fn_c_try_compile "$LINENO"; then :
4422 ac_cv_prog_cc_c89=$ac_arg
4424 rm -f core conftest.err conftest.$ac_objext
4425 test "x$ac_cv_prog_cc_c89" != "xno" && break
4427 rm -f conftest.$ac_ext
4432 case "x$ac_cv_prog_cc_c89" in
4434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4435 $as_echo "none needed" >&6; } ;;
4437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4438 $as_echo "unsupported" >&6; } ;;
4440 CC="$CC $ac_cv_prog_cc_c89"
4441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4442 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
4444 if test "x$ac_cv_prog_cc_c89" != xno; then :
4449 ac_cpp='$CPP $CPPFLAGS'
4450 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4451 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4452 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4454 depcc="$CC" am_compiler_list=
4456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
4457 $as_echo_n "checking dependency style of $depcc... " >&6; }
4458 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
4459 $as_echo_n "(cached) " >&6
4461 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
4462 # We make a subdir and do the tests there. Otherwise we can end up
4463 # making bogus files that we don't know about and never remove. For
4464 # instance it was reported that on HP-UX the gcc test will end up
4465 # making a dummy file named `D' -- because `-MD' means `put the output
4468 # Copy depcomp to subdir because otherwise we won't find it if we're
4469 # using a relative directory.
4470 cp "$am_depcomp" conftest.dir
4472 # We will build objects and dependencies in a subdirectory because
4473 # it helps to detect inapplicable dependency modes. For instance
4474 # both Tru64's cc and ICC support -MD to output dependencies as a
4475 # side effect of compilation, but ICC will put the dependencies in
4476 # the current directory while Tru64 will put them in the object
4480 am_cv_CC_dependencies_compiler_type=none
4481 if test "$am_compiler_list" = ""; then
4482 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
4485 case " $depcc " in #(
4486 *\ -arch\ *\ -arch\ *) am__universal=true ;;
4489 for depmode in $am_compiler_list; do
4490 # Setup a source with many dependencies, because some compilers
4491 # like to wrap large dependency lists on column 80 (with \), and
4492 # we should not choose a depcomp mode which is confused by this.
4494 # We need to recreate these files for each test, as the compiler may
4495 # overwrite some of them when testing with obscure command lines.
4496 # This happens at least with the AIX C compiler.
4498 for i in 1 2 3 4 5 6; do
4499 echo '#include "conftst'$i'.h"' >> sub/conftest.c
4500 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
4501 # Solaris 8's {/usr,}/bin/sh.
4502 touch sub/conftst$i.h
4504 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
4506 # We check with `-c' and `-o' for the sake of the "dashmstdout"
4507 # mode. It turns out that the SunPro C++ compiler does not properly
4508 # handle `-M -o', and we need to detect this. Also, some Intel
4509 # versions had trouble with output in subdirs
4510 am__obj=sub/conftest.${OBJEXT-o}
4511 am__minus_obj="-o $am__obj"
4514 # This depmode causes a compiler race in universal mode.
4515 test "$am__universal" = false || continue
4518 # after this tag, mechanisms are not by side-effect, so they'll
4519 # only be used when explicitly requested
4520 if test "x$enable_dependency_tracking" = xyes; then
4526 msvisualcpp | msvcmsys)
4527 # This compiler won't grok `-c -o', but also, the minuso test has
4528 # not run yet. These depmodes are late enough in the game, and
4529 # so weak that their functioning should not be impacted.
4530 am__obj=conftest.${OBJEXT-o}
4535 if depmode=$depmode \
4536 source=sub/conftest.c object=$am__obj \
4537 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
4538 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
4539 >/dev/null 2>conftest.err &&
4540 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
4541 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
4542 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
4543 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
4544 # icc doesn't choke on unknown options, it will just issue warnings
4545 # or remarks (even with -Werror). So we grep stderr for any message
4546 # that says an option was ignored or not supported.
4547 # When given -MP, icc 7.0 and 7.1 complain thusly:
4548 # icc: Command line warning: ignoring option '-M'; no argument required
4549 # The diagnosis changed in icc 8.0:
4550 # icc: Command line remark: option '-MP' not supported
4551 if (grep 'ignoring option' conftest.err ||
4552 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
4553 am_cv_CC_dependencies_compiler_type=$depmode
4562 am_cv_CC_dependencies_compiler_type=none
4566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
4567 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
4568 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
4571 test "x$enable_dependency_tracking" != xno \
4572 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
4574 am__fastdepCC_FALSE='#'
4576 am__fastdepCC_TRUE='#'
4577 am__fastdepCC_FALSE=
4581 case $ac_cv_prog_cc_stdc in #(
4583 ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
4585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
4586 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
4587 if test "${ac_cv_prog_cc_c99+set}" = set; then :
4588 $as_echo_n "(cached) " >&6
4590 ac_cv_prog_cc_c99=no
4592 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4593 /* end confdefs.h. */
4595 #include <stdbool.h>
4600 // Check varargs macros. These examples are taken from C99 6.10.3.5.
4601 #define debug(...) fprintf (stderr, __VA_ARGS__)
4602 #define showlist(...) puts (#__VA_ARGS__)
4603 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
4605 test_varargs_macros (void)
4610 debug ("X = %d\n", x);
4611 showlist (The first, second, and third items.);
4612 report (x>y, "x is %d but y is %d", x, y);
4615 // Check long long types.
4616 #define BIG64 18446744073709551615ull
4617 #define BIG32 4294967295ul
4618 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
4620 your preprocessor is broken;
4624 your preprocessor is broken;
4626 static long long int bignum = -9223372036854775807LL;
4627 static unsigned long long int ubignum = BIG64;
4629 struct incomplete_array
4637 const wchar_t *name;
4641 typedef const char *ccp;
4644 test_restrict (ccp restrict text)
4646 // See if C++-style comments work.
4647 // Iterate through items via the restricted pointer.
4648 // Also check for declarations in for loops.
4649 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
4654 // Check varargs and va_copy.
4656 test_varargs (const char *format, ...)
4659 va_start (args, format);
4661 va_copy (args_copy, args);
4672 str = va_arg (args_copy, const char *);
4675 number = va_arg (args_copy, int);
4678 fnumber = va_arg (args_copy, double);
4693 _Bool success = false;
4696 if (test_restrict ("String literal") == 0)
4698 char *restrict newvar = "Another string";
4701 test_varargs ("s, d' f .", "string", 65, 34.234);
4702 test_varargs_macros ();
4704 // Check flexible array members.
4705 struct incomplete_array *ia =
4706 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
4708 for (int i = 0; i < ia->datasize; ++i)
4709 ia->data[i] = i * 1.234;
4711 // Check named initializers.
4712 struct named_init ni = {
4714 .name = L"Test wide string",
4715 .average = 543.34343,
4720 int dynamic_array[ni.number];
4721 dynamic_array[ni.number - 1] = 543;
4723 // work around unused variable warnings
4724 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
4725 || dynamic_array[ni.number - 1] != 543);
4731 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99
4733 CC="$ac_save_CC $ac_arg"
4734 if ac_fn_c_try_compile "$LINENO"; then :
4735 ac_cv_prog_cc_c99=$ac_arg
4737 rm -f core conftest.err conftest.$ac_objext
4738 test "x$ac_cv_prog_cc_c99" != "xno" && break
4740 rm -f conftest.$ac_ext
4745 case "x$ac_cv_prog_cc_c99" in
4747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4748 $as_echo "none needed" >&6; } ;;
4750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4751 $as_echo "unsupported" >&6; } ;;
4753 CC="$CC $ac_cv_prog_cc_c99"
4754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
4755 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
4757 if test "x$ac_cv_prog_cc_c99" != xno; then :
4758 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
4760 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4761 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4762 if test "${ac_cv_prog_cc_c89+set}" = set; then :
4763 $as_echo_n "(cached) " >&6
4765 ac_cv_prog_cc_c89=no
4767 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4768 /* end confdefs.h. */
4771 #include <sys/types.h>
4772 #include <sys/stat.h>
4773 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4774 struct buf { int x; };
4775 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4776 static char *e (p, i)
4782 static char *f (char * (*g) (char **, int), char **p, ...)
4787 s = g (p, va_arg (v,int));
4792 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
4793 function prototypes and stuff, but not '\xHH' hex character constants.
4794 These don't provoke an error unfortunately, instead are silently treated
4795 as 'x'. The following induces an error, until -std is added to get
4796 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
4797 array size at least. It's necessary to write '\x00'==0 to get something
4798 that's true only with -std. */
4799 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4801 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4802 inside strings and character constants. */
4804 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4806 int test (int i, double x);
4807 struct s1 {int (*f) (int a);};
4808 struct s2 {int (*f) (double a);};
4809 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4815 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4820 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4821 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4823 CC="$ac_save_CC $ac_arg"
4824 if ac_fn_c_try_compile "$LINENO"; then :
4825 ac_cv_prog_cc_c89=$ac_arg
4827 rm -f core conftest.err conftest.$ac_objext
4828 test "x$ac_cv_prog_cc_c89" != "xno" && break
4830 rm -f conftest.$ac_ext
4835 case "x$ac_cv_prog_cc_c89" in
4837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4838 $as_echo "none needed" >&6; } ;;
4840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4841 $as_echo "unsupported" >&6; } ;;
4843 CC="$CC $ac_cv_prog_cc_c89"
4844 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4845 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
4847 if test "x$ac_cv_prog_cc_c89" != xno; then :
4848 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
4850 ac_cv_prog_cc_stdc=no
4856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
4857 $as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
4858 if test "${ac_cv_prog_cc_stdc+set}" = set; then :
4859 $as_echo_n "(cached) " >&6
4862 case $ac_cv_prog_cc_stdc in #(
4864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4865 $as_echo "unsupported" >&6; } ;; #(
4867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4868 $as_echo "none needed" >&6; } ;; #(
4870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
4871 $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
4874 if test "x$CC" != xcc; then
4875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
4876 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
4878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
4879 $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
4881 set dummy $CC; ac_cc=`$as_echo "$2" |
4882 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
4883 if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
4884 $as_echo_n "(cached) " >&6
4886 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4887 /* end confdefs.h. */
4897 # Make sure it works both with $CC and with simple cc.
4898 # We do the test twice because some compilers refuse to overwrite an
4899 # existing .o file with -o, though they will create one.
4900 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
4902 if { { case "(($ac_try" in
4903 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4904 *) ac_try_echo=$ac_try;;
4906 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4907 $as_echo "$ac_try_echo"; } >&5
4908 (eval "$ac_try") 2>&5
4910 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4911 test $ac_status = 0; } &&
4912 test -f conftest2.$ac_objext && { { case "(($ac_try" in
4913 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4914 *) ac_try_echo=$ac_try;;
4916 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4917 $as_echo "$ac_try_echo"; } >&5
4918 (eval "$ac_try") 2>&5
4920 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4921 test $ac_status = 0; };
4923 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
4924 if test "x$CC" != xcc; then
4925 # Test first that cc exists at all.
4926 if { ac_try='cc -c conftest.$ac_ext >&5'
4927 { { case "(($ac_try" in
4928 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4929 *) ac_try_echo=$ac_try;;
4931 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4932 $as_echo "$ac_try_echo"; } >&5
4933 (eval "$ac_try") 2>&5
4935 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4936 test $ac_status = 0; }; }; then
4937 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
4939 if { { case "(($ac_try" in
4940 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4941 *) ac_try_echo=$ac_try;;
4943 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4944 $as_echo "$ac_try_echo"; } >&5
4945 (eval "$ac_try") 2>&5
4947 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4948 test $ac_status = 0; } &&
4949 test -f conftest2.$ac_objext && { { case "(($ac_try" in
4950 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4951 *) ac_try_echo=$ac_try;;
4953 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4954 $as_echo "$ac_try_echo"; } >&5
4955 (eval "$ac_try") 2>&5
4957 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4958 test $ac_status = 0; };
4963 # cc exists but doesn't like -o.
4964 eval ac_cv_prog_cc_${ac_cc}_c_o=no
4969 eval ac_cv_prog_cc_${ac_cc}_c_o=no
4971 rm -f core conftest*
4974 if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
4975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4976 $as_echo "yes" >&6; }
4978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4979 $as_echo "no" >&6; }
4981 $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
4985 # FIXME: we rely on the cache variable name because
4986 # there is no other way.
4988 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
4989 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
4990 if test "$am_t" != yes; then
4991 # Losing compiler, so override with the script.
4992 # FIXME: It is wrong to rewrite CC.
4993 # But if we don't then we get into trouble of one sort or another.
4994 # A longer-term fix would be to have automake use am__CC in this case,
4995 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
4996 CC="$am_aux_dir/compile $CC"
5001 ac_cpp='$CPP $CPPFLAGS'
5002 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5003 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5004 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5006 $as_echo_n "checking how to run the C preprocessor... " >&6; }
5007 # On Suns, sometimes $CPP names a directory.
5008 if test -n "$CPP" && test -d "$CPP"; then
5011 if test -z "$CPP"; then
5012 if test "${ac_cv_prog_CPP+set}" = set; then :
5013 $as_echo_n "(cached) " >&6
5015 # Double quotes because CPP needs to be expanded
5016 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5019 for ac_c_preproc_warn_flag in '' yes
5021 # Use a header file that comes with gcc, so configuring glibc
5022 # with a fresh cross-compiler works.
5023 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5024 # <limits.h> exists even on freestanding compilers.
5025 # On the NeXT, cc -E runs the code through the compiler's parser,
5026 # not just through cpp. "Syntax error" is here to catch this case.
5027 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5028 /* end confdefs.h. */
5030 # include <limits.h>
5032 # include <assert.h>
5036 if ac_fn_c_try_cpp "$LINENO"; then :
5039 # Broken: fails on valid input.
5042 rm -f conftest.err conftest.$ac_ext
5044 # OK, works on sane cases. Now check whether nonexistent headers
5045 # can be detected and how.
5046 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5047 /* end confdefs.h. */
5048 #include <ac_nonexistent.h>
5050 if ac_fn_c_try_cpp "$LINENO"; then :
5051 # Broken: success on invalid input.
5054 # Passes both tests.
5058 rm -f conftest.err conftest.$ac_ext
5061 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5062 rm -f conftest.err conftest.$ac_ext
5063 if $ac_preproc_ok; then :
5075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5076 $as_echo "$CPP" >&6; }
5078 for ac_c_preproc_warn_flag in '' yes
5080 # Use a header file that comes with gcc, so configuring glibc
5081 # with a fresh cross-compiler works.
5082 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5083 # <limits.h> exists even on freestanding compilers.
5084 # On the NeXT, cc -E runs the code through the compiler's parser,
5085 # not just through cpp. "Syntax error" is here to catch this case.
5086 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5087 /* end confdefs.h. */
5089 # include <limits.h>
5091 # include <assert.h>
5095 if ac_fn_c_try_cpp "$LINENO"; then :
5098 # Broken: fails on valid input.
5101 rm -f conftest.err conftest.$ac_ext
5103 # OK, works on sane cases. Now check whether nonexistent headers
5104 # can be detected and how.
5105 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5106 /* end confdefs.h. */
5107 #include <ac_nonexistent.h>
5109 if ac_fn_c_try_cpp "$LINENO"; then :
5110 # Broken: success on invalid input.
5113 # Passes both tests.
5117 rm -f conftest.err conftest.$ac_ext
5120 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5121 rm -f conftest.err conftest.$ac_ext
5122 if $ac_preproc_ok; then :
5125 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5126 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5127 as_fn_error "C preprocessor \"$CPP\" fails sanity check
5128 See \`config.log' for more details." "$LINENO" 5; }
5132 ac_cpp='$CPP $CPPFLAGS'
5133 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5134 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5135 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5137 if test -n "$ac_tool_prefix"; then
5138 # Extract the first word of "${ac_tool_prefix}nm", so it can be a program name with args.
5139 set dummy ${ac_tool_prefix}nm; ac_word=$2
5140 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5141 $as_echo_n "checking for $ac_word... " >&6; }
5142 if test "${ac_cv_prog_NM+set}" = set; then :
5143 $as_echo_n "(cached) " >&6
5145 if test -n "$NM"; then
5146 ac_cv_prog_NM="$NM" # Let the user override the test.
5148 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5152 test -z "$as_dir" && as_dir=.
5153 for ac_exec_ext in '' $ac_executable_extensions; do
5154 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5155 ac_cv_prog_NM="${ac_tool_prefix}nm"
5156 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5166 if test -n "$NM"; then
5167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
5168 $as_echo "$NM" >&6; }
5170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5171 $as_echo "no" >&6; }
5176 if test -z "$ac_cv_prog_NM"; then
5178 # Extract the first word of "nm", so it can be a program name with args.
5179 set dummy nm; ac_word=$2
5180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5181 $as_echo_n "checking for $ac_word... " >&6; }
5182 if test "${ac_cv_prog_ac_ct_NM+set}" = set; then :
5183 $as_echo_n "(cached) " >&6
5185 if test -n "$ac_ct_NM"; then
5186 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test.
5188 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5192 test -z "$as_dir" && as_dir=.
5193 for ac_exec_ext in '' $ac_executable_extensions; do
5194 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5195 ac_cv_prog_ac_ct_NM="nm"
5196 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5205 ac_ct_NM=$ac_cv_prog_ac_ct_NM
5206 if test -n "$ac_ct_NM"; then
5207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5
5208 $as_echo "$ac_ct_NM" >&6; }
5210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5211 $as_echo "no" >&6; }
5214 if test "x$ac_ct_NM" = x; then
5217 case $cross_compiling:$ac_tool_warned in
5219 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5220 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5221 ac_tool_warned=yes ;;
5229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
5230 $as_echo_n "checking whether ln -s works... " >&6; }
5232 if test "$LN_S" = "ln -s"; then
5233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5234 $as_echo "yes" >&6; }
5236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
5237 $as_echo "no, using $LN_S" >&6; }
5240 if test -n "$ac_tool_prefix"; then
5241 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5242 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5244 $as_echo_n "checking for $ac_word... " >&6; }
5245 if test "${ac_cv_prog_RANLIB+set}" = set; then :
5246 $as_echo_n "(cached) " >&6
5248 if test -n "$RANLIB"; then
5249 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5251 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5255 test -z "$as_dir" && as_dir=.
5256 for ac_exec_ext in '' $ac_executable_extensions; do
5257 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5258 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5259 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5268 RANLIB=$ac_cv_prog_RANLIB
5269 if test -n "$RANLIB"; then
5270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
5271 $as_echo "$RANLIB" >&6; }
5273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5274 $as_echo "no" >&6; }
5279 if test -z "$ac_cv_prog_RANLIB"; then
5280 ac_ct_RANLIB=$RANLIB
5281 # Extract the first word of "ranlib", so it can be a program name with args.
5282 set dummy ranlib; ac_word=$2
5283 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5284 $as_echo_n "checking for $ac_word... " >&6; }
5285 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
5286 $as_echo_n "(cached) " >&6
5288 if test -n "$ac_ct_RANLIB"; then
5289 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
5291 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5295 test -z "$as_dir" && as_dir=.
5296 for ac_exec_ext in '' $ac_executable_extensions; do
5297 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5298 ac_cv_prog_ac_ct_RANLIB="ranlib"
5299 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5308 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
5309 if test -n "$ac_ct_RANLIB"; then
5310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
5311 $as_echo "$ac_ct_RANLIB" >&6; }
5313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5314 $as_echo "no" >&6; }
5317 if test "x$ac_ct_RANLIB" = x; then
5320 case $cross_compiling:$ac_tool_warned in
5322 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5323 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5324 ac_tool_warned=yes ;;
5326 RANLIB=$ac_ct_RANLIB
5329 RANLIB="$ac_cv_prog_RANLIB"
5332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a POSIX-compliant shell" >&5
5333 $as_echo_n "checking for a POSIX-compliant shell... " >&6; }
5334 if test "${ac_cv_path_shell+set}" = set; then :
5335 $as_echo_n "(cached) " >&6
5338 # Test the noclobber option, using the portable POSIX.2 syntax.
5342 >|conftest.c || exit
5343 !>conftest.c || exit
5344 # Test that $(...) works.
5345 test "$(expr 3 + 4)" -eq 7 || exit
5352 if ("$SHELL" -c "$ac_command") 2>/dev/null; then
5353 ac_cv_path_shell=$SHELL
5357 case $ac_cv_path_shell in
5359 # Prefer shells that are more likely to be installed in the
5360 # same place on all hosts of this platform. Therefore, prefer
5361 # shells in /bin and /usr/bin to shells in the installer's
5362 # PATH. Also, loop through PATH first and then through
5363 # shells, since less-"nice" shells in /bin and /usr/bin are
5364 # more likely to be installed than "nicer" shells elsewhere.
5365 as_save_IFS=$IFS; IFS=:
5366 for as_dir in /bin /usr/bin $PATH
5371 for ac_base in sh bash ksh sh5; do
5373 if ("$as_dir/$ac_base" -c "$ac_command") 2>/dev/null; then
5374 ac_cv_path_shell=$as_dir/$ac_base
5378 case $ac_cv_path_shell in
5387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_shell" >&5
5388 $as_echo "$ac_cv_path_shell" >&6; }
5389 SHELL=$ac_cv_path_shell
5390 if test "$SHELL" = no; then
5392 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using $SHELL, even though it does not conform to POSIX" >&5
5393 $as_echo "$as_me: WARNING: using $SHELL, even though it does not conform to POSIX" >&2;}
5397 # Make sure we can run config.sub.
5398 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
5399 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
5401 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
5402 $as_echo_n "checking build system type... " >&6; }
5403 if test "${ac_cv_build+set}" = set; then :
5404 $as_echo_n "(cached) " >&6
5406 ac_build_alias=$build_alias
5407 test "x$ac_build_alias" = x &&
5408 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
5409 test "x$ac_build_alias" = x &&
5410 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
5411 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
5412 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
5415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
5416 $as_echo "$ac_cv_build" >&6; }
5417 case $ac_cv_build in
5419 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
5422 ac_save_IFS=$IFS; IFS='-'
5428 # Remember, the first character of IFS is used to create $*,
5429 # except with old shells:
5432 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
5435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
5436 $as_echo_n "checking host system type... " >&6; }
5437 if test "${ac_cv_host+set}" = set; then :
5438 $as_echo_n "(cached) " >&6
5440 if test "x$host_alias" = x; then
5441 ac_cv_host=$ac_cv_build
5443 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
5444 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
5448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
5449 $as_echo "$ac_cv_host" >&6; }
5452 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
5455 ac_save_IFS=$IFS; IFS='-'
5461 # Remember, the first character of IFS is used to create $*,
5462 # except with old shells:
5465 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
5470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
5471 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5472 if test "${ac_cv_path_GREP+set}" = set; then :
5473 $as_echo_n "(cached) " >&6
5475 if test -z "$GREP"; then
5476 ac_path_GREP_found=false
5477 # Loop through the user's path and test for each of PROGNAME-LIST
5478 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5479 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5482 test -z "$as_dir" && as_dir=.
5483 for ac_prog in grep ggrep; do
5484 for ac_exec_ext in '' $ac_executable_extensions; do
5485 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5486 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5487 # Check for GNU ac_path_GREP and select it if it is found.
5488 # Check for GNU $ac_path_GREP
5489 case `"$ac_path_GREP" --version 2>&1` in
5491 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5494 $as_echo_n 0123456789 >"conftest.in"
5497 cat "conftest.in" "conftest.in" >"conftest.tmp"
5498 mv "conftest.tmp" "conftest.in"
5499 cp "conftest.in" "conftest.nl"
5500 $as_echo 'GREP' >> "conftest.nl"
5501 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5502 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5503 as_fn_arith $ac_count + 1 && ac_count=$as_val
5504 if test $ac_count -gt ${ac_path_GREP_max-0}; then
5505 # Best one so far, save it but keep looking for a better one
5506 ac_cv_path_GREP="$ac_path_GREP"
5507 ac_path_GREP_max=$ac_count
5509 # 10*(2^10) chars as input seems more than enough
5510 test $ac_count -gt 10 && break
5512 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5515 $ac_path_GREP_found && break 3
5520 if test -z "$ac_cv_path_GREP"; then
5521 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5524 ac_cv_path_GREP=$GREP
5528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
5529 $as_echo "$ac_cv_path_GREP" >&6; }
5530 GREP="$ac_cv_path_GREP"
5533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
5534 $as_echo_n "checking for egrep... " >&6; }
5535 if test "${ac_cv_path_EGREP+set}" = set; then :
5536 $as_echo_n "(cached) " >&6
5538 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5539 then ac_cv_path_EGREP="$GREP -E"
5541 if test -z "$EGREP"; then
5542 ac_path_EGREP_found=false
5543 # Loop through the user's path and test for each of PROGNAME-LIST
5544 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5545 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5548 test -z "$as_dir" && as_dir=.
5549 for ac_prog in egrep; do
5550 for ac_exec_ext in '' $ac_executable_extensions; do
5551 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
5552 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
5553 # Check for GNU ac_path_EGREP and select it if it is found.
5554 # Check for GNU $ac_path_EGREP
5555 case `"$ac_path_EGREP" --version 2>&1` in
5557 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5560 $as_echo_n 0123456789 >"conftest.in"
5563 cat "conftest.in" "conftest.in" >"conftest.tmp"
5564 mv "conftest.tmp" "conftest.in"
5565 cp "conftest.in" "conftest.nl"
5566 $as_echo 'EGREP' >> "conftest.nl"
5567 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5568 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5569 as_fn_arith $ac_count + 1 && ac_count=$as_val
5570 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5571 # Best one so far, save it but keep looking for a better one
5572 ac_cv_path_EGREP="$ac_path_EGREP"
5573 ac_path_EGREP_max=$ac_count
5575 # 10*(2^10) chars as input seems more than enough
5576 test $ac_count -gt 10 && break
5578 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5581 $ac_path_EGREP_found && break 3
5586 if test -z "$ac_cv_path_EGREP"; then
5587 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5590 ac_cv_path_EGREP=$EGREP
5595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
5596 $as_echo "$ac_cv_path_EGREP" >&6; }
5597 EGREP="$ac_cv_path_EGREP"
5600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
5601 $as_echo_n "checking for ANSI C header files... " >&6; }
5602 if test "${ac_cv_header_stdc+set}" = set; then :
5603 $as_echo_n "(cached) " >&6
5605 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5606 /* end confdefs.h. */
5620 if ac_fn_c_try_compile "$LINENO"; then :
5621 ac_cv_header_stdc=yes
5623 ac_cv_header_stdc=no
5625 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5627 if test $ac_cv_header_stdc = yes; then
5628 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5629 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5630 /* end confdefs.h. */
5634 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5635 $EGREP "memchr" >/dev/null 2>&1; then :
5638 ac_cv_header_stdc=no
5644 if test $ac_cv_header_stdc = yes; then
5645 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5646 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5647 /* end confdefs.h. */
5651 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5652 $EGREP "free" >/dev/null 2>&1; then :
5655 ac_cv_header_stdc=no
5661 if test $ac_cv_header_stdc = yes; then
5662 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5663 if test "$cross_compiling" = yes; then :
5666 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5667 /* end confdefs.h. */
5670 #if ((' ' & 0x0FF) == 0x020)
5671 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5672 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5674 # define ISLOWER(c) \
5675 (('a' <= (c) && (c) <= 'i') \
5676 || ('j' <= (c) && (c) <= 'r') \
5677 || ('s' <= (c) && (c) <= 'z'))
5678 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5681 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
5686 for (i = 0; i < 256; i++)
5687 if (XOR (islower (i), ISLOWER (i))
5688 || toupper (i) != TOUPPER (i))
5693 if ac_fn_c_try_run "$LINENO"; then :
5696 ac_cv_header_stdc=no
5698 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
5699 conftest.$ac_objext conftest.beam conftest.$ac_ext
5704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
5705 $as_echo "$ac_cv_header_stdc" >&6; }
5706 if test $ac_cv_header_stdc = yes; then
5708 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
5712 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
5713 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
5714 inttypes.h stdint.h unistd.h
5716 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
5717 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
5719 eval as_val=\$$as_ac_Header
5720 if test "x$as_val" = x""yes; then :
5721 cat >>confdefs.h <<_ACEOF
5722 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
5733 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
5734 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
5741 if test "$MINIX" = yes; then
5743 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
5746 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
5749 $as_echo "#define _MINIX 1" >>confdefs.h
5756 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
5762 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
5763 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
5764 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
5765 $as_echo_n "(cached) " >&6
5767 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5768 /* end confdefs.h. */
5770 # define __EXTENSIONS__ 1
5771 $ac_includes_default
5780 if ac_fn_c_try_compile "$LINENO"; then :
5781 ac_cv_safe_to_define___extensions__=yes
5783 ac_cv_safe_to_define___extensions__=no
5785 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
5788 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
5789 test $ac_cv_safe_to_define___extensions__ = yes &&
5790 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
5792 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
5794 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
5796 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
5798 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
5807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
5808 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
5809 if test "${ac_cv_sys_largefile_source+set}" = set; then :
5810 $as_echo_n "(cached) " >&6
5813 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5814 /* end confdefs.h. */
5815 #include <sys/types.h> /* for off_t */
5820 int (*fp) (FILE *, off_t, int) = fseeko;
5821 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
5826 if ac_fn_c_try_link "$LINENO"; then :
5827 ac_cv_sys_largefile_source=no; break
5829 rm -f core conftest.err conftest.$ac_objext \
5830 conftest$ac_exeext conftest.$ac_ext
5831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5832 /* end confdefs.h. */
5833 #define _LARGEFILE_SOURCE 1
5834 #include <sys/types.h> /* for off_t */
5839 int (*fp) (FILE *, off_t, int) = fseeko;
5840 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
5845 if ac_fn_c_try_link "$LINENO"; then :
5846 ac_cv_sys_largefile_source=1; break
5848 rm -f core conftest.err conftest.$ac_objext \
5849 conftest$ac_exeext conftest.$ac_ext
5850 ac_cv_sys_largefile_source=unknown
5854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
5855 $as_echo "$ac_cv_sys_largefile_source" >&6; }
5856 case $ac_cv_sys_largefile_source in #(
5859 cat >>confdefs.h <<_ACEOF
5860 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
5866 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
5867 # in glibc 2.1.3, but that breaks too many other things.
5868 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
5869 if test $ac_cv_sys_largefile_source != unknown; then
5871 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
5878 # IEEE behaviour is the default on all CPUs except Alpha and SH
5879 # (according to the test results of Bruno Haible's ieeefp/fenv_default.m4
5880 # and the GCC 4.1.2 manual).
5883 # On Alpha systems, a compiler option provides the behaviour.
5884 # See the ieee(3) manual page, also available at
5885 # <http://h30097.www3.hp.com/docs/base_doc/DOCUMENTATION/V51B_HTML/MAN/MAN3/0600____.HTM>
5886 if test -n "$GCC"; then
5887 # GCC has the option -mieee.
5888 CPPFLAGS="$CPPFLAGS -mieee"
5890 # Compaq (ex-DEC) C has the option -ieee.
5891 CPPFLAGS="$CPPFLAGS -ieee"
5895 if test -n "$GCC"; then
5896 # GCC has the option -mieee.
5897 CPPFLAGS="$CPPFLAGS -mieee"
5910 # Check whether --enable-largefile was given.
5911 if test "${enable_largefile+set}" = set; then :
5912 enableval=$enable_largefile;
5915 if test "$enable_largefile" != no; then
5917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
5918 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
5919 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
5920 $as_echo_n "(cached) " >&6
5922 ac_cv_sys_largefile_CC=no
5923 if test "$GCC" != yes; then
5926 # IRIX 6.2 and later do not support large files by default,
5927 # so use the C compiler's -n32 option if that helps.
5928 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5929 /* end confdefs.h. */
5930 #include <sys/types.h>
5931 /* Check that off_t can represent 2**63 - 1 correctly.
5932 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5933 since some C++ compilers masquerading as C compilers
5934 incorrectly reject 9223372036854775807. */
5935 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5936 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5937 && LARGE_OFF_T % 2147483647 == 1)
5947 if ac_fn_c_try_compile "$LINENO"; then :
5950 rm -f core conftest.err conftest.$ac_objext
5952 if ac_fn_c_try_compile "$LINENO"; then :
5953 ac_cv_sys_largefile_CC=' -n32'; break
5955 rm -f core conftest.err conftest.$ac_objext
5959 rm -f conftest.$ac_ext
5962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
5963 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
5964 if test "$ac_cv_sys_largefile_CC" != no; then
5965 CC=$CC$ac_cv_sys_largefile_CC
5968 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
5969 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
5970 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
5971 $as_echo_n "(cached) " >&6
5974 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5975 /* end confdefs.h. */
5976 #include <sys/types.h>
5977 /* Check that off_t can represent 2**63 - 1 correctly.
5978 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5979 since some C++ compilers masquerading as C compilers
5980 incorrectly reject 9223372036854775807. */
5981 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5982 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5983 && LARGE_OFF_T % 2147483647 == 1)
5993 if ac_fn_c_try_compile "$LINENO"; then :
5994 ac_cv_sys_file_offset_bits=no; break
5996 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5997 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5998 /* end confdefs.h. */
5999 #define _FILE_OFFSET_BITS 64
6000 #include <sys/types.h>
6001 /* Check that off_t can represent 2**63 - 1 correctly.
6002 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6003 since some C++ compilers masquerading as C compilers
6004 incorrectly reject 9223372036854775807. */
6005 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6006 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6007 && LARGE_OFF_T % 2147483647 == 1)
6017 if ac_fn_c_try_compile "$LINENO"; then :
6018 ac_cv_sys_file_offset_bits=64; break
6020 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6021 ac_cv_sys_file_offset_bits=unknown
6025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6026 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
6027 case $ac_cv_sys_file_offset_bits in #(
6030 cat >>confdefs.h <<_ACEOF
6031 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6036 if test $ac_cv_sys_file_offset_bits = unknown; then
6037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6038 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
6039 if test "${ac_cv_sys_large_files+set}" = set; then :
6040 $as_echo_n "(cached) " >&6
6043 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6044 /* end confdefs.h. */
6045 #include <sys/types.h>
6046 /* Check that off_t can represent 2**63 - 1 correctly.
6047 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6048 since some C++ compilers masquerading as C compilers
6049 incorrectly reject 9223372036854775807. */
6050 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6051 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6052 && LARGE_OFF_T % 2147483647 == 1)
6062 if ac_fn_c_try_compile "$LINENO"; then :
6063 ac_cv_sys_large_files=no; break
6065 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6066 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6067 /* end confdefs.h. */
6068 #define _LARGE_FILES 1
6069 #include <sys/types.h>
6070 /* Check that off_t can represent 2**63 - 1 correctly.
6071 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6072 since some C++ compilers masquerading as C compilers
6073 incorrectly reject 9223372036854775807. */
6074 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6075 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6076 && LARGE_OFF_T % 2147483647 == 1)
6086 if ac_fn_c_try_compile "$LINENO"; then :
6087 ac_cv_sys_large_files=1; break
6089 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6090 ac_cv_sys_large_files=unknown
6094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6095 $as_echo "$ac_cv_sys_large_files" >&6; }
6096 case $ac_cv_sys_large_files in #(
6099 cat >>confdefs.h <<_ACEOF
6100 #define _LARGE_FILES $ac_cv_sys_large_files
6114 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
6115 # for constant arguments. Useless!
6116 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
6117 $as_echo_n "checking for working alloca.h... " >&6; }
6118 if test "${ac_cv_working_alloca_h+set}" = set; then :
6119 $as_echo_n "(cached) " >&6
6121 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6122 /* end confdefs.h. */
6127 char *p = (char *) alloca (2 * sizeof (int));
6133 if ac_fn_c_try_link "$LINENO"; then :
6134 ac_cv_working_alloca_h=yes
6136 ac_cv_working_alloca_h=no
6138 rm -f core conftest.err conftest.$ac_objext \
6139 conftest$ac_exeext conftest.$ac_ext
6141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
6142 $as_echo "$ac_cv_working_alloca_h" >&6; }
6143 if test $ac_cv_working_alloca_h = yes; then
6145 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
6149 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
6150 $as_echo_n "checking for alloca... " >&6; }
6151 if test "${ac_cv_func_alloca_works+set}" = set; then :
6152 $as_echo_n "(cached) " >&6
6154 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6155 /* end confdefs.h. */
6157 # define alloca __builtin_alloca
6160 # include <malloc.h>
6161 # define alloca _alloca
6163 # ifdef HAVE_ALLOCA_H
6164 # include <alloca.h>
6169 # ifndef alloca /* predefined by HP cc +Olibcalls */
6180 char *p = (char *) alloca (1);
6186 if ac_fn_c_try_link "$LINENO"; then :
6187 ac_cv_func_alloca_works=yes
6189 ac_cv_func_alloca_works=no
6191 rm -f core conftest.err conftest.$ac_objext \
6192 conftest$ac_exeext conftest.$ac_ext
6194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
6195 $as_echo "$ac_cv_func_alloca_works" >&6; }
6197 if test $ac_cv_func_alloca_works = yes; then
6199 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
6202 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
6203 # that cause trouble. Some versions do not even contain alloca or
6204 # contain a buggy version. If you still want to use their alloca,
6205 # use ar to extract alloca.o from them instead of compiling alloca.c.
6211 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
6213 $as_echo "#define C_ALLOCA 1" >>confdefs.h
6216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
6217 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
6218 if test "${ac_cv_os_cray+set}" = set; then :
6219 $as_echo_n "(cached) " >&6
6221 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6222 /* end confdefs.h. */
6223 #if defined CRAY && ! defined CRAY2
6230 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6231 $EGREP "webecray" >/dev/null 2>&1; then :
6239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
6240 $as_echo "$ac_cv_os_cray" >&6; }
6241 if test $ac_cv_os_cray = yes; then
6242 for ac_func in _getb67 GETB67 getb67; do
6243 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
6244 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
6245 eval as_val=\$$as_ac_var
6246 if test "x$as_val" = x""yes; then :
6248 cat >>confdefs.h <<_ACEOF
6249 #define CRAY_STACKSEG_END $ac_func
6258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
6259 $as_echo_n "checking stack direction for C alloca... " >&6; }
6260 if test "${ac_cv_c_stack_direction+set}" = set; then :
6261 $as_echo_n "(cached) " >&6
6263 if test "$cross_compiling" = yes; then :
6264 ac_cv_c_stack_direction=0
6266 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6267 /* end confdefs.h. */
6268 $ac_includes_default
6270 find_stack_direction ()
6272 static char *addr = 0;
6277 return find_stack_direction ();
6280 return (&dummy > addr) ? 1 : -1;
6286 return find_stack_direction () < 0;
6289 if ac_fn_c_try_run "$LINENO"; then :
6290 ac_cv_c_stack_direction=1
6292 ac_cv_c_stack_direction=-1
6294 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6295 conftest.$ac_objext conftest.beam conftest.$ac_ext
6299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
6300 $as_echo "$ac_cv_c_stack_direction" >&6; }
6301 cat >>confdefs.h <<_ACEOF
6302 #define STACK_DIRECTION $ac_cv_c_stack_direction
6308 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
6309 if test "x$ac_cv_type_size_t" = x""yes; then :
6313 cat >>confdefs.h <<_ACEOF
6314 #define size_t unsigned int
6320 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc, realloc, calloc are POSIX compliant" >&5
6321 $as_echo_n "checking whether malloc, realloc, calloc are POSIX compliant... " >&6; }
6322 if test "${gl_cv_func_malloc_posix+set}" = set; then :
6323 $as_echo_n "(cached) " >&6
6326 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6327 /* end confdefs.h. */
6332 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
6340 if ac_fn_c_try_compile "$LINENO"; then :
6341 gl_cv_func_malloc_posix=yes
6343 gl_cv_func_malloc_posix=no
6345 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_malloc_posix" >&5
6349 $as_echo "$gl_cv_func_malloc_posix" >&6; }
6353 GNULIB_CALLOC_POSIX=0;
6354 GNULIB_CANONICALIZE_FILE_NAME=0;
6355 GNULIB_GETLOADAVG=0;
6357 GNULIB_MALLOC_POSIX=0;
6365 GNULIB_REALLOC_POSIX=0;
6374 HAVE_CALLOC_POSIX=1;
6375 HAVE_CANONICALIZE_FILE_NAME=1;
6376 HAVE_DECL_GETLOADAVG=1;
6378 HAVE_MALLOC_POSIX=1;
6384 HAVE_REALLOC_POSIX=1;
6391 HAVE_STRUCT_RANDOM_DATA=1;
6392 HAVE_SYS_LOADAVG_H=0;
6394 REPLACE_CANONICALIZE_FILE_NAME=0;
6402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
6403 $as_echo_n "checking for inline... " >&6; }
6404 if test "${ac_cv_c_inline+set}" = set; then :
6405 $as_echo_n "(cached) " >&6
6408 for ac_kw in inline __inline__ __inline; do
6409 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6410 /* end confdefs.h. */
6413 static $ac_kw foo_t static_foo () {return 0; }
6414 $ac_kw foo_t foo () {return 0; }
6418 if ac_fn_c_try_compile "$LINENO"; then :
6419 ac_cv_c_inline=$ac_kw
6421 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6422 test "$ac_cv_c_inline" != no && break
6426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
6427 $as_echo "$ac_cv_c_inline" >&6; }
6429 case $ac_cv_c_inline in
6432 case $ac_cv_c_inline in
6434 *) ac_val=$ac_cv_c_inline;;
6436 cat >>confdefs.h <<_ACEOF
6438 #define inline $ac_val
6450 GNULIB_EUIDACCESS=0;
6457 GNULIB_GETDOMAINNAME=0;
6458 GNULIB_GETDTABLESIZE=0;
6460 GNULIB_GETHOSTNAME=0;
6462 GNULIB_GETLOGIN_R=0;
6463 GNULIB_GETPAGESIZE=0;
6464 GNULIB_GETUSERSHELL=0;
6472 GNULIB_READLINKAT=0;
6477 GNULIB_UNISTD_H_GETOPT=0;
6478 GNULIB_UNISTD_H_SIGPIPE=0;
6491 HAVE_GETDOMAINNAME=1;
6492 HAVE_GETDTABLESIZE=1;
6497 HAVE_GETUSERSHELL=1;
6508 HAVE_DECL_ENVIRON=1;
6509 HAVE_DECL_GETLOGIN_R=1;
6521 REPLACE_GETGROUPS=0;
6522 REPLACE_GETPAGESIZE=0;
6536 UNISTD_H_HAVE_WINSOCK2_H=0;
6537 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
6540 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
6541 $as_echo_n "checking for uid_t in sys/types.h... " >&6; }
6542 if test "${ac_cv_type_uid_t+set}" = set; then :
6543 $as_echo_n "(cached) " >&6
6545 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6546 /* end confdefs.h. */
6547 #include <sys/types.h>
6550 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6551 $EGREP "uid_t" >/dev/null 2>&1; then :
6552 ac_cv_type_uid_t=yes
6559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
6560 $as_echo "$ac_cv_type_uid_t" >&6; }
6561 if test $ac_cv_type_uid_t = no; then
6563 $as_echo "#define uid_t int" >>confdefs.h
6566 $as_echo "#define gid_t int" >>confdefs.h
6570 for ac_header in unistd.h
6572 ac_fn_c_check_header_mongrel "$LINENO" "unistd.h" "ac_cv_header_unistd_h" "$ac_includes_default"
6573 if test "x$ac_cv_header_unistd_h" = x""yes; then :
6574 cat >>confdefs.h <<_ACEOF
6575 #define HAVE_UNISTD_H 1
6582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working chown" >&5
6583 $as_echo_n "checking for working chown... " >&6; }
6584 if test "${ac_cv_func_chown_works+set}" = set; then :
6585 $as_echo_n "(cached) " >&6
6587 if test "$cross_compiling" = yes; then :
6588 ac_cv_func_chown_works=no
6590 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6591 /* end confdefs.h. */
6592 $ac_includes_default
6598 char *f = "conftest.chown";
6599 struct stat before, after;
6601 if (creat (f, 0600) < 0)
6603 if (stat (f, &before) < 0)
6605 if (chown (f, (uid_t) -1, (gid_t) -1) == -1)
6607 if (stat (f, &after) < 0)
6609 return ! (before.st_uid == after.st_uid && before.st_gid == after.st_gid);
6615 if ac_fn_c_try_run "$LINENO"; then :
6616 ac_cv_func_chown_works=yes
6618 ac_cv_func_chown_works=no
6620 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6621 conftest.$ac_objext conftest.beam conftest.$ac_ext
6624 rm -f conftest.chown
6627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_chown_works" >&5
6628 $as_echo "$ac_cv_func_chown_works" >&6; }
6629 if test $ac_cv_func_chown_works = yes; then
6631 $as_echo "#define HAVE_CHOWN 1" >>confdefs.h
6636 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether chown dereferences symlinks" >&5
6637 $as_echo_n "checking whether chown dereferences symlinks... " >&6; }
6638 if test "${gl_cv_func_chown_follows_symlink+set}" = set; then :
6639 $as_echo_n "(cached) " >&6
6642 if test "$cross_compiling" = yes; then :
6643 gl_cv_func_chown_follows_symlink=yes
6646 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6647 /* end confdefs.h. */
6656 char const *dangling_symlink = "conftest.dangle";
6658 unlink (dangling_symlink);
6659 if (symlink ("conftest.no-such", dangling_symlink))
6662 /* Exit successfully on a conforming system,
6663 i.e., where chown must fail with ENOENT. */
6664 exit ( ! (chown (dangling_symlink, getuid (), getgid ()) != 0
6665 && errno == ENOENT));
6669 if ac_fn_c_try_run "$LINENO"; then :
6670 gl_cv_func_chown_follows_symlink=yes
6672 gl_cv_func_chown_follows_symlink=no
6674 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6675 conftest.$ac_objext conftest.beam conftest.$ac_ext
6681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_chown_follows_symlink" >&5
6682 $as_echo "$gl_cv_func_chown_follows_symlink" >&6; }
6684 if test $gl_cv_func_chown_follows_symlink = no; then
6686 $as_echo "#define CHOWN_MODIFIES_SYMLINK 1" >>confdefs.h
6693 for ac_func in $ac_func_list
6695 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
6696 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
6697 eval as_val=\$$as_ac_var
6698 if test "x$as_val" = x""yes; then :
6699 cat >>confdefs.h <<_ACEOF
6700 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
6717 if test $ac_cv_func_chown = no; then
6727 gl_LIBOBJS="$gl_LIBOBJS chown.$ac_objext"
6730 if test $gl_cv_func_chown_follows_symlink = no; then
6740 gl_LIBOBJS="$gl_LIBOBJS chown.$ac_objext"
6744 if test $ac_cv_func_chown_works = no; then
6746 $as_echo "#define CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE 1" >>confdefs.h
6757 gl_LIBOBJS="$gl_LIBOBJS chown.$ac_objext"
6761 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether chown honors trailing slash" >&5
6762 $as_echo_n "checking whether chown honors trailing slash... " >&6; }
6763 if test "${gl_cv_func_chown_slash_works+set}" = set; then :
6764 $as_echo_n "(cached) " >&6
6766 touch conftest.file && rm -f conftest.link
6767 if test "$cross_compiling" = yes; then :
6768 gl_cv_func_chown_slash_works="guessing no"
6770 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6771 /* end confdefs.h. */
6780 if (symlink ("conftest.file", "conftest.link")) return 1;
6781 if (chown ("conftest.link/", getuid (), getgid ()) == 0) return 2;
6787 if ac_fn_c_try_run "$LINENO"; then :
6788 gl_cv_func_chown_slash_works=yes
6790 gl_cv_func_chown_slash_works=no
6792 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6793 conftest.$ac_objext conftest.beam conftest.$ac_ext
6796 rm -f conftest.link conftest.file
6798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_chown_slash_works" >&5
6799 $as_echo "$gl_cv_func_chown_slash_works" >&6; }
6800 if test "$gl_cv_func_chown_slash_works" != yes; then
6802 $as_echo "#define CHOWN_TRAILING_SLASH_BUG 1" >>confdefs.h
6813 gl_LIBOBJS="$gl_LIBOBJS chown.$ac_objext"
6817 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether chown always updates ctime" >&5
6818 $as_echo_n "checking whether chown always updates ctime... " >&6; }
6819 if test "${gl_cv_func_chown_ctime_works+set}" = set; then :
6820 $as_echo_n "(cached) " >&6
6822 if test "$cross_compiling" = yes; then :
6823 gl_cv_func_chown_ctime_works="guessing no"
6825 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6826 /* end confdefs.h. */
6832 #include <sys/stat.h>
6837 struct stat st1, st2;
6838 if (close (creat ("conftest.file", 0600))) return 1;
6839 if (stat ("conftest.file", &st1)) return 2;
6841 if (chown ("conftest.file", st1.st_uid, st1.st_gid)) return 3;
6842 if (stat ("conftest.file", &st2)) return 4;
6843 if (st2.st_ctime <= st1.st_ctime) return 5;
6849 if ac_fn_c_try_run "$LINENO"; then :
6850 gl_cv_func_chown_ctime_works=yes
6852 gl_cv_func_chown_ctime_works=no
6854 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6855 conftest.$ac_objext conftest.beam conftest.$ac_ext
6860 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_chown_ctime_works" >&5
6861 $as_echo "$gl_cv_func_chown_ctime_works" >&6; }
6862 if test "$gl_cv_func_chown_ctime_works" != yes; then
6864 $as_echo "#define CHOWN_CHANGE_TIME_BUG 1" >>confdefs.h
6875 gl_LIBOBJS="$gl_LIBOBJS chown.$ac_objext"
6879 if test $REPLACE_CHOWN = 1 && test $ac_cv_func_fchown = no; then
6888 gl_LIBOBJS="$gl_LIBOBJS fchown-stub.$ac_objext"
6903 REPLACE_FDOPENDIR=0;
6908 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
6909 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
6910 if test "${gl_cv_have_include_next+set}" = set; then :
6911 $as_echo_n "(cached) " >&6
6913 rm -rf conftestd1a conftestd1b conftestd2
6914 mkdir conftestd1a conftestd1b conftestd2
6915 cat <<EOF > conftestd1a/conftest.h
6916 #define DEFINED_IN_CONFTESTD1
6917 #include_next <conftest.h>
6918 #ifdef DEFINED_IN_CONFTESTD2
6921 #error "include_next doesn't work"
6924 cat <<EOF > conftestd1b/conftest.h
6925 #define DEFINED_IN_CONFTESTD1
6927 #include_next <conftest.h>
6928 #ifdef DEFINED_IN_CONFTESTD2
6931 #error "include_next doesn't work"
6934 cat <<EOF > conftestd2/conftest.h
6935 #ifndef DEFINED_IN_CONFTESTD1
6936 #error "include_next test doesn't work"
6938 #define DEFINED_IN_CONFTESTD2
6940 gl_save_CPPFLAGS="$CPPFLAGS"
6941 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
6942 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6943 /* end confdefs.h. */
6944 #include <conftest.h>
6946 if ac_fn_c_try_compile "$LINENO"; then :
6947 gl_cv_have_include_next=yes
6949 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
6950 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6951 /* end confdefs.h. */
6952 #include <conftest.h>
6954 if ac_fn_c_try_compile "$LINENO"; then :
6955 gl_cv_have_include_next=buggy
6957 gl_cv_have_include_next=no
6959 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6962 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6963 CPPFLAGS="$gl_save_CPPFLAGS"
6964 rm -rf conftestd1a conftestd1b conftestd2
6967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
6968 $as_echo "$gl_cv_have_include_next" >&6; }
6969 PRAGMA_SYSTEM_HEADER=
6970 if test $gl_cv_have_include_next = yes; then
6971 INCLUDE_NEXT=include_next
6972 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
6973 if test -n "$GCC"; then
6974 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
6977 if test $gl_cv_have_include_next = buggy; then
6978 INCLUDE_NEXT=include
6979 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
6981 INCLUDE_NEXT=include
6982 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
6992 for ac_header in $ac_header_list
6994 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6995 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6997 eval as_val=\$$as_ac_Header
6998 if test "x$as_val" = x""yes; then :
6999 cat >>confdefs.h <<_ACEOF
7000 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7010 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system is Windows or MSDOS" >&5
7011 $as_echo_n "checking whether system is Windows or MSDOS... " >&6; }
7012 if test "${ac_cv_win_or_dos+set}" = set; then :
7013 $as_echo_n "(cached) " >&6
7016 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7017 /* end confdefs.h. */
7023 #if !defined _WIN32 && !defined __WIN32__ && !defined __MSDOS__ && !defined __CYGWIN__
7024 neither MSDOS nor Windows
7030 if ac_fn_c_try_compile "$LINENO"; then :
7031 ac_cv_win_or_dos=yes
7035 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_win_or_dos" >&5
7039 $as_echo "$ac_cv_win_or_dos" >&6; }
7041 if test x"$ac_cv_win_or_dos" = xyes; then
7042 ac_fs_accepts_drive_letter_prefix=1
7043 ac_fs_backslash_is_file_name_separator=1
7044 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether drive letter can start relative path" >&5
7045 $as_echo_n "checking whether drive letter can start relative path... " >&6; }
7046 if test "${ac_cv_drive_letter_can_be_relative+set}" = set; then :
7047 $as_echo_n "(cached) " >&6
7050 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7051 /* end confdefs.h. */
7057 #if defined __CYGWIN__
7058 drive letters are always absolute
7064 if ac_fn_c_try_compile "$LINENO"; then :
7065 ac_cv_drive_letter_can_be_relative=yes
7067 ac_cv_drive_letter_can_be_relative=no
7069 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_drive_letter_can_be_relative" >&5
7073 $as_echo "$ac_cv_drive_letter_can_be_relative" >&6; }
7074 if test x"$ac_cv_drive_letter_can_be_relative" = xyes; then
7075 ac_fs_drive_letter_can_be_relative=1
7077 ac_fs_drive_letter_can_be_relative=0
7080 ac_fs_accepts_drive_letter_prefix=0
7081 ac_fs_backslash_is_file_name_separator=0
7082 ac_fs_drive_letter_can_be_relative=0
7086 cat >>confdefs.h <<_ACEOF
7087 #define FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX $ac_fs_accepts_drive_letter_prefix
7094 cat >>confdefs.h <<_ACEOF
7095 #define FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR $ac_fs_backslash_is_file_name_separator
7100 cat >>confdefs.h <<_ACEOF
7101 #define FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE $ac_fs_drive_letter_can_be_relative
7107 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether // is distinct from /" >&5
7108 $as_echo_n "checking whether // is distinct from /... " >&6; }
7109 if test "${gl_cv_double_slash_root+set}" = set; then :
7110 $as_echo_n "(cached) " >&6
7112 if test x"$cross_compiling" = xyes ; then
7113 # When cross-compiling, there is no way to tell whether // is special
7114 # short of a list of hosts. However, the only known hosts to date
7115 # that have a distinct // are Apollo DomainOS (too old to port to),
7116 # Cygwin, and z/OS. If anyone knows of another system for which // has
7117 # special semantics and is distinct from /, please report it to
7118 # <bug-gnulib@gnu.org>.
7120 *-cygwin | i370-ibm-openedition)
7121 gl_cv_double_slash_root=yes ;;
7123 # Be optimistic and assume that / and // are the same when we
7125 gl_cv_double_slash_root='unknown, assuming no' ;;
7128 set x `ls -di / // 2>/dev/null`
7129 if test "$2" = "$4" && wc //dev/null >/dev/null 2>&1; then
7130 gl_cv_double_slash_root=no
7132 gl_cv_double_slash_root=yes
7136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_double_slash_root" >&5
7137 $as_echo "$gl_cv_double_slash_root" >&6; }
7138 if test "$gl_cv_double_slash_root" = yes; then
7140 $as_echo "#define DOUBLE_SLASH_IS_DISTINCT_ROOT 1" >>confdefs.h
7150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for complete errno.h" >&5
7151 $as_echo_n "checking for complete errno.h... " >&6; }
7152 if test "${gl_cv_header_errno_h_complete+set}" = set; then :
7153 $as_echo_n "(cached) " >&6
7156 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7157 /* end confdefs.h. */
7166 #if !defined ENOLINK
7172 #if !defined EMULTIHOP
7175 #if !defined EBADMSG
7178 #if !defined EOVERFLOW
7181 #if !defined ENOTSUP
7187 #if !defined ECANCELED
7192 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7193 $EGREP "booboo" >/dev/null 2>&1; then :
7194 gl_cv_header_errno_h_complete=no
7196 gl_cv_header_errno_h_complete=yes
7202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_complete" >&5
7203 $as_echo "$gl_cv_header_errno_h_complete" >&6; }
7204 if test $gl_cv_header_errno_h_complete = yes; then
7213 if test $gl_cv_have_include_next = yes; then
7214 gl_cv_next_errno_h='<'errno.h'>'
7216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <errno.h>" >&5
7217 $as_echo_n "checking absolute name of <errno.h>... " >&6; }
7218 if test "${gl_cv_next_errno_h+set}" = set; then :
7219 $as_echo_n "(cached) " >&6
7222 if test $ac_cv_header_errno_h = yes; then
7223 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7224 /* end confdefs.h. */
7229 aix*) gl_absname_cpp="$ac_cpp -C" ;;
7230 *) gl_absname_cpp="$ac_cpp" ;;
7232 gl_cv_next_errno_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
7233 sed -n '\#/errno.h#{
7234 s#.*"\(.*/errno.h\)".*#\1#
7240 gl_cv_next_errno_h='<'errno.h'>'
7244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_errno_h" >&5
7245 $as_echo "$gl_cv_next_errno_h" >&6; }
7247 NEXT_ERRNO_H=$gl_cv_next_errno_h
7249 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
7250 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
7251 gl_next_as_first_directive='<'errno.h'>'
7253 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
7254 gl_next_as_first_directive=$gl_cv_next_errno_h
7256 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H=$gl_next_as_first_directive
7264 if test -n "$ERRNO_H"; then
7265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EMULTIHOP value" >&5
7266 $as_echo_n "checking for EMULTIHOP value... " >&6; }
7267 if test "${gl_cv_header_errno_h_EMULTIHOP+set}" = set; then :
7268 $as_echo_n "(cached) " >&6
7271 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7272 /* end confdefs.h. */
7280 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7281 $EGREP "yes" >/dev/null 2>&1; then :
7282 gl_cv_header_errno_h_EMULTIHOP=yes
7284 gl_cv_header_errno_h_EMULTIHOP=no
7288 if test $gl_cv_header_errno_h_EMULTIHOP = no; then
7289 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7290 /* end confdefs.h. */
7292 #define _XOPEN_SOURCE_EXTENDED 1
7299 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7300 $EGREP "yes" >/dev/null 2>&1; then :
7301 gl_cv_header_errno_h_EMULTIHOP=hidden
7305 if test $gl_cv_header_errno_h_EMULTIHOP = hidden; then
7306 if ac_fn_c_compute_int "$LINENO" "EMULTIHOP" "gl_cv_header_errno_h_EMULTIHOP" "
7307 #define _XOPEN_SOURCE_EXTENDED 1
7309 /* The following two lines are a workaround against an autoconf-2.52 bug. */
7320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EMULTIHOP" >&5
7321 $as_echo "$gl_cv_header_errno_h_EMULTIHOP" >&6; }
7322 case $gl_cv_header_errno_h_EMULTIHOP in
7324 EMULTIHOP_HIDDEN=0; EMULTIHOP_VALUE=
7327 EMULTIHOP_HIDDEN=1; EMULTIHOP_VALUE="$gl_cv_header_errno_h_EMULTIHOP"
7335 if test -n "$ERRNO_H"; then
7336 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ENOLINK value" >&5
7337 $as_echo_n "checking for ENOLINK value... " >&6; }
7338 if test "${gl_cv_header_errno_h_ENOLINK+set}" = set; then :
7339 $as_echo_n "(cached) " >&6
7342 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7343 /* end confdefs.h. */
7351 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7352 $EGREP "yes" >/dev/null 2>&1; then :
7353 gl_cv_header_errno_h_ENOLINK=yes
7355 gl_cv_header_errno_h_ENOLINK=no
7359 if test $gl_cv_header_errno_h_ENOLINK = no; then
7360 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7361 /* end confdefs.h. */
7363 #define _XOPEN_SOURCE_EXTENDED 1
7370 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7371 $EGREP "yes" >/dev/null 2>&1; then :
7372 gl_cv_header_errno_h_ENOLINK=hidden
7376 if test $gl_cv_header_errno_h_ENOLINK = hidden; then
7377 if ac_fn_c_compute_int "$LINENO" "ENOLINK" "gl_cv_header_errno_h_ENOLINK" "
7378 #define _XOPEN_SOURCE_EXTENDED 1
7380 /* The following two lines are a workaround against an autoconf-2.52 bug. */
7391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_ENOLINK" >&5
7392 $as_echo "$gl_cv_header_errno_h_ENOLINK" >&6; }
7393 case $gl_cv_header_errno_h_ENOLINK in
7395 ENOLINK_HIDDEN=0; ENOLINK_VALUE=
7398 ENOLINK_HIDDEN=1; ENOLINK_VALUE="$gl_cv_header_errno_h_ENOLINK"
7406 if test -n "$ERRNO_H"; then
7407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EOVERFLOW value" >&5
7408 $as_echo_n "checking for EOVERFLOW value... " >&6; }
7409 if test "${gl_cv_header_errno_h_EOVERFLOW+set}" = set; then :
7410 $as_echo_n "(cached) " >&6
7413 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7414 /* end confdefs.h. */
7422 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7423 $EGREP "yes" >/dev/null 2>&1; then :
7424 gl_cv_header_errno_h_EOVERFLOW=yes
7426 gl_cv_header_errno_h_EOVERFLOW=no
7430 if test $gl_cv_header_errno_h_EOVERFLOW = no; then
7431 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7432 /* end confdefs.h. */
7434 #define _XOPEN_SOURCE_EXTENDED 1
7441 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7442 $EGREP "yes" >/dev/null 2>&1; then :
7443 gl_cv_header_errno_h_EOVERFLOW=hidden
7447 if test $gl_cv_header_errno_h_EOVERFLOW = hidden; then
7448 if ac_fn_c_compute_int "$LINENO" "EOVERFLOW" "gl_cv_header_errno_h_EOVERFLOW" "
7449 #define _XOPEN_SOURCE_EXTENDED 1
7451 /* The following two lines are a workaround against an autoconf-2.52 bug. */
7462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EOVERFLOW" >&5
7463 $as_echo "$gl_cv_header_errno_h_EOVERFLOW" >&6; }
7464 case $gl_cv_header_errno_h_EOVERFLOW in
7466 EOVERFLOW_HIDDEN=0; EOVERFLOW_VALUE=
7469 EOVERFLOW_HIDDEN=1; EOVERFLOW_VALUE="$gl_cv_header_errno_h_EOVERFLOW"
7477 ac_fn_c_check_decl "$LINENO" "strerror_r" "ac_cv_have_decl_strerror_r" "$ac_includes_default"
7478 if test "x$ac_cv_have_decl_strerror_r" = x""yes; then :
7484 cat >>confdefs.h <<_ACEOF
7485 #define HAVE_DECL_STRERROR_R $ac_have_decl
7488 for ac_func in strerror_r
7490 ac_fn_c_check_func "$LINENO" "strerror_r" "ac_cv_func_strerror_r"
7491 if test "x$ac_cv_func_strerror_r" = x""yes; then :
7492 cat >>confdefs.h <<_ACEOF
7493 #define HAVE_STRERROR_R 1
7499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror_r returns char *" >&5
7500 $as_echo_n "checking whether strerror_r returns char *... " >&6; }
7501 if test "${ac_cv_func_strerror_r_char_p+set}" = set; then :
7502 $as_echo_n "(cached) " >&6
7505 ac_cv_func_strerror_r_char_p=no
7506 if test $ac_cv_have_decl_strerror_r = yes; then
7507 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7508 /* end confdefs.h. */
7509 $ac_includes_default
7515 char x = *strerror_r (0, buf, sizeof buf);
7516 char *p = strerror_r (0, buf, sizeof buf);
7523 if ac_fn_c_try_compile "$LINENO"; then :
7524 ac_cv_func_strerror_r_char_p=yes
7526 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7528 # strerror_r is not declared. Choose between
7529 # systems that have relatively inaccessible declarations for the
7530 # function. BeOS and DEC UNIX 4.0 fall in this category, but the
7531 # former has a strerror_r that returns char*, while the latter
7532 # has a strerror_r that returns `int'.
7533 # This test should segfault on the DEC system.
7534 if test "$cross_compiling" = yes; then :
7537 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7538 /* end confdefs.h. */
7539 $ac_includes_default
7540 extern char *strerror_r ();
7545 char x = *strerror_r (0, buf, sizeof buf);
7546 return ! isalpha (x);
7551 if ac_fn_c_try_run "$LINENO"; then :
7552 ac_cv_func_strerror_r_char_p=yes
7554 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7555 conftest.$ac_objext conftest.beam conftest.$ac_ext
7561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strerror_r_char_p" >&5
7562 $as_echo "$ac_cv_func_strerror_r_char_p" >&6; }
7563 if test $ac_cv_func_strerror_r_char_p = yes; then
7565 $as_echo "#define STRERROR_R_CHAR_P 1" >>confdefs.h
7570 XGETTEXT_EXTRA_OPTIONS=
7604 REPLACE_UTIMENSAT=0;
7618 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
7619 if test "x$ac_cv_type_mode_t" = x""yes; then :
7623 cat >>confdefs.h <<_ACEOF
7631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for promoted mode_t type" >&5
7632 $as_echo_n "checking for promoted mode_t type... " >&6; }
7633 if test "${gl_cv_promoted_mode_t+set}" = set; then :
7634 $as_echo_n "(cached) " >&6
7637 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7638 /* end confdefs.h. */
7639 #include <sys/types.h>
7643 typedef int array[2 * (sizeof (mode_t) < sizeof (int)) - 1];
7648 if ac_fn_c_try_compile "$LINENO"; then :
7649 gl_cv_promoted_mode_t='int'
7651 gl_cv_promoted_mode_t='mode_t'
7653 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_promoted_mode_t" >&5
7657 $as_echo "$gl_cv_promoted_mode_t" >&6; }
7659 cat >>confdefs.h <<_ACEOF
7660 #define PROMOTED_MODE_T $gl_cv_promoted_mode_t
7670 GNULIB_FPRINTF_POSIX=0;
7682 GNULIB_OBSTACK_PRINTF=0;
7683 GNULIB_OBSTACK_PRINTF_POSIX=0;
7687 GNULIB_PRINTF_POSIX=0;
7695 GNULIB_SPRINTF_POSIX=0;
7696 GNULIB_STDIO_H_SIGPIPE=0;
7700 GNULIB_VFPRINTF_POSIX=0;
7702 GNULIB_VPRINTF_POSIX=0;
7704 GNULIB_VSPRINTF_POSIX=0;
7706 HAVE_DECL_GETDELIM=1;
7707 HAVE_DECL_GETLINE=1;
7708 HAVE_DECL_OBSTACK_PRINTF=1;
7709 HAVE_DECL_SNPRINTF=1;
7710 HAVE_DECL_VSNPRINTF=1;
7727 REPLACE_OBSTACK_PRINTF=0;
7736 REPLACE_STDIO_WRITE_FUNCS=0;
7737 REPLACE_VASPRINTF=0;
7741 REPLACE_VSNPRINTF=0;
7748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fcntl.h" >&5
7749 $as_echo_n "checking for working fcntl.h... " >&6; }
7750 if test "${gl_cv_header_working_fcntl_h+set}" = set; then :
7751 $as_echo_n "(cached) " >&6
7753 if test "$cross_compiling" = yes; then :
7754 gl_cv_header_working_fcntl_h=cross-compiling
7756 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7757 /* end confdefs.h. */
7758 #include <sys/types.h>
7759 #include <sys/stat.h>
7766 #define O_NOFOLLOW 0
7768 static int const constants[] =
7770 O_CREAT, O_EXCL, O_NOCTTY, O_TRUNC, O_APPEND,
7771 O_NONBLOCK, O_SYNC, O_ACCMODE, O_RDONLY, O_RDWR, O_WRONLY
7778 int status = !constants;
7780 static char const sym[] = "conftest.sym";
7781 if (symlink (".", sym) != 0
7782 || close (open (sym, O_RDONLY | O_NOFOLLOW)) == 0)
7787 static char const file[] = "confdefs.h";
7788 int fd = open (file, O_RDONLY | O_NOATIME);
7790 struct stat st0, st1;
7792 || fstat (fd, &st0) != 0
7794 || read (fd, &c, 1) != 1
7796 || stat (file, &st1) != 0
7797 || st0.st_atime != st1.st_atime)
7805 if ac_fn_c_try_run "$LINENO"; then :
7806 gl_cv_header_working_fcntl_h=yes
7809 32) gl_cv_header_working_fcntl_h='no (bad O_NOFOLLOW)';; #(
7810 64) gl_cv_header_working_fcntl_h='no (bad O_NOATIME)';; #(
7811 96) gl_cv_header_working_fcntl_h='no (bad O_NOATIME, O_NOFOLLOW)';; #(
7812 *) gl_cv_header_working_fcntl_h='no';;
7815 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7816 conftest.$ac_objext conftest.beam conftest.$ac_ext
7820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_fcntl_h" >&5
7821 $as_echo "$gl_cv_header_working_fcntl_h" >&6; }
7823 case $gl_cv_header_working_fcntl_h in #(
7824 *O_NOATIME* | no | cross-compiling) ac_val=0;; #(
7828 cat >>confdefs.h <<_ACEOF
7829 #define HAVE_WORKING_O_NOATIME $ac_val
7833 case $gl_cv_header_working_fcntl_h in #(
7834 *O_NOFOLLOW* | no | cross-compiling) ac_val=0;; #(
7838 cat >>confdefs.h <<_ACEOF
7839 #define HAVE_WORKING_O_NOFOLLOW $ac_val
7854 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdint.h" >&5
7855 $as_echo_n "checking for stdint.h... " >&6; }
7856 if test "${gl_cv_header_stdint_h+set}" = set; then :
7857 $as_echo_n "(cached) " >&6
7859 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7860 /* end confdefs.h. */
7861 #include <sys/types.h>
7866 uintmax_t i = (uintmax_t) -1; return !i;
7871 if ac_fn_c_try_compile "$LINENO"; then :
7872 gl_cv_header_stdint_h=yes
7874 gl_cv_header_stdint_h=no
7876 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_stdint_h" >&5
7879 $as_echo "$gl_cv_header_stdint_h" >&6; }
7880 if test $gl_cv_header_stdint_h = yes; then
7882 cat >>confdefs.h <<_ACEOF
7883 #define HAVE_STDINT_H_WITH_UINTMAX 1
7889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inttypes.h" >&5
7890 $as_echo_n "checking for inttypes.h... " >&6; }
7891 if test "${gl_cv_header_inttypes_h+set}" = set; then :
7892 $as_echo_n "(cached) " >&6
7894 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7895 /* end confdefs.h. */
7896 #include <sys/types.h>
7897 #include <inttypes.h>
7901 uintmax_t i = (uintmax_t) -1; return !i;
7906 if ac_fn_c_try_compile "$LINENO"; then :
7907 gl_cv_header_inttypes_h=yes
7909 gl_cv_header_inttypes_h=no
7911 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_inttypes_h" >&5
7914 $as_echo "$gl_cv_header_inttypes_h" >&6; }
7915 if test $gl_cv_header_inttypes_h = yes; then
7917 cat >>confdefs.h <<_ACEOF
7918 #define HAVE_INTTYPES_H_WITH_UINTMAX 1
7927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether printf supports size specifiers as in C99" >&5
7928 $as_echo_n "checking whether printf supports size specifiers as in C99... " >&6; }
7929 if test "${gl_cv_func_printf_sizes_c99+set}" = set; then :
7930 $as_echo_n "(cached) " >&6
7933 if test "$cross_compiling" = yes; then :
7936 # Guess yes on glibc systems.
7937 *-gnu*) gl_cv_func_printf_sizes_c99="guessing yes";;
7938 # Guess yes on FreeBSD >= 5.
7939 freebsd[1-4]*) gl_cv_func_printf_sizes_c99="guessing no";;
7940 freebsd* | kfreebsd*) gl_cv_func_printf_sizes_c99="guessing yes";;
7941 # Guess yes on MacOS X >= 10.3.
7942 darwin[1-6].*) gl_cv_func_printf_sizes_c99="guessing no";;
7943 darwin*) gl_cv_func_printf_sizes_c99="guessing yes";;
7944 # Guess yes on OpenBSD >= 3.9.
7945 openbsd[1-2].* | openbsd3.[0-8] | openbsd3.[0-8].*)
7946 gl_cv_func_printf_sizes_c99="guessing no";;
7947 openbsd*) gl_cv_func_printf_sizes_c99="guessing yes";;
7948 # Guess yes on Solaris >= 2.10.
7949 solaris2.[0-9]*) gl_cv_func_printf_sizes_c99="guessing no";;
7950 solaris*) gl_cv_func_printf_sizes_c99="guessing yes";;
7951 # Guess yes on NetBSD >= 3.
7952 netbsd[1-2]* | netbsdelf[1-2]* | netbsdaout[1-2]* | netbsdcoff[1-2]*)
7953 gl_cv_func_printf_sizes_c99="guessing no";;
7954 netbsd*) gl_cv_func_printf_sizes_c99="guessing yes";;
7955 # If we don't know, assume the worst.
7956 *) gl_cv_func_printf_sizes_c99="guessing no";;
7960 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7961 /* end confdefs.h. */
7966 #include <sys/types.h>
7967 #if HAVE_STDINT_H_WITH_UINTMAX
7968 # include <stdint.h>
7970 #if HAVE_INTTYPES_H_WITH_UINTMAX
7971 # include <inttypes.h>
7973 static char buf[100];
7976 #if HAVE_STDINT_H_WITH_UINTMAX || HAVE_INTTYPES_H_WITH_UINTMAX
7978 if (sprintf (buf, "%ju %d", (uintmax_t) 12345671, 33, 44, 55) < 0
7979 || strcmp (buf, "12345671 33") != 0)
7983 if (sprintf (buf, "%zu %d", (size_t) 12345672, 33, 44, 55) < 0
7984 || strcmp (buf, "12345672 33") != 0)
7987 if (sprintf (buf, "%tu %d", (ptrdiff_t) 12345673, 33, 44, 55) < 0
7988 || strcmp (buf, "12345673 33") != 0)
7991 if (sprintf (buf, "%Lg %d", (long double) 1.5, 33, 44, 55) < 0
7992 || strcmp (buf, "1.5 33") != 0)
7997 if ac_fn_c_try_run "$LINENO"; then :
7998 gl_cv_func_printf_sizes_c99=yes
8000 gl_cv_func_printf_sizes_c99=no
8002 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8003 conftest.$ac_objext conftest.beam conftest.$ac_ext
8008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_sizes_c99" >&5
8009 $as_echo "$gl_cv_func_printf_sizes_c99" >&6; }
8013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether printf supports 'long double' arguments" >&5
8014 $as_echo_n "checking whether printf supports 'long double' arguments... " >&6; }
8015 if test "${gl_cv_func_printf_long_double+set}" = set; then :
8016 $as_echo_n "(cached) " >&6
8019 if test "$cross_compiling" = yes; then :
8022 beos*) gl_cv_func_printf_long_double="guessing no";;
8023 mingw* | pw*) gl_cv_func_printf_long_double="guessing no";;
8024 *) gl_cv_func_printf_long_double="guessing yes";;
8028 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8029 /* end confdefs.h. */
8033 static char buf[10000];
8037 if (sprintf (buf, "%Lf %d", 1.75L, 33, 44, 55) < 0
8038 || strcmp (buf, "1.750000 33") != 0)
8041 if (sprintf (buf, "%Le %d", 1.75L, 33, 44, 55) < 0
8042 || strcmp (buf, "1.750000e+00 33") != 0)
8045 if (sprintf (buf, "%Lg %d", 1.75L, 33, 44, 55) < 0
8046 || strcmp (buf, "1.75 33") != 0)
8051 if ac_fn_c_try_run "$LINENO"; then :
8052 gl_cv_func_printf_long_double=yes
8054 gl_cv_func_printf_long_double=no
8056 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8057 conftest.$ac_objext conftest.beam conftest.$ac_ext
8062 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_long_double" >&5
8063 $as_echo "$gl_cv_func_printf_long_double" >&6; }
8067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether printf supports infinite 'double' arguments" >&5
8068 $as_echo_n "checking whether printf supports infinite 'double' arguments... " >&6; }
8069 if test "${gl_cv_func_printf_infinite+set}" = set; then :
8070 $as_echo_n "(cached) " >&6
8073 if test "$cross_compiling" = yes; then :
8076 # Guess yes on glibc systems.
8077 *-gnu*) gl_cv_func_printf_infinite="guessing yes";;
8078 # Guess yes on FreeBSD >= 6.
8079 freebsd[1-5]*) gl_cv_func_printf_infinite="guessing no";;
8080 freebsd* | kfreebsd*) gl_cv_func_printf_infinite="guessing yes";;
8081 # Guess yes on MacOS X >= 10.3.
8082 darwin[1-6].*) gl_cv_func_printf_infinite="guessing no";;
8083 darwin*) gl_cv_func_printf_infinite="guessing yes";;
8084 # Guess yes on HP-UX >= 11.
8085 hpux[7-9]* | hpux10*) gl_cv_func_printf_infinite="guessing no";;
8086 hpux*) gl_cv_func_printf_infinite="guessing yes";;
8087 # Guess yes on NetBSD >= 3.
8088 netbsd[1-2]* | netbsdelf[1-2]* | netbsdaout[1-2]* | netbsdcoff[1-2]*)
8089 gl_cv_func_printf_infinite="guessing no";;
8090 netbsd*) gl_cv_func_printf_infinite="guessing yes";;
8091 # Guess yes on BeOS.
8092 beos*) gl_cv_func_printf_infinite="guessing yes";;
8093 # If we don't know, assume the worst.
8094 *) gl_cv_func_printf_infinite="guessing no";;
8098 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8099 /* end confdefs.h. */
8104 strisnan (const char *string, size_t start_index, size_t end_index)
8106 if (start_index < end_index)
8108 if (string[start_index] == '-')
8110 if (start_index + 3 <= end_index
8111 && memcmp (string + start_index, "nan", 3) == 0)
8114 if (start_index == end_index
8115 || (string[start_index] == '(' && string[end_index - 1] == ')'))
8124 static double plus_zero = 0.0;
8125 double minus_zero = - plus_zero;
8126 return memcmp (&plus_zero, &minus_zero, sizeof (double)) != 0;
8128 static char buf[10000];
8129 static double zero = 0.0;
8132 if (sprintf (buf, "%f", 1.0 / 0.0) < 0
8133 || (strcmp (buf, "inf") != 0 && strcmp (buf, "infinity") != 0))
8135 if (sprintf (buf, "%f", -1.0 / 0.0) < 0
8136 || (strcmp (buf, "-inf") != 0 && strcmp (buf, "-infinity") != 0))
8138 if (sprintf (buf, "%f", zero / zero) < 0
8139 || !strisnan (buf, 0, strlen (buf)))
8141 if (sprintf (buf, "%e", 1.0 / 0.0) < 0
8142 || (strcmp (buf, "inf") != 0 && strcmp (buf, "infinity") != 0))
8144 if (sprintf (buf, "%e", -1.0 / 0.0) < 0
8145 || (strcmp (buf, "-inf") != 0 && strcmp (buf, "-infinity") != 0))
8147 if (sprintf (buf, "%e", zero / zero) < 0
8148 || !strisnan (buf, 0, strlen (buf)))
8150 if (sprintf (buf, "%g", 1.0 / 0.0) < 0
8151 || (strcmp (buf, "inf") != 0 && strcmp (buf, "infinity") != 0))
8153 if (sprintf (buf, "%g", -1.0 / 0.0) < 0
8154 || (strcmp (buf, "-inf") != 0 && strcmp (buf, "-infinity") != 0))
8156 if (sprintf (buf, "%g", zero / zero) < 0
8157 || !strisnan (buf, 0, strlen (buf)))
8159 /* This test fails on HP-UX 10.20. */
8160 if (have_minus_zero ())
8161 if (sprintf (buf, "%g", - zero) < 0
8162 || strcmp (buf, "-0") != 0)
8167 if ac_fn_c_try_run "$LINENO"; then :
8168 gl_cv_func_printf_infinite=yes
8170 gl_cv_func_printf_infinite=no
8172 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8173 conftest.$ac_objext conftest.beam conftest.$ac_ext
8178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_infinite" >&5
8179 $as_echo "$gl_cv_func_printf_infinite" >&6; }
8182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
8183 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
8184 if test "${ac_cv_c_bigendian+set}" = set; then :
8185 $as_echo_n "(cached) " >&6
8187 ac_cv_c_bigendian=unknown
8188 # See if we're dealing with a universal compiler.
8189 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8190 /* end confdefs.h. */
8191 #ifndef __APPLE_CC__
8192 not a universal capable compiler
8197 if ac_fn_c_try_compile "$LINENO"; then :
8199 # Check for potential -arch flags. It is not universal unless
8200 # there are at least two -arch flags with different values.
8203 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
8204 if test -n "$ac_prev"; then
8206 i?86 | x86_64 | ppc | ppc64)
8207 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
8210 ac_cv_c_bigendian=universal
8216 elif test "x$ac_word" = "x-arch"; then
8221 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8222 if test $ac_cv_c_bigendian = unknown; then
8223 # See if sys/param.h defines the BYTE_ORDER macro.
8224 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8225 /* end confdefs.h. */
8226 #include <sys/types.h>
8227 #include <sys/param.h>
8232 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
8233 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
8242 if ac_fn_c_try_compile "$LINENO"; then :
8243 # It does; now see whether it defined to BIG_ENDIAN or not.
8244 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8245 /* end confdefs.h. */
8246 #include <sys/types.h>
8247 #include <sys/param.h>
8252 #if BYTE_ORDER != BIG_ENDIAN
8260 if ac_fn_c_try_compile "$LINENO"; then :
8261 ac_cv_c_bigendian=yes
8263 ac_cv_c_bigendian=no
8265 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8267 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8269 if test $ac_cv_c_bigendian = unknown; then
8270 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
8271 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8272 /* end confdefs.h. */
8278 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
8286 if ac_fn_c_try_compile "$LINENO"; then :
8287 # It does; now see whether it defined to _BIG_ENDIAN or not.
8288 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8289 /* end confdefs.h. */
8303 if ac_fn_c_try_compile "$LINENO"; then :
8304 ac_cv_c_bigendian=yes
8306 ac_cv_c_bigendian=no
8308 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8310 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8312 if test $ac_cv_c_bigendian = unknown; then
8313 # Compile a test program.
8314 if test "$cross_compiling" = yes; then :
8315 # Try to guess by grepping values from an object file.
8316 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8317 /* end confdefs.h. */
8318 short int ascii_mm[] =
8319 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
8320 short int ascii_ii[] =
8321 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
8322 int use_ascii (int i) {
8323 return ascii_mm[i] + ascii_ii[i];
8325 short int ebcdic_ii[] =
8326 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
8327 short int ebcdic_mm[] =
8328 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
8329 int use_ebcdic (int i) {
8330 return ebcdic_mm[i] + ebcdic_ii[i];
8337 return use_ascii (foo) == use_ebcdic (foo);
8342 if ac_fn_c_try_compile "$LINENO"; then :
8343 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
8344 ac_cv_c_bigendian=yes
8346 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
8347 if test "$ac_cv_c_bigendian" = unknown; then
8348 ac_cv_c_bigendian=no
8350 # finding both strings is unlikely to happen, but who knows?
8351 ac_cv_c_bigendian=unknown
8355 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8357 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8358 /* end confdefs.h. */
8359 $ac_includes_default
8364 /* Are we little or big endian? From Harbison&Steele. */
8368 char c[sizeof (long int)];
8371 return u.c[sizeof (long int) - 1] == 1;
8377 if ac_fn_c_try_run "$LINENO"; then :
8378 ac_cv_c_bigendian=no
8380 ac_cv_c_bigendian=yes
8382 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8383 conftest.$ac_objext conftest.beam conftest.$ac_ext
8388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
8389 $as_echo "$ac_cv_c_bigendian" >&6; }
8390 case $ac_cv_c_bigendian in #(
8392 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
8398 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
8402 as_fn_error "unknown endianness
8403 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
8411 if test -n "$gl_printf_safe"; then
8413 $as_echo "#define CHECK_PRINTF_SAFE 1" >>confdefs.h
8416 case "$gl_cv_func_printf_long_double" in
8418 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether printf supports infinite 'long double' arguments" >&5
8419 $as_echo_n "checking whether printf supports infinite 'long double' arguments... " >&6; }
8420 if test "${gl_cv_func_printf_infinite_long_double+set}" = set; then :
8421 $as_echo_n "(cached) " >&6
8424 if test "$cross_compiling" = yes; then :
8427 # Guess no on ia64, x86_64, i386.
8428 ia64 | x86_64 | i*86) gl_cv_func_printf_infinite_long_double="guessing no";;
8431 # Guess yes on glibc systems.
8432 *-gnu*) gl_cv_func_printf_infinite_long_double="guessing yes";;
8433 # Guess yes on FreeBSD >= 6.
8434 freebsd[1-5]*) gl_cv_func_printf_infinite_long_double="guessing no";;
8435 freebsd* | kfreebsd*) gl_cv_func_printf_infinite_long_double="guessing yes";;
8436 # Guess yes on MacOS X >= 10.3.
8437 darwin[1-6].*) gl_cv_func_printf_infinite_long_double="guessing no";;
8438 darwin*) gl_cv_func_printf_infinite_long_double="guessing yes";;
8439 # Guess yes on HP-UX >= 11.
8440 hpux[7-9]* | hpux10*) gl_cv_func_printf_infinite_long_double="guessing no";;
8441 hpux*) gl_cv_func_printf_infinite_long_double="guessing yes";;
8442 # Guess yes on NetBSD >= 3.
8443 netbsd[1-2]* | netbsdelf[1-2]* | netbsdaout[1-2]* | netbsdcoff[1-2]*)
8444 gl_cv_func_printf_infinite_long_double="guessing no";;
8445 netbsd*) gl_cv_func_printf_infinite_long_double="guessing yes";;
8446 # If we don't know, assume the worst.
8447 *) gl_cv_func_printf_infinite_long_double="guessing no";;
8453 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8454 /* end confdefs.h. */
8458 #if defined __MACH__ && defined __APPLE__
8459 /* Avoid a crash on MacOS X. */
8460 #include <mach/mach.h>
8461 #include <mach/mach_error.h>
8462 #include <mach/thread_status.h>
8463 #include <mach/exception.h>
8464 #include <mach/task.h>
8465 #include <pthread.h>
8466 /* The exception port on which our thread listens. */
8467 static mach_port_t our_exception_port;
8468 /* The main function of the thread listening for exceptions of type
8471 mach_exception_thread (void *arg)
8473 /* Buffer for a message to be received. */
8475 mach_msg_header_t head;
8476 mach_msg_body_t msgh_body;
8479 mach_msg_return_t retval;
8480 /* Wait for a message on the exception port. */
8481 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
8482 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
8483 if (retval != MACH_MSG_SUCCESS)
8490 mach_port_t self = mach_task_self ();
8491 /* Allocate a port on which the thread shall listen for exceptions. */
8492 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
8494 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
8495 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
8496 MACH_MSG_TYPE_MAKE_SEND)
8498 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
8500 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
8501 /* Create the thread listening on the exception port. */
8502 pthread_attr_t attr;
8504 if (pthread_attr_init (&attr) == 0
8505 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
8506 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
8507 pthread_attr_destroy (&attr);
8508 /* Replace the exception port info for these exceptions with our own.
8509 Note that we replace the exception port for the entire task, not only
8510 for a particular thread. This has the effect that when our exception
8511 port gets the message, the thread specific exception port has already
8512 been asked, and we don't need to bother about it.
8513 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
8514 task_set_exception_ports (self, mask, our_exception_port,
8515 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
8521 /* Avoid a crash on POSIX systems. */
8523 /* A POSIX signal handler. */
8525 exception_handler (int sig)
8533 signal (SIGSEGV, exception_handler);
8536 signal (SIGBUS, exception_handler);
8545 strisnan (const char *string, size_t start_index, size_t end_index)
8547 if (start_index < end_index)
8549 if (string[start_index] == '-')
8551 if (start_index + 3 <= end_index
8552 && memcmp (string + start_index, "nan", 3) == 0)
8555 if (start_index == end_index
8556 || (string[start_index] == '(' && string[end_index - 1] == ')'))
8562 static char buf[10000];
8563 static long double zeroL = 0.0L;
8567 if (sprintf (buf, "%Lf", 1.0L / 0.0L) < 0
8568 || (strcmp (buf, "inf") != 0 && strcmp (buf, "infinity") != 0))
8570 if (sprintf (buf, "%Lf", -1.0L / 0.0L) < 0
8571 || (strcmp (buf, "-inf") != 0 && strcmp (buf, "-infinity") != 0))
8573 if (sprintf (buf, "%Lf", zeroL / zeroL) < 0
8574 || !strisnan (buf, 0, strlen (buf)))
8576 if (sprintf (buf, "%Le", 1.0L / 0.0L) < 0
8577 || (strcmp (buf, "inf") != 0 && strcmp (buf, "infinity") != 0))
8579 if (sprintf (buf, "%Le", -1.0L / 0.0L) < 0
8580 || (strcmp (buf, "-inf") != 0 && strcmp (buf, "-infinity") != 0))
8582 if (sprintf (buf, "%Le", zeroL / zeroL) < 0
8583 || !strisnan (buf, 0, strlen (buf)))
8585 if (sprintf (buf, "%Lg", 1.0L / 0.0L) < 0
8586 || (strcmp (buf, "inf") != 0 && strcmp (buf, "infinity") != 0))
8588 if (sprintf (buf, "%Lg", -1.0L / 0.0L) < 0
8589 || (strcmp (buf, "-inf") != 0 && strcmp (buf, "-infinity") != 0))
8591 if (sprintf (buf, "%Lg", zeroL / zeroL) < 0
8592 || !strisnan (buf, 0, strlen (buf)))
8594 #if CHECK_PRINTF_SAFE && ((defined __ia64 && LDBL_MANT_DIG == 64) || (defined __x86_64__ || defined __amd64__) || (defined __i386 || defined __i386__ || defined _I386 || defined _M_IX86 || defined _X86_))
8595 /* Representation of an 80-bit 'long double' as an initializer for a sequence
8596 of 'unsigned int' words. */
8597 # ifdef WORDS_BIGENDIAN
8598 # define LDBL80_WORDS(exponent,manthi,mantlo) \
8599 { ((unsigned int) (exponent) << 16) | ((unsigned int) (manthi) >> 16), \
8600 ((unsigned int) (manthi) << 16) | (unsigned int) (mantlo) >> 16), \
8601 (unsigned int) (mantlo) << 16 \
8604 # define LDBL80_WORDS(exponent,manthi,mantlo) \
8605 { mantlo, manthi, exponent }
8608 static union { unsigned int word[4]; long double value; } x =
8609 { LDBL80_WORDS (0xFFFF, 0xC3333333, 0x00000000) };
8610 if (sprintf (buf, "%Lf", x.value) < 0
8611 || !strisnan (buf, 0, strlen (buf)))
8613 if (sprintf (buf, "%Le", x.value) < 0
8614 || !strisnan (buf, 0, strlen (buf)))
8616 if (sprintf (buf, "%Lg", x.value) < 0
8617 || !strisnan (buf, 0, strlen (buf)))
8621 /* Signalling NaN. */
8622 static union { unsigned int word[4]; long double value; } x =
8623 { LDBL80_WORDS (0xFFFF, 0x83333333, 0x00000000) };
8624 if (sprintf (buf, "%Lf", x.value) < 0
8625 || !strisnan (buf, 0, strlen (buf)))
8627 if (sprintf (buf, "%Le", x.value) < 0
8628 || !strisnan (buf, 0, strlen (buf)))
8630 if (sprintf (buf, "%Lg", x.value) < 0
8631 || !strisnan (buf, 0, strlen (buf)))
8635 static union { unsigned int word[4]; long double value; } x =
8636 { LDBL80_WORDS (0xFFFF, 0x40000001, 0x00000000) };
8637 if (sprintf (buf, "%Lf", x.value) < 0
8638 || !strisnan (buf, 0, strlen (buf)))
8640 if (sprintf (buf, "%Le", x.value) < 0
8641 || !strisnan (buf, 0, strlen (buf)))
8643 if (sprintf (buf, "%Lg", x.value) < 0
8644 || !strisnan (buf, 0, strlen (buf)))
8647 { /* Pseudo-Infinity. */
8648 static union { unsigned int word[4]; long double value; } x =
8649 { LDBL80_WORDS (0xFFFF, 0x00000000, 0x00000000) };
8650 if (sprintf (buf, "%Lf", x.value) < 0
8651 || !strisnan (buf, 0, strlen (buf)))
8653 if (sprintf (buf, "%Le", x.value) < 0
8654 || !strisnan (buf, 0, strlen (buf)))
8656 if (sprintf (buf, "%Lg", x.value) < 0
8657 || !strisnan (buf, 0, strlen (buf)))
8660 { /* Pseudo-Zero. */
8661 static union { unsigned int word[4]; long double value; } x =
8662 { LDBL80_WORDS (0x4004, 0x00000000, 0x00000000) };
8663 if (sprintf (buf, "%Lf", x.value) < 0
8664 || !strisnan (buf, 0, strlen (buf)))
8666 if (sprintf (buf, "%Le", x.value) < 0
8667 || !strisnan (buf, 0, strlen (buf)))
8669 if (sprintf (buf, "%Lg", x.value) < 0
8670 || !strisnan (buf, 0, strlen (buf)))
8673 { /* Unnormalized number. */
8674 static union { unsigned int word[4]; long double value; } x =
8675 { LDBL80_WORDS (0x4000, 0x63333333, 0x00000000) };
8676 if (sprintf (buf, "%Lf", x.value) < 0
8677 || !strisnan (buf, 0, strlen (buf)))
8679 if (sprintf (buf, "%Le", x.value) < 0
8680 || !strisnan (buf, 0, strlen (buf)))
8682 if (sprintf (buf, "%Lg", x.value) < 0
8683 || !strisnan (buf, 0, strlen (buf)))
8686 { /* Pseudo-Denormal. */
8687 static union { unsigned int word[4]; long double value; } x =
8688 { LDBL80_WORDS (0x0000, 0x83333333, 0x00000000) };
8689 if (sprintf (buf, "%Lf", x.value) < 0
8690 || !strisnan (buf, 0, strlen (buf)))
8692 if (sprintf (buf, "%Le", x.value) < 0
8693 || !strisnan (buf, 0, strlen (buf)))
8695 if (sprintf (buf, "%Lg", x.value) < 0
8696 || !strisnan (buf, 0, strlen (buf)))
8703 if ac_fn_c_try_run "$LINENO"; then :
8704 gl_cv_func_printf_infinite_long_double=yes
8706 gl_cv_func_printf_infinite_long_double=no
8708 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8709 conftest.$ac_objext conftest.beam conftest.$ac_ext
8714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_infinite_long_double" >&5
8715 $as_echo "$gl_cv_func_printf_infinite_long_double" >&6; }
8718 gl_cv_func_printf_infinite_long_double="irrelevant"
8724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether printf supports the 'a' and 'A' directives" >&5
8725 $as_echo_n "checking whether printf supports the 'a' and 'A' directives... " >&6; }
8726 if test "${gl_cv_func_printf_directive_a+set}" = set; then :
8727 $as_echo_n "(cached) " >&6
8730 if test "$cross_compiling" = yes; then :
8733 # Guess yes on glibc >= 2.5 systems.
8735 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8736 /* end confdefs.h. */
8738 #include <features.h>
8739 #ifdef __GNU_LIBRARY__
8740 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 5) || (__GLIBC__ > 2)
8746 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8747 $EGREP "BZ2908" >/dev/null 2>&1; then :
8748 gl_cv_func_printf_directive_a="guessing yes"
8750 gl_cv_func_printf_directive_a="guessing no"
8755 # If we don't know, assume the worst.
8756 *) gl_cv_func_printf_directive_a="guessing no";;
8760 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8761 /* end confdefs.h. */
8765 static char buf[100];
8768 if (sprintf (buf, "%a %d", 3.1416015625, 33, 44, 55) < 0
8769 || (strcmp (buf, "0x1.922p+1 33") != 0
8770 && strcmp (buf, "0x3.244p+0 33") != 0
8771 && strcmp (buf, "0x6.488p-1 33") != 0
8772 && strcmp (buf, "0xc.91p-2 33") != 0))
8774 if (sprintf (buf, "%A %d", -3.1416015625, 33, 44, 55) < 0
8775 || (strcmp (buf, "-0X1.922P+1 33") != 0
8776 && strcmp (buf, "-0X3.244P+0 33") != 0
8777 && strcmp (buf, "-0X6.488P-1 33") != 0
8778 && strcmp (buf, "-0XC.91P-2 33") != 0))
8780 /* This catches a FreeBSD 6.1 bug: it doesn't round. */
8781 if (sprintf (buf, "%.2a %d", 1.51, 33, 44, 55) < 0
8782 || (strcmp (buf, "0x1.83p+0 33") != 0
8783 && strcmp (buf, "0x3.05p-1 33") != 0
8784 && strcmp (buf, "0x6.0ap-2 33") != 0
8785 && strcmp (buf, "0xc.14p-3 33") != 0))
8787 /* This catches a FreeBSD 6.1 bug. See
8788 <http://lists.gnu.org/archive/html/bug-gnulib/2007-04/msg00107.html> */
8789 if (sprintf (buf, "%010a %d", 1.0 / 0.0, 33, 44, 55) < 0
8792 /* This catches a MacOS X 10.3.9 (Darwin 7.9) bug. */
8793 if (sprintf (buf, "%.1a", 1.999) < 0
8794 || (strcmp (buf, "0x1.0p+1") != 0
8795 && strcmp (buf, "0x2.0p+0") != 0
8796 && strcmp (buf, "0x4.0p-1") != 0
8797 && strcmp (buf, "0x8.0p-2") != 0))
8799 /* This catches the same MacOS X 10.3.9 (Darwin 7.9) bug and also a
8800 glibc 2.4 bug <http://sourceware.org/bugzilla/show_bug.cgi?id=2908>. */
8801 if (sprintf (buf, "%.1La", 1.999L) < 0
8802 || (strcmp (buf, "0x1.0p+1") != 0
8803 && strcmp (buf, "0x2.0p+0") != 0
8804 && strcmp (buf, "0x4.0p-1") != 0
8805 && strcmp (buf, "0x8.0p-2") != 0))
8810 if ac_fn_c_try_run "$LINENO"; then :
8811 gl_cv_func_printf_directive_a=yes
8813 gl_cv_func_printf_directive_a=no
8815 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8816 conftest.$ac_objext conftest.beam conftest.$ac_ext
8821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_directive_a" >&5
8822 $as_echo "$gl_cv_func_printf_directive_a" >&6; }
8826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether printf supports the 'F' directive" >&5
8827 $as_echo_n "checking whether printf supports the 'F' directive... " >&6; }
8828 if test "${gl_cv_func_printf_directive_f+set}" = set; then :
8829 $as_echo_n "(cached) " >&6
8832 if test "$cross_compiling" = yes; then :
8835 # Guess yes on glibc systems.
8836 *-gnu*) gl_cv_func_printf_directive_f="guessing yes";;
8837 # Guess yes on FreeBSD >= 6.
8838 freebsd[1-5]*) gl_cv_func_printf_directive_f="guessing no";;
8839 freebsd* | kfreebsd*) gl_cv_func_printf_directive_f="guessing yes";;
8840 # Guess yes on MacOS X >= 10.3.
8841 darwin[1-6].*) gl_cv_func_printf_directive_f="guessing no";;
8842 darwin*) gl_cv_func_printf_directive_f="guessing yes";;
8843 # Guess yes on Solaris >= 2.10.
8844 solaris2.[0-9]*) gl_cv_func_printf_directive_f="guessing no";;
8845 solaris*) gl_cv_func_printf_directive_f="guessing yes";;
8846 # If we don't know, assume the worst.
8847 *) gl_cv_func_printf_directive_f="guessing no";;
8851 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8852 /* end confdefs.h. */
8856 static char buf[100];
8859 if (sprintf (buf, "%F %d", 1234567.0, 33, 44, 55) < 0
8860 || strcmp (buf, "1234567.000000 33") != 0)
8862 if (sprintf (buf, "%F", 1.0 / 0.0) < 0
8863 || (strcmp (buf, "INF") != 0 && strcmp (buf, "INFINITY") != 0))
8865 /* This catches a Cygwin 1.5.x bug. */
8866 if (sprintf (buf, "%.F", 1234.0) < 0
8867 || strcmp (buf, "1234") != 0)
8872 if ac_fn_c_try_run "$LINENO"; then :
8873 gl_cv_func_printf_directive_f=yes
8875 gl_cv_func_printf_directive_f=no
8877 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8878 conftest.$ac_objext conftest.beam conftest.$ac_ext
8883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_directive_f" >&5
8884 $as_echo "$gl_cv_func_printf_directive_f" >&6; }
8888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether printf supports the 'n' directive" >&5
8889 $as_echo_n "checking whether printf supports the 'n' directive... " >&6; }
8890 if test "${gl_cv_func_printf_directive_n+set}" = set; then :
8891 $as_echo_n "(cached) " >&6
8894 if test "$cross_compiling" = yes; then :
8897 *) gl_cv_func_printf_directive_n="guessing yes";;
8901 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8902 /* end confdefs.h. */
8906 static char fmtstring[10];
8907 static char buf[100];
8911 /* Copy the format string. Some systems (glibc with _FORTIFY_SOURCE=2)
8912 support %n in format strings in read-only memory but not in writable
8914 strcpy (fmtstring, "%d %n");
8915 if (sprintf (buf, fmtstring, 123, &count, 33, 44, 55) < 0
8916 || strcmp (buf, "123 ") != 0
8922 if ac_fn_c_try_run "$LINENO"; then :
8923 gl_cv_func_printf_directive_n=yes
8925 gl_cv_func_printf_directive_n=no
8927 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8928 conftest.$ac_objext conftest.beam conftest.$ac_ext
8933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_directive_n" >&5
8934 $as_echo "$gl_cv_func_printf_directive_n" >&6; }
8938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether printf supports the 'ls' directive" >&5
8939 $as_echo_n "checking whether printf supports the 'ls' directive... " >&6; }
8940 if test "${gl_cv_func_printf_directive_ls+set}" = set; then :
8941 $as_echo_n "(cached) " >&6
8944 if test "$cross_compiling" = yes; then :
8947 openbsd*) gl_cv_func_printf_directive_ls="guessing no";;
8948 irix*) gl_cv_func_printf_directive_ls="guessing no";;
8949 solaris*) gl_cv_func_printf_directive_ls="guessing no";;
8950 cygwin*) gl_cv_func_printf_directive_ls="guessing no";;
8951 beos* | haiku*) gl_cv_func_printf_directive_ls="guessing no";;
8952 *) gl_cv_func_printf_directive_ls="guessing yes";;
8956 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8957 /* end confdefs.h. */
8959 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
8961 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
8962 included before <wchar.h>. */
8971 /* Test whether %ls works at all.
8972 This test fails on OpenBSD 4.0, IRIX 6.5, Solaris 2.6, Haiku, but not on
8975 static const wchar_t wstring[] = { 'a', 'b', 'c', 0 };
8977 if (sprintf (buf, "%ls", wstring) < 0
8978 || strcmp (buf, "abc") != 0)
8981 /* This test fails on IRIX 6.5, Solaris 2.6, Cygwin 1.5, Haiku (with an
8982 assertion failure inside libc), but not on OpenBSD 4.0. */
8984 static const wchar_t wstring[] = { 'a', 0 };
8986 if (sprintf (buf, "%ls", wstring) < 0
8987 || strcmp (buf, "a") != 0)
8990 /* Test whether precisions in %ls are supported as specified in ISO C 99
8992 "If a precision is specified, no more than that many bytes are written
8993 (including shift sequences, if any), and the array shall contain a
8994 null wide character if, to equal the multibyte character sequence
8995 length given by the precision, the function would need to access a
8996 wide character one past the end of the array."
8997 This test fails on Solaris 10. */
8999 static const wchar_t wstring[] = { 'a', 'b', (wchar_t) 0xfdfdfdfd, 0 };
9001 if (sprintf (buf, "%.2ls", wstring) < 0
9002 || strcmp (buf, "ab") != 0)
9008 if ac_fn_c_try_run "$LINENO"; then :
9009 gl_cv_func_printf_directive_ls=yes
9011 gl_cv_func_printf_directive_ls=no
9013 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9014 conftest.$ac_objext conftest.beam conftest.$ac_ext
9019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_directive_ls" >&5
9020 $as_echo "$gl_cv_func_printf_directive_ls" >&6; }
9024 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether printf supports POSIX/XSI format strings with positions" >&5
9025 $as_echo_n "checking whether printf supports POSIX/XSI format strings with positions... " >&6; }
9026 if test "${gl_cv_func_printf_positions+set}" = set; then :
9027 $as_echo_n "(cached) " >&6
9030 if test "$cross_compiling" = yes; then :
9033 netbsd[1-3]* | netbsdelf[1-3]* | netbsdaout[1-3]* | netbsdcoff[1-3]*)
9034 gl_cv_func_printf_positions="guessing no";;
9035 beos*) gl_cv_func_printf_positions="guessing no";;
9036 mingw* | pw*) gl_cv_func_printf_positions="guessing no";;
9037 *) gl_cv_func_printf_positions="guessing yes";;
9041 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9042 /* end confdefs.h. */
9046 /* The string "%2$d %1$d", with dollar characters protected from the shell's
9047 dollar expansion (possibly an autoconf bug). */
9048 static char format[] = { '%', '2', '$', 'd', ' ', '%', '1', '$', 'd', '\0' };
9049 static char buf[100];
9052 sprintf (buf, format, 33, 55);
9053 return (strcmp (buf, "55 33") != 0);
9056 if ac_fn_c_try_run "$LINENO"; then :
9057 gl_cv_func_printf_positions=yes
9059 gl_cv_func_printf_positions=no
9061 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9062 conftest.$ac_objext conftest.beam conftest.$ac_ext
9067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_positions" >&5
9068 $as_echo "$gl_cv_func_printf_positions" >&6; }
9072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether printf supports the grouping flag" >&5
9073 $as_echo_n "checking whether printf supports the grouping flag... " >&6; }
9074 if test "${gl_cv_func_printf_flag_grouping+set}" = set; then :
9075 $as_echo_n "(cached) " >&6
9078 if test "$cross_compiling" = yes; then :
9081 cygwin*) gl_cv_func_printf_flag_grouping="guessing no";;
9082 netbsd*) gl_cv_func_printf_flag_grouping="guessing no";;
9083 mingw* | pw*) gl_cv_func_printf_flag_grouping="guessing no";;
9084 *) gl_cv_func_printf_flag_grouping="guessing yes";;
9088 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9089 /* end confdefs.h. */
9093 static char buf[100];
9096 if (sprintf (buf, "%'d %d", 1234567, 99) < 0
9097 || buf[strlen (buf) - 1] != '9')
9102 if ac_fn_c_try_run "$LINENO"; then :
9103 gl_cv_func_printf_flag_grouping=yes
9105 gl_cv_func_printf_flag_grouping=no
9107 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9108 conftest.$ac_objext conftest.beam conftest.$ac_ext
9113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_flag_grouping" >&5
9114 $as_echo "$gl_cv_func_printf_flag_grouping" >&6; }
9118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether printf supports the left-adjust flag correctly" >&5
9119 $as_echo_n "checking whether printf supports the left-adjust flag correctly... " >&6; }
9120 if test "${gl_cv_func_printf_flag_leftadjust+set}" = set; then :
9121 $as_echo_n "(cached) " >&6
9124 if test "$cross_compiling" = yes; then :
9127 # Guess yes on HP-UX 11.
9128 hpux11*) gl_cv_func_printf_flag_leftadjust="guessing yes";;
9129 # Guess no on HP-UX 10 and older.
9130 hpux*) gl_cv_func_printf_flag_leftadjust="guessing no";;
9131 # Guess yes otherwise.
9132 *) gl_cv_func_printf_flag_leftadjust="guessing yes";;
9136 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9137 /* end confdefs.h. */
9141 static char buf[100];
9144 /* Check that a '-' flag is not annihilated by a negative width. */
9145 if (sprintf (buf, "a%-*sc", -3, "b") < 0
9146 || strcmp (buf, "ab c") != 0)
9151 if ac_fn_c_try_run "$LINENO"; then :
9152 gl_cv_func_printf_flag_leftadjust=yes
9154 gl_cv_func_printf_flag_leftadjust=no
9156 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9157 conftest.$ac_objext conftest.beam conftest.$ac_ext
9162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_flag_leftadjust" >&5
9163 $as_echo "$gl_cv_func_printf_flag_leftadjust" >&6; }
9167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether printf supports the zero flag correctly" >&5
9168 $as_echo_n "checking whether printf supports the zero flag correctly... " >&6; }
9169 if test "${gl_cv_func_printf_flag_zero+set}" = set; then :
9170 $as_echo_n "(cached) " >&6
9173 if test "$cross_compiling" = yes; then :
9176 # Guess yes on glibc systems.
9177 *-gnu*) gl_cv_func_printf_flag_zero="guessing yes";;
9178 # Guess yes on BeOS.
9179 beos*) gl_cv_func_printf_flag_zero="guessing yes";;
9180 # If we don't know, assume the worst.
9181 *) gl_cv_func_printf_flag_zero="guessing no";;
9185 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9186 /* end confdefs.h. */
9190 static char buf[100];
9193 if (sprintf (buf, "%010f", 1.0 / 0.0, 33, 44, 55) < 0
9194 || (strcmp (buf, " inf") != 0
9195 && strcmp (buf, " infinity") != 0))
9200 if ac_fn_c_try_run "$LINENO"; then :
9201 gl_cv_func_printf_flag_zero=yes
9203 gl_cv_func_printf_flag_zero=no
9205 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9206 conftest.$ac_objext conftest.beam conftest.$ac_ext
9211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_flag_zero" >&5
9212 $as_echo "$gl_cv_func_printf_flag_zero" >&6; }
9216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether printf supports large precisions" >&5
9217 $as_echo_n "checking whether printf supports large precisions... " >&6; }
9218 if test "${gl_cv_func_printf_precision+set}" = set; then :
9219 $as_echo_n "(cached) " >&6
9222 if test "$cross_compiling" = yes; then :
9225 # Guess no only on native Win32 and BeOS systems.
9226 mingw* | pw*) gl_cv_func_printf_precision="guessing no" ;;
9227 beos*) gl_cv_func_printf_precision="guessing no" ;;
9228 *) gl_cv_func_printf_precision="guessing yes" ;;
9232 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9233 /* end confdefs.h. */
9237 static char buf[5000];
9241 /* On BeOS, this would crash and show a dialog box. Avoid the crash. */
9244 if (sprintf (buf, "%.4000d %d", 1, 33, 44) < 4000 + 3)
9249 if ac_fn_c_try_run "$LINENO"; then :
9250 gl_cv_func_printf_precision=yes
9252 gl_cv_func_printf_precision=no
9254 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9255 conftest.$ac_objext conftest.beam conftest.$ac_ext
9260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_precision" >&5
9261 $as_echo "$gl_cv_func_printf_precision" >&6; }
9264 gl_cv_c_multiarch=no
9265 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9266 /* end confdefs.h. */
9267 #ifndef __APPLE_CC__
9268 not a universal capable compiler
9273 if ac_fn_c_try_compile "$LINENO"; then :
9277 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
9278 if test -n "$prev"; then
9280 i?86 | x86_64 | ppc | ppc64)
9281 if test -z "$arch" || test "$arch" = "$word"; then
9284 gl_cv_c_multiarch=yes
9290 if test "x$word" = "x-arch"; then
9297 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9298 if test $gl_cv_c_multiarch = yes; then
9300 $as_echo "#define AA_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
9302 APPLE_UNIVERSAL_BUILD=1
9304 APPLE_UNIVERSAL_BUILD=0
9311 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether printf survives out-of-memory conditions" >&5
9312 $as_echo_n "checking whether printf survives out-of-memory conditions... " >&6; }
9313 if test "${gl_cv_func_printf_enomem+set}" = set; then :
9314 $as_echo_n "(cached) " >&6
9317 gl_cv_func_printf_enomem="guessing no"
9318 if test "$cross_compiling" = no; then
9319 if test $APPLE_UNIVERSAL_BUILD = 0; then
9320 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9321 /* end confdefs.h. */
9325 #if defined __MACH__ && defined __APPLE__
9326 /* Avoid a crash on MacOS X. */
9327 #include <mach/mach.h>
9328 #include <mach/mach_error.h>
9329 #include <mach/thread_status.h>
9330 #include <mach/exception.h>
9331 #include <mach/task.h>
9332 #include <pthread.h>
9333 /* The exception port on which our thread listens. */
9334 static mach_port_t our_exception_port;
9335 /* The main function of the thread listening for exceptions of type
9338 mach_exception_thread (void *arg)
9340 /* Buffer for a message to be received. */
9342 mach_msg_header_t head;
9343 mach_msg_body_t msgh_body;
9346 mach_msg_return_t retval;
9347 /* Wait for a message on the exception port. */
9348 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
9349 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
9350 if (retval != MACH_MSG_SUCCESS)
9357 mach_port_t self = mach_task_self ();
9358 /* Allocate a port on which the thread shall listen for exceptions. */
9359 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
9361 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
9362 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
9363 MACH_MSG_TYPE_MAKE_SEND)
9365 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
9367 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
9368 /* Create the thread listening on the exception port. */
9369 pthread_attr_t attr;
9371 if (pthread_attr_init (&attr) == 0
9372 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
9373 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
9374 pthread_attr_destroy (&attr);
9375 /* Replace the exception port info for these exceptions with our own.
9376 Note that we replace the exception port for the entire task, not only
9377 for a particular thread. This has the effect that when our exception
9378 port gets the message, the thread specific exception port has already
9379 been asked, and we don't need to bother about it.
9380 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
9381 task_set_exception_ports (self, mask, our_exception_port,
9382 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
9388 /* Avoid a crash on POSIX systems. */
9390 /* A POSIX signal handler. */
9392 exception_handler (int sig)
9400 signal (SIGSEGV, exception_handler);
9403 signal (SIGBUS, exception_handler);
9409 #include <sys/types.h>
9410 #include <sys/time.h>
9411 #include <sys/resource.h>
9415 struct rlimit limit;
9418 /* Some printf implementations allocate temporary space with malloc. */
9419 /* On BSD systems, malloc() is limited by RLIMIT_DATA. */
9421 if (getrlimit (RLIMIT_DATA, &limit) < 0)
9423 if (limit.rlim_max == RLIM_INFINITY || limit.rlim_max > 5000000)
9424 limit.rlim_max = 5000000;
9425 limit.rlim_cur = limit.rlim_max;
9426 if (setrlimit (RLIMIT_DATA, &limit) < 0)
9429 /* On Linux systems, malloc() is limited by RLIMIT_AS. */
9431 if (getrlimit (RLIMIT_AS, &limit) < 0)
9433 if (limit.rlim_max == RLIM_INFINITY || limit.rlim_max > 5000000)
9434 limit.rlim_max = 5000000;
9435 limit.rlim_cur = limit.rlim_max;
9436 if (setrlimit (RLIMIT_AS, &limit) < 0)
9439 /* Some printf implementations allocate temporary space on the stack. */
9441 if (getrlimit (RLIMIT_STACK, &limit) < 0)
9443 if (limit.rlim_max == RLIM_INFINITY || limit.rlim_max > 5000000)
9444 limit.rlim_max = 5000000;
9445 limit.rlim_cur = limit.rlim_max;
9446 if (setrlimit (RLIMIT_STACK, &limit) < 0)
9449 ret = printf ("%.5000000f", 1.0);
9450 return !(ret == 5000002 || (ret < 0 && errno == ENOMEM));
9454 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
9455 (eval $ac_link) 2>&5
9457 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9458 test $ac_status = 0; } && test -s conftest$ac_exeext; then
9461 if test $result != 0 && test $result != 77; then result=1; fi
9463 ) >/dev/null 2>/dev/null
9465 0) gl_cv_func_printf_enomem="yes" ;;
9466 77) gl_cv_func_printf_enomem="guessing no" ;;
9467 *) gl_cv_func_printf_enomem="no" ;;
9470 gl_cv_func_printf_enomem="guessing no"
9474 gl_cv_func_printf_enomem="guessing no"
9477 if test "$gl_cv_func_printf_enomem" = "guessing no"; then
9479 # Guess yes on glibc systems.
9480 *-gnu*) gl_cv_func_printf_enomem="guessing yes";;
9481 # Guess yes on Solaris.
9482 solaris*) gl_cv_func_printf_enomem="guessing yes";;
9484 aix*) gl_cv_func_printf_enomem="guessing yes";;
9485 # Guess yes on HP-UX/hppa.
9486 hpux*) case "$host_cpu" in
9487 hppa*) gl_cv_func_printf_enomem="guessing yes";;
9488 *) gl_cv_func_printf_enomem="guessing no";;
9491 # Guess yes on IRIX.
9492 irix*) gl_cv_func_printf_enomem="guessing yes";;
9493 # Guess yes on OSF/1.
9494 osf*) gl_cv_func_printf_enomem="guessing yes";;
9495 # Guess yes on BeOS.
9496 beos*) gl_cv_func_printf_enomem="guessing yes";;
9497 # Guess yes on Haiku.
9498 haiku*) gl_cv_func_printf_enomem="guessing yes";;
9499 # If we don't know, assume the worst.
9500 *) gl_cv_func_printf_enomem="guessing no";;
9505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_enomem" >&5
9506 $as_echo "$gl_cv_func_printf_enomem" >&6; }
9510 case "$gl_cv_func_printf_long_double" in
9515 $as_echo "#define NEED_PRINTF_LONG_DOUBLE 1" >>confdefs.h
9523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
9524 $as_echo_n "checking for long long int... " >&6; }
9525 if test "${ac_cv_type_long_long_int+set}" = set; then :
9526 $as_echo_n "(cached) " >&6
9528 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9529 /* end confdefs.h. */
9531 /* For now, do not test the preprocessor; as of 2007 there are too many
9532 implementations with broken preprocessors. Perhaps this can
9533 be revisited in 2012. In the meantime, code should not expect
9534 #if to work with literals wider than 32 bits. */
9535 /* Test literals. */
9536 long long int ll = 9223372036854775807ll;
9537 long long int nll = -9223372036854775807LL;
9538 unsigned long long int ull = 18446744073709551615ULL;
9539 /* Test constant expressions. */
9540 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
9542 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
9548 /* Test availability of runtime routines for shift and division. */
9549 long long int llmax = 9223372036854775807ll;
9550 unsigned long long int ullmax = 18446744073709551615ull;
9551 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
9552 | (llmax / ll) | (llmax % ll)
9553 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
9554 | (ullmax / ull) | (ullmax % ull));
9560 if ac_fn_c_try_link "$LINENO"; then :
9561 if test "$cross_compiling" = yes; then :
9562 ac_cv_type_long_long_int=yes
9564 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9565 /* end confdefs.h. */
9569 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
9570 # define LLONG_MAX (HALF - 1 + HALF)
9575 long long int n = 1;
9579 long long int m = n << i;
9582 if (LLONG_MAX / 2 < m)
9590 if ac_fn_c_try_run "$LINENO"; then :
9591 ac_cv_type_long_long_int=yes
9593 ac_cv_type_long_long_int=no
9595 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9596 conftest.$ac_objext conftest.beam conftest.$ac_ext
9600 ac_cv_type_long_long_int=no
9602 rm -f core conftest.err conftest.$ac_objext \
9603 conftest$ac_exeext conftest.$ac_ext
9605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
9606 $as_echo "$ac_cv_type_long_long_int" >&6; }
9607 if test $ac_cv_type_long_long_int = yes; then
9609 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
9614 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
9615 $as_echo_n "checking for wchar_t... " >&6; }
9616 if test "${gt_cv_c_wchar_t+set}" = set; then :
9617 $as_echo_n "(cached) " >&6
9619 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9620 /* end confdefs.h. */
9622 wchar_t foo = (wchar_t)'\0';
9631 if ac_fn_c_try_compile "$LINENO"; then :
9636 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
9639 $as_echo "$gt_cv_c_wchar_t" >&6; }
9640 if test $gt_cv_c_wchar_t = yes; then
9642 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
9647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wint_t" >&5
9648 $as_echo_n "checking for wint_t... " >&6; }
9649 if test "${gt_cv_c_wint_t+set}" = set; then :
9650 $as_echo_n "(cached) " >&6
9652 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9653 /* end confdefs.h. */
9655 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
9657 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
9658 before <wchar.h>. */
9663 wint_t foo = (wchar_t)'\0';
9672 if ac_fn_c_try_compile "$LINENO"; then :
9677 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wint_t" >&5
9680 $as_echo "$gt_cv_c_wint_t" >&6; }
9681 if test $gt_cv_c_wint_t = yes; then
9683 $as_echo "#define HAVE_WINT_T 1" >>confdefs.h
9690 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for intmax_t" >&5
9691 $as_echo_n "checking for intmax_t... " >&6; }
9692 if test "${gt_cv_c_intmax_t+set}" = set; then :
9693 $as_echo_n "(cached) " >&6
9695 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9696 /* end confdefs.h. */
9700 #if HAVE_STDINT_H_WITH_UINTMAX
9703 #if HAVE_INTTYPES_H_WITH_UINTMAX
9704 #include <inttypes.h>
9710 intmax_t x = -1; return !x;
9715 if ac_fn_c_try_compile "$LINENO"; then :
9716 gt_cv_c_intmax_t=yes
9720 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_intmax_t" >&5
9723 $as_echo "$gt_cv_c_intmax_t" >&6; }
9724 if test $gt_cv_c_intmax_t = yes; then
9726 $as_echo "#define HAVE_INTMAX_T 1" >>confdefs.h
9730 test $ac_cv_type_long_long_int = yes \
9731 && ac_type='long long' \
9734 cat >>confdefs.h <<_ACEOF
9735 #define intmax_t $ac_type
9745 for ac_func in snprintf strnlen wcslen wcsnlen mbrtowc wcrtomb
9747 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9748 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
9749 eval as_val=\$$as_ac_var
9750 if test "x$as_val" = x""yes; then :
9751 cat >>confdefs.h <<_ACEOF
9752 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
9758 ac_fn_c_check_decl "$LINENO" "_snprintf" "ac_cv_have_decl__snprintf" "#include <stdio.h>
9760 if test "x$ac_cv_have_decl__snprintf" = x""yes; then :
9766 cat >>confdefs.h <<_ACEOF
9767 #define HAVE_DECL__SNPRINTF $ac_have_decl
9848 REPLACE_SIGNBIT_USING_GCC=0;
9852 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdin defaults to large file offsets" >&5
9853 $as_echo_n "checking whether stdin defaults to large file offsets... " >&6; }
9854 if test "${gl_cv_var_stdin_large_offset+set}" = set; then :
9855 $as_echo_n "(cached) " >&6
9857 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9858 /* end confdefs.h. */
9863 #if defined __SL64 && defined __SCLE /* cygwin */
9864 /* Cygwin 1.5.24 and earlier fail to put stdin in 64-bit mode, making
9865 fseeko/ftello needlessly fail. This bug was fixed in 1.5.25, and
9866 it is easier to do a version check than building a runtime test. */
9867 # include <cygwin/version.h>
9868 # if CYGWIN_VERSION_DLL_COMBINED < CYGWIN_VERSION_DLL_MAKE_COMBINED (1005, 25)
9876 if ac_fn_c_try_link "$LINENO"; then :
9877 gl_cv_var_stdin_large_offset=yes
9879 gl_cv_var_stdin_large_offset=no
9881 rm -f core conftest.err conftest.$ac_objext \
9882 conftest$ac_exeext conftest.$ac_ext
9884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_var_stdin_large_offset" >&5
9885 $as_echo "$gl_cv_var_stdin_large_offset" >&6; }
9888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getcwd (NULL, 0) allocates memory for result" >&5
9889 $as_echo_n "checking whether getcwd (NULL, 0) allocates memory for result... " >&6; }
9890 if test "${gl_cv_func_getcwd_null+set}" = set; then :
9891 $as_echo_n "(cached) " >&6
9893 if test "$cross_compiling" = yes; then :
9896 # Guess yes on glibc systems.
9897 *-gnu*) gl_cv_func_getcwd_null="guessing yes";;
9898 # Guess yes on Cygwin.
9899 cygwin*) gl_cv_func_getcwd_null="guessing yes";;
9900 # Guess yes on mingw.
9901 mingw*) gl_cv_func_getcwd_null="guessing yes";;
9902 # If we don't know, assume the worst.
9903 *) gl_cv_func_getcwd_null="guessing no";;
9907 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9908 /* end confdefs.h. */
9910 # include <unistd.h>
9919 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
9920 /* mingw cwd does not start with '/', but getcwd does allocate. */
9922 if (chdir ("/") != 0)
9926 char *f = getcwd (NULL, 0);
9927 return ! (f && f[0] == '/' && !f[1]);
9935 if ac_fn_c_try_run "$LINENO"; then :
9936 gl_cv_func_getcwd_null=yes
9938 gl_cv_func_getcwd_null=no
9940 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9941 conftest.$ac_objext conftest.beam conftest.$ac_ext
9945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_null" >&5
9946 $as_echo "$gl_cv_func_getcwd_null" >&6; }
9948 ac_fn_c_check_decl "$LINENO" "getcwd" "ac_cv_have_decl_getcwd" "$ac_includes_default"
9949 if test "x$ac_cv_have_decl_getcwd" = x""yes; then :
9955 cat >>confdefs.h <<_ACEOF
9956 #define HAVE_DECL_GETCWD $ac_have_decl
9971 if test $gl_cv_have_include_next = yes; then
9972 gl_cv_next_getopt_h='<'getopt.h'>'
9974 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
9975 $as_echo_n "checking absolute name of <getopt.h>... " >&6; }
9976 if test "${gl_cv_next_getopt_h+set}" = set; then :
9977 $as_echo_n "(cached) " >&6
9980 if test $ac_cv_header_getopt_h = yes; then
9981 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9982 /* end confdefs.h. */
9987 aix*) gl_absname_cpp="$ac_cpp -C" ;;
9988 *) gl_absname_cpp="$ac_cpp" ;;
9990 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
9991 sed -n '\#/getopt.h#{
9992 s#.*"\(.*/getopt.h\)".*#\1#
9998 gl_cv_next_getopt_h='<'getopt.h'>'
10002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
10003 $as_echo "$gl_cv_next_getopt_h" >&6; }
10005 NEXT_GETOPT_H=$gl_cv_next_getopt_h
10007 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
10008 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
10009 gl_next_as_first_directive='<'getopt.h'>'
10011 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
10012 gl_next_as_first_directive=$gl_cv_next_getopt_h
10014 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
10019 if test $ac_cv_header_getopt_h = yes; then
10028 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
10029 for ac_header in getopt.h
10031 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
10032 if test "x$ac_cv_header_getopt_h" = x""yes; then :
10033 cat >>confdefs.h <<_ACEOF
10034 #define HAVE_GETOPT_H 1
10038 gl_replace_getopt=yes
10045 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
10046 for ac_func in getopt_long_only
10048 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
10049 if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
10050 cat >>confdefs.h <<_ACEOF
10051 #define HAVE_GETOPT_LONG_ONLY 1
10055 gl_replace_getopt=yes
10061 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
10062 ac_fn_c_check_decl "$LINENO" "optreset" "ac_cv_have_decl_optreset" "#include <getopt.h>
10064 if test "x$ac_cv_have_decl_optreset" = x""yes; then :
10070 cat >>confdefs.h <<_ACEOF
10071 #define HAVE_DECL_OPTRESET $ac_have_decl
10076 if test -z "$gl_replace_getopt"; then
10077 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
10078 $as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
10079 if test "${gl_cv_func_getopt_posix+set}" = set; then :
10080 $as_echo_n "(cached) " >&6
10083 if test "$cross_compiling" = yes; then :
10085 mingw*) gl_cv_func_getopt_posix="guessing no";;
10086 *) gl_cv_func_getopt_posix="guessing yes";;
10090 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10091 /* end confdefs.h. */
10093 #include <unistd.h>
10094 #include <stdlib.h>
10095 #include <string.h>
10097 #if !HAVE_DECL_OPTRESET
10098 # define OPTIND_MIN 0
10100 # define OPTIND_MIN 1
10111 argv[argc++] = "program";
10112 argv[argc++] = "-a";
10113 argv[argc++] = "foo";
10114 argv[argc++] = "bar";
10116 optind = OPTIND_MIN;
10119 c = getopt (argc, argv, "ab");
10122 c = getopt (argc, argv, "ab");
10125 if (!(optind == 2))
10128 /* Some internal state exists at this point. */
10134 argv[argc++] = "program";
10135 argv[argc++] = "donald";
10136 argv[argc++] = "-p";
10137 argv[argc++] = "billy";
10138 argv[argc++] = "duck";
10139 argv[argc++] = "-a";
10140 argv[argc++] = "bar";
10142 optind = OPTIND_MIN;
10145 c = getopt (argc, argv, "+abp:q:");
10148 if (!(strcmp (argv[0], "program") == 0))
10150 if (!(strcmp (argv[1], "donald") == 0))
10152 if (!(strcmp (argv[2], "-p") == 0))
10154 if (!(strcmp (argv[3], "billy") == 0))
10156 if (!(strcmp (argv[4], "duck") == 0))
10158 if (!(strcmp (argv[5], "-a") == 0))
10160 if (!(strcmp (argv[6], "bar") == 0))
10162 if (!(optind == 1))
10170 if ac_fn_c_try_run "$LINENO"; then :
10171 gl_cv_func_getopt_posix=yes
10173 gl_cv_func_getopt_posix=no
10175 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10176 conftest.$ac_objext conftest.beam conftest.$ac_ext
10181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
10182 $as_echo "$gl_cv_func_getopt_posix" >&6; }
10183 case "$gl_cv_func_getopt_posix" in
10184 *no) gl_replace_getopt=yes ;;
10188 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
10189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
10190 $as_echo_n "checking for working GNU getopt function... " >&6; }
10191 if test "${gl_cv_func_getopt_gnu+set}" = set; then :
10192 $as_echo_n "(cached) " >&6
10194 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
10195 # optstring is necessary for programs like m4 that have POSIX-mandated
10196 # semantics for supporting options interspersed with files.
10197 # Also, since getopt_long is a GNU extension, we require optind=0.
10198 gl_had_POSIXLY_CORRECT=${POSIXLY_CORRECT:+yes}
10200 export POSIXLY_CORRECT
10201 if test "$cross_compiling" = yes; then :
10202 case $host_os:$ac_cv_have_decl_optreset in
10203 *-gnu*:* | mingw*:*) gl_cv_func_getopt_gnu=no;;
10204 *:yes) gl_cv_func_getopt_gnu=no;;
10205 *) gl_cv_func_getopt_gnu=yes;;
10209 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10210 /* end confdefs.h. */
10211 #include <getopt.h>
10212 #include <stddef.h>
10213 #include <string.h>
10219 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
10220 and fails on MacOS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
10221 OSF/1 5.1, Solaris 10. */
10224 myargv[0] = "conftest";
10228 if (getopt (2, myargv, "+a") != '?')
10231 /* This code succeeds on glibc 2.8, mingw,
10232 and fails on MacOS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
10233 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
10235 char *argv[] = { "program", "-p", "foo", "bar", NULL };
10238 if (getopt (4, argv, "p::") != 'p')
10240 if (optarg != NULL)
10242 if (getopt (4, argv, "p::") != -1)
10247 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
10249 char *argv[] = { "program", "foo", "-p", NULL };
10251 if (getopt (3, argv, "-p") != 1)
10253 if (getopt (3, argv, "-p") != 'p')
10262 if ac_fn_c_try_run "$LINENO"; then :
10263 gl_cv_func_getopt_gnu=yes
10265 gl_cv_func_getopt_gnu=no
10267 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10268 conftest.$ac_objext conftest.beam conftest.$ac_ext
10271 if test "$gl_had_POSIXLY_CORRECT" != yes; then
10272 { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}
10276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
10277 $as_echo "$gl_cv_func_getopt_gnu" >&6; }
10278 if test "$gl_cv_func_getopt_gnu" = "no"; then
10279 gl_replace_getopt=yes
10283 ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
10284 if test "x$ac_cv_have_decl_getenv" = x""yes; then :
10290 cat >>confdefs.h <<_ACEOF
10291 #define HAVE_DECL_GETENV $ac_have_decl
10299 if test -n "$gl_replace_getopt"; then :
10305 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
10309 GNULIB_UNISTD_H_GETOPT=1
10318 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
10328 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
10345 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
10346 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
10347 if test "${ac_cv_c_restrict+set}" = set; then :
10348 $as_echo_n "(cached) " >&6
10350 ac_cv_c_restrict=no
10351 # The order here caters to the fact that C++ does not require restrict.
10352 for ac_kw in __restrict __restrict__ _Restrict restrict; do
10353 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10354 /* end confdefs.h. */
10355 typedef int * int_ptr;
10356 int foo (int_ptr $ac_kw ip) {
10363 int * $ac_kw t = s;
10370 if ac_fn_c_try_compile "$LINENO"; then :
10371 ac_cv_c_restrict=$ac_kw
10373 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10374 test "$ac_cv_c_restrict" != no && break
10378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
10379 $as_echo "$ac_cv_c_restrict" >&6; }
10381 case $ac_cv_c_restrict in
10383 no) $as_echo "#define restrict /**/" >>confdefs.h
10385 *) cat >>confdefs.h <<_ACEOF
10386 #define restrict $ac_cv_c_restrict
10402 if test $gl_cv_have_include_next = yes; then
10403 gl_cv_next_sys_time_h='<'sys/time.h'>'
10405 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
10406 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
10407 if test "${gl_cv_next_sys_time_h+set}" = set; then :
10408 $as_echo_n "(cached) " >&6
10411 if test $ac_cv_header_sys_time_h = yes; then
10412 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10413 /* end confdefs.h. */
10414 #include <sys/time.h>
10418 aix*) gl_absname_cpp="$ac_cpp -C" ;;
10419 *) gl_absname_cpp="$ac_cpp" ;;
10421 gl_cv_next_sys_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
10422 sed -n '\#/sys/time.h#{
10423 s#.*"\(.*/sys/time.h\)".*#\1#
10429 gl_cv_next_sys_time_h='<'sys/time.h'>'
10433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
10434 $as_echo "$gl_cv_next_sys_time_h" >&6; }
10436 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
10438 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
10439 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
10440 gl_next_as_first_directive='<'sys/time.h'>'
10442 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
10443 gl_next_as_first_directive=$gl_cv_next_sys_time_h
10445 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
10450 if test $ac_cv_header_sys_time_h = yes; then
10457 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
10458 $as_echo_n "checking for struct timeval... " >&6; }
10459 if test "${gl_cv_sys_struct_timeval+set}" = set; then :
10460 $as_echo_n "(cached) " >&6
10462 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10463 /* end confdefs.h. */
10464 #if HAVE_SYS_TIME_H
10465 #include <sys/time.h>
10472 static struct timeval x; x.tv_sec = x.tv_usec;
10477 if ac_fn_c_try_compile "$LINENO"; then :
10478 gl_cv_sys_struct_timeval=yes
10480 gl_cv_sys_struct_timeval=no
10482 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
10485 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
10486 if test $gl_cv_sys_struct_timeval = yes; then
10487 HAVE_STRUCT_TIMEVAL=1
10489 HAVE_STRUCT_TIMEVAL=0
10493 REPLACE_GETTIMEOFDAY=0
10495 if test $HAVE_SYS_TIME_H = 0 || test $HAVE_STRUCT_TIMEVAL = 0; then
10496 SYS_TIME_H=sys/time.h
10506 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'float'" >&5
10507 $as_echo_n "checking where to find the exponent in a 'float'... " >&6; }
10508 if test "${gl_cv_cc_float_expbit0+set}" = set; then :
10509 $as_echo_n "(cached) " >&6
10512 if test "$cross_compiling" = yes; then :
10513 gl_cv_cc_float_expbit0="word 0 bit 23"
10515 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10516 /* end confdefs.h. */
10519 #include <stddef.h>
10521 #include <string.h>
10523 ((sizeof (float) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
10524 typedef union { float value; unsigned int word[NWORDS]; } memory_float;
10525 static unsigned int ored_words[NWORDS];
10526 static unsigned int anded_words[NWORDS];
10527 static void add_to_ored_words (float x)
10531 /* Clear it first, in case
10532 sizeof (float) < sizeof (memory_float). */
10533 memset (&m, 0, sizeof (memory_float));
10535 for (i = 0; i < NWORDS; i++)
10537 ored_words[i] |= m.word[i];
10538 anded_words[i] &= m.word[i];
10544 FILE *fp = fopen ("conftest.out", "w");
10547 for (j = 0; j < NWORDS; j++)
10548 anded_words[j] = ~ (unsigned int) 0;
10549 add_to_ored_words (0.25f);
10550 add_to_ored_words (0.5f);
10551 add_to_ored_words (1.0f);
10552 add_to_ored_words (2.0f);
10553 add_to_ored_words (4.0f);
10554 /* Remove bits that are common (e.g. if representation of the first mantissa
10555 bit is explicit). */
10556 for (j = 0; j < NWORDS; j++)
10557 ored_words[j] &= ~anded_words[j];
10558 /* Now find the nonzero word. */
10559 for (j = 0; j < NWORDS; j++)
10560 if (ored_words[j] != 0)
10565 for (i = j + 1; i < NWORDS; i++)
10566 if (ored_words[i] != 0)
10568 fprintf (fp, "unknown");
10569 return (fclose (fp) != 0);
10572 if ((ored_words[j] >> i) & 1)
10574 fprintf (fp, "word %d bit %d", (int) j, (int) i);
10575 return (fclose (fp) != 0);
10578 fprintf (fp, "unknown");
10579 return (fclose (fp) != 0);
10583 if ac_fn_c_try_run "$LINENO"; then :
10584 gl_cv_cc_float_expbit0=`cat conftest.out`
10586 gl_cv_cc_float_expbit0="unknown"
10588 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10589 conftest.$ac_objext conftest.beam conftest.$ac_ext
10595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_float_expbit0" >&5
10596 $as_echo "$gl_cv_cc_float_expbit0" >&6; }
10597 case "$gl_cv_cc_float_expbit0" in
10599 word=`echo "$gl_cv_cc_float_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
10600 bit=`echo "$gl_cv_cc_float_expbit0" | sed -e 's/word.*bit //'`
10602 cat >>confdefs.h <<_ACEOF
10603 #define FLT_EXPBIT0_WORD $word
10607 cat >>confdefs.h <<_ACEOF
10608 #define FLT_EXPBIT0_BIT $bit
10617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
10618 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
10619 if test "${am_cv_langinfo_codeset+set}" = set; then :
10620 $as_echo_n "(cached) " >&6
10622 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10623 /* end confdefs.h. */
10624 #include <langinfo.h>
10628 char* cs = nl_langinfo(CODESET); return !cs;
10633 if ac_fn_c_try_link "$LINENO"; then :
10634 am_cv_langinfo_codeset=yes
10636 am_cv_langinfo_codeset=no
10638 rm -f core conftest.err conftest.$ac_objext \
10639 conftest$ac_exeext conftest.$ac_ext
10642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
10643 $as_echo "$am_cv_langinfo_codeset" >&6; }
10644 if test $am_cv_langinfo_codeset = yes; then
10646 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
10650 ac_fn_c_check_decl "$LINENO" "getc_unlocked" "ac_cv_have_decl_getc_unlocked" "$ac_includes_default"
10651 if test "x$ac_cv_have_decl_getc_unlocked" = x""yes; then :
10657 cat >>confdefs.h <<_ACEOF
10658 #define HAVE_DECL_GETC_UNLOCKED $ac_have_decl
10662 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C Library 2.1 or newer" >&5
10663 $as_echo_n "checking whether we are using the GNU C Library 2.1 or newer... " >&6; }
10664 if test "${ac_cv_gnu_library_2_1+set}" = set; then :
10665 $as_echo_n "(cached) " >&6
10667 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10668 /* end confdefs.h. */
10670 #include <features.h>
10671 #ifdef __GNU_LIBRARY__
10672 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)
10678 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10679 $EGREP "Lucky GNU user" >/dev/null 2>&1; then :
10680 ac_cv_gnu_library_2_1=yes
10682 ac_cv_gnu_library_2_1=no
10689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gnu_library_2_1" >&5
10690 $as_echo "$ac_cv_gnu_library_2_1" >&6; }
10692 GLIBC21="$ac_cv_gnu_library_2_1"
10697 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
10698 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
10699 if test "${ac_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
10700 $as_echo_n "(cached) " >&6
10702 rm -f conftest.sym conftest.file
10703 echo >conftest.file
10704 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
10705 if test "$cross_compiling" = yes; then :
10706 ac_cv_func_lstat_dereferences_slashed_symlink=no
10708 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10709 /* end confdefs.h. */
10710 $ac_includes_default
10715 /* Linux will dereference the symlink and fail, as required by POSIX.
10716 That is better in the sense that it means we will not
10717 have to compile and use the lstat wrapper. */
10718 return lstat ("conftest.sym/", &sbuf) == 0;
10723 if ac_fn_c_try_run "$LINENO"; then :
10724 ac_cv_func_lstat_dereferences_slashed_symlink=yes
10726 ac_cv_func_lstat_dereferences_slashed_symlink=no
10728 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10729 conftest.$ac_objext conftest.beam conftest.$ac_ext
10733 # If the `ln -s' command failed, then we probably don't even
10734 # have an lstat function.
10735 ac_cv_func_lstat_dereferences_slashed_symlink=no
10737 rm -f conftest.sym conftest.file
10740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_lstat_dereferences_slashed_symlink" >&5
10741 $as_echo "$ac_cv_func_lstat_dereferences_slashed_symlink" >&6; }
10743 test $ac_cv_func_lstat_dereferences_slashed_symlink = yes &&
10745 cat >>confdefs.h <<_ACEOF
10746 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
10750 if test "x$ac_cv_func_lstat_dereferences_slashed_symlink" = xno; then
10759 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
10771 GNULIB_MBSRTOWCS=0;
10772 GNULIB_MBSNRTOWCS=0;
10774 GNULIB_WCSRTOMBS=0;
10775 GNULIB_WCSNRTOMBS=0;
10787 HAVE_DECL_WCWIDTH=1;
10788 REPLACE_MBSTATE_T=0;
10794 REPLACE_MBSRTOWCS=0;
10795 REPLACE_MBSNRTOWCS=0;
10797 REPLACE_WCSRTOMBS=0;
10798 REPLACE_WCSNRTOMBS=0;
10803 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
10804 $as_echo_n "checking for mbstate_t... " >&6; }
10805 if test "${ac_cv_type_mbstate_t+set}" = set; then :
10806 $as_echo_n "(cached) " >&6
10808 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10809 /* end confdefs.h. */
10810 $ac_includes_default
10811 # include <wchar.h>
10815 mbstate_t x; return sizeof x;
10820 if ac_fn_c_try_compile "$LINENO"; then :
10821 ac_cv_type_mbstate_t=yes
10823 ac_cv_type_mbstate_t=no
10825 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
10828 $as_echo "$ac_cv_type_mbstate_t" >&6; }
10829 if test $ac_cv_type_mbstate_t = yes; then
10831 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
10835 $as_echo "#define mbstate_t int" >>confdefs.h
10846 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional japanese locale" >&5
10847 $as_echo_n "checking for a traditional japanese locale... " >&6; }
10848 if test "${gt_cv_locale_ja+set}" = set; then :
10849 $as_echo_n "(cached) " >&6
10852 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10853 /* end confdefs.h. */
10855 #include <locale.h>
10857 #if HAVE_LANGINFO_CODESET
10858 # include <langinfo.h>
10860 #include <stdlib.h>
10861 #include <string.h>
10867 /* Check whether the given locale name is recognized by the system. */
10868 if (setlocale (LC_ALL, "") == NULL) return 1;
10869 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
10870 On MacOS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
10871 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
10872 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
10873 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
10874 some unit tests fail. */
10875 #if HAVE_LANGINFO_CODESET
10877 const char *cs = nl_langinfo (CODESET);
10878 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
10883 /* On Cygwin, avoid locale names without encoding suffix, because the
10884 locale_charset() function relies on the encoding suffix. Note that
10885 LC_ALL is set on the command line. */
10886 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
10888 /* Check whether MB_CUR_MAX is > 1. This excludes the dysfunctional locales
10889 on Cygwin 1.5.x. */
10890 if (MB_CUR_MAX == 1)
10892 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
10893 This excludes the UTF-8 encoding. */
10894 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
10895 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
10896 for (p = buf; *p != '\0'; p++)
10897 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
10903 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
10904 (eval $ac_link) 2>&5
10906 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
10907 test $ac_status = 0; } && test -s conftest$ac_exeext; then
10908 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
10909 # otherwise on MacOS X 10.3.5 the LC_TIME=C from the beginning of the
10910 # configure script would override the LC_ALL setting. Likewise for
10911 # LC_CTYPE, which is also set at the beginning of the configure script.
10912 # Test for the AIX locale name.
10913 if (LC_ALL=ja_JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10914 gt_cv_locale_ja=ja_JP
10916 # Test for the locale name with explicit encoding suffix.
10917 if (LC_ALL=ja_JP.EUC-JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10918 gt_cv_locale_ja=ja_JP.EUC-JP
10920 # Test for the HP-UX, OSF/1, NetBSD locale name.
10921 if (LC_ALL=ja_JP.eucJP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10922 gt_cv_locale_ja=ja_JP.eucJP
10924 # Test for the IRIX, FreeBSD locale name.
10925 if (LC_ALL=ja_JP.EUC LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10926 gt_cv_locale_ja=ja_JP.EUC
10928 # Test for the Solaris 7 locale name.
10929 if (LC_ALL=ja LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10932 # Special test for NetBSD 1.6.
10933 if test -f /usr/share/locale/ja_JP.eucJP/LC_CTYPE; then
10934 gt_cv_locale_ja=ja_JP.eucJP
10937 gt_cv_locale_ja=none
10948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_ja" >&5
10949 $as_echo "$gt_cv_locale_ja" >&6; }
10950 LOCALE_JA=$gt_cv_locale_ja
10956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a transitional chinese locale" >&5
10957 $as_echo_n "checking for a transitional chinese locale... " >&6; }
10958 if test "${gt_cv_locale_zh_CN+set}" = set; then :
10959 $as_echo_n "(cached) " >&6
10962 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10963 /* end confdefs.h. */
10965 #include <locale.h>
10966 #include <stdlib.h>
10968 #if HAVE_LANGINFO_CODESET
10969 # include <langinfo.h>
10971 #include <stdlib.h>
10972 #include <string.h>
10978 /* Check whether the given locale name is recognized by the system. */
10979 if (setlocale (LC_ALL, "") == NULL) return 1;
10980 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
10981 On MacOS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
10982 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
10983 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
10984 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
10985 some unit tests fail. */
10986 #if HAVE_LANGINFO_CODESET
10988 const char *cs = nl_langinfo (CODESET);
10989 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
10994 /* On Cygwin, avoid locale names without encoding suffix, because the
10995 locale_charset() function relies on the encoding suffix. Note that
10996 LC_ALL is set on the command line. */
10997 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
10999 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
11000 This excludes the UTF-8 encoding. */
11001 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
11002 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
11003 for (p = buf; *p != '\0'; p++)
11004 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
11006 /* Check whether a typical GB18030 multibyte sequence is recognized as a
11007 single wide character. This excludes the GB2312 and GBK encodings. */
11008 if (mblen ("\203\062\332\066", 5) != 4)
11014 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
11015 (eval $ac_link) 2>&5
11017 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
11018 test $ac_status = 0; } && test -s conftest$ac_exeext; then
11019 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
11020 # otherwise on MacOS X 10.3.5 the LC_TIME=C from the beginning of the
11021 # configure script would override the LC_ALL setting. Likewise for
11022 # LC_CTYPE, which is also set at the beginning of the configure script.
11023 # Test for the locale name without encoding suffix.
11024 if (LC_ALL=zh_CN LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11025 gt_cv_locale_zh_CN=zh_CN
11027 # Test for the locale name with explicit encoding suffix.
11028 if (LC_ALL=zh_CN.GB18030 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11029 gt_cv_locale_zh_CN=zh_CN.GB18030
11032 gt_cv_locale_zh_CN=none
11036 # If there was a link error, due to mblen(), the system is so old that
11037 # it certainly doesn't have a chinese locale.
11038 gt_cv_locale_zh_CN=none
11043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_zh_CN" >&5
11044 $as_echo "$gt_cv_locale_zh_CN" >&6; }
11045 LOCALE_ZH_CN=$gt_cv_locale_zh_CN
11050 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
11051 $as_echo_n "checking for a french Unicode locale... " >&6; }
11052 if test "${gt_cv_locale_fr_utf8+set}" = set; then :
11053 $as_echo_n "(cached) " >&6
11056 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11057 /* end confdefs.h. */
11059 #include <locale.h>
11061 #if HAVE_LANGINFO_CODESET
11062 # include <langinfo.h>
11064 #include <stdlib.h>
11065 #include <string.h>
11069 /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
11070 imitates locale dependent behaviour by looking at the environment
11071 variables, and all locales use the UTF-8 encoding. */
11072 #if !(defined __BEOS__ || defined __HAIKU__)
11073 /* Check whether the given locale name is recognized by the system. */
11074 if (setlocale (LC_ALL, "") == NULL) return 1;
11075 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
11076 On MacOS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
11077 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
11078 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
11079 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
11080 some unit tests fail. */
11081 # if HAVE_LANGINFO_CODESET
11083 const char *cs = nl_langinfo (CODESET);
11084 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
11089 /* On Cygwin, avoid locale names without encoding suffix, because the
11090 locale_charset() function relies on the encoding suffix. Note that
11091 LC_ALL is set on the command line. */
11092 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
11094 /* Check whether in the abbreviation of the second month, the second
11095 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
11096 two bytes long, with UTF-8 encoding. */
11097 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
11098 if (strftime (buf, sizeof (buf), "%b", &t) < 4
11099 || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
11102 /* Check whether the decimal separator is a comma.
11103 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
11104 are nl_langinfo(RADIXCHAR) are both ".". */
11105 if (localeconv () ->decimal_point[0] != ',') return 1;
11110 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
11111 (eval $ac_link) 2>&5
11113 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
11114 test $ac_status = 0; } && test -s conftest$ac_exeext; then
11115 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
11116 # otherwise on MacOS X 10.3.5 the LC_TIME=C from the beginning of the
11117 # configure script would override the LC_ALL setting. Likewise for
11118 # LC_CTYPE, which is also set at the beginning of the configure script.
11119 # Test for the usual locale name.
11120 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11121 gt_cv_locale_fr_utf8=fr_FR
11123 # Test for the locale name with explicit encoding suffix.
11124 if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11125 gt_cv_locale_fr_utf8=fr_FR.UTF-8
11127 # Test for the Solaris 7 locale name.
11128 if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11129 gt_cv_locale_fr_utf8=fr.UTF-8
11132 gt_cv_locale_fr_utf8=none
11140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
11141 $as_echo "$gt_cv_locale_fr_utf8" >&6; }
11142 LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
11154 GNULIB_RAWMEMCHR=0;
11157 GNULIB_STRCHRNUL=0;
11164 GNULIB_STRCASESTR=0;
11171 GNULIB_MBSCASECMP=0;
11172 GNULIB_MBSNCASECMP=0;
11173 GNULIB_MBSPCASECMP=0;
11174 GNULIB_MBSCASESTR=0;
11181 GNULIB_STRSIGNAL=0;
11182 GNULIB_STRVERSCMP=0;
11184 HAVE_DECL_MEMMEM=1;
11186 HAVE_DECL_MEMRCHR=1;
11191 HAVE_DECL_STRDUP=1;
11192 HAVE_DECL_STRNDUP=1;
11193 HAVE_DECL_STRNLEN=1;
11197 HAVE_DECL_STRTOK_R=1;
11198 HAVE_DECL_STRERROR=1;
11199 HAVE_DECL_STRSIGNAL=1;
11205 REPLACE_STRCASESTR=0;
11206 REPLACE_STRERROR=0;
11208 REPLACE_STRSIGNAL=0;
11209 REPLACE_STRTOK_R=0;
11210 UNDEFINE_STRTOK_R=0;
11219 # Check for mmap(). Don't use AC_FUNC_MMAP, because it checks too much: it
11220 # fails on HP-UX 11, because MAP_FIXED mappings do not work. But this is
11221 # irrelevant for anonymous mappings.
11222 ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap"
11223 if test "x$ac_cv_func_mmap" = x""yes; then :
11230 # Try to allow MAP_ANONYMOUS.
11231 gl_have_mmap_anonymous=no
11232 if test $gl_have_mmap = yes; then
11233 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAP_ANONYMOUS" >&5
11234 $as_echo_n "checking for MAP_ANONYMOUS... " >&6; }
11235 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11236 /* end confdefs.h. */
11238 #include <sys/mman.h>
11239 #ifdef MAP_ANONYMOUS
11240 I cant identify this map.
11244 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11245 $EGREP "I cant identify this map." >/dev/null 2>&1; then :
11246 gl_have_mmap_anonymous=yes
11250 if test $gl_have_mmap_anonymous != yes; then
11251 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11252 /* end confdefs.h. */
11254 #include <sys/mman.h>
11256 I cant identify this map.
11260 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11261 $EGREP "I cant identify this map." >/dev/null 2>&1; then :
11263 $as_echo "#define MAP_ANONYMOUS MAP_ANON" >>confdefs.h
11265 gl_have_mmap_anonymous=yes
11270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_have_mmap_anonymous" >&5
11271 $as_echo "$gl_have_mmap_anonymous" >&6; }
11272 if test $gl_have_mmap_anonymous = yes; then
11274 $as_echo "#define HAVE_MAP_ANONYMOUS 1" >>confdefs.h
11291 for ac_func in memchr
11293 ac_fn_c_check_func "$LINENO" "memchr" "ac_cv_func_memchr"
11294 if test "x$ac_cv_func_memchr" = x""yes; then :
11295 cat >>confdefs.h <<_ACEOF
11296 #define HAVE_MEMCHR 1
11301 gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
11307 if test $ac_cv_func_memchr = no; then
11309 for ac_header in bp-sym.h
11311 ac_fn_c_check_header_mongrel "$LINENO" "bp-sym.h" "ac_cv_header_bp_sym_h" "$ac_includes_default"
11312 if test "x$ac_cv_header_bp_sym_h" = x""yes; then :
11313 cat >>confdefs.h <<_ACEOF
11314 #define HAVE_BP_SYM_H 1
11325 if test $ac_cv_func_memchr = yes; then
11326 # Detect platform-specific bugs in some versions of glibc:
11327 # memchr should not dereference anything with length 0
11328 # http://bugzilla.redhat.com/499689
11329 # memchr should not dereference overestimated length after a match
11330 # http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=521737
11331 # http://sourceware.org/bugzilla/show_bug.cgi?id=10162
11332 # Assume that memchr works on platforms that lack mprotect.
11333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memchr works" >&5
11334 $as_echo_n "checking whether memchr works... " >&6; }
11335 if test "${gl_cv_func_memchr_works+set}" = set; then :
11336 $as_echo_n "(cached) " >&6
11338 if test "$cross_compiling" = yes; then :
11339 gl_cv_func_memchr_works="guessing no"
11341 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11342 /* end confdefs.h. */
11344 #include <string.h>
11345 #if HAVE_SYS_MMAN_H
11346 # include <fcntl.h>
11347 # include <unistd.h>
11348 # include <sys/types.h>
11349 # include <sys/mman.h>
11351 # define MAP_FILE 0
11359 char *fence = NULL;
11360 #if HAVE_SYS_MMAN_H && HAVE_MPROTECT
11361 # if HAVE_MAP_ANONYMOUS
11362 const int flags = MAP_ANONYMOUS | MAP_PRIVATE;
11364 # else /* !HAVE_MAP_ANONYMOUS */
11365 const int flags = MAP_FILE | MAP_PRIVATE;
11366 int fd = open ("/dev/zero", O_RDONLY, 0666);
11370 int pagesize = getpagesize ();
11372 (char *) mmap (NULL, 2 * pagesize, PROT_READ | PROT_WRITE,
11374 if (two_pages != (char *)(-1)
11375 && mprotect (two_pages + pagesize, pagesize, PROT_NONE) == 0)
11376 fence = two_pages + pagesize;
11381 if (memchr (fence, 0, 0))
11383 strcpy (fence - 9, "12345678");
11384 if (memchr (fence - 9, 0, 79) != fence - 1)
11393 if ac_fn_c_try_run "$LINENO"; then :
11394 gl_cv_func_memchr_works=yes
11396 gl_cv_func_memchr_works=no
11398 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11399 conftest.$ac_objext conftest.beam conftest.$ac_ext
11403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memchr_works" >&5
11404 $as_echo "$gl_cv_func_memchr_works" >&6; }
11405 if test "$gl_cv_func_memchr_works" != yes; then
11407 for ac_header in bp-sym.h
11409 ac_fn_c_check_header_mongrel "$LINENO" "bp-sym.h" "ac_cv_header_bp_sym_h" "$ac_includes_default"
11410 if test "x$ac_cv_header_bp_sym_h" = x""yes; then :
11411 cat >>confdefs.h <<_ACEOF
11412 #define HAVE_BP_SYM_H 1
11429 gl_LIBOBJS="$gl_LIBOBJS memchr.$ac_objext"
11434 ac_fn_c_check_decl "$LINENO" "memrchr" "ac_cv_have_decl_memrchr" "$ac_includes_default"
11435 if test "x$ac_cv_have_decl_memrchr" = x""yes; then :
11441 cat >>confdefs.h <<_ACEOF
11442 #define HAVE_DECL_MEMRCHR $ac_have_decl
11450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether unlink honors trailing slashes" >&5
11451 $as_echo_n "checking whether unlink honors trailing slashes... " >&6; }
11452 if test "${gl_cv_func_unlink_works+set}" = set; then :
11453 $as_echo_n "(cached) " >&6
11455 touch conftest.file
11456 # Assume that if we have lstat, we can also check symlinks.
11457 if test $ac_cv_func_lstat = yes; then
11458 ln -s conftest.file conftest.lnk
11460 if test "$cross_compiling" = yes; then :
11461 gl_cv_func_unlink_works="guessing no"
11463 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11464 /* end confdefs.h. */
11465 #include <unistd.h>
11471 if (!unlink ("conftest.file/") || errno != ENOTDIR) return 1;
11473 if (!unlink ("conftest.lnk/") || errno != ENOTDIR) return 2;
11480 if ac_fn_c_try_run "$LINENO"; then :
11481 gl_cv_func_unlink_works=yes
11483 gl_cv_func_unlink_works=no
11485 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11486 conftest.$ac_objext conftest.beam conftest.$ac_ext
11489 rm -f conftest.file conftest.lnk
11491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_unlink_works" >&5
11492 $as_echo "$gl_cv_func_unlink_works" >&6; }
11493 if test x"$gl_cv_func_unlink_works" != xyes; then
11503 gl_LIBOBJS="$gl_LIBOBJS unlink.$ac_objext"
11522 gl_cv_func_vfprintf_posix=no
11523 case "$gl_cv_func_printf_sizes_c99" in
11525 case "$gl_cv_func_printf_long_double" in
11527 case "$gl_cv_func_printf_infinite" in
11529 case "$gl_cv_func_printf_infinite_long_double" in
11531 case "$gl_cv_func_printf_directive_a" in
11533 case "$gl_cv_func_printf_directive_f" in
11535 case "$gl_cv_func_printf_directive_n" in
11537 case "$gl_cv_func_printf_directive_ls" in
11539 case "$gl_cv_func_printf_positions" in
11541 case "$gl_cv_func_printf_flag_grouping" in
11543 case "$gl_cv_func_printf_flag_leftadjust" in
11545 case "$gl_cv_func_printf_flag_zero" in
11547 case "$gl_cv_func_printf_precision" in
11549 case "$gl_cv_func_printf_enomem" in
11551 # vfprintf exists and is
11552 # already POSIX compliant.
11553 gl_cv_func_vfprintf_posix=yes
11582 if test $gl_cv_func_vfprintf_posix = no; then
11586 case "$gl_cv_func_printf_infinite" in
11591 $as_echo "#define NEED_PRINTF_INFINITE_DOUBLE 1" >>confdefs.h
11599 case "$gl_cv_func_printf_long_double" in
11601 case "$gl_cv_func_printf_infinite_long_double" in
11606 $as_echo "#define NEED_PRINTF_INFINITE_LONG_DOUBLE 1" >>confdefs.h
11615 case "$gl_cv_func_printf_directive_a" in
11620 $as_echo "#define NEED_PRINTF_DIRECTIVE_A 1" >>confdefs.h
11622 for ac_func in nl_langinfo
11624 ac_fn_c_check_func "$LINENO" "nl_langinfo" "ac_cv_func_nl_langinfo"
11625 if test "x$ac_cv_func_nl_langinfo" = x""yes; then :
11626 cat >>confdefs.h <<_ACEOF
11627 #define HAVE_NL_LANGINFO 1
11638 case "$gl_cv_func_printf_directive_f" in
11643 $as_echo "#define NEED_PRINTF_DIRECTIVE_F 1" >>confdefs.h
11650 case "$gl_cv_func_printf_directive_ls" in
11655 $as_echo "#define NEED_PRINTF_DIRECTIVE_LS 1" >>confdefs.h
11662 case "$gl_cv_func_printf_flag_grouping" in
11667 $as_echo "#define NEED_PRINTF_FLAG_GROUPING 1" >>confdefs.h
11674 case "$gl_cv_func_printf_flag_leftadjust" in
11679 $as_echo "#define NEED_PRINTF_FLAG_LEFTADJUST 1" >>confdefs.h
11686 case "$gl_cv_func_printf_flag_zero" in
11691 $as_echo "#define NEED_PRINTF_FLAG_ZERO 1" >>confdefs.h
11698 case "$gl_cv_func_printf_precision" in
11703 $as_echo "#define NEED_PRINTF_UNBOUNDED_PRECISION 1" >>confdefs.h
11706 $as_echo "#define NEED_PRINTF_DOUBLE 1" >>confdefs.h
11709 $as_echo "#define NEED_PRINTF_LONG_DOUBLE 1" >>confdefs.h
11716 case "$gl_cv_func_printf_enomem" in
11721 $as_echo "#define NEED_PRINTF_ENOMEM 1" >>confdefs.h
11724 $as_echo "#define NEED_PRINTF_DOUBLE 1" >>confdefs.h
11727 $as_echo "#define NEED_PRINTF_LONG_DOUBLE 1" >>confdefs.h
11742 gl_LIBOBJS="$gl_LIBOBJS vasnprintf.$ac_objext"
11752 gl_LIBOBJS="$gl_LIBOBJS printf-args.$ac_objext"
11762 gl_LIBOBJS="$gl_LIBOBJS printf-parse.$ac_objext"
11772 gl_LIBOBJS="$gl_LIBOBJS asnprintf.$ac_objext"
11774 if test $ac_cv_func_vasnprintf = yes; then
11776 $as_echo "#define REPLACE_VASNPRINTF 1" >>confdefs.h
11789 ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
11790 if test "x$ac_cv_type_ptrdiff_t" = x""yes; then :
11794 $as_echo "#define ptrdiff_t long" >>confdefs.h
11815 gl_LIBOBJS="$gl_LIBOBJS vfprintf.$ac_objext"
11819 $as_echo "#define REPLACE_VFPRINTF_POSIX 1" >>confdefs.h
11825 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
11826 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
11827 if test "${ac_cv_header_stdbool_h+set}" = set; then :
11828 $as_echo_n "(cached) " >&6
11830 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11831 /* end confdefs.h. */
11833 #include <stdbool.h>
11835 "error: bool is not defined"
11838 "error: false is not defined"
11841 "error: false is not 0"
11844 "error: true is not defined"
11847 "error: true is not 1"
11849 #ifndef __bool_true_false_are_defined
11850 "error: __bool_true_false_are_defined is not defined"
11853 struct s { _Bool s: 1; _Bool t; } s;
11855 char a[true == 1 ? 1 : -1];
11856 char b[false == 0 ? 1 : -1];
11857 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
11858 char d[(bool) 0.5 == true ? 1 : -1];
11860 char f[(_Bool) 0.0 == false ? 1 : -1];
11862 char h[sizeof (_Bool)];
11863 char i[sizeof s.t];
11864 enum { j = false, k = true, l = false * true, m = true * 256 };
11866 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
11867 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
11868 #if defined __xlc__ || defined __GNUC__
11869 /* Catch a bug in IBM AIX xlc compiler version 6.0.0.0
11870 reported by James Lemley on 2005-10-05; see
11871 http://lists.gnu.org/archive/html/bug-coreutils/2005-10/msg00086.html
11872 This test is not quite right, since xlc is allowed to
11873 reject this program, as the initializer for xlcbug is
11874 not one of the forms that C requires support for.
11875 However, doing the test right would require a run-time
11876 test, and that would make cross-compilation harder.
11877 Let us hope that IBM fixes the xlc bug, and also adds
11878 support for this kind of constant expression. In the
11879 meantime, this test will reject xlc, which is OK, since
11880 our stdbool.h substitute should suffice. We also test
11881 this with GCC, where it should work, to detect more
11882 quickly whether someone messes up the test in the
11884 char digs[] = "0123456789";
11885 int xlcbug = 1 / (&(digs + 5)[-2 + (bool) 1] == &digs[4] ? 1 : -1);
11887 /* Catch a bug in an HP-UX C compiler. See
11888 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
11889 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
11900 /* Refer to every declared value, to avoid compiler optimizations. */
11901 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
11902 + !m + !n + !o + !p + !q + !pq);
11908 if ac_fn_c_try_compile "$LINENO"; then :
11909 ac_cv_header_stdbool_h=yes
11911 ac_cv_header_stdbool_h=no
11913 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
11916 $as_echo "$ac_cv_header_stdbool_h" >&6; }
11917 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
11918 if test "x$ac_cv_type__Bool" = x""yes; then :
11920 cat >>confdefs.h <<_ACEOF
11921 #define HAVE__BOOL 1
11927 if test $ac_cv_header_stdbool_h = yes; then
11929 $as_echo "#define HAVE_STDBOOL_H 1" >>confdefs.h
11940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
11941 $as_echo_n "checking for unsigned long long int... " >&6; }
11942 if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
11943 $as_echo_n "(cached) " >&6
11945 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11946 /* end confdefs.h. */
11948 /* For now, do not test the preprocessor; as of 2007 there are too many
11949 implementations with broken preprocessors. Perhaps this can
11950 be revisited in 2012. In the meantime, code should not expect
11951 #if to work with literals wider than 32 bits. */
11952 /* Test literals. */
11953 long long int ll = 9223372036854775807ll;
11954 long long int nll = -9223372036854775807LL;
11955 unsigned long long int ull = 18446744073709551615ULL;
11956 /* Test constant expressions. */
11957 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
11959 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
11965 /* Test availability of runtime routines for shift and division. */
11966 long long int llmax = 9223372036854775807ll;
11967 unsigned long long int ullmax = 18446744073709551615ull;
11968 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
11969 | (llmax / ll) | (llmax % ll)
11970 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
11971 | (ullmax / ull) | (ullmax % ull));
11977 if ac_fn_c_try_link "$LINENO"; then :
11978 ac_cv_type_unsigned_long_long_int=yes
11980 ac_cv_type_unsigned_long_long_int=no
11982 rm -f core conftest.err conftest.$ac_objext \
11983 conftest$ac_exeext conftest.$ac_ext
11985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
11986 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
11987 if test $ac_cv_type_unsigned_long_long_int = yes; then
11989 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
12001 ac_fn_c_check_decl "$LINENO" "strdup" "ac_cv_have_decl_strdup" "$ac_includes_default"
12002 if test "x$ac_cv_have_decl_strdup" = x""yes; then :
12008 cat >>confdefs.h <<_ACEOF
12009 #define HAVE_DECL_STRDUP $ac_have_decl
12017 if test -z "$ERRNO_H"; then
12018 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strerror function" >&5
12019 $as_echo_n "checking for working strerror function... " >&6; }
12020 if test "${gl_cv_func_working_strerror+set}" = set; then :
12021 $as_echo_n "(cached) " >&6
12023 if test "$cross_compiling" = yes; then :
12024 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12025 /* end confdefs.h. */
12026 #include <string.h>
12031 return !*strerror (-2);
12036 if ac_fn_c_try_compile "$LINENO"; then :
12037 gl_cv_func_working_strerror=yes
12039 gl_cv_func_working_strerror=no
12041 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12044 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12045 /* end confdefs.h. */
12046 #include <string.h>
12051 return !*strerror (-2);
12056 if ac_fn_c_try_run "$LINENO"; then :
12057 gl_cv_func_working_strerror=yes
12059 gl_cv_func_working_strerror=no
12061 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12062 conftest.$ac_objext conftest.beam conftest.$ac_ext
12067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_strerror" >&5
12068 $as_echo "$gl_cv_func_working_strerror" >&6; }
12069 if test $gl_cv_func_working_strerror = no; then
12075 if test $REPLACE_STRERROR = 1; then
12077 ac_fn_c_check_decl "$LINENO" "strerror" "ac_cv_have_decl_strerror" "$ac_includes_default"
12078 if test "x$ac_cv_have_decl_strerror" = x""yes; then :
12084 cat >>confdefs.h <<_ACEOF
12085 #define HAVE_DECL_STRERROR $ac_have_decl
12089 if test $ac_cv_header_sys_socket_h != yes; then
12090 for ac_header in winsock2.h
12092 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
12093 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
12094 cat >>confdefs.h <<_ACEOF
12095 #define HAVE_WINSOCK2_H 1
12117 if test $gl_cv_have_include_next = yes; then
12118 gl_cv_next_string_h='<'string.h'>'
12120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <string.h>" >&5
12121 $as_echo_n "checking absolute name of <string.h>... " >&6; }
12122 if test "${gl_cv_next_string_h+set}" = set; then :
12123 $as_echo_n "(cached) " >&6
12126 if test $ac_cv_header_string_h = yes; then
12127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12128 /* end confdefs.h. */
12129 #include <string.h>
12133 aix*) gl_absname_cpp="$ac_cpp -C" ;;
12134 *) gl_absname_cpp="$ac_cpp" ;;
12136 gl_cv_next_string_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
12137 sed -n '\#/string.h#{
12138 s#.*"\(.*/string.h\)".*#\1#
12144 gl_cv_next_string_h='<'string.h'>'
12148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_string_h" >&5
12149 $as_echo "$gl_cv_next_string_h" >&6; }
12151 NEXT_STRING_H=$gl_cv_next_string_h
12153 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
12154 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
12155 gl_next_as_first_directive='<'string.h'>'
12157 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
12158 gl_next_as_first_directive=$gl_cv_next_string_h
12160 NEXT_AS_FIRST_DIRECTIVE_STRING_H=$gl_next_as_first_directive
12165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
12166 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
12167 if test "${ac_cv_header_stat_broken+set}" = set; then :
12168 $as_echo_n "(cached) " >&6
12170 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12171 /* end confdefs.h. */
12172 #include <sys/types.h>
12173 #include <sys/stat.h>
12175 #if defined S_ISBLK && defined S_IFDIR
12176 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
12179 #if defined S_ISBLK && defined S_IFCHR
12180 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
12183 #if defined S_ISLNK && defined S_IFREG
12184 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
12187 #if defined S_ISSOCK && defined S_IFREG
12188 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
12192 if ac_fn_c_try_compile "$LINENO"; then :
12193 ac_cv_header_stat_broken=no
12195 ac_cv_header_stat_broken=yes
12197 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
12200 $as_echo "$ac_cv_header_stat_broken" >&6; }
12201 if test $ac_cv_header_stat_broken = yes; then
12203 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
12210 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
12211 REPLACE_MKTIME=GNULIB_PORTCHECK;
12212 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
12213 REPLACE_STRPTIME=GNULIB_PORTCHECK;
12214 REPLACE_TIMEGM=GNULIB_PORTCHECK;
12220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
12221 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
12222 if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
12223 $as_echo_n "(cached) " >&6
12225 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12226 /* end confdefs.h. */
12232 static struct timespec x; x.tv_sec = x.tv_nsec;
12237 if ac_fn_c_try_compile "$LINENO"; then :
12238 gl_cv_sys_struct_timespec_in_time_h=yes
12240 gl_cv_sys_struct_timespec_in_time_h=no
12242 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
12245 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
12247 TIME_H_DEFINES_STRUCT_TIMESPEC=0
12248 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
12249 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
12250 TIME_H_DEFINES_STRUCT_TIMESPEC=1
12252 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
12253 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
12254 if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
12255 $as_echo_n "(cached) " >&6
12257 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12258 /* end confdefs.h. */
12259 #include <sys/time.h>
12264 static struct timespec x; x.tv_sec = x.tv_nsec;
12269 if ac_fn_c_try_compile "$LINENO"; then :
12270 gl_cv_sys_struct_timespec_in_sys_time_h=yes
12272 gl_cv_sys_struct_timespec_in_sys_time_h=no
12274 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
12277 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
12278 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
12279 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
12294 if test $gl_cv_have_include_next = yes; then
12295 gl_cv_next_time_h='<'time.h'>'
12297 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
12298 $as_echo_n "checking absolute name of <time.h>... " >&6; }
12299 if test "${gl_cv_next_time_h+set}" = set; then :
12300 $as_echo_n "(cached) " >&6
12303 if test $ac_cv_header_time_h = yes; then
12304 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12305 /* end confdefs.h. */
12310 aix*) gl_absname_cpp="$ac_cpp -C" ;;
12311 *) gl_absname_cpp="$ac_cpp" ;;
12313 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
12314 sed -n '\#/time.h#{
12315 s#.*"\(.*/time.h\)".*#\1#
12321 gl_cv_next_time_h='<'time.h'>'
12325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
12326 $as_echo "$gl_cv_next_time_h" >&6; }
12328 NEXT_TIME_H=$gl_cv_next_time_h
12330 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
12331 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
12332 gl_next_as_first_directive='<'time.h'>'
12334 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
12335 gl_next_as_first_directive=$gl_cv_next_time_h
12337 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
12346 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the utimes function works" >&5
12347 $as_echo_n "checking whether the utimes function works... " >&6; }
12348 if test "${gl_cv_func_working_utimes+set}" = set; then :
12349 $as_echo_n "(cached) " >&6
12352 if test "$cross_compiling" = yes; then :
12353 gl_cv_func_working_utimes=no
12355 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12356 /* end confdefs.h. */
12358 #include <sys/types.h>
12359 #include <sys/stat.h>
12361 #include <sys/time.h>
12363 #include <unistd.h>
12364 #include <stdlib.h>
12371 static struct timeval timeval[2] = {{9, 10}, {999999, 999999}};
12373 char const *file = "conftest.utimes";
12378 int ok = ((f = fopen (file, "w"))
12380 && utimes (file, timeval) == 0
12381 && lstat (file, &sbuf) == 0
12382 && sbuf.st_atime == timeval[0].tv_sec
12383 && sbuf.st_mtime == timeval[1].tv_sec);
12389 ((f = fopen (file, "w"))
12391 && time (&now) != (time_t)-1
12392 && utimes (file, NULL) == 0
12393 && lstat (file, &sbuf) == 0
12394 && now - sbuf.st_atime <= 2
12395 && now - sbuf.st_mtime <= 2);
12400 ok = (0 <= (fd = open (file, O_WRONLY|O_CREAT, 0444))
12402 && utimes (file, NULL) == 0);
12409 if ac_fn_c_try_run "$LINENO"; then :
12410 gl_cv_func_working_utimes=yes
12412 gl_cv_func_working_utimes=no
12414 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12415 conftest.$ac_objext conftest.beam conftest.$ac_ext
12419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_utimes" >&5
12420 $as_echo "$gl_cv_func_working_utimes" >&6; }
12422 if test $gl_cv_func_working_utimes = yes; then
12424 $as_echo "#define HAVE_WORKING_UTIMES 1" >>confdefs.h
12432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
12433 $as_echo_n "checking for struct utimbuf... " >&6; }
12434 if test "${gl_cv_sys_struct_utimbuf+set}" = set; then :
12435 $as_echo_n "(cached) " >&6
12437 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12438 /* end confdefs.h. */
12439 #if HAVE_SYS_TIME_H
12440 #include <sys/time.h>
12443 #ifdef HAVE_UTIME_H
12450 static struct utimbuf x; x.actime = x.modtime;
12455 if ac_fn_c_try_compile "$LINENO"; then :
12456 gl_cv_sys_struct_utimbuf=yes
12458 gl_cv_sys_struct_utimbuf=no
12460 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_utimbuf" >&5
12463 $as_echo "$gl_cv_sys_struct_utimbuf" >&6; }
12465 if test $gl_cv_sys_struct_utimbuf = yes; then
12467 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
12482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <wchar.h> uses 'inline' correctly" >&5
12483 $as_echo_n "checking whether <wchar.h> uses 'inline' correctly... " >&6; }
12484 if test "${gl_cv_header_wchar_h_correct_inline+set}" = set; then :
12485 $as_echo_n "(cached) " >&6
12487 gl_cv_header_wchar_h_correct_inline=yes
12488 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12489 /* end confdefs.h. */
12491 #define wcstod renamed_wcstod
12493 extern int zero (void);
12494 int main () { return zero(); }
12497 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
12498 (eval $ac_compile) 2>&5
12500 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
12501 test $ac_status = 0; }; then
12502 mv conftest.$ac_objext conftest1.$ac_objext
12503 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12504 /* end confdefs.h. */
12506 #define wcstod renamed_wcstod
12508 int zero (void) { return 0; }
12511 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
12512 (eval $ac_compile) 2>&5
12514 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
12515 test $ac_status = 0; }; then
12516 mv conftest.$ac_objext conftest2.$ac_objext
12517 if $CC -o conftest$ac_exeext $CFLAGS $LDFLAGS conftest1.$ac_objext conftest2.$ac_objext $LIBS >&5 2>&1; then
12520 gl_cv_header_wchar_h_correct_inline=no
12524 rm -f conftest1.$ac_objext conftest2.$ac_objext conftest$ac_exeext
12527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_wchar_h_correct_inline" >&5
12528 $as_echo "$gl_cv_header_wchar_h_correct_inline" >&6; }
12529 if test $gl_cv_header_wchar_h_correct_inline = no; then
12530 as_fn_error "<wchar.h> cannot be used with this compiler ($CC $CFLAGS $CPPFLAGS).
12531 This is a known interoperability problem of glibc <= 2.5 with gcc >= 4.3 in
12532 C99 mode. You have four options:
12533 - Add the flag -fgnu89-inline to CC and reconfigure, or
12534 - Fix your include files, using parts of
12535 <http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=b037a293a48718af30d706c2e18c929d0e69a621>, or
12536 - Use a gcc version older than 4.3, or
12537 - Don't use the flags -std=c99 or -std=gnu99.
12538 Configuration aborted." "$LINENO" 5
12547 GL_COND_LIBTOOL_TRUE=
12548 GL_COND_LIBTOOL_FALSE='#'
12550 GL_COND_LIBTOOL_TRUE='#'
12551 GL_COND_LIBTOOL_FALSE=
12554 gl_cond_libtool=false
12566 gl_source_base='lib'
12572 if test $ac_cv_func_alloca_works = no; then
12576 # Define an additional variable used in the Makefile substitution.
12577 if test $ac_cv_working_alloca_h = yes; then
12578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
12579 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
12580 if test "${gl_cv_rpl_alloca+set}" = set; then :
12581 $as_echo_n "(cached) " >&6
12584 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12585 /* end confdefs.h. */
12587 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
12592 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12593 $EGREP "Need own alloca" >/dev/null 2>&1; then :
12594 gl_cv_rpl_alloca=yes
12596 gl_cv_rpl_alloca=no
12602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
12603 $as_echo "$gl_cv_rpl_alloca" >&6; }
12604 if test $gl_cv_rpl_alloca = yes; then
12606 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
12617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible calloc" >&5
12618 $as_echo_n "checking for GNU libc compatible calloc... " >&6; }
12619 if test "${ac_cv_func_calloc_0_nonnull+set}" = set; then :
12620 $as_echo_n "(cached) " >&6
12622 if test "$cross_compiling" = yes; then :
12623 ac_cv_func_calloc_0_nonnull=no
12625 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12626 /* end confdefs.h. */
12627 $ac_includes_default
12631 exit (!calloc (0, 0) || calloc ((size_t) -1 / 8 + 1, 8));
12636 if ac_fn_c_try_run "$LINENO"; then :
12637 ac_cv_func_calloc_0_nonnull=yes
12639 ac_cv_func_calloc_0_nonnull=no
12641 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12642 conftest.$ac_objext conftest.beam conftest.$ac_ext
12646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_calloc_0_nonnull" >&5
12647 $as_echo "$ac_cv_func_calloc_0_nonnull" >&6; }
12648 if test $ac_cv_func_calloc_0_nonnull = yes; then :
12650 $as_echo "#define HAVE_CALLOC 1" >>confdefs.h
12653 $as_echo "#define HAVE_CALLOC 0" >>confdefs.h
12663 gl_LIBOBJS="$gl_LIBOBJS calloc.$ac_objext"
12666 $as_echo "#define calloc rpl_calloc" >>confdefs.h
12673 if test $gl_cv_func_malloc_posix = yes; then
12674 HAVE_CALLOC_POSIX=1
12676 $as_echo "#define HAVE_CALLOC_POSIX 1" >>confdefs.h
12687 gl_LIBOBJS="$gl_LIBOBJS calloc.$ac_objext"
12689 HAVE_CALLOC_POSIX=0
12695 GNULIB_CALLOC_POSIX=1
12698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether this system has an arbitrary file name length limit" >&5
12699 $as_echo_n "checking whether this system has an arbitrary file name length limit... " >&6; }
12700 if test "${gl_cv_have_arbitrary_file_name_length_limit+set}" = set; then :
12701 $as_echo_n "(cached) " >&6
12703 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12704 /* end confdefs.h. */
12705 #include <unistd.h>
12706 #include <limits.h>
12707 #if defined PATH_MAX || defined MAXPATHLEN
12708 have_arbitrary_file_name_length_limit
12711 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12712 $EGREP "have_arbitrary_file_name_length_limit" >/dev/null 2>&1; then :
12713 gl_cv_have_arbitrary_file_name_length_limit=yes
12715 gl_cv_have_arbitrary_file_name_length_limit=no
12720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_arbitrary_file_name_length_limit" >&5
12721 $as_echo "$gl_cv_have_arbitrary_file_name_length_limit" >&6; }
12723 if test $gl_cv_have_arbitrary_file_name_length_limit = yes; then
12732 gl_LIBOBJS="$gl_LIBOBJS chdir-long.$ac_objext"
12748 # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
12749 # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
12751 # Save and restore LIBS so e.g., -lrt, isn't added to it. Otherwise, *all*
12752 # programs in the package would end up linked with that potentially-shared
12753 # library, inducing unnecessary run-time overhead.
12756 gl_saved_libs=$LIBS
12757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
12758 $as_echo_n "checking for library containing clock_gettime... " >&6; }
12759 if test "${ac_cv_search_clock_gettime+set}" = set; then :
12760 $as_echo_n "(cached) " >&6
12762 ac_func_search_save_LIBS=$LIBS
12763 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12764 /* end confdefs.h. */
12766 /* Override any GCC internal prototype to avoid an error.
12767 Use char because int might match the return type of a GCC
12768 builtin and then its argument prototype would still apply. */
12772 char clock_gettime ();
12776 return clock_gettime ();
12781 for ac_lib in '' rt posix4; do
12782 if test -z "$ac_lib"; then
12783 ac_res="none required"
12786 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
12788 if ac_fn_c_try_link "$LINENO"; then :
12789 ac_cv_search_clock_gettime=$ac_res
12791 rm -f core conftest.err conftest.$ac_objext \
12793 if test "${ac_cv_search_clock_gettime+set}" = set; then :
12797 if test "${ac_cv_search_clock_gettime+set}" = set; then :
12800 ac_cv_search_clock_gettime=no
12802 rm conftest.$ac_ext
12803 LIBS=$ac_func_search_save_LIBS
12805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
12806 $as_echo "$ac_cv_search_clock_gettime" >&6; }
12807 ac_res=$ac_cv_search_clock_gettime
12808 if test "$ac_res" != no; then :
12809 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
12810 test "$ac_cv_search_clock_gettime" = "none required" ||
12811 LIB_CLOCK_GETTIME=$ac_cv_search_clock_gettime
12814 for ac_func in clock_gettime clock_settime
12816 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
12817 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
12818 eval as_val=\$$as_ac_var
12819 if test "x$as_val" = x""yes; then :
12820 cat >>confdefs.h <<_ACEOF
12821 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
12827 LIBS=$gl_saved_libs
12845 gl_LIBOBJS="$gl_LIBOBJS close-stream.$ac_objext"
12852 $as_echo "#define GNULIB_CLOSE_STREAM 1" >>confdefs.h
12864 gl_LIBOBJS="$gl_LIBOBJS closein.$ac_objext"
12878 gl_LIBOBJS="$gl_LIBOBJS closeout.$ac_objext"
12883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for d_ino member in directory struct" >&5
12884 $as_echo_n "checking for d_ino member in directory struct... " >&6; }
12885 if test "${gl_cv_struct_dirent_d_ino+set}" = set; then :
12886 $as_echo_n "(cached) " >&6
12888 if test "$cross_compiling" = yes; then :
12889 gl_cv_struct_dirent_d_ino=no
12891 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12892 /* end confdefs.h. */
12893 #include <sys/types.h>
12894 #include <sys/stat.h>
12895 #include <dirent.h>
12900 DIR *dp = opendir (".");
12907 && stat (e->d_name, &st) == 0
12908 && e->d_ino == st.st_ino);
12913 if ac_fn_c_try_run "$LINENO"; then :
12914 gl_cv_struct_dirent_d_ino=yes
12916 gl_cv_struct_dirent_d_ino=no
12918 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12919 conftest.$ac_objext conftest.beam conftest.$ac_ext
12923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_struct_dirent_d_ino" >&5
12924 $as_echo "$gl_cv_struct_dirent_d_ino" >&6; }
12925 if test $gl_cv_struct_dirent_d_ino = yes; then
12927 $as_echo "#define D_INO_IN_DIRENT 1" >>confdefs.h
12941 if test $gl_cv_have_include_next = yes; then
12942 gl_cv_next_dirent_h='<'dirent.h'>'
12944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <dirent.h>" >&5
12945 $as_echo_n "checking absolute name of <dirent.h>... " >&6; }
12946 if test "${gl_cv_next_dirent_h+set}" = set; then :
12947 $as_echo_n "(cached) " >&6
12950 if test $ac_cv_header_dirent_h = yes; then
12951 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12952 /* end confdefs.h. */
12953 #include <dirent.h>
12957 aix*) gl_absname_cpp="$ac_cpp -C" ;;
12958 *) gl_absname_cpp="$ac_cpp" ;;
12960 gl_cv_next_dirent_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
12961 sed -n '\#/dirent.h#{
12962 s#.*"\(.*/dirent.h\)".*#\1#
12968 gl_cv_next_dirent_h='<'dirent.h'>'
12972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_dirent_h" >&5
12973 $as_echo "$gl_cv_next_dirent_h" >&6; }
12975 NEXT_DIRENT_H=$gl_cv_next_dirent_h
12977 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
12978 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
12979 gl_next_as_first_directive='<'dirent.h'>'
12981 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
12982 gl_next_as_first_directive=$gl_cv_next_dirent_h
12984 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H=$gl_next_as_first_directive
13000 for ac_func in dirfd
13002 ac_fn_c_check_func "$LINENO" "dirfd" "ac_cv_func_dirfd"
13003 if test "x$ac_cv_func_dirfd" = x""yes; then :
13004 cat >>confdefs.h <<_ACEOF
13005 #define HAVE_DIRFD 1
13011 ac_fn_c_check_decl "$LINENO" "dirfd" "ac_cv_have_decl_dirfd" "#include <sys/types.h>
13012 #include <dirent.h>
13014 if test "x$ac_cv_have_decl_dirfd" = x""yes; then :
13020 cat >>confdefs.h <<_ACEOF
13021 #define HAVE_DECL_DIRFD $ac_have_decl
13024 if test $ac_cv_have_decl_dirfd = no; then
13028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dirfd is a macro" >&5
13029 $as_echo_n "checking whether dirfd is a macro... " >&6; }
13030 if test "${gl_cv_func_dirfd_macro+set}" = set; then :
13031 $as_echo_n "(cached) " >&6
13033 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13034 /* end confdefs.h. */
13036 #include <sys/types.h>
13037 #include <dirent.h>
13039 dirent_header_defines_dirfd
13042 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13043 $EGREP "dirent_header_defines_dirfd" >/dev/null 2>&1; then :
13044 gl_cv_func_dirfd_macro=yes
13046 gl_cv_func_dirfd_macro=no
13051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dirfd_macro" >&5
13052 $as_echo "$gl_cv_func_dirfd_macro" >&6; }
13054 # Use the replacement only if we have no function, macro,
13055 # or declaration with that name.
13056 if test $ac_cv_func_dirfd,$ac_cv_have_decl_dirfd,$gl_cv_func_dirfd_macro \
13066 for ac_func in dirfd
13068 ac_fn_c_check_func "$LINENO" "dirfd" "ac_cv_func_dirfd"
13069 if test "x$ac_cv_func_dirfd" = x""yes; then :
13070 cat >>confdefs.h <<_ACEOF
13071 #define HAVE_DIRFD 1
13076 gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
13082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to get the file descriptor associated with an open DIR*" >&5
13083 $as_echo_n "checking how to get the file descriptor associated with an open DIR*... " >&6; }
13084 if test "${gl_cv_sys_dir_fd_member_name+set}" = set; then :
13085 $as_echo_n "(cached) " >&6
13088 dirfd_save_CFLAGS=$CFLAGS
13089 for ac_expr in d_fd dd_fd; do
13091 CFLAGS="$CFLAGS -DDIR_FD_MEMBER_NAME=$ac_expr"
13092 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13093 /* end confdefs.h. */
13095 #include <sys/types.h>
13096 #include <dirent.h>
13100 DIR *dir_p = opendir("."); (void) dir_p->DIR_FD_MEMBER_NAME;
13105 if ac_fn_c_try_compile "$LINENO"; then :
13109 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13110 CFLAGS=$dirfd_save_CFLAGS
13111 test "$dir_fd_found" = yes && break
13113 test "$dir_fd_found" = yes || ac_expr=no_such_member
13115 gl_cv_sys_dir_fd_member_name=$ac_expr
13119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_dir_fd_member_name" >&5
13120 $as_echo "$gl_cv_sys_dir_fd_member_name" >&6; }
13121 if test $gl_cv_sys_dir_fd_member_name != no_such_member; then
13123 cat >>confdefs.h <<_ACEOF
13124 #define DIR_FD_MEMBER_NAME $gl_cv_sys_dir_fd_member_name
13144 gl_LIBOBJS="$gl_LIBOBJS basename-lgpl.$ac_objext"
13154 gl_LIBOBJS="$gl_LIBOBJS dirname-lgpl.$ac_objext"
13164 gl_LIBOBJS="$gl_LIBOBJS stripslash.$ac_objext"
13173 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether // is distinct from /" >&5
13174 $as_echo_n "checking whether // is distinct from /... " >&6; }
13175 if test "${gl_cv_double_slash_root+set}" = set; then :
13176 $as_echo_n "(cached) " >&6
13178 if test x"$cross_compiling" = xyes ; then
13179 # When cross-compiling, there is no way to tell whether // is special
13180 # short of a list of hosts. However, the only known hosts to date
13181 # that have a distinct // are Apollo DomainOS (too old to port to),
13182 # Cygwin, and z/OS. If anyone knows of another system for which // has
13183 # special semantics and is distinct from /, please report it to
13184 # <bug-gnulib@gnu.org>.
13186 *-cygwin | i370-ibm-openedition)
13187 gl_cv_double_slash_root=yes ;;
13189 # Be optimistic and assume that / and // are the same when we
13191 gl_cv_double_slash_root='unknown, assuming no' ;;
13194 set x `ls -di / // 2>/dev/null`
13195 if test "$2" = "$4" && wc //dev/null >/dev/null 2>&1; then
13196 gl_cv_double_slash_root=no
13198 gl_cv_double_slash_root=yes
13202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_double_slash_root" >&5
13203 $as_echo "$gl_cv_double_slash_root" >&6; }
13204 if test "$gl_cv_double_slash_root" = yes; then
13206 $as_echo "#define DOUBLE_SLASH_IS_DISTINCT_ROOT 1" >>confdefs.h
13214 if test $ac_cv_func_dup2 = no; then
13224 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
13227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
13228 $as_echo_n "checking whether dup2 works... " >&6; }
13229 if test "${gl_cv_func_dup2_works+set}" = set; then :
13230 $as_echo_n "(cached) " >&6
13232 if test "$cross_compiling" = yes; then :
13234 mingw*) # on this platform, dup2 always returns 0 for success
13235 gl_cv_func_dup2_works=no;;
13236 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
13237 gl_cv_func_dup2_works=no;;
13238 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
13239 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
13240 gl_cv_func_dup2_works=no;;
13241 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
13242 gl_cv_func_dup2_works=no;;
13243 *) gl_cv_func_dup2_works=yes;;
13246 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13247 /* end confdefs.h. */
13249 #include <unistd.h>
13254 if (dup2 (1, 1) == 0)
13257 if (dup2 (0, 0) != -1)
13259 /* Many gnulib modules require POSIX conformance of EBADF. */
13260 if (dup2 (1, 1000000) == -1 && errno != EBADF)
13269 if ac_fn_c_try_run "$LINENO"; then :
13270 gl_cv_func_dup2_works=yes
13272 gl_cv_func_dup2_works=no
13274 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13275 conftest.$ac_objext conftest.beam conftest.$ac_ext
13280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
13281 $as_echo "$gl_cv_func_dup2_works" >&6; }
13282 if test "$gl_cv_func_dup2_works" = no; then
13285 if test $ac_cv_func_dup2 = yes; then
13296 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
13320 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for error_at_line" >&5
13321 $as_echo_n "checking for error_at_line... " >&6; }
13322 if test "${ac_cv_lib_error_at_line+set}" = set; then :
13323 $as_echo_n "(cached) " >&6
13325 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13326 /* end confdefs.h. */
13331 error_at_line (0, 0, "", 0, "an error occurred");
13336 if ac_fn_c_try_link "$LINENO"; then :
13337 ac_cv_lib_error_at_line=yes
13339 ac_cv_lib_error_at_line=no
13341 rm -f core conftest.err conftest.$ac_objext \
13342 conftest$ac_exeext conftest.$ac_ext
13344 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_error_at_line" >&5
13345 $as_echo "$ac_cv_lib_error_at_line" >&6; }
13346 if test $ac_cv_lib_error_at_line = no; then
13355 gl_LIBOBJS="$gl_LIBOBJS error.$ac_objext"
13367 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=error:3:c-format"
13371 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=error_at_line:5:c-format"
13382 gl_LIBOBJS="$gl_LIBOBJS exitfail.$ac_objext"
13392 if test $ac_cv_func_fchdir = no; then
13402 gl_LIBOBJS="$gl_LIBOBJS fchdir.$ac_objext"
13406 $as_echo "#define REPLACE_FCHDIR 1" >>confdefs.h
13422 gl_LIBOBJS="$gl_LIBOBJS open.$ac_objext"
13441 gl_LIBOBJS="$gl_LIBOBJS close.$ac_objext"
13454 gl_LIBOBJS="$gl_LIBOBJS fclose.$ac_objext"
13460 if test $ac_cv_func_dup2 = yes; then
13471 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
13477 if test $ac_cv_func_fcntl = no; then
13490 gl_LIBOBJS="$gl_LIBOBJS fcntl.$ac_objext"
13496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether open can visit directories" >&5
13497 $as_echo_n "checking whether open can visit directories... " >&6; }
13498 if test "${gl_cv_func_open_directory_works+set}" = set; then :
13499 $as_echo_n "(cached) " >&6
13501 if test "$cross_compiling" = yes; then :
13502 gl_cv_func_open_directory_works="guessing no"
13504 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13505 /* end confdefs.h. */
13511 return open(".", O_RDONLY) < 0;
13516 if ac_fn_c_try_run "$LINENO"; then :
13517 gl_cv_func_open_directory_works=yes
13519 gl_cv_func_open_directory_works=no
13521 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13522 conftest.$ac_objext conftest.beam conftest.$ac_ext
13526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_open_directory_works" >&5
13527 $as_echo "$gl_cv_func_open_directory_works" >&6; }
13528 if test "$gl_cv_func_open_directory_works" != yes; then
13530 $as_echo "#define REPLACE_OPEN_DIRECTORY 1" >>confdefs.h
13551 if test $ac_cv_func_fcntl = no; then
13555 if test $ac_cv_func_fcntl = no; then
13568 gl_LIBOBJS="$gl_LIBOBJS fcntl.$ac_objext"
13572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl handles F_DUPFD correctly" >&5
13573 $as_echo_n "checking whether fcntl handles F_DUPFD correctly... " >&6; }
13574 if test "${gl_cv_func_fcntl_f_dupfd_works+set}" = set; then :
13575 $as_echo_n "(cached) " >&6
13577 if test "$cross_compiling" = yes; then :
13578 # Guess that it works on glibc systems
13579 case $host_os in #((
13580 *-gnu*) gl_cv_func_fcntl_f_dupfd_works="guessing yes";;
13581 *) gl_cv_func_fcntl_f_dupfd_works="guessing no";;
13584 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13585 /* end confdefs.h. */
13592 return fcntl (0, F_DUPFD, -1) != -1;
13598 if ac_fn_c_try_run "$LINENO"; then :
13599 gl_cv_func_fcntl_f_dupfd_works=yes
13601 gl_cv_func_fcntl_f_dupfd_works=no
13603 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13604 conftest.$ac_objext conftest.beam conftest.$ac_ext
13608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_works" >&5
13609 $as_echo "$gl_cv_func_fcntl_f_dupfd_works" >&6; }
13610 case $gl_cv_func_fcntl_f_dupfd_works in
13615 if test $ac_cv_func_fcntl = no; then
13628 gl_LIBOBJS="$gl_LIBOBJS fcntl.$ac_objext"
13632 $as_echo "#define FCNTL_DUPFD_BUGGY 1" >>confdefs.h
13636 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl understands F_DUPFD_CLOEXEC" >&5
13637 $as_echo_n "checking whether fcntl understands F_DUPFD_CLOEXEC... " >&6; }
13638 if test "${gl_cv_func_fcntl_f_dupfd_cloexec+set}" = set; then :
13639 $as_echo_n "(cached) " >&6
13641 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13642 /* end confdefs.h. */
13645 #ifndef F_DUPFD_CLOEXEC
13657 if ac_fn_c_try_compile "$LINENO"; then :
13658 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13659 /* end confdefs.h. */
13662 /* The Linux kernel only added F_DUPFD_CLOEXEC in 2.6.24, so we always replace
13663 it to support the semantics on older kernels that failed with EINVAL. */
13675 if ac_fn_c_try_compile "$LINENO"; then :
13676 gl_cv_func_fcntl_f_dupfd_cloexec=yes
13678 gl_cv_func_fcntl_f_dupfd_cloexec="needs runtime check"
13680 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13682 gl_cv_func_fcntl_f_dupfd_cloexec=no
13684 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_cloexec" >&5
13687 $as_echo "$gl_cv_func_fcntl_f_dupfd_cloexec" >&6; }
13688 if test "$gl_cv_func_fcntl_f_dupfd_cloexec" != yes; then
13692 if test $ac_cv_func_fcntl = no; then
13705 gl_LIBOBJS="$gl_LIBOBJS fcntl.$ac_objext"
13724 if test $gl_cv_have_include_next = yes; then
13725 gl_cv_next_fcntl_h='<'fcntl.h'>'
13727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <fcntl.h>" >&5
13728 $as_echo_n "checking absolute name of <fcntl.h>... " >&6; }
13729 if test "${gl_cv_next_fcntl_h+set}" = set; then :
13730 $as_echo_n "(cached) " >&6
13733 if test $ac_cv_header_fcntl_h = yes; then
13734 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13735 /* end confdefs.h. */
13740 aix*) gl_absname_cpp="$ac_cpp -C" ;;
13741 *) gl_absname_cpp="$ac_cpp" ;;
13743 gl_cv_next_fcntl_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
13744 sed -n '\#/fcntl.h#{
13745 s#.*"\(.*/fcntl.h\)".*#\1#
13751 gl_cv_next_fcntl_h='<'fcntl.h'>'
13755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_fcntl_h" >&5
13756 $as_echo "$gl_cv_next_fcntl_h" >&6; }
13758 NEXT_FCNTL_H=$gl_cv_next_fcntl_h
13760 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
13761 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
13762 gl_next_as_first_directive='<'fcntl.h'>'
13764 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
13765 gl_next_as_first_directive=$gl_cv_next_fcntl_h
13767 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H=$gl_next_as_first_directive
13781 gl_LIBOBJS="$gl_LIBOBJS open-safer.$ac_objext"
13791 gl_LIBOBJS="$gl_LIBOBJS creat-safer.$ac_objext"
13793 # Prerequisites of lib/open-safer.c.
13798 $as_echo "#define GNULIB_FCNTL_SAFER 1" >>confdefs.h
13804 if test $ac_cv_func_fdopendir = no; then
13813 gl_LIBOBJS="$gl_LIBOBJS openat-proc.$ac_objext"
13823 gl_LIBOBJS="$gl_LIBOBJS fdopendir.$ac_objext"
13830 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fdopendir works" >&5
13831 $as_echo_n "checking whether fdopendir works... " >&6; }
13832 if test "${gl_cv_func_fdopendir_works+set}" = set; then :
13833 $as_echo_n "(cached) " >&6
13835 if test "$cross_compiling" = yes; then :
13836 gl_cv_func_fdopendir_works="guessing no"
13838 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13839 /* end confdefs.h. */
13841 #include <dirent.h>
13847 int fd = open ("conftest.c", O_RDONLY);
13848 if (fd < 0) return 2;
13849 return !!fdopendir (fd);
13854 if ac_fn_c_try_run "$LINENO"; then :
13855 gl_cv_func_fdopendir_works=yes
13857 gl_cv_func_fdopendir_works=no
13859 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13860 conftest.$ac_objext conftest.beam conftest.$ac_ext
13864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fdopendir_works" >&5
13865 $as_echo "$gl_cv_func_fdopendir_works" >&6; }
13866 if test "$gl_cv_func_fdopendir_works" != yes; then
13867 REPLACE_FDOPENDIR=1
13879 gl_LIBOBJS="$gl_LIBOBJS fdopendir.$ac_objext"
13889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fflush works on input streams" >&5
13890 $as_echo_n "checking whether fflush works on input streams... " >&6; }
13891 if test "${gl_cv_func_fflush_stdin+set}" = set; then :
13892 $as_echo_n "(cached) " >&6
13894 echo hello world > conftest.txt
13895 if test "$cross_compiling" = yes; then :
13896 gl_cv_func_fflush_stdin=no
13898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13899 /* end confdefs.h. */
13902 #include <unistd.h>
13907 FILE *f = fopen ("conftest.txt", "r");
13914 if (fd < 0 || fread (buffer, 1, 5, f) != 5)
13916 /* For deterministic results, ensure f read a bigger buffer. */
13917 if (lseek (fd, 0, SEEK_CUR) == 5)
13919 /* POSIX requires fflush-fseek to set file offset of fd. This fails
13920 on BSD systems and on mingw. */
13921 if (fflush (f) != 0 || fseek (f, 0, SEEK_CUR) != 0)
13923 if (lseek (fd, 0, SEEK_CUR) != 5)
13925 /* Verify behaviour of fflush after ungetc. See
13926 <http://www.opengroup.org/austin/aardvark/latest/xshbug3.txt> */
13927 /* Verify behaviour of fflush after a backup ungetc. This fails on
13932 if (fgetc (f) != c)
13934 /* Verify behaviour of fflush after a non-backup ungetc. This fails
13935 on glibc 2.8 and on BSD systems. */
13939 if (fgetc (f) != c)
13947 if ac_fn_c_try_run "$LINENO"; then :
13948 gl_cv_func_fflush_stdin=yes
13950 gl_cv_func_fflush_stdin=no
13952 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13953 conftest.$ac_objext conftest.beam conftest.$ac_ext
13959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fflush_stdin" >&5
13960 $as_echo "$gl_cv_func_fflush_stdin" >&6; }
13961 if test $gl_cv_func_fflush_stdin = no; then
13971 gl_LIBOBJS="$gl_LIBOBJS fflush.$ac_objext"
13981 gl_LIBOBJS="$gl_LIBOBJS fseeko.$ac_objext"
14010 if test $gl_cv_have_include_next = yes; then
14011 gl_cv_next_float_h='<'float.h'>'
14013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <float.h>" >&5
14014 $as_echo_n "checking absolute name of <float.h>... " >&6; }
14015 if test "${gl_cv_next_float_h+set}" = set; then :
14016 $as_echo_n "(cached) " >&6
14019 if test $ac_cv_header_float_h = yes; then
14020 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14021 /* end confdefs.h. */
14026 aix*) gl_absname_cpp="$ac_cpp -C" ;;
14027 *) gl_absname_cpp="$ac_cpp" ;;
14029 gl_cv_next_float_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
14030 sed -n '\#/float.h#{
14031 s#.*"\(.*/float.h\)".*#\1#
14037 gl_cv_next_float_h='<'float.h'>'
14041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_float_h" >&5
14042 $as_echo "$gl_cv_next_float_h" >&6; }
14044 NEXT_FLOAT_H=$gl_cv_next_float_h
14046 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
14047 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
14048 gl_next_as_first_directive='<'float.h'>'
14050 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
14051 gl_next_as_first_directive=$gl_cv_next_float_h
14053 NEXT_AS_FIRST_DIRECTIVE_FLOAT_H=$gl_next_as_first_directive
14065 # include <stdio.h>
14066 # if HAVE_STDIO_EXT_H
14067 # include <stdio_ext.h>
14070 ac_fn_c_check_decl "$LINENO" "__fpending" "ac_cv_have_decl___fpending" "$fp_headers
14072 if test "x$ac_cv_have_decl___fpending" = x""yes; then :
14078 cat >>confdefs.h <<_ACEOF
14079 #define HAVE_DECL___FPENDING $ac_have_decl
14082 if test $ac_cv_func___fpending = no; then
14083 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to determine the number of pending output bytes on a stream" >&5
14084 $as_echo_n "checking how to determine the number of pending output bytes on a stream... " >&6; }
14085 if test "${ac_cv_sys_pending_output_n_bytes+set}" = set; then :
14086 $as_echo_n "(cached) " >&6
14092 'fp->_IO_write_ptr - fp->_IO_write_base' \
14094 '# traditional Unix' \
14095 'fp->_ptr - fp->_base' \
14098 'fp->_p - fp->_bf._base' \
14100 '# SCO, Unixware' \
14101 '(fp->__ptr ? fp->__ptr - fp->__base : 0)' \
14104 '(fp->_Mode & 0x2000 /*_MWRITE*/ ? fp->_Next - fp->_Buf : 0)' \
14107 'fp->__bufp - fp->__buffer' \
14109 '# old glibc iostream?' \
14110 'fp->_pptr - fp->_pbase' \
14113 'fp->_ptr - fp->_buffer' \
14116 '(*fp)->_ptr - (*fp)->_base' \
14118 '# e.g., DGUX R4.11; the info is not available' \
14122 # Skip each embedded comment.
14123 case "$ac_expr" in '#'*) continue;; esac
14125 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14126 /* end confdefs.h. */
14131 FILE *fp = stdin; (void) ($ac_expr);
14136 if ac_fn_c_try_compile "$LINENO"; then :
14140 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14141 test "$fp_done" = yes && break
14144 ac_cv_sys_pending_output_n_bytes=$ac_expr
14148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_pending_output_n_bytes" >&5
14149 $as_echo "$ac_cv_sys_pending_output_n_bytes" >&6; }
14151 cat >>confdefs.h <<_ACEOF
14152 #define PENDING_OUTPUT_N_BYTES $ac_cv_sys_pending_output_n_bytes
14163 gl_LIBOBJS="$gl_LIBOBJS fpending.$ac_objext"
14182 gl_cv_func_fprintf_posix=no
14183 case "$gl_cv_func_printf_sizes_c99" in
14185 case "$gl_cv_func_printf_long_double" in
14187 case "$gl_cv_func_printf_infinite" in
14189 case "$gl_cv_func_printf_infinite_long_double" in
14191 case "$gl_cv_func_printf_directive_a" in
14193 case "$gl_cv_func_printf_directive_f" in
14195 case "$gl_cv_func_printf_directive_n" in
14197 case "$gl_cv_func_printf_directive_ls" in
14199 case "$gl_cv_func_printf_positions" in
14201 case "$gl_cv_func_printf_flag_grouping" in
14203 case "$gl_cv_func_printf_flag_leftadjust" in
14205 case "$gl_cv_func_printf_flag_zero" in
14207 case "$gl_cv_func_printf_precision" in
14209 case "$gl_cv_func_printf_enomem" in
14211 # fprintf exists and is
14212 # already POSIX compliant.
14213 gl_cv_func_fprintf_posix=yes
14242 if test $gl_cv_func_fprintf_posix = no; then
14246 case "$gl_cv_func_printf_infinite" in
14251 $as_echo "#define NEED_PRINTF_INFINITE_DOUBLE 1" >>confdefs.h
14259 case "$gl_cv_func_printf_long_double" in
14261 case "$gl_cv_func_printf_infinite_long_double" in
14266 $as_echo "#define NEED_PRINTF_INFINITE_LONG_DOUBLE 1" >>confdefs.h
14275 case "$gl_cv_func_printf_directive_a" in
14280 $as_echo "#define NEED_PRINTF_DIRECTIVE_A 1" >>confdefs.h
14282 for ac_func in nl_langinfo
14284 ac_fn_c_check_func "$LINENO" "nl_langinfo" "ac_cv_func_nl_langinfo"
14285 if test "x$ac_cv_func_nl_langinfo" = x""yes; then :
14286 cat >>confdefs.h <<_ACEOF
14287 #define HAVE_NL_LANGINFO 1
14298 case "$gl_cv_func_printf_directive_f" in
14303 $as_echo "#define NEED_PRINTF_DIRECTIVE_F 1" >>confdefs.h
14310 case "$gl_cv_func_printf_directive_ls" in
14315 $as_echo "#define NEED_PRINTF_DIRECTIVE_LS 1" >>confdefs.h
14322 case "$gl_cv_func_printf_flag_grouping" in
14327 $as_echo "#define NEED_PRINTF_FLAG_GROUPING 1" >>confdefs.h
14334 case "$gl_cv_func_printf_flag_leftadjust" in
14339 $as_echo "#define NEED_PRINTF_FLAG_LEFTADJUST 1" >>confdefs.h
14346 case "$gl_cv_func_printf_flag_zero" in
14351 $as_echo "#define NEED_PRINTF_FLAG_ZERO 1" >>confdefs.h
14358 case "$gl_cv_func_printf_precision" in
14363 $as_echo "#define NEED_PRINTF_UNBOUNDED_PRECISION 1" >>confdefs.h
14366 $as_echo "#define NEED_PRINTF_DOUBLE 1" >>confdefs.h
14369 $as_echo "#define NEED_PRINTF_LONG_DOUBLE 1" >>confdefs.h
14376 case "$gl_cv_func_printf_enomem" in
14381 $as_echo "#define NEED_PRINTF_ENOMEM 1" >>confdefs.h
14384 $as_echo "#define NEED_PRINTF_DOUBLE 1" >>confdefs.h
14387 $as_echo "#define NEED_PRINTF_LONG_DOUBLE 1" >>confdefs.h
14402 gl_LIBOBJS="$gl_LIBOBJS vasnprintf.$ac_objext"
14412 gl_LIBOBJS="$gl_LIBOBJS printf-args.$ac_objext"
14422 gl_LIBOBJS="$gl_LIBOBJS printf-parse.$ac_objext"
14432 gl_LIBOBJS="$gl_LIBOBJS asnprintf.$ac_objext"
14434 if test $ac_cv_func_vasnprintf = yes; then
14436 $as_echo "#define REPLACE_VASNPRINTF 1" >>confdefs.h
14449 ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
14450 if test "x$ac_cv_type_ptrdiff_t" = x""yes; then :
14454 $as_echo "#define ptrdiff_t long" >>confdefs.h
14475 gl_LIBOBJS="$gl_LIBOBJS fprintf.$ac_objext"
14479 $as_echo "#define REPLACE_FPRINTF_POSIX 1" >>confdefs.h
14487 GNULIB_FPRINTF_POSIX=1
14493 ac_fn_c_check_decl "$LINENO" "fpurge" "ac_cv_have_decl_fpurge" "#include <stdio.h>
14495 if test "x$ac_cv_have_decl_fpurge" = x""yes; then :
14501 cat >>confdefs.h <<_ACEOF
14502 #define HAVE_DECL_FPURGE $ac_have_decl
14505 if test "x$ac_cv_func_fpurge" = xyes; then
14506 # Detect BSD bug. Only cygwin 1.7 is known to be immune.
14507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fpurge works" >&5
14508 $as_echo_n "checking whether fpurge works... " >&6; }
14509 if test "${gl_cv_func_fpurge_works+set}" = set; then :
14510 $as_echo_n "(cached) " >&6
14512 if test "$cross_compiling" = yes; then :
14513 gl_cv_func_fpurge_works='guessing no'
14515 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14516 /* end confdefs.h. */
14522 FILE *f = fopen ("conftest.txt", "w+");
14524 if (fputc ('a', f) != 'a') return 2;
14526 if (fgetc (f) != 'a') return 3;
14527 if (fgetc (f) != EOF) return 4;
14528 if (fpurge (f) != 0) return 5;
14529 if (putc ('b', f) != 'b') return 6;
14530 if (fclose (f) != 0) return 7;
14531 if ((f = fopen ("conftest.txt", "r")) == NULL) return 8;
14532 if (fgetc (f) != 'a') return 9;
14533 if (fgetc (f) != 'b') return 10;
14534 if (fgetc (f) != EOF) return 11;
14535 if (fclose (f) != 0) return 12;
14536 if (remove ("conftest.txt") != 0) return 13;
14542 if ac_fn_c_try_run "$LINENO"; then :
14543 gl_cv_func_fpurge_works=yes
14545 gl_cv_func_fpurge_works=no
14547 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14548 conftest.$ac_objext conftest.beam conftest.$ac_ext
14552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fpurge_works" >&5
14553 $as_echo "$gl_cv_func_fpurge_works" >&6; }
14554 if test "x$gl_cv_func_fpurge_works" != xyes; then
14564 gl_LIBOBJS="$gl_LIBOBJS fpurge.$ac_objext"
14576 gl_LIBOBJS="$gl_LIBOBJS fpurge.$ac_objext"
14579 if test "x$ac_cv_have_decl_fpurge" = xno; then
14592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexp() can be used without linking with libm" >&5
14593 $as_echo_n "checking whether frexp() can be used without linking with libm... " >&6; }
14594 if test "${gl_cv_func_frexp_no_libm+set}" = set; then :
14595 $as_echo_n "(cached) " >&6
14598 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14599 /* end confdefs.h. */
14605 int e; return frexp (x, &e) > 0;
14610 if ac_fn_c_try_link "$LINENO"; then :
14611 gl_cv_func_frexp_no_libm=yes
14613 gl_cv_func_frexp_no_libm=no
14615 rm -f core conftest.err conftest.$ac_objext \
14616 conftest$ac_exeext conftest.$ac_ext
14619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexp_no_libm" >&5
14620 $as_echo "$gl_cv_func_frexp_no_libm" >&6; }
14621 if test $gl_cv_func_frexp_no_libm = yes; then
14624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexp works" >&5
14625 $as_echo_n "checking whether frexp works... " >&6; }
14626 if test "${gl_cv_func_frexp_works+set}" = set; then :
14627 $as_echo_n "(cached) " >&6
14630 if test "$cross_compiling" = yes; then :
14632 netbsd* | irix* | mingw*) gl_cv_func_frexp_works="guessing no";;
14633 *) gl_cv_func_frexp_works="guessing yes";;
14637 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14638 /* end confdefs.h. */
14642 #include <string.h>
14647 /* HP cc on HP-UX 10.20 has a bug with the constant expression -0.0.
14648 So we use -zero instead. */
14650 /* Test on denormalized numbers. */
14651 for (i = 1, x = 1.0; i >= DBL_MIN_EXP; i--, x *= 0.5)
14656 double y = frexp (x, &exp);
14657 /* On machines with IEEE754 arithmetic: x = 1.11254e-308, exp = -1022.
14658 On NetBSD: y = 0.75. Correct: y = 0.5. */
14662 /* Test on infinite numbers. */
14666 double y = frexp (x, &exp);
14670 /* Test on negative zero. */
14674 double y = frexp (x, &exp);
14675 if (memcmp (&y, &x, sizeof x))
14681 if ac_fn_c_try_run "$LINENO"; then :
14682 gl_cv_func_frexp_works=yes
14684 gl_cv_func_frexp_works=no
14686 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14687 conftest.$ac_objext conftest.beam conftest.$ac_ext
14692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexp_works" >&5
14693 $as_echo "$gl_cv_func_frexp_works" >&6; }
14695 case "$gl_cv_func_frexp_works" in
14696 *yes) gl_func_frexp_no_libm=yes ;;
14697 *) gl_func_frexp_no_libm=no; REPLACE_FREXP=1 ;;
14700 gl_func_frexp_no_libm=no
14703 if test $gl_func_frexp_no_libm = yes; then
14705 $as_echo "#define HAVE_FREXP_IN_LIBC 1" >>confdefs.h
14716 gl_LIBOBJS="$gl_LIBOBJS frexp.$ac_objext"
14726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexpl() can be used without linking with libm" >&5
14727 $as_echo_n "checking whether frexpl() can be used without linking with libm... " >&6; }
14728 if test "${gl_cv_func_frexpl_no_libm+set}" = set; then :
14729 $as_echo_n "(cached) " >&6
14732 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14733 /* end confdefs.h. */
14739 int e; return frexpl (x, &e) > 0;
14744 if ac_fn_c_try_link "$LINENO"; then :
14745 gl_cv_func_frexpl_no_libm=yes
14747 gl_cv_func_frexpl_no_libm=no
14749 rm -f core conftest.err conftest.$ac_objext \
14750 conftest$ac_exeext conftest.$ac_ext
14753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexpl_no_libm" >&5
14754 $as_echo "$gl_cv_func_frexpl_no_libm" >&6; }
14755 if test $gl_cv_func_frexpl_no_libm = yes; then
14758 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexpl works" >&5
14759 $as_echo_n "checking whether frexpl works... " >&6; }
14760 if test "${gl_cv_func_frexpl_works+set}" = set; then :
14761 $as_echo_n "(cached) " >&6
14764 if test "$cross_compiling" = yes; then :
14766 aix* | beos* | darwin* | irix* | mingw* | pw*)
14767 gl_cv_func_frexpl_works="guessing no";;
14768 *) gl_cv_func_frexpl_works="guessing yes";;
14772 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14773 /* end confdefs.h. */
14777 /* Override the values of <float.h>, like done in float.in.h. */
14778 #if defined __i386__ && (defined __BEOS__ || defined __OpenBSD__)
14779 # undef LDBL_MIN_EXP
14780 # define LDBL_MIN_EXP (-16381)
14782 extern long double frexpl (long double, int *);
14785 volatile long double x;
14786 /* Test on finite numbers that fails on AIX 5.1. */
14794 /* Test on finite numbers that fails on MacOS X 10.4, because its frexpl
14795 function returns an invalid (incorrectly normalized) value: it returns
14796 y = { 0x3fe028f5, 0xc28f5c28, 0x3c9eb851, 0xeb851eb8 }
14797 but the correct result is
14798 0.505L = { 0x3fe028f5, 0xc28f5c29, 0xbc547ae1, 0x47ae1480 } */
14802 long double y = frexpl (x, &exp);
14803 if (!(exp == 1 && y == 0.505L))
14806 /* Test on large finite numbers. This fails on BeOS at i = 16322, while
14807 LDBL_MAX_EXP = 16384.
14808 In the loop end test, we test x against Infinity, rather than comparing
14809 i with LDBL_MAX_EXP, because BeOS <float.h> has a wrong LDBL_MAX_EXP. */
14812 for (i = 1, x = 1.0L; x != x + x; i++, x *= 2.0L)
14820 /* Test on denormalized numbers. */
14823 for (i = 1, x = 1.0L; i >= LDBL_MIN_EXP; i--, x *= 0.5L)
14828 long double y = frexpl (x, &exp);
14829 /* On machines with IEEE854 arithmetic: x = 1.68105e-4932,
14830 exp = -16382, y = 0.5. On MacOS X 10.5: exp = -16384, y = 0.5. */
14831 if (exp != LDBL_MIN_EXP - 1)
14835 /* Test on infinite numbers. */
14839 long double y = frexpl (x, &exp);
14846 if ac_fn_c_try_run "$LINENO"; then :
14847 gl_cv_func_frexpl_works=yes
14849 gl_cv_func_frexpl_works=no
14851 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14852 conftest.$ac_objext conftest.beam conftest.$ac_ext
14857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexpl_works" >&5
14858 $as_echo "$gl_cv_func_frexpl_works" >&6; }
14860 case "$gl_cv_func_frexpl_works" in
14861 *yes) gl_func_frexpl_no_libm=yes ;;
14862 *) gl_func_frexpl_no_libm=no; REPLACE_FREXPL=1 ;;
14865 gl_func_frexpl_no_libm=no
14868 if test $gl_func_frexpl_no_libm = yes; then
14870 $as_echo "#define HAVE_FREXPL_IN_LIBC 1" >>confdefs.h
14872 ac_fn_c_check_decl "$LINENO" "frexpl" "ac_cv_have_decl_frexpl" "#include <math.h>
14874 if test "x$ac_cv_have_decl_frexpl" = x""yes; then :
14890 gl_LIBOBJS="$gl_LIBOBJS frexpl.$ac_objext"
14905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fseeko" >&5
14906 $as_echo_n "checking for fseeko... " >&6; }
14907 if test "${gl_cv_func_fseeko+set}" = set; then :
14908 $as_echo_n "(cached) " >&6
14911 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14912 /* end confdefs.h. */
14918 fseeko (stdin, 0, 0);
14923 if ac_fn_c_try_link "$LINENO"; then :
14924 gl_cv_func_fseeko=yes
14926 gl_cv_func_fseeko=no
14928 rm -f core conftest.err conftest.$ac_objext \
14929 conftest$ac_exeext conftest.$ac_ext
14932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fseeko" >&5
14933 $as_echo "$gl_cv_func_fseeko" >&6; }
14934 if test $gl_cv_func_fseeko = no \
14935 || test $gl_cv_var_stdin_large_offset = no; then
14945 gl_LIBOBJS="$gl_LIBOBJS fseeko.$ac_objext"
14964 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ftello" >&5
14965 $as_echo_n "checking for ftello... " >&6; }
14966 if test "${gl_cv_func_ftello+set}" = set; then :
14967 $as_echo_n "(cached) " >&6
14970 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14971 /* end confdefs.h. */
14981 if ac_fn_c_try_link "$LINENO"; then :
14982 gl_cv_func_ftello=yes
14984 gl_cv_func_ftello=no
14986 rm -f core conftest.err conftest.$ac_objext \
14987 conftest$ac_exeext conftest.$ac_ext
14990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_ftello" >&5
14991 $as_echo "$gl_cv_func_ftello" >&6; }
14992 if test $gl_cv_func_ftello = no \
14993 || test $gl_cv_var_stdin_large_offset = no; then
15003 gl_LIBOBJS="$gl_LIBOBJS ftello.$ac_objext"
15019 case $gl_cv_func_getcwd_null,$host_os in
15021 gl_cv_func_getcwd_path_max=yes;;
15026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getcwd handles long file names properly" >&5
15027 $as_echo_n "checking whether getcwd handles long file names properly... " >&6; }
15028 if test "${gl_cv_func_getcwd_path_max+set}" = set; then :
15029 $as_echo_n "(cached) " >&6
15031 # Arrange for deletion of the temporary directory this test creates.
15032 ac_clean_files="$ac_clean_files confdir3"
15033 if test "$cross_compiling" = yes; then :
15034 gl_cv_func_getcwd_path_max=no
15036 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15037 /* end confdefs.h. */
15040 #include <stdlib.h>
15041 #include <unistd.h>
15042 #include <string.h>
15043 #include <limits.h>
15044 #include <sys/stat.h>
15045 #include <sys/types.h>
15049 # define AT_FDCWD 0
15051 #ifdef ENAMETOOLONG
15052 # define is_ENAMETOOLONG(x) ((x) == ENAMETOOLONG)
15054 # define is_ENAMETOOLONG(x) 0
15057 /* Don't get link errors because mkdir is redefined to rpl_mkdir. */
15061 # define S_IRWXU 0700
15064 /* The length of this name must be 8. */
15065 #define DIR_NAME "confdir3"
15066 #define DIR_NAME_LEN 8
15067 #define DIR_NAME_SIZE (DIR_NAME_LEN + 1)
15069 /* The length of "../". */
15070 #define DOTDOTSLASH_LEN 3
15072 /* Leftover bytes in the buffer, to work around library or OS bugs. */
15073 #define BUF_SLOP 20
15079 /* The Hurd doesn't define this, so getcwd can't exhibit the bug --
15080 at least not on a local file system. And if we were to start worrying
15081 about remote file systems, we'd have to enable the wrapper function
15082 all of the time, just to be safe. That's not worth the cost. */
15084 #elif ((INT_MAX / (DIR_NAME_SIZE / DOTDOTSLASH_LEN + 1) \
15085 - DIR_NAME_SIZE - BUF_SLOP) \
15087 /* FIXME: Assuming there's a system for which this is true,
15088 this should be done in a compile test. */
15091 char buf[PATH_MAX * (DIR_NAME_SIZE / DOTDOTSLASH_LEN + 1)
15092 + DIR_NAME_SIZE + BUF_SLOP];
15093 char *cwd = getcwd (buf, PATH_MAX);
15094 size_t initial_cwd_len;
15097 size_t n_chdirs = 0;
15102 cwd_len = initial_cwd_len = strlen (cwd);
15106 size_t dotdot_max = PATH_MAX * (DIR_NAME_SIZE / DOTDOTSLASH_LEN);
15109 cwd_len += DIR_NAME_SIZE;
15110 /* If mkdir or chdir fails, it could be that this system cannot create
15111 any file with an absolute name longer than PATH_MAX, such as cygwin.
15112 If so, leave fail as 0, because the current working directory can't
15113 be too long for getcwd if it can't even be created. For other
15114 errors, be pessimistic and consider that as a failure, too. */
15115 if (mkdir (DIR_NAME, S_IRWXU) < 0 || chdir (DIR_NAME) < 0)
15117 if (! (errno == ERANGE || is_ENAMETOOLONG (errno)))
15122 if (PATH_MAX <= cwd_len && cwd_len < PATH_MAX + DIR_NAME_SIZE)
15124 c = getcwd (buf, PATH_MAX);
15125 if (!c && errno == ENOENT)
15130 if (c || ! (errno == ERANGE || is_ENAMETOOLONG (errno)))
15137 if (dotdot_max <= cwd_len - initial_cwd_len)
15139 if (dotdot_max + DIR_NAME_SIZE < cwd_len - initial_cwd_len)
15141 c = getcwd (buf, cwd_len + 1);
15144 if (! (errno == ERANGE || errno == ENOENT
15145 || is_ENAMETOOLONG (errno)))
15150 if (AT_FDCWD || errno == ERANGE || errno == ENOENT)
15158 if (c && strlen (c) != cwd_len)
15166 /* Leaving behind such a deep directory is not polite.
15167 So clean up here, right away, even though the driving
15168 shell script would also clean up. */
15172 /* Try rmdir first, in case the chdir failed. */
15174 for (i = 0; i <= n_chdirs; i++)
15176 if (chdir ("..") < 0)
15178 if (rmdir (DIR_NAME) != 0)
15188 if ac_fn_c_try_run "$LINENO"; then :
15189 gl_cv_func_getcwd_path_max=yes
15192 1) gl_cv_func_getcwd_path_max='no, but it is partly working';;
15193 *) gl_cv_func_getcwd_path_max=no;;
15196 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15197 conftest.$ac_objext conftest.beam conftest.$ac_ext
15202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_path_max" >&5
15203 $as_echo "$gl_cv_func_getcwd_path_max" >&6; }
15204 case $gl_cv_func_getcwd_path_max in
15207 $as_echo "#define HAVE_PARTLY_WORKING_GETCWD 1" >>confdefs.h
15213 for ac_func in getpagesize
15215 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
15216 if test "x$ac_cv_func_getpagesize" = x""yes; then :
15217 cat >>confdefs.h <<_ACEOF
15218 #define HAVE_GETPAGESIZE 1
15224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getcwd aborts when 4k < cwd_length < 16k" >&5
15225 $as_echo_n "checking whether getcwd aborts when 4k < cwd_length < 16k... " >&6; }
15226 if test "${gl_cv_func_getcwd_abort_bug+set}" = set; then :
15227 $as_echo_n "(cached) " >&6
15229 # Remove any remnants of a previous test.
15230 rm -rf confdir-14B---
15231 # Arrange for deletion of the temporary directory this test creates.
15232 ac_clean_files="$ac_clean_files confdir-14B---"
15233 if test "$cross_compiling" = yes; then :
15234 gl_cv_func_getcwd_abort_bug=yes
15236 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15237 /* end confdefs.h. */
15239 #include <stdlib.h>
15240 #include <unistd.h>
15241 #include <limits.h>
15242 #include <string.h>
15243 #include <sys/stat.h>
15245 /* Don't get link errors because mkdir is redefined to rpl_mkdir. */
15249 # define S_IRWXU 0700
15252 /* FIXME: skip the run-test altogether on systems without getpagesize. */
15253 #if ! HAVE_GETPAGESIZE
15254 # define getpagesize() 0
15257 /* This size is chosen to be larger than PATH_MAX (4k), yet smaller than
15258 the 16kB pagesize on ia64 linux. Those conditions make the code below
15259 trigger a bug in glibc's getcwd implementation before 2.4.90-10. */
15260 #define TARGET_LEN (5 * 1024)
15265 char const *dir_name = "confdir-14B---";
15267 size_t initial_cwd_len;
15269 size_t desired_depth;
15272 /* The bug is triggered when PATH_MAX < getpagesize (), so skip
15273 this relative expensive and invasive test if that's not true. */
15274 if (getpagesize () <= PATH_MAX)
15277 cwd = getcwd (NULL, 0);
15281 initial_cwd_len = strlen (cwd);
15283 desired_depth = ((TARGET_LEN - 1 - initial_cwd_len)
15284 / (1 + strlen (dir_name)));
15285 for (d = 0; d < desired_depth; d++)
15287 if (mkdir (dir_name, S_IRWXU) < 0 || chdir (dir_name) < 0)
15289 fail = 3; /* Unable to construct deep hierarchy. */
15294 /* If libc has the bug in question, this invocation of getcwd
15295 results in a failed assertion. */
15296 cwd = getcwd (NULL, 0);
15298 fail = 4; /* getcwd failed. This is ok, and expected. */
15301 /* Call rmdir first, in case the above chdir failed. */
15305 if (chdir ("..") < 0)
15314 if ac_fn_c_try_run "$LINENO"; then :
15315 gl_cv_func_getcwd_abort_bug=no
15317 gl_cv_func_getcwd_abort_bug=yes
15319 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15320 conftest.$ac_objext conftest.beam conftest.$ac_ext
15325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_abort_bug" >&5
15326 $as_echo "$gl_cv_func_getcwd_abort_bug" >&6; }
15327 if test $gl_cv_func_getcwd_abort_bug = yes; then :
15333 case $gl_cv_func_getcwd_null,$gl_cv_func_getcwd_path_max,$gl_abort_bug in
15345 gl_LIBOBJS="$gl_LIBOBJS getcwd.$ac_objext"
15365 $as_echo "#define GNULIB_GETOPT_GNU 1" >>confdefs.h
15373 if test -n "$gl_replace_getopt"; then :
15379 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
15383 GNULIB_UNISTD_H_GETOPT=1
15392 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
15402 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
15423 gl_LIBOBJS="$gl_LIBOBJS gettime.$ac_objext"
15435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
15436 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
15437 if test "${gl_cv_func_gettimeofday_posix_signature+set}" = set; then :
15438 $as_echo_n "(cached) " >&6
15440 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15441 /* end confdefs.h. */
15442 #include <sys/time.h>
15449 int (*f) (struct timeval *restrict, void *restrict) = gettimeofday;
15451 return !(x | c.tv_sec | c.tv_usec);
15457 if ac_fn_c_try_compile "$LINENO"; then :
15458 gl_cv_func_gettimeofday_posix_signature=yes
15460 gl_cv_func_gettimeofday_posix_signature=no
15462 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
15465 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
15470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
15471 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
15472 if test "${gl_cv_func_gettimeofday_clobber+set}" = set; then :
15473 $as_echo_n "(cached) " >&6
15475 if test "$cross_compiling" = yes; then :
15476 gl_cv_func_gettimeofday_clobber=yes
15478 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15479 /* end confdefs.h. */
15480 #include <string.h>
15481 #include <sys/time.h>
15483 #include <stdlib.h>
15491 struct tm saved_lt;
15493 lt = localtime (&t);
15495 gettimeofday (&tv, NULL);
15496 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
15502 if ac_fn_c_try_run "$LINENO"; then :
15503 gl_cv_func_gettimeofday_clobber=no
15505 gl_cv_func_gettimeofday_clobber=yes
15507 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15508 conftest.$ac_objext conftest.beam conftest.$ac_ext
15512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
15513 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
15515 if test $gl_cv_func_gettimeofday_clobber = yes; then
15516 REPLACE_GETTIMEOFDAY=1
15517 SYS_TIME_H=sys/time.h
15527 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
15530 for ac_header in sys/timeb.h
15532 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
15533 if test "x$ac_cv_header_sys_timeb_h" = x""yes; then :
15534 cat >>confdefs.h <<_ACEOF
15535 #define HAVE_SYS_TIMEB_H 1
15542 for ac_func in _ftime
15544 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
15545 if test "x$ac_cv_func__ftime" = x""yes; then :
15546 cat >>confdefs.h <<_ACEOF
15547 #define HAVE__FTIME 1
15555 $as_echo "#define gmtime rpl_gmtime" >>confdefs.h
15558 $as_echo "#define localtime rpl_localtime" >>confdefs.h
15562 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
15567 if test $gl_cv_func_gettimeofday_posix_signature != yes; then
15568 REPLACE_GETTIMEOFDAY=1
15569 SYS_TIME_H=sys/time.h
15570 if test $gl_cv_func_gettimeofday_clobber != yes; then
15579 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
15582 for ac_header in sys/timeb.h
15584 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
15585 if test "x$ac_cv_header_sys_timeb_h" = x""yes; then :
15586 cat >>confdefs.h <<_ACEOF
15587 #define HAVE_SYS_TIMEB_H 1
15594 for ac_func in _ftime
15596 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
15597 if test "x$ac_cv_func__ftime" = x""yes; then :
15598 cat >>confdefs.h <<_ACEOF
15599 #define HAVE__FTIME 1
15610 if ${MAKE-make} --version /cannot/make/this >/dev/null 2>&1; then
15619 # Autoconf 2.61a.99 and earlier don't support linking a file only
15620 # in VPATH builds. But since GNUmakefile is for maintainer use
15621 # only, it does not matter if we skip the link with older autoconf.
15622 # Automake 1.10.1 and earlier try to remove GNUmakefile in non-VPATH
15623 # builds, so use a shell variable to bypass this.
15624 GNUmakefile=GNUmakefile
15625 ac_config_links="$ac_config_links $GNUmakefile:$GNUmakefile"
15630 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler generally respects inline" >&5
15631 $as_echo_n "checking whether the compiler generally respects inline... " >&6; }
15632 if test "${gl_cv_c_inline_effective+set}" = set; then :
15633 $as_echo_n "(cached) " >&6
15635 if test $ac_cv_c_inline = no; then
15636 gl_cv_c_inline_effective=no
15638 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15639 /* end confdefs.h. */
15644 #ifdef __NO_INLINE__
15645 #error "inline is not effective"
15651 if ac_fn_c_try_compile "$LINENO"; then :
15652 gl_cv_c_inline_effective=yes
15654 gl_cv_c_inline_effective=no
15656 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_inline_effective" >&5
15661 $as_echo "$gl_cv_c_inline_effective" >&6; }
15662 if test $gl_cv_c_inline_effective = yes; then
15664 $as_echo "#define HAVE_INLINE 1" >>confdefs.h
15670 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnan(double) can be used without linking with libm" >&5
15671 $as_echo_n "checking whether isnan(double) can be used without linking with libm... " >&6; }
15672 if test "${gl_cv_func_isnand_no_libm+set}" = set; then :
15673 $as_echo_n "(cached) " >&6
15676 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15677 /* end confdefs.h. */
15681 # define isnand(x) __builtin_isnan ((double)(x))
15684 # define isnand(x) isnan ((double)(x))
15695 if ac_fn_c_try_link "$LINENO"; then :
15696 gl_cv_func_isnand_no_libm=yes
15698 gl_cv_func_isnand_no_libm=no
15700 rm -f core conftest.err conftest.$ac_objext \
15701 conftest$ac_exeext conftest.$ac_ext
15704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnand_no_libm" >&5
15705 $as_echo "$gl_cv_func_isnand_no_libm" >&6; }
15707 if test $gl_cv_func_isnand_no_libm = yes; then
15709 $as_echo "#define HAVE_ISNAND_IN_LIBC 1" >>confdefs.h
15721 gl_LIBOBJS="$gl_LIBOBJS isnand.$ac_objext"
15724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'double'" >&5
15725 $as_echo_n "checking where to find the exponent in a 'double'... " >&6; }
15726 if test "${gl_cv_cc_double_expbit0+set}" = set; then :
15727 $as_echo_n "(cached) " >&6
15730 if test "$cross_compiling" = yes; then :
15732 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15733 /* end confdefs.h. */
15735 #if defined arm || defined __arm || defined __arm__
15740 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15741 $EGREP "mixed_endianness" >/dev/null 2>&1; then :
15742 gl_cv_cc_double_expbit0="unknown"
15746 if test "${ac_cv_c_bigendian+set}" = set; then :
15747 $as_echo_n "(cached) " >&6
15749 ac_cv_c_bigendian=unknown
15750 # See if we're dealing with a universal compiler.
15751 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15752 /* end confdefs.h. */
15753 #ifndef __APPLE_CC__
15754 not a universal capable compiler
15759 if ac_fn_c_try_compile "$LINENO"; then :
15761 # Check for potential -arch flags. It is not universal unless
15762 # there are at least two -arch flags with different values.
15765 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
15766 if test -n "$ac_prev"; then
15768 i?86 | x86_64 | ppc | ppc64)
15769 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
15772 ac_cv_c_bigendian=universal
15778 elif test "x$ac_word" = "x-arch"; then
15783 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15784 if test $ac_cv_c_bigendian = unknown; then
15785 # See if sys/param.h defines the BYTE_ORDER macro.
15786 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15787 /* end confdefs.h. */
15788 #include <sys/types.h>
15789 #include <sys/param.h>
15794 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
15795 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
15797 bogus endian macros
15804 if ac_fn_c_try_compile "$LINENO"; then :
15805 # It does; now see whether it defined to BIG_ENDIAN or not.
15806 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15807 /* end confdefs.h. */
15808 #include <sys/types.h>
15809 #include <sys/param.h>
15814 #if BYTE_ORDER != BIG_ENDIAN
15822 if ac_fn_c_try_compile "$LINENO"; then :
15823 ac_cv_c_bigendian=yes
15825 ac_cv_c_bigendian=no
15827 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15829 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15831 if test $ac_cv_c_bigendian = unknown; then
15832 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
15833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15834 /* end confdefs.h. */
15835 #include <limits.h>
15840 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
15841 bogus endian macros
15848 if ac_fn_c_try_compile "$LINENO"; then :
15849 # It does; now see whether it defined to _BIG_ENDIAN or not.
15850 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15851 /* end confdefs.h. */
15852 #include <limits.h>
15857 #ifndef _BIG_ENDIAN
15865 if ac_fn_c_try_compile "$LINENO"; then :
15866 ac_cv_c_bigendian=yes
15868 ac_cv_c_bigendian=no
15870 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15872 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15874 if test $ac_cv_c_bigendian = unknown; then
15875 # Compile a test program.
15876 if test "$cross_compiling" = yes; then :
15877 # Try to guess by grepping values from an object file.
15878 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15879 /* end confdefs.h. */
15880 short int ascii_mm[] =
15881 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
15882 short int ascii_ii[] =
15883 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
15884 int use_ascii (int i) {
15885 return ascii_mm[i] + ascii_ii[i];
15887 short int ebcdic_ii[] =
15888 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
15889 short int ebcdic_mm[] =
15890 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
15891 int use_ebcdic (int i) {
15892 return ebcdic_mm[i] + ebcdic_ii[i];
15899 return use_ascii (foo) == use_ebcdic (foo);
15904 if ac_fn_c_try_compile "$LINENO"; then :
15905 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
15906 ac_cv_c_bigendian=yes
15908 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
15909 if test "$ac_cv_c_bigendian" = unknown; then
15910 ac_cv_c_bigendian=no
15912 # finding both strings is unlikely to happen, but who knows?
15913 ac_cv_c_bigendian=unknown
15917 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15919 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15920 /* end confdefs.h. */
15921 $ac_includes_default
15926 /* Are we little or big endian? From Harbison&Steele. */
15930 char c[sizeof (long int)];
15933 return u.c[sizeof (long int) - 1] == 1;
15939 if ac_fn_c_try_run "$LINENO"; then :
15940 ac_cv_c_bigendian=no
15942 ac_cv_c_bigendian=yes
15944 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15945 conftest.$ac_objext conftest.beam conftest.$ac_ext
15951 case $ac_cv_c_bigendian in #(
15953 gl_cv_cc_double_expbit0="word 0 bit 20";; #(
15955 gl_cv_cc_double_expbit0="word 1 bit 20" ;; #(
15958 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
15962 gl_cv_cc_double_expbit0="unknown" ;;
15971 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15972 /* end confdefs.h. */
15975 #include <stddef.h>
15977 #include <string.h>
15979 ((sizeof (double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
15980 typedef union { double value; unsigned int word[NWORDS]; } memory_double;
15981 static unsigned int ored_words[NWORDS];
15982 static unsigned int anded_words[NWORDS];
15983 static void add_to_ored_words (double x)
15987 /* Clear it first, in case sizeof (double) < sizeof (memory_double). */
15988 memset (&m, 0, sizeof (memory_double));
15990 for (i = 0; i < NWORDS; i++)
15992 ored_words[i] |= m.word[i];
15993 anded_words[i] &= m.word[i];
15999 FILE *fp = fopen ("conftest.out", "w");
16002 for (j = 0; j < NWORDS; j++)
16003 anded_words[j] = ~ (unsigned int) 0;
16004 add_to_ored_words (0.25);
16005 add_to_ored_words (0.5);
16006 add_to_ored_words (1.0);
16007 add_to_ored_words (2.0);
16008 add_to_ored_words (4.0);
16009 /* Remove bits that are common (e.g. if representation of the first mantissa
16010 bit is explicit). */
16011 for (j = 0; j < NWORDS; j++)
16012 ored_words[j] &= ~anded_words[j];
16013 /* Now find the nonzero word. */
16014 for (j = 0; j < NWORDS; j++)
16015 if (ored_words[j] != 0)
16020 for (i = j + 1; i < NWORDS; i++)
16021 if (ored_words[i] != 0)
16023 fprintf (fp, "unknown");
16024 return (fclose (fp) != 0);
16027 if ((ored_words[j] >> i) & 1)
16029 fprintf (fp, "word %d bit %d", (int) j, (int) i);
16030 return (fclose (fp) != 0);
16033 fprintf (fp, "unknown");
16034 return (fclose (fp) != 0);
16038 if ac_fn_c_try_run "$LINENO"; then :
16039 gl_cv_cc_double_expbit0=`cat conftest.out`
16041 gl_cv_cc_double_expbit0="unknown"
16043 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16044 conftest.$ac_objext conftest.beam conftest.$ac_ext
16050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_double_expbit0" >&5
16051 $as_echo "$gl_cv_cc_double_expbit0" >&6; }
16052 case "$gl_cv_cc_double_expbit0" in
16054 word=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
16055 bit=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word.*bit //'`
16057 cat >>confdefs.h <<_ACEOF
16058 #define DBL_EXPBIT0_WORD $word
16062 cat >>confdefs.h <<_ACEOF
16063 #define DBL_EXPBIT0_BIT $bit
16074 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnan(float) can be used without linking with libm" >&5
16075 $as_echo_n "checking whether isnan(float) can be used without linking with libm... " >&6; }
16076 if test "${gl_cv_func_isnanf_no_libm+set}" = set; then :
16077 $as_echo_n "(cached) " >&6
16080 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16081 /* end confdefs.h. */
16085 # define isnanf(x) __builtin_isnanf ((float)(x))
16086 #elif defined isnan
16088 # define isnanf(x) isnan ((float)(x))
16099 if ac_fn_c_try_link "$LINENO"; then :
16100 gl_cv_func_isnanf_no_libm=yes
16102 gl_cv_func_isnanf_no_libm=no
16104 rm -f core conftest.err conftest.$ac_objext \
16105 conftest$ac_exeext conftest.$ac_ext
16108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnanf_no_libm" >&5
16109 $as_echo "$gl_cv_func_isnanf_no_libm" >&6; }
16111 if test $gl_cv_func_isnanf_no_libm = yes; then
16115 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnan(float) works" >&5
16116 $as_echo_n "checking whether isnan(float) works... " >&6; }
16117 if test "${gl_cv_func_isnanf_works+set}" = set; then :
16118 $as_echo_n "(cached) " >&6
16121 if test "$cross_compiling" = yes; then :
16123 irix* | solaris*) gl_cv_func_isnanf_works="guessing no";;
16124 *) gl_cv_func_isnanf_works="guessing yes";;
16128 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16129 /* end confdefs.h. */
16134 # define isnanf(x) __builtin_isnanf ((float)(x))
16135 #elif defined isnan
16137 # define isnanf(x) isnan ((float)(x))
16139 /* The Compaq (ex-DEC) C 6.4 compiler chokes on the expression 0.0 / 0.0. */
16144 static float zero = 0.0f;
16145 return zero / zero;
16148 # define NaN() (0.0f / 0.0f)
16151 ((sizeof (float) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
16152 typedef union { unsigned int word[NWORDS]; float value; } memory_float;
16157 if (isnanf (1.0f / 0.0f))
16160 if (!isnanf (NaN ()))
16163 #if defined FLT_EXPBIT0_WORD && defined FLT_EXPBIT0_BIT
16164 /* The isnanf function should be immune against changes in the sign bit and
16165 in the mantissa bits. The xor operation twiddles a bit that can only be
16166 a sign bit or a mantissa bit. */
16167 if (FLT_EXPBIT0_WORD == 0 && FLT_EXPBIT0_BIT > 0)
16170 /* Set the bits below the exponent to 01111...111. */
16171 m.word[0] &= -1U << FLT_EXPBIT0_BIT;
16172 m.word[0] |= 1U << (FLT_EXPBIT0_BIT - 1) - 1;
16173 if (!isnanf (m.value))
16181 if ac_fn_c_try_run "$LINENO"; then :
16182 gl_cv_func_isnanf_works=yes
16184 gl_cv_func_isnanf_works=no
16186 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16187 conftest.$ac_objext conftest.beam conftest.$ac_ext
16192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnanf_works" >&5
16193 $as_echo "$gl_cv_func_isnanf_works" >&6; }
16196 if test $gl_cv_func_isnanf_no_libm = yes \
16197 && { case "$gl_cv_func_isnanf_works" in
16203 $as_echo "#define HAVE_ISNANF_IN_LIBC 1" >>confdefs.h
16215 gl_LIBOBJS="$gl_LIBOBJS isnanf.$ac_objext"
16218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'float'" >&5
16219 $as_echo_n "checking where to find the exponent in a 'float'... " >&6; }
16220 if test "${gl_cv_cc_float_expbit0+set}" = set; then :
16221 $as_echo_n "(cached) " >&6
16224 if test "$cross_compiling" = yes; then :
16225 gl_cv_cc_float_expbit0="word 0 bit 23"
16227 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16228 /* end confdefs.h. */
16231 #include <stddef.h>
16233 #include <string.h>
16235 ((sizeof (float) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
16236 typedef union { float value; unsigned int word[NWORDS]; } memory_float;
16237 static unsigned int ored_words[NWORDS];
16238 static unsigned int anded_words[NWORDS];
16239 static void add_to_ored_words (float x)
16243 /* Clear it first, in case
16244 sizeof (float) < sizeof (memory_float). */
16245 memset (&m, 0, sizeof (memory_float));
16247 for (i = 0; i < NWORDS; i++)
16249 ored_words[i] |= m.word[i];
16250 anded_words[i] &= m.word[i];
16256 FILE *fp = fopen ("conftest.out", "w");
16259 for (j = 0; j < NWORDS; j++)
16260 anded_words[j] = ~ (unsigned int) 0;
16261 add_to_ored_words (0.25f);
16262 add_to_ored_words (0.5f);
16263 add_to_ored_words (1.0f);
16264 add_to_ored_words (2.0f);
16265 add_to_ored_words (4.0f);
16266 /* Remove bits that are common (e.g. if representation of the first mantissa
16267 bit is explicit). */
16268 for (j = 0; j < NWORDS; j++)
16269 ored_words[j] &= ~anded_words[j];
16270 /* Now find the nonzero word. */
16271 for (j = 0; j < NWORDS; j++)
16272 if (ored_words[j] != 0)
16277 for (i = j + 1; i < NWORDS; i++)
16278 if (ored_words[i] != 0)
16280 fprintf (fp, "unknown");
16281 return (fclose (fp) != 0);
16284 if ((ored_words[j] >> i) & 1)
16286 fprintf (fp, "word %d bit %d", (int) j, (int) i);
16287 return (fclose (fp) != 0);
16290 fprintf (fp, "unknown");
16291 return (fclose (fp) != 0);
16295 if ac_fn_c_try_run "$LINENO"; then :
16296 gl_cv_cc_float_expbit0=`cat conftest.out`
16298 gl_cv_cc_float_expbit0="unknown"
16300 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16301 conftest.$ac_objext conftest.beam conftest.$ac_ext
16307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_float_expbit0" >&5
16308 $as_echo "$gl_cv_cc_float_expbit0" >&6; }
16309 case "$gl_cv_cc_float_expbit0" in
16311 word=`echo "$gl_cv_cc_float_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
16312 bit=`echo "$gl_cv_cc_float_expbit0" | sed -e 's/word.*bit //'`
16314 cat >>confdefs.h <<_ACEOF
16315 #define FLT_EXPBIT0_WORD $word
16319 cat >>confdefs.h <<_ACEOF
16320 #define FLT_EXPBIT0_BIT $bit
16331 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnan(long double) can be used without linking with libm" >&5
16332 $as_echo_n "checking whether isnan(long double) can be used without linking with libm... " >&6; }
16333 if test "${gl_cv_func_isnanl_no_libm+set}" = set; then :
16334 $as_echo_n "(cached) " >&6
16337 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16338 /* end confdefs.h. */
16342 # define isnanl(x) __builtin_isnanl ((long double)(x))
16343 #elif defined isnan
16345 # define isnanl(x) isnan ((long double)(x))
16356 if ac_fn_c_try_link "$LINENO"; then :
16357 gl_cv_func_isnanl_no_libm=yes
16359 gl_cv_func_isnanl_no_libm=no
16361 rm -f core conftest.err conftest.$ac_objext \
16362 conftest$ac_exeext conftest.$ac_ext
16365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnanl_no_libm" >&5
16366 $as_echo "$gl_cv_func_isnanl_no_libm" >&6; }
16368 gl_func_isnanl_no_libm=$gl_cv_func_isnanl_no_libm
16369 if test $gl_func_isnanl_no_libm = yes; then
16373 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnanl works" >&5
16374 $as_echo_n "checking whether isnanl works... " >&6; }
16375 if test "${gl_cv_func_isnanl_works+set}" = set; then :
16376 $as_echo_n "(cached) " >&6
16379 if test "$cross_compiling" = yes; then :
16380 case "$host_cpu" in
16381 # Guess no on ia64, x86_64, i386.
16382 ia64 | x86_64 | i*86) gl_cv_func_isnanl_works="guessing no";;
16385 netbsd*) gl_cv_func_isnanl_works="guessing no";;
16386 *) gl_cv_func_isnanl_works="guessing yes";;
16392 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16393 /* end confdefs.h. */
16396 #include <limits.h>
16400 # define isnanl(x) __builtin_isnanl ((long double)(x))
16401 #elif defined isnan
16403 # define isnanl(x) isnan ((long double)(x))
16406 ((sizeof (long double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
16407 typedef union { unsigned int word[NWORDS]; long double value; }
16408 memory_long_double;
16409 /* On Irix 6.5, gcc 3.4.3 can't compute compile-time NaN, and needs the
16410 runtime type conversion. */
16412 static long double NaNl ()
16415 return zero / zero;
16418 # define NaNl() (0.0L / 0.0L)
16422 memory_long_double m;
16425 if (!isnanl (NaNl ()))
16428 /* The isnanl function should be immune against changes in the sign bit and
16429 in the mantissa bits. The xor operation twiddles a bit that can only be
16430 a sign bit or a mantissa bit (since the exponent never extends to
16433 m.word[NWORDS / 2] ^= (unsigned int) 1 << (sizeof (unsigned int) * CHAR_BIT - 1);
16434 for (i = 0; i < NWORDS; i++)
16436 if (!isnanl (m.value))
16439 #if ((defined __ia64 && LDBL_MANT_DIG == 64) || (defined __x86_64__ || defined __amd64__) || (defined __i386 || defined __i386__ || defined _I386 || defined _M_IX86 || defined _X86_))
16440 /* Representation of an 80-bit 'long double' as an initializer for a sequence
16441 of 'unsigned int' words. */
16442 # ifdef WORDS_BIGENDIAN
16443 # define LDBL80_WORDS(exponent,manthi,mantlo) \
16444 { ((unsigned int) (exponent) << 16) | ((unsigned int) (manthi) >> 16), \
16445 ((unsigned int) (manthi) << 16) | (unsigned int) (mantlo) >> 16), \
16446 (unsigned int) (mantlo) << 16 \
16449 # define LDBL80_WORDS(exponent,manthi,mantlo) \
16450 { mantlo, manthi, exponent }
16453 static memory_long_double x =
16454 { LDBL80_WORDS (0xFFFF, 0xC3333333, 0x00000000) };
16455 if (!isnanl (x.value))
16459 /* Signalling NaN. */
16460 static memory_long_double x =
16461 { LDBL80_WORDS (0xFFFF, 0x83333333, 0x00000000) };
16462 if (!isnanl (x.value))
16465 /* The isnanl function should recognize Pseudo-NaNs, Pseudo-Infinities,
16466 Pseudo-Zeroes, Unnormalized Numbers, and Pseudo-Denormals, as defined in
16467 Intel IA-64 Architecture Software Developer's Manual, Volume 1:
16468 Application Architecture.
16469 Table 5-2 "Floating-Point Register Encodings"
16470 Figure 5-6 "Memory to Floating-Point Register Data Translation"
16472 { /* Pseudo-NaN. */
16473 static memory_long_double x =
16474 { LDBL80_WORDS (0xFFFF, 0x40000001, 0x00000000) };
16475 if (!isnanl (x.value))
16478 { /* Pseudo-Infinity. */
16479 static memory_long_double x =
16480 { LDBL80_WORDS (0xFFFF, 0x00000000, 0x00000000) };
16481 if (!isnanl (x.value))
16484 { /* Pseudo-Zero. */
16485 static memory_long_double x =
16486 { LDBL80_WORDS (0x4004, 0x00000000, 0x00000000) };
16487 if (!isnanl (x.value))
16490 { /* Unnormalized number. */
16491 static memory_long_double x =
16492 { LDBL80_WORDS (0x4000, 0x63333333, 0x00000000) };
16493 if (!isnanl (x.value))
16496 { /* Pseudo-Denormal. */
16497 static memory_long_double x =
16498 { LDBL80_WORDS (0x0000, 0x83333333, 0x00000000) };
16499 if (!isnanl (x.value))
16507 if ac_fn_c_try_run "$LINENO"; then :
16508 gl_cv_func_isnanl_works=yes
16510 gl_cv_func_isnanl_works=no
16512 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16513 conftest.$ac_objext conftest.beam conftest.$ac_ext
16518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnanl_works" >&5
16519 $as_echo "$gl_cv_func_isnanl_works" >&6; }
16521 case "$gl_cv_func_isnanl_works" in
16523 *) gl_func_isnanl_no_libm=no ;;
16526 if test $gl_func_isnanl_no_libm = yes; then
16528 $as_echo "#define HAVE_ISNANL_IN_LIBC 1" >>confdefs.h
16540 gl_LIBOBJS="$gl_LIBOBJS isnanl.$ac_objext"
16544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'long double'" >&5
16545 $as_echo_n "checking where to find the exponent in a 'long double'... " >&6; }
16546 if test "${gl_cv_cc_long_double_expbit0+set}" = set; then :
16547 $as_echo_n "(cached) " >&6
16550 if test "$cross_compiling" = yes; then :
16552 gl_cv_cc_long_double_expbit0="unknown"
16555 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16556 /* end confdefs.h. */
16559 #include <stddef.h>
16561 #include <string.h>
16563 ((sizeof (long double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
16564 typedef union { long double value; unsigned int word[NWORDS]; }
16565 memory_long_double;
16566 static unsigned int ored_words[NWORDS];
16567 static unsigned int anded_words[NWORDS];
16568 static void add_to_ored_words (long double x)
16570 memory_long_double m;
16572 /* Clear it first, in case
16573 sizeof (long double) < sizeof (memory_long_double). */
16574 memset (&m, 0, sizeof (memory_long_double));
16576 for (i = 0; i < NWORDS; i++)
16578 ored_words[i] |= m.word[i];
16579 anded_words[i] &= m.word[i];
16585 FILE *fp = fopen ("conftest.out", "w");
16588 for (j = 0; j < NWORDS; j++)
16589 anded_words[j] = ~ (unsigned int) 0;
16590 add_to_ored_words (0.25L);
16591 add_to_ored_words (0.5L);
16592 add_to_ored_words (1.0L);
16593 add_to_ored_words (2.0L);
16594 add_to_ored_words (4.0L);
16595 /* Remove bits that are common (e.g. if representation of the first mantissa
16596 bit is explicit). */
16597 for (j = 0; j < NWORDS; j++)
16598 ored_words[j] &= ~anded_words[j];
16599 /* Now find the nonzero word. */
16600 for (j = 0; j < NWORDS; j++)
16601 if (ored_words[j] != 0)
16606 for (i = j + 1; i < NWORDS; i++)
16607 if (ored_words[i] != 0)
16609 fprintf (fp, "unknown");
16610 return (fclose (fp) != 0);
16613 if ((ored_words[j] >> i) & 1)
16615 fprintf (fp, "word %d bit %d", (int) j, (int) i);
16616 return (fclose (fp) != 0);
16619 fprintf (fp, "unknown");
16620 return (fclose (fp) != 0);
16624 if ac_fn_c_try_run "$LINENO"; then :
16625 gl_cv_cc_long_double_expbit0=`cat conftest.out`
16627 gl_cv_cc_long_double_expbit0="unknown"
16629 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16630 conftest.$ac_objext conftest.beam conftest.$ac_ext
16636 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_long_double_expbit0" >&5
16637 $as_echo "$gl_cv_cc_long_double_expbit0" >&6; }
16638 case "$gl_cv_cc_long_double_expbit0" in
16640 word=`echo "$gl_cv_cc_long_double_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
16641 bit=`echo "$gl_cv_cc_long_double_expbit0" | sed -e 's/word.*bit //'`
16643 cat >>confdefs.h <<_ACEOF
16644 #define LDBL_EXPBIT0_WORD $word
16648 cat >>confdefs.h <<_ACEOF
16649 #define LDBL_EXPBIT0_BIT $bit
16670 for ac_func in lchown
16672 ac_fn_c_check_func "$LINENO" "lchown" "ac_cv_func_lchown"
16673 if test "x$ac_cv_func_lchown" = x""yes; then :
16674 cat >>confdefs.h <<_ACEOF
16675 #define HAVE_LCHOWN 1
16680 gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
16686 if test $ac_cv_func_lchown = no; then
16688 elif test "$gl_cv_func_chown_slash_works" != yes \
16689 || test "$gl_cv_func_chown_ctime_works" != yes; then
16698 gl_LIBOBJS="$gl_LIBOBJS lchown.$ac_objext"
16715 LOCALCHARSET_TESTS_ENVIRONMENT="CHARSETALIASDIR=\"\$(top_builddir)/$gl_source_base\""
16720 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lseek detects pipes" >&5
16721 $as_echo_n "checking whether lseek detects pipes... " >&6; }
16722 if test "${gl_cv_func_lseek_pipe+set}" = set; then :
16723 $as_echo_n "(cached) " >&6
16725 if test $cross_compiling = no; then
16726 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16727 /* end confdefs.h. */
16729 #include <sys/types.h> /* for off_t */
16730 #include <stdio.h> /* for SEEK_CUR */
16731 #include <unistd.h>
16734 /* Exit with success only if stdin is seekable. */
16735 return lseek (0, (off_t)0, SEEK_CUR) < 0;
16738 if ac_fn_c_try_link "$LINENO"; then :
16739 if test -s conftest$ac_exeext \
16740 && ./conftest$ac_exeext < conftest.$ac_ext \
16741 && { echo hi | ./conftest$ac_exeext; test $? = 1; }; then
16742 gl_cv_func_lseek_pipe=yes
16744 gl_cv_func_lseek_pipe=no
16747 gl_cv_func_lseek_pipe=no
16749 rm -f core conftest.err conftest.$ac_objext \
16750 conftest$ac_exeext conftest.$ac_ext
16752 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16753 /* end confdefs.h. */
16755 #if ((defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__) || defined __BEOS__
16756 /* mingw and BeOS mistakenly return 0 when trying to seek on pipes. */
16760 if ac_fn_c_try_compile "$LINENO"; then :
16761 gl_cv_func_lseek_pipe=yes
16763 gl_cv_func_lseek_pipe=no
16765 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lseek_pipe" >&5
16769 $as_echo "$gl_cv_func_lseek_pipe" >&6; }
16770 if test $gl_cv_func_lseek_pipe = no; then
16780 gl_LIBOBJS="$gl_LIBOBJS lseek.$ac_objext"
16785 $as_echo "#define LSEEK_PIPE_BROKEN 1" >>confdefs.h
16797 if test $ac_cv_func_lstat = yes; then
16799 if test $ac_cv_func_lstat_dereferences_slashed_symlink = no; then
16802 # Prerequisites of lib/lstat.c.
16812 for ac_header in stdlib.h
16814 ac_fn_c_check_header_mongrel "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default"
16815 if test "x$ac_cv_header_stdlib_h" = x""yes; then :
16816 cat >>confdefs.h <<_ACEOF
16817 #define HAVE_STDLIB_H 1
16824 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5
16825 $as_echo_n "checking for GNU libc compatible malloc... " >&6; }
16826 if test "${ac_cv_func_malloc_0_nonnull+set}" = set; then :
16827 $as_echo_n "(cached) " >&6
16829 if test "$cross_compiling" = yes; then :
16830 ac_cv_func_malloc_0_nonnull=no
16832 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16833 /* end confdefs.h. */
16834 #if defined STDC_HEADERS || defined HAVE_STDLIB_H
16835 # include <stdlib.h>
16843 return ! malloc (0);
16848 if ac_fn_c_try_run "$LINENO"; then :
16849 ac_cv_func_malloc_0_nonnull=yes
16851 ac_cv_func_malloc_0_nonnull=no
16853 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16854 conftest.$ac_objext conftest.beam conftest.$ac_ext
16858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_malloc_0_nonnull" >&5
16859 $as_echo "$ac_cv_func_malloc_0_nonnull" >&6; }
16860 if test $ac_cv_func_malloc_0_nonnull = yes; then :
16862 $as_echo "#define HAVE_MALLOC 1" >>confdefs.h
16865 $as_echo "#define HAVE_MALLOC 0" >>confdefs.h
16875 gl_LIBOBJS="$gl_LIBOBJS malloc.$ac_objext"
16878 $as_echo "#define malloc rpl_malloc" >>confdefs.h
16884 $as_echo "#define GNULIB_MALLOC_GNU 1" >>confdefs.h
16888 if test $gl_cv_func_malloc_posix = yes; then
16889 HAVE_MALLOC_POSIX=1
16891 $as_echo "#define HAVE_MALLOC_POSIX 1" >>confdefs.h
16902 gl_LIBOBJS="$gl_LIBOBJS malloc.$ac_objext"
16904 HAVE_MALLOC_POSIX=0
16910 GNULIB_MALLOC_POSIX=1
16920 if test $gl_cv_have_include_next = yes; then
16921 gl_cv_next_math_h='<'math.h'>'
16923 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <math.h>" >&5
16924 $as_echo_n "checking absolute name of <math.h>... " >&6; }
16925 if test "${gl_cv_next_math_h+set}" = set; then :
16926 $as_echo_n "(cached) " >&6
16929 if test $ac_cv_header_math_h = yes; then
16930 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16931 /* end confdefs.h. */
16936 aix*) gl_absname_cpp="$ac_cpp -C" ;;
16937 *) gl_absname_cpp="$ac_cpp" ;;
16939 gl_cv_next_math_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
16940 sed -n '\#/math.h#{
16941 s#.*"\(.*/math.h\)".*#\1#
16947 gl_cv_next_math_h='<'math.h'>'
16951 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_math_h" >&5
16952 $as_echo "$gl_cv_next_math_h" >&6; }
16954 NEXT_MATH_H=$gl_cv_next_math_h
16956 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
16957 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
16958 gl_next_as_first_directive='<'math.h'>'
16960 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
16961 gl_next_as_first_directive=$gl_cv_next_math_h
16963 NEXT_AS_FIRST_DIRECTIVE_MATH_H=$gl_next_as_first_directive
16969 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NAN macro works" >&5
16970 $as_echo_n "checking whether NAN macro works... " >&6; }
16971 if test "${gl_cv_header_math_nan_works+set}" = set; then :
16972 $as_echo_n "(cached) " >&6
16974 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16975 /* end confdefs.h. */
16980 /* Solaris 10 has a broken definition of NAN. Other platforms
16981 fail to provide NAN, or provide it only in C99 mode; this
16982 test only needs to fail when NAN is provided but wrong. */
16992 if ac_fn_c_try_compile "$LINENO"; then :
16993 gl_cv_header_math_nan_works=yes
16995 gl_cv_header_math_nan_works=no
16997 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_math_nan_works" >&5
17000 $as_echo "$gl_cv_header_math_nan_works" >&6; }
17001 if test $gl_cv_header_math_nan_works = no; then
17004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether HUGE_VAL works" >&5
17005 $as_echo_n "checking whether HUGE_VAL works... " >&6; }
17006 if test "${gl_cv_header_math_huge_val_works+set}" = set; then :
17007 $as_echo_n "(cached) " >&6
17009 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17010 /* end confdefs.h. */
17015 /* Solaris 10 has a broken definition of HUGE_VAL. */
17016 double d = HUGE_VAL;
17022 if ac_fn_c_try_compile "$LINENO"; then :
17023 gl_cv_header_math_huge_val_works=yes
17025 gl_cv_header_math_huge_val_works=no
17027 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_math_huge_val_works" >&5
17030 $as_echo "$gl_cv_header_math_huge_val_works" >&6; }
17031 if test $gl_cv_header_math_huge_val_works = no; then
17045 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
17049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
17050 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
17051 if test "${gl_cv_func_mbrtowc_incomplete_state+set}" = set; then :
17052 $as_echo_n "(cached) " >&6
17056 # Guess no on AIX and OSF/1.
17057 osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
17058 # Guess yes otherwise.
17059 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
17061 if test $LOCALE_JA != none; then
17062 if test "$cross_compiling" = yes; then :
17065 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17066 /* end confdefs.h. */
17068 #include <locale.h>
17069 #include <string.h>
17073 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
17075 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
17079 memset (&state, '\0', sizeof (mbstate_t));
17080 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
17081 if (mbsinit (&state))
17087 if ac_fn_c_try_run "$LINENO"; then :
17088 gl_cv_func_mbrtowc_incomplete_state=yes
17090 gl_cv_func_mbrtowc_incomplete_state=no
17092 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17093 conftest.$ac_objext conftest.beam conftest.$ac_ext
17099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
17100 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
17105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
17106 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
17107 if test "${gl_cv_func_mbrtowc_sanitycheck+set}" = set; then :
17108 $as_echo_n "(cached) " >&6
17112 # Guess no on Solaris 8.
17113 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
17114 # Guess yes otherwise.
17115 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
17117 if test $LOCALE_ZH_CN != none; then
17118 if test "$cross_compiling" = yes; then :
17121 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17122 /* end confdefs.h. */
17124 #include <locale.h>
17125 #include <stdlib.h>
17126 #include <string.h>
17130 /* This fails on Solaris 8:
17131 mbrtowc returns 2, and sets wc to 0x00F0.
17132 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
17133 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
17135 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
17139 memset (&state, '\0', sizeof (mbstate_t));
17140 if (mbrtowc (&wc, input + 3, 6, &state) != 4
17141 && mbtowc (&wc, input + 3, 6) == 4)
17147 if ac_fn_c_try_run "$LINENO"; then :
17148 gl_cv_func_mbrtowc_sanitycheck=yes
17150 gl_cv_func_mbrtowc_sanitycheck=no
17152 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17153 conftest.$ac_objext conftest.beam conftest.$ac_ext
17159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
17160 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
17162 REPLACE_MBSTATE_T=0
17163 case "$gl_cv_func_mbrtowc_incomplete_state" in
17165 *) REPLACE_MBSTATE_T=1 ;;
17167 case "$gl_cv_func_mbrtowc_sanitycheck" in
17169 *) REPLACE_MBSTATE_T=1 ;;
17172 REPLACE_MBSTATE_T=1
17174 if test $REPLACE_MBSTATE_T = 1; then
17180 if test $REPLACE_MBSTATE_T = 1; then
17184 if test $ac_cv_func_mbrtowc = no; then
17187 if test $HAVE_MBRTOWC != 0 && test $REPLACE_MBRTOWC != 1; then
17191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles a NULL string argument" >&5
17192 $as_echo_n "checking whether mbrtowc handles a NULL string argument... " >&6; }
17193 if test "${gl_cv_func_mbrtowc_null_arg+set}" = set; then :
17194 $as_echo_n "(cached) " >&6
17198 # Guess no on OSF/1.
17199 osf*) gl_cv_func_mbrtowc_null_arg="guessing no" ;;
17200 # Guess yes otherwise.
17201 *) gl_cv_func_mbrtowc_null_arg="guessing yes" ;;
17203 if test $LOCALE_FR_UTF8 != none; then
17204 if test "$cross_compiling" = yes; then :
17207 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17208 /* end confdefs.h. */
17210 #include <locale.h>
17211 #include <string.h>
17215 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
17221 memset (&state, '\0', sizeof (mbstate_t));
17222 wc = (wchar_t) 0xBADFACE;
17223 mbrtowc (&wc, NULL, 5, &state);
17224 /* Check that wc was not modified. */
17225 if (wc != (wchar_t) 0xBADFACE)
17231 if ac_fn_c_try_run "$LINENO"; then :
17232 gl_cv_func_mbrtowc_null_arg=yes
17234 gl_cv_func_mbrtowc_null_arg=no
17236 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17237 conftest.$ac_objext conftest.beam conftest.$ac_ext
17243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_null_arg" >&5
17244 $as_echo "$gl_cv_func_mbrtowc_null_arg" >&6; }
17250 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc has a correct return value" >&5
17251 $as_echo_n "checking whether mbrtowc has a correct return value... " >&6; }
17252 if test "${gl_cv_func_mbrtowc_retval+set}" = set; then :
17253 $as_echo_n "(cached) " >&6
17257 # Guess no on HP-UX and Solaris.
17258 hpux* | solaris*) gl_cv_func_mbrtowc_retval="guessing no" ;;
17259 # Guess yes otherwise.
17260 *) gl_cv_func_mbrtowc_retval="guessing yes" ;;
17262 if test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none; then
17263 if test "$cross_compiling" = yes; then :
17266 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17267 /* end confdefs.h. */
17269 #include <locale.h>
17270 #include <string.h>
17274 /* This fails on Solaris. */
17275 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
17277 char input[] = "B\303\274\303\237er"; /* "Büßer" */
17281 memset (&state, '\0', sizeof (mbstate_t));
17282 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
17285 if (mbrtowc (&wc, input + 2, 5, &state) != 1)
17289 /* This fails on HP-UX 11.11. */
17290 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
17292 char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
17296 memset (&state, '\0', sizeof (mbstate_t));
17297 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
17300 if (mbrtowc (&wc, input + 2, 5, &state) != 2)
17307 if ac_fn_c_try_run "$LINENO"; then :
17308 gl_cv_func_mbrtowc_retval=yes
17310 gl_cv_func_mbrtowc_retval=no
17312 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17313 conftest.$ac_objext conftest.beam conftest.$ac_ext
17319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_retval" >&5
17320 $as_echo "$gl_cv_func_mbrtowc_retval" >&6; }
17325 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc returns 0 when parsing a NUL character" >&5
17326 $as_echo_n "checking whether mbrtowc returns 0 when parsing a NUL character... " >&6; }
17327 if test "${gl_cv_func_mbrtowc_nul_retval+set}" = set; then :
17328 $as_echo_n "(cached) " >&6
17332 # Guess no on Solaris 8 and 9.
17333 solaris2.[89]) gl_cv_func_mbrtowc_nul_retval="guessing no" ;;
17334 # Guess yes otherwise.
17335 *) gl_cv_func_mbrtowc_nul_retval="guessing yes" ;;
17337 if test $LOCALE_ZH_CN != none; then
17338 if test "$cross_compiling" = yes; then :
17341 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17342 /* end confdefs.h. */
17344 #include <locale.h>
17345 #include <string.h>
17349 /* This fails on Solaris 8 and 9. */
17350 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
17355 memset (&state, '\0', sizeof (mbstate_t));
17356 if (mbrtowc (&wc, "", 1, &state) != 0)
17362 if ac_fn_c_try_run "$LINENO"; then :
17363 gl_cv_func_mbrtowc_nul_retval=yes
17365 gl_cv_func_mbrtowc_nul_retval=no
17367 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17368 conftest.$ac_objext conftest.beam conftest.$ac_ext
17374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_nul_retval" >&5
17375 $as_echo "$gl_cv_func_mbrtowc_nul_retval" >&6; }
17377 case "$gl_cv_func_mbrtowc_null_arg" in
17380 $as_echo "#define MBRTOWC_NULL_ARG_BUG 1" >>confdefs.h
17385 case "$gl_cv_func_mbrtowc_retval" in
17388 $as_echo "#define MBRTOWC_RETVAL_BUG 1" >>confdefs.h
17393 case "$gl_cv_func_mbrtowc_nul_retval" in
17396 $as_echo "#define MBRTOWC_NUL_RETVAL_BUG 1" >>confdefs.h
17402 if test $HAVE_MBRTOWC = 0 || test $REPLACE_MBRTOWC = 1; then
17414 gl_LIBOBJS="$gl_LIBOBJS mbrtowc.$ac_objext"
17435 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
17439 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
17440 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
17441 if test "${gl_cv_func_mbrtowc_incomplete_state+set}" = set; then :
17442 $as_echo_n "(cached) " >&6
17446 # Guess no on AIX and OSF/1.
17447 osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
17448 # Guess yes otherwise.
17449 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
17451 if test $LOCALE_JA != none; then
17452 if test "$cross_compiling" = yes; then :
17455 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17456 /* end confdefs.h. */
17458 #include <locale.h>
17459 #include <string.h>
17463 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
17465 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
17469 memset (&state, '\0', sizeof (mbstate_t));
17470 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
17471 if (mbsinit (&state))
17477 if ac_fn_c_try_run "$LINENO"; then :
17478 gl_cv_func_mbrtowc_incomplete_state=yes
17480 gl_cv_func_mbrtowc_incomplete_state=no
17482 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17483 conftest.$ac_objext conftest.beam conftest.$ac_ext
17489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
17490 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
17495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
17496 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
17497 if test "${gl_cv_func_mbrtowc_sanitycheck+set}" = set; then :
17498 $as_echo_n "(cached) " >&6
17502 # Guess no on Solaris 8.
17503 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
17504 # Guess yes otherwise.
17505 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
17507 if test $LOCALE_ZH_CN != none; then
17508 if test "$cross_compiling" = yes; then :
17511 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17512 /* end confdefs.h. */
17514 #include <locale.h>
17515 #include <stdlib.h>
17516 #include <string.h>
17520 /* This fails on Solaris 8:
17521 mbrtowc returns 2, and sets wc to 0x00F0.
17522 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
17523 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
17525 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
17529 memset (&state, '\0', sizeof (mbstate_t));
17530 if (mbrtowc (&wc, input + 3, 6, &state) != 4
17531 && mbtowc (&wc, input + 3, 6) == 4)
17537 if ac_fn_c_try_run "$LINENO"; then :
17538 gl_cv_func_mbrtowc_sanitycheck=yes
17540 gl_cv_func_mbrtowc_sanitycheck=no
17542 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17543 conftest.$ac_objext conftest.beam conftest.$ac_ext
17549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
17550 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
17552 REPLACE_MBSTATE_T=0
17553 case "$gl_cv_func_mbrtowc_incomplete_state" in
17555 *) REPLACE_MBSTATE_T=1 ;;
17557 case "$gl_cv_func_mbrtowc_sanitycheck" in
17559 *) REPLACE_MBSTATE_T=1 ;;
17562 REPLACE_MBSTATE_T=1
17564 if test $REPLACE_MBSTATE_T = 1; then
17570 if test $REPLACE_MBSTATE_T = 1; then
17574 if test $ac_cv_func_mbsinit = no; then
17577 if test $HAVE_MBSINIT = 0 || test $REPLACE_MBSINIT = 1; then
17589 gl_LIBOBJS="$gl_LIBOBJS mbsinit.$ac_objext"
17619 for ac_func in mempcpy
17621 ac_fn_c_check_func "$LINENO" "mempcpy" "ac_cv_func_mempcpy"
17622 if test "x$ac_cv_func_mempcpy" = x""yes; then :
17623 cat >>confdefs.h <<_ACEOF
17624 #define HAVE_MEMPCPY 1
17629 gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
17635 if test $ac_cv_func_mempcpy = no; then
17651 if test $ac_cv_have_decl_memrchr = no; then
17652 HAVE_DECL_MEMRCHR=0
17663 for ac_func in memrchr
17665 ac_fn_c_check_func "$LINENO" "memrchr" "ac_cv_func_memrchr"
17666 if test "x$ac_cv_func_memrchr" = x""yes; then :
17667 cat >>confdefs.h <<_ACEOF
17668 #define HAVE_MEMRCHR 1
17673 gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
17679 if test $ac_cv_func_memrchr = no; then
17689 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mkdir handles trailing slash" >&5
17690 $as_echo_n "checking whether mkdir handles trailing slash... " >&6; }
17691 if test "${gl_cv_func_mkdir_trailing_slash_works+set}" = set; then :
17692 $as_echo_n "(cached) " >&6
17694 rm -rf conftest.dir
17695 if test "$cross_compiling" = yes; then :
17696 gl_cv_func_mkdir_trailing_slash_works="guessing no"
17698 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17699 /* end confdefs.h. */
17701 # include <sys/types.h>
17702 # include <sys/stat.h>
17707 return mkdir ("conftest.dir/", 0700);
17712 if ac_fn_c_try_run "$LINENO"; then :
17713 gl_cv_func_mkdir_trailing_slash_works=yes
17715 gl_cv_func_mkdir_trailing_slash_works=no
17717 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17718 conftest.$ac_objext conftest.beam conftest.$ac_ext
17721 rm -rf conftest.dir
17725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mkdir_trailing_slash_works" >&5
17726 $as_echo "$gl_cv_func_mkdir_trailing_slash_works" >&6; }
17727 if test "$gl_cv_func_mkdir_trailing_slash_works" != yes; then
17737 gl_LIBOBJS="$gl_LIBOBJS mkdir.$ac_objext"
17741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mkdir handles trailing dot" >&5
17742 $as_echo_n "checking whether mkdir handles trailing dot... " >&6; }
17743 if test "${gl_cv_func_mkdir_trailing_dot_works+set}" = set; then :
17744 $as_echo_n "(cached) " >&6
17746 rm -rf conftest.dir
17747 if test "$cross_compiling" = yes; then :
17748 gl_cv_func_mkdir_trailing_dot_works="guessing no"
17750 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17751 /* end confdefs.h. */
17753 # include <sys/types.h>
17754 # include <sys/stat.h>
17759 return !mkdir ("conftest.dir/./", 0700);
17764 if ac_fn_c_try_run "$LINENO"; then :
17765 gl_cv_func_mkdir_trailing_dot_works=yes
17767 gl_cv_func_mkdir_trailing_dot_works=no
17769 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17770 conftest.$ac_objext conftest.beam conftest.$ac_ext
17773 rm -rf conftest.dir
17777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mkdir_trailing_dot_works" >&5
17778 $as_echo "$gl_cv_func_mkdir_trailing_dot_works" >&6; }
17779 if test "$gl_cv_func_mkdir_trailing_dot_works" != yes; then
17789 gl_LIBOBJS="$gl_LIBOBJS mkdir.$ac_objext"
17792 $as_echo "#define FUNC_MKDIR_DOT_BUG 1" >>confdefs.h
17812 gl_LIBOBJS="$gl_LIBOBJS open.$ac_objext"
17823 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether open recognizes a trailing slash" >&5
17824 $as_echo_n "checking whether open recognizes a trailing slash... " >&6; }
17825 if test "${gl_cv_func_open_slash+set}" = set; then :
17826 $as_echo_n "(cached) " >&6
17828 # Assume that if we have lstat, we can also check symlinks.
17829 if test $ac_cv_func_lstat = yes; then
17831 ln -s conftest.tmp conftest.lnk
17833 if test "$cross_compiling" = yes; then :
17836 freebsd*) gl_cv_func_open_slash="guessing no" ;;
17837 solaris2.[0-9]*) gl_cv_func_open_slash="guessing no" ;;
17838 hpux*) gl_cv_func_open_slash="guessing no" ;;
17839 *) gl_cv_func_open_slash="guessing yes" ;;
17843 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17844 /* end confdefs.h. */
17848 # include <unistd.h>
17853 if (open ("conftest.lnk/", O_RDONLY) != -1) return 2;
17855 return open ("conftest.sl/", O_CREAT, 0600) >= 0;
17858 if ac_fn_c_try_run "$LINENO"; then :
17859 gl_cv_func_open_slash=yes
17861 gl_cv_func_open_slash=no
17863 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17864 conftest.$ac_objext conftest.beam conftest.$ac_ext
17867 rm -f conftest.sl conftest.tmp conftest.lnk
17870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_open_slash" >&5
17871 $as_echo "$gl_cv_func_open_slash" >&6; }
17872 case "$gl_cv_func_open_slash" in
17875 $as_echo "#define OPEN_TRAILING_SLASH_BUG 1" >>confdefs.h
17888 gl_LIBOBJS="$gl_LIBOBJS open.$ac_objext"
17903 $as_echo "#define GNULIB_OPEN 1" >>confdefs.h
17931 gl_LIBOBJS="$gl_LIBOBJS openat-proc.$ac_objext"
17971 for ac_func in fchmodat fstatat mkdirat openat unlinkat
17973 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
17974 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
17975 eval as_val=\$$as_ac_var
17976 if test "x$as_val" = x""yes; then :
17977 cat >>confdefs.h <<_ACEOF
17978 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
17983 gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
17991 case $ac_cv_func_openat+$ac_cv_func_lstat_dereferences_slashed_symlink in
17993 # GNU/Hurd has unlinkat, but it has the same bug as unlink.
17994 if test $REPLACE_UNLINK = 1; then
18003 gl_LIBOBJS="$gl_LIBOBJS unlinkat.$ac_objext"
18008 # Solaris 9 has *at functions, but uniformly mishandles trailing
18009 # slash in all of them.
18018 gl_LIBOBJS="$gl_LIBOBJS openat.$ac_objext"
18029 gl_LIBOBJS="$gl_LIBOBJS fstatat.$ac_objext"
18040 gl_LIBOBJS="$gl_LIBOBJS unlinkat.$ac_objext"
18046 HAVE_UNLINKAT=0 # No known system with unlinkat but not openat
18047 HAVE_FSTATAT=0 # No known system with fstatat but not openat
18054 if test $ac_cv_func_fchmodat != yes; then
18057 if test $ac_cv_func_mkdirat != yes; then
18062 ac_fn_c_check_func "$LINENO" "fchownat" "ac_cv_func_fchownat"
18063 if test "x$ac_cv_func_fchownat" = x""yes; then :
18065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fchownat works with AT_SYMLINK_NOFOLLOW" >&5
18066 $as_echo_n "checking whether fchownat works with AT_SYMLINK_NOFOLLOW... " >&6; }
18067 if test "${gl_cv_func_fchownat_nofollow_works+set}" = set; then :
18068 $as_echo_n "(cached) " >&6
18071 gl_dangle=conftest.dangle
18072 # Remove any remnants of a previous test.
18074 # Arrange for deletion of the temporary file this test creates.
18075 ac_clean_files="$ac_clean_files $gl_dangle"
18076 ln -s conftest.no-such $gl_dangle
18077 if test "$cross_compiling" = yes; then :
18078 gl_cv_func_fchownat_nofollow_works=no
18080 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18081 /* end confdefs.h. */
18084 #include <unistd.h>
18085 #include <stdlib.h>
18087 #include <sys/types.h>
18091 return (fchownat (AT_FDCWD, "$gl_dangle", -1, getgid (),
18092 AT_SYMLINK_NOFOLLOW) != 0
18093 && errno == ENOENT);
18097 if ac_fn_c_try_run "$LINENO"; then :
18098 gl_cv_func_fchownat_nofollow_works=yes
18100 gl_cv_func_fchownat_nofollow_works=no
18102 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18103 conftest.$ac_objext conftest.beam conftest.$ac_ext
18108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fchownat_nofollow_works" >&5
18109 $as_echo "$gl_cv_func_fchownat_nofollow_works" >&6; }
18110 if test $gl_cv_func_fchownat_nofollow_works = no; then :
18113 $as_echo "#define FCHOWNAT_NOFOLLOW_BUG 1" >>confdefs.h
18121 if test $REPLACE_CHOWN = 1; then
18124 if test $HAVE_FCHOWNAT = 0 || test $REPLACE_FCHOWNAT = 1; then
18133 gl_LIBOBJS="$gl_LIBOBJS fchownat.$ac_objext"
18141 if test -n "$ERRNO_H"; then
18151 gl_LIBOBJS="$gl_LIBOBJS perror.$ac_objext"
18160 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexp can be used without linking with libm" >&5
18161 $as_echo_n "checking whether frexp can be used without linking with libm... " >&6; }
18162 if test "${gl_cv_func_frexp_no_libm+set}" = set; then :
18163 $as_echo_n "(cached) " >&6
18166 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18167 /* end confdefs.h. */
18174 return frexp (x, &y) < 1;
18179 if ac_fn_c_try_link "$LINENO"; then :
18180 gl_cv_func_frexp_no_libm=yes
18182 gl_cv_func_frexp_no_libm=no
18184 rm -f core conftest.err conftest.$ac_objext \
18185 conftest$ac_exeext conftest.$ac_ext
18188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexp_no_libm" >&5
18189 $as_echo "$gl_cv_func_frexp_no_libm" >&6; }
18190 if test $gl_cv_func_frexp_no_libm = yes; then
18193 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexp works" >&5
18194 $as_echo_n "checking whether frexp works... " >&6; }
18195 if test "${gl_cv_func_frexp_works+set}" = set; then :
18196 $as_echo_n "(cached) " >&6
18199 if test "$cross_compiling" = yes; then :
18201 netbsd* | irix* | mingw*) gl_cv_func_frexp_works="guessing no";;
18202 *) gl_cv_func_frexp_works="guessing yes";;
18206 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18207 /* end confdefs.h. */
18211 #include <string.h>
18216 /* HP cc on HP-UX 10.20 has a bug with the constant expression -0.0.
18217 So we use -zero instead. */
18219 /* Test on denormalized numbers. */
18220 for (i = 1, x = 1.0; i >= DBL_MIN_EXP; i--, x *= 0.5)
18225 double y = frexp (x, &exp);
18226 /* On machines with IEEE754 arithmetic: x = 1.11254e-308, exp = -1022.
18227 On NetBSD: y = 0.75. Correct: y = 0.5. */
18231 /* Test on infinite numbers. */
18235 double y = frexp (x, &exp);
18239 /* Test on negative zero. */
18243 double y = frexp (x, &exp);
18244 if (memcmp (&y, &x, sizeof x))
18250 if ac_fn_c_try_run "$LINENO"; then :
18251 gl_cv_func_frexp_works=yes
18253 gl_cv_func_frexp_works=no
18255 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18256 conftest.$ac_objext conftest.beam conftest.$ac_ext
18261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexp_works" >&5
18262 $as_echo "$gl_cv_func_frexp_works" >&6; }
18264 case "$gl_cv_func_frexp_works" in
18267 $as_echo "#define HAVE_FREXP_IN_LIBC 1" >>confdefs.h
18273 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ldexp can be used without linking with libm" >&5
18274 $as_echo_n "checking whether ldexp can be used without linking with libm... " >&6; }
18275 if test "${gl_cv_func_ldexp_no_libm+set}" = set; then :
18276 $as_echo_n "(cached) " >&6
18279 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18280 /* end confdefs.h. */
18287 return ldexp (x, y) < 1;
18292 if ac_fn_c_try_link "$LINENO"; then :
18293 gl_cv_func_ldexp_no_libm=yes
18295 gl_cv_func_ldexp_no_libm=no
18297 rm -f core conftest.err conftest.$ac_objext \
18298 conftest$ac_exeext conftest.$ac_ext
18301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_ldexp_no_libm" >&5
18302 $as_echo "$gl_cv_func_ldexp_no_libm" >&6; }
18303 if test $gl_cv_func_ldexp_no_libm = yes; then
18305 $as_echo "#define HAVE_LDEXP_IN_LIBC 1" >>confdefs.h
18311 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexpl can be used without linking with libm" >&5
18312 $as_echo_n "checking whether frexpl can be used without linking with libm... " >&6; }
18313 if test "${gl_cv_func_frexpl_no_libm+set}" = set; then :
18314 $as_echo_n "(cached) " >&6
18317 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18318 /* end confdefs.h. */
18325 return frexpl (x, &y) < 1;
18330 if ac_fn_c_try_link "$LINENO"; then :
18331 gl_cv_func_frexpl_no_libm=yes
18333 gl_cv_func_frexpl_no_libm=no
18335 rm -f core conftest.err conftest.$ac_objext \
18336 conftest$ac_exeext conftest.$ac_ext
18339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexpl_no_libm" >&5
18340 $as_echo "$gl_cv_func_frexpl_no_libm" >&6; }
18341 if test $gl_cv_func_frexpl_no_libm = yes; then
18344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexpl works" >&5
18345 $as_echo_n "checking whether frexpl works... " >&6; }
18346 if test "${gl_cv_func_frexpl_works+set}" = set; then :
18347 $as_echo_n "(cached) " >&6
18350 if test "$cross_compiling" = yes; then :
18352 aix* | beos* | darwin* | irix* | mingw* | pw*)
18353 gl_cv_func_frexpl_works="guessing no";;
18354 *) gl_cv_func_frexpl_works="guessing yes";;
18358 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18359 /* end confdefs.h. */
18363 /* Override the values of <float.h>, like done in float.in.h. */
18364 #if defined __i386__ && (defined __BEOS__ || defined __OpenBSD__)
18365 # undef LDBL_MIN_EXP
18366 # define LDBL_MIN_EXP (-16381)
18368 extern long double frexpl (long double, int *);
18371 volatile long double x;
18372 /* Test on finite numbers that fails on AIX 5.1. */
18380 /* Test on finite numbers that fails on MacOS X 10.4, because its frexpl
18381 function returns an invalid (incorrectly normalized) value: it returns
18382 y = { 0x3fe028f5, 0xc28f5c28, 0x3c9eb851, 0xeb851eb8 }
18383 but the correct result is
18384 0.505L = { 0x3fe028f5, 0xc28f5c29, 0xbc547ae1, 0x47ae1480 } */
18388 long double y = frexpl (x, &exp);
18389 if (!(exp == 1 && y == 0.505L))
18392 /* Test on large finite numbers. This fails on BeOS at i = 16322, while
18393 LDBL_MAX_EXP = 16384.
18394 In the loop end test, we test x against Infinity, rather than comparing
18395 i with LDBL_MAX_EXP, because BeOS <float.h> has a wrong LDBL_MAX_EXP. */
18398 for (i = 1, x = 1.0L; x != x + x; i++, x *= 2.0L)
18406 /* Test on denormalized numbers. */
18409 for (i = 1, x = 1.0L; i >= LDBL_MIN_EXP; i--, x *= 0.5L)
18414 long double y = frexpl (x, &exp);
18415 /* On machines with IEEE854 arithmetic: x = 1.68105e-4932,
18416 exp = -16382, y = 0.5. On MacOS X 10.5: exp = -16384, y = 0.5. */
18417 if (exp != LDBL_MIN_EXP - 1)
18421 /* Test on infinite numbers. */
18425 long double y = frexpl (x, &exp);
18432 if ac_fn_c_try_run "$LINENO"; then :
18433 gl_cv_func_frexpl_works=yes
18435 gl_cv_func_frexpl_works=no
18437 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18438 conftest.$ac_objext conftest.beam conftest.$ac_ext
18443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexpl_works" >&5
18444 $as_echo "$gl_cv_func_frexpl_works" >&6; }
18446 case "$gl_cv_func_frexpl_works" in
18447 *yes) gl_func_frexpl_no_libm=yes ;;
18448 *) gl_func_frexpl_no_libm=no; REPLACE_FREXPL=1 ;;
18451 gl_func_frexpl_no_libm=no
18454 if test $gl_func_frexpl_no_libm = yes; then
18456 $as_echo "#define HAVE_FREXPL_IN_LIBC 1" >>confdefs.h
18458 ac_fn_c_check_decl "$LINENO" "frexpl" "ac_cv_have_decl_frexpl" "#include <math.h>
18460 if test "x$ac_cv_have_decl_frexpl" = x""yes; then :
18468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ldexpl can be used without linking with libm" >&5
18469 $as_echo_n "checking whether ldexpl can be used without linking with libm... " >&6; }
18470 if test "${gl_cv_func_ldexpl_no_libm+set}" = set; then :
18471 $as_echo_n "(cached) " >&6
18474 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18475 /* end confdefs.h. */
18482 return ldexpl (x, y) < 1;
18487 if ac_fn_c_try_link "$LINENO"; then :
18488 gl_cv_func_ldexpl_no_libm=yes
18490 gl_cv_func_ldexpl_no_libm=no
18492 rm -f core conftest.err conftest.$ac_objext \
18493 conftest$ac_exeext conftest.$ac_ext
18496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_ldexpl_no_libm" >&5
18497 $as_echo "$gl_cv_func_ldexpl_no_libm" >&6; }
18498 if test $gl_cv_func_ldexpl_no_libm = yes; then
18501 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ldexpl works" >&5
18502 $as_echo_n "checking whether ldexpl works... " >&6; }
18503 if test "${gl_cv_func_ldexpl_works+set}" = set; then :
18504 $as_echo_n "(cached) " >&6
18507 if test "$cross_compiling" = yes; then :
18509 aix*) gl_cv_func_ldexpl_works="guessing no";;
18510 *) gl_cv_func_ldexpl_works="guessing yes";;
18514 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18515 /* end confdefs.h. */
18518 extern long double ldexpl (long double, int);
18521 volatile long double x1 = 1.0;
18522 volatile long double y1 = ldexpl (x1, -1);
18523 volatile long double x2 = 1.73205L;
18524 volatile long double y2 = ldexpl (x2, 0);
18525 return (y1 != 0.5L) || (y2 != x2);
18528 if ac_fn_c_try_run "$LINENO"; then :
18529 gl_cv_func_ldexpl_works=yes
18531 gl_cv_func_ldexpl_works=no
18533 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18534 conftest.$ac_objext conftest.beam conftest.$ac_ext
18539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_ldexpl_works" >&5
18540 $as_echo "$gl_cv_func_ldexpl_works" >&6; }
18542 case "$gl_cv_func_ldexpl_works" in
18545 $as_echo "#define HAVE_LDEXPL_IN_LIBC 1" >>confdefs.h
18547 ac_fn_c_check_decl "$LINENO" "ldexpl" "ac_cv_have_decl_ldexpl" "#include <math.h>
18549 if test "x$ac_cv_have_decl_ldexpl" = x""yes; then :
18561 if test $gl_cv_func_vfprintf_posix = no; then
18572 gl_LIBOBJS="$gl_LIBOBJS printf.$ac_objext"
18576 $as_echo "#define REPLACE_PRINTF_POSIX 1" >>confdefs.h
18584 GNULIB_PRINTF_POSIX=1
18596 gl_LIBOBJS="$gl_LIBOBJS quotearg.$ac_objext"
18599 for ac_header in stdlib.h
18601 ac_fn_c_check_header_mongrel "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default"
18602 if test "x$ac_cv_header_stdlib_h" = x""yes; then :
18603 cat >>confdefs.h <<_ACEOF
18604 #define HAVE_STDLIB_H 1
18611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible realloc" >&5
18612 $as_echo_n "checking for GNU libc compatible realloc... " >&6; }
18613 if test "${ac_cv_func_realloc_0_nonnull+set}" = set; then :
18614 $as_echo_n "(cached) " >&6
18616 if test "$cross_compiling" = yes; then :
18617 ac_cv_func_realloc_0_nonnull=no
18619 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18620 /* end confdefs.h. */
18621 #if defined STDC_HEADERS || defined HAVE_STDLIB_H
18622 # include <stdlib.h>
18630 return ! realloc (0, 0);
18635 if ac_fn_c_try_run "$LINENO"; then :
18636 ac_cv_func_realloc_0_nonnull=yes
18638 ac_cv_func_realloc_0_nonnull=no
18640 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18641 conftest.$ac_objext conftest.beam conftest.$ac_ext
18645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_realloc_0_nonnull" >&5
18646 $as_echo "$ac_cv_func_realloc_0_nonnull" >&6; }
18647 if test $ac_cv_func_realloc_0_nonnull = yes; then :
18649 $as_echo "#define HAVE_REALLOC 1" >>confdefs.h
18652 $as_echo "#define HAVE_REALLOC 0" >>confdefs.h
18662 gl_LIBOBJS="$gl_LIBOBJS realloc.$ac_objext"
18665 $as_echo "#define realloc rpl_realloc" >>confdefs.h
18671 $as_echo "#define GNULIB_REALLOC_GNU 1" >>confdefs.h
18675 if test $gl_cv_func_malloc_posix = yes; then
18676 HAVE_REALLOC_POSIX=1
18678 $as_echo "#define HAVE_REALLOC_POSIX 1" >>confdefs.h
18689 gl_LIBOBJS="$gl_LIBOBJS realloc.$ac_objext"
18691 HAVE_REALLOC_POSIX=0
18697 GNULIB_REALLOC_POSIX=1
18710 for ac_func in rmdir
18712 ac_fn_c_check_func "$LINENO" "rmdir" "ac_cv_func_rmdir"
18713 if test "x$ac_cv_func_rmdir" = x""yes; then :
18714 cat >>confdefs.h <<_ACEOF
18715 #define HAVE_RMDIR 1
18720 gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
18726 if test $ac_cv_func_rmdir = no; then
18728 # If someone lacks rmdir, make configure fail, and request
18729 # a bug report to inform us about it.
18730 if test x"$SKIP_RMDIR_CHECK" != xyes; then
18731 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
18732 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18733 as_fn_error "Your system lacks the rmdir function.
18734 Please report this, along with the output of \"uname -a\", to the
18735 bug-coreutils@gnu.org mailing list. To continue past this point,
18736 rerun configure with SKIP_RMDIR_CHECK=yes.
18737 E.g., ./configure SKIP_RMDIR_CHECK=yes
18738 See \`config.log' for more details." "$LINENO" 5; }
18741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rmdir works" >&5
18742 $as_echo_n "checking whether rmdir works... " >&6; }
18743 if test "${gl_cv_func_rmdir_works+set}" = set; then :
18744 $as_echo_n "(cached) " >&6
18747 touch conftest.file
18748 if test "$cross_compiling" = yes; then :
18749 gl_cv_func_rmdir_works="guessing no"
18751 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18752 /* end confdefs.h. */
18755 #include <unistd.h>
18760 return !rmdir ("conftest.file/") || errno != ENOTDIR
18761 || !rmdir ("conftest.dir/./");
18766 if ac_fn_c_try_run "$LINENO"; then :
18767 gl_cv_func_rmdir_works=yes
18769 gl_cv_func_rmdir_works=no
18771 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18772 conftest.$ac_objext conftest.beam conftest.$ac_ext
18775 rm -rf conftest.dir conftest.file
18777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rmdir_works" >&5
18778 $as_echo "$gl_cv_func_rmdir_works" >&6; }
18779 if test x"$gl_cv_func_rmdir_works" != xyes; then
18789 gl_LIBOBJS="$gl_LIBOBJS rmdir.$ac_objext"
18807 gl_LIBOBJS="$gl_LIBOBJS save-cwd.$ac_objext"
18813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signbit macro" >&5
18814 $as_echo_n "checking for signbit macro... " >&6; }
18815 if test "${gl_cv_func_signbit+set}" = set; then :
18816 $as_echo_n "(cached) " >&6
18819 if test "$cross_compiling" = yes; then :
18820 gl_cv_func_signbit="guessing no"
18822 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18823 /* end confdefs.h. */
18826 /* If signbit is defined as a function, don't use it, since calling it for
18827 'float' or 'long double' arguments would involve conversions.
18828 If signbit is not declared at all but exists as a library function, don't
18829 use it, since the prototype may not match.
18830 If signbit is not declared at all but exists as a compiler built-in, don't
18831 use it, since it's preferable to use __builtin_signbit* (no warnings,
18832 no conversions). */
18834 # error "signbit should be a macro"
18836 #include <string.h>
18838 /* Global variables.
18839 Needed because GCC 4 constant-folds __builtin_signbitl (literal)
18840 but cannot constant-fold __builtin_signbitl (variable). */
18846 /* HP cc on HP-UX 10.20 has a bug with the constant expression -0.0.
18847 So we use -p0f and -p0d instead. */
18852 /* On HP-UX 10.20, negating 0.0L does not yield -0.0L.
18853 So we use another constant expression instead.
18854 But that expression does not work on other platforms, such as when
18855 cross-compiling to PowerPC on MacOS X 10.5. */
18856 long double p0l = 0.0L;
18857 #if defined __hpux || defined __sgi
18858 long double m0l = -LDBL_MIN * LDBL_MIN;
18860 long double m0l = -p0l;
18865 float plus_inf = 1.0f / p0f;
18866 float minus_inf = -1.0f / p0f;
18867 if (!(!signbit (255.0f)
18868 && signbit (-255.0f)
18870 && (memcmp (&m0f, &p0f, sizeof (float)) == 0 || signbit (m0f))
18871 && !signbit (plus_inf)
18872 && signbit (minus_inf)))
18878 double plus_inf = 1.0 / p0d;
18879 double minus_inf = -1.0 / p0d;
18880 if (!(!signbit (255.0)
18881 && signbit (-255.0)
18883 && (memcmp (&m0d, &p0d, sizeof (double)) == 0 || signbit (m0d))
18884 && !signbit (plus_inf)
18885 && signbit (minus_inf)))
18891 long double plus_inf = 1.0L / p0l;
18892 long double minus_inf = -1.0L / p0l;
18893 if (!(!signbit (255.0L)
18894 && signbit (-255.0L)
18896 && (memcmp (&m0l, &p0l, sizeof (long double)) == 0 || signbit (m0l))
18897 && !signbit (plus_inf)
18898 && signbit (minus_inf)))
18906 if ac_fn_c_try_run "$LINENO"; then :
18907 gl_cv_func_signbit=yes
18909 gl_cv_func_signbit=no
18911 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18912 conftest.$ac_objext conftest.beam conftest.$ac_ext
18917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_signbit" >&5
18918 $as_echo "$gl_cv_func_signbit" >&6; }
18919 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signbit compiler built-ins" >&5
18920 $as_echo_n "checking for signbit compiler built-ins... " >&6; }
18921 if test "${gl_cv_func_signbit_gcc+set}" = set; then :
18922 $as_echo_n "(cached) " >&6
18925 if test "$cross_compiling" = yes; then :
18926 gl_cv_func_signbit_gcc="guessing no"
18928 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18929 /* end confdefs.h. */
18932 # define signbit(x) \
18933 (sizeof (x) == sizeof (long double) ? __builtin_signbitl (x) : \
18934 sizeof (x) == sizeof (double) ? __builtin_signbit (x) : \
18935 __builtin_signbitf (x))
18937 # error "signbit should be three compiler built-ins"
18939 #include <string.h>
18941 /* Global variables.
18942 Needed because GCC 4 constant-folds __builtin_signbitl (literal)
18943 but cannot constant-fold __builtin_signbitl (variable). */
18949 /* HP cc on HP-UX 10.20 has a bug with the constant expression -0.0.
18950 So we use -p0f and -p0d instead. */
18955 /* On HP-UX 10.20, negating 0.0L does not yield -0.0L.
18956 So we use another constant expression instead.
18957 But that expression does not work on other platforms, such as when
18958 cross-compiling to PowerPC on MacOS X 10.5. */
18959 long double p0l = 0.0L;
18960 #if defined __hpux || defined __sgi
18961 long double m0l = -LDBL_MIN * LDBL_MIN;
18963 long double m0l = -p0l;
18968 float plus_inf = 1.0f / p0f;
18969 float minus_inf = -1.0f / p0f;
18970 if (!(!signbit (255.0f)
18971 && signbit (-255.0f)
18973 && (memcmp (&m0f, &p0f, sizeof (float)) == 0 || signbit (m0f))
18974 && !signbit (plus_inf)
18975 && signbit (minus_inf)))
18981 double plus_inf = 1.0 / p0d;
18982 double minus_inf = -1.0 / p0d;
18983 if (!(!signbit (255.0)
18984 && signbit (-255.0)
18986 && (memcmp (&m0d, &p0d, sizeof (double)) == 0 || signbit (m0d))
18987 && !signbit (plus_inf)
18988 && signbit (minus_inf)))
18994 long double plus_inf = 1.0L / p0l;
18995 long double minus_inf = -1.0L / p0l;
18996 if (!(!signbit (255.0L)
18997 && signbit (-255.0L)
18999 && (memcmp (&m0l, &p0l, sizeof (long double)) == 0 || signbit (m0l))
19000 && !signbit (plus_inf)
19001 && signbit (minus_inf)))
19009 if ac_fn_c_try_run "$LINENO"; then :
19010 gl_cv_func_signbit_gcc=yes
19012 gl_cv_func_signbit_gcc=no
19014 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19015 conftest.$ac_objext conftest.beam conftest.$ac_ext
19020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_signbit_gcc" >&5
19021 $as_echo "$gl_cv_func_signbit_gcc" >&6; }
19022 if test "$gl_cv_func_signbit_gcc" = yes; then
19023 REPLACE_SIGNBIT_USING_GCC=1
19025 if test "$gl_cv_func_signbit" != yes; then
19035 gl_LIBOBJS="$gl_LIBOBJS signbitf.$ac_objext"
19045 gl_LIBOBJS="$gl_LIBOBJS signbitd.$ac_objext"
19055 gl_LIBOBJS="$gl_LIBOBJS signbitl.$ac_objext"
19059 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the sign bit in a 'float'" >&5
19060 $as_echo_n "checking where to find the sign bit in a 'float'... " >&6; }
19061 if test "${gl_cv_cc_float_signbit+set}" = set; then :
19062 $as_echo_n "(cached) " >&6
19065 if test "$cross_compiling" = yes; then :
19067 gl_cv_cc_float_signbit="unknown"
19070 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19071 /* end confdefs.h. */
19073 #include <stddef.h>
19076 ((sizeof (float) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
19077 typedef union { float value; unsigned int word[NWORDS]; }
19079 static memory_float plus = { 1.0f };
19080 static memory_float minus = { -1.0f };
19085 FILE *fp = fopen ("conftest.out", "w");
19088 /* Find the different bit. */
19090 for (j = 0; j < NWORDS; j++)
19092 unsigned int x = plus.word[j] ^ minus.word[j];
19093 if ((x & (x - 1)) || (x && m))
19095 /* More than one bit difference. */
19096 fprintf (fp, "unknown");
19107 /* No difference. */
19108 fprintf (fp, "unknown");
19111 /* Now m = plus.word[k] ^ ~minus.word[k]. */
19112 if (plus.word[k] & ~minus.word[k])
19114 /* Oh? The sign bit is set in the positive and cleared in the negative
19116 fprintf (fp, "unknown");
19122 fprintf (fp, "word %d bit %d", (int) k, (int) i);
19123 return (fclose (fp) != 0);
19127 if ac_fn_c_try_run "$LINENO"; then :
19128 gl_cv_cc_float_signbit=`cat conftest.out`
19130 gl_cv_cc_float_signbit="unknown"
19132 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19133 conftest.$ac_objext conftest.beam conftest.$ac_ext
19139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_float_signbit" >&5
19140 $as_echo "$gl_cv_cc_float_signbit" >&6; }
19141 case "$gl_cv_cc_float_signbit" in
19143 word=`echo "$gl_cv_cc_float_signbit" | sed -e 's/word //' -e 's/ bit.*//'`
19144 bit=`echo "$gl_cv_cc_float_signbit" | sed -e 's/word.*bit //'`
19146 cat >>confdefs.h <<_ACEOF
19147 #define FLT_SIGNBIT_WORD $word
19151 cat >>confdefs.h <<_ACEOF
19152 #define FLT_SIGNBIT_BIT $bit
19161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the sign bit in a 'double'" >&5
19162 $as_echo_n "checking where to find the sign bit in a 'double'... " >&6; }
19163 if test "${gl_cv_cc_double_signbit+set}" = set; then :
19164 $as_echo_n "(cached) " >&6
19167 if test "$cross_compiling" = yes; then :
19169 gl_cv_cc_double_signbit="unknown"
19172 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19173 /* end confdefs.h. */
19175 #include <stddef.h>
19178 ((sizeof (double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
19179 typedef union { double value; unsigned int word[NWORDS]; }
19181 static memory_float plus = { 1.0 };
19182 static memory_float minus = { -1.0 };
19187 FILE *fp = fopen ("conftest.out", "w");
19190 /* Find the different bit. */
19192 for (j = 0; j < NWORDS; j++)
19194 unsigned int x = plus.word[j] ^ minus.word[j];
19195 if ((x & (x - 1)) || (x && m))
19197 /* More than one bit difference. */
19198 fprintf (fp, "unknown");
19209 /* No difference. */
19210 fprintf (fp, "unknown");
19213 /* Now m = plus.word[k] ^ ~minus.word[k]. */
19214 if (plus.word[k] & ~minus.word[k])
19216 /* Oh? The sign bit is set in the positive and cleared in the negative
19218 fprintf (fp, "unknown");
19224 fprintf (fp, "word %d bit %d", (int) k, (int) i);
19225 return (fclose (fp) != 0);
19229 if ac_fn_c_try_run "$LINENO"; then :
19230 gl_cv_cc_double_signbit=`cat conftest.out`
19232 gl_cv_cc_double_signbit="unknown"
19234 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19235 conftest.$ac_objext conftest.beam conftest.$ac_ext
19241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_double_signbit" >&5
19242 $as_echo "$gl_cv_cc_double_signbit" >&6; }
19243 case "$gl_cv_cc_double_signbit" in
19245 word=`echo "$gl_cv_cc_double_signbit" | sed -e 's/word //' -e 's/ bit.*//'`
19246 bit=`echo "$gl_cv_cc_double_signbit" | sed -e 's/word.*bit //'`
19248 cat >>confdefs.h <<_ACEOF
19249 #define DBL_SIGNBIT_WORD $word
19253 cat >>confdefs.h <<_ACEOF
19254 #define DBL_SIGNBIT_BIT $bit
19263 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the sign bit in a 'long double'" >&5
19264 $as_echo_n "checking where to find the sign bit in a 'long double'... " >&6; }
19265 if test "${gl_cv_cc_long_double_signbit+set}" = set; then :
19266 $as_echo_n "(cached) " >&6
19269 if test "$cross_compiling" = yes; then :
19271 gl_cv_cc_long_double_signbit="unknown"
19274 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19275 /* end confdefs.h. */
19277 #include <stddef.h>
19280 ((sizeof (long double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
19281 typedef union { long double value; unsigned int word[NWORDS]; }
19283 static memory_float plus = { 1.0L };
19284 static memory_float minus = { -1.0L };
19289 FILE *fp = fopen ("conftest.out", "w");
19292 /* Find the different bit. */
19294 for (j = 0; j < NWORDS; j++)
19296 unsigned int x = plus.word[j] ^ minus.word[j];
19297 if ((x & (x - 1)) || (x && m))
19299 /* More than one bit difference. */
19300 fprintf (fp, "unknown");
19311 /* No difference. */
19312 fprintf (fp, "unknown");
19315 /* Now m = plus.word[k] ^ ~minus.word[k]. */
19316 if (plus.word[k] & ~minus.word[k])
19318 /* Oh? The sign bit is set in the positive and cleared in the negative
19320 fprintf (fp, "unknown");
19326 fprintf (fp, "word %d bit %d", (int) k, (int) i);
19327 return (fclose (fp) != 0);
19331 if ac_fn_c_try_run "$LINENO"; then :
19332 gl_cv_cc_long_double_signbit=`cat conftest.out`
19334 gl_cv_cc_long_double_signbit="unknown"
19336 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19337 conftest.$ac_objext conftest.beam conftest.$ac_ext
19343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_long_double_signbit" >&5
19344 $as_echo "$gl_cv_cc_long_double_signbit" >&6; }
19345 case "$gl_cv_cc_long_double_signbit" in
19347 word=`echo "$gl_cv_cc_long_double_signbit" | sed -e 's/word //' -e 's/ bit.*//'`
19348 bit=`echo "$gl_cv_cc_long_double_signbit" | sed -e 's/word.*bit //'`
19350 cat >>confdefs.h <<_ACEOF
19351 #define LDBL_SIGNBIT_WORD $word
19355 cat >>confdefs.h <<_ACEOF
19356 #define LDBL_SIGNBIT_BIT $bit
19363 if test "$gl_cv_cc_float_signbit" = unknown; then
19364 ac_fn_c_check_decl "$LINENO" "copysignf" "ac_cv_have_decl_copysignf" "#include <math.h>
19366 if test "x$ac_cv_have_decl_copysignf" = x""yes; then :
19372 cat >>confdefs.h <<_ACEOF
19373 #define HAVE_DECL_COPYSIGNF $ac_have_decl
19376 if test "$ac_cv_have_decl_copysignf" = yes; then
19377 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether copysignf can be used without linking with libm" >&5
19378 $as_echo_n "checking whether copysignf can be used without linking with libm... " >&6; }
19379 if test "${gl_cv_func_copysignf_no_libm+set}" = set; then :
19380 $as_echo_n "(cached) " >&6
19383 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19384 /* end confdefs.h. */
19390 return copysignf (x, y) < 0;
19395 if ac_fn_c_try_link "$LINENO"; then :
19396 gl_cv_func_copysignf_no_libm=yes
19398 gl_cv_func_copysignf_no_libm=no
19400 rm -f core conftest.err conftest.$ac_objext \
19401 conftest$ac_exeext conftest.$ac_ext
19404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_copysignf_no_libm" >&5
19405 $as_echo "$gl_cv_func_copysignf_no_libm" >&6; }
19406 if test $gl_cv_func_copysignf_no_libm = yes; then
19408 $as_echo "#define HAVE_COPYSIGNF_IN_LIBC 1" >>confdefs.h
19413 if test "$gl_cv_cc_double_signbit" = unknown; then
19414 ac_fn_c_check_decl "$LINENO" "copysign" "ac_cv_have_decl_copysign" "#include <math.h>
19416 if test "x$ac_cv_have_decl_copysign" = x""yes; then :
19422 cat >>confdefs.h <<_ACEOF
19423 #define HAVE_DECL_COPYSIGN $ac_have_decl
19426 if test "$ac_cv_have_decl_copysign" = yes; then
19427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether copysign can be used without linking with libm" >&5
19428 $as_echo_n "checking whether copysign can be used without linking with libm... " >&6; }
19429 if test "${gl_cv_func_copysign_no_libm+set}" = set; then :
19430 $as_echo_n "(cached) " >&6
19433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19434 /* end confdefs.h. */
19440 return copysign (x, y) < 0;
19445 if ac_fn_c_try_link "$LINENO"; then :
19446 gl_cv_func_copysign_no_libm=yes
19448 gl_cv_func_copysign_no_libm=no
19450 rm -f core conftest.err conftest.$ac_objext \
19451 conftest$ac_exeext conftest.$ac_ext
19454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_copysign_no_libm" >&5
19455 $as_echo "$gl_cv_func_copysign_no_libm" >&6; }
19456 if test $gl_cv_func_copysign_no_libm = yes; then
19458 $as_echo "#define HAVE_COPYSIGN_IN_LIBC 1" >>confdefs.h
19463 if test "$gl_cv_cc_long_double_signbit" = unknown; then
19464 ac_fn_c_check_decl "$LINENO" "copysignl" "ac_cv_have_decl_copysignl" "#include <math.h>
19466 if test "x$ac_cv_have_decl_copysignl" = x""yes; then :
19472 cat >>confdefs.h <<_ACEOF
19473 #define HAVE_DECL_COPYSIGNL $ac_have_decl
19476 if test "$ac_cv_have_decl_copysignl" = yes; then
19477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether copysignl can be used without linking with libm" >&5
19478 $as_echo_n "checking whether copysignl can be used without linking with libm... " >&6; }
19479 if test "${gl_cv_func_copysignl_no_libm+set}" = set; then :
19480 $as_echo_n "(cached) " >&6
19483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19484 /* end confdefs.h. */
19490 return copysignl (x, y) < 0;
19495 if ac_fn_c_try_link "$LINENO"; then :
19496 gl_cv_func_copysignl_no_libm=yes
19498 gl_cv_func_copysignl_no_libm=no
19500 rm -f core conftest.err conftest.$ac_objext \
19501 conftest$ac_exeext conftest.$ac_ext
19504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_copysignl_no_libm" >&5
19505 $as_echo "$gl_cv_func_copysignl_no_libm" >&6; }
19506 if test $gl_cv_func_copysignl_no_libm = yes; then
19508 $as_echo "#define HAVE_COPYSIGNL_IN_LIBC 1" >>confdefs.h
19521 for ac_header in stdint.h
19523 ac_fn_c_check_header_mongrel "$LINENO" "stdint.h" "ac_cv_header_stdint_h" "$ac_includes_default"
19524 if test "x$ac_cv_header_stdint_h" = x""yes; then :
19525 cat >>confdefs.h <<_ACEOF
19526 #define HAVE_STDINT_H 1
19533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SIZE_MAX" >&5
19534 $as_echo_n "checking for SIZE_MAX... " >&6; }
19535 if test "${gl_cv_size_max+set}" = set; then :
19536 $as_echo_n "(cached) " >&6
19540 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19541 /* end confdefs.h. */
19543 #include <limits.h>
19545 #include <stdint.h>
19552 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19553 $EGREP "Found it" >/dev/null 2>&1; then :
19558 if test -z "$gl_cv_size_max"; then
19559 if ac_fn_c_compute_int "$LINENO" "sizeof (size_t) * CHAR_BIT - 1" "size_t_bits_minus_1" "#include <stddef.h>
19560 #include <limits.h>"; then :
19563 size_t_bits_minus_1=
19566 if ac_fn_c_compute_int "$LINENO" "sizeof (size_t) <= sizeof (unsigned int)" "fits_in_uint" "#include <stddef.h>"; then :
19572 if test -n "$size_t_bits_minus_1" && test -n "$fits_in_uint"; then
19573 if test $fits_in_uint = 1; then
19574 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19575 /* end confdefs.h. */
19576 #include <stddef.h>
19578 extern unsigned long foo;
19588 if ac_fn_c_try_compile "$LINENO"; then :
19591 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19593 if test $fits_in_uint = 1; then
19594 gl_cv_size_max="(((1U << $size_t_bits_minus_1) - 1) * 2 + 1)"
19596 gl_cv_size_max="(((1UL << $size_t_bits_minus_1) - 1) * 2 + 1)"
19599 gl_cv_size_max='((size_t)~(size_t)0)'
19604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_size_max" >&5
19605 $as_echo "$gl_cv_size_max" >&6; }
19606 if test "$gl_cv_size_max" != yes; then
19608 cat >>confdefs.h <<_ACEOF
19609 #define SIZE_MAX $gl_cv_size_max
19619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
19620 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
19621 if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
19622 $as_echo_n "(cached) " >&6
19624 if test "$cross_compiling" = yes; then :
19626 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
19627 *) gl_cv_func_stat_dir_slash="guessing yes";;
19630 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19631 /* end confdefs.h. */
19632 #include <sys/stat.h>
19637 struct stat st; return stat (".", &st) != stat ("./", &st);
19642 if ac_fn_c_try_run "$LINENO"; then :
19643 gl_cv_func_stat_dir_slash=yes
19645 gl_cv_func_stat_dir_slash=no
19647 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19648 conftest.$ac_objext conftest.beam conftest.$ac_ext
19652 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
19653 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
19654 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
19655 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
19656 if test "${gl_cv_func_stat_file_slash+set}" = set; then :
19657 $as_echo_n "(cached) " >&6
19660 # Assume that if we have lstat, we can also check symlinks.
19661 if test $ac_cv_func_lstat = yes; then
19662 ln -s conftest.tmp conftest.lnk
19664 if test "$cross_compiling" = yes; then :
19665 gl_cv_func_stat_file_slash="guessing no"
19667 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19668 /* end confdefs.h. */
19669 #include <sys/stat.h>
19675 if (!stat ("conftest.tmp/", &st)) return 1;
19677 if (!stat ("conftest.lnk/", &st)) return 2;
19684 if ac_fn_c_try_run "$LINENO"; then :
19685 gl_cv_func_stat_file_slash=yes
19687 gl_cv_func_stat_file_slash=no
19689 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19690 conftest.$ac_objext conftest.beam conftest.$ac_ext
19693 rm -f conftest.tmp conftest.lnk
19695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
19696 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
19697 case $gl_cv_func_stat_dir_slash in
19698 *no) REPLACE_STAT=1
19700 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
19703 case $gl_cv_func_stat_file_slash in
19704 *no) REPLACE_STAT=1
19706 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
19709 if test $REPLACE_STAT = 1; then
19718 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
19732 ac_fn_c_check_member "$LINENO" "struct stat" "st_atim.tv_nsec" "ac_cv_member_struct_stat_st_atim_tv_nsec" "#include <sys/types.h>
19733 #include <sys/stat.h>
19735 if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = x""yes; then :
19737 cat >>confdefs.h <<_ACEOF
19738 #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
19741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
19742 $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
19743 if test "${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+set}" = set; then :
19744 $as_echo_n "(cached) " >&6
19746 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19747 /* end confdefs.h. */
19749 #include <sys/types.h>
19750 #include <sys/stat.h>
19751 #if HAVE_SYS_TIME_H
19752 # include <sys/time.h>
19755 struct timespec ts;
19768 if ac_fn_c_try_compile "$LINENO"; then :
19769 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
19771 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no
19773 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
19776 $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
19777 if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
19779 $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
19783 ac_fn_c_check_member "$LINENO" "struct stat" "st_atimespec.tv_nsec" "ac_cv_member_struct_stat_st_atimespec_tv_nsec" "#include <sys/types.h>
19784 #include <sys/stat.h>
19786 if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = x""yes; then :
19788 cat >>confdefs.h <<_ACEOF
19789 #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
19794 ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
19795 #include <sys/stat.h>
19797 if test "x$ac_cv_member_struct_stat_st_atimensec" = x""yes; then :
19799 cat >>confdefs.h <<_ACEOF
19800 #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
19805 ac_fn_c_check_member "$LINENO" "struct stat" "st_atim.st__tim.tv_nsec" "ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" "#include <sys/types.h>
19806 #include <sys/stat.h>
19808 if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = x""yes; then :
19810 cat >>confdefs.h <<_ACEOF
19811 #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
19828 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimespec.tv_nsec" "ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" "#include <sys/types.h>
19829 #include <sys/stat.h>
19831 if test "x$ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" = x""yes; then :
19833 cat >>confdefs.h <<_ACEOF
19834 #define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
19839 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimensec" "ac_cv_member_struct_stat_st_birthtimensec" "#include <sys/types.h>
19840 #include <sys/stat.h>
19842 if test "x$ac_cv_member_struct_stat_st_birthtimensec" = x""yes; then :
19844 cat >>confdefs.h <<_ACEOF
19845 #define HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC 1
19850 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtim.tv_nsec" "ac_cv_member_struct_stat_st_birthtim_tv_nsec" "#include <sys/types.h>
19851 #include <sys/stat.h>
19853 if test "x$ac_cv_member_struct_stat_st_birthtim_tv_nsec" = x""yes; then :
19855 cat >>confdefs.h <<_ACEOF
19856 #define HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC 1
19870 # Define two additional variables used in the Makefile substitution.
19872 if test "$ac_cv_header_stdbool_h" = yes; then
19875 STDBOOL_H='stdbool.h'
19879 if test "$ac_cv_type__Bool" = yes; then
19889 if test $gt_cv_c_wchar_t = no; then
19893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
19894 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
19895 if test "${gl_cv_decl_null_works+set}" = set; then :
19896 $as_echo_n "(cached) " >&6
19898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19899 /* end confdefs.h. */
19900 #include <stddef.h>
19901 int test[2 * (sizeof NULL == sizeof (void *)) -1];
19911 if ac_fn_c_try_compile "$LINENO"; then :
19912 gl_cv_decl_null_works=yes
19914 gl_cv_decl_null_works=no
19916 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
19919 $as_echo "$gl_cv_decl_null_works" >&6; }
19920 if test $gl_cv_decl_null_works = no; then
19924 if test -n "$STDDEF_H"; then
19931 if test $gl_cv_have_include_next = yes; then
19932 gl_cv_next_stddef_h='<'stddef.h'>'
19934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
19935 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
19936 if test "${gl_cv_next_stddef_h+set}" = set; then :
19937 $as_echo_n "(cached) " >&6
19940 if test $ac_cv_header_stddef_h = yes; then
19941 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19942 /* end confdefs.h. */
19943 #include <stddef.h>
19947 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19948 *) gl_absname_cpp="$ac_cpp" ;;
19950 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19951 sed -n '\#/stddef.h#{
19952 s#.*"\(.*/stddef.h\)".*#\1#
19958 gl_cv_next_stddef_h='<'stddef.h'>'
19962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
19963 $as_echo "$gl_cv_next_stddef_h" >&6; }
19965 NEXT_STDDEF_H=$gl_cv_next_stddef_h
19967 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19968 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19969 gl_next_as_first_directive='<'stddef.h'>'
19971 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19972 gl_next_as_first_directive=$gl_cv_next_stddef_h
19974 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
19983 if test $ac_cv_type_long_long_int = yes; then
19984 HAVE_LONG_LONG_INT=1
19986 HAVE_LONG_LONG_INT=0
19990 if test $ac_cv_type_unsigned_long_long_int = yes; then
19991 HAVE_UNSIGNED_LONG_LONG_INT=1
19993 HAVE_UNSIGNED_LONG_LONG_INT=0
19997 if test $ac_cv_header_inttypes_h = yes; then
20004 if test $ac_cv_header_sys_types_h = yes; then
20017 if test $gl_cv_have_include_next = yes; then
20018 gl_cv_next_stdint_h='<'stdint.h'>'
20020 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
20021 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
20022 if test "${gl_cv_next_stdint_h+set}" = set; then :
20023 $as_echo_n "(cached) " >&6
20026 if test $ac_cv_header_stdint_h = yes; then
20027 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20028 /* end confdefs.h. */
20029 #include <stdint.h>
20033 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20034 *) gl_absname_cpp="$ac_cpp" ;;
20036 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20037 sed -n '\#/stdint.h#{
20038 s#.*"\(.*/stdint.h\)".*#\1#
20044 gl_cv_next_stdint_h='<'stdint.h'>'
20048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
20049 $as_echo "$gl_cv_next_stdint_h" >&6; }
20051 NEXT_STDINT_H=$gl_cv_next_stdint_h
20053 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20054 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20055 gl_next_as_first_directive='<'stdint.h'>'
20057 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20058 gl_next_as_first_directive=$gl_cv_next_stdint_h
20060 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
20064 if test $ac_cv_header_stdint_h = yes; then
20071 if test $ac_cv_header_stdint_h = yes; then
20072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
20073 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
20074 if test "${gl_cv_header_working_stdint_h+set}" = set; then :
20075 $as_echo_n "(cached) " >&6
20077 gl_cv_header_working_stdint_h=no
20078 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20079 /* end confdefs.h. */
20082 #define __STDC_LIMIT_MACROS 1 /* to make it work also in C++ mode */
20083 #define __STDC_CONSTANT_MACROS 1 /* to make it work also in C++ mode */
20084 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
20085 #include <stdint.h>
20086 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
20087 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
20088 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
20092 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20093 included before <wchar.h>. */
20094 #include <stddef.h>
20095 #include <signal.h>
20097 # include <stdio.h>
20099 # include <wchar.h>
20104 int8_t a1 = INT8_MAX;
20105 int8_t a1min = INT8_MIN;
20108 int16_t a2 = INT16_MAX;
20109 int16_t a2min = INT16_MIN;
20112 int32_t a3 = INT32_MAX;
20113 int32_t a3min = INT32_MIN;
20116 int64_t a4 = INT64_MAX;
20117 int64_t a4min = INT64_MIN;
20120 uint8_t b1 = UINT8_MAX;
20122 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
20125 uint16_t b2 = UINT16_MAX;
20128 uint32_t b3 = UINT32_MAX;
20131 uint64_t b4 = UINT64_MAX;
20133 int_least8_t c1 = INT8_C (0x7f);
20134 int_least8_t c1max = INT_LEAST8_MAX;
20135 int_least8_t c1min = INT_LEAST8_MIN;
20136 int_least16_t c2 = INT16_C (0x7fff);
20137 int_least16_t c2max = INT_LEAST16_MAX;
20138 int_least16_t c2min = INT_LEAST16_MIN;
20139 int_least32_t c3 = INT32_C (0x7fffffff);
20140 int_least32_t c3max = INT_LEAST32_MAX;
20141 int_least32_t c3min = INT_LEAST32_MIN;
20142 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
20143 int_least64_t c4max = INT_LEAST64_MAX;
20144 int_least64_t c4min = INT_LEAST64_MIN;
20145 uint_least8_t d1 = UINT8_C (0xff);
20146 uint_least8_t d1max = UINT_LEAST8_MAX;
20147 uint_least16_t d2 = UINT16_C (0xffff);
20148 uint_least16_t d2max = UINT_LEAST16_MAX;
20149 uint_least32_t d3 = UINT32_C (0xffffffff);
20150 uint_least32_t d3max = UINT_LEAST32_MAX;
20151 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
20152 uint_least64_t d4max = UINT_LEAST64_MAX;
20153 int_fast8_t e1 = INT_FAST8_MAX;
20154 int_fast8_t e1min = INT_FAST8_MIN;
20155 int_fast16_t e2 = INT_FAST16_MAX;
20156 int_fast16_t e2min = INT_FAST16_MIN;
20157 int_fast32_t e3 = INT_FAST32_MAX;
20158 int_fast32_t e3min = INT_FAST32_MIN;
20159 int_fast64_t e4 = INT_FAST64_MAX;
20160 int_fast64_t e4min = INT_FAST64_MIN;
20161 uint_fast8_t f1 = UINT_FAST8_MAX;
20162 uint_fast16_t f2 = UINT_FAST16_MAX;
20163 uint_fast32_t f3 = UINT_FAST32_MAX;
20164 uint_fast64_t f4 = UINT_FAST64_MAX;
20166 intptr_t g = INTPTR_MAX;
20167 intptr_t gmin = INTPTR_MIN;
20170 uintptr_t h = UINTPTR_MAX;
20172 intmax_t i = INTMAX_MAX;
20173 uintmax_t j = UINTMAX_MAX;
20175 #include <limits.h> /* for CHAR_BIT */
20176 #define TYPE_MINIMUM(t) \
20177 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ (t) 0 << (sizeof (t) * CHAR_BIT - 1)))
20178 #define TYPE_MAXIMUM(t) \
20179 ((t) ((t) 0 < (t) -1 ? (t) -1 : ~ (~ (t) 0 << (sizeof (t) * CHAR_BIT - 1))))
20182 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
20183 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
20185 /* Detect bug in FreeBSD 6.0 / ia64. */
20186 int check_SIG_ATOMIC:
20187 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
20188 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
20190 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
20192 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
20193 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
20195 /* Detect bug in mingw. */
20197 WINT_MIN == TYPE_MINIMUM (wint_t)
20198 && WINT_MAX == TYPE_MAXIMUM (wint_t)
20201 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
20203 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
20204 int check_UINT16_C:
20205 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
20207 /* Detect bugs in OpenBSD 3.9 stdint.h. */
20209 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
20212 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
20215 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
20218 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
20220 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
20221 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
20222 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
20223 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
20224 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
20225 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
20226 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
20227 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
20228 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
20229 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
20230 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
20241 if ac_fn_c_try_compile "$LINENO"; then :
20242 if test "$cross_compiling" = yes; then :
20243 gl_cv_header_working_stdint_h=yes
20246 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20247 /* end confdefs.h. */
20250 #define __STDC_LIMIT_MACROS 1 /* to make it work also in C++ mode */
20251 #define __STDC_CONSTANT_MACROS 1 /* to make it work also in C++ mode */
20252 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
20253 #include <stdint.h>
20256 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20257 included before <wchar.h>. */
20258 #include <stddef.h>
20259 #include <signal.h>
20261 # include <stdio.h>
20263 # include <wchar.h>
20268 #include <string.h>
20269 #define MVAL(macro) MVAL1(macro)
20270 #define MVAL1(expression) #expression
20271 static const char *macro_values[] =
20305 for (mv = macro_values; *mv != NULL; mv++)
20307 const char *value = *mv;
20308 /* Test whether it looks like a cast expression. */
20309 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
20310 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
20311 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
20312 || strncmp (value, "((int)"/*)*/, 6) == 0
20313 || strncmp (value, "((signed short)"/*)*/, 15) == 0
20314 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
20323 if ac_fn_c_try_run "$LINENO"; then :
20324 gl_cv_header_working_stdint_h=yes
20326 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20327 conftest.$ac_objext conftest.beam conftest.$ac_ext
20332 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
20336 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
20338 if test "$gl_cv_header_working_stdint_h" = yes; then
20341 for ac_header in sys/inttypes.h sys/bitypes.h
20343 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
20344 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
20345 eval as_val=\$$as_ac_Header
20346 if test "x$as_val" = x""yes; then :
20347 cat >>confdefs.h <<_ACEOF
20348 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
20355 if test $ac_cv_header_sys_inttypes_h = yes; then
20356 HAVE_SYS_INTTYPES_H=1
20358 HAVE_SYS_INTTYPES_H=0
20361 if test $ac_cv_header_sys_bitypes_h = yes; then
20362 HAVE_SYS_BITYPES_H=1
20364 HAVE_SYS_BITYPES_H=0
20372 if test $APPLE_UNIVERSAL_BUILD = 0; then
20375 for gltype in ptrdiff_t size_t ; do
20376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
20377 $as_echo_n "checking for bit size of $gltype... " >&6; }
20378 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
20379 $as_echo_n "(cached) " >&6
20381 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
20382 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20383 included before <wchar.h>. */
20384 #include <stddef.h>
20385 #include <signal.h>
20387 # include <stdio.h>
20389 # include <wchar.h>
20392 #include <limits.h>"; then :
20398 eval gl_cv_bitsizeof_${gltype}=\$result
20401 eval ac_res=\$gl_cv_bitsizeof_${gltype}
20402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20403 $as_echo "$ac_res" >&6; }
20404 eval result=\$gl_cv_bitsizeof_${gltype}
20405 if test $result = unknown; then
20408 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20409 cat >>confdefs.h <<_ACEOF
20410 #define BITSIZEOF_${GLTYPE} $result
20413 eval BITSIZEOF_${GLTYPE}=\$result
20420 for gltype in sig_atomic_t wchar_t wint_t ; do
20421 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
20422 $as_echo_n "checking for bit size of $gltype... " >&6; }
20423 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
20424 $as_echo_n "(cached) " >&6
20426 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
20427 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20428 included before <wchar.h>. */
20429 #include <stddef.h>
20430 #include <signal.h>
20432 # include <stdio.h>
20434 # include <wchar.h>
20437 #include <limits.h>"; then :
20443 eval gl_cv_bitsizeof_${gltype}=\$result
20446 eval ac_res=\$gl_cv_bitsizeof_${gltype}
20447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20448 $as_echo "$ac_res" >&6; }
20449 eval result=\$gl_cv_bitsizeof_${gltype}
20450 if test $result = unknown; then
20453 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20454 cat >>confdefs.h <<_ACEOF
20455 #define BITSIZEOF_${GLTYPE} $result
20458 eval BITSIZEOF_${GLTYPE}=\$result
20464 for gltype in sig_atomic_t wchar_t wint_t ; do
20465 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
20466 $as_echo_n "checking whether $gltype is signed... " >&6; }
20467 if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
20468 $as_echo_n "(cached) " >&6
20470 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20471 /* end confdefs.h. */
20473 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20474 included before <wchar.h>. */
20475 #include <stddef.h>
20476 #include <signal.h>
20478 # include <stdio.h>
20480 # include <wchar.h>
20483 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
20492 if ac_fn_c_try_compile "$LINENO"; then :
20497 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20498 eval gl_cv_type_${gltype}_signed=\$result
20501 eval ac_res=\$gl_cv_type_${gltype}_signed
20502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20503 $as_echo "$ac_res" >&6; }
20504 eval result=\$gl_cv_type_${gltype}_signed
20505 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20506 if test "$result" = yes; then
20507 cat >>confdefs.h <<_ACEOF
20508 #define HAVE_SIGNED_${GLTYPE} 1
20511 eval HAVE_SIGNED_${GLTYPE}=1
20513 eval HAVE_SIGNED_${GLTYPE}=0
20518 gl_cv_type_ptrdiff_t_signed=yes
20519 gl_cv_type_size_t_signed=no
20520 if test $APPLE_UNIVERSAL_BUILD = 0; then
20523 for gltype in ptrdiff_t size_t ; do
20524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
20525 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
20526 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
20527 $as_echo_n "(cached) " >&6
20529 eval gl_cv_type_${gltype}_suffix=no
20530 eval result=\$gl_cv_type_${gltype}_signed
20531 if test "$result" = yes; then
20536 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
20538 '') gltype1='int';;
20539 l) gltype1='long int';;
20540 ll) gltype1='long long int';;
20541 i64) gltype1='__int64';;
20542 u) gltype1='unsigned int';;
20543 ul) gltype1='unsigned long int';;
20544 ull) gltype1='unsigned long long int';;
20545 ui64)gltype1='unsigned __int64';;
20547 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20548 /* end confdefs.h. */
20550 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20551 included before <wchar.h>. */
20552 #include <stddef.h>
20553 #include <signal.h>
20555 # include <stdio.h>
20557 # include <wchar.h>
20560 extern $gltype foo;
20561 extern $gltype1 foo;
20570 if ac_fn_c_try_compile "$LINENO"; then :
20571 eval gl_cv_type_${gltype}_suffix=\$glsuf
20573 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20574 eval result=\$gl_cv_type_${gltype}_suffix
20575 test "$result" != no && break
20578 eval ac_res=\$gl_cv_type_${gltype}_suffix
20579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20580 $as_echo "$ac_res" >&6; }
20581 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20582 eval result=\$gl_cv_type_${gltype}_suffix
20583 test "$result" = no && result=
20584 eval ${GLTYPE}_SUFFIX=\$result
20585 cat >>confdefs.h <<_ACEOF
20586 #define ${GLTYPE}_SUFFIX $result
20595 for gltype in sig_atomic_t wchar_t wint_t ; do
20596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
20597 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
20598 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
20599 $as_echo_n "(cached) " >&6
20601 eval gl_cv_type_${gltype}_suffix=no
20602 eval result=\$gl_cv_type_${gltype}_signed
20603 if test "$result" = yes; then
20608 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
20610 '') gltype1='int';;
20611 l) gltype1='long int';;
20612 ll) gltype1='long long int';;
20613 i64) gltype1='__int64';;
20614 u) gltype1='unsigned int';;
20615 ul) gltype1='unsigned long int';;
20616 ull) gltype1='unsigned long long int';;
20617 ui64)gltype1='unsigned __int64';;
20619 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20620 /* end confdefs.h. */
20622 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20623 included before <wchar.h>. */
20624 #include <stddef.h>
20625 #include <signal.h>
20627 # include <stdio.h>
20629 # include <wchar.h>
20632 extern $gltype foo;
20633 extern $gltype1 foo;
20642 if ac_fn_c_try_compile "$LINENO"; then :
20643 eval gl_cv_type_${gltype}_suffix=\$glsuf
20645 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20646 eval result=\$gl_cv_type_${gltype}_suffix
20647 test "$result" != no && break
20650 eval ac_res=\$gl_cv_type_${gltype}_suffix
20651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20652 $as_echo "$ac_res" >&6; }
20653 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20654 eval result=\$gl_cv_type_${gltype}_suffix
20655 test "$result" = no && result=
20656 eval ${GLTYPE}_SUFFIX=\$result
20657 cat >>confdefs.h <<_ACEOF
20658 #define ${GLTYPE}_SUFFIX $result
20678 if test $gl_cv_have_include_next = yes; then
20679 gl_cv_next_stdio_h='<'stdio.h'>'
20681 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
20682 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
20683 if test "${gl_cv_next_stdio_h+set}" = set; then :
20684 $as_echo_n "(cached) " >&6
20687 if test $ac_cv_header_stdio_h = yes; then
20688 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20689 /* end confdefs.h. */
20694 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20695 *) gl_absname_cpp="$ac_cpp" ;;
20697 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20698 sed -n '\#/stdio.h#{
20699 s#.*"\(.*/stdio.h\)".*#\1#
20705 gl_cv_next_stdio_h='<'stdio.h'>'
20709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
20710 $as_echo "$gl_cv_next_stdio_h" >&6; }
20712 NEXT_STDIO_H=$gl_cv_next_stdio_h
20714 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20715 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20716 gl_next_as_first_directive='<'stdio.h'>'
20718 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20719 gl_next_as_first_directive=$gl_cv_next_stdio_h
20721 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
20738 for gl_func in fseeko ftello; do
20739 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
20740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
20741 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
20742 if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
20743 $as_echo_n "(cached) " >&6
20745 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20746 /* end confdefs.h. */
20758 if ac_fn_c_try_compile "$LINENO"; then :
20759 eval "$as_gl_Symbol=yes"
20761 eval "$as_gl_Symbol=no"
20763 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20765 eval ac_res=\$$as_gl_Symbol
20766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20767 $as_echo "$ac_res" >&6; }
20768 eval as_val=\$$as_gl_Symbol
20769 if test "x$as_val" = x""yes; then :
20770 cat >>confdefs.h <<_ACEOF
20771 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
20774 eval ac_cv_have_decl_$gl_func=yes
20787 if test $gl_cv_have_include_next = yes; then
20788 gl_cv_next_stdlib_h='<'stdlib.h'>'
20790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
20791 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
20792 if test "${gl_cv_next_stdlib_h+set}" = set; then :
20793 $as_echo_n "(cached) " >&6
20796 if test $ac_cv_header_stdlib_h = yes; then
20797 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20798 /* end confdefs.h. */
20799 #include <stdlib.h>
20803 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20804 *) gl_absname_cpp="$ac_cpp" ;;
20806 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20807 sed -n '\#/stdlib.h#{
20808 s#.*"\(.*/stdlib.h\)".*#\1#
20814 gl_cv_next_stdlib_h='<'stdlib.h'>'
20818 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
20819 $as_echo "$gl_cv_next_stdlib_h" >&6; }
20821 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
20823 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20824 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20825 gl_next_as_first_directive='<'stdlib.h'>'
20827 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20828 gl_next_as_first_directive=$gl_cv_next_stdlib_h
20830 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
20834 for ac_header in random.h
20836 ac_fn_c_check_header_compile "$LINENO" "random.h" "ac_cv_header_random_h" "$ac_includes_default
20838 if test "x$ac_cv_header_random_h" = x""yes; then :
20839 cat >>confdefs.h <<_ACEOF
20840 #define HAVE_RANDOM_H 1
20847 if test $ac_cv_header_random_h = yes; then
20853 ac_fn_c_check_type "$LINENO" "struct random_data" "ac_cv_type_struct_random_data" "#include <stdlib.h>
20855 # include <random.h>
20859 if test "x$ac_cv_type_struct_random_data" = x""yes; then :
20861 cat >>confdefs.h <<_ACEOF
20862 #define HAVE_STRUCT_RANDOM_DATA 1
20867 HAVE_STRUCT_RANDOM_DATA=0
20874 if test $gl_cv_func_malloc_posix != yes; then
20884 gl_LIBOBJS="$gl_LIBOBJS strdup.$ac_objext"
20895 for ac_func in strdup
20897 ac_fn_c_check_func "$LINENO" "strdup" "ac_cv_func_strdup"
20898 if test "x$ac_cv_func_strdup" = x""yes; then :
20899 cat >>confdefs.h <<_ACEOF
20900 #define HAVE_STRDUP 1
20905 gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
20913 if test $ac_cv_have_decl_strdup = no; then
20924 if test $REPLACE_STRERROR = 1; then
20933 gl_LIBOBJS="$gl_LIBOBJS strerror.$ac_objext"
20936 cat >>confdefs.h <<_ACEOF
20937 #define REPLACE_STRERROR $REPLACE_STRERROR
20962 if test $gl_cv_have_include_next = yes; then
20963 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
20965 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
20966 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
20967 if test "${gl_cv_next_sys_stat_h+set}" = set; then :
20968 $as_echo_n "(cached) " >&6
20971 if test $ac_cv_header_sys_stat_h = yes; then
20972 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20973 /* end confdefs.h. */
20974 #include <sys/stat.h>
20978 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20979 *) gl_absname_cpp="$ac_cpp" ;;
20981 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20982 sed -n '\#/sys/stat.h#{
20983 s#.*"\(.*/sys/stat.h\)".*#\1#
20989 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
20993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
20994 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
20996 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
20998 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20999 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21000 gl_next_as_first_directive='<'sys/stat.h'>'
21002 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21003 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
21005 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
21010 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
21011 #include <sys/stat.h>
21013 if test "x$ac_cv_type_nlink_t" = x""yes; then :
21017 $as_echo "#define nlink_t int" >>confdefs.h
21044 if test $gl_cv_have_include_next = yes; then
21045 gl_cv_next_unistd_h='<'unistd.h'>'
21047 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
21048 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
21049 if test "${gl_cv_next_unistd_h+set}" = set; then :
21050 $as_echo_n "(cached) " >&6
21053 if test $ac_cv_header_unistd_h = yes; then
21054 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21055 /* end confdefs.h. */
21056 #include <unistd.h>
21060 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21061 *) gl_absname_cpp="$ac_cpp" ;;
21063 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21064 sed -n '\#/unistd.h#{
21065 s#.*"\(.*/unistd.h\)".*#\1#
21071 gl_cv_next_unistd_h='<'unistd.h'>'
21075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
21076 $as_echo "$gl_cv_next_unistd_h" >&6; }
21078 NEXT_UNISTD_H=$gl_cv_next_unistd_h
21080 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21081 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21082 gl_next_as_first_directive='<'unistd.h'>'
21084 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21085 gl_next_as_first_directive=$gl_cv_next_unistd_h
21087 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
21093 if test $ac_cv_header_unistd_h = yes; then
21101 for gl_func in environ; do
21102 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
21103 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
21104 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
21105 if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
21106 $as_echo_n "(cached) " >&6
21108 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21109 /* end confdefs.h. */
21110 #include <unistd.h>
21111 /* Some systems declare environ in the wrong header. */
21113 # include <stdlib.h>
21125 if ac_fn_c_try_compile "$LINENO"; then :
21126 eval "$as_gl_Symbol=yes"
21128 eval "$as_gl_Symbol=no"
21130 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21132 eval ac_res=\$$as_gl_Symbol
21133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
21134 $as_echo "$ac_res" >&6; }
21135 eval as_val=\$$as_gl_Symbol
21136 if test "x$as_val" = x""yes; then :
21137 cat >>confdefs.h <<_ACEOF
21138 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
21141 eval ac_cv_have_decl_$gl_func=yes
21156 gl_LIBOBJS="$gl_LIBOBJS dup-safer.$ac_objext"
21166 gl_LIBOBJS="$gl_LIBOBJS fd-safer.$ac_objext"
21176 gl_LIBOBJS="$gl_LIBOBJS pipe-safer.$ac_objext"
21182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether unlink honors trailing slashes" >&5
21183 $as_echo_n "checking whether unlink honors trailing slashes... " >&6; }
21184 if test "${gl_cv_func_unlink_works+set}" = set; then :
21185 $as_echo_n "(cached) " >&6
21187 touch conftest.file
21188 # Assume that if we have lstat, we can also check symlinks.
21189 if test $ac_cv_func_lstat = yes; then
21190 ln -s conftest.file conftest.lnk
21192 if test "$cross_compiling" = yes; then :
21193 gl_cv_func_unlink_works="guessing no"
21195 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21196 /* end confdefs.h. */
21197 #include <unistd.h>
21203 if (!unlink ("conftest.file/") || errno != ENOTDIR) return 1;
21205 if (!unlink ("conftest.lnk/") || errno != ENOTDIR) return 2;
21212 if ac_fn_c_try_run "$LINENO"; then :
21213 gl_cv_func_unlink_works=yes
21215 gl_cv_func_unlink_works=no
21217 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21218 conftest.$ac_objext conftest.beam conftest.$ac_ext
21221 rm -f conftest.file conftest.lnk
21223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_unlink_works" >&5
21224 $as_echo "$gl_cv_func_unlink_works" >&6; }
21225 if test x"$gl_cv_func_unlink_works" != xyes; then
21235 gl_LIBOBJS="$gl_LIBOBJS unlink.$ac_objext"
21252 gl_LIBOBJS="$gl_LIBOBJS utimens.$ac_objext"
21260 if test $ac_cv_func_futimens = no && test $ac_cv_func_futimesat = yes; then
21261 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether futimesat handles NULL file" >&5
21262 $as_echo_n "checking whether futimesat handles NULL file... " >&6; }
21263 if test "${gl_cv_func_futimesat_works+set}" = set; then :
21264 $as_echo_n "(cached) " >&6
21266 touch conftest.file
21267 if test "$cross_compiling" = yes; then :
21268 gl_cv_func_futimesat_works="guessing no"
21270 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21271 /* end confdefs.h. */
21273 #include <stddef.h>
21274 #include <sys/times.h>
21279 int fd = open ("conftest.file", O_RDWR);
21280 if (fd < 0) return 1;
21281 if (futimesat (fd, NULL, NULL)) return 2;
21287 if ac_fn_c_try_run "$LINENO"; then :
21288 gl_cv_func_futimesat_works=yes
21290 gl_cv_func_futimesat_works=no
21292 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21293 conftest.$ac_objext conftest.beam conftest.$ac_ext
21296 rm -f conftest.file
21298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_futimesat_works" >&5
21299 $as_echo "$gl_cv_func_futimesat_works" >&6; }
21300 if test "$gl_cv_func_futimesat_works" != yes; then
21302 $as_echo "#define FUTIMESAT_NULL_BUG 1" >>confdefs.h
21309 if test $ac_cv_func_vasnprintf = no; then
21320 gl_LIBOBJS="$gl_LIBOBJS vasnprintf.$ac_objext"
21330 gl_LIBOBJS="$gl_LIBOBJS printf-args.$ac_objext"
21340 gl_LIBOBJS="$gl_LIBOBJS printf-parse.$ac_objext"
21350 gl_LIBOBJS="$gl_LIBOBJS asnprintf.$ac_objext"
21352 if test $ac_cv_func_vasnprintf = yes; then
21354 $as_echo "#define REPLACE_VASNPRINTF 1" >>confdefs.h
21367 ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
21368 if test "x$ac_cv_type_ptrdiff_t" = x""yes; then :
21372 $as_echo "#define ptrdiff_t long" >>confdefs.h
21400 gl_cv_func_vfprintf_posix=no
21401 case "$gl_cv_func_printf_sizes_c99" in
21403 case "$gl_cv_func_printf_long_double" in
21405 case "$gl_cv_func_printf_infinite" in
21407 case "$gl_cv_func_printf_infinite_long_double" in
21409 case "$gl_cv_func_printf_directive_a" in
21411 case "$gl_cv_func_printf_directive_f" in
21413 case "$gl_cv_func_printf_directive_n" in
21415 case "$gl_cv_func_printf_directive_ls" in
21417 case "$gl_cv_func_printf_positions" in
21419 case "$gl_cv_func_printf_flag_grouping" in
21421 case "$gl_cv_func_printf_flag_leftadjust" in
21423 case "$gl_cv_func_printf_flag_zero" in
21425 case "$gl_cv_func_printf_precision" in
21427 case "$gl_cv_func_printf_enomem" in
21429 # vfprintf exists and is
21430 # already POSIX compliant.
21431 gl_cv_func_vfprintf_posix=yes
21460 if test $gl_cv_func_vfprintf_posix = no; then
21464 case "$gl_cv_func_printf_infinite" in
21469 $as_echo "#define NEED_PRINTF_INFINITE_DOUBLE 1" >>confdefs.h
21477 case "$gl_cv_func_printf_long_double" in
21479 case "$gl_cv_func_printf_infinite_long_double" in
21484 $as_echo "#define NEED_PRINTF_INFINITE_LONG_DOUBLE 1" >>confdefs.h
21493 case "$gl_cv_func_printf_directive_a" in
21498 $as_echo "#define NEED_PRINTF_DIRECTIVE_A 1" >>confdefs.h
21500 for ac_func in nl_langinfo
21502 ac_fn_c_check_func "$LINENO" "nl_langinfo" "ac_cv_func_nl_langinfo"
21503 if test "x$ac_cv_func_nl_langinfo" = x""yes; then :
21504 cat >>confdefs.h <<_ACEOF
21505 #define HAVE_NL_LANGINFO 1
21516 case "$gl_cv_func_printf_directive_f" in
21521 $as_echo "#define NEED_PRINTF_DIRECTIVE_F 1" >>confdefs.h
21528 case "$gl_cv_func_printf_directive_ls" in
21533 $as_echo "#define NEED_PRINTF_DIRECTIVE_LS 1" >>confdefs.h
21540 case "$gl_cv_func_printf_flag_grouping" in
21545 $as_echo "#define NEED_PRINTF_FLAG_GROUPING 1" >>confdefs.h
21552 case "$gl_cv_func_printf_flag_leftadjust" in
21557 $as_echo "#define NEED_PRINTF_FLAG_LEFTADJUST 1" >>confdefs.h
21564 case "$gl_cv_func_printf_flag_zero" in
21569 $as_echo "#define NEED_PRINTF_FLAG_ZERO 1" >>confdefs.h
21576 case "$gl_cv_func_printf_precision" in
21581 $as_echo "#define NEED_PRINTF_UNBOUNDED_PRECISION 1" >>confdefs.h
21584 $as_echo "#define NEED_PRINTF_DOUBLE 1" >>confdefs.h
21587 $as_echo "#define NEED_PRINTF_LONG_DOUBLE 1" >>confdefs.h
21594 case "$gl_cv_func_printf_enomem" in
21599 $as_echo "#define NEED_PRINTF_ENOMEM 1" >>confdefs.h
21602 $as_echo "#define NEED_PRINTF_DOUBLE 1" >>confdefs.h
21605 $as_echo "#define NEED_PRINTF_LONG_DOUBLE 1" >>confdefs.h
21620 gl_LIBOBJS="$gl_LIBOBJS vasnprintf.$ac_objext"
21630 gl_LIBOBJS="$gl_LIBOBJS printf-args.$ac_objext"
21640 gl_LIBOBJS="$gl_LIBOBJS printf-parse.$ac_objext"
21650 gl_LIBOBJS="$gl_LIBOBJS asnprintf.$ac_objext"
21652 if test $ac_cv_func_vasnprintf = yes; then
21654 $as_echo "#define REPLACE_VASNPRINTF 1" >>confdefs.h
21667 ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
21668 if test "x$ac_cv_type_ptrdiff_t" = x""yes; then :
21672 $as_echo "#define ptrdiff_t long" >>confdefs.h
21693 gl_LIBOBJS="$gl_LIBOBJS vfprintf.$ac_objext"
21697 $as_echo "#define REPLACE_VFPRINTF_POSIX 1" >>confdefs.h
21705 GNULIB_VFPRINTF_POSIX=1
21718 if test $gl_cv_have_include_next = yes; then
21719 gl_cv_next_wchar_h='<'wchar.h'>'
21721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <wchar.h>" >&5
21722 $as_echo_n "checking absolute name of <wchar.h>... " >&6; }
21723 if test "${gl_cv_next_wchar_h+set}" = set; then :
21724 $as_echo_n "(cached) " >&6
21727 if test $ac_cv_header_wchar_h = yes; then
21728 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21729 /* end confdefs.h. */
21734 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21735 *) gl_absname_cpp="$ac_cpp" ;;
21737 gl_cv_next_wchar_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21738 sed -n '\#/wchar.h#{
21739 s#.*"\(.*/wchar.h\)".*#\1#
21745 gl_cv_next_wchar_h='<'wchar.h'>'
21749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wchar_h" >&5
21750 $as_echo "$gl_cv_next_wchar_h" >&6; }
21752 NEXT_WCHAR_H=$gl_cv_next_wchar_h
21754 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21755 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21756 gl_next_as_first_directive='<'wchar.h'>'
21758 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21759 gl_next_as_first_directive=$gl_cv_next_wchar_h
21761 NEXT_AS_FIRST_DIRECTIVE_WCHAR_H=$gl_next_as_first_directive
21765 if test $ac_cv_header_wchar_h = yes; then
21773 if test $gt_cv_c_wint_t = yes; then
21784 if test $ac_cv_func_iswcntrl = yes; then
21794 if test $gt_cv_c_wint_t = yes; then
21802 if test $ac_cv_header_wctype_h = yes; then
21803 if test $ac_cv_func_iswcntrl = yes; then
21804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether iswcntrl works" >&5
21805 $as_echo_n "checking whether iswcntrl works... " >&6; }
21806 if test "${gl_cv_func_iswcntrl_works+set}" = set; then :
21807 $as_echo_n "(cached) " >&6
21810 if test "$cross_compiling" = yes; then :
21811 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21812 /* end confdefs.h. */
21813 #include <stdlib.h>
21814 #if __GNU_LIBRARY__ == 1
21815 Linux libc5 i18n is broken.
21825 if ac_fn_c_try_compile "$LINENO"; then :
21826 gl_cv_func_iswcntrl_works=yes
21828 gl_cv_func_iswcntrl_works=no
21830 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21834 /* end confdefs.h. */
21836 #include <stddef.h>
21840 #include <wctype.h>
21841 int main () { return iswprint ('x') == 0; }
21843 if ac_fn_c_try_run "$LINENO"; then :
21844 gl_cv_func_iswcntrl_works=yes
21846 gl_cv_func_iswcntrl_works=no
21848 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21849 conftest.$ac_objext conftest.beam conftest.$ac_ext
21854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_iswcntrl_works" >&5
21855 $as_echo "$gl_cv_func_iswcntrl_works" >&6; }
21856 if test $gl_cv_func_iswcntrl_works = yes; then
21872 if test $gl_cv_have_include_next = yes; then
21873 gl_cv_next_wctype_h='<'wctype.h'>'
21875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <wctype.h>" >&5
21876 $as_echo_n "checking absolute name of <wctype.h>... " >&6; }
21877 if test "${gl_cv_next_wctype_h+set}" = set; then :
21878 $as_echo_n "(cached) " >&6
21881 if test $ac_cv_header_wctype_h = yes; then
21882 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21883 /* end confdefs.h. */
21884 #include <wctype.h>
21888 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21889 *) gl_absname_cpp="$ac_cpp" ;;
21891 gl_cv_next_wctype_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21892 sed -n '\#/wctype.h#{
21893 s#.*"\(.*/wctype.h\)".*#\1#
21899 gl_cv_next_wctype_h='<'wctype.h'>'
21903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wctype_h" >&5
21904 $as_echo "$gl_cv_next_wctype_h" >&6; }
21906 NEXT_WCTYPE_H=$gl_cv_next_wctype_h
21908 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21909 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21910 gl_next_as_first_directive='<'wctype.h'>'
21912 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21913 gl_next_as_first_directive=$gl_cv_next_wctype_h
21915 NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H=$gl_next_as_first_directive
21926 if test "$gl_cv_func_iswcntrl_works" = no; then
21942 gl_LIBOBJS="$gl_LIBOBJS xmalloc.$ac_objext"
21962 gl_LIBOBJS="$gl_LIBOBJS xgetcwd.$ac_objext"
21970 for ac_header in stdint.h
21972 ac_fn_c_check_header_mongrel "$LINENO" "stdint.h" "ac_cv_header_stdint_h" "$ac_includes_default"
21973 if test "x$ac_cv_header_stdint_h" = x""yes; then :
21974 cat >>confdefs.h <<_ACEOF
21975 #define HAVE_STDINT_H 1
21992 gl_LIBOBJS="$gl_LIBOBJS yesno.$ac_objext"
22017 gl_source_base='tests'
22025 LIBGZIP_LIBDEPS="$gl_libdeps"
22027 LIBGZIP_LTLIBDEPS="$gl_ltlibdeps"
22031 # Check whether --enable-gcc-warnings was given.
22032 if test "${enable_gcc_warnings+set}" = set; then :
22033 enableval=$enable_gcc_warnings; case $enableval in
22035 *) as_fn_error "bad value $enableval for gcc-warnings option" "$LINENO" 5 ;;
22037 gl_gcc_warnings=$enableval
22044 if test "$gl_gcc_warnings" = yes; then
22045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler handles -Werror" >&5
22046 $as_echo_n "checking whether compiler handles -Werror... " >&6; }
22047 if test "${gl_cv_warn__Werror+set}" = set; then :
22048 $as_echo_n "(cached) " >&6
22051 save_CPPFLAGS="$CPPFLAGS"
22052 CPPFLAGS="${CPPFLAGS} -Werror"
22053 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22054 /* end confdefs.h. */
22064 if ac_fn_c_try_cpp "$LINENO"; then :
22065 gl_cv_warn__Werror=yes
22067 gl_cv_warn__Werror=no
22069 rm -f conftest.err conftest.$ac_ext
22070 CPPFLAGS="$save_CPPFLAGS"
22073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn__Werror" >&5
22074 $as_echo "$gl_cv_warn__Werror" >&6; }
22075 if test "x$gl_cv_warn__Werror" = x""yes; then :
22076 as_fn_append WERROR_CFLAGS " -Werror"
22082 # This, $nw, is the list of warnings we disable.
22083 nw="$nw -Wdeclaration-after-statement" # too useful to forbid
22084 nw="$nw -Waggregate-return" # anachronistic
22085 nw="$nw -Wlong-long" # C90 is anachronistic (lib/gethrxtime.h)
22086 nw="$nw -Wc++-compat" # We don't care about C++ compilers
22087 nw="$nw -Wundef" # Warns on '#if GNULIB_FOO' etc in gnulib
22088 nw="$nw -Wtraditional" # Warns on #elif which we use often
22089 nw="$nw -Wcast-qual" # Too many warnings for now
22090 nw="$nw -Wconversion" # Too many warnings for now
22091 nw="$nw -Wsystem-headers" # Don't let system headers trigger warnings
22092 nw="$nw -Wsign-conversion" # Too many warnings for now
22093 nw="$nw -Wtraditional-conversion" # Too many warnings for now
22094 nw="$nw -Wunreachable-code" # Too many warnings for now
22095 nw="$nw -Wpadded" # Our structs are not padded
22096 nw="$nw -Wredundant-decls" # openat.h declares e.g., mkdirat
22097 nw="$nw -Wlogical-op" # any use of fwrite provokes this
22098 nw="$nw -Wformat-nonliteral" # who.c and pinky.c strftime uses
22099 nw="$nw -Wvla" # warnings in gettext.h
22100 nw="$nw -Wnested-externs" # use of XARGMATCH/verify_function__
22101 nw="$nw -Wswitch-enum" # Too many warnings for now
22102 nw="$nw -Wswitch-default" # Too many warnings for now
22103 nw="$nw -Wstack-protector" # not worth working around
22104 # things I might fix soon:
22105 nw="$nw -Wfloat-equal" # sort.c, seq.c
22106 nw="$nw -Wmissing-format-attribute" # copy.c
22107 nw="$nw -Wunsafe-loop-optimizations" # a few src/*.c
22108 nw="$nw -Winline" # system.h's readdir_ignoring_dot_and_dotdot
22109 nw="$nw -Wstrict-overflow" # expr.c, pr.c, tr.c, factor.c
22110 # initial problems in gzip
22111 nw="$nw -Wold-style-definition"
22113 nw="$nw -Wunused-macros"
22114 # ?? -Wstrict-overflow
22118 for gl_manywarn_item in \
22122 -Wformat-nonliteral \
22123 -Wformat-security \
22125 -Wmissing-include-dirs \
22129 -Wunknown-pragmas \
22130 -Wstrict-aliasing \
22131 -Wstrict-overflow \
22135 -Wtraditional-conversion \
22136 -Wdeclaration-after-statement \
22139 -Wunsafe-loop-optimizations \
22141 -Wbad-function-cast \
22147 -Wsign-conversion \
22149 -Waggregate-return \
22150 -Wstrict-prototypes \
22151 -Wold-style-definition \
22152 -Wmissing-prototypes \
22153 -Wmissing-declarations \
22154 -Wmissing-noreturn \
22155 -Wmissing-format-attribute \
22158 -Wredundant-decls \
22160 -Wunreachable-code \
22165 -Wvolatile-register-var \
22166 -Wdisabled-optimization \
22167 -Wstack-protector \
22168 -Woverlength-strings \
22169 -Wbuiltin-macro-redefined \
22171 -Wpacked-bitfield-compat \
22174 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
22176 # The following are not documented in the manual but are included in
22177 # output from gcc --help=warnings.
22178 for gl_manywarn_item in \
22180 -Wcoverage-mismatch \
22184 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
22186 ws=$gl_manywarn_set
22194 *" $gl_warn_item "*)
22197 gl_warn_set="$gl_warn_set $gl_warn_item"
22204 as_gl_Warn=`$as_echo "gl_cv_warn_$w" | $as_tr_sh`
22205 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler handles $w" >&5
22206 $as_echo_n "checking whether compiler handles $w... " >&6; }
22207 if { as_var=$as_gl_Warn; eval "test \"\${$as_var+set}\" = set"; }; then :
22208 $as_echo_n "(cached) " >&6
22211 save_CPPFLAGS="$CPPFLAGS"
22212 CPPFLAGS="${CPPFLAGS} $w"
22213 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22214 /* end confdefs.h. */
22224 if ac_fn_c_try_cpp "$LINENO"; then :
22225 eval "$as_gl_Warn=yes"
22227 eval "$as_gl_Warn=no"
22229 rm -f conftest.err conftest.$ac_ext
22230 CPPFLAGS="$save_CPPFLAGS"
22233 eval ac_res=\$$as_gl_Warn
22234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
22235 $as_echo "$ac_res" >&6; }
22236 eval as_val=\$$as_gl_Warn
22237 if test "x$as_val" = x""yes; then :
22238 as_fn_append WARN_CFLAGS " $w"
22242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler handles -Wno-missing-field-initializers" >&5
22243 $as_echo_n "checking whether compiler handles -Wno-missing-field-initializers... " >&6; }
22244 if test "${gl_cv_warn__Wno_missing_field_initializers+set}" = set; then :
22245 $as_echo_n "(cached) " >&6
22248 save_CPPFLAGS="$CPPFLAGS"
22249 CPPFLAGS="${CPPFLAGS} -Wno-missing-field-initializers"
22250 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22251 /* end confdefs.h. */
22261 if ac_fn_c_try_cpp "$LINENO"; then :
22262 gl_cv_warn__Wno_missing_field_initializers=yes
22264 gl_cv_warn__Wno_missing_field_initializers=no
22266 rm -f conftest.err conftest.$ac_ext
22267 CPPFLAGS="$save_CPPFLAGS"
22270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn__Wno_missing_field_initializers" >&5
22271 $as_echo "$gl_cv_warn__Wno_missing_field_initializers" >&6; }
22272 if test "x$gl_cv_warn__Wno_missing_field_initializers" = x""yes; then :
22273 as_fn_append WARN_CFLAGS " -Wno-missing-field-initializers"
22276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler handles -Wno-sign-compare" >&5
22277 $as_echo_n "checking whether compiler handles -Wno-sign-compare... " >&6; }
22278 if test "${gl_cv_warn__Wno_sign_compare+set}" = set; then :
22279 $as_echo_n "(cached) " >&6
22282 save_CPPFLAGS="$CPPFLAGS"
22283 CPPFLAGS="${CPPFLAGS} -Wno-sign-compare"
22284 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22285 /* end confdefs.h. */
22295 if ac_fn_c_try_cpp "$LINENO"; then :
22296 gl_cv_warn__Wno_sign_compare=yes
22298 gl_cv_warn__Wno_sign_compare=no
22300 rm -f conftest.err conftest.$ac_ext
22301 CPPFLAGS="$save_CPPFLAGS"
22304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn__Wno_sign_compare" >&5
22305 $as_echo "$gl_cv_warn__Wno_sign_compare" >&6; }
22306 if test "x$gl_cv_warn__Wno_sign_compare" = x""yes; then :
22307 as_fn_append WARN_CFLAGS " -Wno-sign-compare"
22309 # Too many warnings for now
22310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler handles -Wno-pointer-sign" >&5
22311 $as_echo_n "checking whether compiler handles -Wno-pointer-sign... " >&6; }
22312 if test "${gl_cv_warn__Wno_pointer_sign+set}" = set; then :
22313 $as_echo_n "(cached) " >&6
22316 save_CPPFLAGS="$CPPFLAGS"
22317 CPPFLAGS="${CPPFLAGS} -Wno-pointer-sign"
22318 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22319 /* end confdefs.h. */
22329 if ac_fn_c_try_cpp "$LINENO"; then :
22330 gl_cv_warn__Wno_pointer_sign=yes
22332 gl_cv_warn__Wno_pointer_sign=no
22334 rm -f conftest.err conftest.$ac_ext
22335 CPPFLAGS="$save_CPPFLAGS"
22338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn__Wno_pointer_sign" >&5
22339 $as_echo "$gl_cv_warn__Wno_pointer_sign" >&6; }
22340 if test "x$gl_cv_warn__Wno_pointer_sign" = x""yes; then :
22341 as_fn_append WARN_CFLAGS " -Wno-pointer-sign"
22343 # Too many warnings for now
22344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler handles -Wno-unused-parameter" >&5
22345 $as_echo_n "checking whether compiler handles -Wno-unused-parameter... " >&6; }
22346 if test "${gl_cv_warn__Wno_unused_parameter+set}" = set; then :
22347 $as_echo_n "(cached) " >&6
22350 save_CPPFLAGS="$CPPFLAGS"
22351 CPPFLAGS="${CPPFLAGS} -Wno-unused-parameter"
22352 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22353 /* end confdefs.h. */
22363 if ac_fn_c_try_cpp "$LINENO"; then :
22364 gl_cv_warn__Wno_unused_parameter=yes
22366 gl_cv_warn__Wno_unused_parameter=no
22368 rm -f conftest.err conftest.$ac_ext
22369 CPPFLAGS="$save_CPPFLAGS"
22372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn__Wno_unused_parameter" >&5
22373 $as_echo "$gl_cv_warn__Wno_unused_parameter" >&6; }
22374 if test "x$gl_cv_warn__Wno_unused_parameter" = x""yes; then :
22375 as_fn_append WARN_CFLAGS " -Wno-unused-parameter"
22377 # Too many warnings for now
22378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler handles -Wno-overflow" >&5
22379 $as_echo_n "checking whether compiler handles -Wno-overflow... " >&6; }
22380 if test "${gl_cv_warn__Wno_overflow+set}" = set; then :
22381 $as_echo_n "(cached) " >&6
22384 save_CPPFLAGS="$CPPFLAGS"
22385 CPPFLAGS="${CPPFLAGS} -Wno-overflow"
22386 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22387 /* end confdefs.h. */
22397 if ac_fn_c_try_cpp "$LINENO"; then :
22398 gl_cv_warn__Wno_overflow=yes
22400 gl_cv_warn__Wno_overflow=no
22402 rm -f conftest.err conftest.$ac_ext
22403 CPPFLAGS="$save_CPPFLAGS"
22406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn__Wno_overflow" >&5
22407 $as_echo "$gl_cv_warn__Wno_overflow" >&6; }
22408 if test "x$gl_cv_warn__Wno_overflow" = x""yes; then :
22409 as_fn_append WARN_CFLAGS " -Wno-overflow"
22412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler handles -Wno-type-limits" >&5
22413 $as_echo_n "checking whether compiler handles -Wno-type-limits... " >&6; }
22414 if test "${gl_cv_warn__Wno_type_limits+set}" = set; then :
22415 $as_echo_n "(cached) " >&6
22418 save_CPPFLAGS="$CPPFLAGS"
22419 CPPFLAGS="${CPPFLAGS} -Wno-type-limits"
22420 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22421 /* end confdefs.h. */
22431 if ac_fn_c_try_cpp "$LINENO"; then :
22432 gl_cv_warn__Wno_type_limits=yes
22434 gl_cv_warn__Wno_type_limits=no
22436 rm -f conftest.err conftest.$ac_ext
22437 CPPFLAGS="$save_CPPFLAGS"
22440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn__Wno_type_limits" >&5
22441 $as_echo "$gl_cv_warn__Wno_type_limits" >&6; }
22442 if test "x$gl_cv_warn__Wno_type_limits" = x""yes; then :
22443 as_fn_append WARN_CFLAGS " -Wno-type-limits"
22447 # In spite of excluding -Wlogical-op above, it is enabled, as of
22448 # gcc 4.5.0 20090517, and it provokes warnings in cat.c, dd.c, truncate.c
22449 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler handles -Wno-logical-op" >&5
22450 $as_echo_n "checking whether compiler handles -Wno-logical-op... " >&6; }
22451 if test "${gl_cv_warn__Wno_logical_op+set}" = set; then :
22452 $as_echo_n "(cached) " >&6
22455 save_CPPFLAGS="$CPPFLAGS"
22456 CPPFLAGS="${CPPFLAGS} -Wno-logical-op"
22457 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22458 /* end confdefs.h. */
22468 if ac_fn_c_try_cpp "$LINENO"; then :
22469 gl_cv_warn__Wno_logical_op=yes
22471 gl_cv_warn__Wno_logical_op=no
22473 rm -f conftest.err conftest.$ac_ext
22474 CPPFLAGS="$save_CPPFLAGS"
22477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn__Wno_logical_op" >&5
22478 $as_echo "$gl_cv_warn__Wno_logical_op" >&6; }
22479 if test "x$gl_cv_warn__Wno_logical_op" = x""yes; then :
22480 as_fn_append WARN_CFLAGS " -Wno-logical-op"
22484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler handles -fdiagnostics-show-option" >&5
22485 $as_echo_n "checking whether compiler handles -fdiagnostics-show-option... " >&6; }
22486 if test "${gl_cv_warn__fdiagnostics_show_option+set}" = set; then :
22487 $as_echo_n "(cached) " >&6
22490 save_CPPFLAGS="$CPPFLAGS"
22491 CPPFLAGS="${CPPFLAGS} -fdiagnostics-show-option"
22492 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22493 /* end confdefs.h. */
22503 if ac_fn_c_try_cpp "$LINENO"; then :
22504 gl_cv_warn__fdiagnostics_show_option=yes
22506 gl_cv_warn__fdiagnostics_show_option=no
22508 rm -f conftest.err conftest.$ac_ext
22509 CPPFLAGS="$save_CPPFLAGS"
22512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn__fdiagnostics_show_option" >&5
22513 $as_echo "$gl_cv_warn__fdiagnostics_show_option" >&6; }
22514 if test "x$gl_cv_warn__fdiagnostics_show_option" = x""yes; then :
22515 as_fn_append WARN_CFLAGS " -fdiagnostics-show-option"
22518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler handles -funit-at-a-time" >&5
22519 $as_echo_n "checking whether compiler handles -funit-at-a-time... " >&6; }
22520 if test "${gl_cv_warn__funit_at_a_time+set}" = set; then :
22521 $as_echo_n "(cached) " >&6
22524 save_CPPFLAGS="$CPPFLAGS"
22525 CPPFLAGS="${CPPFLAGS} -funit-at-a-time"
22526 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22527 /* end confdefs.h. */
22537 if ac_fn_c_try_cpp "$LINENO"; then :
22538 gl_cv_warn__funit_at_a_time=yes
22540 gl_cv_warn__funit_at_a_time=no
22542 rm -f conftest.err conftest.$ac_ext
22543 CPPFLAGS="$save_CPPFLAGS"
22546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn__funit_at_a_time" >&5
22547 $as_echo "$gl_cv_warn__funit_at_a_time" >&6; }
22548 if test "x$gl_cv_warn__funit_at_a_time" = x""yes; then :
22549 as_fn_append WARN_CFLAGS " -funit-at-a-time"
22556 $as_echo "#define lint 1" >>confdefs.h
22559 $as_echo "#define _FORTIFY_SOURCE 2" >>confdefs.h
22562 $as_echo "#define GNULIB_PORTCHECK 1" >>confdefs.h
22565 # We use a slightly smaller set of warning options for lib/.
22566 # Remove the following and save the result in GNULIB_WARN_CFLAGS.
22568 nw="$nw -Wuninitialized"
22569 nw="$nw -Wmissing-prototypes"
22570 nw="$nw -Wold-style-definition"
22573 set x $WARN_CFLAGS; shift
22577 *" $gl_warn_item "*)
22580 gl_warn_set="$gl_warn_set $gl_warn_item"
22584 GNULIB_WARN_CFLAGS=$gl_warn_set
22589 # cc -E produces incorrect asm files on SVR4, so postprocess it.
22590 ASCPPPOST="sed '/^ *#/d; s,//.*,,; s/% /%/g; s/\\. /./g'"
22593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for underline in external names" >&5
22594 $as_echo_n "checking for underline in external names... " >&6; }
22595 if test "${gzip_cv_underline+set}" = set; then :
22596 $as_echo_n "(cached) " >&6
22598 gzip_cv_underline=yes
22599 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22600 /* end confdefs.h. */
22601 int foo() {return 0;}
22610 if ac_fn_c_try_compile "$LINENO"; then :
22611 $NM conftest.$OBJEXT | grep _foo >/dev/null 2>&1 ||
22612 gzip_cv_underline=no
22614 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gzip_cv_underline" >&5
22617 $as_echo "$gzip_cv_underline" >&6; }
22619 if test $gzip_cv_underline = no; then
22620 ASCPPFLAGS='-DNO_UNDERLINE'
22625 # Try to assemble match.S.
22626 # "gcc -E match.s" ignores -E, so we must use _match.S.
22627 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an assembler syntax supported by this package" >&5
22628 $as_echo_n "checking for an assembler syntax supported by this package... " >&6; }
22629 if test "${gzip_cv_assembler+set}" = set; then :
22630 $as_echo_n "(cached) " >&6
22632 gzip_cv_assembler=no
22636 if cp $srcdir/lib/match.c _match.S &&
22637 eval "$CPP $CPPFLAGS $ASCPPFLAGS _match.S > _match.i" 2>/dev/null &&
22638 eval "$ASCPPPOST < _match.i > match_.s" 2>/dev/null; then
22639 if test ! -s match_.s || grep error < match_.s > /dev/null; then
22641 elif eval "$CC $CPPFLAGS $CFLAGS -c match_.s >/dev/null 2>&1" &&
22642 test -f match_.$OBJEXT; then
22643 rm -f match_.$OBJEXT
22644 gzip_cv_assembler=yes
22645 if echo 'void foo (void) {}' > conftest.c &&
22646 eval "$CC $CPPFLAGS $CFLAGS -S conftest.c >/dev/null 2>&1" &&
22647 grep '\.note\.GNU-stack' conftest.s >/dev/null 2>&1 &&
22648 eval "$CC $CPPFLAGS $CFLAGS -c -Wa,--noexecstack match_.s >/dev/null 2>&1" &&
22649 test -f match_.$OBJEXT; then
22650 gzip_cv_assembler='yes, with -Wa,--noexecstack'
22654 rm -f conftest* _match.i _match.S match_.s match_.$OBJEXT;;
22657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gzip_cv_assembler" >&5
22658 $as_echo "$gzip_cv_assembler" >&6; }
22659 if test "$gzip_cv_assembler" != no; then
22661 $as_echo "#define ASMV /**/" >>confdefs.h
22663 case " $LIBOBJS " in
22664 *" match.$ac_objext "* ) ;;
22665 *) LIBOBJS="$LIBOBJS match.$ac_objext"
22670 if test "$gzip_cv_assembler" = 'yes, with -Wa,--noexecstack'; then
22671 ASFLAGS_config='-Wa,--noexecstack'
22677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing strerror" >&5
22678 $as_echo_n "checking for library containing strerror... " >&6; }
22679 if test "${ac_cv_search_strerror+set}" = set; then :
22680 $as_echo_n "(cached) " >&6
22682 ac_func_search_save_LIBS=$LIBS
22683 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22684 /* end confdefs.h. */
22686 /* Override any GCC internal prototype to avoid an error.
22687 Use char because int might match the return type of a GCC
22688 builtin and then its argument prototype would still apply. */
22696 return strerror ();
22701 for ac_lib in '' cposix; do
22702 if test -z "$ac_lib"; then
22703 ac_res="none required"
22706 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
22708 if ac_fn_c_try_link "$LINENO"; then :
22709 ac_cv_search_strerror=$ac_res
22711 rm -f core conftest.err conftest.$ac_objext \
22713 if test "${ac_cv_search_strerror+set}" = set; then :
22717 if test "${ac_cv_search_strerror+set}" = set; then :
22720 ac_cv_search_strerror=no
22722 rm conftest.$ac_ext
22723 LIBS=$ac_func_search_save_LIBS
22725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_strerror" >&5
22726 $as_echo "$ac_cv_search_strerror" >&6; }
22727 ac_res=$ac_cv_search_strerror
22728 if test "$ac_res" != no; then :
22729 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
22733 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
22734 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
22735 if test "${ac_cv_c_const+set}" = set; then :
22736 $as_echo_n "(cached) " >&6
22738 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22739 /* end confdefs.h. */
22744 /* FIXME: Include the comments suggested by Paul. */
22745 #ifndef __cplusplus
22746 /* Ultrix mips cc rejects this. */
22747 typedef int charset[2];
22749 /* SunOS 4.1.1 cc rejects this. */
22750 char const *const *pcpcc;
22752 /* NEC SVR4.0.2 mips cc rejects this. */
22753 struct point {int x, y;};
22754 static struct point const zero = {0,0};
22755 /* AIX XL C 1.02.0.0 rejects this.
22756 It does not let you subtract one const X* pointer from another in
22757 an arm of an if-expression whose if-part is not a constant
22759 const char *g = "string";
22760 pcpcc = &g + (g ? g-g : 0);
22761 /* HPUX 7.0 cc rejects these. */
22763 ppc = (char**) pcpcc;
22764 pcpcc = (char const *const *) ppc;
22765 { /* SCO 3.2v4 cc rejects this. */
22767 char const *s = 0 ? (char *) 0 : (char const *) 0;
22772 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
22773 int x[] = {25, 17};
22774 const int *foo = &x[0];
22777 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
22778 typedef const int *iptr;
22782 { /* AIX XL C 1.02.0.0 rejects this saying
22783 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
22784 struct s { int j; const int *ap[3]; };
22785 struct s *b; b->j = 5;
22787 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
22788 const int foo = 10;
22789 if (!foo) return 0;
22791 return !cs[0] && !zero.x;
22798 if ac_fn_c_try_compile "$LINENO"; then :
22803 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
22806 $as_echo "$ac_cv_c_const" >&6; }
22807 if test $ac_cv_c_const = no; then
22809 $as_echo "#define const /**/" >>confdefs.h
22813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
22814 $as_echo_n "checking for ANSI C header files... " >&6; }
22815 if test "${ac_cv_header_stdc+set}" = set; then :
22816 $as_echo_n "(cached) " >&6
22818 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22819 /* end confdefs.h. */
22820 #include <stdlib.h>
22821 #include <stdarg.h>
22822 #include <string.h>
22833 if ac_fn_c_try_compile "$LINENO"; then :
22834 ac_cv_header_stdc=yes
22836 ac_cv_header_stdc=no
22838 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22840 if test $ac_cv_header_stdc = yes; then
22841 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
22842 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22843 /* end confdefs.h. */
22844 #include <string.h>
22847 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22848 $EGREP "memchr" >/dev/null 2>&1; then :
22851 ac_cv_header_stdc=no
22857 if test $ac_cv_header_stdc = yes; then
22858 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
22859 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22860 /* end confdefs.h. */
22861 #include <stdlib.h>
22864 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22865 $EGREP "free" >/dev/null 2>&1; then :
22868 ac_cv_header_stdc=no
22874 if test $ac_cv_header_stdc = yes; then
22875 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
22876 if test "$cross_compiling" = yes; then :
22879 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22880 /* end confdefs.h. */
22882 #include <stdlib.h>
22883 #if ((' ' & 0x0FF) == 0x020)
22884 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
22885 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
22887 # define ISLOWER(c) \
22888 (('a' <= (c) && (c) <= 'i') \
22889 || ('j' <= (c) && (c) <= 'r') \
22890 || ('s' <= (c) && (c) <= 'z'))
22891 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
22894 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
22899 for (i = 0; i < 256; i++)
22900 if (XOR (islower (i), ISLOWER (i))
22901 || toupper (i) != TOUPPER (i))
22906 if ac_fn_c_try_run "$LINENO"; then :
22909 ac_cv_header_stdc=no
22911 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22912 conftest.$ac_objext conftest.beam conftest.$ac_ext
22917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
22918 $as_echo "$ac_cv_header_stdc" >&6; }
22919 if test $ac_cv_header_stdc = yes; then
22921 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
22935 ac_header_dirent=no
22936 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
22937 as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
22938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5
22939 $as_echo_n "checking for $ac_hdr that defines DIR... " >&6; }
22940 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then :
22941 $as_echo_n "(cached) " >&6
22943 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22944 /* end confdefs.h. */
22945 #include <sys/types.h>
22957 if ac_fn_c_try_compile "$LINENO"; then :
22958 eval "$as_ac_Header=yes"
22960 eval "$as_ac_Header=no"
22962 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22964 eval ac_res=\$$as_ac_Header
22965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
22966 $as_echo "$ac_res" >&6; }
22967 eval as_val=\$$as_ac_Header
22968 if test "x$as_val" = x""yes; then :
22969 cat >>confdefs.h <<_ACEOF
22970 #define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
22973 ac_header_dirent=$ac_hdr; break
22977 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
22978 if test $ac_header_dirent = dirent.h; then
22979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
22980 $as_echo_n "checking for library containing opendir... " >&6; }
22981 if test "${ac_cv_search_opendir+set}" = set; then :
22982 $as_echo_n "(cached) " >&6
22984 ac_func_search_save_LIBS=$LIBS
22985 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22986 /* end confdefs.h. */
22988 /* Override any GCC internal prototype to avoid an error.
22989 Use char because int might match the return type of a GCC
22990 builtin and then its argument prototype would still apply. */
23003 for ac_lib in '' dir; do
23004 if test -z "$ac_lib"; then
23005 ac_res="none required"
23008 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
23010 if ac_fn_c_try_link "$LINENO"; then :
23011 ac_cv_search_opendir=$ac_res
23013 rm -f core conftest.err conftest.$ac_objext \
23015 if test "${ac_cv_search_opendir+set}" = set; then :
23019 if test "${ac_cv_search_opendir+set}" = set; then :
23022 ac_cv_search_opendir=no
23024 rm conftest.$ac_ext
23025 LIBS=$ac_func_search_save_LIBS
23027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
23028 $as_echo "$ac_cv_search_opendir" >&6; }
23029 ac_res=$ac_cv_search_opendir
23030 if test "$ac_res" != no; then :
23031 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
23036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
23037 $as_echo_n "checking for library containing opendir... " >&6; }
23038 if test "${ac_cv_search_opendir+set}" = set; then :
23039 $as_echo_n "(cached) " >&6
23041 ac_func_search_save_LIBS=$LIBS
23042 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23043 /* end confdefs.h. */
23045 /* Override any GCC internal prototype to avoid an error.
23046 Use char because int might match the return type of a GCC
23047 builtin and then its argument prototype would still apply. */
23060 for ac_lib in '' x; do
23061 if test -z "$ac_lib"; then
23062 ac_res="none required"
23065 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
23067 if ac_fn_c_try_link "$LINENO"; then :
23068 ac_cv_search_opendir=$ac_res
23070 rm -f core conftest.err conftest.$ac_objext \
23072 if test "${ac_cv_search_opendir+set}" = set; then :
23076 if test "${ac_cv_search_opendir+set}" = set; then :
23079 ac_cv_search_opendir=no
23081 rm conftest.$ac_ext
23082 LIBS=$ac_func_search_save_LIBS
23084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
23085 $as_echo "$ac_cv_search_opendir" >&6; }
23086 ac_res=$ac_cv_search_opendir
23087 if test "$ac_res" != no; then :
23088 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
23094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5
23095 $as_echo_n "checking return type of signal handlers... " >&6; }
23096 if test "${ac_cv_type_signal+set}" = set; then :
23097 $as_echo_n "(cached) " >&6
23099 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23100 /* end confdefs.h. */
23101 #include <sys/types.h>
23102 #include <signal.h>
23107 return *(signal (0, 0)) (0) == 1;
23112 if ac_fn_c_try_compile "$LINENO"; then :
23113 ac_cv_type_signal=int
23115 ac_cv_type_signal=void
23117 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5
23120 $as_echo "$ac_cv_type_signal" >&6; }
23122 cat >>confdefs.h <<_ACEOF
23123 #define RETSIGTYPE $ac_cv_type_signal
23127 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
23128 if test "x$ac_cv_type_size_t" = x""yes; then :
23132 cat >>confdefs.h <<_ACEOF
23133 #define size_t unsigned int
23138 ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default"
23139 if test "x$ac_cv_type_off_t" = x""yes; then :
23143 cat >>confdefs.h <<_ACEOF
23144 #define off_t long int
23150 ac_config_files="$ac_config_files Makefile doc/Makefile lib/Makefile"
23152 cat >confcache <<\_ACEOF
23153 # This file is a shell script that caches the results of configure
23154 # tests run on this system so they can be shared between configure
23155 # scripts and configure runs, see configure's option --config-cache.
23156 # It is not useful on other systems. If it contains results you don't
23157 # want to keep, you may remove or edit it.
23159 # config.status only pays attention to the cache file if you give it
23160 # the --recheck option to rerun configure.
23162 # `ac_cv_env_foo' variables (set or unset) will be overridden when
23163 # loading this file, other *unset* `ac_cv_foo' will be assigned the
23164 # following values.
23168 # The following way of writing the cache mishandles newlines in values,
23169 # but we know of no workaround that is simple, portable, and efficient.
23170 # So, we kill variables containing newlines.
23171 # Ultrix sh set writes to stderr and can't be redirected directly,
23172 # and sets the high bit in the cache file unless we assign to the vars.
23174 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
23175 eval ac_val=\$$ac_var
23179 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
23180 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
23183 _ | IFS | as_nl) ;; #(
23184 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
23185 *) { eval $ac_var=; unset $ac_var;} ;;
23191 case $as_nl`(ac_space=' '; set) 2>&1` in #(
23192 *${as_nl}ac_space=\ *)
23193 # `set' does not quote correctly, so add quotes: double-quote
23194 # substitution turns \\\\ into \\, and sed turns \\ into \.
23197 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
23200 # `set' quotes correctly as required by POSIX, so do not add quotes.
23201 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
23210 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
23212 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
23214 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
23215 if test -w "$cache_file"; then
23216 test "x$cache_file" != "x/dev/null" &&
23217 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
23218 $as_echo "$as_me: updating cache $cache_file" >&6;}
23219 cat confcache >$cache_file
23221 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
23222 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
23227 test "x$prefix" = xNONE && prefix=$ac_default_prefix
23228 # Let make expand exec_prefix.
23229 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
23231 DEFS=-DHAVE_CONFIG_H
23235 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
23236 # 1. Remove the extension, and $U if already installed.
23237 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
23238 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
23239 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
23240 # will be set to the directory where LIBOBJS objects are built.
23241 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
23242 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
23244 LIBOBJS=$ac_libobjs
23246 LTLIBOBJS=$ac_ltlibobjs
23249 if test -n "$EXEEXT"; then
23251 am__EXEEXT_FALSE='#'
23253 am__EXEEXT_TRUE='#'
23257 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
23258 as_fn_error "conditional \"AMDEP\" was never defined.
23259 Usually this means the macro was only invoked conditionally." "$LINENO" 5
23261 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
23262 as_fn_error "conditional \"am__fastdepCC\" was never defined.
23263 Usually this means the macro was only invoked conditionally." "$LINENO" 5
23265 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
23266 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
23267 Usually this means the macro was only invoked conditionally." "$LINENO" 5
23270 if test -z "${GNU_MAKE_TRUE}" && test -z "${GNU_MAKE_FALSE}"; then
23271 as_fn_error "conditional \"GNU_MAKE\" was never defined.
23272 Usually this means the macro was only invoked conditionally." "$LINENO" 5
23278 if test -n "$gl_LIBOBJS"; then
23279 # Remove the extension.
23280 sed_drop_objext='s/\.o$//;s/\.obj$//'
23281 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
23282 gl_libobjs="$gl_libobjs $i.$ac_objext"
23283 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
23286 gl_LIBOBJS=$gl_libobjs
23288 gl_LTLIBOBJS=$gl_ltlibobjs
23294 if test -n "$gltests_LIBOBJS"; then
23295 # Remove the extension.
23296 sed_drop_objext='s/\.o$//;s/\.obj$//'
23297 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
23298 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
23299 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
23302 gltests_LIBOBJS=$gltests_libobjs
23304 gltests_LTLIBOBJS=$gltests_ltlibobjs
23308 : ${CONFIG_STATUS=./config.status}
23310 ac_clean_files_save=$ac_clean_files
23311 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
23312 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
23313 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
23315 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
23317 # Generated by $as_me.
23318 # Run this file to recreate the current configuration.
23319 # Compiler output produced by configure, useful for debugging
23320 # configure, is in config.log if it exists.
23323 ac_cs_recheck=false
23326 SHELL=\${CONFIG_SHELL-$SHELL}
23329 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
23330 ## -------------------- ##
23331 ## M4sh Initialization. ##
23332 ## -------------------- ##
23334 # Be more Bourne compatible
23335 DUALCASE=1; export DUALCASE # for MKS sh
23336 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
23339 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23340 # is contrary to our usage. Disable this feature.
23341 alias -g '${1+"$@"}'='"$@"'
23342 setopt NO_GLOB_SUBST
23344 case `(set -o) 2>/dev/null` in #(
23356 # Printing a long string crashes Solaris 7 /usr/bin/printf.
23357 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
23358 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
23359 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
23360 # Prefer a ksh shell builtin over an external printf program on Solaris,
23361 # but without wasting forks for bash or zsh.
23362 if test -z "$BASH_VERSION$ZSH_VERSION" \
23363 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
23364 as_echo='print -r --'
23365 as_echo_n='print -rn --'
23366 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
23367 as_echo='printf %s\n'
23368 as_echo_n='printf %s'
23370 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
23371 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
23372 as_echo_n='/usr/ucb/echo -n'
23374 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
23375 as_echo_n_body='eval
23379 expr "X$arg" : "X\\(.*\\)$as_nl";
23380 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
23382 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
23384 export as_echo_n_body
23385 as_echo_n='sh -c $as_echo_n_body as_echo'
23387 export as_echo_body
23388 as_echo='sh -c $as_echo_body as_echo'
23391 # The user is always right.
23392 if test "${PATH_SEPARATOR+set}" != set; then
23394 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
23395 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
23402 # We need space, tab and new line, in precisely that order. Quoting is
23403 # there to prevent editors from complaining about space-tab.
23404 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
23405 # splitting by setting IFS to empty value.)
23408 # Find who we are. Look in the path if we contain no directory separator.
23410 *[\\/]* ) as_myself=$0 ;;
23411 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23412 for as_dir in $PATH
23415 test -z "$as_dir" && as_dir=.
23416 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
23422 # We did not find ourselves, most probably we were run as `sh COMMAND'
23423 # in which case we are not to be found in the path.
23424 if test "x$as_myself" = x; then
23427 if test ! -f "$as_myself"; then
23428 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
23432 # Unset variables that we do not need and which cause bugs (e.g. in
23433 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
23434 # suppresses any "Segmentation fault" message there. '((' could
23435 # trigger a bug in pdksh 5.2.14.
23436 for as_var in BASH_ENV ENV MAIL MAILPATH
23437 do eval test x\${$as_var+set} = xset \
23438 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
23451 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
23454 # as_fn_error ERROR [LINENO LOG_FD]
23455 # ---------------------------------
23456 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
23457 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
23458 # script with status $?, using 1 if that was 0.
23461 as_status=$?; test $as_status -eq 0 && as_status=1
23463 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
23464 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
23466 $as_echo "$as_me: error: $1" >&2
23467 as_fn_exit $as_status
23471 # as_fn_set_status STATUS
23472 # -----------------------
23473 # Set $? to STATUS, without forking.
23474 as_fn_set_status ()
23477 } # as_fn_set_status
23479 # as_fn_exit STATUS
23480 # -----------------
23481 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
23485 as_fn_set_status $1
23491 # Portably unset VAR.
23494 { eval $1=; unset $1;}
23496 as_unset=as_fn_unset
23497 # as_fn_append VAR VALUE
23498 # ----------------------
23499 # Append the text in VALUE to the end of the definition contained in VAR. Take
23500 # advantage of any shell optimizations that allow amortized linear growth over
23501 # repeated appends, instead of the typical quadratic growth present in naive
23503 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
23504 eval 'as_fn_append ()
23515 # as_fn_arith ARG...
23516 # ------------------
23517 # Perform arithmetic evaluation on the ARGs, and store the result in the
23518 # global $as_val. Take advantage of shells that can avoid forks. The arguments
23519 # must be portable across $(()) and expr.
23520 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
23521 eval 'as_fn_arith ()
23528 as_val=`expr "$@" || test $? -eq 1`
23533 if expr a : '\(a\)' >/dev/null 2>&1 &&
23534 test "X`expr 00001 : '.*\(...\)'`" = X001; then
23540 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
23541 as_basename=basename
23546 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
23552 as_me=`$as_basename -- "$0" ||
23553 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
23554 X"$0" : 'X\(//\)$' \| \
23555 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
23557 sed '/^.*\/\([^/][^/]*\)\/*$/{
23571 # Avoid depending upon Character Ranges.
23572 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
23573 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
23574 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
23575 as_cr_digits='0123456789'
23576 as_cr_alnum=$as_cr_Letters$as_cr_digits
23578 ECHO_C= ECHO_N= ECHO_T=
23579 case `echo -n x` in #(((((
23581 case `echo 'xy\c'` in
23582 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
23584 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
23591 rm -f conf$$ conf$$.exe conf$$.file
23592 if test -d conf$$.dir; then
23593 rm -f conf$$.dir/conf$$.file
23596 mkdir conf$$.dir 2>/dev/null
23598 if (echo >conf$$.file) 2>/dev/null; then
23599 if ln -s conf$$.file conf$$ 2>/dev/null; then
23601 # ... but there are two gotchas:
23602 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
23603 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
23604 # In both cases, we have to default to `cp -p'.
23605 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
23607 elif ln conf$$.file conf$$ 2>/dev/null; then
23615 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
23616 rmdir conf$$.dir 2>/dev/null
23621 # Create "$as_dir" as a directory, including parents if necessary.
23626 -*) as_dir=./$as_dir;;
23628 test -d "$as_dir" || eval $as_mkdir_p || {
23632 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
23633 *) as_qdir=$as_dir;;
23635 as_dirs="'$as_qdir' $as_dirs"
23636 as_dir=`$as_dirname -- "$as_dir" ||
23637 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23638 X"$as_dir" : 'X\(//\)[^/]' \| \
23639 X"$as_dir" : 'X\(//\)$' \| \
23640 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
23641 $as_echo X"$as_dir" |
23642 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
23646 /^X\(\/\/\)[^/].*/{
23659 test -d "$as_dir" && break
23661 test -z "$as_dirs" || eval "mkdir $as_dirs"
23662 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
23666 if mkdir -p . 2>/dev/null; then
23667 as_mkdir_p='mkdir -p "$as_dir"'
23669 test -d ./-p && rmdir ./-p
23673 if test -x / >/dev/null 2>&1; then
23674 as_test_x='test -x'
23676 if ls -dL / >/dev/null 2>&1; then
23683 if test -d "$1"; then
23689 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
23690 ???[sx]*):;;*)false;;esac;fi
23694 as_executable_p=$as_test_x
23696 # Sed expression to map a string onto a valid CPP name.
23697 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
23699 # Sed expression to map a string onto a valid variable name.
23700 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
23704 ## ----------------------------------- ##
23705 ## Main body of $CONFIG_STATUS script. ##
23706 ## ----------------------------------- ##
23708 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
23710 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23711 # Save the log message, to keep $0 and so on meaningful, and to
23712 # report actual input values of CONFIG_FILES etc. instead of their
23713 # values after options handling.
23715 This file was extended by gzip $as_me 1.4, which was
23716 generated by GNU Autoconf 2.65.23-13e35. Invocation command line was
23718 CONFIG_FILES = $CONFIG_FILES
23719 CONFIG_HEADERS = $CONFIG_HEADERS
23720 CONFIG_LINKS = $CONFIG_LINKS
23721 CONFIG_COMMANDS = $CONFIG_COMMANDS
23724 on `(hostname || uname -n) 2>/dev/null | sed 1q`
23729 case $ac_config_files in *"
23730 "*) set x $ac_config_files; shift; ac_config_files=$*;;
23733 case $ac_config_headers in *"
23734 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
23738 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23739 # Files that config.status was made for.
23740 config_files="$ac_config_files"
23741 config_headers="$ac_config_headers"
23742 config_links="$ac_config_links"
23743 config_commands="$ac_config_commands"
23747 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23749 \`$as_me' instantiates files and other configuration actions
23750 from templates according to the current configuration. Unless the files
23751 and actions are specified as TAGs, all are instantiated by default.
23753 Usage: $0 [OPTION]... [TAG]...
23755 -h, --help print this help, then exit
23756 -V, --version print version number and configuration settings, then exit
23757 --config print configuration, then exit
23758 -q, --quiet, --silent
23759 do not print progress messages
23760 -d, --debug don't remove temporary files
23761 --recheck update $as_me by reconfiguring in the same conditions
23762 --file=FILE[:TEMPLATE]
23763 instantiate the configuration file FILE
23764 --header=FILE[:TEMPLATE]
23765 instantiate the configuration header FILE
23767 Configuration files:
23770 Configuration headers:
23773 Configuration links:
23776 Configuration commands:
23779 Report bugs to <bug-gzip@gnu.org>."
23782 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23783 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
23785 gzip config.status 1.4
23786 configured by $0, generated by GNU Autoconf 2.65.23-13e35,
23787 with options \\"\$ac_cs_config\\"
23789 Copyright (C) 2010 Free Software Foundation, Inc.
23790 This config.status script is free software; the Free Software Foundation
23791 gives unlimited permission to copy, distribute and modify it."
23798 test -n "\$AWK" || AWK=awk
23801 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23802 # The default lists apply if the user does not specify any file.
23808 ac_option=`expr "X$1" : 'X\([^=]*\)='`
23809 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
23820 # Handling of the options.
23821 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
23823 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
23824 $as_echo "$ac_cs_version"; exit ;;
23825 --config | --confi | --conf | --con | --co | --c )
23826 $as_echo "$ac_cs_config"; exit ;;
23827 --debug | --debu | --deb | --de | --d | -d )
23829 --file | --fil | --fi | --f )
23832 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
23834 as_fn_append CONFIG_FILES " '$ac_optarg'"
23835 ac_need_defaults=false;;
23836 --header | --heade | --head | --hea )
23839 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
23841 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
23842 ac_need_defaults=false;;
23844 # Conflict between --help and --header
23845 as_fn_error "ambiguous option: \`$1'
23846 Try \`$0 --help' for more information.";;
23847 --help | --hel | -h )
23848 $as_echo "$ac_cs_usage"; exit ;;
23849 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
23850 | -silent | --silent | --silen | --sile | --sil | --si | --s)
23853 # This is an error.
23854 -*) as_fn_error "unrecognized option: \`$1'
23855 Try \`$0 --help' for more information." ;;
23857 *) as_fn_append ac_config_targets " $1"
23858 ac_need_defaults=false ;;
23864 ac_configure_extra_args=
23866 if $ac_cs_silent; then
23868 ac_configure_extra_args="$ac_configure_extra_args --silent"
23872 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23873 if \$ac_cs_recheck; then
23874 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
23876 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
23877 CONFIG_SHELL='$SHELL'
23878 export CONFIG_SHELL
23883 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23887 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
23888 ## Running $as_me. ##
23894 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23898 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
23899 GNUmakefile=$GNUmakefile
23903 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23905 # Handling of arguments.
23906 for ac_config_target in $ac_config_targets
23908 case $ac_config_target in
23909 "lib/config.h") CONFIG_HEADERS="$CONFIG_HEADERS lib/config.h:lib/config.hin" ;;
23910 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
23911 "$GNUmakefile") CONFIG_LINKS="$CONFIG_LINKS $GNUmakefile:$GNUmakefile" ;;
23912 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
23913 "doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
23914 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
23916 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
23921 # If the user did not use the arguments to specify the items to instantiate,
23922 # then the envvar interface is used. Set only those that are not.
23923 # We use the long form for the default assignment because of an extremely
23924 # bizarre bug on SunOS 4.1.3.
23925 if $ac_need_defaults; then
23926 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
23927 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
23928 test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
23929 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
23932 # Have a temporary directory for convenience. Make it in the build tree
23933 # simply because there is no reason against having it here, and in addition,
23934 # creating and moving files from /tmp can sometimes cause problems.
23935 # Hook for its removal unless debugging.
23936 # Note that there is a small window in which the directory will not be cleaned:
23937 # after its creation but before its name has been assigned to `$tmp'.
23941 trap 'exit_status=$?
23942 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
23944 trap 'as_fn_exit 1' 1 2 13 15
23946 # Create a (secure) tmp directory for tmp files.
23949 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
23950 test -n "$tmp" && test -d "$tmp"
23953 tmp=./conf$$-$RANDOM
23954 (umask 077 && mkdir "$tmp")
23955 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
23957 # Set up the scripts for CONFIG_FILES section.
23958 # No need to generate them if there are no CONFIG_FILES.
23959 # This happens for instance with `./config.status config.h'.
23960 if test -n "$CONFIG_FILES"; then
23963 ac_cr=`echo X | tr X '\015'`
23964 # On cygwin, bash can eat \r inside `` if the user requested igncr.
23965 # But we know of no other shell where ac_cr would be empty at this
23966 # point, so we can use a bashism as a fallback.
23967 if test "x$ac_cr" = x; then
23968 eval ac_cr=\$\'\\r\'
23970 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
23971 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
23974 ac_cs_awk_cr=$ac_cr
23977 echo 'BEGIN {' >"$tmp/subs1.awk" &&
23982 echo "cat >conf$$subs.awk <<_ACEOF" &&
23983 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
23985 } >conf$$subs.sh ||
23986 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
23987 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
23989 for ac_last_try in false false false false false :; do
23990 . ./conf$$subs.sh ||
23991 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
23993 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
23994 if test $ac_delim_n = $ac_delim_num; then
23996 elif $ac_last_try; then
23997 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
23999 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
24002 rm -f conf$$subs.sh
24004 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24005 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
24009 s/^/S["/; s/!.*/"]=/
24019 s/\(.\{148\}\)..*/\1/
24021 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
24026 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
24033 s/\(.\{148\}\)..*/\1/
24035 s/["\\]/\\&/g; s/^/"/; s/$/"/
24039 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
24044 ' <conf$$subs.awk | sed '
24049 ' >>$CONFIG_STATUS || ac_write_fail=1
24050 rm -f conf$$subs.awk
24051 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24053 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
24054 for (key in S) S_is_set[key] = 1
24060 nfields = split(line, field, "@")
24062 len = length(field[1])
24063 for (i = 2; i < nfields; i++) {
24065 keylen = length(key)
24066 if (S_is_set[key]) {
24068 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
24069 len += length(value) + length(field[++i])
24080 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24081 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
24082 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
24085 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
24086 || as_fn_error "could not setup config files machinery" "$LINENO" 5
24089 # VPATH may cause trouble with some makes, so we remove $(srcdir),
24090 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
24091 # trailing colons and then remove the whole line if VPATH becomes empty
24092 # (actually we leave an empty line to preserve line numbers).
24093 if test "x$srcdir" = x.; then
24094 ac_vpsub='/^[ ]*VPATH[ ]*=/{
24095 s/:*\$(srcdir):*/:/
24096 s/:*\${srcdir}:*/:/
24098 s/^\([^=]*=[ ]*\):*/\1/
24104 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24105 fi # test -n "$CONFIG_FILES"
24107 # Set up the scripts for CONFIG_HEADERS section.
24108 # No need to generate them if there are no CONFIG_HEADERS.
24109 # This happens for instance with `./config.status Makefile'.
24110 if test -n "$CONFIG_HEADERS"; then
24111 cat >"$tmp/defines.awk" <<\_ACAWK ||
24115 # Transform confdefs.h into an awk script `defines.awk', embedded as
24116 # here-document in config.status, that substitutes the proper values into
24117 # config.h.in to produce config.h.
24119 # Create a delimiter string that does not exist in confdefs.h, to ease
24120 # handling of long lines.
24122 for ac_last_try in false false :; do
24123 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
24124 if test -z "$ac_t"; then
24126 elif $ac_last_try; then
24127 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
24129 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
24133 # For the awk script, D is an array of macro values keyed by name,
24134 # likewise P contains macro parameters if any. Preserve backslash
24135 # newline sequences.
24137 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
24139 s/.\{148\}/&'"$ac_delim"'/g
24142 s/^[ ]*#[ ]*define[ ][ ]*/ /
24149 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
24151 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
24155 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
24156 D["\1"]=" \3\\\\\\n"\\/p
24158 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
24163 s/.\{148\}/&'"$ac_delim"'/g
24168 s/["\\]/\\&/g; s/^/"/; s/$/"/p
24171 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
24173 ' <confdefs.h | sed '
24174 s/'"$ac_delim"'/"\\\
24175 "/g' >>$CONFIG_STATUS || ac_write_fail=1
24177 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24178 for (key in D) D_is_set[key] = 1
24181 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
24183 split(line, arg, " ")
24184 if (arg[1] == "#") {
24188 defundef = substr(arg[1], 2)
24191 split(mac1, mac2, "(") #)
24193 prefix = substr(line, 1, index(line, defundef) - 1)
24194 if (D_is_set[macro]) {
24195 # Preserve the white space surrounding the "#".
24196 print prefix "define", macro P[macro] D[macro]
24199 # Replace #undef with comments. This is necessary, for example,
24200 # in the case of _POSIX_SOURCE, which is predefined and required
24201 # on some systems where configure will not decide to define it.
24202 if (defundef == "undef") {
24203 print "/*", prefix defundef, macro, "*/"
24211 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24212 as_fn_error "could not setup config headers machinery" "$LINENO" 5
24213 fi # test -n "$CONFIG_HEADERS"
24216 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :L $CONFIG_LINKS :C $CONFIG_COMMANDS"
24221 :[FHLC]) ac_mode=$ac_tag; continue;;
24223 case $ac_mode$ac_tag in
24225 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
24226 :[FH]-) ac_tag=-:-;;
24227 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
24244 -) ac_f="$tmp/stdin";;
24245 *) # Look for the file first in the build tree, then in the source tree
24246 # (if the path is not absolute). The absolute path cannot be DOS-style,
24247 # because $ac_f cannot contain `:'.
24251 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
24253 { as_fn_set_status 1
24254 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5; };;
24256 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
24257 as_fn_append ac_file_inputs " '$ac_f'"
24260 # Let's still pretend it is `configure' which instantiates (i.e., don't
24261 # use $as_me), people would be surprised to read:
24262 # /* config.h. Generated by config.status. */
24263 configure_input='Generated from '`
24264 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
24266 if test x"$ac_file" != x-; then
24267 configure_input="$ac_file. $configure_input"
24268 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
24269 $as_echo "$as_me: creating $ac_file" >&6;}
24271 # Neutralize special characters interpreted by sed in replacement strings.
24272 case $configure_input in #(
24273 *\&* | *\|* | *\\* )
24274 ac_sed_conf_input=`$as_echo "$configure_input" |
24275 sed 's/[\\\\&|]/\\\\&/g'`;; #(
24276 *) ac_sed_conf_input=$configure_input;;
24280 *:-:* | *:-) cat >"$tmp/stdin" \
24281 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
24286 ac_dir=`$as_dirname -- "$ac_file" ||
24287 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24288 X"$ac_file" : 'X\(//\)[^/]' \| \
24289 X"$ac_file" : 'X\(//\)$' \| \
24290 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
24291 $as_echo X"$ac_file" |
24292 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
24296 /^X\(\/\/\)[^/].*/{
24309 as_dir="$ac_dir"; as_fn_mkdir_p
24313 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
24315 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
24316 # A ".." for each directory in $ac_dir_suffix.
24317 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
24318 case $ac_top_builddir_sub in
24319 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
24320 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
24323 ac_abs_top_builddir=$ac_pwd
24324 ac_abs_builddir=$ac_pwd$ac_dir_suffix
24325 # for backward compatibility:
24326 ac_top_builddir=$ac_top_build_prefix
24329 .) # We are building in place.
24331 ac_top_srcdir=$ac_top_builddir_sub
24332 ac_abs_top_srcdir=$ac_pwd ;;
24333 [\\/]* | ?:[\\/]* ) # Absolute name.
24334 ac_srcdir=$srcdir$ac_dir_suffix;
24335 ac_top_srcdir=$srcdir
24336 ac_abs_top_srcdir=$srcdir ;;
24337 *) # Relative name.
24338 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
24339 ac_top_srcdir=$ac_top_build_prefix$srcdir
24340 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
24342 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
24352 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
24353 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
24355 ac_MKDIR_P=$MKDIR_P
24357 [\\/$]* | ?:[\\/]* ) ;;
24358 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
24362 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24363 # If the template does not know about datarootdir, expand it.
24364 # FIXME: This hack should be removed a few years after 2.60.
24365 ac_datarootdir_hack=; ac_datarootdir_seen=
24376 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
24377 *datarootdir*) ac_datarootdir_seen=yes;;
24378 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
24379 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
24380 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
24382 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24383 ac_datarootdir_hack='
24384 s&@datadir@&$datadir&g
24385 s&@docdir@&$docdir&g
24386 s&@infodir@&$infodir&g
24387 s&@localedir@&$localedir&g
24388 s&@mandir@&$mandir&g
24389 s&\\\${datarootdir}&$datarootdir&g' ;;
24393 # Neutralize VPATH when `$srcdir' = `.'.
24394 # Shell code in configure.ac might set extrasub.
24395 # FIXME: do we really want to maintain this feature?
24396 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24397 ac_sed_extra="$ac_vpsub
24400 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24402 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
24403 s|@configure_input@|$ac_sed_conf_input|;t t
24404 s&@top_builddir@&$ac_top_builddir_sub&;t t
24405 s&@top_build_prefix@&$ac_top_build_prefix&;t t
24406 s&@srcdir@&$ac_srcdir&;t t
24407 s&@abs_srcdir@&$ac_abs_srcdir&;t t
24408 s&@top_srcdir@&$ac_top_srcdir&;t t
24409 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
24410 s&@builddir@&$ac_builddir&;t t
24411 s&@abs_builddir@&$ac_abs_builddir&;t t
24412 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
24413 s&@INSTALL@&$ac_INSTALL&;t t
24414 s&@MKDIR_P@&$ac_MKDIR_P&;t t
24415 $ac_datarootdir_hack
24417 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
24418 || as_fn_error "could not create $ac_file" "$LINENO" 5
24420 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
24421 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
24422 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
24423 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
24424 which seems to be undefined. Please make sure it is defined." >&5
24425 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
24426 which seems to be undefined. Please make sure it is defined." >&2;}
24430 -) cat "$tmp/out" && rm -f "$tmp/out";;
24431 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
24433 || as_fn_error "could not create $ac_file" "$LINENO" 5
24439 if test x"$ac_file" != x-; then
24441 $as_echo "/* $configure_input */" \
24442 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
24443 } >"$tmp/config.h" \
24444 || as_fn_error "could not create $ac_file" "$LINENO" 5
24445 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
24446 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
24447 $as_echo "$as_me: $ac_file is unchanged" >&6;}
24450 mv "$tmp/config.h" "$ac_file" \
24451 || as_fn_error "could not create $ac_file" "$LINENO" 5
24454 $as_echo "/* $configure_input */" \
24455 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
24456 || as_fn_error "could not create -" "$LINENO" 5
24458 # Compute "$ac_file"'s index in $config_headers.
24461 for _am_header in $config_headers :; do
24462 case $_am_header in
24463 $_am_arg | $_am_arg:* )
24466 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
24469 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
24470 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24471 X"$_am_arg" : 'X\(//\)[^/]' \| \
24472 X"$_am_arg" : 'X\(//\)$' \| \
24473 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
24474 $as_echo X"$_am_arg" |
24475 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
24479 /^X\(\/\/\)[^/].*/{
24491 s/.*/./; q'`/stamp-h$_am_stamp_count
24498 if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
24501 # Prefer the file from the source tree if names are identical.
24502 if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
24503 ac_source=$srcdir/$ac_source
24506 { $as_echo "$as_me:${as_lineno-$LINENO}: linking $ac_source to $ac_file" >&5
24507 $as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
24509 if test ! -r "$ac_source"; then
24510 as_fn_error "$ac_source: file not found" "$LINENO" 5
24514 # Try a relative symlink, then a hard link, then a copy.
24516 [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
24517 *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
24519 ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
24520 ln "$ac_source" "$ac_file" 2>/dev/null ||
24521 cp -p "$ac_source" "$ac_file" ||
24522 as_fn_error "cannot link or copy $ac_source to $ac_file" "$LINENO" 5
24525 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
24526 $as_echo "$as_me: executing $ac_file commands" >&6;}
24531 case $ac_file$ac_mode in
24532 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
24533 # Autoconf 2.62 quotes --file arguments for eval, but not when files
24534 # are listed without --file. Let's play safe and only enable the eval
24535 # if we detect the quoting.
24536 case $CONFIG_FILES in
24537 *\'*) eval set x "$CONFIG_FILES" ;;
24538 *) set x $CONFIG_FILES ;;
24543 # Strip MF so we end up with the name of the file.
24544 mf=`echo "$mf" | sed -e 's/:.*$//'`
24545 # Check whether this is an Automake generated Makefile or not.
24546 # We used to match only the files named `Makefile.in', but
24547 # some people rename them; so instead we look at the file content.
24548 # Grep'ing the first line is not enough: some people post-process
24549 # each Makefile.in and add a new line on top of each file to say so.
24550 # Grep'ing the whole file is not good either: AIX grep has a line
24551 # limit of 2048, but all sed's we know have understand at least 4000.
24552 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
24553 dirpart=`$as_dirname -- "$mf" ||
24554 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24555 X"$mf" : 'X\(//\)[^/]' \| \
24556 X"$mf" : 'X\(//\)$' \| \
24557 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
24559 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
24563 /^X\(\/\/\)[^/].*/{
24579 # Extract the definition of DEPDIR, am__include, and am__quote
24580 # from the Makefile without running `make'.
24581 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
24582 test -z "$DEPDIR" && continue
24583 am__include=`sed -n 's/^am__include = //p' < "$mf"`
24584 test -z "am__include" && continue
24585 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
24586 # When using ansi2knr, U may be empty or an underscore; expand it
24587 U=`sed -n 's/^U = //p' < "$mf"`
24588 # Find all dependency output files, they are included files with
24589 # $(DEPDIR) in their names. We invoke sed twice because it is the
24590 # simplest approach to changing $(DEPDIR) to its actual value in the
24592 for file in `sed -n "
24593 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
24594 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
24595 # Make sure the directory exists.
24596 test -f "$dirpart/$file" && continue
24597 fdir=`$as_dirname -- "$file" ||
24598 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24599 X"$file" : 'X\(//\)[^/]' \| \
24600 X"$file" : 'X\(//\)$' \| \
24601 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
24602 $as_echo X"$file" |
24603 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
24607 /^X\(\/\/\)[^/].*/{
24620 as_dir=$dirpart/$fdir; as_fn_mkdir_p
24621 # echo "creating $dirpart/$file"
24622 echo '# dummy' > "$dirpart/$file"
24634 ac_clean_files=$ac_clean_files_save
24636 test $ac_write_fail = 0 ||
24637 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
24640 # configure is writing to config.log, and then calls config.status.
24641 # config.status does its own redirection, appending to config.log.
24642 # Unfortunately, on DOS this fails, as config.log is still kept open
24643 # by configure, so config.status won't be able to write to it; its
24644 # output is simply discarded. So we exec the FD to /dev/null,
24645 # effectively closing config.log, so it can be properly (re)opened and
24646 # appended to by config.status. When coming back to configure, we
24647 # need to make the FD available again.
24648 if test "$no_create" != yes; then
24650 ac_config_status_args=
24651 test "$silent" = yes &&
24652 ac_config_status_args="$ac_config_status_args --quiet"
24654 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
24656 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
24657 # would make configure fail if this is the last instruction.
24658 $ac_cs_success || as_fn_exit 1
24660 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
24661 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
24662 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}