2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.69 for GNU tar 1.27.1.
5 # Report bugs to <bug-tar@gnu.org>.
8 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
11 # This configure script is free software; the Free Software Foundation
12 # gives unlimited permission to copy, distribute and modify it.
13 ## -------------------- ##
14 ## M4sh Initialization. ##
15 ## -------------------- ##
17 # Be more Bourne compatible
18 DUALCASE=1; export DUALCASE # for MKS sh
19 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
22 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23 # is contrary to our usage. Disable this feature.
24 alias -g '${1+"$@"}'='"$@"'
27 case `(set -o) 2>/dev/null` in #(
39 # Printing a long string crashes Solaris 7 /usr/bin/printf.
40 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
41 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
42 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
43 # Prefer a ksh shell builtin over an external printf program on Solaris,
44 # but without wasting forks for bash or zsh.
45 if test -z "$BASH_VERSION$ZSH_VERSION" \
46 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
48 as_echo_n='print -rn --'
49 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
53 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
54 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
55 as_echo_n='/usr/ucb/echo -n'
57 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
62 expr "X$arg" : "X\\(.*\\)$as_nl";
63 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
65 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
68 as_echo_n='sh -c $as_echo_n_body as_echo'
71 as_echo='sh -c $as_echo_body as_echo'
74 # The user is always right.
75 if test "${PATH_SEPARATOR+set}" != set; then
77 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
78 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
85 # We need space, tab and new line, in precisely that order. Quoting is
86 # there to prevent editors from complaining about space-tab.
87 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
88 # splitting by setting IFS to empty value.)
91 # Find who we are. Look in the path if we contain no directory separator.
94 *[\\/]* ) as_myself=$0 ;;
95 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
99 test -z "$as_dir" && as_dir=.
100 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
106 # We did not find ourselves, most probably we were run as `sh COMMAND'
107 # in which case we are not to be found in the path.
108 if test "x$as_myself" = x; then
111 if test ! -f "$as_myself"; then
112 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
116 # Unset variables that we do not need and which cause bugs (e.g. in
117 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
118 # suppresses any "Segmentation fault" message there. '((' could
119 # trigger a bug in pdksh 5.2.14.
120 for as_var in BASH_ENV ENV MAIL MAILPATH
121 do eval test x\${$as_var+set} = xset \
122 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
135 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
137 # Use a proper internal environment variable to ensure we don't fall
138 # into an infinite loop, continuously re-executing ourselves.
139 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
140 _as_can_reexec=no; export _as_can_reexec;
141 # We cannot yet assume a decent shell, so we have to provide a
142 # neutralization value for shells without unset; and this also
143 # works around shells that cannot unset nonexistent variables.
144 # Preserve -v and -x to the replacement shell.
147 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
149 *v*x* | *x*v* ) as_opts=-vx ;;
154 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
155 # Admittedly, this is quite paranoid, since all the known shells bail
156 # out after a failed `exec'.
157 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
160 # We don't want this to propagate to other subprocesses.
161 { _as_can_reexec=; unset _as_can_reexec;}
162 if test "x$CONFIG_SHELL" = x; then
163 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
166 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
167 # is contrary to our usage. Disable this feature.
168 alias -g '\${1+\"\$@\"}'='\"\$@\"'
171 case \`(set -o) 2>/dev/null\` in #(
179 as_required="as_fn_return () { (exit \$1); }
180 as_fn_success () { as_fn_return 0; }
181 as_fn_failure () { as_fn_return 1; }
182 as_fn_ret_success () { return 0; }
183 as_fn_ret_failure () { return 1; }
186 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
187 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
188 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
189 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
190 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
193 exitcode=1; echo positional parameters were not saved.
195 test x\$exitcode = x0 || exit 1
197 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
198 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
199 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
200 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
201 test \$(( 1 + 1 )) = 2 || exit 1"
202 if (eval "$as_required") 2>/dev/null; then :
207 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
210 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
212 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
215 test -z "$as_dir" && as_dir=.
219 for as_base in sh bash ksh sh5; do
220 # Try only shells that exist, to save several forks.
221 as_shell=$as_dir/$as_base
222 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
223 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
224 CONFIG_SHELL=$as_shell as_have_required=yes
225 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
233 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
234 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
235 CONFIG_SHELL=$SHELL as_have_required=yes
240 if test "x$CONFIG_SHELL" != x; then :
242 # We cannot yet assume a decent shell, so we have to provide a
243 # neutralization value for shells without unset; and this also
244 # works around shells that cannot unset nonexistent variables.
245 # Preserve -v and -x to the replacement shell.
248 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
250 *v*x* | *x*v* ) as_opts=-vx ;;
255 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
256 # Admittedly, this is quite paranoid, since all the known shells bail
257 # out after a failed `exec'.
258 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
262 if test x$as_have_required = xno; then :
263 $as_echo "$0: This script requires a shell more modern than all"
264 $as_echo "$0: the shells that I found on your system."
265 if test x${ZSH_VERSION+set} = xset ; then
266 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
267 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
269 $as_echo "$0: Please tell bug-autoconf@gnu.org and bug-tar@gnu.org
270 $0: about your system, including any error possibly output
271 $0: before this message. Then install a modern shell, or
272 $0: manually run the script under such a shell if you do
279 SHELL=${CONFIG_SHELL-/bin/sh}
281 # Unset more variables known to interfere with behavior of common tools.
282 CLICOLOR_FORCE= GREP_OPTIONS=
283 unset CLICOLOR_FORCE GREP_OPTIONS
285 ## --------------------- ##
286 ## M4sh Shell Functions. ##
287 ## --------------------- ##
290 # Portably unset VAR.
293 { eval $1=; unset $1;}
297 # as_fn_set_status STATUS
298 # -----------------------
299 # Set $? to STATUS, without forking.
307 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
317 # Create "$as_dir" as a directory, including parents if necessary.
322 -*) as_dir=./$as_dir;;
324 test -d "$as_dir" || eval $as_mkdir_p || {
328 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
331 as_dirs="'$as_qdir' $as_dirs"
332 as_dir=`$as_dirname -- "$as_dir" ||
333 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
334 X"$as_dir" : 'X\(//\)[^/]' \| \
335 X"$as_dir" : 'X\(//\)$' \| \
336 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
337 $as_echo X"$as_dir" |
338 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
355 test -d "$as_dir" && break
357 test -z "$as_dirs" || eval "mkdir $as_dirs"
358 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
363 # as_fn_executable_p FILE
364 # -----------------------
365 # Test if FILE is an executable regular file.
366 as_fn_executable_p ()
368 test -f "$1" && test -x "$1"
369 } # as_fn_executable_p
370 # as_fn_append VAR VALUE
371 # ----------------------
372 # Append the text in VALUE to the end of the definition contained in VAR. Take
373 # advantage of any shell optimizations that allow amortized linear growth over
374 # repeated appends, instead of the typical quadratic growth present in naive
376 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
377 eval 'as_fn_append ()
390 # Perform arithmetic evaluation on the ARGs, and store the result in the
391 # global $as_val. Take advantage of shells that can avoid forks. The arguments
392 # must be portable across $(()) and expr.
393 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
401 as_val=`expr "$@" || test $? -eq 1`
406 # as_fn_error STATUS ERROR [LINENO LOG_FD]
407 # ----------------------------------------
408 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
409 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
410 # script with STATUS, using 1 if that was 0.
413 as_status=$1; test $as_status -eq 0 && as_status=1
415 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
416 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
418 $as_echo "$as_me: error: $2" >&2
419 as_fn_exit $as_status
422 if expr a : '\(a\)' >/dev/null 2>&1 &&
423 test "X`expr 00001 : '.*\(...\)'`" = X001; then
429 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
435 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
441 as_me=`$as_basename -- "$0" ||
442 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
443 X"$0" : 'X\(//\)$' \| \
444 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
446 sed '/^.*\/\([^/][^/]*\)\/*$/{
460 # Avoid depending upon Character Ranges.
461 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
462 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
463 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
464 as_cr_digits='0123456789'
465 as_cr_alnum=$as_cr_Letters$as_cr_digits
468 as_lineno_1=$LINENO as_lineno_1a=$LINENO
469 as_lineno_2=$LINENO as_lineno_2a=$LINENO
470 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
471 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
472 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
484 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
488 chmod +x "$as_me.lineno" ||
489 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
491 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
492 # already done that, so ensure we don't try to do so again and fall
493 # in an infinite loop. This has already happened in practice.
494 _as_can_reexec=no; export _as_can_reexec
495 # Don't try to exec as it changes $[0], causing all sort of problems
496 # (the dirname of $[0] is not the place where we might find the
497 # original and so on. Autoconf is especially sensitive to this).
499 # Exit status is that of the last command.
503 ECHO_C= ECHO_N= ECHO_T=
504 case `echo -n x` in #(((((
506 case `echo 'xy\c'` in
507 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
509 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
516 rm -f conf$$ conf$$.exe conf$$.file
517 if test -d conf$$.dir; then
518 rm -f conf$$.dir/conf$$.file
521 mkdir conf$$.dir 2>/dev/null
523 if (echo >conf$$.file) 2>/dev/null; then
524 if ln -s conf$$.file conf$$ 2>/dev/null; then
526 # ... but there are two gotchas:
527 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
528 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
529 # In both cases, we have to default to `cp -pR'.
530 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
532 elif ln conf$$.file conf$$ 2>/dev/null; then
540 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
541 rmdir conf$$.dir 2>/dev/null
543 if mkdir -p . 2>/dev/null; then
544 as_mkdir_p='mkdir -p "$as_dir"'
546 test -d ./-p && rmdir ./-p
551 as_executable_p=as_fn_executable_p
553 # Sed expression to map a string onto a valid CPP name.
554 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
556 # Sed expression to map a string onto a valid variable name.
557 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
560 test -n "$DJDIR" || exec 7<&0 </dev/null
564 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
565 # so uname gets run too.
566 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
571 ac_default_prefix=/usr/local
573 ac_config_libobj_dir=.
580 # Identity of this package.
581 PACKAGE_NAME='GNU tar'
582 PACKAGE_TARNAME='tar'
583 PACKAGE_VERSION='1.27.1'
584 PACKAGE_STRING='GNU tar 1.27.1'
585 PACKAGE_BUGREPORT='bug-tar@gnu.org'
586 PACKAGE_URL='http://www.gnu.org/software/tar/'
588 ac_unique_file="src/tar.c"
589 # Factoring default headers for most tests.
590 ac_includes_default="\
592 #ifdef HAVE_SYS_TYPES_H
593 # include <sys/types.h>
595 #ifdef HAVE_SYS_STAT_H
596 # include <sys/stat.h>
602 # ifdef HAVE_STDLIB_H
607 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
612 #ifdef HAVE_STRINGS_H
613 # include <strings.h>
615 #ifdef HAVE_INTTYPES_H
616 # include <inttypes.h>
627 gl_fnmatch_required=POSIX
628 gl_getopt_required=POSIX
629 gl_getopt_required=POSIX
631 ac_subst_vars='gltests_LTLIBOBJS
640 BACKUP_LIBEXEC_SCRIPTS
645 XGETTEXT_EXTRA_OPTIONS
653 GETTEXT_MACRO_VERSION
657 DEFAULT_QUOTING_STYLE
660 DEFAULT_ARCHIVE_FORMAT
663 TAR_COND_XATTR_H_FALSE
664 TAR_COND_XATTR_H_TRUE
665 GNULIB_TEST_WARN_CFLAGS
676 NEXT_AS_FIRST_DIRECTIVE_WCHAR_H
679 LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_FALSE
680 LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_TRUE
681 LIBUNISTRING_UNIWIDTH_H
682 LIBUNISTRING_UNITYPES_H
684 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
686 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
687 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
688 TIME_H_DEFINES_STRUCT_TIMESPEC
689 NEXT_AS_FIRST_DIRECTIVE_TIME_H
691 GL_GENERATE_SYSEXITS_H_FALSE
692 GL_GENERATE_SYSEXITS_H_TRUE
695 NEXT_AS_FIRST_DIRECTIVE_SYSEXITS_H
698 NEXT_AS_FIRST_DIRECTIVE_STRINGS_H
700 NEXT_AS_FIRST_DIRECTIVE_STRING_H
702 HAVE_DECL_STRNCASECMP
706 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
708 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
710 GL_GENERATE_STDARG_H_FALSE
711 GL_GENERATE_STDARG_H_TRUE
713 NEXT_AS_FIRST_DIRECTIVE_STDARG_H
715 GL_GENERATE_STDALIGN_H_FALSE
716 GL_GENERATE_STDALIGN_H_TRUE
718 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
720 GL_GENERATE_SELINUX_CONTEXT_H_FALSE
721 GL_GENERATE_SELINUX_CONTEXT_H_TRUE
723 NEXT_AS_FIRST_DIRECTIVE_SELINUX_SELINUX_H
724 NEXT_SELINUX_SELINUX_H
727 REPLACE_PTHREAD_SIGMASK
729 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
730 HAVE_STRUCT_SIGACTION_SA_SIGACTION
736 HAVE_POSIX_SIGNALBLOCKING
739 GNULIB_SIGNAL_H_SIGPIPE
741 GNULIB_PTHREAD_SIGMASK
745 GL_GENERATE_STDBOOL_H_FALSE
746 GL_GENERATE_STDBOOL_H_TRUE
755 HAVE_DECL_LOCALTIME_R
837 NEXT_AS_FIRST_DIRECTIVE_LOCALE_H
840 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
842 GL_GENERATE_STDDEF_H_FALSE
843 GL_GENERATE_STDDEF_H_TRUE
855 LOCALCHARSET_TESTS_ENVIRONMENT
857 HAVE_LANGINFO_YESEXPR
859 HAVE_LANGINFO_T_FMT_AMPM
860 HAVE_LANGINFO_CODESET
862 NEXT_AS_FIRST_DIRECTIVE_LANGINFO_H
870 NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H
883 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
885 UINT64_MAX_EQ_ULONG_MAX
886 UINT32_MAX_LT_UINTMAX_MAX
889 INT64_MAX_EQ_LONG_MAX
890 INT32_MAX_LT_INTMAX_MAX
900 GL_GENERATE_STDINT_H_FALSE
901 GL_GENERATE_STDINT_H_TRUE
910 HAVE_SIGNED_SIG_ATOMIC_T
913 BITSIZEOF_SIG_ATOMIC_T
916 APPLE_UNIVERSAL_BUILD
920 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
925 HAVE_UNSIGNED_LONG_LONG_INT
927 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
929 REPLACE_STRUCT_TIMEVAL
937 GNULIB_GL_UNISTD_H_GETOPT
940 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H
942 WINDOWS_64_BIT_ST_SIZE
943 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
946 NEXT_AS_FIRST_DIRECTIVE_SYS_TYPES_H
955 REPLACE_STDIO_WRITE_FUNCS
956 REPLACE_STDIO_READ_FUNCS
965 REPLACE_OBSTACK_PRINTF
990 HAVE_DECL_OBSTACK_PRINTF
996 GNULIB_VSPRINTF_POSIX
1000 GNULIB_VFPRINTF_POSIX
1007 GNULIB_STDIO_H_SIGPIPE
1008 GNULIB_STDIO_H_NONBLOCKING
1009 GNULIB_SPRINTF_POSIX
1023 GNULIB_OBSTACK_PRINTF_POSIX
1024 GNULIB_OBSTACK_PRINTF
1040 GNULIB_FPRINTF_POSIX
1049 GL_GENERATE_FNMATCH_H_FALSE
1050 GL_GENERATE_FNMATCH_H_TRUE
1053 GL_GENERATE_FLOAT_H_FALSE
1054 GL_GENERATE_FLOAT_H_TRUE
1056 NEXT_AS_FIRST_DIRECTIVE_FLOAT_H
1058 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H
1108 GL_GENERATE_ERRNO_H_FALSE
1109 GL_GENERATE_ERRNO_H_TRUE
1111 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H
1114 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H
1117 PRAGMA_SYSTEM_HEADER
1118 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
1144 HAVE_MSVC_INVALID_PARAMETER_HANDLER
1146 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
1147 UNISTD_H_HAVE_WINSOCK2_H
1168 REPLACE_GETDOMAINNAME
1179 HAVE_DECL_SETHOSTNAME
1180 HAVE_DECL_GETUSERSHELL
1181 HAVE_DECL_GETPAGESIZE
1182 HAVE_DECL_GETLOGIN_R
1183 HAVE_DECL_GETDOMAINNAME
1222 GNULIB_UNISTD_H_SIGPIPE
1223 GNULIB_UNISTD_H_NONBLOCKING
1249 GNULIB_GETDTABLESIZE
1250 GNULIB_GETDOMAINNAME
1279 REPLACE_CANONICALIZE_FILE_NAME
1284 HAVE_STRUCT_RANDOM_DATA
1306 HAVE_DECL_GETLOADAVG
1307 HAVE_CANONICALIZE_FILE_NAME
1318 GNULIB_SECURE_GETENV
1321 GNULIB_REALLOC_POSIX
1338 GNULIB_CANONICALIZE_FILE_NAME
1442 GL_GENERATE_ALLOCA_H_FALSE
1443 GL_GENERATE_ALLOCA_H_TRUE
1446 GL_COND_LIBTOOL_FALSE
1447 GL_COND_LIBTOOL_TRUE
1474 AM_DEFAULT_VERBOSITY
1485 INSTALL_STRIP_PROGRAM
1527 program_transform_name
1540 enable_option_checking
1542 enable_dependency_tracking
1549 with_packager_version
1550 with_packager_bug_reports
1563 with_libiconv_prefix
1566 enable_backup_scripts
1568 ac_precious_vars='build_alias
1581 DEFAULT_ARCHIVE_FORMAT
1584 DEFAULT_QUOTING_STYLE'
1587 # Initialize some variables set by options.
1589 ac_init_version=false
1590 ac_unrecognized_opts=
1591 ac_unrecognized_sep=
1592 # The variables have the same names as the options, with
1593 # dashes changed to underlines.
1594 cache_file=/dev/null
1601 program_transform_name=s,x,x,
1609 # Installation directory options.
1610 # These are left unexpanded so users can "make install exec_prefix=/foo"
1611 # and all the variables that are supposed to be based on exec_prefix
1612 # by default will actually change.
1613 # Use braces instead of parens because sh, perl, etc. also accept them.
1614 # (The list follows the same order as the GNU Coding Standards.)
1615 bindir='${exec_prefix}/bin'
1616 sbindir='${exec_prefix}/sbin'
1617 libexecdir='${exec_prefix}/libexec'
1618 datarootdir='${prefix}/share'
1619 datadir='${datarootdir}'
1620 sysconfdir='${prefix}/etc'
1621 sharedstatedir='${prefix}/com'
1622 localstatedir='${prefix}/var'
1623 includedir='${prefix}/include'
1624 oldincludedir='/usr/include'
1625 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1626 infodir='${datarootdir}/info'
1631 libdir='${exec_prefix}/lib'
1632 localedir='${datarootdir}/locale'
1633 mandir='${datarootdir}/man'
1639 # If the previous option needs an argument, assign it.
1640 if test -n "$ac_prev"; then
1641 eval $ac_prev=\$ac_option
1647 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1652 # Accept the important Cygnus configure options, so we can diagnose typos.
1654 case $ac_dashdash$ac_option in
1658 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1660 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1661 bindir=$ac_optarg ;;
1663 -build | --build | --buil | --bui | --bu)
1664 ac_prev=build_alias ;;
1665 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1666 build_alias=$ac_optarg ;;
1668 -cache-file | --cache-file | --cache-fil | --cache-fi \
1669 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1670 ac_prev=cache_file ;;
1671 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1672 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1673 cache_file=$ac_optarg ;;
1675 --config-cache | -C)
1676 cache_file=config.cache ;;
1678 -datadir | --datadir | --datadi | --datad)
1680 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1681 datadir=$ac_optarg ;;
1683 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1684 | --dataroo | --dataro | --datar)
1685 ac_prev=datarootdir ;;
1686 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1687 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1688 datarootdir=$ac_optarg ;;
1690 -disable-* | --disable-*)
1691 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1692 # Reject names that are not valid shell variable names.
1693 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1694 as_fn_error $? "invalid feature name: $ac_useropt"
1695 ac_useropt_orig=$ac_useropt
1696 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1697 case $ac_user_opts in
1699 "enable_$ac_useropt"
1701 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1702 ac_unrecognized_sep=', ';;
1704 eval enable_$ac_useropt=no ;;
1706 -docdir | --docdir | --docdi | --doc | --do)
1708 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1709 docdir=$ac_optarg ;;
1711 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1713 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1714 dvidir=$ac_optarg ;;
1716 -enable-* | --enable-*)
1717 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1718 # Reject names that are not valid shell variable names.
1719 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1720 as_fn_error $? "invalid feature name: $ac_useropt"
1721 ac_useropt_orig=$ac_useropt
1722 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1723 case $ac_user_opts in
1725 "enable_$ac_useropt"
1727 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1728 ac_unrecognized_sep=', ';;
1730 eval enable_$ac_useropt=\$ac_optarg ;;
1732 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1733 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1734 | --exec | --exe | --ex)
1735 ac_prev=exec_prefix ;;
1736 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1737 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1738 | --exec=* | --exe=* | --ex=*)
1739 exec_prefix=$ac_optarg ;;
1741 -gas | --gas | --ga | --g)
1742 # Obsolete; use --with-gas.
1745 -help | --help | --hel | --he | -h)
1746 ac_init_help=long ;;
1747 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1748 ac_init_help=recursive ;;
1749 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1750 ac_init_help=short ;;
1752 -host | --host | --hos | --ho)
1753 ac_prev=host_alias ;;
1754 -host=* | --host=* | --hos=* | --ho=*)
1755 host_alias=$ac_optarg ;;
1757 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1759 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1761 htmldir=$ac_optarg ;;
1763 -includedir | --includedir | --includedi | --included | --include \
1764 | --includ | --inclu | --incl | --inc)
1765 ac_prev=includedir ;;
1766 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1767 | --includ=* | --inclu=* | --incl=* | --inc=*)
1768 includedir=$ac_optarg ;;
1770 -infodir | --infodir | --infodi | --infod | --info | --inf)
1772 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1773 infodir=$ac_optarg ;;
1775 -libdir | --libdir | --libdi | --libd)
1777 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1778 libdir=$ac_optarg ;;
1780 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1781 | --libexe | --libex | --libe)
1782 ac_prev=libexecdir ;;
1783 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1784 | --libexe=* | --libex=* | --libe=*)
1785 libexecdir=$ac_optarg ;;
1787 -localedir | --localedir | --localedi | --localed | --locale)
1788 ac_prev=localedir ;;
1789 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1790 localedir=$ac_optarg ;;
1792 -localstatedir | --localstatedir | --localstatedi | --localstated \
1793 | --localstate | --localstat | --localsta | --localst | --locals)
1794 ac_prev=localstatedir ;;
1795 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1796 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1797 localstatedir=$ac_optarg ;;
1799 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1801 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1802 mandir=$ac_optarg ;;
1804 -nfp | --nfp | --nf)
1805 # Obsolete; use --without-fp.
1808 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1809 | --no-cr | --no-c | -n)
1812 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1813 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1816 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1817 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1818 | --oldin | --oldi | --old | --ol | --o)
1819 ac_prev=oldincludedir ;;
1820 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1821 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1822 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1823 oldincludedir=$ac_optarg ;;
1825 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1827 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1828 prefix=$ac_optarg ;;
1830 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1831 | --program-pre | --program-pr | --program-p)
1832 ac_prev=program_prefix ;;
1833 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1834 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1835 program_prefix=$ac_optarg ;;
1837 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1838 | --program-suf | --program-su | --program-s)
1839 ac_prev=program_suffix ;;
1840 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1841 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1842 program_suffix=$ac_optarg ;;
1844 -program-transform-name | --program-transform-name \
1845 | --program-transform-nam | --program-transform-na \
1846 | --program-transform-n | --program-transform- \
1847 | --program-transform | --program-transfor \
1848 | --program-transfo | --program-transf \
1849 | --program-trans | --program-tran \
1850 | --progr-tra | --program-tr | --program-t)
1851 ac_prev=program_transform_name ;;
1852 -program-transform-name=* | --program-transform-name=* \
1853 | --program-transform-nam=* | --program-transform-na=* \
1854 | --program-transform-n=* | --program-transform-=* \
1855 | --program-transform=* | --program-transfor=* \
1856 | --program-transfo=* | --program-transf=* \
1857 | --program-trans=* | --program-tran=* \
1858 | --progr-tra=* | --program-tr=* | --program-t=*)
1859 program_transform_name=$ac_optarg ;;
1861 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1863 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1864 pdfdir=$ac_optarg ;;
1866 -psdir | --psdir | --psdi | --psd | --ps)
1868 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1871 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1872 | -silent | --silent | --silen | --sile | --sil)
1875 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1877 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1879 sbindir=$ac_optarg ;;
1881 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1882 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1883 | --sharedst | --shareds | --shared | --share | --shar \
1885 ac_prev=sharedstatedir ;;
1886 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1887 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1888 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1890 sharedstatedir=$ac_optarg ;;
1892 -site | --site | --sit)
1894 -site=* | --site=* | --sit=*)
1897 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1899 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1900 srcdir=$ac_optarg ;;
1902 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1903 | --syscon | --sysco | --sysc | --sys | --sy)
1904 ac_prev=sysconfdir ;;
1905 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1906 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1907 sysconfdir=$ac_optarg ;;
1909 -target | --target | --targe | --targ | --tar | --ta | --t)
1910 ac_prev=target_alias ;;
1911 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1912 target_alias=$ac_optarg ;;
1914 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1917 -version | --version | --versio | --versi | --vers | -V)
1918 ac_init_version=: ;;
1921 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1922 # Reject names that are not valid shell variable names.
1923 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1924 as_fn_error $? "invalid package name: $ac_useropt"
1925 ac_useropt_orig=$ac_useropt
1926 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1927 case $ac_user_opts in
1931 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1932 ac_unrecognized_sep=', ';;
1934 eval with_$ac_useropt=\$ac_optarg ;;
1936 -without-* | --without-*)
1937 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1938 # Reject names that are not valid shell variable names.
1939 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1940 as_fn_error $? "invalid package name: $ac_useropt"
1941 ac_useropt_orig=$ac_useropt
1942 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1943 case $ac_user_opts in
1947 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1948 ac_unrecognized_sep=', ';;
1950 eval with_$ac_useropt=no ;;
1953 # Obsolete; use --with-x.
1956 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1957 | --x-incl | --x-inc | --x-in | --x-i)
1958 ac_prev=x_includes ;;
1959 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1960 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1961 x_includes=$ac_optarg ;;
1963 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1964 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1965 ac_prev=x_libraries ;;
1966 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1967 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1968 x_libraries=$ac_optarg ;;
1970 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1971 Try \`$0 --help' for more information"
1975 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1976 # Reject names that are not valid shell variable names.
1977 case $ac_envvar in #(
1978 '' | [0-9]* | *[!_$as_cr_alnum]* )
1979 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1981 eval $ac_envvar=\$ac_optarg
1982 export $ac_envvar ;;
1985 # FIXME: should be removed in autoconf 3.0.
1986 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1987 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1988 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1989 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1995 if test -n "$ac_prev"; then
1996 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1997 as_fn_error $? "missing argument to $ac_option"
2000 if test -n "$ac_unrecognized_opts"; then
2001 case $enable_option_checking in
2003 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
2004 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
2008 # Check all directory arguments for consistency.
2009 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
2010 datadir sysconfdir sharedstatedir localstatedir includedir \
2011 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
2012 libdir localedir mandir
2014 eval ac_val=\$$ac_var
2015 # Remove trailing slashes.
2018 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
2019 eval $ac_var=\$ac_val;;
2021 # Be sure to have absolute directory names.
2023 [\\/$]* | ?:[\\/]* ) continue;;
2024 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
2026 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
2029 # There might be people who depend on the old broken behavior: `$host'
2030 # used to hold the argument of --host etc.
2031 # FIXME: To remove some day.
2034 target=$target_alias
2036 # FIXME: To remove some day.
2037 if test "x$host_alias" != x; then
2038 if test "x$build_alias" = x; then
2039 cross_compiling=maybe
2040 elif test "x$build_alias" != "x$host_alias"; then
2046 test -n "$host_alias" && ac_tool_prefix=$host_alias-
2048 test "$silent" = yes && exec 6>/dev/null
2051 ac_pwd=`pwd` && test -n "$ac_pwd" &&
2052 ac_ls_di=`ls -di .` &&
2053 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
2054 as_fn_error $? "working directory cannot be determined"
2055 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
2056 as_fn_error $? "pwd does not report name of working directory"
2059 # Find the source files, if location was not specified.
2060 if test -z "$srcdir"; then
2061 ac_srcdir_defaulted=yes
2062 # Try the directory containing this script, then the parent directory.
2063 ac_confdir=`$as_dirname -- "$as_myself" ||
2064 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
2065 X"$as_myself" : 'X\(//\)[^/]' \| \
2066 X"$as_myself" : 'X\(//\)$' \| \
2067 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
2068 $as_echo X"$as_myself" |
2069 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
2087 if test ! -r "$srcdir/$ac_unique_file"; then
2091 ac_srcdir_defaulted=no
2093 if test ! -r "$srcdir/$ac_unique_file"; then
2094 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
2095 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
2097 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
2099 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
2101 # When building in place, set srcdir=.
2102 if test "$ac_abs_confdir" = "$ac_pwd"; then
2105 # Remove unnecessary trailing slashes from srcdir.
2106 # Double slashes in file names in object file debugging info
2107 # mess up M-x gdb in Emacs.
2109 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
2111 for ac_var in $ac_precious_vars; do
2112 eval ac_env_${ac_var}_set=\${${ac_var}+set}
2113 eval ac_env_${ac_var}_value=\$${ac_var}
2114 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
2115 eval ac_cv_env_${ac_var}_value=\$${ac_var}
2119 # Report the --help message.
2121 if test "$ac_init_help" = "long"; then
2122 # Omit some internal or obsolete options to make the list less imposing.
2123 # This message is too long to be a string in the A/UX 3.1 sh.
2125 \`configure' configures GNU tar 1.27.1 to adapt to many kinds of systems.
2127 Usage: $0 [OPTION]... [VAR=VALUE]...
2129 To assign environment variables (e.g., CC, CFLAGS...), specify them as
2130 VAR=VALUE. See below for descriptions of some of the useful variables.
2132 Defaults for the options are specified in brackets.
2135 -h, --help display this help and exit
2136 --help=short display options specific to this package
2137 --help=recursive display the short help of all the included packages
2138 -V, --version display version information and exit
2139 -q, --quiet, --silent do not print \`checking ...' messages
2140 --cache-file=FILE cache test results in FILE [disabled]
2141 -C, --config-cache alias for \`--cache-file=config.cache'
2142 -n, --no-create do not create output files
2143 --srcdir=DIR find the sources in DIR [configure dir or \`..']
2145 Installation directories:
2146 --prefix=PREFIX install architecture-independent files in PREFIX
2147 [$ac_default_prefix]
2148 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
2151 By default, \`make install' will install all the files in
2152 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
2153 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
2154 for instance \`--prefix=\$HOME'.
2156 For better control, use the options below.
2158 Fine tuning of the installation directories:
2159 --bindir=DIR user executables [EPREFIX/bin]
2160 --sbindir=DIR system admin executables [EPREFIX/sbin]
2161 --libexecdir=DIR program executables [EPREFIX/libexec]
2162 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
2163 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
2164 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
2165 --libdir=DIR object code libraries [EPREFIX/lib]
2166 --includedir=DIR C header files [PREFIX/include]
2167 --oldincludedir=DIR C header files for non-gcc [/usr/include]
2168 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
2169 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
2170 --infodir=DIR info documentation [DATAROOTDIR/info]
2171 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
2172 --mandir=DIR man documentation [DATAROOTDIR/man]
2173 --docdir=DIR documentation root [DATAROOTDIR/doc/tar]
2174 --htmldir=DIR html documentation [DOCDIR]
2175 --dvidir=DIR dvi documentation [DOCDIR]
2176 --pdfdir=DIR pdf documentation [DOCDIR]
2177 --psdir=DIR ps documentation [DOCDIR]
2183 --program-prefix=PREFIX prepend PREFIX to installed program names
2184 --program-suffix=SUFFIX append SUFFIX to installed program names
2185 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
2188 --build=BUILD configure for building on BUILD [guessed]
2189 --host=HOST cross-compile to build programs to run on HOST [BUILD]
2193 if test -n "$ac_init_help"; then
2194 case $ac_init_help in
2195 short | recursive ) echo "Configuration of GNU tar 1.27.1:";;
2200 --disable-option-checking ignore unrecognized --enable/--with options
2201 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
2202 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
2203 --enable-silent-rules less verbose build output (undo: "make V=1")
2204 --disable-silent-rules verbose build output (undo: "make V=0")
2205 --enable-dependency-tracking
2206 do not reject slow dependency extractors
2207 --disable-dependency-tracking
2208 speeds up one-time build
2209 --disable-largefile omit support for large files
2210 --disable-acl do not support ACLs
2211 --enable-gcc-warnings turn on many GCC warnings (for developers; best with
2213 --disable-rpath do not hardcode runtime library paths
2214 --disable-nls do not use Native Language Support
2215 --enable-backup-scripts Create and install backup and restore scripts
2218 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
2219 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
2220 --without-posix-acls do not use POSIX.1e access control lists
2221 --without-included-regex
2222 don't compile regex; this is the default on systems
2223 with recent-enough versions of the GNU C Library
2224 (use with caution on other systems).
2225 --without-selinux do not use SELinux, even on systems with SELinux
2226 --with-packager String identifying the packager of this software
2227 --with-packager-version Packager-specific version information
2228 --with-packager-bug-reports
2229 Packager info for bug reports (URL/e-mail/...)
2230 --with-rmt=FILE Use FILE as the default `rmt' program. Do not build
2231 included copy of `rmt'.
2232 --without-xattrs don't use linux extended attributes
2233 --with-compress=PROG use PROG as compress compressor program
2234 --with-gzip=PROG use PROG as gzip compressor program
2235 --with-bzip2=PROG use PROG as bzip2 compressor program
2236 --with-lzip=PROG use PROG as lzip compressor program
2237 --with-lzma=PROG use PROG as lzma compressor program
2238 --with-lzop=PROG use PROG as lzop compressor program
2239 --with-xz=PROG use PROG as xz compressor program
2240 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
2241 --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
2242 --without-libiconv-prefix don't search for libiconv in includedir and libdir
2243 --with-libintl-prefix[=DIR] search for libintl in DIR/include and DIR/lib
2244 --without-libintl-prefix don't search for libintl in includedir and libdir
2246 Some influential environment variables:
2247 CC C compiler command
2248 CFLAGS C compiler flags
2249 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2250 nonstandard directory <lib dir>
2251 LIBS libraries to pass to the linker, e.g. -l<library>
2252 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2253 you have headers in a nonstandard directory <include dir>
2254 YACC The `Yet Another Compiler Compiler' implementation to use.
2255 Defaults to the first program found out of: `bison -y', `byacc',
2257 YFLAGS The list of arguments that will be passed by default to $YACC.
2258 This script will default YFLAGS to the empty string to avoid a
2259 default value of `-d' given by some make applications.
2262 Define full file name of the directory where to install `rmt'.
2263 (default: $(libexecdir))
2264 RSH Configure absolute path to default remote shell binary
2265 DEFAULT_ARCHIVE_FORMAT
2266 Set the default archive format. Allowed values are: V7, OLDGNU,
2267 USTAR, POSIX, GNU. Default is GNU
2269 Set the name of the default archive (default: -)
2271 Define default blocking factor (default: 20)
2272 DEFAULT_QUOTING_STYLE
2273 Set the default quoting style. Allowed values are: literal,
2274 shell, shell-always, c, escape, locale, clocale . Default is
2277 Use these variables to override the choices made by `configure' or to help
2278 it to find libraries and programs with nonstandard names/locations.
2280 Report bugs to <bug-tar@gnu.org>.
2281 GNU tar home page: <http://www.gnu.org/software/tar/>.
2282 General help using GNU software: <http://www.gnu.org/gethelp/>.
2287 if test "$ac_init_help" = "recursive"; then
2288 # If there are subdirs, report their specific --help.
2289 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2290 test -d "$ac_dir" ||
2291 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2296 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2298 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2299 # A ".." for each directory in $ac_dir_suffix.
2300 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2301 case $ac_top_builddir_sub in
2302 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2303 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2306 ac_abs_top_builddir=$ac_pwd
2307 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2308 # for backward compatibility:
2309 ac_top_builddir=$ac_top_build_prefix
2312 .) # We are building in place.
2314 ac_top_srcdir=$ac_top_builddir_sub
2315 ac_abs_top_srcdir=$ac_pwd ;;
2316 [\\/]* | ?:[\\/]* ) # Absolute name.
2317 ac_srcdir=$srcdir$ac_dir_suffix;
2318 ac_top_srcdir=$srcdir
2319 ac_abs_top_srcdir=$srcdir ;;
2321 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2322 ac_top_srcdir=$ac_top_build_prefix$srcdir
2323 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2325 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2327 cd "$ac_dir" || { ac_status=$?; continue; }
2328 # Check for guested configure.
2329 if test -f "$ac_srcdir/configure.gnu"; then
2331 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2332 elif test -f "$ac_srcdir/configure"; then
2334 $SHELL "$ac_srcdir/configure" --help=recursive
2336 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2338 cd "$ac_pwd" || { ac_status=$?; break; }
2342 test -n "$ac_init_help" && exit $ac_status
2343 if $ac_init_version; then
2345 GNU tar configure 1.27.1
2346 generated by GNU Autoconf 2.69
2348 Copyright (C) 2012 Free Software Foundation, Inc.
2349 This configure script is free software; the Free Software Foundation
2350 gives unlimited permission to copy, distribute and modify it.
2355 ## ------------------------ ##
2356 ## Autoconf initialization. ##
2357 ## ------------------------ ##
2359 # ac_fn_c_try_compile LINENO
2360 # --------------------------
2361 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2362 ac_fn_c_try_compile ()
2364 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2365 rm -f conftest.$ac_objext
2366 if { { ac_try="$ac_compile"
2368 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2369 *) ac_try_echo=$ac_try;;
2371 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2372 $as_echo "$ac_try_echo"; } >&5
2373 (eval "$ac_compile") 2>conftest.err
2375 if test -s conftest.err; then
2376 grep -v '^ *+' conftest.err >conftest.er1
2377 cat conftest.er1 >&5
2378 mv -f conftest.er1 conftest.err
2380 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2381 test $ac_status = 0; } && {
2382 test -z "$ac_c_werror_flag" ||
2383 test ! -s conftest.err
2384 } && test -s conftest.$ac_objext; then :
2387 $as_echo "$as_me: failed program was:" >&5
2388 sed 's/^/| /' conftest.$ac_ext >&5
2392 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2393 as_fn_set_status $ac_retval
2395 } # ac_fn_c_try_compile
2397 # ac_fn_c_try_cpp LINENO
2398 # ----------------------
2399 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2402 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2403 if { { ac_try="$ac_cpp conftest.$ac_ext"
2405 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2406 *) ac_try_echo=$ac_try;;
2408 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2409 $as_echo "$ac_try_echo"; } >&5
2410 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2412 if test -s conftest.err; then
2413 grep -v '^ *+' conftest.err >conftest.er1
2414 cat conftest.er1 >&5
2415 mv -f conftest.er1 conftest.err
2417 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2418 test $ac_status = 0; } > conftest.i && {
2419 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2420 test ! -s conftest.err
2424 $as_echo "$as_me: failed program was:" >&5
2425 sed 's/^/| /' conftest.$ac_ext >&5
2429 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2430 as_fn_set_status $ac_retval
2434 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2435 # -------------------------------------------------------
2436 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2437 # the include files in INCLUDES and setting the cache variable VAR
2439 ac_fn_c_check_header_mongrel ()
2441 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2442 if eval \${$3+:} false; then :
2443 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2444 $as_echo_n "checking for $2... " >&6; }
2445 if eval \${$3+:} false; then :
2446 $as_echo_n "(cached) " >&6
2449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2450 $as_echo "$ac_res" >&6; }
2452 # Is the header compilable?
2453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2454 $as_echo_n "checking $2 usability... " >&6; }
2455 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2456 /* end confdefs.h. */
2460 if ac_fn_c_try_compile "$LINENO"; then :
2461 ac_header_compiler=yes
2463 ac_header_compiler=no
2465 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2467 $as_echo "$ac_header_compiler" >&6; }
2469 # Is the header present?
2470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2471 $as_echo_n "checking $2 presence... " >&6; }
2472 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2473 /* end confdefs.h. */
2476 if ac_fn_c_try_cpp "$LINENO"; then :
2477 ac_header_preproc=yes
2479 ac_header_preproc=no
2481 rm -f conftest.err conftest.i conftest.$ac_ext
2482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2483 $as_echo "$ac_header_preproc" >&6; }
2485 # So? What about this header?
2486 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2488 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2489 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2490 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2491 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2494 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2495 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2496 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2497 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2498 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2499 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2500 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2501 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2502 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2503 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2504 ( $as_echo "## ------------------------------ ##
2505 ## Report this to bug-tar@gnu.org ##
2506 ## ------------------------------ ##"
2507 ) | sed "s/^/$as_me: WARNING: /" >&2
2510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2511 $as_echo_n "checking for $2... " >&6; }
2512 if eval \${$3+:} false; then :
2513 $as_echo_n "(cached) " >&6
2515 eval "$3=\$ac_header_compiler"
2518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2519 $as_echo "$ac_res" >&6; }
2521 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2523 } # ac_fn_c_check_header_mongrel
2525 # ac_fn_c_try_run LINENO
2526 # ----------------------
2527 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2528 # that executables *can* be run.
2531 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2532 if { { ac_try="$ac_link"
2534 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2535 *) ac_try_echo=$ac_try;;
2537 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2538 $as_echo "$ac_try_echo"; } >&5
2539 (eval "$ac_link") 2>&5
2541 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2542 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2543 { { case "(($ac_try" in
2544 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2545 *) ac_try_echo=$ac_try;;
2547 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2548 $as_echo "$ac_try_echo"; } >&5
2549 (eval "$ac_try") 2>&5
2551 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2552 test $ac_status = 0; }; }; then :
2555 $as_echo "$as_me: program exited with status $ac_status" >&5
2556 $as_echo "$as_me: failed program was:" >&5
2557 sed 's/^/| /' conftest.$ac_ext >&5
2559 ac_retval=$ac_status
2561 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2562 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2563 as_fn_set_status $ac_retval
2567 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2568 # -------------------------------------------------------
2569 # Tests whether HEADER exists and can be compiled using the include files in
2570 # INCLUDES, setting the cache variable VAR accordingly.
2571 ac_fn_c_check_header_compile ()
2573 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2574 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2575 $as_echo_n "checking for $2... " >&6; }
2576 if eval \${$3+:} false; then :
2577 $as_echo_n "(cached) " >&6
2579 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2580 /* end confdefs.h. */
2584 if ac_fn_c_try_compile "$LINENO"; then :
2589 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2593 $as_echo "$ac_res" >&6; }
2594 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2596 } # ac_fn_c_check_header_compile
2598 # ac_fn_c_try_link LINENO
2599 # -----------------------
2600 # Try to link conftest.$ac_ext, and return whether this succeeded.
2603 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2604 rm -f conftest.$ac_objext conftest$ac_exeext
2605 if { { ac_try="$ac_link"
2607 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2608 *) ac_try_echo=$ac_try;;
2610 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2611 $as_echo "$ac_try_echo"; } >&5
2612 (eval "$ac_link") 2>conftest.err
2614 if test -s conftest.err; then
2615 grep -v '^ *+' conftest.err >conftest.er1
2616 cat conftest.er1 >&5
2617 mv -f conftest.er1 conftest.err
2619 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2620 test $ac_status = 0; } && {
2621 test -z "$ac_c_werror_flag" ||
2622 test ! -s conftest.err
2623 } && test -s conftest$ac_exeext && {
2624 test "$cross_compiling" = yes ||
2625 test -x conftest$ac_exeext
2629 $as_echo "$as_me: failed program was:" >&5
2630 sed 's/^/| /' conftest.$ac_ext >&5
2634 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2635 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2636 # interfere with the next link command; also delete a directory that is
2637 # left behind by Apple's compiler. We do this before executing the actions.
2638 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2639 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2640 as_fn_set_status $ac_retval
2642 } # ac_fn_c_try_link
2644 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2645 # -------------------------------------------
2646 # Tests whether TYPE exists after having included INCLUDES, setting cache
2647 # variable VAR accordingly.
2648 ac_fn_c_check_type ()
2650 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2652 $as_echo_n "checking for $2... " >&6; }
2653 if eval \${$3+:} false; then :
2654 $as_echo_n "(cached) " >&6
2657 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2658 /* end confdefs.h. */
2669 if ac_fn_c_try_compile "$LINENO"; then :
2670 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2671 /* end confdefs.h. */
2682 if ac_fn_c_try_compile "$LINENO"; then :
2687 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2689 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2693 $as_echo "$ac_res" >&6; }
2694 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2696 } # ac_fn_c_check_type
2698 # ac_fn_c_check_func LINENO FUNC VAR
2699 # ----------------------------------
2700 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2701 ac_fn_c_check_func ()
2703 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2705 $as_echo_n "checking for $2... " >&6; }
2706 if eval \${$3+:} false; then :
2707 $as_echo_n "(cached) " >&6
2709 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2710 /* end confdefs.h. */
2711 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2712 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2713 #define $2 innocuous_$2
2715 /* System header to define __stub macros and hopefully few prototypes,
2716 which can conflict with char $2 (); below.
2717 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2718 <limits.h> exists even on freestanding compilers. */
2721 # include <limits.h>
2723 # include <assert.h>
2728 /* Override any GCC internal prototype to avoid an error.
2729 Use char because int might match the return type of a GCC
2730 builtin and then its argument prototype would still apply. */
2735 /* The GNU C library defines this for functions which it implements
2736 to always fail with ENOSYS. Some functions are actually named
2737 something starting with __ and the normal name is an alias. */
2738 #if defined __stub_$2 || defined __stub___$2
2750 if ac_fn_c_try_link "$LINENO"; then :
2755 rm -f core conftest.err conftest.$ac_objext \
2756 conftest$ac_exeext conftest.$ac_ext
2759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2760 $as_echo "$ac_res" >&6; }
2761 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2763 } # ac_fn_c_check_func
2765 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2766 # ---------------------------------------------
2767 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2769 ac_fn_c_check_decl ()
2771 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2772 as_decl_name=`echo $2|sed 's/ *(.*//'`
2773 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2775 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2776 if eval \${$3+:} false; then :
2777 $as_echo_n "(cached) " >&6
2779 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2780 /* end confdefs.h. */
2785 #ifndef $as_decl_name
2787 (void) $as_decl_use;
2789 (void) $as_decl_name;
2797 if ac_fn_c_try_compile "$LINENO"; then :
2802 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2806 $as_echo "$ac_res" >&6; }
2807 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2809 } # ac_fn_c_check_decl
2811 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2812 # --------------------------------------------
2813 # Tries to find the compile-time value of EXPR in a program that includes
2814 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2816 ac_fn_c_compute_int ()
2818 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2819 if test "$cross_compiling" = yes; then
2820 # Depending upon the size, compute the lo and hi bounds.
2821 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2822 /* end confdefs.h. */
2827 static int test_array [1 - 2 * !(($2) >= 0)];
2829 return test_array [0];
2835 if ac_fn_c_try_compile "$LINENO"; then :
2838 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2839 /* end confdefs.h. */
2844 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2846 return test_array [0];
2852 if ac_fn_c_try_compile "$LINENO"; then :
2853 ac_hi=$ac_mid; break
2855 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2856 if test $ac_lo -le $ac_mid; then
2860 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2862 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2865 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2866 /* end confdefs.h. */
2871 static int test_array [1 - 2 * !(($2) < 0)];
2873 return test_array [0];
2879 if ac_fn_c_try_compile "$LINENO"; then :
2882 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2883 /* end confdefs.h. */
2888 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2890 return test_array [0];
2896 if ac_fn_c_try_compile "$LINENO"; then :
2897 ac_lo=$ac_mid; break
2899 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2900 if test $ac_mid -le $ac_hi; then
2904 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2906 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2911 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2913 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2914 # Binary search between lo and hi bounds.
2915 while test "x$ac_lo" != "x$ac_hi"; do
2916 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2917 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2918 /* end confdefs.h. */
2923 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2925 return test_array [0];
2931 if ac_fn_c_try_compile "$LINENO"; then :
2934 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2936 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2939 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2943 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2944 /* end confdefs.h. */
2946 static long int longval () { return $2; }
2947 static unsigned long int ulongval () { return $2; }
2954 FILE *f = fopen ("conftest.val", "w");
2959 long int i = longval ();
2962 fprintf (f, "%ld", i);
2966 unsigned long int i = ulongval ();
2969 fprintf (f, "%lu", i);
2971 /* Do not output a trailing newline, as this causes \r\n confusion
2972 on some platforms. */
2973 return ferror (f) || fclose (f) != 0;
2979 if ac_fn_c_try_run "$LINENO"; then :
2980 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2984 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2985 conftest.$ac_objext conftest.beam conftest.$ac_ext
2989 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2990 as_fn_set_status $ac_retval
2992 } # ac_fn_c_compute_int
2994 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2995 # ----------------------------------------------------
2996 # Tries to find if the field MEMBER exists in type AGGR, after including
2997 # INCLUDES, setting cache variable VAR accordingly.
2998 ac_fn_c_check_member ()
3000 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
3001 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
3002 $as_echo_n "checking for $2.$3... " >&6; }
3003 if eval \${$4+:} false; then :
3004 $as_echo_n "(cached) " >&6
3006 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3007 /* end confdefs.h. */
3019 if ac_fn_c_try_compile "$LINENO"; then :
3022 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3023 /* end confdefs.h. */
3029 if (sizeof ac_aggr.$3)
3035 if ac_fn_c_try_compile "$LINENO"; then :
3040 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3042 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
3046 $as_echo "$ac_res" >&6; }
3047 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3049 } # ac_fn_c_check_member
3050 cat >config.log <<_ACEOF
3051 This file contains any messages produced by compilers while
3052 running configure, to aid debugging if configure makes a mistake.
3054 It was created by GNU tar $as_me 1.27.1, which was
3055 generated by GNU Autoconf 2.69. Invocation command line was
3067 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
3068 uname -m = `(uname -m) 2>/dev/null || echo unknown`
3069 uname -r = `(uname -r) 2>/dev/null || echo unknown`
3070 uname -s = `(uname -s) 2>/dev/null || echo unknown`
3071 uname -v = `(uname -v) 2>/dev/null || echo unknown`
3073 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
3074 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
3076 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
3077 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
3078 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
3079 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
3080 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
3081 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
3082 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
3086 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3090 test -z "$as_dir" && as_dir=.
3091 $as_echo "PATH: $as_dir"
3107 # Keep a trace of the command line.
3108 # Strip out --no-create and --no-recursion so they do not pile up.
3109 # Strip out --silent because we don't want to record it for future runs.
3110 # Also quote any args containing shell meta-characters.
3111 # Make two passes to allow for proper duplicate-argument suppression.
3115 ac_must_keep_next=false
3121 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
3122 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
3123 | -silent | --silent | --silen | --sile | --sil)
3126 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
3129 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
3131 as_fn_append ac_configure_args1 " '$ac_arg'"
3132 if test $ac_must_keep_next = true; then
3133 ac_must_keep_next=false # Got value, back to normal.
3136 *=* | --config-cache | -C | -disable-* | --disable-* \
3137 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
3138 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
3139 | -with-* | --with-* | -without-* | --without-* | --x)
3140 case "$ac_configure_args0 " in
3141 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
3144 -* ) ac_must_keep_next=true ;;
3147 as_fn_append ac_configure_args " '$ac_arg'"
3152 { ac_configure_args0=; unset ac_configure_args0;}
3153 { ac_configure_args1=; unset ac_configure_args1;}
3155 # When interrupted or exit'd, cleanup temporary files, and complete
3156 # config.log. We remove comments because anyway the quotes in there
3157 # would cause problems or look ugly.
3158 # WARNING: Use '\'' to represent an apostrophe within the trap.
3159 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3160 trap 'exit_status=$?
3161 # Save into config.log some information that might help in debugging.
3165 $as_echo "## ---------------- ##
3166 ## Cache variables. ##
3167 ## ---------------- ##"
3169 # The following way of writing the cache mishandles newlines in values,
3171 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3172 eval ac_val=\$$ac_var
3176 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3177 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3180 _ | IFS | as_nl) ;; #(
3181 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3182 *) { eval $ac_var=; unset $ac_var;} ;;
3187 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3188 *${as_nl}ac_space=\ *)
3190 "s/'\''/'\''\\\\'\'''\''/g;
3191 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3194 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3201 $as_echo "## ----------------- ##
3202 ## Output variables. ##
3203 ## ----------------- ##"
3205 for ac_var in $ac_subst_vars
3207 eval ac_val=\$$ac_var
3209 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3211 $as_echo "$ac_var='\''$ac_val'\''"
3215 if test -n "$ac_subst_files"; then
3216 $as_echo "## ------------------- ##
3217 ## File substitutions. ##
3218 ## ------------------- ##"
3220 for ac_var in $ac_subst_files
3222 eval ac_val=\$$ac_var
3224 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3226 $as_echo "$ac_var='\''$ac_val'\''"
3231 if test -s confdefs.h; then
3232 $as_echo "## ----------- ##
3239 test "$ac_signal" != 0 &&
3240 $as_echo "$as_me: caught signal $ac_signal"
3241 $as_echo "$as_me: exit $exit_status"
3243 rm -f core *.core core.conftest.* &&
3244 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3247 for ac_signal in 1 2 13 15; do
3248 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3252 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3253 rm -f -r conftest* confdefs.h
3255 $as_echo "/* confdefs.h */" > confdefs.h
3257 # Predefined preprocessor variables.
3259 cat >>confdefs.h <<_ACEOF
3260 #define PACKAGE_NAME "$PACKAGE_NAME"
3263 cat >>confdefs.h <<_ACEOF
3264 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3267 cat >>confdefs.h <<_ACEOF
3268 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3271 cat >>confdefs.h <<_ACEOF
3272 #define PACKAGE_STRING "$PACKAGE_STRING"
3275 cat >>confdefs.h <<_ACEOF
3276 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3279 cat >>confdefs.h <<_ACEOF
3280 #define PACKAGE_URL "$PACKAGE_URL"
3284 # Let the site file select an alternate cache file if it wants to.
3285 # Prefer an explicitly selected file to automatically selected ones.
3288 if test -n "$CONFIG_SITE"; then
3289 # We do not want a PATH search for config.site.
3290 case $CONFIG_SITE in #((
3291 -*) ac_site_file1=./$CONFIG_SITE;;
3292 */*) ac_site_file1=$CONFIG_SITE;;
3293 *) ac_site_file1=./$CONFIG_SITE;;
3295 elif test "x$prefix" != xNONE; then
3296 ac_site_file1=$prefix/share/config.site
3297 ac_site_file2=$prefix/etc/config.site
3299 ac_site_file1=$ac_default_prefix/share/config.site
3300 ac_site_file2=$ac_default_prefix/etc/config.site
3302 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3304 test "x$ac_site_file" = xNONE && continue
3305 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3306 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3307 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3308 sed 's/^/| /' "$ac_site_file" >&5
3310 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3311 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3312 as_fn_error $? "failed to load site script $ac_site_file
3313 See \`config.log' for more details" "$LINENO" 5; }
3317 if test -r "$cache_file"; then
3318 # Some versions of bash will fail to source /dev/null (special files
3319 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3320 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3321 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3322 $as_echo "$as_me: loading cache $cache_file" >&6;}
3324 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3325 *) . "./$cache_file";;
3329 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3330 $as_echo "$as_me: creating cache $cache_file" >&6;}
3334 as_fn_append ac_header_list " fcntl.h"
3335 as_fn_append ac_header_list " linux/fd.h"
3336 as_fn_append ac_header_list " memory.h"
3337 as_fn_append ac_header_list " net/errno.h"
3338 as_fn_append ac_header_list " sgtty.h"
3339 as_fn_append ac_header_list " string.h"
3340 as_fn_append ac_header_list " sys/param.h"
3341 as_fn_append ac_header_list " sys/device.h"
3342 as_fn_append ac_header_list " sys/gentape.h"
3343 as_fn_append ac_header_list " sys/inet.h"
3344 as_fn_append ac_header_list " sys/io/trioctl.h"
3345 as_fn_append ac_header_list " sys/mtio.h"
3346 as_fn_append ac_header_list " sys/time.h"
3347 as_fn_append ac_header_list " sys/tprintf.h"
3348 as_fn_append ac_header_list " sys/tape.h"
3349 as_fn_append ac_header_list " unistd.h"
3350 as_fn_append ac_header_list " locale.h"
3351 as_fn_append ac_func_list " flockfile"
3352 as_fn_append ac_func_list " funlockfile"
3353 as_fn_append ac_header_list " features.h"
3354 as_fn_append ac_header_list " linewrap.h"
3355 as_fn_append ac_func_list " pathconf"
3356 as_fn_append ac_func_list " btowc"
3357 as_fn_append ac_func_list " canonicalize_file_name"
3358 as_fn_append ac_func_list " getcwd"
3359 as_fn_append ac_func_list " readlink"
3360 as_fn_append ac_func_list " realpath"
3361 as_fn_append ac_func_list " readlinkat"
3362 as_fn_append ac_func_list " chown"
3363 as_fn_append ac_func_list " fchown"
3364 as_fn_append ac_func_list " _set_invalid_parameter_handler"
3365 as_fn_append ac_header_list " sys/socket.h"
3366 as_fn_append ac_func_list " fchdir"
3367 as_fn_append ac_header_list " dirent.h"
3368 as_fn_append ac_func_list " fdopendir"
3369 as_fn_append ac_func_list " fchmodat"
3370 as_fn_append ac_func_list " lchmod"
3371 as_fn_append ac_func_list " fcntl"
3372 as_fn_append ac_func_list " symlink"
3373 as_fn_append ac_func_list " mempcpy"
3374 as_fn_append ac_func_list " isblank"
3375 as_fn_append ac_func_list " iswctype"
3376 as_fn_append ac_func_list " mbsrtowcs"
3377 as_fn_append ac_func_list " wmemchr"
3378 as_fn_append ac_func_list " wmemcpy"
3379 as_fn_append ac_func_list " wmempcpy"
3380 as_fn_append ac_header_list " wctype.h"
3381 gl_fnmatch_required=GNU
3382 as_fn_append ac_header_list " stdio_ext.h"
3383 as_fn_append ac_func_list " __fpending"
3384 as_fn_append ac_header_list " sys/stat.h"
3385 as_fn_append ac_func_list " fstatat"
3386 as_fn_append ac_func_list " futimens"
3387 as_fn_append ac_func_list " getdelim"
3388 as_fn_append ac_func_list " getdtablesize"
3389 gl_getopt_required=GNU
3390 as_fn_append ac_header_list " getopt.h"
3391 as_fn_append ac_func_list " gettimeofday"
3392 as_fn_append ac_func_list " nanotime"
3393 as_fn_append ac_header_list " wchar.h"
3394 as_fn_append ac_header_list " stdint.h"
3395 as_fn_append ac_header_list " inttypes.h"
3396 as_fn_append ac_func_list " iswcntrl"
3397 as_fn_append ac_func_list " iswblank"
3398 as_fn_append ac_header_list " langinfo.h"
3399 as_fn_append ac_func_list " link"
3400 as_fn_append ac_func_list " openat"
3401 as_fn_append ac_func_list " linkat"
3402 as_fn_append ac_header_list " xlocale.h"
3403 as_fn_append ac_func_list " lstat"
3404 as_fn_append ac_func_list " mbsinit"
3405 as_fn_append ac_func_list " mbrtowc"
3406 as_fn_append ac_header_list " sys/mman.h"
3407 as_fn_append ac_func_list " mprotect"
3408 as_fn_append ac_func_list " mkdirat"
3409 as_fn_append ac_func_list " mkfifo"
3410 as_fn_append ac_func_list " mkfifoat"
3411 as_fn_append ac_func_list " mknodat"
3412 as_fn_append ac_func_list " mknod"
3413 as_fn_append ac_func_list " nl_langinfo"
3414 as_fn_append ac_header_list " priv.h"
3415 as_fn_append ac_func_list " wcscoll"
3416 as_fn_append ac_func_list " renameat"
3417 as_fn_append ac_func_list " secure_getenv"
3418 as_fn_append ac_header_list " selinux/selinux.h"
3419 as_fn_append ac_func_list " setenv"
3420 as_fn_append ac_func_list " sleep"
3421 as_fn_append ac_func_list " snprintf"
3422 as_fn_append ac_func_list " strdup"
3423 as_fn_append ac_header_list " strings.h"
3424 as_fn_append ac_func_list " strndup"
3425 as_fn_append ac_func_list " strtoumax"
3426 as_fn_append ac_func_list " symlinkat"
3427 as_fn_append ac_header_list " sysexits.h"
3428 as_fn_append ac_func_list " localtime_r"
3429 as_fn_append ac_func_list " pipe"
3430 as_fn_append ac_func_list " unlinkat"
3431 as_fn_append ac_header_list " utime.h"
3432 as_fn_append ac_func_list " futimes"
3433 as_fn_append ac_func_list " futimesat"
3434 as_fn_append ac_func_list " utimensat"
3435 as_fn_append ac_func_list " lutimes"
3436 as_fn_append ac_func_list " vasnprintf"
3437 as_fn_append ac_func_list " wcrtomb"
3438 as_fn_append ac_func_list " wcwidth"
3439 as_fn_append ac_header_list " netdb.h"
3440 as_fn_append ac_header_list " sys/wait.h"
3441 as_fn_append ac_header_list " pwd.h"
3442 as_fn_append ac_header_list " grp.h"
3443 as_fn_append ac_func_list " setlocale"
3444 as_fn_append ac_func_list " fchmod"
3445 as_fn_append ac_func_list " fsync"
3446 gt_needs="$gt_needs need-formatstring-macros"
3447 # Check that the precious variables saved in the cache have kept the same
3449 ac_cache_corrupted=false
3450 for ac_var in $ac_precious_vars; do
3451 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3452 eval ac_new_set=\$ac_env_${ac_var}_set
3453 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3454 eval ac_new_val=\$ac_env_${ac_var}_value
3455 case $ac_old_set,$ac_new_set in
3457 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3458 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3459 ac_cache_corrupted=: ;;
3461 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3462 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3463 ac_cache_corrupted=: ;;
3466 if test "x$ac_old_val" != "x$ac_new_val"; then
3467 # differences in whitespace do not lead to failure.
3468 ac_old_val_w=`echo x $ac_old_val`
3469 ac_new_val_w=`echo x $ac_new_val`
3470 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3471 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3472 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3473 ac_cache_corrupted=:
3475 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3476 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3477 eval $ac_var=\$ac_old_val
3479 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3480 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3481 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3482 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3485 # Pass precious variables to config.status.
3486 if test "$ac_new_set" = set; then
3488 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3489 *) ac_arg=$ac_var=$ac_new_val ;;
3491 case " $ac_configure_args " in
3492 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3493 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3497 if $ac_cache_corrupted; then
3498 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3499 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3500 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3501 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3502 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3504 ## -------------------- ##
3505 ## Main body of script. ##
3506 ## -------------------- ##
3509 ac_cpp='$CPP $CPPFLAGS'
3510 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3511 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3512 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3517 for ac_dir in build-aux "$srcdir"/build-aux; do
3518 if test -f "$ac_dir/install-sh"; then
3520 ac_install_sh="$ac_aux_dir/install-sh -c"
3522 elif test -f "$ac_dir/install.sh"; then
3524 ac_install_sh="$ac_aux_dir/install.sh -c"
3526 elif test -f "$ac_dir/shtool"; then
3528 ac_install_sh="$ac_aux_dir/shtool install -c"
3532 if test -z "$ac_aux_dir"; then
3533 as_fn_error $? "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
3536 # These three variables are undocumented and unsupported,
3537 # and are intended to be withdrawn in a future Autoconf release.
3538 # They can cause serious problems if a builder's source tree is in a directory
3539 # whose full name contains unusual characters.
3540 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3541 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3542 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3545 ac_config_headers="$ac_config_headers config.h"
3548 am__api_version='1.14'
3550 # Find a good install program. We prefer a C program (faster),
3551 # so one script is as good as another. But avoid the broken or
3552 # incompatible versions:
3553 # SysV /etc/install, /usr/sbin/install
3554 # SunOS /usr/etc/install
3555 # IRIX /sbin/install
3557 # AmigaOS /C/install, which installs bootblocks on floppy discs
3558 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3559 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3560 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3561 # OS/2's system install, which has a completely different semantic
3562 # ./install, which can be erroneously created by make from ./install.sh.
3563 # Reject install programs that cannot install multiple files.
3564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3565 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3566 if test -z "$INSTALL"; then
3567 if ${ac_cv_path_install+:} false; then :
3568 $as_echo_n "(cached) " >&6
3570 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3574 test -z "$as_dir" && as_dir=.
3575 # Account for people who put trailing slashes in PATH elements.
3576 case $as_dir/ in #((
3577 ./ | .// | /[cC]/* | \
3578 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3579 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3582 # OSF1 and SCO ODT 3.0 have their own names for install.
3583 # Don't use installbsd from OSF since it installs stuff as root
3585 for ac_prog in ginstall scoinst install; do
3586 for ac_exec_ext in '' $ac_executable_extensions; do
3587 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3588 if test $ac_prog = install &&
3589 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3590 # AIX install. It has an incompatible calling convention.
3592 elif test $ac_prog = install &&
3593 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3594 # program-specific install script used by HP pwplus--don't use.
3597 rm -rf conftest.one conftest.two conftest.dir
3598 echo one > conftest.one
3599 echo two > conftest.two
3601 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3602 test -s conftest.one && test -s conftest.two &&
3603 test -s conftest.dir/conftest.one &&
3604 test -s conftest.dir/conftest.two
3606 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3619 rm -rf conftest.one conftest.two conftest.dir
3622 if test "${ac_cv_path_install+set}" = set; then
3623 INSTALL=$ac_cv_path_install
3625 # As a last resort, use the slow shell script. Don't cache a
3626 # value for INSTALL within a source directory, because that will
3627 # break other packages using the cache if that directory is
3628 # removed, or if the value is a relative name.
3629 INSTALL=$ac_install_sh
3632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3633 $as_echo "$INSTALL" >&6; }
3635 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3636 # It thinks the first close brace ends the variable substitution.
3637 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3639 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3641 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3643 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3644 $as_echo_n "checking whether build environment is sane... " >&6; }
3645 # Reject unsafe characters in $srcdir or the absolute working directory
3646 # name. Accept space and tab only in the latter.
3650 *[\\\"\#\$\&\'\`$am_lf]*)
3651 as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
3654 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3655 as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
3658 # Do 'set' in a subshell so we don't clobber the current shell's
3659 # arguments. Must try -L first in case configure is actually a
3660 # symlink; some systems play weird games with the mod time of symlinks
3661 # (eg FreeBSD returns the mod time of the symlink's containing
3665 for am_try in 1 2; do
3666 echo "timestamp, slept: $am_has_slept" > conftest.file
3667 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3668 if test "$*" = "X"; then
3670 set X `ls -t "$srcdir/configure" conftest.file`
3672 if test "$*" != "X $srcdir/configure conftest.file" \
3673 && test "$*" != "X conftest.file $srcdir/configure"; then
3675 # If neither matched, then we have a broken ls. This can happen
3676 # if, for instance, CONFIG_SHELL is bash and it inherits a
3677 # broken ls alias from the environment. This has actually
3678 # happened. Such a system could not be considered "sane".
3679 as_fn_error $? "ls -t appears to fail. Make sure there is not a broken
3680 alias in your environment" "$LINENO" 5
3682 if test "$2" = conftest.file || test $am_try -eq 2; then
3689 test "$2" = conftest.file
3695 as_fn_error $? "newly created file is older than distributed files!
3696 Check your system clock" "$LINENO" 5
3698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3699 $as_echo "yes" >&6; }
3700 # If we didn't sleep, we still need to ensure time stamps of config.status and
3701 # generated files are strictly newer.
3703 if grep 'slept: no' conftest.file >/dev/null 2>&1; then
3710 test "$program_prefix" != NONE &&
3711 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3712 # Use a double $ so make ignores it.
3713 test "$program_suffix" != NONE &&
3714 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3715 # Double any \ or $.
3716 # By default was `s,x,x', remove it if useless.
3717 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3718 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3720 # expand $ac_aux_dir to an absolute path
3721 am_aux_dir=`cd $ac_aux_dir && pwd`
3723 if test x"${MISSING+set}" != xset; then
3726 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3728 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3731 # Use eval to expand $SHELL
3732 if eval "$MISSING --is-lightweight"; then
3733 am_missing_run="$MISSING "
3736 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
3737 $as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
3740 if test x"${install_sh}" != xset; then
3743 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3745 install_sh="\${SHELL} $am_aux_dir/install-sh"
3749 # Installed binaries are usually stripped using 'strip' when the user
3750 # run "make install-strip". However 'strip' might not be the right
3751 # tool to use in cross-compilation environments, therefore Automake
3752 # will honor the 'STRIP' environment variable to overrule this program.
3753 if test "$cross_compiling" != no; then
3754 if test -n "$ac_tool_prefix"; then
3755 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3756 set dummy ${ac_tool_prefix}strip; ac_word=$2
3757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3758 $as_echo_n "checking for $ac_word... " >&6; }
3759 if ${ac_cv_prog_STRIP+:} false; then :
3760 $as_echo_n "(cached) " >&6
3762 if test -n "$STRIP"; then
3763 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3765 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3769 test -z "$as_dir" && as_dir=.
3770 for ac_exec_ext in '' $ac_executable_extensions; do
3771 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3772 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3773 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3782 STRIP=$ac_cv_prog_STRIP
3783 if test -n "$STRIP"; then
3784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3785 $as_echo "$STRIP" >&6; }
3787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3788 $as_echo "no" >&6; }
3793 if test -z "$ac_cv_prog_STRIP"; then
3795 # Extract the first word of "strip", so it can be a program name with args.
3796 set dummy strip; ac_word=$2
3797 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3798 $as_echo_n "checking for $ac_word... " >&6; }
3799 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
3800 $as_echo_n "(cached) " >&6
3802 if test -n "$ac_ct_STRIP"; then
3803 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3805 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3809 test -z "$as_dir" && as_dir=.
3810 for ac_exec_ext in '' $ac_executable_extensions; do
3811 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3812 ac_cv_prog_ac_ct_STRIP="strip"
3813 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3822 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3823 if test -n "$ac_ct_STRIP"; then
3824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3825 $as_echo "$ac_ct_STRIP" >&6; }
3827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3828 $as_echo "no" >&6; }
3831 if test "x$ac_ct_STRIP" = x; then
3834 case $cross_compiling:$ac_tool_warned in
3836 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3837 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3838 ac_tool_warned=yes ;;
3843 STRIP="$ac_cv_prog_STRIP"
3847 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3849 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3850 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3851 if test -z "$MKDIR_P"; then
3852 if ${ac_cv_path_mkdir+:} false; then :
3853 $as_echo_n "(cached) " >&6
3855 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3856 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3859 test -z "$as_dir" && as_dir=.
3860 for ac_prog in mkdir gmkdir; do
3861 for ac_exec_ext in '' $ac_executable_extensions; do
3862 as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
3863 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3864 'mkdir (GNU coreutils) '* | \
3865 'mkdir (coreutils) '* | \
3866 'mkdir (fileutils) '4.1*)
3867 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3877 test -d ./--version && rmdir ./--version
3878 if test "${ac_cv_path_mkdir+set}" = set; then
3879 MKDIR_P="$ac_cv_path_mkdir -p"
3881 # As a last resort, use the slow shell script. Don't cache a
3882 # value for MKDIR_P within a source directory, because that will
3883 # break other packages using the cache if that directory is
3884 # removed, or if the value is a relative name.
3885 MKDIR_P="$ac_install_sh -d"
3888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3889 $as_echo "$MKDIR_P" >&6; }
3891 for ac_prog in gawk mawk nawk awk
3893 # Extract the first word of "$ac_prog", so it can be a program name with args.
3894 set dummy $ac_prog; ac_word=$2
3895 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3896 $as_echo_n "checking for $ac_word... " >&6; }
3897 if ${ac_cv_prog_AWK+:} false; then :
3898 $as_echo_n "(cached) " >&6
3900 if test -n "$AWK"; then
3901 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3903 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3907 test -z "$as_dir" && as_dir=.
3908 for ac_exec_ext in '' $ac_executable_extensions; do
3909 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3910 ac_cv_prog_AWK="$ac_prog"
3911 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3921 if test -n "$AWK"; then
3922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3923 $as_echo "$AWK" >&6; }
3925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3926 $as_echo "no" >&6; }
3930 test -n "$AWK" && break
3933 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3934 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3936 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3937 if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
3938 $as_echo_n "(cached) " >&6
3940 cat >conftest.make <<\_ACEOF
3943 @echo '@@@%%%=$(MAKE)=@@@%%%'
3945 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
3946 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3948 eval ac_cv_prog_make_${ac_make}_set=yes;;
3950 eval ac_cv_prog_make_${ac_make}_set=no;;
3954 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3956 $as_echo "yes" >&6; }
3959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3960 $as_echo "no" >&6; }
3961 SET_MAKE="MAKE=${MAKE-make}"
3964 rm -rf .tst 2>/dev/null
3965 mkdir .tst 2>/dev/null
3966 if test -d .tst; then
3971 rmdir .tst 2>/dev/null
3973 # Check whether --enable-silent-rules was given.
3974 if test "${enable_silent_rules+set}" = set; then :
3975 enableval=$enable_silent_rules;
3978 case $enable_silent_rules in # (((
3979 yes) AM_DEFAULT_VERBOSITY=0;;
3980 no) AM_DEFAULT_VERBOSITY=1;;
3981 *) AM_DEFAULT_VERBOSITY=1;;
3983 am_make=${MAKE-make}
3984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
3985 $as_echo_n "checking whether $am_make supports nested variables... " >&6; }
3986 if ${am_cv_make_support_nested_variables+:} false; then :
3987 $as_echo_n "(cached) " >&6
3989 if $as_echo 'TRUE=$(BAR$(V))
3995 .PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
3996 am_cv_make_support_nested_variables=yes
3998 am_cv_make_support_nested_variables=no
4001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
4002 $as_echo "$am_cv_make_support_nested_variables" >&6; }
4003 if test $am_cv_make_support_nested_variables = yes; then
4005 AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
4007 AM_V=$AM_DEFAULT_VERBOSITY
4008 AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
4012 if test "`cd $srcdir && pwd`" != "`pwd`"; then
4013 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
4014 # is not polluted with repeated "-I."
4015 am__isrc=' -I$(srcdir)'
4016 # test to see if srcdir already configured
4017 if test -f $srcdir/config.status; then
4018 as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
4022 # test whether we have cygpath
4023 if test -z "$CYGPATH_W"; then
4024 if (cygpath --version) >/dev/null 2>/dev/null; then
4025 CYGPATH_W='cygpath -w'
4032 # Define the identity of the package.
4037 cat >>confdefs.h <<_ACEOF
4038 #define PACKAGE "$PACKAGE"
4042 cat >>confdefs.h <<_ACEOF
4043 #define VERSION "$VERSION"
4046 # Some tools Automake needs.
4048 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
4051 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
4054 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
4057 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
4060 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
4062 # For better backward compatibility. To be removed once Automake 1.9.x
4063 # dies out for good. For more background, see:
4064 # <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
4065 # <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
4066 mkdir_p='$(MKDIR_P)'
4068 # We need awk for the "check" target. The system "awk" is bad on
4070 # Always define AMTAR for backward compatibility. Yes, it's still used
4071 # in the wild :-( We should find a proper way to deprecate it ...
4075 # We'll loop over all known methods to create a tar archive until one works.
4076 _am_tools='gnutar plaintar pax cpio none'
4078 # The POSIX 1988 'ustar' format is defined with fixed-size fields.
4079 # There is notably a 21 bits limit for the UID and the GID. In fact,
4080 # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343
4082 am_max_uid=2097151 # 2^21 - 1
4083 am_max_gid=$am_max_uid
4084 # The $UID and $GID variables are not portable, so we need to resort
4085 # to the POSIX-mandated id(1) utility. Errors in the 'id' calls
4086 # below are definitely unexpected, so allow the users to see them
4087 # (that is, avoid stderr redirection).
4088 am_uid=`id -u || echo unknown`
4089 am_gid=`id -g || echo unknown`
4090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether UID '$am_uid' is supported by ustar format" >&5
4091 $as_echo_n "checking whether UID '$am_uid' is supported by ustar format... " >&6; }
4092 if test $am_uid -le $am_max_uid; then
4093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4094 $as_echo "yes" >&6; }
4096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4097 $as_echo "no" >&6; }
4100 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether GID '$am_gid' is supported by ustar format" >&5
4101 $as_echo_n "checking whether GID '$am_gid' is supported by ustar format... " >&6; }
4102 if test $am_gid -le $am_max_gid; then
4103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4104 $as_echo "yes" >&6; }
4106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4107 $as_echo "no" >&6; }
4111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to create a ustar tar archive" >&5
4112 $as_echo_n "checking how to create a ustar tar archive... " >&6; }
4114 # Go ahead even if we have the value already cached. We do so because we
4115 # need to set the values for the 'am__tar' and 'am__untar' variables.
4116 _am_tools=${am_cv_prog_tar_ustar-$_am_tools}
4118 for _am_tool in $_am_tools; do
4121 for _am_tar in tar gnutar gtar; do
4122 { echo "$as_me:$LINENO: $_am_tar --version" >&5
4123 ($_am_tar --version) >&5 2>&5
4125 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4126 (exit $ac_status); } && break
4128 am__tar="$_am_tar --format=ustar -chf - "'"$$tardir"'
4129 am__tar_="$_am_tar --format=ustar -chf - "'"$tardir"'
4130 am__untar="$_am_tar -xf -"
4133 # Must skip GNU tar: if it does not support --format= it doesn't create
4134 # ustar tarball either.
4135 (tar --version) >/dev/null 2>&1 && continue
4136 am__tar='tar chf - "$$tardir"'
4137 am__tar_='tar chf - "$tardir"'
4138 am__untar='tar xf -'
4141 am__tar='pax -L -x ustar -w "$$tardir"'
4142 am__tar_='pax -L -x ustar -w "$tardir"'
4146 am__tar='find "$$tardir" -print | cpio -o -H ustar -L'
4147 am__tar_='find "$tardir" -print | cpio -o -H ustar -L'
4148 am__untar='cpio -i -H ustar -d'
4157 # If the value was cached, stop now. We just wanted to have am__tar
4158 # and am__untar set.
4159 test -n "${am_cv_prog_tar_ustar}" && break
4161 # tar/untar a dummy directory, and stop if the command works.
4164 echo GrepMe > conftest.dir/file
4165 { echo "$as_me:$LINENO: tardir=conftest.dir && eval $am__tar_ >conftest.tar" >&5
4166 (tardir=conftest.dir && eval $am__tar_ >conftest.tar) >&5 2>&5
4168 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4169 (exit $ac_status); }
4171 if test -s conftest.tar; then
4172 { echo "$as_me:$LINENO: $am__untar <conftest.tar" >&5
4173 ($am__untar <conftest.tar) >&5 2>&5
4175 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4176 (exit $ac_status); }
4177 { echo "$as_me:$LINENO: cat conftest.dir/file" >&5
4178 (cat conftest.dir/file) >&5 2>&5
4180 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4181 (exit $ac_status); }
4182 grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
4187 if ${am_cv_prog_tar_ustar+:} false; then :
4188 $as_echo_n "(cached) " >&6
4190 am_cv_prog_tar_ustar=$_am_tool
4193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_tar_ustar" >&5
4194 $as_echo "$am_cv_prog_tar_ustar" >&6; }
4201 # POSIX will say in a future version that running "rm -f" with no argument
4202 # is OK; and we want to be able to make that assumption in our Makefile
4203 # recipes. So use an aggressive probe to check that the usage we want is
4204 # actually supported "in the wild" to an acceptable degree.
4205 # See automake bug#10828.
4206 # To make any issue more visible, cause the running configure to be aborted
4207 # by default if the 'rm' program in use doesn't match our expectations; the
4208 # user can still override this though.
4209 if rm -f && rm -fr && rm -rf; then : OK; else
4213 Your 'rm' program seems unable to run without file operands specified
4214 on the command line, even when the '-f' option is present. This is contrary
4215 to the behaviour of most rm programs out there, and not conforming with
4216 the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
4218 Please tell bug-automake@gnu.org about your system, including the value
4219 of your $PATH and any error possibly output before this message. This
4220 can help us improve future automake versions.
4223 if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
4224 echo 'Configuration will proceed anyway, since you have set the' >&2
4225 echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
4229 Aborting the configuration process, to ensure you take notice of the issue.
4231 You can download and install GNU coreutils to get an 'rm' implementation
4232 that behaves properly: <http://www.gnu.org/software/coreutils/>.
4234 If you want to complete the configuration process using your problematic
4235 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
4236 to "yes", and re-run configure.
4239 as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5
4243 # Enable silent rules by default:
4244 # Check whether --enable-silent-rules was given.
4245 if test "${enable_silent_rules+set}" = set; then :
4246 enableval=$enable_silent_rules;
4249 case $enable_silent_rules in # (((
4250 yes) AM_DEFAULT_VERBOSITY=0;;
4251 no) AM_DEFAULT_VERBOSITY=1;;
4252 *) AM_DEFAULT_VERBOSITY=0;;
4254 am_make=${MAKE-make}
4255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
4256 $as_echo_n "checking whether $am_make supports nested variables... " >&6; }
4257 if ${am_cv_make_support_nested_variables+:} false; then :
4258 $as_echo_n "(cached) " >&6
4260 if $as_echo 'TRUE=$(BAR$(V))
4266 .PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
4267 am_cv_make_support_nested_variables=yes
4269 am_cv_make_support_nested_variables=no
4272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
4273 $as_echo "$am_cv_make_support_nested_variables" >&6; }
4274 if test $am_cv_make_support_nested_variables = yes; then
4276 AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
4278 AM_V=$AM_DEFAULT_VERBOSITY
4279 AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
4285 ac_cpp='$CPP $CPPFLAGS'
4286 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4287 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4288 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4289 if test -n "$ac_tool_prefix"; then
4290 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4291 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4292 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4293 $as_echo_n "checking for $ac_word... " >&6; }
4294 if ${ac_cv_prog_CC+:} false; then :
4295 $as_echo_n "(cached) " >&6
4297 if test -n "$CC"; then
4298 ac_cv_prog_CC="$CC" # Let the user override the test.
4300 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4304 test -z "$as_dir" && as_dir=.
4305 for ac_exec_ext in '' $ac_executable_extensions; do
4306 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4307 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4308 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4318 if test -n "$CC"; then
4319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4320 $as_echo "$CC" >&6; }
4322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4323 $as_echo "no" >&6; }
4328 if test -z "$ac_cv_prog_CC"; then
4330 # Extract the first word of "gcc", so it can be a program name with args.
4331 set dummy gcc; ac_word=$2
4332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4333 $as_echo_n "checking for $ac_word... " >&6; }
4334 if ${ac_cv_prog_ac_ct_CC+:} false; then :
4335 $as_echo_n "(cached) " >&6
4337 if test -n "$ac_ct_CC"; then
4338 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4340 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4344 test -z "$as_dir" && as_dir=.
4345 for ac_exec_ext in '' $ac_executable_extensions; do
4346 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4347 ac_cv_prog_ac_ct_CC="gcc"
4348 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4357 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4358 if test -n "$ac_ct_CC"; then
4359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4360 $as_echo "$ac_ct_CC" >&6; }
4362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4363 $as_echo "no" >&6; }
4366 if test "x$ac_ct_CC" = x; then
4369 case $cross_compiling:$ac_tool_warned in
4371 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4372 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4373 ac_tool_warned=yes ;;
4381 if test -z "$CC"; then
4382 if test -n "$ac_tool_prefix"; then
4383 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4384 set dummy ${ac_tool_prefix}cc; ac_word=$2
4385 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4386 $as_echo_n "checking for $ac_word... " >&6; }
4387 if ${ac_cv_prog_CC+:} false; then :
4388 $as_echo_n "(cached) " >&6
4390 if test -n "$CC"; then
4391 ac_cv_prog_CC="$CC" # Let the user override the test.
4393 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4397 test -z "$as_dir" && as_dir=.
4398 for ac_exec_ext in '' $ac_executable_extensions; do
4399 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4400 ac_cv_prog_CC="${ac_tool_prefix}cc"
4401 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4411 if test -n "$CC"; then
4412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4413 $as_echo "$CC" >&6; }
4415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4416 $as_echo "no" >&6; }
4422 if test -z "$CC"; then
4423 # Extract the first word of "cc", so it can be a program name with args.
4424 set dummy cc; ac_word=$2
4425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4426 $as_echo_n "checking for $ac_word... " >&6; }
4427 if ${ac_cv_prog_CC+:} false; then :
4428 $as_echo_n "(cached) " >&6
4430 if test -n "$CC"; then
4431 ac_cv_prog_CC="$CC" # Let the user override the test.
4434 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4438 test -z "$as_dir" && as_dir=.
4439 for ac_exec_ext in '' $ac_executable_extensions; do
4440 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4441 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4442 ac_prog_rejected=yes
4446 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4453 if test $ac_prog_rejected = yes; then
4454 # We found a bogon in the path, so make sure we never use it.
4455 set dummy $ac_cv_prog_CC
4457 if test $# != 0; then
4458 # We chose a different compiler from the bogus one.
4459 # However, it has the same basename, so the bogon will be chosen
4460 # first if we set CC to just the basename; use the full file name.
4462 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4468 if test -n "$CC"; then
4469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4470 $as_echo "$CC" >&6; }
4472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4473 $as_echo "no" >&6; }
4478 if test -z "$CC"; then
4479 if test -n "$ac_tool_prefix"; then
4480 for ac_prog in cl.exe
4482 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4483 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4485 $as_echo_n "checking for $ac_word... " >&6; }
4486 if ${ac_cv_prog_CC+:} false; then :
4487 $as_echo_n "(cached) " >&6
4489 if test -n "$CC"; then
4490 ac_cv_prog_CC="$CC" # Let the user override the test.
4492 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4496 test -z "$as_dir" && as_dir=.
4497 for ac_exec_ext in '' $ac_executable_extensions; do
4498 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4499 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4500 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4510 if test -n "$CC"; then
4511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4512 $as_echo "$CC" >&6; }
4514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4515 $as_echo "no" >&6; }
4519 test -n "$CC" && break
4522 if test -z "$CC"; then
4524 for ac_prog in cl.exe
4526 # Extract the first word of "$ac_prog", so it can be a program name with args.
4527 set dummy $ac_prog; ac_word=$2
4528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4529 $as_echo_n "checking for $ac_word... " >&6; }
4530 if ${ac_cv_prog_ac_ct_CC+:} false; then :
4531 $as_echo_n "(cached) " >&6
4533 if test -n "$ac_ct_CC"; then
4534 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4536 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4540 test -z "$as_dir" && as_dir=.
4541 for ac_exec_ext in '' $ac_executable_extensions; do
4542 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4543 ac_cv_prog_ac_ct_CC="$ac_prog"
4544 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4553 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4554 if test -n "$ac_ct_CC"; then
4555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4556 $as_echo "$ac_ct_CC" >&6; }
4558 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4559 $as_echo "no" >&6; }
4563 test -n "$ac_ct_CC" && break
4566 if test "x$ac_ct_CC" = x; then
4569 case $cross_compiling:$ac_tool_warned in
4571 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4572 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4573 ac_tool_warned=yes ;;
4582 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4583 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4584 as_fn_error $? "no acceptable C compiler found in \$PATH
4585 See \`config.log' for more details" "$LINENO" 5; }
4587 # Provide some information about the compiler.
4588 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4591 for ac_option in --version -v -V -qversion; do
4592 { { ac_try="$ac_compiler $ac_option >&5"
4594 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4595 *) ac_try_echo=$ac_try;;
4597 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4598 $as_echo "$ac_try_echo"; } >&5
4599 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4601 if test -s conftest.err; then
4603 ... rest of stderr output deleted ...
4604 10q' conftest.err >conftest.er1
4605 cat conftest.er1 >&5
4607 rm -f conftest.er1 conftest.err
4608 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4609 test $ac_status = 0; }
4612 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4613 /* end confdefs.h. */
4623 ac_clean_files_save=$ac_clean_files
4624 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4625 # Try to create an executable without -o first, disregard a.out.
4626 # It will help us diagnose broken compilers, and finding out an intuition
4628 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4629 $as_echo_n "checking whether the C compiler works... " >&6; }
4630 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4632 # The possible output files:
4633 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4636 for ac_file in $ac_files
4639 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4640 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4645 if { { ac_try="$ac_link_default"
4647 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4648 *) ac_try_echo=$ac_try;;
4650 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4651 $as_echo "$ac_try_echo"; } >&5
4652 (eval "$ac_link_default") 2>&5
4654 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4655 test $ac_status = 0; }; then :
4656 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4657 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4658 # in a Makefile. We should not override ac_cv_exeext if it was cached,
4659 # so that the user can short-circuit this test for compilers unknown to
4661 for ac_file in $ac_files ''
4663 test -f "$ac_file" || continue
4665 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
4668 # We found the default executable, but exeext='' is most
4672 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
4674 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4676 # We set ac_cv_exeext here because the later test for it is not
4677 # safe: cross compilers may not add the suffix if given an `-o'
4678 # argument, so we may need to know it at that point already.
4679 # Even if this section looks crufty: it has the advantage of
4686 test "$ac_cv_exeext" = no && ac_cv_exeext=
4691 if test -z "$ac_file"; then :
4692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4693 $as_echo "no" >&6; }
4694 $as_echo "$as_me: failed program was:" >&5
4695 sed 's/^/| /' conftest.$ac_ext >&5
4697 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4698 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4699 as_fn_error 77 "C compiler cannot create executables
4700 See \`config.log' for more details" "$LINENO" 5; }
4702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4703 $as_echo "yes" >&6; }
4705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
4706 $as_echo_n "checking for C compiler default output file name... " >&6; }
4707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
4708 $as_echo "$ac_file" >&6; }
4709 ac_exeext=$ac_cv_exeext
4711 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
4712 ac_clean_files=$ac_clean_files_save
4713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
4714 $as_echo_n "checking for suffix of executables... " >&6; }
4715 if { { ac_try="$ac_link"
4717 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4718 *) ac_try_echo=$ac_try;;
4720 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4721 $as_echo "$ac_try_echo"; } >&5
4722 (eval "$ac_link") 2>&5
4724 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4725 test $ac_status = 0; }; then :
4726 # If both `conftest.exe' and `conftest' are `present' (well, observable)
4727 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
4728 # work properly (i.e., refer to `conftest.exe'), while it won't with
4730 for ac_file in conftest.exe conftest conftest.*; do
4731 test -f "$ac_file" || continue
4733 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4734 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4740 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4741 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4742 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
4743 See \`config.log' for more details" "$LINENO" 5; }
4745 rm -f conftest conftest$ac_cv_exeext
4746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4747 $as_echo "$ac_cv_exeext" >&6; }
4749 rm -f conftest.$ac_ext
4750 EXEEXT=$ac_cv_exeext
4752 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4753 /* end confdefs.h. */
4758 FILE *f = fopen ("conftest.out", "w");
4759 return ferror (f) || fclose (f) != 0;
4765 ac_clean_files="$ac_clean_files conftest.out"
4766 # Check that the compiler produces executables we can run. If not, either
4767 # the compiler is broken, or we cross compile.
4768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4769 $as_echo_n "checking whether we are cross compiling... " >&6; }
4770 if test "$cross_compiling" != yes; then
4771 { { ac_try="$ac_link"
4773 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4774 *) ac_try_echo=$ac_try;;
4776 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4777 $as_echo "$ac_try_echo"; } >&5
4778 (eval "$ac_link") 2>&5
4780 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4781 test $ac_status = 0; }
4782 if { ac_try='./conftest$ac_cv_exeext'
4783 { { case "(($ac_try" in
4784 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4785 *) ac_try_echo=$ac_try;;
4787 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4788 $as_echo "$ac_try_echo"; } >&5
4789 (eval "$ac_try") 2>&5
4791 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4792 test $ac_status = 0; }; }; then
4795 if test "$cross_compiling" = maybe; then
4798 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4799 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4800 as_fn_error $? "cannot run C compiled programs.
4801 If you meant to cross compile, use \`--host'.
4802 See \`config.log' for more details" "$LINENO" 5; }
4806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4807 $as_echo "$cross_compiling" >&6; }
4809 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
4810 ac_clean_files=$ac_clean_files_save
4811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4812 $as_echo_n "checking for suffix of object files... " >&6; }
4813 if ${ac_cv_objext+:} false; then :
4814 $as_echo_n "(cached) " >&6
4816 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4817 /* end confdefs.h. */
4827 rm -f conftest.o conftest.obj
4828 if { { ac_try="$ac_compile"
4830 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4831 *) ac_try_echo=$ac_try;;
4833 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4834 $as_echo "$ac_try_echo"; } >&5
4835 (eval "$ac_compile") 2>&5
4837 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4838 test $ac_status = 0; }; then :
4839 for ac_file in conftest.o conftest.obj conftest.*; do
4840 test -f "$ac_file" || continue;
4842 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
4843 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4848 $as_echo "$as_me: failed program was:" >&5
4849 sed 's/^/| /' conftest.$ac_ext >&5
4851 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4852 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4853 as_fn_error $? "cannot compute suffix of object files: cannot compile
4854 See \`config.log' for more details" "$LINENO" 5; }
4856 rm -f conftest.$ac_cv_objext conftest.$ac_ext
4858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4859 $as_echo "$ac_cv_objext" >&6; }
4860 OBJEXT=$ac_cv_objext
4862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4863 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4864 if ${ac_cv_c_compiler_gnu+:} false; then :
4865 $as_echo_n "(cached) " >&6
4867 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4868 /* end confdefs.h. */
4881 if ac_fn_c_try_compile "$LINENO"; then :
4886 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4887 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4891 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
4892 if test $ac_compiler_gnu = yes; then
4897 ac_test_CFLAGS=${CFLAGS+set}
4898 ac_save_CFLAGS=$CFLAGS
4899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4900 $as_echo_n "checking whether $CC accepts -g... " >&6; }
4901 if ${ac_cv_prog_cc_g+:} false; then :
4902 $as_echo_n "(cached) " >&6
4904 ac_save_c_werror_flag=$ac_c_werror_flag
4905 ac_c_werror_flag=yes
4908 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4909 /* end confdefs.h. */
4919 if ac_fn_c_try_compile "$LINENO"; then :
4923 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4924 /* end confdefs.h. */
4934 if ac_fn_c_try_compile "$LINENO"; then :
4937 ac_c_werror_flag=$ac_save_c_werror_flag
4939 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4940 /* end confdefs.h. */
4950 if ac_fn_c_try_compile "$LINENO"; then :
4953 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4955 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4957 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4958 ac_c_werror_flag=$ac_save_c_werror_flag
4960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4961 $as_echo "$ac_cv_prog_cc_g" >&6; }
4962 if test "$ac_test_CFLAGS" = set; then
4963 CFLAGS=$ac_save_CFLAGS
4964 elif test $ac_cv_prog_cc_g = yes; then
4965 if test "$GCC" = yes; then
4971 if test "$GCC" = yes; then
4977 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4978 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4979 if ${ac_cv_prog_cc_c89+:} false; then :
4980 $as_echo_n "(cached) " >&6
4982 ac_cv_prog_cc_c89=no
4984 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4985 /* end confdefs.h. */
4989 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4990 struct buf { int x; };
4991 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4992 static char *e (p, i)
4998 static char *f (char * (*g) (char **, int), char **p, ...)
5003 s = g (p, va_arg (v,int));
5008 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5009 function prototypes and stuff, but not '\xHH' hex character constants.
5010 These don't provoke an error unfortunately, instead are silently treated
5011 as 'x'. The following induces an error, until -std is added to get
5012 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5013 array size at least. It's necessary to write '\x00'==0 to get something
5014 that's true only with -std. */
5015 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5017 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5018 inside strings and character constants. */
5020 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5022 int test (int i, double x);
5023 struct s1 {int (*f) (int a);};
5024 struct s2 {int (*f) (double a);};
5025 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5031 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5036 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5037 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5039 CC="$ac_save_CC $ac_arg"
5040 if ac_fn_c_try_compile "$LINENO"; then :
5041 ac_cv_prog_cc_c89=$ac_arg
5043 rm -f core conftest.err conftest.$ac_objext
5044 test "x$ac_cv_prog_cc_c89" != "xno" && break
5046 rm -f conftest.$ac_ext
5051 case "x$ac_cv_prog_cc_c89" in
5053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5054 $as_echo "none needed" >&6; } ;;
5056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5057 $as_echo "unsupported" >&6; } ;;
5059 CC="$CC $ac_cv_prog_cc_c89"
5060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5061 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5063 if test "x$ac_cv_prog_cc_c89" != xno; then :
5068 ac_cpp='$CPP $CPPFLAGS'
5069 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5070 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5071 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5074 ac_cpp='$CPP $CPPFLAGS'
5075 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5076 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5077 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5078 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
5079 $as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
5080 if ${am_cv_prog_cc_c_o+:} false; then :
5081 $as_echo_n "(cached) " >&6
5083 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5084 /* end confdefs.h. */
5094 # Make sure it works both with $CC and with simple cc.
5095 # Following AC_PROG_CC_C_O, we do the test twice because some
5096 # compilers refuse to overwrite an existing .o file with -o,
5097 # though they will create one.
5098 am_cv_prog_cc_c_o=yes
5100 if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
5101 ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
5103 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5104 (exit $ac_status); } \
5105 && test -f conftest2.$ac_objext; then
5108 am_cv_prog_cc_c_o=no
5112 rm -f core conftest*
5115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
5116 $as_echo "$am_cv_prog_cc_c_o" >&6; }
5117 if test "$am_cv_prog_cc_c_o" != yes; then
5118 # Losing compiler, so override with the script.
5119 # FIXME: It is wrong to rewrite CC.
5120 # But if we don't then we get into trouble of one sort or another.
5121 # A longer-term fix would be to have automake use am__CC in this case,
5122 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5123 CC="$am_aux_dir/compile $CC"
5126 ac_cpp='$CPP $CPPFLAGS'
5127 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5128 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5129 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5131 DEPDIR="${am__leading_dot}deps"
5133 ac_config_commands="$ac_config_commands depfiles"
5136 am_make=${MAKE-make}
5137 cat > confinc << 'END'
5139 @echo this is the am__doit target
5142 # If we don't find an include directive, just comment out the code.
5143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5144 $as_echo_n "checking for style of include used by $am_make... " >&6; }
5148 # First try GNU make style include.
5149 echo "include confinc" > confmf
5150 # Ignore all kinds of additional output from 'make'.
5151 case `$am_make -s -f confmf 2> /dev/null` in #(
5152 *the\ am__doit\ target*)
5158 # Now try BSD make style include.
5159 if test "$am__include" = "#"; then
5160 echo '.include "confinc"' > confmf
5161 case `$am_make -s -f confmf 2> /dev/null` in #(
5162 *the\ am__doit\ target*)
5163 am__include=.include
5171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5172 $as_echo "$_am_result" >&6; }
5173 rm -f confinc confmf
5175 # Check whether --enable-dependency-tracking was given.
5176 if test "${enable_dependency_tracking+set}" = set; then :
5177 enableval=$enable_dependency_tracking;
5180 if test "x$enable_dependency_tracking" != xno; then
5181 am_depcomp="$ac_aux_dir/depcomp"
5185 if test "x$enable_dependency_tracking" != xno; then
5195 depcc="$CC" am_compiler_list=
5197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5198 $as_echo_n "checking dependency style of $depcc... " >&6; }
5199 if ${am_cv_CC_dependencies_compiler_type+:} false; then :
5200 $as_echo_n "(cached) " >&6
5202 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5203 # We make a subdir and do the tests there. Otherwise we can end up
5204 # making bogus files that we don't know about and never remove. For
5205 # instance it was reported that on HP-UX the gcc test will end up
5206 # making a dummy file named 'D' -- because '-MD' means "put the output
5210 # Copy depcomp to subdir because otherwise we won't find it if we're
5211 # using a relative directory.
5212 cp "$am_depcomp" conftest.dir
5214 # We will build objects and dependencies in a subdirectory because
5215 # it helps to detect inapplicable dependency modes. For instance
5216 # both Tru64's cc and ICC support -MD to output dependencies as a
5217 # side effect of compilation, but ICC will put the dependencies in
5218 # the current directory while Tru64 will put them in the object
5222 am_cv_CC_dependencies_compiler_type=none
5223 if test "$am_compiler_list" = ""; then
5224 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5227 case " $depcc " in #(
5228 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5231 for depmode in $am_compiler_list; do
5232 # Setup a source with many dependencies, because some compilers
5233 # like to wrap large dependency lists on column 80 (with \), and
5234 # we should not choose a depcomp mode which is confused by this.
5236 # We need to recreate these files for each test, as the compiler may
5237 # overwrite some of them when testing with obscure command lines.
5238 # This happens at least with the AIX C compiler.
5240 for i in 1 2 3 4 5 6; do
5241 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5242 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
5243 # Solaris 10 /bin/sh.
5244 echo '/* dummy */' > sub/conftst$i.h
5246 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5248 # We check with '-c' and '-o' for the sake of the "dashmstdout"
5249 # mode. It turns out that the SunPro C++ compiler does not properly
5250 # handle '-M -o', and we need to detect this. Also, some Intel
5251 # versions had trouble with output in subdirs.
5252 am__obj=sub/conftest.${OBJEXT-o}
5253 am__minus_obj="-o $am__obj"
5256 # This depmode causes a compiler race in universal mode.
5257 test "$am__universal" = false || continue
5260 # After this tag, mechanisms are not by side-effect, so they'll
5261 # only be used when explicitly requested.
5262 if test "x$enable_dependency_tracking" = xyes; then
5268 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
5269 # This compiler won't grok '-c -o', but also, the minuso test has
5270 # not run yet. These depmodes are late enough in the game, and
5271 # so weak that their functioning should not be impacted.
5272 am__obj=conftest.${OBJEXT-o}
5277 if depmode=$depmode \
5278 source=sub/conftest.c object=$am__obj \
5279 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5280 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5281 >/dev/null 2>conftest.err &&
5282 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5283 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5284 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5285 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5286 # icc doesn't choke on unknown options, it will just issue warnings
5287 # or remarks (even with -Werror). So we grep stderr for any message
5288 # that says an option was ignored or not supported.
5289 # When given -MP, icc 7.0 and 7.1 complain thusly:
5290 # icc: Command line warning: ignoring option '-M'; no argument required
5291 # The diagnosis changed in icc 8.0:
5292 # icc: Command line remark: option '-MP' not supported
5293 if (grep 'ignoring option' conftest.err ||
5294 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5295 am_cv_CC_dependencies_compiler_type=$depmode
5304 am_cv_CC_dependencies_compiler_type=none
5308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5309 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5310 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5313 test "x$enable_dependency_tracking" != xno \
5314 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5316 am__fastdepCC_FALSE='#'
5318 am__fastdepCC_TRUE='#'
5319 am__fastdepCC_FALSE=
5324 if test -n "$ac_tool_prefix"; then
5325 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5326 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5328 $as_echo_n "checking for $ac_word... " >&6; }
5329 if ${ac_cv_prog_RANLIB+:} false; then :
5330 $as_echo_n "(cached) " >&6
5332 if test -n "$RANLIB"; then
5333 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5335 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5339 test -z "$as_dir" && as_dir=.
5340 for ac_exec_ext in '' $ac_executable_extensions; do
5341 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5342 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5343 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5352 RANLIB=$ac_cv_prog_RANLIB
5353 if test -n "$RANLIB"; then
5354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
5355 $as_echo "$RANLIB" >&6; }
5357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5358 $as_echo "no" >&6; }
5363 if test -z "$ac_cv_prog_RANLIB"; then
5364 ac_ct_RANLIB=$RANLIB
5365 # Extract the first word of "ranlib", so it can be a program name with args.
5366 set dummy ranlib; ac_word=$2
5367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5368 $as_echo_n "checking for $ac_word... " >&6; }
5369 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
5370 $as_echo_n "(cached) " >&6
5372 if test -n "$ac_ct_RANLIB"; then
5373 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
5375 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5379 test -z "$as_dir" && as_dir=.
5380 for ac_exec_ext in '' $ac_executable_extensions; do
5381 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5382 ac_cv_prog_ac_ct_RANLIB="ranlib"
5383 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5392 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
5393 if test -n "$ac_ct_RANLIB"; then
5394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
5395 $as_echo "$ac_ct_RANLIB" >&6; }
5397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5398 $as_echo "no" >&6; }
5401 if test "x$ac_ct_RANLIB" = x; then
5404 case $cross_compiling:$ac_tool_warned in
5406 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5407 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5408 ac_tool_warned=yes ;;
5410 RANLIB=$ac_ct_RANLIB
5413 RANLIB="$ac_cv_prog_RANLIB"
5416 for ac_prog in 'bison -y' byacc
5418 # Extract the first word of "$ac_prog", so it can be a program name with args.
5419 set dummy $ac_prog; ac_word=$2
5420 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5421 $as_echo_n "checking for $ac_word... " >&6; }
5422 if ${ac_cv_prog_YACC+:} false; then :
5423 $as_echo_n "(cached) " >&6
5425 if test -n "$YACC"; then
5426 ac_cv_prog_YACC="$YACC" # Let the user override the test.
5428 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5432 test -z "$as_dir" && as_dir=.
5433 for ac_exec_ext in '' $ac_executable_extensions; do
5434 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5435 ac_cv_prog_YACC="$ac_prog"
5436 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5445 YACC=$ac_cv_prog_YACC
5446 if test -n "$YACC"; then
5447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
5448 $as_echo "$YACC" >&6; }
5450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5451 $as_echo "no" >&6; }
5455 test -n "$YACC" && break
5457 test -n "$YACC" || YACC="yacc"
5461 ac_cpp='$CPP $CPPFLAGS'
5462 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5463 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5464 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5465 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5466 $as_echo_n "checking how to run the C preprocessor... " >&6; }
5467 # On Suns, sometimes $CPP names a directory.
5468 if test -n "$CPP" && test -d "$CPP"; then
5471 if test -z "$CPP"; then
5472 if ${ac_cv_prog_CPP+:} false; then :
5473 $as_echo_n "(cached) " >&6
5475 # Double quotes because CPP needs to be expanded
5476 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5479 for ac_c_preproc_warn_flag in '' yes
5481 # Use a header file that comes with gcc, so configuring glibc
5482 # with a fresh cross-compiler works.
5483 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5484 # <limits.h> exists even on freestanding compilers.
5485 # On the NeXT, cc -E runs the code through the compiler's parser,
5486 # not just through cpp. "Syntax error" is here to catch this case.
5487 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5488 /* end confdefs.h. */
5490 # include <limits.h>
5492 # include <assert.h>
5496 if ac_fn_c_try_cpp "$LINENO"; then :
5499 # Broken: fails on valid input.
5502 rm -f conftest.err conftest.i conftest.$ac_ext
5504 # OK, works on sane cases. Now check whether nonexistent headers
5505 # can be detected and how.
5506 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5507 /* end confdefs.h. */
5508 #include <ac_nonexistent.h>
5510 if ac_fn_c_try_cpp "$LINENO"; then :
5511 # Broken: success on invalid input.
5514 # Passes both tests.
5518 rm -f conftest.err conftest.i conftest.$ac_ext
5521 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5522 rm -f conftest.i conftest.err conftest.$ac_ext
5523 if $ac_preproc_ok; then :
5535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5536 $as_echo "$CPP" >&6; }
5538 for ac_c_preproc_warn_flag in '' yes
5540 # Use a header file that comes with gcc, so configuring glibc
5541 # with a fresh cross-compiler works.
5542 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5543 # <limits.h> exists even on freestanding compilers.
5544 # On the NeXT, cc -E runs the code through the compiler's parser,
5545 # not just through cpp. "Syntax error" is here to catch this case.
5546 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5547 /* end confdefs.h. */
5549 # include <limits.h>
5551 # include <assert.h>
5555 if ac_fn_c_try_cpp "$LINENO"; then :
5558 # Broken: fails on valid input.
5561 rm -f conftest.err conftest.i conftest.$ac_ext
5563 # OK, works on sane cases. Now check whether nonexistent headers
5564 # can be detected and how.
5565 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5566 /* end confdefs.h. */
5567 #include <ac_nonexistent.h>
5569 if ac_fn_c_try_cpp "$LINENO"; then :
5570 # Broken: success on invalid input.
5573 # Passes both tests.
5577 rm -f conftest.err conftest.i conftest.$ac_ext
5580 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5581 rm -f conftest.i conftest.err conftest.$ac_ext
5582 if $ac_preproc_ok; then :
5585 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5586 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5587 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
5588 See \`config.log' for more details" "$LINENO" 5; }
5592 ac_cpp='$CPP $CPPFLAGS'
5593 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5594 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5595 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
5599 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5600 if ${ac_cv_path_GREP+:} false; then :
5601 $as_echo_n "(cached) " >&6
5603 if test -z "$GREP"; then
5604 ac_path_GREP_found=false
5605 # Loop through the user's path and test for each of PROGNAME-LIST
5606 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5607 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5610 test -z "$as_dir" && as_dir=.
5611 for ac_prog in grep ggrep; do
5612 for ac_exec_ext in '' $ac_executable_extensions; do
5613 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5614 as_fn_executable_p "$ac_path_GREP" || continue
5615 # Check for GNU ac_path_GREP and select it if it is found.
5616 # Check for GNU $ac_path_GREP
5617 case `"$ac_path_GREP" --version 2>&1` in
5619 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5622 $as_echo_n 0123456789 >"conftest.in"
5625 cat "conftest.in" "conftest.in" >"conftest.tmp"
5626 mv "conftest.tmp" "conftest.in"
5627 cp "conftest.in" "conftest.nl"
5628 $as_echo 'GREP' >> "conftest.nl"
5629 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5630 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5631 as_fn_arith $ac_count + 1 && ac_count=$as_val
5632 if test $ac_count -gt ${ac_path_GREP_max-0}; then
5633 # Best one so far, save it but keep looking for a better one
5634 ac_cv_path_GREP="$ac_path_GREP"
5635 ac_path_GREP_max=$ac_count
5637 # 10*(2^10) chars as input seems more than enough
5638 test $ac_count -gt 10 && break
5640 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5643 $ac_path_GREP_found && break 3
5648 if test -z "$ac_cv_path_GREP"; then
5649 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5652 ac_cv_path_GREP=$GREP
5656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
5657 $as_echo "$ac_cv_path_GREP" >&6; }
5658 GREP="$ac_cv_path_GREP"
5661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
5662 $as_echo_n "checking for egrep... " >&6; }
5663 if ${ac_cv_path_EGREP+:} false; then :
5664 $as_echo_n "(cached) " >&6
5666 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5667 then ac_cv_path_EGREP="$GREP -E"
5669 if test -z "$EGREP"; then
5670 ac_path_EGREP_found=false
5671 # Loop through the user's path and test for each of PROGNAME-LIST
5672 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5673 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5676 test -z "$as_dir" && as_dir=.
5677 for ac_prog in egrep; do
5678 for ac_exec_ext in '' $ac_executable_extensions; do
5679 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
5680 as_fn_executable_p "$ac_path_EGREP" || continue
5681 # Check for GNU ac_path_EGREP and select it if it is found.
5682 # Check for GNU $ac_path_EGREP
5683 case `"$ac_path_EGREP" --version 2>&1` in
5685 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5688 $as_echo_n 0123456789 >"conftest.in"
5691 cat "conftest.in" "conftest.in" >"conftest.tmp"
5692 mv "conftest.tmp" "conftest.in"
5693 cp "conftest.in" "conftest.nl"
5694 $as_echo 'EGREP' >> "conftest.nl"
5695 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5696 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5697 as_fn_arith $ac_count + 1 && ac_count=$as_val
5698 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5699 # Best one so far, save it but keep looking for a better one
5700 ac_cv_path_EGREP="$ac_path_EGREP"
5701 ac_path_EGREP_max=$ac_count
5703 # 10*(2^10) chars as input seems more than enough
5704 test $ac_count -gt 10 && break
5706 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5709 $ac_path_EGREP_found && break 3
5714 if test -z "$ac_cv_path_EGREP"; then
5715 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5718 ac_cv_path_EGREP=$EGREP
5723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
5724 $as_echo "$ac_cv_path_EGREP" >&6; }
5725 EGREP="$ac_cv_path_EGREP"
5730 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
5731 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
5732 if ${gl_cv_c_amsterdam_compiler+:} false; then :
5733 $as_echo_n "(cached) " >&6
5736 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5737 /* end confdefs.h. */
5744 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5745 $EGREP "Amsterdam" >/dev/null 2>&1; then :
5746 gl_cv_c_amsterdam_compiler=yes
5748 gl_cv_c_amsterdam_compiler=no
5754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
5755 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
5756 if test -z "$AR"; then
5757 if test $gl_cv_c_amsterdam_compiler = yes; then
5759 if test -z "$ARFLAGS"; then
5763 if test -n "$ac_tool_prefix"; then
5764 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
5765 set dummy ${ac_tool_prefix}ar; ac_word=$2
5766 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5767 $as_echo_n "checking for $ac_word... " >&6; }
5768 if ${ac_cv_prog_AR+:} false; then :
5769 $as_echo_n "(cached) " >&6
5771 if test -n "$AR"; then
5772 ac_cv_prog_AR="$AR" # Let the user override the test.
5774 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5778 test -z "$as_dir" && as_dir=.
5779 for ac_exec_ext in '' $ac_executable_extensions; do
5780 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5781 ac_cv_prog_AR="${ac_tool_prefix}ar"
5782 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5792 if test -n "$AR"; then
5793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
5794 $as_echo "$AR" >&6; }
5796 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5797 $as_echo "no" >&6; }
5802 if test -z "$ac_cv_prog_AR"; then
5804 # Extract the first word of "ar", so it can be a program name with args.
5805 set dummy ar; ac_word=$2
5806 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5807 $as_echo_n "checking for $ac_word... " >&6; }
5808 if ${ac_cv_prog_ac_ct_AR+:} false; then :
5809 $as_echo_n "(cached) " >&6
5811 if test -n "$ac_ct_AR"; then
5812 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
5814 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5818 test -z "$as_dir" && as_dir=.
5819 for ac_exec_ext in '' $ac_executable_extensions; do
5820 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5821 ac_cv_prog_ac_ct_AR="ar"
5822 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5831 ac_ct_AR=$ac_cv_prog_ac_ct_AR
5832 if test -n "$ac_ct_AR"; then
5833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
5834 $as_echo "$ac_ct_AR" >&6; }
5836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5837 $as_echo "no" >&6; }
5840 if test "x$ac_ct_AR" = x; then
5843 case $cross_compiling:$ac_tool_warned in
5845 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5846 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5847 ac_tool_warned=yes ;;
5855 if test -z "$ARFLAGS"; then
5860 if test -z "$ARFLAGS"; then
5866 if test -z "$RANLIB"; then
5867 if test $gl_cv_c_amsterdam_compiler = yes; then
5870 if test -n "$ac_tool_prefix"; then
5871 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5872 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5873 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5874 $as_echo_n "checking for $ac_word... " >&6; }
5875 if ${ac_cv_prog_RANLIB+:} false; then :
5876 $as_echo_n "(cached) " >&6
5878 if test -n "$RANLIB"; then
5879 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5881 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5885 test -z "$as_dir" && as_dir=.
5886 for ac_exec_ext in '' $ac_executable_extensions; do
5887 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5888 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5889 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5898 RANLIB=$ac_cv_prog_RANLIB
5899 if test -n "$RANLIB"; then
5900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
5901 $as_echo "$RANLIB" >&6; }
5903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5904 $as_echo "no" >&6; }
5909 if test -z "$ac_cv_prog_RANLIB"; then
5910 ac_ct_RANLIB=$RANLIB
5911 # Extract the first word of "ranlib", so it can be a program name with args.
5912 set dummy ranlib; ac_word=$2
5913 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5914 $as_echo_n "checking for $ac_word... " >&6; }
5915 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
5916 $as_echo_n "(cached) " >&6
5918 if test -n "$ac_ct_RANLIB"; then
5919 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
5921 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5925 test -z "$as_dir" && as_dir=.
5926 for ac_exec_ext in '' $ac_executable_extensions; do
5927 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5928 ac_cv_prog_ac_ct_RANLIB="ranlib"
5929 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5938 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
5939 if test -n "$ac_ct_RANLIB"; then
5940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
5941 $as_echo "$ac_ct_RANLIB" >&6; }
5943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5944 $as_echo "no" >&6; }
5947 if test "x$ac_ct_RANLIB" = x; then
5950 case $cross_compiling:$ac_tool_warned in
5952 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5953 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5954 ac_tool_warned=yes ;;
5956 RANLIB=$ac_ct_RANLIB
5959 RANLIB="$ac_cv_prog_RANLIB"
5967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
5968 $as_echo_n "checking for ANSI C header files... " >&6; }
5969 if ${ac_cv_header_stdc+:} false; then :
5970 $as_echo_n "(cached) " >&6
5972 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5973 /* end confdefs.h. */
5987 if ac_fn_c_try_compile "$LINENO"; then :
5988 ac_cv_header_stdc=yes
5990 ac_cv_header_stdc=no
5992 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5994 if test $ac_cv_header_stdc = yes; then
5995 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5996 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5997 /* end confdefs.h. */
6001 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6002 $EGREP "memchr" >/dev/null 2>&1; then :
6005 ac_cv_header_stdc=no
6011 if test $ac_cv_header_stdc = yes; then
6012 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6013 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6014 /* end confdefs.h. */
6018 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6019 $EGREP "free" >/dev/null 2>&1; then :
6022 ac_cv_header_stdc=no
6028 if test $ac_cv_header_stdc = yes; then
6029 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6030 if test "$cross_compiling" = yes; then :
6033 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6034 /* end confdefs.h. */
6037 #if ((' ' & 0x0FF) == 0x020)
6038 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6039 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6041 # define ISLOWER(c) \
6042 (('a' <= (c) && (c) <= 'i') \
6043 || ('j' <= (c) && (c) <= 'r') \
6044 || ('s' <= (c) && (c) <= 'z'))
6045 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6048 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6053 for (i = 0; i < 256; i++)
6054 if (XOR (islower (i), ISLOWER (i))
6055 || toupper (i) != TOUPPER (i))
6060 if ac_fn_c_try_run "$LINENO"; then :
6063 ac_cv_header_stdc=no
6065 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6066 conftest.$ac_objext conftest.beam conftest.$ac_ext
6071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6072 $as_echo "$ac_cv_header_stdc" >&6; }
6073 if test $ac_cv_header_stdc = yes; then
6075 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6079 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6080 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6081 inttypes.h stdint.h unistd.h
6083 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6084 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6086 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
6087 cat >>confdefs.h <<_ACEOF
6088 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6097 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
6098 if test "x$ac_cv_header_minix_config_h" = xyes; then :
6105 if test "$MINIX" = yes; then
6107 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
6110 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
6113 $as_echo "#define _MINIX 1" >>confdefs.h
6116 $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h
6121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6122 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
6123 if ${ac_cv_safe_to_define___extensions__+:} false; then :
6124 $as_echo_n "(cached) " >&6
6126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6127 /* end confdefs.h. */
6129 # define __EXTENSIONS__ 1
6130 $ac_includes_default
6139 if ac_fn_c_try_compile "$LINENO"; then :
6140 ac_cv_safe_to_define___extensions__=yes
6142 ac_cv_safe_to_define___extensions__=no
6144 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6147 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
6148 test $ac_cv_safe_to_define___extensions__ = yes &&
6149 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
6151 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6153 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
6155 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
6157 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6159 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
6161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5
6162 $as_echo_n "checking whether _XOPEN_SOURCE should be defined... " >&6; }
6163 if ${ac_cv_should_define__xopen_source+:} false; then :
6164 $as_echo_n "(cached) " >&6
6166 ac_cv_should_define__xopen_source=no
6167 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6168 /* end confdefs.h. */
6180 if ac_fn_c_try_compile "$LINENO"; then :
6183 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6184 /* end confdefs.h. */
6186 #define _XOPEN_SOURCE 500
6197 if ac_fn_c_try_compile "$LINENO"; then :
6198 ac_cv_should_define__xopen_source=yes
6200 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6202 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5
6205 $as_echo "$ac_cv_should_define__xopen_source" >&6; }
6206 test $ac_cv_should_define__xopen_source = yes &&
6207 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
6216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
6217 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
6218 if ${ac_cv_sys_largefile_source+:} false; then :
6219 $as_echo_n "(cached) " >&6
6222 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6223 /* end confdefs.h. */
6224 #include <sys/types.h> /* for off_t */
6229 int (*fp) (FILE *, off_t, int) = fseeko;
6230 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
6235 if ac_fn_c_try_link "$LINENO"; then :
6236 ac_cv_sys_largefile_source=no; break
6238 rm -f core conftest.err conftest.$ac_objext \
6239 conftest$ac_exeext conftest.$ac_ext
6240 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6241 /* end confdefs.h. */
6242 #define _LARGEFILE_SOURCE 1
6243 #include <sys/types.h> /* for off_t */
6248 int (*fp) (FILE *, off_t, int) = fseeko;
6249 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
6254 if ac_fn_c_try_link "$LINENO"; then :
6255 ac_cv_sys_largefile_source=1; break
6257 rm -f core conftest.err conftest.$ac_objext \
6258 conftest$ac_exeext conftest.$ac_ext
6259 ac_cv_sys_largefile_source=unknown
6263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
6264 $as_echo "$ac_cv_sys_largefile_source" >&6; }
6265 case $ac_cv_sys_largefile_source in #(
6268 cat >>confdefs.h <<_ACEOF
6269 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
6275 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
6276 # in glibc 2.1.3, but that breaks too many other things.
6277 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
6278 if test $ac_cv_sys_largefile_source != unknown; then
6280 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
6284 # Check whether --enable-largefile was given.
6285 if test "${enable_largefile+set}" = set; then :
6286 enableval=$enable_largefile;
6289 if test "$enable_largefile" != no; then
6291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
6292 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
6293 if ${ac_cv_sys_largefile_CC+:} false; then :
6294 $as_echo_n "(cached) " >&6
6296 ac_cv_sys_largefile_CC=no
6297 if test "$GCC" != yes; then
6300 # IRIX 6.2 and later do not support large files by default,
6301 # so use the C compiler's -n32 option if that helps.
6302 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6303 /* end confdefs.h. */
6304 #include <sys/types.h>
6305 /* Check that off_t can represent 2**63 - 1 correctly.
6306 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6307 since some C++ compilers masquerading as C compilers
6308 incorrectly reject 9223372036854775807. */
6309 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6310 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6311 && LARGE_OFF_T % 2147483647 == 1)
6321 if ac_fn_c_try_compile "$LINENO"; then :
6324 rm -f core conftest.err conftest.$ac_objext
6326 if ac_fn_c_try_compile "$LINENO"; then :
6327 ac_cv_sys_largefile_CC=' -n32'; break
6329 rm -f core conftest.err conftest.$ac_objext
6333 rm -f conftest.$ac_ext
6336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
6337 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
6338 if test "$ac_cv_sys_largefile_CC" != no; then
6339 CC=$CC$ac_cv_sys_largefile_CC
6342 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
6343 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
6344 if ${ac_cv_sys_file_offset_bits+:} false; then :
6345 $as_echo_n "(cached) " >&6
6348 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6349 /* end confdefs.h. */
6350 #include <sys/types.h>
6351 /* Check that off_t can represent 2**63 - 1 correctly.
6352 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6353 since some C++ compilers masquerading as C compilers
6354 incorrectly reject 9223372036854775807. */
6355 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6356 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6357 && LARGE_OFF_T % 2147483647 == 1)
6367 if ac_fn_c_try_compile "$LINENO"; then :
6368 ac_cv_sys_file_offset_bits=no; break
6370 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6371 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6372 /* end confdefs.h. */
6373 #define _FILE_OFFSET_BITS 64
6374 #include <sys/types.h>
6375 /* Check that off_t can represent 2**63 - 1 correctly.
6376 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6377 since some C++ compilers masquerading as C compilers
6378 incorrectly reject 9223372036854775807. */
6379 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6380 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6381 && LARGE_OFF_T % 2147483647 == 1)
6391 if ac_fn_c_try_compile "$LINENO"; then :
6392 ac_cv_sys_file_offset_bits=64; break
6394 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6395 ac_cv_sys_file_offset_bits=unknown
6399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6400 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
6401 case $ac_cv_sys_file_offset_bits in #(
6404 cat >>confdefs.h <<_ACEOF
6405 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6410 if test $ac_cv_sys_file_offset_bits = unknown; then
6411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6412 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
6413 if ${ac_cv_sys_large_files+:} false; then :
6414 $as_echo_n "(cached) " >&6
6417 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6418 /* end confdefs.h. */
6419 #include <sys/types.h>
6420 /* Check that off_t can represent 2**63 - 1 correctly.
6421 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6422 since some C++ compilers masquerading as C compilers
6423 incorrectly reject 9223372036854775807. */
6424 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6425 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6426 && LARGE_OFF_T % 2147483647 == 1)
6436 if ac_fn_c_try_compile "$LINENO"; then :
6437 ac_cv_sys_large_files=no; break
6439 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6440 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6441 /* end confdefs.h. */
6442 #define _LARGE_FILES 1
6443 #include <sys/types.h>
6444 /* Check that off_t can represent 2**63 - 1 correctly.
6445 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6446 since some C++ compilers masquerading as C compilers
6447 incorrectly reject 9223372036854775807. */
6448 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6449 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6450 && LARGE_OFF_T % 2147483647 == 1)
6460 if ac_fn_c_try_compile "$LINENO"; then :
6461 ac_cv_sys_large_files=1; break
6463 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6464 ac_cv_sys_large_files=unknown
6468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6469 $as_echo "$ac_cv_sys_large_files" >&6; }
6470 case $ac_cv_sys_large_files in #(
6473 cat >>confdefs.h <<_ACEOF
6474 #define _LARGE_FILES $ac_cv_sys_large_files
6482 $as_echo "#define _DARWIN_USE_64_BIT_INODE 1" >>confdefs.h
6486 case $ac_cv_prog_cc_stdc in #(
6488 ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
6490 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
6491 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
6492 if ${ac_cv_prog_cc_c99+:} false; then :
6493 $as_echo_n "(cached) " >&6
6495 ac_cv_prog_cc_c99=no
6497 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6498 /* end confdefs.h. */
6500 #include <stdbool.h>
6505 // Check varargs macros. These examples are taken from C99 6.10.3.5.
6506 #define debug(...) fprintf (stderr, __VA_ARGS__)
6507 #define showlist(...) puts (#__VA_ARGS__)
6508 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
6510 test_varargs_macros (void)
6515 debug ("X = %d\n", x);
6516 showlist (The first, second, and third items.);
6517 report (x>y, "x is %d but y is %d", x, y);
6520 // Check long long types.
6521 #define BIG64 18446744073709551615ull
6522 #define BIG32 4294967295ul
6523 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
6525 your preprocessor is broken;
6529 your preprocessor is broken;
6531 static long long int bignum = -9223372036854775807LL;
6532 static unsigned long long int ubignum = BIG64;
6534 struct incomplete_array
6542 const wchar_t *name;
6546 typedef const char *ccp;
6549 test_restrict (ccp restrict text)
6551 // See if C++-style comments work.
6552 // Iterate through items via the restricted pointer.
6553 // Also check for declarations in for loops.
6554 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
6559 // Check varargs and va_copy.
6561 test_varargs (const char *format, ...)
6564 va_start (args, format);
6566 va_copy (args_copy, args);
6577 str = va_arg (args_copy, const char *);
6580 number = va_arg (args_copy, int);
6583 fnumber = va_arg (args_copy, double);
6598 _Bool success = false;
6601 if (test_restrict ("String literal") == 0)
6603 char *restrict newvar = "Another string";
6606 test_varargs ("s, d' f .", "string", 65, 34.234);
6607 test_varargs_macros ();
6609 // Check flexible array members.
6610 struct incomplete_array *ia =
6611 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
6613 for (int i = 0; i < ia->datasize; ++i)
6614 ia->data[i] = i * 1.234;
6616 // Check named initializers.
6617 struct named_init ni = {
6619 .name = L"Test wide string",
6620 .average = 543.34343,
6625 int dynamic_array[ni.number];
6626 dynamic_array[ni.number - 1] = 543;
6628 // work around unused variable warnings
6629 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
6630 || dynamic_array[ni.number - 1] != 543);
6636 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc99
6638 CC="$ac_save_CC $ac_arg"
6639 if ac_fn_c_try_compile "$LINENO"; then :
6640 ac_cv_prog_cc_c99=$ac_arg
6642 rm -f core conftest.err conftest.$ac_objext
6643 test "x$ac_cv_prog_cc_c99" != "xno" && break
6645 rm -f conftest.$ac_ext
6650 case "x$ac_cv_prog_cc_c99" in
6652 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6653 $as_echo "none needed" >&6; } ;;
6655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6656 $as_echo "unsupported" >&6; } ;;
6658 CC="$CC $ac_cv_prog_cc_c99"
6659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
6660 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
6662 if test "x$ac_cv_prog_cc_c99" != xno; then :
6663 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
6665 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
6666 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
6667 if ${ac_cv_prog_cc_c89+:} false; then :
6668 $as_echo_n "(cached) " >&6
6670 ac_cv_prog_cc_c89=no
6672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6673 /* end confdefs.h. */
6677 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
6678 struct buf { int x; };
6679 FILE * (*rcsopen) (struct buf *, struct stat *, int);
6680 static char *e (p, i)
6686 static char *f (char * (*g) (char **, int), char **p, ...)
6691 s = g (p, va_arg (v,int));
6696 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
6697 function prototypes and stuff, but not '\xHH' hex character constants.
6698 These don't provoke an error unfortunately, instead are silently treated
6699 as 'x'. The following induces an error, until -std is added to get
6700 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
6701 array size at least. It's necessary to write '\x00'==0 to get something
6702 that's true only with -std. */
6703 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
6705 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
6706 inside strings and character constants. */
6708 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
6710 int test (int i, double x);
6711 struct s1 {int (*f) (int a);};
6712 struct s2 {int (*f) (double a);};
6713 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
6719 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
6724 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
6725 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
6727 CC="$ac_save_CC $ac_arg"
6728 if ac_fn_c_try_compile "$LINENO"; then :
6729 ac_cv_prog_cc_c89=$ac_arg
6731 rm -f core conftest.err conftest.$ac_objext
6732 test "x$ac_cv_prog_cc_c89" != "xno" && break
6734 rm -f conftest.$ac_ext
6739 case "x$ac_cv_prog_cc_c89" in
6741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6742 $as_echo "none needed" >&6; } ;;
6744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6745 $as_echo "unsupported" >&6; } ;;
6747 CC="$CC $ac_cv_prog_cc_c89"
6748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
6749 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
6751 if test "x$ac_cv_prog_cc_c89" != xno; then :
6752 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
6754 ac_cv_prog_cc_stdc=no
6760 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
6761 $as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
6762 if ${ac_cv_prog_cc_stdc+:} false; then :
6763 $as_echo_n "(cached) " >&6
6766 case $ac_cv_prog_cc_stdc in #(
6768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6769 $as_echo "unsupported" >&6; } ;; #(
6771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6772 $as_echo "none needed" >&6; } ;; #(
6774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
6775 $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
6781 # Code from module acl:
6782 # Code from module alloca:
6783 # Code from module alloca-opt:
6784 # Code from module allocator:
6785 # Code from module areadlink:
6786 # Code from module areadlinkat:
6787 # Code from module argmatch:
6788 # Code from module argp:
6789 # Code from module argp-version-etc:
6790 # Code from module at-internal:
6791 # Code from module backupfile:
6792 # Code from module bitrotate:
6793 # Code from module btowc:
6794 # Code from module c-ctype:
6795 # Code from module c-strcase:
6796 # Code from module c-strcaseeq:
6797 # Code from module canonicalize-lgpl:
6798 # Code from module careadlinkat:
6799 # Code from module chdir:
6800 # Code from module chdir-long:
6801 # Code from module chown:
6802 # Code from module clock-time:
6803 # Code from module cloexec:
6804 # Code from module close:
6805 # Code from module close-stream:
6806 # Code from module closedir:
6807 # Code from module closeout:
6808 # Code from module configmake:
6809 # Code from module d-ino:
6810 # Code from module dirent:
6811 # Code from module dirent-safer:
6812 # Code from module dirfd:
6813 # Code from module dirname:
6814 # Code from module dirname-lgpl:
6815 # Code from module dosname:
6816 # Code from module double-slash-root:
6817 # Code from module dup:
6818 # Code from module dup2:
6819 # Code from module environ:
6820 # Code from module errno:
6821 # Code from module error:
6822 # Code from module exclude:
6823 # Code from module exitfail:
6824 # Code from module extensions:
6826 # Code from module extern-inline:
6827 # Code from module fchdir:
6828 # Code from module fchmodat:
6829 # Code from module fchownat:
6830 # Code from module fcntl:
6831 # Code from module fcntl-h:
6832 # Code from module fd-hook:
6833 # Code from module fdopendir:
6834 # Code from module fdutimensat:
6835 # Code from module fileblocks:
6836 # Code from module filename:
6837 # Code from module filenamecat-lgpl:
6838 # Code from module float:
6839 # Code from module fnmatch:
6840 # Code from module fnmatch-gnu:
6841 # Code from module fpending:
6842 # Code from module fseek:
6843 # Code from module fseeko:
6845 # Code from module fstat:
6846 # Code from module fstatat:
6847 # Code from module full-write:
6848 # Code from module futimens:
6849 # Code from module getcwd:
6850 # Code from module getcwd-lgpl:
6851 # Code from module getdelim:
6852 # Code from module getdtablesize:
6853 # Code from module getline:
6854 # Code from module getopt-gnu:
6855 # Code from module getopt-posix:
6856 # Code from module getpagesize:
6857 # Code from module gettext:
6858 # Code from module gettext-h:
6859 # Code from module gettime:
6860 # Code from module gettimeofday:
6861 # Code from module gitlog-to-changelog:
6862 # Code from module hash:
6863 # Code from module havelib:
6864 # Code from module human:
6865 # Code from module include_next:
6866 # Code from module intprops:
6867 # Code from module inttostr:
6868 # Code from module inttypes:
6869 # Code from module inttypes-incomplete:
6870 # Code from module iswblank:
6871 # Code from module langinfo:
6872 # Code from module largefile:
6874 # Code from module lchown:
6875 # Code from module link:
6876 # Code from module link-follow:
6877 # Code from module linkat:
6878 # Code from module localcharset:
6879 # Code from module locale:
6880 # Code from module localeconv:
6881 # Code from module lseek:
6882 # Code from module lstat:
6883 # Code from module malloc-gnu:
6884 # Code from module malloc-posix:
6885 # Code from module malloca:
6886 # Code from module manywarnings:
6887 # Code from module mbchar:
6888 # Code from module mbrtowc:
6889 # Code from module mbscasecmp:
6890 # Code from module mbsinit:
6891 # Code from module mbsrtowcs:
6892 # Code from module mbtowc:
6893 # Code from module mbuiter:
6894 # Code from module memchr:
6895 # Code from module mempcpy:
6896 # Code from module memrchr:
6897 # Code from module mkdir:
6898 # Code from module mkdirat:
6899 # Code from module mkdtemp:
6900 # Code from module mkfifo:
6901 # Code from module mkfifoat:
6902 # Code from module mknod:
6903 # Code from module mktime:
6904 # Code from module modechange:
6905 # Code from module msvc-inval:
6906 # Code from module msvc-nothrow:
6907 # Code from module multiarch:
6908 # Code from module nl_langinfo:
6909 # Code from module nocrash:
6910 # Code from module obstack:
6911 # Code from module open:
6912 # Code from module openat:
6913 # Code from module openat-die:
6914 # Code from module openat-h:
6915 # Code from module opendir:
6916 # Code from module parse-datetime:
6917 # Code from module pathmax:
6918 # Code from module priv-set:
6919 # Code from module progname:
6920 # Code from module qacl:
6921 # Code from module quote:
6922 # Code from module quotearg:
6923 # Code from module quotearg-simple:
6924 # Code from module raise:
6925 # Code from module rawmemchr:
6926 # Code from module read:
6927 # Code from module readdir:
6928 # Code from module readlink:
6929 # Code from module readlinkat:
6930 # Code from module realloc-posix:
6931 # Code from module regex:
6932 # Code from module rename:
6933 # Code from module renameat:
6934 # Code from module rewinddir:
6935 # Code from module rmdir:
6936 # Code from module root-uid:
6937 # Code from module rpmatch:
6938 # Code from module safe-read:
6939 # Code from module safe-write:
6940 # Code from module same-inode:
6941 # Code from module save-cwd:
6942 # Code from module savedir:
6943 # Code from module secure_getenv:
6944 # Code from module selinux-at:
6945 # Code from module selinux-h:
6946 # Code from module setenv:
6947 # Code from module signal-h:
6948 # Code from module size_max:
6949 # Code from module sleep:
6950 # Code from module snippet/_Noreturn:
6951 # Code from module snippet/arg-nonnull:
6952 # Code from module snippet/c++defs:
6953 # Code from module snippet/unused-parameter:
6954 # Code from module snippet/warn-on-use:
6955 # Code from module snprintf:
6956 # Code from module ssize_t:
6957 # Code from module stat:
6958 # Code from module stat-macros:
6959 # Code from module stat-time:
6960 # Code from module statat:
6961 # Code from module stdalign:
6962 # Code from module stdarg:
6966 # Code from module stdbool:
6967 # Code from module stddef:
6968 # Code from module stdint:
6969 # Code from module stdio:
6970 # Code from module stdlib:
6971 # Code from module stpcpy:
6972 # Code from module strcase:
6973 # Code from module strchrnul:
6974 # Code from module strdup-posix:
6975 # Code from module streq:
6976 # Code from module strerror:
6977 # Code from module strerror-override:
6978 # Code from module string:
6979 # Code from module strings:
6980 # Code from module strndup:
6981 # Code from module strnlen:
6982 # Code from module strnlen1:
6983 # Code from module strtol:
6984 # Code from module strtoul:
6985 # Code from module strtoull:
6986 # Code from module strtoumax:
6987 # Code from module symlink:
6988 # Code from module symlinkat:
6989 # Code from module sys_stat:
6990 # Code from module sys_time:
6991 # Code from module sys_types:
6992 # Code from module sysexits:
6993 # Code from module tempname:
6994 # Code from module time:
6995 # Code from module time_r:
6996 # Code from module timespec:
6997 # Code from module unistd:
6998 # Code from module unistd-safer:
6999 # Code from module unitypes:
7000 # Code from module uniwidth/base:
7001 # Code from module uniwidth/width:
7002 # Code from module unlink:
7003 # Code from module unlinkat:
7004 # Code from module unlinkdir:
7005 # Code from module unlocked-io:
7006 # Code from module unsetenv:
7007 # Code from module utimens:
7008 # Code from module utimensat:
7009 # Code from module vasnprintf:
7010 # Code from module vasprintf:
7011 # Code from module verify:
7012 # Code from module version-etc:
7013 # Code from module version-etc-fsf:
7014 # Code from module vsnprintf:
7015 # Code from module warnings:
7016 # Code from module wchar:
7017 # Code from module wcrtomb:
7018 # Code from module wctype-h:
7019 # Code from module wcwidth:
7020 # Code from module write:
7021 # Code from module xalloc:
7022 # Code from module xalloc-die:
7023 # Code from module xalloc-oversized:
7024 # Code from module xgetcwd:
7025 # Code from module xsize:
7026 # Code from module xstrndup:
7027 # Code from module xstrtol:
7028 # Code from module xstrtoumax:
7029 # Code from module xvasprintf:
7032 # Check whether --enable-largefile was given.
7033 if test "${enable_largefile+set}" = set; then :
7034 enableval=$enable_largefile;
7037 if test "$enable_largefile" != no; then
7039 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
7040 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
7041 if ${ac_cv_sys_largefile_CC+:} false; then :
7042 $as_echo_n "(cached) " >&6
7044 ac_cv_sys_largefile_CC=no
7045 if test "$GCC" != yes; then
7048 # IRIX 6.2 and later do not support large files by default,
7049 # so use the C compiler's -n32 option if that helps.
7050 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7051 /* end confdefs.h. */
7052 #include <sys/types.h>
7053 /* Check that off_t can represent 2**63 - 1 correctly.
7054 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7055 since some C++ compilers masquerading as C compilers
7056 incorrectly reject 9223372036854775807. */
7057 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7058 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7059 && LARGE_OFF_T % 2147483647 == 1)
7069 if ac_fn_c_try_compile "$LINENO"; then :
7072 rm -f core conftest.err conftest.$ac_objext
7074 if ac_fn_c_try_compile "$LINENO"; then :
7075 ac_cv_sys_largefile_CC=' -n32'; break
7077 rm -f core conftest.err conftest.$ac_objext
7081 rm -f conftest.$ac_ext
7084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
7085 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
7086 if test "$ac_cv_sys_largefile_CC" != no; then
7087 CC=$CC$ac_cv_sys_largefile_CC
7090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
7091 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
7092 if ${ac_cv_sys_file_offset_bits+:} false; then :
7093 $as_echo_n "(cached) " >&6
7096 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7097 /* end confdefs.h. */
7098 #include <sys/types.h>
7099 /* Check that off_t can represent 2**63 - 1 correctly.
7100 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7101 since some C++ compilers masquerading as C compilers
7102 incorrectly reject 9223372036854775807. */
7103 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7104 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7105 && LARGE_OFF_T % 2147483647 == 1)
7115 if ac_fn_c_try_compile "$LINENO"; then :
7116 ac_cv_sys_file_offset_bits=no; break
7118 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7119 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7120 /* end confdefs.h. */
7121 #define _FILE_OFFSET_BITS 64
7122 #include <sys/types.h>
7123 /* Check that off_t can represent 2**63 - 1 correctly.
7124 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7125 since some C++ compilers masquerading as C compilers
7126 incorrectly reject 9223372036854775807. */
7127 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7128 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7129 && LARGE_OFF_T % 2147483647 == 1)
7139 if ac_fn_c_try_compile "$LINENO"; then :
7140 ac_cv_sys_file_offset_bits=64; break
7142 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7143 ac_cv_sys_file_offset_bits=unknown
7147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
7148 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
7149 case $ac_cv_sys_file_offset_bits in #(
7152 cat >>confdefs.h <<_ACEOF
7153 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
7158 if test $ac_cv_sys_file_offset_bits = unknown; then
7159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
7160 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
7161 if ${ac_cv_sys_large_files+:} false; then :
7162 $as_echo_n "(cached) " >&6
7165 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7166 /* end confdefs.h. */
7167 #include <sys/types.h>
7168 /* Check that off_t can represent 2**63 - 1 correctly.
7169 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7170 since some C++ compilers masquerading as C compilers
7171 incorrectly reject 9223372036854775807. */
7172 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7173 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7174 && LARGE_OFF_T % 2147483647 == 1)
7184 if ac_fn_c_try_compile "$LINENO"; then :
7185 ac_cv_sys_large_files=no; break
7187 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7188 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7189 /* end confdefs.h. */
7190 #define _LARGE_FILES 1
7191 #include <sys/types.h>
7192 /* Check that off_t can represent 2**63 - 1 correctly.
7193 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7194 since some C++ compilers masquerading as C compilers
7195 incorrectly reject 9223372036854775807. */
7196 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7197 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7198 && LARGE_OFF_T % 2147483647 == 1)
7208 if ac_fn_c_try_compile "$LINENO"; then :
7209 ac_cv_sys_large_files=1; break
7211 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7212 ac_cv_sys_large_files=unknown
7216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
7217 $as_echo "$ac_cv_sys_large_files" >&6; }
7218 case $ac_cv_sys_large_files in #(
7221 cat >>confdefs.h <<_ACEOF
7222 #define _LARGE_FILES $ac_cv_sys_large_files
7230 $as_echo "#define _DARWIN_USE_64_BIT_INODE 1" >>confdefs.h
7234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing strerror" >&5
7235 $as_echo_n "checking for library containing strerror... " >&6; }
7236 if ${ac_cv_search_strerror+:} false; then :
7237 $as_echo_n "(cached) " >&6
7239 ac_func_search_save_LIBS=$LIBS
7240 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7241 /* end confdefs.h. */
7243 /* Override any GCC internal prototype to avoid an error.
7244 Use char because int might match the return type of a GCC
7245 builtin and then its argument prototype would still apply. */
7258 for ac_lib in '' cposix; do
7259 if test -z "$ac_lib"; then
7260 ac_res="none required"
7263 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
7265 if ac_fn_c_try_link "$LINENO"; then :
7266 ac_cv_search_strerror=$ac_res
7268 rm -f core conftest.err conftest.$ac_objext \
7270 if ${ac_cv_search_strerror+:} false; then :
7274 if ${ac_cv_search_strerror+:} false; then :
7277 ac_cv_search_strerror=no
7280 LIBS=$ac_func_search_save_LIBS
7282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_strerror" >&5
7283 $as_echo "$ac_cv_search_strerror" >&6; }
7284 ac_res=$ac_cv_search_strerror
7285 if test "$ac_res" != no; then :
7286 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
7291 $as_echo_n "checking for inline... " >&6; }
7292 if ${ac_cv_c_inline+:} false; then :
7293 $as_echo_n "(cached) " >&6
7296 for ac_kw in inline __inline__ __inline; do
7297 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7298 /* end confdefs.h. */
7301 static $ac_kw foo_t static_foo () {return 0; }
7302 $ac_kw foo_t foo () {return 0; }
7306 if ac_fn_c_try_compile "$LINENO"; then :
7307 ac_cv_c_inline=$ac_kw
7309 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7310 test "$ac_cv_c_inline" != no && break
7314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
7315 $as_echo "$ac_cv_c_inline" >&6; }
7317 case $ac_cv_c_inline in
7320 case $ac_cv_c_inline in
7322 *) ac_val=$ac_cv_c_inline;;
7324 cat >>confdefs.h <<_ACEOF
7326 #define inline $ac_val
7336 for ac_header in $ac_header_list
7338 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7339 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
7341 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
7342 cat >>confdefs.h <<_ACEOF
7343 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7386 for ac_header in sys/buf.h
7388 ac_fn_c_check_header_compile "$LINENO" "sys/buf.h" "ac_cv_header_sys_buf_h" "#if HAVE_SYS_PARAM_H
7389 #include <sys/param.h>
7392 if test "x$ac_cv_header_sys_buf_h" = xyes; then :
7393 cat >>confdefs.h <<_ACEOF
7394 #define HAVE_SYS_BUF_H 1
7402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
7403 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
7404 if ${ac_cv_header_sys_wait_h+:} false; then :
7405 $as_echo_n "(cached) " >&6
7407 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7408 /* end confdefs.h. */
7409 #include <sys/types.h>
7410 #include <sys/wait.h>
7412 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
7415 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
7423 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
7428 if ac_fn_c_try_compile "$LINENO"; then :
7429 ac_cv_header_sys_wait_h=yes
7431 ac_cv_header_sys_wait_h=no
7433 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
7436 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
7437 if test $ac_cv_header_sys_wait_h = yes; then
7439 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
7445 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
7446 as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
7447 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5
7448 $as_echo_n "checking for $ac_hdr that defines DIR... " >&6; }
7449 if eval \${$as_ac_Header+:} false; then :
7450 $as_echo_n "(cached) " >&6
7452 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7453 /* end confdefs.h. */
7454 #include <sys/types.h>
7466 if ac_fn_c_try_compile "$LINENO"; then :
7467 eval "$as_ac_Header=yes"
7469 eval "$as_ac_Header=no"
7471 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7473 eval ac_res=\$$as_ac_Header
7474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7475 $as_echo "$ac_res" >&6; }
7476 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
7477 cat >>confdefs.h <<_ACEOF
7478 #define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
7481 ac_header_dirent=$ac_hdr; break
7485 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
7486 if test $ac_header_dirent = dirent.h; then
7487 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
7488 $as_echo_n "checking for library containing opendir... " >&6; }
7489 if ${ac_cv_search_opendir+:} false; then :
7490 $as_echo_n "(cached) " >&6
7492 ac_func_search_save_LIBS=$LIBS
7493 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7494 /* end confdefs.h. */
7496 /* Override any GCC internal prototype to avoid an error.
7497 Use char because int might match the return type of a GCC
7498 builtin and then its argument prototype would still apply. */
7511 for ac_lib in '' dir; do
7512 if test -z "$ac_lib"; then
7513 ac_res="none required"
7516 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
7518 if ac_fn_c_try_link "$LINENO"; then :
7519 ac_cv_search_opendir=$ac_res
7521 rm -f core conftest.err conftest.$ac_objext \
7523 if ${ac_cv_search_opendir+:} false; then :
7527 if ${ac_cv_search_opendir+:} false; then :
7530 ac_cv_search_opendir=no
7533 LIBS=$ac_func_search_save_LIBS
7535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
7536 $as_echo "$ac_cv_search_opendir" >&6; }
7537 ac_res=$ac_cv_search_opendir
7538 if test "$ac_res" != no; then :
7539 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
7545 $as_echo_n "checking for library containing opendir... " >&6; }
7546 if ${ac_cv_search_opendir+:} false; then :
7547 $as_echo_n "(cached) " >&6
7549 ac_func_search_save_LIBS=$LIBS
7550 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7551 /* end confdefs.h. */
7553 /* Override any GCC internal prototype to avoid an error.
7554 Use char because int might match the return type of a GCC
7555 builtin and then its argument prototype would still apply. */
7568 for ac_lib in '' x; do
7569 if test -z "$ac_lib"; then
7570 ac_res="none required"
7573 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
7575 if ac_fn_c_try_link "$LINENO"; then :
7576 ac_cv_search_opendir=$ac_res
7578 rm -f core conftest.err conftest.$ac_objext \
7580 if ${ac_cv_search_opendir+:} false; then :
7584 if ${ac_cv_search_opendir+:} false; then :
7587 ac_cv_search_opendir=no
7590 LIBS=$ac_func_search_save_LIBS
7592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
7593 $as_echo "$ac_cv_search_opendir" >&6; }
7594 ac_res=$ac_cv_search_opendir
7595 if test "$ac_res" != no; then :
7596 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/types.h defines makedev" >&5
7603 $as_echo_n "checking whether sys/types.h defines makedev... " >&6; }
7604 if ${ac_cv_header_sys_types_h_makedev+:} false; then :
7605 $as_echo_n "(cached) " >&6
7607 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7608 /* end confdefs.h. */
7609 #include <sys/types.h>
7613 return makedev(0, 0);
7618 if ac_fn_c_try_link "$LINENO"; then :
7619 ac_cv_header_sys_types_h_makedev=yes
7621 ac_cv_header_sys_types_h_makedev=no
7623 rm -f core conftest.err conftest.$ac_objext \
7624 conftest$ac_exeext conftest.$ac_ext
7627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_types_h_makedev" >&5
7628 $as_echo "$ac_cv_header_sys_types_h_makedev" >&6; }
7630 if test $ac_cv_header_sys_types_h_makedev = no; then
7631 ac_fn_c_check_header_mongrel "$LINENO" "sys/mkdev.h" "ac_cv_header_sys_mkdev_h" "$ac_includes_default"
7632 if test "x$ac_cv_header_sys_mkdev_h" = xyes; then :
7634 $as_echo "#define MAJOR_IN_MKDEV 1" >>confdefs.h
7640 if test $ac_cv_header_sys_mkdev_h = no; then
7641 ac_fn_c_check_header_mongrel "$LINENO" "sys/sysmacros.h" "ac_cv_header_sys_sysmacros_h" "$ac_includes_default"
7642 if test "x$ac_cv_header_sys_sysmacros_h" = xyes; then :
7644 $as_echo "#define MAJOR_IN_SYSMACROS 1" >>confdefs.h
7652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
7653 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
7654 if ${ac_cv_header_stat_broken+:} false; then :
7655 $as_echo_n "(cached) " >&6
7657 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7658 /* end confdefs.h. */
7659 #include <sys/types.h>
7660 #include <sys/stat.h>
7662 #if defined S_ISBLK && defined S_IFDIR
7663 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
7666 #if defined S_ISBLK && defined S_IFCHR
7667 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
7670 #if defined S_ISLNK && defined S_IFREG
7671 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
7674 #if defined S_ISSOCK && defined S_IFREG
7675 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
7679 if ac_fn_c_try_compile "$LINENO"; then :
7680 ac_cv_header_stat_broken=no
7682 ac_cv_header_stat_broken=yes
7684 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
7687 $as_echo "$ac_cv_header_stat_broken" >&6; }
7688 if test $ac_cv_header_stat_broken = yes; then
7690 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
7694 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
7695 $as_echo_n "checking for ANSI C header files... " >&6; }
7696 if ${ac_cv_header_stdc+:} false; then :
7697 $as_echo_n "(cached) " >&6
7699 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7700 /* end confdefs.h. */
7714 if ac_fn_c_try_compile "$LINENO"; then :
7715 ac_cv_header_stdc=yes
7717 ac_cv_header_stdc=no
7719 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7721 if test $ac_cv_header_stdc = yes; then
7722 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
7723 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7724 /* end confdefs.h. */
7728 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7729 $EGREP "memchr" >/dev/null 2>&1; then :
7732 ac_cv_header_stdc=no
7738 if test $ac_cv_header_stdc = yes; then
7739 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
7740 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7741 /* end confdefs.h. */
7745 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7746 $EGREP "free" >/dev/null 2>&1; then :
7749 ac_cv_header_stdc=no
7755 if test $ac_cv_header_stdc = yes; then
7756 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
7757 if test "$cross_compiling" = yes; then :
7760 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7761 /* end confdefs.h. */
7764 #if ((' ' & 0x0FF) == 0x020)
7765 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
7766 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
7768 # define ISLOWER(c) \
7769 (('a' <= (c) && (c) <= 'i') \
7770 || ('j' <= (c) && (c) <= 'r') \
7771 || ('s' <= (c) && (c) <= 'z'))
7772 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
7775 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
7780 for (i = 0; i < 256; i++)
7781 if (XOR (islower (i), ISLOWER (i))
7782 || toupper (i) != TOUPPER (i))
7787 if ac_fn_c_try_run "$LINENO"; then :
7790 ac_cv_header_stdc=no
7792 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7793 conftest.$ac_objext conftest.beam conftest.$ac_ext
7798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
7799 $as_echo "$ac_cv_header_stdc" >&6; }
7800 if test $ac_cv_header_stdc = yes; then
7802 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
7807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_fstype string in struct stat" >&5
7808 $as_echo_n "checking for st_fstype string in struct stat... " >&6; }
7809 if ${diff_cv_st_fstype_string+:} false; then :
7810 $as_echo_n "(cached) " >&6
7812 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7813 /* end confdefs.h. */
7814 #include <sys/types.h>
7815 #include <sys/stat.h>
7819 struct stat s; s.st_fstype[0] = 'x';
7824 if ac_fn_c_try_compile "$LINENO"; then :
7825 diff_cv_st_fstype_string=yes
7827 diff_cv_st_fstype_string=no
7829 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $diff_cv_st_fstype_string" >&5
7833 $as_echo "$diff_cv_st_fstype_string" >&6; }
7834 if test $diff_cv_st_fstype_string = yes; then
7836 $as_echo "#define HAVE_ST_FSTYPE_STRING 1" >>confdefs.h
7840 # even if we use gnulib's acl.h with integrated m4 file later on (used because
7841 # of very useful file_has_acl() function) we need following checks that restrict
7842 # tar to use POSIX.1e ACLs only.
7844 # Check whether --with-posix-acls was given.
7845 if test "${with_posix_acls+set}" = set; then :
7846 withval=$with_posix_acls;
7851 if test "x$with_posix_acls" != "xno"; then
7852 for ac_header in sys/acl.h
7854 ac_fn_c_check_header_mongrel "$LINENO" "sys/acl.h" "ac_cv_header_sys_acl_h" "$ac_includes_default"
7855 if test "x$ac_cv_header_sys_acl_h" = xyes; then :
7856 cat >>confdefs.h <<_ACEOF
7857 #define HAVE_SYS_ACL_H 1
7866 for tar_acl_func in acl_get_file acl_get_fd acl_set_file acl_set_fd \
7867 acl_to_text acl_from_text; do \
7868 test "x$with_posix_acls" = xno && break
7869 as_ac_Search=`$as_echo "ac_cv_search_$tar_acl_func" | $as_tr_sh`
7870 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing $tar_acl_func" >&5
7871 $as_echo_n "checking for library containing $tar_acl_func... " >&6; }
7872 if eval \${$as_ac_Search+:} false; then :
7873 $as_echo_n "(cached) " >&6
7875 ac_func_search_save_LIBS=$LIBS
7876 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7877 /* end confdefs.h. */
7879 /* Override any GCC internal prototype to avoid an error.
7880 Use char because int might match the return type of a GCC
7881 builtin and then its argument prototype would still apply. */
7885 char $tar_acl_func ();
7889 return $tar_acl_func ();
7894 for ac_lib in '' acl pacl; do
7895 if test -z "$ac_lib"; then
7896 ac_res="none required"
7899 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
7901 if ac_fn_c_try_link "$LINENO"; then :
7902 eval "$as_ac_Search=\$ac_res"
7904 rm -f core conftest.err conftest.$ac_objext \
7906 if eval \${$as_ac_Search+:} false; then :
7910 if eval \${$as_ac_Search+:} false; then :
7913 eval "$as_ac_Search=no"
7916 LIBS=$ac_func_search_save_LIBS
7918 eval ac_res=\$$as_ac_Search
7919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7920 $as_echo "$ac_res" >&6; }
7921 eval ac_res=\$$as_ac_Search
7922 if test "$ac_res" != no; then :
7923 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7930 if test "x$with_posix_acls" != xno; then
7932 $as_echo "#define HAVE_POSIX_ACLS /**/" >>confdefs.h
7936 # disable acls in gnulib's checks
7937 export enable_acl=no
7940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5
7941 $as_echo_n "checking return type of signal handlers... " >&6; }
7942 if ${ac_cv_type_signal+:} false; then :
7943 $as_echo_n "(cached) " >&6
7945 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7946 /* end confdefs.h. */
7947 #include <sys/types.h>
7953 return *(signal (0, 0)) (0) == 1;
7958 if ac_fn_c_try_compile "$LINENO"; then :
7959 ac_cv_type_signal=int
7961 ac_cv_type_signal=void
7963 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5
7966 $as_echo "$ac_cv_type_signal" >&6; }
7968 cat >>confdefs.h <<_ACEOF
7969 #define RETSIGTYPE $ac_cv_type_signal
7973 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
7974 if test "x$ac_cv_type_mode_t" = xyes; then :
7978 cat >>confdefs.h <<_ACEOF
7984 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
7985 if test "x$ac_cv_type_pid_t" = xyes; then :
7989 cat >>confdefs.h <<_ACEOF
7995 ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default"
7996 if test "x$ac_cv_type_off_t" = xyes; then :
8000 cat >>confdefs.h <<_ACEOF
8001 #define off_t long int
8006 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
8007 if test "x$ac_cv_type_size_t" = xyes; then :
8011 cat >>confdefs.h <<_ACEOF
8012 #define size_t unsigned int
8017 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
8018 $as_echo_n "checking for uid_t in sys/types.h... " >&6; }
8019 if ${ac_cv_type_uid_t+:} false; then :
8020 $as_echo_n "(cached) " >&6
8022 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8023 /* end confdefs.h. */
8024 #include <sys/types.h>
8027 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8028 $EGREP "uid_t" >/dev/null 2>&1; then :
8029 ac_cv_type_uid_t=yes
8036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
8037 $as_echo "$ac_cv_type_uid_t" >&6; }
8038 if test $ac_cv_type_uid_t = no; then
8040 $as_echo "#define uid_t int" >>confdefs.h
8043 $as_echo "#define gid_t int" >>confdefs.h
8047 ac_fn_c_check_type "$LINENO" "major_t" "ac_cv_type_major_t" "$ac_includes_default"
8048 if test "x$ac_cv_type_major_t" = xyes; then :
8052 $as_echo "#define major_t int" >>confdefs.h
8056 ac_fn_c_check_type "$LINENO" "minor_t" "ac_cv_type_minor_t" "$ac_includes_default"
8057 if test "x$ac_cv_type_minor_t" = xyes; then :
8061 $as_echo "#define minor_t int" >>confdefs.h
8065 ac_fn_c_check_type "$LINENO" "dev_t" "ac_cv_type_dev_t" "$ac_includes_default"
8066 if test "x$ac_cv_type_dev_t" = xyes; then :
8070 cat >>confdefs.h <<_ACEOF
8071 #define dev_t unsigned
8076 ac_fn_c_check_type "$LINENO" "ino_t" "ac_cv_type_ino_t" "$ac_includes_default"
8077 if test "x$ac_cv_type_ino_t" = xyes; then :
8081 cat >>confdefs.h <<_ACEOF
8082 #define ino_t unsigned
8089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
8090 $as_echo_n "checking for ssize_t... " >&6; }
8091 if ${gt_cv_ssize_t+:} false; then :
8092 $as_echo_n "(cached) " >&6
8094 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8095 /* end confdefs.h. */
8096 #include <sys/types.h>
8100 int x = sizeof (ssize_t *) + sizeof (ssize_t);
8106 if ac_fn_c_try_compile "$LINENO"; then :
8111 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
8114 $as_echo "$gt_cv_ssize_t" >&6; }
8115 if test $gt_cv_ssize_t = no; then
8117 $as_echo "#define ssize_t int" >>confdefs.h
8128 LIBC_FATAL_STDERR_=1
8129 export LIBC_FATAL_STDERR_
8131 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
8132 # for constant arguments. Useless!
8133 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
8134 $as_echo_n "checking for working alloca.h... " >&6; }
8135 if ${ac_cv_working_alloca_h+:} false; then :
8136 $as_echo_n "(cached) " >&6
8138 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8139 /* end confdefs.h. */
8144 char *p = (char *) alloca (2 * sizeof (int));
8150 if ac_fn_c_try_link "$LINENO"; then :
8151 ac_cv_working_alloca_h=yes
8153 ac_cv_working_alloca_h=no
8155 rm -f core conftest.err conftest.$ac_objext \
8156 conftest$ac_exeext conftest.$ac_ext
8158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
8159 $as_echo "$ac_cv_working_alloca_h" >&6; }
8160 if test $ac_cv_working_alloca_h = yes; then
8162 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
8166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
8167 $as_echo_n "checking for alloca... " >&6; }
8168 if ${ac_cv_func_alloca_works+:} false; then :
8169 $as_echo_n "(cached) " >&6
8171 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8172 /* end confdefs.h. */
8174 # define alloca __builtin_alloca
8177 # include <malloc.h>
8178 # define alloca _alloca
8180 # ifdef HAVE_ALLOCA_H
8181 # include <alloca.h>
8186 # ifndef alloca /* predefined by HP cc +Olibcalls */
8187 void *alloca (size_t);
8197 char *p = (char *) alloca (1);
8203 if ac_fn_c_try_link "$LINENO"; then :
8204 ac_cv_func_alloca_works=yes
8206 ac_cv_func_alloca_works=no
8208 rm -f core conftest.err conftest.$ac_objext \
8209 conftest$ac_exeext conftest.$ac_ext
8211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
8212 $as_echo "$ac_cv_func_alloca_works" >&6; }
8214 if test $ac_cv_func_alloca_works = yes; then
8216 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
8219 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
8220 # that cause trouble. Some versions do not even contain alloca or
8221 # contain a buggy version. If you still want to use their alloca,
8222 # use ar to extract alloca.o from them instead of compiling alloca.c.
8228 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
8230 $as_echo "#define C_ALLOCA 1" >>confdefs.h
8233 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
8234 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
8235 if ${ac_cv_os_cray+:} false; then :
8236 $as_echo_n "(cached) " >&6
8238 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8239 /* end confdefs.h. */
8240 #if defined CRAY && ! defined CRAY2
8247 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8248 $EGREP "webecray" >/dev/null 2>&1; then :
8256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
8257 $as_echo "$ac_cv_os_cray" >&6; }
8258 if test $ac_cv_os_cray = yes; then
8259 for ac_func in _getb67 GETB67 getb67; do
8260 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8261 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8262 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
8264 cat >>confdefs.h <<_ACEOF
8265 #define CRAY_STACKSEG_END $ac_func
8274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
8275 $as_echo_n "checking stack direction for C alloca... " >&6; }
8276 if ${ac_cv_c_stack_direction+:} false; then :
8277 $as_echo_n "(cached) " >&6
8279 if test "$cross_compiling" = yes; then :
8280 ac_cv_c_stack_direction=0
8282 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8283 /* end confdefs.h. */
8284 $ac_includes_default
8286 find_stack_direction (int *addr, int depth)
8291 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
8292 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
8297 main (int argc, char **argv)
8299 return find_stack_direction (0, argc + !argv + 20) < 0;
8302 if ac_fn_c_try_run "$LINENO"; then :
8303 ac_cv_c_stack_direction=1
8305 ac_cv_c_stack_direction=-1
8307 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8308 conftest.$ac_objext conftest.beam conftest.$ac_ext
8312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
8313 $as_echo "$ac_cv_c_stack_direction" >&6; }
8314 cat >>confdefs.h <<_ACEOF
8315 #define STACK_DIRECTION $ac_cv_c_stack_direction
8321 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
8322 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
8323 if ${ac_cv_c_restrict+:} false; then :
8324 $as_echo_n "(cached) " >&6
8327 # The order here caters to the fact that C++ does not require restrict.
8328 for ac_kw in __restrict __restrict__ _Restrict restrict; do
8329 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8330 /* end confdefs.h. */
8331 typedef int * int_ptr;
8332 int foo (int_ptr $ac_kw ip) {
8346 if ac_fn_c_try_compile "$LINENO"; then :
8347 ac_cv_c_restrict=$ac_kw
8349 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8350 test "$ac_cv_c_restrict" != no && break
8354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
8355 $as_echo "$ac_cv_c_restrict" >&6; }
8357 case $ac_cv_c_restrict in
8359 no) $as_echo "#define restrict /**/" >>confdefs.h
8361 *) cat >>confdefs.h <<_ACEOF
8362 #define restrict $ac_cv_c_restrict
8367 ac_fn_c_check_decl "$LINENO" "clearerr_unlocked" "ac_cv_have_decl_clearerr_unlocked" "$ac_includes_default"
8368 if test "x$ac_cv_have_decl_clearerr_unlocked" = xyes; then :
8374 cat >>confdefs.h <<_ACEOF
8375 #define HAVE_DECL_CLEARERR_UNLOCKED $ac_have_decl
8378 ac_fn_c_check_decl "$LINENO" "feof_unlocked" "ac_cv_have_decl_feof_unlocked" "$ac_includes_default"
8379 if test "x$ac_cv_have_decl_feof_unlocked" = xyes; then :
8385 cat >>confdefs.h <<_ACEOF
8386 #define HAVE_DECL_FEOF_UNLOCKED $ac_have_decl
8389 ac_fn_c_check_decl "$LINENO" "ferror_unlocked" "ac_cv_have_decl_ferror_unlocked" "$ac_includes_default"
8390 if test "x$ac_cv_have_decl_ferror_unlocked" = xyes; then :
8396 cat >>confdefs.h <<_ACEOF
8397 #define HAVE_DECL_FERROR_UNLOCKED $ac_have_decl
8400 ac_fn_c_check_decl "$LINENO" "fflush_unlocked" "ac_cv_have_decl_fflush_unlocked" "$ac_includes_default"
8401 if test "x$ac_cv_have_decl_fflush_unlocked" = xyes; then :
8407 cat >>confdefs.h <<_ACEOF
8408 #define HAVE_DECL_FFLUSH_UNLOCKED $ac_have_decl
8411 ac_fn_c_check_decl "$LINENO" "fgets_unlocked" "ac_cv_have_decl_fgets_unlocked" "$ac_includes_default"
8412 if test "x$ac_cv_have_decl_fgets_unlocked" = xyes; then :
8418 cat >>confdefs.h <<_ACEOF
8419 #define HAVE_DECL_FGETS_UNLOCKED $ac_have_decl
8422 ac_fn_c_check_decl "$LINENO" "fputc_unlocked" "ac_cv_have_decl_fputc_unlocked" "$ac_includes_default"
8423 if test "x$ac_cv_have_decl_fputc_unlocked" = xyes; then :
8429 cat >>confdefs.h <<_ACEOF
8430 #define HAVE_DECL_FPUTC_UNLOCKED $ac_have_decl
8433 ac_fn_c_check_decl "$LINENO" "fputs_unlocked" "ac_cv_have_decl_fputs_unlocked" "$ac_includes_default"
8434 if test "x$ac_cv_have_decl_fputs_unlocked" = xyes; then :
8440 cat >>confdefs.h <<_ACEOF
8441 #define HAVE_DECL_FPUTS_UNLOCKED $ac_have_decl
8444 ac_fn_c_check_decl "$LINENO" "fread_unlocked" "ac_cv_have_decl_fread_unlocked" "$ac_includes_default"
8445 if test "x$ac_cv_have_decl_fread_unlocked" = xyes; then :
8451 cat >>confdefs.h <<_ACEOF
8452 #define HAVE_DECL_FREAD_UNLOCKED $ac_have_decl
8455 ac_fn_c_check_decl "$LINENO" "fwrite_unlocked" "ac_cv_have_decl_fwrite_unlocked" "$ac_includes_default"
8456 if test "x$ac_cv_have_decl_fwrite_unlocked" = xyes; then :
8462 cat >>confdefs.h <<_ACEOF
8463 #define HAVE_DECL_FWRITE_UNLOCKED $ac_have_decl
8466 ac_fn_c_check_decl "$LINENO" "getc_unlocked" "ac_cv_have_decl_getc_unlocked" "$ac_includes_default"
8467 if test "x$ac_cv_have_decl_getc_unlocked" = xyes; then :
8473 cat >>confdefs.h <<_ACEOF
8474 #define HAVE_DECL_GETC_UNLOCKED $ac_have_decl
8477 ac_fn_c_check_decl "$LINENO" "getchar_unlocked" "ac_cv_have_decl_getchar_unlocked" "$ac_includes_default"
8478 if test "x$ac_cv_have_decl_getchar_unlocked" = xyes; then :
8484 cat >>confdefs.h <<_ACEOF
8485 #define HAVE_DECL_GETCHAR_UNLOCKED $ac_have_decl
8488 ac_fn_c_check_decl "$LINENO" "putc_unlocked" "ac_cv_have_decl_putc_unlocked" "$ac_includes_default"
8489 if test "x$ac_cv_have_decl_putc_unlocked" = xyes; then :
8495 cat >>confdefs.h <<_ACEOF
8496 #define HAVE_DECL_PUTC_UNLOCKED $ac_have_decl
8499 ac_fn_c_check_decl "$LINENO" "putchar_unlocked" "ac_cv_have_decl_putchar_unlocked" "$ac_includes_default"
8500 if test "x$ac_cv_have_decl_putchar_unlocked" = xyes; then :
8506 cat >>confdefs.h <<_ACEOF
8507 #define HAVE_DECL_PUTCHAR_UNLOCKED $ac_have_decl
8513 for ac_func in $ac_func_list
8515 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8516 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8517 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
8518 cat >>confdefs.h <<_ACEOF
8519 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
8534 XGETTEXT_EXTRA_OPTIONS=
8536 # Make sure we can run config.sub.
8537 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
8538 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
8540 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
8541 $as_echo_n "checking build system type... " >&6; }
8542 if ${ac_cv_build+:} false; then :
8543 $as_echo_n "(cached) " >&6
8545 ac_build_alias=$build_alias
8546 test "x$ac_build_alias" = x &&
8547 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
8548 test "x$ac_build_alias" = x &&
8549 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
8550 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
8551 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
8554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
8555 $as_echo "$ac_cv_build" >&6; }
8556 case $ac_cv_build in
8558 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
8561 ac_save_IFS=$IFS; IFS='-'
8567 # Remember, the first character of IFS is used to create $*,
8568 # except with old shells:
8571 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
8574 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
8575 $as_echo_n "checking host system type... " >&6; }
8576 if ${ac_cv_host+:} false; then :
8577 $as_echo_n "(cached) " >&6
8579 if test "x$host_alias" = x; then
8580 ac_cv_host=$ac_cv_build
8582 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
8583 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
8587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
8588 $as_echo "$ac_cv_host" >&6; }
8591 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
8594 ac_save_IFS=$IFS; IFS='-'
8600 # Remember, the first character of IFS is used to create $*,
8601 # except with old shells:
8604 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
8607 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for d_ino member in directory struct" >&5
8608 $as_echo_n "checking for d_ino member in directory struct... " >&6; }
8609 if ${gl_cv_struct_dirent_d_ino+:} false; then :
8610 $as_echo_n "(cached) " >&6
8612 if test "$cross_compiling" = yes; then :
8614 # Guess yes on glibc systems with Linux kernel.
8615 linux*-gnu*) gl_cv_struct_dirent_d_ino="guessing yes" ;;
8616 # If we don't know, assume the worst.
8617 *) gl_cv_struct_dirent_d_ino="guessing no" ;;
8621 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8622 /* end confdefs.h. */
8623 #include <sys/types.h>
8624 #include <sys/stat.h>
8630 DIR *dp = opendir (".");
8638 if (stat (e->d_name, &st) != 0)
8640 if (e->d_ino != st.st_ino)
8648 if ac_fn_c_try_run "$LINENO"; then :
8649 gl_cv_struct_dirent_d_ino=yes
8651 gl_cv_struct_dirent_d_ino=no
8653 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8654 conftest.$ac_objext conftest.beam conftest.$ac_ext
8658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_struct_dirent_d_ino" >&5
8659 $as_echo "$gl_cv_struct_dirent_d_ino" >&6; }
8660 case "$gl_cv_struct_dirent_d_ino" in
8663 $as_echo "#define D_INO_IN_DIRENT 1" >>confdefs.h
8669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
8670 $as_echo_n "checking for long file names... " >&6; }
8671 if ${ac_cv_sys_long_file_names+:} false; then :
8672 $as_echo_n "(cached) " >&6
8674 ac_cv_sys_long_file_names=yes
8675 # Test for long file names in all the places we know might matter:
8676 # . the current directory, where building will happen
8677 # $prefix/lib where we will be installing things
8678 # $exec_prefix/lib likewise
8679 # $TMPDIR if set, where it might want to write temporary files
8680 # /tmp where it might want to write temporary files
8683 for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
8684 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
8685 # in the usual case where exec_prefix is '${prefix}'.
8687 . | /* | ?:[\\/]*) ;; #(
8690 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
8691 ac_xdir=$ac_dir/cf$$
8692 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
8693 ac_tf1=$ac_xdir/conftest9012345
8694 ac_tf2=$ac_xdir/conftest9012346
8695 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
8696 ac_cv_sys_long_file_names=no
8697 rm -f -r "$ac_xdir" 2>/dev/null
8698 test $ac_cv_sys_long_file_names = no && break
8701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
8702 $as_echo "$ac_cv_sys_long_file_names" >&6; }
8703 if test $ac_cv_sys_long_file_names = yes; then
8705 $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
8718 GNULIB_MBSNRTOWCS=0;
8721 GNULIB_WCSNRTOMBS=0;
8738 GNULIB_WCSCASECMP=0;
8739 GNULIB_WCSNCASECMP=0;
8789 HAVE_DECL_WCWIDTH=1;
8790 REPLACE_MBSTATE_T=0;
8796 REPLACE_MBSRTOWCS=0;
8797 REPLACE_MBSNRTOWCS=0;
8799 REPLACE_WCSRTOMBS=0;
8800 REPLACE_WCSNRTOMBS=0;
8805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <wchar.h> uses 'inline' correctly" >&5
8806 $as_echo_n "checking whether <wchar.h> uses 'inline' correctly... " >&6; }
8807 if ${gl_cv_header_wchar_h_correct_inline+:} false; then :
8808 $as_echo_n "(cached) " >&6
8810 gl_cv_header_wchar_h_correct_inline=yes
8811 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8812 /* end confdefs.h. */
8814 #define wcstod renamed_wcstod
8815 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
8817 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
8818 included before <wchar.h>. */
8823 extern int zero (void);
8824 int main () { return zero(); }
8827 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
8828 (eval $ac_compile) 2>&5
8830 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8831 test $ac_status = 0; }; then
8832 mv conftest.$ac_objext conftest1.$ac_objext
8833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8834 /* end confdefs.h. */
8836 #define wcstod renamed_wcstod
8837 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
8839 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
8840 included before <wchar.h>. */
8845 int zero (void) { return 0; }
8848 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
8849 (eval $ac_compile) 2>&5
8851 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8852 test $ac_status = 0; }; then
8853 mv conftest.$ac_objext conftest2.$ac_objext
8854 if $CC -o conftest$ac_exeext $CFLAGS $LDFLAGS conftest1.$ac_objext conftest2.$ac_objext $LIBS >&5 2>&1; then
8857 gl_cv_header_wchar_h_correct_inline=no
8861 rm -f conftest1.$ac_objext conftest2.$ac_objext conftest$ac_exeext
8864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_wchar_h_correct_inline" >&5
8865 $as_echo "$gl_cv_header_wchar_h_correct_inline" >&6; }
8866 if test $gl_cv_header_wchar_h_correct_inline = no; then
8867 as_fn_error $? "<wchar.h> cannot be used with this compiler ($CC $CFLAGS $CPPFLAGS).
8868 This is a known interoperability problem of glibc <= 2.5 with gcc >= 4.3 in
8869 C99 mode. You have four options:
8870 - Add the flag -fgnu89-inline to CC and reconfigure, or
8871 - Fix your include files, using parts of
8872 <http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=b037a293a48718af30d706c2e18c929d0e69a621>, or
8873 - Use a gcc version older than 4.3, or
8874 - Don't use the flags -std=c99 or -std=gnu99.
8875 Configuration aborted." "$LINENO" 5
8881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
8882 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
8883 if ${am_cv_langinfo_codeset+:} false; then :
8884 $as_echo_n "(cached) " >&6
8886 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8887 /* end confdefs.h. */
8888 #include <langinfo.h>
8892 char* cs = nl_langinfo(CODESET); return !cs;
8897 if ac_fn_c_try_link "$LINENO"; then :
8898 am_cv_langinfo_codeset=yes
8900 am_cv_langinfo_codeset=no
8902 rm -f core conftest.err conftest.$ac_objext \
8903 conftest$ac_exeext conftest.$ac_ext
8906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
8907 $as_echo "$am_cv_langinfo_codeset" >&6; }
8908 if test $am_cv_langinfo_codeset = yes; then
8910 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
8917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
8918 $as_echo_n "checking for a traditional french locale... " >&6; }
8919 if ${gt_cv_locale_fr+:} false; then :
8920 $as_echo_n "(cached) " >&6
8923 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8924 /* end confdefs.h. */
8928 #if HAVE_LANGINFO_CODESET
8929 # include <langinfo.h>
8936 /* Check whether the given locale name is recognized by the system. */
8937 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
8938 /* On native Windows, setlocale(category, "") looks at the system settings,
8939 not at the environment variables. Also, when an encoding suffix such
8940 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
8941 category of the locale to "C". */
8942 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
8943 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
8946 if (setlocale (LC_ALL, "") == NULL) return 1;
8948 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
8949 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
8950 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
8951 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
8952 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
8953 some unit tests fail.
8954 On MirBSD 10, when an unsupported locale is specified, setlocale()
8955 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
8956 #if HAVE_LANGINFO_CODESET
8958 const char *cs = nl_langinfo (CODESET);
8959 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
8960 || strcmp (cs, "UTF-8") == 0)
8965 /* On Cygwin, avoid locale names without encoding suffix, because the
8966 locale_charset() function relies on the encoding suffix. Note that
8967 LC_ALL is set on the command line. */
8968 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
8970 /* Check whether in the abbreviation of the second month, the second
8971 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
8972 one byte long. This excludes the UTF-8 encoding. */
8973 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
8974 if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
8975 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
8976 /* Check whether the decimal separator is a comma.
8977 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
8978 are nl_langinfo(RADIXCHAR) are both ".". */
8979 if (localeconv () ->decimal_point[0] != ',') return 1;
8985 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
8986 (eval $ac_link) 2>&5
8988 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8989 test $ac_status = 0; } && test -s conftest$ac_exeext; then
8991 # Handle native Windows specially, because there setlocale() interprets
8992 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
8993 # "fr" or "fra" as "French" or "French_France.1252",
8994 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
8995 # "ja" as "Japanese" or "Japanese_Japan.932",
8998 # Test for the native Windows locale name.
8999 if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
9000 gt_cv_locale_fr=French_France.1252
9003 gt_cv_locale_fr=none
9007 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
9008 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
9009 # configure script would override the LC_ALL setting. Likewise for
9010 # LC_CTYPE, which is also set at the beginning of the configure script.
9011 # Test for the usual locale name.
9012 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
9013 gt_cv_locale_fr=fr_FR
9015 # Test for the locale name with explicit encoding suffix.
9016 if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
9017 gt_cv_locale_fr=fr_FR.ISO-8859-1
9019 # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
9020 if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
9021 gt_cv_locale_fr=fr_FR.ISO8859-1
9023 # Test for the HP-UX locale name.
9024 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
9025 gt_cv_locale_fr=fr_FR.iso88591
9027 # Test for the Solaris 7 locale name.
9028 if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
9032 gt_cv_locale_fr=none
9044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
9045 $as_echo "$gt_cv_locale_fr" >&6; }
9046 LOCALE_FR=$gt_cv_locale_fr
9052 GNULIB_CALLOC_POSIX=0;
9053 GNULIB_CANONICALIZE_FILE_NAME=0;
9054 GNULIB_GETLOADAVG=0;
9057 GNULIB_MALLOC_POSIX=0;
9064 GNULIB_POSIX_OPENPT=0;
9070 GNULIB_REALLOC_POSIX=0;
9073 GNULIB_SECURE_GETENV=0;
9078 GNULIB_SYSTEM_POSIX=0;
9084 HAVE_CANONICALIZE_FILE_NAME=1;
9085 HAVE_DECL_GETLOADAVG=1;
9093 HAVE_POSIX_OPENPT=1;
9101 HAVE_SECURE_GETENV=1;
9107 HAVE_STRUCT_RANDOM_DATA=1;
9108 HAVE_SYS_LOADAVG_H=0;
9110 HAVE_DECL_UNSETENV=1;
9112 REPLACE_CANONICALIZE_FILE_NAME=0;
9117 REPLACE_PTSNAME_R=0;
9135 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether // is distinct from /" >&5
9136 $as_echo_n "checking whether // is distinct from /... " >&6; }
9137 if ${gl_cv_double_slash_root+:} false; then :
9138 $as_echo_n "(cached) " >&6
9140 if test x"$cross_compiling" = xyes ; then
9141 # When cross-compiling, there is no way to tell whether // is special
9142 # short of a list of hosts. However, the only known hosts to date
9143 # that have a distinct // are Apollo DomainOS (too old to port to),
9144 # Cygwin, and z/OS. If anyone knows of another system for which // has
9145 # special semantics and is distinct from /, please report it to
9146 # <bug-gnulib@gnu.org>.
9148 *-cygwin | i370-ibm-openedition)
9149 gl_cv_double_slash_root=yes ;;
9151 # Be optimistic and assume that / and // are the same when we
9153 gl_cv_double_slash_root='unknown, assuming no' ;;
9156 set x `ls -di / // 2>/dev/null`
9157 if test "$2" = "$4" && wc //dev/null >/dev/null 2>&1; then
9158 gl_cv_double_slash_root=no
9160 gl_cv_double_slash_root=yes
9164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_double_slash_root" >&5
9165 $as_echo "$gl_cv_double_slash_root" >&6; }
9166 if test "$gl_cv_double_slash_root" = yes; then
9168 $as_echo "#define DOUBLE_SLASH_IS_DISTINCT_ROOT 1" >>confdefs.h
9176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether realpath works" >&5
9177 $as_echo_n "checking whether realpath works... " >&6; }
9178 if ${gl_cv_func_realpath_works+:} false; then :
9179 $as_echo_n "(cached) " >&6
9184 if test "$cross_compiling" = yes; then :
9186 # Guess yes on glibc systems.
9187 *-gnu* | gnu*) gl_cv_func_realpath_works="guessing yes" ;;
9188 # If we don't know, assume the worst.
9189 *) gl_cv_func_realpath_works="guessing no" ;;
9193 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9194 /* end confdefs.h. */
9199 #if defined __MACH__ && defined __APPLE__
9200 /* Avoid a crash on Mac OS X. */
9201 #include <mach/mach.h>
9202 #include <mach/mach_error.h>
9203 #include <mach/thread_status.h>
9204 #include <mach/exception.h>
9205 #include <mach/task.h>
9206 #include <pthread.h>
9207 /* The exception port on which our thread listens. */
9208 static mach_port_t our_exception_port;
9209 /* The main function of the thread listening for exceptions of type
9212 mach_exception_thread (void *arg)
9214 /* Buffer for a message to be received. */
9216 mach_msg_header_t head;
9217 mach_msg_body_t msgh_body;
9220 mach_msg_return_t retval;
9221 /* Wait for a message on the exception port. */
9222 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
9223 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
9224 if (retval != MACH_MSG_SUCCESS)
9231 mach_port_t self = mach_task_self ();
9232 /* Allocate a port on which the thread shall listen for exceptions. */
9233 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
9235 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
9236 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
9237 MACH_MSG_TYPE_MAKE_SEND)
9239 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
9241 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
9242 /* Create the thread listening on the exception port. */
9243 pthread_attr_t attr;
9245 if (pthread_attr_init (&attr) == 0
9246 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
9247 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
9248 pthread_attr_destroy (&attr);
9249 /* Replace the exception port info for these exceptions with our own.
9250 Note that we replace the exception port for the entire task, not only
9251 for a particular thread. This has the effect that when our exception
9252 port gets the message, the thread specific exception port has already
9253 been asked, and we don't need to bother about it.
9254 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
9255 task_set_exception_ports (self, mask, our_exception_port,
9256 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
9261 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
9262 /* Avoid a crash on native Windows. */
9263 #define WIN32_LEAN_AND_MEAN
9264 #include <windows.h>
9265 #include <winerror.h>
9267 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
9269 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
9271 case EXCEPTION_ACCESS_VIOLATION:
9272 case EXCEPTION_IN_PAGE_ERROR:
9273 case EXCEPTION_STACK_OVERFLOW:
9274 case EXCEPTION_GUARD_PAGE:
9275 case EXCEPTION_PRIV_INSTRUCTION:
9276 case EXCEPTION_ILLEGAL_INSTRUCTION:
9277 case EXCEPTION_DATATYPE_MISALIGNMENT:
9278 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
9279 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
9282 return EXCEPTION_CONTINUE_SEARCH;
9287 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
9290 /* Avoid a crash on POSIX systems. */
9292 /* A POSIX signal handler. */
9294 exception_handler (int sig)
9302 signal (SIGSEGV, exception_handler);
9305 signal (SIGBUS, exception_handler);
9319 char *name = realpath ("conftest.a", NULL);
9320 if (!(name && *name == '/'))
9324 char *name = realpath ("conftest.b/../conftest.a", NULL);
9329 char *name = realpath ("conftest.a/", NULL);
9334 char *name1 = realpath (".", NULL);
9335 char *name2 = realpath ("conftest.d//./..", NULL);
9336 if (strcmp (name1, name2) != 0)
9346 if ac_fn_c_try_run "$LINENO"; then :
9347 gl_cv_func_realpath_works=yes
9349 gl_cv_func_realpath_works=no
9351 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9352 conftest.$ac_objext conftest.beam conftest.$ac_ext
9355 rm -rf conftest.a conftest.d
9358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_realpath_works" >&5
9359 $as_echo "$gl_cv_func_realpath_works" >&6; }
9360 case "$gl_cv_func_realpath_works" in
9363 $as_echo "#define FUNC_REALPATH_WORKS 1" >>confdefs.h
9385 GNULIB_EUIDACCESS=0;
9393 GNULIB_GETDOMAINNAME=0;
9394 GNULIB_GETDTABLESIZE=0;
9396 GNULIB_GETHOSTNAME=0;
9398 GNULIB_GETLOGIN_R=0;
9399 GNULIB_GETPAGESIZE=0;
9400 GNULIB_GETUSERSHELL=0;
9401 GNULIB_GROUP_MEMBER=0;
9413 GNULIB_READLINKAT=0;
9415 GNULIB_SETHOSTNAME=0;
9420 GNULIB_UNISTD_H_NONBLOCKING=0;
9421 GNULIB_UNISTD_H_SIGPIPE=0;
9436 HAVE_GETDTABLESIZE=1;
9441 HAVE_GROUP_MEMBER=1;
9457 HAVE_DECL_ENVIRON=1;
9459 HAVE_DECL_FDATASYNC=1;
9460 HAVE_DECL_GETDOMAINNAME=1;
9461 HAVE_DECL_GETLOGIN_R=1;
9462 HAVE_DECL_GETPAGESIZE=1;
9463 HAVE_DECL_GETUSERSHELL=1;
9464 HAVE_DECL_SETHOSTNAME=1;
9465 HAVE_DECL_TTYNAME_R=1;
9473 REPLACE_FTRUNCATE=0;
9475 REPLACE_GETDOMAINNAME=0;
9476 REPLACE_GETLOGIN_R=0;
9477 REPLACE_GETGROUPS=0;
9478 REPLACE_GETPAGESIZE=0;
9491 REPLACE_TTYNAME_R=0;
9496 UNISTD_H_HAVE_WINSOCK2_H=0;
9497 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
9504 for ac_header in unistd.h
9506 ac_fn_c_check_header_mongrel "$LINENO" "unistd.h" "ac_cv_header_unistd_h" "$ac_includes_default"
9507 if test "x$ac_cv_header_unistd_h" = xyes; then :
9508 cat >>confdefs.h <<_ACEOF
9509 #define HAVE_UNISTD_H 1
9516 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working chown" >&5
9517 $as_echo_n "checking for working chown... " >&6; }
9518 if ${ac_cv_func_chown_works+:} false; then :
9519 $as_echo_n "(cached) " >&6
9521 if test "$cross_compiling" = yes; then :
9522 case "$host_os" in # ((
9523 # Guess yes on glibc systems.
9524 *-gnu*) ac_cv_func_chown_works=yes ;;
9525 # If we don't know, assume the worst.
9526 *) ac_cv_func_chown_works=no ;;
9530 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9531 /* end confdefs.h. */
9532 $ac_includes_default
9539 char *f = "conftest.chown";
9540 struct stat before, after;
9542 if (creat (f, 0600) < 0)
9544 if (stat (f, &before) < 0)
9546 if (chown (f, (uid_t) -1, (gid_t) -1) == -1)
9548 if (stat (f, &after) < 0)
9550 return ! (before.st_uid == after.st_uid && before.st_gid == after.st_gid);
9557 if ac_fn_c_try_run "$LINENO"; then :
9558 ac_cv_func_chown_works=yes
9560 ac_cv_func_chown_works=no
9562 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9563 conftest.$ac_objext conftest.beam conftest.$ac_ext
9566 rm -f conftest.chown
9569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_chown_works" >&5
9570 $as_echo "$ac_cv_func_chown_works" >&6; }
9571 if test $ac_cv_func_chown_works = yes; then
9573 $as_echo "#define HAVE_CHOWN 1" >>confdefs.h
9578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether chown dereferences symlinks" >&5
9579 $as_echo_n "checking whether chown dereferences symlinks... " >&6; }
9580 if ${gl_cv_func_chown_follows_symlink+:} false; then :
9581 $as_echo_n "(cached) " >&6
9584 if test "$cross_compiling" = yes; then :
9585 gl_cv_func_chown_follows_symlink=yes
9588 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9589 /* end confdefs.h. */
9599 char const *dangling_symlink = "conftest.dangle";
9601 unlink (dangling_symlink);
9602 if (symlink ("conftest.no-such", dangling_symlink))
9605 /* Exit successfully on a conforming system,
9606 i.e., where chown must fail with ENOENT. */
9607 if (chown (dangling_symlink, getuid (), getgid ()) == 0)
9609 if (errno != ENOENT)
9615 if ac_fn_c_try_run "$LINENO"; then :
9616 gl_cv_func_chown_follows_symlink=yes
9618 gl_cv_func_chown_follows_symlink=no
9620 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9621 conftest.$ac_objext conftest.beam conftest.$ac_ext
9627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_chown_follows_symlink" >&5
9628 $as_echo "$gl_cv_func_chown_follows_symlink" >&6; }
9630 if test $gl_cv_func_chown_follows_symlink = no; then
9632 $as_echo "#define CHOWN_MODIFIES_SYMLINK 1" >>confdefs.h
9647 if test $ac_cv_func_chown = no; then
9650 if test $gl_cv_func_chown_follows_symlink = no; then
9654 if test $ac_cv_func_chown_works = no; then
9656 $as_echo "#define CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE 1" >>confdefs.h
9661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether chown honors trailing slash" >&5
9662 $as_echo_n "checking whether chown honors trailing slash... " >&6; }
9663 if ${gl_cv_func_chown_slash_works+:} false; then :
9664 $as_echo_n "(cached) " >&6
9666 touch conftest.file && rm -f conftest.link
9667 if test "$cross_compiling" = yes; then :
9669 # Guess yes on glibc systems.
9670 *-gnu*) gl_cv_func_chown_slash_works="guessing yes" ;;
9671 # If we don't know, assume the worst.
9672 *) gl_cv_func_chown_slash_works="guessing no" ;;
9676 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9677 /* end confdefs.h. */
9686 if (symlink ("conftest.file", "conftest.link")) return 1;
9687 if (chown ("conftest.link/", getuid (), getgid ()) == 0) return 2;
9693 if ac_fn_c_try_run "$LINENO"; then :
9694 gl_cv_func_chown_slash_works=yes
9696 gl_cv_func_chown_slash_works=no
9698 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9699 conftest.$ac_objext conftest.beam conftest.$ac_ext
9702 rm -f conftest.link conftest.file
9704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_chown_slash_works" >&5
9705 $as_echo "$gl_cv_func_chown_slash_works" >&6; }
9706 case "$gl_cv_func_chown_slash_works" in
9710 $as_echo "#define CHOWN_TRAILING_SLASH_BUG 1" >>confdefs.h
9716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether chown always updates ctime" >&5
9717 $as_echo_n "checking whether chown always updates ctime... " >&6; }
9718 if ${gl_cv_func_chown_ctime_works+:} false; then :
9719 $as_echo_n "(cached) " >&6
9721 if test "$cross_compiling" = yes; then :
9723 # Guess yes on glibc systems.
9724 *-gnu*) gl_cv_func_chown_ctime_works="guessing yes" ;;
9725 # If we don't know, assume the worst.
9726 *) gl_cv_func_chown_ctime_works="guessing no" ;;
9730 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9731 /* end confdefs.h. */
9737 #include <sys/stat.h>
9742 struct stat st1, st2;
9743 if (close (creat ("conftest.file", 0600))) return 1;
9744 if (stat ("conftest.file", &st1)) return 2;
9746 if (chown ("conftest.file", st1.st_uid, st1.st_gid)) return 3;
9747 if (stat ("conftest.file", &st2)) return 4;
9748 if (st2.st_ctime <= st1.st_ctime) return 5;
9754 if ac_fn_c_try_run "$LINENO"; then :
9755 gl_cv_func_chown_ctime_works=yes
9757 gl_cv_func_chown_ctime_works=no
9759 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9760 conftest.$ac_objext conftest.beam conftest.$ac_ext
9765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_chown_ctime_works" >&5
9766 $as_echo "$gl_cv_func_chown_ctime_works" >&6; }
9767 case "$gl_cv_func_chown_ctime_works" in
9771 $as_echo "#define CHOWN_CHANGE_TIME_BUG 1" >>confdefs.h
9782 if test $ac_cv_func__set_invalid_parameter_handler = yes; then
9783 HAVE_MSVC_INVALID_PARAMETER_HANDLER=1
9785 $as_echo "#define HAVE_MSVC_INVALID_PARAMETER_HANDLER 1" >>confdefs.h
9788 HAVE_MSVC_INVALID_PARAMETER_HANDLER=0
9810 HAVE_DECL_FDOPENDIR=1;
9817 REPLACE_FDOPENDIR=0;
9821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
9822 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
9823 if ${gl_cv_have_include_next+:} false; then :
9824 $as_echo_n "(cached) " >&6
9826 rm -rf conftestd1a conftestd1b conftestd2
9827 mkdir conftestd1a conftestd1b conftestd2
9828 cat <<EOF > conftestd1a/conftest.h
9829 #define DEFINED_IN_CONFTESTD1
9830 #include_next <conftest.h>
9831 #ifdef DEFINED_IN_CONFTESTD2
9834 #error "include_next doesn't work"
9837 cat <<EOF > conftestd1b/conftest.h
9838 #define DEFINED_IN_CONFTESTD1
9840 #include_next <conftest.h>
9841 #ifdef DEFINED_IN_CONFTESTD2
9844 #error "include_next doesn't work"
9847 cat <<EOF > conftestd2/conftest.h
9848 #ifndef DEFINED_IN_CONFTESTD1
9849 #error "include_next test doesn't work"
9851 #define DEFINED_IN_CONFTESTD2
9853 gl_save_CPPFLAGS="$CPPFLAGS"
9854 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
9855 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9856 /* end confdefs.h. */
9857 #include <conftest.h>
9859 if ac_fn_c_try_compile "$LINENO"; then :
9860 gl_cv_have_include_next=yes
9862 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
9863 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9864 /* end confdefs.h. */
9865 #include <conftest.h>
9867 if ac_fn_c_try_compile "$LINENO"; then :
9868 gl_cv_have_include_next=buggy
9870 gl_cv_have_include_next=no
9872 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9875 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9876 CPPFLAGS="$gl_save_CPPFLAGS"
9877 rm -rf conftestd1a conftestd1b conftestd2
9880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
9881 $as_echo "$gl_cv_have_include_next" >&6; }
9882 PRAGMA_SYSTEM_HEADER=
9883 if test $gl_cv_have_include_next = yes; then
9884 INCLUDE_NEXT=include_next
9885 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
9886 if test -n "$GCC"; then
9887 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
9890 if test $gl_cv_have_include_next = buggy; then
9891 INCLUDE_NEXT=include
9892 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
9894 INCLUDE_NEXT=include
9895 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
9901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
9902 $as_echo_n "checking whether system header files limit the line length... " >&6; }
9903 if ${gl_cv_pragma_columns+:} false; then :
9904 $as_echo_n "(cached) " >&6
9906 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9907 /* end confdefs.h. */
9914 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9915 $EGREP "choke me" >/dev/null 2>&1; then :
9916 gl_cv_pragma_columns=yes
9918 gl_cv_pragma_columns=no
9924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
9925 $as_echo "$gl_cv_pragma_columns" >&6; }
9926 if test $gl_cv_pragma_columns = yes; then
9927 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
9948 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
9949 $as_echo_n "checking if environ is properly declared... " >&6; }
9950 if ${gt_cv_var_environ_declaration+:} false; then :
9951 $as_echo_n "(cached) " >&6
9954 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9955 /* end confdefs.h. */
9959 /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
9962 extern struct { int foo; } environ;
9971 if ac_fn_c_try_compile "$LINENO"; then :
9972 gt_cv_var_environ_declaration=no
9974 gt_cv_var_environ_declaration=yes
9976 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
9980 $as_echo "$gt_cv_var_environ_declaration" >&6; }
9981 if test $gt_cv_var_environ_declaration = yes; then
9983 $as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
9988 if test $gt_cv_var_environ_declaration != yes; then
9994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for complete errno.h" >&5
9995 $as_echo_n "checking for complete errno.h... " >&6; }
9996 if ${gl_cv_header_errno_h_complete+:} false; then :
9997 $as_echo_n "(cached) " >&6
10000 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10001 /* end confdefs.h. */
10004 #if !defined ETXTBSY
10007 #if !defined ENOMSG
10013 #if !defined ENOLINK
10016 #if !defined EPROTO
10019 #if !defined EMULTIHOP
10022 #if !defined EBADMSG
10025 #if !defined EOVERFLOW
10028 #if !defined ENOTSUP
10031 #if !defined ENETRESET
10034 #if !defined ECONNABORTED
10037 #if !defined ESTALE
10040 #if !defined EDQUOT
10043 #if !defined ECANCELED
10046 #if !defined EOWNERDEAD
10049 #if !defined ENOTRECOVERABLE
10052 #if !defined EILSEQ
10057 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10058 $EGREP "booboo" >/dev/null 2>&1; then :
10059 gl_cv_header_errno_h_complete=no
10061 gl_cv_header_errno_h_complete=yes
10067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_complete" >&5
10068 $as_echo "$gl_cv_header_errno_h_complete" >&6; }
10069 if test $gl_cv_header_errno_h_complete = yes; then
10080 if test $gl_cv_have_include_next = yes; then
10081 gl_cv_next_errno_h='<'errno.h'>'
10083 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <errno.h>" >&5
10084 $as_echo_n "checking absolute name of <errno.h>... " >&6; }
10085 if ${gl_cv_next_errno_h+:} false; then :
10086 $as_echo_n "(cached) " >&6
10089 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10090 /* end confdefs.h. */
10095 aix*) gl_absname_cpp="$ac_cpp -C" ;;
10096 *) gl_absname_cpp="$ac_cpp" ;;
10101 gl_dirsep_regex='[/\\]'
10104 gl_dirsep_regex='\/'
10107 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
10109 gl_header_literal_regex=`echo 'errno.h' \
10110 | sed -e "$gl_make_literal_regex_sed"`
10111 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
10112 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
10117 gl_cv_next_errno_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
10118 sed -n "$gl_absolute_header_sed"`'"'
10122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_errno_h" >&5
10123 $as_echo "$gl_cv_next_errno_h" >&6; }
10125 NEXT_ERRNO_H=$gl_cv_next_errno_h
10127 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
10128 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
10129 gl_next_as_first_directive='<'errno.h'>'
10131 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
10132 gl_next_as_first_directive=$gl_cv_next_errno_h
10134 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H=$gl_next_as_first_directive
10142 if test -n "$ERRNO_H"; then
10143 GL_GENERATE_ERRNO_H_TRUE=
10144 GL_GENERATE_ERRNO_H_FALSE='#'
10146 GL_GENERATE_ERRNO_H_TRUE='#'
10147 GL_GENERATE_ERRNO_H_FALSE=
10151 if test -n "$ERRNO_H"; then
10152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EMULTIHOP value" >&5
10153 $as_echo_n "checking for EMULTIHOP value... " >&6; }
10154 if ${gl_cv_header_errno_h_EMULTIHOP+:} false; then :
10155 $as_echo_n "(cached) " >&6
10158 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10159 /* end confdefs.h. */
10167 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10168 $EGREP "yes" >/dev/null 2>&1; then :
10169 gl_cv_header_errno_h_EMULTIHOP=yes
10171 gl_cv_header_errno_h_EMULTIHOP=no
10175 if test $gl_cv_header_errno_h_EMULTIHOP = no; then
10176 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10177 /* end confdefs.h. */
10179 #define _XOPEN_SOURCE_EXTENDED 1
10186 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10187 $EGREP "yes" >/dev/null 2>&1; then :
10188 gl_cv_header_errno_h_EMULTIHOP=hidden
10192 if test $gl_cv_header_errno_h_EMULTIHOP = hidden; then
10193 if ac_fn_c_compute_int "$LINENO" "EMULTIHOP" "gl_cv_header_errno_h_EMULTIHOP" "
10194 #define _XOPEN_SOURCE_EXTENDED 1
10196 /* The following two lines are a workaround against an autoconf-2.52 bug. */
10198 #include <stdlib.h>
10207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EMULTIHOP" >&5
10208 $as_echo "$gl_cv_header_errno_h_EMULTIHOP" >&6; }
10209 case $gl_cv_header_errno_h_EMULTIHOP in
10211 EMULTIHOP_HIDDEN=0; EMULTIHOP_VALUE=
10214 EMULTIHOP_HIDDEN=1; EMULTIHOP_VALUE="$gl_cv_header_errno_h_EMULTIHOP"
10222 if test -n "$ERRNO_H"; then
10223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ENOLINK value" >&5
10224 $as_echo_n "checking for ENOLINK value... " >&6; }
10225 if ${gl_cv_header_errno_h_ENOLINK+:} false; then :
10226 $as_echo_n "(cached) " >&6
10229 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10230 /* end confdefs.h. */
10238 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10239 $EGREP "yes" >/dev/null 2>&1; then :
10240 gl_cv_header_errno_h_ENOLINK=yes
10242 gl_cv_header_errno_h_ENOLINK=no
10246 if test $gl_cv_header_errno_h_ENOLINK = no; then
10247 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10248 /* end confdefs.h. */
10250 #define _XOPEN_SOURCE_EXTENDED 1
10257 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10258 $EGREP "yes" >/dev/null 2>&1; then :
10259 gl_cv_header_errno_h_ENOLINK=hidden
10263 if test $gl_cv_header_errno_h_ENOLINK = hidden; then
10264 if ac_fn_c_compute_int "$LINENO" "ENOLINK" "gl_cv_header_errno_h_ENOLINK" "
10265 #define _XOPEN_SOURCE_EXTENDED 1
10267 /* The following two lines are a workaround against an autoconf-2.52 bug. */
10269 #include <stdlib.h>
10278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_ENOLINK" >&5
10279 $as_echo "$gl_cv_header_errno_h_ENOLINK" >&6; }
10280 case $gl_cv_header_errno_h_ENOLINK in
10282 ENOLINK_HIDDEN=0; ENOLINK_VALUE=
10285 ENOLINK_HIDDEN=1; ENOLINK_VALUE="$gl_cv_header_errno_h_ENOLINK"
10293 if test -n "$ERRNO_H"; then
10294 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EOVERFLOW value" >&5
10295 $as_echo_n "checking for EOVERFLOW value... " >&6; }
10296 if ${gl_cv_header_errno_h_EOVERFLOW+:} false; then :
10297 $as_echo_n "(cached) " >&6
10300 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10301 /* end confdefs.h. */
10309 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10310 $EGREP "yes" >/dev/null 2>&1; then :
10311 gl_cv_header_errno_h_EOVERFLOW=yes
10313 gl_cv_header_errno_h_EOVERFLOW=no
10317 if test $gl_cv_header_errno_h_EOVERFLOW = no; then
10318 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10319 /* end confdefs.h. */
10321 #define _XOPEN_SOURCE_EXTENDED 1
10328 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10329 $EGREP "yes" >/dev/null 2>&1; then :
10330 gl_cv_header_errno_h_EOVERFLOW=hidden
10334 if test $gl_cv_header_errno_h_EOVERFLOW = hidden; then
10335 if ac_fn_c_compute_int "$LINENO" "EOVERFLOW" "gl_cv_header_errno_h_EOVERFLOW" "
10336 #define _XOPEN_SOURCE_EXTENDED 1
10338 /* The following two lines are a workaround against an autoconf-2.52 bug. */
10340 #include <stdlib.h>
10349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EOVERFLOW" >&5
10350 $as_echo "$gl_cv_header_errno_h_EOVERFLOW" >&6; }
10351 case $gl_cv_header_errno_h_EOVERFLOW in
10353 EOVERFLOW_HIDDEN=0; EOVERFLOW_VALUE=
10356 EOVERFLOW_HIDDEN=1; EOVERFLOW_VALUE="$gl_cv_header_errno_h_EOVERFLOW"
10364 ac_fn_c_check_decl "$LINENO" "strerror_r" "ac_cv_have_decl_strerror_r" "$ac_includes_default"
10365 if test "x$ac_cv_have_decl_strerror_r" = xyes; then :
10371 cat >>confdefs.h <<_ACEOF
10372 #define HAVE_DECL_STRERROR_R $ac_have_decl
10375 for ac_func in strerror_r
10377 ac_fn_c_check_func "$LINENO" "strerror_r" "ac_cv_func_strerror_r"
10378 if test "x$ac_cv_func_strerror_r" = xyes; then :
10379 cat >>confdefs.h <<_ACEOF
10380 #define HAVE_STRERROR_R 1
10386 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror_r returns char *" >&5
10387 $as_echo_n "checking whether strerror_r returns char *... " >&6; }
10388 if ${ac_cv_func_strerror_r_char_p+:} false; then :
10389 $as_echo_n "(cached) " >&6
10392 ac_cv_func_strerror_r_char_p=no
10393 if test $ac_cv_have_decl_strerror_r = yes; then
10394 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10395 /* end confdefs.h. */
10396 $ac_includes_default
10402 char x = *strerror_r (0, buf, sizeof buf);
10403 char *p = strerror_r (0, buf, sizeof buf);
10410 if ac_fn_c_try_compile "$LINENO"; then :
10411 ac_cv_func_strerror_r_char_p=yes
10413 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10415 # strerror_r is not declared. Choose between
10416 # systems that have relatively inaccessible declarations for the
10417 # function. BeOS and DEC UNIX 4.0 fall in this category, but the
10418 # former has a strerror_r that returns char*, while the latter
10419 # has a strerror_r that returns `int'.
10420 # This test should segfault on the DEC system.
10421 if test "$cross_compiling" = yes; then :
10424 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10425 /* end confdefs.h. */
10426 $ac_includes_default
10427 extern char *strerror_r ();
10432 char x = *strerror_r (0, buf, sizeof buf);
10433 return ! isalpha (x);
10438 if ac_fn_c_try_run "$LINENO"; then :
10439 ac_cv_func_strerror_r_char_p=yes
10441 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10442 conftest.$ac_objext conftest.beam conftest.$ac_ext
10448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strerror_r_char_p" >&5
10449 $as_echo "$ac_cv_func_strerror_r_char_p" >&6; }
10450 if test $ac_cv_func_strerror_r_char_p = yes; then
10452 $as_echo "#define STRERROR_R_CHAR_P 1" >>confdefs.h
10459 ac_fn_c_check_decl "$LINENO" "fchdir" "ac_cv_have_decl_fchdir" "$ac_includes_default"
10460 if test "x$ac_cv_have_decl_fchdir" = xyes; then :
10466 cat >>confdefs.h <<_ACEOF
10467 #define HAVE_DECL_FCHDIR $ac_have_decl
10483 GNULIB_UTIMENSAT=0;
10497 REPLACE_FUTIMENS=0;
10503 REPLACE_UTIMENSAT=0;
10511 GNULIB_NONBLOCKING=0;
10529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fcntl.h" >&5
10530 $as_echo_n "checking for working fcntl.h... " >&6; }
10531 if ${gl_cv_header_working_fcntl_h+:} false; then :
10532 $as_echo_n "(cached) " >&6
10534 if test "$cross_compiling" = yes; then :
10535 gl_cv_header_working_fcntl_h=cross-compiling
10537 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10538 /* end confdefs.h. */
10539 #include <sys/types.h>
10540 #include <sys/stat.h>
10542 # include <unistd.h>
10543 #else /* on Windows with MSVC */
10545 # include <stdlib.h>
10546 # defined sleep(n) _sleep ((n) * 1000)
10550 #define O_NOATIME 0
10553 #define O_NOFOLLOW 0
10555 static int const constants[] =
10557 O_CREAT, O_EXCL, O_NOCTTY, O_TRUNC, O_APPEND,
10558 O_NONBLOCK, O_SYNC, O_ACCMODE, O_RDONLY, O_RDWR, O_WRONLY
10565 int result = !constants;
10568 static char const sym[] = "conftest.sym";
10569 if (symlink ("/dev/null", sym) != 0)
10573 int fd = open (sym, O_WRONLY | O_NOFOLLOW | O_CREAT, 0);
10580 if (unlink (sym) != 0 || symlink (".", sym) != 0)
10584 int fd = open (sym, O_RDONLY | O_NOFOLLOW);
10595 static char const file[] = "confdefs.h";
10596 int fd = open (file, O_RDONLY | O_NOATIME);
10602 if (fstat (fd, &st0) != 0)
10608 if (read (fd, &c, 1) != 1)
10612 if (close (fd) != 0)
10617 if (stat (file, &st1) != 0)
10620 if (st0.st_atime != st1.st_atime)
10632 if ac_fn_c_try_run "$LINENO"; then :
10633 gl_cv_header_working_fcntl_h=yes
10636 4) gl_cv_header_working_fcntl_h='no (bad O_NOFOLLOW)';; #(
10637 64) gl_cv_header_working_fcntl_h='no (bad O_NOATIME)';; #(
10638 68) gl_cv_header_working_fcntl_h='no (bad O_NOATIME, O_NOFOLLOW)';; #(
10639 *) gl_cv_header_working_fcntl_h='no';;
10642 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10643 conftest.$ac_objext conftest.beam conftest.$ac_ext
10647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_fcntl_h" >&5
10648 $as_echo "$gl_cv_header_working_fcntl_h" >&6; }
10650 case $gl_cv_header_working_fcntl_h in #(
10651 *O_NOATIME* | no | cross-compiling) ac_val=0;; #(
10655 cat >>confdefs.h <<_ACEOF
10656 #define HAVE_WORKING_O_NOATIME $ac_val
10660 case $gl_cv_header_working_fcntl_h in #(
10661 *O_NOFOLLOW* | no | cross-compiling) ac_val=0;; #(
10665 cat >>confdefs.h <<_ACEOF
10666 #define HAVE_WORKING_O_NOFOLLOW $ac_val
10674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
10675 $as_echo_n "checking for mbstate_t... " >&6; }
10676 if ${ac_cv_type_mbstate_t+:} false; then :
10677 $as_echo_n "(cached) " >&6
10679 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10680 /* end confdefs.h. */
10681 $ac_includes_default
10682 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
10684 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
10685 included before <wchar.h>. */
10686 #include <stddef.h>
10693 mbstate_t x; return sizeof x;
10698 if ac_fn_c_try_compile "$LINENO"; then :
10699 ac_cv_type_mbstate_t=yes
10701 ac_cv_type_mbstate_t=no
10703 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
10706 $as_echo "$ac_cv_type_mbstate_t" >&6; }
10707 if test $ac_cv_type_mbstate_t = yes; then
10709 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
10713 $as_echo "#define mbstate_t int" >>confdefs.h
10744 GNULIB_FPRINTF_POSIX=0;
10760 GNULIB_OBSTACK_PRINTF=0;
10761 GNULIB_OBSTACK_PRINTF_POSIX=0;
10766 GNULIB_PRINTF_POSIX=0;
10775 GNULIB_SPRINTF_POSIX=0;
10776 GNULIB_STDIO_H_NONBLOCKING=0;
10777 GNULIB_STDIO_H_SIGPIPE=0;
10779 GNULIB_VASPRINTF=0;
10784 GNULIB_VFPRINTF_POSIX=0;
10786 GNULIB_VPRINTF_POSIX=0;
10787 GNULIB_VSNPRINTF=0;
10788 GNULIB_VSPRINTF_POSIX=0;
10789 HAVE_DECL_FPURGE=1;
10790 HAVE_DECL_FSEEKO=1;
10791 HAVE_DECL_FTELLO=1;
10792 HAVE_DECL_GETDELIM=1;
10793 HAVE_DECL_GETLINE=1;
10794 HAVE_DECL_OBSTACK_PRINTF=1;
10795 HAVE_DECL_SNPRINTF=1;
10796 HAVE_DECL_VSNPRINTF=1;
10817 REPLACE_GETDELIM=0;
10819 REPLACE_OBSTACK_PRINTF=0;
10825 REPLACE_RENAMEAT=0;
10826 REPLACE_SNPRINTF=0;
10828 REPLACE_STDIO_READ_FUNCS=0;
10829 REPLACE_STDIO_WRITE_FUNCS=0;
10831 REPLACE_VASPRINTF=0;
10832 REPLACE_VDPRINTF=0;
10833 REPLACE_VFPRINTF=0;
10835 REPLACE_VSNPRINTF=0;
10836 REPLACE_VSPRINTF=0;
10839 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdin defaults to large file offsets" >&5
10840 $as_echo_n "checking whether stdin defaults to large file offsets... " >&6; }
10841 if ${gl_cv_var_stdin_large_offset+:} false; then :
10842 $as_echo_n "(cached) " >&6
10844 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10845 /* end confdefs.h. */
10850 #if defined __SL64 && defined __SCLE /* cygwin */
10851 /* Cygwin 1.5.24 and earlier fail to put stdin in 64-bit mode, making
10852 fseeko/ftello needlessly fail. This bug was fixed in 1.5.25, and
10853 it is easier to do a version check than building a runtime test. */
10854 # include <cygwin/version.h>
10855 # if CYGWIN_VERSION_DLL_COMBINED < CYGWIN_VERSION_DLL_MAKE_COMBINED (1005, 25)
10863 if ac_fn_c_try_link "$LINENO"; then :
10864 gl_cv_var_stdin_large_offset=yes
10866 gl_cv_var_stdin_large_offset=no
10868 rm -f core conftest.err conftest.$ac_objext \
10869 conftest$ac_exeext conftest.$ac_ext
10871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_var_stdin_large_offset" >&5
10872 $as_echo "$gl_cv_var_stdin_large_offset" >&6; }
10880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
10881 $as_echo_n "checking for 64-bit off_t... " >&6; }
10882 if ${gl_cv_type_off_t_64+:} false; then :
10883 $as_echo_n "(cached) " >&6
10885 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10886 /* end confdefs.h. */
10887 #include <sys/types.h>
10888 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
10898 if ac_fn_c_try_compile "$LINENO"; then :
10899 gl_cv_type_off_t_64=yes
10901 gl_cv_type_off_t_64=no
10903 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
10907 $as_echo "$gl_cv_type_off_t_64" >&6; }
10908 if test $gl_cv_type_off_t_64 = no; then
10909 WINDOWS_64_BIT_OFF_T=1
10911 WINDOWS_64_BIT_OFF_T=0
10913 WINDOWS_64_BIT_ST_SIZE=1
10916 WINDOWS_64_BIT_OFF_T=0
10917 WINDOWS_64_BIT_ST_SIZE=0
10937 if test $gl_cv_have_include_next = yes; then
10938 gl_cv_next_sys_types_h='<'sys/types.h'>'
10940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/types.h>" >&5
10941 $as_echo_n "checking absolute name of <sys/types.h>... " >&6; }
10942 if ${gl_cv_next_sys_types_h+:} false; then :
10943 $as_echo_n "(cached) " >&6
10946 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10947 /* end confdefs.h. */
10948 #include <sys/types.h>
10952 aix*) gl_absname_cpp="$ac_cpp -C" ;;
10953 *) gl_absname_cpp="$ac_cpp" ;;
10958 gl_dirsep_regex='[/\\]'
10961 gl_dirsep_regex='\/'
10964 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
10966 gl_header_literal_regex=`echo 'sys/types.h' \
10967 | sed -e "$gl_make_literal_regex_sed"`
10968 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
10969 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
10974 gl_cv_next_sys_types_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
10975 sed -n "$gl_absolute_header_sed"`'"'
10979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_types_h" >&5
10980 $as_echo "$gl_cv_next_sys_types_h" >&6; }
10982 NEXT_SYS_TYPES_H=$gl_cv_next_sys_types_h
10984 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
10985 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
10986 gl_next_as_first_directive='<'sys/types.h'>'
10988 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
10989 gl_next_as_first_directive=$gl_cv_next_sys_types_h
10991 NEXT_AS_FIRST_DIRECTIVE_SYS_TYPES_H=$gl_next_as_first_directive
11003 ac_fn_c_check_decl "$LINENO" "fseeko" "ac_cv_have_decl_fseeko" "$ac_includes_default"
11004 if test "x$ac_cv_have_decl_fseeko" = xyes; then :
11010 cat >>confdefs.h <<_ACEOF
11011 #define HAVE_DECL_FSEEKO $ac_have_decl
11022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fseeko" >&5
11023 $as_echo_n "checking for fseeko... " >&6; }
11024 if ${gl_cv_func_fseeko+:} false; then :
11025 $as_echo_n "(cached) " >&6
11028 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11029 /* end confdefs.h. */
11035 fseeko (stdin, 0, 0);
11040 if ac_fn_c_try_link "$LINENO"; then :
11041 gl_cv_func_fseeko=yes
11043 gl_cv_func_fseeko=no
11045 rm -f core conftest.err conftest.$ac_objext \
11046 conftest$ac_exeext conftest.$ac_ext
11049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fseeko" >&5
11050 $as_echo "$gl_cv_func_fseeko" >&6; }
11053 if test $ac_cv_have_decl_fseeko = no; then
11057 if test $gl_cv_func_fseeko = no; then
11060 if test $WINDOWS_64_BIT_OFF_T = 1; then
11063 if test $gl_cv_var_stdin_large_offset = no; then
11085 if test $gl_cv_have_include_next = yes; then
11086 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
11088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
11089 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
11090 if ${gl_cv_next_sys_stat_h+:} false; then :
11091 $as_echo_n "(cached) " >&6
11094 if test $ac_cv_header_sys_stat_h = yes; then
11097 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11098 /* end confdefs.h. */
11099 #include <sys/stat.h>
11103 aix*) gl_absname_cpp="$ac_cpp -C" ;;
11104 *) gl_absname_cpp="$ac_cpp" ;;
11109 gl_dirsep_regex='[/\\]'
11112 gl_dirsep_regex='\/'
11115 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
11117 gl_header_literal_regex=`echo 'sys/stat.h' \
11118 | sed -e "$gl_make_literal_regex_sed"`
11119 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
11120 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
11125 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
11126 sed -n "$gl_absolute_header_sed"`'"'
11128 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
11133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
11134 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
11136 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
11138 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
11139 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
11140 gl_next_as_first_directive='<'sys/stat.h'>'
11142 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
11143 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
11145 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
11157 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
11159 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
11163 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
11164 #include <sys/stat.h>
11166 if test "x$ac_cv_type_nlink_t" = xyes; then :
11170 $as_echo "#define nlink_t int" >>confdefs.h
11176 for gl_func in fchmodat fstat fstatat futimens lchmod lstat mkdirat mkfifo mkfifoat mknod mknodat stat utimensat; do
11177 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
11178 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
11179 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
11180 if eval \${$as_gl_Symbol+:} false; then :
11181 $as_echo_n "(cached) " >&6
11183 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11184 /* end confdefs.h. */
11185 #include <sys/stat.h>
11196 if ac_fn_c_try_compile "$LINENO"; then :
11197 eval "$as_gl_Symbol=yes"
11199 eval "$as_gl_Symbol=no"
11201 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11203 eval ac_res=\$$as_gl_Symbol
11204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
11205 $as_echo "$ac_res" >&6; }
11206 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
11207 cat >>confdefs.h <<_ACEOF
11208 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
11211 eval ac_cv_have_decl_$gl_func=yes
11217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
11218 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
11219 if ${gl_cv_func_lstat_dereferences_slashed_symlink+:} false; then :
11220 $as_echo_n "(cached) " >&6
11222 rm -f conftest.sym conftest.file
11223 echo >conftest.file
11224 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
11225 if test "$cross_compiling" = yes; then :
11227 # Guess yes on glibc systems.
11228 *-gnu*) gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
11229 # If we don't know, assume the worst.
11230 *) gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
11234 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11235 /* end confdefs.h. */
11236 $ac_includes_default
11241 /* Linux will dereference the symlink and fail, as required by
11242 POSIX. That is better in the sense that it means we will not
11243 have to compile and use the lstat wrapper. */
11244 return lstat ("conftest.sym/", &sbuf) == 0;
11250 if ac_fn_c_try_run "$LINENO"; then :
11251 gl_cv_func_lstat_dereferences_slashed_symlink=yes
11253 gl_cv_func_lstat_dereferences_slashed_symlink=no
11255 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11256 conftest.$ac_objext conftest.beam conftest.$ac_ext
11260 # If the 'ln -s' command failed, then we probably don't even
11261 # have an lstat function.
11262 gl_cv_func_lstat_dereferences_slashed_symlink="guessing no"
11264 rm -f conftest.sym conftest.file
11267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
11268 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
11269 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
11272 cat >>confdefs.h <<_ACEOF
11273 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
11285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getcwd (NULL, 0) allocates memory for result" >&5
11286 $as_echo_n "checking whether getcwd (NULL, 0) allocates memory for result... " >&6; }
11287 if ${gl_cv_func_getcwd_null+:} false; then :
11288 $as_echo_n "(cached) " >&6
11290 if test "$cross_compiling" = yes; then :
11292 # Guess yes on glibc systems.
11293 *-gnu*) gl_cv_func_getcwd_null="guessing yes";;
11294 # Guess yes on Cygwin.
11295 cygwin*) gl_cv_func_getcwd_null="guessing yes";;
11296 # If we don't know, assume the worst.
11297 *) gl_cv_func_getcwd_null="guessing no";;
11301 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11302 /* end confdefs.h. */
11305 # include <unistd.h>
11306 # else /* on Windows with MSVC */
11307 # include <direct.h>
11317 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
11318 /* mingw cwd does not start with '/', but getcwd does allocate.
11319 However, mingw fails to honor non-zero size. */
11321 if (chdir ("/") != 0)
11325 char *f = getcwd (NULL, 0);
11340 if ac_fn_c_try_run "$LINENO"; then :
11341 gl_cv_func_getcwd_null=yes
11343 gl_cv_func_getcwd_null=no
11345 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11346 conftest.$ac_objext conftest.beam conftest.$ac_ext
11350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_null" >&5
11351 $as_echo "$gl_cv_func_getcwd_null" >&6; }
11354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getcwd with POSIX signature" >&5
11355 $as_echo_n "checking for getcwd with POSIX signature... " >&6; }
11356 if ${gl_cv_func_getcwd_posix_signature+:} false; then :
11357 $as_echo_n "(cached) " >&6
11359 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11360 /* end confdefs.h. */
11361 #include <unistd.h>
11369 char *getcwd (char *, size_t);
11376 if ac_fn_c_try_compile "$LINENO"; then :
11377 gl_cv_func_getcwd_posix_signature=yes
11379 gl_cv_func_getcwd_posix_signature=no
11381 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_posix_signature" >&5
11385 $as_echo "$gl_cv_func_getcwd_posix_signature" >&6; }
11387 ac_fn_c_check_decl "$LINENO" "getcwd" "ac_cv_have_decl_getcwd" "$ac_includes_default"
11388 if test "x$ac_cv_have_decl_getcwd" = xyes; then :
11394 cat >>confdefs.h <<_ACEOF
11395 #define HAVE_DECL_GETCWD $ac_have_decl
11398 ac_fn_c_check_decl "$LINENO" "getdelim" "ac_cv_have_decl_getdelim" "$ac_includes_default"
11399 if test "x$ac_cv_have_decl_getdelim" = xyes; then :
11405 cat >>confdefs.h <<_ACEOF
11406 #define HAVE_DECL_GETDELIM $ac_have_decl
11413 ac_fn_c_check_decl "$LINENO" "getline" "ac_cv_have_decl_getline" "$ac_includes_default"
11414 if test "x$ac_cv_have_decl_getline" = xyes; then :
11420 cat >>confdefs.h <<_ACEOF
11421 #define HAVE_DECL_GETLINE $ac_have_decl
11439 if test $gl_cv_have_include_next = yes; then
11440 gl_cv_next_getopt_h='<'getopt.h'>'
11442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
11443 $as_echo_n "checking absolute name of <getopt.h>... " >&6; }
11444 if ${gl_cv_next_getopt_h+:} false; then :
11445 $as_echo_n "(cached) " >&6
11448 if test $ac_cv_header_getopt_h = yes; then
11451 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11452 /* end confdefs.h. */
11453 #include <getopt.h>
11457 aix*) gl_absname_cpp="$ac_cpp -C" ;;
11458 *) gl_absname_cpp="$ac_cpp" ;;
11463 gl_dirsep_regex='[/\\]'
11466 gl_dirsep_regex='\/'
11469 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
11471 gl_header_literal_regex=`echo 'getopt.h' \
11472 | sed -e "$gl_make_literal_regex_sed"`
11473 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
11474 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
11479 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
11480 sed -n "$gl_absolute_header_sed"`'"'
11482 gl_cv_next_getopt_h='<'getopt.h'>'
11487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
11488 $as_echo "$gl_cv_next_getopt_h" >&6; }
11490 NEXT_GETOPT_H=$gl_cv_next_getopt_h
11492 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
11493 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
11494 gl_next_as_first_directive='<'getopt.h'>'
11496 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
11497 gl_next_as_first_directive=$gl_cv_next_getopt_h
11499 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
11504 if test $ac_cv_header_getopt_h = yes; then
11513 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
11514 for ac_header in getopt.h
11516 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
11517 if test "x$ac_cv_header_getopt_h" = xyes; then :
11518 cat >>confdefs.h <<_ACEOF
11519 #define HAVE_GETOPT_H 1
11523 gl_replace_getopt=yes
11530 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
11531 for ac_func in getopt_long_only
11533 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
11534 if test "x$ac_cv_func_getopt_long_only" = xyes; then :
11535 cat >>confdefs.h <<_ACEOF
11536 #define HAVE_GETOPT_LONG_ONLY 1
11540 gl_replace_getopt=yes
11546 if test -z "$gl_replace_getopt"; then
11547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
11548 $as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
11549 if ${gl_cv_func_getopt_posix+:} false; then :
11550 $as_echo_n "(cached) " >&6
11553 if test $cross_compiling = no; then
11554 if test "$cross_compiling" = yes; then :
11555 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11556 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11557 as_fn_error $? "cannot run test program while cross compiling
11558 See \`config.log' for more details" "$LINENO" 5; }
11560 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11561 /* end confdefs.h. */
11563 #include <unistd.h>
11564 #include <stdlib.h>
11565 #include <string.h>
11570 static char program[] = "program";
11571 static char a[] = "-a";
11572 static char foo[] = "foo";
11573 static char bar[] = "bar";
11574 char *argv[] = { program, a, foo, bar, NULL };
11577 c = getopt (4, argv, "ab");
11580 c = getopt (4, argv, "ab");
11583 if (!(optind == 2))
11589 if ac_fn_c_try_run "$LINENO"; then :
11590 gl_cv_func_getopt_posix=maybe
11592 gl_cv_func_getopt_posix=no
11594 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11595 conftest.$ac_objext conftest.beam conftest.$ac_ext
11598 if test $gl_cv_func_getopt_posix = maybe; then
11599 if test "$cross_compiling" = yes; then :
11600 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11601 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11602 as_fn_error $? "cannot run test program while cross compiling
11603 See \`config.log' for more details" "$LINENO" 5; }
11605 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11606 /* end confdefs.h. */
11608 #include <unistd.h>
11609 #include <stdlib.h>
11610 #include <string.h>
11615 static char program[] = "program";
11616 static char donald[] = "donald";
11617 static char p[] = "-p";
11618 static char billy[] = "billy";
11619 static char duck[] = "duck";
11620 static char a[] = "-a";
11621 static char bar[] = "bar";
11622 char *argv[] = { program, donald, p, billy, duck, a, bar, NULL };
11625 c = getopt (7, argv, "+abp:q:");
11628 if (!(strcmp (argv[0], "program") == 0))
11630 if (!(strcmp (argv[1], "donald") == 0))
11632 if (!(strcmp (argv[2], "-p") == 0))
11634 if (!(strcmp (argv[3], "billy") == 0))
11636 if (!(strcmp (argv[4], "duck") == 0))
11638 if (!(strcmp (argv[5], "-a") == 0))
11640 if (!(strcmp (argv[6], "bar") == 0))
11642 if (!(optind == 1))
11648 if ac_fn_c_try_run "$LINENO"; then :
11649 gl_cv_func_getopt_posix=maybe
11651 gl_cv_func_getopt_posix=no
11653 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11654 conftest.$ac_objext conftest.beam conftest.$ac_ext
11658 if test $gl_cv_func_getopt_posix = maybe; then
11659 if test "$cross_compiling" = yes; then :
11660 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11661 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11662 as_fn_error $? "cannot run test program while cross compiling
11663 See \`config.log' for more details" "$LINENO" 5; }
11665 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11666 /* end confdefs.h. */
11668 #include <unistd.h>
11669 #include <stdlib.h>
11670 #include <string.h>
11675 static char program[] = "program";
11676 static char ab[] = "-ab";
11677 char *argv[3] = { program, ab, NULL };
11678 if (getopt (2, argv, "ab:") != 'a')
11680 if (getopt (2, argv, "ab:") != '?')
11690 if ac_fn_c_try_run "$LINENO"; then :
11691 gl_cv_func_getopt_posix=yes
11693 gl_cv_func_getopt_posix=no
11695 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11696 conftest.$ac_objext conftest.beam conftest.$ac_ext
11702 darwin* | aix* | mingw*) gl_cv_func_getopt_posix="guessing no";;
11703 *) gl_cv_func_getopt_posix="guessing yes";;
11708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
11709 $as_echo "$gl_cv_func_getopt_posix" >&6; }
11710 case "$gl_cv_func_getopt_posix" in
11711 *no) gl_replace_getopt=yes ;;
11715 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
11716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
11717 $as_echo_n "checking for working GNU getopt function... " >&6; }
11718 if ${gl_cv_func_getopt_gnu+:} false; then :
11719 $as_echo_n "(cached) " >&6
11721 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
11722 # optstring is necessary for programs like m4 that have POSIX-mandated
11723 # semantics for supporting options interspersed with files.
11724 # Also, since getopt_long is a GNU extension, we require optind=0.
11725 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
11726 # so take care to revert to the correct (non-)export state.
11727 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
11728 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
11729 xx) gl_had_POSIXLY_CORRECT=exported ;;
11730 x) gl_had_POSIXLY_CORRECT=yes ;;
11731 *) gl_had_POSIXLY_CORRECT= ;;
11734 export POSIXLY_CORRECT
11735 if test "$cross_compiling" = yes; then :
11736 gl_cv_func_getopt_gnu="guessing no"
11739 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11740 /* end confdefs.h. */
11741 #include <getopt.h>
11742 #include <stddef.h>
11743 #include <string.h>
11745 #include <stdlib.h>
11746 #if defined __MACH__ && defined __APPLE__
11747 /* Avoid a crash on Mac OS X. */
11748 #include <mach/mach.h>
11749 #include <mach/mach_error.h>
11750 #include <mach/thread_status.h>
11751 #include <mach/exception.h>
11752 #include <mach/task.h>
11753 #include <pthread.h>
11754 /* The exception port on which our thread listens. */
11755 static mach_port_t our_exception_port;
11756 /* The main function of the thread listening for exceptions of type
11759 mach_exception_thread (void *arg)
11761 /* Buffer for a message to be received. */
11763 mach_msg_header_t head;
11764 mach_msg_body_t msgh_body;
11767 mach_msg_return_t retval;
11768 /* Wait for a message on the exception port. */
11769 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
11770 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
11771 if (retval != MACH_MSG_SUCCESS)
11776 nocrash_init (void)
11778 mach_port_t self = mach_task_self ();
11779 /* Allocate a port on which the thread shall listen for exceptions. */
11780 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
11782 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
11783 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
11784 MACH_MSG_TYPE_MAKE_SEND)
11786 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
11788 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
11789 /* Create the thread listening on the exception port. */
11790 pthread_attr_t attr;
11792 if (pthread_attr_init (&attr) == 0
11793 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
11794 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
11795 pthread_attr_destroy (&attr);
11796 /* Replace the exception port info for these exceptions with our own.
11797 Note that we replace the exception port for the entire task, not only
11798 for a particular thread. This has the effect that when our exception
11799 port gets the message, the thread specific exception port has already
11800 been asked, and we don't need to bother about it.
11801 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
11802 task_set_exception_ports (self, mask, our_exception_port,
11803 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
11808 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
11809 /* Avoid a crash on native Windows. */
11810 #define WIN32_LEAN_AND_MEAN
11811 #include <windows.h>
11812 #include <winerror.h>
11814 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
11816 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
11818 case EXCEPTION_ACCESS_VIOLATION:
11819 case EXCEPTION_IN_PAGE_ERROR:
11820 case EXCEPTION_STACK_OVERFLOW:
11821 case EXCEPTION_GUARD_PAGE:
11822 case EXCEPTION_PRIV_INSTRUCTION:
11823 case EXCEPTION_ILLEGAL_INSTRUCTION:
11824 case EXCEPTION_DATATYPE_MISALIGNMENT:
11825 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
11826 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
11829 return EXCEPTION_CONTINUE_SEARCH;
11832 nocrash_init (void)
11834 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
11837 /* Avoid a crash on POSIX systems. */
11838 #include <signal.h>
11839 /* A POSIX signal handler. */
11841 exception_handler (int sig)
11846 nocrash_init (void)
11849 signal (SIGSEGV, exception_handler);
11852 signal (SIGBUS, exception_handler);
11866 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
11867 and fails on Mac OS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
11868 OSF/1 5.1, Solaris 10. */
11870 static char conftest[] = "conftest";
11871 static char plus[] = "-+";
11872 char *argv[3] = { conftest, plus, NULL };
11874 if (getopt (2, argv, "+a") != '?')
11877 /* This code succeeds on glibc 2.8, mingw,
11878 and fails on Mac OS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
11879 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
11881 static char program[] = "program";
11882 static char p[] = "-p";
11883 static char foo[] = "foo";
11884 static char bar[] = "bar";
11885 char *argv[] = { program, p, foo, bar, NULL };
11888 if (getopt (4, argv, "p::") != 'p')
11890 else if (optarg != NULL)
11892 else if (getopt (4, argv, "p::") != -1)
11894 else if (optind != 2)
11897 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
11899 static char program[] = "program";
11900 static char foo[] = "foo";
11901 static char p[] = "-p";
11902 char *argv[] = { program, foo, p, NULL };
11904 if (getopt (3, argv, "-p") != 1)
11906 else if (getopt (3, argv, "-p") != 'p')
11909 /* This code fails on glibc 2.11. */
11911 static char program[] = "program";
11912 static char b[] = "-b";
11913 static char a[] = "-a";
11914 char *argv[] = { program, b, a, NULL };
11915 optind = opterr = 0;
11916 if (getopt (3, argv, "+:a:b") != 'b')
11918 else if (getopt (3, argv, "+:a:b") != ':')
11921 /* This code dumps core on glibc 2.14. */
11923 static char program[] = "program";
11924 static char w[] = "-W";
11925 static char dummy[] = "dummy";
11926 char *argv[] = { program, w, dummy, NULL };
11927 optind = opterr = 1;
11928 if (getopt (3, argv, "W;") != 'W')
11937 if ac_fn_c_try_run "$LINENO"; then :
11938 gl_cv_func_getopt_gnu=yes
11940 gl_cv_func_getopt_gnu=no
11942 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11943 conftest.$ac_objext conftest.beam conftest.$ac_ext
11946 case $gl_had_POSIXLY_CORRECT in
11948 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
11949 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
11953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
11954 $as_echo "$gl_cv_func_getopt_gnu" >&6; }
11955 if test "$gl_cv_func_getopt_gnu" != yes; then
11956 gl_replace_getopt=yes
11958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt_long function" >&5
11959 $as_echo_n "checking for working GNU getopt_long function... " >&6; }
11960 if ${gl_cv_func_getopt_long_gnu+:} false; then :
11961 $as_echo_n "(cached) " >&6
11963 if test "$cross_compiling" = yes; then :
11965 openbsd*) gl_cv_func_getopt_long_gnu="guessing no";;
11966 *) gl_cv_func_getopt_long_gnu="guessing yes";;
11970 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11971 /* end confdefs.h. */
11972 #include <getopt.h>
11973 #include <stddef.h>
11974 #include <string.h>
11979 static const struct option long_options[] =
11981 { "xtremely-",no_argument, NULL, 1003 },
11982 { "xtra", no_argument, NULL, 1001 },
11983 { "xtreme", no_argument, NULL, 1002 },
11984 { "xtremely", no_argument, NULL, 1003 },
11985 { NULL, 0, NULL, 0 }
11987 /* This code fails on OpenBSD 5.0. */
11989 static char program[] = "program";
11990 static char xtremel[] = "--xtremel";
11991 char *argv[] = { program, xtremel, NULL };
11993 optind = 1; opterr = 0;
11994 if (getopt_long (2, argv, "", long_options, &option_index) != 1003)
12003 if ac_fn_c_try_run "$LINENO"; then :
12004 gl_cv_func_getopt_long_gnu=yes
12006 gl_cv_func_getopt_long_gnu=no
12008 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12009 conftest.$ac_objext conftest.beam conftest.$ac_ext
12014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_long_gnu" >&5
12015 $as_echo "$gl_cv_func_getopt_long_gnu" >&6; }
12016 case "$gl_cv_func_getopt_long_gnu" in
12018 *) gl_replace_getopt=yes ;;
12030 if test $REPLACE_GETOPT = 1; then
12034 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
12040 ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
12041 if test "x$ac_cv_have_decl_getenv" = xyes; then :
12047 cat >>confdefs.h <<_ACEOF
12048 #define HAVE_DECL_GETENV $ac_have_decl
12057 GNULIB_GETTIMEOFDAY=0;
12058 HAVE_GETTIMEOFDAY=1;
12059 HAVE_STRUCT_TIMEVAL=1;
12061 REPLACE_GETTIMEOFDAY=0;
12062 REPLACE_STRUCT_TIMEVAL=0;
12077 if test $gl_cv_have_include_next = yes; then
12078 gl_cv_next_sys_time_h='<'sys/time.h'>'
12080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
12081 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
12082 if ${gl_cv_next_sys_time_h+:} false; then :
12083 $as_echo_n "(cached) " >&6
12086 if test $ac_cv_header_sys_time_h = yes; then
12089 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12090 /* end confdefs.h. */
12091 #include <sys/time.h>
12095 aix*) gl_absname_cpp="$ac_cpp -C" ;;
12096 *) gl_absname_cpp="$ac_cpp" ;;
12101 gl_dirsep_regex='[/\\]'
12104 gl_dirsep_regex='\/'
12107 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
12109 gl_header_literal_regex=`echo 'sys/time.h' \
12110 | sed -e "$gl_make_literal_regex_sed"`
12111 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
12112 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
12117 gl_cv_next_sys_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
12118 sed -n "$gl_absolute_header_sed"`'"'
12120 gl_cv_next_sys_time_h='<'sys/time.h'>'
12125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
12126 $as_echo "$gl_cv_next_sys_time_h" >&6; }
12128 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
12130 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
12131 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
12132 gl_next_as_first_directive='<'sys/time.h'>'
12134 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
12135 gl_next_as_first_directive=$gl_cv_next_sys_time_h
12137 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
12143 if test $ac_cv_header_sys_time_h != yes; then
12151 if test $ac_cv_header_sys_socket_h != yes; then
12152 for ac_header in winsock2.h
12154 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
12155 if test "x$ac_cv_header_winsock2_h" = xyes; then :
12156 cat >>confdefs.h <<_ACEOF
12157 #define HAVE_WINSOCK2_H 1
12165 if test "$ac_cv_header_winsock2_h" = yes; then
12167 UNISTD_H_HAVE_WINSOCK2_H=1
12168 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
12174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
12175 $as_echo_n "checking for struct timeval... " >&6; }
12176 if ${gl_cv_sys_struct_timeval+:} false; then :
12177 $as_echo_n "(cached) " >&6
12179 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12180 /* end confdefs.h. */
12181 #if HAVE_SYS_TIME_H
12182 #include <sys/time.h>
12185 #if HAVE_WINSOCK2_H
12186 # include <winsock2.h>
12192 static struct timeval x; x.tv_sec = x.tv_usec;
12197 if ac_fn_c_try_compile "$LINENO"; then :
12198 gl_cv_sys_struct_timeval=yes
12200 gl_cv_sys_struct_timeval=no
12202 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
12206 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
12207 if test $gl_cv_sys_struct_timeval != yes; then
12208 HAVE_STRUCT_TIMEVAL=0
12210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
12211 $as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
12212 if ${gl_cv_sys_struct_timeval_tv_sec+:} false; then :
12213 $as_echo_n "(cached) " >&6
12215 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12216 /* end confdefs.h. */
12217 #if HAVE_SYS_TIME_H
12218 #include <sys/time.h>
12221 #if HAVE_WINSOCK2_H
12222 # include <winsock2.h>
12228 static struct timeval x;
12229 typedef int verify_tv_sec_type[
12230 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
12237 if ac_fn_c_try_compile "$LINENO"; then :
12238 gl_cv_sys_struct_timeval_tv_sec=yes
12240 gl_cv_sys_struct_timeval_tv_sec=no
12242 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
12246 $as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
12247 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
12248 REPLACE_STRUCT_TIMEVAL=1
12253 for gl_func in gettimeofday; do
12254 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
12255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
12256 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
12257 if eval \${$as_gl_Symbol+:} false; then :
12258 $as_echo_n "(cached) " >&6
12260 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12261 /* end confdefs.h. */
12263 #if HAVE_SYS_TIME_H
12264 # include <sys/time.h>
12277 if ac_fn_c_try_compile "$LINENO"; then :
12278 eval "$as_gl_Symbol=yes"
12280 eval "$as_gl_Symbol=no"
12282 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12284 eval ac_res=\$$as_gl_Symbol
12285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
12286 $as_echo "$ac_res" >&6; }
12287 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
12288 cat >>confdefs.h <<_ACEOF
12289 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
12292 eval ac_cv_have_decl_$gl_func=yes
12301 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
12302 $as_echo_n "checking for unsigned long long int... " >&6; }
12303 if ${ac_cv_type_unsigned_long_long_int+:} false; then :
12304 $as_echo_n "(cached) " >&6
12306 ac_cv_type_unsigned_long_long_int=yes
12307 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
12308 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12309 /* end confdefs.h. */
12311 /* For now, do not test the preprocessor; as of 2007 there are too many
12312 implementations with broken preprocessors. Perhaps this can
12313 be revisited in 2012. In the meantime, code should not expect
12314 #if to work with literals wider than 32 bits. */
12315 /* Test literals. */
12316 long long int ll = 9223372036854775807ll;
12317 long long int nll = -9223372036854775807LL;
12318 unsigned long long int ull = 18446744073709551615ULL;
12319 /* Test constant expressions. */
12320 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
12322 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
12328 /* Test availability of runtime routines for shift and division. */
12329 long long int llmax = 9223372036854775807ll;
12330 unsigned long long int ullmax = 18446744073709551615ull;
12331 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
12332 | (llmax / ll) | (llmax % ll)
12333 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
12334 | (ullmax / ull) | (ullmax % ull));
12340 if ac_fn_c_try_link "$LINENO"; then :
12343 ac_cv_type_unsigned_long_long_int=no
12345 rm -f core conftest.err conftest.$ac_objext \
12346 conftest$ac_exeext conftest.$ac_ext
12349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
12350 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
12351 if test $ac_cv_type_unsigned_long_long_int = yes; then
12353 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
12359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
12360 $as_echo_n "checking for long long int... " >&6; }
12361 if ${ac_cv_type_long_long_int+:} false; then :
12362 $as_echo_n "(cached) " >&6
12364 ac_cv_type_long_long_int=yes
12365 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
12366 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
12367 if test $ac_cv_type_long_long_int = yes; then
12368 if test "$cross_compiling" = yes; then :
12371 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12372 /* end confdefs.h. */
12373 #include <limits.h>
12376 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
12377 # define LLONG_MAX (HALF - 1 + HALF)
12382 long long int n = 1;
12386 long long int m = n << i;
12389 if (LLONG_MAX / 2 < m)
12397 if ac_fn_c_try_run "$LINENO"; then :
12400 ac_cv_type_long_long_int=no
12402 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12403 conftest.$ac_objext conftest.beam conftest.$ac_ext
12409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
12410 $as_echo "$ac_cv_type_long_long_int" >&6; }
12411 if test $ac_cv_type_long_long_int = yes; then
12413 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
12422 gl_cv_c_multiarch=no
12423 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12424 /* end confdefs.h. */
12425 #ifndef __APPLE_CC__
12426 not a universal capable compiler
12431 if ac_fn_c_try_compile "$LINENO"; then :
12435 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
12436 if test -n "$prev"; then
12438 i?86 | x86_64 | ppc | ppc64)
12439 if test -z "$arch" || test "$arch" = "$word"; then
12442 gl_cv_c_multiarch=yes
12448 if test "x$word" = "x-arch"; then
12455 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12456 if test $gl_cv_c_multiarch = yes; then
12457 APPLE_UNIVERSAL_BUILD=1
12459 APPLE_UNIVERSAL_BUILD=0
12466 if test $ac_cv_type_long_long_int = yes; then
12467 HAVE_LONG_LONG_INT=1
12469 HAVE_LONG_LONG_INT=0
12473 if test $ac_cv_type_unsigned_long_long_int = yes; then
12474 HAVE_UNSIGNED_LONG_LONG_INT=1
12476 HAVE_UNSIGNED_LONG_LONG_INT=0
12481 if test $ac_cv_header_wchar_h = yes; then
12488 if test $ac_cv_header_inttypes_h = yes; then
12495 if test $ac_cv_header_sys_types_h = yes; then
12511 if test $gl_cv_have_include_next = yes; then
12512 gl_cv_next_stdint_h='<'stdint.h'>'
12514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
12515 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
12516 if ${gl_cv_next_stdint_h+:} false; then :
12517 $as_echo_n "(cached) " >&6
12520 if test $ac_cv_header_stdint_h = yes; then
12523 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12524 /* end confdefs.h. */
12525 #include <stdint.h>
12529 aix*) gl_absname_cpp="$ac_cpp -C" ;;
12530 *) gl_absname_cpp="$ac_cpp" ;;
12535 gl_dirsep_regex='[/\\]'
12538 gl_dirsep_regex='\/'
12541 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
12543 gl_header_literal_regex=`echo 'stdint.h' \
12544 | sed -e "$gl_make_literal_regex_sed"`
12545 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
12546 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
12551 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
12552 sed -n "$gl_absolute_header_sed"`'"'
12554 gl_cv_next_stdint_h='<'stdint.h'>'
12559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
12560 $as_echo "$gl_cv_next_stdint_h" >&6; }
12562 NEXT_STDINT_H=$gl_cv_next_stdint_h
12564 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
12565 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
12566 gl_next_as_first_directive='<'stdint.h'>'
12568 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
12569 gl_next_as_first_directive=$gl_cv_next_stdint_h
12571 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
12576 if test $ac_cv_header_stdint_h = yes; then
12583 if test $ac_cv_header_stdint_h = yes; then
12584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
12585 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
12586 if ${gl_cv_header_working_stdint_h+:} false; then :
12587 $as_echo_n "(cached) " >&6
12589 gl_cv_header_working_stdint_h=no
12590 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12591 /* end confdefs.h. */
12594 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
12595 #include <stdint.h>
12596 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
12597 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
12598 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
12602 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
12603 included before <wchar.h>. */
12604 #include <stddef.h>
12605 #include <signal.h>
12607 # include <stdio.h>
12609 # include <wchar.h>
12614 int8_t a1 = INT8_MAX;
12615 int8_t a1min = INT8_MIN;
12618 int16_t a2 = INT16_MAX;
12619 int16_t a2min = INT16_MIN;
12622 int32_t a3 = INT32_MAX;
12623 int32_t a3min = INT32_MIN;
12626 int64_t a4 = INT64_MAX;
12627 int64_t a4min = INT64_MIN;
12630 uint8_t b1 = UINT8_MAX;
12632 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
12635 uint16_t b2 = UINT16_MAX;
12638 uint32_t b3 = UINT32_MAX;
12641 uint64_t b4 = UINT64_MAX;
12643 int_least8_t c1 = INT8_C (0x7f);
12644 int_least8_t c1max = INT_LEAST8_MAX;
12645 int_least8_t c1min = INT_LEAST8_MIN;
12646 int_least16_t c2 = INT16_C (0x7fff);
12647 int_least16_t c2max = INT_LEAST16_MAX;
12648 int_least16_t c2min = INT_LEAST16_MIN;
12649 int_least32_t c3 = INT32_C (0x7fffffff);
12650 int_least32_t c3max = INT_LEAST32_MAX;
12651 int_least32_t c3min = INT_LEAST32_MIN;
12652 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
12653 int_least64_t c4max = INT_LEAST64_MAX;
12654 int_least64_t c4min = INT_LEAST64_MIN;
12655 uint_least8_t d1 = UINT8_C (0xff);
12656 uint_least8_t d1max = UINT_LEAST8_MAX;
12657 uint_least16_t d2 = UINT16_C (0xffff);
12658 uint_least16_t d2max = UINT_LEAST16_MAX;
12659 uint_least32_t d3 = UINT32_C (0xffffffff);
12660 uint_least32_t d3max = UINT_LEAST32_MAX;
12661 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
12662 uint_least64_t d4max = UINT_LEAST64_MAX;
12663 int_fast8_t e1 = INT_FAST8_MAX;
12664 int_fast8_t e1min = INT_FAST8_MIN;
12665 int_fast16_t e2 = INT_FAST16_MAX;
12666 int_fast16_t e2min = INT_FAST16_MIN;
12667 int_fast32_t e3 = INT_FAST32_MAX;
12668 int_fast32_t e3min = INT_FAST32_MIN;
12669 int_fast64_t e4 = INT_FAST64_MAX;
12670 int_fast64_t e4min = INT_FAST64_MIN;
12671 uint_fast8_t f1 = UINT_FAST8_MAX;
12672 uint_fast16_t f2 = UINT_FAST16_MAX;
12673 uint_fast32_t f3 = UINT_FAST32_MAX;
12674 uint_fast64_t f4 = UINT_FAST64_MAX;
12676 intptr_t g = INTPTR_MAX;
12677 intptr_t gmin = INTPTR_MIN;
12680 uintptr_t h = UINTPTR_MAX;
12682 intmax_t i = INTMAX_MAX;
12683 uintmax_t j = UINTMAX_MAX;
12685 #include <limits.h> /* for CHAR_BIT */
12686 #define TYPE_MINIMUM(t) \
12687 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
12688 #define TYPE_MAXIMUM(t) \
12689 ((t) ((t) 0 < (t) -1 \
12691 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
12694 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
12695 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
12697 /* Detect bug in FreeBSD 6.0 / ia64. */
12698 int check_SIG_ATOMIC:
12699 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
12700 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
12702 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
12704 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
12705 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
12707 /* Detect bug in mingw. */
12709 WINT_MIN == TYPE_MINIMUM (wint_t)
12710 && WINT_MAX == TYPE_MAXIMUM (wint_t)
12713 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
12715 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
12716 int check_UINT16_C:
12717 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
12719 /* Detect bugs in OpenBSD 3.9 stdint.h. */
12721 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
12724 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
12727 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
12730 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
12732 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
12733 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
12734 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
12735 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
12736 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
12737 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
12738 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
12739 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
12740 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
12741 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
12742 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
12753 if ac_fn_c_try_compile "$LINENO"; then :
12754 if test "$cross_compiling" = yes; then :
12755 gl_cv_header_working_stdint_h=yes
12758 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12759 /* end confdefs.h. */
12762 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
12763 #include <stdint.h>
12766 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
12767 included before <wchar.h>. */
12768 #include <stddef.h>
12769 #include <signal.h>
12771 # include <stdio.h>
12773 # include <wchar.h>
12778 #include <string.h>
12779 #define MVAL(macro) MVAL1(macro)
12780 #define MVAL1(expression) #expression
12781 static const char *macro_values[] =
12815 for (mv = macro_values; *mv != NULL; mv++)
12817 const char *value = *mv;
12818 /* Test whether it looks like a cast expression. */
12819 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
12820 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
12821 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
12822 || strncmp (value, "((int)"/*)*/, 6) == 0
12823 || strncmp (value, "((signed short)"/*)*/, 15) == 0
12824 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
12825 return mv - macro_values + 1;
12833 if ac_fn_c_try_run "$LINENO"; then :
12834 gl_cv_header_working_stdint_h=yes
12836 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12837 conftest.$ac_objext conftest.beam conftest.$ac_ext
12842 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
12846 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
12848 if test "$gl_cv_header_working_stdint_h" = yes; then
12851 for ac_header in sys/inttypes.h sys/bitypes.h
12853 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12854 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12855 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
12856 cat >>confdefs.h <<_ACEOF
12857 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12864 if test $ac_cv_header_sys_inttypes_h = yes; then
12865 HAVE_SYS_INTTYPES_H=1
12867 HAVE_SYS_INTTYPES_H=0
12870 if test $ac_cv_header_sys_bitypes_h = yes; then
12871 HAVE_SYS_BITYPES_H=1
12873 HAVE_SYS_BITYPES_H=0
12879 if test $APPLE_UNIVERSAL_BUILD = 0; then
12882 for gltype in ptrdiff_t size_t ; do
12883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
12884 $as_echo_n "checking for bit size of $gltype... " >&6; }
12885 if eval \${gl_cv_bitsizeof_${gltype}+:} false; then :
12886 $as_echo_n "(cached) " >&6
12888 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
12889 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
12890 included before <wchar.h>. */
12891 #include <stddef.h>
12892 #include <signal.h>
12894 # include <stdio.h>
12896 # include <wchar.h>
12899 #include <limits.h>"; then :
12905 eval gl_cv_bitsizeof_${gltype}=\$result
12908 eval ac_res=\$gl_cv_bitsizeof_${gltype}
12909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
12910 $as_echo "$ac_res" >&6; }
12911 eval result=\$gl_cv_bitsizeof_${gltype}
12912 if test $result = unknown; then
12915 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
12916 cat >>confdefs.h <<_ACEOF
12917 #define BITSIZEOF_${GLTYPE} $result
12920 eval BITSIZEOF_${GLTYPE}=\$result
12927 for gltype in sig_atomic_t wchar_t wint_t ; do
12928 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
12929 $as_echo_n "checking for bit size of $gltype... " >&6; }
12930 if eval \${gl_cv_bitsizeof_${gltype}+:} false; then :
12931 $as_echo_n "(cached) " >&6
12933 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
12934 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
12935 included before <wchar.h>. */
12936 #include <stddef.h>
12937 #include <signal.h>
12939 # include <stdio.h>
12941 # include <wchar.h>
12944 #include <limits.h>"; then :
12950 eval gl_cv_bitsizeof_${gltype}=\$result
12953 eval ac_res=\$gl_cv_bitsizeof_${gltype}
12954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
12955 $as_echo "$ac_res" >&6; }
12956 eval result=\$gl_cv_bitsizeof_${gltype}
12957 if test $result = unknown; then
12960 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
12961 cat >>confdefs.h <<_ACEOF
12962 #define BITSIZEOF_${GLTYPE} $result
12965 eval BITSIZEOF_${GLTYPE}=\$result
12971 for gltype in sig_atomic_t wchar_t wint_t ; do
12972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
12973 $as_echo_n "checking whether $gltype is signed... " >&6; }
12974 if eval \${gl_cv_type_${gltype}_signed+:} false; then :
12975 $as_echo_n "(cached) " >&6
12977 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12978 /* end confdefs.h. */
12980 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
12981 included before <wchar.h>. */
12982 #include <stddef.h>
12983 #include <signal.h>
12985 # include <stdio.h>
12987 # include <wchar.h>
12990 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
12999 if ac_fn_c_try_compile "$LINENO"; then :
13004 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13005 eval gl_cv_type_${gltype}_signed=\$result
13008 eval ac_res=\$gl_cv_type_${gltype}_signed
13009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
13010 $as_echo "$ac_res" >&6; }
13011 eval result=\$gl_cv_type_${gltype}_signed
13012 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
13013 if test "$result" = yes; then
13014 cat >>confdefs.h <<_ACEOF
13015 #define HAVE_SIGNED_${GLTYPE} 1
13018 eval HAVE_SIGNED_${GLTYPE}=1
13020 eval HAVE_SIGNED_${GLTYPE}=0
13025 gl_cv_type_ptrdiff_t_signed=yes
13026 gl_cv_type_size_t_signed=no
13027 if test $APPLE_UNIVERSAL_BUILD = 0; then
13030 for gltype in ptrdiff_t size_t ; do
13031 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
13032 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
13033 if eval \${gl_cv_type_${gltype}_suffix+:} false; then :
13034 $as_echo_n "(cached) " >&6
13036 eval gl_cv_type_${gltype}_suffix=no
13037 eval result=\$gl_cv_type_${gltype}_signed
13038 if test "$result" = yes; then
13043 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
13045 '') gltype1='int';;
13046 l) gltype1='long int';;
13047 ll) gltype1='long long int';;
13048 i64) gltype1='__int64';;
13049 u) gltype1='unsigned int';;
13050 ul) gltype1='unsigned long int';;
13051 ull) gltype1='unsigned long long int';;
13052 ui64)gltype1='unsigned __int64';;
13054 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13055 /* end confdefs.h. */
13057 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
13058 included before <wchar.h>. */
13059 #include <stddef.h>
13060 #include <signal.h>
13062 # include <stdio.h>
13064 # include <wchar.h>
13067 extern $gltype foo;
13068 extern $gltype1 foo;
13077 if ac_fn_c_try_compile "$LINENO"; then :
13078 eval gl_cv_type_${gltype}_suffix=\$glsuf
13080 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13081 eval result=\$gl_cv_type_${gltype}_suffix
13082 test "$result" != no && break
13085 eval ac_res=\$gl_cv_type_${gltype}_suffix
13086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
13087 $as_echo "$ac_res" >&6; }
13088 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
13089 eval result=\$gl_cv_type_${gltype}_suffix
13090 test "$result" = no && result=
13091 eval ${GLTYPE}_SUFFIX=\$result
13092 cat >>confdefs.h <<_ACEOF
13093 #define ${GLTYPE}_SUFFIX $result
13102 for gltype in sig_atomic_t wchar_t wint_t ; do
13103 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
13104 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
13105 if eval \${gl_cv_type_${gltype}_suffix+:} false; then :
13106 $as_echo_n "(cached) " >&6
13108 eval gl_cv_type_${gltype}_suffix=no
13109 eval result=\$gl_cv_type_${gltype}_signed
13110 if test "$result" = yes; then
13115 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
13117 '') gltype1='int';;
13118 l) gltype1='long int';;
13119 ll) gltype1='long long int';;
13120 i64) gltype1='__int64';;
13121 u) gltype1='unsigned int';;
13122 ul) gltype1='unsigned long int';;
13123 ull) gltype1='unsigned long long int';;
13124 ui64)gltype1='unsigned __int64';;
13126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13127 /* end confdefs.h. */
13129 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
13130 included before <wchar.h>. */
13131 #include <stddef.h>
13132 #include <signal.h>
13134 # include <stdio.h>
13136 # include <wchar.h>
13139 extern $gltype foo;
13140 extern $gltype1 foo;
13149 if ac_fn_c_try_compile "$LINENO"; then :
13150 eval gl_cv_type_${gltype}_suffix=\$glsuf
13152 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13153 eval result=\$gl_cv_type_${gltype}_suffix
13154 test "$result" != no && break
13157 eval ac_res=\$gl_cv_type_${gltype}_suffix
13158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
13159 $as_echo "$ac_res" >&6; }
13160 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
13161 eval result=\$gl_cv_type_${gltype}_suffix
13162 test "$result" = no && result=
13163 eval ${GLTYPE}_SUFFIX=\$result
13164 cat >>confdefs.h <<_ACEOF
13165 #define ${GLTYPE}_SUFFIX $result
13172 if test $BITSIZEOF_WINT_T -lt 32; then
13173 BITSIZEOF_WINT_T=32
13179 if test -n "$STDINT_H"; then
13180 GL_GENERATE_STDINT_H_TRUE=
13181 GL_GENERATE_STDINT_H_FALSE='#'
13183 GL_GENERATE_STDINT_H_TRUE='#'
13184 GL_GENERATE_STDINT_H_FALSE=
13193 GNULIB_STRTOIMAX=0;
13194 GNULIB_STRTOUMAX=0;
13195 HAVE_DECL_IMAXABS=1;
13196 HAVE_DECL_IMAXDIV=1;
13197 HAVE_DECL_STRTOIMAX=1;
13198 HAVE_DECL_STRTOUMAX=1;
13199 REPLACE_STRTOIMAX=0;
13200 INT32_MAX_LT_INTMAX_MAX=1;
13201 INT64_MAX_EQ_LONG_MAX='defined _LP64';
13202 PRI_MACROS_BROKEN=0;
13203 PRIPTR_PREFIX=__PRIPTR_PREFIX;
13204 UINT32_MAX_LT_UINTMAX_MAX=1;
13205 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
13221 if test $gl_cv_have_include_next = yes; then
13222 gl_cv_next_inttypes_h='<'inttypes.h'>'
13224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
13225 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
13226 if ${gl_cv_next_inttypes_h+:} false; then :
13227 $as_echo_n "(cached) " >&6
13230 if test $ac_cv_header_inttypes_h = yes; then
13233 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13234 /* end confdefs.h. */
13235 #include <inttypes.h>
13239 aix*) gl_absname_cpp="$ac_cpp -C" ;;
13240 *) gl_absname_cpp="$ac_cpp" ;;
13245 gl_dirsep_regex='[/\\]'
13248 gl_dirsep_regex='\/'
13251 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
13253 gl_header_literal_regex=`echo 'inttypes.h' \
13254 | sed -e "$gl_make_literal_regex_sed"`
13255 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
13256 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
13261 gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
13262 sed -n "$gl_absolute_header_sed"`'"'
13264 gl_cv_next_inttypes_h='<'inttypes.h'>'
13269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
13270 $as_echo "$gl_cv_next_inttypes_h" >&6; }
13272 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
13274 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
13275 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
13276 gl_next_as_first_directive='<'inttypes.h'>'
13278 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
13279 gl_next_as_first_directive=$gl_cv_next_inttypes_h
13281 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
13290 for gl_func in imaxabs imaxdiv strtoimax strtoumax; do
13291 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
13292 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
13293 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
13294 if eval \${$as_gl_Symbol+:} false; then :
13295 $as_echo_n "(cached) " >&6
13297 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13298 /* end confdefs.h. */
13299 #include <inttypes.h>
13310 if ac_fn_c_try_compile "$LINENO"; then :
13311 eval "$as_gl_Symbol=yes"
13313 eval "$as_gl_Symbol=no"
13315 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13317 eval ac_res=\$$as_gl_Symbol
13318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
13319 $as_echo "$ac_res" >&6; }
13320 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
13321 cat >>confdefs.h <<_ACEOF
13322 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
13325 eval ac_cv_have_decl_$gl_func=yes
13331 for ac_header in inttypes.h
13333 ac_fn_c_check_header_mongrel "$LINENO" "inttypes.h" "ac_cv_header_inttypes_h" "$ac_includes_default"
13334 if test "x$ac_cv_header_inttypes_h" = xyes; then :
13335 cat >>confdefs.h <<_ACEOF
13336 #define HAVE_INTTYPES_H 1
13343 if test $ac_cv_header_inttypes_h = yes; then
13344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the inttypes.h PRIxNN macros are broken" >&5
13345 $as_echo_n "checking whether the inttypes.h PRIxNN macros are broken... " >&6; }
13346 if ${gt_cv_inttypes_pri_broken+:} false; then :
13347 $as_echo_n "(cached) " >&6
13350 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13351 /* end confdefs.h. */
13353 #include <inttypes.h>
13366 if ac_fn_c_try_compile "$LINENO"; then :
13367 gt_cv_inttypes_pri_broken=no
13369 gt_cv_inttypes_pri_broken=yes
13371 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_inttypes_pri_broken" >&5
13375 $as_echo "$gt_cv_inttypes_pri_broken" >&6; }
13377 if test "$gt_cv_inttypes_pri_broken" = yes; then
13379 cat >>confdefs.h <<_ACEOF
13380 #define PRI_MACROS_BROKEN 1
13383 PRI_MACROS_BROKEN=1
13385 PRI_MACROS_BROKEN=0
13394 GNULIB_TOWCTRANS=0;
13398 REPLACE_ISWBLANK=0;
13403 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wint_t" >&5
13404 $as_echo_n "checking for wint_t... " >&6; }
13405 if ${gt_cv_c_wint_t+:} false; then :
13406 $as_echo_n "(cached) " >&6
13408 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13409 /* end confdefs.h. */
13411 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
13413 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
13414 before <wchar.h>. */
13415 #include <stddef.h>
13419 wint_t foo = (wchar_t)'\0';
13428 if ac_fn_c_try_compile "$LINENO"; then :
13433 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wint_t" >&5
13436 $as_echo "$gt_cv_c_wint_t" >&6; }
13437 if test $gt_cv_c_wint_t = yes; then
13439 $as_echo "#define HAVE_WINT_T 1" >>confdefs.h
13448 if test $ac_cv_func_iswcntrl = yes; then
13456 if test $gt_cv_c_wint_t = yes; then
13472 if test $gl_cv_have_include_next = yes; then
13473 gl_cv_next_wctype_h='<'wctype.h'>'
13475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <wctype.h>" >&5
13476 $as_echo_n "checking absolute name of <wctype.h>... " >&6; }
13477 if ${gl_cv_next_wctype_h+:} false; then :
13478 $as_echo_n "(cached) " >&6
13481 if test $ac_cv_header_wctype_h = yes; then
13484 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13485 /* end confdefs.h. */
13486 #include <wctype.h>
13490 aix*) gl_absname_cpp="$ac_cpp -C" ;;
13491 *) gl_absname_cpp="$ac_cpp" ;;
13496 gl_dirsep_regex='[/\\]'
13499 gl_dirsep_regex='\/'
13502 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
13504 gl_header_literal_regex=`echo 'wctype.h' \
13505 | sed -e "$gl_make_literal_regex_sed"`
13506 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
13507 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
13512 gl_cv_next_wctype_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
13513 sed -n "$gl_absolute_header_sed"`'"'
13515 gl_cv_next_wctype_h='<'wctype.h'>'
13520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wctype_h" >&5
13521 $as_echo "$gl_cv_next_wctype_h" >&6; }
13523 NEXT_WCTYPE_H=$gl_cv_next_wctype_h
13525 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
13526 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
13527 gl_next_as_first_directive='<'wctype.h'>'
13529 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
13530 gl_next_as_first_directive=$gl_cv_next_wctype_h
13532 NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H=$gl_next_as_first_directive
13537 if test $ac_cv_header_wctype_h = yes; then
13538 if test $ac_cv_func_iswcntrl = yes; then
13539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether iswcntrl works" >&5
13540 $as_echo_n "checking whether iswcntrl works... " >&6; }
13541 if ${gl_cv_func_iswcntrl_works+:} false; then :
13542 $as_echo_n "(cached) " >&6
13545 if test "$cross_compiling" = yes; then :
13546 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13547 /* end confdefs.h. */
13548 #include <stdlib.h>
13549 #if __GNU_LIBRARY__ == 1
13550 Linux libc5 i18n is broken.
13560 if ac_fn_c_try_compile "$LINENO"; then :
13561 gl_cv_func_iswcntrl_works="guessing yes"
13563 gl_cv_func_iswcntrl_works="guessing no"
13565 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13568 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13569 /* end confdefs.h. */
13571 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
13572 included before <wchar.h>.
13573 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
13574 must be included before <wchar.h>. */
13575 #include <stddef.h>
13579 #include <wctype.h>
13580 int main () { return iswprint ('x') == 0; }
13583 if ac_fn_c_try_run "$LINENO"; then :
13584 gl_cv_func_iswcntrl_works=yes
13586 gl_cv_func_iswcntrl_works=no
13588 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13589 conftest.$ac_objext conftest.beam conftest.$ac_ext
13594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_iswcntrl_works" >&5
13595 $as_echo "$gl_cv_func_iswcntrl_works" >&6; }
13603 case "$gl_cv_func_iswcntrl_works" in
13604 *yes) REPLACE_ISWCNTRL=0 ;;
13605 *) REPLACE_ISWCNTRL=1 ;;
13609 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_ISWCNTRL = 1; then
13613 if test $REPLACE_ISWCNTRL = 1; then
13616 for ac_func in towlower
13618 ac_fn_c_check_func "$LINENO" "towlower" "ac_cv_func_towlower"
13619 if test "x$ac_cv_func_towlower" = xyes; then :
13620 cat >>confdefs.h <<_ACEOF
13621 #define HAVE_TOWLOWER 1
13627 if test $ac_cv_func_towlower = yes; then
13630 ac_fn_c_check_decl "$LINENO" "towlower" "ac_cv_have_decl_towlower" "/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
13631 included before <wchar.h>.
13632 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
13633 must be included before <wchar.h>. */
13634 #include <stddef.h>
13639 # include <wctype.h>
13643 if test "x$ac_cv_have_decl_towlower" = xyes; then :
13649 cat >>confdefs.h <<_ACEOF
13650 #define HAVE_DECL_TOWLOWER $ac_have_decl
13653 if test $ac_cv_have_decl_towlower = yes; then
13662 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_TOWLOWER = 1; then
13666 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctype_t" >&5
13667 $as_echo_n "checking for wctype_t... " >&6; }
13668 if ${gl_cv_type_wctype_t+:} false; then :
13669 $as_echo_n "(cached) " >&6
13671 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13672 /* end confdefs.h. */
13673 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
13674 included before <wchar.h>.
13675 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
13676 must be included before <wchar.h>. */
13677 #include <stddef.h>
13682 # include <wctype.h>
13694 if ac_fn_c_try_compile "$LINENO"; then :
13695 gl_cv_type_wctype_t=yes
13697 gl_cv_type_wctype_t=no
13699 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctype_t" >&5
13703 $as_echo "$gl_cv_type_wctype_t" >&6; }
13704 if test $gl_cv_type_wctype_t = no; then
13708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctrans_t" >&5
13709 $as_echo_n "checking for wctrans_t... " >&6; }
13710 if ${gl_cv_type_wctrans_t+:} false; then :
13711 $as_echo_n "(cached) " >&6
13713 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13714 /* end confdefs.h. */
13715 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
13716 included before <wchar.h>.
13717 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
13718 must be included before <wchar.h>. */
13719 #include <stddef.h>
13723 #include <wctype.h>
13734 if ac_fn_c_try_compile "$LINENO"; then :
13735 gl_cv_type_wctrans_t=yes
13737 gl_cv_type_wctrans_t=no
13739 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctrans_t" >&5
13743 $as_echo "$gl_cv_type_wctrans_t" >&6; }
13744 if test $gl_cv_type_wctrans_t = no; then
13749 for gl_func in wctype iswctype wctrans towctrans ; do
13750 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
13751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
13752 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
13753 if eval \${$as_gl_Symbol+:} false; then :
13754 $as_echo_n "(cached) " >&6
13756 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13757 /* end confdefs.h. */
13759 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
13761 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
13762 included before <wchar.h>. */
13763 #if !(defined __GLIBC__ && !defined __UCLIBC__)
13764 # include <stddef.h>
13765 # include <stdio.h>
13767 # include <wchar.h>
13769 #include <wctype.h>
13780 if ac_fn_c_try_compile "$LINENO"; then :
13781 eval "$as_gl_Symbol=yes"
13783 eval "$as_gl_Symbol=no"
13785 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13787 eval ac_res=\$$as_gl_Symbol
13788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
13789 $as_echo "$ac_res" >&6; }
13790 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
13791 cat >>confdefs.h <<_ACEOF
13792 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
13795 eval ac_cv_have_decl_$gl_func=yes
13803 GNULIB_NL_LANGINFO=0;
13804 HAVE_NL_LANGINFO=1;
13805 REPLACE_NL_LANGINFO=0;
13818 case $ac_cv_func_openat+$gl_cv_func_lstat_dereferences_slashed_symlink in
13822 # Solaris 9 has *at functions, but uniformly mishandles trailing
13823 # slash in all of them.
13834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C Library >= 2.1 or uClibc" >&5
13835 $as_echo_n "checking whether we are using the GNU C Library >= 2.1 or uClibc... " >&6; }
13836 if ${ac_cv_gnu_library_2_1+:} false; then :
13837 $as_echo_n "(cached) " >&6
13839 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13840 /* end confdefs.h. */
13842 #include <features.h>
13843 #ifdef __GNU_LIBRARY__
13844 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)
13853 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13854 $EGREP "Lucky" >/dev/null 2>&1; then :
13855 ac_cv_gnu_library_2_1=yes
13857 ac_cv_gnu_library_2_1=no
13864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gnu_library_2_1" >&5
13865 $as_echo "$ac_cv_gnu_library_2_1" >&6; }
13867 GLIBC21="$ac_cv_gnu_library_2_1"
13871 GNULIB_LOCALECONV=0;
13872 GNULIB_SETLOCALE=0;
13873 GNULIB_DUPLOCALE=0;
13875 REPLACE_LOCALECONV=0;
13876 REPLACE_SETLOCALE=0;
13877 REPLACE_DUPLOCALE=0;
13878 REPLACE_STRUCT_LCONV=0;
13885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
13886 $as_echo_n "checking for wchar_t... " >&6; }
13887 if ${gt_cv_c_wchar_t+:} false; then :
13888 $as_echo_n "(cached) " >&6
13890 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13891 /* end confdefs.h. */
13892 #include <stddef.h>
13893 wchar_t foo = (wchar_t)'\0';
13902 if ac_fn_c_try_compile "$LINENO"; then :
13903 gt_cv_c_wchar_t=yes
13907 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
13910 $as_echo "$gt_cv_c_wchar_t" >&6; }
13911 if test $gt_cv_c_wchar_t = yes; then
13913 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
13921 if test $gt_cv_c_wchar_t = no; then
13925 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
13926 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
13927 if ${gl_cv_decl_null_works+:} false; then :
13928 $as_echo_n "(cached) " >&6
13930 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13931 /* end confdefs.h. */
13932 #include <stddef.h>
13933 int test[2 * (sizeof NULL == sizeof (void *)) -1];
13943 if ac_fn_c_try_compile "$LINENO"; then :
13944 gl_cv_decl_null_works=yes
13946 gl_cv_decl_null_works=no
13948 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
13951 $as_echo "$gl_cv_decl_null_works" >&6; }
13952 if test $gl_cv_decl_null_works = no; then
13957 if test -n "$STDDEF_H"; then
13958 GL_GENERATE_STDDEF_H_TRUE=
13959 GL_GENERATE_STDDEF_H_FALSE='#'
13961 GL_GENERATE_STDDEF_H_TRUE='#'
13962 GL_GENERATE_STDDEF_H_FALSE=
13965 if test -n "$STDDEF_H"; then
13974 if test $gl_cv_have_include_next = yes; then
13975 gl_cv_next_stddef_h='<'stddef.h'>'
13977 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
13978 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
13979 if ${gl_cv_next_stddef_h+:} false; then :
13980 $as_echo_n "(cached) " >&6
13983 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13984 /* end confdefs.h. */
13985 #include <stddef.h>
13989 aix*) gl_absname_cpp="$ac_cpp -C" ;;
13990 *) gl_absname_cpp="$ac_cpp" ;;
13995 gl_dirsep_regex='[/\\]'
13998 gl_dirsep_regex='\/'
14001 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
14003 gl_header_literal_regex=`echo 'stddef.h' \
14004 | sed -e "$gl_make_literal_regex_sed"`
14005 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
14006 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
14011 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
14012 sed -n "$gl_absolute_header_sed"`'"'
14016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
14017 $as_echo "$gl_cv_next_stddef_h" >&6; }
14019 NEXT_STDDEF_H=$gl_cv_next_stddef_h
14021 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
14022 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
14023 gl_next_as_first_directive='<'stddef.h'>'
14025 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
14026 gl_next_as_first_directive=$gl_cv_next_stddef_h
14028 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
14040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc, realloc, calloc are POSIX compliant" >&5
14041 $as_echo_n "checking whether malloc, realloc, calloc are POSIX compliant... " >&6; }
14042 if ${gl_cv_func_malloc_posix+:} false; then :
14043 $as_echo_n "(cached) " >&6
14046 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14047 /* end confdefs.h. */
14052 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
14060 if ac_fn_c_try_compile "$LINENO"; then :
14061 gl_cv_func_malloc_posix=yes
14063 gl_cv_func_malloc_posix=no
14065 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_malloc_posix" >&5
14069 $as_echo "$gl_cv_func_malloc_posix" >&6; }
14073 for ac_header in stdlib.h
14075 ac_fn_c_check_header_mongrel "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default"
14076 if test "x$ac_cv_header_stdlib_h" = xyes; then :
14077 cat >>confdefs.h <<_ACEOF
14078 #define HAVE_STDLIB_H 1
14085 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5
14086 $as_echo_n "checking for GNU libc compatible malloc... " >&6; }
14087 if ${ac_cv_func_malloc_0_nonnull+:} false; then :
14088 $as_echo_n "(cached) " >&6
14090 if test "$cross_compiling" = yes; then :
14092 # Guess yes on platforms where we know the result.
14093 *-gnu* | freebsd* | netbsd* | openbsd* \
14094 | hpux* | solaris* | cygwin* | mingw*)
14095 ac_cv_func_malloc_0_nonnull=yes ;;
14096 # If we don't know, assume the worst.
14097 *) ac_cv_func_malloc_0_nonnull=no ;;
14101 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14102 /* end confdefs.h. */
14103 #if defined STDC_HEADERS || defined HAVE_STDLIB_H
14104 # include <stdlib.h>
14112 return ! malloc (0);
14118 if ac_fn_c_try_run "$LINENO"; then :
14119 ac_cv_func_malloc_0_nonnull=yes
14121 ac_cv_func_malloc_0_nonnull=no
14123 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14124 conftest.$ac_objext conftest.beam conftest.$ac_ext
14129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_malloc_0_nonnull" >&5
14130 $as_echo "$ac_cv_func_malloc_0_nonnull" >&6; }
14131 if test $ac_cv_func_malloc_0_nonnull = yes; then :
14132 gl_cv_func_malloc_0_nonnull=1
14134 gl_cv_func_malloc_0_nonnull=0
14138 cat >>confdefs.h <<_ACEOF
14139 #define MALLOC_0_IS_NONNULL $gl_cv_func_malloc_0_nonnull
14150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional japanese locale" >&5
14151 $as_echo_n "checking for a traditional japanese locale... " >&6; }
14152 if ${gt_cv_locale_ja+:} false; then :
14153 $as_echo_n "(cached) " >&6
14156 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14157 /* end confdefs.h. */
14159 #include <locale.h>
14161 #if HAVE_LANGINFO_CODESET
14162 # include <langinfo.h>
14164 #include <stdlib.h>
14165 #include <string.h>
14171 /* Check whether the given locale name is recognized by the system. */
14172 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
14173 /* On native Windows, setlocale(category, "") looks at the system settings,
14174 not at the environment variables. Also, when an encoding suffix such
14175 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
14176 category of the locale to "C". */
14177 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
14178 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
14181 if (setlocale (LC_ALL, "") == NULL) return 1;
14183 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
14184 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
14185 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
14186 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
14187 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
14188 some unit tests fail.
14189 On MirBSD 10, when an unsupported locale is specified, setlocale()
14190 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
14191 #if HAVE_LANGINFO_CODESET
14193 const char *cs = nl_langinfo (CODESET);
14194 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
14195 || strcmp (cs, "UTF-8") == 0)
14200 /* On Cygwin, avoid locale names without encoding suffix, because the
14201 locale_charset() function relies on the encoding suffix. Note that
14202 LC_ALL is set on the command line. */
14203 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
14205 /* Check whether MB_CUR_MAX is > 1. This excludes the dysfunctional locales
14206 on Cygwin 1.5.x. */
14207 if (MB_CUR_MAX == 1)
14209 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
14210 This excludes the UTF-8 encoding (except on MirBSD). */
14211 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
14212 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
14213 for (p = buf; *p != '\0'; p++)
14214 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
14220 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
14221 (eval $ac_link) 2>&5
14223 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14224 test $ac_status = 0; } && test -s conftest$ac_exeext; then
14226 # Handle native Windows specially, because there setlocale() interprets
14227 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
14228 # "fr" or "fra" as "French" or "French_France.1252",
14229 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
14230 # "ja" as "Japanese" or "Japanese_Japan.932",
14233 # Note that on native Windows, the Japanese locale is
14234 # Japanese_Japan.932, and CP932 is very different from EUC-JP, so we
14235 # cannot use it here.
14236 gt_cv_locale_ja=none
14239 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
14240 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
14241 # configure script would override the LC_ALL setting. Likewise for
14242 # LC_CTYPE, which is also set at the beginning of the configure script.
14243 # Test for the AIX locale name.
14244 if (LC_ALL=ja_JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14245 gt_cv_locale_ja=ja_JP
14247 # Test for the locale name with explicit encoding suffix.
14248 if (LC_ALL=ja_JP.EUC-JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14249 gt_cv_locale_ja=ja_JP.EUC-JP
14251 # Test for the HP-UX, OSF/1, NetBSD locale name.
14252 if (LC_ALL=ja_JP.eucJP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14253 gt_cv_locale_ja=ja_JP.eucJP
14255 # Test for the IRIX, FreeBSD locale name.
14256 if (LC_ALL=ja_JP.EUC LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14257 gt_cv_locale_ja=ja_JP.EUC
14259 # Test for the Solaris 7 locale name.
14260 if (LC_ALL=ja LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14263 # Special test for NetBSD 1.6.
14264 if test -f /usr/share/locale/ja_JP.eucJP/LC_CTYPE; then
14265 gt_cv_locale_ja=ja_JP.eucJP
14268 gt_cv_locale_ja=none
14281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_ja" >&5
14282 $as_echo "$gt_cv_locale_ja" >&6; }
14283 LOCALE_JA=$gt_cv_locale_ja
14289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a transitional chinese locale" >&5
14290 $as_echo_n "checking for a transitional chinese locale... " >&6; }
14291 if ${gt_cv_locale_zh_CN+:} false; then :
14292 $as_echo_n "(cached) " >&6
14295 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14296 /* end confdefs.h. */
14298 #include <locale.h>
14299 #include <stdlib.h>
14301 #if HAVE_LANGINFO_CODESET
14302 # include <langinfo.h>
14304 #include <stdlib.h>
14305 #include <string.h>
14311 /* Check whether the given locale name is recognized by the system. */
14312 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
14313 /* On native Windows, setlocale(category, "") looks at the system settings,
14314 not at the environment variables. Also, when an encoding suffix such
14315 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
14316 category of the locale to "C". */
14317 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
14318 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
14321 if (setlocale (LC_ALL, "") == NULL) return 1;
14323 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
14324 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
14325 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
14326 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
14327 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
14328 some unit tests fail.
14329 On MirBSD 10, when an unsupported locale is specified, setlocale()
14330 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
14331 #if HAVE_LANGINFO_CODESET
14333 const char *cs = nl_langinfo (CODESET);
14334 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
14335 || strcmp (cs, "UTF-8") == 0)
14340 /* On Cygwin, avoid locale names without encoding suffix, because the
14341 locale_charset() function relies on the encoding suffix. Note that
14342 LC_ALL is set on the command line. */
14343 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
14345 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
14346 This excludes the UTF-8 encoding (except on MirBSD). */
14347 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
14348 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
14349 for (p = buf; *p != '\0'; p++)
14350 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
14352 /* Check whether a typical GB18030 multibyte sequence is recognized as a
14353 single wide character. This excludes the GB2312 and GBK encodings. */
14354 if (mblen ("\203\062\332\066", 5) != 4)
14360 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
14361 (eval $ac_link) 2>&5
14363 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14364 test $ac_status = 0; } && test -s conftest$ac_exeext; then
14366 # Handle native Windows specially, because there setlocale() interprets
14367 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
14368 # "fr" or "fra" as "French" or "French_France.1252",
14369 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
14370 # "ja" as "Japanese" or "Japanese_Japan.932",
14373 # Test for the hypothetical native Windows locale name.
14374 if (LC_ALL=Chinese_China.54936 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14375 gt_cv_locale_zh_CN=Chinese_China.54936
14378 gt_cv_locale_zh_CN=none
14382 # On Solaris 8, the locales zh_CN.GB18030, zh_CN.GBK, zh.GBK are
14383 # broken. One witness is the test case in gl_MBRTOWC_SANITYCHECK.
14384 # Another witness is that "LC_ALL=zh_CN.GB18030 bash -c true" dumps core.
14385 gt_cv_locale_zh_CN=none
14388 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
14389 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
14390 # configure script would override the LC_ALL setting. Likewise for
14391 # LC_CTYPE, which is also set at the beginning of the configure script.
14392 # Test for the locale name without encoding suffix.
14393 if (LC_ALL=zh_CN LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14394 gt_cv_locale_zh_CN=zh_CN
14396 # Test for the locale name with explicit encoding suffix.
14397 if (LC_ALL=zh_CN.GB18030 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14398 gt_cv_locale_zh_CN=zh_CN.GB18030
14401 gt_cv_locale_zh_CN=none
14407 # If there was a link error, due to mblen(), the system is so old that
14408 # it certainly doesn't have a chinese locale.
14409 gt_cv_locale_zh_CN=none
14414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_zh_CN" >&5
14415 $as_echo "$gt_cv_locale_zh_CN" >&6; }
14416 LOCALE_ZH_CN=$gt_cv_locale_zh_CN
14421 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
14422 $as_echo_n "checking for a french Unicode locale... " >&6; }
14423 if ${gt_cv_locale_fr_utf8+:} false; then :
14424 $as_echo_n "(cached) " >&6
14427 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14428 /* end confdefs.h. */
14430 #include <locale.h>
14432 #if HAVE_LANGINFO_CODESET
14433 # include <langinfo.h>
14435 #include <stdlib.h>
14436 #include <string.h>
14440 /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
14441 imitates locale dependent behaviour by looking at the environment
14442 variables, and all locales use the UTF-8 encoding. */
14443 #if !(defined __BEOS__ || defined __HAIKU__)
14444 /* Check whether the given locale name is recognized by the system. */
14445 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
14446 /* On native Windows, setlocale(category, "") looks at the system settings,
14447 not at the environment variables. Also, when an encoding suffix such
14448 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
14449 category of the locale to "C". */
14450 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
14451 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
14454 if (setlocale (LC_ALL, "") == NULL) return 1;
14456 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
14457 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
14458 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
14459 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
14460 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
14461 some unit tests fail. */
14462 # if HAVE_LANGINFO_CODESET
14464 const char *cs = nl_langinfo (CODESET);
14465 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
14470 /* On Cygwin, avoid locale names without encoding suffix, because the
14471 locale_charset() function relies on the encoding suffix. Note that
14472 LC_ALL is set on the command line. */
14473 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
14475 /* Check whether in the abbreviation of the second month, the second
14476 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
14477 two bytes long, with UTF-8 encoding. */
14478 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
14479 if (strftime (buf, sizeof (buf), "%b", &t) < 4
14480 || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
14483 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
14484 /* Check whether the decimal separator is a comma.
14485 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
14486 are nl_langinfo(RADIXCHAR) are both ".". */
14487 if (localeconv () ->decimal_point[0] != ',') return 1;
14493 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
14494 (eval $ac_link) 2>&5
14496 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14497 test $ac_status = 0; } && test -s conftest$ac_exeext; then
14499 # Handle native Windows specially, because there setlocale() interprets
14500 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
14501 # "fr" or "fra" as "French" or "French_France.1252",
14502 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
14503 # "ja" as "Japanese" or "Japanese_Japan.932",
14506 # Test for the hypothetical native Windows locale name.
14507 if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14508 gt_cv_locale_fr_utf8=French_France.65001
14511 gt_cv_locale_fr_utf8=none
14515 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
14516 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
14517 # configure script would override the LC_ALL setting. Likewise for
14518 # LC_CTYPE, which is also set at the beginning of the configure script.
14519 # Test for the usual locale name.
14520 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14521 gt_cv_locale_fr_utf8=fr_FR
14523 # Test for the locale name with explicit encoding suffix.
14524 if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14525 gt_cv_locale_fr_utf8=fr_FR.UTF-8
14527 # Test for the Solaris 7 locale name.
14528 if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14529 gt_cv_locale_fr_utf8=fr.UTF-8
14532 gt_cv_locale_fr_utf8=none
14542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
14543 $as_echo "$gt_cv_locale_fr_utf8" >&6; }
14544 LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
14554 GNULIB_RAWMEMCHR=0;
14557 GNULIB_STRCHRNUL=0;
14565 GNULIB_STRCASESTR=0;
14572 GNULIB_MBSCASECMP=0;
14573 GNULIB_MBSNCASECMP=0;
14574 GNULIB_MBSPCASECMP=0;
14575 GNULIB_MBSCASESTR=0;
14582 GNULIB_STRERROR_R=0;
14583 GNULIB_STRSIGNAL=0;
14584 GNULIB_STRVERSCMP=0;
14589 HAVE_DECL_MEMMEM=1;
14591 HAVE_DECL_MEMRCHR=1;
14596 HAVE_DECL_STRDUP=1;
14597 HAVE_DECL_STRNDUP=1;
14598 HAVE_DECL_STRNLEN=1;
14602 HAVE_DECL_STRTOK_R=1;
14603 HAVE_DECL_STRERROR_R=1;
14604 HAVE_DECL_STRSIGNAL=1;
14611 REPLACE_STRCASESTR=0;
14612 REPLACE_STRCHRNUL=0;
14613 REPLACE_STRERROR=0;
14614 REPLACE_STRERROR_R=0;
14618 REPLACE_STRSIGNAL=0;
14619 REPLACE_STRTOK_R=0;
14620 UNDEFINE_STRTOK_R=0;
14630 # Check for mmap(). Don't use AC_FUNC_MMAP, because it checks too much: it
14631 # fails on HP-UX 11, because MAP_FIXED mappings do not work. But this is
14632 # irrelevant for anonymous mappings.
14633 ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap"
14634 if test "x$ac_cv_func_mmap" = xyes; then :
14641 # Try to allow MAP_ANONYMOUS.
14642 gl_have_mmap_anonymous=no
14643 if test $gl_have_mmap = yes; then
14644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAP_ANONYMOUS" >&5
14645 $as_echo_n "checking for MAP_ANONYMOUS... " >&6; }
14646 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14647 /* end confdefs.h. */
14649 #include <sys/mman.h>
14650 #ifdef MAP_ANONYMOUS
14651 I cannot identify this map
14655 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14656 $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
14657 gl_have_mmap_anonymous=yes
14661 if test $gl_have_mmap_anonymous != yes; then
14662 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14663 /* end confdefs.h. */
14665 #include <sys/mman.h>
14667 I cannot identify this map
14671 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14672 $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
14674 $as_echo "#define MAP_ANONYMOUS MAP_ANON" >>confdefs.h
14676 gl_have_mmap_anonymous=yes
14681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_have_mmap_anonymous" >&5
14682 $as_echo "$gl_have_mmap_anonymous" >&6; }
14683 if test $gl_have_mmap_anonymous = yes; then
14685 $as_echo "#define HAVE_MAP_ANONYMOUS 1" >>confdefs.h
14695 if test $HAVE_MEMCHR = 1; then
14696 # Detect platform-specific bugs in some versions of glibc:
14697 # memchr should not dereference anything with length 0
14698 # http://bugzilla.redhat.com/499689
14699 # memchr should not dereference overestimated length after a match
14700 # http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=521737
14701 # http://sourceware.org/bugzilla/show_bug.cgi?id=10162
14702 # Assume that memchr works on platforms that lack mprotect.
14703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memchr works" >&5
14704 $as_echo_n "checking whether memchr works... " >&6; }
14705 if ${gl_cv_func_memchr_works+:} false; then :
14706 $as_echo_n "(cached) " >&6
14708 if test "$cross_compiling" = yes; then :
14709 gl_cv_func_memchr_works="guessing no"
14711 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14712 /* end confdefs.h. */
14714 #include <string.h>
14715 #if HAVE_SYS_MMAN_H
14716 # include <fcntl.h>
14717 # include <unistd.h>
14718 # include <sys/types.h>
14719 # include <sys/mman.h>
14721 # define MAP_FILE 0
14730 char *fence = NULL;
14731 #if HAVE_SYS_MMAN_H && HAVE_MPROTECT
14732 # if HAVE_MAP_ANONYMOUS
14733 const int flags = MAP_ANONYMOUS | MAP_PRIVATE;
14735 # else /* !HAVE_MAP_ANONYMOUS */
14736 const int flags = MAP_FILE | MAP_PRIVATE;
14737 int fd = open ("/dev/zero", O_RDONLY, 0666);
14741 int pagesize = getpagesize ();
14743 (char *) mmap (NULL, 2 * pagesize, PROT_READ | PROT_WRITE,
14745 if (two_pages != (char *)(-1)
14746 && mprotect (two_pages + pagesize, pagesize, PROT_NONE) == 0)
14747 fence = two_pages + pagesize;
14752 if (memchr (fence, 0, 0))
14754 strcpy (fence - 9, "12345678");
14755 if (memchr (fence - 9, 0, 79) != fence - 1)
14757 if (memchr (fence - 1, 0, 3) != fence - 1)
14766 if ac_fn_c_try_run "$LINENO"; then :
14767 gl_cv_func_memchr_works=yes
14769 gl_cv_func_memchr_works=no
14771 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14772 conftest.$ac_objext conftest.beam conftest.$ac_ext
14776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memchr_works" >&5
14777 $as_echo "$gl_cv_func_memchr_works" >&6; }
14778 if test "$gl_cv_func_memchr_works" != yes; then
14783 ac_fn_c_check_decl "$LINENO" "memrchr" "ac_cv_have_decl_memrchr" "$ac_includes_default"
14784 if test "x$ac_cv_have_decl_memrchr" = xyes; then :
14790 cat >>confdefs.h <<_ACEOF
14791 #define HAVE_DECL_MEMRCHR $ac_have_decl
14806 GNULIB_NANOSLEEP=0;
14810 HAVE_DECL_LOCALTIME_R=1;
14814 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
14815 REPLACE_MKTIME=GNULIB_PORTCHECK;
14816 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
14817 REPLACE_TIMEGM=GNULIB_PORTCHECK;
14819 ac_fn_c_check_decl "$LINENO" "alarm" "ac_cv_have_decl_alarm" "$ac_includes_default"
14820 if test "x$ac_cv_have_decl_alarm" = xyes; then :
14826 cat >>confdefs.h <<_ACEOF
14827 #define HAVE_DECL_ALARM $ac_have_decl
14834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for promoted mode_t type" >&5
14835 $as_echo_n "checking for promoted mode_t type... " >&6; }
14836 if ${gl_cv_promoted_mode_t+:} false; then :
14837 $as_echo_n "(cached) " >&6
14840 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14841 /* end confdefs.h. */
14842 #include <sys/types.h>
14846 typedef int array[2 * (sizeof (mode_t) < sizeof (int)) - 1];
14851 if ac_fn_c_try_compile "$LINENO"; then :
14852 gl_cv_promoted_mode_t='int'
14854 gl_cv_promoted_mode_t='mode_t'
14856 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_promoted_mode_t" >&5
14860 $as_echo "$gl_cv_promoted_mode_t" >&6; }
14862 cat >>confdefs.h <<_ACEOF
14863 #define PROMOTED_MODE_T $gl_cv_promoted_mode_t
14867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
14868 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
14869 if ${ac_cv_header_stdbool_h+:} false; then :
14870 $as_echo_n "(cached) " >&6
14872 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14873 /* end confdefs.h. */
14875 #include <stdbool.h>
14877 "error: bool is not defined"
14880 "error: false is not defined"
14883 "error: false is not 0"
14886 "error: true is not defined"
14889 "error: true is not 1"
14891 #ifndef __bool_true_false_are_defined
14892 "error: __bool_true_false_are_defined is not defined"
14895 struct s { _Bool s: 1; _Bool t; } s;
14897 char a[true == 1 ? 1 : -1];
14898 char b[false == 0 ? 1 : -1];
14899 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
14900 char d[(bool) 0.5 == true ? 1 : -1];
14901 /* See body of main program for 'e'. */
14902 char f[(_Bool) 0.0 == false ? 1 : -1];
14904 char h[sizeof (_Bool)];
14905 char i[sizeof s.t];
14906 enum { j = false, k = true, l = false * true, m = true * 256 };
14907 /* The following fails for
14908 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
14910 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
14911 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
14912 /* Catch a bug in an HP-UX C compiler. See
14913 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
14914 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
14926 /* Refer to every declared value, to avoid compiler optimizations. */
14927 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
14928 + !m + !n + !o + !p + !q + !pq);
14934 if ac_fn_c_try_compile "$LINENO"; then :
14935 ac_cv_header_stdbool_h=yes
14937 ac_cv_header_stdbool_h=no
14939 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
14942 $as_echo "$ac_cv_header_stdbool_h" >&6; }
14943 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
14944 if test "x$ac_cv_type__Bool" = xyes; then :
14946 cat >>confdefs.h <<_ACEOF
14947 #define HAVE__BOOL 1
14957 # Define two additional variables used in the Makefile substitution.
14959 if test "$ac_cv_header_stdbool_h" = yes; then
14962 STDBOOL_H='stdbool.h'
14965 if test -n "$STDBOOL_H"; then
14966 GL_GENERATE_STDBOOL_H_TRUE=
14967 GL_GENERATE_STDBOOL_H_FALSE='#'
14969 GL_GENERATE_STDBOOL_H_TRUE='#'
14970 GL_GENERATE_STDBOOL_H_FALSE=
14974 if test "$ac_cv_type__Bool" = yes; then
14982 # parse-datetime.y works with bison only.
14983 : ${YACC='bison -y'}
14986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compound literals" >&5
14987 $as_echo_n "checking for compound literals... " >&6; }
14988 if ${gl_cv_compound_literals+:} false; then :
14989 $as_echo_n "(cached) " >&6
14991 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14992 /* end confdefs.h. */
14993 struct s { int i, j; };
14997 struct s t = (struct s) { 3, 4 };
14998 if (t.i != 0) return 0;
15003 if ac_fn_c_try_compile "$LINENO"; then :
15004 gl_cv_compound_literals=yes
15006 gl_cv_compound_literals=no
15008 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_compound_literals" >&5
15011 $as_echo "$gl_cv_compound_literals" >&6; }
15012 if test $gl_cv_compound_literals = yes; then
15014 $as_echo "#define HAVE_COMPOUND_LITERALS 1" >>confdefs.h
15018 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
15019 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
15020 if ${ac_cv_struct_tm+:} false; then :
15021 $as_echo_n "(cached) " >&6
15023 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15024 /* end confdefs.h. */
15025 #include <sys/types.h>
15032 int *p = &tm.tm_sec;
15038 if ac_fn_c_try_compile "$LINENO"; then :
15039 ac_cv_struct_tm=time.h
15041 ac_cv_struct_tm=sys/time.h
15043 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
15046 $as_echo "$ac_cv_struct_tm" >&6; }
15047 if test $ac_cv_struct_tm = sys/time.h; then
15049 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
15054 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
15056 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = xyes; then :
15058 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
15066 GNULIB_PTHREAD_SIGMASK=0;
15068 GNULIB_SIGNAL_H_SIGPIPE=0;
15069 GNULIB_SIGPROCMASK=0;
15070 GNULIB_SIGACTION=0;
15071 HAVE_POSIX_SIGNALBLOCKING=1;
15072 HAVE_PTHREAD_SIGMASK=1;
15077 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
15079 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
15081 HAVE_SIGHANDLER_T=1;
15082 REPLACE_PTHREAD_SIGMASK=0;
15096 # Check whether --with-selinux was given.
15097 if test "${with_selinux+set}" = set; then :
15098 withval=$with_selinux;
15105 if test "$with_selinux" != no; then
15107 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setfilecon" >&5
15108 $as_echo_n "checking for library containing setfilecon... " >&6; }
15109 if ${ac_cv_search_setfilecon+:} false; then :
15110 $as_echo_n "(cached) " >&6
15112 ac_func_search_save_LIBS=$LIBS
15113 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15114 /* end confdefs.h. */
15116 /* Override any GCC internal prototype to avoid an error.
15117 Use char because int might match the return type of a GCC
15118 builtin and then its argument prototype would still apply. */
15122 char setfilecon ();
15126 return setfilecon ();
15131 for ac_lib in '' selinux; do
15132 if test -z "$ac_lib"; then
15133 ac_res="none required"
15136 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
15138 if ac_fn_c_try_link "$LINENO"; then :
15139 ac_cv_search_setfilecon=$ac_res
15141 rm -f core conftest.err conftest.$ac_objext \
15143 if ${ac_cv_search_setfilecon+:} false; then :
15147 if ${ac_cv_search_setfilecon+:} false; then :
15150 ac_cv_search_setfilecon=no
15152 rm conftest.$ac_ext
15153 LIBS=$ac_func_search_save_LIBS
15155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setfilecon" >&5
15156 $as_echo "$ac_cv_search_setfilecon" >&6; }
15157 ac_res=$ac_cv_search_setfilecon
15158 if test "$ac_res" != no; then :
15159 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
15160 test "$ac_cv_search_setfilecon" = "none required" ||
15161 LIB_SELINUX=$ac_cv_search_setfilecon
15168 # Warn if SELinux is found but libselinux is absent;
15169 if test "$ac_cv_search_setfilecon" = no &&
15170 test "$host" = "$build" && test -d /selinux; then
15171 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This system supports SELinux but libselinux is missing." >&5
15172 $as_echo "$as_me: WARNING: This system supports SELinux but libselinux is missing." >&2;}
15173 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: GNU tar will be compiled without SELinux support." >&5
15174 $as_echo "$as_me: WARNING: GNU tar will be compiled without SELinux support." >&2;}
15179 ac_fn_c_check_decl "$LINENO" "setenv" "ac_cv_have_decl_setenv" "$ac_includes_default"
15180 if test "x$ac_cv_have_decl_setenv" = xyes; then :
15186 cat >>confdefs.h <<_ACEOF
15187 #define HAVE_DECL_SETENV $ac_have_decl
15195 if test $ac_cv_have_decl_setenv = no; then
15203 for ac_header in search.h
15205 ac_fn_c_check_header_mongrel "$LINENO" "search.h" "ac_cv_header_search_h" "$ac_includes_default"
15206 if test "x$ac_cv_header_search_h" = xyes; then :
15207 cat >>confdefs.h <<_ACEOF
15208 #define HAVE_SEARCH_H 1
15215 for ac_func in tsearch
15217 ac_fn_c_check_func "$LINENO" "tsearch" "ac_cv_func_tsearch"
15218 if test "x$ac_cv_func_tsearch" = xyes; then :
15219 cat >>confdefs.h <<_ACEOF
15220 #define HAVE_TSEARCH 1
15229 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
15230 #include <signal.h>
15231 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
15232 #include <sys/types.h>
15235 if test "x$ac_cv_type_sigset_t" = xyes; then :
15237 cat >>confdefs.h <<_ACEOF
15238 #define HAVE_SIGSET_T 1
15241 gl_cv_type_sigset_t=yes
15243 gl_cv_type_sigset_t=no
15246 if test $gl_cv_type_sigset_t != yes; then
15260 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf returns a byte count as in C99" >&5
15261 $as_echo_n "checking whether snprintf returns a byte count as in C99... " >&6; }
15262 if ${gl_cv_func_snprintf_retval_c99+:} false; then :
15263 $as_echo_n "(cached) " >&6
15266 if test "$cross_compiling" = yes; then :
15269 # Guess yes on glibc systems.
15270 *-gnu*) gl_cv_func_snprintf_retval_c99="guessing yes";;
15271 # Guess yes on FreeBSD >= 5.
15272 freebsd[1-4]*) gl_cv_func_snprintf_retval_c99="guessing no";;
15273 freebsd* | kfreebsd*) gl_cv_func_snprintf_retval_c99="guessing yes";;
15274 # Guess yes on Mac OS X >= 10.3.
15275 darwin[1-6].*) gl_cv_func_snprintf_retval_c99="guessing no";;
15276 darwin*) gl_cv_func_snprintf_retval_c99="guessing yes";;
15277 # Guess yes on OpenBSD >= 3.9.
15278 openbsd[1-2].* | openbsd3.[0-8] | openbsd3.[0-8].*)
15279 gl_cv_func_snprintf_retval_c99="guessing no";;
15280 openbsd*) gl_cv_func_snprintf_retval_c99="guessing yes";;
15281 # Guess yes on Solaris >= 2.10.
15282 solaris2.[1-9][0-9]*) gl_cv_func_printf_sizes_c99="guessing yes";;
15283 solaris*) gl_cv_func_printf_sizes_c99="guessing no";;
15284 # Guess yes on AIX >= 4.
15285 aix[1-3]*) gl_cv_func_snprintf_retval_c99="guessing no";;
15286 aix*) gl_cv_func_snprintf_retval_c99="guessing yes";;
15287 # Guess yes on NetBSD >= 3.
15288 netbsd[1-2]* | netbsdelf[1-2]* | netbsdaout[1-2]* | netbsdcoff[1-2]*)
15289 gl_cv_func_snprintf_retval_c99="guessing no";;
15290 netbsd*) gl_cv_func_snprintf_retval_c99="guessing yes";;
15291 # Guess yes on BeOS.
15292 beos*) gl_cv_func_snprintf_retval_c99="guessing yes";;
15293 # If we don't know, assume the worst.
15294 *) gl_cv_func_snprintf_retval_c99="guessing no";;
15298 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15299 /* end confdefs.h. */
15302 #include <string.h>
15304 # define my_snprintf snprintf
15306 # include <stdarg.h>
15307 static int my_snprintf (char *buf, int size, const char *format, ...)
15311 va_start (args, format);
15312 ret = vsnprintf (buf, size, format, args);
15317 static char buf[100];
15320 strcpy (buf, "ABCDEF");
15321 if (my_snprintf (buf, 3, "%d %d", 4567, 89) != 7)
15323 if (my_snprintf (buf, 0, "%d %d", 4567, 89) != 7)
15325 if (my_snprintf (NULL, 0, "%d %d", 4567, 89) != 7)
15330 if ac_fn_c_try_run "$LINENO"; then :
15331 gl_cv_func_snprintf_retval_c99=yes
15333 gl_cv_func_snprintf_retval_c99=no
15335 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15336 conftest.$ac_objext conftest.beam conftest.$ac_ext
15341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_snprintf_retval_c99" >&5
15342 $as_echo "$gl_cv_func_snprintf_retval_c99" >&6; }
15344 ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
15345 if test "x$ac_cv_have_decl_snprintf" = xyes; then :
15351 cat >>confdefs.h <<_ACEOF
15352 #define HAVE_DECL_SNPRINTF $ac_have_decl
15359 HAVE_DECL_STRNCASECMP=1;
15363 ac_fn_c_check_decl "$LINENO" "strdup" "ac_cv_have_decl_strdup" "$ac_includes_default"
15364 if test "x$ac_cv_have_decl_strdup" = xyes; then :
15370 cat >>confdefs.h <<_ACEOF
15371 #define HAVE_DECL_STRDUP $ac_have_decl
15375 REPLACE_STRERROR_0=0
15376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror(0) succeeds" >&5
15377 $as_echo_n "checking whether strerror(0) succeeds... " >&6; }
15378 if ${gl_cv_func_strerror_0_works+:} false; then :
15379 $as_echo_n "(cached) " >&6
15381 if test "$cross_compiling" = yes; then :
15383 # Guess yes on glibc systems.
15384 *-gnu*) gl_cv_func_strerror_0_works="guessing yes" ;;
15385 # If we don't know, assume the worst.
15386 *) gl_cv_func_strerror_0_works="guessing no" ;;
15390 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15391 /* end confdefs.h. */
15392 #include <string.h>
15401 str = strerror (0);
15402 if (!*str) result |= 1;
15403 if (errno) result |= 2;
15404 if (strstr (str, "nknown") || strstr (str, "ndefined"))
15411 if ac_fn_c_try_run "$LINENO"; then :
15412 gl_cv_func_strerror_0_works=yes
15414 gl_cv_func_strerror_0_works=no
15416 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15417 conftest.$ac_objext conftest.beam conftest.$ac_ext
15422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strerror_0_works" >&5
15423 $as_echo "$gl_cv_func_strerror_0_works" >&6; }
15424 case "$gl_cv_func_strerror_0_works" in
15427 REPLACE_STRERROR_0=1
15429 $as_echo "#define REPLACE_STRERROR_0 1" >>confdefs.h
15445 if test $gl_cv_have_include_next = yes; then
15446 gl_cv_next_string_h='<'string.h'>'
15448 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <string.h>" >&5
15449 $as_echo_n "checking absolute name of <string.h>... " >&6; }
15450 if ${gl_cv_next_string_h+:} false; then :
15451 $as_echo_n "(cached) " >&6
15454 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15455 /* end confdefs.h. */
15456 #include <string.h>
15460 aix*) gl_absname_cpp="$ac_cpp -C" ;;
15461 *) gl_absname_cpp="$ac_cpp" ;;
15466 gl_dirsep_regex='[/\\]'
15469 gl_dirsep_regex='\/'
15472 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
15474 gl_header_literal_regex=`echo 'string.h' \
15475 | sed -e "$gl_make_literal_regex_sed"`
15476 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
15477 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
15482 gl_cv_next_string_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
15483 sed -n "$gl_absolute_header_sed"`'"'
15487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_string_h" >&5
15488 $as_echo "$gl_cv_next_string_h" >&6; }
15490 NEXT_STRING_H=$gl_cv_next_string_h
15492 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
15493 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
15494 gl_next_as_first_directive='<'string.h'>'
15496 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
15497 gl_next_as_first_directive=$gl_cv_next_string_h
15499 NEXT_AS_FIRST_DIRECTIVE_STRING_H=$gl_next_as_first_directive
15506 for gl_func in ffsl ffsll memmem mempcpy memrchr rawmemchr stpcpy stpncpy strchrnul strdup strncat strndup strnlen strpbrk strsep strcasestr strtok_r strerror_r strsignal strverscmp; do
15507 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
15508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
15509 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
15510 if eval \${$as_gl_Symbol+:} false; then :
15511 $as_echo_n "(cached) " >&6
15513 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15514 /* end confdefs.h. */
15515 #include <string.h>
15526 if ac_fn_c_try_compile "$LINENO"; then :
15527 eval "$as_gl_Symbol=yes"
15529 eval "$as_gl_Symbol=no"
15531 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15533 eval ac_res=\$$as_gl_Symbol
15534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15535 $as_echo "$ac_res" >&6; }
15536 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
15537 cat >>confdefs.h <<_ACEOF
15538 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
15541 eval ac_cv_have_decl_$gl_func=yes
15560 if test $gl_cv_have_include_next = yes; then
15561 gl_cv_next_strings_h='<'strings.h'>'
15563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <strings.h>" >&5
15564 $as_echo_n "checking absolute name of <strings.h>... " >&6; }
15565 if ${gl_cv_next_strings_h+:} false; then :
15566 $as_echo_n "(cached) " >&6
15569 if test $ac_cv_header_strings_h = yes; then
15572 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15573 /* end confdefs.h. */
15574 #include <strings.h>
15578 aix*) gl_absname_cpp="$ac_cpp -C" ;;
15579 *) gl_absname_cpp="$ac_cpp" ;;
15584 gl_dirsep_regex='[/\\]'
15587 gl_dirsep_regex='\/'
15590 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
15592 gl_header_literal_regex=`echo 'strings.h' \
15593 | sed -e "$gl_make_literal_regex_sed"`
15594 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
15595 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
15600 gl_cv_next_strings_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
15601 sed -n "$gl_absolute_header_sed"`'"'
15603 gl_cv_next_strings_h='<'strings.h'>'
15608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_strings_h" >&5
15609 $as_echo "$gl_cv_next_strings_h" >&6; }
15611 NEXT_STRINGS_H=$gl_cv_next_strings_h
15613 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
15614 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
15615 gl_next_as_first_directive='<'strings.h'>'
15617 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
15618 gl_next_as_first_directive=$gl_cv_next_strings_h
15620 NEXT_AS_FIRST_DIRECTIVE_STRINGS_H=$gl_next_as_first_directive
15625 if test $ac_cv_header_strings_h = yes; then
15633 for gl_func in ffs strcasecmp strncasecmp; do
15634 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
15635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
15636 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
15637 if eval \${$as_gl_Symbol+:} false; then :
15638 $as_echo_n "(cached) " >&6
15640 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15641 /* end confdefs.h. */
15643 /* Minix 3.1.8 has a bug: <sys/types.h> must be included before
15645 #include <sys/types.h>
15646 #include <strings.h>
15657 if ac_fn_c_try_compile "$LINENO"; then :
15658 eval "$as_gl_Symbol=yes"
15660 eval "$as_gl_Symbol=no"
15662 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15664 eval ac_res=\$$as_gl_Symbol
15665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15666 $as_echo "$ac_res" >&6; }
15667 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
15668 cat >>confdefs.h <<_ACEOF
15669 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
15672 eval ac_cv_have_decl_$gl_func=yes
15677 ac_fn_c_check_decl "$LINENO" "strndup" "ac_cv_have_decl_strndup" "$ac_includes_default"
15678 if test "x$ac_cv_have_decl_strndup" = xyes; then :
15684 cat >>confdefs.h <<_ACEOF
15685 #define HAVE_DECL_STRNDUP $ac_have_decl
15690 ac_fn_c_check_decl "$LINENO" "strnlen" "ac_cv_have_decl_strnlen" "$ac_includes_default"
15691 if test "x$ac_cv_have_decl_strnlen" = xyes; then :
15697 cat >>confdefs.h <<_ACEOF
15698 #define HAVE_DECL_STRNLEN $ac_have_decl
15703 ac_fn_c_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default"
15704 if test "x$ac_cv_have_decl_strtoumax" = xyes; then :
15710 cat >>confdefs.h <<_ACEOF
15711 #define HAVE_DECL_STRTOUMAX $ac_have_decl
15720 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
15721 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
15722 if ${gl_cv_sys_struct_timespec_in_time_h+:} false; then :
15723 $as_echo_n "(cached) " >&6
15725 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15726 /* end confdefs.h. */
15732 static struct timespec x; x.tv_sec = x.tv_nsec;
15737 if ac_fn_c_try_compile "$LINENO"; then :
15738 gl_cv_sys_struct_timespec_in_time_h=yes
15740 gl_cv_sys_struct_timespec_in_time_h=no
15742 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
15745 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
15747 TIME_H_DEFINES_STRUCT_TIMESPEC=0
15748 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
15749 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
15750 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
15751 TIME_H_DEFINES_STRUCT_TIMESPEC=1
15753 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
15754 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
15755 if ${gl_cv_sys_struct_timespec_in_sys_time_h+:} false; then :
15756 $as_echo_n "(cached) " >&6
15758 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15759 /* end confdefs.h. */
15760 #include <sys/time.h>
15765 static struct timespec x; x.tv_sec = x.tv_nsec;
15770 if ac_fn_c_try_compile "$LINENO"; then :
15771 gl_cv_sys_struct_timespec_in_sys_time_h=yes
15773 gl_cv_sys_struct_timespec_in_sys_time_h=no
15775 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
15778 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
15779 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
15780 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
15782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
15783 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
15784 if ${gl_cv_sys_struct_timespec_in_pthread_h+:} false; then :
15785 $as_echo_n "(cached) " >&6
15787 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15788 /* end confdefs.h. */
15789 #include <pthread.h>
15794 static struct timespec x; x.tv_sec = x.tv_nsec;
15799 if ac_fn_c_try_compile "$LINENO"; then :
15800 gl_cv_sys_struct_timespec_in_pthread_h=yes
15802 gl_cv_sys_struct_timespec_in_pthread_h=no
15804 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
15807 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
15808 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
15809 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
15828 if test $gl_cv_have_include_next = yes; then
15829 gl_cv_next_time_h='<'time.h'>'
15831 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
15832 $as_echo_n "checking absolute name of <time.h>... " >&6; }
15833 if ${gl_cv_next_time_h+:} false; then :
15834 $as_echo_n "(cached) " >&6
15837 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15838 /* end confdefs.h. */
15843 aix*) gl_absname_cpp="$ac_cpp -C" ;;
15844 *) gl_absname_cpp="$ac_cpp" ;;
15849 gl_dirsep_regex='[/\\]'
15852 gl_dirsep_regex='\/'
15855 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
15857 gl_header_literal_regex=`echo 'time.h' \
15858 | sed -e "$gl_make_literal_regex_sed"`
15859 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
15860 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
15865 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
15866 sed -n "$gl_absolute_header_sed"`'"'
15870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
15871 $as_echo "$gl_cv_next_time_h" >&6; }
15873 NEXT_TIME_H=$gl_cv_next_time_h
15875 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
15876 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
15877 gl_next_as_first_directive='<'time.h'>'
15879 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
15880 gl_next_as_first_directive=$gl_cv_next_time_h
15882 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
15899 gl_libunistring_sed_extract_major='/^[0-9]/{s/^\([0-9]*\).*/\1/p;q;}
15904 gl_libunistring_sed_extract_minor='/^[0-9][0-9]*[.][0-9]/{s/^[0-9]*[.]\([0-9]*\).*/\1/p;q;}
15909 gl_libunistring_sed_extract_subminor='/^[0-9][0-9]*[.][0-9][0-9]*[.][0-9]/{s/^[0-9]*[.][0-9]*[.]\([0-9]*\).*/\1/p;q;}
15916 if test "$HAVE_LIBUNISTRING" = yes; then
15917 LIBUNISTRING_VERSION_MAJOR=`echo "$LIBUNISTRING_VERSION" | sed -n -e "$gl_libunistring_sed_extract_major"`
15918 LIBUNISTRING_VERSION_MINOR=`echo "$LIBUNISTRING_VERSION" | sed -n -e "$gl_libunistring_sed_extract_minor"`
15919 LIBUNISTRING_VERSION_SUBMINOR=`echo "$LIBUNISTRING_VERSION" | sed -n -e "$gl_libunistring_sed_extract_subminor"`
15924 ac_fn_c_check_decl "$LINENO" "unsetenv" "ac_cv_have_decl_unsetenv" "$ac_includes_default"
15925 if test "x$ac_cv_have_decl_unsetenv" = xyes; then :
15931 cat >>confdefs.h <<_ACEOF
15932 #define HAVE_DECL_UNSETENV $ac_have_decl
15936 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the utimes function works" >&5
15937 $as_echo_n "checking whether the utimes function works... " >&6; }
15938 if ${gl_cv_func_working_utimes+:} false; then :
15939 $as_echo_n "(cached) " >&6
15942 if test "$cross_compiling" = yes; then :
15943 gl_cv_func_working_utimes=no
15945 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15946 /* end confdefs.h. */
15948 #include <sys/types.h>
15949 #include <sys/stat.h>
15951 #include <sys/time.h>
15953 #include <unistd.h>
15954 #include <stdlib.h>
15959 inorder (time_t a, time_t b, time_t c)
15961 return a <= b && b <= c;
15968 char const *file = "conftest.utimes";
15969 static struct timeval timeval[2] = {{9, 10}, {999999, 999999}};
15971 /* Test whether utimes() essentially works. */
15974 FILE *f = fopen (file, "w");
15977 else if (fclose (f) != 0)
15979 else if (utimes (file, timeval) != 0)
15981 else if (lstat (file, &sbuf) != 0)
15983 else if (!(sbuf.st_atime == timeval[0].tv_sec
15984 && sbuf.st_mtime == timeval[1].tv_sec))
15986 if (unlink (file) != 0)
15990 /* Test whether utimes() with a NULL argument sets the file's timestamp
15991 to the current time. Use 'fstat' as well as 'time' to
15992 determine the "current" time, to accommodate NFS file systems
15993 if there is a time skew between the host and the NFS server. */
15995 int fd = open (file, O_WRONLY|O_CREAT, 0644);
16001 struct stat st0, st1, st2;
16002 if (time (&t0) == (time_t) -1)
16004 else if (fstat (fd, &st0) != 0)
16006 else if (utimes (file, timeval) != 0)
16008 else if (utimes (file, NULL) != 0)
16010 else if (fstat (fd, &st1) != 0)
16012 else if (write (fd, "\n", 1) != 1)
16014 else if (fstat (fd, &st2) != 0)
16016 else if (time (&t2) == (time_t) -1)
16020 int m_ok_POSIX = inorder (t0, st1.st_mtime, t2);
16021 int m_ok_NFS = inorder (st0.st_mtime, st1.st_mtime, st2.st_mtime);
16022 if (! (st1.st_atime == st1.st_mtime))
16024 if (! (m_ok_POSIX || m_ok_NFS))
16027 if (close (fd) != 0)
16030 if (unlink (file) != 0)
16034 /* Test whether utimes() with a NULL argument works on read-only files. */
16036 int fd = open (file, O_WRONLY|O_CREAT, 0444);
16039 else if (close (fd) != 0)
16041 else if (utimes (file, NULL) != 0)
16043 if (unlink (file) != 0)
16051 if ac_fn_c_try_run "$LINENO"; then :
16052 gl_cv_func_working_utimes=yes
16054 gl_cv_func_working_utimes=no
16056 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16057 conftest.$ac_objext conftest.beam conftest.$ac_ext
16061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_utimes" >&5
16062 $as_echo "$gl_cv_func_working_utimes" >&6; }
16064 if test $gl_cv_func_working_utimes = yes; then
16066 $as_echo "#define HAVE_WORKING_UTIMES 1" >>confdefs.h
16074 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
16075 $as_echo_n "checking for struct utimbuf... " >&6; }
16076 if ${gl_cv_sys_struct_utimbuf+:} false; then :
16077 $as_echo_n "(cached) " >&6
16079 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16080 /* end confdefs.h. */
16081 #if HAVE_SYS_TIME_H
16082 #include <sys/time.h>
16085 #ifdef HAVE_UTIME_H
16092 static struct utimbuf x; x.actime = x.modtime;
16097 if ac_fn_c_try_compile "$LINENO"; then :
16098 gl_cv_sys_struct_utimbuf=yes
16100 gl_cv_sys_struct_utimbuf=no
16102 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_utimbuf" >&5
16105 $as_echo "$gl_cv_sys_struct_utimbuf" >&6; }
16107 if test $gl_cv_sys_struct_utimbuf = yes; then
16109 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
16125 if test $ac_cv_header_features_h = yes; then
16133 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inttypes.h" >&5
16134 $as_echo_n "checking for inttypes.h... " >&6; }
16135 if ${gl_cv_header_inttypes_h+:} false; then :
16136 $as_echo_n "(cached) " >&6
16138 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16139 /* end confdefs.h. */
16141 #include <sys/types.h>
16142 #include <inttypes.h>
16147 uintmax_t i = (uintmax_t) -1; return !i;
16152 if ac_fn_c_try_compile "$LINENO"; then :
16153 gl_cv_header_inttypes_h=yes
16155 gl_cv_header_inttypes_h=no
16157 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_inttypes_h" >&5
16160 $as_echo "$gl_cv_header_inttypes_h" >&6; }
16161 if test $gl_cv_header_inttypes_h = yes; then
16163 cat >>confdefs.h <<_ACEOF
16164 #define HAVE_INTTYPES_H_WITH_UINTMAX 1
16170 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdint.h" >&5
16171 $as_echo_n "checking for stdint.h... " >&6; }
16172 if ${gl_cv_header_stdint_h+:} false; then :
16173 $as_echo_n "(cached) " >&6
16175 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16176 /* end confdefs.h. */
16177 #include <sys/types.h>
16178 #include <stdint.h>
16182 uintmax_t i = (uintmax_t) -1; return !i;
16187 if ac_fn_c_try_compile "$LINENO"; then :
16188 gl_cv_header_stdint_h=yes
16190 gl_cv_header_stdint_h=no
16192 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_stdint_h" >&5
16195 $as_echo "$gl_cv_header_stdint_h" >&6; }
16196 if test $gl_cv_header_stdint_h = yes; then
16198 cat >>confdefs.h <<_ACEOF
16199 #define HAVE_STDINT_H_WITH_UINTMAX 1
16207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for intmax_t" >&5
16208 $as_echo_n "checking for intmax_t... " >&6; }
16209 if ${gt_cv_c_intmax_t+:} false; then :
16210 $as_echo_n "(cached) " >&6
16212 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16213 /* end confdefs.h. */
16215 #include <stddef.h>
16216 #include <stdlib.h>
16217 #if HAVE_STDINT_H_WITH_UINTMAX
16218 #include <stdint.h>
16220 #if HAVE_INTTYPES_H_WITH_UINTMAX
16221 #include <inttypes.h>
16227 intmax_t x = -1; return !x;
16232 if ac_fn_c_try_compile "$LINENO"; then :
16233 gt_cv_c_intmax_t=yes
16235 gt_cv_c_intmax_t=no
16237 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_intmax_t" >&5
16240 $as_echo "$gt_cv_c_intmax_t" >&6; }
16241 if test $gt_cv_c_intmax_t = yes; then
16243 $as_echo "#define HAVE_INTMAX_T 1" >>confdefs.h
16247 test $ac_cv_type_long_long_int = yes \
16248 && ac_type='long long' \
16251 cat >>confdefs.h <<_ACEOF
16252 #define intmax_t $ac_type
16258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'double'" >&5
16259 $as_echo_n "checking where to find the exponent in a 'double'... " >&6; }
16260 if ${gl_cv_cc_double_expbit0+:} false; then :
16261 $as_echo_n "(cached) " >&6
16264 if test "$cross_compiling" = yes; then :
16266 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16267 /* end confdefs.h. */
16269 #if defined arm || defined __arm || defined __arm__
16274 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16275 $EGREP "mixed_endianness" >/dev/null 2>&1; then :
16276 gl_cv_cc_double_expbit0="unknown"
16280 if ${ac_cv_c_bigendian+:} false; then :
16281 $as_echo_n "(cached) " >&6
16283 ac_cv_c_bigendian=unknown
16284 # See if we're dealing with a universal compiler.
16285 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16286 /* end confdefs.h. */
16287 #ifndef __APPLE_CC__
16288 not a universal capable compiler
16293 if ac_fn_c_try_compile "$LINENO"; then :
16295 # Check for potential -arch flags. It is not universal unless
16296 # there are at least two -arch flags with different values.
16299 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
16300 if test -n "$ac_prev"; then
16302 i?86 | x86_64 | ppc | ppc64)
16303 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
16306 ac_cv_c_bigendian=universal
16312 elif test "x$ac_word" = "x-arch"; then
16317 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16318 if test $ac_cv_c_bigendian = unknown; then
16319 # See if sys/param.h defines the BYTE_ORDER macro.
16320 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16321 /* end confdefs.h. */
16322 #include <sys/types.h>
16323 #include <sys/param.h>
16328 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
16329 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
16331 bogus endian macros
16338 if ac_fn_c_try_compile "$LINENO"; then :
16339 # It does; now see whether it defined to BIG_ENDIAN or not.
16340 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16341 /* end confdefs.h. */
16342 #include <sys/types.h>
16343 #include <sys/param.h>
16348 #if BYTE_ORDER != BIG_ENDIAN
16356 if ac_fn_c_try_compile "$LINENO"; then :
16357 ac_cv_c_bigendian=yes
16359 ac_cv_c_bigendian=no
16361 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16363 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16365 if test $ac_cv_c_bigendian = unknown; then
16366 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
16367 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16368 /* end confdefs.h. */
16369 #include <limits.h>
16374 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
16375 bogus endian macros
16382 if ac_fn_c_try_compile "$LINENO"; then :
16383 # It does; now see whether it defined to _BIG_ENDIAN or not.
16384 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16385 /* end confdefs.h. */
16386 #include <limits.h>
16391 #ifndef _BIG_ENDIAN
16399 if ac_fn_c_try_compile "$LINENO"; then :
16400 ac_cv_c_bigendian=yes
16402 ac_cv_c_bigendian=no
16404 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16406 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16408 if test $ac_cv_c_bigendian = unknown; then
16409 # Compile a test program.
16410 if test "$cross_compiling" = yes; then :
16411 # Try to guess by grepping values from an object file.
16412 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16413 /* end confdefs.h. */
16414 short int ascii_mm[] =
16415 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
16416 short int ascii_ii[] =
16417 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
16418 int use_ascii (int i) {
16419 return ascii_mm[i] + ascii_ii[i];
16421 short int ebcdic_ii[] =
16422 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
16423 short int ebcdic_mm[] =
16424 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
16425 int use_ebcdic (int i) {
16426 return ebcdic_mm[i] + ebcdic_ii[i];
16433 return use_ascii (foo) == use_ebcdic (foo);
16438 if ac_fn_c_try_compile "$LINENO"; then :
16439 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
16440 ac_cv_c_bigendian=yes
16442 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
16443 if test "$ac_cv_c_bigendian" = unknown; then
16444 ac_cv_c_bigendian=no
16446 # finding both strings is unlikely to happen, but who knows?
16447 ac_cv_c_bigendian=unknown
16451 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16453 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16454 /* end confdefs.h. */
16455 $ac_includes_default
16460 /* Are we little or big endian? From Harbison&Steele. */
16464 char c[sizeof (long int)];
16467 return u.c[sizeof (long int) - 1] == 1;
16473 if ac_fn_c_try_run "$LINENO"; then :
16474 ac_cv_c_bigendian=no
16476 ac_cv_c_bigendian=yes
16478 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16479 conftest.$ac_objext conftest.beam conftest.$ac_ext
16485 case $ac_cv_c_bigendian in #(
16487 gl_cv_cc_double_expbit0="word 0 bit 20";; #(
16489 gl_cv_cc_double_expbit0="word 1 bit 20" ;; #(
16492 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
16496 gl_cv_cc_double_expbit0="unknown" ;;
16505 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16506 /* end confdefs.h. */
16509 #include <stddef.h>
16511 #include <string.h>
16513 ((sizeof (double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
16514 typedef union { double value; unsigned int word[NWORDS]; } memory_double;
16515 static unsigned int ored_words[NWORDS];
16516 static unsigned int anded_words[NWORDS];
16517 static void add_to_ored_words (double x)
16521 /* Clear it first, in case sizeof (double) < sizeof (memory_double). */
16522 memset (&m, 0, sizeof (memory_double));
16524 for (i = 0; i < NWORDS; i++)
16526 ored_words[i] |= m.word[i];
16527 anded_words[i] &= m.word[i];
16533 FILE *fp = fopen ("conftest.out", "w");
16536 for (j = 0; j < NWORDS; j++)
16537 anded_words[j] = ~ (unsigned int) 0;
16538 add_to_ored_words (0.25);
16539 add_to_ored_words (0.5);
16540 add_to_ored_words (1.0);
16541 add_to_ored_words (2.0);
16542 add_to_ored_words (4.0);
16543 /* Remove bits that are common (e.g. if representation of the first mantissa
16544 bit is explicit). */
16545 for (j = 0; j < NWORDS; j++)
16546 ored_words[j] &= ~anded_words[j];
16547 /* Now find the nonzero word. */
16548 for (j = 0; j < NWORDS; j++)
16549 if (ored_words[j] != 0)
16554 for (i = j + 1; i < NWORDS; i++)
16555 if (ored_words[i] != 0)
16557 fprintf (fp, "unknown");
16558 return (fclose (fp) != 0);
16561 if ((ored_words[j] >> i) & 1)
16563 fprintf (fp, "word %d bit %d", (int) j, (int) i);
16564 return (fclose (fp) != 0);
16567 fprintf (fp, "unknown");
16568 return (fclose (fp) != 0);
16572 if ac_fn_c_try_run "$LINENO"; then :
16573 gl_cv_cc_double_expbit0=`cat conftest.out`
16575 gl_cv_cc_double_expbit0="unknown"
16577 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16578 conftest.$ac_objext conftest.beam conftest.$ac_ext
16584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_double_expbit0" >&5
16585 $as_echo "$gl_cv_cc_double_expbit0" >&6; }
16586 case "$gl_cv_cc_double_expbit0" in
16588 word=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
16589 bit=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word.*bit //'`
16591 cat >>confdefs.h <<_ACEOF
16592 #define DBL_EXPBIT0_WORD $word
16596 cat >>confdefs.h <<_ACEOF
16597 #define DBL_EXPBIT0_BIT $bit
16608 for ac_func in snprintf strnlen wcslen wcsnlen mbrtowc wcrtomb
16610 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16611 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16612 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
16613 cat >>confdefs.h <<_ACEOF
16614 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16620 ac_fn_c_check_decl "$LINENO" "_snprintf" "ac_cv_have_decl__snprintf" "#include <stdio.h>
16622 if test "x$ac_cv_have_decl__snprintf" = xyes; then :
16628 cat >>confdefs.h <<_ACEOF
16629 #define HAVE_DECL__SNPRINTF $ac_have_decl
16634 case "$gl_cv_func_snprintf_retval_c99" in
16637 $as_echo "#define HAVE_SNPRINTF_RETVAL_C99 1" >>confdefs.h
16642 ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
16643 if test "x$ac_cv_have_decl_vsnprintf" = xyes; then :
16649 cat >>confdefs.h <<_ACEOF
16650 #define HAVE_DECL_VSNPRINTF $ac_have_decl
16659 GL_COND_LIBTOOL_TRUE=
16660 GL_COND_LIBTOOL_FALSE='#'
16662 GL_COND_LIBTOOL_TRUE='#'
16663 GL_COND_LIBTOOL_FALSE=
16666 gl_cond_libtool=false
16679 gl_source_base='gnu'
16682 if test $ac_cv_func_alloca_works = no; then
16686 # Define an additional variable used in the Makefile substitution.
16687 if test $ac_cv_working_alloca_h = yes; then
16688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
16689 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
16690 if ${gl_cv_rpl_alloca+:} false; then :
16691 $as_echo_n "(cached) " >&6
16694 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16695 /* end confdefs.h. */
16697 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
16702 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16703 $EGREP "Need own alloca" >/dev/null 2>&1; then :
16704 gl_cv_rpl_alloca=yes
16706 gl_cv_rpl_alloca=no
16712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
16713 $as_echo "$gl_cv_rpl_alloca" >&6; }
16714 if test $gl_cv_rpl_alloca = yes; then
16716 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
16726 if test -n "$ALLOCA_H"; then
16727 GL_GENERATE_ALLOCA_H_TRUE=
16728 GL_GENERATE_ALLOCA_H_FALSE='#'
16730 GL_GENERATE_ALLOCA_H_TRUE='#'
16731 GL_GENERATE_ALLOCA_H_FALSE=
16737 cat >>confdefs.h <<_ACEOF
16738 #define GNULIB_AREADLINKAT 1
16747 ac_fn_c_check_decl "$LINENO" "program_invocation_name" "ac_cv_have_decl_program_invocation_name" "#include <errno.h>
16749 if test "x$ac_cv_have_decl_program_invocation_name" = xyes; then :
16755 cat >>confdefs.h <<_ACEOF
16756 #define HAVE_DECL_PROGRAM_INVOCATION_NAME $ac_have_decl
16758 if test $ac_have_decl = 1; then :
16762 $as_echo "#define GNULIB_PROGRAM_INVOCATION_NAME 1" >>confdefs.h
16766 ac_fn_c_check_decl "$LINENO" "program_invocation_short_name" "ac_cv_have_decl_program_invocation_short_name" "#include <errno.h>
16768 if test "x$ac_cv_have_decl_program_invocation_short_name" = xyes; then :
16774 cat >>confdefs.h <<_ACEOF
16775 #define HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME $ac_have_decl
16777 if test $ac_have_decl = 1; then :
16781 $as_echo "#define GNULIB_PROGRAM_INVOCATION_SHORT_NAME 1" >>confdefs.h
16786 # Check if program_invocation_name and program_invocation_short_name
16787 # are defined elsewhere. It is improbable that only one of them will
16788 # be defined and other not, I prefer to stay on the safe side and to
16789 # test each one separately.
16790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether program_invocation_name is defined" >&5
16791 $as_echo_n "checking whether program_invocation_name is defined... " >&6; }
16792 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16793 /* end confdefs.h. */
16798 program_invocation_name = "test";
16803 if ac_fn_c_try_link "$LINENO"; then :
16805 $as_echo "#define HAVE_PROGRAM_INVOCATION_NAME 1" >>confdefs.h
16807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16808 $as_echo "yes" >&6; }
16810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16811 $as_echo "no" >&6; }
16813 rm -f core conftest.err conftest.$ac_objext \
16814 conftest$ac_exeext conftest.$ac_ext
16816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether program_invocation_short_name is defined" >&5
16817 $as_echo_n "checking whether program_invocation_short_name is defined... " >&6; }
16818 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16819 /* end confdefs.h. */
16824 program_invocation_short_name = "test";
16829 if ac_fn_c_try_link "$LINENO"; then :
16831 $as_echo "#define HAVE_PROGRAM_INVOCATION_SHORT_NAME 1" >>confdefs.h
16833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16834 $as_echo "yes" >&6; }
16836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16837 $as_echo "no" >&6; }
16839 rm -f core conftest.err conftest.$ac_objext \
16840 conftest$ac_exeext conftest.$ac_ext
16860 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=argp_error:2:c-format"
16864 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=argp_failure:4:c-format"
16874 gl_LIBOBJS="$gl_LIBOBJS openat-proc.$ac_objext"
16887 if test $ac_cv_func_btowc = no; then
16894 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether btowc(0) is correct" >&5
16895 $as_echo_n "checking whether btowc(0) is correct... " >&6; }
16896 if ${gl_cv_func_btowc_nul+:} false; then :
16897 $as_echo_n "(cached) " >&6
16900 if test "$cross_compiling" = yes; then :
16903 # Guess no on Cygwin.
16904 cygwin*) gl_cv_func_btowc_nul="guessing no" ;;
16905 # Guess yes otherwise.
16906 *) gl_cv_func_btowc_nul="guessing yes" ;;
16910 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16911 /* end confdefs.h. */
16913 #include <string.h>
16914 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
16916 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
16917 included before <wchar.h>. */
16918 #include <stddef.h>
16924 if (btowc ('\0') != 0)
16929 if ac_fn_c_try_run "$LINENO"; then :
16930 gl_cv_func_btowc_nul=yes
16932 gl_cv_func_btowc_nul=no
16934 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16935 conftest.$ac_objext conftest.beam conftest.$ac_ext
16940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_btowc_nul" >&5
16941 $as_echo "$gl_cv_func_btowc_nul" >&6; }
16943 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether btowc(EOF) is correct" >&5
16944 $as_echo_n "checking whether btowc(EOF) is correct... " >&6; }
16945 if ${gl_cv_func_btowc_eof+:} false; then :
16946 $as_echo_n "(cached) " >&6
16950 # Guess no on IRIX.
16951 irix*) gl_cv_func_btowc_eof="guessing no" ;;
16952 # Guess yes otherwise.
16953 *) gl_cv_func_btowc_eof="guessing yes" ;;
16955 if test $LOCALE_FR != none; then
16956 if test "$cross_compiling" = yes; then :
16959 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16960 /* end confdefs.h. */
16962 #include <locale.h>
16963 #include <string.h>
16964 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
16966 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
16967 included before <wchar.h>. */
16968 #include <stddef.h>
16974 if (setlocale (LC_ALL, "$LOCALE_FR") != NULL)
16976 if (btowc (EOF) != WEOF)
16982 if ac_fn_c_try_run "$LINENO"; then :
16983 gl_cv_func_btowc_eof=yes
16985 gl_cv_func_btowc_eof=no
16987 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16988 conftest.$ac_objext conftest.beam conftest.$ac_ext
16994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_btowc_eof" >&5
16995 $as_echo "$gl_cv_func_btowc_eof" >&6; }
16997 case "$gl_cv_func_btowc_nul" in
16999 *) REPLACE_BTOWC=1 ;;
17001 case "$gl_cv_func_btowc_eof" in
17003 *) REPLACE_BTOWC=1 ;;
17007 if test $HAVE_BTOWC = 0 || test $REPLACE_BTOWC = 1; then
17016 gl_LIBOBJS="$gl_LIBOBJS btowc.$ac_objext"
17033 $as_echo "#define GNULIB_TEST_BTOWC 1" >>confdefs.h
17040 if test $ac_cv_func_canonicalize_file_name = no; then
17041 HAVE_CANONICALIZE_FILE_NAME=0
17042 if test $ac_cv_func_realpath = no; then
17045 case "$gl_cv_func_realpath_works" in
17047 *) REPLACE_REALPATH=1 ;;
17051 case "$gl_cv_func_realpath_works" in
17055 REPLACE_CANONICALIZE_FILE_NAME=1
17061 if test $HAVE_CANONICALIZE_FILE_NAME = 0 || test $REPLACE_CANONICALIZE_FILE_NAME = 1; then
17070 gl_LIBOBJS="$gl_LIBOBJS canonicalize-lgpl.$ac_objext"
17075 cat >>confdefs.h <<_ACEOF
17076 #define GNULIB_CANONICALIZE_LGPL 1
17085 GNULIB_CANONICALIZE_FILE_NAME=1
17091 $as_echo "#define GNULIB_TEST_CANONICALIZE_FILE_NAME 1" >>confdefs.h
17106 $as_echo "#define GNULIB_TEST_REALPATH 1" >>confdefs.h
17122 $as_echo "#define GNULIB_TEST_CHDIR 1" >>confdefs.h
17128 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether this system has an arbitrary file name length limit" >&5
17129 $as_echo_n "checking whether this system has an arbitrary file name length limit... " >&6; }
17130 if ${gl_cv_have_arbitrary_file_name_length_limit+:} false; then :
17131 $as_echo_n "(cached) " >&6
17133 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17134 /* end confdefs.h. */
17136 /* Arrange to define PATH_MAX, like "pathmax.h" does. */
17138 # include <unistd.h>
17140 #include <limits.h>
17141 #if defined HAVE_SYS_PARAM_H && !defined PATH_MAX && !defined MAXPATHLEN
17142 # include <sys/param.h>
17144 #if !defined PATH_MAX && defined MAXPATHLEN
17145 # define PATH_MAX MAXPATHLEN
17149 # define PATH_MAX 1024
17151 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
17153 # define PATH_MAX 260
17157 have_arbitrary_file_name_length_limit
17160 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17161 $EGREP "have_arbitrary_file_name_length_limit" >/dev/null 2>&1; then :
17162 gl_cv_have_arbitrary_file_name_length_limit=yes
17164 gl_cv_have_arbitrary_file_name_length_limit=no
17169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_arbitrary_file_name_length_limit" >&5
17170 $as_echo "$gl_cv_have_arbitrary_file_name_length_limit" >&6; }
17172 if test $gl_cv_have_arbitrary_file_name_length_limit = yes; then
17181 gl_LIBOBJS="$gl_LIBOBJS chdir-long.$ac_objext"
17186 if test $HAVE_CHOWN = 0 || test $REPLACE_CHOWN = 1; then
17195 gl_LIBOBJS="$gl_LIBOBJS chown.$ac_objext"
17198 if test $REPLACE_CHOWN = 1 && test $ac_cv_func_fchown = no; then
17207 gl_LIBOBJS="$gl_LIBOBJS fchown-stub.$ac_objext"
17221 $as_echo "#define GNULIB_TEST_CHOWN 1" >>confdefs.h
17228 # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
17229 # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
17231 # Save and restore LIBS so e.g., -lrt, isn't added to it. Otherwise, *all*
17232 # programs in the package would end up linked with that potentially-shared
17233 # library, inducing unnecessary run-time overhead.
17236 gl_saved_libs=$LIBS
17237 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
17238 $as_echo_n "checking for library containing clock_gettime... " >&6; }
17239 if ${ac_cv_search_clock_gettime+:} false; then :
17240 $as_echo_n "(cached) " >&6
17242 ac_func_search_save_LIBS=$LIBS
17243 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17244 /* end confdefs.h. */
17246 /* Override any GCC internal prototype to avoid an error.
17247 Use char because int might match the return type of a GCC
17248 builtin and then its argument prototype would still apply. */
17252 char clock_gettime ();
17256 return clock_gettime ();
17261 for ac_lib in '' rt posix4; do
17262 if test -z "$ac_lib"; then
17263 ac_res="none required"
17266 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
17268 if ac_fn_c_try_link "$LINENO"; then :
17269 ac_cv_search_clock_gettime=$ac_res
17271 rm -f core conftest.err conftest.$ac_objext \
17273 if ${ac_cv_search_clock_gettime+:} false; then :
17277 if ${ac_cv_search_clock_gettime+:} false; then :
17280 ac_cv_search_clock_gettime=no
17282 rm conftest.$ac_ext
17283 LIBS=$ac_func_search_save_LIBS
17285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
17286 $as_echo "$ac_cv_search_clock_gettime" >&6; }
17287 ac_res=$ac_cv_search_clock_gettime
17288 if test "$ac_res" != no; then :
17289 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17290 test "$ac_cv_search_clock_gettime" = "none required" ||
17291 LIB_CLOCK_GETTIME=$ac_cv_search_clock_gettime
17294 for ac_func in clock_gettime clock_settime
17296 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
17297 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
17298 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
17299 cat >>confdefs.h <<_ACEOF
17300 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
17306 LIBS=$gl_saved_libs
17310 $as_echo "#define GNULIB_TEST_CLOEXEC 1" >>confdefs.h
17316 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
17324 if test $ac_cv_header_sys_socket_h != yes; then
17325 for ac_header in winsock2.h
17327 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
17328 if test "x$ac_cv_header_winsock2_h" = xyes; then :
17329 cat >>confdefs.h <<_ACEOF
17330 #define HAVE_WINSOCK2_H 1
17338 if test "$ac_cv_header_winsock2_h" = yes; then
17340 UNISTD_H_HAVE_WINSOCK2_H=1
17341 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
17347 if test $UNISTD_H_HAVE_WINSOCK2_H = 1; then
17352 if test $REPLACE_CLOSE = 0; then
17356 if test $ac_cv_func_fchdir = no; then
17360 if test $HAVE_FCHDIR = 0; then
17366 if test $REPLACE_CLOSE = 1; then
17375 gl_LIBOBJS="$gl_LIBOBJS close.$ac_objext"
17389 $as_echo "#define GNULIB_TEST_CLOSE 1" >>confdefs.h
17398 cat >>confdefs.h <<_ACEOF
17399 #define GNULIB_CLOSE_STREAM 1
17406 for ac_func in closedir
17408 ac_fn_c_check_func "$LINENO" "closedir" "ac_cv_func_closedir"
17409 if test "x$ac_cv_func_closedir" = xyes; then :
17410 cat >>confdefs.h <<_ACEOF
17411 #define HAVE_CLOSEDIR 1
17417 if test $ac_cv_func_closedir = no; then
17424 if test $ac_cv_func_fchdir = no; then
17428 if test $HAVE_FCHDIR = 0; then
17429 if test $HAVE_CLOSEDIR = 1; then
17435 if test $HAVE_CLOSEDIR = 0 || test $REPLACE_CLOSEDIR = 1; then
17444 gl_LIBOBJS="$gl_LIBOBJS closedir.$ac_objext"
17458 $as_echo "#define GNULIB_TEST_CLOSEDIR 1" >>confdefs.h
17466 if test "x$datarootdir" = x; then
17467 datarootdir='${datadir}'
17470 if test "x$docdir" = x; then
17471 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
17474 if test "x$htmldir" = x; then
17475 htmldir='${docdir}'
17478 if test "x$dvidir" = x; then
17482 if test "x$pdfdir" = x; then
17486 if test "x$psdir" = x; then
17490 if test "x$lispdir" = x; then
17491 lispdir='${datarootdir}/emacs/site-lisp'
17494 if test "x$localedir" = x; then
17495 localedir='${datarootdir}/locale'
17499 pkglibexecdir='${libexecdir}/${PACKAGE}'
17502 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for d_ino member in directory struct" >&5
17503 $as_echo_n "checking for d_ino member in directory struct... " >&6; }
17504 if ${gl_cv_struct_dirent_d_ino+:} false; then :
17505 $as_echo_n "(cached) " >&6
17507 if test "$cross_compiling" = yes; then :
17509 # Guess yes on glibc systems with Linux kernel.
17510 linux*-gnu*) gl_cv_struct_dirent_d_ino="guessing yes" ;;
17511 # If we don't know, assume the worst.
17512 *) gl_cv_struct_dirent_d_ino="guessing no" ;;
17516 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17517 /* end confdefs.h. */
17518 #include <sys/types.h>
17519 #include <sys/stat.h>
17520 #include <dirent.h>
17525 DIR *dp = opendir (".");
17533 if (stat (e->d_name, &st) != 0)
17535 if (e->d_ino != st.st_ino)
17543 if ac_fn_c_try_run "$LINENO"; then :
17544 gl_cv_struct_dirent_d_ino=yes
17546 gl_cv_struct_dirent_d_ino=no
17548 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17549 conftest.$ac_objext conftest.beam conftest.$ac_ext
17553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_struct_dirent_d_ino" >&5
17554 $as_echo "$gl_cv_struct_dirent_d_ino" >&6; }
17555 case "$gl_cv_struct_dirent_d_ino" in
17558 $as_echo "#define D_INO_IN_DIRENT 1" >>confdefs.h
17576 if test $gl_cv_have_include_next = yes; then
17577 gl_cv_next_dirent_h='<'dirent.h'>'
17579 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <dirent.h>" >&5
17580 $as_echo_n "checking absolute name of <dirent.h>... " >&6; }
17581 if ${gl_cv_next_dirent_h+:} false; then :
17582 $as_echo_n "(cached) " >&6
17585 if test $ac_cv_header_dirent_h = yes; then
17588 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17589 /* end confdefs.h. */
17590 #include <dirent.h>
17594 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17595 *) gl_absname_cpp="$ac_cpp" ;;
17600 gl_dirsep_regex='[/\\]'
17603 gl_dirsep_regex='\/'
17606 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17608 gl_header_literal_regex=`echo 'dirent.h' \
17609 | sed -e "$gl_make_literal_regex_sed"`
17610 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17611 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17616 gl_cv_next_dirent_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17617 sed -n "$gl_absolute_header_sed"`'"'
17619 gl_cv_next_dirent_h='<'dirent.h'>'
17624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_dirent_h" >&5
17625 $as_echo "$gl_cv_next_dirent_h" >&6; }
17627 NEXT_DIRENT_H=$gl_cv_next_dirent_h
17629 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17630 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17631 gl_next_as_first_directive='<'dirent.h'>'
17633 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17634 gl_next_as_first_directive=$gl_cv_next_dirent_h
17636 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H=$gl_next_as_first_directive
17641 if test $ac_cv_header_dirent_h = yes; then
17649 for gl_func in alphasort closedir dirfd fdopendir opendir readdir rewinddir scandir; do
17650 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
17651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
17652 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
17653 if eval \${$as_gl_Symbol+:} false; then :
17654 $as_echo_n "(cached) " >&6
17656 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17657 /* end confdefs.h. */
17658 #include <dirent.h>
17669 if ac_fn_c_try_compile "$LINENO"; then :
17670 eval "$as_gl_Symbol=yes"
17672 eval "$as_gl_Symbol=no"
17674 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17676 eval ac_res=\$$as_gl_Symbol
17677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
17678 $as_echo "$ac_res" >&6; }
17679 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
17680 cat >>confdefs.h <<_ACEOF
17681 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
17684 eval ac_cv_have_decl_$gl_func=yes
17694 cat >>confdefs.h <<_ACEOF
17695 #define GNULIB_DIRENT_SAFER 1
17704 for ac_func in dirfd
17706 ac_fn_c_check_func "$LINENO" "dirfd" "ac_cv_func_dirfd"
17707 if test "x$ac_cv_func_dirfd" = xyes; then :
17708 cat >>confdefs.h <<_ACEOF
17709 #define HAVE_DIRFD 1
17715 ac_fn_c_check_decl "$LINENO" "dirfd" "ac_cv_have_decl_dirfd" "#include <sys/types.h>
17716 #include <dirent.h>
17718 if test "x$ac_cv_have_decl_dirfd" = xyes; then :
17724 cat >>confdefs.h <<_ACEOF
17725 #define HAVE_DECL_DIRFD $ac_have_decl
17728 if test $ac_cv_have_decl_dirfd = no; then
17732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dirfd is a macro" >&5
17733 $as_echo_n "checking whether dirfd is a macro... " >&6; }
17734 if ${gl_cv_func_dirfd_macro+:} false; then :
17735 $as_echo_n "(cached) " >&6
17737 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17738 /* end confdefs.h. */
17740 #include <sys/types.h>
17741 #include <dirent.h>
17743 dirent_header_defines_dirfd
17746 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17747 $EGREP "dirent_header_defines_dirfd" >/dev/null 2>&1; then :
17748 gl_cv_func_dirfd_macro=yes
17750 gl_cv_func_dirfd_macro=no
17755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dirfd_macro" >&5
17756 $as_echo "$gl_cv_func_dirfd_macro" >&6; }
17758 # Use the replacement only if we have no function or macro with that name.
17759 if test $ac_cv_func_dirfd = no && test $gl_cv_func_dirfd_macro = no; then
17760 if test $ac_cv_have_decl_dirfd = yes; then
17761 # If the system declares dirfd already, let's declare rpl_dirfd instead.
17766 if test $ac_cv_func_dirfd = no && test $gl_cv_func_dirfd_macro = no; then
17775 gl_LIBOBJS="$gl_LIBOBJS dirfd.$ac_objext"
17778 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to get the file descriptor associated with an open DIR*" >&5
17779 $as_echo_n "checking how to get the file descriptor associated with an open DIR*... " >&6; }
17780 if ${gl_cv_sys_dir_fd_member_name+:} false; then :
17781 $as_echo_n "(cached) " >&6
17784 dirfd_save_CFLAGS=$CFLAGS
17785 for ac_expr in d_fd dd_fd; do
17787 CFLAGS="$CFLAGS -DDIR_FD_MEMBER_NAME=$ac_expr"
17788 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17789 /* end confdefs.h. */
17791 #include <sys/types.h>
17792 #include <dirent.h>
17796 DIR *dir_p = opendir("."); (void) dir_p->DIR_FD_MEMBER_NAME;
17801 if ac_fn_c_try_compile "$LINENO"; then :
17805 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17806 CFLAGS=$dirfd_save_CFLAGS
17807 test "$dir_fd_found" = yes && break
17809 test "$dir_fd_found" = yes || ac_expr=no_such_member
17811 gl_cv_sys_dir_fd_member_name=$ac_expr
17815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_dir_fd_member_name" >&5
17816 $as_echo "$gl_cv_sys_dir_fd_member_name" >&6; }
17817 if test $gl_cv_sys_dir_fd_member_name != no_such_member; then
17819 cat >>confdefs.h <<_ACEOF
17820 #define DIR_FD_MEMBER_NAME $gl_cv_sys_dir_fd_member_name
17838 $as_echo "#define GNULIB_TEST_DIRFD 1" >>confdefs.h
17847 cat >>confdefs.h <<_ACEOF
17848 #define GNULIB_DIRNAME 1
17858 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether // is distinct from /" >&5
17859 $as_echo_n "checking whether // is distinct from /... " >&6; }
17860 if ${gl_cv_double_slash_root+:} false; then :
17861 $as_echo_n "(cached) " >&6
17863 if test x"$cross_compiling" = xyes ; then
17864 # When cross-compiling, there is no way to tell whether // is special
17865 # short of a list of hosts. However, the only known hosts to date
17866 # that have a distinct // are Apollo DomainOS (too old to port to),
17867 # Cygwin, and z/OS. If anyone knows of another system for which // has
17868 # special semantics and is distinct from /, please report it to
17869 # <bug-gnulib@gnu.org>.
17871 *-cygwin | i370-ibm-openedition)
17872 gl_cv_double_slash_root=yes ;;
17874 # Be optimistic and assume that / and // are the same when we
17876 gl_cv_double_slash_root='unknown, assuming no' ;;
17879 set x `ls -di / // 2>/dev/null`
17880 if test "$2" = "$4" && wc //dev/null >/dev/null 2>&1; then
17881 gl_cv_double_slash_root=no
17883 gl_cv_double_slash_root=yes
17887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_double_slash_root" >&5
17888 $as_echo "$gl_cv_double_slash_root" >&6; }
17889 if test "$gl_cv_double_slash_root" = yes; then
17891 $as_echo "#define DOUBLE_SLASH_IS_DISTINCT_ROOT 1" >>confdefs.h
17898 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
17905 if test $ac_cv_func_fchdir = no; then
17909 if test $HAVE_FCHDIR = 0; then
17914 if test $REPLACE_DUP = 1; then
17923 gl_LIBOBJS="$gl_LIBOBJS dup.$ac_objext"
17938 $as_echo "#define GNULIB_TEST_DUP 1" >>confdefs.h
17947 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
17950 if test $HAVE_DUP2 = 1; then
17951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
17952 $as_echo_n "checking whether dup2 works... " >&6; }
17953 if ${gl_cv_func_dup2_works+:} false; then :
17954 $as_echo_n "(cached) " >&6
17956 if test "$cross_compiling" = yes; then :
17958 mingw*) # on this platform, dup2 always returns 0 for success
17959 gl_cv_func_dup2_works="guessing no" ;;
17960 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
17961 gl_cv_func_dup2_works="guessing no" ;;
17962 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
17963 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
17964 gl_cv_func_dup2_works="guessing no" ;;
17965 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
17966 gl_cv_func_dup2_works="guessing no" ;;
17967 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
17968 gl_cv_func_dup2_works="guessing no" ;;
17969 *) gl_cv_func_dup2_works="guessing yes" ;;
17972 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17973 /* end confdefs.h. */
17975 #include <unistd.h>
17983 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
17986 if (dup2 (1, 1) == 0)
17989 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
17993 if (dup2 (0, 0) != -1)
17995 /* Many gnulib modules require POSIX conformance of EBADF. */
17996 if (dup2 (2, 1000000) == -1 && errno != EBADF)
17998 /* Flush out a cygwin core dump. */
17999 if (dup2 (2, -1) != -1 || errno != EBADF)
18008 if ac_fn_c_try_run "$LINENO"; then :
18009 gl_cv_func_dup2_works=yes
18011 gl_cv_func_dup2_works=no
18013 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18014 conftest.$ac_objext conftest.beam conftest.$ac_ext
18019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
18020 $as_echo "$gl_cv_func_dup2_works" >&6; }
18021 case "$gl_cv_func_dup2_works" in
18032 if test $ac_cv_func_fchdir = no; then
18036 if test $HAVE_FCHDIR = 0; then
18037 if test $HAVE_DUP2 = 1; then
18043 if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
18052 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
18067 $as_echo "#define GNULIB_TEST_DUP2 1" >>confdefs.h
18083 $as_echo "#define GNULIB_TEST_ENVIRON 1" >>confdefs.h
18089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for error_at_line" >&5
18090 $as_echo_n "checking for error_at_line... " >&6; }
18091 if ${ac_cv_lib_error_at_line+:} false; then :
18092 $as_echo_n "(cached) " >&6
18094 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18095 /* end confdefs.h. */
18100 error_at_line (0, 0, "", 0, "an error occurred");
18105 if ac_fn_c_try_link "$LINENO"; then :
18106 ac_cv_lib_error_at_line=yes
18108 ac_cv_lib_error_at_line=no
18110 rm -f core conftest.err conftest.$ac_objext \
18111 conftest$ac_exeext conftest.$ac_ext
18113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_error_at_line" >&5
18114 $as_echo "$ac_cv_lib_error_at_line" >&6; }
18116 if test $ac_cv_lib_error_at_line = no; then
18125 gl_LIBOBJS="$gl_LIBOBJS error.$ac_objext"
18134 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=error:3:c-format"
18138 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=error_at_line:5:c-format"
18146 if test $ac_cv_have_decl_fchdir = no; then
18151 if test $HAVE_FCHDIR = 0; then
18160 gl_LIBOBJS="$gl_LIBOBJS fchdir.$ac_objext"
18164 $as_echo "#define REPLACE_FCHDIR 1" >>confdefs.h
18166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether open can visit directories" >&5
18167 $as_echo_n "checking whether open can visit directories... " >&6; }
18168 if ${gl_cv_func_open_directory_works+:} false; then :
18169 $as_echo_n "(cached) " >&6
18171 if test "$cross_compiling" = yes; then :
18173 # Guess yes on glibc systems.
18174 *-gnu*) gl_cv_func_open_directory_works="guessing yes" ;;
18175 # If we don't know, assume the worst.
18176 *) gl_cv_func_open_directory_works="guessing no" ;;
18180 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18181 /* end confdefs.h. */
18187 return open(".", O_RDONLY) < 0;
18192 if ac_fn_c_try_run "$LINENO"; then :
18193 gl_cv_func_open_directory_works=yes
18195 gl_cv_func_open_directory_works=no
18197 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18198 conftest.$ac_objext conftest.beam conftest.$ac_ext
18202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_open_directory_works" >&5
18203 $as_echo "$gl_cv_func_open_directory_works" >&6; }
18204 case "$gl_cv_func_open_directory_works" in
18208 $as_echo "#define REPLACE_OPEN_DIRECTORY 1" >>confdefs.h
18225 $as_echo "#define GNULIB_TEST_FCHDIR 1" >>confdefs.h
18233 if test $ac_cv_func_fchmodat != yes; then
18237 if test $HAVE_FCHMODAT = 0; then
18246 gl_LIBOBJS="$gl_LIBOBJS fchmodat.$ac_objext"
18251 cat >>confdefs.h <<_ACEOF
18252 #define GNULIB_FCHMODAT 1
18266 $as_echo "#define GNULIB_TEST_FCHMODAT 1" >>confdefs.h
18274 ac_fn_c_check_func "$LINENO" "fchownat" "ac_cv_func_fchownat"
18275 if test "x$ac_cv_func_fchownat" = xyes; then :
18279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fchownat works with AT_SYMLINK_NOFOLLOW" >&5
18280 $as_echo_n "checking whether fchownat works with AT_SYMLINK_NOFOLLOW... " >&6; }
18281 if ${gl_cv_func_fchownat_nofollow_works+:} false; then :
18282 $as_echo_n "(cached) " >&6
18285 gl_dangle=conftest.dangle
18286 # Remove any remnants of a previous test.
18288 # Arrange for deletion of the temporary file this test creates.
18289 ac_clean_files="$ac_clean_files $gl_dangle"
18290 ln -s conftest.no-such $gl_dangle
18291 if test "$cross_compiling" = yes; then :
18292 gl_cv_func_fchownat_nofollow_works=no
18294 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18295 /* end confdefs.h. */
18298 #include <unistd.h>
18299 #include <stdlib.h>
18301 #include <sys/types.h>
18305 return (fchownat (AT_FDCWD, "$gl_dangle", -1, getgid (),
18306 AT_SYMLINK_NOFOLLOW) != 0
18307 && errno == ENOENT);
18311 if ac_fn_c_try_run "$LINENO"; then :
18312 gl_cv_func_fchownat_nofollow_works=yes
18314 gl_cv_func_fchownat_nofollow_works=no
18316 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18317 conftest.$ac_objext conftest.beam conftest.$ac_ext
18322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fchownat_nofollow_works" >&5
18323 $as_echo "$gl_cv_func_fchownat_nofollow_works" >&6; }
18324 if test $gl_cv_func_fchownat_nofollow_works = no; then :
18327 $as_echo "#define FCHOWNAT_NOFOLLOW_BUG 1" >>confdefs.h
18335 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fchownat works with an empty file name" >&5
18336 $as_echo_n "checking whether fchownat works with an empty file name... " >&6; }
18337 if ${gl_cv_func_fchownat_empty_filename_works+:} false; then :
18338 $as_echo_n "(cached) " >&6
18340 if test "$cross_compiling" = yes; then :
18341 gl_cv_func_fchownat_empty_filename_works="guessing no"
18343 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18344 /* end confdefs.h. */
18345 #include <unistd.h>
18353 if (mkdir ("conftestdir", 0700) < 0)
18355 fd = open ("conftestdir", O_RDONLY);
18358 ret = fchownat (fd, "", -1, -1, 0);
18360 rmdir ("conftestdir");
18367 if ac_fn_c_try_run "$LINENO"; then :
18368 gl_cv_func_fchownat_empty_filename_works=yes
18370 gl_cv_func_fchownat_empty_filename_works=no
18372 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18373 conftest.$ac_objext conftest.beam conftest.$ac_ext
18378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fchownat_empty_filename_works" >&5
18379 $as_echo "$gl_cv_func_fchownat_empty_filename_works" >&6; }
18380 if test "$gl_cv_func_fchownat_empty_filename_works" != yes; then :
18383 $as_echo "#define FCHOWNAT_EMPTY_FILENAME_BUG 1" >>confdefs.h
18388 if test $REPLACE_CHOWN = 1; then
18396 if test $HAVE_FCHOWNAT = 0 || test $REPLACE_FCHOWNAT = 1; then
18405 gl_LIBOBJS="$gl_LIBOBJS fchownat.$ac_objext"
18410 cat >>confdefs.h <<_ACEOF
18411 #define GNULIB_FCHOWNAT 1
18425 $as_echo "#define GNULIB_TEST_FCHOWNAT 1" >>confdefs.h
18434 if test $ac_cv_func_fcntl = no; then
18438 if test $ac_cv_func_fcntl = no; then
18445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl handles F_DUPFD correctly" >&5
18446 $as_echo_n "checking whether fcntl handles F_DUPFD correctly... " >&6; }
18447 if ${gl_cv_func_fcntl_f_dupfd_works+:} false; then :
18448 $as_echo_n "(cached) " >&6
18450 if test "$cross_compiling" = yes; then :
18451 # Guess that it works on glibc systems
18452 case $host_os in #((
18453 *-gnu*) gl_cv_func_fcntl_f_dupfd_works="guessing yes";;
18454 *) gl_cv_func_fcntl_f_dupfd_works="guessing no";;
18457 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18458 /* end confdefs.h. */
18467 if (fcntl (0, F_DUPFD, -1) != -1) result |= 1;
18468 if (errno != EINVAL) result |= 2;
18475 if ac_fn_c_try_run "$LINENO"; then :
18476 gl_cv_func_fcntl_f_dupfd_works=yes
18478 gl_cv_func_fcntl_f_dupfd_works=no
18480 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18481 conftest.$ac_objext conftest.beam conftest.$ac_ext
18485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_works" >&5
18486 $as_echo "$gl_cv_func_fcntl_f_dupfd_works" >&6; }
18487 case $gl_cv_func_fcntl_f_dupfd_works in
18492 if test $ac_cv_func_fcntl = no; then
18499 $as_echo "#define FCNTL_DUPFD_BUGGY 1" >>confdefs.h
18503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl understands F_DUPFD_CLOEXEC" >&5
18504 $as_echo_n "checking whether fcntl understands F_DUPFD_CLOEXEC... " >&6; }
18505 if ${gl_cv_func_fcntl_f_dupfd_cloexec+:} false; then :
18506 $as_echo_n "(cached) " >&6
18508 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18509 /* end confdefs.h. */
18512 #ifndef F_DUPFD_CLOEXEC
18524 if ac_fn_c_try_compile "$LINENO"; then :
18525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18526 /* end confdefs.h. */
18529 /* The Linux kernel only added F_DUPFD_CLOEXEC in 2.6.24, so we always replace
18530 it to support the semantics on older kernels that failed with EINVAL. */
18542 if ac_fn_c_try_compile "$LINENO"; then :
18543 gl_cv_func_fcntl_f_dupfd_cloexec=yes
18545 gl_cv_func_fcntl_f_dupfd_cloexec="needs runtime check"
18547 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18549 gl_cv_func_fcntl_f_dupfd_cloexec=no
18551 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_cloexec" >&5
18554 $as_echo "$gl_cv_func_fcntl_f_dupfd_cloexec" >&6; }
18555 if test "$gl_cv_func_fcntl_f_dupfd_cloexec" != yes; then
18559 if test $ac_cv_func_fcntl = no; then
18571 if test $ac_cv_func_fchdir = no; then
18575 if test $HAVE_FCHDIR = 0; then
18579 if test $ac_cv_func_fcntl = no; then
18588 if test $HAVE_FCNTL = 0 || test $REPLACE_FCNTL = 1; then
18597 gl_LIBOBJS="$gl_LIBOBJS fcntl.$ac_objext"
18611 $as_echo "#define GNULIB_TEST_FCNTL 1" >>confdefs.h
18626 if test $gl_cv_have_include_next = yes; then
18627 gl_cv_next_fcntl_h='<'fcntl.h'>'
18629 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <fcntl.h>" >&5
18630 $as_echo_n "checking absolute name of <fcntl.h>... " >&6; }
18631 if ${gl_cv_next_fcntl_h+:} false; then :
18632 $as_echo_n "(cached) " >&6
18635 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18636 /* end confdefs.h. */
18641 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18642 *) gl_absname_cpp="$ac_cpp" ;;
18647 gl_dirsep_regex='[/\\]'
18650 gl_dirsep_regex='\/'
18653 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18655 gl_header_literal_regex=`echo 'fcntl.h' \
18656 | sed -e "$gl_make_literal_regex_sed"`
18657 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18658 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18663 gl_cv_next_fcntl_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18664 sed -n "$gl_absolute_header_sed"`'"'
18668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_fcntl_h" >&5
18669 $as_echo "$gl_cv_next_fcntl_h" >&6; }
18671 NEXT_FCNTL_H=$gl_cv_next_fcntl_h
18673 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18674 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18675 gl_next_as_first_directive='<'fcntl.h'>'
18677 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18678 gl_next_as_first_directive=$gl_cv_next_fcntl_h
18680 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H=$gl_next_as_first_directive
18691 for gl_func in fcntl openat; do
18692 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
18693 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
18694 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
18695 if eval \${$as_gl_Symbol+:} false; then :
18696 $as_echo_n "(cached) " >&6
18698 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18699 /* end confdefs.h. */
18711 if ac_fn_c_try_compile "$LINENO"; then :
18712 eval "$as_gl_Symbol=yes"
18714 eval "$as_gl_Symbol=no"
18716 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18718 eval ac_res=\$$as_gl_Symbol
18719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18720 $as_echo "$ac_res" >&6; }
18721 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
18722 cat >>confdefs.h <<_ACEOF
18723 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
18726 eval ac_cv_have_decl_$gl_func=yes
18736 ac_fn_c_check_decl "$LINENO" "fdopendir" "ac_cv_have_decl_fdopendir" "
18737 #include <dirent.h>
18740 if test "x$ac_cv_have_decl_fdopendir" = xyes; then :
18746 cat >>confdefs.h <<_ACEOF
18747 #define HAVE_DECL_FDOPENDIR $ac_have_decl
18749 if test $ac_have_decl = 1; then :
18752 HAVE_DECL_FDOPENDIR=0
18756 if test $ac_cv_func_fdopendir = no; then
18759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fdopendir works" >&5
18760 $as_echo_n "checking whether fdopendir works... " >&6; }
18761 if ${gl_cv_func_fdopendir_works+:} false; then :
18762 $as_echo_n "(cached) " >&6
18764 if test "$cross_compiling" = yes; then :
18766 # Guess yes on glibc systems.
18767 *-gnu*) gl_cv_func_fdopendir_works="guessing yes" ;;
18768 # If we don't know, assume the worst.
18769 *) gl_cv_func_fdopendir_works="guessing no" ;;
18773 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18774 /* end confdefs.h. */
18776 #include <dirent.h>
18778 #include <unistd.h>
18779 #if !HAVE_DECL_FDOPENDIR
18781 # ifdef __cplusplus
18784 DIR *fdopendir (int);
18791 int fd = open ("conftest.c", O_RDONLY);
18792 if (fd < 0) result |= 1;
18793 if (fdopendir (fd)) result |= 2;
18794 if (close (fd)) result |= 4;
18800 if ac_fn_c_try_run "$LINENO"; then :
18801 gl_cv_func_fdopendir_works=yes
18803 gl_cv_func_fdopendir_works=no
18805 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18806 conftest.$ac_objext conftest.beam conftest.$ac_ext
18810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fdopendir_works" >&5
18811 $as_echo "$gl_cv_func_fdopendir_works" >&6; }
18812 case "$gl_cv_func_fdopendir_works" in
18815 REPLACE_FDOPENDIR=1
18820 if test $HAVE_FDOPENDIR = 0 || test $REPLACE_FDOPENDIR = 1; then
18829 gl_LIBOBJS="$gl_LIBOBJS fdopendir.$ac_objext"
18843 $as_echo "#define GNULIB_TEST_FDOPENDIR 1" >>confdefs.h
18849 cat >>confdefs.h <<_ACEOF
18850 #define GNULIB_FDOPENDIR 1
18856 cat >>confdefs.h <<_ACEOF
18857 #define GNULIB_FDUTIMENSAT 1
18863 ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default"
18864 if test "x$ac_cv_member_struct_stat_st_blocks" = xyes; then :
18866 cat >>confdefs.h <<_ACEOF
18867 #define HAVE_STRUCT_STAT_ST_BLOCKS 1
18871 $as_echo "#define HAVE_ST_BLOCKS 1" >>confdefs.h
18880 if test $ac_cv_member_struct_stat_st_blocks = no; then
18889 gl_LIBOBJS="$gl_LIBOBJS fileblocks.$ac_objext"
18903 REPLACE_FLOAT_LDBL=0
18905 aix* | beos* | openbsd* | mirbsd* | irix*)
18909 case "$host_cpu" in
18914 # On x86_64 systems, the C compiler may still be generating
18916 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18917 /* end confdefs.h. */
18918 #if defined __LP64__ || defined __x86_64__ || defined __amd64__
18922 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18923 $EGREP "yes" >/dev/null 2>&1; then :
18934 case "$host_cpu" in
18942 aix* | freebsd* | linux*)
18943 if test -n "$FLOAT_H"; then
18944 REPLACE_FLOAT_LDBL=1
18950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether conversion from 'int' to 'long double' works" >&5
18951 $as_echo_n "checking whether conversion from 'int' to 'long double' works... " >&6; }
18952 if ${gl_cv_func_itold_works+:} false; then :
18953 $as_echo_n "(cached) " >&6
18956 if test "$cross_compiling" = yes; then :
18959 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18960 /* end confdefs.h. */
18961 #if defined __LP64__ || defined __arch64__
18965 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18966 $EGREP "yes" >/dev/null 2>&1; then :
18967 gl_cv_func_itold_works="guessing no"
18969 gl_cv_func_itold_works="guessing yes"
18974 *) gl_cv_func_itold_works="guessing yes" ;;
18978 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18979 /* end confdefs.h. */
18982 volatile long double ld;
18991 if ac_fn_c_try_run "$LINENO"; then :
18992 gl_cv_func_itold_works=yes
18994 gl_cv_func_itold_works=no
18996 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18997 conftest.$ac_objext conftest.beam conftest.$ac_ext
19002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_itold_works" >&5
19003 $as_echo "$gl_cv_func_itold_works" >&6; }
19004 case "$gl_cv_func_itold_works" in
19011 if test -n "$FLOAT_H"; then
19020 if test $gl_cv_have_include_next = yes; then
19021 gl_cv_next_float_h='<'float.h'>'
19023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <float.h>" >&5
19024 $as_echo_n "checking absolute name of <float.h>... " >&6; }
19025 if ${gl_cv_next_float_h+:} false; then :
19026 $as_echo_n "(cached) " >&6
19029 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19030 /* end confdefs.h. */
19035 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19036 *) gl_absname_cpp="$ac_cpp" ;;
19041 gl_dirsep_regex='[/\\]'
19044 gl_dirsep_regex='\/'
19047 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19049 gl_header_literal_regex=`echo 'float.h' \
19050 | sed -e "$gl_make_literal_regex_sed"`
19051 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19052 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19057 gl_cv_next_float_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19058 sed -n "$gl_absolute_header_sed"`'"'
19062 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_float_h" >&5
19063 $as_echo "$gl_cv_next_float_h" >&6; }
19065 NEXT_FLOAT_H=$gl_cv_next_float_h
19067 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19068 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19069 gl_next_as_first_directive='<'float.h'>'
19071 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19072 gl_next_as_first_directive=$gl_cv_next_float_h
19074 NEXT_AS_FIRST_DIRECTIVE_FLOAT_H=$gl_next_as_first_directive
19081 if test -n "$FLOAT_H"; then
19082 GL_GENERATE_FLOAT_H_TRUE=
19083 GL_GENERATE_FLOAT_H_FALSE='#'
19085 GL_GENERATE_FLOAT_H_TRUE='#'
19086 GL_GENERATE_FLOAT_H_FALSE=
19091 if test $REPLACE_FLOAT_LDBL = 1; then
19100 gl_LIBOBJS="$gl_LIBOBJS float.$ac_objext"
19103 if test $REPLACE_ITOLD = 1; then
19112 gl_LIBOBJS="$gl_LIBOBJS itold.$ac_objext"
19121 gl_fnmatch_required_lowercase=`
19122 echo $gl_fnmatch_required | LC_ALL=C tr '[A-Z]' '[a-z]'
19124 gl_fnmatch_cache_var="gl_cv_func_fnmatch_${gl_fnmatch_required_lowercase}"
19125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working $gl_fnmatch_required fnmatch" >&5
19126 $as_echo_n "checking for working $gl_fnmatch_required fnmatch... " >&6; }
19127 if eval \${$gl_fnmatch_cache_var+:} false; then :
19128 $as_echo_n "(cached) " >&6
19130 if test $gl_fnmatch_required = GNU; then
19131 gl_fnmatch_gnu_start=
19132 gl_fnmatch_gnu_end=
19134 gl_fnmatch_gnu_start='#if 0'
19135 gl_fnmatch_gnu_end='#endif'
19137 if test "$cross_compiling" = yes; then :
19138 eval "$gl_fnmatch_cache_var=\"guessing no\""
19140 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19141 /* end confdefs.h. */
19142 #include <fnmatch.h>
19144 y (char const *pattern, char const *string, int flags)
19146 return fnmatch (pattern, string, flags) == 0;
19149 n (char const *pattern, char const *string, int flags)
19151 return fnmatch (pattern, string, flags) == FNM_NOMATCH;
19157 char const *Apat = 'A' < '\\\\' ? "[A-\\\\\\\\]" : "[\\\\\\\\-A]";
19158 char const *apat = 'a' < '\\\\' ? "[a-\\\\\\\\]" : "[\\\\\\\\-a]";
19159 static char const A_1[] = { 'A' - 1, 0 };
19160 static char const A01[] = { 'A' + 1, 0 };
19161 static char const a_1[] = { 'a' - 1, 0 };
19162 static char const a01[] = { 'a' + 1, 0 };
19163 static char const bs_1[] = { '\\\\' - 1, 0 };
19164 static char const bs01[] = { '\\\\' + 1, 0 };
19166 if (!n ("a*", "", 0))
19168 if (!y ("a*", "abc", 0))
19170 if (!y ("[/b", "[/b", 0)) /*"]]"*/ /* glibc Bugzilla bug 12378 */
19172 if (!n ("d*/*1", "d/s/1", FNM_PATHNAME))
19174 if (!y ("a\\\\bc", "abc", 0))
19176 if (!n ("a\\\\bc", "abc", FNM_NOESCAPE))
19178 if (!y ("*x", ".x", 0))
19180 if (!n ("*x", ".x", FNM_PERIOD))
19182 if (!y (Apat, "\\\\", 0))
19184 if (!y (Apat, "A", 0))
19186 if (!y (apat, "\\\\", 0))
19188 if (!y (apat, "a", 0))
19190 if (!(n (Apat, A_1, 0) == ('A' < '\\\\')))
19192 if (!(n (apat, a_1, 0) == ('a' < '\\\\')))
19194 if (!(y (Apat, A01, 0) == ('A' < '\\\\')))
19196 if (!(y (apat, a01, 0) == ('a' < '\\\\')))
19198 if (!(y (Apat, bs_1, 0) == ('A' < '\\\\')))
19200 if (!(y (apat, bs_1, 0) == ('a' < '\\\\')))
19202 if (!(n (Apat, bs01, 0) == ('A' < '\\\\')))
19204 if (!(n (apat, bs01, 0) == ('a' < '\\\\')))
19206 $gl_fnmatch_gnu_start
19207 if (!y ("xxXX", "xXxX", FNM_CASEFOLD))
19209 if (!y ("a++(x|yy)b", "a+xyyyyxb", FNM_EXTMATCH))
19211 if (!n ("d*/*1", "d/s/1", FNM_FILE_NAME))
19213 if (!y ("*", "x", FNM_FILE_NAME | FNM_LEADING_DIR))
19215 if (!y ("x*", "x/y/z", FNM_FILE_NAME | FNM_LEADING_DIR))
19217 if (!y ("*c*", "c/x", FNM_FILE_NAME | FNM_LEADING_DIR))
19219 $gl_fnmatch_gnu_end
19226 if ac_fn_c_try_run "$LINENO"; then :
19227 eval "$gl_fnmatch_cache_var=yes"
19229 eval "$gl_fnmatch_cache_var=no"
19231 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19232 conftest.$ac_objext conftest.beam conftest.$ac_ext
19237 eval ac_res=\$$gl_fnmatch_cache_var
19238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
19239 $as_echo "$ac_res" >&6; }
19240 eval "gl_fnmatch_result=\"\$$gl_fnmatch_cache_var\""
19241 if test "$gl_fnmatch_result" = yes; then
19242 rm -f "$gl_source_base/fnmatch.h"
19244 FNMATCH_H=fnmatch.h
19247 if test -n "$FNMATCH_H"; then
19248 GL_GENERATE_FNMATCH_H_TRUE=
19249 GL_GENERATE_FNMATCH_H_FALSE='#'
19251 GL_GENERATE_FNMATCH_H_TRUE='#'
19252 GL_GENERATE_FNMATCH_H_FALSE=
19256 if test -n "$FNMATCH_H"; then
19265 gl_LIBOBJS="$gl_LIBOBJS fnmatch.$ac_objext"
19269 cat >>confdefs.h <<_ACEOF
19270 #define fnmatch ${gl_fnmatch_required_lowercase}_fnmatch
19274 ac_fn_c_check_decl "$LINENO" "isblank" "ac_cv_have_decl_isblank" "#include <ctype.h>
19276 if test "x$ac_cv_have_decl_isblank" = xyes; then :
19282 cat >>confdefs.h <<_ACEOF
19283 #define HAVE_DECL_ISBLANK $ac_have_decl
19295 if test -n "$FNMATCH_H"; then
19304 gl_LIBOBJS="$gl_LIBOBJS fnmatch.$ac_objext"
19308 cat >>confdefs.h <<_ACEOF
19309 #define fnmatch ${gl_fnmatch_required_lowercase}_fnmatch
19313 ac_fn_c_check_decl "$LINENO" "isblank" "ac_cv_have_decl_isblank" "#include <ctype.h>
19315 if test "x$ac_cv_have_decl_isblank" = xyes; then :
19321 cat >>confdefs.h <<_ACEOF
19322 #define HAVE_DECL_ISBLANK $ac_have_decl
19333 # include <stdio.h>
19334 # if HAVE_STDIO_EXT_H
19335 # include <stdio_ext.h>
19338 ac_fn_c_check_decl "$LINENO" "__fpending" "ac_cv_have_decl___fpending" "$fp_headers
19340 if test "x$ac_cv_have_decl___fpending" = xyes; then :
19346 cat >>confdefs.h <<_ACEOF
19347 #define HAVE_DECL___FPENDING $ac_have_decl
19351 if test $ac_cv_func___fpending = no; then
19360 gl_LIBOBJS="$gl_LIBOBJS fpending.$ac_objext"
19363 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to determine the number of pending output bytes on a stream" >&5
19364 $as_echo_n "checking how to determine the number of pending output bytes on a stream... " >&6; }
19365 if ${ac_cv_sys_pending_output_n_bytes+:} false; then :
19366 $as_echo_n "(cached) " >&6
19372 'fp->_IO_write_ptr - fp->_IO_write_base' \
19374 '# traditional Unix' \
19375 'fp->_ptr - fp->_base' \
19378 'fp->_p - fp->_bf._base' \
19380 '# SCO, Unixware' \
19381 '(fp->__ptr ? fp->__ptr - fp->__base : 0)' \
19384 '(fp->_Mode & 0x2000 /*_MWRITE*/ ? fp->_Next - fp->_Buf : 0)' \
19387 'fp->__bufp - fp->__buffer' \
19389 '# old glibc iostream?' \
19390 'fp->_pptr - fp->_pbase' \
19393 'fp->_ptr - fp->_buffer' \
19396 'fp->_ptr - fp->_buf' \
19399 'fp->wp - fp->buf' \
19402 '(*fp)->_ptr - (*fp)->_base' \
19404 '# e.g., DGUX R4.11; the info is not available' \
19408 # Skip each embedded comment.
19409 case "$ac_expr" in '#'*) continue;; esac
19411 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19412 /* end confdefs.h. */
19417 FILE *fp = stdin; (void) ($ac_expr);
19422 if ac_fn_c_try_compile "$LINENO"; then :
19426 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19427 test "$fp_done" = yes && break
19430 ac_cv_sys_pending_output_n_bytes=$ac_expr
19434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_pending_output_n_bytes" >&5
19435 $as_echo "$ac_cv_sys_pending_output_n_bytes" >&6; }
19437 cat >>confdefs.h <<_ACEOF
19438 #define PENDING_OUTPUT_N_BYTES $ac_cv_sys_pending_output_n_bytes
19446 if test $HAVE_FSEEKO = 0 || test $REPLACE_FSEEKO = 1; then
19450 if test $REPLACE_FSEEK = 1; then
19459 gl_LIBOBJS="$gl_LIBOBJS fseek.$ac_objext"
19473 $as_echo "#define GNULIB_TEST_FSEEK 1" >>confdefs.h
19485 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fseeko" >&5
19486 $as_echo_n "checking for fseeko... " >&6; }
19487 if ${gl_cv_func_fseeko+:} false; then :
19488 $as_echo_n "(cached) " >&6
19491 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19492 /* end confdefs.h. */
19498 fseeko (stdin, 0, 0);
19503 if ac_fn_c_try_link "$LINENO"; then :
19504 gl_cv_func_fseeko=yes
19506 gl_cv_func_fseeko=no
19508 rm -f core conftest.err conftest.$ac_objext \
19509 conftest$ac_exeext conftest.$ac_ext
19512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fseeko" >&5
19513 $as_echo "$gl_cv_func_fseeko" >&6; }
19516 if test $ac_cv_have_decl_fseeko = no; then
19520 if test $gl_cv_func_fseeko = no; then
19523 if test $WINDOWS_64_BIT_OFF_T = 1; then
19526 if test $gl_cv_var_stdin_large_offset = no; then
19532 if test $HAVE_FSEEKO = 0 || test $REPLACE_FSEEKO = 1; then
19541 gl_LIBOBJS="$gl_LIBOBJS fseeko.$ac_objext"
19544 for ac_func in _fseeki64
19546 ac_fn_c_check_func "$LINENO" "_fseeki64" "ac_cv_func__fseeki64"
19547 if test "x$ac_cv_func__fseeki64" = xyes; then :
19548 cat >>confdefs.h <<_ACEOF
19549 #define HAVE__FSEEKI64 1
19568 $as_echo "#define GNULIB_TEST_FSEEKO 1" >>confdefs.h
19576 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
19581 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
19589 if test $ac_cv_func_fchdir = no; then
19593 if test $HAVE_FCHDIR = 0; then
19594 case "$gl_cv_func_open_directory_works" in
19603 if test $REPLACE_FSTAT = 1; then
19612 gl_LIBOBJS="$gl_LIBOBJS fstat.$ac_objext"
19627 $as_echo "#define GNULIB_TEST_FSTAT 1" >>confdefs.h
19637 if test $ac_cv_func_fstatat = no; then
19640 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fstatat (..., 0) works" >&5
19641 $as_echo_n "checking whether fstatat (..., 0) works... " >&6; }
19642 if ${gl_cv_func_fstatat_zero_flag+:} false; then :
19643 $as_echo_n "(cached) " >&6
19645 if test "$cross_compiling" = yes; then :
19647 aix*) gl_cv_func_fstatat_zero_flag="guessing no";;
19648 *) gl_cv_func_fstatat_zero_flag="guessing yes";;
19652 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19653 /* end confdefs.h. */
19656 #include <sys/stat.h>
19661 return fstatat (AT_FDCWD, ".", &a, 0) != 0;
19665 if ac_fn_c_try_run "$LINENO"; then :
19666 gl_cv_func_fstatat_zero_flag=yes
19668 gl_cv_func_fstatat_zero_flag=no
19670 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19671 conftest.$ac_objext conftest.beam conftest.$ac_ext
19676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fstatat_zero_flag" >&5
19677 $as_echo "$gl_cv_func_fstatat_zero_flag" >&6; }
19679 case $gl_cv_func_fstatat_zero_flag+$gl_cv_func_lstat_dereferences_slashed_symlink in
19681 *) REPLACE_FSTATAT=1
19682 case $gl_cv_func_fstatat_zero_flag in
19685 $as_echo "#define HAVE_WORKING_FSTATAT_ZERO_FLAG 1" >>confdefs.h
19693 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
19702 gl_LIBOBJS="$gl_LIBOBJS fstatat.$ac_objext"
19716 $as_echo "#define GNULIB_TEST_FSTATAT 1" >>confdefs.h
19724 if test $ac_cv_func_futimens = no; then
19727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether futimens works" >&5
19728 $as_echo_n "checking whether futimens works... " >&6; }
19729 if ${gl_cv_func_futimens_works+:} false; then :
19730 $as_echo_n "(cached) " >&6
19732 if test "$cross_compiling" = yes; then :
19733 gl_cv_func_futimens_works="guessing no"
19735 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19736 /* end confdefs.h. */
19739 #include <sys/stat.h>
19740 #include <unistd.h>
19746 struct timespec ts[2] = { { 1, UTIME_OMIT }, { 1, UTIME_NOW } };
19747 int fd = creat ("conftest.file", 0600);
19749 if (fd < 0) return 1;
19751 if (futimens (AT_FDCWD, NULL) == 0) return 2;
19752 if (errno != EBADF) return 3;
19753 if (futimens (fd, ts)) return 4;
19755 ts[0].tv_nsec = UTIME_NOW;
19756 ts[1].tv_nsec = UTIME_OMIT;
19757 if (futimens (fd, ts)) return 5;
19758 if (fstat (fd, &st)) return 6;
19759 if (st.st_ctime < st.st_atime) return 7;
19765 if ac_fn_c_try_run "$LINENO"; then :
19766 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19767 /* end confdefs.h. */
19770 /* The Linux kernel added futimens in 2.6.22, but has bugs with UTIME_OMIT
19771 in several file systems as recently as 2.6.32. Always replace futimens
19772 to support older kernels. */
19784 if ac_fn_c_try_compile "$LINENO"; then :
19785 gl_cv_func_futimens_works=yes
19787 gl_cv_func_futimens_works="needs runtime check"
19789 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19791 gl_cv_func_futimens_works=no
19793 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19794 conftest.$ac_objext conftest.beam conftest.$ac_ext
19797 rm -f conftest.file
19799 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_futimens_works" >&5
19800 $as_echo "$gl_cv_func_futimens_works" >&6; }
19801 if test "$gl_cv_func_futimens_works" != yes; then
19806 if test $HAVE_FUTIMENS = 0 || test $REPLACE_FUTIMENS = 1; then
19815 gl_LIBOBJS="$gl_LIBOBJS futimens.$ac_objext"
19829 $as_echo "#define GNULIB_TEST_FUTIMENS 1" >>confdefs.h
19841 gl_cv_func_getcwd_path_max=yes
19849 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getcwd handles long file names properly" >&5
19850 $as_echo_n "checking whether getcwd handles long file names properly... " >&6; }
19851 if ${gl_cv_func_getcwd_path_max+:} false; then :
19852 $as_echo_n "(cached) " >&6
19854 # Arrange for deletion of the temporary directory this test creates.
19855 ac_clean_files="$ac_clean_files confdir3"
19856 if test "$cross_compiling" = yes; then :
19858 aix*) gl_cv_func_getcwd_path_max='no, it has the AIX bug';;
19859 *) gl_cv_func_getcwd_path_max=no;;
19862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19863 /* end confdefs.h. */
19866 #include <stdlib.h>
19868 # include <unistd.h>
19870 # include <direct.h>
19872 #include <string.h>
19873 #include <limits.h>
19874 #include <sys/stat.h>
19875 #include <sys/types.h>
19879 /* Arrange to define PATH_MAX, like "pathmax.h" does. */
19881 # include <unistd.h>
19883 #include <limits.h>
19884 #if defined HAVE_SYS_PARAM_H && !defined PATH_MAX && !defined MAXPATHLEN
19885 # include <sys/param.h>
19887 #if !defined PATH_MAX && defined MAXPATHLEN
19888 # define PATH_MAX MAXPATHLEN
19892 # define PATH_MAX 1024
19894 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
19896 # define PATH_MAX 260
19901 # define AT_FDCWD 0
19903 #ifdef ENAMETOOLONG
19904 # define is_ENAMETOOLONG(x) ((x) == ENAMETOOLONG)
19906 # define is_ENAMETOOLONG(x) 0
19909 /* Use the getcwd function, not any macro. */
19912 /* Don't get link errors because mkdir is redefined to rpl_mkdir. */
19916 # define S_IRWXU 0700
19919 /* The length of this name must be 8. */
19920 #define DIR_NAME "confdir3"
19921 #define DIR_NAME_LEN 8
19922 #define DIR_NAME_SIZE (DIR_NAME_LEN + 1)
19924 /* The length of "../". */
19925 #define DOTDOTSLASH_LEN 3
19927 /* Leftover bytes in the buffer, to work around library or OS bugs. */
19928 #define BUF_SLOP 20
19934 /* The Hurd doesn't define this, so getcwd can't exhibit the bug --
19935 at least not on a local file system. And if we were to start worrying
19936 about remote file systems, we'd have to enable the wrapper function
19937 all of the time, just to be safe. That's not worth the cost. */
19939 #elif ((INT_MAX / (DIR_NAME_SIZE / DOTDOTSLASH_LEN + 1) \
19940 - DIR_NAME_SIZE - BUF_SLOP) \
19942 /* FIXME: Assuming there's a system for which this is true,
19943 this should be done in a compile test. */
19946 char buf[PATH_MAX * (DIR_NAME_SIZE / DOTDOTSLASH_LEN + 1)
19947 + DIR_NAME_SIZE + BUF_SLOP];
19948 char *cwd = getcwd (buf, PATH_MAX);
19949 size_t initial_cwd_len;
19952 size_t n_chdirs = 0;
19957 cwd_len = initial_cwd_len = strlen (cwd);
19961 size_t dotdot_max = PATH_MAX * (DIR_NAME_SIZE / DOTDOTSLASH_LEN);
19964 cwd_len += DIR_NAME_SIZE;
19965 /* If mkdir or chdir fails, it could be that this system cannot create
19966 any file with an absolute name longer than PATH_MAX, such as cygwin.
19967 If so, leave fail as 0, because the current working directory can't
19968 be too long for getcwd if it can't even be created. For other
19969 errors, be pessimistic and consider that as a failure, too. */
19970 if (mkdir (DIR_NAME, S_IRWXU) < 0 || chdir (DIR_NAME) < 0)
19972 if (! (errno == ERANGE || is_ENAMETOOLONG (errno)))
19977 if (PATH_MAX <= cwd_len && cwd_len < PATH_MAX + DIR_NAME_SIZE)
19979 c = getcwd (buf, PATH_MAX);
19980 if (!c && errno == ENOENT)
19990 if (! (errno == ERANGE || is_ENAMETOOLONG (errno)))
19997 if (dotdot_max <= cwd_len - initial_cwd_len)
19999 if (dotdot_max + DIR_NAME_SIZE < cwd_len - initial_cwd_len)
20001 c = getcwd (buf, cwd_len + 1);
20004 if (! (errno == ERANGE || errno == ENOENT
20005 || is_ENAMETOOLONG (errno)))
20010 if (AT_FDCWD || errno == ERANGE || errno == ENOENT)
20018 if (c && strlen (c) != cwd_len)
20026 /* Leaving behind such a deep directory is not polite.
20027 So clean up here, right away, even though the driving
20028 shell script would also clean up. */
20032 /* Try rmdir first, in case the chdir failed. */
20034 for (i = 0; i <= n_chdirs; i++)
20036 if (chdir ("..") < 0)
20038 if (rmdir (DIR_NAME) != 0)
20048 if ac_fn_c_try_run "$LINENO"; then :
20049 gl_cv_func_getcwd_path_max=yes
20052 10|11|12) gl_cv_func_getcwd_path_max='no, but it is partly working';;
20053 31) gl_cv_func_getcwd_path_max='no, it has the AIX bug';;
20054 *) gl_cv_func_getcwd_path_max=no;;
20057 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20058 conftest.$ac_objext conftest.beam conftest.$ac_ext
20063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_path_max" >&5
20064 $as_echo "$gl_cv_func_getcwd_path_max" >&6; }
20066 case "$gl_cv_func_getcwd_null" in
20072 for ac_func in getpagesize
20074 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
20075 if test "x$ac_cv_func_getpagesize" = xyes; then :
20076 cat >>confdefs.h <<_ACEOF
20077 #define HAVE_GETPAGESIZE 1
20083 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getcwd aborts when 4k < cwd_length < 16k" >&5
20084 $as_echo_n "checking whether getcwd aborts when 4k < cwd_length < 16k... " >&6; }
20085 if ${gl_cv_func_getcwd_abort_bug+:} false; then :
20086 $as_echo_n "(cached) " >&6
20088 # Remove any remnants of a previous test.
20089 rm -rf confdir-14B---
20090 # Arrange for deletion of the temporary directory this test creates.
20091 ac_clean_files="$ac_clean_files confdir-14B---"
20092 if test "$cross_compiling" = yes; then :
20093 gl_cv_func_getcwd_abort_bug=yes
20095 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20096 /* end confdefs.h. */
20098 #include <stdlib.h>
20100 # include <unistd.h>
20101 #else /* on Windows with MSVC */
20102 # include <direct.h>
20104 #include <string.h>
20105 #include <sys/stat.h>
20108 /* Arrange to define PATH_MAX, like "pathmax.h" does. */
20110 # include <unistd.h>
20112 #include <limits.h>
20113 #if defined HAVE_SYS_PARAM_H && !defined PATH_MAX && !defined MAXPATHLEN
20114 # include <sys/param.h>
20116 #if !defined PATH_MAX && defined MAXPATHLEN
20117 # define PATH_MAX MAXPATHLEN
20121 # define PATH_MAX 1024
20123 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
20125 # define PATH_MAX 260
20129 /* Don't get link errors because mkdir is redefined to rpl_mkdir. */
20133 # define S_IRWXU 0700
20136 /* FIXME: skip the run-test altogether on systems without getpagesize. */
20137 #if ! HAVE_GETPAGESIZE
20138 # define getpagesize() 0
20141 /* This size is chosen to be larger than PATH_MAX (4k), yet smaller than
20142 the 16kB pagesize on ia64 linux. Those conditions make the code below
20143 trigger a bug in glibc's getcwd implementation before 2.4.90-10. */
20144 #define TARGET_LEN (5 * 1024)
20150 size_t initial_cwd_len;
20153 /* The bug is triggered when PATH_MAX < getpagesize (), so skip
20154 this relatively expensive and invasive test if that's not true. */
20156 int bug_possible = PATH_MAX < getpagesize ();
20158 int bug_possible = 0;
20160 if (! bug_possible)
20163 cwd = getcwd (NULL, 0);
20167 initial_cwd_len = strlen (cwd);
20172 static char const dir_name[] = "confdir-14B---";
20173 size_t desired_depth = ((TARGET_LEN - 1 - initial_cwd_len)
20174 / sizeof dir_name);
20176 for (d = 0; d < desired_depth; d++)
20178 if (mkdir (dir_name, S_IRWXU) < 0 || chdir (dir_name) < 0)
20180 if (! (errno == ERANGE || errno == ENAMETOOLONG
20181 || errno == ENOENT))
20182 fail = 3; /* Unable to construct deep hierarchy. */
20187 /* If libc has the bug in question, this invocation of getcwd
20188 results in a failed assertion. */
20189 cwd = getcwd (NULL, 0);
20191 fail = 4; /* getcwd didn't assert, but it failed for a long name
20192 where the answer could have been learned. */
20195 /* Call rmdir first, in case the above chdir failed. */
20199 if (chdir ("..") < 0)
20212 if ac_fn_c_try_run "$LINENO"; then :
20213 gl_cv_func_getcwd_abort_bug=no
20216 if test $ret -ge 128 || test $ret = 4; then
20217 gl_cv_func_getcwd_abort_bug=yes
20219 gl_cv_func_getcwd_abort_bug=no
20222 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20223 conftest.$ac_objext conftest.beam conftest.$ac_ext
20228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_abort_bug" >&5
20229 $as_echo "$gl_cv_func_getcwd_abort_bug" >&6; }
20230 if test $gl_cv_func_getcwd_abort_bug = yes; then :
20238 case "$gl_cv_func_getcwd_path_max" in
20239 "no"|"no, it has the AIX bug") ;;
20242 $as_echo "#define HAVE_MINIMALLY_WORKING_GETCWD 1" >>confdefs.h
20246 case "$gl_cv_func_getcwd_path_max" in
20247 "no, but it is partly working")
20249 $as_echo "#define HAVE_PARTLY_WORKING_GETCWD 1" >>confdefs.h
20254 if { case "$gl_cv_func_getcwd_null" in *yes) false;; *) true;; esac; } \
20255 || test $gl_cv_func_getcwd_posix_signature != yes \
20256 || test "$gl_cv_func_getcwd_path_max" != yes \
20257 || test $gl_abort_bug = yes; then
20261 if test $REPLACE_GETCWD = 1; then
20270 gl_LIBOBJS="$gl_LIBOBJS getcwd.$ac_objext"
20280 cat >>confdefs.h <<_ACEOF
20281 #define GNULIB_GETCWD 1
20296 $as_echo "#define GNULIB_TEST_GETCWD 1" >>confdefs.h
20305 case $gl_cv_func_getcwd_null,$gl_cv_func_getcwd_posix_signature in
20312 if test $REPLACE_GETCWD = 1; then
20321 gl_LIBOBJS="$gl_LIBOBJS getcwd-lgpl.$ac_objext"
20335 $as_echo "#define GNULIB_TEST_GETCWD 1" >>confdefs.h
20347 if test $ac_cv_func_getdelim = yes; then
20349 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getdelim function" >&5
20350 $as_echo_n "checking for working getdelim function... " >&6; }
20351 if ${gl_cv_func_working_getdelim+:} false; then :
20352 $as_echo_n "(cached) " >&6
20354 echo fooNbarN | tr -d '\012' | tr N '\012' > conftest.data
20355 if test "$cross_compiling" = yes; then :
20356 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20357 /* end confdefs.h. */
20359 #include <features.h>
20360 #ifdef __GNU_LIBRARY__
20361 #if (__GLIBC__ >= 2) && !defined __UCLIBC__
20367 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20368 $EGREP "Lucky GNU user" >/dev/null 2>&1; then :
20369 gl_cv_func_working_getdelim="guessing yes"
20371 gl_cv_func_working_getdelim="guessing no"
20377 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20378 /* end confdefs.h. */
20380 # include <stdio.h>
20381 # include <stdlib.h>
20382 # include <string.h>
20385 FILE *in = fopen ("./conftest.data", "r");
20389 /* Test result for a NULL buffer and a zero size.
20390 Based on a test program from Karl Heuer. */
20393 int len = getdelim (&line, &siz, '\n', in);
20394 if (!(len == 4 && line && strcmp (line, "foo\n") == 0))
20398 /* Test result for a NULL buffer and a non-zero size.
20399 This crashes on FreeBSD 8.0. */
20401 size_t siz = (size_t)(~0) / 4;
20402 if (getdelim (&line, &siz, '\n', in) == -1)
20409 if ac_fn_c_try_run "$LINENO"; then :
20410 gl_cv_func_working_getdelim=yes
20412 gl_cv_func_working_getdelim=no
20414 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20415 conftest.$ac_objext conftest.beam conftest.$ac_ext
20419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_getdelim" >&5
20420 $as_echo "$gl_cv_func_working_getdelim" >&6; }
20421 case "$gl_cv_func_working_getdelim" in
20430 if test $ac_cv_have_decl_getdelim = no; then
20431 HAVE_DECL_GETDELIM=0
20434 if test $HAVE_GETDELIM = 0 || test $REPLACE_GETDELIM = 1; then
20443 gl_LIBOBJS="$gl_LIBOBJS getdelim.$ac_objext"
20446 for ac_func in flockfile funlockfile
20448 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20449 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
20450 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
20451 cat >>confdefs.h <<_ACEOF
20452 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20458 ac_fn_c_check_decl "$LINENO" "getc_unlocked" "ac_cv_have_decl_getc_unlocked" "$ac_includes_default"
20459 if test "x$ac_cv_have_decl_getc_unlocked" = xyes; then :
20465 cat >>confdefs.h <<_ACEOF
20466 #define HAVE_DECL_GETC_UNLOCKED $ac_have_decl
20482 $as_echo "#define GNULIB_TEST_GETDELIM 1" >>confdefs.h
20489 if test $ac_cv_func_getdtablesize != yes; then
20490 HAVE_GETDTABLESIZE=0
20493 if test $HAVE_GETDTABLESIZE = 0; then
20502 gl_LIBOBJS="$gl_LIBOBJS getdtablesize.$ac_objext"
20511 GNULIB_GETDTABLESIZE=1
20517 $as_echo "#define GNULIB_TEST_GETDTABLESIZE 1" >>confdefs.h
20528 gl_getline_needs_run_time_check=no
20529 ac_fn_c_check_func "$LINENO" "getline" "ac_cv_func_getline"
20530 if test "x$ac_cv_func_getline" = xyes; then :
20531 gl_getline_needs_run_time_check=yes
20533 am_cv_func_working_getline=no
20536 if test $gl_getline_needs_run_time_check = yes; then
20537 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getline function" >&5
20538 $as_echo_n "checking for working getline function... " >&6; }
20539 if ${am_cv_func_working_getline+:} false; then :
20540 $as_echo_n "(cached) " >&6
20542 echo fooNbarN | tr -d '\012' | tr N '\012' > conftest.data
20543 if test "$cross_compiling" = yes; then :
20544 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20545 /* end confdefs.h. */
20547 #include <features.h>
20548 #ifdef __GNU_LIBRARY__
20549 #if (__GLIBC__ >= 2) && !defined __UCLIBC__
20555 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20556 $EGREP "Lucky GNU user" >/dev/null 2>&1; then :
20557 am_cv_func_working_getline="guessing yes"
20559 am_cv_func_working_getline="guessing no"
20565 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20566 /* end confdefs.h. */
20568 # include <stdio.h>
20569 # include <stdlib.h>
20570 # include <string.h>
20573 FILE *in = fopen ("./conftest.data", "r");
20577 /* Test result for a NULL buffer and a zero size.
20578 Based on a test program from Karl Heuer. */
20581 int len = getline (&line, &siz, in);
20582 if (!(len == 4 && line && strcmp (line, "foo\n") == 0))
20586 /* Test result for a NULL buffer and a non-zero size.
20587 This crashes on FreeBSD 8.0. */
20589 size_t siz = (size_t)(~0) / 4;
20590 if (getline (&line, &siz, in) == -1)
20597 if ac_fn_c_try_run "$LINENO"; then :
20598 am_cv_func_working_getline=yes
20600 am_cv_func_working_getline=no
20602 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20603 conftest.$ac_objext conftest.beam conftest.$ac_ext
20607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_working_getline" >&5
20608 $as_echo "$am_cv_func_working_getline" >&6; }
20611 if test $ac_cv_have_decl_getline = no; then
20612 HAVE_DECL_GETLINE=0
20615 case "$am_cv_func_working_getline" in
20621 if test $REPLACE_GETLINE = 1; then
20630 gl_LIBOBJS="$gl_LIBOBJS getline.$ac_objext"
20647 $as_echo "#define GNULIB_TEST_GETLINE 1" >>confdefs.h
20656 if test $REPLACE_GETOPT = 1; then
20665 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
20675 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
20680 GNULIB_GL_UNISTD_H_GETOPT=1
20685 $as_echo "#define GNULIB_TEST_GETOPT_GNU 1" >>confdefs.h
20695 if test $REPLACE_GETOPT = 1; then
20699 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
20705 if test $REPLACE_GETOPT = 1; then
20714 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
20724 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
20729 GNULIB_GL_UNISTD_H_GETOPT=1
20735 for ac_func in getpagesize
20737 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
20738 if test "x$ac_cv_func_getpagesize" = xyes; then :
20739 cat >>confdefs.h <<_ACEOF
20740 #define HAVE_GETPAGESIZE 1
20746 if test $ac_cv_func_getpagesize = no; then
20748 for ac_header in OS.h
20750 ac_fn_c_check_header_mongrel "$LINENO" "OS.h" "ac_cv_header_OS_h" "$ac_includes_default"
20751 if test "x$ac_cv_header_OS_h" = xyes; then :
20752 cat >>confdefs.h <<_ACEOF
20753 #define HAVE_OS_H 1
20760 if test $ac_cv_header_OS_h = yes; then
20763 for ac_header in sys/param.h
20765 ac_fn_c_check_header_mongrel "$LINENO" "sys/param.h" "ac_cv_header_sys_param_h" "$ac_includes_default"
20766 if test "x$ac_cv_header_sys_param_h" = xyes; then :
20767 cat >>confdefs.h <<_ACEOF
20768 #define HAVE_SYS_PARAM_H 1
20775 if test $ac_cv_header_sys_param_h = yes; then
20781 REPLACE_GETPAGESIZE=1
20784 ac_fn_c_check_decl "$LINENO" "getpagesize" "ac_cv_have_decl_getpagesize" "$ac_includes_default"
20785 if test "x$ac_cv_have_decl_getpagesize" = xyes; then :
20788 HAVE_DECL_GETPAGESIZE=0
20792 if test $REPLACE_GETPAGESIZE = 1; then
20801 gl_LIBOBJS="$gl_LIBOBJS getpagesize.$ac_objext"
20809 GNULIB_GETPAGESIZE=1
20815 $as_echo "#define GNULIB_TEST_GETPAGESIZE 1" >>confdefs.h
20833 gl_gettimeofday_timezone=void
20834 if test $ac_cv_func_gettimeofday != yes; then
20835 HAVE_GETTIMEOFDAY=0
20840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
20841 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
20842 if ${gl_cv_func_gettimeofday_clobber+:} false; then :
20843 $as_echo_n "(cached) " >&6
20845 if test "$cross_compiling" = yes; then :
20846 # When cross-compiling:
20848 # Guess all is fine on glibc systems.
20849 *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
20850 # If we don't know, assume the worst.
20851 *) gl_cv_func_gettimeofday_clobber="guessing yes" ;;
20855 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20856 /* end confdefs.h. */
20857 #include <string.h>
20858 #include <sys/time.h>
20860 #include <stdlib.h>
20868 struct tm saved_lt;
20870 lt = localtime (&t);
20872 gettimeofday (&tv, NULL);
20873 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
20879 if ac_fn_c_try_run "$LINENO"; then :
20880 gl_cv_func_gettimeofday_clobber=no
20882 gl_cv_func_gettimeofday_clobber=yes
20884 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20885 conftest.$ac_objext conftest.beam conftest.$ac_ext
20889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
20890 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
20892 case "$gl_cv_func_gettimeofday_clobber" in
20894 REPLACE_GETTIMEOFDAY=1
20897 $as_echo "#define gmtime rpl_gmtime" >>confdefs.h
20900 $as_echo "#define localtime rpl_localtime" >>confdefs.h
20904 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
20909 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
20910 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
20911 if ${gl_cv_func_gettimeofday_posix_signature+:} false; then :
20912 $as_echo_n "(cached) " >&6
20914 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20915 /* end confdefs.h. */
20916 #include <sys/time.h>
20918 int gettimeofday (struct timeval *restrict, void *restrict);
20923 /* glibc uses struct timezone * rather than the POSIX void *
20924 if _GNU_SOURCE is defined. However, since the only portable
20925 use of gettimeofday uses NULL as the second parameter, and
20926 since the glibc definition is actually more typesafe, it is
20927 not worth wrapping this to get a compliant signature. */
20928 int (*f) (struct timeval *restrict, void *restrict)
20931 return !(x | c.tv_sec | c.tv_usec);
20937 if ac_fn_c_try_compile "$LINENO"; then :
20938 gl_cv_func_gettimeofday_posix_signature=yes
20940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20941 /* end confdefs.h. */
20942 #include <sys/time.h>
20943 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
20953 if ac_fn_c_try_compile "$LINENO"; then :
20954 gl_cv_func_gettimeofday_posix_signature=almost
20956 gl_cv_func_gettimeofday_posix_signature=no
20958 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20960 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
20963 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
20964 if test $gl_cv_func_gettimeofday_posix_signature = almost; then
20965 gl_gettimeofday_timezone='struct timezone'
20966 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
20967 REPLACE_GETTIMEOFDAY=1
20969 if test $REPLACE_STRUCT_TIMEVAL = 1; then
20970 REPLACE_GETTIMEOFDAY=1
20975 cat >>confdefs.h <<_ACEOF
20976 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
20980 if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
20989 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
20992 for ac_header in sys/timeb.h
20994 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
20995 if test "x$ac_cv_header_sys_timeb_h" = xyes; then :
20996 cat >>confdefs.h <<_ACEOF
20997 #define HAVE_SYS_TIMEB_H 1
21004 for ac_func in _ftime
21006 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
21007 if test "x$ac_cv_func__ftime" = xyes; then :
21008 cat >>confdefs.h <<_ACEOF
21009 #define HAVE__FTIME 1
21022 GNULIB_GETTIMEOFDAY=1
21028 $as_echo "#define GNULIB_TEST_GETTIMEOFDAY 1" >>confdefs.h
21051 if test -n "$STDINT_H"; then
21052 PRIPTR_PREFIX='"l"'
21054 for glpfx in '' l ll I64; do
21056 '') gltype1='int';;
21057 l) gltype1='long int';;
21058 ll) gltype1='long long int';;
21059 I64) gltype1='__int64';;
21061 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21062 /* end confdefs.h. */
21063 #include <stdint.h>
21064 extern intptr_t foo;
21065 extern $gltype1 foo;
21074 if ac_fn_c_try_compile "$LINENO"; then :
21075 PRIPTR_PREFIX='"'$glpfx'"'
21077 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21078 test -n "$PRIPTR_PREFIX" && break
21084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether INT32_MAX < INTMAX_MAX" >&5
21085 $as_echo_n "checking whether INT32_MAX < INTMAX_MAX... " >&6; }
21086 if ${gl_cv_test_INT32_MAX_LT_INTMAX_MAX+:} false; then :
21087 $as_echo_n "(cached) " >&6
21089 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21090 /* end confdefs.h. */
21091 /* Work also in C++ mode. */
21092 #define __STDC_LIMIT_MACROS 1
21094 /* Work if build is not clean. */
21095 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
21097 #include <limits.h>
21099 #include <stdint.h>
21102 #if defined INT32_MAX && defined INTMAX_MAX
21103 #define CONDITION (INT32_MAX < INTMAX_MAX)
21104 #elif HAVE_LONG_LONG_INT
21105 #define CONDITION (sizeof (int) < sizeof (long long int))
21107 #define CONDITION 0
21109 int test[CONDITION ? 1 : -1];
21118 if ac_fn_c_try_compile "$LINENO"; then :
21119 gl_cv_test_INT32_MAX_LT_INTMAX_MAX=yes
21121 gl_cv_test_INT32_MAX_LT_INTMAX_MAX=no
21123 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_INT32_MAX_LT_INTMAX_MAX" >&5
21126 $as_echo "$gl_cv_test_INT32_MAX_LT_INTMAX_MAX" >&6; }
21127 if test $gl_cv_test_INT32_MAX_LT_INTMAX_MAX = yes; then
21128 INT32_MAX_LT_INTMAX_MAX=1;
21130 INT32_MAX_LT_INTMAX_MAX=0;
21134 if test $APPLE_UNIVERSAL_BUILD = 0; then
21136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether INT64_MAX == LONG_MAX" >&5
21137 $as_echo_n "checking whether INT64_MAX == LONG_MAX... " >&6; }
21138 if ${gl_cv_test_INT64_MAX_EQ_LONG_MAX+:} false; then :
21139 $as_echo_n "(cached) " >&6
21141 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21142 /* end confdefs.h. */
21143 /* Work also in C++ mode. */
21144 #define __STDC_LIMIT_MACROS 1
21146 /* Work if build is not clean. */
21147 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
21149 #include <limits.h>
21151 #include <stdint.h>
21154 #if defined INT64_MAX
21155 #define CONDITION (INT64_MAX == LONG_MAX)
21156 #elif HAVE_LONG_LONG_INT
21157 #define CONDITION (sizeof (long long int) == sizeof (long int))
21159 #define CONDITION 0
21161 int test[CONDITION ? 1 : -1];
21170 if ac_fn_c_try_compile "$LINENO"; then :
21171 gl_cv_test_INT64_MAX_EQ_LONG_MAX=yes
21173 gl_cv_test_INT64_MAX_EQ_LONG_MAX=no
21175 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_INT64_MAX_EQ_LONG_MAX" >&5
21178 $as_echo "$gl_cv_test_INT64_MAX_EQ_LONG_MAX" >&6; }
21179 if test $gl_cv_test_INT64_MAX_EQ_LONG_MAX = yes; then
21180 INT64_MAX_EQ_LONG_MAX=1;
21182 INT64_MAX_EQ_LONG_MAX=0;
21187 INT64_MAX_EQ_LONG_MAX=-1
21190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether UINT32_MAX < UINTMAX_MAX" >&5
21191 $as_echo_n "checking whether UINT32_MAX < UINTMAX_MAX... " >&6; }
21192 if ${gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX+:} false; then :
21193 $as_echo_n "(cached) " >&6
21195 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21196 /* end confdefs.h. */
21197 /* Work also in C++ mode. */
21198 #define __STDC_LIMIT_MACROS 1
21200 /* Work if build is not clean. */
21201 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
21203 #include <limits.h>
21205 #include <stdint.h>
21208 #if defined UINT32_MAX && defined UINTMAX_MAX
21209 #define CONDITION (UINT32_MAX < UINTMAX_MAX)
21210 #elif HAVE_LONG_LONG_INT
21211 #define CONDITION (sizeof (unsigned int) < sizeof (unsigned long long int))
21213 #define CONDITION 0
21215 int test[CONDITION ? 1 : -1];
21224 if ac_fn_c_try_compile "$LINENO"; then :
21225 gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX=yes
21227 gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX=no
21229 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX" >&5
21232 $as_echo "$gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX" >&6; }
21233 if test $gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX = yes; then
21234 UINT32_MAX_LT_UINTMAX_MAX=1;
21236 UINT32_MAX_LT_UINTMAX_MAX=0;
21240 if test $APPLE_UNIVERSAL_BUILD = 0; then
21242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether UINT64_MAX == ULONG_MAX" >&5
21243 $as_echo_n "checking whether UINT64_MAX == ULONG_MAX... " >&6; }
21244 if ${gl_cv_test_UINT64_MAX_EQ_ULONG_MAX+:} false; then :
21245 $as_echo_n "(cached) " >&6
21247 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21248 /* end confdefs.h. */
21249 /* Work also in C++ mode. */
21250 #define __STDC_LIMIT_MACROS 1
21252 /* Work if build is not clean. */
21253 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
21255 #include <limits.h>
21257 #include <stdint.h>
21260 #if defined UINT64_MAX
21261 #define CONDITION (UINT64_MAX == ULONG_MAX)
21262 #elif HAVE_LONG_LONG_INT
21263 #define CONDITION (sizeof (unsigned long long int) == sizeof (unsigned long int))
21265 #define CONDITION 0
21267 int test[CONDITION ? 1 : -1];
21276 if ac_fn_c_try_compile "$LINENO"; then :
21277 gl_cv_test_UINT64_MAX_EQ_ULONG_MAX=yes
21279 gl_cv_test_UINT64_MAX_EQ_ULONG_MAX=no
21281 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_UINT64_MAX_EQ_ULONG_MAX" >&5
21284 $as_echo "$gl_cv_test_UINT64_MAX_EQ_ULONG_MAX" >&6; }
21285 if test $gl_cv_test_UINT64_MAX_EQ_ULONG_MAX = yes; then
21286 UINT64_MAX_EQ_ULONG_MAX=1;
21288 UINT64_MAX_EQ_ULONG_MAX=0;
21293 UINT64_MAX_EQ_ULONG_MAX=-1
21303 ac_fn_c_check_decl "$LINENO" "iswblank" "ac_cv_have_decl_iswblank" "
21304 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
21306 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
21307 before <wchar.h>. */
21308 #include <stddef.h>
21312 #include <wctype.h>
21315 if test "x$ac_cv_have_decl_iswblank" = xyes; then :
21321 cat >>confdefs.h <<_ACEOF
21322 #define HAVE_DECL_ISWBLANK $ac_have_decl
21325 if test $ac_cv_func_iswblank = no; then
21327 if test $ac_cv_have_decl_iswblank = yes; then
21331 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_ISWCNTRL = 1; then
21334 if test $HAVE_ISWBLANK = 0 || test $REPLACE_ISWBLANK = 1; then
21340 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_ISWCNTRL = 1; then
21343 if test $HAVE_ISWBLANK = 0 || test $REPLACE_ISWBLANK = 1; then
21352 gl_LIBOBJS="$gl_LIBOBJS iswblank.$ac_objext"
21367 $as_echo "#define GNULIB_TEST_ISWBLANK 1" >>confdefs.h
21385 if test $gl_cv_have_include_next = yes; then
21386 gl_cv_next_langinfo_h='<'langinfo.h'>'
21388 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <langinfo.h>" >&5
21389 $as_echo_n "checking absolute name of <langinfo.h>... " >&6; }
21390 if ${gl_cv_next_langinfo_h+:} false; then :
21391 $as_echo_n "(cached) " >&6
21394 if test $ac_cv_header_langinfo_h = yes; then
21397 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21398 /* end confdefs.h. */
21399 #include <langinfo.h>
21403 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21404 *) gl_absname_cpp="$ac_cpp" ;;
21409 gl_dirsep_regex='[/\\]'
21412 gl_dirsep_regex='\/'
21415 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21417 gl_header_literal_regex=`echo 'langinfo.h' \
21418 | sed -e "$gl_make_literal_regex_sed"`
21419 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21420 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21425 gl_cv_next_langinfo_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21426 sed -n "$gl_absolute_header_sed"`'"'
21428 gl_cv_next_langinfo_h='<'langinfo.h'>'
21433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_langinfo_h" >&5
21434 $as_echo "$gl_cv_next_langinfo_h" >&6; }
21436 NEXT_LANGINFO_H=$gl_cv_next_langinfo_h
21438 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21439 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21440 gl_next_as_first_directive='<'langinfo.h'>'
21442 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21443 gl_next_as_first_directive=$gl_cv_next_langinfo_h
21445 NEXT_AS_FIRST_DIRECTIVE_LANGINFO_H=$gl_next_as_first_directive
21451 HAVE_LANGINFO_CODESET=0
21452 HAVE_LANGINFO_T_FMT_AMPM=0
21453 HAVE_LANGINFO_ERA=0
21454 HAVE_LANGINFO_YESEXPR=0
21456 if test $ac_cv_header_langinfo_h = yes; then
21458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether langinfo.h defines CODESET" >&5
21459 $as_echo_n "checking whether langinfo.h defines CODESET... " >&6; }
21460 if ${gl_cv_header_langinfo_codeset+:} false; then :
21461 $as_echo_n "(cached) " >&6
21463 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21464 /* end confdefs.h. */
21465 #include <langinfo.h>
21476 if ac_fn_c_try_compile "$LINENO"; then :
21477 gl_cv_header_langinfo_codeset=yes
21479 gl_cv_header_langinfo_codeset=no
21481 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_langinfo_codeset" >&5
21485 $as_echo "$gl_cv_header_langinfo_codeset" >&6; }
21486 if test $gl_cv_header_langinfo_codeset = yes; then
21487 HAVE_LANGINFO_CODESET=1
21489 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether langinfo.h defines T_FMT_AMPM" >&5
21490 $as_echo_n "checking whether langinfo.h defines T_FMT_AMPM... " >&6; }
21491 if ${gl_cv_header_langinfo_t_fmt_ampm+:} false; then :
21492 $as_echo_n "(cached) " >&6
21494 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21495 /* end confdefs.h. */
21496 #include <langinfo.h>
21497 int a = T_FMT_AMPM;
21507 if ac_fn_c_try_compile "$LINENO"; then :
21508 gl_cv_header_langinfo_t_fmt_ampm=yes
21510 gl_cv_header_langinfo_t_fmt_ampm=no
21512 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_langinfo_t_fmt_ampm" >&5
21516 $as_echo "$gl_cv_header_langinfo_t_fmt_ampm" >&6; }
21517 if test $gl_cv_header_langinfo_t_fmt_ampm = yes; then
21518 HAVE_LANGINFO_T_FMT_AMPM=1
21520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether langinfo.h defines ERA" >&5
21521 $as_echo_n "checking whether langinfo.h defines ERA... " >&6; }
21522 if ${gl_cv_header_langinfo_era+:} false; then :
21523 $as_echo_n "(cached) " >&6
21525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21526 /* end confdefs.h. */
21527 #include <langinfo.h>
21538 if ac_fn_c_try_compile "$LINENO"; then :
21539 gl_cv_header_langinfo_era=yes
21541 gl_cv_header_langinfo_era=no
21543 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_langinfo_era" >&5
21547 $as_echo "$gl_cv_header_langinfo_era" >&6; }
21548 if test $gl_cv_header_langinfo_era = yes; then
21549 HAVE_LANGINFO_ERA=1
21551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether langinfo.h defines YESEXPR" >&5
21552 $as_echo_n "checking whether langinfo.h defines YESEXPR... " >&6; }
21553 if ${gl_cv_header_langinfo_yesexpr+:} false; then :
21554 $as_echo_n "(cached) " >&6
21556 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21557 /* end confdefs.h. */
21558 #include <langinfo.h>
21569 if ac_fn_c_try_compile "$LINENO"; then :
21570 gl_cv_header_langinfo_yesexpr=yes
21572 gl_cv_header_langinfo_yesexpr=no
21574 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_langinfo_yesexpr" >&5
21578 $as_echo "$gl_cv_header_langinfo_yesexpr" >&6; }
21579 if test $gl_cv_header_langinfo_yesexpr = yes; then
21580 HAVE_LANGINFO_YESEXPR=1
21592 for gl_func in nl_langinfo; do
21593 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
21594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
21595 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
21596 if eval \${$as_gl_Symbol+:} false; then :
21597 $as_echo_n "(cached) " >&6
21599 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21600 /* end confdefs.h. */
21601 #include <langinfo.h>
21612 if ac_fn_c_try_compile "$LINENO"; then :
21613 eval "$as_gl_Symbol=yes"
21615 eval "$as_gl_Symbol=no"
21617 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21619 eval ac_res=\$$as_gl_Symbol
21620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
21621 $as_echo "$ac_res" >&6; }
21622 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
21623 cat >>confdefs.h <<_ACEOF
21624 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
21627 eval ac_cv_have_decl_$gl_func=yes
21637 for ac_func in lchown
21639 ac_fn_c_check_func "$LINENO" "lchown" "ac_cv_func_lchown"
21640 if test "x$ac_cv_func_lchown" = xyes; then :
21641 cat >>confdefs.h <<_ACEOF
21642 #define HAVE_LCHOWN 1
21648 if test $ac_cv_func_lchown = no; then
21651 case "$gl_cv_func_chown_slash_works" in
21657 case "$gl_cv_func_chown_ctime_works" in
21665 if test $HAVE_LCHOWN = 0 || test $REPLACE_LCHOWN = 1; then
21674 gl_LIBOBJS="$gl_LIBOBJS lchown.$ac_objext"
21688 $as_echo "#define GNULIB_TEST_LCHOWN 1" >>confdefs.h
21695 if test $ac_cv_func_link = no; then
21698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether link obeys POSIX" >&5
21699 $as_echo_n "checking whether link obeys POSIX... " >&6; }
21700 if ${gl_cv_func_link_works+:} false; then :
21701 $as_echo_n "(cached) " >&6
21704 # Assume that if we have lstat, we can also check symlinks.
21705 if test $ac_cv_func_lstat = yes; then
21706 ln -s conftest.a conftest.lnk
21708 if test "$cross_compiling" = yes; then :
21710 # Guess yes on glibc systems.
21711 *-gnu*) gl_cv_func_link_works="guessing yes" ;;
21712 # If we don't know, assume the worst.
21713 *) gl_cv_func_link_works="guessing no" ;;
21717 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21718 /* end confdefs.h. */
21719 #include <unistd.h>
21725 if (!link ("conftest.a", "conftest.b/"))
21728 if (!link ("conftest.lnk/", "conftest.b"))
21730 if (rename ("conftest.a", "conftest.b"))
21732 if (!link ("conftest.b", "conftest.lnk"))
21741 if ac_fn_c_try_run "$LINENO"; then :
21742 gl_cv_func_link_works=yes
21744 gl_cv_func_link_works=no
21746 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21747 conftest.$ac_objext conftest.beam conftest.$ac_ext
21750 rm -f conftest.a conftest.b conftest.lnk
21752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_link_works" >&5
21753 $as_echo "$gl_cv_func_link_works" >&6; }
21754 case "$gl_cv_func_link_works" in
21762 if test $HAVE_LINK = 0 || test $REPLACE_LINK = 1; then
21771 gl_LIBOBJS="$gl_LIBOBJS link.$ac_objext"
21785 $as_echo "#define GNULIB_TEST_LINK 1" >>confdefs.h
21790 gl_link_follows_symlinks=0 # assume GNU behavior
21791 if test $ac_cv_func_readlink = yes; then
21792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __xpg4" >&5
21793 $as_echo_n "checking for __xpg4... " >&6; }
21794 if ${gl_cv_have___xpg4+:} false; then :
21795 $as_echo_n "(cached) " >&6
21797 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21798 /* end confdefs.h. */
21808 if ac_fn_c_try_link "$LINENO"; then :
21809 gl_cv_have___xpg4=yes
21811 gl_cv_have___xpg4=no
21813 rm -f core conftest.err conftest.$ac_objext \
21814 conftest$ac_exeext conftest.$ac_ext
21817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have___xpg4" >&5
21818 $as_echo "$gl_cv_have___xpg4" >&6; }
21819 if test $gl_cv_have___xpg4 = yes; then
21820 gl_link_follows_symlinks=-1
21822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether link(2) dereferences a symlink" >&5
21823 $as_echo_n "checking whether link(2) dereferences a symlink... " >&6; }
21824 if ${gl_cv_func_link_follows_symlink+:} false; then :
21825 $as_echo_n "(cached) " >&6
21828 # Create a regular file.
21829 echo > conftest.file
21830 if test "$cross_compiling" = yes; then :
21832 # On glibc/Linux we know the result.
21833 linux*-gnu*) gl_cv_func_link_follows_symlink="guessing no" ;;
21834 # Otherwise, we don't know.
21835 *) gl_cv_func_link_follows_symlink=unknown ;;
21839 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21840 /* end confdefs.h. */
21842 # include <sys/types.h>
21843 # include <sys/stat.h>
21844 # include <unistd.h>
21845 # include <stdlib.h>
21847 # define SAME_INODE(Stat_buf_1, Stat_buf_2) \
21848 ((Stat_buf_1).st_ino == (Stat_buf_2).st_ino \
21849 && (Stat_buf_1).st_dev == (Stat_buf_2).st_dev)
21854 const char *file = "conftest.file";
21855 const char *sym = "conftest.sym";
21856 const char *hard = "conftest.hard";
21857 struct stat sb_file, sb_hard;
21859 /* Create a symlink to the regular file. */
21860 if (symlink (file, sym))
21863 /* Create a hard link to that symlink. */
21864 if (link (sym, hard))
21867 if (lstat (hard, &sb_hard))
21869 if (lstat (file, &sb_file))
21872 /* If the dev/inode of hard and file are the same, then
21873 the link call followed the symlink. */
21874 return SAME_INODE (sb_hard, sb_file) ? 1 : 0;
21878 if ac_fn_c_try_run "$LINENO"; then :
21879 gl_cv_func_link_follows_symlink=no
21881 gl_cv_func_link_follows_symlink=yes
21883 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21884 conftest.$ac_objext conftest.beam conftest.$ac_ext
21887 rm -f conftest.file conftest.sym conftest.hard
21890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_link_follows_symlink" >&5
21891 $as_echo "$gl_cv_func_link_follows_symlink" >&6; }
21892 case "$gl_cv_func_link_follows_symlink" in
21893 *yes) gl_link_follows_symlinks=1 ;;
21894 *no) ;; # already defaulted to 0
21895 *) gl_link_follows_symlinks=-2 ;;
21900 cat >>confdefs.h <<_ACEOF
21901 #define LINK_FOLLOWS_SYMLINKS $gl_link_follows_symlinks
21912 if test $ac_cv_func_linkat = no; then
21915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether linkat(,AT_SYMLINK_FOLLOW) works" >&5
21916 $as_echo_n "checking whether linkat(,AT_SYMLINK_FOLLOW) works... " >&6; }
21917 if ${gl_cv_func_linkat_follow+:} false; then :
21918 $as_echo_n "(cached) " >&6
21920 rm -rf conftest.f1 conftest.f2
21922 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21923 /* end confdefs.h. */
21926 #include <unistd.h>
21928 /* Linux added linkat in 2.6.16, but did not add AT_SYMLINK_FOLLOW
21929 until 2.6.18. Always replace linkat to support older kernels. */
21936 return linkat (AT_FDCWD, "conftest.f1", AT_FDCWD, "conftest.f2",
21937 AT_SYMLINK_FOLLOW);
21942 if ac_fn_c_try_compile "$LINENO"; then :
21943 gl_cv_func_linkat_follow=yes
21945 gl_cv_func_linkat_follow="need runtime check"
21947 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21948 rm -rf conftest.f1 conftest.f2
21950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_linkat_follow" >&5
21951 $as_echo "$gl_cv_func_linkat_follow" >&6; }
21952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether linkat handles trailing slash correctly" >&5
21953 $as_echo_n "checking whether linkat handles trailing slash correctly... " >&6; }
21954 if ${gl_cv_func_linkat_slash+:} false; then :
21955 $as_echo_n "(cached) " >&6
21957 rm -rf conftest.a conftest.b conftest.c conftest.d
21958 if test "$cross_compiling" = yes; then :
21959 # Guess yes on glibc systems, no otherwise.
21961 *-gnu*) gl_cv_func_linkat_slash="guessing yes";;
21962 *) gl_cv_func_linkat_slash="guessing no";;
21966 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21967 /* end confdefs.h. */
21968 #include <unistd.h>
21978 /* Create a regular file. */
21979 fd = open ("conftest.a", O_CREAT | O_EXCL | O_WRONLY, 0600);
21982 if (write (fd, "hello", 5) < 5)
21984 if (close (fd) < 0)
21986 /* Test whether hard links are supported on the current
21988 if (linkat (AT_FDCWD, "conftest.a", AT_FDCWD, "conftest.b",
21989 AT_SYMLINK_FOLLOW) < 0)
21992 /* Test whether a trailing "/" is treated like "/.". */
21993 if (linkat (AT_FDCWD, "conftest.a/", AT_FDCWD, "conftest.c",
21994 AT_SYMLINK_FOLLOW) == 0)
21996 if (linkat (AT_FDCWD, "conftest.a", AT_FDCWD, "conftest.d/",
21997 AT_SYMLINK_FOLLOW) == 0)
22005 if ac_fn_c_try_run "$LINENO"; then :
22006 gl_cv_func_linkat_slash=yes
22008 gl_cv_func_linkat_slash=no
22010 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22011 conftest.$ac_objext conftest.beam conftest.$ac_ext
22014 rm -rf conftest.a conftest.b conftest.c conftest.d
22016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_linkat_slash" >&5
22017 $as_echo "$gl_cv_func_linkat_slash" >&6; }
22018 case "$gl_cv_func_linkat_slash" in
22019 *yes) gl_linkat_slash_bug=0 ;;
22020 *) gl_linkat_slash_bug=1 ;;
22022 if test "$gl_cv_func_linkat_follow" != yes \
22023 || test $gl_linkat_slash_bug = 1; then
22026 cat >>confdefs.h <<_ACEOF
22027 #define LINKAT_TRAILING_SLASH_BUG $gl_linkat_slash_bug
22033 if test $HAVE_LINKAT = 0 || test $REPLACE_LINKAT = 1; then
22042 gl_LIBOBJS="$gl_LIBOBJS linkat.$ac_objext"
22045 if test $HAVE_LINKAT = 0; then
22054 gl_LIBOBJS="$gl_LIBOBJS at-func2.$ac_objext"
22068 $as_echo "#define GNULIB_TEST_LINKAT 1" >>confdefs.h
22080 LOCALCHARSET_TESTS_ENVIRONMENT="CHARSETALIASDIR=\"\$(abs_top_builddir)/$gl_source_base\""
22093 $as_echo "#define _LCONV_C99 1" >>confdefs.h
22098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether locale.h conforms to POSIX:2001" >&5
22099 $as_echo_n "checking whether locale.h conforms to POSIX:2001... " >&6; }
22100 if ${gl_cv_header_locale_h_posix2001+:} false; then :
22101 $as_echo_n "(cached) " >&6
22103 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22104 /* end confdefs.h. */
22105 #include <locale.h>
22106 int x = LC_MESSAGES;
22107 int y = sizeof (((struct lconv *) 0)->decimal_point);
22116 if ac_fn_c_try_compile "$LINENO"; then :
22117 gl_cv_header_locale_h_posix2001=yes
22119 gl_cv_header_locale_h_posix2001=no
22121 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_locale_h_posix2001" >&5
22124 $as_echo "$gl_cv_header_locale_h_posix2001" >&6; }
22127 if test $ac_cv_header_xlocale_h = yes; then
22129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether locale.h defines locale_t" >&5
22130 $as_echo_n "checking whether locale.h defines locale_t... " >&6; }
22131 if ${gl_cv_header_locale_has_locale_t+:} false; then :
22132 $as_echo_n "(cached) " >&6
22134 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22135 /* end confdefs.h. */
22136 #include <locale.h>
22146 if ac_fn_c_try_compile "$LINENO"; then :
22147 gl_cv_header_locale_has_locale_t=yes
22149 gl_cv_header_locale_has_locale_t=no
22151 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_locale_has_locale_t" >&5
22155 $as_echo "$gl_cv_header_locale_has_locale_t" >&6; }
22156 if test $gl_cv_header_locale_has_locale_t = yes; then
22157 gl_cv_header_locale_h_needs_xlocale_h=no
22159 gl_cv_header_locale_h_needs_xlocale_h=yes
22163 gl_cv_header_locale_h_needs_xlocale_h=no
22167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct lconv is properly defined" >&5
22168 $as_echo_n "checking whether struct lconv is properly defined... " >&6; }
22169 if ${gl_cv_sys_struct_lconv_ok+:} false; then :
22170 $as_echo_n "(cached) " >&6
22172 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22173 /* end confdefs.h. */
22174 #include <locale.h>
22176 int x = sizeof (l.decimal_point);
22177 int y = sizeof (l.int_p_cs_precedes);
22186 if ac_fn_c_try_compile "$LINENO"; then :
22187 gl_cv_sys_struct_lconv_ok=yes
22189 gl_cv_sys_struct_lconv_ok=no
22191 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_lconv_ok" >&5
22195 $as_echo "$gl_cv_sys_struct_lconv_ok" >&6; }
22196 if test $gl_cv_sys_struct_lconv_ok = no; then
22197 REPLACE_STRUCT_LCONV=1
22208 if test $gl_cv_have_include_next = yes; then
22209 gl_cv_next_locale_h='<'locale.h'>'
22211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <locale.h>" >&5
22212 $as_echo_n "checking absolute name of <locale.h>... " >&6; }
22213 if ${gl_cv_next_locale_h+:} false; then :
22214 $as_echo_n "(cached) " >&6
22217 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22218 /* end confdefs.h. */
22219 #include <locale.h>
22223 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22224 *) gl_absname_cpp="$ac_cpp" ;;
22229 gl_dirsep_regex='[/\\]'
22232 gl_dirsep_regex='\/'
22235 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22237 gl_header_literal_regex=`echo 'locale.h' \
22238 | sed -e "$gl_make_literal_regex_sed"`
22239 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22240 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22245 gl_cv_next_locale_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22246 sed -n "$gl_absolute_header_sed"`'"'
22250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_locale_h" >&5
22251 $as_echo "$gl_cv_next_locale_h" >&6; }
22253 NEXT_LOCALE_H=$gl_cv_next_locale_h
22255 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22256 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22257 gl_next_as_first_directive='<'locale.h'>'
22259 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22260 gl_next_as_first_directive=$gl_cv_next_locale_h
22262 NEXT_AS_FIRST_DIRECTIVE_LOCALE_H=$gl_next_as_first_directive
22269 for gl_func in setlocale duplocale; do
22270 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
22271 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
22272 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
22273 if eval \${$as_gl_Symbol+:} false; then :
22274 $as_echo_n "(cached) " >&6
22276 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22277 /* end confdefs.h. */
22278 #include <locale.h>
22279 /* Some systems provide declarations in a non-standard header. */
22281 # include <xlocale.h>
22293 if ac_fn_c_try_compile "$LINENO"; then :
22294 eval "$as_gl_Symbol=yes"
22296 eval "$as_gl_Symbol=no"
22298 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22300 eval ac_res=\$$as_gl_Symbol
22301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
22302 $as_echo "$ac_res" >&6; }
22303 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
22304 cat >>confdefs.h <<_ACEOF
22305 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
22308 eval ac_cv_have_decl_$gl_func=yes
22317 if test $REPLACE_STRUCT_LCONV = 1; then
22318 REPLACE_LOCALECONV=1
22321 if test $REPLACE_LOCALECONV = 1; then
22330 gl_LIBOBJS="$gl_LIBOBJS localeconv.$ac_objext"
22333 ac_fn_c_check_member "$LINENO" "struct lconv" "decimal_point" "ac_cv_member_struct_lconv_decimal_point" "#include <locale.h>
22335 if test "x$ac_cv_member_struct_lconv_decimal_point" = xyes; then :
22337 cat >>confdefs.h <<_ACEOF
22338 #define HAVE_STRUCT_LCONV_DECIMAL_POINT 1
22351 GNULIB_LOCALECONV=1
22357 $as_echo "#define GNULIB_TEST_LOCALECONV 1" >>confdefs.h
22367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lseek detects pipes" >&5
22368 $as_echo_n "checking whether lseek detects pipes... " >&6; }
22369 if ${gl_cv_func_lseek_pipe+:} false; then :
22370 $as_echo_n "(cached) " >&6
22374 gl_cv_func_lseek_pipe=no
22377 if test $cross_compiling = no; then
22378 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22379 /* end confdefs.h. */
22381 #include <sys/types.h> /* for off_t */
22382 #include <stdio.h> /* for SEEK_CUR */
22384 # include <unistd.h>
22385 #else /* on Windows with MSVC */
22393 /* Exit with success only if stdin is seekable. */
22394 return lseek (0, (off_t)0, SEEK_CUR) < 0;
22400 if ac_fn_c_try_link "$LINENO"; then :
22401 if test -s conftest$ac_exeext \
22402 && ./conftest$ac_exeext < conftest.$ac_ext \
22403 && test 1 = "`echo hi \
22404 | { ./conftest$ac_exeext; echo $?; cat >/dev/null; }`"; then
22405 gl_cv_func_lseek_pipe=yes
22407 gl_cv_func_lseek_pipe=no
22411 gl_cv_func_lseek_pipe=no
22413 rm -f core conftest.err conftest.$ac_objext \
22414 conftest$ac_exeext conftest.$ac_ext
22416 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22417 /* end confdefs.h. */
22419 #if defined __BEOS__
22420 /* BeOS mistakenly return 0 when trying to seek on pipes. */
22424 if ac_fn_c_try_compile "$LINENO"; then :
22425 gl_cv_func_lseek_pipe=yes
22427 gl_cv_func_lseek_pipe=no
22429 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lseek_pipe" >&5
22436 $as_echo "$gl_cv_func_lseek_pipe" >&6; }
22437 if test $gl_cv_func_lseek_pipe = no; then
22440 $as_echo "#define LSEEK_PIPE_BROKEN 1" >>confdefs.h
22445 if test $WINDOWS_64_BIT_OFF_T = 1; then
22449 if test $REPLACE_LSEEK = 1; then
22458 gl_LIBOBJS="$gl_LIBOBJS lseek.$ac_objext"
22472 $as_echo "#define GNULIB_TEST_LSEEK 1" >>confdefs.h
22479 if test $ac_cv_func_lstat = yes; then
22481 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
22490 if test $REPLACE_LSTAT = 1; then
22499 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
22514 $as_echo "#define GNULIB_TEST_LSTAT 1" >>confdefs.h
22521 for ac_header in stdlib.h
22523 ac_fn_c_check_header_mongrel "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default"
22524 if test "x$ac_cv_header_stdlib_h" = xyes; then :
22525 cat >>confdefs.h <<_ACEOF
22526 #define HAVE_STDLIB_H 1
22533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5
22534 $as_echo_n "checking for GNU libc compatible malloc... " >&6; }
22535 if ${ac_cv_func_malloc_0_nonnull+:} false; then :
22536 $as_echo_n "(cached) " >&6
22538 if test "$cross_compiling" = yes; then :
22540 # Guess yes on platforms where we know the result.
22541 *-gnu* | freebsd* | netbsd* | openbsd* \
22542 | hpux* | solaris* | cygwin* | mingw*)
22543 ac_cv_func_malloc_0_nonnull=yes ;;
22544 # If we don't know, assume the worst.
22545 *) ac_cv_func_malloc_0_nonnull=no ;;
22549 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22550 /* end confdefs.h. */
22551 #if defined STDC_HEADERS || defined HAVE_STDLIB_H
22552 # include <stdlib.h>
22560 return ! malloc (0);
22566 if ac_fn_c_try_run "$LINENO"; then :
22567 ac_cv_func_malloc_0_nonnull=yes
22569 ac_cv_func_malloc_0_nonnull=no
22571 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22572 conftest.$ac_objext conftest.beam conftest.$ac_ext
22577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_malloc_0_nonnull" >&5
22578 $as_echo "$ac_cv_func_malloc_0_nonnull" >&6; }
22579 if test $ac_cv_func_malloc_0_nonnull = yes; then :
22581 $as_echo "#define HAVE_MALLOC_GNU 1" >>confdefs.h
22584 $as_echo "#define HAVE_MALLOC_GNU 0" >>confdefs.h
22591 if test $REPLACE_MALLOC = 1; then
22600 gl_LIBOBJS="$gl_LIBOBJS malloc.$ac_objext"
22605 cat >>confdefs.h <<_ACEOF
22606 #define GNULIB_MALLOC_GNU 1
22613 if test $gl_cv_func_malloc_posix = yes; then
22615 $as_echo "#define HAVE_MALLOC_POSIX 1" >>confdefs.h
22621 if test $REPLACE_MALLOC = 1; then
22630 gl_LIBOBJS="$gl_LIBOBJS malloc.$ac_objext"
22638 GNULIB_MALLOC_POSIX=1
22644 $as_echo "#define GNULIB_TEST_MALLOC_POSIX 1" >>confdefs.h
22665 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
22669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
22670 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
22671 if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then :
22672 $as_echo_n "(cached) " >&6
22676 # Guess no on AIX and OSF/1.
22677 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
22678 # Guess yes otherwise.
22679 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
22681 if test $LOCALE_JA != none; then
22682 if test "$cross_compiling" = yes; then :
22685 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22686 /* end confdefs.h. */
22688 #include <locale.h>
22689 #include <string.h>
22690 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
22692 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
22693 included before <wchar.h>. */
22694 #include <stddef.h>
22700 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
22702 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
22706 memset (&state, '\0', sizeof (mbstate_t));
22707 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
22708 if (mbsinit (&state))
22714 if ac_fn_c_try_run "$LINENO"; then :
22715 gl_cv_func_mbrtowc_incomplete_state=yes
22717 gl_cv_func_mbrtowc_incomplete_state=no
22719 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22720 conftest.$ac_objext conftest.beam conftest.$ac_ext
22726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
22727 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
22732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
22733 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
22734 if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then :
22735 $as_echo_n "(cached) " >&6
22739 # Guess no on Solaris 8.
22740 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
22741 # Guess yes otherwise.
22742 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
22744 if test $LOCALE_ZH_CN != none; then
22745 if test "$cross_compiling" = yes; then :
22748 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22749 /* end confdefs.h. */
22751 #include <locale.h>
22752 #include <stdlib.h>
22753 #include <string.h>
22754 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
22756 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
22757 included before <wchar.h>. */
22758 #include <stddef.h>
22764 /* This fails on Solaris 8:
22765 mbrtowc returns 2, and sets wc to 0x00F0.
22766 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
22767 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
22769 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
22773 memset (&state, '\0', sizeof (mbstate_t));
22774 if (mbrtowc (&wc, input + 3, 6, &state) != 4
22775 && mbtowc (&wc, input + 3, 6) == 4)
22781 if ac_fn_c_try_run "$LINENO"; then :
22782 gl_cv_func_mbrtowc_sanitycheck=yes
22784 gl_cv_func_mbrtowc_sanitycheck=no
22786 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22787 conftest.$ac_objext conftest.beam conftest.$ac_ext
22793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
22794 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
22796 REPLACE_MBSTATE_T=0
22797 case "$gl_cv_func_mbrtowc_incomplete_state" in
22799 *) REPLACE_MBSTATE_T=1 ;;
22801 case "$gl_cv_func_mbrtowc_sanitycheck" in
22803 *) REPLACE_MBSTATE_T=1 ;;
22806 REPLACE_MBSTATE_T=1
22811 if test $ac_cv_func_mbrtowc = no; then
22813 ac_fn_c_check_decl "$LINENO" "mbrtowc" "ac_cv_have_decl_mbrtowc" "
22814 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
22816 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
22817 included before <wchar.h>. */
22818 #include <stddef.h>
22824 if test "x$ac_cv_have_decl_mbrtowc" = xyes; then :
22830 cat >>confdefs.h <<_ACEOF
22831 #define HAVE_DECL_MBRTOWC $ac_have_decl
22834 if test $ac_cv_have_decl_mbrtowc = yes; then
22838 if test $REPLACE_MBSTATE_T = 1; then
22844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles a NULL pwc argument" >&5
22845 $as_echo_n "checking whether mbrtowc handles a NULL pwc argument... " >&6; }
22846 if ${gl_cv_func_mbrtowc_null_arg1+:} false; then :
22847 $as_echo_n "(cached) " >&6
22851 # Guess no on Solaris.
22852 solaris*) gl_cv_func_mbrtowc_null_arg1="guessing no" ;;
22853 # Guess yes otherwise.
22854 *) gl_cv_func_mbrtowc_null_arg1="guessing yes" ;;
22856 if test $LOCALE_FR_UTF8 != none; then
22857 if test "$cross_compiling" = yes; then :
22860 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22861 /* end confdefs.h. */
22863 #include <locale.h>
22864 #include <stdlib.h>
22865 #include <string.h>
22866 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
22868 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
22869 included before <wchar.h>. */
22870 #include <stddef.h>
22878 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
22880 char input[] = "\303\237er";
22885 memset (&state, '\0', sizeof (mbstate_t));
22886 wc = (wchar_t) 0xBADFACE;
22887 ret = mbrtowc (&wc, input, 5, &state);
22890 if (!mbsinit (&state))
22893 memset (&state, '\0', sizeof (mbstate_t));
22894 ret = mbrtowc (NULL, input, 5, &state);
22895 if (ret != 2) /* Solaris 7 fails here: ret is -1. */
22897 if (!mbsinit (&state))
22903 if ac_fn_c_try_run "$LINENO"; then :
22904 gl_cv_func_mbrtowc_null_arg1=yes
22906 gl_cv_func_mbrtowc_null_arg1=no
22908 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22909 conftest.$ac_objext conftest.beam conftest.$ac_ext
22915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_null_arg1" >&5
22916 $as_echo "$gl_cv_func_mbrtowc_null_arg1" >&6; }
22921 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles a NULL string argument" >&5
22922 $as_echo_n "checking whether mbrtowc handles a NULL string argument... " >&6; }
22923 if ${gl_cv_func_mbrtowc_null_arg2+:} false; then :
22924 $as_echo_n "(cached) " >&6
22928 # Guess no on OSF/1.
22929 osf*) gl_cv_func_mbrtowc_null_arg2="guessing no" ;;
22930 # Guess yes otherwise.
22931 *) gl_cv_func_mbrtowc_null_arg2="guessing yes" ;;
22933 if test $LOCALE_FR_UTF8 != none; then
22934 if test "$cross_compiling" = yes; then :
22937 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22938 /* end confdefs.h. */
22940 #include <locale.h>
22941 #include <string.h>
22942 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
22944 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
22945 included before <wchar.h>. */
22946 #include <stddef.h>
22952 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
22958 memset (&state, '\0', sizeof (mbstate_t));
22959 wc = (wchar_t) 0xBADFACE;
22960 mbrtowc (&wc, NULL, 5, &state);
22961 /* Check that wc was not modified. */
22962 if (wc != (wchar_t) 0xBADFACE)
22968 if ac_fn_c_try_run "$LINENO"; then :
22969 gl_cv_func_mbrtowc_null_arg2=yes
22971 gl_cv_func_mbrtowc_null_arg2=no
22973 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22974 conftest.$ac_objext conftest.beam conftest.$ac_ext
22980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_null_arg2" >&5
22981 $as_echo "$gl_cv_func_mbrtowc_null_arg2" >&6; }
22988 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc has a correct return value" >&5
22989 $as_echo_n "checking whether mbrtowc has a correct return value... " >&6; }
22990 if ${gl_cv_func_mbrtowc_retval+:} false; then :
22991 $as_echo_n "(cached) " >&6
22995 # Guess no on HP-UX, Solaris, native Windows.
22996 hpux* | solaris* | mingw*) gl_cv_func_mbrtowc_retval="guessing no" ;;
22997 # Guess yes otherwise.
22998 *) gl_cv_func_mbrtowc_retval="guessing yes" ;;
23000 if test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none \
23001 || { case "$host_os" in mingw*) true;; *) false;; esac; }; then
23002 if test "$cross_compiling" = yes; then :
23005 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23006 /* end confdefs.h. */
23008 #include <locale.h>
23009 #include <string.h>
23010 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
23012 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
23013 included before <wchar.h>. */
23014 #include <stddef.h>
23021 int found_some_locale = 0;
23022 /* This fails on Solaris. */
23023 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
23025 char input[] = "B\303\274\303\237er"; /* "Büßer" */
23029 memset (&state, '\0', sizeof (mbstate_t));
23030 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
23033 if (mbrtowc (&wc, input + 2, 5, &state) != 1)
23036 found_some_locale = 1;
23038 /* This fails on HP-UX 11.11. */
23039 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
23041 char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
23045 memset (&state, '\0', sizeof (mbstate_t));
23046 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
23049 if (mbrtowc (&wc, input + 2, 5, &state) != 2)
23052 found_some_locale = 1;
23054 /* This fails on native Windows. */
23055 if (setlocale (LC_ALL, "Japanese_Japan.932") != NULL)
23057 char input[] = "<\223\372\226\173\214\352>"; /* "<日本語>" */
23061 memset (&state, '\0', sizeof (mbstate_t));
23062 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
23065 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
23068 found_some_locale = 1;
23070 if (setlocale (LC_ALL, "Chinese_Taiwan.950") != NULL)
23072 char input[] = "<\244\351\245\273\273\171>"; /* "<日本語>" */
23076 memset (&state, '\0', sizeof (mbstate_t));
23077 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
23080 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
23083 found_some_locale = 1;
23085 if (setlocale (LC_ALL, "Chinese_China.936") != NULL)
23087 char input[] = "<\310\325\261\276\325\132>"; /* "<日本語>" */
23091 memset (&state, '\0', sizeof (mbstate_t));
23092 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
23095 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
23098 found_some_locale = 1;
23100 return (found_some_locale ? result : 77);
23103 if ac_fn_c_try_run "$LINENO"; then :
23104 gl_cv_func_mbrtowc_retval=yes
23106 if test $? != 77; then
23107 gl_cv_func_mbrtowc_retval=no
23111 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23112 conftest.$ac_objext conftest.beam conftest.$ac_ext
23118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_retval" >&5
23119 $as_echo "$gl_cv_func_mbrtowc_retval" >&6; }
23124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc returns 0 when parsing a NUL character" >&5
23125 $as_echo_n "checking whether mbrtowc returns 0 when parsing a NUL character... " >&6; }
23126 if ${gl_cv_func_mbrtowc_nul_retval+:} false; then :
23127 $as_echo_n "(cached) " >&6
23131 # Guess no on Solaris 8 and 9.
23132 solaris2.[89]) gl_cv_func_mbrtowc_nul_retval="guessing no" ;;
23133 # Guess yes otherwise.
23134 *) gl_cv_func_mbrtowc_nul_retval="guessing yes" ;;
23136 if test $LOCALE_ZH_CN != none; then
23137 if test "$cross_compiling" = yes; then :
23140 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23141 /* end confdefs.h. */
23143 #include <locale.h>
23144 #include <string.h>
23145 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
23147 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
23148 included before <wchar.h>. */
23149 #include <stddef.h>
23155 /* This fails on Solaris 8 and 9. */
23156 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
23161 memset (&state, '\0', sizeof (mbstate_t));
23162 if (mbrtowc (&wc, "", 1, &state) != 0)
23168 if ac_fn_c_try_run "$LINENO"; then :
23169 gl_cv_func_mbrtowc_nul_retval=yes
23171 gl_cv_func_mbrtowc_nul_retval=no
23173 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23174 conftest.$ac_objext conftest.beam conftest.$ac_ext
23180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_nul_retval" >&5
23181 $as_echo "$gl_cv_func_mbrtowc_nul_retval" >&6; }
23183 case "$gl_cv_func_mbrtowc_null_arg1" in
23186 $as_echo "#define MBRTOWC_NULL_ARG1_BUG 1" >>confdefs.h
23191 case "$gl_cv_func_mbrtowc_null_arg2" in
23194 $as_echo "#define MBRTOWC_NULL_ARG2_BUG 1" >>confdefs.h
23199 case "$gl_cv_func_mbrtowc_retval" in
23202 $as_echo "#define MBRTOWC_RETVAL_BUG 1" >>confdefs.h
23207 case "$gl_cv_func_mbrtowc_nul_retval" in
23210 $as_echo "#define MBRTOWC_NUL_RETVAL_BUG 1" >>confdefs.h
23218 if test $HAVE_MBRTOWC = 0 || test $REPLACE_MBRTOWC = 1; then
23227 gl_LIBOBJS="$gl_LIBOBJS mbrtowc.$ac_objext"
23244 $as_echo "#define GNULIB_TEST_MBRTOWC 1" >>confdefs.h
23253 GNULIB_MBSCASECMP=1
23259 $as_echo "#define GNULIB_TEST_MBSCASECMP 1" >>confdefs.h
23274 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
23278 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
23279 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
23280 if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then :
23281 $as_echo_n "(cached) " >&6
23285 # Guess no on AIX and OSF/1.
23286 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
23287 # Guess yes otherwise.
23288 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
23290 if test $LOCALE_JA != none; then
23291 if test "$cross_compiling" = yes; then :
23294 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23295 /* end confdefs.h. */
23297 #include <locale.h>
23298 #include <string.h>
23299 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
23301 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
23302 included before <wchar.h>. */
23303 #include <stddef.h>
23309 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
23311 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
23315 memset (&state, '\0', sizeof (mbstate_t));
23316 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
23317 if (mbsinit (&state))
23323 if ac_fn_c_try_run "$LINENO"; then :
23324 gl_cv_func_mbrtowc_incomplete_state=yes
23326 gl_cv_func_mbrtowc_incomplete_state=no
23328 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23329 conftest.$ac_objext conftest.beam conftest.$ac_ext
23335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
23336 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
23341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
23342 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
23343 if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then :
23344 $as_echo_n "(cached) " >&6
23348 # Guess no on Solaris 8.
23349 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
23350 # Guess yes otherwise.
23351 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
23353 if test $LOCALE_ZH_CN != none; then
23354 if test "$cross_compiling" = yes; then :
23357 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23358 /* end confdefs.h. */
23360 #include <locale.h>
23361 #include <stdlib.h>
23362 #include <string.h>
23363 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
23365 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
23366 included before <wchar.h>. */
23367 #include <stddef.h>
23373 /* This fails on Solaris 8:
23374 mbrtowc returns 2, and sets wc to 0x00F0.
23375 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
23376 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
23378 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
23382 memset (&state, '\0', sizeof (mbstate_t));
23383 if (mbrtowc (&wc, input + 3, 6, &state) != 4
23384 && mbtowc (&wc, input + 3, 6) == 4)
23390 if ac_fn_c_try_run "$LINENO"; then :
23391 gl_cv_func_mbrtowc_sanitycheck=yes
23393 gl_cv_func_mbrtowc_sanitycheck=no
23395 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23396 conftest.$ac_objext conftest.beam conftest.$ac_ext
23402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
23403 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
23405 REPLACE_MBSTATE_T=0
23406 case "$gl_cv_func_mbrtowc_incomplete_state" in
23408 *) REPLACE_MBSTATE_T=1 ;;
23410 case "$gl_cv_func_mbrtowc_sanitycheck" in
23412 *) REPLACE_MBSTATE_T=1 ;;
23415 REPLACE_MBSTATE_T=1
23420 if test $ac_cv_func_mbsinit = no; then
23422 ac_fn_c_check_decl "$LINENO" "mbsinit" "ac_cv_have_decl_mbsinit" "
23423 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
23425 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
23426 included before <wchar.h>. */
23427 #include <stddef.h>
23433 if test "x$ac_cv_have_decl_mbsinit" = xyes; then :
23439 cat >>confdefs.h <<_ACEOF
23440 #define HAVE_DECL_MBSINIT $ac_have_decl
23443 if test $ac_cv_have_decl_mbsinit = yes; then
23447 if test $REPLACE_MBSTATE_T = 1; then
23451 mingw*) REPLACE_MBSINIT=1 ;;
23456 if test $HAVE_MBSINIT = 0 || test $REPLACE_MBSINIT = 1; then
23465 gl_LIBOBJS="$gl_LIBOBJS mbsinit.$ac_objext"
23482 $as_echo "#define GNULIB_TEST_MBSINIT 1" >>confdefs.h
23496 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
23500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
23501 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
23502 if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then :
23503 $as_echo_n "(cached) " >&6
23507 # Guess no on AIX and OSF/1.
23508 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
23509 # Guess yes otherwise.
23510 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
23512 if test $LOCALE_JA != none; then
23513 if test "$cross_compiling" = yes; then :
23516 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23517 /* end confdefs.h. */
23519 #include <locale.h>
23520 #include <string.h>
23521 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
23523 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
23524 included before <wchar.h>. */
23525 #include <stddef.h>
23531 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
23533 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
23537 memset (&state, '\0', sizeof (mbstate_t));
23538 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
23539 if (mbsinit (&state))
23545 if ac_fn_c_try_run "$LINENO"; then :
23546 gl_cv_func_mbrtowc_incomplete_state=yes
23548 gl_cv_func_mbrtowc_incomplete_state=no
23550 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23551 conftest.$ac_objext conftest.beam conftest.$ac_ext
23557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
23558 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
23563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
23564 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
23565 if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then :
23566 $as_echo_n "(cached) " >&6
23570 # Guess no on Solaris 8.
23571 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
23572 # Guess yes otherwise.
23573 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
23575 if test $LOCALE_ZH_CN != none; then
23576 if test "$cross_compiling" = yes; then :
23579 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23580 /* end confdefs.h. */
23582 #include <locale.h>
23583 #include <stdlib.h>
23584 #include <string.h>
23585 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
23587 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
23588 included before <wchar.h>. */
23589 #include <stddef.h>
23595 /* This fails on Solaris 8:
23596 mbrtowc returns 2, and sets wc to 0x00F0.
23597 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
23598 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
23600 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
23604 memset (&state, '\0', sizeof (mbstate_t));
23605 if (mbrtowc (&wc, input + 3, 6, &state) != 4
23606 && mbtowc (&wc, input + 3, 6) == 4)
23612 if ac_fn_c_try_run "$LINENO"; then :
23613 gl_cv_func_mbrtowc_sanitycheck=yes
23615 gl_cv_func_mbrtowc_sanitycheck=no
23617 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23618 conftest.$ac_objext conftest.beam conftest.$ac_ext
23624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
23625 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
23627 REPLACE_MBSTATE_T=0
23628 case "$gl_cv_func_mbrtowc_incomplete_state" in
23630 *) REPLACE_MBSTATE_T=1 ;;
23632 case "$gl_cv_func_mbrtowc_sanitycheck" in
23634 *) REPLACE_MBSTATE_T=1 ;;
23637 REPLACE_MBSTATE_T=1
23642 if test $ac_cv_func_mbsrtowcs = no; then
23644 ac_fn_c_check_decl "$LINENO" "mbsrtowcs" "ac_cv_have_decl_mbsrtowcs" "
23645 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
23647 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
23648 included before <wchar.h>. */
23649 #include <stddef.h>
23655 if test "x$ac_cv_have_decl_mbsrtowcs" = xyes; then :
23661 cat >>confdefs.h <<_ACEOF
23662 #define HAVE_DECL_MBSRTOWCS $ac_have_decl
23665 if test $ac_cv_have_decl_mbsrtowcs = yes; then
23666 REPLACE_MBSRTOWCS=1
23669 if test $REPLACE_MBSTATE_T = 1; then
23670 REPLACE_MBSRTOWCS=1
23678 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbsrtowcs works" >&5
23679 $as_echo_n "checking whether mbsrtowcs works... " >&6; }
23680 if ${gl_cv_func_mbsrtowcs_works+:} false; then :
23681 $as_echo_n "(cached) " >&6
23685 # Guess no on HP-UX, Solaris, mingw.
23686 hpux* | solaris* | mingw*) gl_cv_func_mbsrtowcs_works="guessing no" ;;
23687 # Guess yes otherwise.
23688 *) gl_cv_func_mbsrtowcs_works="guessing yes" ;;
23690 if test $LOCALE_FR != none || test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none || test $LOCALE_ZH_CN != none; then
23691 if test "$cross_compiling" = yes; then :
23694 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23695 /* end confdefs.h. */
23697 #include <locale.h>
23698 #include <string.h>
23699 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
23701 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
23702 included before <wchar.h>. */
23703 #include <stddef.h>
23710 /* Test whether the function supports a NULL destination argument.
23711 This fails on native Windows. */
23712 if (setlocale (LC_ALL, "$LOCALE_FR") != NULL)
23714 const char input[] = "\337er";
23715 const char *src = input;
23718 memset (&state, '\0', sizeof (mbstate_t));
23719 if (mbsrtowcs (NULL, &src, 1, &state) != 3
23723 /* Test whether the function works when started with a conversion state
23724 in non-initial state. This fails on HP-UX 11.11 and Solaris 10. */
23725 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
23727 const char input[] = "B\303\274\303\237er";
23730 memset (&state, '\0', sizeof (mbstate_t));
23731 if (mbrtowc (NULL, input + 1, 1, &state) == (size_t)(-2))
23732 if (!mbsinit (&state))
23734 const char *src = input + 2;
23735 if (mbsrtowcs (NULL, &src, 10, &state) != 4)
23739 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
23741 const char input[] = "<\306\374\313\334\270\354>";
23744 memset (&state, '\0', sizeof (mbstate_t));
23745 if (mbrtowc (NULL, input + 3, 1, &state) == (size_t)(-2))
23746 if (!mbsinit (&state))
23748 const char *src = input + 4;
23749 if (mbsrtowcs (NULL, &src, 10, &state) != 3)
23753 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
23755 const char input[] = "B\250\271\201\060\211\070er";
23758 memset (&state, '\0', sizeof (mbstate_t));
23759 if (mbrtowc (NULL, input + 1, 1, &state) == (size_t)(-2))
23760 if (!mbsinit (&state))
23762 const char *src = input + 2;
23763 if (mbsrtowcs (NULL, &src, 10, &state) != 4)
23770 if ac_fn_c_try_run "$LINENO"; then :
23771 gl_cv_func_mbsrtowcs_works=yes
23773 gl_cv_func_mbsrtowcs_works=no
23775 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23776 conftest.$ac_objext conftest.beam conftest.$ac_ext
23782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbsrtowcs_works" >&5
23783 $as_echo "$gl_cv_func_mbsrtowcs_works" >&6; }
23785 case "$gl_cv_func_mbsrtowcs_works" in
23787 *) REPLACE_MBSRTOWCS=1 ;;
23792 if test $HAVE_MBSRTOWCS = 0 || test $REPLACE_MBSRTOWCS = 1; then
23801 gl_LIBOBJS="$gl_LIBOBJS mbsrtowcs.$ac_objext"
23811 gl_LIBOBJS="$gl_LIBOBJS mbsrtowcs-state.$ac_objext"
23828 $as_echo "#define GNULIB_TEST_MBSRTOWCS 1" >>confdefs.h
23839 if test $REPLACE_MBTOWC = 1; then
23848 gl_LIBOBJS="$gl_LIBOBJS mbtowc.$ac_objext"
23865 $as_echo "#define GNULIB_TEST_MBTOWC 1" >>confdefs.h
23874 if test $HAVE_MEMCHR = 0 || test $REPLACE_MEMCHR = 1; then
23883 gl_LIBOBJS="$gl_LIBOBJS memchr.$ac_objext"
23886 for ac_header in bp-sym.h
23888 ac_fn_c_check_header_mongrel "$LINENO" "bp-sym.h" "ac_cv_header_bp_sym_h" "$ac_includes_default"
23889 if test "x$ac_cv_header_bp_sym_h" = xyes; then :
23890 cat >>confdefs.h <<_ACEOF
23891 #define HAVE_BP_SYM_H 1
23911 $as_echo "#define GNULIB_TEST_MEMCHR 1" >>confdefs.h
23921 for ac_func in mempcpy
23923 ac_fn_c_check_func "$LINENO" "mempcpy" "ac_cv_func_mempcpy"
23924 if test "x$ac_cv_func_mempcpy" = xyes; then :
23925 cat >>confdefs.h <<_ACEOF
23926 #define HAVE_MEMPCPY 1
23932 if test $ac_cv_func_mempcpy = no; then
23936 if test $HAVE_MEMPCPY = 0; then
23945 gl_LIBOBJS="$gl_LIBOBJS mempcpy.$ac_objext"
23962 $as_echo "#define GNULIB_TEST_MEMPCPY 1" >>confdefs.h
23971 if test $ac_cv_have_decl_memrchr = no; then
23972 HAVE_DECL_MEMRCHR=0
23975 for ac_func in memrchr
23977 ac_fn_c_check_func "$LINENO" "memrchr" "ac_cv_func_memrchr"
23978 if test "x$ac_cv_func_memrchr" = xyes; then :
23979 cat >>confdefs.h <<_ACEOF
23980 #define HAVE_MEMRCHR 1
23987 if test $ac_cv_func_memrchr = no; then
23996 gl_LIBOBJS="$gl_LIBOBJS memrchr.$ac_objext"
24011 $as_echo "#define GNULIB_TEST_MEMRCHR 1" >>confdefs.h
24017 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mkdir handles trailing slash" >&5
24018 $as_echo_n "checking whether mkdir handles trailing slash... " >&6; }
24019 if ${gl_cv_func_mkdir_trailing_slash_works+:} false; then :
24020 $as_echo_n "(cached) " >&6
24022 rm -rf conftest.dir
24023 if test "$cross_compiling" = yes; then :
24025 # Guess yes on glibc systems.
24026 *-gnu*) gl_cv_func_mkdir_trailing_slash_works="guessing yes" ;;
24027 # If we don't know, assume the worst.
24028 *) gl_cv_func_mkdir_trailing_slash_works="guessing no" ;;
24032 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24033 /* end confdefs.h. */
24035 # include <sys/types.h>
24036 # include <sys/stat.h>
24041 return mkdir ("conftest.dir/", 0700);
24046 if ac_fn_c_try_run "$LINENO"; then :
24047 gl_cv_func_mkdir_trailing_slash_works=yes
24049 gl_cv_func_mkdir_trailing_slash_works=no
24051 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24052 conftest.$ac_objext conftest.beam conftest.$ac_ext
24055 rm -rf conftest.dir
24059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mkdir_trailing_slash_works" >&5
24060 $as_echo "$gl_cv_func_mkdir_trailing_slash_works" >&6; }
24061 case "$gl_cv_func_mkdir_trailing_slash_works" in
24068 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mkdir handles trailing dot" >&5
24069 $as_echo_n "checking whether mkdir handles trailing dot... " >&6; }
24070 if ${gl_cv_func_mkdir_trailing_dot_works+:} false; then :
24071 $as_echo_n "(cached) " >&6
24073 rm -rf conftest.dir
24074 if test "$cross_compiling" = yes; then :
24076 # Guess yes on glibc systems.
24077 *-gnu*) gl_cv_func_mkdir_trailing_dot_works="guessing yes" ;;
24078 # If we don't know, assume the worst.
24079 *) gl_cv_func_mkdir_trailing_dot_works="guessing no" ;;
24083 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24084 /* end confdefs.h. */
24086 # include <sys/types.h>
24087 # include <sys/stat.h>
24092 return !mkdir ("conftest.dir/./", 0700);
24097 if ac_fn_c_try_run "$LINENO"; then :
24098 gl_cv_func_mkdir_trailing_dot_works=yes
24100 gl_cv_func_mkdir_trailing_dot_works=no
24102 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24103 conftest.$ac_objext conftest.beam conftest.$ac_ext
24106 rm -rf conftest.dir
24110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mkdir_trailing_dot_works" >&5
24111 $as_echo "$gl_cv_func_mkdir_trailing_dot_works" >&6; }
24112 case "$gl_cv_func_mkdir_trailing_dot_works" in
24117 $as_echo "#define FUNC_MKDIR_DOT_BUG 1" >>confdefs.h
24122 if test $REPLACE_MKDIR = 1; then
24131 gl_LIBOBJS="$gl_LIBOBJS mkdir.$ac_objext"
24138 if test $ac_cv_func_mkdirat != yes; then
24142 if test $HAVE_MKDIRAT = 0; then
24151 gl_LIBOBJS="$gl_LIBOBJS mkdirat.$ac_objext"
24168 $as_echo "#define GNULIB_TEST_MKDIRAT 1" >>confdefs.h
24174 for ac_func in mkdtemp
24176 ac_fn_c_check_func "$LINENO" "mkdtemp" "ac_cv_func_mkdtemp"
24177 if test "x$ac_cv_func_mkdtemp" = xyes; then :
24178 cat >>confdefs.h <<_ACEOF
24179 #define HAVE_MKDTEMP 1
24185 if test $ac_cv_func_mkdtemp = no; then
24189 if test $HAVE_MKDTEMP = 0; then
24198 gl_LIBOBJS="$gl_LIBOBJS mkdtemp.$ac_objext"
24214 $as_echo "#define GNULIB_TEST_MKDTEMP 1" >>confdefs.h
24221 if test $ac_cv_func_mkfifo = no; then
24225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mkfifo rejects trailing slashes" >&5
24226 $as_echo_n "checking whether mkfifo rejects trailing slashes... " >&6; }
24227 if ${gl_cv_func_mkfifo_works+:} false; then :
24228 $as_echo_n "(cached) " >&6
24230 # Assume that if we have lstat, we can also check symlinks.
24231 if test $ac_cv_func_lstat = yes; then
24232 ln -s conftest.tmp conftest.lnk
24234 if test "$cross_compiling" = yes; then :
24236 # Guess yes on glibc systems.
24237 *-gnu*) gl_cv_func_mkfifo_works="guessing yes" ;;
24238 # If we don't know, assume the worst.
24239 *) gl_cv_func_mkfifo_works="guessing no" ;;
24243 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24244 /* end confdefs.h. */
24245 #include <sys/stat.h>
24251 if (!mkfifo ("conftest.tmp/", 0600))
24254 if (!mkfifo ("conftest.lnk/", 0600))
24263 if ac_fn_c_try_run "$LINENO"; then :
24264 gl_cv_func_mkfifo_works=yes
24266 gl_cv_func_mkfifo_works=no
24268 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24269 conftest.$ac_objext conftest.beam conftest.$ac_ext
24272 rm -f conftest.tmp conftest.lnk
24274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mkfifo_works" >&5
24275 $as_echo "$gl_cv_func_mkfifo_works" >&6; }
24276 case "$gl_cv_func_mkfifo_works" in
24280 $as_echo "#define MKFIFO_TRAILING_SLASH_BUG 1" >>confdefs.h
24287 if test $HAVE_MKFIFO = 0 || test $REPLACE_MKFIFO = 1; then
24296 gl_LIBOBJS="$gl_LIBOBJS mkfifo.$ac_objext"
24310 $as_echo "#define GNULIB_TEST_MKFIFO 1" >>confdefs.h
24319 if test $ac_cv_func_mkfifoat = no; then
24320 # No known system has mkfifoat but not mknodat
24325 if test $HAVE_MKFIFOAT = 0; then
24334 gl_LIBOBJS="$gl_LIBOBJS mkfifoat.$ac_objext"
24337 if test $HAVE_MKNODAT = 0; then
24346 gl_LIBOBJS="$gl_LIBOBJS mknodat.$ac_objext"
24360 $as_echo "#define GNULIB_TEST_MKFIFOAT 1" >>confdefs.h
24375 $as_echo "#define GNULIB_TEST_MKNODAT 1" >>confdefs.h
24384 if test $ac_cv_func_mknod = no; then
24387 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mknod can create fifo without root privileges" >&5
24388 $as_echo_n "checking whether mknod can create fifo without root privileges... " >&6; }
24389 if ${gl_cv_func_mknod_works+:} false; then :
24390 $as_echo_n "(cached) " >&6
24392 if test "$cross_compiling" = yes; then :
24394 # Guess yes on glibc systems.
24395 *-gnu*) gl_cv_func_mknod_works="guessing yes" ;;
24396 # If we don't know, assume the worst.
24397 *) gl_cv_func_mknod_works="guessing no" ;;
24401 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24402 /* end confdefs.h. */
24403 #include <sys/stat.h>
24404 #include <unistd.h>
24406 /* Copied from root-uid.h. FIXME: Just use root-uid.h. */
24408 # define ROOT_UID 65535
24410 # define ROOT_UID 0
24416 /* Indeterminate for super-user, assume no. Why are you running
24417 configure as root, anyway? */
24418 if (geteuid () == ROOT_UID) return 99;
24419 if (mknod ("conftest.fifo", S_IFIFO | 0600, 0)) return 2;
24424 if ac_fn_c_try_run "$LINENO"; then :
24425 gl_cv_func_mknod_works=yes
24427 if test $? = 99 && test x"$FORCE_UNSAFE_CONFIGURE" = x; then
24428 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
24429 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24430 as_fn_error $? "you should not run configure as root (set FORCE_UNSAFE_CONFIGURE=1 in environment to bypass this check)
24431 See \`config.log' for more details" "$LINENO" 5; }
24433 gl_cv_func_mknod_works=no
24435 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24436 conftest.$ac_objext conftest.beam conftest.$ac_ext
24439 rm -f conftest.fifo
24441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mknod_works" >&5
24442 $as_echo "$gl_cv_func_mknod_works" >&6; }
24443 case "$gl_cv_func_mknod_works" in
24448 $as_echo "#define MKNOD_FIFO_BUG 1" >>confdefs.h
24452 if test $REPLACE_MKFIFO = 1; then
24457 if test $HAVE_MKNOD = 0 || test $REPLACE_MKNOD = 1; then
24466 gl_LIBOBJS="$gl_LIBOBJS mknod.$ac_objext"
24480 $as_echo "#define GNULIB_TEST_MKNOD 1" >>confdefs.h
24490 if test $APPLE_UNIVERSAL_BUILD = 1; then
24491 # A universal build on Apple Mac OS X platforms.
24492 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
24493 # But we need a configuration result that is valid in both modes.
24494 gl_cv_func_working_mktime=no
24496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
24497 $as_echo_n "checking for working mktime... " >&6; }
24498 if ${gl_cv_func_working_mktime+:} false; then :
24499 $as_echo_n "(cached) " >&6
24501 if test "$cross_compiling" = yes; then :
24502 gl_cv_func_working_mktime=no
24504 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24505 /* end confdefs.h. */
24506 /* Test program from Paul Eggert and Tony Leneis. */
24507 #include <limits.h>
24508 #include <stdlib.h>
24511 #ifdef HAVE_UNISTD_H
24512 # include <unistd.h>
24515 #if HAVE_DECL_ALARM
24516 # include <signal.h>
24519 /* Work around redefinition to rpl_putenv by other config tests. */
24522 static time_t time_t_max;
24523 static time_t time_t_min;
24525 /* Values we'll use to set the TZ environment variable. */
24526 static char *tz_strings[] = {
24527 (char *) 0, "TZ=GMT0", "TZ=JST-9",
24528 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
24530 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
24532 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
24533 Based on a problem report from Andreas Jaeger. */
24535 spring_forward_gap ()
24537 /* glibc (up to about 1998-10-07) failed this test. */
24540 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
24541 instead of "TZ=America/Vancouver" in order to detect the bug even
24542 on systems that don't support the Olson extension, or don't have the
24543 full zoneinfo tables installed. */
24544 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
24553 return mktime (&tm) != (time_t) -1;
24557 mktime_test1 (time_t now)
24560 return ! (lt = localtime (&now)) || mktime (lt) == now;
24564 mktime_test (time_t now)
24566 return (mktime_test1 (now)
24567 && mktime_test1 ((time_t) (time_t_max - now))
24568 && mktime_test1 ((time_t) (time_t_min + now)));
24574 /* Based on code from Ariel Faigon. */
24584 return tm.tm_mon == 2 && tm.tm_mday == 31;
24588 bigtime_test (int j)
24592 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
24593 now = mktime (&tm);
24594 if (now != (time_t) -1)
24596 struct tm *lt = localtime (&now);
24598 && lt->tm_year == tm.tm_year
24599 && lt->tm_mon == tm.tm_mon
24600 && lt->tm_mday == tm.tm_mday
24601 && lt->tm_hour == tm.tm_hour
24602 && lt->tm_min == tm.tm_min
24603 && lt->tm_sec == tm.tm_sec
24604 && lt->tm_yday == tm.tm_yday
24605 && lt->tm_wday == tm.tm_wday
24606 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
24607 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
24616 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
24617 ignoring leap seconds. */
24618 unsigned long int answer = 2527315200UL;
24622 tm.tm_year = 2050 - 1900;
24625 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
24628 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
24629 instead of "TZ=America/Vancouver" in order to detect the bug even
24630 on systems that don't support the Olson extension, or don't have the
24631 full zoneinfo tables installed. */
24632 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
24636 /* Check that the result is either a failure, or close enough
24637 to the correct answer that we can assume the discrepancy is
24638 due to leap seconds. */
24639 return (t == (time_t) -1
24640 || (0 < t && answer - 120 <= t && t <= answer + 120));
24649 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
24650 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
24652 #if HAVE_DECL_ALARM
24653 /* This test makes some buggy mktime implementations loop.
24654 Give up after 60 seconds; a mktime slower than that
24655 isn't worth using anyway. */
24656 signal (SIGALRM, SIG_DFL);
24660 time_t_max = (! time_t_signed
24662 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
24664 time_t_min = (! time_t_signed
24666 : time_t_signed_magnitude
24670 delta = time_t_max / 997; /* a suitable prime number */
24671 for (i = 0; i < N_STRINGS; i++)
24674 putenv (tz_strings[i]);
24676 for (t = 0; t <= time_t_max - delta && (result & 1) == 0; t += delta)
24677 if (! mktime_test (t))
24679 if ((result & 2) == 0
24680 && ! (mktime_test ((time_t) 1)
24681 && mktime_test ((time_t) (60 * 60))
24682 && mktime_test ((time_t) (60 * 60 * 24))))
24685 for (j = 1; (result & 4) == 0; j <<= 1)
24687 if (! bigtime_test (j))
24689 if (INT_MAX / 2 < j)
24692 if ((result & 8) == 0 && ! bigtime_test (INT_MAX))
24695 if (! irix_6_4_bug ())
24697 if (! spring_forward_gap ())
24699 if (! year_2050_test ())
24704 if ac_fn_c_try_run "$LINENO"; then :
24705 gl_cv_func_working_mktime=yes
24707 gl_cv_func_working_mktime=no
24709 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24710 conftest.$ac_objext conftest.beam conftest.$ac_ext
24715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
24716 $as_echo "$gl_cv_func_working_mktime" >&6; }
24718 if test $gl_cv_func_working_mktime = no; then
24724 if test $REPLACE_MKTIME = 1; then
24733 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
24748 $as_echo "#define GNULIB_TEST_MKTIME 1" >>confdefs.h
24757 if test $ac_cv_func__set_invalid_parameter_handler = yes; then
24758 HAVE_MSVC_INVALID_PARAMETER_HANDLER=1
24760 $as_echo "#define HAVE_MSVC_INVALID_PARAMETER_HANDLER 1" >>confdefs.h
24763 HAVE_MSVC_INVALID_PARAMETER_HANDLER=0
24767 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
24776 gl_LIBOBJS="$gl_LIBOBJS msvc-inval.$ac_objext"
24782 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
24791 gl_LIBOBJS="$gl_LIBOBJS msvc-nothrow.$ac_objext"
24799 if test $ac_cv_func_nl_langinfo = yes; then
24800 # On Irix 6.5, YESEXPR is defined, but nl_langinfo(YESEXPR) is broken.
24801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether YESEXPR works" >&5
24802 $as_echo_n "checking whether YESEXPR works... " >&6; }
24803 if ${gl_cv_func_nl_langinfo_yesexpr_works+:} false; then :
24804 $as_echo_n "(cached) " >&6
24806 if test "$cross_compiling" = yes; then :
24809 # Guess no on irix systems.
24810 irix*) gl_cv_func_nl_langinfo_yesexpr_works="guessing no";;
24811 # Guess yes elsewhere.
24812 *) gl_cv_func_nl_langinfo_yesexpr_works="guessing yes";;
24816 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24817 /* end confdefs.h. */
24818 #include <langinfo.h>
24823 return !*nl_langinfo(YESEXPR);
24829 if ac_fn_c_try_run "$LINENO"; then :
24830 gl_cv_func_nl_langinfo_yesexpr_works=yes
24832 gl_cv_func_nl_langinfo_yesexpr_works=no
24834 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24835 conftest.$ac_objext conftest.beam conftest.$ac_ext
24840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_nl_langinfo_yesexpr_works" >&5
24841 $as_echo "$gl_cv_func_nl_langinfo_yesexpr_works" >&6; }
24842 case $gl_cv_func_nl_langinfo_yesexpr_works in
24843 *yes) FUNC_NL_LANGINFO_YESEXPR_WORKS=1 ;;
24844 *) FUNC_NL_LANGINFO_YESEXPR_WORKS=0 ;;
24847 cat >>confdefs.h <<_ACEOF
24848 #define FUNC_NL_LANGINFO_YESEXPR_WORKS $FUNC_NL_LANGINFO_YESEXPR_WORKS
24851 if test $HAVE_LANGINFO_CODESET = 1 && test $HAVE_LANGINFO_ERA = 1 \
24852 && test $FUNC_NL_LANGINFO_YESEXPR_WORKS = 1; then
24855 REPLACE_NL_LANGINFO=1
24857 $as_echo "#define REPLACE_NL_LANGINFO 1" >>confdefs.h
24864 if test $HAVE_NL_LANGINFO = 0 || test $REPLACE_NL_LANGINFO = 1; then
24873 gl_LIBOBJS="$gl_LIBOBJS nl_langinfo.$ac_objext"
24881 GNULIB_NL_LANGINFO=1
24887 $as_echo "#define GNULIB_TEST_NL_LANGINFO 1" >>confdefs.h
24903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for obstacks" >&5
24904 $as_echo_n "checking for obstacks... " >&6; }
24905 if ${ac_cv_func_obstack+:} false; then :
24906 $as_echo_n "(cached) " >&6
24908 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24909 /* end confdefs.h. */
24910 $ac_includes_default
24911 #include "obstack.h"
24915 struct obstack mem;
24916 #define obstack_chunk_alloc malloc
24917 #define obstack_chunk_free free
24918 obstack_init (&mem);
24919 obstack_free (&mem, 0);
24924 if ac_fn_c_try_link "$LINENO"; then :
24925 ac_cv_func_obstack=yes
24927 ac_cv_func_obstack=no
24929 rm -f core conftest.err conftest.$ac_objext \
24930 conftest$ac_exeext conftest.$ac_ext
24932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_obstack" >&5
24933 $as_echo "$ac_cv_func_obstack" >&6; }
24934 if test $ac_cv_func_obstack = yes; then
24936 $as_echo "#define HAVE_OBSTACK 1" >>confdefs.h
24947 gl_LIBOBJS="$gl_LIBOBJS obstack.$ac_objext"
24959 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether open recognizes a trailing slash" >&5
24960 $as_echo_n "checking whether open recognizes a trailing slash... " >&6; }
24961 if ${gl_cv_func_open_slash+:} false; then :
24962 $as_echo_n "(cached) " >&6
24964 # Assume that if we have lstat, we can also check symlinks.
24965 if test $ac_cv_func_lstat = yes; then
24967 ln -s conftest.tmp conftest.lnk
24969 if test "$cross_compiling" = yes; then :
24972 freebsd* | aix* | hpux* | solaris2.[0-9] | solaris2.[0-9].*)
24973 gl_cv_func_open_slash="guessing no" ;;
24975 gl_cv_func_open_slash="guessing yes" ;;
24979 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24980 /* end confdefs.h. */
24984 # include <unistd.h>
24990 if (open ("conftest.lnk/", O_RDONLY) != -1)
24993 if (open ("conftest.sl/", O_CREAT, 0600) >= 0)
24998 if ac_fn_c_try_run "$LINENO"; then :
24999 gl_cv_func_open_slash=yes
25001 gl_cv_func_open_slash=no
25003 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25004 conftest.$ac_objext conftest.beam conftest.$ac_ext
25007 rm -f conftest.sl conftest.tmp conftest.lnk
25010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_open_slash" >&5
25011 $as_echo "$gl_cv_func_open_slash" >&6; }
25012 case "$gl_cv_func_open_slash" in
25015 $as_echo "#define OPEN_TRAILING_SLASH_BUG 1" >>confdefs.h
25023 if test $REPLACE_OPEN = 0; then
25027 if test $ac_cv_func_fchdir = no; then
25031 if test $HAVE_FCHDIR = 0; then
25038 if test $REPLACE_OPEN = 1; then
25047 gl_LIBOBJS="$gl_LIBOBJS open.$ac_objext"
25065 $as_echo "#define GNULIB_TEST_OPEN 1" >>confdefs.h
25074 case $ac_cv_func_openat+$gl_cv_func_lstat_dereferences_slashed_symlink in
25078 # Solaris 9 has *at functions, but uniformly mishandles trailing
25079 # slash in all of them.
25087 if test $HAVE_OPENAT = 0 || test $REPLACE_OPENAT = 1; then
25096 gl_LIBOBJS="$gl_LIBOBJS openat.$ac_objext"
25105 cat >>confdefs.h <<_ACEOF
25106 #define GNULIB_OPENAT 1
25120 $as_echo "#define GNULIB_TEST_OPENAT 1" >>confdefs.h
25127 for ac_func in opendir
25129 ac_fn_c_check_func "$LINENO" "opendir" "ac_cv_func_opendir"
25130 if test "x$ac_cv_func_opendir" = xyes; then :
25131 cat >>confdefs.h <<_ACEOF
25132 #define HAVE_OPENDIR 1
25138 if test $ac_cv_func_opendir = no; then
25145 if test $ac_cv_func_fchdir = no; then
25149 if test $HAVE_FCHDIR = 0; then
25150 if test $HAVE_OPENDIR = 1; then
25156 if test $HAVE_OPENDIR = 0 || test $REPLACE_OPENDIR = 1; then
25165 gl_LIBOBJS="$gl_LIBOBJS opendir.$ac_objext"
25179 $as_echo "#define GNULIB_TEST_OPENDIR 1" >>confdefs.h
25189 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
25190 #include <$ac_cv_struct_tm>
25193 if test "x$ac_cv_member_struct_tm_tm_zone" = xyes; then :
25195 cat >>confdefs.h <<_ACEOF
25196 #define HAVE_STRUCT_TM_TM_ZONE 1
25202 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
25204 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
25207 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
25209 if test "x$ac_cv_have_decl_tzname" = xyes; then :
25215 cat >>confdefs.h <<_ACEOF
25216 #define HAVE_DECL_TZNAME $ac_have_decl
25219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
25220 $as_echo_n "checking for tzname... " >&6; }
25221 if ${ac_cv_var_tzname+:} false; then :
25222 $as_echo_n "(cached) " >&6
25224 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25225 /* end confdefs.h. */
25227 #if !HAVE_DECL_TZNAME
25228 extern char *tzname[];
25234 return tzname[0][0];
25239 if ac_fn_c_try_link "$LINENO"; then :
25240 ac_cv_var_tzname=yes
25242 ac_cv_var_tzname=no
25244 rm -f core conftest.err conftest.$ac_objext \
25245 conftest$ac_exeext conftest.$ac_ext
25247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
25248 $as_echo "$ac_cv_var_tzname" >&6; }
25249 if test $ac_cv_var_tzname = yes; then
25251 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
25258 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25259 /* end confdefs.h. */
25261 #include <time.h> /* for time_t */
25262 #include <limits.h> /* for CHAR_BIT, LONG_MIN, LONG_MAX */
25263 #define TYPE_MINIMUM(t) \
25264 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
25265 #define TYPE_MAXIMUM(t) \
25266 ((t) ((t) 0 < (t) -1 \
25268 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
25269 typedef int verify_min[2 * (LONG_MIN <= TYPE_MINIMUM (time_t)) - 1];
25270 typedef int verify_max[2 * (TYPE_MAXIMUM (time_t) <= LONG_MAX) - 1];
25273 if ac_fn_c_try_compile "$LINENO"; then :
25275 $as_echo "#define TIME_T_FITS_IN_LONG_INT 1" >>confdefs.h
25279 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25285 for ac_func in getppriv
25287 ac_fn_c_check_func "$LINENO" "getppriv" "ac_cv_func_getppriv"
25288 if test "x$ac_cv_func_getppriv" = xyes; then :
25289 cat >>confdefs.h <<_ACEOF
25290 #define HAVE_GETPPRIV 1
25298 ac_fn_c_check_decl "$LINENO" "program_invocation_name" "ac_cv_have_decl_program_invocation_name" "#include <errno.h>
25300 if test "x$ac_cv_have_decl_program_invocation_name" = xyes; then :
25306 cat >>confdefs.h <<_ACEOF
25307 #define HAVE_DECL_PROGRAM_INVOCATION_NAME $ac_have_decl
25310 ac_fn_c_check_decl "$LINENO" "program_invocation_short_name" "ac_cv_have_decl_program_invocation_short_name" "#include <errno.h>
25312 if test "x$ac_cv_have_decl_program_invocation_short_name" = xyes; then :
25318 cat >>confdefs.h <<_ACEOF
25319 #define HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME $ac_have_decl
25323 # Check whether --enable-acl was given.
25324 if test "${enable_acl+set}" = set; then :
25325 enableval=$enable_acl;
25333 if test "x$enable_acl" != "xno"; then
25334 for ac_header in sys/acl.h
25336 ac_fn_c_check_header_mongrel "$LINENO" "sys/acl.h" "ac_cv_header_sys_acl_h" "$ac_includes_default"
25337 if test "x$ac_cv_header_sys_acl_h" = xyes; then :
25338 cat >>confdefs.h <<_ACEOF
25339 #define HAVE_SYS_ACL_H 1
25346 if test $ac_cv_header_sys_acl_h = yes; then
25349 if test $use_acl = 0; then
25350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing acl_get_file" >&5
25351 $as_echo_n "checking for library containing acl_get_file... " >&6; }
25352 if ${ac_cv_search_acl_get_file+:} false; then :
25353 $as_echo_n "(cached) " >&6
25355 ac_func_search_save_LIBS=$LIBS
25356 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25357 /* end confdefs.h. */
25359 /* Override any GCC internal prototype to avoid an error.
25360 Use char because int might match the return type of a GCC
25361 builtin and then its argument prototype would still apply. */
25365 char acl_get_file ();
25369 return acl_get_file ();
25374 for ac_lib in '' acl pacl; do
25375 if test -z "$ac_lib"; then
25376 ac_res="none required"
25379 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
25381 if ac_fn_c_try_link "$LINENO"; then :
25382 ac_cv_search_acl_get_file=$ac_res
25384 rm -f core conftest.err conftest.$ac_objext \
25386 if ${ac_cv_search_acl_get_file+:} false; then :
25390 if ${ac_cv_search_acl_get_file+:} false; then :
25393 ac_cv_search_acl_get_file=no
25395 rm conftest.$ac_ext
25396 LIBS=$ac_func_search_save_LIBS
25398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_acl_get_file" >&5
25399 $as_echo "$ac_cv_search_acl_get_file" >&6; }
25400 ac_res=$ac_cv_search_acl_get_file
25401 if test "$ac_res" != no; then :
25402 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25403 if test "$ac_cv_search_acl_get_file" != "none required"; then
25404 LIB_ACL=$ac_cv_search_acl_get_file
25406 for ac_func in acl_get_file acl_get_fd acl_set_file acl_set_fd \
25407 acl_free acl_from_mode acl_from_text \
25408 acl_delete_def_file acl_extended_file \
25409 acl_delete_fd_np acl_delete_file_np \
25410 acl_copy_ext_native acl_create_entry_np \
25411 acl_to_short_text acl_free_text
25413 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
25414 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
25415 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
25416 cat >>confdefs.h <<_ACEOF
25417 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
25423 # If the acl_get_file bug is detected, don't enable the ACL support.
25425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working acl_get_file" >&5
25426 $as_echo_n "checking for working acl_get_file... " >&6; }
25427 if ${gl_cv_func_working_acl_get_file+:} false; then :
25428 $as_echo_n "(cached) " >&6
25430 if test "$cross_compiling" = yes; then :
25431 gl_cv_func_working_acl_get_file=cross-compiling
25433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25434 /* end confdefs.h. */
25435 #include <sys/types.h>
25436 #include <sys/acl.h>
25442 if (!acl_get_file (".", ACL_TYPE_ACCESS) && errno == ENOENT)
25450 if ac_fn_c_try_run "$LINENO"; then :
25451 gl_cv_func_working_acl_get_file=yes
25453 gl_cv_func_working_acl_get_file=no
25455 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25456 conftest.$ac_objext conftest.beam conftest.$ac_ext
25460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_acl_get_file" >&5
25461 $as_echo "$gl_cv_func_working_acl_get_file" >&6; }
25463 if test $gl_cv_func_working_acl_get_file = yes; then :
25467 if test $use_acl = 1; then
25468 for ac_header in acl/libacl.h
25470 ac_fn_c_check_header_mongrel "$LINENO" "acl/libacl.h" "ac_cv_header_acl_libacl_h" "$ac_includes_default"
25471 if test "x$ac_cv_header_acl_libacl_h" = xyes; then :
25472 cat >>confdefs.h <<_ACEOF
25473 #define HAVE_ACL_LIBACL_H 1
25488 for ac_func in acl_entries
25490 ac_fn_c_check_func "$LINENO" "acl_entries" "ac_cv_func_acl_entries"
25491 if test "x$ac_cv_func_acl_entries" = xyes; then :
25492 cat >>confdefs.h <<_ACEOF
25493 #define HAVE_ACL_ENTRIES 1
25498 gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
25504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ACL_FIRST_ENTRY" >&5
25505 $as_echo_n "checking for ACL_FIRST_ENTRY... " >&6; }
25506 if ${gl_cv_acl_ACL_FIRST_ENTRY+:} false; then :
25507 $as_echo_n "(cached) " >&6
25509 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25510 /* end confdefs.h. */
25511 #include <sys/types.h>
25512 #include <sys/acl.h>
25513 int type = ACL_FIRST_ENTRY;
25522 if ac_fn_c_try_compile "$LINENO"; then :
25523 gl_cv_acl_ACL_FIRST_ENTRY=yes
25525 gl_cv_acl_ACL_FIRST_ENTRY=no
25527 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_acl_ACL_FIRST_ENTRY" >&5
25530 $as_echo "$gl_cv_acl_ACL_FIRST_ENTRY" >&6; }
25531 if test $gl_cv_acl_ACL_FIRST_ENTRY = yes; then
25533 $as_echo "#define HAVE_ACL_FIRST_ENTRY 1" >>confdefs.h
25536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ACL_TYPE_EXTENDED" >&5
25537 $as_echo_n "checking for ACL_TYPE_EXTENDED... " >&6; }
25538 if ${gl_cv_acl_ACL_TYPE_EXTENDED+:} false; then :
25539 $as_echo_n "(cached) " >&6
25541 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25542 /* end confdefs.h. */
25543 #include <sys/types.h>
25544 #include <sys/acl.h>
25545 int type = ACL_TYPE_EXTENDED;
25554 if ac_fn_c_try_compile "$LINENO"; then :
25555 gl_cv_acl_ACL_TYPE_EXTENDED=yes
25557 gl_cv_acl_ACL_TYPE_EXTENDED=no
25559 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_acl_ACL_TYPE_EXTENDED" >&5
25562 $as_echo "$gl_cv_acl_ACL_TYPE_EXTENDED" >&6; }
25563 if test $gl_cv_acl_ACL_TYPE_EXTENDED = yes; then
25565 $as_echo "#define HAVE_ACL_TYPE_EXTENDED 1" >>confdefs.h
25576 if test $use_acl = 0; then
25577 for ac_func in facl
25579 ac_fn_c_check_func "$LINENO" "facl" "ac_cv_func_facl"
25580 if test "x$ac_cv_func_facl" = xyes; then :
25581 cat >>confdefs.h <<_ACEOF
25582 #define HAVE_FACL 1
25588 if test $ac_cv_func_facl = yes; then
25589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing acl_trivial" >&5
25590 $as_echo_n "checking for library containing acl_trivial... " >&6; }
25591 if ${ac_cv_search_acl_trivial+:} false; then :
25592 $as_echo_n "(cached) " >&6
25594 ac_func_search_save_LIBS=$LIBS
25595 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25596 /* end confdefs.h. */
25598 /* Override any GCC internal prototype to avoid an error.
25599 Use char because int might match the return type of a GCC
25600 builtin and then its argument prototype would still apply. */
25604 char acl_trivial ();
25608 return acl_trivial ();
25613 for ac_lib in '' sec; do
25614 if test -z "$ac_lib"; then
25615 ac_res="none required"
25618 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
25620 if ac_fn_c_try_link "$LINENO"; then :
25621 ac_cv_search_acl_trivial=$ac_res
25623 rm -f core conftest.err conftest.$ac_objext \
25625 if ${ac_cv_search_acl_trivial+:} false; then :
25629 if ${ac_cv_search_acl_trivial+:} false; then :
25632 ac_cv_search_acl_trivial=no
25634 rm conftest.$ac_ext
25635 LIBS=$ac_func_search_save_LIBS
25637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_acl_trivial" >&5
25638 $as_echo "$ac_cv_search_acl_trivial" >&6; }
25639 ac_res=$ac_cv_search_acl_trivial
25640 if test "$ac_res" != no; then :
25641 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25642 if test "$ac_cv_search_acl_trivial" != "none required"; then
25643 LIB_ACL=$ac_cv_search_acl_trivial
25648 for ac_func in acl_trivial
25650 ac_fn_c_check_func "$LINENO" "acl_trivial" "ac_cv_func_acl_trivial"
25651 if test "x$ac_cv_func_acl_trivial" = xyes; then :
25652 cat >>confdefs.h <<_ACEOF
25653 #define HAVE_ACL_TRIVIAL 1
25663 if test $use_acl = 0; then
25664 for ac_func in getacl
25666 ac_fn_c_check_func "$LINENO" "getacl" "ac_cv_func_getacl"
25667 if test "x$ac_cv_func_getacl" = xyes; then :
25668 cat >>confdefs.h <<_ACEOF
25669 #define HAVE_GETACL 1
25675 if test $ac_cv_func_getacl = yes; then
25678 for ac_header in aclv.h
25680 ac_fn_c_check_header_compile "$LINENO" "aclv.h" "ac_cv_header_aclv_h" "#include <sys/types.h>
25682 if test "x$ac_cv_header_aclv_h" = xyes; then :
25683 cat >>confdefs.h <<_ACEOF
25684 #define HAVE_ACLV_H 1
25693 if test $use_acl = 0; then
25694 for ac_func in aclx_get
25696 ac_fn_c_check_func "$LINENO" "aclx_get" "ac_cv_func_aclx_get"
25697 if test "x$ac_cv_func_aclx_get" = xyes; then :
25698 cat >>confdefs.h <<_ACEOF
25699 #define HAVE_ACLX_GET 1
25705 if test $ac_cv_func_aclx_get = yes; then
25710 if test $use_acl = 0 || test "$ac_cv_func_aclx_get" = yes; then
25711 for ac_func in statacl
25713 ac_fn_c_check_func "$LINENO" "statacl" "ac_cv_func_statacl"
25714 if test "x$ac_cv_func_statacl" = xyes; then :
25715 cat >>confdefs.h <<_ACEOF
25716 #define HAVE_STATACL 1
25722 if test $ac_cv_func_statacl = yes; then
25727 if test $use_acl = 0; then
25728 for ac_func in aclsort
25730 ac_fn_c_check_func "$LINENO" "aclsort" "ac_cv_func_aclsort"
25731 if test "x$ac_cv_func_aclsort" = xyes; then :
25732 cat >>confdefs.h <<_ACEOF
25733 #define HAVE_ACLSORT 1
25739 if test $ac_cv_func_aclsort = yes; then
25746 if test "x$enable_acl$use_acl" = "xyes0"; then
25747 as_fn_error $? "ACLs enabled but support not detected" "$LINENO" 5
25748 elif test "x$enable_acl$use_acl" = "xauto0"; then
25749 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libacl development library was not found or not usable." >&5
25750 $as_echo "$as_me: WARNING: libacl development library was not found or not usable." >&2;}
25751 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: GNU tar will be built without ACL support." >&5
25752 $as_echo "$as_me: WARNING: GNU tar will be built without ACL support." >&2;}
25757 cat >>confdefs.h <<_ACEOF
25758 #define USE_ACL $use_acl
25774 for ac_func in raise
25776 ac_fn_c_check_func "$LINENO" "raise" "ac_cv_func_raise"
25777 if test "x$ac_cv_func_raise" = xyes; then :
25778 cat >>confdefs.h <<_ACEOF
25779 #define HAVE_RAISE 1
25785 if test $ac_cv_func_raise = no; then
25788 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
25794 if test $HAVE_RAISE = 0 || test $REPLACE_RAISE = 1; then
25803 gl_LIBOBJS="$gl_LIBOBJS raise.$ac_objext"
25818 $as_echo "#define GNULIB_TEST_RAISE 1" >>confdefs.h
25826 for ac_func in rawmemchr
25828 ac_fn_c_check_func "$LINENO" "rawmemchr" "ac_cv_func_rawmemchr"
25829 if test "x$ac_cv_func_rawmemchr" = xyes; then :
25830 cat >>confdefs.h <<_ACEOF
25831 #define HAVE_RAWMEMCHR 1
25837 if test $ac_cv_func_rawmemchr = no; then
25841 if test $HAVE_RAWMEMCHR = 0; then
25850 gl_LIBOBJS="$gl_LIBOBJS rawmemchr.$ac_objext"
25865 $as_echo "#define GNULIB_TEST_RAWMEMCHR 1" >>confdefs.h
25872 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
25877 if test $REPLACE_READ = 1; then
25886 gl_LIBOBJS="$gl_LIBOBJS read.$ac_objext"
25901 $as_echo "#define GNULIB_TEST_READ 1" >>confdefs.h
25908 for ac_func in readdir
25910 ac_fn_c_check_func "$LINENO" "readdir" "ac_cv_func_readdir"
25911 if test "x$ac_cv_func_readdir" = xyes; then :
25912 cat >>confdefs.h <<_ACEOF
25913 #define HAVE_READDIR 1
25919 if test $ac_cv_func_readdir = no; then
25923 if test $HAVE_READDIR = 0; then
25932 gl_LIBOBJS="$gl_LIBOBJS readdir.$ac_objext"
25946 $as_echo "#define GNULIB_TEST_READDIR 1" >>confdefs.h
25953 if test $ac_cv_func_readlink = no; then
25956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
25957 $as_echo_n "checking whether readlink signature is correct... " >&6; }
25958 if ${gl_cv_decl_readlink_works+:} false; then :
25959 $as_echo_n "(cached) " >&6
25961 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25962 /* end confdefs.h. */
25963 #include <unistd.h>
25964 /* Cause compilation failure if original declaration has wrong type. */
25965 ssize_t readlink (const char *, char *, size_t);
25974 if ac_fn_c_try_compile "$LINENO"; then :
25975 gl_cv_decl_readlink_works=yes
25977 gl_cv_decl_readlink_works=no
25979 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
25982 $as_echo "$gl_cv_decl_readlink_works" >&6; }
25983 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
25984 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
25985 if ${gl_cv_func_readlink_works+:} false; then :
25986 $as_echo_n "(cached) " >&6
25988 # We have readlink, so assume ln -s works.
25989 ln -s conftest.no-such conftest.link
25990 ln -s conftest.link conftest.lnk2
25991 if test "$cross_compiling" = yes; then :
25993 # Guess yes on glibc systems.
25994 *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
25995 # If we don't know, assume the worst.
25996 *) gl_cv_func_readlink_works="guessing no" ;;
26000 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26001 /* end confdefs.h. */
26002 #include <unistd.h>
26008 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
26013 if ac_fn_c_try_run "$LINENO"; then :
26014 gl_cv_func_readlink_works=yes
26016 gl_cv_func_readlink_works=no
26018 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
26019 conftest.$ac_objext conftest.beam conftest.$ac_ext
26022 rm -f conftest.link conftest.lnk2
26024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
26025 $as_echo "$gl_cv_func_readlink_works" >&6; }
26026 case "$gl_cv_func_readlink_works" in
26028 if test "$gl_cv_decl_readlink_works" != yes; then
26034 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
26041 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
26050 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
26067 $as_echo "#define GNULIB_TEST_READLINK 1" >>confdefs.h
26075 if test $ac_cv_func_readlinkat = no; then
26079 if test $HAVE_READLINKAT = 0; then
26088 gl_LIBOBJS="$gl_LIBOBJS readlinkat.$ac_objext"
26096 GNULIB_READLINKAT=1
26102 $as_echo "#define GNULIB_TEST_READLINKAT 1" >>confdefs.h
26109 if test $gl_cv_func_malloc_posix = yes; then
26111 $as_echo "#define HAVE_REALLOC_POSIX 1" >>confdefs.h
26117 if test $REPLACE_REALLOC = 1; then
26126 gl_LIBOBJS="$gl_LIBOBJS realloc.$ac_objext"
26134 GNULIB_REALLOC_POSIX=1
26140 $as_echo "#define GNULIB_TEST_REALLOC_POSIX 1" >>confdefs.h
26146 # Check whether --with-included-regex was given.
26147 if test "${with_included_regex+set}" = set; then :
26148 withval=$with_included_regex;
26152 case $with_included_regex in #(
26153 yes|no) ac_use_included_regex=$with_included_regex
26156 # If the system regex support is good enough that it passes the
26157 # following run test, then default to *not* using the included regex.c.
26158 # If cross compiling, assume the test would fail and use the included
26161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working re_compile_pattern" >&5
26162 $as_echo_n "checking for working re_compile_pattern... " >&6; }
26163 if ${gl_cv_func_re_compile_pattern_working+:} false; then :
26164 $as_echo_n "(cached) " >&6
26166 if test "$cross_compiling" = yes; then :
26167 gl_cv_func_re_compile_pattern_working=no
26169 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26170 /* end confdefs.h. */
26173 #include <locale.h>
26174 #include <limits.h>
26175 #include <string.h>
26176 #if HAVE_DECL_ALARM
26177 # include <unistd.h>
26178 # include <signal.h>
26185 static struct re_pattern_buffer regex;
26186 unsigned char folded_chars[UCHAR_MAX + 1];
26189 struct re_registers regs;
26191 #if HAVE_DECL_ALARM
26192 /* Some builds of glibc go into an infinite loop on this test. */
26193 signal (SIGALRM, SIG_DFL);
26196 if (setlocale (LC_ALL, "en_US.UTF-8"))
26199 /* http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html
26200 This test needs valgrind to catch the bug on Debian
26201 GNU/Linux 3.1 x86, but it might catch the bug better
26202 on other platforms and it shouldn't hurt to try the
26204 static char const pat[] = "insert into";
26205 static char const data[] =
26206 "\xFF\0\x12\xA2\xAA\xC4\xB1,K\x12\xC4\xB1*\xACK";
26207 re_set_syntax (RE_SYNTAX_GREP | RE_HAT_LISTS_NOT_NEWLINE
26209 memset (®ex, 0, sizeof regex);
26210 s = re_compile_pattern (pat, sizeof pat - 1, ®ex);
26213 else if (re_search (®ex, data, sizeof data - 1,
26214 0, sizeof data - 1, ®s)
26220 /* This test is from glibc bug 15078.
26221 The test case is from Andreas Schwab in
26222 <http://www.sourceware.org/ml/libc-alpha/2013-01/msg00967.html>.
26224 static char const pat[] = "[^x]x";
26225 static char const data[] =
26226 /* <U1000><U103B><U103D><U1014><U103A><U102F><U1015><U103A> */
26237 memset (®ex, 0, sizeof regex);
26238 s = re_compile_pattern (pat, sizeof pat - 1, ®ex);
26243 i = re_search (®ex, data, sizeof data - 1,
26244 0, sizeof data - 1, 0);
26245 if (i != 0 && i != 21)
26250 if (! setlocale (LC_ALL, "C"))
26254 /* This test is from glibc bug 3957, reported by Andrew Mackey. */
26255 re_set_syntax (RE_SYNTAX_EGREP | RE_HAT_LISTS_NOT_NEWLINE);
26256 memset (®ex, 0, sizeof regex);
26257 s = re_compile_pattern ("a[^x]b", 6, ®ex);
26260 /* This should fail, but succeeds for glibc-2.5. */
26261 else if (re_search (®ex, "a\nb", 3, 0, 3, ®s) != -1)
26264 /* This regular expression is from Spencer ere test number 75
26266 re_set_syntax (RE_SYNTAX_POSIX_EGREP);
26267 memset (®ex, 0, sizeof regex);
26268 for (i = 0; i <= UCHAR_MAX; i++)
26269 folded_chars[i] = i;
26270 regex.translate = folded_chars;
26271 s = re_compile_pattern ("a[[:]:]]b\n", 11, ®ex);
26272 /* This should fail with _Invalid character class name_ error. */
26276 /* Ensure that [b-a] is diagnosed as invalid, when
26277 using RE_NO_EMPTY_RANGES. */
26278 re_set_syntax (RE_SYNTAX_POSIX_EGREP | RE_NO_EMPTY_RANGES);
26279 memset (®ex, 0, sizeof regex);
26280 s = re_compile_pattern ("a[b-a]", 6, ®ex);
26284 /* This should succeed, but does not for glibc-2.1.3. */
26285 memset (®ex, 0, sizeof regex);
26286 s = re_compile_pattern ("{1", 2, ®ex);
26290 /* The following example is derived from a problem report
26291 against gawk from Jorge Stolfi <stolfi@ic.unicamp.br>. */
26292 memset (®ex, 0, sizeof regex);
26293 s = re_compile_pattern ("[an\371]*n", 7, ®ex);
26296 /* This should match, but does not for glibc-2.2.1. */
26297 else if (re_match (®ex, "an", 2, 0, ®s) != 2)
26300 memset (®ex, 0, sizeof regex);
26301 s = re_compile_pattern ("x", 1, ®ex);
26304 /* glibc-2.2.93 does not work with a negative RANGE argument. */
26305 else if (re_search (®ex, "wxy", 3, 2, -2, ®s) != 1)
26308 /* The version of regex.c in older versions of gnulib
26309 ignored RE_ICASE. Detect that problem too. */
26310 re_set_syntax (RE_SYNTAX_EMACS | RE_ICASE);
26311 memset (®ex, 0, sizeof regex);
26312 s = re_compile_pattern ("x", 1, ®ex);
26315 else if (re_search (®ex, "WXY", 3, 0, 3, ®s) < 0)
26318 /* Catch a bug reported by Vin Shelton in
26319 http://lists.gnu.org/archive/html/bug-coreutils/2007-06/msg00089.html
26321 re_set_syntax (RE_SYNTAX_POSIX_BASIC
26322 & ~RE_CONTEXT_INVALID_DUP
26323 & ~RE_NO_EMPTY_RANGES);
26324 memset (®ex, 0, sizeof regex);
26325 s = re_compile_pattern ("[[:alnum:]_-]\\\\+$", 16, ®ex);
26329 /* REG_STARTEND was added to glibc on 2004-01-15.
26330 Reject older versions. */
26331 if (! REG_STARTEND)
26335 /* It would be nice to reject hosts whose regoff_t values are too
26336 narrow (including glibc on hosts with 64-bit ptrdiff_t and
26337 32-bit int), but we should wait until glibc implements this
26338 feature. Otherwise, support for equivalence classes and
26339 multibyte collation symbols would always be broken except
26340 when compiling --without-included-regex. */
26341 if (sizeof (regoff_t) < sizeof (ptrdiff_t)
26342 || sizeof (regoff_t) < sizeof (ssize_t))
26352 if ac_fn_c_try_run "$LINENO"; then :
26353 gl_cv_func_re_compile_pattern_working=yes
26355 gl_cv_func_re_compile_pattern_working=no
26357 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
26358 conftest.$ac_objext conftest.beam conftest.$ac_ext
26362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_re_compile_pattern_working" >&5
26363 $as_echo "$gl_cv_func_re_compile_pattern_working" >&6; }
26364 case $gl_cv_func_re_compile_pattern_working in #(
26365 yes) ac_use_included_regex=no;; #(
26366 no) ac_use_included_regex=yes;;
26369 *) as_fn_error $? "Invalid value for --with-included-regex: $with_included_regex" "$LINENO" 5
26373 if test $ac_use_included_regex = yes; then
26375 $as_echo "#define _REGEX_INCLUDE_LIMITS_H 1" >>confdefs.h
26378 $as_echo "#define _REGEX_LARGE_OFFSETS 1" >>confdefs.h
26381 $as_echo "#define re_syntax_options rpl_re_syntax_options" >>confdefs.h
26384 $as_echo "#define re_set_syntax rpl_re_set_syntax" >>confdefs.h
26387 $as_echo "#define re_compile_pattern rpl_re_compile_pattern" >>confdefs.h
26390 $as_echo "#define re_compile_fastmap rpl_re_compile_fastmap" >>confdefs.h
26393 $as_echo "#define re_search rpl_re_search" >>confdefs.h
26396 $as_echo "#define re_search_2 rpl_re_search_2" >>confdefs.h
26399 $as_echo "#define re_match rpl_re_match" >>confdefs.h
26402 $as_echo "#define re_match_2 rpl_re_match_2" >>confdefs.h
26405 $as_echo "#define re_set_registers rpl_re_set_registers" >>confdefs.h
26408 $as_echo "#define re_comp rpl_re_comp" >>confdefs.h
26411 $as_echo "#define re_exec rpl_re_exec" >>confdefs.h
26414 $as_echo "#define regcomp rpl_regcomp" >>confdefs.h
26417 $as_echo "#define regexec rpl_regexec" >>confdefs.h
26420 $as_echo "#define regerror rpl_regerror" >>confdefs.h
26423 $as_echo "#define regfree rpl_regfree" >>confdefs.h
26427 if test $ac_use_included_regex = yes; then
26436 gl_LIBOBJS="$gl_LIBOBJS regex.$ac_objext"
26444 for ac_header in libintl.h
26446 ac_fn_c_check_header_mongrel "$LINENO" "libintl.h" "ac_cv_header_libintl_h" "$ac_includes_default"
26447 if test "x$ac_cv_header_libintl_h" = xyes; then :
26448 cat >>confdefs.h <<_ACEOF
26449 #define HAVE_LIBINTL_H 1
26457 ac_fn_c_check_decl "$LINENO" "isblank" "ac_cv_have_decl_isblank" "#include <ctype.h>
26459 if test "x$ac_cv_have_decl_isblank" = xyes; then :
26465 cat >>confdefs.h <<_ACEOF
26466 #define HAVE_DECL_ISBLANK $ac_have_decl
26476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename honors trailing slash on destination" >&5
26477 $as_echo_n "checking whether rename honors trailing slash on destination... " >&6; }
26478 if ${gl_cv_func_rename_slash_dst_works+:} false; then :
26479 $as_echo_n "(cached) " >&6
26481 rm -rf conftest.f conftest.f1 conftest.f2 conftest.d1 conftest.d2 conftest.lnk
26482 touch conftest.f && touch conftest.f1 && mkdir conftest.d1 ||
26483 as_fn_error $? "cannot create temporary files" "$LINENO" 5
26484 # Assume that if we have lstat, we can also check symlinks.
26485 if test $ac_cv_func_lstat = yes; then
26486 ln -s conftest.f conftest.lnk
26488 if test "$cross_compiling" = yes; then :
26490 # Guess yes on glibc systems.
26491 *-gnu*) gl_cv_func_rename_slash_dst_works="guessing yes" ;;
26492 # If we don't know, assume the worst.
26493 *) gl_cv_func_rename_slash_dst_works="guessing no" ;;
26497 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26498 /* end confdefs.h. */
26500 # include <stdio.h>
26501 # include <stdlib.h>
26507 if (rename ("conftest.f1", "conftest.f2/") == 0)
26509 if (rename ("conftest.d1", "conftest.d2/") != 0)
26512 if (rename ("conftest.f", "conftest.lnk/") == 0)
26521 if ac_fn_c_try_run "$LINENO"; then :
26522 gl_cv_func_rename_slash_dst_works=yes
26524 gl_cv_func_rename_slash_dst_works=no
26526 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
26527 conftest.$ac_objext conftest.beam conftest.$ac_ext
26530 rm -rf conftest.f conftest.f1 conftest.f2 conftest.d1 conftest.d2 conftest.lnk
26533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_slash_dst_works" >&5
26534 $as_echo "$gl_cv_func_rename_slash_dst_works" >&6; }
26535 case "$gl_cv_func_rename_slash_dst_works" in
26540 $as_echo "#define RENAME_TRAILING_SLASH_DEST_BUG 1" >>confdefs.h
26545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename honors trailing slash on source" >&5
26546 $as_echo_n "checking whether rename honors trailing slash on source... " >&6; }
26547 if ${gl_cv_func_rename_slash_src_works+:} false; then :
26548 $as_echo_n "(cached) " >&6
26550 rm -rf conftest.f conftest.f1 conftest.d1 conftest.d2 conftest.d3 conftest.lnk
26551 touch conftest.f && touch conftest.f1 && mkdir conftest.d1 ||
26552 as_fn_error $? "cannot create temporary files" "$LINENO" 5
26553 # Assume that if we have lstat, we can also check symlinks.
26554 if test $ac_cv_func_lstat = yes; then
26555 ln -s conftest.f conftest.lnk
26557 if test "$cross_compiling" = yes; then :
26559 # Guess yes on glibc systems.
26560 *-gnu*) gl_cv_func_rename_slash_src_works="guessing yes" ;;
26561 # If we don't know, assume the worst.
26562 *) gl_cv_func_rename_slash_src_works="guessing no" ;;
26566 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26567 /* end confdefs.h. */
26569 # include <stdio.h>
26570 # include <stdlib.h>
26576 if (rename ("conftest.f1/", "conftest.d3") == 0)
26578 if (rename ("conftest.d1/", "conftest.d2") != 0)
26581 if (rename ("conftest.lnk/", "conftest.f") == 0)
26590 if ac_fn_c_try_run "$LINENO"; then :
26591 gl_cv_func_rename_slash_src_works=yes
26593 gl_cv_func_rename_slash_src_works=no
26595 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
26596 conftest.$ac_objext conftest.beam conftest.$ac_ext
26599 rm -rf conftest.f conftest.f1 conftest.d1 conftest.d2 conftest.d3 conftest.lnk
26602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_slash_src_works" >&5
26603 $as_echo "$gl_cv_func_rename_slash_src_works" >&6; }
26604 case "$gl_cv_func_rename_slash_src_works" in
26609 $as_echo "#define RENAME_TRAILING_SLASH_SOURCE_BUG 1" >>confdefs.h
26615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename manages hard links correctly" >&5
26616 $as_echo_n "checking whether rename manages hard links correctly... " >&6; }
26617 if ${gl_cv_func_rename_link_works+:} false; then :
26618 $as_echo_n "(cached) " >&6
26620 if test $ac_cv_func_link = yes; then
26621 rm -rf conftest.f conftest.f1
26622 if touch conftest.f && ln conftest.f conftest.f1 &&
26623 set x `ls -i conftest.f conftest.f1` && test "" = ""; then
26624 if test "$cross_compiling" = yes; then :
26626 # Guess yes on glibc systems.
26627 *-gnu*) gl_cv_func_rename_link_works="guessing yes" ;;
26628 # If we don't know, assume the worst.
26629 *) gl_cv_func_rename_link_works="guessing no" ;;
26633 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26634 /* end confdefs.h. */
26636 # include <stdio.h>
26637 # include <stdlib.h>
26638 # include <unistd.h>
26644 if (rename ("conftest.f", "conftest.f1"))
26646 if (unlink ("conftest.f1"))
26648 if (rename ("conftest.f", "conftest.f"))
26650 if (rename ("conftest.f1", "conftest.f1") == 0)
26658 if ac_fn_c_try_run "$LINENO"; then :
26659 gl_cv_func_rename_link_works=yes
26661 gl_cv_func_rename_link_works=no
26663 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
26664 conftest.$ac_objext conftest.beam conftest.$ac_ext
26668 gl_cv_func_rename_link_works="guessing no"
26670 rm -rf conftest.f conftest.f1
26672 gl_cv_func_rename_link_works=yes
26676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_link_works" >&5
26677 $as_echo "$gl_cv_func_rename_link_works" >&6; }
26678 case "$gl_cv_func_rename_link_works" in
26683 $as_echo "#define RENAME_HARD_LINK_BUG 1" >>confdefs.h
26688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename manages existing destinations correctly" >&5
26689 $as_echo_n "checking whether rename manages existing destinations correctly... " >&6; }
26690 if ${gl_cv_func_rename_dest_works+:} false; then :
26691 $as_echo_n "(cached) " >&6
26693 rm -rf conftest.f conftest.d1 conftest.d2
26694 touch conftest.f && mkdir conftest.d1 conftest.d2 ||
26695 as_fn_error $? "cannot create temporary files" "$LINENO" 5
26696 if test "$cross_compiling" = yes; then :
26698 # Guess yes on glibc systems.
26699 *-gnu*) gl_cv_func_rename_dest_works="guessing yes" ;;
26700 # If we don't know, assume the worst.
26701 *) gl_cv_func_rename_dest_works="guessing no" ;;
26705 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26706 /* end confdefs.h. */
26708 # include <stdio.h>
26709 # include <stdlib.h>
26715 if (rename ("conftest.d1", "conftest.d2") != 0)
26717 if (rename ("conftest.d2", "conftest.f") == 0)
26725 if ac_fn_c_try_run "$LINENO"; then :
26726 gl_cv_func_rename_dest_works=yes
26728 gl_cv_func_rename_dest_works=no
26730 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
26731 conftest.$ac_objext conftest.beam conftest.$ac_ext
26734 rm -rf conftest.f conftest.d1 conftest.d2
26737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_dest_works" >&5
26738 $as_echo "$gl_cv_func_rename_dest_works" >&6; }
26739 case "$gl_cv_func_rename_dest_works" in
26744 $as_echo "#define RENAME_DEST_EXISTS_BUG 1" >>confdefs.h
26749 if test $REPLACE_RENAME = 1; then
26758 gl_LIBOBJS="$gl_LIBOBJS rename.$ac_objext"
26772 $as_echo "#define GNULIB_TEST_RENAME 1" >>confdefs.h
26782 if test $ac_cv_func_renameat = no; then
26784 elif test $REPLACE_RENAME = 1; then
26788 if test $HAVE_RENAMEAT = 0 || test $REPLACE_RENAMEAT = 1; then
26797 gl_LIBOBJS="$gl_LIBOBJS renameat.$ac_objext"
26800 if test $HAVE_RENAMEAT = 0; then
26809 gl_LIBOBJS="$gl_LIBOBJS at-func2.$ac_objext"
26823 $as_echo "#define GNULIB_TEST_RENAMEAT 1" >>confdefs.h
26830 for ac_func in rewinddir
26832 ac_fn_c_check_func "$LINENO" "rewinddir" "ac_cv_func_rewinddir"
26833 if test "x$ac_cv_func_rewinddir" = xyes; then :
26834 cat >>confdefs.h <<_ACEOF
26835 #define HAVE_REWINDDIR 1
26841 if test $ac_cv_func_rewinddir = no; then
26845 if test $HAVE_REWINDDIR = 0; then
26854 gl_LIBOBJS="$gl_LIBOBJS rewinddir.$ac_objext"
26868 $as_echo "#define GNULIB_TEST_REWINDDIR 1" >>confdefs.h
26875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rmdir works" >&5
26876 $as_echo_n "checking whether rmdir works... " >&6; }
26877 if ${gl_cv_func_rmdir_works+:} false; then :
26878 $as_echo_n "(cached) " >&6
26881 touch conftest.file
26882 if test "$cross_compiling" = yes; then :
26884 # Guess yes on glibc systems.
26885 *-gnu*) gl_cv_func_rmdir_works="guessing yes" ;;
26886 # If we don't know, assume the worst.
26887 *) gl_cv_func_rmdir_works="guessing no" ;;
26891 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26892 /* end confdefs.h. */
26896 # include <unistd.h>
26897 #else /* on Windows with MSVC */
26898 # include <direct.h>
26905 if (!rmdir ("conftest.file/"))
26907 else if (errno != ENOTDIR)
26909 if (!rmdir ("conftest.dir/./"))
26917 if ac_fn_c_try_run "$LINENO"; then :
26918 gl_cv_func_rmdir_works=yes
26920 gl_cv_func_rmdir_works=no
26922 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
26923 conftest.$ac_objext conftest.beam conftest.$ac_ext
26926 rm -rf conftest.dir conftest.file
26928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rmdir_works" >&5
26929 $as_echo "$gl_cv_func_rmdir_works" >&6; }
26930 case "$gl_cv_func_rmdir_works" in
26937 if test $REPLACE_RMDIR = 1; then
26946 gl_LIBOBJS="$gl_LIBOBJS rmdir.$ac_objext"
26960 $as_echo "#define GNULIB_TEST_RMDIR 1" >>confdefs.h
26968 for ac_func in rpmatch
26970 ac_fn_c_check_func "$LINENO" "rpmatch" "ac_cv_func_rpmatch"
26971 if test "x$ac_cv_func_rpmatch" = xyes; then :
26972 cat >>confdefs.h <<_ACEOF
26973 #define HAVE_RPMATCH 1
26979 if test $ac_cv_func_rpmatch = no; then
26983 if test $HAVE_RPMATCH = 0; then
26992 gl_LIBOBJS="$gl_LIBOBJS rpmatch.$ac_objext"
26995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and YESEXPR" >&5
26996 $as_echo_n "checking for nl_langinfo and YESEXPR... " >&6; }
26997 if ${gl_cv_langinfo_yesexpr+:} false; then :
26998 $as_echo_n "(cached) " >&6
27000 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27001 /* end confdefs.h. */
27002 #include <langinfo.h>
27006 char* cs = nl_langinfo(YESEXPR); return !cs;
27011 if ac_fn_c_try_link "$LINENO"; then :
27012 gl_cv_langinfo_yesexpr=yes
27014 gl_cv_langinfo_yesexpr=no
27016 rm -f core conftest.err conftest.$ac_objext \
27017 conftest$ac_exeext conftest.$ac_ext
27020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_langinfo_yesexpr" >&5
27021 $as_echo "$gl_cv_langinfo_yesexpr" >&6; }
27022 if test $gl_cv_langinfo_yesexpr = yes; then
27024 $as_echo "#define HAVE_LANGINFO_YESEXPR 1" >>confdefs.h
27040 $as_echo "#define GNULIB_TEST_RPMATCH 1" >>confdefs.h
27063 if test $ac_cv_func_secure_getenv = no; then
27064 HAVE_SECURE_GETENV=0
27067 if test $HAVE_SECURE_GETENV = 0; then
27076 gl_LIBOBJS="$gl_LIBOBJS secure_getenv.$ac_objext"
27079 for ac_func in __secure_getenv
27081 ac_fn_c_check_func "$LINENO" "__secure_getenv" "ac_cv_func___secure_getenv"
27082 if test "x$ac_cv_func___secure_getenv" = xyes; then :
27083 cat >>confdefs.h <<_ACEOF
27084 #define HAVE___SECURE_GETENV 1
27090 if test $ac_cv_func___secure_getenv = no; then
27091 for ac_func in issetugid
27093 ac_fn_c_check_func "$LINENO" "issetugid" "ac_cv_func_issetugid"
27094 if test "x$ac_cv_func_issetugid" = xyes; then :
27095 cat >>confdefs.h <<_ACEOF
27096 #define HAVE_ISSETUGID 1
27110 GNULIB_SECURE_GETENV=1
27116 $as_echo "#define GNULIB_TEST_SECURE_GETENV 1" >>confdefs.h
27120 for ac_header in selinux/flask.h
27122 ac_fn_c_check_header_mongrel "$LINENO" "selinux/flask.h" "ac_cv_header_selinux_flask_h" "$ac_includes_default"
27123 if test "x$ac_cv_header_selinux_flask_h" = xyes; then :
27124 cat >>confdefs.h <<_ACEOF
27125 #define HAVE_SELINUX_FLASK_H 1
27140 gl_LIBOBJS="$gl_LIBOBJS selinux-at.$ac_objext"
27144 if test "$with_selinux" != no; then
27145 for ac_header in selinux/selinux.h
27147 ac_fn_c_check_header_mongrel "$LINENO" "selinux/selinux.h" "ac_cv_header_selinux_selinux_h" "$ac_includes_default"
27148 if test "x$ac_cv_header_selinux_selinux_h" = xyes; then :
27149 cat >>confdefs.h <<_ACEOF
27150 #define HAVE_SELINUX_SELINUX_H 1
27158 if test "$ac_cv_header_selinux_selinux_h" = yes; then
27159 # We do have <selinux/selinux.h>, so do compile getfilecon.c
27160 # and arrange to use its wrappers.
27170 if test $gl_cv_have_include_next = yes; then
27171 gl_cv_next_selinux_selinux_h='<'selinux/selinux.h'>'
27173 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <selinux/selinux.h>" >&5
27174 $as_echo_n "checking absolute name of <selinux/selinux.h>... " >&6; }
27175 if ${gl_cv_next_selinux_selinux_h+:} false; then :
27176 $as_echo_n "(cached) " >&6
27179 if test $ac_cv_header_selinux_selinux_h = yes; then
27182 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27183 /* end confdefs.h. */
27184 #include <selinux/selinux.h>
27188 aix*) gl_absname_cpp="$ac_cpp -C" ;;
27189 *) gl_absname_cpp="$ac_cpp" ;;
27194 gl_dirsep_regex='[/\\]'
27197 gl_dirsep_regex='\/'
27200 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
27202 gl_header_literal_regex=`echo 'selinux/selinux.h' \
27203 | sed -e "$gl_make_literal_regex_sed"`
27204 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
27205 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
27210 gl_cv_next_selinux_selinux_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
27211 sed -n "$gl_absolute_header_sed"`'"'
27213 gl_cv_next_selinux_selinux_h='<'selinux/selinux.h'>'
27218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_selinux_selinux_h" >&5
27219 $as_echo "$gl_cv_next_selinux_selinux_h" >&6; }
27221 NEXT_SELINUX_SELINUX_H=$gl_cv_next_selinux_selinux_h
27223 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
27224 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
27225 gl_next_as_first_directive='<'selinux/selinux.h'>'
27227 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
27228 gl_next_as_first_directive=$gl_cv_next_selinux_selinux_h
27230 NEXT_AS_FIRST_DIRECTIVE_SELINUX_SELINUX_H=$gl_next_as_first_directive
27236 $as_echo "#define getfilecon rpl_getfilecon" >>confdefs.h
27239 $as_echo "#define lgetfilecon rpl_lgetfilecon" >>confdefs.h
27242 $as_echo "#define fgetfilecon rpl_fgetfilecon" >>confdefs.h
27246 case "$ac_cv_search_setfilecon:$ac_cv_header_selinux_selinux_h" in
27247 no:*) # already warned
27250 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libselinux was found but selinux/selinux.h is missing." >&5
27251 $as_echo "$as_me: WARNING: libselinux was found but selinux/selinux.h is missing." >&2;}
27252 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: GNU tar will be compiled without SELinux support." >&5
27253 $as_echo "$as_me: WARNING: GNU tar will be compiled without SELinux support." >&2;}
27256 # Do as if <selinux/selinux.h> does not exist, even if
27257 # AC_CHECK_HEADERS_ONCE has already determined that it exists.
27258 $as_echo "#define HAVE_SELINUX_SELINUX_H 0" >>confdefs.h
27264 if test "$with_selinux" != no; then
27265 for ac_header in selinux/context.h
27267 ac_fn_c_check_header_mongrel "$LINENO" "selinux/context.h" "ac_cv_header_selinux_context_h" "$ac_includes_default"
27268 if test "x$ac_cv_header_selinux_context_h" = xyes; then :
27269 cat >>confdefs.h <<_ACEOF
27270 #define HAVE_SELINUX_CONTEXT_H 1
27274 SELINUX_CONTEXT_H=selinux/context.h
27280 SELINUX_CONTEXT_H=selinux/context.h
27283 if test -n "$SELINUX_CONTEXT_H"; then
27284 GL_GENERATE_SELINUX_CONTEXT_H_TRUE=
27285 GL_GENERATE_SELINUX_CONTEXT_H_FALSE='#'
27287 GL_GENERATE_SELINUX_CONTEXT_H_TRUE='#'
27288 GL_GENERATE_SELINUX_CONTEXT_H_FALSE=
27292 if test "$with_selinux" != no && test "$ac_cv_header_selinux_selinux_h" = yes; then
27301 gl_LIBOBJS="$gl_LIBOBJS getfilecon.$ac_objext"
27306 if test $ac_cv_func_setenv = no; then
27309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setenv validates arguments" >&5
27310 $as_echo_n "checking whether setenv validates arguments... " >&6; }
27311 if ${gl_cv_func_setenv_works+:} false; then :
27312 $as_echo_n "(cached) " >&6
27314 if test "$cross_compiling" = yes; then :
27316 # Guess yes on glibc systems.
27317 *-gnu*) gl_cv_func_setenv_works="guessing yes" ;;
27318 # If we don't know, assume the worst.
27319 *) gl_cv_func_setenv_works="guessing no" ;;
27323 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27324 /* end confdefs.h. */
27326 #include <stdlib.h>
27328 #include <string.h>
27336 if (setenv ("", "", 0) != -1)
27338 else if (errno != EINVAL)
27342 if (setenv ("a", "=", 1) != 0)
27344 else if (strcmp (getenv ("a"), "=") != 0)
27353 if ac_fn_c_try_run "$LINENO"; then :
27354 gl_cv_func_setenv_works=yes
27356 gl_cv_func_setenv_works=no
27358 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27359 conftest.$ac_objext conftest.beam conftest.$ac_ext
27363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_setenv_works" >&5
27364 $as_echo "$gl_cv_func_setenv_works" >&6; }
27365 case "$gl_cv_func_setenv_works" in
27373 if test $HAVE_SETENV = 0 || test $REPLACE_SETENV = 1; then
27382 gl_LIBOBJS="$gl_LIBOBJS setenv.$ac_objext"
27396 $as_echo "#define GNULIB_TEST_SETENV 1" >>confdefs.h
27411 if test $gl_cv_have_include_next = yes; then
27412 gl_cv_next_signal_h='<'signal.h'>'
27414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
27415 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
27416 if ${gl_cv_next_signal_h+:} false; then :
27417 $as_echo_n "(cached) " >&6
27420 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27421 /* end confdefs.h. */
27422 #include <signal.h>
27426 aix*) gl_absname_cpp="$ac_cpp -C" ;;
27427 *) gl_absname_cpp="$ac_cpp" ;;
27432 gl_dirsep_regex='[/\\]'
27435 gl_dirsep_regex='\/'
27438 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
27440 gl_header_literal_regex=`echo 'signal.h' \
27441 | sed -e "$gl_make_literal_regex_sed"`
27442 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
27443 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
27448 gl_cv_next_signal_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
27449 sed -n "$gl_absolute_header_sed"`'"'
27453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
27454 $as_echo "$gl_cv_next_signal_h" >&6; }
27456 NEXT_SIGNAL_H=$gl_cv_next_signal_h
27458 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
27459 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
27460 gl_next_as_first_directive='<'signal.h'>'
27462 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
27463 gl_next_as_first_directive=$gl_cv_next_signal_h
27465 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
27471 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
27472 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
27473 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
27474 #include <signal.h>
27477 if test "x$ac_cv_type_volatile_sig_atomic_t" = xyes; then :
27480 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
27489 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
27490 #include <signal.h>
27493 if test "x$ac_cv_type_sighandler_t" = xyes; then :
27496 HAVE_SIGHANDLER_T=0
27501 for gl_func in pthread_sigmask sigaction sigaddset sigdelset sigemptyset sigfillset sigismember sigpending sigprocmask; do
27502 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
27503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
27504 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
27505 if eval \${$as_gl_Symbol+:} false; then :
27506 $as_echo_n "(cached) " >&6
27508 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27509 /* end confdefs.h. */
27510 #include <signal.h>
27521 if ac_fn_c_try_compile "$LINENO"; then :
27522 eval "$as_gl_Symbol=yes"
27524 eval "$as_gl_Symbol=no"
27526 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27528 eval ac_res=\$$as_gl_Symbol
27529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
27530 $as_echo "$ac_res" >&6; }
27531 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
27532 cat >>confdefs.h <<_ACEOF
27533 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
27536 eval ac_cv_have_decl_$gl_func=yes
27542 for ac_header in stdint.h
27544 ac_fn_c_check_header_mongrel "$LINENO" "stdint.h" "ac_cv_header_stdint_h" "$ac_includes_default"
27545 if test "x$ac_cv_header_stdint_h" = xyes; then :
27546 cat >>confdefs.h <<_ACEOF
27547 #define HAVE_STDINT_H 1
27554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SIZE_MAX" >&5
27555 $as_echo_n "checking for SIZE_MAX... " >&6; }
27556 if ${gl_cv_size_max+:} false; then :
27557 $as_echo_n "(cached) " >&6
27561 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27562 /* end confdefs.h. */
27564 #include <limits.h>
27566 #include <stdint.h>
27573 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27574 $EGREP "Found it" >/dev/null 2>&1; then :
27579 if test -z "$gl_cv_size_max"; then
27580 if ac_fn_c_compute_int "$LINENO" "sizeof (size_t) * CHAR_BIT - 1" "size_t_bits_minus_1" "#include <stddef.h>
27581 #include <limits.h>"; then :
27584 size_t_bits_minus_1=
27587 if ac_fn_c_compute_int "$LINENO" "sizeof (size_t) <= sizeof (unsigned int)" "fits_in_uint" "#include <stddef.h>"; then :
27593 if test -n "$size_t_bits_minus_1" && test -n "$fits_in_uint"; then
27594 if test $fits_in_uint = 1; then
27595 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27596 /* end confdefs.h. */
27597 #include <stddef.h>
27599 extern unsigned long foo;
27609 if ac_fn_c_try_compile "$LINENO"; then :
27612 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27614 if test $fits_in_uint = 1; then
27615 gl_cv_size_max="(((1U << $size_t_bits_minus_1) - 1) * 2 + 1)"
27617 gl_cv_size_max="(((1UL << $size_t_bits_minus_1) - 1) * 2 + 1)"
27620 gl_cv_size_max='((size_t)~(size_t)0)'
27625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_size_max" >&5
27626 $as_echo "$gl_cv_size_max" >&6; }
27627 if test "$gl_cv_size_max" != yes; then
27629 cat >>confdefs.h <<_ACEOF
27630 #define SIZE_MAX $gl_cv_size_max
27638 ac_fn_c_check_decl "$LINENO" "sleep" "ac_cv_have_decl_sleep" "#include <unistd.h>
27640 if test "x$ac_cv_have_decl_sleep" = xyes; then :
27646 cat >>confdefs.h <<_ACEOF
27647 #define HAVE_DECL_SLEEP $ac_have_decl
27651 if test $ac_cv_have_decl_sleep != yes; then
27654 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working sleep" >&5
27655 $as_echo_n "checking for working sleep... " >&6; }
27656 if ${gl_cv_func_sleep_works+:} false; then :
27657 $as_echo_n "(cached) " >&6
27659 if test "$cross_compiling" = yes; then :
27661 # Guess yes on glibc systems.
27662 *-gnu*) gl_cv_func_sleep_works="guessing yes" ;;
27663 # If we don't know, assume the worst.
27664 *) gl_cv_func_sleep_works="guessing no" ;;
27668 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27669 /* end confdefs.h. */
27672 #include <unistd.h>
27673 #include <signal.h>
27675 handle_alarm (int sig)
27677 if (sig != SIGALRM)
27685 /* Failure to compile this test due to missing alarm is okay,
27686 since all such platforms (mingw) also lack sleep. */
27687 unsigned int pentecost = 50 * 24 * 60 * 60; /* 50 days. */
27688 unsigned int remaining;
27689 signal (SIGALRM, handle_alarm);
27691 remaining = sleep (pentecost);
27692 if (remaining > pentecost)
27694 if (remaining <= pentecost - 10)
27702 if ac_fn_c_try_run "$LINENO"; then :
27703 gl_cv_func_sleep_works=yes
27705 gl_cv_func_sleep_works=no
27707 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27708 conftest.$ac_objext conftest.beam conftest.$ac_ext
27712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_sleep_works" >&5
27713 $as_echo "$gl_cv_func_sleep_works" >&6; }
27714 case "$gl_cv_func_sleep_works" in
27722 if test $HAVE_SLEEP = 0 || test $REPLACE_SLEEP = 1; then
27731 gl_LIBOBJS="$gl_LIBOBJS sleep.$ac_objext"
27745 $as_echo "#define GNULIB_TEST_SLEEP 1" >>confdefs.h
27751 gl_cv_func_snprintf_usable=no
27752 for ac_func in snprintf
27754 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
27755 if test "x$ac_cv_func_snprintf" = xyes; then :
27756 cat >>confdefs.h <<_ACEOF
27757 #define HAVE_SNPRINTF 1
27763 if test $ac_cv_func_snprintf = yes; then
27767 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf respects a size of 1" >&5
27768 $as_echo_n "checking whether snprintf respects a size of 1... " >&6; }
27769 if ${gl_cv_func_snprintf_size1+:} false; then :
27770 $as_echo_n "(cached) " >&6
27773 if test "$cross_compiling" = yes; then :
27774 gl_cv_func_snprintf_size1="guessing yes"
27776 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27777 /* end confdefs.h. */
27781 # define my_snprintf snprintf
27783 # include <stdarg.h>
27784 static int my_snprintf (char *buf, int size, const char *format, ...)
27788 va_start (args, format);
27789 ret = vsnprintf (buf, size, format, args);
27796 static char buf[8] = { 'D', 'E', 'A', 'D', 'B', 'E', 'E', 'F' };
27797 my_snprintf (buf, 1, "%d", 12345);
27798 return buf[1] != 'E';
27801 if ac_fn_c_try_run "$LINENO"; then :
27802 gl_cv_func_snprintf_size1=yes
27804 gl_cv_func_snprintf_size1=no
27806 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27807 conftest.$ac_objext conftest.beam conftest.$ac_ext
27812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_snprintf_size1" >&5
27813 $as_echo "$gl_cv_func_snprintf_size1" >&6; }
27815 case "$gl_cv_func_snprintf_size1" in
27818 case "$gl_cv_func_snprintf_retval_c99" in
27822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether printf supports POSIX/XSI format strings with positions" >&5
27823 $as_echo_n "checking whether printf supports POSIX/XSI format strings with positions... " >&6; }
27824 if ${gl_cv_func_printf_positions+:} false; then :
27825 $as_echo_n "(cached) " >&6
27828 if test "$cross_compiling" = yes; then :
27831 netbsd[1-3]* | netbsdelf[1-3]* | netbsdaout[1-3]* | netbsdcoff[1-3]*)
27832 gl_cv_func_printf_positions="guessing no";;
27833 beos*) gl_cv_func_printf_positions="guessing no";;
27834 mingw* | pw*) gl_cv_func_printf_positions="guessing no";;
27835 *) gl_cv_func_printf_positions="guessing yes";;
27839 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27840 /* end confdefs.h. */
27843 #include <string.h>
27844 /* The string "%2$d %1$d", with dollar characters protected from the shell's
27845 dollar expansion (possibly an autoconf bug). */
27846 static char format[] = { '%', '2', '$', 'd', ' ', '%', '1', '$', 'd', '\0' };
27847 static char buf[100];
27850 sprintf (buf, format, 33, 55);
27851 return (strcmp (buf, "55 33") != 0);
27854 if ac_fn_c_try_run "$LINENO"; then :
27855 gl_cv_func_printf_positions=yes
27857 gl_cv_func_printf_positions=no
27859 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27860 conftest.$ac_objext conftest.beam conftest.$ac_ext
27865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_positions" >&5
27866 $as_echo "$gl_cv_func_printf_positions" >&6; }
27868 case "$gl_cv_func_printf_positions" in
27870 gl_cv_func_snprintf_usable=yes
27878 if test $gl_cv_func_snprintf_usable = no; then
27889 gl_LIBOBJS="$gl_LIBOBJS snprintf.$ac_objext"
27891 if test $ac_cv_func_snprintf = yes; then
27898 if test $ac_cv_have_decl_snprintf = no; then
27899 HAVE_DECL_SNPRINTF=0
27913 $as_echo "#define GNULIB_TEST_SNPRINTF 1" >>confdefs.h
27919 cat >>confdefs.h <<_ACEOF
27920 #define GNULIB_SNPRINTF 1
27925 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
27926 $as_echo_n "checking for ssize_t... " >&6; }
27927 if ${gt_cv_ssize_t+:} false; then :
27928 $as_echo_n "(cached) " >&6
27930 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27931 /* end confdefs.h. */
27932 #include <sys/types.h>
27936 int x = sizeof (ssize_t *) + sizeof (ssize_t);
27942 if ac_fn_c_try_compile "$LINENO"; then :
27947 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
27950 $as_echo "$gt_cv_ssize_t" >&6; }
27951 if test $gt_cv_ssize_t = no; then
27953 $as_echo "#define ssize_t int" >>confdefs.h
27960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
27961 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
27962 if ${gl_cv_func_stat_dir_slash+:} false; then :
27963 $as_echo_n "(cached) " >&6
27965 if test "$cross_compiling" = yes; then :
27967 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
27968 *) gl_cv_func_stat_dir_slash="guessing yes";;
27971 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27972 /* end confdefs.h. */
27973 #include <sys/stat.h>
27978 struct stat st; return stat (".", &st) != stat ("./", &st);
27983 if ac_fn_c_try_run "$LINENO"; then :
27984 gl_cv_func_stat_dir_slash=yes
27986 gl_cv_func_stat_dir_slash=no
27988 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27989 conftest.$ac_objext conftest.beam conftest.$ac_ext
27993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
27994 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
27995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
27996 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
27997 if ${gl_cv_func_stat_file_slash+:} false; then :
27998 $as_echo_n "(cached) " >&6
28001 # Assume that if we have lstat, we can also check symlinks.
28002 if test $ac_cv_func_lstat = yes; then
28003 ln -s conftest.tmp conftest.lnk
28005 if test "$cross_compiling" = yes; then :
28007 # Guess yes on glibc systems.
28008 *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
28009 # If we don't know, assume the worst.
28010 *) gl_cv_func_stat_file_slash="guessing no" ;;
28014 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28015 /* end confdefs.h. */
28016 #include <sys/stat.h>
28023 if (!stat ("conftest.tmp/", &st))
28026 if (!stat ("conftest.lnk/", &st))
28035 if ac_fn_c_try_run "$LINENO"; then :
28036 gl_cv_func_stat_file_slash=yes
28038 gl_cv_func_stat_file_slash=no
28040 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28041 conftest.$ac_objext conftest.beam conftest.$ac_ext
28044 rm -f conftest.tmp conftest.lnk
28046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
28047 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
28048 case $gl_cv_func_stat_dir_slash in
28049 *no) REPLACE_STAT=1
28051 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
28054 case $gl_cv_func_stat_file_slash in
28055 *no) REPLACE_STAT=1
28057 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
28061 if test $REPLACE_STAT = 1; then
28070 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
28085 $as_echo "#define GNULIB_TEST_STAT 1" >>confdefs.h
28093 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>
28094 #include <sys/stat.h>
28096 if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = xyes; then :
28098 cat >>confdefs.h <<_ACEOF
28099 #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
28102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
28103 $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
28104 if ${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+:} false; then :
28105 $as_echo_n "(cached) " >&6
28107 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28108 /* end confdefs.h. */
28110 #include <sys/types.h>
28111 #include <sys/stat.h>
28112 #if HAVE_SYS_TIME_H
28113 # include <sys/time.h>
28116 struct timespec ts;
28129 if ac_fn_c_try_compile "$LINENO"; then :
28130 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
28132 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no
28134 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
28137 $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
28138 if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
28140 $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
28144 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>
28145 #include <sys/stat.h>
28147 if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = xyes; then :
28149 cat >>confdefs.h <<_ACEOF
28150 #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
28155 ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
28156 #include <sys/stat.h>
28158 if test "x$ac_cv_member_struct_stat_st_atimensec" = xyes; then :
28160 cat >>confdefs.h <<_ACEOF
28161 #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
28166 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>
28167 #include <sys/stat.h>
28169 if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = xyes; then :
28171 cat >>confdefs.h <<_ACEOF
28172 #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
28188 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>
28189 #include <sys/stat.h>
28191 if test "x$ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" = xyes; then :
28193 cat >>confdefs.h <<_ACEOF
28194 #define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
28199 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimensec" "ac_cv_member_struct_stat_st_birthtimensec" "#include <sys/types.h>
28200 #include <sys/stat.h>
28202 if test "x$ac_cv_member_struct_stat_st_birthtimensec" = xyes; then :
28204 cat >>confdefs.h <<_ACEOF
28205 #define HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC 1
28210 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>
28211 #include <sys/stat.h>
28213 if test "x$ac_cv_member_struct_stat_st_birthtim_tv_nsec" = xyes; then :
28215 cat >>confdefs.h <<_ACEOF
28216 #define HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC 1
28229 cat >>confdefs.h <<_ACEOF
28230 #define GNULIB_STATAT 1
28234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdalign.h" >&5
28235 $as_echo_n "checking for working stdalign.h... " >&6; }
28236 if ${gl_cv_header_working_stdalign_h+:} false; then :
28237 $as_echo_n "(cached) " >&6
28239 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28240 /* end confdefs.h. */
28241 #include <stdalign.h>
28242 #include <stddef.h>
28244 /* Test that alignof yields a result consistent with offsetof.
28245 This catches GCC bug 52023
28246 <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023>. */
28248 template <class t> struct alignof_helper { char a; t b; };
28249 # define ao(type) offsetof (alignof_helper<type>, b)
28251 # define ao(type) offsetof (struct { char a; type b; }, b)
28253 char test_double[ao (double) % _Alignof (double) == 0 ? 1 : -1];
28254 char test_long[ao (long int) % _Alignof (long int) == 0 ? 1 : -1];
28255 char test_alignof[alignof (double) == _Alignof (double) ? 1 : -1];
28257 /* Test _Alignas only on platforms where gnulib can help. */
28259 (__GNUC__ || __IBMC__ || __IBMCPP__ \
28260 || 0x5110 <= __SUNPRO_C || 1300 <= _MSC_VER)
28261 struct alignas_test { char c; char alignas (8) alignas_8; };
28262 char test_alignas[offsetof (struct alignas_test, alignas_8) == 8
28274 if ac_fn_c_try_compile "$LINENO"; then :
28275 gl_cv_header_working_stdalign_h=yes
28277 gl_cv_header_working_stdalign_h=no
28279 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdalign_h" >&5
28282 $as_echo "$gl_cv_header_working_stdalign_h" >&6; }
28284 if test $gl_cv_header_working_stdalign_h = yes; then
28287 STDALIGN_H='stdalign.h'
28291 if test -n "$STDALIGN_H"; then
28292 GL_GENERATE_STDALIGN_H_TRUE=
28293 GL_GENERATE_STDALIGN_H_FALSE='#'
28295 GL_GENERATE_STDALIGN_H_TRUE='#'
28296 GL_GENERATE_STDALIGN_H_FALSE=
28302 NEXT_STDARG_H='<stdarg.h>'
28303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
28304 $as_echo_n "checking for va_copy... " >&6; }
28305 if ${gl_cv_func_va_copy+:} false; then :
28306 $as_echo_n "(cached) " >&6
28309 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28310 /* end confdefs.h. */
28311 #include <stdarg.h>
28317 void (*func) (va_list, va_list) = va_copy;
28324 if ac_fn_c_try_compile "$LINENO"; then :
28325 gl_cv_func_va_copy=yes
28327 gl_cv_func_va_copy=no
28329 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
28333 $as_echo "$gl_cv_func_va_copy" >&6; }
28334 if test $gl_cv_func_va_copy = no; then
28335 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28336 /* end confdefs.h. */
28337 #if defined _AIX && !defined __GNUC__
28342 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28343 $EGREP "vaccine" >/dev/null 2>&1; then :
28350 if test $gl_aixcc = yes; then
28360 if test $gl_cv_have_include_next = yes; then
28361 gl_cv_next_stdarg_h='<'stdarg.h'>'
28363 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
28364 $as_echo_n "checking absolute name of <stdarg.h>... " >&6; }
28365 if ${gl_cv_next_stdarg_h+:} false; then :
28366 $as_echo_n "(cached) " >&6
28369 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28370 /* end confdefs.h. */
28371 #include <stdarg.h>
28375 aix*) gl_absname_cpp="$ac_cpp -C" ;;
28376 *) gl_absname_cpp="$ac_cpp" ;;
28381 gl_dirsep_regex='[/\\]'
28384 gl_dirsep_regex='\/'
28387 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
28389 gl_header_literal_regex=`echo 'stdarg.h' \
28390 | sed -e "$gl_make_literal_regex_sed"`
28391 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
28392 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
28397 gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
28398 sed -n "$gl_absolute_header_sed"`'"'
28402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
28403 $as_echo "$gl_cv_next_stdarg_h" >&6; }
28405 NEXT_STDARG_H=$gl_cv_next_stdarg_h
28407 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
28408 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
28409 gl_next_as_first_directive='<'stdarg.h'>'
28411 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
28412 gl_next_as_first_directive=$gl_cv_next_stdarg_h
28414 NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
28419 if test "$gl_cv_next_stdarg_h" = '""'; then
28420 gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
28421 NEXT_STDARG_H="$gl_cv_next_stdarg_h"
28425 saved_as_echo_n="$as_echo_n"
28427 if ${gl_cv_func___va_copy+:} false; then :
28428 $as_echo_n "(cached) " >&6
28431 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28432 /* end confdefs.h. */
28433 #include <stdarg.h>
28446 if ac_fn_c_try_compile "$LINENO"; then :
28447 gl_cv_func___va_copy=yes
28449 gl_cv_func___va_copy=no
28451 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28454 as_echo_n="$saved_as_echo_n"
28456 if test $gl_cv_func___va_copy = yes; then
28458 $as_echo "#define va_copy __va_copy" >>confdefs.h
28463 $as_echo "#define va_copy gl_va_copy" >>confdefs.h
28469 if test -n "$STDARG_H"; then
28470 GL_GENERATE_STDARG_H_TRUE=
28471 GL_GENERATE_STDARG_H_FALSE='#'
28473 GL_GENERATE_STDARG_H_TRUE='#'
28474 GL_GENERATE_STDARG_H_FALSE=
28482 # Define two additional variables used in the Makefile substitution.
28484 if test "$ac_cv_header_stdbool_h" = yes; then
28487 STDBOOL_H='stdbool.h'
28490 if test -n "$STDBOOL_H"; then
28491 GL_GENERATE_STDBOOL_H_TRUE=
28492 GL_GENERATE_STDBOOL_H_FALSE='#'
28494 GL_GENERATE_STDBOOL_H_TRUE='#'
28495 GL_GENERATE_STDBOOL_H_FALSE=
28499 if test "$ac_cv_type__Bool" = yes; then
28510 if test $gt_cv_c_wchar_t = no; then
28514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
28515 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
28516 if ${gl_cv_decl_null_works+:} false; then :
28517 $as_echo_n "(cached) " >&6
28519 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28520 /* end confdefs.h. */
28521 #include <stddef.h>
28522 int test[2 * (sizeof NULL == sizeof (void *)) -1];
28532 if ac_fn_c_try_compile "$LINENO"; then :
28533 gl_cv_decl_null_works=yes
28535 gl_cv_decl_null_works=no
28537 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
28540 $as_echo "$gl_cv_decl_null_works" >&6; }
28541 if test $gl_cv_decl_null_works = no; then
28546 if test -n "$STDDEF_H"; then
28547 GL_GENERATE_STDDEF_H_TRUE=
28548 GL_GENERATE_STDDEF_H_FALSE='#'
28550 GL_GENERATE_STDDEF_H_TRUE='#'
28551 GL_GENERATE_STDDEF_H_FALSE=
28554 if test -n "$STDDEF_H"; then
28563 if test $gl_cv_have_include_next = yes; then
28564 gl_cv_next_stddef_h='<'stddef.h'>'
28566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
28567 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
28568 if ${gl_cv_next_stddef_h+:} false; then :
28569 $as_echo_n "(cached) " >&6
28572 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28573 /* end confdefs.h. */
28574 #include <stddef.h>
28578 aix*) gl_absname_cpp="$ac_cpp -C" ;;
28579 *) gl_absname_cpp="$ac_cpp" ;;
28584 gl_dirsep_regex='[/\\]'
28587 gl_dirsep_regex='\/'
28590 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
28592 gl_header_literal_regex=`echo 'stddef.h' \
28593 | sed -e "$gl_make_literal_regex_sed"`
28594 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
28595 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
28600 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
28601 sed -n "$gl_absolute_header_sed"`'"'
28605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
28606 $as_echo "$gl_cv_next_stddef_h" >&6; }
28608 NEXT_STDDEF_H=$gl_cv_next_stddef_h
28610 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
28611 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
28612 gl_next_as_first_directive='<'stddef.h'>'
28614 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
28615 gl_next_as_first_directive=$gl_cv_next_stddef_h
28617 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
28635 if test $gl_cv_have_include_next = yes; then
28636 gl_cv_next_stdio_h='<'stdio.h'>'
28638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
28639 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
28640 if ${gl_cv_next_stdio_h+:} false; then :
28641 $as_echo_n "(cached) " >&6
28644 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28645 /* end confdefs.h. */
28650 aix*) gl_absname_cpp="$ac_cpp -C" ;;
28651 *) gl_absname_cpp="$ac_cpp" ;;
28656 gl_dirsep_regex='[/\\]'
28659 gl_dirsep_regex='\/'
28662 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
28664 gl_header_literal_regex=`echo 'stdio.h' \
28665 | sed -e "$gl_make_literal_regex_sed"`
28666 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
28667 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
28672 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
28673 sed -n "$gl_absolute_header_sed"`'"'
28677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
28678 $as_echo "$gl_cv_next_stdio_h" >&6; }
28680 NEXT_STDIO_H=$gl_cv_next_stdio_h
28682 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
28683 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
28684 gl_next_as_first_directive='<'stdio.h'>'
28686 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
28687 gl_next_as_first_directive=$gl_cv_next_stdio_h
28689 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
28698 cat >>confdefs.h <<_ACEOF
28699 #define GNULIB_FSCANF 1
28706 cat >>confdefs.h <<_ACEOF
28707 #define GNULIB_SCANF 1
28732 for gl_func in dprintf fpurge fseeko ftello getdelim getline gets pclose popen renameat snprintf tmpfile vdprintf vsnprintf; do
28733 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
28734 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
28735 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
28736 if eval \${$as_gl_Symbol+:} false; then :
28737 $as_echo_n "(cached) " >&6
28739 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28740 /* end confdefs.h. */
28752 if ac_fn_c_try_compile "$LINENO"; then :
28753 eval "$as_gl_Symbol=yes"
28755 eval "$as_gl_Symbol=no"
28757 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28759 eval ac_res=\$$as_gl_Symbol
28760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
28761 $as_echo "$ac_res" >&6; }
28762 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
28763 cat >>confdefs.h <<_ACEOF
28764 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
28767 eval ac_cv_have_decl_$gl_func=yes
28782 if test $gl_cv_have_include_next = yes; then
28783 gl_cv_next_stdlib_h='<'stdlib.h'>'
28785 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
28786 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
28787 if ${gl_cv_next_stdlib_h+:} false; then :
28788 $as_echo_n "(cached) " >&6
28791 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28792 /* end confdefs.h. */
28793 #include <stdlib.h>
28797 aix*) gl_absname_cpp="$ac_cpp -C" ;;
28798 *) gl_absname_cpp="$ac_cpp" ;;
28803 gl_dirsep_regex='[/\\]'
28806 gl_dirsep_regex='\/'
28809 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
28811 gl_header_literal_regex=`echo 'stdlib.h' \
28812 | sed -e "$gl_make_literal_regex_sed"`
28813 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
28814 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
28819 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
28820 sed -n "$gl_absolute_header_sed"`'"'
28824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
28825 $as_echo "$gl_cv_next_stdlib_h" >&6; }
28827 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
28829 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
28830 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
28831 gl_next_as_first_directive='<'stdlib.h'>'
28833 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
28834 gl_next_as_first_directive=$gl_cv_next_stdlib_h
28836 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
28843 for gl_func in _Exit atoll canonicalize_file_name getloadavg getsubopt grantpt initstate initstate_r mkdtemp mkostemp mkostemps mkstemp mkstemps posix_openpt ptsname ptsname_r random random_r realpath rpmatch secure_getenv setenv setstate setstate_r srandom srandom_r strtod strtoll strtoull unlockpt unsetenv; do
28844 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
28845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
28846 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
28847 if eval \${$as_gl_Symbol+:} false; then :
28848 $as_echo_n "(cached) " >&6
28850 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28851 /* end confdefs.h. */
28852 #include <stdlib.h>
28853 #if HAVE_SYS_LOADAVG_H
28854 # include <sys/loadavg.h>
28857 # include <random.h>
28869 if ac_fn_c_try_compile "$LINENO"; then :
28870 eval "$as_gl_Symbol=yes"
28872 eval "$as_gl_Symbol=no"
28874 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28876 eval ac_res=\$$as_gl_Symbol
28877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
28878 $as_echo "$ac_res" >&6; }
28879 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
28880 cat >>confdefs.h <<_ACEOF
28881 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
28884 eval ac_cv_have_decl_$gl_func=yes
28895 for ac_func in stpcpy
28897 ac_fn_c_check_func "$LINENO" "stpcpy" "ac_cv_func_stpcpy"
28898 if test "x$ac_cv_func_stpcpy" = xyes; then :
28899 cat >>confdefs.h <<_ACEOF
28900 #define HAVE_STPCPY 1
28906 if test $ac_cv_func_stpcpy = no; then
28910 if test $HAVE_STPCPY = 0; then
28919 gl_LIBOBJS="$gl_LIBOBJS stpcpy.$ac_objext"
28936 $as_echo "#define GNULIB_TEST_STPCPY 1" >>confdefs.h
28943 for ac_func in strcasecmp
28945 ac_fn_c_check_func "$LINENO" "strcasecmp" "ac_cv_func_strcasecmp"
28946 if test "x$ac_cv_func_strcasecmp" = xyes; then :
28947 cat >>confdefs.h <<_ACEOF
28948 #define HAVE_STRCASECMP 1
28954 if test $ac_cv_func_strcasecmp = no; then
28960 for ac_func in strncasecmp
28962 ac_fn_c_check_func "$LINENO" "strncasecmp" "ac_cv_func_strncasecmp"
28963 if test "x$ac_cv_func_strncasecmp" = xyes; then :
28964 cat >>confdefs.h <<_ACEOF
28965 #define HAVE_STRNCASECMP 1
28971 if test $ac_cv_func_strncasecmp = yes; then
28976 ac_fn_c_check_decl "$LINENO" "strncasecmp" "ac_cv_have_decl_strncasecmp" "$ac_includes_default"
28977 if test "x$ac_cv_have_decl_strncasecmp" = xyes; then :
28983 cat >>confdefs.h <<_ACEOF
28984 #define HAVE_DECL_STRNCASECMP $ac_have_decl
28987 if test $ac_cv_have_decl_strncasecmp = no; then
28988 HAVE_DECL_STRNCASECMP=0
28992 if test $HAVE_STRCASECMP = 0; then
29001 gl_LIBOBJS="$gl_LIBOBJS strcasecmp.$ac_objext"
29007 if test $HAVE_STRNCASECMP = 0; then
29016 gl_LIBOBJS="$gl_LIBOBJS strncasecmp.$ac_objext"
29026 for ac_func in strchrnul
29028 ac_fn_c_check_func "$LINENO" "strchrnul" "ac_cv_func_strchrnul"
29029 if test "x$ac_cv_func_strchrnul" = xyes; then :
29030 cat >>confdefs.h <<_ACEOF
29031 #define HAVE_STRCHRNUL 1
29037 if test $ac_cv_func_strchrnul = no; then
29040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strchrnul works" >&5
29041 $as_echo_n "checking whether strchrnul works... " >&6; }
29042 if ${gl_cv_func_strchrnul_works+:} false; then :
29043 $as_echo_n "(cached) " >&6
29045 if test "$cross_compiling" = yes; then :
29046 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29047 /* end confdefs.h. */
29049 #if defined __CYGWIN__
29050 #include <cygwin/version.h>
29051 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 9)
29059 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
29060 $EGREP "Lucky user" >/dev/null 2>&1; then :
29061 gl_cv_func_strchrnul_works="guessing yes"
29063 gl_cv_func_strchrnul_works="guessing no"
29069 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29070 /* end confdefs.h. */
29072 #include <string.h> /* for strchrnul */
29077 const char *buf = "a";
29078 return strchrnul (buf, 'b') != buf + 1;
29084 if ac_fn_c_try_run "$LINENO"; then :
29085 gl_cv_func_strchrnul_works=yes
29087 gl_cv_func_strchrnul_works=no
29089 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
29090 conftest.$ac_objext conftest.beam conftest.$ac_ext
29095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strchrnul_works" >&5
29096 $as_echo "$gl_cv_func_strchrnul_works" >&6; }
29097 case "$gl_cv_func_strchrnul_works" in
29099 *) REPLACE_STRCHRNUL=1 ;;
29103 if test $HAVE_STRCHRNUL = 0 || test $REPLACE_STRCHRNUL = 1; then
29112 gl_LIBOBJS="$gl_LIBOBJS strchrnul.$ac_objext"
29127 $as_echo "#define GNULIB_TEST_STRCHRNUL 1" >>confdefs.h
29135 if test $ac_cv_func_strdup = yes; then
29136 if test $gl_cv_func_malloc_posix != yes; then
29141 if test $ac_cv_have_decl_strdup = no; then
29145 if test $ac_cv_func_strdup = no || test $REPLACE_STRDUP = 1; then
29154 gl_LIBOBJS="$gl_LIBOBJS strdup.$ac_objext"
29169 $as_echo "#define GNULIB_TEST_STRDUP 1" >>confdefs.h
29178 if test "$ERRNO_H:$REPLACE_STRERROR_0" = :0; then
29179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strerror function" >&5
29180 $as_echo_n "checking for working strerror function... " >&6; }
29181 if ${gl_cv_func_working_strerror+:} false; then :
29182 $as_echo_n "(cached) " >&6
29184 if test "$cross_compiling" = yes; then :
29186 # Guess yes on glibc systems.
29187 *-gnu*) gl_cv_func_working_strerror="guessing yes" ;;
29188 # If we don't know, assume the worst.
29189 *) gl_cv_func_working_strerror="guessing no" ;;
29193 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29194 /* end confdefs.h. */
29195 #include <string.h>
29200 if (!*strerror (-2)) return 1;
29205 if ac_fn_c_try_run "$LINENO"; then :
29206 gl_cv_func_working_strerror=yes
29208 gl_cv_func_working_strerror=no
29210 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
29211 conftest.$ac_objext conftest.beam conftest.$ac_ext
29216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_strerror" >&5
29217 $as_echo "$gl_cv_func_working_strerror" >&6; }
29218 case "$gl_cv_func_working_strerror" in
29229 if test $REPLACE_STRERROR = 1; then
29238 gl_LIBOBJS="$gl_LIBOBJS strerror.$ac_objext"
29243 cat >>confdefs.h <<_ACEOF
29244 #define GNULIB_STRERROR 1
29259 $as_echo "#define GNULIB_TEST_STRERROR 1" >>confdefs.h
29265 if test -n "$ERRNO_H" || test $REPLACE_STRERROR_0 = 1; then
29274 gl_LIBOBJS="$gl_LIBOBJS strerror-override.$ac_objext"
29280 if test $ac_cv_header_sys_socket_h != yes; then
29281 for ac_header in winsock2.h
29283 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
29284 if test "x$ac_cv_header_winsock2_h" = xyes; then :
29285 cat >>confdefs.h <<_ACEOF
29286 #define HAVE_WINSOCK2_H 1
29294 if test "$ac_cv_header_winsock2_h" = yes; then
29296 UNISTD_H_HAVE_WINSOCK2_H=1
29297 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
29316 if test $ac_cv_have_decl_strndup = no; then
29317 HAVE_DECL_STRNDUP=0
29320 if test $ac_cv_func_strndup = yes; then
29322 # AIX 4.3.3, AIX 5.1 have a function that fails to add the terminating '\0'.
29323 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strndup" >&5
29324 $as_echo_n "checking for working strndup... " >&6; }
29325 if ${gl_cv_func_strndup_works+:} false; then :
29326 $as_echo_n "(cached) " >&6
29328 if test "$cross_compiling" = yes; then :
29331 aix | aix[3-6]*) gl_cv_func_strndup_works="guessing no";;
29332 *) gl_cv_func_strndup_works="guessing yes";;
29336 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29337 /* end confdefs.h. */
29339 #include <string.h>
29340 #include <stdlib.h>
29345 #if !HAVE_DECL_STRNDUP
29350 char *strndup (const char *, size_t);
29353 s = strndup ("some longer string", 15);
29355 s = strndup ("shorter string", 13);
29356 return s[13] != '\0';
29361 if ac_fn_c_try_run "$LINENO"; then :
29362 gl_cv_func_strndup_works=yes
29364 gl_cv_func_strndup_works=no
29366 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
29367 conftest.$ac_objext conftest.beam conftest.$ac_ext
29371 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strndup_works" >&5
29372 $as_echo "$gl_cv_func_strndup_works" >&6; }
29373 case $gl_cv_func_strndup_works in
29374 *no) REPLACE_STRNDUP=1 ;;
29380 if test $HAVE_STRNDUP = 0 || test $REPLACE_STRNDUP = 1; then
29389 gl_LIBOBJS="$gl_LIBOBJS strndup.$ac_objext"
29403 $as_echo "#define GNULIB_TEST_STRNDUP 1" >>confdefs.h
29413 if test $ac_cv_have_decl_strnlen = no; then
29414 HAVE_DECL_STRNLEN=0
29417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strnlen" >&5
29418 $as_echo_n "checking for working strnlen... " >&6; }
29419 if ${ac_cv_func_strnlen_working+:} false; then :
29420 $as_echo_n "(cached) " >&6
29422 if test "$cross_compiling" = yes; then :
29423 # Guess no on AIX systems, yes otherwise.
29425 aix*) ac_cv_func_strnlen_working=no;;
29426 *) ac_cv_func_strnlen_working=yes;;
29429 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29430 /* end confdefs.h. */
29431 $ac_includes_default
29437 #define S_LEN (sizeof S - 1)
29439 /* At least one implementation is buggy: that of AIX 4.3 would
29440 give strnlen (S, 1) == 3. */
29443 for (i = 0; i < S_LEN + 1; ++i)
29445 int expected = i <= S_LEN ? i : S_LEN;
29446 if (strnlen (S, i) != expected)
29455 if ac_fn_c_try_run "$LINENO"; then :
29456 ac_cv_func_strnlen_working=yes
29458 ac_cv_func_strnlen_working=no
29460 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
29461 conftest.$ac_objext conftest.beam conftest.$ac_ext
29465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strnlen_working" >&5
29466 $as_echo "$ac_cv_func_strnlen_working" >&6; }
29467 test $ac_cv_func_strnlen_working = no && :
29470 if test $ac_cv_func_strnlen_working = no; then
29475 if test $HAVE_DECL_STRNLEN = 0 || test $REPLACE_STRNLEN = 1; then
29484 gl_LIBOBJS="$gl_LIBOBJS strnlen.$ac_objext"
29499 $as_echo "#define GNULIB_TEST_STRNLEN 1" >>confdefs.h
29504 for ac_func in strtol
29506 ac_fn_c_check_func "$LINENO" "strtol" "ac_cv_func_strtol"
29507 if test "x$ac_cv_func_strtol" = xyes; then :
29508 cat >>confdefs.h <<_ACEOF
29509 #define HAVE_STRTOL 1
29516 if test $ac_cv_func_strtol = no; then
29525 gl_LIBOBJS="$gl_LIBOBJS strtol.$ac_objext"
29529 for ac_func in strtoul
29531 ac_fn_c_check_func "$LINENO" "strtoul" "ac_cv_func_strtoul"
29532 if test "x$ac_cv_func_strtoul" = xyes; then :
29533 cat >>confdefs.h <<_ACEOF
29534 #define HAVE_STRTOUL 1
29541 if test $ac_cv_func_strtoul = no; then
29550 gl_LIBOBJS="$gl_LIBOBJS strtoul.$ac_objext"
29556 if test "$ac_cv_type_unsigned_long_long_int" = yes; then
29557 for ac_func in strtoull
29559 ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
29560 if test "x$ac_cv_func_strtoull" = xyes; then :
29561 cat >>confdefs.h <<_ACEOF
29562 #define HAVE_STRTOULL 1
29568 if test $ac_cv_func_strtoull = no; then
29573 if test $HAVE_STRTOULL = 0; then
29582 gl_LIBOBJS="$gl_LIBOBJS strtoull.$ac_objext"
29599 $as_echo "#define GNULIB_TEST_STRTOULL 1" >>confdefs.h
29608 if test "$ac_cv_have_decl_strtoumax" != yes; then
29609 HAVE_DECL_STRTOUMAX=0
29612 if test $ac_cv_func_strtoumax = no; then
29621 gl_LIBOBJS="$gl_LIBOBJS strtoumax.$ac_objext"
29624 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
29625 if test "x$ac_cv_have_decl_strtoull" = xyes; then :
29631 cat >>confdefs.h <<_ACEOF
29632 #define HAVE_DECL_STRTOULL $ac_have_decl
29651 if test $ac_cv_func_symlink = no; then
29654 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
29655 $as_echo_n "checking whether symlink handles trailing slash correctly... " >&6; }
29656 if ${gl_cv_func_symlink_works+:} false; then :
29657 $as_echo_n "(cached) " >&6
29659 if test "$cross_compiling" = yes; then :
29661 # Guess yes on glibc systems.
29662 *-gnu*) gl_cv_func_symlink_works="guessing yes" ;;
29663 # If we don't know, assume the worst.
29664 *) gl_cv_func_symlink_works="guessing no" ;;
29668 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29669 /* end confdefs.h. */
29670 #include <unistd.h>
29676 if (!symlink ("a", "conftest.link/"))
29678 if (symlink ("conftest.f", "conftest.lnk2"))
29680 else if (!symlink ("a", "conftest.lnk2/"))
29688 if ac_fn_c_try_run "$LINENO"; then :
29689 gl_cv_func_symlink_works=yes
29691 gl_cv_func_symlink_works=no
29693 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
29694 conftest.$ac_objext conftest.beam conftest.$ac_ext
29697 rm -f conftest.f conftest.link conftest.lnk2
29699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
29700 $as_echo "$gl_cv_func_symlink_works" >&6; }
29701 case "$gl_cv_func_symlink_works" in
29709 if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
29718 gl_LIBOBJS="$gl_LIBOBJS symlink.$ac_objext"
29732 $as_echo "#define GNULIB_TEST_SYMLINK 1" >>confdefs.h
29741 if test $ac_cv_func_symlinkat = no; then
29745 if test $HAVE_SYMLINKAT = 0; then
29754 gl_LIBOBJS="$gl_LIBOBJS symlinkat.$ac_objext"
29768 $as_echo "#define GNULIB_TEST_SYMLINKAT 1" >>confdefs.h
29786 if test $gl_cv_have_include_next = yes; then
29787 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
29789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
29790 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
29791 if ${gl_cv_next_sys_stat_h+:} false; then :
29792 $as_echo_n "(cached) " >&6
29795 if test $ac_cv_header_sys_stat_h = yes; then
29798 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29799 /* end confdefs.h. */
29800 #include <sys/stat.h>
29804 aix*) gl_absname_cpp="$ac_cpp -C" ;;
29805 *) gl_absname_cpp="$ac_cpp" ;;
29810 gl_dirsep_regex='[/\\]'
29813 gl_dirsep_regex='\/'
29816 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
29818 gl_header_literal_regex=`echo 'sys/stat.h' \
29819 | sed -e "$gl_make_literal_regex_sed"`
29820 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
29821 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
29826 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
29827 sed -n "$gl_absolute_header_sed"`'"'
29829 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
29834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
29835 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
29837 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
29839 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
29840 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
29841 gl_next_as_first_directive='<'sys/stat.h'>'
29843 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
29844 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
29846 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
29858 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
29860 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
29864 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
29865 #include <sys/stat.h>
29867 if test "x$ac_cv_type_nlink_t" = xyes; then :
29871 $as_echo "#define nlink_t int" >>confdefs.h
29877 for gl_func in fchmodat fstat fstatat futimens lchmod lstat mkdirat mkfifo mkfifoat mknod mknodat stat utimensat; do
29878 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
29879 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
29880 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
29881 if eval \${$as_gl_Symbol+:} false; then :
29882 $as_echo_n "(cached) " >&6
29884 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29885 /* end confdefs.h. */
29886 #include <sys/stat.h>
29897 if ac_fn_c_try_compile "$LINENO"; then :
29898 eval "$as_gl_Symbol=yes"
29900 eval "$as_gl_Symbol=no"
29902 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29904 eval ac_res=\$$as_gl_Symbol
29905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
29906 $as_echo "$ac_res" >&6; }
29907 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
29908 cat >>confdefs.h <<_ACEOF
29909 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
29912 eval ac_cv_have_decl_$gl_func=yes
29926 if test $ac_cv_header_sysexits_h = yes; then
29937 if test $gl_cv_have_include_next = yes; then
29938 gl_cv_next_sysexits_h='<'sysexits.h'>'
29940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sysexits.h>" >&5
29941 $as_echo_n "checking absolute name of <sysexits.h>... " >&6; }
29942 if ${gl_cv_next_sysexits_h+:} false; then :
29943 $as_echo_n "(cached) " >&6
29946 if test $ac_cv_header_sysexits_h = yes; then
29949 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29950 /* end confdefs.h. */
29951 #include <sysexits.h>
29955 aix*) gl_absname_cpp="$ac_cpp -C" ;;
29956 *) gl_absname_cpp="$ac_cpp" ;;
29961 gl_dirsep_regex='[/\\]'
29964 gl_dirsep_regex='\/'
29967 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
29969 gl_header_literal_regex=`echo 'sysexits.h' \
29970 | sed -e "$gl_make_literal_regex_sed"`
29971 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
29972 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
29977 gl_cv_next_sysexits_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
29978 sed -n "$gl_absolute_header_sed"`'"'
29980 gl_cv_next_sysexits_h='<'sysexits.h'>'
29985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sysexits_h" >&5
29986 $as_echo "$gl_cv_next_sysexits_h" >&6; }
29988 NEXT_SYSEXITS_H=$gl_cv_next_sysexits_h
29990 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
29991 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
29992 gl_next_as_first_directive='<'sysexits.h'>'
29994 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
29995 gl_next_as_first_directive=$gl_cv_next_sysexits_h
29997 NEXT_AS_FIRST_DIRECTIVE_SYSEXITS_H=$gl_next_as_first_directive
30002 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30003 /* end confdefs.h. */
30004 #include <sysexits.h>
30016 case EX_UNAVAILABLE:
30033 if ac_fn_c_try_compile "$LINENO"; then :
30036 SYSEXITS_H=sysexits.h
30038 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30041 SYSEXITS_H=sysexits.h
30045 if test -n "$SYSEXITS_H"; then
30046 GL_GENERATE_SYSEXITS_H_TRUE=
30047 GL_GENERATE_SYSEXITS_H_FALSE='#'
30049 GL_GENERATE_SYSEXITS_H_TRUE='#'
30050 GL_GENERATE_SYSEXITS_H_FALSE=
30068 ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "#include <time.h>
30070 if test "x$ac_cv_have_decl_localtime_r" = xyes; then :
30076 cat >>confdefs.h <<_ACEOF
30077 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
30080 if test $ac_cv_have_decl_localtime_r = no; then
30081 HAVE_DECL_LOCALTIME_R=0
30085 if test $ac_cv_func_localtime_r = yes; then
30087 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
30088 $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
30089 if ${gl_cv_time_r_posix+:} false; then :
30090 $as_echo_n "(cached) " >&6
30092 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30093 /* end confdefs.h. */
30098 /* We don't need to append 'restrict's to the argument types,
30099 even though the POSIX signature has the 'restrict's,
30100 since C99 says they can't affect type compatibility. */
30101 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
30103 /* Check the return type is a pointer.
30104 On HP-UX 10 it is 'int'. */
30105 *localtime_r (0, 0);
30111 if ac_fn_c_try_compile "$LINENO"; then :
30112 gl_cv_time_r_posix=yes
30114 gl_cv_time_r_posix=no
30116 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
30120 $as_echo "$gl_cv_time_r_posix" >&6; }
30121 if test $gl_cv_time_r_posix = yes; then
30122 REPLACE_LOCALTIME_R=0
30124 REPLACE_LOCALTIME_R=1
30130 if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
30139 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
30156 $as_echo "#define GNULIB_TEST_TIME_R 1" >>confdefs.h
30173 if test $gl_cv_have_include_next = yes; then
30174 gl_cv_next_unistd_h='<'unistd.h'>'
30176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
30177 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
30178 if ${gl_cv_next_unistd_h+:} false; then :
30179 $as_echo_n "(cached) " >&6
30182 if test $ac_cv_header_unistd_h = yes; then
30185 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30186 /* end confdefs.h. */
30187 #include <unistd.h>
30191 aix*) gl_absname_cpp="$ac_cpp -C" ;;
30192 *) gl_absname_cpp="$ac_cpp" ;;
30197 gl_dirsep_regex='[/\\]'
30200 gl_dirsep_regex='\/'
30203 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
30205 gl_header_literal_regex=`echo 'unistd.h' \
30206 | sed -e "$gl_make_literal_regex_sed"`
30207 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
30208 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
30213 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
30214 sed -n "$gl_absolute_header_sed"`'"'
30216 gl_cv_next_unistd_h='<'unistd.h'>'
30221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
30222 $as_echo "$gl_cv_next_unistd_h" >&6; }
30224 NEXT_UNISTD_H=$gl_cv_next_unistd_h
30226 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
30227 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
30228 gl_next_as_first_directive='<'unistd.h'>'
30230 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
30231 gl_next_as_first_directive=$gl_cv_next_unistd_h
30233 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
30238 if test $ac_cv_header_unistd_h = yes; then
30250 for gl_func in chdir chown dup dup2 dup3 environ euidaccess faccessat fchdir fchownat fdatasync fsync ftruncate getcwd getdomainname getdtablesize getgroups gethostname getlogin getlogin_r getpagesize getusershell setusershell endusershell group_member isatty lchown link linkat lseek pipe pipe2 pread pwrite readlink readlinkat rmdir sethostname sleep symlink symlinkat ttyname_r unlink unlinkat usleep; do
30251 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
30252 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
30253 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
30254 if eval \${$as_gl_Symbol+:} false; then :
30255 $as_echo_n "(cached) " >&6
30257 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30258 /* end confdefs.h. */
30261 # include <unistd.h>
30263 /* Some systems declare various items in the wrong headers. */
30264 #if !(defined __GLIBC__ && !defined __UCLIBC__)
30265 # include <fcntl.h>
30266 # include <stdio.h>
30267 # include <stdlib.h>
30268 # if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
30282 if ac_fn_c_try_compile "$LINENO"; then :
30283 eval "$as_gl_Symbol=yes"
30285 eval "$as_gl_Symbol=no"
30287 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30289 eval ac_res=\$$as_gl_Symbol
30290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
30291 $as_echo "$ac_res" >&6; }
30292 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
30293 cat >>confdefs.h <<_ACEOF
30294 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
30297 eval ac_cv_have_decl_$gl_func=yes
30307 if { test "$HAVE_LIBUNISTRING" != yes \
30312 test $LIBUNISTRING_VERSION_MAJOR -lt 0 \
30313 || { test $LIBUNISTRING_VERSION_MAJOR -eq 0 \
30314 && { test $LIBUNISTRING_VERSION_MINOR -lt 9 \
30315 || { test $LIBUNISTRING_VERSION_MINOR -eq 9 \
30316 && test $LIBUNISTRING_VERSION_SUBMINOR -lt 0
30326 LIBUNISTRING_UNITYPES_H='unitypes.h'
30328 LIBUNISTRING_UNITYPES_H=
30334 if { test "$HAVE_LIBUNISTRING" != yes \
30339 test $LIBUNISTRING_VERSION_MAJOR -lt 0 \
30340 || { test $LIBUNISTRING_VERSION_MAJOR -eq 0 \
30341 && { test $LIBUNISTRING_VERSION_MINOR -lt 9 \
30342 || { test $LIBUNISTRING_VERSION_MINOR -eq 9 \
30343 && test $LIBUNISTRING_VERSION_SUBMINOR -lt 0
30353 LIBUNISTRING_UNIWIDTH_H='uniwidth.h'
30355 LIBUNISTRING_UNIWIDTH_H=
30361 if { test "$HAVE_LIBUNISTRING" != yes \
30366 test $LIBUNISTRING_VERSION_MAJOR -lt 0 \
30367 || { test $LIBUNISTRING_VERSION_MAJOR -eq 0 \
30368 && { test $LIBUNISTRING_VERSION_MINOR -lt 9 \
30369 || { test $LIBUNISTRING_VERSION_MINOR -eq 9 \
30370 && test $LIBUNISTRING_VERSION_SUBMINOR -lt 4
30380 LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_TRUE=
30381 LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_FALSE='#'
30383 LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_TRUE='#'
30384 LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_FALSE=
30393 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether unlink honors trailing slashes" >&5
30394 $as_echo_n "checking whether unlink honors trailing slashes... " >&6; }
30395 if ${gl_cv_func_unlink_honors_slashes+:} false; then :
30396 $as_echo_n "(cached) " >&6
30398 touch conftest.file
30399 # Assume that if we have lstat, we can also check symlinks.
30400 if test $ac_cv_func_lstat = yes; then
30401 ln -s conftest.file conftest.lnk
30403 if test "$cross_compiling" = yes; then :
30405 # Guess yes on glibc systems.
30406 *-gnu*) gl_cv_func_unlink_honors_slashes="guessing yes" ;;
30407 # If we don't know, assume the worst.
30408 *) gl_cv_func_unlink_honors_slashes="guessing no" ;;
30412 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30413 /* end confdefs.h. */
30415 # include <unistd.h>
30416 #else /* on Windows with MSVC */
30425 if (!unlink ("conftest.file/"))
30427 else if (errno != ENOTDIR)
30430 if (!unlink ("conftest.lnk/"))
30432 else if (errno != ENOTDIR)
30441 if ac_fn_c_try_run "$LINENO"; then :
30442 gl_cv_func_unlink_honors_slashes=yes
30444 gl_cv_func_unlink_honors_slashes=no
30446 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
30447 conftest.$ac_objext conftest.beam conftest.$ac_ext
30450 rm -f conftest.file conftest.lnk
30452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_unlink_honors_slashes" >&5
30453 $as_echo "$gl_cv_func_unlink_honors_slashes" >&6; }
30454 case "$gl_cv_func_unlink_honors_slashes" in
30460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether unlink of a parent directory fails as it should" >&5
30461 $as_echo_n "checking whether unlink of a parent directory fails as it should... " >&6; }
30462 if ${gl_cv_func_unlink_parent_fails+:} false; then :
30463 $as_echo_n "(cached) " >&6
30468 # Use the mktemp program if available. If not available, hide the error
30470 tmp=`(umask 077 && mktemp -d /tmp/gtXXXXXX) 2>/dev/null` &&
30471 test -n "$tmp" && test -d "$tmp"
30474 # Use a simple mkdir command. It is guaranteed to fail if the directory
30475 # already exists. $RANDOM is bash specific and expands to empty in shells
30476 # other than bash, ksh and zsh. Its use does not increase security;
30477 # rather, it minimizes the probability of failure in a very cluttered /tmp
30479 tmp=/tmp/gt$$-$RANDOM
30480 (umask 077 && mkdir "$tmp")
30482 mkdir "$tmp/subdir"
30483 GL_SUBDIR_FOR_UNLINK="$tmp/subdir"
30484 export GL_SUBDIR_FOR_UNLINK
30485 if test "$cross_compiling" = yes; then :
30486 # If we don't know, assume the worst.
30487 gl_cv_func_unlink_parent_fails="guessing no"
30490 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30491 /* end confdefs.h. */
30493 #include <stdlib.h>
30495 # include <unistd.h>
30496 #else /* on Windows with MSVC */
30497 # include <direct.h>
30503 if (chdir (getenv ("GL_SUBDIR_FOR_UNLINK")) != 0)
30505 else if (unlink ("..") == 0)
30511 if ac_fn_c_try_run "$LINENO"; then :
30512 gl_cv_func_unlink_parent_fails=yes
30514 gl_cv_func_unlink_parent_fails=no
30516 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
30517 conftest.$ac_objext conftest.beam conftest.$ac_ext
30520 unset GL_SUBDIR_FOR_UNLINK
30523 gl_cv_func_unlink_parent_fails="guessing no"
30527 gl_cv_func_unlink_parent_fails="guessing yes"
30532 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_unlink_parent_fails" >&5
30533 $as_echo "$gl_cv_func_unlink_parent_fails" >&6; }
30534 case "$gl_cv_func_unlink_parent_fails" in
30538 $as_echo "#define UNLINK_PARENT_BUG 1" >>confdefs.h
30543 if test $REPLACE_UNLINK = 1; then
30552 gl_LIBOBJS="$gl_LIBOBJS unlink.$ac_objext"
30566 $as_echo "#define GNULIB_TEST_UNLINK 1" >>confdefs.h
30576 if test $ac_cv_func_unlinkat = no; then
30579 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
30581 # Solaris 9 has *at functions, but uniformly mishandles trailing
30582 # slash in all of them.
30586 # GNU/Hurd has unlinkat, but it has the same bug as unlink.
30587 if test $REPLACE_UNLINK = 1; then
30594 if test $HAVE_UNLINKAT = 0 || test $REPLACE_UNLINKAT = 1; then
30603 gl_LIBOBJS="$gl_LIBOBJS unlinkat.$ac_objext"
30617 $as_echo "#define GNULIB_TEST_UNLINKAT 1" >>confdefs.h
30625 # The Hurd, the Linux kernel, the FreeBSD kernel version 2.2 and later,
30626 # Cygwin, and mingw never let anyone (even root) unlink directories.
30627 # If anyone knows of another system for which unlink can never
30628 # remove a directory, please report it to <bug-coreutils@gnu.org>.
30629 # Unfortunately this is difficult to test for, since it requires root access
30630 # and might create garbage in the file system,
30631 # so the code below simply relies on the kernel name and version number.
30634 linux-* | linux | \
30635 freebsd2.2* | freebsd[3-9]* | freebsd[1-9][0-9]* | \
30639 $as_echo "#define UNLINK_CANNOT_UNLINK_DIR 1" >>confdefs.h
30645 $as_echo "#define USE_UNLOCKED_IO 1" >>confdefs.h
30667 if test $ac_cv_have_decl_unsetenv = no; then
30668 HAVE_DECL_UNSETENV=0
30670 for ac_func in unsetenv
30672 ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv"
30673 if test "x$ac_cv_func_unsetenv" = xyes; then :
30674 cat >>confdefs.h <<_ACEOF
30675 #define HAVE_UNSETENV 1
30681 if test $ac_cv_func_unsetenv = no; then
30685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsetenv() return type" >&5
30686 $as_echo_n "checking for unsetenv() return type... " >&6; }
30687 if ${gt_cv_func_unsetenv_ret+:} false; then :
30688 $as_echo_n "(cached) " >&6
30690 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30691 /* end confdefs.h. */
30694 #define _BSD 1 /* unhide unsetenv declaration in OSF/1 5.1 <stdlib.h> */
30695 #include <stdlib.h>
30700 int unsetenv (const char *name);
30710 if ac_fn_c_try_compile "$LINENO"; then :
30711 gt_cv_func_unsetenv_ret='int'
30713 gt_cv_func_unsetenv_ret='void'
30715 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_unsetenv_ret" >&5
30718 $as_echo "$gt_cv_func_unsetenv_ret" >&6; }
30719 if test $gt_cv_func_unsetenv_ret = 'void'; then
30721 $as_echo "#define VOID_UNSETENV 1" >>confdefs.h
30726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether unsetenv obeys POSIX" >&5
30727 $as_echo_n "checking whether unsetenv obeys POSIX... " >&6; }
30728 if ${gl_cv_func_unsetenv_works+:} false; then :
30729 $as_echo_n "(cached) " >&6
30731 if test "$cross_compiling" = yes; then :
30733 # Guess yes on glibc systems.
30734 *-gnu*) gl_cv_func_unsetenv_works="guessing yes" ;;
30735 # If we don't know, assume the worst.
30736 *) gl_cv_func_unsetenv_works="guessing no" ;;
30740 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30741 /* end confdefs.h. */
30743 #include <stdlib.h>
30745 extern char **environ;
30751 char entry1[] = "a=1";
30752 char entry2[] = "b=2";
30753 char *env[] = { entry1, entry2, NULL };
30754 if (putenv ((char *) "a=1")) return 1;
30755 if (putenv (entry2)) return 2;
30758 if (getenv ("a")) return 3;
30759 if (!unsetenv ("") || errno != EINVAL) return 4;
30762 if (!getenv ("a")) return 5;
30765 if (getenv ("a")) return 6;
30771 if ac_fn_c_try_run "$LINENO"; then :
30772 gl_cv_func_unsetenv_works=yes
30774 gl_cv_func_unsetenv_works=no
30776 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
30777 conftest.$ac_objext conftest.beam conftest.$ac_ext
30781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_unsetenv_works" >&5
30782 $as_echo "$gl_cv_func_unsetenv_works" >&6; }
30783 case "$gl_cv_func_unsetenv_works" in
30791 if test $HAVE_UNSETENV = 0 || test $REPLACE_UNSETENV = 1; then
30800 gl_LIBOBJS="$gl_LIBOBJS unsetenv.$ac_objext"
30818 $as_echo "#define GNULIB_TEST_UNSETENV 1" >>confdefs.h
30828 if test $ac_cv_func_futimens = no && test $ac_cv_func_futimesat = yes; then
30829 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether futimesat handles NULL file" >&5
30830 $as_echo_n "checking whether futimesat handles NULL file... " >&6; }
30831 if ${gl_cv_func_futimesat_works+:} false; then :
30832 $as_echo_n "(cached) " >&6
30834 touch conftest.file
30835 if test "$cross_compiling" = yes; then :
30837 # Guess yes on glibc systems.
30838 *-gnu*) gl_cv_func_futimesat_works="guessing yes" ;;
30839 # If we don't know, assume the worst.
30840 *) gl_cv_func_futimesat_works="guessing no" ;;
30844 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30845 /* end confdefs.h. */
30847 #include <stddef.h>
30848 #include <sys/times.h>
30854 int fd = open ("conftest.file", O_RDWR);
30855 if (fd < 0) return 1;
30856 if (futimesat (fd, NULL, NULL)) return 2;
30862 if ac_fn_c_try_run "$LINENO"; then :
30863 gl_cv_func_futimesat_works=yes
30865 gl_cv_func_futimesat_works=no
30867 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
30868 conftest.$ac_objext conftest.beam conftest.$ac_ext
30871 rm -f conftest.file
30873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_futimesat_works" >&5
30874 $as_echo "$gl_cv_func_futimesat_works" >&6; }
30875 case "$gl_cv_func_futimesat_works" in
30879 $as_echo "#define FUTIMESAT_NULL_BUG 1" >>confdefs.h
30889 if test $ac_cv_func_utimensat = no; then
30892 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether utimensat works" >&5
30893 $as_echo_n "checking whether utimensat works... " >&6; }
30894 if ${gl_cv_func_utimensat_works+:} false; then :
30895 $as_echo_n "(cached) " >&6
30897 if test "$cross_compiling" = yes; then :
30898 gl_cv_func_utimensat_works="guessing no"
30900 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30901 /* end confdefs.h. */
30904 #include <sys/stat.h>
30905 #include <unistd.h>
30911 const char *f = "conftest.file";
30912 if (close (creat (f, 0600)))
30914 /* Test whether the AT_SYMLINK_NOFOLLOW flag is supported. */
30916 if (utimensat (AT_FDCWD, f, NULL, AT_SYMLINK_NOFOLLOW))
30919 /* Test whether UTIME_NOW and UTIME_OMIT work. */
30921 struct timespec ts[2] = { { 1, UTIME_OMIT }, { 1, UTIME_NOW } };
30922 if (utimensat (AT_FDCWD, f, ts, 0))
30927 struct timespec ts[2] = { { 1, UTIME_NOW }, { 1, UTIME_OMIT } };
30929 if (utimensat (AT_FDCWD, f, ts, 0))
30933 else if (st.st_ctime < st.st_atime)
30942 if ac_fn_c_try_run "$LINENO"; then :
30943 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30944 /* end confdefs.h. */
30947 /* The Linux kernel added utimensat in 2.6.22, but has bugs with UTIME_OMIT
30948 in several file systems as recently as 2.6.32. Always replace utimensat
30949 to support older kernels. */
30961 if ac_fn_c_try_compile "$LINENO"; then :
30962 gl_cv_func_utimensat_works=yes
30964 gl_cv_func_utimensat_works="needs runtime check"
30966 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30968 gl_cv_func_utimensat_works=no
30970 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
30971 conftest.$ac_objext conftest.beam conftest.$ac_ext
30975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_utimensat_works" >&5
30976 $as_echo "$gl_cv_func_utimensat_works" >&6; }
30977 if test "$gl_cv_func_utimensat_works" != yes; then
30978 REPLACE_UTIMENSAT=1
30982 if test $HAVE_UTIMENSAT = 0 || test $REPLACE_UTIMENSAT = 1; then
30991 gl_LIBOBJS="$gl_LIBOBJS utimensat.$ac_objext"
31005 $as_echo "#define GNULIB_TEST_UTIMENSAT 1" >>confdefs.h
31011 if test $ac_cv_func_vasnprintf = no; then
31022 gl_LIBOBJS="$gl_LIBOBJS vasnprintf.$ac_objext"
31032 gl_LIBOBJS="$gl_LIBOBJS printf-args.$ac_objext"
31042 gl_LIBOBJS="$gl_LIBOBJS printf-parse.$ac_objext"
31052 gl_LIBOBJS="$gl_LIBOBJS asnprintf.$ac_objext"
31054 if test $ac_cv_func_vasnprintf = yes; then
31056 $as_echo "#define REPLACE_VASNPRINTF 1" >>confdefs.h
31070 ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
31071 if test "x$ac_cv_type_ptrdiff_t" = xyes; then :
31075 $as_echo "#define ptrdiff_t long" >>confdefs.h
31089 for ac_func in vasprintf
31091 ac_fn_c_check_func "$LINENO" "vasprintf" "ac_cv_func_vasprintf"
31092 if test "x$ac_cv_func_vasprintf" = xyes; then :
31093 cat >>confdefs.h <<_ACEOF
31094 #define HAVE_VASPRINTF 1
31100 if test $ac_cv_func_vasprintf = no; then
31110 gl_LIBOBJS="$gl_LIBOBJS vasprintf.$ac_objext"
31120 gl_LIBOBJS="$gl_LIBOBJS asprintf.$ac_objext"
31123 if test $ac_cv_func_vasprintf = yes; then
31124 REPLACE_VASPRINTF=1
31149 $as_echo "#define GNULIB_TEST_VASPRINTF 1" >>confdefs.h
31155 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=asprintf:2:c-format"
31159 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=vasprintf:2:c-format"
31162 # Check whether --with-packager was given.
31163 if test "${with_packager+set}" = set; then :
31164 withval=$with_packager; case $withval in
31167 cat >>confdefs.h <<_ACEOF
31168 #define PACKAGE_PACKAGER "$withval"
31177 # Check whether --with-packager-version was given.
31178 if test "${with_packager_version+set}" = set; then :
31179 withval=$with_packager_version; case $withval in
31182 cat >>confdefs.h <<_ACEOF
31183 #define PACKAGE_PACKAGER_VERSION "$withval"
31192 # Check whether --with-packager-bug-reports was given.
31193 if test "${with_packager_bug_reports+set}" = set; then :
31194 withval=$with_packager_bug_reports; case $withval in
31197 cat >>confdefs.h <<_ACEOF
31198 #define PACKAGE_PACKAGER_BUG_REPORTS "$withval"
31206 if test "X$with_packager" = "X" && \
31207 test "X$with_packager_version$with_packager_bug_reports" != "X"
31209 as_fn_error $? "The --with-packager-{bug-reports,version} options require --with-packager" "$LINENO" 5
31214 gl_cv_func_vsnprintf_usable=no
31215 for ac_func in vsnprintf
31217 ac_fn_c_check_func "$LINENO" "vsnprintf" "ac_cv_func_vsnprintf"
31218 if test "x$ac_cv_func_vsnprintf" = xyes; then :
31219 cat >>confdefs.h <<_ACEOF
31220 #define HAVE_VSNPRINTF 1
31226 if test $ac_cv_func_vsnprintf = yes; then
31230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf respects a size of 1" >&5
31231 $as_echo_n "checking whether snprintf respects a size of 1... " >&6; }
31232 if ${gl_cv_func_snprintf_size1+:} false; then :
31233 $as_echo_n "(cached) " >&6
31236 if test "$cross_compiling" = yes; then :
31237 gl_cv_func_snprintf_size1="guessing yes"
31239 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31240 /* end confdefs.h. */
31244 # define my_snprintf snprintf
31246 # include <stdarg.h>
31247 static int my_snprintf (char *buf, int size, const char *format, ...)
31251 va_start (args, format);
31252 ret = vsnprintf (buf, size, format, args);
31259 static char buf[8] = { 'D', 'E', 'A', 'D', 'B', 'E', 'E', 'F' };
31260 my_snprintf (buf, 1, "%d", 12345);
31261 return buf[1] != 'E';
31264 if ac_fn_c_try_run "$LINENO"; then :
31265 gl_cv_func_snprintf_size1=yes
31267 gl_cv_func_snprintf_size1=no
31269 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
31270 conftest.$ac_objext conftest.beam conftest.$ac_ext
31275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_snprintf_size1" >&5
31276 $as_echo "$gl_cv_func_snprintf_size1" >&6; }
31278 case "$gl_cv_func_snprintf_size1" in
31281 case "$gl_cv_func_snprintf_retval_c99" in
31285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether printf supports POSIX/XSI format strings with positions" >&5
31286 $as_echo_n "checking whether printf supports POSIX/XSI format strings with positions... " >&6; }
31287 if ${gl_cv_func_printf_positions+:} false; then :
31288 $as_echo_n "(cached) " >&6
31291 if test "$cross_compiling" = yes; then :
31294 netbsd[1-3]* | netbsdelf[1-3]* | netbsdaout[1-3]* | netbsdcoff[1-3]*)
31295 gl_cv_func_printf_positions="guessing no";;
31296 beos*) gl_cv_func_printf_positions="guessing no";;
31297 mingw* | pw*) gl_cv_func_printf_positions="guessing no";;
31298 *) gl_cv_func_printf_positions="guessing yes";;
31302 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31303 /* end confdefs.h. */
31306 #include <string.h>
31307 /* The string "%2$d %1$d", with dollar characters protected from the shell's
31308 dollar expansion (possibly an autoconf bug). */
31309 static char format[] = { '%', '2', '$', 'd', ' ', '%', '1', '$', 'd', '\0' };
31310 static char buf[100];
31313 sprintf (buf, format, 33, 55);
31314 return (strcmp (buf, "55 33") != 0);
31317 if ac_fn_c_try_run "$LINENO"; then :
31318 gl_cv_func_printf_positions=yes
31320 gl_cv_func_printf_positions=no
31322 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
31323 conftest.$ac_objext conftest.beam conftest.$ac_ext
31328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_positions" >&5
31329 $as_echo "$gl_cv_func_printf_positions" >&6; }
31331 case "$gl_cv_func_printf_positions" in
31333 gl_cv_func_vsnprintf_usable=yes
31341 if test $gl_cv_func_vsnprintf_usable = no; then
31352 gl_LIBOBJS="$gl_LIBOBJS vsnprintf.$ac_objext"
31354 if test $ac_cv_func_vsnprintf = yes; then
31355 REPLACE_VSNPRINTF=1
31361 if test $ac_cv_have_decl_vsnprintf = no; then
31362 HAVE_DECL_VSNPRINTF=0
31376 $as_echo "#define GNULIB_TEST_VSNPRINTF 1" >>confdefs.h
31392 if test $gl_cv_have_include_next = yes; then
31393 gl_cv_next_wchar_h='<'wchar.h'>'
31395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <wchar.h>" >&5
31396 $as_echo_n "checking absolute name of <wchar.h>... " >&6; }
31397 if ${gl_cv_next_wchar_h+:} false; then :
31398 $as_echo_n "(cached) " >&6
31401 if test $ac_cv_header_wchar_h = yes; then
31404 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31405 /* end confdefs.h. */
31410 aix*) gl_absname_cpp="$ac_cpp -C" ;;
31411 *) gl_absname_cpp="$ac_cpp" ;;
31416 gl_dirsep_regex='[/\\]'
31419 gl_dirsep_regex='\/'
31422 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
31424 gl_header_literal_regex=`echo 'wchar.h' \
31425 | sed -e "$gl_make_literal_regex_sed"`
31426 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
31427 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
31432 gl_cv_next_wchar_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
31433 sed -n "$gl_absolute_header_sed"`'"'
31435 gl_cv_next_wchar_h='<'wchar.h'>'
31440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wchar_h" >&5
31441 $as_echo "$gl_cv_next_wchar_h" >&6; }
31443 NEXT_WCHAR_H=$gl_cv_next_wchar_h
31445 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
31446 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
31447 gl_next_as_first_directive='<'wchar.h'>'
31449 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
31450 gl_next_as_first_directive=$gl_cv_next_wchar_h
31452 NEXT_AS_FIRST_DIRECTIVE_WCHAR_H=$gl_next_as_first_directive
31457 if test $ac_cv_header_wchar_h = yes; then
31467 if test $gt_cv_c_wint_t = yes; then
31475 for gl_func in btowc wctob mbsinit mbrtowc mbrlen mbsrtowcs mbsnrtowcs wcrtomb wcsrtombs wcsnrtombs wcwidth wmemchr wmemcmp wmemcpy wmemmove wmemset wcslen wcsnlen wcscpy wcpcpy wcsncpy wcpncpy wcscat wcsncat wcscmp wcsncmp wcscasecmp wcsncasecmp wcscoll wcsxfrm wcsdup wcschr wcsrchr wcscspn wcsspn wcspbrk wcsstr wcstok wcswidth ; do
31476 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
31477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
31478 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
31479 if eval \${$as_gl_Symbol+:} false; then :
31480 $as_echo_n "(cached) " >&6
31482 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31483 /* end confdefs.h. */
31485 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
31487 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
31488 included before <wchar.h>. */
31489 #if !(defined __GLIBC__ && !defined __UCLIBC__)
31490 # include <stddef.h>
31491 # include <stdio.h>
31505 if ac_fn_c_try_compile "$LINENO"; then :
31506 eval "$as_gl_Symbol=yes"
31508 eval "$as_gl_Symbol=no"
31510 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31512 eval ac_res=\$$as_gl_Symbol
31513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
31514 $as_echo "$ac_res" >&6; }
31515 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
31516 cat >>confdefs.h <<_ACEOF
31517 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
31520 eval ac_cv_have_decl_$gl_func=yes
31535 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
31539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
31540 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
31541 if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then :
31542 $as_echo_n "(cached) " >&6
31546 # Guess no on AIX and OSF/1.
31547 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
31548 # Guess yes otherwise.
31549 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
31551 if test $LOCALE_JA != none; then
31552 if test "$cross_compiling" = yes; then :
31555 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31556 /* end confdefs.h. */
31558 #include <locale.h>
31559 #include <string.h>
31560 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
31562 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
31563 included before <wchar.h>. */
31564 #include <stddef.h>
31570 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
31572 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
31576 memset (&state, '\0', sizeof (mbstate_t));
31577 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
31578 if (mbsinit (&state))
31584 if ac_fn_c_try_run "$LINENO"; then :
31585 gl_cv_func_mbrtowc_incomplete_state=yes
31587 gl_cv_func_mbrtowc_incomplete_state=no
31589 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
31590 conftest.$ac_objext conftest.beam conftest.$ac_ext
31596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
31597 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
31602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
31603 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
31604 if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then :
31605 $as_echo_n "(cached) " >&6
31609 # Guess no on Solaris 8.
31610 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
31611 # Guess yes otherwise.
31612 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
31614 if test $LOCALE_ZH_CN != none; then
31615 if test "$cross_compiling" = yes; then :
31618 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31619 /* end confdefs.h. */
31621 #include <locale.h>
31622 #include <stdlib.h>
31623 #include <string.h>
31624 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
31626 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
31627 included before <wchar.h>. */
31628 #include <stddef.h>
31634 /* This fails on Solaris 8:
31635 mbrtowc returns 2, and sets wc to 0x00F0.
31636 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
31637 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
31639 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
31643 memset (&state, '\0', sizeof (mbstate_t));
31644 if (mbrtowc (&wc, input + 3, 6, &state) != 4
31645 && mbtowc (&wc, input + 3, 6) == 4)
31651 if ac_fn_c_try_run "$LINENO"; then :
31652 gl_cv_func_mbrtowc_sanitycheck=yes
31654 gl_cv_func_mbrtowc_sanitycheck=no
31656 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
31657 conftest.$ac_objext conftest.beam conftest.$ac_ext
31663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
31664 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
31666 REPLACE_MBSTATE_T=0
31667 case "$gl_cv_func_mbrtowc_incomplete_state" in
31669 *) REPLACE_MBSTATE_T=1 ;;
31671 case "$gl_cv_func_mbrtowc_sanitycheck" in
31673 *) REPLACE_MBSTATE_T=1 ;;
31676 REPLACE_MBSTATE_T=1
31681 if test $ac_cv_func_wcrtomb = no; then
31683 ac_fn_c_check_decl "$LINENO" "wcrtomb" "ac_cv_have_decl_wcrtomb" "
31684 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
31686 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
31687 included before <wchar.h>. */
31688 #include <stddef.h>
31694 if test "x$ac_cv_have_decl_wcrtomb" = xyes; then :
31700 cat >>confdefs.h <<_ACEOF
31701 #define HAVE_DECL_WCRTOMB $ac_have_decl
31704 if test $ac_cv_have_decl_wcrtomb = yes; then
31708 if test $REPLACE_MBSTATE_T = 1; then
31716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether wcrtomb return value is correct" >&5
31717 $as_echo_n "checking whether wcrtomb return value is correct... " >&6; }
31718 if ${gl_cv_func_wcrtomb_retval+:} false; then :
31719 $as_echo_n "(cached) " >&6
31723 # Guess no on AIX 4, OSF/1 and Solaris.
31724 aix4* | osf* | solaris*) gl_cv_func_wcrtomb_retval="guessing no" ;;
31725 # Guess yes otherwise.
31726 *) gl_cv_func_wcrtomb_retval="guessing yes" ;;
31728 if test $LOCALE_FR != none || test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none || test $LOCALE_ZH_CN != none; then
31729 if test "$cross_compiling" = yes; then :
31732 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31733 /* end confdefs.h. */
31735 #include <locale.h>
31736 #include <string.h>
31737 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
31739 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
31740 included before <wchar.h>. */
31741 #include <stddef.h>
31748 if (setlocale (LC_ALL, "$LOCALE_FR") != NULL)
31750 if (wcrtomb (NULL, 0, NULL) != 1)
31753 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
31755 if (wcrtomb (NULL, 0, NULL) != 1)
31758 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
31760 if (wcrtomb (NULL, 0, NULL) != 1)
31763 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
31765 if (wcrtomb (NULL, 0, NULL) != 1)
31771 if ac_fn_c_try_run "$LINENO"; then :
31772 gl_cv_func_wcrtomb_retval=yes
31774 gl_cv_func_wcrtomb_retval=no
31776 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
31777 conftest.$ac_objext conftest.beam conftest.$ac_ext
31783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_wcrtomb_retval" >&5
31784 $as_echo "$gl_cv_func_wcrtomb_retval" >&6; }
31785 case "$gl_cv_func_wcrtomb_retval" in
31787 *) REPLACE_WCRTOMB=1 ;;
31792 if test $HAVE_WCRTOMB = 0 || test $REPLACE_WCRTOMB = 1; then
31801 gl_LIBOBJS="$gl_LIBOBJS wcrtomb.$ac_objext"
31818 $as_echo "#define GNULIB_TEST_WCRTOMB 1" >>confdefs.h
31827 if test $ac_cv_func_iswcntrl = yes; then
31835 if test $gt_cv_c_wint_t = yes; then
31851 if test $gl_cv_have_include_next = yes; then
31852 gl_cv_next_wctype_h='<'wctype.h'>'
31854 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <wctype.h>" >&5
31855 $as_echo_n "checking absolute name of <wctype.h>... " >&6; }
31856 if ${gl_cv_next_wctype_h+:} false; then :
31857 $as_echo_n "(cached) " >&6
31860 if test $ac_cv_header_wctype_h = yes; then
31863 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31864 /* end confdefs.h. */
31865 #include <wctype.h>
31869 aix*) gl_absname_cpp="$ac_cpp -C" ;;
31870 *) gl_absname_cpp="$ac_cpp" ;;
31875 gl_dirsep_regex='[/\\]'
31878 gl_dirsep_regex='\/'
31881 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
31883 gl_header_literal_regex=`echo 'wctype.h' \
31884 | sed -e "$gl_make_literal_regex_sed"`
31885 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
31886 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
31891 gl_cv_next_wctype_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
31892 sed -n "$gl_absolute_header_sed"`'"'
31894 gl_cv_next_wctype_h='<'wctype.h'>'
31899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wctype_h" >&5
31900 $as_echo "$gl_cv_next_wctype_h" >&6; }
31902 NEXT_WCTYPE_H=$gl_cv_next_wctype_h
31904 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
31905 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
31906 gl_next_as_first_directive='<'wctype.h'>'
31908 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
31909 gl_next_as_first_directive=$gl_cv_next_wctype_h
31911 NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H=$gl_next_as_first_directive
31916 if test $ac_cv_header_wctype_h = yes; then
31917 if test $ac_cv_func_iswcntrl = yes; then
31918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether iswcntrl works" >&5
31919 $as_echo_n "checking whether iswcntrl works... " >&6; }
31920 if ${gl_cv_func_iswcntrl_works+:} false; then :
31921 $as_echo_n "(cached) " >&6
31924 if test "$cross_compiling" = yes; then :
31925 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31926 /* end confdefs.h. */
31927 #include <stdlib.h>
31928 #if __GNU_LIBRARY__ == 1
31929 Linux libc5 i18n is broken.
31939 if ac_fn_c_try_compile "$LINENO"; then :
31940 gl_cv_func_iswcntrl_works="guessing yes"
31942 gl_cv_func_iswcntrl_works="guessing no"
31944 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31947 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31948 /* end confdefs.h. */
31950 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
31951 included before <wchar.h>.
31952 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
31953 must be included before <wchar.h>. */
31954 #include <stddef.h>
31958 #include <wctype.h>
31959 int main () { return iswprint ('x') == 0; }
31962 if ac_fn_c_try_run "$LINENO"; then :
31963 gl_cv_func_iswcntrl_works=yes
31965 gl_cv_func_iswcntrl_works=no
31967 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
31968 conftest.$ac_objext conftest.beam conftest.$ac_ext
31973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_iswcntrl_works" >&5
31974 $as_echo "$gl_cv_func_iswcntrl_works" >&6; }
31982 case "$gl_cv_func_iswcntrl_works" in
31983 *yes) REPLACE_ISWCNTRL=0 ;;
31984 *) REPLACE_ISWCNTRL=1 ;;
31988 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_ISWCNTRL = 1; then
31992 if test $REPLACE_ISWCNTRL = 1; then
31995 for ac_func in towlower
31997 ac_fn_c_check_func "$LINENO" "towlower" "ac_cv_func_towlower"
31998 if test "x$ac_cv_func_towlower" = xyes; then :
31999 cat >>confdefs.h <<_ACEOF
32000 #define HAVE_TOWLOWER 1
32006 if test $ac_cv_func_towlower = yes; then
32009 ac_fn_c_check_decl "$LINENO" "towlower" "ac_cv_have_decl_towlower" "/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
32010 included before <wchar.h>.
32011 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
32012 must be included before <wchar.h>. */
32013 #include <stddef.h>
32018 # include <wctype.h>
32022 if test "x$ac_cv_have_decl_towlower" = xyes; then :
32028 cat >>confdefs.h <<_ACEOF
32029 #define HAVE_DECL_TOWLOWER $ac_have_decl
32032 if test $ac_cv_have_decl_towlower = yes; then
32041 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_TOWLOWER = 1; then
32045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctype_t" >&5
32046 $as_echo_n "checking for wctype_t... " >&6; }
32047 if ${gl_cv_type_wctype_t+:} false; then :
32048 $as_echo_n "(cached) " >&6
32050 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32051 /* end confdefs.h. */
32052 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
32053 included before <wchar.h>.
32054 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
32055 must be included before <wchar.h>. */
32056 #include <stddef.h>
32061 # include <wctype.h>
32073 if ac_fn_c_try_compile "$LINENO"; then :
32074 gl_cv_type_wctype_t=yes
32076 gl_cv_type_wctype_t=no
32078 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctype_t" >&5
32082 $as_echo "$gl_cv_type_wctype_t" >&6; }
32083 if test $gl_cv_type_wctype_t = no; then
32087 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctrans_t" >&5
32088 $as_echo_n "checking for wctrans_t... " >&6; }
32089 if ${gl_cv_type_wctrans_t+:} false; then :
32090 $as_echo_n "(cached) " >&6
32092 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32093 /* end confdefs.h. */
32094 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
32095 included before <wchar.h>.
32096 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
32097 must be included before <wchar.h>. */
32098 #include <stddef.h>
32102 #include <wctype.h>
32113 if ac_fn_c_try_compile "$LINENO"; then :
32114 gl_cv_type_wctrans_t=yes
32116 gl_cv_type_wctrans_t=no
32118 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctrans_t" >&5
32122 $as_echo "$gl_cv_type_wctrans_t" >&6; }
32123 if test $gl_cv_type_wctrans_t = no; then
32128 for gl_func in wctype iswctype wctrans towctrans ; do
32129 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
32130 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
32131 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
32132 if eval \${$as_gl_Symbol+:} false; then :
32133 $as_echo_n "(cached) " >&6
32135 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32136 /* end confdefs.h. */
32138 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
32140 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
32141 included before <wchar.h>. */
32142 #if !(defined __GLIBC__ && !defined __UCLIBC__)
32143 # include <stddef.h>
32144 # include <stdio.h>
32146 # include <wchar.h>
32148 #include <wctype.h>
32159 if ac_fn_c_try_compile "$LINENO"; then :
32160 eval "$as_gl_Symbol=yes"
32162 eval "$as_gl_Symbol=no"
32164 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32166 eval ac_res=\$$as_gl_Symbol
32167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
32168 $as_echo "$ac_res" >&6; }
32169 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
32170 cat >>confdefs.h <<_ACEOF
32171 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
32174 eval ac_cv_have_decl_$gl_func=yes
32190 ac_fn_c_check_decl "$LINENO" "wcwidth" "ac_cv_have_decl_wcwidth" "
32191 /* AIX 3.2.5 declares wcwidth in <string.h>. */
32192 #include <string.h>
32193 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
32195 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
32196 before <wchar.h>. */
32197 #include <stddef.h>
32203 if test "x$ac_cv_have_decl_wcwidth" = xyes; then :
32209 cat >>confdefs.h <<_ACEOF
32210 #define HAVE_DECL_WCWIDTH $ac_have_decl
32213 if test $ac_cv_have_decl_wcwidth != yes; then
32214 HAVE_DECL_WCWIDTH=0
32217 if test $ac_cv_func_wcwidth = yes; then
32219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether wcwidth works reasonably in UTF-8 locales" >&5
32220 $as_echo_n "checking whether wcwidth works reasonably in UTF-8 locales... " >&6; }
32221 if ${gl_cv_func_wcwidth_works+:} false; then :
32222 $as_echo_n "(cached) " >&6
32225 if test "$cross_compiling" = yes; then :
32228 # Guess yes on glibc and AIX 7 systems.
32229 *-gnu* | aix[7-9]*) gl_cv_func_wcwidth_works="guessing yes";;
32230 *) gl_cv_func_wcwidth_works="guessing no";;
32234 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32235 /* end confdefs.h. */
32237 #include <locale.h>
32238 /* AIX 3.2.5 declares wcwidth in <string.h>. */
32239 #include <string.h>
32240 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
32242 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
32243 before <wchar.h>. */
32244 #include <stddef.h>
32248 #if !HAVE_DECL_WCWIDTH
32250 # ifdef __cplusplus
32258 if (setlocale (LC_ALL, "fr_FR.UTF-8") != NULL)
32260 if (wcwidth (0x0301) > 0)
32262 if (wcwidth (0x05B0) > 0)
32264 if (wcwidth (0x200B) > 0)
32270 if ac_fn_c_try_run "$LINENO"; then :
32271 gl_cv_func_wcwidth_works=yes
32273 gl_cv_func_wcwidth_works=no
32275 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
32276 conftest.$ac_objext conftest.beam conftest.$ac_ext
32281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_wcwidth_works" >&5
32282 $as_echo "$gl_cv_func_wcwidth_works" >&6; }
32283 case "$gl_cv_func_wcwidth_works" in
32285 *no) REPLACE_WCWIDTH=1 ;;
32291 if test $HAVE_WCWIDTH = 0 || test $REPLACE_WCWIDTH = 1; then
32300 gl_LIBOBJS="$gl_LIBOBJS wcwidth.$ac_objext"
32314 $as_echo "#define GNULIB_TEST_WCWIDTH 1" >>confdefs.h
32321 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
32327 if test $REPLACE_WRITE = 1; then
32336 gl_LIBOBJS="$gl_LIBOBJS write.$ac_objext"
32351 $as_echo "#define GNULIB_TEST_WRITE 1" >>confdefs.h
32361 for ac_header in stdint.h
32363 ac_fn_c_check_header_mongrel "$LINENO" "stdint.h" "ac_cv_header_stdint_h" "$ac_includes_default"
32364 if test "x$ac_cv_header_stdint_h" = xyes; then :
32365 cat >>confdefs.h <<_ACEOF
32366 #define HAVE_STDINT_H 1
32385 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=xasprintf:1:c-format"
32387 # End of code from modules
32408 gl_source_base='tests'
32409 gltests_WITNESS=IN_`echo "${PACKAGE-$PACKAGE_TARNAME}" | LC_ALL=C tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ | LC_ALL=C sed -e 's/[^A-Z0-9_]/_/g'`_GNULIB_TESTS
32411 gl_module_indicator_condition=$gltests_WITNESS
32421 LIBGNU_LIBDEPS="$gl_libdeps"
32423 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
32435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
32436 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
32437 if ${ac_cv_header_time+:} false; then :
32438 $as_echo_n "(cached) " >&6
32440 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32441 /* end confdefs.h. */
32442 #include <sys/types.h>
32443 #include <sys/time.h>
32449 if ((struct tm *) 0)
32455 if ac_fn_c_try_compile "$LINENO"; then :
32456 ac_cv_header_time=yes
32458 ac_cv_header_time=no
32460 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
32463 $as_echo "$ac_cv_header_time" >&6; }
32464 if test $ac_cv_header_time = yes; then
32466 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
32470 ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
32471 if test "x$ac_cv_member_struct_stat_st_blksize" = xyes; then :
32473 cat >>confdefs.h <<_ACEOF
32474 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
32478 $as_echo "#define HAVE_ST_BLKSIZE 1" >>confdefs.h
32487 # Set LIB_SETSOCKOPT to -lnsl -lsocket if necessary.
32490 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setsockopt" >&5
32491 $as_echo_n "checking for library containing setsockopt... " >&6; }
32492 if ${ac_cv_search_setsockopt+:} false; then :
32493 $as_echo_n "(cached) " >&6
32495 ac_func_search_save_LIBS=$LIBS
32496 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32497 /* end confdefs.h. */
32499 /* Override any GCC internal prototype to avoid an error.
32500 Use char because int might match the return type of a GCC
32501 builtin and then its argument prototype would still apply. */
32505 char setsockopt ();
32509 return setsockopt ();
32514 for ac_lib in '' socket; do
32515 if test -z "$ac_lib"; then
32516 ac_res="none required"
32519 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
32521 if ac_fn_c_try_link "$LINENO"; then :
32522 ac_cv_search_setsockopt=$ac_res
32524 rm -f core conftest.err conftest.$ac_objext \
32526 if ${ac_cv_search_setsockopt+:} false; then :
32530 if ${ac_cv_search_setsockopt+:} false; then :
32533 ac_cv_search_setsockopt=no
32535 rm conftest.$ac_ext
32536 LIBS=$ac_func_search_save_LIBS
32538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setsockopt" >&5
32539 $as_echo "$ac_cv_search_setsockopt" >&6; }
32540 ac_res=$ac_cv_search_setsockopt
32541 if test "$ac_res" != no; then :
32542 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
32545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setsockopt" >&5
32546 $as_echo_n "checking for library containing setsockopt... " >&6; }
32547 if ${ac_cv_search_setsockopt+:} false; then :
32548 $as_echo_n "(cached) " >&6
32550 ac_func_search_save_LIBS=$LIBS
32551 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32552 /* end confdefs.h. */
32554 /* Override any GCC internal prototype to avoid an error.
32555 Use char because int might match the return type of a GCC
32556 builtin and then its argument prototype would still apply. */
32560 char setsockopt ();
32564 return setsockopt ();
32569 for ac_lib in '' socket; do
32570 if test -z "$ac_lib"; then
32571 ac_res="none required"
32574 LIBS="-l$ac_lib -lnsl $ac_func_search_save_LIBS"
32576 if ac_fn_c_try_link "$LINENO"; then :
32577 ac_cv_search_setsockopt=$ac_res
32579 rm -f core conftest.err conftest.$ac_objext \
32581 if ${ac_cv_search_setsockopt+:} false; then :
32585 if ${ac_cv_search_setsockopt+:} false; then :
32588 ac_cv_search_setsockopt=no
32590 rm conftest.$ac_ext
32591 LIBS=$ac_func_search_save_LIBS
32593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setsockopt" >&5
32594 $as_echo "$ac_cv_search_setsockopt" >&6; }
32595 ac_res=$ac_cv_search_setsockopt
32596 if test "$ac_res" != no; then :
32597 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
32603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setsockopt" >&5
32604 $as_echo_n "checking for library containing setsockopt... " >&6; }
32605 if ${ac_cv_search_setsockopt+:} false; then :
32606 $as_echo_n "(cached) " >&6
32608 ac_func_search_save_LIBS=$LIBS
32609 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32610 /* end confdefs.h. */
32612 /* Override any GCC internal prototype to avoid an error.
32613 Use char because int might match the return type of a GCC
32614 builtin and then its argument prototype would still apply. */
32618 char setsockopt ();
32622 return setsockopt ();
32627 for ac_lib in '' nsl; do
32628 if test -z "$ac_lib"; then
32629 ac_res="none required"
32632 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
32634 if ac_fn_c_try_link "$LINENO"; then :
32635 ac_cv_search_setsockopt=$ac_res
32637 rm -f core conftest.err conftest.$ac_objext \
32639 if ${ac_cv_search_setsockopt+:} false; then :
32643 if ${ac_cv_search_setsockopt+:} false; then :
32646 ac_cv_search_setsockopt=no
32648 rm conftest.$ac_ext
32649 LIBS=$ac_func_search_save_LIBS
32651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setsockopt" >&5
32652 $as_echo "$ac_cv_search_setsockopt" >&6; }
32653 ac_res=$ac_cv_search_setsockopt
32654 if test "$ac_res" != no; then :
32655 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
32660 case "$ac_cv_search_setsockopt" in
32661 -l*) LIB_SETSOCKOPT=$ac_cv_search_setsockopt
32667 if test $ac_cv_header_sys_mtio_h = yes; then
32668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remote tape header files" >&5
32669 $as_echo_n "checking for remote tape header files... " >&6; }
32670 if ${pu_cv_header_rmt+:} false; then :
32671 $as_echo_n "(cached) " >&6
32673 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32674 /* end confdefs.h. */
32677 # include <sgtty.h>
32679 #include <sys/socket.h>
32681 if ac_fn_c_try_cpp "$LINENO"; then :
32682 pu_cv_header_rmt=yes
32684 pu_cv_header_rmt=no
32686 rm -f conftest.err conftest.i conftest.$ac_ext
32688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pu_cv_header_rmt" >&5
32689 $as_echo "$pu_cv_header_rmt" >&6; }
32690 test $pu_cv_header_rmt = yes && PU_RMT_PROG='rmt$(EXEEXT)'
32695 for ac_header in sys/mtio.h
32697 ac_fn_c_check_header_mongrel "$LINENO" "sys/mtio.h" "ac_cv_header_sys_mtio_h" "$ac_includes_default"
32698 if test "x$ac_cv_header_sys_mtio_h" = xyes; then :
32699 cat >>confdefs.h <<_ACEOF
32700 #define HAVE_SYS_MTIO_H 1
32707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which ioctl field to test for reversed bytes" >&5
32708 $as_echo_n "checking which ioctl field to test for reversed bytes... " >&6; }
32709 if ${pu_cv_header_mtio_check_field+:} false; then :
32710 $as_echo_n "(cached) " >&6
32712 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32713 /* end confdefs.h. */
32714 #include <sys/mtio.h>
32717 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
32718 $EGREP "mt_model" >/dev/null 2>&1; then :
32719 pu_cv_header_mtio_check_field=mt_model
32721 pu_cv_header_mtio_check_field=mt_type
32726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pu_cv_header_mtio_check_field" >&5
32727 $as_echo "$pu_cv_header_mtio_check_field" >&6; }
32729 cat >>confdefs.h <<_ACEOF
32730 #define MTIO_CHECK_FIELD $pu_cv_header_mtio_check_field
32736 if test "x$DEFAULT_RMT_DIR" != x; then
32737 DEFAULT_RMT_COMMAND=$DEFAULT_RMT_DIR/rmt
32739 DEFAULT_RMT_DIR='$(libexecdir)'
32742 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build rmt" >&5
32743 $as_echo_n "checking whether to build rmt... " >&6; }
32745 # Check whether --with-rmt was given.
32746 if test "${with_rmt+set}" = set; then :
32747 withval=$with_rmt; case $withval in
32748 yes|no) as_fn_error $? "Invalid argument to --with-rmt" "$LINENO" 5;;
32749 /*) DEFAULT_RMT_COMMAND=$withval
32750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, use $withval instead" >&5
32751 $as_echo "no, use $withval instead" >&6; };;
32752 *) as_fn_error $? "Argument to --with-rmt must be an absolute file name" "$LINENO" 5;;
32755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32756 $as_echo "yes" >&6; }
32758 if test "$PU_RMT_PROG" = ""; then
32759 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: not building rmt, required header files are missing" >&5
32760 $as_echo "$as_me: WARNING: not building rmt, required header files are missing" >&2;}
32766 if test "x$DEFAULT_RMT_COMMAND" != x; then
32768 cat >>confdefs.h <<_ACEOF
32769 #define DEFAULT_RMT_COMMAND "$DEFAULT_RMT_COMMAND"
32782 for ac_header in sys/buf.h
32784 ac_fn_c_check_header_compile "$LINENO" "sys/buf.h" "ac_cv_header_sys_buf_h" "#if HAVE_SYS_PARAM_H
32785 #include <sys/param.h>
32788 if test "x$ac_cv_header_sys_buf_h" = xyes; then :
32789 cat >>confdefs.h <<_ACEOF
32790 #define HAVE_SYS_BUF_H 1
32800 ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
32801 if test "x$ac_cv_member_struct_stat_st_blksize" = xyes; then :
32803 cat >>confdefs.h <<_ACEOF
32804 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
32816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname" >&5
32817 $as_echo_n "checking for library containing gethostbyname... " >&6; }
32818 if ${ac_cv_search_gethostbyname+:} false; then :
32819 $as_echo_n "(cached) " >&6
32821 ac_func_search_save_LIBS=$LIBS
32822 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32823 /* end confdefs.h. */
32825 /* Override any GCC internal prototype to avoid an error.
32826 Use char because int might match the return type of a GCC
32827 builtin and then its argument prototype would still apply. */
32831 char gethostbyname ();
32835 return gethostbyname ();
32840 for ac_lib in '' nsl; do
32841 if test -z "$ac_lib"; then
32842 ac_res="none required"
32845 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
32847 if ac_fn_c_try_link "$LINENO"; then :
32848 ac_cv_search_gethostbyname=$ac_res
32850 rm -f core conftest.err conftest.$ac_objext \
32852 if ${ac_cv_search_gethostbyname+:} false; then :
32856 if ${ac_cv_search_gethostbyname+:} false; then :
32859 ac_cv_search_gethostbyname=no
32861 rm conftest.$ac_ext
32862 LIBS=$ac_func_search_save_LIBS
32864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname" >&5
32865 $as_echo "$ac_cv_search_gethostbyname" >&6; }
32866 ac_res=$ac_cv_search_gethostbyname
32867 if test "$ac_res" != no; then :
32868 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
32875 # gl_GCC_VERSION_IFELSE([major], [minor], [run-if-found], [run-if-not-found])
32876 # ------------------------------------------------
32877 # If $CPP is gcc-MAJOR.MINOR or newer, then run RUN-IF-FOUND.
32878 # Otherwise, run RUN-IF-NOT-FOUND.
32881 # Check whether --enable-gcc-warnings was given.
32882 if test "${enable_gcc_warnings+set}" = set; then :
32883 enableval=$enable_gcc_warnings; case $enableval in
32885 *) as_fn_error $? "bad value $enableval for gcc-warnings option" "$LINENO" 5 ;;
32887 gl_gcc_warnings=$enableval
32890 if test -d "$srcdir"/.git; then
32891 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32892 /* end confdefs.h. */
32894 #if (4) < __GNUC__ || ((4) == __GNUC__ && (6) <= __GNUC_MINOR__)
32897 # error "your version of gcc is older than 4.6"
32909 if ac_fn_c_try_cpp "$LINENO"; then :
32910 gl_gcc_warnings=yes
32912 rm -f conftest.err conftest.i conftest.$ac_ext
32920 if test "$gl_gcc_warnings" = yes; then
32921 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror -Wunknown-warning-option" >&5
32922 $as_echo_n "checking whether C compiler handles -Werror -Wunknown-warning-option... " >&6; }
32923 if ${gl_cv_warn_c__Werror__Wunknown_warning_option+:} false; then :
32924 $as_echo_n "(cached) " >&6
32927 gl_save_compiler_FLAGS="$CFLAGS"
32928 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Werror -Wunknown-warning-option"
32929 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32930 /* end confdefs.h. */
32940 if ac_fn_c_try_compile "$LINENO"; then :
32941 gl_cv_warn_c__Werror__Wunknown_warning_option=yes
32943 gl_cv_warn_c__Werror__Wunknown_warning_option=no
32945 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32946 CFLAGS="$gl_save_compiler_FLAGS"
32949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror__Wunknown_warning_option" >&5
32950 $as_echo "$gl_cv_warn_c__Werror__Wunknown_warning_option" >&6; }
32951 if test "x$gl_cv_warn_c__Werror__Wunknown_warning_option" = xyes; then :
32952 gl_unknown_warnings_are_errors='-Wunknown-warning-option -Werror'
32954 gl_unknown_warnings_are_errors=
32958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror" >&5
32959 $as_echo_n "checking whether C compiler handles -Werror... " >&6; }
32960 if ${gl_cv_warn_c__Werror+:} false; then :
32961 $as_echo_n "(cached) " >&6
32964 gl_save_compiler_FLAGS="$CFLAGS"
32965 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Werror"
32966 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32967 /* end confdefs.h. */
32977 if ac_fn_c_try_compile "$LINENO"; then :
32978 gl_cv_warn_c__Werror=yes
32980 gl_cv_warn_c__Werror=no
32982 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32983 CFLAGS="$gl_save_compiler_FLAGS"
32986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror" >&5
32987 $as_echo "$gl_cv_warn_c__Werror" >&6; }
32988 if test "x$gl_cv_warn_c__Werror" = xyes; then :
32989 as_fn_append WERROR_CFLAGS " -Werror"
32996 # This, $nw, is the list of warnings we disable.
32997 nw="$nw -Wformat-nonliteral" # warnings in Fedora 17 stdio.h
32998 nw="$nw -Wvla" # warnings in gettext.h
32999 nw="$nw -Wswitch-default" # Too many warnings for now
33000 nw="$nw -Wunsafe-loop-optimizations" # It's OK to omit unsafe optimizations.
33001 nw="$nw -Winline" # It's OK to not inline.
33002 nw="$nw -Wstrict-overflow" # It's OK to optimize strictly.
33003 nw="$nw -Wsuggest-attribute=pure" # Too many warnings for now.
33007 if test -n "$GCC"; then
33009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is supported" >&5
33010 $as_echo_n "checking whether -Wno-missing-field-initializers is supported... " >&6; }
33011 if ${gl_cv_cc_nomfi_supported+:} false; then :
33012 $as_echo_n "(cached) " >&6
33015 gl_save_CFLAGS="$CFLAGS"
33016 CFLAGS="$CFLAGS -W -Werror -Wno-missing-field-initializers"
33017 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33018 /* end confdefs.h. */
33028 if ac_fn_c_try_compile "$LINENO"; then :
33029 gl_cv_cc_nomfi_supported=yes
33031 gl_cv_cc_nomfi_supported=no
33033 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33034 CFLAGS="$gl_save_CFLAGS"
33037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_supported" >&5
33038 $as_echo "$gl_cv_cc_nomfi_supported" >&6; }
33040 if test "$gl_cv_cc_nomfi_supported" = yes; then
33041 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is needed" >&5
33042 $as_echo_n "checking whether -Wno-missing-field-initializers is needed... " >&6; }
33043 if ${gl_cv_cc_nomfi_needed+:} false; then :
33044 $as_echo_n "(cached) " >&6
33047 gl_save_CFLAGS="$CFLAGS"
33048 CFLAGS="$CFLAGS -W -Werror"
33049 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33050 /* end confdefs.h. */
33053 typedef struct { int a; int b; } s_t;
33065 if ac_fn_c_try_compile "$LINENO"; then :
33066 gl_cv_cc_nomfi_needed=no
33068 gl_cv_cc_nomfi_needed=yes
33070 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33071 CFLAGS="$gl_save_CFLAGS"
33075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_needed" >&5
33076 $as_echo "$gl_cv_cc_nomfi_needed" >&6; }
33079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wuninitialized is supported" >&5
33080 $as_echo_n "checking whether -Wuninitialized is supported... " >&6; }
33081 if ${gl_cv_cc_uninitialized_supported+:} false; then :
33082 $as_echo_n "(cached) " >&6
33085 gl_save_CFLAGS="$CFLAGS"
33086 CFLAGS="$CFLAGS -Werror -Wuninitialized"
33087 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33088 /* end confdefs.h. */
33098 if ac_fn_c_try_compile "$LINENO"; then :
33099 gl_cv_cc_uninitialized_supported=yes
33101 gl_cv_cc_uninitialized_supported=no
33103 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33104 CFLAGS="$gl_save_CFLAGS"
33107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_uninitialized_supported" >&5
33108 $as_echo "$gl_cv_cc_uninitialized_supported" >&6; }
33112 # List all gcc warning categories.
33114 for gl_manywarn_item in \
33118 -Waggressive-loop-optimizations \
33122 -Wbad-function-cast \
33123 -Wbuiltin-macro-redefined \
33125 -Wchar-subscripts \
33129 -Wcoverage-mismatch \
33132 -Wdeprecated-declarations \
33133 -Wdisabled-optimization \
33135 -Wdouble-promotion \
33140 -Wformat-contains-nul \
33141 -Wformat-extra-args \
33142 -Wformat-nonliteral \
33143 -Wformat-security \
33145 -Wformat-zero-length \
33146 -Wfree-nonheap-object \
33147 -Wignored-qualifiers \
33149 -Wimplicit-function-declaration \
33153 -Wint-to-pointer-cast \
33154 -Winvalid-memory-model \
33156 -Wjump-misses-init \
33159 -Wmaybe-uninitialized \
33161 -Wmissing-declarations \
33162 -Wmissing-field-initializers \
33163 -Wmissing-include-dirs \
33164 -Wmissing-parameter-type \
33165 -Wmissing-prototypes \
33172 -Wold-style-declaration \
33173 -Wold-style-definition \
33175 -Woverlength-strings \
33178 -Wpacked-bitfield-compat \
33182 -Wpointer-to-int-cast \
33184 -Wreturn-local-addr \
33188 -Wsizeof-pointer-memaccess \
33189 -Wstack-protector \
33190 -Wstrict-aliasing \
33191 -Wstrict-overflow \
33192 -Wstrict-prototypes \
33193 -Wsuggest-attribute=const \
33194 -Wsuggest-attribute=format \
33195 -Wsuggest-attribute=noreturn \
33196 -Wsuggest-attribute=pure \
33205 -Wunknown-pragmas \
33206 -Wunsafe-loop-optimizations \
33208 -Wunused-but-set-parameter \
33209 -Wunused-but-set-variable \
33210 -Wunused-function \
33212 -Wunused-local-typedefs \
33214 -Wunused-parameter \
33217 -Wunused-variable \
33219 -Wvariadic-macros \
33220 -Wvector-operation-performance \
33222 -Wvolatile-register-var \
33226 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
33229 # Disable specific options as needed.
33230 if test "$gl_cv_cc_nomfi_needed" = yes; then
33231 gl_manywarn_set="$gl_manywarn_set -Wno-missing-field-initializers"
33234 if test "$gl_cv_cc_uninitialized_supported" = no; then
33235 gl_manywarn_set="$gl_manywarn_set -Wno-uninitialized"
33238 ws=$gl_manywarn_set
33246 *" $gl_warn_item "*)
33249 gl_warn_set="$gl_warn_set $gl_warn_item"
33257 as_gl_Warn=`$as_echo "gl_cv_warn_c_$w" | $as_tr_sh`
33258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles $w" >&5
33259 $as_echo_n "checking whether C compiler handles $w... " >&6; }
33260 if eval \${$as_gl_Warn+:} false; then :
33261 $as_echo_n "(cached) " >&6
33264 gl_save_compiler_FLAGS="$CFLAGS"
33265 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors $w"
33266 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33267 /* end confdefs.h. */
33277 if ac_fn_c_try_compile "$LINENO"; then :
33278 eval "$as_gl_Warn=yes"
33280 eval "$as_gl_Warn=no"
33282 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33283 CFLAGS="$gl_save_compiler_FLAGS"
33286 eval ac_res=\$$as_gl_Warn
33287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
33288 $as_echo "$ac_res" >&6; }
33289 if eval test \"x\$"$as_gl_Warn"\" = x"yes"; then :
33290 as_fn_append WARN_CFLAGS " $w"
33296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-sign-compare" >&5
33297 $as_echo_n "checking whether C compiler handles -Wno-sign-compare... " >&6; }
33298 if ${gl_cv_warn_c__Wno_sign_compare+:} false; then :
33299 $as_echo_n "(cached) " >&6
33302 gl_save_compiler_FLAGS="$CFLAGS"
33303 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-sign-compare"
33304 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33305 /* end confdefs.h. */
33315 if ac_fn_c_try_compile "$LINENO"; then :
33316 gl_cv_warn_c__Wno_sign_compare=yes
33318 gl_cv_warn_c__Wno_sign_compare=no
33320 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33321 CFLAGS="$gl_save_compiler_FLAGS"
33324 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_sign_compare" >&5
33325 $as_echo "$gl_cv_warn_c__Wno_sign_compare" >&6; }
33326 if test "x$gl_cv_warn_c__Wno_sign_compare" = xyes; then :
33327 as_fn_append WARN_CFLAGS " -Wno-sign-compare"
33330 # Too many warnings for now
33332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-type-limits" >&5
33333 $as_echo_n "checking whether C compiler handles -Wno-type-limits... " >&6; }
33334 if ${gl_cv_warn_c__Wno_type_limits+:} false; then :
33335 $as_echo_n "(cached) " >&6
33338 gl_save_compiler_FLAGS="$CFLAGS"
33339 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-type-limits"
33340 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33341 /* end confdefs.h. */
33351 if ac_fn_c_try_compile "$LINENO"; then :
33352 gl_cv_warn_c__Wno_type_limits=yes
33354 gl_cv_warn_c__Wno_type_limits=no
33356 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33357 CFLAGS="$gl_save_compiler_FLAGS"
33360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_type_limits" >&5
33361 $as_echo "$gl_cv_warn_c__Wno_type_limits" >&6; }
33362 if test "x$gl_cv_warn_c__Wno_type_limits" = xyes; then :
33363 as_fn_append WARN_CFLAGS " -Wno-type-limits"
33366 # It's OK to optimize based on types.
33368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-parameter" >&5
33369 $as_echo_n "checking whether C compiler handles -Wno-unused-parameter... " >&6; }
33370 if ${gl_cv_warn_c__Wno_unused_parameter+:} false; then :
33371 $as_echo_n "(cached) " >&6
33374 gl_save_compiler_FLAGS="$CFLAGS"
33375 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-unused-parameter"
33376 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33377 /* end confdefs.h. */
33387 if ac_fn_c_try_compile "$LINENO"; then :
33388 gl_cv_warn_c__Wno_unused_parameter=yes
33390 gl_cv_warn_c__Wno_unused_parameter=no
33392 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33393 CFLAGS="$gl_save_compiler_FLAGS"
33396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_parameter" >&5
33397 $as_echo "$gl_cv_warn_c__Wno_unused_parameter" >&6; }
33398 if test "x$gl_cv_warn_c__Wno_unused_parameter" = xyes; then :
33399 as_fn_append WARN_CFLAGS " -Wno-unused-parameter"
33402 # Too many warnings for now
33404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-nonliteral" >&5
33405 $as_echo_n "checking whether C compiler handles -Wno-format-nonliteral... " >&6; }
33406 if ${gl_cv_warn_c__Wno_format_nonliteral+:} false; then :
33407 $as_echo_n "(cached) " >&6
33410 gl_save_compiler_FLAGS="$CFLAGS"
33411 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-format-nonliteral"
33412 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33413 /* end confdefs.h. */
33423 if ac_fn_c_try_compile "$LINENO"; then :
33424 gl_cv_warn_c__Wno_format_nonliteral=yes
33426 gl_cv_warn_c__Wno_format_nonliteral=no
33428 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33429 CFLAGS="$gl_save_compiler_FLAGS"
33432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_nonliteral" >&5
33433 $as_echo "$gl_cv_warn_c__Wno_format_nonliteral" >&6; }
33434 if test "x$gl_cv_warn_c__Wno_format_nonliteral" = xyes; then :
33435 as_fn_append WARN_CFLAGS " -Wno-format-nonliteral"
33441 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -fdiagnostics-show-option" >&5
33442 $as_echo_n "checking whether C compiler handles -fdiagnostics-show-option... " >&6; }
33443 if ${gl_cv_warn_c__fdiagnostics_show_option+:} false; then :
33444 $as_echo_n "(cached) " >&6
33447 gl_save_compiler_FLAGS="$CFLAGS"
33448 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -fdiagnostics-show-option"
33449 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33450 /* end confdefs.h. */
33460 if ac_fn_c_try_compile "$LINENO"; then :
33461 gl_cv_warn_c__fdiagnostics_show_option=yes
33463 gl_cv_warn_c__fdiagnostics_show_option=no
33465 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33466 CFLAGS="$gl_save_compiler_FLAGS"
33469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__fdiagnostics_show_option" >&5
33470 $as_echo "$gl_cv_warn_c__fdiagnostics_show_option" >&6; }
33471 if test "x$gl_cv_warn_c__fdiagnostics_show_option" = xyes; then :
33472 as_fn_append WARN_CFLAGS " -fdiagnostics-show-option"
33477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -funit-at-a-time" >&5
33478 $as_echo_n "checking whether C compiler handles -funit-at-a-time... " >&6; }
33479 if ${gl_cv_warn_c__funit_at_a_time+:} false; then :
33480 $as_echo_n "(cached) " >&6
33483 gl_save_compiler_FLAGS="$CFLAGS"
33484 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -funit-at-a-time"
33485 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33486 /* end confdefs.h. */
33496 if ac_fn_c_try_compile "$LINENO"; then :
33497 gl_cv_warn_c__funit_at_a_time=yes
33499 gl_cv_warn_c__funit_at_a_time=no
33501 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33502 CFLAGS="$gl_save_compiler_FLAGS"
33505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__funit_at_a_time" >&5
33506 $as_echo "$gl_cv_warn_c__funit_at_a_time" >&6; }
33507 if test "x$gl_cv_warn_c__funit_at_a_time" = xyes; then :
33508 as_fn_append WARN_CFLAGS " -funit-at-a-time"
33516 $as_echo "#define lint 1" >>confdefs.h
33520 $as_echo "#define GNULIB_PORTCHECK 1" >>confdefs.h
33523 # Use a slightly smaller set of warning options for lib/.
33524 # Remove the following and save the result in GNULIB_WARN_CFLAGS.
33526 nw="$nw -Wmissing-prototypes"
33527 nw="$nw -Wunused-macros"
33529 # These are for argp.
33530 nw="$nw -Wmissing-field-initializers"
33535 set x $WARN_CFLAGS; shift
33539 *" $gl_warn_item "*)
33542 gl_warn_set="$gl_warn_set $gl_warn_item"
33546 GNULIB_WARN_CFLAGS=$gl_warn_set
33549 # This is also for argp.
33551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-missing-field-initializers" >&5
33552 $as_echo_n "checking whether C compiler handles -Wno-missing-field-initializers... " >&6; }
33553 if ${gl_cv_warn_c__Wno_missing_field_initializers+:} false; then :
33554 $as_echo_n "(cached) " >&6
33557 gl_save_compiler_FLAGS="$CFLAGS"
33558 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-missing-field-initializers"
33559 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33560 /* end confdefs.h. */
33570 if ac_fn_c_try_compile "$LINENO"; then :
33571 gl_cv_warn_c__Wno_missing_field_initializers=yes
33573 gl_cv_warn_c__Wno_missing_field_initializers=no
33575 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33576 CFLAGS="$gl_save_compiler_FLAGS"
33579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_missing_field_initializers" >&5
33580 $as_echo "$gl_cv_warn_c__Wno_missing_field_initializers" >&6; }
33581 if test "x$gl_cv_warn_c__Wno_missing_field_initializers" = xyes; then :
33582 as_fn_append GNULIB_WARN_CFLAGS " -Wno-missing-field-initializers"
33589 # For gnulib-tests, the set is slightly smaller still.
33591 # It's not worth being this picky about test programs.
33592 nw="$nw -Wsuggest-attribute=const"
33595 set x $GNULIB_WARN_CFLAGS; shift
33599 *" $gl_warn_item "*)
33602 gl_warn_set="$gl_warn_set $gl_warn_item"
33606 GNULIB_TEST_WARN_CFLAGS=$gl_warn_set
33613 # Check whether --with-xattrs was given.
33614 if test "${with_xattrs+set}" = set; then :
33615 withval=$with_xattrs;
33622 for ac_header in attr/xattr.h
33624 ac_fn_c_check_header_mongrel "$LINENO" "attr/xattr.h" "ac_cv_header_attr_xattr_h" "$ac_includes_default"
33625 if test "x$ac_cv_header_attr_xattr_h" = xyes; then :
33626 cat >>confdefs.h <<_ACEOF
33627 #define HAVE_ATTR_XATTR_H 1
33634 if test "$ac_cv_header_attr_xattr_h" = yes; then
33635 TAR_COND_XATTR_H_TRUE=
33636 TAR_COND_XATTR_H_FALSE='#'
33638 TAR_COND_XATTR_H_TRUE='#'
33639 TAR_COND_XATTR_H_FALSE=
33642 if test "$ac_cv_header_attr_xattr_h" = yes; then
33643 for ac_func in getxattr fgetxattr lgetxattr \
33644 setxattr fsetxattr lsetxattr \
33645 listxattr flistxattr llistxattr
33647 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
33648 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
33649 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
33650 cat >>confdefs.h <<_ACEOF
33651 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
33653 # only when functions are present
33655 $as_echo "#define HAVE_ATTR_XATTR_H 1" >>confdefs.h
33657 if test "$with_xattrs" != no; then
33659 $as_echo "#define HAVE_XATTRS /**/" >>confdefs.h
33675 ac_fn_c_check_decl "$LINENO" "getgrgid" "ac_cv_have_decl_getgrgid" "#include <grp.h>
33677 if test "x$ac_cv_have_decl_getgrgid" = xyes; then :
33683 cat >>confdefs.h <<_ACEOF
33684 #define HAVE_DECL_GETGRGID $ac_have_decl
33687 ac_fn_c_check_decl "$LINENO" "getpwuid" "ac_cv_have_decl_getpwuid" "#include <pwd.h>
33689 if test "x$ac_cv_have_decl_getpwuid" = xyes; then :
33695 cat >>confdefs.h <<_ACEOF
33696 #define HAVE_DECL_GETPWUID $ac_have_decl
33699 ac_fn_c_check_decl "$LINENO" "time" "ac_cv_have_decl_time" "#include <time.h>
33701 if test "x$ac_cv_have_decl_time" = xyes; then :
33707 cat >>confdefs.h <<_ACEOF
33708 #define HAVE_DECL_TIME $ac_have_decl
33712 ac_fn_c_check_func "$LINENO" "waitpid" "ac_cv_func_waitpid"
33713 if test "x$ac_cv_func_waitpid" = xyes; then :
33714 $as_echo "#define HAVE_WAITPID 1" >>confdefs.h
33717 case " $LIBOBJS " in
33718 *" waitpid.$ac_objext "* ) ;;
33719 *) LIBOBJS="$LIBOBJS waitpid.$ac_objext"
33728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remote shell" >&5
33729 $as_echo_n "checking for remote shell... " >&6; }
33730 if ${tar_cv_path_RSH+:} false; then :
33731 $as_echo_n "(cached) " >&6
33733 if test -n "$RSH"; then
33734 tar_cv_path_RSH=$RSH
33737 for ac_file in /usr/ucb/rsh /usr/bin/remsh /usr/bin/rsh /usr/bsd/rsh \
33738 /usr/bin/nsh /usr/bin/rcmd
33740 # Prefer a non-symlink rsh to a symlink one, so that binaries built
33741 # on AIX 4.1.4, where /usr/ucb/rsh is a symlink to /usr/bin/rsh
33742 # will run on AIX 4.3.0, which has only /usr/bin/rsh.
33743 if test -f $ac_file; then
33744 if (test -h $ac_file) 2>/dev/null; then
33745 test $tar_cv_path_RSH = no && tar_cv_path_RSH=$ac_file
33747 tar_cv_path_RSH=$ac_file
33754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tar_cv_path_RSH" >&5
33755 $as_echo "$tar_cv_path_RSH" >&6; }
33756 if test $tar_cv_path_RSH = no; then
33757 for ac_header in netdb.h
33759 ac_fn_c_check_header_mongrel "$LINENO" "netdb.h" "ac_cv_header_netdb_h" "$ac_includes_default"
33760 if test "x$ac_cv_header_netdb_h" = xyes; then :
33761 cat >>confdefs.h <<_ACEOF
33762 #define HAVE_NETDB_H 1
33771 cat >>confdefs.h <<_ACEOF
33772 #define REMOTE_SHELL "$tar_cv_path_RSH"
33781 # Check whether --with-compress was given.
33782 if test "${with_compress+set}" = set; then :
33783 withval=$with_compress; tar_cv_compressor_compress=${withval}
33785 tar_cv_compressor_compress=compress
33789 cat >>confdefs.h <<_ACEOF
33790 #define COMPRESS_PROGRAM "$tar_cv_compressor_compress"
33797 # Check whether --with-gzip was given.
33798 if test "${with_gzip+set}" = set; then :
33799 withval=$with_gzip; tar_cv_compressor_gzip=${withval}
33801 tar_cv_compressor_gzip=gzip
33805 cat >>confdefs.h <<_ACEOF
33806 #define GZIP_PROGRAM "$tar_cv_compressor_gzip"
33813 # Check whether --with-bzip2 was given.
33814 if test "${with_bzip2+set}" = set; then :
33815 withval=$with_bzip2; tar_cv_compressor_bzip2=${withval}
33817 tar_cv_compressor_bzip2=bzip2
33821 cat >>confdefs.h <<_ACEOF
33822 #define BZIP2_PROGRAM "$tar_cv_compressor_bzip2"
33829 # Check whether --with-lzip was given.
33830 if test "${with_lzip+set}" = set; then :
33831 withval=$with_lzip; tar_cv_compressor_lzip=${withval}
33833 tar_cv_compressor_lzip=lzip
33837 cat >>confdefs.h <<_ACEOF
33838 #define LZIP_PROGRAM "$tar_cv_compressor_lzip"
33845 # Check whether --with-lzma was given.
33846 if test "${with_lzma+set}" = set; then :
33847 withval=$with_lzma; tar_cv_compressor_lzma=${withval}
33849 tar_cv_compressor_lzma=lzma
33853 cat >>confdefs.h <<_ACEOF
33854 #define LZMA_PROGRAM "$tar_cv_compressor_lzma"
33861 # Check whether --with-lzop was given.
33862 if test "${with_lzop+set}" = set; then :
33863 withval=$with_lzop; tar_cv_compressor_lzop=${withval}
33865 tar_cv_compressor_lzop=lzop
33869 cat >>confdefs.h <<_ACEOF
33870 #define LZOP_PROGRAM "$tar_cv_compressor_lzop"
33877 # Check whether --with-xz was given.
33878 if test "${with_xz+set}" = set; then :
33879 withval=$with_xz; tar_cv_compressor_xz=${withval}
33881 tar_cv_compressor_xz=xz
33885 cat >>confdefs.h <<_ACEOF
33886 #define XZ_PROGRAM "$tar_cv_compressor_xz"
33890 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default archive format" >&5
33891 $as_echo_n "checking for default archive format... " >&6; }
33895 if test -z "$DEFAULT_ARCHIVE_FORMAT"; then
33896 DEFAULT_ARCHIVE_FORMAT="GNU"
33898 case $DEFAULT_ARCHIVE_FORMAT in
33899 V7|OLDGNU|USTAR|POSIX|GNU) ;;
33900 *) as_fn_error $? "Invalid format name" "$LINENO" 5;;
33903 cat >>confdefs.h <<_ACEOF
33904 #define DEFAULT_ARCHIVE_FORMAT ${DEFAULT_ARCHIVE_FORMAT}_FORMAT
33907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEFAULT_ARCHIVE_FORMAT" >&5
33908 $as_echo "$DEFAULT_ARCHIVE_FORMAT" >&6; }
33910 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default archive" >&5
33911 $as_echo_n "checking for default archive... " >&6; }
33914 if test -z "$DEFAULT_ARCHIVE"; then
33917 if test -z "`ls $DEFAULT_ARCHIVE 2>/dev/null`"; then
33918 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: DEFAULT_ARCHIVE '$DEFAULT_ARCHIVE' not found on this system" >&5
33919 $as_echo "$as_me: WARNING: DEFAULT_ARCHIVE '$DEFAULT_ARCHIVE' not found on this system" >&2;}
33921 # FIXME: Look for DEFTAPE in <sys/mtio.h>.
33922 # FIXME: Let DEVICE_PREFIX be configured from the environment.
33923 # FIXME: Rearrange, here.
33924 case $DEFAULT_ARCHIVE in
33927 $as_echo "#define DENSITY_LETTER 1" >>confdefs.h
33929 device_prefix=`echo $DEFAULT_ARCHIVE | sed 's/0-7lmh$//'`
33932 device_prefix=`echo $DEFAULT_ARCHIVE | sed 's/0-7$//'`
33938 case "$device_prefix" in
33941 cat >>confdefs.h <<_ACEOF
33942 #define DEVICE_PREFIX "$device_prefix"
33949 cat >>confdefs.h <<_ACEOF
33950 #define DEFAULT_ARCHIVE "$DEFAULT_ARCHIVE"
33953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEFAULT_ARCHIVE" >&5
33954 $as_echo "$DEFAULT_ARCHIVE" >&6; }
33957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default blocking" >&5
33958 $as_echo_n "checking for default blocking... " >&6; }
33959 DEFAULT_BLOCKING=${DEFAULT_BLOCKING-20}
33961 cat >>confdefs.h <<_ACEOF
33962 #define DEFAULT_BLOCKING $DEFAULT_BLOCKING
33965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEFAULT_BLOCKING" >&5
33966 $as_echo "$DEFAULT_BLOCKING" >&6; }
33968 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default quoting style" >&5
33969 $as_echo_n "checking for default quoting style... " >&6; }
33972 DEFAULT_QUOTING_STYLE="escape"
33975 case $DEFAULT_QUOTING_STYLE in
33976 literal|shell|shell-always|c|escape|locale|clocale) ;;
33977 *) as_fn_error $? "Invalid quoting style" "$LINENO" 5;;
33979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEFAULT_QUOTING_STYLE" >&5
33980 $as_echo "$DEFAULT_QUOTING_STYLE" >&6; }
33981 DEFAULT_QUOTING_STYLE=`echo ${DEFAULT_QUOTING_STYLE}|sed 's/-/_/g'`_quoting_style
33983 cat >>confdefs.h <<_ACEOF
33984 #define DEFAULT_QUOTING_STYLE $DEFAULT_QUOTING_STYLE
33990 if test "X$prefix" = "XNONE"; then
33991 acl_final_prefix="$ac_default_prefix"
33993 acl_final_prefix="$prefix"
33995 if test "X$exec_prefix" = "XNONE"; then
33996 acl_final_exec_prefix='${prefix}'
33998 acl_final_exec_prefix="$exec_prefix"
34000 acl_save_prefix="$prefix"
34001 prefix="$acl_final_prefix"
34002 eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
34003 prefix="$acl_save_prefix"
34007 # Check whether --with-gnu-ld was given.
34008 if test "${with_gnu_ld+set}" = set; then :
34009 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
34014 # Prepare PATH_SEPARATOR.
34015 # The user is always right.
34016 if test "${PATH_SEPARATOR+set}" != set; then
34017 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
34018 # contains only /bin. Note that ksh looks also at the FPATH variable,
34019 # so we have to set that as well for the test.
34021 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
34022 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
34023 || PATH_SEPARATOR=';'
34028 if test "$GCC" = yes; then
34029 # Check if gcc -print-prog-name=ld gives a path.
34030 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
34031 $as_echo_n "checking for ld used by $CC... " >&6; }
34034 # gcc leaves a trailing carriage return which upsets mingw
34035 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
34037 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
34040 # Accept absolute paths.
34042 re_direlt='/[^/][^/]*/\.\./'
34043 # Canonicalize the pathname of ld
34044 ac_prog=`echo "$ac_prog"| sed 's%\\\\%/%g'`
34045 while echo "$ac_prog" | grep "$re_direlt" > /dev/null 2>&1; do
34046 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
34048 test -z "$LD" && LD="$ac_prog"
34051 # If it fails, then pretend we aren't using GCC.
34055 # If it is relative, then search for the first ld in PATH.
34056 with_gnu_ld=unknown
34059 elif test "$with_gnu_ld" = yes; then
34060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
34061 $as_echo_n "checking for GNU ld... " >&6; }
34063 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
34064 $as_echo_n "checking for non-GNU ld... " >&6; }
34066 if ${acl_cv_path_LD+:} false; then :
34067 $as_echo_n "(cached) " >&6
34069 if test -z "$LD"; then
34070 acl_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
34071 for ac_dir in $PATH; do
34072 IFS="$acl_save_ifs"
34073 test -z "$ac_dir" && ac_dir=.
34074 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
34075 acl_cv_path_LD="$ac_dir/$ac_prog"
34076 # Check to see if the program is GNU ld. I'd rather use --version,
34077 # but apparently some variants of GNU ld only accept -v.
34078 # Break only if it was the GNU/non-GNU ld that we prefer.
34079 case `"$acl_cv_path_LD" -v 2>&1 </dev/null` in
34080 *GNU* | *'with BFD'*)
34081 test "$with_gnu_ld" != no && break
34084 test "$with_gnu_ld" != yes && break
34089 IFS="$acl_save_ifs"
34091 acl_cv_path_LD="$LD" # Let the user override the test with a path.
34095 LD="$acl_cv_path_LD"
34096 if test -n "$LD"; then
34097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
34098 $as_echo "$LD" >&6; }
34100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34101 $as_echo "no" >&6; }
34103 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
34104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
34105 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
34106 if ${acl_cv_prog_gnu_ld+:} false; then :
34107 $as_echo_n "(cached) " >&6
34109 # I'd rather use --version here, but apparently some GNU lds only accept -v.
34110 case `$LD -v 2>&1 </dev/null` in
34111 *GNU* | *'with BFD'*)
34112 acl_cv_prog_gnu_ld=yes
34115 acl_cv_prog_gnu_ld=no
34119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
34120 $as_echo "$acl_cv_prog_gnu_ld" >&6; }
34121 with_gnu_ld=$acl_cv_prog_gnu_ld
34126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
34127 $as_echo_n "checking for shared library run path origin... " >&6; }
34128 if ${acl_cv_rpath+:} false; then :
34129 $as_echo_n "(cached) " >&6
34132 CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
34133 ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
34135 rm -f ./conftest.sh
34139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
34140 $as_echo "$acl_cv_rpath" >&6; }
34142 acl_libext="$acl_cv_libext"
34143 acl_shlibext="$acl_cv_shlibext"
34144 acl_libname_spec="$acl_cv_libname_spec"
34145 acl_library_names_spec="$acl_cv_library_names_spec"
34146 acl_hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
34147 acl_hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
34148 acl_hardcode_direct="$acl_cv_hardcode_direct"
34149 acl_hardcode_minus_L="$acl_cv_hardcode_minus_L"
34150 # Check whether --enable-rpath was given.
34151 if test "${enable_rpath+set}" = set; then :
34152 enableval=$enable_rpath; :
34164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit host" >&5
34165 $as_echo_n "checking for 64-bit host... " >&6; }
34166 if ${gl_cv_solaris_64bit+:} false; then :
34167 $as_echo_n "(cached) " >&6
34169 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34170 /* end confdefs.h. */
34177 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
34178 $EGREP "sixtyfour bits" >/dev/null 2>&1; then :
34179 gl_cv_solaris_64bit=yes
34181 gl_cv_solaris_64bit=no
34187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_solaris_64bit" >&5
34188 $as_echo "$gl_cv_solaris_64bit" >&6; }
34189 if test $gl_cv_solaris_64bit = yes; then
34190 acl_libdirstem=lib/64
34191 case "$host_cpu" in
34192 sparc*) acl_libdirstem2=lib/sparcv9 ;;
34193 i*86 | x86_64) acl_libdirstem2=lib/amd64 ;;
34198 searchpath=`(LC_ALL=C $CC -print-search-dirs) 2>/dev/null | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'`
34199 if test -n "$searchpath"; then
34200 acl_save_IFS="${IFS= }"; IFS=":"
34201 for searchdir in $searchpath; do
34202 if test -d "$searchdir"; then
34203 case "$searchdir" in
34204 */lib64/ | */lib64 ) acl_libdirstem=lib64 ;;
34206 # Better ignore directories of this form. They are misleading.
34208 *) searchdir=`cd "$searchdir" && pwd`
34209 case "$searchdir" in
34210 */lib64 ) acl_libdirstem=lib64 ;;
34215 IFS="$acl_save_IFS"
34219 test -n "$acl_libdirstem2" || acl_libdirstem2="$acl_libdirstem"
34234 acl_save_prefix="$prefix"
34235 prefix="$acl_final_prefix"
34236 acl_save_exec_prefix="$exec_prefix"
34237 exec_prefix="$acl_final_exec_prefix"
34239 eval additional_includedir=\"$includedir\"
34240 eval additional_libdir=\"$libdir\"
34242 exec_prefix="$acl_save_exec_prefix"
34243 prefix="$acl_save_prefix"
34246 # Check whether --with-libiconv-prefix was given.
34247 if test "${with_libiconv_prefix+set}" = set; then :
34248 withval=$with_libiconv_prefix;
34249 if test "X$withval" = "Xno"; then
34252 if test "X$withval" = "X"; then
34254 acl_save_prefix="$prefix"
34255 prefix="$acl_final_prefix"
34256 acl_save_exec_prefix="$exec_prefix"
34257 exec_prefix="$acl_final_exec_prefix"
34259 eval additional_includedir=\"$includedir\"
34260 eval additional_libdir=\"$libdir\"
34262 exec_prefix="$acl_save_exec_prefix"
34263 prefix="$acl_save_prefix"
34266 additional_includedir="$withval/include"
34267 additional_libdir="$withval/$acl_libdirstem"
34268 if test "$acl_libdirstem2" != "$acl_libdirstem" \
34269 && ! test -d "$withval/$acl_libdirstem"; then
34270 additional_libdir="$withval/$acl_libdirstem2"
34284 names_already_handled=
34285 names_next_round='iconv '
34286 while test -n "$names_next_round"; do
34287 names_this_round="$names_next_round"
34289 for name in $names_this_round; do
34291 for n in $names_already_handled; do
34292 if test "$n" = "$name"; then
34293 already_handled=yes
34297 if test -z "$already_handled"; then
34298 names_already_handled="$names_already_handled $name"
34299 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./+-|ABCDEFGHIJKLMNOPQRSTUVWXYZ____|'`
34300 eval value=\"\$HAVE_LIB$uppername\"
34301 if test -n "$value"; then
34302 if test "$value" = yes; then
34303 eval value=\"\$LIB$uppername\"
34304 test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
34305 eval value=\"\$LTLIB$uppername\"
34306 test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
34315 eval libname=\"$acl_libname_spec\" # typically: libname=lib$name
34316 if test -n "$acl_shlibext"; then
34317 shrext=".$acl_shlibext" # typically: shrext=.so
34321 if test $use_additional = yes; then
34322 dir="$additional_libdir"
34323 if test -n "$acl_shlibext"; then
34324 if test -f "$dir/$libname$shrext"; then
34326 found_so="$dir/$libname$shrext"
34328 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
34329 ver=`(cd "$dir" && \
34330 for f in "$libname$shrext".*; do echo "$f"; done \
34331 | sed -e "s,^$libname$shrext\\\\.,," \
34332 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
34333 | sed 1q ) 2>/dev/null`
34334 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
34336 found_so="$dir/$libname$shrext.$ver"
34339 eval library_names=\"$acl_library_names_spec\"
34340 for f in $library_names; do
34341 if test -f "$dir/$f"; then
34350 if test "X$found_dir" = "X"; then
34351 if test -f "$dir/$libname.$acl_libext"; then
34353 found_a="$dir/$libname.$acl_libext"
34356 if test "X$found_dir" != "X"; then
34357 if test -f "$dir/$libname.la"; then
34358 found_la="$dir/$libname.la"
34362 if test "X$found_dir" = "X"; then
34363 for x in $LDFLAGS $LTLIBICONV; do
34365 acl_save_prefix="$prefix"
34366 prefix="$acl_final_prefix"
34367 acl_save_exec_prefix="$exec_prefix"
34368 exec_prefix="$acl_final_exec_prefix"
34370 exec_prefix="$acl_save_exec_prefix"
34371 prefix="$acl_save_prefix"
34375 dir=`echo "X$x" | sed -e 's/^X-L//'`
34376 if test -n "$acl_shlibext"; then
34377 if test -f "$dir/$libname$shrext"; then
34379 found_so="$dir/$libname$shrext"
34381 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
34382 ver=`(cd "$dir" && \
34383 for f in "$libname$shrext".*; do echo "$f"; done \
34384 | sed -e "s,^$libname$shrext\\\\.,," \
34385 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
34386 | sed 1q ) 2>/dev/null`
34387 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
34389 found_so="$dir/$libname$shrext.$ver"
34392 eval library_names=\"$acl_library_names_spec\"
34393 for f in $library_names; do
34394 if test -f "$dir/$f"; then
34403 if test "X$found_dir" = "X"; then
34404 if test -f "$dir/$libname.$acl_libext"; then
34406 found_a="$dir/$libname.$acl_libext"
34409 if test "X$found_dir" != "X"; then
34410 if test -f "$dir/$libname.la"; then
34411 found_la="$dir/$libname.la"
34416 if test "X$found_dir" != "X"; then
34421 if test "X$found_dir" != "X"; then
34422 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
34423 if test "X$found_so" != "X"; then
34424 if test "$enable_rpath" = no \
34425 || test "X$found_dir" = "X/usr/$acl_libdirstem" \
34426 || test "X$found_dir" = "X/usr/$acl_libdirstem2"; then
34427 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
34430 for x in $ltrpathdirs; do
34431 if test "X$x" = "X$found_dir"; then
34436 if test -z "$haveit"; then
34437 ltrpathdirs="$ltrpathdirs $found_dir"
34439 if test "$acl_hardcode_direct" = yes; then
34440 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
34442 if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
34443 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
34445 for x in $rpathdirs; do
34446 if test "X$x" = "X$found_dir"; then
34451 if test -z "$haveit"; then
34452 rpathdirs="$rpathdirs $found_dir"
34456 for x in $LDFLAGS $LIBICONV; do
34458 acl_save_prefix="$prefix"
34459 prefix="$acl_final_prefix"
34460 acl_save_exec_prefix="$exec_prefix"
34461 exec_prefix="$acl_final_exec_prefix"
34463 exec_prefix="$acl_save_exec_prefix"
34464 prefix="$acl_save_prefix"
34466 if test "X$x" = "X-L$found_dir"; then
34471 if test -z "$haveit"; then
34472 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
34474 if test "$acl_hardcode_minus_L" != no; then
34475 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
34477 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
34483 if test "X$found_a" != "X"; then
34484 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
34486 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
34489 additional_includedir=
34490 case "$found_dir" in
34491 */$acl_libdirstem | */$acl_libdirstem/)
34492 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
34493 if test "$name" = 'iconv'; then
34494 LIBICONV_PREFIX="$basedir"
34496 additional_includedir="$basedir/include"
34498 */$acl_libdirstem2 | */$acl_libdirstem2/)
34499 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
34500 if test "$name" = 'iconv'; then
34501 LIBICONV_PREFIX="$basedir"
34503 additional_includedir="$basedir/include"
34506 if test "X$additional_includedir" != "X"; then
34507 if test "X$additional_includedir" != "X/usr/include"; then
34509 if test "X$additional_includedir" = "X/usr/local/include"; then
34510 if test -n "$GCC"; then
34512 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
34516 if test -z "$haveit"; then
34517 for x in $CPPFLAGS $INCICONV; do
34519 acl_save_prefix="$prefix"
34520 prefix="$acl_final_prefix"
34521 acl_save_exec_prefix="$exec_prefix"
34522 exec_prefix="$acl_final_exec_prefix"
34524 exec_prefix="$acl_save_exec_prefix"
34525 prefix="$acl_save_prefix"
34527 if test "X$x" = "X-I$additional_includedir"; then
34532 if test -z "$haveit"; then
34533 if test -d "$additional_includedir"; then
34534 INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
34540 if test -n "$found_la"; then
34541 save_libdir="$libdir"
34542 case "$found_la" in
34543 */* | *\\*) . "$found_la" ;;
34544 *) . "./$found_la" ;;
34546 libdir="$save_libdir"
34547 for dep in $dependency_libs; do
34550 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
34551 if test "X$additional_libdir" != "X/usr/$acl_libdirstem" \
34552 && test "X$additional_libdir" != "X/usr/$acl_libdirstem2"; then
34554 if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem" \
34555 || test "X$additional_libdir" = "X/usr/local/$acl_libdirstem2"; then
34556 if test -n "$GCC"; then
34558 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
34562 if test -z "$haveit"; then
34564 for x in $LDFLAGS $LIBICONV; do
34566 acl_save_prefix="$prefix"
34567 prefix="$acl_final_prefix"
34568 acl_save_exec_prefix="$exec_prefix"
34569 exec_prefix="$acl_final_exec_prefix"
34571 exec_prefix="$acl_save_exec_prefix"
34572 prefix="$acl_save_prefix"
34574 if test "X$x" = "X-L$additional_libdir"; then
34579 if test -z "$haveit"; then
34580 if test -d "$additional_libdir"; then
34581 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir"
34585 for x in $LDFLAGS $LTLIBICONV; do
34587 acl_save_prefix="$prefix"
34588 prefix="$acl_final_prefix"
34589 acl_save_exec_prefix="$exec_prefix"
34590 exec_prefix="$acl_final_exec_prefix"
34592 exec_prefix="$acl_save_exec_prefix"
34593 prefix="$acl_save_prefix"
34595 if test "X$x" = "X-L$additional_libdir"; then
34600 if test -z "$haveit"; then
34601 if test -d "$additional_libdir"; then
34602 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir"
34609 dir=`echo "X$dep" | sed -e 's/^X-R//'`
34610 if test "$enable_rpath" != no; then
34612 for x in $rpathdirs; do
34613 if test "X$x" = "X$dir"; then
34618 if test -z "$haveit"; then
34619 rpathdirs="$rpathdirs $dir"
34622 for x in $ltrpathdirs; do
34623 if test "X$x" = "X$dir"; then
34628 if test -z "$haveit"; then
34629 ltrpathdirs="$ltrpathdirs $dir"
34634 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
34637 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
34640 LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
34641 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
34647 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
34648 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
34654 if test "X$rpathdirs" != "X"; then
34655 if test -n "$acl_hardcode_libdir_separator"; then
34657 for found_dir in $rpathdirs; do
34658 alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir"
34660 acl_save_libdir="$libdir"
34662 eval flag=\"$acl_hardcode_libdir_flag_spec\"
34663 libdir="$acl_save_libdir"
34664 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
34666 for found_dir in $rpathdirs; do
34667 acl_save_libdir="$libdir"
34668 libdir="$found_dir"
34669 eval flag=\"$acl_hardcode_libdir_flag_spec\"
34670 libdir="$acl_save_libdir"
34671 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
34675 if test "X$ltrpathdirs" != "X"; then
34676 for found_dir in $ltrpathdirs; do
34677 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
34692 am_save_CPPFLAGS="$CPPFLAGS"
34694 for element in $INCICONV; do
34696 for x in $CPPFLAGS; do
34698 acl_save_prefix="$prefix"
34699 prefix="$acl_final_prefix"
34700 acl_save_exec_prefix="$exec_prefix"
34701 exec_prefix="$acl_final_exec_prefix"
34703 exec_prefix="$acl_save_exec_prefix"
34704 prefix="$acl_save_prefix"
34706 if test "X$x" = "X$element"; then
34711 if test -z "$haveit"; then
34712 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
34717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
34718 $as_echo_n "checking for iconv... " >&6; }
34719 if ${am_cv_func_iconv+:} false; then :
34720 $as_echo_n "(cached) " >&6
34723 am_cv_func_iconv="no, consider installing GNU libiconv"
34725 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34726 /* end confdefs.h. */
34728 #include <stdlib.h>
34734 iconv_t cd = iconv_open("","");
34735 iconv(cd,NULL,NULL,NULL,NULL);
34741 if ac_fn_c_try_link "$LINENO"; then :
34742 am_cv_func_iconv=yes
34744 rm -f core conftest.err conftest.$ac_objext \
34745 conftest$ac_exeext conftest.$ac_ext
34746 if test "$am_cv_func_iconv" != yes; then
34747 am_save_LIBS="$LIBS"
34748 LIBS="$LIBS $LIBICONV"
34749 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34750 /* end confdefs.h. */
34752 #include <stdlib.h>
34758 iconv_t cd = iconv_open("","");
34759 iconv(cd,NULL,NULL,NULL,NULL);
34765 if ac_fn_c_try_link "$LINENO"; then :
34766 am_cv_lib_iconv=yes
34767 am_cv_func_iconv=yes
34769 rm -f core conftest.err conftest.$ac_objext \
34770 conftest$ac_exeext conftest.$ac_ext
34771 LIBS="$am_save_LIBS"
34775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
34776 $as_echo "$am_cv_func_iconv" >&6; }
34777 if test "$am_cv_func_iconv" = yes; then
34778 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
34779 $as_echo_n "checking for working iconv... " >&6; }
34780 if ${am_cv_func_iconv_works+:} false; then :
34781 $as_echo_n "(cached) " >&6
34784 am_save_LIBS="$LIBS"
34785 if test $am_cv_lib_iconv = yes; then
34786 LIBS="$LIBS $LIBICONV"
34788 if test "$cross_compiling" = yes; then :
34791 aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
34792 *) am_cv_func_iconv_works="guessing yes" ;;
34796 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34797 /* end confdefs.h. */
34800 #include <string.h>
34804 /* Test against AIX 5.1 bug: Failures are not distinguishable from successful
34807 iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
34808 if (cd_utf8_to_88591 != (iconv_t)(-1))
34810 static const char input[] = "\342\202\254"; /* EURO SIGN */
34812 const char *inptr = input;
34813 size_t inbytesleft = strlen (input);
34814 char *outptr = buf;
34815 size_t outbytesleft = sizeof (buf);
34816 size_t res = iconv (cd_utf8_to_88591,
34817 (char **) &inptr, &inbytesleft,
34818 &outptr, &outbytesleft);
34821 iconv_close (cd_utf8_to_88591);
34824 /* Test against Solaris 10 bug: Failures are not distinguishable from
34825 successful returns. */
34827 iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
34828 if (cd_ascii_to_88591 != (iconv_t)(-1))
34830 static const char input[] = "\263";
34832 const char *inptr = input;
34833 size_t inbytesleft = strlen (input);
34834 char *outptr = buf;
34835 size_t outbytesleft = sizeof (buf);
34836 size_t res = iconv (cd_ascii_to_88591,
34837 (char **) &inptr, &inbytesleft,
34838 &outptr, &outbytesleft);
34841 iconv_close (cd_ascii_to_88591);
34844 /* Test against AIX 6.1..7.1 bug: Buffer overrun. */
34846 iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1");
34847 if (cd_88591_to_utf8 != (iconv_t)(-1))
34849 static const char input[] = "\304";
34850 static char buf[2] = { (char)0xDE, (char)0xAD };
34851 const char *inptr = input;
34852 size_t inbytesleft = 1;
34853 char *outptr = buf;
34854 size_t outbytesleft = 1;
34855 size_t res = iconv (cd_88591_to_utf8,
34856 (char **) &inptr, &inbytesleft,
34857 &outptr, &outbytesleft);
34858 if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD)
34860 iconv_close (cd_88591_to_utf8);
34863 #if 0 /* This bug could be worked around by the caller. */
34864 /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */
34866 iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
34867 if (cd_88591_to_utf8 != (iconv_t)(-1))
34869 static const char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
34871 const char *inptr = input;
34872 size_t inbytesleft = strlen (input);
34873 char *outptr = buf;
34874 size_t outbytesleft = sizeof (buf);
34875 size_t res = iconv (cd_88591_to_utf8,
34876 (char **) &inptr, &inbytesleft,
34877 &outptr, &outbytesleft);
34880 iconv_close (cd_88591_to_utf8);
34884 /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
34886 if (/* Try standardized names. */
34887 iconv_open ("UTF-8", "EUC-JP") == (iconv_t)(-1)
34888 /* Try IRIX, OSF/1 names. */
34889 && iconv_open ("UTF-8", "eucJP") == (iconv_t)(-1)
34890 /* Try AIX names. */
34891 && iconv_open ("UTF-8", "IBM-eucJP") == (iconv_t)(-1)
34892 /* Try HP-UX names. */
34893 && iconv_open ("utf8", "eucJP") == (iconv_t)(-1))
34898 if ac_fn_c_try_run "$LINENO"; then :
34899 am_cv_func_iconv_works=yes
34901 am_cv_func_iconv_works=no
34903 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
34904 conftest.$ac_objext conftest.beam conftest.$ac_ext
34907 LIBS="$am_save_LIBS"
34910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5
34911 $as_echo "$am_cv_func_iconv_works" >&6; }
34912 case "$am_cv_func_iconv_works" in
34913 *no) am_func_iconv=no am_cv_lib_iconv=no ;;
34914 *) am_func_iconv=yes ;;
34917 am_func_iconv=no am_cv_lib_iconv=no
34919 if test "$am_func_iconv" = yes; then
34921 $as_echo "#define HAVE_ICONV 1" >>confdefs.h
34924 if test "$am_cv_lib_iconv" = yes; then
34925 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
34926 $as_echo_n "checking how to link with libiconv... " >&6; }
34927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
34928 $as_echo "$LIBICONV" >&6; }
34930 CPPFLAGS="$am_save_CPPFLAGS"
34937 if test "$am_cv_func_iconv" = yes; then
34938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv declaration" >&5
34939 $as_echo_n "checking for iconv declaration... " >&6; }
34940 if ${am_cv_proto_iconv+:} false; then :
34941 $as_echo_n "(cached) " >&6
34944 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34945 /* end confdefs.h. */
34947 #include <stdlib.h>
34953 #if defined(__STDC__) || defined(_MSC_VER) || defined(__cplusplus)
34954 size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
34967 if ac_fn_c_try_compile "$LINENO"; then :
34968 am_cv_proto_iconv_arg1=""
34970 am_cv_proto_iconv_arg1="const"
34972 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34973 am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);"
34976 am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
34977 { $as_echo "$as_me:${as_lineno-$LINENO}: result:
34978 $am_cv_proto_iconv" >&5
34980 $am_cv_proto_iconv" >&6; }
34982 cat >>confdefs.h <<_ACEOF
34983 #define ICONV_CONST $am_cv_proto_iconv_arg1
34989 for ac_header in iconv.h
34991 ac_fn_c_check_header_mongrel "$LINENO" "iconv.h" "ac_cv_header_iconv_h" "$ac_includes_default"
34992 if test "x$ac_cv_header_iconv_h" = xyes; then :
34993 cat >>confdefs.h <<_ACEOF
34994 #define HAVE_ICONV_H 1
35001 ac_fn_c_check_type "$LINENO" "iconv_t" "ac_cv_type_iconv_t" "
35002 #ifdef HAVE_ICONV_H
35003 # include <iconv.h>
35007 if test "x$ac_cv_type_iconv_t" = xyes; then :
35011 $as_echo "#define iconv_t int" >>confdefs.h
35018 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
35019 $as_echo_n "checking whether NLS is requested... " >&6; }
35020 # Check whether --enable-nls was given.
35021 if test "${enable_nls+set}" = set; then :
35022 enableval=$enable_nls; USE_NLS=$enableval
35027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
35028 $as_echo "$USE_NLS" >&6; }
35033 GETTEXT_MACRO_VERSION=0.18
35038 # Prepare PATH_SEPARATOR.
35039 # The user is always right.
35040 if test "${PATH_SEPARATOR+set}" != set; then
35041 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
35042 # contains only /bin. Note that ksh looks also at the FPATH variable,
35043 # so we have to set that as well for the test.
35045 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
35046 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
35047 || PATH_SEPARATOR=';'
35051 # Find out how to test for executable files. Don't use a zero-byte file,
35052 # as systems may use methods other than mode bits to determine executability.
35053 cat >conf$$.file <<_ASEOF
35057 chmod +x conf$$.file
35058 if test -x conf$$.file >/dev/null 2>&1; then
35059 ac_executable_p="test -x"
35061 ac_executable_p="test -f"
35065 # Extract the first word of "msgfmt", so it can be a program name with args.
35066 set dummy msgfmt; ac_word=$2
35067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35068 $as_echo_n "checking for $ac_word... " >&6; }
35069 if ${ac_cv_path_MSGFMT+:} false; then :
35070 $as_echo_n "(cached) " >&6
35074 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
35077 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
35078 for ac_dir in $PATH; do
35080 test -z "$ac_dir" && ac_dir=.
35081 for ac_exec_ext in '' $ac_executable_extensions; do
35082 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
35083 echo "$as_me: trying $ac_dir/$ac_word..." >&5
35084 if $ac_dir/$ac_word --statistics /dev/null >&5 2>&1 &&
35085 (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
35086 ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
35093 test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
35097 MSGFMT="$ac_cv_path_MSGFMT"
35098 if test "$MSGFMT" != ":"; then
35099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
35100 $as_echo "$MSGFMT" >&6; }
35102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35103 $as_echo "no" >&6; }
35106 # Extract the first word of "gmsgfmt", so it can be a program name with args.
35107 set dummy gmsgfmt; ac_word=$2
35108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35109 $as_echo_n "checking for $ac_word... " >&6; }
35110 if ${ac_cv_path_GMSGFMT+:} false; then :
35111 $as_echo_n "(cached) " >&6
35115 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
35118 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35119 for as_dir in $PATH
35122 test -z "$as_dir" && as_dir=.
35123 for ac_exec_ext in '' $ac_executable_extensions; do
35124 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35125 ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
35126 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35133 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
35137 GMSGFMT=$ac_cv_path_GMSGFMT
35138 if test -n "$GMSGFMT"; then
35139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
35140 $as_echo "$GMSGFMT" >&6; }
35142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35143 $as_echo "no" >&6; }
35148 case `$MSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
35149 '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) MSGFMT_015=: ;;
35150 *) MSGFMT_015=$MSGFMT ;;
35153 case `$GMSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
35154 '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) GMSGFMT_015=: ;;
35155 *) GMSGFMT_015=$GMSGFMT ;;
35160 # Prepare PATH_SEPARATOR.
35161 # The user is always right.
35162 if test "${PATH_SEPARATOR+set}" != set; then
35163 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
35164 # contains only /bin. Note that ksh looks also at the FPATH variable,
35165 # so we have to set that as well for the test.
35167 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
35168 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
35169 || PATH_SEPARATOR=';'
35173 # Find out how to test for executable files. Don't use a zero-byte file,
35174 # as systems may use methods other than mode bits to determine executability.
35175 cat >conf$$.file <<_ASEOF
35179 chmod +x conf$$.file
35180 if test -x conf$$.file >/dev/null 2>&1; then
35181 ac_executable_p="test -x"
35183 ac_executable_p="test -f"
35187 # Extract the first word of "xgettext", so it can be a program name with args.
35188 set dummy xgettext; ac_word=$2
35189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35190 $as_echo_n "checking for $ac_word... " >&6; }
35191 if ${ac_cv_path_XGETTEXT+:} false; then :
35192 $as_echo_n "(cached) " >&6
35194 case "$XGETTEXT" in
35196 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
35199 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
35200 for ac_dir in $PATH; do
35202 test -z "$ac_dir" && ac_dir=.
35203 for ac_exec_ext in '' $ac_executable_extensions; do
35204 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
35205 echo "$as_me: trying $ac_dir/$ac_word..." >&5
35206 if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >&5 2>&1 &&
35207 (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
35208 ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
35215 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
35219 XGETTEXT="$ac_cv_path_XGETTEXT"
35220 if test "$XGETTEXT" != ":"; then
35221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
35222 $as_echo "$XGETTEXT" >&6; }
35224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35225 $as_echo "no" >&6; }
35230 case `$XGETTEXT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
35231 '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) XGETTEXT_015=: ;;
35232 *) XGETTEXT_015=$XGETTEXT ;;
35237 # Prepare PATH_SEPARATOR.
35238 # The user is always right.
35239 if test "${PATH_SEPARATOR+set}" != set; then
35240 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
35241 # contains only /bin. Note that ksh looks also at the FPATH variable,
35242 # so we have to set that as well for the test.
35244 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
35245 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
35246 || PATH_SEPARATOR=';'
35250 # Find out how to test for executable files. Don't use a zero-byte file,
35251 # as systems may use methods other than mode bits to determine executability.
35252 cat >conf$$.file <<_ASEOF
35256 chmod +x conf$$.file
35257 if test -x conf$$.file >/dev/null 2>&1; then
35258 ac_executable_p="test -x"
35260 ac_executable_p="test -f"
35264 # Extract the first word of "msgmerge", so it can be a program name with args.
35265 set dummy msgmerge; ac_word=$2
35266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35267 $as_echo_n "checking for $ac_word... " >&6; }
35268 if ${ac_cv_path_MSGMERGE+:} false; then :
35269 $as_echo_n "(cached) " >&6
35271 case "$MSGMERGE" in
35273 ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
35276 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
35277 for ac_dir in $PATH; do
35279 test -z "$ac_dir" && ac_dir=.
35280 for ac_exec_ext in '' $ac_executable_extensions; do
35281 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
35282 echo "$as_me: trying $ac_dir/$ac_word..." >&5
35283 if $ac_dir/$ac_word --update -q /dev/null /dev/null >&5 2>&1; then
35284 ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
35291 test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
35295 MSGMERGE="$ac_cv_path_MSGMERGE"
35296 if test "$MSGMERGE" != ":"; then
35297 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
35298 $as_echo "$MSGMERGE" >&6; }
35300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35301 $as_echo "no" >&6; }
35305 test -n "$localedir" || localedir='${datadir}/locale'
35308 test -n "${XGETTEXT_EXTRA_OPTIONS+set}" || XGETTEXT_EXTRA_OPTIONS=
35311 ac_config_commands="$ac_config_commands po-directories"
35338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5
35339 $as_echo_n "checking for CFPreferencesCopyAppValue... " >&6; }
35340 if ${gt_cv_func_CFPreferencesCopyAppValue+:} false; then :
35341 $as_echo_n "(cached) " >&6
35343 gt_save_LIBS="$LIBS"
35344 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
35345 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35346 /* end confdefs.h. */
35347 #include <CoreFoundation/CFPreferences.h>
35351 CFPreferencesCopyAppValue(NULL, NULL)
35356 if ac_fn_c_try_link "$LINENO"; then :
35357 gt_cv_func_CFPreferencesCopyAppValue=yes
35359 gt_cv_func_CFPreferencesCopyAppValue=no
35361 rm -f core conftest.err conftest.$ac_objext \
35362 conftest$ac_exeext conftest.$ac_ext
35363 LIBS="$gt_save_LIBS"
35365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5
35366 $as_echo "$gt_cv_func_CFPreferencesCopyAppValue" >&6; }
35367 if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
35369 $as_echo "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h
35372 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyCurrent" >&5
35373 $as_echo_n "checking for CFLocaleCopyCurrent... " >&6; }
35374 if ${gt_cv_func_CFLocaleCopyCurrent+:} false; then :
35375 $as_echo_n "(cached) " >&6
35377 gt_save_LIBS="$LIBS"
35378 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
35379 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35380 /* end confdefs.h. */
35381 #include <CoreFoundation/CFLocale.h>
35385 CFLocaleCopyCurrent();
35390 if ac_fn_c_try_link "$LINENO"; then :
35391 gt_cv_func_CFLocaleCopyCurrent=yes
35393 gt_cv_func_CFLocaleCopyCurrent=no
35395 rm -f core conftest.err conftest.$ac_objext \
35396 conftest$ac_exeext conftest.$ac_ext
35397 LIBS="$gt_save_LIBS"
35399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyCurrent" >&5
35400 $as_echo "$gt_cv_func_CFLocaleCopyCurrent" >&6; }
35401 if test $gt_cv_func_CFLocaleCopyCurrent = yes; then
35403 $as_echo "#define HAVE_CFLOCALECOPYCURRENT 1" >>confdefs.h
35407 if test $gt_cv_func_CFPreferencesCopyAppValue = yes || test $gt_cv_func_CFLocaleCopyCurrent = yes; then
35408 INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation"
35420 case " $gt_needs " in
35421 *" need-formatstring-macros "*) gt_api_version=3 ;;
35422 *" need-ngettext "*) gt_api_version=2 ;;
35423 *) gt_api_version=1 ;;
35425 gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc"
35426 gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl"
35428 if test "$USE_NLS" = "yes"; then
35429 gt_use_preinstalled_gnugettext=no
35432 if test $gt_api_version -ge 3; then
35433 gt_revision_test_code='
35434 #ifndef __GNU_GETTEXT_SUPPORTED_REVISION
35435 #define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
35437 typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
35440 gt_revision_test_code=
35442 if test $gt_api_version -ge 2; then
35443 gt_expression_test_code=' + * ngettext ("", "", 0)'
35445 gt_expression_test_code=
35448 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5
35449 $as_echo_n "checking for GNU gettext in libc... " >&6; }
35450 if eval \${$gt_func_gnugettext_libc+:} false; then :
35451 $as_echo_n "(cached) " >&6
35453 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35454 /* end confdefs.h. */
35456 #include <libintl.h>
35457 $gt_revision_test_code
35458 extern int _nl_msg_cat_cntr;
35459 extern int *_nl_domain_bindings;
35465 bindtextdomain ("", "");
35466 return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_domain_bindings
35472 if ac_fn_c_try_link "$LINENO"; then :
35473 eval "$gt_func_gnugettext_libc=yes"
35475 eval "$gt_func_gnugettext_libc=no"
35477 rm -f core conftest.err conftest.$ac_objext \
35478 conftest$ac_exeext conftest.$ac_ext
35480 eval ac_res=\$$gt_func_gnugettext_libc
35481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
35482 $as_echo "$ac_res" >&6; }
35484 if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
35490 am_save_CPPFLAGS="$CPPFLAGS"
35492 for element in $INCICONV; do
35494 for x in $CPPFLAGS; do
35496 acl_save_prefix="$prefix"
35497 prefix="$acl_final_prefix"
35498 acl_save_exec_prefix="$exec_prefix"
35499 exec_prefix="$acl_final_exec_prefix"
35501 exec_prefix="$acl_save_exec_prefix"
35502 prefix="$acl_save_prefix"
35504 if test "X$x" = "X$element"; then
35509 if test -z "$haveit"; then
35510 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
35515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
35516 $as_echo_n "checking for iconv... " >&6; }
35517 if ${am_cv_func_iconv+:} false; then :
35518 $as_echo_n "(cached) " >&6
35521 am_cv_func_iconv="no, consider installing GNU libiconv"
35523 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35524 /* end confdefs.h. */
35526 #include <stdlib.h>
35532 iconv_t cd = iconv_open("","");
35533 iconv(cd,NULL,NULL,NULL,NULL);
35539 if ac_fn_c_try_link "$LINENO"; then :
35540 am_cv_func_iconv=yes
35542 rm -f core conftest.err conftest.$ac_objext \
35543 conftest$ac_exeext conftest.$ac_ext
35544 if test "$am_cv_func_iconv" != yes; then
35545 am_save_LIBS="$LIBS"
35546 LIBS="$LIBS $LIBICONV"
35547 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35548 /* end confdefs.h. */
35550 #include <stdlib.h>
35556 iconv_t cd = iconv_open("","");
35557 iconv(cd,NULL,NULL,NULL,NULL);
35563 if ac_fn_c_try_link "$LINENO"; then :
35564 am_cv_lib_iconv=yes
35565 am_cv_func_iconv=yes
35567 rm -f core conftest.err conftest.$ac_objext \
35568 conftest$ac_exeext conftest.$ac_ext
35569 LIBS="$am_save_LIBS"
35573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
35574 $as_echo "$am_cv_func_iconv" >&6; }
35575 if test "$am_cv_func_iconv" = yes; then
35576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
35577 $as_echo_n "checking for working iconv... " >&6; }
35578 if ${am_cv_func_iconv_works+:} false; then :
35579 $as_echo_n "(cached) " >&6
35582 am_save_LIBS="$LIBS"
35583 if test $am_cv_lib_iconv = yes; then
35584 LIBS="$LIBS $LIBICONV"
35586 if test "$cross_compiling" = yes; then :
35589 aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
35590 *) am_cv_func_iconv_works="guessing yes" ;;
35594 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35595 /* end confdefs.h. */
35598 #include <string.h>
35602 /* Test against AIX 5.1 bug: Failures are not distinguishable from successful
35605 iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
35606 if (cd_utf8_to_88591 != (iconv_t)(-1))
35608 static const char input[] = "\342\202\254"; /* EURO SIGN */
35610 const char *inptr = input;
35611 size_t inbytesleft = strlen (input);
35612 char *outptr = buf;
35613 size_t outbytesleft = sizeof (buf);
35614 size_t res = iconv (cd_utf8_to_88591,
35615 (char **) &inptr, &inbytesleft,
35616 &outptr, &outbytesleft);
35619 iconv_close (cd_utf8_to_88591);
35622 /* Test against Solaris 10 bug: Failures are not distinguishable from
35623 successful returns. */
35625 iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
35626 if (cd_ascii_to_88591 != (iconv_t)(-1))
35628 static const char input[] = "\263";
35630 const char *inptr = input;
35631 size_t inbytesleft = strlen (input);
35632 char *outptr = buf;
35633 size_t outbytesleft = sizeof (buf);
35634 size_t res = iconv (cd_ascii_to_88591,
35635 (char **) &inptr, &inbytesleft,
35636 &outptr, &outbytesleft);
35639 iconv_close (cd_ascii_to_88591);
35642 /* Test against AIX 6.1..7.1 bug: Buffer overrun. */
35644 iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1");
35645 if (cd_88591_to_utf8 != (iconv_t)(-1))
35647 static const char input[] = "\304";
35648 static char buf[2] = { (char)0xDE, (char)0xAD };
35649 const char *inptr = input;
35650 size_t inbytesleft = 1;
35651 char *outptr = buf;
35652 size_t outbytesleft = 1;
35653 size_t res = iconv (cd_88591_to_utf8,
35654 (char **) &inptr, &inbytesleft,
35655 &outptr, &outbytesleft);
35656 if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD)
35658 iconv_close (cd_88591_to_utf8);
35661 #if 0 /* This bug could be worked around by the caller. */
35662 /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */
35664 iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
35665 if (cd_88591_to_utf8 != (iconv_t)(-1))
35667 static const char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
35669 const char *inptr = input;
35670 size_t inbytesleft = strlen (input);
35671 char *outptr = buf;
35672 size_t outbytesleft = sizeof (buf);
35673 size_t res = iconv (cd_88591_to_utf8,
35674 (char **) &inptr, &inbytesleft,
35675 &outptr, &outbytesleft);
35678 iconv_close (cd_88591_to_utf8);
35682 /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
35684 if (/* Try standardized names. */
35685 iconv_open ("UTF-8", "EUC-JP") == (iconv_t)(-1)
35686 /* Try IRIX, OSF/1 names. */
35687 && iconv_open ("UTF-8", "eucJP") == (iconv_t)(-1)
35688 /* Try AIX names. */
35689 && iconv_open ("UTF-8", "IBM-eucJP") == (iconv_t)(-1)
35690 /* Try HP-UX names. */
35691 && iconv_open ("utf8", "eucJP") == (iconv_t)(-1))
35696 if ac_fn_c_try_run "$LINENO"; then :
35697 am_cv_func_iconv_works=yes
35699 am_cv_func_iconv_works=no
35701 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
35702 conftest.$ac_objext conftest.beam conftest.$ac_ext
35705 LIBS="$am_save_LIBS"
35708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5
35709 $as_echo "$am_cv_func_iconv_works" >&6; }
35710 case "$am_cv_func_iconv_works" in
35711 *no) am_func_iconv=no am_cv_lib_iconv=no ;;
35712 *) am_func_iconv=yes ;;
35715 am_func_iconv=no am_cv_lib_iconv=no
35717 if test "$am_func_iconv" = yes; then
35719 $as_echo "#define HAVE_ICONV 1" >>confdefs.h
35722 if test "$am_cv_lib_iconv" = yes; then
35723 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
35724 $as_echo_n "checking how to link with libiconv... " >&6; }
35725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
35726 $as_echo "$LIBICONV" >&6; }
35728 CPPFLAGS="$am_save_CPPFLAGS"
35745 acl_save_prefix="$prefix"
35746 prefix="$acl_final_prefix"
35747 acl_save_exec_prefix="$exec_prefix"
35748 exec_prefix="$acl_final_exec_prefix"
35750 eval additional_includedir=\"$includedir\"
35751 eval additional_libdir=\"$libdir\"
35753 exec_prefix="$acl_save_exec_prefix"
35754 prefix="$acl_save_prefix"
35757 # Check whether --with-libintl-prefix was given.
35758 if test "${with_libintl_prefix+set}" = set; then :
35759 withval=$with_libintl_prefix;
35760 if test "X$withval" = "Xno"; then
35763 if test "X$withval" = "X"; then
35765 acl_save_prefix="$prefix"
35766 prefix="$acl_final_prefix"
35767 acl_save_exec_prefix="$exec_prefix"
35768 exec_prefix="$acl_final_exec_prefix"
35770 eval additional_includedir=\"$includedir\"
35771 eval additional_libdir=\"$libdir\"
35773 exec_prefix="$acl_save_exec_prefix"
35774 prefix="$acl_save_prefix"
35777 additional_includedir="$withval/include"
35778 additional_libdir="$withval/$acl_libdirstem"
35779 if test "$acl_libdirstem2" != "$acl_libdirstem" \
35780 && ! test -d "$withval/$acl_libdirstem"; then
35781 additional_libdir="$withval/$acl_libdirstem2"
35795 names_already_handled=
35796 names_next_round='intl '
35797 while test -n "$names_next_round"; do
35798 names_this_round="$names_next_round"
35800 for name in $names_this_round; do
35802 for n in $names_already_handled; do
35803 if test "$n" = "$name"; then
35804 already_handled=yes
35808 if test -z "$already_handled"; then
35809 names_already_handled="$names_already_handled $name"
35810 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./+-|ABCDEFGHIJKLMNOPQRSTUVWXYZ____|'`
35811 eval value=\"\$HAVE_LIB$uppername\"
35812 if test -n "$value"; then
35813 if test "$value" = yes; then
35814 eval value=\"\$LIB$uppername\"
35815 test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value"
35816 eval value=\"\$LTLIB$uppername\"
35817 test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value"
35826 eval libname=\"$acl_libname_spec\" # typically: libname=lib$name
35827 if test -n "$acl_shlibext"; then
35828 shrext=".$acl_shlibext" # typically: shrext=.so
35832 if test $use_additional = yes; then
35833 dir="$additional_libdir"
35834 if test -n "$acl_shlibext"; then
35835 if test -f "$dir/$libname$shrext"; then
35837 found_so="$dir/$libname$shrext"
35839 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
35840 ver=`(cd "$dir" && \
35841 for f in "$libname$shrext".*; do echo "$f"; done \
35842 | sed -e "s,^$libname$shrext\\\\.,," \
35843 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
35844 | sed 1q ) 2>/dev/null`
35845 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
35847 found_so="$dir/$libname$shrext.$ver"
35850 eval library_names=\"$acl_library_names_spec\"
35851 for f in $library_names; do
35852 if test -f "$dir/$f"; then
35861 if test "X$found_dir" = "X"; then
35862 if test -f "$dir/$libname.$acl_libext"; then
35864 found_a="$dir/$libname.$acl_libext"
35867 if test "X$found_dir" != "X"; then
35868 if test -f "$dir/$libname.la"; then
35869 found_la="$dir/$libname.la"
35873 if test "X$found_dir" = "X"; then
35874 for x in $LDFLAGS $LTLIBINTL; do
35876 acl_save_prefix="$prefix"
35877 prefix="$acl_final_prefix"
35878 acl_save_exec_prefix="$exec_prefix"
35879 exec_prefix="$acl_final_exec_prefix"
35881 exec_prefix="$acl_save_exec_prefix"
35882 prefix="$acl_save_prefix"
35886 dir=`echo "X$x" | sed -e 's/^X-L//'`
35887 if test -n "$acl_shlibext"; then
35888 if test -f "$dir/$libname$shrext"; then
35890 found_so="$dir/$libname$shrext"
35892 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
35893 ver=`(cd "$dir" && \
35894 for f in "$libname$shrext".*; do echo "$f"; done \
35895 | sed -e "s,^$libname$shrext\\\\.,," \
35896 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
35897 | sed 1q ) 2>/dev/null`
35898 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
35900 found_so="$dir/$libname$shrext.$ver"
35903 eval library_names=\"$acl_library_names_spec\"
35904 for f in $library_names; do
35905 if test -f "$dir/$f"; then
35914 if test "X$found_dir" = "X"; then
35915 if test -f "$dir/$libname.$acl_libext"; then
35917 found_a="$dir/$libname.$acl_libext"
35920 if test "X$found_dir" != "X"; then
35921 if test -f "$dir/$libname.la"; then
35922 found_la="$dir/$libname.la"
35927 if test "X$found_dir" != "X"; then
35932 if test "X$found_dir" != "X"; then
35933 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name"
35934 if test "X$found_so" != "X"; then
35935 if test "$enable_rpath" = no \
35936 || test "X$found_dir" = "X/usr/$acl_libdirstem" \
35937 || test "X$found_dir" = "X/usr/$acl_libdirstem2"; then
35938 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
35941 for x in $ltrpathdirs; do
35942 if test "X$x" = "X$found_dir"; then
35947 if test -z "$haveit"; then
35948 ltrpathdirs="$ltrpathdirs $found_dir"
35950 if test "$acl_hardcode_direct" = yes; then
35951 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
35953 if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
35954 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
35956 for x in $rpathdirs; do
35957 if test "X$x" = "X$found_dir"; then
35962 if test -z "$haveit"; then
35963 rpathdirs="$rpathdirs $found_dir"
35967 for x in $LDFLAGS $LIBINTL; do
35969 acl_save_prefix="$prefix"
35970 prefix="$acl_final_prefix"
35971 acl_save_exec_prefix="$exec_prefix"
35972 exec_prefix="$acl_final_exec_prefix"
35974 exec_prefix="$acl_save_exec_prefix"
35975 prefix="$acl_save_prefix"
35977 if test "X$x" = "X-L$found_dir"; then
35982 if test -z "$haveit"; then
35983 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir"
35985 if test "$acl_hardcode_minus_L" != no; then
35986 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
35988 LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
35994 if test "X$found_a" != "X"; then
35995 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a"
35997 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name"
36000 additional_includedir=
36001 case "$found_dir" in
36002 */$acl_libdirstem | */$acl_libdirstem/)
36003 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
36004 if test "$name" = 'intl'; then
36005 LIBINTL_PREFIX="$basedir"
36007 additional_includedir="$basedir/include"
36009 */$acl_libdirstem2 | */$acl_libdirstem2/)
36010 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
36011 if test "$name" = 'intl'; then
36012 LIBINTL_PREFIX="$basedir"
36014 additional_includedir="$basedir/include"
36017 if test "X$additional_includedir" != "X"; then
36018 if test "X$additional_includedir" != "X/usr/include"; then
36020 if test "X$additional_includedir" = "X/usr/local/include"; then
36021 if test -n "$GCC"; then
36023 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
36027 if test -z "$haveit"; then
36028 for x in $CPPFLAGS $INCINTL; do
36030 acl_save_prefix="$prefix"
36031 prefix="$acl_final_prefix"
36032 acl_save_exec_prefix="$exec_prefix"
36033 exec_prefix="$acl_final_exec_prefix"
36035 exec_prefix="$acl_save_exec_prefix"
36036 prefix="$acl_save_prefix"
36038 if test "X$x" = "X-I$additional_includedir"; then
36043 if test -z "$haveit"; then
36044 if test -d "$additional_includedir"; then
36045 INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir"
36051 if test -n "$found_la"; then
36052 save_libdir="$libdir"
36053 case "$found_la" in
36054 */* | *\\*) . "$found_la" ;;
36055 *) . "./$found_la" ;;
36057 libdir="$save_libdir"
36058 for dep in $dependency_libs; do
36061 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
36062 if test "X$additional_libdir" != "X/usr/$acl_libdirstem" \
36063 && test "X$additional_libdir" != "X/usr/$acl_libdirstem2"; then
36065 if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem" \
36066 || test "X$additional_libdir" = "X/usr/local/$acl_libdirstem2"; then
36067 if test -n "$GCC"; then
36069 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
36073 if test -z "$haveit"; then
36075 for x in $LDFLAGS $LIBINTL; do
36077 acl_save_prefix="$prefix"
36078 prefix="$acl_final_prefix"
36079 acl_save_exec_prefix="$exec_prefix"
36080 exec_prefix="$acl_final_exec_prefix"
36082 exec_prefix="$acl_save_exec_prefix"
36083 prefix="$acl_save_prefix"
36085 if test "X$x" = "X-L$additional_libdir"; then
36090 if test -z "$haveit"; then
36091 if test -d "$additional_libdir"; then
36092 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir"
36096 for x in $LDFLAGS $LTLIBINTL; do
36098 acl_save_prefix="$prefix"
36099 prefix="$acl_final_prefix"
36100 acl_save_exec_prefix="$exec_prefix"
36101 exec_prefix="$acl_final_exec_prefix"
36103 exec_prefix="$acl_save_exec_prefix"
36104 prefix="$acl_save_prefix"
36106 if test "X$x" = "X-L$additional_libdir"; then
36111 if test -z "$haveit"; then
36112 if test -d "$additional_libdir"; then
36113 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir"
36120 dir=`echo "X$dep" | sed -e 's/^X-R//'`
36121 if test "$enable_rpath" != no; then
36123 for x in $rpathdirs; do
36124 if test "X$x" = "X$dir"; then
36129 if test -z "$haveit"; then
36130 rpathdirs="$rpathdirs $dir"
36133 for x in $ltrpathdirs; do
36134 if test "X$x" = "X$dir"; then
36139 if test -z "$haveit"; then
36140 ltrpathdirs="$ltrpathdirs $dir"
36145 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
36148 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
36151 LIBINTL="${LIBINTL}${LIBINTL:+ }$dep"
36152 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep"
36158 LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
36159 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name"
36165 if test "X$rpathdirs" != "X"; then
36166 if test -n "$acl_hardcode_libdir_separator"; then
36168 for found_dir in $rpathdirs; do
36169 alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir"
36171 acl_save_libdir="$libdir"
36173 eval flag=\"$acl_hardcode_libdir_flag_spec\"
36174 libdir="$acl_save_libdir"
36175 LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
36177 for found_dir in $rpathdirs; do
36178 acl_save_libdir="$libdir"
36179 libdir="$found_dir"
36180 eval flag=\"$acl_hardcode_libdir_flag_spec\"
36181 libdir="$acl_save_libdir"
36182 LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
36186 if test "X$ltrpathdirs" != "X"; then
36187 for found_dir in $ltrpathdirs; do
36188 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir"
36197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5
36198 $as_echo_n "checking for GNU gettext in libintl... " >&6; }
36199 if eval \${$gt_func_gnugettext_libintl+:} false; then :
36200 $as_echo_n "(cached) " >&6
36202 gt_save_CPPFLAGS="$CPPFLAGS"
36203 CPPFLAGS="$CPPFLAGS $INCINTL"
36204 gt_save_LIBS="$LIBS"
36205 LIBS="$LIBS $LIBINTL"
36206 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36207 /* end confdefs.h. */
36209 #include <libintl.h>
36210 $gt_revision_test_code
36211 extern int _nl_msg_cat_cntr;
36216 const char *_nl_expand_alias (const char *);
36222 bindtextdomain ("", "");
36223 return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_alias ("")
36229 if ac_fn_c_try_link "$LINENO"; then :
36230 eval "$gt_func_gnugettext_libintl=yes"
36232 eval "$gt_func_gnugettext_libintl=no"
36234 rm -f core conftest.err conftest.$ac_objext \
36235 conftest$ac_exeext conftest.$ac_ext
36236 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then
36237 LIBS="$LIBS $LIBICONV"
36238 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36239 /* end confdefs.h. */
36241 #include <libintl.h>
36242 $gt_revision_test_code
36243 extern int _nl_msg_cat_cntr;
36248 const char *_nl_expand_alias (const char *);
36254 bindtextdomain ("", "");
36255 return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_alias ("")
36261 if ac_fn_c_try_link "$LINENO"; then :
36262 LIBINTL="$LIBINTL $LIBICONV"
36263 LTLIBINTL="$LTLIBINTL $LTLIBICONV"
36264 eval "$gt_func_gnugettext_libintl=yes"
36267 rm -f core conftest.err conftest.$ac_objext \
36268 conftest$ac_exeext conftest.$ac_ext
36270 CPPFLAGS="$gt_save_CPPFLAGS"
36271 LIBS="$gt_save_LIBS"
36273 eval ac_res=\$$gt_func_gnugettext_libintl
36274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
36275 $as_echo "$ac_res" >&6; }
36278 if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \
36279 || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \
36280 && test "$PACKAGE" != gettext-runtime \
36281 && test "$PACKAGE" != gettext-tools; }; then
36282 gt_use_preinstalled_gnugettext=yes
36291 if test -n "$INTL_MACOSX_LIBS"; then
36292 if test "$gt_use_preinstalled_gnugettext" = "yes" \
36293 || test "$nls_cv_use_gnu_gettext" = "yes"; then
36294 LIBINTL="$LIBINTL $INTL_MACOSX_LIBS"
36295 LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS"
36299 if test "$gt_use_preinstalled_gnugettext" = "yes" \
36300 || test "$nls_cv_use_gnu_gettext" = "yes"; then
36302 $as_echo "#define ENABLE_NLS 1" >>confdefs.h
36309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5
36310 $as_echo_n "checking whether to use NLS... " >&6; }
36311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
36312 $as_echo "$USE_NLS" >&6; }
36313 if test "$USE_NLS" = "yes"; then
36314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5
36315 $as_echo_n "checking where the gettext function comes from... " >&6; }
36316 if test "$gt_use_preinstalled_gnugettext" = "yes"; then
36317 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
36318 gt_source="external libintl"
36323 gt_source="included intl directory"
36325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5
36326 $as_echo "$gt_source" >&6; }
36329 if test "$USE_NLS" = "yes"; then
36331 if test "$gt_use_preinstalled_gnugettext" = "yes"; then
36332 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
36333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5
36334 $as_echo_n "checking how to link with libintl... " >&6; }
36335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5
36336 $as_echo "$LIBINTL" >&6; }
36338 for element in $INCINTL; do
36340 for x in $CPPFLAGS; do
36342 acl_save_prefix="$prefix"
36343 prefix="$acl_final_prefix"
36344 acl_save_exec_prefix="$exec_prefix"
36345 exec_prefix="$acl_final_exec_prefix"
36347 exec_prefix="$acl_save_exec_prefix"
36348 prefix="$acl_save_prefix"
36350 if test "X$x" = "X$element"; then
36355 if test -z "$haveit"; then
36356 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
36363 $as_echo "#define HAVE_GETTEXT 1" >>confdefs.h
36366 $as_echo "#define HAVE_DCGETTEXT 1" >>confdefs.h
36375 INTLLIBS="$LIBINTL"
36384 # Initialize the test suite.
36385 ac_config_commands="$ac_config_commands tests/atconfig"
36387 ac_config_files="$ac_config_files tests/Makefile tests/atlocal"
36388 # FIXME: tests/preset?
36390 AUTOM4TE=${AUTOM4TE-"${am_missing_run}autom4te"}
36395 # Check whether --enable-backup-scripts was given.
36396 if test "${enable_backup_scripts+set}" = set; then :
36397 enableval=$enable_backup_scripts; case $enableval in
36398 yes) BACKUP_LIBEXEC_SCRIPTS='$(BACKUP_LIBEXEC_SCRIPTS_LIST)'
36399 BACKUP_SBIN_SCRIPTS='$(BACKUP_SBIN_SCRIPTS_LIST)'
36406 if date +%Y-%m-%d 2>/dev/null >&2; then
36407 BACKUP_SED_COND='/^\#ELSE_DATE_FORMAT_OK/,/^\#ENDIF_DATE_FORMAT_OK/d;/^\#IF_DATE_FORMAT_OK/d'
36409 BACKUP_SED_COND='/^\#IF_DATE_FORMAT_OK/,/^\#ELSE_DATE_FORMAT_OK/d;/^\#ENDIF_DATE_FORMAT_OK/d'
36412 ac_config_files="$ac_config_files Makefile doc/Makefile gnu/Makefile lib/Makefile po/Makefile.in scripts/Makefile rmt/Makefile src/Makefile"
36414 cat >confcache <<\_ACEOF
36415 # This file is a shell script that caches the results of configure
36416 # tests run on this system so they can be shared between configure
36417 # scripts and configure runs, see configure's option --config-cache.
36418 # It is not useful on other systems. If it contains results you don't
36419 # want to keep, you may remove or edit it.
36421 # config.status only pays attention to the cache file if you give it
36422 # the --recheck option to rerun configure.
36424 # `ac_cv_env_foo' variables (set or unset) will be overridden when
36425 # loading this file, other *unset* `ac_cv_foo' will be assigned the
36426 # following values.
36430 # The following way of writing the cache mishandles newlines in values,
36431 # but we know of no workaround that is simple, portable, and efficient.
36432 # So, we kill variables containing newlines.
36433 # Ultrix sh set writes to stderr and can't be redirected directly,
36434 # and sets the high bit in the cache file unless we assign to the vars.
36436 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
36437 eval ac_val=\$$ac_var
36441 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
36442 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
36445 _ | IFS | as_nl) ;; #(
36446 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
36447 *) { eval $ac_var=; unset $ac_var;} ;;
36453 case $as_nl`(ac_space=' '; set) 2>&1` in #(
36454 *${as_nl}ac_space=\ *)
36455 # `set' does not quote correctly, so add quotes: double-quote
36456 # substitution turns \\\\ into \\, and sed turns \\ into \.
36459 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
36462 # `set' quotes correctly as required by POSIX, so do not add quotes.
36463 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
36472 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
36474 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
36476 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
36477 if test -w "$cache_file"; then
36478 if test "x$cache_file" != "x/dev/null"; then
36479 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
36480 $as_echo "$as_me: updating cache $cache_file" >&6;}
36481 if test ! -f "$cache_file" || test -h "$cache_file"; then
36482 cat confcache >"$cache_file"
36484 case $cache_file in #(
36486 mv -f confcache "$cache_file"$$ &&
36487 mv -f "$cache_file"$$ "$cache_file" ;; #(
36489 mv -f confcache "$cache_file" ;;
36494 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
36495 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
36500 test "x$prefix" = xNONE && prefix=$ac_default_prefix
36501 # Let make expand exec_prefix.
36502 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
36504 DEFS=-DHAVE_CONFIG_H
36509 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
36510 # 1. Remove the extension, and $U if already installed.
36511 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
36512 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
36513 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
36514 # will be set to the directory where LIBOBJS objects are built.
36515 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
36516 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
36518 LIBOBJS=$ac_libobjs
36520 LTLIBOBJS=$ac_ltlibobjs
36523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
36524 $as_echo_n "checking that generated files are newer than configure... " >&6; }
36525 if test -n "$am_sleep_pid"; then
36526 # Hide warnings about reused PIDs.
36527 wait $am_sleep_pid 2>/dev/null
36529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
36530 $as_echo "done" >&6; }
36531 if test -n "$EXEEXT"; then
36533 am__EXEEXT_FALSE='#'
36535 am__EXEEXT_TRUE='#'
36539 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
36540 as_fn_error $? "conditional \"AMDEP\" was never defined.
36541 Usually this means the macro was only invoked conditionally." "$LINENO" 5
36543 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
36544 as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
36545 Usually this means the macro was only invoked conditionally." "$LINENO" 5
36547 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
36548 as_fn_error $? "conditional \"GL_COND_LIBTOOL\" was never defined.
36549 Usually this means the macro was only invoked conditionally." "$LINENO" 5
36551 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
36552 as_fn_error $? "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
36553 Usually this means the macro was only invoked conditionally." "$LINENO" 5
36555 if test -z "${GL_GENERATE_ERRNO_H_TRUE}" && test -z "${GL_GENERATE_ERRNO_H_FALSE}"; then
36556 as_fn_error $? "conditional \"GL_GENERATE_ERRNO_H\" was never defined.
36557 Usually this means the macro was only invoked conditionally." "$LINENO" 5
36559 if test -z "${GL_GENERATE_FLOAT_H_TRUE}" && test -z "${GL_GENERATE_FLOAT_H_FALSE}"; then
36560 as_fn_error $? "conditional \"GL_GENERATE_FLOAT_H\" was never defined.
36561 Usually this means the macro was only invoked conditionally." "$LINENO" 5
36563 if test -z "${GL_GENERATE_FNMATCH_H_TRUE}" && test -z "${GL_GENERATE_FNMATCH_H_FALSE}"; then
36564 as_fn_error $? "conditional \"GL_GENERATE_FNMATCH_H\" was never defined.
36565 Usually this means the macro was only invoked conditionally." "$LINENO" 5
36567 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
36568 as_fn_error $? "conditional \"GL_GENERATE_STDINT_H\" was never defined.
36569 Usually this means the macro was only invoked conditionally." "$LINENO" 5
36571 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
36572 as_fn_error $? "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
36573 Usually this means the macro was only invoked conditionally." "$LINENO" 5
36575 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
36576 as_fn_error $? "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
36577 Usually this means the macro was only invoked conditionally." "$LINENO" 5
36579 if test -z "${GL_GENERATE_SELINUX_CONTEXT_H_TRUE}" && test -z "${GL_GENERATE_SELINUX_CONTEXT_H_FALSE}"; then
36580 as_fn_error $? "conditional \"GL_GENERATE_SELINUX_CONTEXT_H\" was never defined.
36581 Usually this means the macro was only invoked conditionally." "$LINENO" 5
36583 if test -z "${GL_GENERATE_STDALIGN_H_TRUE}" && test -z "${GL_GENERATE_STDALIGN_H_FALSE}"; then
36584 as_fn_error $? "conditional \"GL_GENERATE_STDALIGN_H\" was never defined.
36585 Usually this means the macro was only invoked conditionally." "$LINENO" 5
36587 if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
36588 as_fn_error $? "conditional \"GL_GENERATE_STDARG_H\" was never defined.
36589 Usually this means the macro was only invoked conditionally." "$LINENO" 5
36591 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
36592 as_fn_error $? "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
36593 Usually this means the macro was only invoked conditionally." "$LINENO" 5
36595 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
36596 as_fn_error $? "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
36597 Usually this means the macro was only invoked conditionally." "$LINENO" 5
36599 if test -z "${GL_GENERATE_SYSEXITS_H_TRUE}" && test -z "${GL_GENERATE_SYSEXITS_H_FALSE}"; then
36600 as_fn_error $? "conditional \"GL_GENERATE_SYSEXITS_H\" was never defined.
36601 Usually this means the macro was only invoked conditionally." "$LINENO" 5
36603 if test -z "${LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_TRUE}" && test -z "${LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_FALSE}"; then
36604 as_fn_error $? "conditional \"LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH\" was never defined.
36605 Usually this means the macro was only invoked conditionally." "$LINENO" 5
36611 if test -n "$gl_LIBOBJS"; then
36612 # Remove the extension.
36613 sed_drop_objext='s/\.o$//;s/\.obj$//'
36614 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
36615 gl_libobjs="$gl_libobjs $i.$ac_objext"
36616 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
36619 gl_LIBOBJS=$gl_libobjs
36621 gl_LTLIBOBJS=$gl_ltlibobjs
36627 if test -n "$gltests_LIBOBJS"; then
36628 # Remove the extension.
36629 sed_drop_objext='s/\.o$//;s/\.obj$//'
36630 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
36631 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
36632 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
36635 gltests_LIBOBJS=$gltests_libobjs
36637 gltests_LTLIBOBJS=$gltests_ltlibobjs
36640 if test -z "${TAR_COND_XATTR_H_TRUE}" && test -z "${TAR_COND_XATTR_H_FALSE}"; then
36641 as_fn_error $? "conditional \"TAR_COND_XATTR_H\" was never defined.
36642 Usually this means the macro was only invoked conditionally." "$LINENO" 5
36645 : "${CONFIG_STATUS=./config.status}"
36647 ac_clean_files_save=$ac_clean_files
36648 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
36649 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
36650 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
36652 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
36654 # Generated by $as_me.
36655 # Run this file to recreate the current configuration.
36656 # Compiler output produced by configure, useful for debugging
36657 # configure, is in config.log if it exists.
36660 ac_cs_recheck=false
36663 SHELL=\${CONFIG_SHELL-$SHELL}
36666 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
36667 ## -------------------- ##
36668 ## M4sh Initialization. ##
36669 ## -------------------- ##
36671 # Be more Bourne compatible
36672 DUALCASE=1; export DUALCASE # for MKS sh
36673 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
36676 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
36677 # is contrary to our usage. Disable this feature.
36678 alias -g '${1+"$@"}'='"$@"'
36679 setopt NO_GLOB_SUBST
36681 case `(set -o) 2>/dev/null` in #(
36693 # Printing a long string crashes Solaris 7 /usr/bin/printf.
36694 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
36695 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
36696 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
36697 # Prefer a ksh shell builtin over an external printf program on Solaris,
36698 # but without wasting forks for bash or zsh.
36699 if test -z "$BASH_VERSION$ZSH_VERSION" \
36700 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
36701 as_echo='print -r --'
36702 as_echo_n='print -rn --'
36703 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
36704 as_echo='printf %s\n'
36705 as_echo_n='printf %s'
36707 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
36708 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
36709 as_echo_n='/usr/ucb/echo -n'
36711 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
36712 as_echo_n_body='eval
36716 expr "X$arg" : "X\\(.*\\)$as_nl";
36717 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
36719 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
36721 export as_echo_n_body
36722 as_echo_n='sh -c $as_echo_n_body as_echo'
36724 export as_echo_body
36725 as_echo='sh -c $as_echo_body as_echo'
36728 # The user is always right.
36729 if test "${PATH_SEPARATOR+set}" != set; then
36731 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
36732 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
36739 # We need space, tab and new line, in precisely that order. Quoting is
36740 # there to prevent editors from complaining about space-tab.
36741 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
36742 # splitting by setting IFS to empty value.)
36745 # Find who we are. Look in the path if we contain no directory separator.
36748 *[\\/]* ) as_myself=$0 ;;
36749 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36750 for as_dir in $PATH
36753 test -z "$as_dir" && as_dir=.
36754 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
36760 # We did not find ourselves, most probably we were run as `sh COMMAND'
36761 # in which case we are not to be found in the path.
36762 if test "x$as_myself" = x; then
36765 if test ! -f "$as_myself"; then
36766 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
36770 # Unset variables that we do not need and which cause bugs (e.g. in
36771 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
36772 # suppresses any "Segmentation fault" message there. '((' could
36773 # trigger a bug in pdksh 5.2.14.
36774 for as_var in BASH_ENV ENV MAIL MAILPATH
36775 do eval test x\${$as_var+set} = xset \
36776 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
36789 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
36792 # as_fn_error STATUS ERROR [LINENO LOG_FD]
36793 # ----------------------------------------
36794 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
36795 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
36796 # script with STATUS, using 1 if that was 0.
36799 as_status=$1; test $as_status -eq 0 && as_status=1
36801 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
36802 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
36804 $as_echo "$as_me: error: $2" >&2
36805 as_fn_exit $as_status
36809 # as_fn_set_status STATUS
36810 # -----------------------
36811 # Set $? to STATUS, without forking.
36812 as_fn_set_status ()
36815 } # as_fn_set_status
36817 # as_fn_exit STATUS
36818 # -----------------
36819 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
36823 as_fn_set_status $1
36829 # Portably unset VAR.
36832 { eval $1=; unset $1;}
36834 as_unset=as_fn_unset
36835 # as_fn_append VAR VALUE
36836 # ----------------------
36837 # Append the text in VALUE to the end of the definition contained in VAR. Take
36838 # advantage of any shell optimizations that allow amortized linear growth over
36839 # repeated appends, instead of the typical quadratic growth present in naive
36841 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
36842 eval 'as_fn_append ()
36853 # as_fn_arith ARG...
36854 # ------------------
36855 # Perform arithmetic evaluation on the ARGs, and store the result in the
36856 # global $as_val. Take advantage of shells that can avoid forks. The arguments
36857 # must be portable across $(()) and expr.
36858 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
36859 eval 'as_fn_arith ()
36866 as_val=`expr "$@" || test $? -eq 1`
36871 if expr a : '\(a\)' >/dev/null 2>&1 &&
36872 test "X`expr 00001 : '.*\(...\)'`" = X001; then
36878 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
36879 as_basename=basename
36884 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
36890 as_me=`$as_basename -- "$0" ||
36891 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
36892 X"$0" : 'X\(//\)$' \| \
36893 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
36895 sed '/^.*\/\([^/][^/]*\)\/*$/{
36909 # Avoid depending upon Character Ranges.
36910 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
36911 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
36912 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
36913 as_cr_digits='0123456789'
36914 as_cr_alnum=$as_cr_Letters$as_cr_digits
36916 ECHO_C= ECHO_N= ECHO_T=
36917 case `echo -n x` in #(((((
36919 case `echo 'xy\c'` in
36920 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
36922 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
36929 rm -f conf$$ conf$$.exe conf$$.file
36930 if test -d conf$$.dir; then
36931 rm -f conf$$.dir/conf$$.file
36934 mkdir conf$$.dir 2>/dev/null
36936 if (echo >conf$$.file) 2>/dev/null; then
36937 if ln -s conf$$.file conf$$ 2>/dev/null; then
36939 # ... but there are two gotchas:
36940 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
36941 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
36942 # In both cases, we have to default to `cp -pR'.
36943 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
36945 elif ln conf$$.file conf$$ 2>/dev/null; then
36953 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
36954 rmdir conf$$.dir 2>/dev/null
36959 # Create "$as_dir" as a directory, including parents if necessary.
36964 -*) as_dir=./$as_dir;;
36966 test -d "$as_dir" || eval $as_mkdir_p || {
36970 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
36971 *) as_qdir=$as_dir;;
36973 as_dirs="'$as_qdir' $as_dirs"
36974 as_dir=`$as_dirname -- "$as_dir" ||
36975 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
36976 X"$as_dir" : 'X\(//\)[^/]' \| \
36977 X"$as_dir" : 'X\(//\)$' \| \
36978 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
36979 $as_echo X"$as_dir" |
36980 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
36984 /^X\(\/\/\)[^/].*/{
36997 test -d "$as_dir" && break
36999 test -z "$as_dirs" || eval "mkdir $as_dirs"
37000 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
37004 if mkdir -p . 2>/dev/null; then
37005 as_mkdir_p='mkdir -p "$as_dir"'
37007 test -d ./-p && rmdir ./-p
37012 # as_fn_executable_p FILE
37013 # -----------------------
37014 # Test if FILE is an executable regular file.
37015 as_fn_executable_p ()
37017 test -f "$1" && test -x "$1"
37018 } # as_fn_executable_p
37019 as_test_x='test -x'
37020 as_executable_p=as_fn_executable_p
37022 # Sed expression to map a string onto a valid CPP name.
37023 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
37025 # Sed expression to map a string onto a valid variable name.
37026 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
37030 ## ----------------------------------- ##
37031 ## Main body of $CONFIG_STATUS script. ##
37032 ## ----------------------------------- ##
37034 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
37036 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
37037 # Save the log message, to keep $0 and so on meaningful, and to
37038 # report actual input values of CONFIG_FILES etc. instead of their
37039 # values after options handling.
37041 This file was extended by GNU tar $as_me 1.27.1, which was
37042 generated by GNU Autoconf 2.69. Invocation command line was
37044 CONFIG_FILES = $CONFIG_FILES
37045 CONFIG_HEADERS = $CONFIG_HEADERS
37046 CONFIG_LINKS = $CONFIG_LINKS
37047 CONFIG_COMMANDS = $CONFIG_COMMANDS
37050 on `(hostname || uname -n) 2>/dev/null | sed 1q`
37055 case $ac_config_files in *"
37056 "*) set x $ac_config_files; shift; ac_config_files=$*;;
37059 case $ac_config_headers in *"
37060 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
37064 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
37065 # Files that config.status was made for.
37066 config_files="$ac_config_files"
37067 config_headers="$ac_config_headers"
37068 config_commands="$ac_config_commands"
37072 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
37074 \`$as_me' instantiates files and other configuration actions
37075 from templates according to the current configuration. Unless the files
37076 and actions are specified as TAGs, all are instantiated by default.
37078 Usage: $0 [OPTION]... [TAG]...
37080 -h, --help print this help, then exit
37081 -V, --version print version number and configuration settings, then exit
37082 --config print configuration, then exit
37083 -q, --quiet, --silent
37084 do not print progress messages
37085 -d, --debug don't remove temporary files
37086 --recheck update $as_me by reconfiguring in the same conditions
37087 --file=FILE[:TEMPLATE]
37088 instantiate the configuration file FILE
37089 --header=FILE[:TEMPLATE]
37090 instantiate the configuration header FILE
37092 Configuration files:
37095 Configuration headers:
37098 Configuration commands:
37101 Report bugs to <bug-tar@gnu.org>.
37102 GNU tar home page: <http://www.gnu.org/software/tar/>.
37103 General help using GNU software: <http://www.gnu.org/gethelp/>."
37106 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
37107 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
37109 GNU tar config.status 1.27.1
37110 configured by $0, generated by GNU Autoconf 2.69,
37111 with options \\"\$ac_cs_config\\"
37113 Copyright (C) 2012 Free Software Foundation, Inc.
37114 This config.status script is free software; the Free Software Foundation
37115 gives unlimited permission to copy, distribute and modify it."
37122 test -n "\$AWK" || AWK=awk
37125 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
37126 # The default lists apply if the user does not specify any file.
37132 ac_option=`expr "X$1" : 'X\([^=]*\)='`
37133 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
37137 ac_option=`expr "X$1" : 'X\([^=]*\)='`
37149 # Handling of the options.
37150 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
37152 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
37153 $as_echo "$ac_cs_version"; exit ;;
37154 --config | --confi | --conf | --con | --co | --c )
37155 $as_echo "$ac_cs_config"; exit ;;
37156 --debug | --debu | --deb | --de | --d | -d )
37158 --file | --fil | --fi | --f )
37161 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
37162 '') as_fn_error $? "missing file argument" ;;
37164 as_fn_append CONFIG_FILES " '$ac_optarg'"
37165 ac_need_defaults=false;;
37166 --header | --heade | --head | --hea )
37169 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
37171 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
37172 ac_need_defaults=false;;
37174 # Conflict between --help and --header
37175 as_fn_error $? "ambiguous option: \`$1'
37176 Try \`$0 --help' for more information.";;
37177 --help | --hel | -h )
37178 $as_echo "$ac_cs_usage"; exit ;;
37179 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
37180 | -silent | --silent | --silen | --sile | --sil | --si | --s)
37183 # This is an error.
37184 -*) as_fn_error $? "unrecognized option: \`$1'
37185 Try \`$0 --help' for more information." ;;
37187 *) as_fn_append ac_config_targets " $1"
37188 ac_need_defaults=false ;;
37194 ac_configure_extra_args=
37196 if $ac_cs_silent; then
37198 ac_configure_extra_args="$ac_configure_extra_args --silent"
37202 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
37203 if \$ac_cs_recheck; then
37204 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
37206 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
37207 CONFIG_SHELL='$SHELL'
37208 export CONFIG_SHELL
37213 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
37217 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
37218 ## Running $as_me. ##
37224 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
37228 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
37229 # Capture the value of obsolete ALL_LINGUAS because we need it to compute
37230 # POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES, CATALOGS. But hide it
37231 # from automake < 1.5.
37232 eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
37233 # Capture the value of LINGUAS because we need it to compute CATALOGS.
37234 LINGUAS="${LINGUAS-%UNSET%}"
37240 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
37242 # Handling of arguments.
37243 for ac_config_target in $ac_config_targets
37245 case $ac_config_target in
37246 "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
37247 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
37248 "po-directories") CONFIG_COMMANDS="$CONFIG_COMMANDS po-directories" ;;
37249 "tests/atconfig") CONFIG_COMMANDS="$CONFIG_COMMANDS tests/atconfig" ;;
37250 "tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;;
37251 "tests/atlocal") CONFIG_FILES="$CONFIG_FILES tests/atlocal" ;;
37252 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
37253 "doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
37254 "gnu/Makefile") CONFIG_FILES="$CONFIG_FILES gnu/Makefile" ;;
37255 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
37256 "po/Makefile.in") CONFIG_FILES="$CONFIG_FILES po/Makefile.in" ;;
37257 "scripts/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/Makefile" ;;
37258 "rmt/Makefile") CONFIG_FILES="$CONFIG_FILES rmt/Makefile" ;;
37259 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
37261 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
37266 # If the user did not use the arguments to specify the items to instantiate,
37267 # then the envvar interface is used. Set only those that are not.
37268 # We use the long form for the default assignment because of an extremely
37269 # bizarre bug on SunOS 4.1.3.
37270 if $ac_need_defaults; then
37271 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
37272 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
37273 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
37276 # Have a temporary directory for convenience. Make it in the build tree
37277 # simply because there is no reason against having it here, and in addition,
37278 # creating and moving files from /tmp can sometimes cause problems.
37279 # Hook for its removal unless debugging.
37280 # Note that there is a small window in which the directory will not be cleaned:
37281 # after its creation but before its name has been assigned to `$tmp'.
37285 trap 'exit_status=$?
37286 : "${ac_tmp:=$tmp}"
37287 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
37289 trap 'as_fn_exit 1' 1 2 13 15
37291 # Create a (secure) tmp directory for tmp files.
37294 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
37298 tmp=./conf$$-$RANDOM
37299 (umask 077 && mkdir "$tmp")
37300 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
37303 # Set up the scripts for CONFIG_FILES section.
37304 # No need to generate them if there are no CONFIG_FILES.
37305 # This happens for instance with `./config.status config.h'.
37306 if test -n "$CONFIG_FILES"; then
37309 ac_cr=`echo X | tr X '\015'`
37310 # On cygwin, bash can eat \r inside `` if the user requested igncr.
37311 # But we know of no other shell where ac_cr would be empty at this
37312 # point, so we can use a bashism as a fallback.
37313 if test "x$ac_cr" = x; then
37314 eval ac_cr=\$\'\\r\'
37316 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
37317 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
37320 ac_cs_awk_cr=$ac_cr
37323 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
37328 echo "cat >conf$$subs.awk <<_ACEOF" &&
37329 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
37331 } >conf$$subs.sh ||
37332 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
37333 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
37335 for ac_last_try in false false false false false :; do
37336 . ./conf$$subs.sh ||
37337 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
37339 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
37340 if test $ac_delim_n = $ac_delim_num; then
37342 elif $ac_last_try; then
37343 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
37345 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
37348 rm -f conf$$subs.sh
37350 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
37351 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
37355 s/^/S["/; s/!.*/"]=/
37365 s/\(.\{148\}\)..*/\1/
37367 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
37372 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
37379 s/\(.\{148\}\)..*/\1/
37381 s/["\\]/\\&/g; s/^/"/; s/$/"/
37385 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
37390 ' <conf$$subs.awk | sed '
37395 ' >>$CONFIG_STATUS || ac_write_fail=1
37396 rm -f conf$$subs.awk
37397 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
37399 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
37400 for (key in S) S_is_set[key] = 1
37406 nfields = split(line, field, "@")
37408 len = length(field[1])
37409 for (i = 2; i < nfields; i++) {
37411 keylen = length(key)
37412 if (S_is_set[key]) {
37414 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
37415 len += length(value) + length(field[++i])
37426 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
37427 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
37428 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
37431 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
37432 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
37435 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
37436 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
37437 # trailing colons and then remove the whole line if VPATH becomes empty
37438 # (actually we leave an empty line to preserve line numbers).
37439 if test "x$srcdir" = x.; then
37440 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
37458 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
37459 fi # test -n "$CONFIG_FILES"
37461 # Set up the scripts for CONFIG_HEADERS section.
37462 # No need to generate them if there are no CONFIG_HEADERS.
37463 # This happens for instance with `./config.status Makefile'.
37464 if test -n "$CONFIG_HEADERS"; then
37465 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
37469 # Transform confdefs.h into an awk script `defines.awk', embedded as
37470 # here-document in config.status, that substitutes the proper values into
37471 # config.h.in to produce config.h.
37473 # Create a delimiter string that does not exist in confdefs.h, to ease
37474 # handling of long lines.
37476 for ac_last_try in false false :; do
37477 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
37478 if test -z "$ac_tt"; then
37480 elif $ac_last_try; then
37481 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
37483 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
37487 # For the awk script, D is an array of macro values keyed by name,
37488 # likewise P contains macro parameters if any. Preserve backslash
37489 # newline sequences.
37491 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
37493 s/.\{148\}/&'"$ac_delim"'/g
37496 s/^[ ]*#[ ]*define[ ][ ]*/ /
37503 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
37505 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
37509 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
37510 D["\1"]=" \3\\\\\\n"\\/p
37512 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
37517 s/.\{148\}/&'"$ac_delim"'/g
37522 s/["\\]/\\&/g; s/^/"/; s/$/"/p
37525 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
37527 ' <confdefs.h | sed '
37528 s/'"$ac_delim"'/"\\\
37529 "/g' >>$CONFIG_STATUS || ac_write_fail=1
37531 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
37532 for (key in D) D_is_set[key] = 1
37535 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
37537 split(line, arg, " ")
37538 if (arg[1] == "#") {
37542 defundef = substr(arg[1], 2)
37545 split(mac1, mac2, "(") #)
37547 prefix = substr(line, 1, index(line, defundef) - 1)
37548 if (D_is_set[macro]) {
37549 # Preserve the white space surrounding the "#".
37550 print prefix "define", macro P[macro] D[macro]
37553 # Replace #undef with comments. This is necessary, for example,
37554 # in the case of _POSIX_SOURCE, which is predefined and required
37555 # on some systems where configure will not decide to define it.
37556 if (defundef == "undef") {
37557 print "/*", prefix defundef, macro, "*/"
37565 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
37566 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
37567 fi # test -n "$CONFIG_HEADERS"
37570 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
37575 :[FHLC]) ac_mode=$ac_tag; continue;;
37577 case $ac_mode$ac_tag in
37579 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
37580 :[FH]-) ac_tag=-:-;;
37581 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
37598 -) ac_f="$ac_tmp/stdin";;
37599 *) # Look for the file first in the build tree, then in the source tree
37600 # (if the path is not absolute). The absolute path cannot be DOS-style,
37601 # because $ac_f cannot contain `:'.
37605 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
37607 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
37609 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
37610 as_fn_append ac_file_inputs " '$ac_f'"
37613 # Let's still pretend it is `configure' which instantiates (i.e., don't
37614 # use $as_me), people would be surprised to read:
37615 # /* config.h. Generated by config.status. */
37616 configure_input='Generated from '`
37617 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
37619 if test x"$ac_file" != x-; then
37620 configure_input="$ac_file. $configure_input"
37621 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
37622 $as_echo "$as_me: creating $ac_file" >&6;}
37624 # Neutralize special characters interpreted by sed in replacement strings.
37625 case $configure_input in #(
37626 *\&* | *\|* | *\\* )
37627 ac_sed_conf_input=`$as_echo "$configure_input" |
37628 sed 's/[\\\\&|]/\\\\&/g'`;; #(
37629 *) ac_sed_conf_input=$configure_input;;
37633 *:-:* | *:-) cat >"$ac_tmp/stdin" \
37634 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
37639 ac_dir=`$as_dirname -- "$ac_file" ||
37640 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
37641 X"$ac_file" : 'X\(//\)[^/]' \| \
37642 X"$ac_file" : 'X\(//\)$' \| \
37643 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
37644 $as_echo X"$ac_file" |
37645 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
37649 /^X\(\/\/\)[^/].*/{
37662 as_dir="$ac_dir"; as_fn_mkdir_p
37666 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
37668 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
37669 # A ".." for each directory in $ac_dir_suffix.
37670 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
37671 case $ac_top_builddir_sub in
37672 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
37673 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
37676 ac_abs_top_builddir=$ac_pwd
37677 ac_abs_builddir=$ac_pwd$ac_dir_suffix
37678 # for backward compatibility:
37679 ac_top_builddir=$ac_top_build_prefix
37682 .) # We are building in place.
37684 ac_top_srcdir=$ac_top_builddir_sub
37685 ac_abs_top_srcdir=$ac_pwd ;;
37686 [\\/]* | ?:[\\/]* ) # Absolute name.
37687 ac_srcdir=$srcdir$ac_dir_suffix;
37688 ac_top_srcdir=$srcdir
37689 ac_abs_top_srcdir=$srcdir ;;
37690 *) # Relative name.
37691 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
37692 ac_top_srcdir=$ac_top_build_prefix$srcdir
37693 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
37695 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
37705 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
37706 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
37708 ac_MKDIR_P=$MKDIR_P
37710 [\\/$]* | ?:[\\/]* ) ;;
37711 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
37715 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
37716 # If the template does not know about datarootdir, expand it.
37717 # FIXME: This hack should be removed a few years after 2.60.
37718 ac_datarootdir_hack=; ac_datarootdir_seen=
37729 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
37730 *datarootdir*) ac_datarootdir_seen=yes;;
37731 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
37732 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
37733 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
37735 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
37736 ac_datarootdir_hack='
37737 s&@datadir@&$datadir&g
37738 s&@docdir@&$docdir&g
37739 s&@infodir@&$infodir&g
37740 s&@localedir@&$localedir&g
37741 s&@mandir@&$mandir&g
37742 s&\\\${datarootdir}&$datarootdir&g' ;;
37746 # Neutralize VPATH when `$srcdir' = `.'.
37747 # Shell code in configure.ac might set extrasub.
37748 # FIXME: do we really want to maintain this feature?
37749 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
37750 ac_sed_extra="$ac_vpsub
37753 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
37755 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
37756 s|@configure_input@|$ac_sed_conf_input|;t t
37757 s&@top_builddir@&$ac_top_builddir_sub&;t t
37758 s&@top_build_prefix@&$ac_top_build_prefix&;t t
37759 s&@srcdir@&$ac_srcdir&;t t
37760 s&@abs_srcdir@&$ac_abs_srcdir&;t t
37761 s&@top_srcdir@&$ac_top_srcdir&;t t
37762 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
37763 s&@builddir@&$ac_builddir&;t t
37764 s&@abs_builddir@&$ac_abs_builddir&;t t
37765 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
37766 s&@INSTALL@&$ac_INSTALL&;t t
37767 s&@MKDIR_P@&$ac_MKDIR_P&;t t
37768 $ac_datarootdir_hack
37770 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
37771 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
37773 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
37774 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
37775 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
37776 "$ac_tmp/out"`; test -z "$ac_out"; } &&
37777 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
37778 which seems to be undefined. Please make sure it is defined" >&5
37779 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
37780 which seems to be undefined. Please make sure it is defined" >&2;}
37782 rm -f "$ac_tmp/stdin"
37784 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
37785 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
37787 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
37793 if test x"$ac_file" != x-; then
37795 $as_echo "/* $configure_input */" \
37796 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
37797 } >"$ac_tmp/config.h" \
37798 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
37799 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
37800 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
37801 $as_echo "$as_me: $ac_file is unchanged" >&6;}
37804 mv "$ac_tmp/config.h" "$ac_file" \
37805 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
37808 $as_echo "/* $configure_input */" \
37809 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
37810 || as_fn_error $? "could not create -" "$LINENO" 5
37812 # Compute "$ac_file"'s index in $config_headers.
37815 for _am_header in $config_headers :; do
37816 case $_am_header in
37817 $_am_arg | $_am_arg:* )
37820 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
37823 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
37824 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
37825 X"$_am_arg" : 'X\(//\)[^/]' \| \
37826 X"$_am_arg" : 'X\(//\)$' \| \
37827 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
37828 $as_echo X"$_am_arg" |
37829 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
37833 /^X\(\/\/\)[^/].*/{
37845 s/.*/./; q'`/stamp-h$_am_stamp_count
37848 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
37849 $as_echo "$as_me: executing $ac_file commands" >&6;}
37854 case $ac_file$ac_mode in
37855 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
37856 # Older Autoconf quotes --file arguments for eval, but not when files
37857 # are listed without --file. Let's play safe and only enable the eval
37858 # if we detect the quoting.
37859 case $CONFIG_FILES in
37860 *\'*) eval set x "$CONFIG_FILES" ;;
37861 *) set x $CONFIG_FILES ;;
37866 # Strip MF so we end up with the name of the file.
37867 mf=`echo "$mf" | sed -e 's/:.*$//'`
37868 # Check whether this is an Automake generated Makefile or not.
37869 # We used to match only the files named 'Makefile.in', but
37870 # some people rename them; so instead we look at the file content.
37871 # Grep'ing the first line is not enough: some people post-process
37872 # each Makefile.in and add a new line on top of each file to say so.
37873 # Grep'ing the whole file is not good either: AIX grep has a line
37874 # limit of 2048, but all sed's we know have understand at least 4000.
37875 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
37876 dirpart=`$as_dirname -- "$mf" ||
37877 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
37878 X"$mf" : 'X\(//\)[^/]' \| \
37879 X"$mf" : 'X\(//\)$' \| \
37880 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
37882 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
37886 /^X\(\/\/\)[^/].*/{
37902 # Extract the definition of DEPDIR, am__include, and am__quote
37903 # from the Makefile without running 'make'.
37904 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
37905 test -z "$DEPDIR" && continue
37906 am__include=`sed -n 's/^am__include = //p' < "$mf"`
37907 test -z "$am__include" && continue
37908 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
37909 # Find all dependency output files, they are included files with
37910 # $(DEPDIR) in their names. We invoke sed twice because it is the
37911 # simplest approach to changing $(DEPDIR) to its actual value in the
37913 for file in `sed -n "
37914 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
37915 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
37916 # Make sure the directory exists.
37917 test -f "$dirpart/$file" && continue
37918 fdir=`$as_dirname -- "$file" ||
37919 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
37920 X"$file" : 'X\(//\)[^/]' \| \
37921 X"$file" : 'X\(//\)$' \| \
37922 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
37923 $as_echo X"$file" |
37924 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
37928 /^X\(\/\/\)[^/].*/{
37941 as_dir=$dirpart/$fdir; as_fn_mkdir_p
37942 # echo "creating $dirpart/$file"
37943 echo '# dummy' > "$dirpart/$file"
37948 "po-directories":C)
37949 for ac_file in $CONFIG_FILES; do
37950 # Support "outfile[:infile[:infile...]]"
37952 *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
37954 # PO directories have a Makefile.in generated from Makefile.in.in.
37955 case "$ac_file" in */Makefile.in)
37956 # Adjust a relative srcdir.
37957 ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
37958 ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
37959 ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
37960 # In autoconf-2.13 it is called $ac_given_srcdir.
37961 # In autoconf-2.50 it is called $srcdir.
37962 test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
37963 case "$ac_given_srcdir" in
37964 .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
37965 /*) top_srcdir="$ac_given_srcdir" ;;
37966 *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
37968 # Treat a directory as a PO directory if and only if it has a
37969 # POTFILES.in file. This allows packages to have multiple PO
37970 # directories under different names or in different locations.
37971 if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
37972 rm -f "$ac_dir/POTFILES"
37973 test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
37974 gt_tab=`printf '\t'`
37975 cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ${gt_tab}]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
37976 POMAKEFILEDEPS="POTFILES.in"
37977 # ALL_LINGUAS, POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES depend
37978 # on $ac_dir but don't depend on user-specified configuration
37980 if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
37981 # The LINGUAS file contains the set of available languages.
37982 if test -n "$OBSOLETE_ALL_LINGUAS"; then
37983 test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete"
37985 ALL_LINGUAS_=`sed -e "/^#/d" -e "s/#.*//" "$ac_given_srcdir/$ac_dir/LINGUAS"`
37986 # Hide the ALL_LINGUAS assignment from automake < 1.5.
37987 eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
37988 POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
37990 # The set of available languages was given in configure.in.
37991 # Hide the ALL_LINGUAS assignment from automake < 1.5.
37992 eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
37995 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).po)
37996 # Compute UPDATEPOFILES
37997 # as $(foreach lang, $(ALL_LINGUAS), $(lang).po-update)
37998 # Compute DUMMYPOFILES
37999 # as $(foreach lang, $(ALL_LINGUAS), $(lang).nop)
38001 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).gmo)
38002 case "$ac_given_srcdir" in
38004 *) srcdirpre='$(srcdir)/' ;;
38010 for lang in $ALL_LINGUAS; do
38011 POFILES="$POFILES $srcdirpre$lang.po"
38012 UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
38013 DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
38014 GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
38016 # CATALOGS depends on both $ac_dir and the user's LINGUAS
38017 # environment variable.
38019 if test -n "$ALL_LINGUAS"; then
38020 for presentlang in $ALL_LINGUAS; do
38022 if test "%UNSET%" != "$LINGUAS"; then
38023 desiredlanguages="$LINGUAS"
38025 desiredlanguages="$ALL_LINGUAS"
38027 for desiredlang in $desiredlanguages; do
38028 # Use the presentlang catalog if desiredlang is
38029 # a. equal to presentlang, or
38030 # b. a variant of presentlang (because in this case,
38031 # presentlang can be used as a fallback for messages
38032 # which are not translated in the desiredlang catalog).
38033 case "$desiredlang" in
38034 "$presentlang"*) useit=yes;;
38037 if test $useit = yes; then
38038 INST_LINGUAS="$INST_LINGUAS $presentlang"
38043 if test -n "$INST_LINGUAS"; then
38044 for lang in $INST_LINGUAS; do
38045 CATALOGS="$CATALOGS $lang.gmo"
38048 test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
38049 sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
38050 for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
38051 if test -f "$f"; then
38053 *.orig | *.bak | *~) ;;
38054 *) cat "$f" >> "$ac_dir/Makefile" ;;
38062 "tests/atconfig":C) cat >tests/atconfig <<ATEOF
38063 # Configurable variable values for building test suites.
38065 # Copyright (C) 2012 Free Software Foundation, Inc.
38067 # The test suite will define top_srcdir=$at_top_srcdir/../.. etc.
38069 abs_builddir='$ac_abs_builddir'
38070 at_srcdir='$ac_srcdir'
38071 abs_srcdir='$ac_abs_srcdir'
38072 at_top_srcdir='$ac_top_srcdir'
38073 abs_top_srcdir='$ac_abs_top_srcdir'
38074 at_top_build_prefix='$ac_top_build_prefix'
38075 abs_top_builddir='$ac_abs_top_builddir'
38077 # Backward compatibility with Autotest <= 2.59b:
38078 at_top_builddir=\$at_top_build_prefix
38080 AUTOTEST_PATH='tests'
38082 SHELL=\${CONFIG_SHELL-'$SHELL'}
38092 ac_clean_files=$ac_clean_files_save
38094 test $ac_write_fail = 0 ||
38095 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
38098 # configure is writing to config.log, and then calls config.status.
38099 # config.status does its own redirection, appending to config.log.
38100 # Unfortunately, on DOS this fails, as config.log is still kept open
38101 # by configure, so config.status won't be able to write to it; its
38102 # output is simply discarded. So we exec the FD to /dev/null,
38103 # effectively closing config.log, so it can be properly (re)opened and
38104 # appended to by config.status. When coming back to configure, we
38105 # need to make the FD available again.
38106 if test "$no_create" != yes; then
38108 ac_config_status_args=
38109 test "$silent" = yes &&
38110 ac_config_status_args="$ac_config_status_args --quiet"
38112 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
38114 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
38115 # would make configure fail if this is the last instruction.
38116 $ac_cs_success || as_fn_exit 1
38118 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
38119 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
38120 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}