diff options
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 7621 |
1 files changed, 3762 insertions, 3859 deletions
@@ -1,13 +1,11 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.68 for GNU coreutils 8.21. +# Generated by GNU Autoconf 2.69 for GNU coreutils 8.23. # # Report bugs to <bug-coreutils@gnu.org>. # # -# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, -# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software -# Foundation, Inc. +# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. # # # This configure script is free software; the Free Software Foundation @@ -136,6 +134,31 @@ export LANGUAGE # CDPATH. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH +# Use a proper internal environment variable to ensure we don't fall + # into an infinite loop, continuously re-executing ourselves. + if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then + _as_can_reexec=no; export _as_can_reexec; + # We cannot yet assume a decent shell, so we have to provide a +# neutralization value for shells without unset; and this also +# works around shells that cannot unset nonexistent variables. +# Preserve -v and -x to the replacement shell. +BASH_ENV=/dev/null +ENV=/dev/null +(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV +case $- in # (((( + *v*x* | *x*v* ) as_opts=-vx ;; + *v* ) as_opts=-v ;; + *x* ) as_opts=-x ;; + * ) as_opts= ;; +esac +exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} +# Admittedly, this is quite paranoid, since all the known shells bail +# out after a failed `exec'. +$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 +as_fn_exit 255 + fi + # We don't want this to propagate to other subprocesses. + { _as_can_reexec=; unset _as_can_reexec;} if test "x$CONFIG_SHELL" = x; then as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : emulate sh @@ -169,7 +192,8 @@ if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : else exitcode=1; echo positional parameters were not saved. fi -test x\$exitcode = x0 || exit 1" +test x\$exitcode = x0 || exit 1 +test -x / || exit 1" as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && @@ -214,21 +238,25 @@ IFS=$as_save_IFS if test "x$CONFIG_SHELL" != x; then : - # We cannot yet assume a decent shell, so we have to provide a - # neutralization value for shells without unset; and this also - # works around shells that cannot unset nonexistent variables. - # Preserve -v and -x to the replacement shell. - BASH_ENV=/dev/null - ENV=/dev/null - (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV - export CONFIG_SHELL - case $- in # (((( - *v*x* | *x*v* ) as_opts=-vx ;; - *v* ) as_opts=-v ;; - *x* ) as_opts=-x ;; - * ) as_opts= ;; - esac - exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"} + export CONFIG_SHELL + # We cannot yet assume a decent shell, so we have to provide a +# neutralization value for shells without unset; and this also +# works around shells that cannot unset nonexistent variables. +# Preserve -v and -x to the replacement shell. +BASH_ENV=/dev/null +ENV=/dev/null +(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV +case $- in # (((( + *v*x* | *x*v* ) as_opts=-vx ;; + *v* ) as_opts=-v ;; + *x* ) as_opts=-x ;; + * ) as_opts= ;; +esac +exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} +# Admittedly, this is quite paranoid, since all the known shells bail +# out after a failed `exec'. +$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 +exit 255 fi if test x$as_have_required = xno; then : @@ -331,6 +359,14 @@ $as_echo X"$as_dir" | } # as_fn_mkdir_p + +# as_fn_executable_p FILE +# ----------------------- +# Test if FILE is an executable regular file. +as_fn_executable_p () +{ + test -f "$1" && test -x "$1" +} # as_fn_executable_p # as_fn_append VAR VALUE # ---------------------- # Append the text in VALUE to the end of the definition contained in VAR. Take @@ -452,6 +488,10 @@ as_cr_alnum=$as_cr_Letters$as_cr_digits chmod +x "$as_me.lineno" || { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } + # If we had to re-execute with $CONFIG_SHELL, we're ensured to have + # already done that, so ensure we don't try to do so again and fall + # in an infinite loop. This has already happened in practice. + _as_can_reexec=no; export _as_can_reexec # Don't try to exec as it changes $[0], causing all sort of problems # (the dirname of $[0] is not the place where we might find the # original and so on. Autoconf is especially sensitive to this). @@ -486,16 +526,16 @@ if (echo >conf$$.file) 2>/dev/null; then # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -p'. + # In both cases, we have to default to `cp -pR'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -p' + as_ln_s='cp -pR' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else - as_ln_s='cp -p' + as_ln_s='cp -pR' fi else - as_ln_s='cp -p' + as_ln_s='cp -pR' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null @@ -507,28 +547,8 @@ else as_mkdir_p=false fi -if test -x / >/dev/null 2>&1; then - as_test_x='test -x' -else - if ls -dL / >/dev/null 2>&1; then - as_ls_L_option=L - else - as_ls_L_option= - fi - as_test_x=' - eval sh -c '\'' - if test -d "$1"; then - test -d "$1/."; - else - case $1 in #( - -*)set "./$1";; - esac; - case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( - ???[sx]*):;;*)false;;esac;fi - '\'' sh - ' -fi -as_executable_p=$as_test_x +as_test_x='test -x' +as_executable_p=as_fn_executable_p # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" @@ -560,8 +580,8 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='GNU coreutils' PACKAGE_TARNAME='coreutils' -PACKAGE_VERSION='8.21' -PACKAGE_STRING='GNU coreutils 8.21' +PACKAGE_VERSION='8.23' +PACKAGE_STRING='GNU coreutils 8.23' PACKAGE_BUGREPORT='bug-coreutils@gnu.org' PACKAGE_URL='http://www.gnu.org/software/coreutils/' @@ -605,6 +625,8 @@ ac_includes_default="\ gl_use_threads_default= ac_header_list= ac_func_list= +with_openssl_default='no' +LIB_CRYPTO= gl_fnmatch_required=POSIX gl_getopt_required=POSIX gl_getopt_required=POSIX @@ -638,7 +660,14 @@ EXTRA_MANS man1_MANS pkglibexec_PROGRAMS bin_PROGRAMS +single_binary_install_type +single_binary_deps +single_binary_libs +single_binary_progs LIB_GMP +LIB_NVPAIR +SINGLE_BINARY_FALSE +SINGLE_BINARY_TRUE GNULIB_TEST_WARN_CFLAGS GNULIB_WARN_CFLAGS WARN_CFLAGS @@ -655,8 +684,6 @@ LIBCOREUTILS_LTLIBDEPS LIBCOREUTILS_LIBDEPS YIELD_LIB abs_aux_dir -POSIX_SPAWN_PORTED_FALSE -POSIX_SPAWN_PORTED_TRUE INTL_MACOSX_LIBS INET_PTON_LIB LOCALE_TR_UTF8 @@ -720,9 +747,7 @@ NEXT_STDARG_H GL_GENERATE_STDALIGN_H_FALSE GL_GENERATE_STDALIGN_H_TRUE STDALIGN_H -HAVE_SPAWN_H -NEXT_AS_FIRST_DIRECTIVE_SPAWN_H -NEXT_SPAWN_H +LIB_SMACK NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H NEXT_SIGNAL_H GL_GENERATE_SELINUX_CONTEXT_H_FALSE @@ -754,6 +779,8 @@ GNULIB_SIGPROCMASK GNULIB_SIGNAL_H_SIGPIPE GNULIB_RAISE GNULIB_PTHREAD_SIGMASK +USE_ACL +LIB_ACL LIB_PTHREAD GL_GENERATE_PTHREAD_H_FALSE GL_GENERATE_PTHREAD_H_TRUE @@ -764,34 +791,6 @@ HAVE_PTHREAD_SPINLOCK_T HAVE_PTHREAD_T HAVE_PTHREAD_H DEFAULT_POSIX2_VERSION -REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN -REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2 -REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE -REPLACE_POSIX_SPAWN -HAVE_POSIX_SPAWN_FILE_ACTIONS_T -HAVE_POSIX_SPAWNATTR_T -HAVE_POSIX_SPAWN -GNULIB_POSIX_SPAWNATTR_DESTROY -GNULIB_POSIX_SPAWNATTR_SETSIGMASK -GNULIB_POSIX_SPAWNATTR_GETSIGMASK -GNULIB_POSIX_SPAWNATTR_SETSIGDEFAULT -GNULIB_POSIX_SPAWNATTR_GETSIGDEFAULT -GNULIB_POSIX_SPAWNATTR_SETSCHEDPOLICY -GNULIB_POSIX_SPAWNATTR_GETSCHEDPOLICY -GNULIB_POSIX_SPAWNATTR_SETSCHEDPARAM -GNULIB_POSIX_SPAWNATTR_GETSCHEDPARAM -GNULIB_POSIX_SPAWNATTR_SETPGROUP -GNULIB_POSIX_SPAWNATTR_GETPGROUP -GNULIB_POSIX_SPAWNATTR_SETFLAGS -GNULIB_POSIX_SPAWNATTR_GETFLAGS -GNULIB_POSIX_SPAWNATTR_INIT -GNULIB_POSIX_SPAWN_FILE_ACTIONS_DESTROY -GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN -GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2 -GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE -GNULIB_POSIX_SPAWN_FILE_ACTIONS_INIT -GNULIB_POSIX_SPAWNP -GNULIB_POSIX_SPAWN PREFERABLY_POSIX_SHELL POSIX_SHELL PERL @@ -818,6 +817,8 @@ REPLACE_PSELECT HAVE_PSELECT GNULIB_SELECT GNULIB_PSELECT +REPLACE_LOCALTIME +REPLACE_GMTIME REPLACE_TIMEGM REPLACE_NANOSLEEP REPLACE_MKTIME @@ -909,6 +910,7 @@ LOCALE_ZH_CN LOCALE_JA NEXT_AS_FIRST_DIRECTIVE_MATH_H NEXT_MATH_H +SED LTLIBMULTITHREAD LIBMULTITHREAD LTLIBTHREAD @@ -971,6 +973,7 @@ PRIPTR_PREFIX PRI_MACROS_BROKEN INT64_MAX_EQ_LONG_MAX INT32_MAX_LT_INTMAX_MAX +REPLACE_STRTOUMAX REPLACE_STRTOIMAX HAVE_DECL_STRTOUMAX HAVE_DECL_STRTOIMAX @@ -1511,7 +1514,9 @@ NEXT_AS_FIRST_DIRECTIVE_CTYPE_H NEXT_CTYPE_H HAVE_ISBLANK GNULIB_ISBLANK +LIB_CRYPTO pkglibexecdir +runstatedir lispdir REPLACE_FDOPENDIR REPLACE_DIRFD @@ -1563,6 +1568,7 @@ REPLACE_ISATTY REPLACE_GETPAGESIZE REPLACE_GETGROUPS REPLACE_GETLOGIN_R +REPLACE_GETDTABLESIZE REPLACE_GETDOMAINNAME REPLACE_GETCWD REPLACE_FTRUNCATE @@ -1685,6 +1691,7 @@ HAVE_STRTOLL HAVE_STRTOD HAVE_DECL_SETENV HAVE_SETENV +HAVE_SECURE_GETENV HAVE_RPMATCH HAVE_REALPATH HAVE_RANDOM_R @@ -1712,6 +1719,7 @@ GNULIB_STRTOULL GNULIB_STRTOLL GNULIB_STRTOD GNULIB_SETENV +GNULIB_SECURE_GETENV GNULIB_RPMATCH GNULIB_REALPATH GNULIB_REALLOC_POSIX @@ -1845,8 +1853,6 @@ GL_GENERATE_ALLOCA_H_FALSE GL_GENERATE_ALLOCA_H_TRUE ALLOCA_H ALLOCA -USE_ACL -LIB_ACL GL_COND_LIBTOOL_FALSE GL_COND_LIBTOOL_TRUE host_os @@ -1953,14 +1959,16 @@ enable_silent_rules enable_dependency_tracking enable_largefile enable_threads -enable_acl enable_assert +with_openssl with_gnu_ld enable_rpath with_libiconv_prefix with_libpth_prefix +enable_acl with_included_regex with_selinux +enable_libsmack with_packager with_packager_version with_packager_bug_reports @@ -1968,6 +1976,8 @@ enable_xattr enable_libcap with_tty_group enable_gcc_warnings +enable_single_binary +enable_single_binary_exceptions with_gmp enable_install_program enable_no_install_program @@ -2441,8 +2451,6 @@ target=$target_alias if test "x$host_alias" != x; then if test "x$build_alias" = x; then cross_compiling=maybe - $as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host. - If a cross compiler is detected then cross compile mode will be used" >&2 elif test "x$build_alias" != "x$host_alias"; then cross_compiling=yes fi @@ -2528,7 +2536,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures GNU coreutils 8.21 to adapt to many kinds of systems. +\`configure' configures GNU coreutils 8.23 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -2598,7 +2606,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of GNU coreutils 8.21:";; + short | recursive ) echo "Configuration of GNU coreutils 8.23:";; esac cat <<\_ACEOF @@ -2606,32 +2614,48 @@ Optional Features: --disable-option-checking ignore unrecognized --enable/--with options --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) --enable-FEATURE[=ARG] include FEATURE [ARG=yes] - --enable-silent-rules less verbose build output (undo: `make V=1') - --disable-silent-rules verbose build output (undo: `make V=0') - --disable-dependency-tracking speeds up one-time build - --enable-dependency-tracking do not reject slow dependency extractors + --enable-silent-rules less verbose build output (undo: "make V=1") + --disable-silent-rules verbose build output (undo: "make V=0") + --enable-dependency-tracking + do not reject slow dependency extractors + --disable-dependency-tracking + speeds up one-time build --disable-largefile omit support for large files --enable-threads={posix|solaris|pth|windows} specify multithreading API --disable-threads build without multithread safety - --disable-acl do not support ACLs --disable-assert turn off assertions --disable-rpath do not hardcode runtime library paths + --disable-acl do not support ACLs + --disable-libsmack disable libsmack support --disable-xattr do not support extended attributes --disable-libcap disable libcap support --enable-gcc-warnings turn on many GCC warnings (for developers; best with GNU make) + --enable-single-binary=shebangs|symlinks + Compile all the tools in a single binary, reducing + the overall size. When compiled this way, shebangs + (default when enabled) or symlinks are installed for + each tool that points to the single binary. + --enable-single-binary-exceptions=PROG_LIST + When used with --enable-single-binary, exclude the + PROG_LIST from it, so these programs are compiled as + separated files (comma-separated, default none)) --enable-install-program=PROG_LIST install the programs in PROG_LIST (comma-separated, default: none) --enable-no-install-program=PROG_LIST do NOT install the programs in PROG_LIST - (comma-separated, default: arch,hostname) + (comma-separated, default: arch,coreutils,hostname) --disable-nls do not use Native Language Support Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) + --with-openssl use libcrypto hash routines. Valid ARGs are: 'yes', + 'no', 'auto' => use if available, 'optional' => use + if available and warn if not available; default is + 'no' --with-gnu-ld assume the C compiler uses GNU ld [default=no] --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib --without-libiconv-prefix don't search for libiconv in includedir and libdir @@ -2742,10 +2766,10 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -GNU coreutils configure 8.21 -generated by GNU Autoconf 2.68 +GNU coreutils configure 8.23 +generated by GNU Autoconf 2.69 -Copyright (C) 2010 Free Software Foundation, Inc. +Copyright (C) 2012 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. _ACEOF @@ -3022,7 +3046,7 @@ $as_echo "$ac_try_echo"; } >&5 test ! -s conftest.err } && test -s conftest$ac_exeext && { test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext + test -x conftest$ac_exeext }; then : ac_retval=0 else @@ -3041,6 +3065,60 @@ fi } # ac_fn_c_try_link +# ac_fn_c_check_type LINENO TYPE VAR INCLUDES +# ------------------------------------------- +# Tests whether TYPE exists after having included INCLUDES, setting cache +# variable VAR accordingly. +ac_fn_c_check_type () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + eval "$3=no" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +if (sizeof ($2)) + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +if (sizeof (($2))) + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + +else + eval "$3=yes" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_type + # ac_fn_c_check_func LINENO FUNC VAR # ---------------------------------- # Tests whether FUNC exists, setting the cache variable VAR accordingly @@ -3108,60 +3186,6 @@ $as_echo "$ac_res" >&6; } } # ac_fn_c_check_func -# ac_fn_c_check_type LINENO TYPE VAR INCLUDES -# ------------------------------------------- -# Tests whether TYPE exists after having included INCLUDES, setting cache -# variable VAR accordingly. -ac_fn_c_check_type () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -else - eval "$3=no" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -if (sizeof ($2)) - return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -if (sizeof (($2))) - return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - -else - eval "$3=yes" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - -} # ac_fn_c_check_type - # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES # --------------------------------------------- # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR @@ -3225,7 +3249,8 @@ int main () { static int test_array [1 - 2 * !(($2) >= 0)]; -test_array [0] = 0 +test_array [0] = 0; +return test_array [0]; ; return 0; @@ -3241,7 +3266,8 @@ int main () { static int test_array [1 - 2 * !(($2) <= $ac_mid)]; -test_array [0] = 0 +test_array [0] = 0; +return test_array [0]; ; return 0; @@ -3267,7 +3293,8 @@ int main () { static int test_array [1 - 2 * !(($2) < 0)]; -test_array [0] = 0 +test_array [0] = 0; +return test_array [0]; ; return 0; @@ -3283,7 +3310,8 @@ int main () { static int test_array [1 - 2 * !(($2) >= $ac_mid)]; -test_array [0] = 0 +test_array [0] = 0; +return test_array [0]; ; return 0; @@ -3317,7 +3345,8 @@ int main () { static int test_array [1 - 2 * !(($2) <= $ac_mid)]; -test_array [0] = 0 +test_array [0] = 0; +return test_array [0]; ; return 0; @@ -3446,8 +3475,8 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by GNU coreutils $as_me 8.21, which was -generated by GNU Autoconf 2.68. Invocation command line was +It was created by GNU coreutils $as_me 8.23, which was +generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ @@ -3742,6 +3771,7 @@ as_fn_append ac_header_list " sys/socket.h" as_fn_append ac_func_list " fchdir" as_fn_append ac_header_list " dirent.h" as_fn_append ac_func_list " fdopendir" +as_fn_append ac_func_list " getdtablesize" as_fn_append ac_func_list " faccessat" as_fn_append ac_func_list " posix_fadvise" as_fn_append ac_func_list " fchmodat" @@ -3758,14 +3788,12 @@ as_fn_append ac_func_list " wmempcpy" as_fn_append ac_header_list " wctype.h" gl_fnmatch_required=GNU as_fn_append ac_header_list " stdio_ext.h" -as_fn_append ac_func_list " __fpending" as_fn_append ac_func_list " fpurge" as_fn_append ac_func_list " __fpurge" as_fn_append ac_func_list " __freadahead" as_fn_append ac_func_list " __freading" as_fn_append ac_func_list " __freadptr" as_fn_append ac_func_list " __freadptrinc" -as_fn_append ac_func_list " alarm" as_fn_append ac_func_list " __fseterr" as_fn_append ac_header_list " sys/stat.h" as_fn_append ac_func_list " fstatat" @@ -3780,7 +3808,6 @@ as_fn_append ac_func_list " futimens" as_fn_append ac_header_list " netdb.h" as_fn_append ac_header_list " netinet/in.h" as_fn_append ac_func_list " getdelim" -as_fn_append ac_func_list " getdtablesize" as_fn_append ac_func_list " microuptime" as_fn_append ac_func_list " nanouptime" as_fn_append ac_func_list " getlogin" @@ -3825,8 +3852,7 @@ as_fn_append ac_func_list " mkstemp" as_fn_append ac_header_list " sys/statvfs.h" as_fn_append ac_header_list " sys/select.h" as_fn_append ac_func_list " nl_langinfo" -as_fn_append ac_func_list " pipe2" -as_fn_append ac_func_list " posix_spawn" +as_fn_append ac_func_list " pipe" gl_printf_safe=yes as_fn_append ac_header_list " priv.h" as_fn_append ac_header_list " pthread.h" @@ -3834,8 +3860,9 @@ as_fn_append ac_header_list " utmp.h" as_fn_append ac_header_list " utmpx.h" as_fn_append ac_func_list " utmpname" as_fn_append ac_func_list " utmpxname" -as_fn_append ac_func_list " wcscoll" +as_fn_append ac_header_list " malloc.h" as_fn_append ac_header_list " sched.h" +as_fn_append ac_func_list " secure_getenv" as_fn_append ac_header_list " selinux/selinux.h" as_fn_append ac_func_list " setenv" as_fn_append ac_func_list " settimeofday" @@ -3844,7 +3871,6 @@ as_fn_append ac_func_list " sigaction" as_fn_append ac_func_list " sigaltstack" as_fn_append ac_func_list " siginterrupt" as_fn_append ac_func_list " snprintf" -as_fn_append ac_header_list " spawn.h" as_fn_append ac_func_list " stpncpy" as_fn_append ac_func_list " strdup" as_fn_append ac_func_list " strerror_r" @@ -3859,7 +3885,6 @@ as_fn_append ac_header_list " sys/uio.h" as_fn_append ac_header_list " sys/utsname.h" as_fn_append ac_header_list " sys/wait.h" as_fn_append ac_func_list " localtime_r" -as_fn_append ac_func_list " pipe" as_fn_append ac_func_list " unlinkat" as_fn_append ac_header_list " utime.h" as_fn_append ac_func_list " futimes" @@ -3871,12 +3896,12 @@ as_fn_append ac_func_list " wcrtomb" as_fn_append ac_func_list " wcwidth" as_fn_append ac_func_list " wcswidth" as_fn_append ac_func_list " getegid" +as_fn_append ac_func_list " ttyname" as_fn_append ac_func_list " newlocale" as_fn_append ac_func_list " sleep" as_fn_append ac_func_list " catgets" as_fn_append ac_func_list " symlinkat" as_fn_append ac_func_list " shutdown" -as_fn_append ac_func_list " usleep" as_fn_append ac_func_list " wctob" as_fn_append ac_header_list " hurd.h" as_fn_append ac_header_list " paths.h" @@ -3900,6 +3925,7 @@ as_fn_append ac_func_list " getgrgid_nomembers" as_fn_append ac_func_list " getgrnam_nomembers" as_fn_append ac_func_list " getgrent_nomembers" as_fn_append ac_header_list " OS.h" +as_fn_append ac_header_list " gmp.h" gt_needs="$gt_needs need-formatstring-macros" # Check that the precious variables saved in the cache have kept the same # value. @@ -4004,7 +4030,7 @@ ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. ac_config_headers="$ac_config_headers lib/config.h:lib/config.hin" -am__api_version='1.11' +am__api_version='1.14' # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or @@ -4043,7 +4069,7 @@ case $as_dir/ in #(( # by default. for ac_prog in ginstall scoinst install; do for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then if test $ac_prog = install && grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # AIX install. It has an incompatible calling convention. @@ -4101,9 +4127,6 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 $as_echo_n "checking whether build environment is sane... " >&6; } -# Just in case -sleep 1 -echo timestamp > conftest.file # Reject unsafe characters in $srcdir or the absolute working directory # name. Accept space and tab only in the latter. am_lf=' @@ -4114,32 +4137,40 @@ case `pwd` in esac case $srcdir in *[\\\"\#\$\&\'\`$am_lf\ \ ]*) - as_fn_error $? "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;; + as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;; esac -# Do `set' in a subshell so we don't clobber the current shell's +# Do 'set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( - set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` - if test "$*" = "X"; then - # -L didn't work. - set X `ls -t "$srcdir/configure" conftest.file` - fi - rm -f conftest.file - if test "$*" != "X $srcdir/configure conftest.file" \ - && test "$*" != "X conftest.file $srcdir/configure"; then - - # If neither matched, then we have a broken ls. This can happen - # if, for instance, CONFIG_SHELL is bash and it inherits a - # broken ls alias from the environment. This has actually - # happened. Such a system could not be considered "sane". - as_fn_error $? "ls -t appears to fail. Make sure there is not a broken -alias in your environment" "$LINENO" 5 - fi - + am_has_slept=no + for am_try in 1 2; do + echo "timestamp, slept: $am_has_slept" > conftest.file + set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` + if test "$*" = "X"; then + # -L didn't work. + set X `ls -t "$srcdir/configure" conftest.file` + fi + if test "$*" != "X $srcdir/configure conftest.file" \ + && test "$*" != "X conftest.file $srcdir/configure"; then + + # If neither matched, then we have a broken ls. This can happen + # if, for instance, CONFIG_SHELL is bash and it inherits a + # broken ls alias from the environment. This has actually + # happened. Such a system could not be considered "sane". + as_fn_error $? "ls -t appears to fail. Make sure there is not a broken + alias in your environment" "$LINENO" 5 + fi + if test "$2" = conftest.file || test $am_try -eq 2; then + break + fi + # Just in case. + sleep 1 + am_has_slept=yes + done test "$2" = conftest.file ) then @@ -4151,6 +4182,16 @@ Check your system clock" "$LINENO" 5 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } +# If we didn't sleep, we still need to ensure time stamps of config.status and +# generated files are strictly newer. +am_sleep_pid= +if grep 'slept: no' conftest.file >/dev/null 2>&1; then + ( sleep 1 ) & + am_sleep_pid=$! +fi + +rm -f conftest.file + test "$program_prefix" != NONE && program_transform_name="s&^&$program_prefix&;$program_transform_name" # Use a double $ so make ignores it. @@ -4173,12 +4214,12 @@ if test x"${MISSING+set}" != xset; then esac fi # Use eval to expand $SHELL -if eval "$MISSING --run true"; then - am_missing_run="$MISSING --run " +if eval "$MISSING --is-lightweight"; then + am_missing_run="$MISSING " else am_missing_run= - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5 -$as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5 +$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;} fi if test x"${install_sh}" != xset; then @@ -4190,10 +4231,10 @@ if test x"${install_sh}" != xset; then esac fi -# Installed binaries are usually stripped using `strip' when the user -# run `make install-strip'. However `strip' might not be the right +# Installed binaries are usually stripped using 'strip' when the user +# run "make install-strip". However 'strip' might not be the right # tool to use in cross-compilation environments, therefore Automake -# will honor the `STRIP' environment variable to overrule this program. +# will honor the 'STRIP' environment variable to overrule this program. if test "$cross_compiling" != no; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. @@ -4212,7 +4253,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -4252,7 +4293,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_STRIP="strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -4303,7 +4344,7 @@ do test -z "$as_dir" && as_dir=. for ac_prog in mkdir gmkdir; do for ac_exec_ext in '' $ac_executable_extensions; do - { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue + as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( 'mkdir (GNU coreutils) '* | \ 'mkdir (coreutils) '* | \ @@ -4332,12 +4373,6 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 $as_echo "$MKDIR_P" >&6; } -mkdir_p="$MKDIR_P" -case $mkdir_p in - [\\/$]* | ?:[\\/]*) ;; - */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; -esac - for ac_prog in gawk mawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. @@ -4356,7 +4391,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_AWK="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -4420,6 +4455,45 @@ else fi rmdir .tst 2>/dev/null +# Check whether --enable-silent-rules was given. +if test "${enable_silent_rules+set}" = set; then : + enableval=$enable_silent_rules; +fi + +case $enable_silent_rules in # ((( + yes) AM_DEFAULT_VERBOSITY=0;; + no) AM_DEFAULT_VERBOSITY=1;; + *) AM_DEFAULT_VERBOSITY=1;; +esac +am_make=${MAKE-make} +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 +$as_echo_n "checking whether $am_make supports nested variables... " >&6; } +if ${am_cv_make_support_nested_variables+:} false; then : + $as_echo_n "(cached) " >&6 +else + if $as_echo 'TRUE=$(BAR$(V)) +BAR0=false +BAR1=true +V=1 +am__doit: + @$(TRUE) +.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then + am_cv_make_support_nested_variables=yes +else + am_cv_make_support_nested_variables=no +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 +$as_echo "$am_cv_make_support_nested_variables" >&6; } +if test $am_cv_make_support_nested_variables = yes; then + AM_V='$(V)' + AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' +else + AM_V=$AM_DEFAULT_VERBOSITY + AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY +fi +AM_BACKSLASH='\' + if test "`cd $srcdir && pwd`" != "`pwd`"; then # Use -I$(srcdir) only when $(srcdir) != ., so that make's output # is not polluted with repeated "-I." @@ -4442,7 +4516,7 @@ fi # Define the identity of the package. PACKAGE='coreutils' - VERSION='8.21' + VERSION='8.23' cat >>confdefs.h <<_ACEOF @@ -4470,27 +4544,79 @@ AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} +# For better backward compatibility. To be removed once Automake 1.9.x +# dies out for good. For more background, see: +# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html> +# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html> +mkdir_p='$(MKDIR_P)' + # We need awk for the "check" target. The system "awk" is bad on # some platforms. # Always define AMTAR for backward compatibility. Yes, it's still used # in the wild :-( We should find a proper way to deprecate it ... AMTAR='$${TAR-tar}' + +# We'll loop over all known methods to create a tar archive until one works. +_am_tools='gnutar pax cpio none' + am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -' + +# POSIX will say in a future version that running "rm -f" with no argument +# is OK; and we want to be able to make that assumption in our Makefile +# recipes. So use an aggressive probe to check that the usage we want is +# actually supported "in the wild" to an acceptable degree. +# See automake bug#10828. +# To make any issue more visible, cause the running configure to be aborted +# by default if the 'rm' program in use doesn't match our expectations; the +# user can still override this though. +if rm -f && rm -fr && rm -rf; then : OK; else + cat >&2 <<'END' +Oops! + +Your 'rm' program seems unable to run without file operands specified +on the command line, even when the '-f' option is present. This is contrary +to the behaviour of most rm programs out there, and not conforming with +the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542> + +Please tell bug-automake@gnu.org about your system, including the value +of your $PATH and any error possibly output before this message. This +can help us improve future automake versions. + +END + if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then + echo 'Configuration will proceed anyway, since you have set the' >&2 + echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 + echo >&2 + else + cat >&2 <<'END' +Aborting the configuration process, to ensure you take notice of the issue. + +You can download and install GNU coreutils to get an 'rm' implementation +that behaves properly: <http://www.gnu.org/software/coreutils/>. + +If you want to complete the configuration process using your problematic +'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM +to "yes", and re-run configure. + +END + as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5 + fi +fi # Check whether --enable-silent-rules was given. if test "${enable_silent_rules+set}" = set; then : enableval=$enable_silent_rules; fi -case $enable_silent_rules in -yes) AM_DEFAULT_VERBOSITY=0;; -no) AM_DEFAULT_VERBOSITY=1;; -*) AM_DEFAULT_VERBOSITY=0;; +case $enable_silent_rules in # ((( + yes) AM_DEFAULT_VERBOSITY=0;; + no) AM_DEFAULT_VERBOSITY=1;; + *) AM_DEFAULT_VERBOSITY=0;; esac am_make=${MAKE-make} { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 @@ -4546,7 +4672,7 @@ am__quote= _am_result=none # First try GNU make style include. echo "include confinc" > confmf -# Ignore all kinds of additional output from `make'. +# Ignore all kinds of additional output from 'make'. case `$am_make -s -f confmf 2> /dev/null` in #( *the\ am__doit\ target*) am__include=include @@ -4612,7 +4738,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -4652,7 +4778,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -4705,7 +4831,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}cc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -4746,7 +4872,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then ac_prog_rejected=yes continue @@ -4804,7 +4930,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -4848,7 +4974,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -5294,8 +5420,7 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <stdarg.h> #include <stdio.h> -#include <sys/types.h> -#include <sys/stat.h> +struct stat; /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ struct buf { int x; }; FILE * (*rcsopen) (struct buf *, struct stat *, int); @@ -5380,6 +5505,65 @@ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 +$as_echo_n "checking whether $CC understands -c and -o together... " >&6; } +if ${am_cv_prog_cc_c_o+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF + # Make sure it works both with $CC and with simple cc. + # Following AC_PROG_CC_C_O, we do the test twice because some + # compilers refuse to overwrite an existing .o file with -o, + # though they will create one. + am_cv_prog_cc_c_o=yes + for am_i in 1 2; do + if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5 + ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } \ + && test -f conftest2.$ac_objext; then + : OK + else + am_cv_prog_cc_c_o=no + break + fi + done + rm -f core conftest* + unset am_i +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 +$as_echo "$am_cv_prog_cc_c_o" >&6; } +if test "$am_cv_prog_cc_c_o" != yes; then + # Losing compiler, so override with the script. + # FIXME: It is wrong to rewrite CC. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__CC in this case, + # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" + CC="$am_aux_dir/compile $CC" +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + depcc="$CC" am_compiler_list= { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 @@ -5391,8 +5575,8 @@ else # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named `D' -- because `-MD' means `put the output - # in D'. + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". rm -rf conftest.dir mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're @@ -5427,16 +5611,16 @@ else : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with - # Solaris 8's {/usr,}/bin/sh. - touch sub/conftst$i.h + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf - # We check with `-c' and `-o' for the sake of the "dashmstdout" + # We check with '-c' and '-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly - # handle `-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. am__obj=sub/conftest.${OBJEXT-o} am__minus_obj="-o $am__obj" case $depmode in @@ -5445,8 +5629,8 @@ else test "$am__universal" = false || continue ;; nosideeffect) - # after this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. if test "x$enable_dependency_tracking" = xyes; then continue else @@ -5454,7 +5638,7 @@ else fi ;; msvc7 | msvc7msys | msvisualcpp | msvcmsys) - # This compiler won't grok `-c -o', but also, the minuso test has + # This compiler won't grok '-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. am__obj=conftest.${OBJEXT-o} @@ -5658,7 +5842,7 @@ main () return 0; } _ACEOF -for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99 +for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc99 do CC="$ac_save_CC $ac_arg" if ac_fn_c_try_compile "$LINENO"; then : @@ -5698,8 +5882,7 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <stdarg.h> #include <stdio.h> -#include <sys/types.h> -#include <sys/stat.h> +struct stat; /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ struct buf { int x; }; FILE * (*rcsopen) (struct buf *, struct stat *, int); @@ -5801,131 +5984,6 @@ $as_echo "none needed" >&6; } ;; #( $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;; esac -if test "x$CC" != xcc; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5 -$as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5 -$as_echo_n "checking whether cc understands -c and -o together... " >&6; } -fi -set dummy $CC; ac_cc=`$as_echo "$2" | - sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'` -if eval \${ac_cv_prog_cc_${ac_cc}_c_o+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -# Make sure it works both with $CC and with simple cc. -# We do the test twice because some compilers refuse to overwrite an -# existing .o file with -o, though they will create one. -ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5' -rm -f conftest2.* -if { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && - test -f conftest2.$ac_objext && { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; -then - eval ac_cv_prog_cc_${ac_cc}_c_o=yes - if test "x$CC" != xcc; then - # Test first that cc exists at all. - if { ac_try='cc -c conftest.$ac_ext >&5' - { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; }; then - ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5' - rm -f conftest2.* - if { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && - test -f conftest2.$ac_objext && { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; - then - # cc works too. - : - else - # cc exists but doesn't like -o. - eval ac_cv_prog_cc_${ac_cc}_c_o=no - fi - fi - fi -else - eval ac_cv_prog_cc_${ac_cc}_c_o=no -fi -rm -f core conftest* - -fi -if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - -$as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h - -fi - -# FIXME: we rely on the cache variable name because -# there is no other way. -set dummy $CC -am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'` -eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o -if test "$am_t" != yes; then - # Losing compiler, so override with the script. - # FIXME: It is wrong to rewrite CC. - # But if we don't then we get into trouble of one sort or another. - # A longer-term fix would be to have automake use am__CC in this case, - # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" - CC="$am_aux_dir/compile $CC" -fi - ac_ext=c ac_cpp='$CPP $CPPFLAGS' @@ -6082,7 +6140,7 @@ do for ac_prog in grep ggrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" - { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue + as_fn_executable_p "$ac_path_GREP" || continue # Check for GNU ac_path_GREP and select it if it is found. # Check for GNU $ac_path_GREP case `"$ac_path_GREP" --version 2>&1` in @@ -6148,7 +6206,7 @@ do for ac_prog in egrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" - { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue + as_fn_executable_p "$ac_path_EGREP" || continue # Check for GNU ac_path_EGREP and select it if it is found. # Check for GNU $ac_path_EGREP case `"$ac_path_EGREP" --version 2>&1` in @@ -6255,7 +6313,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -6295,7 +6353,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_RANLIB="ranlib" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -6393,7 +6451,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_AR="${ac_tool_prefix}ar" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -6433,7 +6491,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_AR="ar" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -6500,7 +6558,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -6540,7 +6598,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_RANLIB="ranlib" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -6780,8 +6838,6 @@ done - - ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default" if test "x$ac_cv_header_minix_config_h" = xyes; then : MINIX=yes @@ -6800,15 +6856,10 @@ $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h $as_echo "#define _MINIX 1" >>confdefs.h - fi - - case "$host_os" in - hpux*) -$as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h +$as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h - ;; - esac + fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 @@ -6851,6 +6902,54 @@ $as_echo "$ac_cv_safe_to_define___extensions__" >&6; } $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5 +$as_echo_n "checking whether _XOPEN_SOURCE should be defined... " >&6; } +if ${ac_cv_should_define__xopen_source+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_cv_should_define__xopen_source=no + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include <wchar.h> + mbstate_t x; +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #define _XOPEN_SOURCE 500 + #include <wchar.h> + mbstate_t x; +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_should_define__xopen_source=yes +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5 +$as_echo "$ac_cv_should_define__xopen_source" >&6; } + test $ac_cv_should_define__xopen_source = yes && + $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h + @@ -7208,6 +7307,7 @@ fi + # Code from module absolute-header: # Code from module accept: # Code from module accept-tests: # Code from module acl: @@ -7360,7 +7460,6 @@ $as_echo "$as_me: autobuild timestamp... $date" >&6;} # Code from module faccessat-tests: # Code from module fadvise: # Code from module fadvise-tests: - # Code from module fatal-signal: # Code from module fchdir: # Code from module fchdir-tests: # Code from module fchmodat: @@ -7676,28 +7775,9 @@ $as_echo "$as_me: autobuild timestamp... $date" >&6;} # Code from module perror: # Code from module perror-tests: # Code from module physmem: - # Code from module pipe: # Code from module pipe-posix: # Code from module pipe-posix-tests: - # Code from module pipe2: - # Code from module pipe2-safer: - # Code from module pipe2-tests: # Code from module posix-shell: - # Code from module posix_spawn-internal: - # Code from module posix_spawn_file_actions_addclose: - # Code from module posix_spawn_file_actions_addclose-tests: - # Code from module posix_spawn_file_actions_adddup2: - # Code from module posix_spawn_file_actions_adddup2-tests: - # Code from module posix_spawn_file_actions_addopen: - # Code from module posix_spawn_file_actions_addopen-tests: - # Code from module posix_spawn_file_actions_destroy: - # Code from module posix_spawn_file_actions_init: - # Code from module posix_spawnattr_destroy: - # Code from module posix_spawnattr_init: - # Code from module posix_spawnattr_setflags: - # Code from module posix_spawnattr_setsigmask: - # Code from module posix_spawnp: - # Code from module posix_spawnp-tests: # Code from module posixtm: # Code from module posixtm-tests: # Code from module posixver: @@ -7711,7 +7791,14 @@ $as_echo "$as_me: autobuild timestamp... $date" >&6;} # Code from module progname: # Code from module propername: # Code from module pthread: + +$as_echo "#define _REENTRANT 1" >>confdefs.h + + +$as_echo "#define _THREAD_SAFE 1" >>confdefs.h + # Code from module putenv: + # Code from module qacl: # Code from module quote: # Code from module quotearg: # Code from module quotearg-simple: @@ -7722,8 +7809,6 @@ $as_echo "$as_me: autobuild timestamp... $date" >&6;} # Code from module randperm: # Code from module randread: # Code from module randread-tests: - # Code from module rawmemchr: - # Code from module rawmemchr-tests: # Code from module read: # Code from module read-file: # Code from module read-file-tests: @@ -7761,6 +7846,7 @@ $as_echo "$as_me: autobuild timestamp... $date" >&6;} # Code from module savewd: # Code from module sched: # Code from module sched-tests: + # Code from module secure_getenv: # Code from module select: # Code from module select-tests: # Code from module selinux-at: @@ -7785,6 +7871,7 @@ $as_echo "$as_me: autobuild timestamp... $date" >&6;} # Code from module size_max: # Code from module sleep: # Code from module sleep-tests: + # Code from module smack: # Code from module snippet/_Noreturn: # Code from module snippet/arg-nonnull: # Code from module snippet/c++defs: @@ -7797,10 +7884,6 @@ $as_echo "$as_me: autobuild timestamp... $date" >&6;} # Code from module sockets: # Code from module sockets-tests: # Code from module socklen: - # Code from module spawn: - # Code from module spawn-pipe: - # Code from module spawn-pipe-tests: - # Code from module spawn-tests: # Code from module ssize_t: # Code from module stat: # Code from module stat-macros: @@ -7829,8 +7912,6 @@ $as_echo "$as_me: autobuild timestamp... $date" >&6;} # Code from module stdlib-tests: # Code from module stpcpy: # Code from module stpncpy: - # Code from module strchrnul: - # Code from module strchrnul-tests: # Code from module strdup-posix: # Code from module streq: # Code from module strerror: @@ -7942,8 +8023,6 @@ $as_echo "$as_me: autobuild timestamp... $date" >&6;} # Code from module useless-if-before-free: # Code from module userspec: # Code from module userspec-tests: - # Code from module usleep: - # Code from module usleep-tests: # Code from module utimecmp: # Code from module utimens: # Code from module utimens-tests: @@ -7967,8 +8046,6 @@ $as_echo "$as_me: autobuild timestamp... $date" >&6;} # Code from module vfprintf-posix-tests: # Code from module vprintf-posix: # Code from module vprintf-posix-tests: - # Code from module wait-process: - # Code from module waitpid: # Code from module warnings: # Code from module wchar: # Code from module wchar-tests: @@ -8139,8 +8216,8 @@ ALLOCA=\${LIBOBJDIR}alloca.$ac_objext $as_echo "#define C_ALLOCA 1" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether 'alloca.c' needs Cray hooks" >&5 -$as_echo_n "checking whether 'alloca.c' needs Cray hooks... " >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5 +$as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; } if ${ac_cv_os_cray+:} false; then : $as_echo_n "(cached) " >&6 else @@ -8410,7 +8487,7 @@ DIR *dp = opendir ("."); e = readdir (dp); if (! e) return 2; - if (stat (e->d_name, &st) != 0) + if (lstat (e->d_name, &st) != 0) return 3; if (e->d_ino != st.st_ino) return 4; @@ -8950,6 +9027,7 @@ $as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h GNULIB_REALLOC_POSIX=0; GNULIB_REALPATH=0; GNULIB_RPMATCH=0; + GNULIB_SECURE_GETENV=0; GNULIB_SETENV=0; GNULIB_STRTOD=0; GNULIB_STRTOLL=0; @@ -8977,6 +9055,7 @@ $as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h HAVE_RANDOM_R=1; HAVE_REALPATH=1; HAVE_RPMATCH=1; + HAVE_SECURE_GETENV=1; HAVE_SETENV=1; HAVE_DECL_SETENV=1; HAVE_STRTOD=1; @@ -9372,6 +9451,7 @@ $as_echo "#define FUNC_REALPATH_WORKS 1" >>confdefs.h REPLACE_FTRUNCATE=0; REPLACE_GETCWD=0; REPLACE_GETDOMAINNAME=0; + REPLACE_GETDTABLESIZE=0; REPLACE_GETLOGIN_R=0; REPLACE_GETGROUPS=0; REPLACE_GETPAGESIZE=0; @@ -10001,6 +10081,8 @@ $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5 $as_echo_n "checking if environ is properly declared... " >&6; } if ${gt_cv_var_environ_declaration+:} false; then : @@ -10142,36 +10224,40 @@ if ${gl_cv_next_errno_h+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <errno.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'errno.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_errno_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` - gl_header_literal_regex=`echo 'errno.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_errno_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + gl_header=$gl_cv_absolute_errno_h + gl_cv_next_errno_h='"'$gl_header'"' fi @@ -10586,23 +10672,6 @@ _ACEOF - - ac_fn_c_check_type "$LINENO" "sig_atomic_t" "ac_cv_type_sig_atomic_t" "#include <signal.h> -" -if test "x$ac_cv_type_sig_atomic_t" = xyes; then : - -cat >>confdefs.h <<_ACEOF -#define HAVE_SIG_ATOMIC_T 1 -_ACEOF - - -else - -$as_echo "#define sig_atomic_t int" >>confdefs.h - -fi - - ac_fn_c_check_decl "$LINENO" "fchdir" "ac_cv_have_decl_fchdir" "$ac_includes_default" if test "x$ac_cv_have_decl_fchdir" = xyes; then : ac_have_decl=1 @@ -11110,8 +11179,6 @@ $as_echo "#define mbstate_t int" >>confdefs.h - - GNULIB_ACOSF=0; GNULIB_ACOSL=0; GNULIB_ASINF=0; @@ -11398,7 +11465,16 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexp_no_libm" >&5 $as_echo "$gl_cv_func_frexp_no_libm" >&6; } +ac_fn_c_check_decl "$LINENO" "alarm" "ac_cv_have_decl_alarm" "$ac_includes_default" +if test "x$ac_cv_have_decl_alarm" = xyes; then : + ac_have_decl=1 +else + ac_have_decl=0 +fi +cat >>confdefs.h <<_ACEOF +#define HAVE_DECL_ALARM $ac_have_decl +_ACEOF { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether long double and double are the same" >&5 @@ -11550,36 +11626,40 @@ if ${gl_cv_next_sys_types_h+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <sys/types.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'sys/types.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' - gl_header_literal_regex=`echo 'sys/types.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_sys_types_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + gl_cv_absolute_sys_types_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_sys_types_h + gl_cv_next_sys_types_h='"'$gl_header'"' fi @@ -11680,7 +11760,7 @@ if ${gl_cv_func_fflush_stdin+:} false; then : else echo hello world > conftest.txt if test "$cross_compiling" = yes; then : - gl_cv_func_fflush_stdin=no + gl_cv_func_fflush_stdin=cross else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -11749,8 +11829,18 @@ fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fflush_stdin" >&5 $as_echo "$gl_cv_func_fflush_stdin" >&6; } + case $gl_cv_func_fflush_stdin in + yes) gl_func_fflush_stdin=1 ;; + no) gl_func_fflush_stdin=0 ;; + *) gl_func_fflush_stdin='(-1)' ;; + esac + +cat >>confdefs.h <<_ACEOF +#define FUNC_FFLUSH_STDIN $gl_func_fflush_stdin +_ACEOF - if test $gl_cv_func_fflush_stdin = no; then + + if test $gl_cv_func_fflush_stdin != yes; then REPLACE_FSEEKO=1 fi @@ -11828,36 +11918,40 @@ else if test $ac_cv_header_sys_stat_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <sys/stat.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'sys/stat.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'sys/stat.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_sys_stat_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_sys_stat_h + gl_cv_next_sys_stat_h='"'$gl_header'"' else gl_cv_next_sys_stat_h='<'sys/stat.h'>' fi @@ -12299,36 +12393,40 @@ else if test $ac_cv_header_sys_socket_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <sys/socket.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'sys/socket.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_sys_socket_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'sys/socket.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_sys_socket_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_sys_socket_h + gl_cv_next_sys_socket_h='"'$gl_header'"' else gl_cv_next_sys_socket_h='<'sys/socket.h'>' fi @@ -12505,36 +12603,40 @@ else if test $ac_cv_header_netdb_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <netdb.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'netdb.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_netdb_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'netdb.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_netdb_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_netdb_h + gl_cv_next_netdb_h='"'$gl_header'"' else gl_cv_next_netdb_h='<'netdb.h'>' fi @@ -13184,8 +13286,6 @@ _ACEOF - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for arithmetic hrtime_t" >&5 $as_echo_n "checking for arithmetic hrtime_t... " >&6; } if ${gl_cv_arithmetic_hrtime_t+:} false; then : @@ -13419,36 +13519,40 @@ else if test $ac_cv_header_getopt_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <getopt.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'getopt.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'getopt.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_getopt_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_getopt_h + gl_cv_next_getopt_h='"'$gl_header'"' else gl_cv_next_getopt_h='<'getopt.h'>' fi @@ -14136,36 +14240,40 @@ else if test $ac_cv_header_sys_time_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <sys/time.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'sys/time.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_sys_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'sys/time.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_sys_time_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_sys_time_h + gl_cv_next_sys_time_h='"'$gl_header'"' else gl_cv_next_sys_time_h='<'sys/time.h'>' fi @@ -15489,36 +15597,40 @@ else if test $ac_cv_header_stdint_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <stdint.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'stdint.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'stdint.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_stdint_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_stdint_h + gl_cv_next_stdint_h='"'$gl_header'"' else gl_cv_next_stdint_h='<'stdint.h'>' fi @@ -16166,6 +16278,7 @@ fi HAVE_DECL_STRTOIMAX=1; HAVE_DECL_STRTOUMAX=1; REPLACE_STRTOIMAX=0; + REPLACE_STRTOUMAX=0; INT32_MAX_LT_INTMAX_MAX=1; INT64_MAX_EQ_LONG_MAX='defined _LP64'; PRI_MACROS_BROKEN=0; @@ -16199,36 +16312,40 @@ else if test $ac_cv_header_inttypes_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <inttypes.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'inttypes.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'inttypes.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_inttypes_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_inttypes_h + gl_cv_next_inttypes_h='"'$gl_header'"' else gl_cv_next_inttypes_h='<'inttypes.h'>' fi @@ -16866,36 +16983,40 @@ else if test $ac_cv_header_wctype_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <wctype.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'wctype.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_wctype_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'wctype.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_wctype_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_wctype_h + gl_cv_next_wctype_h='"'$gl_header'"' else gl_cv_next_wctype_h='<'wctype.h'>' fi @@ -17308,36 +17429,40 @@ if ${gl_cv_next_stddef_h+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <stddef.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'stddef.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' - gl_header_literal_regex=`echo 'stddef.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + gl_cv_absolute_stddef_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_stddef_h + gl_cv_next_stddef_h='"'$gl_header'"' fi @@ -18269,6 +18394,75 @@ $as_echo "$gl_threads_api" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 +$as_echo_n "checking for a sed that does not truncate output... " >&6; } +if ${ac_cv_path_SED+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ + for ac_i in 1 2 3 4 5 6 7; do + ac_script="$ac_script$as_nl$ac_script" + done + echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed + { ac_script=; unset ac_script;} + if test -z "$SED"; then + ac_path_SED_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in sed gsed; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_SED" || continue +# Check for GNU ac_path_SED and select it if it is found. + # Check for GNU $ac_path_SED +case `"$ac_path_SED" --version 2>&1` in +*GNU*) + ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo '' >> "conftest.nl" + "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_SED_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_SED="$ac_path_SED" + ac_path_SED_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_SED_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_SED"; then + as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 + fi +else + ac_cv_path_SED=$SED +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 +$as_echo "$ac_cv_path_SED" >&6; } + SED="$ac_cv_path_SED" + rm -f conftest.sed + for ac_header in stdlib.h @@ -19275,6 +19469,49 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_nul_retval" >&5 $as_echo "$gl_cv_func_mbrtowc_nul_retval" >&6; } + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works on empty input" >&5 +$as_echo_n "checking whether mbrtowc works on empty input... " >&6; } +if ${gl_cv_func_mbrtowc_empty_input+:} false; then : + $as_echo_n "(cached) " >&6 +else + + case "$host_os" in + # Guess no on AIX and glibc systems. + aix* | *-gnu*) + gl_cv_func_mbrtowc_empty_input="guessing no" ;; + *) gl_cv_func_mbrtowc_empty_input="guessing yes" ;; + esac + if test "$cross_compiling" = yes; then : + : +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include <wchar.h> + static wchar_t wc; + static mbstate_t mbs; + int + main (void) + { + return mbrtowc (&wc, "", 0, &mbs) == (size_t) -2; + } +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + gl_cv_func_mbrtowc_empty_input=no +else + gl_cv_func_mbrtowc_empty_input=yes +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_empty_input" >&5 +$as_echo "$gl_cv_func_mbrtowc_empty_input" >&6; } + case "$gl_cv_func_mbrtowc_null_arg1" in *yes) ;; *) @@ -19307,6 +19544,14 @@ $as_echo "#define MBRTOWC_NUL_RETVAL_BUG 1" >>confdefs.h REPLACE_MBRTOWC=1 ;; esac + case "$gl_cv_func_mbrtowc_empty_input" in + *yes) ;; + *) +$as_echo "#define MBRTOWC_EMPTY_INPUT_BUG 1" >>confdefs.h + + REPLACE_MBRTOWC=1 + ;; + esac fi fi @@ -19588,6 +19833,10 @@ _ACEOF REPLACE_NANOSLEEP=GNULIB_PORTCHECK; REPLACE_TIMEGM=GNULIB_PORTCHECK; + : ${GNULIB_GETTIMEOFDAY=0}; + REPLACE_GMTIME=0; + REPLACE_LOCALTIME=0; + @@ -19704,36 +19953,40 @@ else if test $ac_cv_header_sys_select_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <sys/select.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'sys/select.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'sys/select.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_sys_select_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_sys_select_h + gl_cv_next_sys_select_h='"'$gl_header'"' else gl_cv_next_sys_select_h='<'sys/select.h'>' fi @@ -20371,454 +20624,6 @@ $as_echo "#define HAVE__SYSTEM_CONFIGURATION 1" >>confdefs.h - GNULIB_POSIX_SPAWN=0; - GNULIB_POSIX_SPAWNP=0; - GNULIB_POSIX_SPAWN_FILE_ACTIONS_INIT=0; - GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE=0; - GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2=0; - GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN=0; - GNULIB_POSIX_SPAWN_FILE_ACTIONS_DESTROY=0; - GNULIB_POSIX_SPAWNATTR_INIT=0; - GNULIB_POSIX_SPAWNATTR_GETFLAGS=0; - GNULIB_POSIX_SPAWNATTR_SETFLAGS=0; - GNULIB_POSIX_SPAWNATTR_GETPGROUP=0; - GNULIB_POSIX_SPAWNATTR_SETPGROUP=0; - GNULIB_POSIX_SPAWNATTR_GETSCHEDPARAM=0; - GNULIB_POSIX_SPAWNATTR_SETSCHEDPARAM=0; - GNULIB_POSIX_SPAWNATTR_GETSCHEDPOLICY=0; - GNULIB_POSIX_SPAWNATTR_SETSCHEDPOLICY=0; - GNULIB_POSIX_SPAWNATTR_GETSIGDEFAULT=0; - GNULIB_POSIX_SPAWNATTR_SETSIGDEFAULT=0; - GNULIB_POSIX_SPAWNATTR_GETSIGMASK=0; - GNULIB_POSIX_SPAWNATTR_SETSIGMASK=0; - GNULIB_POSIX_SPAWNATTR_DESTROY=0; - HAVE_POSIX_SPAWN=1; - HAVE_POSIX_SPAWNATTR_T=1; - HAVE_POSIX_SPAWN_FILE_ACTIONS_T=1; - - REPLACE_POSIX_SPAWN=0; - REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE=0; - - REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2=0; - - REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN=0; - - - - - - - - - if test $ac_cv_func_posix_spawn != yes; then - HAVE_POSIX_SPAWN=0 - fi - - - - - if test $ac_cv_func_posix_spawn = yes; then - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether posix_spawn works" >&5 -$as_echo_n "checking whether posix_spawn works... " >&6; } -if ${gl_cv_func_posix_spawn_works+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test $cross_compiling = no; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -#include <errno.h> -#include <fcntl.h> -#include <signal.h> -#include <spawn.h> -#include <stdbool.h> -#include <stdio.h> -#include <stdlib.h> -#include <string.h> -#include <unistd.h> -#include <sys/types.h> -#include <sys/wait.h> - -extern char **environ; - -#ifndef STDIN_FILENO -# define STDIN_FILENO 0 -#endif -#ifndef STDOUT_FILENO -# define STDOUT_FILENO 1 -#endif -#ifndef STDERR_FILENO -# define STDERR_FILENO 2 -#endif - -#ifndef WTERMSIG -# define WTERMSIG(x) ((x) & 0x7f) -#endif -#ifndef WIFEXITED -# define WIFEXITED(x) (WTERMSIG (x) == 0) -#endif -#ifndef WEXITSTATUS -# define WEXITSTATUS(x) (((x) >> 8) & 0xff) -#endif - -#define CHILD_PROGRAM_FILENAME "/non/exist/ent" - -static int -fd_safer (int fd) -{ - if (0 <= fd && fd <= 2) - { - int f = fd_safer (dup (fd)); - int e = errno; - close (fd); - errno = e; - fd = f; - } - - return fd; -} - -int -main () -{ - char *argv[2] = { CHILD_PROGRAM_FILENAME, NULL }; - int ofd[2]; - sigset_t blocked_signals; - sigset_t fatal_signal_set; - posix_spawn_file_actions_t actions; - bool actions_allocated; - posix_spawnattr_t attrs; - bool attrs_allocated; - int err; - pid_t child; - int status; - int exitstatus; - - setvbuf (stdout, NULL, _IOFBF, 0); - puts ("This should be seen only once."); - if (pipe (ofd) < 0 || (ofd[1] = fd_safer (ofd[1])) < 0) - { - perror ("cannot create pipe"); - exit (1); - } - sigprocmask (SIG_SETMASK, NULL, &blocked_signals); - sigemptyset (&fatal_signal_set); - sigaddset (&fatal_signal_set, SIGINT); - sigaddset (&fatal_signal_set, SIGTERM); - sigaddset (&fatal_signal_set, SIGHUP); - sigaddset (&fatal_signal_set, SIGPIPE); - sigprocmask (SIG_BLOCK, &fatal_signal_set, NULL); - actions_allocated = false; - attrs_allocated = false; - if ((err = posix_spawn_file_actions_init (&actions)) != 0 - || (actions_allocated = true, - (err = posix_spawn_file_actions_adddup2 (&actions, ofd[0], STDIN_FILENO)) != 0 - || (err = posix_spawn_file_actions_addclose (&actions, ofd[0])) != 0 - || (err = posix_spawn_file_actions_addclose (&actions, ofd[1])) != 0 - || (err = posix_spawnattr_init (&attrs)) != 0 - || (attrs_allocated = true, - (err = posix_spawnattr_setsigmask (&attrs, &blocked_signals)) != 0 - || (err = posix_spawnattr_setflags (&attrs, POSIX_SPAWN_SETSIGMASK)) != 0) - || (err = posix_spawnp (&child, CHILD_PROGRAM_FILENAME, &actions, &attrs, argv, environ)) != 0)) - { - if (actions_allocated) - posix_spawn_file_actions_destroy (&actions); - if (attrs_allocated) - posix_spawnattr_destroy (&attrs); - sigprocmask (SIG_UNBLOCK, &fatal_signal_set, NULL); - if (err == ENOENT) - return 0; - else - { - errno = err; - perror ("subprocess failed"); - exit (1); - } - } - posix_spawn_file_actions_destroy (&actions); - posix_spawnattr_destroy (&attrs); - sigprocmask (SIG_UNBLOCK, &fatal_signal_set, NULL); - close (ofd[0]); - close (ofd[1]); - status = 0; - while (waitpid (child, &status, 0) != child) - ; - if (!WIFEXITED (status)) - { - fprintf (stderr, "subprocess terminated with unexpected wait status %d\n", status); - exit (1); - } - exitstatus = WEXITSTATUS (status); - if (exitstatus != 127) - { - fprintf (stderr, "subprocess terminated with unexpected exit status %d\n", exitstatus); - exit (1); - } - return 0; -} - -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - if test -s conftest$ac_exeext \ - && ./conftest$ac_exeext > conftest.out \ - && echo 'This should be seen only once.' > conftest.ok \ - && cmp conftest.out conftest.ok > /dev/null; then - gl_cv_func_posix_spawn_works=yes - else - gl_cv_func_posix_spawn_works=no - fi -else - gl_cv_func_posix_spawn_works=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - if test $gl_cv_func_posix_spawn_works = yes; then - if test "$cross_compiling" = yes; then : - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "cannot run test program while cross compiling -See \`config.log' for more details" "$LINENO" 5; } -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Test whether posix_spawn_file_actions_addopen supports filename arguments - that contain special characters such as '*'. */ - -#include <errno.h> -#include <fcntl.h> -#include <signal.h> -#include <spawn.h> -#include <stdbool.h> -#include <stdio.h> -#include <string.h> -#include <unistd.h> -#include <sys/types.h> -#include <sys/wait.h> - -extern char **environ; - -#ifndef STDIN_FILENO -# define STDIN_FILENO 0 -#endif -#ifndef STDOUT_FILENO -# define STDOUT_FILENO 1 -#endif -#ifndef STDERR_FILENO -# define STDERR_FILENO 2 -#endif - -#ifndef WTERMSIG -# define WTERMSIG(x) ((x) & 0x7f) -#endif -#ifndef WIFEXITED -# define WIFEXITED(x) (WTERMSIG (x) == 0) -#endif -#ifndef WEXITSTATUS -# define WEXITSTATUS(x) (((x) >> 8) & 0xff) -#endif - -#define CHILD_PROGRAM_FILENAME "conftest" -#define DATA_FILENAME "conftest%=*#?" - -static int -parent_main (void) -{ - FILE *fp; - char *argv[3] = { CHILD_PROGRAM_FILENAME, "-child", NULL }; - posix_spawn_file_actions_t actions; - bool actions_allocated; - int err; - pid_t child; - int status; - int exitstatus; - - /* Create a data file with specific contents. */ - fp = fopen (DATA_FILENAME, "wb"); - if (fp == NULL) - { - perror ("cannot create data file"); - return 1; - } - fwrite ("Halle Potta", 1, 11, fp); - if (fflush (fp) || fclose (fp)) - { - perror ("cannot prepare data file"); - return 2; - } - - /* Avoid reading from our stdin, as it could block. */ - freopen ("/dev/null", "rb", stdin); - - /* Test whether posix_spawn_file_actions_addopen with this file name - actually works, but spawning a child that reads from this file. */ - actions_allocated = false; - if ((err = posix_spawn_file_actions_init (&actions)) != 0 - || (actions_allocated = true, - (err = posix_spawn_file_actions_addopen (&actions, STDIN_FILENO, DATA_FILENAME, O_RDONLY, 0600)) != 0 - || (err = posix_spawn (&child, CHILD_PROGRAM_FILENAME, &actions, NULL, argv, environ)) != 0)) - { - if (actions_allocated) - posix_spawn_file_actions_destroy (&actions); - errno = err; - perror ("subprocess failed"); - return 3; - } - posix_spawn_file_actions_destroy (&actions); - status = 0; - while (waitpid (child, &status, 0) != child) - ; - if (!WIFEXITED (status)) - { - fprintf (stderr, "subprocess terminated with unexpected wait status %d\n", status); - return 4; - } - exitstatus = WEXITSTATUS (status); - if (exitstatus != 0) - { - fprintf (stderr, "subprocess terminated with unexpected exit status %d\n", exitstatus); - return 5; - } - return 0; -} - -static int -child_main (void) -{ - char buf[1024]; - - /* See if reading from STDIN_FILENO yields the expected contents. */ - if (fread (buf, 1, sizeof (buf), stdin) == 11 - && memcmp (buf, "Halle Potta", 11) == 0) - return 0; - else - return 8; -} - -static void -cleanup_then_die (int sig) -{ - /* Clean up data file. */ - unlink (DATA_FILENAME); - - /* Re-raise the signal and die from it. */ - signal (sig, SIG_DFL); - raise (sig); -} - -int -main (int argc, char *argv[]) -{ - int exitstatus; - - if (!(argc > 1 && strcmp (argv[1], "-child") == 0)) - { - /* This is the parent process. */ - signal (SIGINT, cleanup_then_die); - signal (SIGTERM, cleanup_then_die); - #ifdef SIGHUP - signal (SIGHUP, cleanup_then_die); - #endif - - exitstatus = parent_main (); - } - else - { - /* This is the child process. */ - - exitstatus = child_main (); - } - unlink (DATA_FILENAME); - return exitstatus; -} - -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - -else - gl_cv_func_posix_spawn_works=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - - fi - else - case "$host_os" in - aix*) gl_cv_func_posix_spawn_works="guessing no";; - *) gl_cv_func_posix_spawn_works="guessing yes";; - esac - fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_posix_spawn_works" >&5 -$as_echo "$gl_cv_func_posix_spawn_works" >&6; } - - case "$gl_cv_func_posix_spawn_works" in - *yes) - -$as_echo "#define HAVE_WORKING_POSIX_SPAWN 1" >>confdefs.h - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether posix_spawnattr_setschedpolicy is supported" >&5 -$as_echo_n "checking whether posix_spawnattr_setschedpolicy is supported... " >&6; } -if ${gl_cv_func_spawnattr_setschedpolicy+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -#include <spawn.h> -#if POSIX_SPAWN_SETSCHEDULER - POSIX scheduling supported -#endif - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "POSIX scheduling supported" >/dev/null 2>&1; then : - gl_cv_func_spawnattr_setschedpolicy=yes -else - gl_cv_func_spawnattr_setschedpolicy=no -fi -rm -f conftest* - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_spawnattr_setschedpolicy" >&5 -$as_echo "$gl_cv_func_spawnattr_setschedpolicy" >&6; } - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether posix_spawnattr_setschedparam is supported" >&5 -$as_echo_n "checking whether posix_spawnattr_setschedparam is supported... " >&6; } -if ${gl_cv_func_spawnattr_setschedparam+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -#include <spawn.h> -#if POSIX_SPAWN_SETSCHEDPARAM - POSIX scheduling supported -#endif - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "POSIX scheduling supported" >/dev/null 2>&1; then : - gl_cv_func_spawnattr_setschedparam=yes -else - gl_cv_func_spawnattr_setschedparam=no -fi -rm -f conftest* - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_spawnattr_setschedparam" >&5 -$as_echo "$gl_cv_func_spawnattr_setschedparam" >&6; } - ;; - *) REPLACE_POSIX_SPAWN=1 ;; - esac - fi - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for desired default level of POSIX conformance" >&5 $as_echo_n "checking for desired default level of POSIX conformance... " >&6; } gl_default_posix2_version=none-specified @@ -21122,6 +20927,8 @@ $as_echo "#define UNLINK_PARENT_BUG 1" >>confdefs.h + + # Check whether --with-selinux was given. if test "${with_selinux+set}" = set; then : withval=$with_selinux; @@ -21195,12 +21002,14 @@ fi # Warn if SELinux is found but libselinux is absent; - if test "$ac_cv_search_setfilecon" = no && - test "$host" = "$build" && test -d /selinux; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This system supports SELinux but libselinux is missing." >&5 + if test "$ac_cv_search_setfilecon" = no; then + if test "$host" = "$build" && test -d /selinux; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This system supports SELinux but libselinux is missing." >&5 $as_echo "$as_me: WARNING: This system supports SELinux but libselinux is missing." >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: GNU coreutils will be compiled without SELinux support." >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: GNU coreutils will be compiled without SELinux support." >&5 $as_echo "$as_me: WARNING: GNU coreutils will be compiled without SELinux support." >&2;} + fi + with_selinux=no fi @@ -21284,7 +21093,7 @@ else # Guess yes on glibc systems. *-gnu*) gl_cv_func_snprintf_retval_c99="guessing yes";; # Guess yes on FreeBSD >= 5. - freebsd[1-4]*) gl_cv_func_snprintf_retval_c99="guessing no";; + freebsd[1-4].*) gl_cv_func_snprintf_retval_c99="guessing no";; freebsd* | kfreebsd*) gl_cv_func_snprintf_retval_c99="guessing yes";; # Guess yes on Mac OS X >= 10.3. darwin[1-6].*) gl_cv_func_snprintf_retval_c99="guessing no";; @@ -21367,8 +21176,6 @@ cat >>confdefs.h <<_ACEOF #define HAVE_DECL_SNPRINTF $ac_have_decl _ACEOF - - ac_fn_c_check_decl "$LINENO" "stpncpy" "ac_cv_have_decl_stpncpy" "$ac_includes_default" if test "x$ac_cv_have_decl_stpncpy" = xyes; then : ac_have_decl=1 @@ -21646,36 +21453,40 @@ if ${gl_cv_next_string_h+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <string.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'string.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' - gl_header_literal_regex=`echo 'string.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_string_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + gl_cv_absolute_string_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_string_h + gl_cv_next_string_h='"'$gl_header'"' fi @@ -22135,36 +21946,40 @@ if ${gl_cv_next_time_h+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'time.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' - gl_header_literal_regex=`echo 'time.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + gl_cv_absolute_time_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_time_h + gl_cv_next_time_h='"'$gl_header'"' fi @@ -22195,8 +22010,6 @@ $as_echo "$gl_cv_next_time_h" >&6; } - - gl_libunistring_sed_extract_major='/^[0-9]/{s/^\([0-9]*\).*/\1/p;q;} i\ 0 @@ -22700,7 +22513,7 @@ else # Guess yes on glibc systems. *-gnu*) gl_cv_func_printf_sizes_c99="guessing yes";; # Guess yes on FreeBSD >= 5. - freebsd[1-4]*) gl_cv_func_printf_sizes_c99="guessing no";; + freebsd[1-4].*) gl_cv_func_printf_sizes_c99="guessing no";; freebsd* | kfreebsd*) gl_cv_func_printf_sizes_c99="guessing yes";; # Guess yes on Mac OS X >= 10.3. darwin[1-6].*) gl_cv_func_printf_sizes_c99="guessing no";; @@ -22842,7 +22655,7 @@ else # Guess yes on glibc systems. *-gnu*) gl_cv_func_printf_infinite="guessing yes";; # Guess yes on FreeBSD >= 6. - freebsd[1-5]*) gl_cv_func_printf_infinite="guessing no";; + freebsd[1-5].*) gl_cv_func_printf_infinite="guessing no";; freebsd* | kfreebsd*) gl_cv_func_printf_infinite="guessing yes";; # Guess yes on Mac OS X >= 10.3. darwin[1-6].*) gl_cv_func_printf_infinite="guessing no";; @@ -22973,7 +22786,7 @@ else # Guess yes on glibc systems. *-gnu*) gl_cv_func_printf_infinite_long_double="guessing yes";; # Guess yes on FreeBSD >= 6. - freebsd[1-5]*) gl_cv_func_printf_infinite_long_double="guessing no";; + freebsd[1-5].*) gl_cv_func_printf_infinite_long_double="guessing no";; freebsd* | kfreebsd*) gl_cv_func_printf_infinite_long_double="guessing yes";; # Guess yes on HP-UX >= 11. hpux[7-9]* | hpux10*) gl_cv_func_printf_infinite_long_double="guessing no";; @@ -23401,7 +23214,7 @@ else # Guess yes on glibc systems. *-gnu*) gl_cv_func_printf_directive_f="guessing yes";; # Guess yes on FreeBSD >= 6. - freebsd[1-5]*) gl_cv_func_printf_directive_f="guessing no";; + freebsd[1-5].*) gl_cv_func_printf_directive_f="guessing no";; freebsd* | kfreebsd*) gl_cv_func_printf_directive_f="guessing yes";; # Guess yes on Mac OS X >= 10.3. darwin[1-6].*) gl_cv_func_printf_directive_f="guessing no";; @@ -24228,17 +24041,6 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_tiocgwinsz_needs_termios_h" >&5 $as_echo "$gl_cv_sys_tiocgwinsz_needs_termios_h" >&6; } -ac_fn_c_check_decl "$LINENO" "alarm" "ac_cv_have_decl_alarm" "$ac_includes_default" -if test "x$ac_cv_have_decl_alarm" = xyes; then : - ac_have_decl=1 -else - ac_have_decl=0 -fi - -cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_ALARM $ac_have_decl -_ACEOF - @@ -24309,6 +24111,8 @@ $as_echo "#define FUNC_UNGETC_BROKEN 1" >>confdefs.h + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LC_MESSAGES" >&5 $as_echo_n "checking for LC_MESSAGES... " >&6; } if ${gt_cv_val_LC_MESSAGES+:} false; then : @@ -24463,8 +24267,6 @@ _ACEOF - - if false; then GL_COND_LIBTOOL_TRUE= GL_COND_LIBTOOL_FALSE='#' @@ -24488,448 +24290,6 @@ fi gl_source_base='lib' - # Check whether --enable-acl was given. -if test "${enable_acl+set}" = set; then : - enableval=$enable_acl; -else - enable_acl=auto -fi - - - LIB_ACL= - use_acl=0 - if test "x$enable_acl" != "xno"; then - for ac_header in sys/acl.h -do : - ac_fn_c_check_header_mongrel "$LINENO" "sys/acl.h" "ac_cv_header_sys_acl_h" "$ac_includes_default" -if test "x$ac_cv_header_sys_acl_h" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_SYS_ACL_H 1 -_ACEOF - -fi - -done - - if test $ac_cv_header_sys_acl_h = yes; then - ac_save_LIBS=$LIBS - - if test $use_acl = 0; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing acl_get_file" >&5 -$as_echo_n "checking for library containing acl_get_file... " >&6; } -if ${ac_cv_search_acl_get_file+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char acl_get_file (); -int -main () -{ -return acl_get_file (); - ; - return 0; -} -_ACEOF -for ac_lib in '' acl pacl; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_acl_get_file=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if ${ac_cv_search_acl_get_file+:} false; then : - break -fi -done -if ${ac_cv_search_acl_get_file+:} false; then : - -else - ac_cv_search_acl_get_file=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_acl_get_file" >&5 -$as_echo "$ac_cv_search_acl_get_file" >&6; } -ac_res=$ac_cv_search_acl_get_file -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" - if test "$ac_cv_search_acl_get_file" != "none required"; then - LIB_ACL=$ac_cv_search_acl_get_file - fi - for ac_func in acl_get_file acl_get_fd acl_set_file acl_set_fd \ - acl_free acl_from_mode acl_from_text \ - acl_delete_def_file acl_extended_file \ - acl_delete_fd_np acl_delete_file_np \ - acl_copy_ext_native acl_create_entry_np \ - acl_to_short_text acl_free_text -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -if eval test \"x\$"$as_ac_var"\" = x"yes"; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - -fi -done - - # If the acl_get_file bug is detected, don't enable the ACL support. - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working acl_get_file" >&5 -$as_echo_n "checking for working acl_get_file... " >&6; } -if ${gl_cv_func_working_acl_get_file+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - gl_cv_func_working_acl_get_file=cross-compiling -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include <sys/types.h> - #include <sys/acl.h> - #include <errno.h> - -int -main () -{ -if (!acl_get_file (".", ACL_TYPE_ACCESS) && errno == ENOENT) - return 1; - return 0; - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - gl_cv_func_working_acl_get_file=yes -else - gl_cv_func_working_acl_get_file=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_acl_get_file" >&5 -$as_echo "$gl_cv_func_working_acl_get_file" >&6; } - - if test $gl_cv_func_working_acl_get_file = yes; then : - use_acl=1 -fi - - if test $use_acl = 1; then - for ac_header in acl/libacl.h -do : - ac_fn_c_check_header_mongrel "$LINENO" "acl/libacl.h" "ac_cv_header_acl_libacl_h" "$ac_includes_default" -if test "x$ac_cv_header_acl_libacl_h" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_ACL_LIBACL_H 1 -_ACEOF - -fi - -done - - - - - - - - - - for ac_func in acl_entries -do : - ac_fn_c_check_func "$LINENO" "acl_entries" "ac_cv_func_acl_entries" -if test "x$ac_cv_func_acl_entries" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_ACL_ENTRIES 1 -_ACEOF - -else - - gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext" - -fi -done - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ACL_FIRST_ENTRY" >&5 -$as_echo_n "checking for ACL_FIRST_ENTRY... " >&6; } -if ${gl_cv_acl_ACL_FIRST_ENTRY+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include <sys/types.h> -#include <sys/acl.h> -int type = ACL_FIRST_ENTRY; -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - gl_cv_acl_ACL_FIRST_ENTRY=yes -else - gl_cv_acl_ACL_FIRST_ENTRY=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_acl_ACL_FIRST_ENTRY" >&5 -$as_echo "$gl_cv_acl_ACL_FIRST_ENTRY" >&6; } - if test $gl_cv_acl_ACL_FIRST_ENTRY = yes; then - -$as_echo "#define HAVE_ACL_FIRST_ENTRY 1" >>confdefs.h - - fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ACL_TYPE_EXTENDED" >&5 -$as_echo_n "checking for ACL_TYPE_EXTENDED... " >&6; } -if ${gl_cv_acl_ACL_TYPE_EXTENDED+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include <sys/types.h> -#include <sys/acl.h> -int type = ACL_TYPE_EXTENDED; -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - gl_cv_acl_ACL_TYPE_EXTENDED=yes -else - gl_cv_acl_ACL_TYPE_EXTENDED=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_acl_ACL_TYPE_EXTENDED" >&5 -$as_echo "$gl_cv_acl_ACL_TYPE_EXTENDED" >&6; } - if test $gl_cv_acl_ACL_TYPE_EXTENDED = yes; then - -$as_echo "#define HAVE_ACL_TYPE_EXTENDED 1" >>confdefs.h - - fi - else - LIB_ACL= - fi - -fi - - fi - - if test $use_acl = 0; then - for ac_func in facl -do : - ac_fn_c_check_func "$LINENO" "facl" "ac_cv_func_facl" -if test "x$ac_cv_func_facl" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_FACL 1 -_ACEOF - -fi -done - - if test $ac_cv_func_facl = yes; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing acl_trivial" >&5 -$as_echo_n "checking for library containing acl_trivial... " >&6; } -if ${ac_cv_search_acl_trivial+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char acl_trivial (); -int -main () -{ -return acl_trivial (); - ; - return 0; -} -_ACEOF -for ac_lib in '' sec; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_acl_trivial=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if ${ac_cv_search_acl_trivial+:} false; then : - break -fi -done -if ${ac_cv_search_acl_trivial+:} false; then : - -else - ac_cv_search_acl_trivial=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_acl_trivial" >&5 -$as_echo "$ac_cv_search_acl_trivial" >&6; } -ac_res=$ac_cv_search_acl_trivial -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" - if test "$ac_cv_search_acl_trivial" != "none required"; then - LIB_ACL=$ac_cv_search_acl_trivial - fi - -fi - - for ac_func in acl_trivial -do : - ac_fn_c_check_func "$LINENO" "acl_trivial" "ac_cv_func_acl_trivial" -if test "x$ac_cv_func_acl_trivial" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_ACL_TRIVIAL 1 -_ACEOF - -fi -done - - use_acl=1 - fi - fi - - if test $use_acl = 0; then - for ac_func in getacl -do : - ac_fn_c_check_func "$LINENO" "getacl" "ac_cv_func_getacl" -if test "x$ac_cv_func_getacl" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_GETACL 1 -_ACEOF - -fi -done - - if test $ac_cv_func_getacl = yes; then - use_acl=1 - fi - for ac_header in aclv.h -do : - ac_fn_c_check_header_compile "$LINENO" "aclv.h" "ac_cv_header_aclv_h" "#include <sys/types.h> -" -if test "x$ac_cv_header_aclv_h" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_ACLV_H 1 -_ACEOF - -fi - -done - - fi - - if test $use_acl = 0; then - for ac_func in aclx_get -do : - ac_fn_c_check_func "$LINENO" "aclx_get" "ac_cv_func_aclx_get" -if test "x$ac_cv_func_aclx_get" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_ACLX_GET 1 -_ACEOF - -fi -done - - if test $ac_cv_func_aclx_get = yes; then - use_acl=1 - fi - fi - - if test $use_acl = 0 || test "$ac_cv_func_aclx_get" = yes; then - for ac_func in statacl -do : - ac_fn_c_check_func "$LINENO" "statacl" "ac_cv_func_statacl" -if test "x$ac_cv_func_statacl" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_STATACL 1 -_ACEOF - -fi -done - - if test $ac_cv_func_statacl = yes; then - use_acl=1 - fi - fi - - if test $use_acl = 0; then - for ac_func in aclsort -do : - ac_fn_c_check_func "$LINENO" "aclsort" "ac_cv_func_aclsort" -if test "x$ac_cv_func_aclsort" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_ACLSORT 1 -_ACEOF - -fi -done - - if test $ac_cv_func_aclsort = yes; then - use_acl=1 - fi - fi - - LIBS=$ac_save_LIBS - fi - if test "x$enable_acl$use_acl" = "xyes0"; then - as_fn_error $? "ACLs enabled but support not detected" "$LINENO" 5 - elif test "x$enable_acl$use_acl" = "xauto0"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libacl development library was not found or not usable." >&5 -$as_echo "$as_me: WARNING: libacl development library was not found or not usable." >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: GNU coreutils will be built without ACL support." >&5 -$as_echo "$as_me: WARNING: GNU coreutils will be built without ACL support." >&2;} - fi - fi - - -cat >>confdefs.h <<_ACEOF -#define USE_ACL $use_acl -_ACEOF - - USE_ACL=$use_acl - - - if test $ac_cv_func_alloca_works = no; then : @@ -25022,36 +24382,40 @@ else if test $ac_cv_header_arpa_inet_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <arpa/inet.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'arpa/inet.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_arpa_inet_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'arpa/inet.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_arpa_inet_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_arpa_inet_h + gl_cv_next_arpa_inet_h='"'$gl_header'"' else gl_cv_next_arpa_inet_h='<'arpa/inet.h'>' fi @@ -25861,22 +25225,376 @@ $as_echo "#define GNULIB_TEST_CLOSEDIR 1" >>confdefs.h localedir='${datarootdir}/locale' fi + if test "x$runstatedir" = x; then + runstatedir='${localstatedir}/run' + + fi pkglibexecdir='${libexecdir}/${PACKAGE}' - : - : +# Check whether --with-openssl was given. +if test "${with_openssl+set}" = set; then : + withval=$with_openssl; +else + with_openssl=$with_openssl_default +fi + + + if test "xMD5" = xMD5; then + ALG_header=md5.h + else + ALG_header=sha.h + fi + + + if test "x$with_openssl" != xno; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MD5 in -lcrypto" >&5 +$as_echo_n "checking for MD5 in -lcrypto... " >&6; } +if ${ac_cv_lib_crypto_MD5+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lcrypto $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char MD5 (); +int +main () +{ +return MD5 (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_crypto_MD5=yes +else + ac_cv_lib_crypto_MD5=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_MD5" >&5 +$as_echo "$ac_cv_lib_crypto_MD5" >&6; } +if test "x$ac_cv_lib_crypto_MD5" = xyes; then : + for ac_header in openssl/$ALG_header +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + LIB_CRYPTO=-lcrypto + +$as_echo "#define HAVE_OPENSSL_MD5 1" >>confdefs.h + +fi + +done + +fi + + if test "x$LIB_CRYPTO" = x; then + if test "x$with_openssl" = xyes; then + as_fn_error $? "openssl development library not found for MD5" "$LINENO" 5 + elif test "x$with_openssl" = xoptional; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: openssl development library not found for MD5" >&5 +$as_echo "$as_me: WARNING: openssl development library not found for MD5" >&2;} + fi + fi + fi + + + + + + + + + + + +# Check whether --with-openssl was given. +if test "${with_openssl+set}" = set; then : + withval=$with_openssl; +else + with_openssl=$with_openssl_default +fi + + + if test "xSHA1" = xMD5; then + ALG_header=md5.h + else + ALG_header=sha.h + fi + + + if test "x$with_openssl" != xno; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SHA1 in -lcrypto" >&5 +$as_echo_n "checking for SHA1 in -lcrypto... " >&6; } +if ${ac_cv_lib_crypto_SHA1+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lcrypto $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char SHA1 (); +int +main () +{ +return SHA1 (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_crypto_SHA1=yes +else + ac_cv_lib_crypto_SHA1=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_SHA1" >&5 +$as_echo "$ac_cv_lib_crypto_SHA1" >&6; } +if test "x$ac_cv_lib_crypto_SHA1" = xyes; then : + for ac_header in openssl/$ALG_header +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + LIB_CRYPTO=-lcrypto + +$as_echo "#define HAVE_OPENSSL_SHA1 1" >>confdefs.h + +fi + +done + +fi + + if test "x$LIB_CRYPTO" = x; then + if test "x$with_openssl" = xyes; then + as_fn_error $? "openssl development library not found for SHA1" "$LINENO" 5 + elif test "x$with_openssl" = xoptional; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: openssl development library not found for SHA1" >&5 +$as_echo "$as_me: WARNING: openssl development library not found for SHA1" >&2;} + fi + fi + fi + + + + + + + + + + + +# Check whether --with-openssl was given. +if test "${with_openssl+set}" = set; then : + withval=$with_openssl; +else + with_openssl=$with_openssl_default +fi + + + if test "xSHA256" = xMD5; then + ALG_header=md5.h + else + ALG_header=sha.h + fi + + + if test "x$with_openssl" != xno; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SHA256 in -lcrypto" >&5 +$as_echo_n "checking for SHA256 in -lcrypto... " >&6; } +if ${ac_cv_lib_crypto_SHA256+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lcrypto $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char SHA256 (); +int +main () +{ +return SHA256 (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_crypto_SHA256=yes +else + ac_cv_lib_crypto_SHA256=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_SHA256" >&5 +$as_echo "$ac_cv_lib_crypto_SHA256" >&6; } +if test "x$ac_cv_lib_crypto_SHA256" = xyes; then : + for ac_header in openssl/$ALG_header +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + LIB_CRYPTO=-lcrypto + +$as_echo "#define HAVE_OPENSSL_SHA256 1" >>confdefs.h + +fi + +done + +fi + if test "x$LIB_CRYPTO" = x; then + if test "x$with_openssl" = xyes; then + as_fn_error $? "openssl development library not found for SHA256" "$LINENO" 5 + elif test "x$with_openssl" = xoptional; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: openssl development library not found for SHA256" >&5 +$as_echo "$as_me: WARNING: openssl development library not found for SHA256" >&2;} + fi + fi + fi + + + + + + + + + + + +# Check whether --with-openssl was given. +if test "${with_openssl+set}" = set; then : + withval=$with_openssl; +else + with_openssl=$with_openssl_default +fi + + + if test "xSHA512" = xMD5; then + ALG_header=md5.h + else + ALG_header=sha.h + fi + + + if test "x$with_openssl" != xno; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SHA512 in -lcrypto" >&5 +$as_echo_n "checking for SHA512 in -lcrypto... " >&6; } +if ${ac_cv_lib_crypto_SHA512+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lcrypto $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char SHA512 (); +int +main () +{ +return SHA512 (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_crypto_SHA512=yes +else + ac_cv_lib_crypto_SHA512=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_SHA512" >&5 +$as_echo "$ac_cv_lib_crypto_SHA512" >&6; } +if test "x$ac_cv_lib_crypto_SHA512" = xyes; then : + for ac_header in openssl/$ALG_header +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + LIB_CRYPTO=-lcrypto + +$as_echo "#define HAVE_OPENSSL_SHA512 1" >>confdefs.h + +fi + +done + +fi + + if test "x$LIB_CRYPTO" = x; then + if test "x$with_openssl" = xyes; then + as_fn_error $? "openssl development library not found for SHA512" "$LINENO" 5 + elif test "x$with_openssl" = xoptional; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: openssl development library not found for SHA512" >&5 +$as_echo "$as_me: WARNING: openssl development library not found for SHA512" >&2;} + fi + fi + fi @@ -25899,36 +25617,40 @@ if ${gl_cv_next_ctype_h+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <ctype.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'ctype.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' - gl_header_literal_regex=`echo 'ctype.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_ctype_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + gl_cv_absolute_ctype_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_ctype_h + gl_cv_next_ctype_h='"'$gl_header'"' fi @@ -25984,7 +25706,7 @@ DIR *dp = opendir ("."); e = readdir (dp); if (! e) return 2; - if (stat (e->d_name, &st) != 0) + if (lstat (e->d_name, &st) != 0) return 3; if (e->d_ino != st.st_ino) return 4; @@ -26077,36 +25799,40 @@ else if test $ac_cv_header_dirent_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <dirent.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'dirent.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_dirent_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'dirent.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_dirent_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_dirent_h + gl_cv_next_dirent_h='"'$gl_header'"' else gl_cv_next_dirent_h='<'dirent.h'>' fi @@ -26398,6 +26124,7 @@ $as_echo "#define GNULIB_TEST_DUP 1" >>confdefs.h + $as_echo "#define HAVE_DUP2 1" >>confdefs.h @@ -26416,7 +26143,9 @@ else linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a # closed fd may yield -EBADF instead of -1 / errno=EBADF. gl_cv_func_dup2_works="guessing no" ;; - freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF. + aix* | freebsd*) + # on AIX 7.1 and FreeBSD 6.1, dup2 (1,toobig) gives EMFILE, + # not EBADF. gl_cv_func_dup2_works="guessing no" ;; haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC. gl_cv_func_dup2_works="guessing no" ;; @@ -26433,6 +26162,11 @@ int main () { int result = 0; +#ifdef HAVE_GETDTABLESIZE + int bad_fd = getdtablesize (); +#else + int bad_fd = 1000000; +#endif #ifdef FD_CLOEXEC if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1) result |= 1; @@ -26447,11 +26181,13 @@ int result = 0; if (dup2 (0, 0) != -1) result |= 8; /* Many gnulib modules require POSIX conformance of EBADF. */ - if (dup2 (2, 1000000) == -1 && errno != EBADF) + if (dup2 (2, bad_fd) == -1 && errno != EBADF) result |= 16; - /* Flush out a cygwin core dump. */ + /* Flush out some cygwin core dumps. */ if (dup2 (2, -1) != -1 || errno != EBADF) result |= 32; + dup2 (2, 255); + dup2 (2, 256); return result; ; @@ -26476,6 +26212,17 @@ $as_echo "$gl_cv_func_dup2_works" >&6; } *yes) ;; *) REPLACE_DUP2=1 + for ac_func in setdtablesize +do : + ac_fn_c_check_func "$LINENO" "setdtablesize" "ac_cv_func_setdtablesize" +if test "x$ac_cv_func_setdtablesize" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SETDTABLESIZE 1 +_ACEOF + +fi +done + ;; esac fi @@ -26900,11 +26647,6 @@ $as_echo "#define GNULIB_TEST_FACCESSAT 1" >>confdefs.h - : - - - - if test $ac_cv_have_decl_fchdir = no; then @@ -27202,7 +26944,7 @@ if ${gl_cv_func_fflush_stdin+:} false; then : else echo hello world > conftest.txt if test "$cross_compiling" = yes; then : - gl_cv_func_fflush_stdin=no + gl_cv_func_fflush_stdin=cross else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -27271,8 +27013,18 @@ fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fflush_stdin" >&5 $as_echo "$gl_cv_func_fflush_stdin" >&6; } + case $gl_cv_func_fflush_stdin in + yes) gl_func_fflush_stdin=1 ;; + no) gl_func_fflush_stdin=0 ;; + *) gl_func_fflush_stdin='(-1)' ;; + esac + +cat >>confdefs.h <<_ACEOF +#define FUNC_FFLUSH_STDIN $gl_func_fflush_stdin +_ACEOF - if test $gl_cv_func_fflush_stdin = no; then + + if test $gl_cv_func_fflush_stdin != yes; then REPLACE_FCLOSE=1 fi @@ -27339,6 +27091,9 @@ else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +#ifdef HAVE_GETDTABLESIZE +# include <unistd.h> +#endif #include <fcntl.h> #include <errno.h> @@ -27346,8 +27101,15 @@ int main () { int result = 0; +#ifdef HAVE_GETDTABLESIZE + int bad_fd = getdtablesize (); +#else + int bad_fd = 1000000; +#endif if (fcntl (0, F_DUPFD, -1) != -1) result |= 1; if (errno != EINVAL) result |= 2; + if (fcntl (0, F_DUPFD, bad_fd) != -1) result |= 4; + if (errno != EINVAL) result |= 8; return result; ; @@ -27514,36 +27276,40 @@ if ${gl_cv_next_fcntl_h+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <fcntl.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'fcntl.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' - gl_header_literal_regex=`echo 'fcntl.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_fcntl_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + gl_cv_absolute_fcntl_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_fcntl_h + gl_cv_next_fcntl_h='"'$gl_header'"' fi @@ -27922,7 +27688,7 @@ if ${gl_cv_func_fflush_stdin+:} false; then : else echo hello world > conftest.txt if test "$cross_compiling" = yes; then : - gl_cv_func_fflush_stdin=no + gl_cv_func_fflush_stdin=cross else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -27991,8 +27757,18 @@ fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fflush_stdin" >&5 $as_echo "$gl_cv_func_fflush_stdin" >&6; } + case $gl_cv_func_fflush_stdin in + yes) gl_func_fflush_stdin=1 ;; + no) gl_func_fflush_stdin=0 ;; + *) gl_func_fflush_stdin='(-1)' ;; + esac - if test $gl_cv_func_fflush_stdin = no; then +cat >>confdefs.h <<_ACEOF +#define FUNC_FFLUSH_STDIN $gl_func_fflush_stdin +_ACEOF + + + if test $gl_cv_func_fflush_stdin != yes; then REPLACE_FFLUSH=1 fi @@ -28255,36 +28031,40 @@ if ${gl_cv_next_float_h+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <float.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'float.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_float_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` - gl_header_literal_regex=`echo 'float.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_float_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + gl_header=$gl_cv_absolute_float_h + gl_cv_next_float_h='"'$gl_header'"' fi @@ -28652,14 +28432,42 @@ _ACEOF - fp_headers=' -# include <stdio.h> -# if HAVE_STDIO_EXT_H -# include <stdio_ext.h> -# endif -' - ac_fn_c_check_decl "$LINENO" "__fpending" "ac_cv_have_decl___fpending" "$fp_headers + #include <stdio.h> + #if HAVE_STDIO_EXT_H + # include <stdio_ext.h> + #endif + ' + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __fpending" >&5 +$as_echo_n "checking for __fpending... " >&6; } +if ${gl_cv_func___fpending+:} false; then : + $as_echo_n "(cached) " >&6 +else + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$fp_headers +int +main () +{ +return ! __fpending (stdin); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + gl_cv_func___fpending=yes +else + gl_cv_func___fpending=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func___fpending" >&5 +$as_echo "$gl_cv_func___fpending" >&6; } + if test $gl_cv_func___fpending = yes; then + ac_fn_c_check_decl "$LINENO" "__fpending" "ac_cv_have_decl___fpending" "$fp_headers " if test "x$ac_cv_have_decl___fpending" = xyes; then : ac_have_decl=1 @@ -28671,8 +28479,9 @@ cat >>confdefs.h <<_ACEOF #define HAVE_DECL___FPENDING $ac_have_decl _ACEOF + fi - if test $ac_cv_func___fpending = no; then + if test $gl_cv_func___fpending = no; then @@ -28973,7 +28782,8 @@ else #include <float.h> #include <math.h> #include <string.h> -#if HAVE_ALARM +#if HAVE_DECL_ALARM +# include <signal.h> # include <unistd.h> #endif /* HP cc on HP-UX 10.20 has a bug with the constant expression -0.0. @@ -28996,9 +28806,10 @@ int main() int i; volatile double x; double zero = 0.0; -#if HAVE_ALARM +#if HAVE_DECL_ALARM /* NeXTstep 3.3 frexp() runs into an endless loop when called on an infinite number. Let the test fail in this case. */ + signal (SIGALRM, SIG_DFL); alarm (5); #endif /* Test on denormalized numbers. */ @@ -29396,7 +29207,7 @@ if ${gl_cv_func_fflush_stdin+:} false; then : else echo hello world > conftest.txt if test "$cross_compiling" = yes; then : - gl_cv_func_fflush_stdin=no + gl_cv_func_fflush_stdin=cross else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -29465,8 +29276,18 @@ fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fflush_stdin" >&5 $as_echo "$gl_cv_func_fflush_stdin" >&6; } + case $gl_cv_func_fflush_stdin in + yes) gl_func_fflush_stdin=1 ;; + no) gl_func_fflush_stdin=0 ;; + *) gl_func_fflush_stdin='(-1)' ;; + esac + +cat >>confdefs.h <<_ACEOF +#define FUNC_FFLUSH_STDIN $gl_func_fflush_stdin +_ACEOF - if test $gl_cv_func_fflush_stdin = no; then + + if test $gl_cv_func_fflush_stdin != yes; then REPLACE_FSEEKO=1 fi @@ -31189,6 +31010,9 @@ else # define is_ENAMETOOLONG(x) 0 #endif +/* Use the getcwd function, not any macro. */ +#undef getcwd + /* Don't get link errors because mkdir is redefined to rpl_mkdir. */ #undef mkdir @@ -31375,6 +31199,7 @@ else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +#include <errno.h> #include <stdlib.h> #if HAVE_UNISTD_H # include <unistd.h> @@ -31516,7 +31341,7 @@ fi ;; esac case "$gl_cv_func_getcwd_path_max" in - "no, it has the AIX bug") ;; + "no"|"no, it has the AIX bug") ;; *) $as_echo "#define HAVE_MINIMALLY_WORKING_GETCWD 1" >>confdefs.h @@ -31766,11 +31591,62 @@ $as_echo "#define GNULIB_TEST_GETDELIM 1" >>confdefs.h - if test $ac_cv_func_getdtablesize != yes; then + + if test $ac_cv_func_getdtablesize = yes; then + # Cygwin 1.7.25 automatically increases the RLIMIT_NOFILE soft limit + # up to an unchangeable hard limit; all other platforms correctly + # require setrlimit before getdtablesize() can report a larger value. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getdtablesize works" >&5 +$as_echo_n "checking whether getdtablesize works... " >&6; } +if ${gl_cv_func_getdtablesize_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + case "$host_os" in + cygwin*) # on cygwin 1.5.25, getdtablesize() automatically grows + gl_cv_func_getdtablesize_works="guessing no" ;; + *) gl_cv_func_getdtablesize_works="guessing yes" ;; + esac +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include <unistd.h> +int +main () +{ +int size = getdtablesize(); + if (dup2 (0, getdtablesize()) != -1) + return 1; + if (size != getdtablesize()) + return 2; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + gl_cv_func_getdtablesize_works=yes +else + gl_cv_func_getdtablesize_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getdtablesize_works" >&5 +$as_echo "$gl_cv_func_getdtablesize_works" >&6; } + case "$gl_cv_func_getdtablesize_works" in + *yes) ;; + *) REPLACE_GETDTABLESIZE=1 ;; + esac + else HAVE_GETDTABLESIZE=0 fi - if test $HAVE_GETDTABLESIZE = 0; then + if test $HAVE_GETDTABLESIZE = 0 || test $REPLACE_GETDTABLESIZE = 1; then @@ -33255,12 +33131,8 @@ $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; } *yes) REPLACE_GETTIMEOFDAY=1 - -$as_echo "#define gmtime rpl_gmtime" >>confdefs.h - - -$as_echo "#define localtime rpl_localtime" >>confdefs.h - + REPLACE_GMTIME=1 + REPLACE_LOCALTIME=1 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h @@ -33395,12 +33267,8 @@ $as_echo "#define HAVE_RUN_TZSET_TEST 1" >>confdefs.h *yes) REPLACE_GETTIMEOFDAY=1 - -$as_echo "#define gmtime rpl_gmtime" >>confdefs.h - - -$as_echo "#define localtime rpl_localtime" >>confdefs.h - + REPLACE_GMTIME=1 + REPLACE_LOCALTIME=1 $as_echo "#define tzset rpl_tzset" >>confdefs.h @@ -33827,36 +33695,40 @@ else if test $ac_cv_header_iconv_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <iconv.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'iconv.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_iconv_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'iconv.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_iconv_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_iconv_h + gl_cv_next_iconv_h='"'$gl_header'"' else gl_cv_next_iconv_h='<'iconv.h'>' fi @@ -35419,36 +35291,40 @@ else if test $ac_cv_header_langinfo_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <langinfo.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'langinfo.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_langinfo_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'langinfo.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_langinfo_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_langinfo_h + gl_cv_next_langinfo_h='"'$gl_header'"' else gl_cv_next_langinfo_h='<'langinfo.h'>' fi @@ -36283,36 +36159,40 @@ if ${gl_cv_next_locale_h+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <locale.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'locale.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_locale_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` - gl_header_literal_regex=`echo 'locale.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_locale_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + gl_header=$gl_cv_absolute_locale_h + gl_cv_next_locale_h='"'$gl_header'"' fi @@ -36408,6 +36288,9 @@ main () #if __FreeBSD__ == 4 error "No, in FreeBSD 4.0 recursive mutexes actually don't work." +#elif (defined __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ \ + && __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ < 1070) +error "No, in Mac OS X < 10.7 recursive mutexes actually don't work." #else int x = (int)PTHREAD_MUTEX_RECURSIVE; return !x; @@ -36428,6 +36311,13 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +cat >>confdefs.h <<_ACEOF +#define GNULIB_LOCK 1 +_ACEOF + + + + @@ -36587,6 +36477,7 @@ $as_echo "#define GNULIB_TEST_LSTAT 1" >>confdefs.h + for ac_header in stdlib.h do : ac_fn_c_check_header_mongrel "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default" @@ -36741,36 +36632,40 @@ else if test $ac_cv_header_math_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <math.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'math.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_math_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'math.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_math_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_math_h + gl_cv_next_math_h='"'$gl_header'"' else gl_cv_next_math_h='<'math.h'>' fi @@ -37466,6 +37361,49 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_nul_retval" >&5 $as_echo "$gl_cv_func_mbrtowc_nul_retval" >&6; } + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works on empty input" >&5 +$as_echo_n "checking whether mbrtowc works on empty input... " >&6; } +if ${gl_cv_func_mbrtowc_empty_input+:} false; then : + $as_echo_n "(cached) " >&6 +else + + case "$host_os" in + # Guess no on AIX and glibc systems. + aix* | *-gnu*) + gl_cv_func_mbrtowc_empty_input="guessing no" ;; + *) gl_cv_func_mbrtowc_empty_input="guessing yes" ;; + esac + if test "$cross_compiling" = yes; then : + : +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include <wchar.h> + static wchar_t wc; + static mbstate_t mbs; + int + main (void) + { + return mbrtowc (&wc, "", 0, &mbs) == (size_t) -2; + } +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + gl_cv_func_mbrtowc_empty_input=no +else + gl_cv_func_mbrtowc_empty_input=yes +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_empty_input" >&5 +$as_echo "$gl_cv_func_mbrtowc_empty_input" >&6; } + case "$gl_cv_func_mbrtowc_null_arg1" in *yes) ;; *) @@ -37498,6 +37436,14 @@ $as_echo "#define MBRTOWC_NUL_RETVAL_BUG 1" >>confdefs.h REPLACE_MBRTOWC=1 ;; esac + case "$gl_cv_func_mbrtowc_empty_input" in + *yes) ;; + *) +$as_echo "#define MBRTOWC_EMPTY_INPUT_BUG 1" >>confdefs.h + + REPLACE_MBRTOWC=1 + ;; + esac fi fi @@ -38910,8 +38856,8 @@ else # include <unistd.h> #endif -#ifndef HAVE_ALARM -# define alarm(X) /* empty */ +#if HAVE_DECL_ALARM +# include <signal.h> #endif /* Work around redefinition to rpl_putenv by other config tests. */ @@ -39047,10 +38993,13 @@ main () int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1; int time_t_signed = ! ((time_t) 0 < (time_t) -1); +#if HAVE_DECL_ALARM /* This test makes some buggy mktime implementations loop. Give up after 60 seconds; a mktime slower than that isn't worth using anyway. */ + signal (SIGALRM, SIG_DFL); alarm (60); +#endif time_t_max = (! time_t_signed ? (time_t) -1 @@ -39443,6 +39392,17 @@ $as_echo "$fu_cv_sys_mounted_getmntent1" >&6; } $as_echo "#define MOUNTED_GETMNTENT1 1" >>confdefs.h + for ac_func in hasmntopt +do : + ac_fn_c_check_func "$LINENO" "hasmntopt" "ac_cv_func_hasmntopt" +if test "x$ac_cv_func_hasmntopt" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_HASMNTOPT 1 +_ACEOF + +fi +done + fi fi @@ -40125,36 +40085,40 @@ else if test $ac_cv_header_netdb_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <netdb.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'netdb.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_netdb_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'netdb.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_netdb_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_netdb_h + gl_cv_next_netdb_h='"'$gl_header'"' else gl_cv_next_netdb_h='<'netdb.h'>' fi @@ -40252,36 +40216,40 @@ else if test $ac_cv_header_netinet_in_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <netinet/in.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'netinet/in.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_netinet_in_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'netinet/in.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_netinet_in_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_netinet_in_h + gl_cv_next_netinet_in_h='"'$gl_header'"' else gl_cv_next_netinet_in_h='<'netinet/in.h'>' fi @@ -40983,7 +40951,7 @@ fi done - for ac_func in pstat_getstatic pstat_getdynamic sysmp getsysinfo sysctl table + for ac_func in pstat_getstatic pstat_getdynamic sysmp getsysinfo sysctl table sysinfo do : as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" @@ -40995,7 +40963,16 @@ _ACEOF fi done + ac_fn_c_check_member "$LINENO" "struct sysinfo" "mem_unit" "ac_cv_member_struct_sysinfo_mem_unit" "#include <sys/sysinfo.h> +" +if test "x$ac_cv_member_struct_sysinfo_mem_unit" = xyes; then : +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_SYSINFO_MEM_UNIT 1 +_ACEOF + + +fi @@ -41003,30 +40980,35 @@ done - if test $ac_cv_func_pipe2 != yes; then - HAVE_PIPE2=0 + if test $ac_cv_func_pipe != yes; then + HAVE_PIPE=0 fi + if test $HAVE_PIPE = 0; then + - GNULIB_PIPE2=1 + gl_LIBOBJS="$gl_LIBOBJS pipe.$ac_objext" + fi -$as_echo "#define GNULIB_TEST_PIPE2 1" >>confdefs.h + GNULIB_PIPE=1 -cat >>confdefs.h <<_ACEOF -#define GNULIB_PIPE2_SAFER 1 -_ACEOF + + + +$as_echo "#define GNULIB_TEST_PIPE 1" >>confdefs.h + @@ -41085,500 +41067,6 @@ $as_echo "$gl_cv_posix_shell" >&6; } - - - - - - if test $REPLACE_POSIX_SPAWN = 1; then - REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE=1 - else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether posix_spawn_file_actions_addclose works" >&5 -$as_echo_n "checking whether posix_spawn_file_actions_addclose works... " >&6; } -if ${gl_cv_func_posix_spawn_file_actions_addclose_works+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - # Guess no on Solaris, yes otherwise. - case "$host_os" in - solaris*) gl_cv_func_posix_spawn_file_actions_addclose_works="guessing no";; - *) gl_cv_func_posix_spawn_file_actions_addclose_works="guessing yes";; - esac - -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -#include <spawn.h> -int main () -{ - posix_spawn_file_actions_t actions; - if (posix_spawn_file_actions_init (&actions) != 0) - return 1; - if (posix_spawn_file_actions_addclose (&actions, 10000000) == 0) - return 2; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - gl_cv_func_posix_spawn_file_actions_addclose_works=yes -else - gl_cv_func_posix_spawn_file_actions_addclose_works=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_posix_spawn_file_actions_addclose_works" >&5 -$as_echo "$gl_cv_func_posix_spawn_file_actions_addclose_works" >&6; } - case "$gl_cv_func_posix_spawn_file_actions_addclose_works" in - *yes) ;; - *) REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE=1 ;; - esac - fi - - if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE = 1; then - - - - - - - - - gl_LIBOBJS="$gl_LIBOBJS spawn_faction_addclose.$ac_objext" - - fi - - - - - - GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE=1 - - - - - -$as_echo "#define GNULIB_TEST_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE 1" >>confdefs.h - - - - - - - - - - if test $REPLACE_POSIX_SPAWN = 1; then - REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2=1 - else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether posix_spawn_file_actions_adddup2 works" >&5 -$as_echo_n "checking whether posix_spawn_file_actions_adddup2 works... " >&6; } -if ${gl_cv_func_posix_spawn_file_actions_adddup2_works+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - # Guess no on Solaris, yes otherwise. - case "$host_os" in - solaris*) gl_cv_func_posix_spawn_file_actions_adddup2_works="guessing no";; - *) gl_cv_func_posix_spawn_file_actions_adddup2_works="guessing yes";; - esac - -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -#include <spawn.h> -int main () -{ - posix_spawn_file_actions_t actions; - if (posix_spawn_file_actions_init (&actions) != 0) - return 1; - if (posix_spawn_file_actions_adddup2 (&actions, 10000000, 2) == 0) - return 2; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - gl_cv_func_posix_spawn_file_actions_adddup2_works=yes -else - gl_cv_func_posix_spawn_file_actions_adddup2_works=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_posix_spawn_file_actions_adddup2_works" >&5 -$as_echo "$gl_cv_func_posix_spawn_file_actions_adddup2_works" >&6; } - case "$gl_cv_func_posix_spawn_file_actions_adddup2_works" in - *yes) ;; - *) REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2=1 ;; - esac - fi - - if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2 = 1; then - - - - - - - - - gl_LIBOBJS="$gl_LIBOBJS spawn_faction_adddup2.$ac_objext" - - fi - - - - - - GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2=1 - - - - - -$as_echo "#define GNULIB_TEST_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2 1" >>confdefs.h - - - - - - - - - - if test $REPLACE_POSIX_SPAWN = 1; then - REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN=1 - else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether posix_spawn_file_actions_addopen works" >&5 -$as_echo_n "checking whether posix_spawn_file_actions_addopen works... " >&6; } -if ${gl_cv_func_posix_spawn_file_actions_addopen_works+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - # Guess no on Solaris, yes otherwise. - case "$host_os" in - solaris*) gl_cv_func_posix_spawn_file_actions_addopen_works="guessing no";; - *) gl_cv_func_posix_spawn_file_actions_addopen_works="guessing yes";; - esac - -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -#include <spawn.h> -#include <fcntl.h> -int main () -{ - posix_spawn_file_actions_t actions; - if (posix_spawn_file_actions_init (&actions) != 0) - return 1; - if (posix_spawn_file_actions_addopen (&actions, 10000000, "foo", 0, O_RDONLY) - == 0) - return 2; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - gl_cv_func_posix_spawn_file_actions_addopen_works=yes -else - gl_cv_func_posix_spawn_file_actions_addopen_works=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_posix_spawn_file_actions_addopen_works" >&5 -$as_echo "$gl_cv_func_posix_spawn_file_actions_addopen_works" >&6; } - case "$gl_cv_func_posix_spawn_file_actions_addopen_works" in - *yes) ;; - *) REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN=1 ;; - esac - fi - - if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN = 1; then - - - - - - - - - gl_LIBOBJS="$gl_LIBOBJS spawn_faction_addopen.$ac_objext" - - fi - - - - - - GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN=1 - - - - - -$as_echo "#define GNULIB_TEST_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN 1" >>confdefs.h - - - - - - - if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN = 1; then - - - - - - - - - gl_LIBOBJS="$gl_LIBOBJS spawn_faction_destroy.$ac_objext" - - fi - - - - - - GNULIB_POSIX_SPAWN_FILE_ACTIONS_DESTROY=1 - - - - - -$as_echo "#define GNULIB_TEST_POSIX_SPAWN_FILE_ACTIONS_DESTROY 1" >>confdefs.h - - - - - - - if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN = 1; then - - - - - - - - - gl_LIBOBJS="$gl_LIBOBJS spawn_faction_init.$ac_objext" - - fi - - - - - - GNULIB_POSIX_SPAWN_FILE_ACTIONS_INIT=1 - - - - - -$as_echo "#define GNULIB_TEST_POSIX_SPAWN_FILE_ACTIONS_INIT 1" >>confdefs.h - - - - - - - if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN = 1; then - - - - - - - - - gl_LIBOBJS="$gl_LIBOBJS spawnattr_destroy.$ac_objext" - - fi - - - - - - GNULIB_POSIX_SPAWNATTR_DESTROY=1 - - - - - -$as_echo "#define GNULIB_TEST_POSIX_SPAWNATTR_DESTROY 1" >>confdefs.h - - - - - - - if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN = 1; then - - - - - - - - - gl_LIBOBJS="$gl_LIBOBJS spawnattr_init.$ac_objext" - - fi - - - - - - GNULIB_POSIX_SPAWNATTR_INIT=1 - - - - - -$as_echo "#define GNULIB_TEST_POSIX_SPAWNATTR_INIT 1" >>confdefs.h - - - - - - - if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN = 1; then - - - - - - - - - gl_LIBOBJS="$gl_LIBOBJS spawnattr_setflags.$ac_objext" - - fi - - - - - - GNULIB_POSIX_SPAWNATTR_SETFLAGS=1 - - - - - -$as_echo "#define GNULIB_TEST_POSIX_SPAWNATTR_SETFLAGS 1" >>confdefs.h - - - - - - - if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN = 1; then - - - - - - - - - gl_LIBOBJS="$gl_LIBOBJS spawnattr_setsigmask.$ac_objext" - - fi - - - - - - GNULIB_POSIX_SPAWNATTR_SETSIGMASK=1 - - - - - -$as_echo "#define GNULIB_TEST_POSIX_SPAWNATTR_SETSIGMASK 1" >>confdefs.h - - - - - - - if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN = 1; then - - - - - - - - - gl_LIBOBJS="$gl_LIBOBJS spawnp.$ac_objext" - - - - - - - - - - gl_LIBOBJS="$gl_LIBOBJS spawni.$ac_objext" - - - for ac_header in paths.h -do : - ac_fn_c_check_header_mongrel "$LINENO" "paths.h" "ac_cv_header_paths_h" "$ac_includes_default" -if test "x$ac_cv_header_paths_h" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_PATHS_H 1 -_ACEOF - -fi - -done - - for ac_func in confstr sched_setparam sched_setscheduler setegid seteuid vfork -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -if eval test \"x\$"$as_ac_var"\" = x"yes"; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - -fi -done - - - fi - - - - - - GNULIB_POSIX_SPAWNP=1 - - - - - -$as_echo "#define GNULIB_TEST_POSIX_SPAWNP 1" >>confdefs.h - - - - : @@ -41609,7 +41097,8 @@ else #include <float.h> #include <math.h> #include <string.h> -#if HAVE_ALARM +#if HAVE_DECL_ALARM +# include <signal.h> # include <unistd.h> #endif /* HP cc on HP-UX 10.20 has a bug with the constant expression -0.0. @@ -41632,9 +41121,10 @@ int main() int i; volatile double x; double zero = 0.0; -#if HAVE_ALARM +#if HAVE_DECL_ALARM /* NeXTstep 3.3 frexp() runs into an endless loop when called on an infinite number. Let the test fail in this case. */ + signal (SIGALRM, SIG_DFL); alarm (5); #endif /* Test on denormalized numbers. */ @@ -42088,36 +41578,40 @@ else if test $ac_cv_header_pthread_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <pthread.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'pthread.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_pthread_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'pthread.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_pthread_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_pthread_h + gl_cv_next_pthread_h='"'$gl_header'"' else gl_cv_next_pthread_h='<'pthread.h'>' fi @@ -42143,6 +41637,37 @@ $as_echo "$gl_cv_next_pthread_h" >&6; } if test $ac_cv_header_pthread_h = yes; then HAVE_PTHREAD_H=1 + # mingw 3.0 uses winpthreads which installs broken macros via <pthread.h> + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <pthread.h> pollutes the namespace" >&5 +$as_echo_n "checking whether <pthread.h> pollutes the namespace... " >&6; } +if ${gl_cv_header_pthread_h_pollution+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <pthread.h> + #ifdef strtok_r + #error + break me + #endif + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + gl_cv_header_pthread_h_pollution=no +else + gl_cv_header_pthread_h_pollution=yes +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_pthread_h_pollution" >&5 +$as_echo "$gl_cv_header_pthread_h_pollution" >&6; } else HAVE_PTHREAD_H=0 fi @@ -42195,6 +41720,8 @@ fi gl_LIBOBJS="$gl_LIBOBJS pthread.$ac_objext" + elif test $gl_cv_header_pthread_h_pollution = yes; then + PTHREAD_H=pthread.h else PTHREAD_H= fi @@ -42260,6 +41787,13 @@ $as_echo "$gl_cv_lib_pthread" >&6; } +cat >>confdefs.h <<_ACEOF +#define GNULIB_PTHREAD 1 +_ACEOF + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for putenv compatible with GNU and SVID" >&5 $as_echo_n "checking for putenv compatible with GNU and SVID... " >&6; } if ${gl_cv_func_svid_putenv+:} false; then : @@ -42330,6 +41864,19 @@ $as_echo "$gl_cv_func_svid_putenv" >&6; } gl_LIBOBJS="$gl_LIBOBJS putenv.$ac_objext" + + ac_fn_c_check_decl "$LINENO" "_putenv" "ac_cv_have_decl__putenv" "$ac_includes_default" +if test "x$ac_cv_have_decl__putenv" = xyes; then : + ac_have_decl=1 +else + ac_have_decl=0 +fi + +cat >>confdefs.h <<_ACEOF +#define HAVE_DECL__PUTENV $ac_have_decl +_ACEOF + + fi @@ -42347,101 +41894,494 @@ $as_echo "#define GNULIB_TEST_PUTENV 1" >>confdefs.h - : + # Check whether --enable-acl was given. +if test "${enable_acl+set}" = set; then : + enableval=$enable_acl; +else + enable_acl=auto +fi - : + LIB_ACL= + use_acl=0 + if test "x$enable_acl" != "xno"; then + for ac_header in sys/acl.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "sys/acl.h" "ac_cv_header_sys_acl_h" "$ac_includes_default" +if test "x$ac_cv_header_sys_acl_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SYS_ACL_H 1 +_ACEOF + +fi +done + if test $ac_cv_header_sys_acl_h = yes; then + ac_save_LIBS=$LIBS + if test $use_acl = 0; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing acl_get_file" >&5 +$as_echo_n "checking for library containing acl_get_file... " >&6; } +if ${ac_cv_search_acl_get_file+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - for ac_func in raise +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char acl_get_file (); +int +main () +{ +return acl_get_file (); + ; + return 0; +} +_ACEOF +for ac_lib in '' acl pacl; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_acl_get_file=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_acl_get_file+:} false; then : + break +fi +done +if ${ac_cv_search_acl_get_file+:} false; then : + +else + ac_cv_search_acl_get_file=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_acl_get_file" >&5 +$as_echo "$ac_cv_search_acl_get_file" >&6; } +ac_res=$ac_cv_search_acl_get_file +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + if test "$ac_cv_search_acl_get_file" != "none required"; then + LIB_ACL=$ac_cv_search_acl_get_file + fi + for ac_func in acl_get_file acl_get_fd acl_set_file acl_set_fd \ + acl_free acl_from_mode acl_from_text \ + acl_delete_def_file acl_extended_file \ + acl_delete_fd_np acl_delete_file_np \ + acl_copy_ext_native acl_create_entry_np \ + acl_to_short_text acl_free_text do : - ac_fn_c_check_func "$LINENO" "raise" "ac_cv_func_raise" -if test "x$ac_cv_func_raise" = xyes; then : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF -#define HAVE_RAISE 1 +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF fi done - if test $ac_cv_func_raise = no; then - HAVE_RAISE=0 - else - if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then - REPLACE_RAISE=1 - fi + # If the acl_get_file bug is detected, don't enable the ACL support. + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working acl_get_file" >&5 +$as_echo_n "checking for working acl_get_file... " >&6; } +if ${gl_cv_func_working_acl_get_file+:} false; then : + $as_echo_n "(cached) " >&6 +else + gl_cv_func_working_acl_get_file=no + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <sys/types.h> + #include <sys/acl.h> + #include <errno.h> + +int +main () +{ +if (!acl_get_file (".", ACL_TYPE_ACCESS) && errno == ENOENT) + return 1; + return 0; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + if test $cross_compiling = yes; then + gl_cv_func_working_acl_get_file="guessing yes" + elif ./conftest$ac_exeext; then + gl_cv_func_working_acl_get_file=yes + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_acl_get_file" >&5 +$as_echo "$gl_cv_func_working_acl_get_file" >&6; } + if test "$gl_cv_func_working_acl_get_file" != no; then : + use_acl=1 +fi + if test $use_acl = 1; then + for ac_header in acl/libacl.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "acl/libacl.h" "ac_cv_header_acl_libacl_h" "$ac_includes_default" +if test "x$ac_cv_header_acl_libacl_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_ACL_LIBACL_H 1 +_ACEOF +fi +done + + + + + + + + + + for ac_func in acl_entries +do : + ac_fn_c_check_func "$LINENO" "acl_entries" "ac_cv_func_acl_entries" +if test "x$ac_cv_func_acl_entries" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_ACL_ENTRIES 1 +_ACEOF + +else + + gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext" - if test $gl_cv_type_sigset_t = yes; then - ac_fn_c_check_func "$LINENO" "sigprocmask" "ac_cv_func_sigprocmask" -if test "x$ac_cv_func_sigprocmask" = xyes; then : - gl_cv_func_sigprocmask=1 fi +done - fi - if test -z "$gl_cv_func_sigprocmask"; then - HAVE_POSIX_SIGNALBLOCKING=0 - fi - if test $HAVE_POSIX_SIGNALBLOCKING = 0; then - : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ACL_FIRST_ENTRY" >&5 +$as_echo_n "checking for ACL_FIRST_ENTRY... " >&6; } +if ${gl_cv_acl_ACL_FIRST_ENTRY+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <sys/types.h> +#include <sys/acl.h> +int type = ACL_FIRST_ENTRY; +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + gl_cv_acl_ACL_FIRST_ENTRY=yes +else + gl_cv_acl_ACL_FIRST_ENTRY=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_acl_ACL_FIRST_ENTRY" >&5 +$as_echo "$gl_cv_acl_ACL_FIRST_ENTRY" >&6; } + if test $gl_cv_acl_ACL_FIRST_ENTRY = yes; then + +$as_echo "#define HAVE_ACL_FIRST_ENTRY 1" >>confdefs.h + + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ACL_TYPE_EXTENDED" >&5 +$as_echo_n "checking for ACL_TYPE_EXTENDED... " >&6; } +if ${gl_cv_acl_ACL_TYPE_EXTENDED+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <sys/types.h> +#include <sys/acl.h> +int type = ACL_TYPE_EXTENDED; +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + gl_cv_acl_ACL_TYPE_EXTENDED=yes +else + gl_cv_acl_ACL_TYPE_EXTENDED=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_acl_ACL_TYPE_EXTENDED" >&5 +$as_echo "$gl_cv_acl_ACL_TYPE_EXTENDED" >&6; } + if test $gl_cv_acl_ACL_TYPE_EXTENDED = yes; then + +$as_echo "#define HAVE_ACL_TYPE_EXTENDED 1" >>confdefs.h + + fi + else + LIB_ACL= + fi + +fi + fi + if test $use_acl = 0; then + for ac_func in facl +do : + ac_fn_c_check_func "$LINENO" "facl" "ac_cv_func_facl" +if test "x$ac_cv_func_facl" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_FACL 1 +_ACEOF + +fi +done + + if test $ac_cv_func_facl = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing acl_trivial" >&5 +$as_echo_n "checking for library containing acl_trivial... " >&6; } +if ${ac_cv_search_acl_trivial+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char acl_trivial (); +int +main () +{ +return acl_trivial (); + ; + return 0; +} +_ACEOF +for ac_lib in '' sec; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_acl_trivial=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_acl_trivial+:} false; then : + break +fi +done +if ${ac_cv_search_acl_trivial+:} false; then : - if test $HAVE_RAISE = 0 || test $REPLACE_RAISE = 1; then +else + ac_cv_search_acl_trivial=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_acl_trivial" >&5 +$as_echo "$ac_cv_search_acl_trivial" >&6; } +ac_res=$ac_cv_search_acl_trivial +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + if test "$ac_cv_search_acl_trivial" != "none required"; then + LIB_ACL=$ac_cv_search_acl_trivial + fi +fi + for ac_func in acl_trivial +do : + ac_fn_c_check_func "$LINENO" "acl_trivial" "ac_cv_func_acl_trivial" +if test "x$ac_cv_func_acl_trivial" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_ACL_TRIVIAL 1 +_ACEOF +fi +done + use_acl=1 + fi + fi + if test $use_acl = 0; then + for ac_func in getacl +do : + ac_fn_c_check_func "$LINENO" "getacl" "ac_cv_func_getacl" +if test "x$ac_cv_func_getacl" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_GETACL 1 +_ACEOF +fi +done + if test $ac_cv_func_getacl = yes; then + use_acl=1 + fi + for ac_header in aclv.h +do : + ac_fn_c_check_header_compile "$LINENO" "aclv.h" "ac_cv_header_aclv_h" "#include <sys/types.h> +" +if test "x$ac_cv_header_aclv_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_ACLV_H 1 +_ACEOF - gl_LIBOBJS="$gl_LIBOBJS raise.$ac_objext" +fi - : - fi +done + fi + if test $use_acl = 0; then + for ac_func in aclx_get +do : + ac_fn_c_check_func "$LINENO" "aclx_get" "ac_cv_func_aclx_get" +if test "x$ac_cv_func_aclx_get" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_ACLX_GET 1 +_ACEOF +fi +done + if test $ac_cv_func_aclx_get = yes; then + use_acl=1 + fi + fi - GNULIB_RAISE=1 + if test $use_acl = 0 || test "$ac_cv_func_aclx_get" = yes; then + for ac_func in statacl +do : + ac_fn_c_check_func "$LINENO" "statacl" "ac_cv_func_statacl" +if test "x$ac_cv_func_statacl" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_STATACL 1 +_ACEOF +fi +done + if test $ac_cv_func_statacl = yes; then + use_acl=1 + fi + fi + if test $use_acl = 0; then + for ac_func in aclsort +do : + ac_fn_c_check_func "$LINENO" "aclsort" "ac_cv_func_aclsort" +if test "x$ac_cv_func_aclsort" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_ACLSORT 1 +_ACEOF +fi +done -$as_echo "#define GNULIB_TEST_RAISE 1" >>confdefs.h + if test $ac_cv_func_aclsort = yes; then + use_acl=1 + fi + fi + + LIBS=$ac_save_LIBS + fi + if test "x$enable_acl$use_acl" = "xyes0"; then + as_fn_error $? "ACLs enabled but support not detected" "$LINENO" 5 + elif test "x$enable_acl$use_acl" = "xauto0"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libacl development library was not found or not usable." >&5 +$as_echo "$as_me: WARNING: libacl development library was not found or not usable." >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: GNU coreutils will be built without ACL support." >&5 +$as_echo "$as_me: WARNING: GNU coreutils will be built without ACL support." >&2;} + fi + fi + + +cat >>confdefs.h <<_ACEOF +#define USE_ACL $use_acl +_ACEOF + + USE_ACL=$use_acl + + + + : + : - for ac_func in rawmemchr + for ac_func in raise do : - ac_fn_c_check_func "$LINENO" "rawmemchr" "ac_cv_func_rawmemchr" -if test "x$ac_cv_func_rawmemchr" = xyes; then : + ac_fn_c_check_func "$LINENO" "raise" "ac_cv_func_raise" +if test "x$ac_cv_func_raise" = xyes; then : cat >>confdefs.h <<_ACEOF -#define HAVE_RAWMEMCHR 1 +#define HAVE_RAISE 1 _ACEOF fi done - if test $ac_cv_func_rawmemchr = no; then - HAVE_RAWMEMCHR=0 + if test $ac_cv_func_raise = no; then + HAVE_RAISE=0 + else + if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then + REPLACE_RAISE=1 + fi + + + + + if test $gl_cv_type_sigset_t = yes; then + ac_fn_c_check_func "$LINENO" "sigprocmask" "ac_cv_func_sigprocmask" +if test "x$ac_cv_func_sigprocmask" = xyes; then : + gl_cv_func_sigprocmask=1 +fi + + fi + if test -z "$gl_cv_func_sigprocmask"; then + HAVE_POSIX_SIGNALBLOCKING=0 fi - if test $HAVE_RAWMEMCHR = 0; then + if test $HAVE_POSIX_SIGNALBLOCKING = 0; then + : + fi + + fi + + if test $HAVE_RAISE = 0 || test $REPLACE_RAISE = 1; then @@ -42450,7 +42390,7 @@ done - gl_LIBOBJS="$gl_LIBOBJS rawmemchr.$ac_objext" + gl_LIBOBJS="$gl_LIBOBJS raise.$ac_objext" : fi @@ -42459,13 +42399,13 @@ done - GNULIB_RAWMEMCHR=1 + GNULIB_RAISE=1 -$as_echo "#define GNULIB_TEST_RAWMEMCHR 1" >>confdefs.h +$as_echo "#define GNULIB_TEST_RAISE 1" >>confdefs.h @@ -43131,6 +43071,7 @@ fi # If cross compiling, assume the test would fail and use the included # regex.c. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working re_compile_pattern" >&5 $as_echo_n "checking for working re_compile_pattern... " >&6; } if ${gl_cv_func_re_compile_pattern_working+:} false; then : @@ -43146,9 +43087,19 @@ else #include <locale.h> #include <limits.h> #include <string.h> - #if HAVE_ALARM - # include <unistd.h> + + #if defined M_CHECK_ACTION || HAVE_DECL_ALARM # include <signal.h> + # include <unistd.h> + #endif + + #if HAVE_MALLOC_H + # include <malloc.h> + #endif + + #ifdef M_CHECK_ACTION + /* Exit with distinguishable exit code. */ + static void sigabrt_no_core (int sig) { raise (SIGTERM); } #endif int @@ -43161,11 +43112,18 @@ int result = 0; const char *s; struct re_registers regs; -#if HAVE_ALARM - /* Some builds of glibc go into an infinite loop on this test. */ + /* Some builds of glibc go into an infinite loop on this + test. Use alarm to force death, and mallopt to avoid + malloc recursion in diagnosing the corrupted heap. */ +#if HAVE_DECL_ALARM signal (SIGALRM, SIG_DFL); alarm (2); #endif +#ifdef M_CHECK_ACTION + signal (SIGABRT, sigabrt_no_core); + mallopt (M_CHECK_ACTION, 2); +#endif + if (setlocale (LC_ALL, "en_US.UTF-8")) { { @@ -43196,17 +43154,28 @@ int result = 0; */ static char const pat[] = "[^x]x"; static char const data[] = - "\xe1\x80\x80\xe1\x80\xbb\xe1\x80\xbd\xe1\x80\x94\xe1\x80" - "\xba\xe1\x80\xaf\xe1\x80\x95\xe1\x80\xbax"; + /* <U1000><U103B><U103D><U1014><U103A><U102F><U1015><U103A> */ + "\xe1\x80\x80" + "\xe1\x80\xbb" + "\xe1\x80\xbd" + "\xe1\x80\x94" + "\xe1\x80\xba" + "\xe1\x80\xaf" + "\xe1\x80\x95" + "\xe1\x80\xba" + "x"; re_set_syntax (0); memset (®ex, 0, sizeof regex); s = re_compile_pattern (pat, sizeof pat - 1, ®ex); if (s) result |= 1; - else if (re_search (®ex, data, sizeof data - 1, - 0, sizeof data - 1, 0) - != 21) - result |= 1; + else + { + i = re_search (®ex, data, sizeof data - 1, + 0, sizeof data - 1, 0); + if (i != 0 && i != 21) + result |= 1; + } } if (! setlocale (LC_ALL, "C")) @@ -43403,6 +43372,7 @@ $as_echo "#define regfree rpl_regfree" >>confdefs.h + for ac_header in libintl.h do : ac_fn_c_check_header_mongrel "$LINENO" "libintl.h" "ac_cv_header_libintl_h" "$ac_includes_default" @@ -44094,36 +44064,40 @@ else if test $ac_cv_header_sched_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <sched.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'sched.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_sched_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'sched.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_sched_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_sched_h + gl_cv_next_sched_h='"'$gl_header'"' else gl_cv_next_sched_h='<'sched.h'>' fi @@ -44182,6 +44156,68 @@ fi + + + if test $ac_cv_func_secure_getenv = no; then + HAVE_SECURE_GETENV=0 + fi + + if test $HAVE_SECURE_GETENV = 0; then + + + + + + + + + gl_LIBOBJS="$gl_LIBOBJS secure_getenv.$ac_objext" + + + for ac_func in __secure_getenv +do : + ac_fn_c_check_func "$LINENO" "__secure_getenv" "ac_cv_func___secure_getenv" +if test "x$ac_cv_func___secure_getenv" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE___SECURE_GETENV 1 +_ACEOF + +fi +done + + if test $ac_cv_func___secure_getenv = no; then + for ac_func in issetugid +do : + ac_fn_c_check_func "$LINENO" "issetugid" "ac_cv_func_issetugid" +if test "x$ac_cv_func_issetugid" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_ISSETUGID 1 +_ACEOF + +fi +done + + fi + + fi + + + + + + GNULIB_SECURE_GETENV=1 + + + + + +$as_echo "#define GNULIB_TEST_SECURE_GETENV 1" >>confdefs.h + + + + + + if test "$ac_cv_header_winsock2_h" = yes; then REPLACE_SELECT=1 else @@ -44417,36 +44453,40 @@ else if test $ac_cv_header_selinux_selinux_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <selinux/selinux.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'selinux/selinux.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_selinux_selinux_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'selinux/selinux.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_selinux_selinux_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_selinux_selinux_h + gl_cv_next_selinux_selinux_h='"'$gl_header'"' else gl_cv_next_selinux_selinux_h='<'selinux/selinux.h'>' fi @@ -44877,36 +44917,40 @@ if ${gl_cv_next_signal_h+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <signal.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'signal.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_signal_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` - gl_header_literal_regex=`echo 'signal.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_signal_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + gl_header=$gl_cv_absolute_signal_h + gl_cv_next_signal_h='"'$gl_header'"' fi @@ -45854,6 +45898,112 @@ _ACEOF fi + # Check whether libsmack is available + LIB_SMACK= + # Check whether --enable-libsmack was given. +if test "${enable_libsmack+set}" = set; then : + enableval=$enable_libsmack; +fi + + if test "X$enable_libsmack" != "Xno"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for smack_new_label_from_self in -lsmack" >&5 +$as_echo_n "checking for smack_new_label_from_self in -lsmack... " >&6; } +if ${ac_cv_lib_smack_smack_new_label_from_self+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lsmack $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char smack_new_label_from_self (); +int +main () +{ +return smack_new_label_from_self (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_smack_smack_new_label_from_self=yes +else + ac_cv_lib_smack_smack_new_label_from_self=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_smack_smack_new_label_from_self" >&5 +$as_echo "$ac_cv_lib_smack_smack_new_label_from_self" >&6; } +if test "x$ac_cv_lib_smack_smack_new_label_from_self" = xyes; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for smack_new_label_from_path in -lsmack" >&5 +$as_echo_n "checking for smack_new_label_from_path in -lsmack... " >&6; } +if ${ac_cv_lib_smack_smack_new_label_from_path+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lsmack $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char smack_new_label_from_path (); +int +main () +{ +return smack_new_label_from_path (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_smack_smack_new_label_from_path=yes +else + ac_cv_lib_smack_smack_new_label_from_path=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_smack_smack_new_label_from_path" >&5 +$as_echo "$ac_cv_lib_smack_smack_new_label_from_path" >&6; } +if test "x$ac_cv_lib_smack_smack_new_label_from_path" = xyes; then : + ac_fn_c_check_header_mongrel "$LINENO" "sys/smack.h" "ac_cv_header_sys_smack_h" "$ac_includes_default" +if test "x$ac_cv_header_sys_smack_h" = xyes; then : + LIB_SMACK=-lsmack + +$as_echo "#define HAVE_SMACK 1" >>confdefs.h + + +fi + + +fi + +fi + + if test "X$LIB_SMACK" = "X"; then + if test "X$enable_libsmack" = "Xyes"; then + as_fn_error $? "libsmack library was not found or not usable" "$LINENO" 5 + fi + fi + else + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libsmack support disabled by user" >&5 +$as_echo "$as_me: WARNING: libsmack support disabled by user" >&2;} + fi + gl_cv_func_snprintf_usable=no @@ -46285,136 +46435,6 @@ _ACEOF fi - - - - - - - - - - - - if test $gl_cv_have_include_next = yes; then - gl_cv_next_spawn_h='<'spawn.h'>' - else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <spawn.h>" >&5 -$as_echo_n "checking absolute name of <spawn.h>... " >&6; } -if ${gl_cv_next_spawn_h+:} false; then : - $as_echo_n "(cached) " >&6 -else - - if test $ac_cv_header_spawn_h = yes; then - - - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include <spawn.h> - -_ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac - - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'spawn.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_spawn_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' - else - gl_cv_next_spawn_h='<'spawn.h'>' - fi - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_spawn_h" >&5 -$as_echo "$gl_cv_next_spawn_h" >&6; } - fi - NEXT_SPAWN_H=$gl_cv_next_spawn_h - - if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then - # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' - gl_next_as_first_directive='<'spawn.h'>' - else - # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' - gl_next_as_first_directive=$gl_cv_next_spawn_h - fi - NEXT_AS_FIRST_DIRECTIVE_SPAWN_H=$gl_next_as_first_directive - - - - - - if test $ac_cv_header_spawn_h = yes; then - HAVE_SPAWN_H=1 - ac_fn_c_check_type "$LINENO" "posix_spawnattr_t" "ac_cv_type_posix_spawnattr_t" " -#include <spawn.h> - -" -if test "x$ac_cv_type_posix_spawnattr_t" = xyes; then : - -cat >>confdefs.h <<_ACEOF -#define HAVE_POSIX_SPAWNATTR_T 1 -_ACEOF - - -else - HAVE_POSIX_SPAWNATTR_T=0 -fi - - ac_fn_c_check_type "$LINENO" "posix_spawn_file_actions_t" "ac_cv_type_posix_spawn_file_actions_t" " -#include <spawn.h> - -" -if test "x$ac_cv_type_posix_spawn_file_actions_t" = xyes; then : - -cat >>confdefs.h <<_ACEOF -#define HAVE_POSIX_SPAWN_FILE_ACTIONS_T 1 -_ACEOF - - -else - HAVE_POSIX_SPAWN_FILE_ACTIONS_T=0 -fi - - else - HAVE_SPAWN_H=0 - HAVE_POSIX_SPAWNATTR_T=0 - HAVE_POSIX_SPAWN_FILE_ACTIONS_T=0 - fi - - - - - - - - - - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5 $as_echo_n "checking for ssize_t... " >&6; } if ${gt_cv_ssize_t+:} false; then : @@ -46754,10 +46774,12 @@ else /* Test _Alignas only on platforms where gnulib can help. */ #if \ - (__GNUC__ || __IBMC__ || __IBMCPP__ \ + ((defined __cplusplus && 201103 <= __cplusplus) \ + || __GNUC__ || __IBMC__ || __IBMCPP__ || __ICC \ || 0x5110 <= __SUNPRO_C || 1300 <= _MSC_VER) - int alignas (8) alignas_int = 1; - char test_alignas[_Alignof (alignas_int) == 8 ? 1 : -1]; + struct alignas_test { char c; char alignas (8) alignas_8; }; + char test_alignas[offsetof (struct alignas_test, alignas_8) == 8 + ? 1 : -1]; #endif int @@ -46863,36 +46885,40 @@ if ${gl_cv_next_stdarg_h+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <stdarg.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'stdarg.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_stdarg_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` - gl_header_literal_regex=`echo 'stdarg.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + gl_header=$gl_cv_absolute_stdarg_h + gl_cv_next_stdarg_h='"'$gl_header'"' fi @@ -47066,36 +47092,40 @@ if ${gl_cv_next_stddef_h+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <stddef.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'stddef.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_stddef_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` - gl_header_literal_regex=`echo 'stddef.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + gl_header=$gl_cv_absolute_stddef_h + gl_cv_next_stddef_h='"'$gl_header'"' fi @@ -47138,36 +47168,40 @@ if ${gl_cv_next_stdio_h+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <stdio.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'stdio.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_stdio_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` - gl_header_literal_regex=`echo 'stdio.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + gl_header=$gl_cv_absolute_stdio_h + gl_cv_next_stdio_h='"'$gl_header'"' fi @@ -47246,36 +47280,40 @@ if ${gl_cv_next_stdlib_h+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <stdlib.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'stdlib.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_stdlib_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` - gl_header_literal_regex=`echo 'stdlib.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + gl_header=$gl_cv_absolute_stdlib_h + gl_cv_next_stdlib_h='"'$gl_header'"' fi @@ -47488,115 +47526,6 @@ $as_echo "#define GNULIB_TEST_STPNCPY 1" >>confdefs.h - for ac_func in strchrnul -do : - ac_fn_c_check_func "$LINENO" "strchrnul" "ac_cv_func_strchrnul" -if test "x$ac_cv_func_strchrnul" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_STRCHRNUL 1 -_ACEOF - -fi -done - - if test $ac_cv_func_strchrnul = no; then - HAVE_STRCHRNUL=0 - else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strchrnul works" >&5 -$as_echo_n "checking whether strchrnul works... " >&6; } -if ${gl_cv_func_strchrnul_works+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -#if defined __CYGWIN__ - #include <cygwin/version.h> - #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 9) - Lucky user - #endif -#else - Lucky user -#endif - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "Lucky user" >/dev/null 2>&1; then : - gl_cv_func_strchrnul_works="guessing yes" -else - gl_cv_func_strchrnul_works="guessing no" -fi -rm -f conftest* - - -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -#include <string.h> /* for strchrnul */ - -int -main () -{ -const char *buf = "a"; - return strchrnul (buf, 'b') != buf + 1; - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - gl_cv_func_strchrnul_works=yes -else - gl_cv_func_strchrnul_works=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strchrnul_works" >&5 -$as_echo "$gl_cv_func_strchrnul_works" >&6; } - case "$gl_cv_func_strchrnul_works" in - *yes) ;; - *) REPLACE_STRCHRNUL=1 ;; - esac - fi - - if test $HAVE_STRCHRNUL = 0 || test $REPLACE_STRCHRNUL = 1; then - - - - - - - - - gl_LIBOBJS="$gl_LIBOBJS strchrnul.$ac_objext" - - : - fi - - - - - - GNULIB_STRCHRNUL=1 - - - - - -$as_echo "#define GNULIB_TEST_STRCHRNUL 1" >>confdefs.h - - - - - - - if test $ac_cv_func_strdup = yes; then if test $gl_cv_func_malloc_posix != yes; then REPLACE_STRDUP=1 @@ -48467,7 +48396,7 @@ $as_echo "#define GNULIB_TEST_STRTOD 1" >>confdefs.h HAVE_DECL_STRTOIMAX=0 fi - if test $ac_cv_func_strtoimax = yes; then + if test "$ac_cv_func_strtoimax" = yes; then HAVE_STRTOIMAX=1 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtoimax works" >&5 $as_echo_n "checking whether strtoimax works... " >&6; } @@ -48540,10 +48469,14 @@ $as_echo "$gl_cv_func_strtoimax" >&6; } *no) REPLACE_STRTOIMAX=1 ;; esac else + if test "$ac_cv_have_decl_strtoimax" = yes; then + # HP-UX 11.11 has "#define strtoimax(...) ..." but no function. + REPLACE_STRTOIMAX=1 + fi HAVE_STRTOIMAX=0 fi - if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then + if test $HAVE_DECL_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then @@ -48684,11 +48617,16 @@ $as_echo "#define GNULIB_TEST_STRTOULL 1" >>confdefs.h - if test "$ac_cv_have_decl_strtoumax" != yes; then + if test "$ac_cv_have_decl_strtoumax" = yes; then + if test "$ac_cv_func_strtoumax" != yes; then + # HP-UX 11.11 has "#define strtoimax(...) ..." but no function. + REPLACE_STRTOUMAX=1 + fi + else HAVE_DECL_STRTOUMAX=0 fi - if test $ac_cv_func_strtoumax = no; then + if test $HAVE_DECL_STRTOUMAX = 0 || test $REPLACE_STRTOUMAX = 1; then @@ -48870,36 +48808,40 @@ else if test $ac_cv_header_sys_ioctl_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <sys/ioctl.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'sys/ioctl.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_sys_ioctl_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'sys/ioctl.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_sys_ioctl_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_sys_ioctl_h + gl_cv_next_sys_ioctl_h='"'$gl_header'"' else gl_cv_next_sys_ioctl_h='<'sys/ioctl.h'>' fi @@ -48950,36 +48892,40 @@ else if test $ac_cv_header_sys_resource_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <sys/resource.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'sys/resource.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_sys_resource_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'sys/resource.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_sys_resource_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_sys_resource_h + gl_cv_next_sys_resource_h='"'$gl_header'"' else gl_cv_next_sys_resource_h='<'sys/resource.h'>' fi @@ -49118,36 +49064,40 @@ else if test $ac_cv_header_sys_select_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <sys/select.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'sys/select.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'sys/select.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_sys_select_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_sys_select_h + gl_cv_next_sys_select_h='"'$gl_header'"' else gl_cv_next_sys_select_h='<'sys/select.h'>' fi @@ -49316,36 +49266,40 @@ else if test $ac_cv_header_sys_socket_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <sys/socket.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'sys/socket.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_sys_socket_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'sys/socket.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_sys_socket_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_sys_socket_h + gl_cv_next_sys_socket_h='"'$gl_header'"' else gl_cv_next_sys_socket_h='<'sys/socket.h'>' fi @@ -49515,36 +49469,40 @@ else if test $ac_cv_header_sys_stat_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <sys/stat.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'sys/stat.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'sys/stat.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_sys_stat_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_sys_stat_h + gl_cv_next_sys_stat_h='"'$gl_header'"' else gl_cv_next_sys_stat_h='<'sys/stat.h'>' fi @@ -49610,81 +49568,6 @@ fi - if test $gl_cv_have_include_next = yes; then - gl_cv_next_sys_types_h='<'sys/types.h'>' - else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/types.h>" >&5 -$as_echo_n "checking absolute name of <sys/types.h>... " >&6; } -if ${gl_cv_next_sys_types_h+:} false; then : - $as_echo_n "(cached) " >&6 -else - - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include <sys/types.h> - -_ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac - - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'sys/types.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_sys_types_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_types_h" >&5 -$as_echo "$gl_cv_next_sys_types_h" >&6; } - fi - NEXT_SYS_TYPES_H=$gl_cv_next_sys_types_h - - if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then - # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' - gl_next_as_first_directive='<'sys/types.h'>' - else - # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' - gl_next_as_first_directive=$gl_cv_next_sys_types_h - fi - NEXT_AS_FIRST_DIRECTIVE_SYS_TYPES_H=$gl_next_as_first_directive - - - - - - - - - - - - - - - - - - - - @@ -49700,36 +49583,40 @@ else if test $ac_cv_header_sys_uio_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <sys/uio.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'sys/uio.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_sys_uio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'sys/uio.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_sys_uio_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_sys_uio_h + gl_cv_next_sys_uio_h='"'$gl_header'"' else gl_cv_next_sys_uio_h='<'sys/uio.h'>' fi @@ -49785,36 +49672,40 @@ else if test $ac_cv_header_sys_utsname_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <sys/utsname.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'sys/utsname.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_sys_utsname_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'sys/utsname.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_sys_utsname_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_sys_utsname_h + gl_cv_next_sys_utsname_h='"'$gl_header'"' else gl_cv_next_sys_utsname_h='<'sys/utsname.h'>' fi @@ -49891,36 +49782,40 @@ else if test $ac_cv_header_sys_wait_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <sys/wait.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'sys/wait.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_sys_wait_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'sys/wait.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_sys_wait_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_sys_wait_h + gl_cv_next_sys_wait_h='"'$gl_header'"' else gl_cv_next_sys_wait_h='<'sys/wait.h'>' fi @@ -49979,36 +49874,40 @@ else if test $ac_cv_header_termios_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <termios.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'termios.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_termios_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'termios.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_termios_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_termios_h + gl_cv_next_termios_h='"'$gl_header'"' else gl_cv_next_termios_h='<'termios.h'>' fi @@ -50150,6 +50049,7 @@ $as_echo "#define GNULIB_TEST_TIME_R 1" >>confdefs.h + LIB_TIMER_TIME= gl_saved_libs=$LIBS @@ -50210,16 +50110,15 @@ if test "$ac_res" != no; then : LIB_TIMER_TIME=$ac_cv_search_timer_settime fi - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ - #include <features.h> -#ifdef __GNU_LIBRARY__ - #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2) || (__GLIBC__ > 2)) \ - && !defined __UCLIBC__ - Thread emulation available - #endif -#endif + #ifdef __GNU_LIBRARY__ + #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2) || (__GLIBC__ > 2)) \ + && !(__UCLIBC__ && __HAS_NO_THREADS__) + Thread emulation available + #endif + #endif _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | @@ -50315,36 +50214,40 @@ else if test $ac_cv_header_unistd_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <unistd.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'unistd.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'unistd.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_unistd_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_unistd_h + gl_cv_next_unistd_h='"'$gl_header'"' else gl_cv_next_unistd_h='<'unistd.h'>' fi @@ -52169,54 +52072,6 @@ $as_echo "#define GNULIB_TEST_VPRINTF_POSIX 1" >>confdefs.h - for ac_func in waitid -do : - ac_fn_c_check_func "$LINENO" "waitid" "ac_cv_func_waitid" -if test "x$ac_cv_func_waitid" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_WAITID 1 -_ACEOF - -fi -done - - - - - HAVE_WAITPID=1 - case $host_os in - mingw*) HAVE_WAITPID=0 ;; - esac - - if test $HAVE_WAITPID = 0; then - - - - - - - - - gl_LIBOBJS="$gl_LIBOBJS waitpid.$ac_objext" - - fi - - - - - - GNULIB_WAITPID=1 - - - - - -$as_echo "#define GNULIB_TEST_WAITPID 1" >>confdefs.h - - - - - @@ -52239,36 +52094,40 @@ else if test $ac_cv_header_wchar_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <wchar.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'wchar.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_wchar_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'wchar.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_wchar_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_wchar_h + gl_cv_next_wchar_h='"'$gl_header'"' else gl_cv_next_wchar_h='<'wchar.h'>' fi @@ -52688,36 +52547,40 @@ else if test $ac_cv_header_wctype_h = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <wctype.h> - _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac - case "$host_os" in - mingw*) - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' - - gl_header_literal_regex=`echo 'wctype.h' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ - s|^/[^/]|//&| - p - q - }' - gl_cv_next_wctype_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n "$gl_absolute_header_sed"`'"' + case "$host_os" in + mingw*) + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo 'wctype.h' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' + + gl_cv_absolute_wctype_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n "$gl_absolute_header_sed"` + + gl_header=$gl_cv_absolute_wctype_h + gl_cv_next_wctype_h='"'$gl_header'"' else gl_cv_next_wctype_h='<'wctype.h'>' fi @@ -53982,6 +53845,7 @@ $as_echo "#define GNULIB_TEST_CONNECT 1" >>confdefs.h + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 $as_echo_n "checking whether byte ordering is bigendian... " >&6; } if ${ac_cv_c_bigendian+:} false; then : @@ -57549,71 +57413,6 @@ $as_echo "#define GNULIB_TEST_PERROR 1" >>confdefs.h - - if test $ac_cv_func_pipe != yes; then - HAVE_PIPE=0 - fi - - if test $HAVE_PIPE = 0; then - - - - - - - - - gltests_LIBOBJS="$gltests_LIBOBJS pipe.$ac_objext" - - fi - - - - - - if test "$GNULIB_PIPE" != 1; then - if test "$GNULIB_PIPE" = 0; then - GNULIB_PIPE=$gl_module_indicator_condition - else - GNULIB_PIPE="($GNULIB_PIPE || $gl_module_indicator_condition)" - fi - fi - - - - - -$as_echo "#define GNULIB_TEST_PIPE 1" >>confdefs.h - - - - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -[ - #if defined _MSC_VER || defined __MINGW32__ - notposix - #endif - ] -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "notposix" >/dev/null 2>&1; then : - posix_spawn_ported=no -else - posix_spawn_ported=yes -fi -rm -f conftest* - - if test $posix_spawn_ported = yes; then - POSIX_SPAWN_PORTED_TRUE= - POSIX_SPAWN_PORTED_FALSE='#' -else - POSIX_SPAWN_PORTED_TRUE='#' - POSIX_SPAWN_PORTED_FALSE= -fi - - - - # Check for mmap(). Don't use AC_FUNC_MMAP, because it checks too much: it # fails on HP-UX 11, because MAP_FIXED mappings do not work. But this is # irrelevant for anonymous mappings. @@ -58743,102 +58542,6 @@ $as_echo "#define UNLINK_CANNOT_UNLINK_DIR 1" >>confdefs.h abs_aux_dir=`cd "$ac_aux_dir"; pwd` - - - - ac_fn_c_check_type "$LINENO" "useconds_t" "ac_cv_type_useconds_t" "$ac_includes_default" -if test "x$ac_cv_type_useconds_t" = xyes; then : - -else - -$as_echo "#define useconds_t unsigned int" >>confdefs.h - -fi - - if test $ac_cv_func_usleep = no; then - HAVE_USLEEP=0 - else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether usleep allows large arguments" >&5 -$as_echo_n "checking whether usleep allows large arguments... " >&6; } -if ${gl_cv_func_usleep_works+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - case "$host_os" in - # Guess yes on glibc systems. - *-gnu*) gl_cv_func_usleep_works="guessing yes" ;; - # If we don't know, assume the worst. - *) gl_cv_func_usleep_works="guessing no" ;; - esac - -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -#include <unistd.h> - -int -main () -{ -return !!usleep (1000000); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - gl_cv_func_usleep_works=yes -else - gl_cv_func_usleep_works=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_usleep_works" >&5 -$as_echo "$gl_cv_func_usleep_works" >&6; } - case "$gl_cv_func_usleep_works" in - *yes) ;; - *) - REPLACE_USLEEP=1 - ;; - esac - fi - - if test $HAVE_USLEEP = 0 || test $REPLACE_USLEEP = 1; then - - - - - - - - - gltests_LIBOBJS="$gltests_LIBOBJS usleep.$ac_objext" - - fi - - - - - - if test "$GNULIB_USLEEP" != 1; then - if test "$GNULIB_USLEEP" = 0; then - GNULIB_USLEEP=$gl_module_indicator_condition - else - GNULIB_USLEEP="($GNULIB_USLEEP || $gl_module_indicator_condition)" - fi - fi - - - - - -$as_echo "#define GNULIB_TEST_USLEEP 1" >>confdefs.h - - - - abs_aux_dir=`cd "$ac_aux_dir"; pwd` @@ -60268,9 +59971,21 @@ $as_echo "#define ARGMATCH_DIE_DECL void usage (int _e)" >>confdefs.h # used by shred - # Used by install.c. coreutils_saved_libs=$LIBS LIBS="$LIBS $LIB_SELINUX" + # Used by selinux.c. + for ac_func in mode_to_security_class +do : + ac_fn_c_check_func "$LINENO" "mode_to_security_class" "ac_cv_func_mode_to_security_class" +if test "x$ac_cv_func_mode_to_security_class" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_MODE_TO_SECURITY_CLASS 1 +_ACEOF + +fi +done + + # Used by install.c. for ac_func in matchpathcon_init_prefix do : ac_fn_c_check_func "$LINENO" "matchpathcon_init_prefix" "ac_cv_func_matchpathcon_init_prefix" @@ -60281,17 +59996,19 @@ _ACEOF else - case "$ac_cv_search_setfilecon:$ac_cv_header_selinux_selinux_h" in - no:*) # SELinux disabled - ;; - *:no) # SELinux disabled - ;; - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: SELinux enabled, but matchpathcon_init_prefix not found" >&5 + if test "$with_selinux" != no; then + case "$ac_cv_search_setfilecon:$ac_cv_header_selinux_selinux_h" in + no:*) # SELinux disabled + ;; + *:no) # SELinux disabled + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: SELinux enabled, but matchpathcon_init_prefix not found" >&5 $as_echo "$as_me: WARNING: SELinux enabled, but matchpathcon_init_prefix not found" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The install utility may run slowly" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The install utility may run slowly" >&5 $as_echo "$as_me: WARNING: The install utility may run slowly" >&2;} - esac + esac + fi fi done @@ -60784,7 +60501,9 @@ main () _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : - test -d "$srcdir"/.git && gl_gcc_warnings=yes + test -d "$srcdir"/.git \ + && ! test -f "$srcdir"/.tarball-version \ + && gl_gcc_warnings=yes fi rm -f conftest.err conftest.i conftest.$ac_ext @@ -60794,14 +60513,52 @@ fi if test "$gl_gcc_warnings" = yes; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror -Wunknown-warning-option" >&5 +$as_echo_n "checking whether C compiler handles -Werror -Wunknown-warning-option... " >&6; } +if ${gl_cv_warn_c__Werror__Wunknown_warning_option+:} false; then : + $as_echo_n "(cached) " >&6 +else + + gl_save_compiler_FLAGS="$CFLAGS" + as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Werror -Wunknown-warning-option" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + gl_cv_warn_c__Werror__Wunknown_warning_option=yes +else + gl_cv_warn_c__Werror__Wunknown_warning_option=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + CFLAGS="$gl_save_compiler_FLAGS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror__Wunknown_warning_option" >&5 +$as_echo "$gl_cv_warn_c__Werror__Wunknown_warning_option" >&6; } +if test "x$gl_cv_warn_c__Werror__Wunknown_warning_option" = xyes; then : + gl_unknown_warnings_are_errors='-Wunknown-warning-option -Werror' +else + gl_unknown_warnings_are_errors= +fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror" >&5 $as_echo_n "checking whether C compiler handles -Werror... " >&6; } if ${gl_cv_warn_c__Werror+:} false; then : $as_echo_n "(cached) " >&6 else gl_save_compiler_FLAGS="$CFLAGS" - as_fn_append CFLAGS " -Werror" + as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Werror" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -60813,12 +60570,13 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_link "$LINENO"; then : gl_cv_warn_c__Werror=yes else gl_cv_warn_c__Werror=no fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$gl_save_compiler_FLAGS" fi @@ -60847,7 +60605,7 @@ fi nw="$nw -Wunreachable-code" # Too many warnings for now nw="$nw -Wpadded" # Our structs are not padded nw="$nw -Wredundant-decls" # openat.h declares e.g., mkdirat - nw="$nw -Wlogical-op" # any use of fwrite provokes this + nw="$nw -Wlogical-op" # Too many warnings until GCC 4.8.0 nw="$nw -Wformat-nonliteral" # who.c and pinky.c strftime uses nw="$nw -Wvla" # warnings in gettext.h nw="$nw -Wnested-externs" # use of XARGMATCH/verify_function__ @@ -60979,6 +60737,7 @@ $as_echo "$gl_cv_cc_uninitialized_supported" >&6; } -W \ -Wabi \ -Waddress \ + -Waggressive-loop-optimizations \ -Wall \ -Warray-bounds \ -Wattributes \ @@ -61006,7 +60765,6 @@ $as_echo "$gl_cv_cc_uninitialized_supported" >&6; } -Wformat-security \ -Wformat-y2k \ -Wformat-zero-length \ - -Wformat=2 \ -Wfree-nonheap-object \ -Wignored-qualifiers \ -Wimplicit \ @@ -61024,12 +60782,9 @@ $as_echo "$gl_cv_cc_uninitialized_supported" >&6; } -Wmissing-braces \ -Wmissing-declarations \ -Wmissing-field-initializers \ - -Wmissing-format-attribute \ -Wmissing-include-dirs \ - -Wmissing-noreturn \ -Wmissing-parameter-type \ -Wmissing-prototypes \ - -Wmudflap \ -Wmultichar \ -Wnarrowing \ -Wnested-externs \ @@ -61047,6 +60802,7 @@ $as_echo "$gl_cv_cc_uninitialized_supported" >&6; } -Wpointer-sign \ -Wpointer-to-int-cast \ -Wpragmas \ + -Wreturn-local-addr \ -Wreturn-type \ -Wsequence-point \ -Wshadow \ @@ -61068,7 +60824,6 @@ $as_echo "$gl_cv_cc_uninitialized_supported" >&6; } -Wtype-limits \ -Wuninitialized \ -Wunknown-pragmas \ - -Wunreachable-code \ -Wunsafe-loop-optimizations \ -Wunused \ -Wunused-but-set-parameter \ @@ -61087,6 +60842,8 @@ $as_echo "$gl_cv_cc_uninitialized_supported" >&6; } -Wvla \ -Wvolatile-register-var \ -Wwrite-strings \ + -fdiagnostics-show-option \ + -funit-at-a-time \ \ ; do gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item" @@ -61119,7 +60876,12 @@ $as_echo "$gl_cv_cc_uninitialized_supported" >&6; } ws=$gl_warn_set for w in $ws; do - as_gl_Warn=`$as_echo "gl_cv_warn_c_$w" | $as_tr_sh` + +as_gl_Warn=`$as_echo "gl_cv_warn_c_$w" | $as_tr_sh` +gl_positive="$w" +case $gl_positive in + -Wno-*) gl_positive=-W`expr "X$gl_positive" : 'X-Wno-\(.*\)'` ;; +esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles $w" >&5 $as_echo_n "checking whether C compiler handles $w... " >&6; } if eval \${$as_gl_Warn+:} false; then : @@ -61127,7 +60889,7 @@ if eval \${$as_gl_Warn+:} false; then : else gl_save_compiler_FLAGS="$CFLAGS" - as_fn_append CFLAGS " $w" + as_fn_append CFLAGS " $gl_unknown_warnings_are_errors $gl_positive" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -61139,12 +60901,13 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_link "$LINENO"; then : eval "$as_gl_Warn=yes" else eval "$as_gl_Warn=no" fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$gl_save_compiler_FLAGS" fi @@ -61157,14 +60920,15 @@ fi done - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-sign-compare" >&5 + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-sign-compare" >&5 $as_echo_n "checking whether C compiler handles -Wno-sign-compare... " >&6; } if ${gl_cv_warn_c__Wno_sign_compare+:} false; then : $as_echo_n "(cached) " >&6 else gl_save_compiler_FLAGS="$CFLAGS" - as_fn_append CFLAGS " -Wno-sign-compare" + as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wsign-compare" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -61176,12 +60940,13 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_link "$LINENO"; then : gl_cv_warn_c__Wno_sign_compare=yes else gl_cv_warn_c__Wno_sign_compare=no fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$gl_save_compiler_FLAGS" fi @@ -61192,14 +60957,15 @@ if test "x$gl_cv_warn_c__Wno_sign_compare" = xyes; then : fi # Too many warnings for now - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-parameter" >&5 + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-parameter" >&5 $as_echo_n "checking whether C compiler handles -Wno-unused-parameter... " >&6; } if ${gl_cv_warn_c__Wno_unused_parameter+:} false; then : $as_echo_n "(cached) " >&6 else gl_save_compiler_FLAGS="$CFLAGS" - as_fn_append CFLAGS " -Wno-unused-parameter" + as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-parameter" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -61211,12 +60977,13 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_link "$LINENO"; then : gl_cv_warn_c__Wno_unused_parameter=yes else gl_cv_warn_c__Wno_unused_parameter=no fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$gl_save_compiler_FLAGS" fi @@ -61227,15 +60994,15 @@ if test "x$gl_cv_warn_c__Wno_unused_parameter" = xyes; then : fi # Too many warnings for now - as_gl_Warn=`$as_echo "gl_cv_warn_c_-Wsuggest-attribute=const" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wsuggest-attribute=const" >&5 -$as_echo_n "checking whether C compiler handles -Wsuggest-attribute=const... " >&6; } -if eval \${$as_gl_Warn+:} false; then : + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-nonliteral" >&5 +$as_echo_n "checking whether C compiler handles -Wno-format-nonliteral... " >&6; } +if ${gl_cv_warn_c__Wno_format_nonliteral+:} false; then : $as_echo_n "(cached) " >&6 else gl_save_compiler_FLAGS="$CFLAGS" - as_fn_append CFLAGS " -Wsuggest-attribute=const" + as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wformat-nonliteral" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -61247,68 +61014,55 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - eval "$as_gl_Warn=yes" +if ac_fn_c_try_link "$LINENO"; then : + gl_cv_warn_c__Wno_format_nonliteral=yes else - eval "$as_gl_Warn=no" + gl_cv_warn_c__Wno_format_nonliteral=no fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$gl_save_compiler_FLAGS" fi -eval ac_res=\$$as_gl_Warn - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_gl_Warn"\" = x"yes"; then : - as_fn_append WARN_CFLAGS " -Wsuggest-attribute=const" +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_nonliteral" >&5 +$as_echo "$gl_cv_warn_c__Wno_format_nonliteral" >&6; } +if test "x$gl_cv_warn_c__Wno_format_nonliteral" = xyes; then : + as_fn_append WARN_CFLAGS " -Wno-format-nonliteral" fi - as_gl_Warn=`$as_echo "gl_cv_warn_c_-Wsuggest-attribute=noreturn" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wsuggest-attribute=noreturn" >&5 -$as_echo_n "checking whether C compiler handles -Wsuggest-attribute=noreturn... " >&6; } -if eval \${$as_gl_Warn+:} false; then : - $as_echo_n "(cached) " >&6 -else - gl_save_compiler_FLAGS="$CFLAGS" - as_fn_append CFLAGS " -Wsuggest-attribute=noreturn" + # Enable this warning only with gcc-4.8 and newer. Before that + # bounds checking as done in truncate.c was incorrectly flagged. + # See: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=43772 cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +#if (4) < __GNUC__ || ((4) == __GNUC__ && (8) <= __GNUC_MINOR__) +/* ok */ +#else +# error "your version of gcc is older than 4.8" +#endif + int main () { ; return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - eval "$as_gl_Warn=yes" -else - eval "$as_gl_Warn=no" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - CFLAGS="$gl_save_compiler_FLAGS" - -fi -eval ac_res=\$$as_gl_Warn - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_gl_Warn"\" = x"yes"; then : - as_fn_append WARN_CFLAGS " -Wsuggest-attribute=noreturn" -fi +}, +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-nonliteral" >&5 -$as_echo_n "checking whether C compiler handles -Wno-format-nonliteral... " >&6; } -if ${gl_cv_warn_c__Wno_format_nonliteral+:} false; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wlogical-op" >&5 +$as_echo_n "checking whether C compiler handles -Wlogical-op... " >&6; } +if ${gl_cv_warn_c__Wlogical_op+:} false; then : $as_echo_n "(cached) " >&6 else gl_save_compiler_FLAGS="$CFLAGS" - as_fn_append CFLAGS " -Wno-format-nonliteral" + as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wlogical-op" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -61320,36 +61074,40 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - gl_cv_warn_c__Wno_format_nonliteral=yes +if ac_fn_c_try_link "$LINENO"; then : + gl_cv_warn_c__Wlogical_op=yes else - gl_cv_warn_c__Wno_format_nonliteral=no + gl_cv_warn_c__Wlogical_op=no fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$gl_save_compiler_FLAGS" fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_nonliteral" >&5 -$as_echo "$gl_cv_warn_c__Wno_format_nonliteral" >&6; } -if test "x$gl_cv_warn_c__Wno_format_nonliteral" = xyes; then : - as_fn_append WARN_CFLAGS " -Wno-format-nonliteral" +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wlogical_op" >&5 +$as_echo "$gl_cv_warn_c__Wlogical_op" >&6; } +if test "x$gl_cv_warn_c__Wlogical_op" = xyes; then : + as_fn_append WARN_CFLAGS " -Wlogical-op" fi +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + - # Enable this warning only with gcc-4.7 and newer. With 4.6.2 20111027, - # it suggests test.c's advance function may be pure, even though it - # increments a global variable. Oops. - # Normally we'd write code to test for the precise failure, but that - # requires a relatively large input to make gcc exhibit the failure. + # clang is unduly picky about some things. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler is clang" >&5 +$as_echo_n "checking whether the compiler is clang... " >&6; } +if ${utils_cv_clang+:} false; then : + $as_echo_n "(cached) " >&6 +else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#if (4) < __GNUC__ || ((4) == __GNUC__ && (7) <= __GNUC_MINOR__) -/* ok */ -#else -# error "your version of gcc is older than 4.7" -#endif + #ifndef __clang__ + #error "not clang" + #endif int main () @@ -61357,19 +61115,27 @@ main () ; return 0; -}, - +} _ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - as_gl_Warn=`$as_echo "gl_cv_warn_c_-Wsuggest-attribute=pure" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wsuggest-attribute=pure" >&5 -$as_echo_n "checking whether C compiler handles -Wsuggest-attribute=pure... " >&6; } -if eval \${$as_gl_Warn+:} false; then : +if ac_fn_c_try_compile "$LINENO"; then : + utils_cv_clang=yes +else + utils_cv_clang=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $utils_cv_clang" >&5 +$as_echo "$utils_cv_clang" >&6; } + if test $utils_cv_clang = yes; then + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-extra-args" >&5 +$as_echo_n "checking whether C compiler handles -Wno-format-extra-args... " >&6; } +if ${gl_cv_warn_c__Wno_format_extra_args+:} false; then : $as_echo_n "(cached) " >&6 else gl_save_compiler_FLAGS="$CFLAGS" - as_fn_append CFLAGS " -Wsuggest-attribute=pure" + as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wformat-extra-args" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -61381,38 +61147,32 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - eval "$as_gl_Warn=yes" +if ac_fn_c_try_link "$LINENO"; then : + gl_cv_warn_c__Wno_format_extra_args=yes else - eval "$as_gl_Warn=no" + gl_cv_warn_c__Wno_format_extra_args=no fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$gl_save_compiler_FLAGS" fi -eval ac_res=\$$as_gl_Warn - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_gl_Warn"\" = x"yes"; then : - as_fn_append WARN_CFLAGS " -Wsuggest-attribute=pure" -fi - - +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_extra_args" >&5 +$as_echo "$gl_cv_warn_c__Wno_format_extra_args" >&6; } +if test "x$gl_cv_warn_c__Wno_format_extra_args" = xyes; then : + as_fn_append WARN_CFLAGS " -Wno-format-extra-args" fi -rm -f conftest.err conftest.i conftest.$ac_ext - # In spite of excluding -Wlogical-op above, it is enabled, as of - # gcc 4.5.0 20090517, and it provokes warnings in cat.c, dd.c, truncate.c - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-logical-op" >&5 -$as_echo_n "checking whether C compiler handles -Wno-logical-op... " >&6; } -if ${gl_cv_warn_c__Wno_logical_op+:} false; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-tautological-constant-out-of-range-compare" >&5 +$as_echo_n "checking whether C compiler handles -Wno-tautological-constant-out-of-range-compare... " >&6; } +if ${gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare+:} false; then : $as_echo_n "(cached) " >&6 else gl_save_compiler_FLAGS="$CFLAGS" - as_fn_append CFLAGS " -Wno-logical-op" + as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wtautological-constant-out-of-range-compare" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -61424,31 +61184,34 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - gl_cv_warn_c__Wno_logical_op=yes +if ac_fn_c_try_link "$LINENO"; then : + gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare=yes else - gl_cv_warn_c__Wno_logical_op=no + gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare=no fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$gl_save_compiler_FLAGS" fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_logical_op" >&5 -$as_echo "$gl_cv_warn_c__Wno_logical_op" >&6; } -if test "x$gl_cv_warn_c__Wno_logical_op" = xyes; then : - as_fn_append WARN_CFLAGS " -Wno-logical-op" +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" >&5 +$as_echo "$gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" >&6; } +if test "x$gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" = xyes; then : + as_fn_append WARN_CFLAGS " -Wno-tautological-constant-out-of-range-compare" fi + fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -fdiagnostics-show-option" >&5 + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -fdiagnostics-show-option" >&5 $as_echo_n "checking whether C compiler handles -fdiagnostics-show-option... " >&6; } if ${gl_cv_warn_c__fdiagnostics_show_option+:} false; then : $as_echo_n "(cached) " >&6 else gl_save_compiler_FLAGS="$CFLAGS" - as_fn_append CFLAGS " -fdiagnostics-show-option" + as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -fdiagnostics-show-option" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -61460,12 +61223,13 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_link "$LINENO"; then : gl_cv_warn_c__fdiagnostics_show_option=yes else gl_cv_warn_c__fdiagnostics_show_option=no fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$gl_save_compiler_FLAGS" fi @@ -61476,14 +61240,15 @@ if test "x$gl_cv_warn_c__fdiagnostics_show_option" = xyes; then : fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -funit-at-a-time" >&5 + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -funit-at-a-time" >&5 $as_echo_n "checking whether C compiler handles -funit-at-a-time... " >&6; } if ${gl_cv_warn_c__funit_at_a_time+:} false; then : $as_echo_n "(cached) " >&6 else gl_save_compiler_FLAGS="$CFLAGS" - as_fn_append CFLAGS " -funit-at-a-time" + as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -funit-at-a-time" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -61495,12 +61260,13 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_link "$LINENO"; then : gl_cv_warn_c__funit_at_a_time=yes else gl_cv_warn_c__funit_at_a_time=no fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$gl_save_compiler_FLAGS" fi @@ -61574,6 +61340,43 @@ $as_echo "#define GNULIB_PORTCHECK 1" >>confdefs.h fi +# Check whether --enable-single-binary was given. +if test "${enable_single_binary+set}" = set; then : + enableval=$enable_single_binary; gl_single_binary=no ; + case $enableval in + yes) gl_single_binary=shebangs ;; + no|shebangs|symlinks) gl_single_binary=$enableval ;; + *) as_fn_error $? "bad value $enableval for single-binary option. + Options are: symlinks, shebangs, no." "$LINENO" 5 ;; + esac +else + gl_single_binary=no + +fi + +# Check whether --enable-single-binary-exceptions was given. +if test "${enable_single_binary_exceptions+set}" = set; then : + enableval=$enable_single_binary_exceptions; gl_single_binary_exceptions=$enableval +else + gl_single_binary_exceptions= + +fi + +if test "$gl_single_binary" = 'symlinks'; then + if ! test "`echo ls | sed \"$program_transform_name\"`" = 'ls'; then + as_fn_error $? "program name transformations are not currently supported + with --enable-single-binary=symlinks." "$LINENO" 5 + fi +fi + if test "$gl_single_binary" != no; then + SINGLE_BINARY_TRUE= + SINGLE_BINARY_FALSE='#' +else + SINGLE_BINARY_TRUE='#' + SINGLE_BINARY_FALSE= +fi + + for ac_header in vfork.h do : ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default" @@ -61944,6 +61747,23 @@ $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h fi +# Assume that if getattrat exists, it's compatible with Solaris 11. +for ac_func in getattrat +do : + ac_fn_c_check_func "$LINENO" "getattrat" "ac_cv_func_getattrat" +if test "x$ac_cv_func_getattrat" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_GETATTRAT 1 +_ACEOF + +fi +done + +if test $ac_cv_func_getattrat = yes; then + LIB_NVPAIR=-lnvpair + +fi + # SCO-ODT-3.0 is reported to need -los to link programs using initgroups for ac_func in initgroups do : @@ -62650,6 +62470,8 @@ _ACEOF + + LIB_GMP= @@ -62663,8 +62485,11 @@ fi if test $cu_use_gmp != no; then - cu_saved_libs=$LIBS - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing __gmpz_init" >&5 + HAVE_GMP=0 + + if test $ac_cv_header_gmp_h = yes; then + cu_saved_libs=$LIBS + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing __gmpz_init" >&5 $as_echo_n "checking for library containing __gmpz_init... " >&6; } if ${ac_cv_search___gmpz_init+:} false; then : $as_echo_n "(cached) " >&6 @@ -62718,13 +62543,13 @@ ac_res=$ac_cv_search___gmpz_init if test "$ac_res" != no; then : test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" test "$ac_cv_search___gmpz_init" = "none required" || - { - LIB_GMP=$ac_cv_search___gmpz_init + LIB_GMP=$ac_cv_search___gmpz_init $as_echo "#define HAVE_GMP 1" >>confdefs.h - # This only available in GMP >= 5 - ac_fn_c_check_decl "$LINENO" "mpz_inits" "ac_cv_have_decl_mpz_inits" "#include <gmp.h> + HAVE_GMP=1 + # This only available in GMP >= 5 + ac_fn_c_check_decl "$LINENO" "mpz_inits" "ac_cv_have_decl_mpz_inits" "#include <gmp.h> " if test "x$ac_cv_have_decl_mpz_inits" = xyes; then : ac_have_decl=1 @@ -62736,15 +62561,17 @@ cat >>confdefs.h <<_ACEOF #define HAVE_DECL_MPZ_INITS $ac_have_decl _ACEOF - } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libgmp development library was not found or not usable." >&5 -$as_echo "$as_me: WARNING: libgmp development library was not found or not usable." >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: GNU coreutils will be built without GMP support." >&5 -$as_echo "$as_me: WARNING: GNU coreutils will be built without GMP support." >&2;} + fi - LIBS=$cu_saved_libs + LIBS=$cu_saved_libs + fi + if test $HAVE_GMP != 1; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libgmp development library was not found or not usable." >&5 +$as_echo "$as_me: WARNING: libgmp development library was not found or not usable." >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: GNU coreutils will be built without GMP support." >&5 +$as_echo "$as_me: WARNING: GNU coreutils will be built without GMP support." >&2;} + fi fi @@ -62759,27 +62586,41 @@ if test $gl_cv_list_mounted_fs = yes && test $gl_cv_fs_space = yes; then } fi -# Limit stdbuf to ELF systems with GCC -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether this is an ELF system" >&5 -$as_echo_n "checking whether this is an ELF system... " >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether this is system supports stdbuf" >&5 +$as_echo_n "checking whether this is system supports stdbuf... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#if __ELF__ -yes -#endif + + static int stdbuf = 0; + + /* Restrict to ELF systems with compilers + that support the constructor attribute. */ + void __attribute__ ((constructor)) + stdbuf_init (void) + { + #if __ELF__ + stdbuf = 1; + #endif + } +int +main () +{ + + return !(stdbuf == 1); + ; + return 0; +} + _ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then : - elf_sys=yes +if ac_fn_c_try_compile "$LINENO"; then : + stdbuf_supported=yes else - elf_sys=no + stdbuf_supported=no fi -rm -f conftest* - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $elf_sys" >&5 -$as_echo "$elf_sys" >&6; } -if test "$elf_sys" = "yes" && \ - test "$GCC" = "yes"; then +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $stdbuf_supported" >&5 +$as_echo "$stdbuf_supported" >&6; } +if test "$stdbuf_supported" = "yes"; then { if test -z "$optional_bin_progs"; then optional_bin_progs=stdbuf @@ -63442,7 +63283,7 @@ fi optional_bin_progs="$optional_bin_progs yes" fi } -no_install_progs_default='arch hostname' +no_install_progs_default='arch coreutils hostname' # Given the name of a variable containing a space-separated # list of install-by-default programs and the actual list of # do-not-install-by-default programs, modify the former variable @@ -63454,7 +63295,7 @@ no_install_progs_default='arch hostname' # and since the corresponding ./configure option argument is # comma-separated on input. { - gl_no_install_progs_default=`echo 'arch,hostname'|sed 's/,/ /g'` + gl_no_install_progs_default=`echo 'arch,coreutils,hostname'|sed 's/,/ /g'` # Check whether --enable-install-program was given. if test "${enable_install_program+set}" = set; then : enableval=$enable_install_program; gl_do_install_prog=$enableval @@ -63550,6 +63391,66 @@ man1_MANS=` # a distribution tarball. EXTRA_MANS=`for p in $no_install_progs_default; do echo man/$p.1; done` +# Replace all the programs by the single binary and symlinks if specified. +single_binary_progs= +single_binary_libs= +single_binary_deps= +single_binary_install_type= +if test "$gl_single_binary" != no; then + man1_MANS="$man1_MANS man/coreutils.1" + # Convert the list to a space separated list + gl_single_binary_exceptions=`echo $gl_single_binary_exceptions | tr ',' ' '` + + single_binary_progs=`echo $optional_bin_progs` + optional_bin_progs="coreutils" + for prog in $gl_single_binary_exceptions; do + # Fail if requested to exclude a program than was not part of coreutils. + case " $single_binary_progs " in + *" $prog "*) + { + single_binary_progs=`for gl_rem_i in $single_binary_progs; do + test "$gl_rem_i" = "$prog" || echo "$gl_rem_i" + done | tr '\012' ' ' | sed 's/ $//'; echo` +} ; + { + if test -z "$optional_bin_progs"; then + optional_bin_progs=$prog + else + optional_bin_progs="$optional_bin_progs $prog" + fi +} ;; + *) as_fn_error $? "'$prog' is not being compiled." "$LINENO" 5 ;; + esac + done + + # single_binary_libs holds the list of libs required by the selected + # programs, such as for example -lrt. + single_binary_libs=` + for p in $single_binary_progs; do + # Convert '[' to '_' + test x"$p" = x'[' && p='_' + printf '$(src_libsinglebin_%s_a_ldadd) ' "$p" + done` + # single_binary_deps holds the list of libsinglebin_*.a files that have the + # compiled code of each selected program in a "library" format. + single_binary_deps=` + for p in $single_binary_progs; do + # Convert '[' to '_' + test x"$p" = x'[' && p='_' + printf 'src/libsinglebin_%s.a ' "$p" + done` + single_binary_install_type="$gl_single_binary" +fi +single_binary_progs=$single_binary_progs + +single_binary_libs=$single_binary_libs + +single_binary_deps=$single_binary_deps + +single_binary_install_type=$single_binary_install_type + + + # The programs built and installed by "make && make install". # Since this is AC_SUBST'd, Automake won't be able to perform rewrite # with $(EXEEXT) appending on it, so we have to do it ourselves -- in @@ -63691,7 +63592,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -65088,6 +64989,14 @@ $as_echo "$gt_cv_locale_fr" >&6; } +# If doing dynamic dependency checking, create man/dynamic-deps.mk so +# that 'make' doesn't complain about its being absent. Use an old +# time stamp, so that 'make' thinks it is older than 'Makefile'. +# Use time stamp 1, since some 'make' implementations treat 0 specially. +# Use 'touch -t', since older 'touch' implementations don't grok -d. +ac_config_commands="$ac_config_commands man/dynamic-deps.mk" + + ac_config_files="$ac_config_files Makefile po/Makefile.in gnulib-tests/Makefile" cat >confcache <<\_ACEOF @@ -65199,6 +65108,14 @@ LIBOBJS=$ac_libobjs LTLIBOBJS=$ac_ltlibobjs +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5 +$as_echo_n "checking that generated files are newer than configure... " >&6; } + if test -n "$am_sleep_pid"; then + # Hide warnings about reused PIDs. + wait $am_sleep_pid 2>/dev/null + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 +$as_echo "done" >&6; } if test -n "$EXEEXT"; then am__EXEEXT_TRUE= am__EXEEXT_FALSE='#' @@ -65292,9 +65209,6 @@ fi esac done - # If $ALLOCA is not empty, prefix its value with "lib/". - test -n "$ALLOCA" && ALLOCA="lib/$ALLOCA" - if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then as_fn_error $? "conditional \"GL_GENERATE_STDBOOL_H\" was never defined. @@ -65359,10 +65273,6 @@ fi -if test -z "${POSIX_SPAWN_PORTED_TRUE}" && test -z "${POSIX_SPAWN_PORTED_FALSE}"; then - as_fn_error $? "conditional \"POSIX_SPAWN_PORTED\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi gltests_libobjs= gltests_ltlibobjs= @@ -65383,6 +65293,10 @@ if test -z "${HAVE_PERL_TRUE}" && test -z "${HAVE_PERL_FALSE}"; then as_fn_error $? "conditional \"HAVE_PERL\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi +if test -z "${SINGLE_BINARY_TRUE}" && test -z "${SINGLE_BINARY_FALSE}"; then + as_fn_error $? "conditional \"SINGLE_BINARY\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi if test -z "${CROSS_COMPILING_TRUE}" && test -z "${CROSS_COMPILING_FALSE}"; then as_fn_error $? "conditional \"CROSS_COMPILING\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 @@ -65685,16 +65599,16 @@ if (echo >conf$$.file) 2>/dev/null; then # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -p'. + # In both cases, we have to default to `cp -pR'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -p' + as_ln_s='cp -pR' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else - as_ln_s='cp -p' + as_ln_s='cp -pR' fi else - as_ln_s='cp -p' + as_ln_s='cp -pR' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null @@ -65754,28 +65668,16 @@ else as_mkdir_p=false fi -if test -x / >/dev/null 2>&1; then - as_test_x='test -x' -else - if ls -dL / >/dev/null 2>&1; then - as_ls_L_option=L - else - as_ls_L_option= - fi - as_test_x=' - eval sh -c '\'' - if test -d "$1"; then - test -d "$1/."; - else - case $1 in #( - -*)set "./$1";; - esac; - case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( - ???[sx]*):;;*)false;;esac;fi - '\'' sh - ' -fi -as_executable_p=$as_test_x + +# as_fn_executable_p FILE +# ----------------------- +# Test if FILE is an executable regular file. +as_fn_executable_p () +{ + test -f "$1" && test -x "$1" +} # as_fn_executable_p +as_test_x='test -x' +as_executable_p=as_fn_executable_p # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" @@ -65796,8 +65698,8 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by GNU coreutils $as_me 8.21, which was -generated by GNU Autoconf 2.68. Invocation command line was +This file was extended by GNU coreutils $as_me 8.23, which was +generated by GNU Autoconf 2.69. Invocation command line was CONFIG_FILES = $CONFIG_FILES CONFIG_HEADERS = $CONFIG_HEADERS @@ -65868,11 +65770,11 @@ _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -GNU coreutils config.status 8.21 -configured by $0, generated by GNU Autoconf 2.68, +GNU coreutils config.status 8.23 +configured by $0, generated by GNU Autoconf 2.69, with options \\"\$ac_cs_config\\" -Copyright (C) 2010 Free Software Foundation, Inc. +Copyright (C) 2012 Free Software Foundation, Inc. This config.status script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it." @@ -65963,7 +65865,7 @@ fi _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 if \$ac_cs_recheck; then - set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion + set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion shift \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 CONFIG_SHELL='$SHELL' @@ -66009,6 +65911,7 @@ do "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; "$GNUmakefile") CONFIG_LINKS="$CONFIG_LINKS $GNUmakefile:$GNUmakefile" ;; "po-directories") CONFIG_COMMANDS="$CONFIG_COMMANDS po-directories" ;; + "man/dynamic-deps.mk") CONFIG_COMMANDS="$CONFIG_COMMANDS man/dynamic-deps.mk" ;; "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; "po/Makefile.in") CONFIG_FILES="$CONFIG_FILES po/Makefile.in" ;; "gnulib-tests/Makefile") CONFIG_FILES="$CONFIG_FILES gnulib-tests/Makefile" ;; @@ -66640,7 +66543,7 @@ $as_echo "$as_me: executing $ac_file commands" >&6;} case $ac_file$ac_mode in "depfiles":C) test x"$AMDEP_TRUE" != x"" || { - # Autoconf 2.62 quotes --file arguments for eval, but not when files + # Older Autoconf quotes --file arguments for eval, but not when files # are listed without --file. Let's play safe and only enable the eval # if we detect the quoting. case $CONFIG_FILES in @@ -66653,7 +66556,7 @@ $as_echo "$as_me: executing $ac_file commands" >&6;} # Strip MF so we end up with the name of the file. mf=`echo "$mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile or not. - # We used to match only the files named `Makefile.in', but + # We used to match only the files named 'Makefile.in', but # some people rename them; so instead we look at the file content. # Grep'ing the first line is not enough: some people post-process # each Makefile.in and add a new line on top of each file to say so. @@ -66687,21 +66590,19 @@ $as_echo X"$mf" | continue fi # Extract the definition of DEPDIR, am__include, and am__quote - # from the Makefile without running `make'. + # from the Makefile without running 'make'. DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` test -z "$DEPDIR" && continue am__include=`sed -n 's/^am__include = //p' < "$mf"` - test -z "am__include" && continue + test -z "$am__include" && continue am__quote=`sed -n 's/^am__quote = //p' < "$mf"` - # When using ansi2knr, U may be empty or an underscore; expand it - U=`sed -n 's/^U = //p' < "$mf"` # Find all dependency output files, they are included files with # $(DEPDIR) in their names. We invoke sed twice because it is the # simplest approach to changing $(DEPDIR) to its actual value in the # expansion. for file in `sed -n " s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ - sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do + sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do # Make sure the directory exists. test -f "$dirpart/$file" && continue fdir=`$as_dirname -- "$file" || @@ -66744,7 +66645,7 @@ $as_echo X"$file" | case "$ac_file" in */Makefile.in) # Adjust a relative srcdir. ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'` - ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`" + ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'` ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'` # In autoconf-2.13 it is called $ac_given_srcdir. # In autoconf-2.50 it is called $srcdir. @@ -66848,6 +66749,8 @@ $as_echo X"$file" | ;; esac done ;; + "man/dynamic-deps.mk":C) test -n "$AMDEP_TRUE" || + TZ=UTC0 touch -t 197001010000.01 man/dynamic-deps.mk ;; esac done # for ac_tag |