2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.69 for libgnu UNUSED-VERSION.
6 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
9 # This configure script is free software; the Free Software Foundation
10 # gives unlimited permission to copy, distribute and modify it.
11 ## -------------------- ##
12 ## M4sh Initialization. ##
13 ## -------------------- ##
15 # Be more Bourne compatible
16 DUALCASE
=1; export DUALCASE
# for MKS sh
17 if test -n "${ZSH_VERSION+set}" && (emulate sh
) >/dev
/null
2>&1; then :
20 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
21 # is contrary to our usage. Disable this feature.
22 alias -g '${1+"$@"}'='"$@"'
25 case `(set -o) 2>/dev/null` in #(
37 # Printing a long string crashes Solaris 7 /usr/bin/printf.
38 as_echo
='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
39 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
40 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
41 # Prefer a ksh shell builtin over an external printf program on Solaris,
42 # but without wasting forks for bash or zsh.
43 if test -z "$BASH_VERSION$ZSH_VERSION" \
44 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
46 as_echo_n='print
-rn --'
47 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
51 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
52 as_echo_body='eval /usr
/ucb
/echo -n "$1$as_nl"'
53 as_echo_n='/usr
/ucb
/echo -n'
55 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
60 expr "X$arg" : "X\\(.*\\)$as_nl";
61 arg
=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
63 expr "X$arg" : "X\\(.*\\)" |
tr -d "$as_nl"
66 as_echo_n='sh
-c $as_echo_n_body as_echo
'
69 as_echo='sh
-c $as_echo_body as_echo
'
72 # The user is always right.
73 if test "${PATH_SEPARATOR+set}" != set; then
75 (PATH='/bin
;/bin
'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
76 (PATH='/bin
:/bin
'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
83 # We need space, tab and new line, in precisely that order. Quoting is
84 # there to prevent editors from complaining about space-tab.
85 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
86 # splitting by setting IFS to empty value.)
89 # Find who we are. Look in the path if we contain no directory separator.
92 *[\\/]* ) as_myself=$0 ;;
93 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
97 test -z "$as_dir" && as_dir=.
98 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
104 # We did not find ourselves, most probably we were run as `sh COMMAND'
105 # in which case we are not to be found in the path.
106 if test "x$as_myself" = x
; then
109 if test ! -f "$as_myself"; then
110 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
114 # Unset variables that we do not need and which cause bugs (e.g. in
115 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
116 # suppresses any "Segmentation fault" message there. '((' could
117 # trigger a bug in pdksh 5.2.14.
118 for as_var
in BASH_ENV ENV MAIL MAILPATH
119 do eval test x\
${$as_var+set} = xset \
120 && ( (unset $as_var) ||
exit 1) >/dev
/null
2>&1 && unset $as_var ||
:
133 (unset CDPATH
) >/dev
/null
2>&1 && unset CDPATH
135 # Use a proper internal environment variable to ensure we don't fall
136 # into an infinite loop, continuously re-executing ourselves.
137 if test x
"${_as_can_reexec}" != xno
&& test "x$CONFIG_SHELL" != x
; then
138 _as_can_reexec
=no
; export _as_can_reexec
;
139 # We cannot yet assume a decent shell, so we have to provide a
140 # neutralization value for shells without unset; and this also
141 # works around shells that cannot unset nonexistent variables.
142 # Preserve -v and -x to the replacement shell.
145 (unset BASH_ENV
) >/dev
/null
2>&1 && unset BASH_ENV ENV
147 *v
*x
* |
*x
*v
* ) as_opts
=-vx ;;
152 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
153 # Admittedly, this is quite paranoid, since all the known shells bail
154 # out after a failed `exec'.
155 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
158 # We don't want this to propagate to other subprocesses.
159 { _as_can_reexec
=; unset _as_can_reexec
;}
160 if test "x$CONFIG_SHELL" = x
; then
161 as_bourne_compatible
="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
164 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
165 # is contrary to our usage. Disable this feature.
166 alias -g '\${1+\"\$@\"}'='\"\$@\"'
169 case \`(set -o) 2>/dev/null\` in #(
177 as_required
="as_fn_return () { (exit \$1); }
178 as_fn_success () { as_fn_return 0; }
179 as_fn_failure () { as_fn_return 1; }
180 as_fn_ret_success () { return 0; }
181 as_fn_ret_failure () { return 1; }
184 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
185 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
186 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
187 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
188 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
191 exitcode=1; echo positional parameters were not saved.
193 test x\$exitcode = x0 || exit 1
195 as_suggested
=" as_lineno_1=";as_suggested
=$as_suggested$LINENO;as_suggested
=$as_suggested" as_lineno_1a=\$LINENO
196 as_lineno_2=";as_suggested
=$as_suggested$LINENO;as_suggested
=$as_suggested" as_lineno_2a=\$LINENO
197 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
198 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
199 test \$(( 1 + 1 )) = 2 || exit 1"
200 if (eval "$as_required") 2>/dev
/null
; then :
205 if test x
$as_have_required = xyes
&& (eval "$as_suggested") 2>/dev
/null
; then :
208 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
210 for as_dir
in /bin
$PATH_SEPARATOR/usr
/bin
$PATH_SEPARATOR$PATH
213 test -z "$as_dir" && as_dir
=.
217 for as_base
in sh bash ksh sh5
; do
218 # Try only shells that exist, to save several forks.
219 as_shell
=$as_dir/$as_base
220 if { test -f "$as_shell" ||
test -f "$as_shell.exe"; } &&
221 { $as_echo "$as_bourne_compatible""$as_required" | as_run
=a
"$as_shell"; } 2>/dev
/null
; then :
222 CONFIG_SHELL
=$as_shell as_have_required
=yes
223 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run
=a
"$as_shell"; } 2>/dev
/null
; then :
231 $as_found ||
{ if { test -f "$SHELL" ||
test -f "$SHELL.exe"; } &&
232 { $as_echo "$as_bourne_compatible""$as_required" | as_run
=a
"$SHELL"; } 2>/dev
/null
; then :
233 CONFIG_SHELL
=$SHELL as_have_required
=yes
238 if test "x$CONFIG_SHELL" != x
; then :
240 # We cannot yet assume a decent shell, so we have to provide a
241 # neutralization value for shells without unset; and this also
242 # works around shells that cannot unset nonexistent variables.
243 # Preserve -v and -x to the replacement shell.
246 (unset BASH_ENV
) >/dev
/null
2>&1 && unset BASH_ENV ENV
248 *v
*x
* |
*x
*v
* ) as_opts
=-vx ;;
253 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
254 # Admittedly, this is quite paranoid, since all the known shells bail
255 # out after a failed `exec'.
256 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
260 if test x
$as_have_required = xno
; then :
261 $as_echo "$0: This script requires a shell more modern than all"
262 $as_echo "$0: the shells that I found on your system."
263 if test x
${ZSH_VERSION+set} = xset
; then
264 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
265 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
267 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
268 $0: including any error possibly output before this
269 $0: message. Then install a modern shell, or manually run
270 $0: the script under such a shell if you do have one."
276 SHELL
=${CONFIG_SHELL-/bin/sh}
278 # Unset more variables known to interfere with behavior of common tools.
279 CLICOLOR_FORCE
= GREP_OPTIONS
=
280 unset CLICOLOR_FORCE GREP_OPTIONS
282 ## --------------------- ##
283 ## M4sh Shell Functions. ##
284 ## --------------------- ##
287 # Portably unset VAR.
290 { eval $1=; unset $1;}
294 # as_fn_set_status STATUS
295 # -----------------------
296 # Set $? to STATUS, without forking.
304 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
314 # Create "$as_dir" as a directory, including parents if necessary.
319 -*) as_dir
=.
/$as_dir;;
321 test -d "$as_dir" ||
eval $as_mkdir_p ||
{
325 *\'*) as_qdir
=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
328 as_dirs
="'$as_qdir' $as_dirs"
329 as_dir
=`$as_dirname -- "$as_dir" ||
330 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
331 X"$as_dir" : 'X\(//\)[^/]' \| \
332 X"$as_dir" : 'X\(//\)$' \| \
333 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
334 $as_echo X"$as_dir" |
335 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
352 test -d "$as_dir" && break
354 test -z "$as_dirs" ||
eval "mkdir $as_dirs"
355 } ||
test -d "$as_dir" || as_fn_error $?
"cannot create directory $as_dir"
360 # as_fn_executable_p FILE
361 # -----------------------
362 # Test if FILE is an executable regular file.
363 as_fn_executable_p
()
365 test -f "$1" && test -x "$1"
366 } # as_fn_executable_p
367 # as_fn_append VAR VALUE
368 # ----------------------
369 # Append the text in VALUE to the end of the definition contained in VAR. Take
370 # advantage of any shell optimizations that allow amortized linear growth over
371 # repeated appends, instead of the typical quadratic growth present in naive
373 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev
/null
; then :
374 eval 'as_fn_append ()
387 # Perform arithmetic evaluation on the ARGs, and store the result in the
388 # global $as_val. Take advantage of shells that can avoid forks. The arguments
389 # must be portable across $(()) and expr.
390 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev
/null
; then :
398 as_val
=`expr "$@" || test $? -eq 1`
403 # as_fn_error STATUS ERROR [LINENO LOG_FD]
404 # ----------------------------------------
405 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
406 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
407 # script with STATUS, using 1 if that was 0.
410 as_status
=$1; test $as_status -eq 0 && as_status
=1
412 as_lineno
=${as_lineno-"$3"} as_lineno_stack
=as_lineno_stack
=$as_lineno_stack
413 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
415 $as_echo "$as_me: error: $2" >&2
416 as_fn_exit
$as_status
419 if expr a
: '\(a\)' >/dev
/null
2>&1 &&
420 test "X`expr 00001 : '.*\(...\)'`" = X001
; then
426 if (basename -- /) >/dev
/null
2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
432 if (as_dir
=`dirname -- /` && test "X$as_dir" = X
/) >/dev
/null
2>&1; then
438 as_me
=`$as_basename -- "$0" ||
439 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
440 X"$0" : 'X\(//\)$' \| \
441 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
443 sed '/^.*\/\([^/][^/]*\)\/*$/{
457 # Avoid depending upon Character Ranges.
458 as_cr_letters
='abcdefghijklmnopqrstuvwxyz'
459 as_cr_LETTERS
='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
460 as_cr_Letters
=$as_cr_letters$as_cr_LETTERS
461 as_cr_digits
='0123456789'
462 as_cr_alnum
=$as_cr_Letters$as_cr_digits
465 as_lineno_1
=$LINENO as_lineno_1a
=$LINENO
466 as_lineno_2
=$LINENO as_lineno_2a
=$LINENO
467 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
468 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' ||
{
469 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
481 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
485 chmod +x
"$as_me.lineno" ||
486 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit
1; }
488 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
489 # already done that, so ensure we don't try to do so again and fall
490 # in an infinite loop. This has already happened in practice.
491 _as_can_reexec
=no
; export _as_can_reexec
492 # Don't try to exec as it changes $[0], causing all sort of problems
493 # (the dirname of $[0] is not the place where we might find the
494 # original and so on. Autoconf is especially sensitive to this).
496 # Exit status is that of the last command.
500 ECHO_C
= ECHO_N
= ECHO_T
=
501 case `echo -n x` in #(((((
503 case `echo 'xy\c'` in
504 *c
*) ECHO_T
=' ';; # ECHO_T is single tab character.
506 *) echo `echo ksh88 bug on AIX 6.1` > /dev
/null
513 rm -f conf$$ conf$$.exe conf$$.
file
514 if test -d conf$$.dir
; then
515 rm -f conf$$.dir
/conf$$.
file
518 mkdir conf$$.dir
2>/dev
/null
520 if (echo >conf$$.
file) 2>/dev
/null
; then
521 if ln -s conf$$.
file conf$$
2>/dev
/null
; then
523 # ... but there are two gotchas:
524 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
525 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
526 # In both cases, we have to default to `cp -pR'.
527 ln -s conf$$.
file conf$$.dir
2>/dev
/null
&& test ! -f conf$$.exe ||
529 elif ln conf$$.
file conf$$
2>/dev
/null
; then
537 rm -f conf$$ conf$$.exe conf$$.dir
/conf$$.
file conf$$.
file
538 rmdir conf$$.dir
2>/dev
/null
540 if mkdir
-p .
2>/dev
/null
; then
541 as_mkdir_p
='mkdir -p "$as_dir"'
543 test -d .
/-p && rmdir .
/-p
548 as_executable_p
=as_fn_executable_p
550 # Sed expression to map a string onto a valid CPP name.
551 as_tr_cpp
="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
553 # Sed expression to map a string onto a valid variable name.
554 as_tr_sh
="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
557 test -n "$DJDIR" ||
exec 7<&0 </dev
/null
561 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
562 # so uname gets run too.
563 ac_hostname
=`(hostname || uname -n) 2>/dev/null | sed 1q`
568 ac_default_prefix
=/usr
/local
570 ac_config_libobj_dir
=.
577 # Identity of this package.
578 PACKAGE_NAME
='libgnu'
579 PACKAGE_TARNAME
='libgnu'
580 PACKAGE_VERSION
='UNUSED-VERSION'
581 PACKAGE_STRING
='libgnu UNUSED-VERSION'
585 ac_unique_file
="import/memmem.c"
587 # Factoring default headers for most tests.
588 ac_includes_default
="\
590 #ifdef HAVE_SYS_TYPES_H
591 # include <sys/types.h>
593 #ifdef HAVE_SYS_STAT_H
594 # include <sys/stat.h>
600 # ifdef HAVE_STDLIB_H
605 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
610 #ifdef HAVE_STRINGS_H
611 # include <strings.h>
613 #ifdef HAVE_INTTYPES_H
614 # include <inttypes.h>
623 gl_use_threads_default
=
624 gl_use_winpthreads_default
=
626 gl_fnmatch_required
=POSIX
627 ac_subst_vars
='am__EXEEXT_FALSE
657 INSTALL_STRIP_PROGRAM
678 NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H
696 NEXT_AS_FIRST_DIRECTIVE_WCHAR_H
699 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
701 TIME_H_DEFINES_TIME_UTC
702 UNISTD_H_DEFINES_STRUCT_TIMESPEC
703 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
704 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
705 TIME_H_DEFINES_STRUCT_TIMESPEC
706 NEXT_AS_FIRST_DIRECTIVE_TIME_H
722 HAVE_DECL_LOCALTIME_R
736 NEXT_AS_FIRST_DIRECTIVE_SYS_UIO_H
740 NEXT_AS_FIRST_DIRECTIVE_SYS_TYPES_H
743 NEXT_AS_FIRST_DIRECTIVE_SYS_RANDOM_H
746 NEXT_AS_FIRST_DIRECTIVE_STRINGS_H
748 NEXT_AS_FIRST_DIRECTIVE_STRING_H
750 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
752 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
755 GL_GENERATE_STDBOOL_H_FALSE
756 GL_GENERATE_STDBOOL_H_TRUE
758 GL_GENERATE_STDALIGN_H_FALSE
759 GL_GENERATE_STDALIGN_H_TRUE
761 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
764 REPLACE_PTHREAD_SIGMASK
766 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
767 HAVE_STRUCT_SIGACTION_SA_SIGACTION
773 HAVE_POSIX_SIGNALBLOCKING
776 GNULIB_SIGNAL_H_SIGPIPE
778 GNULIB_PTHREAD_SIGMASK
782 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H
789 GL_GENERATE_NETINET_IN_H_FALSE
790 GL_GENERATE_NETINET_IN_H_TRUE
793 NEXT_AS_FIRST_DIRECTIVE_NETINET_IN_H
796 NEXT_AS_FIRST_DIRECTIVE_NETDB_H
800 HAVE_DECL_GETNAMEINFO
801 HAVE_DECL_GETADDRINFO
802 HAVE_DECL_GAI_STRERROR
803 HAVE_DECL_FREEADDRINFO
808 REPLACE_STRERRORNAME_NP
853 GNULIB_STRERRORNAME_NP
889 GNULIB_EXPLICIT_BZERO
896 NEXT_AS_FIRST_DIRECTIVE_MATH_H
903 NEXT_AS_FIRST_DIRECTIVE_LOCALE_H
906 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
908 GL_GENERATE_STDDEF_H_FALSE
909 GL_GENERATE_STDDEF_H_TRUE
925 GNULIB_SETLOCALE_NULL
928 LOCALCHARSET_TESTS_ENVIRONMENT
929 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
931 UINT64_MAX_EQ_ULONG_MAX
932 UINT32_MAX_LT_UINTMAX_MAX
934 INT64_MAX_EQ_LONG_MAX
935 INT32_MAX_LT_INTMAX_MAX
947 GL_GENERATE_STDINT_H_FALSE
948 GL_GENERATE_STDINT_H_TRUE
960 HAVE_SIGNED_SIG_ATOMIC_T
963 BITSIZEOF_SIG_ATOMIC_T
966 APPLE_UNIVERSAL_BUILD
968 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
973 GNULIB_OVERRIDES_WINT_T
974 GL_GENERATE_LIMITS_H_FALSE
975 GL_GENERATE_LIMITS_H_TRUE
977 NEXT_AS_FIRST_DIRECTIVE_LIMITS_H
980 NEXT_AS_FIRST_DIRECTIVE_SYS_SOCKET_H
984 HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY
985 HAVE_STRUCT_SOCKADDR_STORAGE
1007 GL_GENERATE_GLOB_H_FALSE
1008 GL_GENERATE_GLOB_H_TRUE
1011 NEXT_AS_FIRST_DIRECTIVE_GLOB_H
1013 REPLACE_GLOB_PATTERN_P
1018 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
1020 REPLACE_STRUCT_TIMEVAL
1021 REPLACE_GETTIMEOFDAY
1040 REPLACE_STDIO_WRITE_FUNCS
1041 REPLACE_STDIO_READ_FUNCS
1050 REPLACE_OBSTACK_PRINTF
1075 HAVE_DECL_OBSTACK_PRINTF
1087 GNULIB_MDA_FCLOSEALL
1088 GNULIB_VSPRINTF_POSIX
1090 GNULIB_VPRINTF_POSIX
1092 GNULIB_VFPRINTF_POSIX
1099 GNULIB_STDIO_H_SIGPIPE
1100 GNULIB_STDIO_H_NONBLOCKING
1101 GNULIB_SPRINTF_POSIX
1115 GNULIB_OBSTACK_PRINTF_POSIX
1116 GNULIB_OBSTACK_PRINTF
1132 GNULIB_FPRINTF_POSIX
1141 WINDOWS_64_BIT_ST_SIZE
1142 WINDOWS_STAT_TIMESPEC
1143 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
1172 GNULIB_OVERRIDES_STRUCT_STAT
1189 HAVE_SAME_LONG_DOUBLE_AS_DOUBLE
1200 REPLACE_SIGNBIT_USING_BUILTINS
1280 HAVE_DECL_REMAINDERL
1467 GL_GENERATE_FNMATCH_H_FALSE
1468 GL_GENERATE_FNMATCH_H_TRUE
1471 NEXT_AS_FIRST_DIRECTIVE_FNMATCH_H
1477 GL_GENERATE_FLOAT_H_FALSE
1478 GL_GENERATE_FLOAT_H_TRUE
1480 NEXT_AS_FIRST_DIRECTIVE_FLOAT_H
1482 HAVE_DECL_STRNCASECMP
1486 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H
1507 GL_GENERATE_ERRNO_H_FALSE
1508 GL_GENERATE_ERRNO_H_TRUE
1510 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H
1513 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H
1515 NEXT_AS_FIRST_DIRECTIVE_CTYPE_H
1541 HAVE_MSVC_INVALID_PARAMETER_HANDLER
1543 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
1544 UNISTD_H_HAVE_WINSOCK2_H
1545 UNISTD_H_HAVE_SYS_RANDOM_H
1570 REPLACE_GETDTABLESIZE
1571 REPLACE_GETDOMAINNAME
1592 HAVE_DECL_SETHOSTNAME
1593 HAVE_DECL_GETUSERSHELL
1594 HAVE_DECL_GETPAGESIZE
1595 HAVE_DECL_GETLOGIN_R
1597 HAVE_DECL_GETDOMAINNAME
1634 HAVE_COPY_FILE_RANGE
1661 GNULIB_UNISTD_H_SIGPIPE
1662 GNULIB_UNISTD_H_NONBLOCKING
1692 GNULIB_GETDTABLESIZE
1693 GNULIB_GETDOMAINNAME
1713 GNULIB_COPY_FILE_RANGE
1732 REPLACE_POSIX_MEMALIGN
1738 REPLACE_CANONICALIZE_FILE_NAME
1740 REPLACE_ALIGNED_ALLOC
1744 HAVE_STRUCT_RANDOM_DATA
1775 HAVE_DECL_GETLOADAVG
1779 HAVE_CANONICALIZE_FILE_NAME
1797 GNULIB_SECURE_GETENV
1800 GNULIB_REALLOC_POSIX
1809 GNULIB_POSIX_MEMALIGN
1821 GNULIB_CANONICALIZE_FILE_NAME
1824 GNULIB_ALIGNED_ALLOC
1929 NEXT_AS_FIRST_DIRECTIVE_ARPA_INET_H
1932 PRAGMA_SYSTEM_HEADER
1933 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
1943 GL_GENERATE_ALLOCA_H_FALSE
1944 GL_GENERATE_ALLOCA_H_TRUE
1947 GL_COND_LIBTOOL_FALSE
1948 GL_COND_LIBTOOL_TRUE
1976 MAINTAINER_MODE_FALSE
1977 MAINTAINER_MODE_TRUE
2005 program_transform_name
2018 enable_option_checking
2019 enable_maintainer_mode
2023 enable_cross_guesses
2024 enable_dependency_tracking
2027 ac_precious_vars
='build_alias
2038 # Initialize some variables set by options.
2040 ac_init_version
=false
2041 ac_unrecognized_opts
=
2042 ac_unrecognized_sep
=
2043 # The variables have the same names as the options, with
2044 # dashes changed to underlines.
2045 cache_file
=/dev
/null
2052 program_transform_name
=s
,x
,x
,
2060 # Installation directory options.
2061 # These are left unexpanded so users can "make install exec_prefix=/foo"
2062 # and all the variables that are supposed to be based on exec_prefix
2063 # by default will actually change.
2064 # Use braces instead of parens because sh, perl, etc. also accept them.
2065 # (The list follows the same order as the GNU Coding Standards.)
2066 bindir
='${exec_prefix}/bin'
2067 sbindir
='${exec_prefix}/sbin'
2068 libexecdir
='${exec_prefix}/libexec'
2069 datarootdir
='${prefix}/share'
2070 datadir
='${datarootdir}'
2071 sysconfdir
='${prefix}/etc'
2072 sharedstatedir
='${prefix}/com'
2073 localstatedir
='${prefix}/var'
2074 includedir
='${prefix}/include'
2075 oldincludedir
='/usr/include'
2076 docdir
='${datarootdir}/doc/${PACKAGE_TARNAME}'
2077 infodir
='${datarootdir}/info'
2082 libdir
='${exec_prefix}/lib'
2083 localedir
='${datarootdir}/locale'
2084 mandir
='${datarootdir}/man'
2090 # If the previous option needs an argument, assign it.
2091 if test -n "$ac_prev"; then
2092 eval $ac_prev=\
$ac_option
2098 *=?
*) ac_optarg
=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
2103 # Accept the important Cygnus configure options, so we can diagnose typos.
2105 case $ac_dashdash$ac_option in
2109 -bindir |
--bindir |
--bindi |
--bind |
--bin |
--bi)
2111 -bindir=* |
--bindir=* |
--bindi=* |
--bind=* |
--bin=* |
--bi=*)
2112 bindir
=$ac_optarg ;;
2114 -build |
--build |
--buil |
--bui |
--bu)
2115 ac_prev
=build_alias
;;
2116 -build=* |
--build=* |
--buil=* |
--bui=* |
--bu=*)
2117 build_alias
=$ac_optarg ;;
2119 -cache-file |
--cache-file |
--cache-fil |
--cache-fi \
2120 |
--cache-f |
--cache- |
--cache |
--cach |
--cac |
--ca |
--c)
2121 ac_prev
=cache_file
;;
2122 -cache-file=* |
--cache-file=* |
--cache-fil=* |
--cache-fi=* \
2123 |
--cache-f=* |
--cache-=* |
--cache=* |
--cach=* |
--cac=* |
--ca=* |
--c=*)
2124 cache_file
=$ac_optarg ;;
2126 --config-cache |
-C)
2127 cache_file
=config.cache
;;
2129 -datadir |
--datadir |
--datadi |
--datad)
2131 -datadir=* |
--datadir=* |
--datadi=* |
--datad=*)
2132 datadir
=$ac_optarg ;;
2134 -datarootdir |
--datarootdir |
--datarootdi |
--datarootd |
--dataroot \
2135 |
--dataroo |
--dataro |
--datar)
2136 ac_prev
=datarootdir
;;
2137 -datarootdir=* |
--datarootdir=* |
--datarootdi=* |
--datarootd=* \
2138 |
--dataroot=* |
--dataroo=* |
--dataro=* |
--datar=*)
2139 datarootdir
=$ac_optarg ;;
2141 -disable-* |
--disable-*)
2142 ac_useropt
=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
2143 # Reject names that are not valid shell variable names.
2144 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev
/null
&&
2145 as_fn_error $?
"invalid feature name: $ac_useropt"
2146 ac_useropt_orig
=$ac_useropt
2147 ac_useropt
=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
2148 case $ac_user_opts in
2150 "enable_
$ac_useropt"
2152 *) ac_unrecognized_opts
="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
2153 ac_unrecognized_sep
=', ';;
2155 eval enable_
$ac_useropt=no
;;
2157 -docdir |
--docdir |
--docdi |
--doc |
--do)
2159 -docdir=* |
--docdir=* |
--docdi=* |
--doc=* |
--do=*)
2160 docdir
=$ac_optarg ;;
2162 -dvidir |
--dvidir |
--dvidi |
--dvid |
--dvi |
--dv)
2164 -dvidir=* |
--dvidir=* |
--dvidi=* |
--dvid=* |
--dvi=* |
--dv=*)
2165 dvidir
=$ac_optarg ;;
2167 -enable-* |
--enable-*)
2168 ac_useropt
=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
2169 # Reject names that are not valid shell variable names.
2170 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev
/null
&&
2171 as_fn_error $?
"invalid feature name: $ac_useropt"
2172 ac_useropt_orig
=$ac_useropt
2173 ac_useropt
=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
2174 case $ac_user_opts in
2176 "enable_
$ac_useropt"
2178 *) ac_unrecognized_opts
="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
2179 ac_unrecognized_sep
=', ';;
2181 eval enable_
$ac_useropt=\
$ac_optarg ;;
2183 -exec-prefix |
--exec_prefix |
--exec-prefix |
--exec-prefi \
2184 |
--exec-pref |
--exec-pre |
--exec-pr |
--exec-p |
--exec- \
2185 |
--exec |
--exe |
--ex)
2186 ac_prev
=exec_prefix
;;
2187 -exec-prefix=* |
--exec_prefix=* |
--exec-prefix=* |
--exec-prefi=* \
2188 |
--exec-pref=* |
--exec-pre=* |
--exec-pr=* |
--exec-p=* |
--exec-=* \
2189 |
--exec=* |
--exe=* |
--ex=*)
2190 exec_prefix
=$ac_optarg ;;
2192 -gas |
--gas |
--ga |
--g)
2193 # Obsolete; use --with-gas.
2196 -help |
--help |
--hel |
--he |
-h)
2197 ac_init_help
=long
;;
2198 -help=r
* |
--help=r
* |
--hel=r
* |
--he=r
* |
-hr*)
2199 ac_init_help
=recursive
;;
2200 -help=s
* |
--help=s
* |
--hel=s
* |
--he=s
* |
-hs*)
2201 ac_init_help
=short
;;
2203 -host |
--host |
--hos |
--ho)
2204 ac_prev
=host_alias
;;
2205 -host=* |
--host=* |
--hos=* |
--ho=*)
2206 host_alias
=$ac_optarg ;;
2208 -htmldir |
--htmldir |
--htmldi |
--htmld |
--html |
--htm |
--ht)
2210 -htmldir=* |
--htmldir=* |
--htmldi=* |
--htmld=* |
--html=* |
--htm=* \
2212 htmldir
=$ac_optarg ;;
2214 -includedir |
--includedir |
--includedi |
--included |
--include \
2215 |
--includ |
--inclu |
--incl |
--inc)
2216 ac_prev
=includedir
;;
2217 -includedir=* |
--includedir=* |
--includedi=* |
--included=* |
--include=* \
2218 |
--includ=* |
--inclu=* |
--incl=* |
--inc=*)
2219 includedir
=$ac_optarg ;;
2221 -infodir |
--infodir |
--infodi |
--infod |
--info |
--inf)
2223 -infodir=* |
--infodir=* |
--infodi=* |
--infod=* |
--info=* |
--inf=*)
2224 infodir
=$ac_optarg ;;
2226 -libdir |
--libdir |
--libdi |
--libd)
2228 -libdir=* |
--libdir=* |
--libdi=* |
--libd=*)
2229 libdir
=$ac_optarg ;;
2231 -libexecdir |
--libexecdir |
--libexecdi |
--libexecd |
--libexec \
2232 |
--libexe |
--libex |
--libe)
2233 ac_prev
=libexecdir
;;
2234 -libexecdir=* |
--libexecdir=* |
--libexecdi=* |
--libexecd=* |
--libexec=* \
2235 |
--libexe=* |
--libex=* |
--libe=*)
2236 libexecdir
=$ac_optarg ;;
2238 -localedir |
--localedir |
--localedi |
--localed |
--locale)
2239 ac_prev
=localedir
;;
2240 -localedir=* |
--localedir=* |
--localedi=* |
--localed=* |
--locale=*)
2241 localedir
=$ac_optarg ;;
2243 -localstatedir |
--localstatedir |
--localstatedi |
--localstated \
2244 |
--localstate |
--localstat |
--localsta |
--localst |
--locals)
2245 ac_prev
=localstatedir
;;
2246 -localstatedir=* |
--localstatedir=* |
--localstatedi=* |
--localstated=* \
2247 |
--localstate=* |
--localstat=* |
--localsta=* |
--localst=* |
--locals=*)
2248 localstatedir
=$ac_optarg ;;
2250 -mandir |
--mandir |
--mandi |
--mand |
--man |
--ma |
--m)
2252 -mandir=* |
--mandir=* |
--mandi=* |
--mand=* |
--man=* |
--ma=* |
--m=*)
2253 mandir
=$ac_optarg ;;
2255 -nfp |
--nfp |
--nf)
2256 # Obsolete; use --without-fp.
2259 -no-create |
--no-create |
--no-creat |
--no-crea |
--no-cre \
2260 |
--no-cr |
--no-c |
-n)
2263 -no-recursion |
--no-recursion |
--no-recursio |
--no-recursi \
2264 |
--no-recurs |
--no-recur |
--no-recu |
--no-rec |
--no-re |
--no-r)
2267 -oldincludedir |
--oldincludedir |
--oldincludedi |
--oldincluded \
2268 |
--oldinclude |
--oldinclud |
--oldinclu |
--oldincl |
--oldinc \
2269 |
--oldin |
--oldi |
--old |
--ol |
--o)
2270 ac_prev
=oldincludedir
;;
2271 -oldincludedir=* |
--oldincludedir=* |
--oldincludedi=* |
--oldincluded=* \
2272 |
--oldinclude=* |
--oldinclud=* |
--oldinclu=* |
--oldincl=* |
--oldinc=* \
2273 |
--oldin=* |
--oldi=* |
--old=* |
--ol=* |
--o=*)
2274 oldincludedir
=$ac_optarg ;;
2276 -prefix |
--prefix |
--prefi |
--pref |
--pre |
--pr |
--p)
2278 -prefix=* |
--prefix=* |
--prefi=* |
--pref=* |
--pre=* |
--pr=* |
--p=*)
2279 prefix
=$ac_optarg ;;
2281 -program-prefix |
--program-prefix |
--program-prefi |
--program-pref \
2282 |
--program-pre |
--program-pr |
--program-p)
2283 ac_prev
=program_prefix
;;
2284 -program-prefix=* |
--program-prefix=* |
--program-prefi=* \
2285 |
--program-pref=* |
--program-pre=* |
--program-pr=* |
--program-p=*)
2286 program_prefix
=$ac_optarg ;;
2288 -program-suffix |
--program-suffix |
--program-suffi |
--program-suff \
2289 |
--program-suf |
--program-su |
--program-s)
2290 ac_prev
=program_suffix
;;
2291 -program-suffix=* |
--program-suffix=* |
--program-suffi=* \
2292 |
--program-suff=* |
--program-suf=* |
--program-su=* |
--program-s=*)
2293 program_suffix
=$ac_optarg ;;
2295 -program-transform-name |
--program-transform-name \
2296 |
--program-transform-nam |
--program-transform-na \
2297 |
--program-transform-n |
--program-transform- \
2298 |
--program-transform |
--program-transfor \
2299 |
--program-transfo |
--program-transf \
2300 |
--program-trans |
--program-tran \
2301 |
--progr-tra |
--program-tr |
--program-t)
2302 ac_prev
=program_transform_name
;;
2303 -program-transform-name=* |
--program-transform-name=* \
2304 |
--program-transform-nam=* |
--program-transform-na=* \
2305 |
--program-transform-n=* |
--program-transform-=* \
2306 |
--program-transform=* |
--program-transfor=* \
2307 |
--program-transfo=* |
--program-transf=* \
2308 |
--program-trans=* |
--program-tran=* \
2309 |
--progr-tra=* |
--program-tr=* |
--program-t=*)
2310 program_transform_name
=$ac_optarg ;;
2312 -pdfdir |
--pdfdir |
--pdfdi |
--pdfd |
--pdf |
--pd)
2314 -pdfdir=* |
--pdfdir=* |
--pdfdi=* |
--pdfd=* |
--pdf=* |
--pd=*)
2315 pdfdir
=$ac_optarg ;;
2317 -psdir |
--psdir |
--psdi |
--psd |
--ps)
2319 -psdir=* |
--psdir=* |
--psdi=* |
--psd=* |
--ps=*)
2322 -q |
-quiet |
--quiet |
--quie |
--qui |
--qu |
--q \
2323 |
-silent |
--silent |
--silen |
--sile |
--sil)
2326 -sbindir |
--sbindir |
--sbindi |
--sbind |
--sbin |
--sbi |
--sb)
2328 -sbindir=* |
--sbindir=* |
--sbindi=* |
--sbind=* |
--sbin=* \
2330 sbindir
=$ac_optarg ;;
2332 -sharedstatedir |
--sharedstatedir |
--sharedstatedi \
2333 |
--sharedstated |
--sharedstate |
--sharedstat |
--sharedsta \
2334 |
--sharedst |
--shareds |
--shared |
--share |
--shar \
2336 ac_prev
=sharedstatedir
;;
2337 -sharedstatedir=* |
--sharedstatedir=* |
--sharedstatedi=* \
2338 |
--sharedstated=* |
--sharedstate=* |
--sharedstat=* |
--sharedsta=* \
2339 |
--sharedst=* |
--shareds=* |
--shared=* |
--share=* |
--shar=* \
2341 sharedstatedir
=$ac_optarg ;;
2343 -site |
--site |
--sit)
2345 -site=* |
--site=* |
--sit=*)
2348 -srcdir |
--srcdir |
--srcdi |
--srcd |
--src |
--sr)
2350 -srcdir=* |
--srcdir=* |
--srcdi=* |
--srcd=* |
--src=* |
--sr=*)
2351 srcdir
=$ac_optarg ;;
2353 -sysconfdir |
--sysconfdir |
--sysconfdi |
--sysconfd |
--sysconf \
2354 |
--syscon |
--sysco |
--sysc |
--sys |
--sy)
2355 ac_prev
=sysconfdir
;;
2356 -sysconfdir=* |
--sysconfdir=* |
--sysconfdi=* |
--sysconfd=* |
--sysconf=* \
2357 |
--syscon=* |
--sysco=* |
--sysc=* |
--sys=* |
--sy=*)
2358 sysconfdir
=$ac_optarg ;;
2360 -target |
--target |
--targe |
--targ |
--tar |
--ta |
--t)
2361 ac_prev
=target_alias
;;
2362 -target=* |
--target=* |
--targe=* |
--targ=* |
--tar=* |
--ta=* |
--t=*)
2363 target_alias
=$ac_optarg ;;
2365 -v |
-verbose |
--verbose |
--verbos |
--verbo |
--verb)
2368 -version |
--version |
--versio |
--versi |
--vers |
-V)
2369 ac_init_version
=: ;;
2372 ac_useropt
=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
2373 # Reject names that are not valid shell variable names.
2374 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev
/null
&&
2375 as_fn_error $?
"invalid package name: $ac_useropt"
2376 ac_useropt_orig
=$ac_useropt
2377 ac_useropt
=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
2378 case $ac_user_opts in
2382 *) ac_unrecognized_opts
="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
2383 ac_unrecognized_sep
=', ';;
2385 eval with_
$ac_useropt=\
$ac_optarg ;;
2387 -without-* |
--without-*)
2388 ac_useropt
=`expr "x$ac_option" : 'x-*without-\(.*\)'`
2389 # Reject names that are not valid shell variable names.
2390 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev
/null
&&
2391 as_fn_error $?
"invalid package name: $ac_useropt"
2392 ac_useropt_orig
=$ac_useropt
2393 ac_useropt
=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
2394 case $ac_user_opts in
2398 *) ac_unrecognized_opts
="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
2399 ac_unrecognized_sep
=', ';;
2401 eval with_
$ac_useropt=no
;;
2404 # Obsolete; use --with-x.
2407 -x-includes |
--x-includes |
--x-include |
--x-includ |
--x-inclu \
2408 |
--x-incl |
--x-inc |
--x-in |
--x-i)
2409 ac_prev
=x_includes
;;
2410 -x-includes=* |
--x-includes=* |
--x-include=* |
--x-includ=* |
--x-inclu=* \
2411 |
--x-incl=* |
--x-inc=* |
--x-in=* |
--x-i=*)
2412 x_includes
=$ac_optarg ;;
2414 -x-libraries |
--x-libraries |
--x-librarie |
--x-librari \
2415 |
--x-librar |
--x-libra |
--x-libr |
--x-lib |
--x-li |
--x-l)
2416 ac_prev
=x_libraries
;;
2417 -x-libraries=* |
--x-libraries=* |
--x-librarie=* |
--x-librari=* \
2418 |
--x-librar=* |
--x-libra=* |
--x-libr=* |
--x-lib=* |
--x-li=* |
--x-l=*)
2419 x_libraries
=$ac_optarg ;;
2421 -*) as_fn_error $?
"unrecognized option: \`$ac_option'
2422 Try \`$0 --help' for more information"
2426 ac_envvar
=`expr "x$ac_option" : 'x\([^=]*\)='`
2427 # Reject names that are not valid shell variable names.
2428 case $ac_envvar in #(
2429 '' |
[0-9]* |
*[!_
$as_cr_alnum]* )
2430 as_fn_error $?
"invalid variable name: \`$ac_envvar'" ;;
2432 eval $ac_envvar=\
$ac_optarg
2433 export $ac_envvar ;;
2436 # FIXME: should be removed in autoconf 3.0.
2437 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
2438 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev
/null
&&
2439 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
2440 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
2446 if test -n "$ac_prev"; then
2447 ac_option
=--`echo $ac_prev | sed 's/_/-/g'`
2448 as_fn_error $?
"missing argument to $ac_option"
2451 if test -n "$ac_unrecognized_opts"; then
2452 case $enable_option_checking in
2454 fatal
) as_fn_error $?
"unrecognized options: $ac_unrecognized_opts" ;;
2455 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
2459 # Check all directory arguments for consistency.
2460 for ac_var
in exec_prefix prefix bindir sbindir libexecdir datarootdir \
2461 datadir sysconfdir sharedstatedir localstatedir includedir \
2462 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
2463 libdir localedir mandir
2465 eval ac_val
=\$
$ac_var
2466 # Remove trailing slashes.
2469 ac_val
=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
2470 eval $ac_var=\
$ac_val;;
2472 # Be sure to have absolute directory names.
2474 [\\/$
]* | ?
:[\\/]* ) continue;;
2475 NONE |
'' ) case $ac_var in *prefix
) continue;; esac;;
2477 as_fn_error $?
"expected an absolute directory name for --$ac_var: $ac_val"
2480 # There might be people who depend on the old broken behavior: `$host'
2481 # used to hold the argument of --host etc.
2482 # FIXME: To remove some day.
2485 target
=$target_alias
2487 # FIXME: To remove some day.
2488 if test "x$host_alias" != x
; then
2489 if test "x$build_alias" = x
; then
2490 cross_compiling
=maybe
2491 elif test "x$build_alias" != "x$host_alias"; then
2497 test -n "$host_alias" && ac_tool_prefix
=$host_alias-
2499 test "$silent" = yes && exec 6>/dev
/null
2502 ac_pwd
=`pwd` && test -n "$ac_pwd" &&
2503 ac_ls_di
=`ls -di .` &&
2504 ac_pwd_ls_di
=`cd "$ac_pwd" && ls -di .` ||
2505 as_fn_error $?
"working directory cannot be determined"
2506 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
2507 as_fn_error $?
"pwd does not report name of working directory"
2510 # Find the source files, if location was not specified.
2511 if test -z "$srcdir"; then
2512 ac_srcdir_defaulted
=yes
2513 # Try the directory containing this script, then the parent directory.
2514 ac_confdir
=`$as_dirname -- "$as_myself" ||
2515 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
2516 X"$as_myself" : 'X\(//\)[^/]' \| \
2517 X"$as_myself" : 'X\(//\)$' \| \
2518 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
2519 $as_echo X"$as_myself" |
2520 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
2538 if test ! -r "$srcdir/$ac_unique_file"; then
2542 ac_srcdir_defaulted
=no
2544 if test ! -r "$srcdir/$ac_unique_file"; then
2545 test "$ac_srcdir_defaulted" = yes && srcdir
="$ac_confdir or .."
2546 as_fn_error $?
"cannot find sources ($ac_unique_file) in $srcdir"
2548 ac_msg
="sources are in $srcdir, but \`cd $srcdir' does not work"
2550 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
2552 # When building in place, set srcdir=.
2553 if test "$ac_abs_confdir" = "$ac_pwd"; then
2556 # Remove unnecessary trailing slashes from srcdir.
2557 # Double slashes in file names in object file debugging info
2558 # mess up M-x gdb in Emacs.
2560 */) srcdir
=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
2562 for ac_var
in $ac_precious_vars; do
2563 eval ac_env_
${ac_var}_set=\${${ac_var}+set}
2564 eval ac_env_
${ac_var}_value
=\$
${ac_var}
2565 eval ac_cv_env_
${ac_var}_set=\${${ac_var}+set}
2566 eval ac_cv_env_
${ac_var}_value
=\$
${ac_var}
2570 # Report the --help message.
2572 if test "$ac_init_help" = "long"; then
2573 # Omit some internal or obsolete options to make the list less imposing.
2574 # This message is too long to be a string in the A/UX 3.1 sh.
2576 \`configure' configures libgnu UNUSED-VERSION to adapt to many kinds of systems.
2578 Usage: $0 [OPTION]... [VAR=VALUE]...
2580 To assign environment variables (e.g., CC, CFLAGS...), specify them as
2581 VAR=VALUE. See below for descriptions of some of the useful variables.
2583 Defaults for the options are specified in brackets.
2586 -h, --help display this help and exit
2587 --help=short display options specific to this package
2588 --help=recursive display the short help of all the included packages
2589 -V, --version display version information and exit
2590 -q, --quiet, --silent do not print \`checking ...' messages
2591 --cache-file=FILE cache test results in FILE [disabled]
2592 -C, --config-cache alias for \`--cache-file=config.cache'
2593 -n, --no-create do not create output files
2594 --srcdir=DIR find the sources in DIR [configure dir or \`..']
2596 Installation directories:
2597 --prefix=PREFIX install architecture-independent files in PREFIX
2598 [$ac_default_prefix]
2599 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
2602 By default, \`make install' will install all the files in
2603 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
2604 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
2605 for instance \`--prefix=\$HOME'.
2607 For better control, use the options below.
2609 Fine tuning of the installation directories:
2610 --bindir=DIR user executables [EPREFIX/bin]
2611 --sbindir=DIR system admin executables [EPREFIX/sbin]
2612 --libexecdir=DIR program executables [EPREFIX/libexec]
2613 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
2614 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
2615 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
2616 --libdir=DIR object code libraries [EPREFIX/lib]
2617 --includedir=DIR C header files [PREFIX/include]
2618 --oldincludedir=DIR C header files for non-gcc [/usr/include]
2619 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
2620 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
2621 --infodir=DIR info documentation [DATAROOTDIR/info]
2622 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
2623 --mandir=DIR man documentation [DATAROOTDIR/man]
2624 --docdir=DIR documentation root [DATAROOTDIR/doc/libgnu]
2625 --htmldir=DIR html documentation [DOCDIR]
2626 --dvidir=DIR dvi documentation [DOCDIR]
2627 --pdfdir=DIR pdf documentation [DOCDIR]
2628 --psdir=DIR ps documentation [DOCDIR]
2634 --program-prefix=PREFIX prepend PREFIX to installed program names
2635 --program-suffix=SUFFIX append SUFFIX to installed program names
2636 --program-transform-name=PROGRAM run
sed PROGRAM on installed program names
2639 --build=BUILD configure
for building on BUILD
[guessed
]
2640 --host=HOST cross-compile to build programs to run on HOST
[BUILD
]
2641 --target=TARGET configure
for building compilers
for TARGET
[HOST
]
2645 if test -n "$ac_init_help"; then
2646 case $ac_init_help in
2647 short | recursive
) echo "Configuration of libgnu UNUSED-VERSION:";;
2652 --disable-option-checking ignore unrecognized
--enable/--with options
2653 --disable-FEATURE do not include FEATURE
(same as
--enable-FEATURE=no
)
2654 --enable-FEATURE[=ARG
] include FEATURE
[ARG
=yes]
2655 --enable-maintainer-mode
2656 enable make rules and dependencies not useful
(and
2657 sometimes confusing
) to the casual installer
2658 --enable-plugins Enable support
for plugins
2659 --disable-largefile omit support
for large files
2660 --enable-threads={isoc|posix|isoc
+posix|windows
}
2661 specify multithreading API
2662 --disable-threads build without multithread safety
2663 --enable-cross-guesses={conservative|risky
}
2664 specify policy
for cross-compilation guesses
2665 --enable-dependency-tracking
2666 do not reject slow dependency extractors
2667 --disable-dependency-tracking
2668 speeds up one-time build
2669 --enable-silent-rules less verbose build output
(undo
: "make V=1")
2670 --disable-silent-rules verbose build output
(undo
: "make V=0")
2672 Some influential environment variables
:
2673 CC C compiler
command
2674 CFLAGS C compiler flags
2675 LDFLAGS linker flags
, e.g.
-L<lib dir
> if you have libraries
in a
2676 nonstandard directory
<lib dir
>
2677 LIBS libraries to pass to the linker
, e.g.
-l<library
>
2678 CPPFLAGS
(Objective
) C
/C
++ preprocessor flags
, e.g.
-I<include dir
> if
2679 you have headers
in a nonstandard directory
<include dir
>
2682 Use these variables to override the choices made by
`configure' or to help
2683 it to find libraries and programs with nonstandard names/locations.
2685 Report bugs to the package provider.
2690 if test "$ac_init_help" = "recursive"; then
2691 # If there are subdirs, report their specific --help.
2692 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2693 test -d "$ac_dir" ||
2694 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2699 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2701 ac_dir_suffix=/`$as_echo "$ac_dir" |
sed 's|^\.[\\/]||'`
2702 # A ".." for each directory in $ac_dir_suffix.
2703 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" |
sed 's|/[^\\/]*|/..|g;s|/||'`
2704 case $ac_top_builddir_sub in
2705 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2706 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2709 ac_abs_top_builddir=$ac_pwd
2710 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2711 # for backward compatibility:
2712 ac_top_builddir=$ac_top_build_prefix
2715 .) # We are building in place.
2717 ac_top_srcdir=$ac_top_builddir_sub
2718 ac_abs_top_srcdir=$ac_pwd ;;
2719 [\\/]* | ?:[\\/]* ) # Absolute name.
2720 ac_srcdir=$srcdir$ac_dir_suffix;
2721 ac_top_srcdir=$srcdir
2722 ac_abs_top_srcdir=$srcdir ;;
2724 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2725 ac_top_srcdir=$ac_top_build_prefix$srcdir
2726 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2728 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2730 cd "$ac_dir" || { ac_status=$?; continue; }
2731 # Check for guested configure.
2732 if test -f "$ac_srcdir/configure.gnu"; then
2734 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2735 elif test -f "$ac_srcdir/configure"; then
2737 $SHELL "$ac_srcdir/configure" --help=recursive
2739 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2741 cd "$ac_pwd" || { ac_status=$?; break; }
2745 test -n "$ac_init_help" && exit $ac_status
2746 if $ac_init_version; then
2748 libgnu configure UNUSED-VERSION
2749 generated by GNU Autoconf 2.69
2751 Copyright (C) 2012 Free Software Foundation, Inc.
2752 This configure script is free software; the Free Software Foundation
2753 gives unlimited permission to copy, distribute and modify it.
2758 ## ------------------------ ##
2759 ## Autoconf initialization. ##
2760 ## ------------------------ ##
2762 # ac_fn_c_try_compile LINENO
2763 # --------------------------
2764 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2765 ac_fn_c_try_compile ()
2767 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2768 rm -f conftest.$ac_objext
2769 if { { ac_try="$ac_compile"
2771 *\"* | *\`* |
*\\*) ac_try_echo
=\
$ac_try;;
2772 *) ac_try_echo
=$ac_try;;
2774 eval ac_try_echo
="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2775 $as_echo "$ac_try_echo"; } >&5
2776 (eval "$ac_compile") 2>conftest.err
2778 if test -s conftest.err
; then
2779 grep -v '^ *+' conftest.err
>conftest.er1
2780 cat conftest.er1
>&5
2781 mv -f conftest.er1 conftest.err
2783 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2784 test $ac_status = 0; } && {
2785 test -z "$ac_c_werror_flag" ||
2786 test ! -s conftest.err
2787 } && test -s conftest.
$ac_objext; then :
2790 $as_echo "$as_me: failed program was:" >&5
2791 sed 's/^/| /' conftest.
$ac_ext >&5
2795 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2796 as_fn_set_status
$ac_retval
2798 } # ac_fn_c_try_compile
2800 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2801 # -------------------------------------------------------
2802 # Tests whether HEADER exists and can be compiled using the include files in
2803 # INCLUDES, setting the cache variable VAR accordingly.
2804 ac_fn_c_check_header_compile
()
2806 as_lineno
=${as_lineno-"$1"} as_lineno_stack
=as_lineno_stack
=$as_lineno_stack
2807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2808 $as_echo_n "checking for $2... " >&6; }
2809 if eval \
${$3+:} false
; then :
2810 $as_echo_n "(cached) " >&6
2812 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
2813 /* end confdefs.h. */
2817 if ac_fn_c_try_compile
"$LINENO"; then :
2822 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
2825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2826 $as_echo "$ac_res" >&6; }
2827 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2829 } # ac_fn_c_check_header_compile
2831 # ac_fn_c_try_cpp LINENO
2832 # ----------------------
2833 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2836 as_lineno
=${as_lineno-"$1"} as_lineno_stack
=as_lineno_stack
=$as_lineno_stack
2837 if { { ac_try
="$ac_cpp conftest.$ac_ext"
2839 *\"* |
*\
`* | *\\*) ac_try_echo=\$ac_try;;
2840 *) ac_try_echo=$ac_try;;
2842 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2843 $as_echo "$ac_try_echo"; } >&5
2844 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2846 if test -s conftest.err; then
2847 grep -v '^ *+' conftest.err >conftest.er1
2848 cat conftest.er1 >&5
2849 mv -f conftest.er1 conftest.err
2851 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2852 test $ac_status = 0; } > conftest.i && {
2853 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2854 test ! -s conftest.err
2858 $as_echo "$as_me: failed program was:" >&5
2859 sed 's/^/| /' conftest.$ac_ext >&5
2863 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2864 as_fn_set_status $ac_retval
2868 # ac_fn_c_try_run LINENO
2869 # ----------------------
2870 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2871 # that executables *can* be run.
2874 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2875 if { { ac_try="$ac_link"
2877 *\"* | *\`* |
*\\*) ac_try_echo
=\
$ac_try;;
2878 *) ac_try_echo
=$ac_try;;
2880 eval ac_try_echo
="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2881 $as_echo "$ac_try_echo"; } >&5
2882 (eval "$ac_link") 2>&5
2884 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2885 test $ac_status = 0; } && { ac_try
='./conftest$ac_exeext'
2886 { { case "(($ac_try" in
2887 *\"* |
*\
`* | *\\*) ac_try_echo=\$ac_try;;
2888 *) ac_try_echo=$ac_try;;
2890 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2891 $as_echo "$ac_try_echo"; } >&5
2892 (eval "$ac_try") 2>&5
2894 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2895 test $ac_status = 0; }; }; then :
2898 $as_echo "$as_me: program exited with status $ac_status" >&5
2899 $as_echo "$as_me: failed program was:" >&5
2900 sed 's/^/| /' conftest.$ac_ext >&5
2902 ac_retval=$ac_status
2904 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2905 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2906 as_fn_set_status $ac_retval
2910 # ac_fn_c_try_link LINENO
2911 # -----------------------
2912 # Try to link conftest.$ac_ext, and return whether this succeeded.
2915 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2916 rm -f conftest.$ac_objext conftest$ac_exeext
2917 if { { ac_try="$ac_link"
2919 *\"* | *\`* |
*\\*) ac_try_echo
=\
$ac_try;;
2920 *) ac_try_echo
=$ac_try;;
2922 eval ac_try_echo
="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2923 $as_echo "$ac_try_echo"; } >&5
2924 (eval "$ac_link") 2>conftest.err
2926 if test -s conftest.err
; then
2927 grep -v '^ *+' conftest.err
>conftest.er1
2928 cat conftest.er1
>&5
2929 mv -f conftest.er1 conftest.err
2931 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2932 test $ac_status = 0; } && {
2933 test -z "$ac_c_werror_flag" ||
2934 test ! -s conftest.err
2935 } && test -s conftest
$ac_exeext && {
2936 test "$cross_compiling" = yes ||
2937 test -x conftest
$ac_exeext
2941 $as_echo "$as_me: failed program was:" >&5
2942 sed 's/^/| /' conftest.
$ac_ext >&5
2946 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2947 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2948 # interfere with the next link command; also delete a directory that is
2949 # left behind by Apple's compiler. We do this before executing the actions.
2950 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2951 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2952 as_fn_set_status
$ac_retval
2954 } # ac_fn_c_try_link
2956 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2957 # -------------------------------------------
2958 # Tests whether TYPE exists after having included INCLUDES, setting cache
2959 # variable VAR accordingly.
2960 ac_fn_c_check_type
()
2962 as_lineno
=${as_lineno-"$1"} as_lineno_stack
=as_lineno_stack
=$as_lineno_stack
2963 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2964 $as_echo_n "checking for $2... " >&6; }
2965 if eval \
${$3+:} false
; then :
2966 $as_echo_n "(cached) " >&6
2969 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
2970 /* end confdefs.h. */
2981 if ac_fn_c_try_compile
"$LINENO"; then :
2982 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
2983 /* end confdefs.h. */
2994 if ac_fn_c_try_compile
"$LINENO"; then :
2999 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
3001 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
3004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
3005 $as_echo "$ac_res" >&6; }
3006 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3008 } # ac_fn_c_check_type
3010 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
3011 # -------------------------------------------------------
3012 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
3013 # the include files in INCLUDES and setting the cache variable VAR
3015 ac_fn_c_check_header_mongrel
()
3017 as_lineno
=${as_lineno-"$1"} as_lineno_stack
=as_lineno_stack
=$as_lineno_stack
3018 if eval \
${$3+:} false
; then :
3019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
3020 $as_echo_n "checking for $2... " >&6; }
3021 if eval \
${$3+:} false
; then :
3022 $as_echo_n "(cached) " >&6
3025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
3026 $as_echo "$ac_res" >&6; }
3028 # Is the header compilable?
3029 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
3030 $as_echo_n "checking $2 usability... " >&6; }
3031 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
3032 /* end confdefs.h. */
3036 if ac_fn_c_try_compile
"$LINENO"; then :
3037 ac_header_compiler
=yes
3039 ac_header_compiler
=no
3041 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
3042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
3043 $as_echo "$ac_header_compiler" >&6; }
3045 # Is the header present?
3046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
3047 $as_echo_n "checking $2 presence... " >&6; }
3048 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
3049 /* end confdefs.h. */
3052 if ac_fn_c_try_cpp
"$LINENO"; then :
3053 ac_header_preproc
=yes
3055 ac_header_preproc
=no
3057 rm -f conftest.err conftest.i conftest.
$ac_ext
3058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
3059 $as_echo "$ac_header_preproc" >&6; }
3061 # So? What about this header?
3062 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
3064 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
3065 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
3066 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
3067 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
3070 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
3071 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
3072 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
3073 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
3074 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
3075 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
3076 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
3077 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
3078 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
3079 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
3082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
3083 $as_echo_n "checking for $2... " >&6; }
3084 if eval \
${$3+:} false
; then :
3085 $as_echo_n "(cached) " >&6
3087 eval "$3=\$ac_header_compiler"
3090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
3091 $as_echo "$ac_res" >&6; }
3093 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3095 } # ac_fn_c_check_header_mongrel
3097 # ac_fn_c_check_func LINENO FUNC VAR
3098 # ----------------------------------
3099 # Tests whether FUNC exists, setting the cache variable VAR accordingly
3100 ac_fn_c_check_func
()
3102 as_lineno
=${as_lineno-"$1"} as_lineno_stack
=as_lineno_stack
=$as_lineno_stack
3103 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
3104 $as_echo_n "checking for $2... " >&6; }
3105 if eval \
${$3+:} false
; then :
3106 $as_echo_n "(cached) " >&6
3108 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
3109 /* end confdefs.h. */
3110 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
3111 For example, HP-UX 11i <limits.h> declares gettimeofday. */
3112 #define $2 innocuous_$2
3114 /* System header to define __stub macros and hopefully few prototypes,
3115 which can conflict with char $2 (); below.
3116 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3117 <limits.h> exists even on freestanding compilers. */
3120 # include <limits.h>
3122 # include <assert.h>
3127 /* Override any GCC internal prototype to avoid an error.
3128 Use char because int might match the return type of a GCC
3129 builtin and then its argument prototype would still apply. */
3134 /* The GNU C library defines this for functions which it implements
3135 to always fail with ENOSYS. Some functions are actually named
3136 something starting with __ and the normal name is an alias. */
3137 #if defined __stub_$2 || defined __stub___$2
3149 if ac_fn_c_try_link
"$LINENO"; then :
3154 rm -f core conftest.err conftest.
$ac_objext \
3155 conftest
$ac_exeext conftest.
$ac_ext
3158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
3159 $as_echo "$ac_res" >&6; }
3160 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3162 } # ac_fn_c_check_func
3164 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
3165 # ---------------------------------------------
3166 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
3168 ac_fn_c_check_decl
()
3170 ac_save_ac_compile
="$ac_compile"
3171 if test -n "$ac_compile_for_check_decl"; then
3172 ac_compile
="$ac_compile_for_check_decl"
3174 as_lineno
=${as_lineno-"$1"} as_lineno_stack
=as_lineno_stack
=$as_lineno_stack
3175 as_decl_name
=`echo $2|sed 's/ *(.*//'`
3176 as_decl_use
=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
3177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
3178 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
3179 if eval \
${$3+:} false
; then :
3180 $as_echo_n "(cached) " >&6
3182 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
3183 /* end confdefs.h. */
3188 #ifndef $as_decl_name
3190 (void) $as_decl_use;
3192 (void) $as_decl_name;
3200 if ac_fn_c_try_compile
"$LINENO"; then :
3205 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
3208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
3209 $as_echo "$ac_res" >&6; }
3210 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3211 ac_compile
="$ac_save_ac_compile"
3213 } # ac_fn_c_check_decl
3215 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
3216 # --------------------------------------------
3217 # Tries to find the compile-time value of EXPR in a program that includes
3218 # INCLUDES, setting VAR accordingly. Returns whether the value could be
3220 ac_fn_c_compute_int
()
3222 as_lineno
=${as_lineno-"$1"} as_lineno_stack
=as_lineno_stack
=$as_lineno_stack
3223 if test "$cross_compiling" = yes; then
3224 # Depending upon the size, compute the lo and hi bounds.
3225 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
3226 /* end confdefs.h. */
3231 static int test_array [1 - 2 * !(($2) >= 0)];
3233 return test_array [0];
3239 if ac_fn_c_try_compile
"$LINENO"; then :
3242 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
3243 /* end confdefs.h. */
3248 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
3250 return test_array [0];
3256 if ac_fn_c_try_compile
"$LINENO"; then :
3257 ac_hi
=$ac_mid; break
3259 as_fn_arith
$ac_mid + 1 && ac_lo
=$as_val
3260 if test $ac_lo -le $ac_mid; then
3264 as_fn_arith
2 '*' $ac_mid + 1 && ac_mid
=$as_val
3266 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
3269 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
3270 /* end confdefs.h. */
3275 static int test_array [1 - 2 * !(($2) < 0)];
3277 return test_array [0];
3283 if ac_fn_c_try_compile
"$LINENO"; then :
3286 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
3287 /* end confdefs.h. */
3292 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
3294 return test_array [0];
3300 if ac_fn_c_try_compile
"$LINENO"; then :
3301 ac_lo
=$ac_mid; break
3303 as_fn_arith
'(' $ac_mid ')' - 1 && ac_hi
=$as_val
3304 if test $ac_mid -le $ac_hi; then
3308 as_fn_arith
2 '*' $ac_mid && ac_mid
=$as_val
3310 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
3315 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
3317 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
3318 # Binary search between lo and hi bounds.
3319 while test "x$ac_lo" != "x$ac_hi"; do
3320 as_fn_arith
'(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid
=$as_val
3321 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
3322 /* end confdefs.h. */
3327 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
3329 return test_array [0];
3335 if ac_fn_c_try_compile
"$LINENO"; then :
3338 as_fn_arith
'(' $ac_mid ')' + 1 && ac_lo
=$as_val
3340 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
3343 ?
*) eval "$3=\$ac_lo"; ac_retval
=0 ;;
3347 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
3348 /* end confdefs.h. */
3350 static long int longval () { return $2; }
3351 static unsigned long int ulongval () { return $2; }
3358 FILE *f = fopen ("conftest.val", "w");
3363 long int i = longval ();
3366 fprintf (f, "%ld", i);
3370 unsigned long int i = ulongval ();
3373 fprintf (f, "%lu", i);
3375 /* Do not output a trailing newline, as this causes \r\n confusion
3376 on some platforms. */
3377 return ferror (f) || fclose (f) != 0;
3383 if ac_fn_c_try_run
"$LINENO"; then :
3384 echo >>conftest.val
; read $3 <conftest.val
; ac_retval
=0
3388 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
3389 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
3393 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3394 as_fn_set_status
$ac_retval
3396 } # ac_fn_c_compute_int
3398 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
3399 # ----------------------------------------------------
3400 # Tries to find if the field MEMBER exists in type AGGR, after including
3401 # INCLUDES, setting cache variable VAR accordingly.
3402 ac_fn_c_check_member
()
3404 as_lineno
=${as_lineno-"$1"} as_lineno_stack
=as_lineno_stack
=$as_lineno_stack
3405 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
3406 $as_echo_n "checking for $2.$3... " >&6; }
3407 if eval \
${$4+:} false
; then :
3408 $as_echo_n "(cached) " >&6
3410 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
3411 /* end confdefs.h. */
3423 if ac_fn_c_try_compile
"$LINENO"; then :
3426 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
3427 /* end confdefs.h. */
3433 if (sizeof ac_aggr.$3)
3439 if ac_fn_c_try_compile
"$LINENO"; then :
3444 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
3446 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
3449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
3450 $as_echo "$ac_res" >&6; }
3451 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3453 } # ac_fn_c_check_member
3454 cat >config.log
<<_ACEOF
3455 This file contains any messages produced by compilers while
3456 running configure, to aid debugging if configure makes a mistake.
3458 It was created by libgnu $as_me UNUSED-VERSION, which was
3459 generated by GNU Autoconf 2.69. Invocation command line was
3471 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
3472 uname -m = `(uname -m) 2>/dev/null || echo unknown`
3473 uname -r = `(uname -r) 2>/dev/null || echo unknown`
3474 uname -s = `(uname -s) 2>/dev/null || echo unknown`
3475 uname -v = `(uname -v) 2>/dev/null || echo unknown`
3477 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
3478 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
3480 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
3481 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
3482 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
3483 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
3484 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
3485 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
3486 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
3490 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
3494 test -z "$as_dir" && as_dir
=.
3495 $as_echo "PATH: $as_dir"
3511 # Keep a trace of the command line.
3512 # Strip out --no-create and --no-recursion so they do not pile up.
3513 # Strip out --silent because we don't want to record it for future runs.
3514 # Also quote any args containing shell meta-characters.
3515 # Make two passes to allow for proper duplicate-argument suppression.
3519 ac_must_keep_next
=false
3525 -no-create |
--no-c* |
-n |
-no-recursion |
--no-r*) continue ;;
3526 -q |
-quiet |
--quiet |
--quie |
--qui |
--qu |
--q \
3527 |
-silent |
--silent |
--silen |
--sile |
--sil)
3530 ac_arg
=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
3533 1) as_fn_append ac_configure_args0
" '$ac_arg'" ;;
3535 as_fn_append ac_configure_args1
" '$ac_arg'"
3536 if test $ac_must_keep_next = true
; then
3537 ac_must_keep_next
=false
# Got value, back to normal.
3540 *=* |
--config-cache |
-C |
-disable-* |
--disable-* \
3541 |
-enable-* |
--enable-* |
-gas |
--g* |
-nfp |
--nf* \
3542 |
-q |
-quiet |
--q* |
-silent |
--sil* |
-v |
-verb* \
3543 |
-with-* |
--with-* |
-without-* |
--without-* |
--x)
3544 case "$ac_configure_args0 " in
3545 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
3548 -* ) ac_must_keep_next
=true
;;
3551 as_fn_append ac_configure_args
" '$ac_arg'"
3556 { ac_configure_args0
=; unset ac_configure_args0
;}
3557 { ac_configure_args1
=; unset ac_configure_args1
;}
3559 # When interrupted or exit'd, cleanup temporary files, and complete
3560 # config.log. We remove comments because anyway the quotes in there
3561 # would cause problems or look ugly.
3562 # WARNING: Use '\'' to represent an apostrophe within the trap.
3563 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3564 trap 'exit_status=$?
3565 # Save into config.log some information that might help in debugging.
3569 $as_echo "## ---------------- ##
3570 ## Cache variables. ##
3571 ## ---------------- ##"
3573 # The following way of writing the cache mishandles newlines in values,
3575 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3576 eval ac_val=\$$ac_var
3580 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3581 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3584 _ | IFS | as_nl) ;; #(
3585 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3586 *) { eval $ac_var=; unset $ac_var;} ;;
3591 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3592 *${as_nl}ac_space=\ *)
3594 "s/'\''/'\''\\\\'\'''\''/g;
3595 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3598 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3605 $as_echo "## ----------------- ##
3606 ## Output variables. ##
3607 ## ----------------- ##"
3609 for ac_var in $ac_subst_vars
3611 eval ac_val=\$$ac_var
3613 *\'\''*) ac_val
=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3615 $as_echo "$ac_var='\''$ac_val'\''"
3619 if test -n "$ac_subst_files"; then
3620 $as_echo "## ------------------- ##
3621 ## File substitutions. ##
3622 ## ------------------- ##"
3624 for ac_var
in $ac_subst_files
3626 eval ac_val
=\$
$ac_var
3628 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3630 $as_echo "$ac_var='\''$ac_val'\''"
3635 if test -s confdefs.h; then
3636 $as_echo "## ----------- ##
3643 test "$ac_signal" != 0 &&
3644 $as_echo "$as_me: caught signal $ac_signal"
3645 $as_echo "$as_me: exit $exit_status"
3647 rm -f core *.core core.conftest.* &&
3648 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3651 for ac_signal
in 1 2 13 15; do
3652 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3656 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3657 rm -f -r conftest
* confdefs.h
3659 $as_echo "/* confdefs.h */" > confdefs.h
3661 # Predefined preprocessor variables.
3663 cat >>confdefs.h
<<_ACEOF
3664 #define PACKAGE_NAME "$PACKAGE_NAME"
3667 cat >>confdefs.h
<<_ACEOF
3668 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3671 cat >>confdefs.h
<<_ACEOF
3672 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3675 cat >>confdefs.h
<<_ACEOF
3676 #define PACKAGE_STRING "$PACKAGE_STRING"
3679 cat >>confdefs.h
<<_ACEOF
3680 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3683 cat >>confdefs.h
<<_ACEOF
3684 #define PACKAGE_URL "$PACKAGE_URL"
3688 # Let the site file select an alternate cache file if it wants to.
3689 # Prefer an explicitly selected file to automatically selected ones.
3692 if test -n "$CONFIG_SITE"; then
3693 # We do not want a PATH search for config.site.
3694 case $CONFIG_SITE in #((
3695 -*) ac_site_file1
=.
/$CONFIG_SITE;;
3696 */*) ac_site_file1
=$CONFIG_SITE;;
3697 *) ac_site_file1
=.
/$CONFIG_SITE;;
3699 elif test "x$prefix" != xNONE
; then
3700 ac_site_file1
=$prefix/share
/config.site
3701 ac_site_file2
=$prefix/etc
/config.site
3703 ac_site_file1
=$ac_default_prefix/share
/config.site
3704 ac_site_file2
=$ac_default_prefix/etc
/config.site
3706 for ac_site_file
in "$ac_site_file1" "$ac_site_file2"
3708 test "x$ac_site_file" = xNONE
&& continue
3709 if test /dev
/null
!= "$ac_site_file" && test -r "$ac_site_file"; then
3710 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3711 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3712 sed 's/^/| /' "$ac_site_file" >&5
3714 ||
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3715 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3716 as_fn_error $?
"failed to load site script $ac_site_file
3717 See \`config.log' for more details" "$LINENO" 5; }
3721 if test -r "$cache_file"; then
3722 # Some versions of bash will fail to source /dev/null (special files
3723 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3724 if test /dev
/null
!= "$cache_file" && test -f "$cache_file"; then
3725 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3726 $as_echo "$as_me: loading cache $cache_file" >&6;}
3728 [\\/]* | ?
:[\\/]* ) .
"$cache_file";;
3729 *) .
"./$cache_file";;
3733 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3734 $as_echo "$as_me: creating cache $cache_file" >&6;}
3738 as_fn_append ac_header_list
" wchar.h"
3739 as_fn_append ac_header_list
" minix/config.h"
3740 as_fn_append ac_header_list
" arpa/inet.h"
3741 as_fn_append ac_header_list
" features.h"
3742 as_fn_append ac_header_list
" sys/socket.h"
3743 as_fn_append ac_func_list
" btowc"
3744 as_fn_append ac_func_list
" canonicalize_file_name"
3745 as_fn_append ac_func_list
" faccessat"
3746 as_fn_append ac_func_list
" realpath"
3747 as_fn_append ac_header_list
" sys/param.h"
3748 as_fn_append ac_header_list
" unistd.h"
3749 as_fn_append ac_func_list
" chown"
3750 as_fn_append ac_func_list
" fchown"
3751 as_fn_append ac_func_list
" _set_invalid_parameter_handler"
3752 as_fn_append ac_func_list
" fchdir"
3753 as_fn_append ac_header_list
" dirent.h"
3754 as_fn_append ac_func_list
" fcntl"
3755 as_fn_append ac_func_list
" symlink"
3756 as_fn_append ac_func_list
" fdopendir"
3757 as_fn_append ac_func_list
" mempcpy"
3758 as_fn_append ac_header_list
" fnmatch.h"
3759 as_fn_append ac_func_list
" fnmatch"
3760 as_fn_append ac_func_list
" mbsrtowcs"
3761 gl_fnmatch_required
=GNU
3762 as_fn_append ac_header_list
" sys/stat.h"
3763 as_fn_append ac_func_list
" fstatat"
3764 as_fn_append ac_func_list
" getdelim"
3765 as_fn_append ac_func_list
" getdtablesize"
3766 as_fn_append ac_func_list
" getlogin_r"
3767 as_fn_append ac_func_list
" getprogname"
3768 as_fn_append ac_func_list
" getexecname"
3769 as_fn_append ac_func_list
" getrandom"
3770 as_fn_append ac_header_list
" sys/time.h"
3771 as_fn_append ac_func_list
" gettimeofday"
3772 as_fn_append ac_header_list
" glob.h"
3773 as_fn_append ac_func_list
" glob"
3774 as_fn_append ac_func_list
" glob_pattern_p"
3775 as_fn_append ac_func_list
" getpwnam_r"
3776 as_fn_append ac_header_list
" threads.h"
3777 as_fn_append ac_header_list
" netdb.h"
3778 as_fn_append ac_header_list
" netinet/in.h"
3779 as_fn_append ac_header_list
" limits.h"
3780 as_fn_append ac_header_list
" inttypes.h"
3781 as_fn_append ac_header_list
" sys/types.h"
3782 as_fn_append ac_header_list
" stdint.h"
3783 as_fn_append ac_func_list
" isblank"
3784 as_fn_append ac_header_list
" xlocale.h"
3785 as_fn_append ac_func_list
" lstat"
3786 as_fn_append ac_header_list
" math.h"
3787 as_fn_append ac_func_list
" mbsinit"
3788 as_fn_append ac_func_list
" mbrtowc"
3789 as_fn_append ac_header_list
" sys/mman.h"
3790 as_fn_append ac_func_list
" mprotect"
3791 as_fn_append ac_func_list
" mkostemp"
3792 as_fn_append ac_func_list
" openat"
3793 as_fn_append ac_func_list
" pipe"
3794 as_fn_append ac_func_list
" readlink"
3795 as_fn_append ac_func_list
" link"
3796 as_fn_append ac_header_list
" sys/select.h"
3797 as_fn_append ac_func_list
" setenv"
3798 as_fn_append ac_func_list
" strerror_r"
3799 as_fn_append ac_func_list
" __xpg_strerror_r"
3800 as_fn_append ac_func_list
" catgets"
3801 as_fn_append ac_func_list
" snprintf"
3802 as_fn_append ac_header_list
" strings.h"
3803 as_fn_append ac_header_list
" sys/random.h"
3804 as_fn_append ac_header_list
" sys/uio.h"
3805 as_fn_append ac_func_list
" localtime_r"
3806 as_fn_append ac_header_list
" crtdefs.h"
3807 as_fn_append ac_func_list
" iswcntrl"
3808 as_fn_append ac_header_list
" wctype.h"
3809 as_fn_append ac_func_list
" wmempcpy"
3810 # Check that the precious variables saved in the cache have kept the same
3812 ac_cache_corrupted
=false
3813 for ac_var
in $ac_precious_vars; do
3814 eval ac_old_set
=\
$ac_cv_env_${ac_var}_set
3815 eval ac_new_set
=\
$ac_env_${ac_var}_set
3816 eval ac_old_val
=\
$ac_cv_env_${ac_var}_value
3817 eval ac_new_val
=\
$ac_env_${ac_var}_value
3818 case $ac_old_set,$ac_new_set in
3820 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3821 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3822 ac_cache_corrupted
=: ;;
3824 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3825 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3826 ac_cache_corrupted
=: ;;
3829 if test "x$ac_old_val" != "x$ac_new_val"; then
3830 # differences in whitespace do not lead to failure.
3831 ac_old_val_w
=`echo x $ac_old_val`
3832 ac_new_val_w
=`echo x $ac_new_val`
3833 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3834 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3835 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3836 ac_cache_corrupted
=:
3838 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3839 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3840 eval $ac_var=\
$ac_old_val
3842 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3843 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3844 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3845 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3848 # Pass precious variables to config.status.
3849 if test "$ac_new_set" = set; then
3851 *\'*) ac_arg
=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3852 *) ac_arg
=$ac_var=$ac_new_val ;;
3854 case " $ac_configure_args " in
3855 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3856 *) as_fn_append ac_configure_args
" '$ac_arg'" ;;
3860 if $ac_cache_corrupted; then
3861 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3862 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3863 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3864 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3865 as_fn_error $?
"run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3867 ## -------------------- ##
3868 ## Main body of script. ##
3869 ## -------------------- ##
3872 ac_cpp
='$CPP $CPPFLAGS'
3873 ac_compile
='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3874 ac_link
='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3875 ac_compiler_gnu
=$ac_cv_c_compiler_gnu
3882 ac_config_headers
="$ac_config_headers config.h:config.in"
3887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
3888 $as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
3889 # Check whether --enable-maintainer-mode was given.
3890 if test "${enable_maintainer_mode+set}" = set; then :
3891 enableval
=$enable_maintainer_mode; USE_MAINTAINER_MODE
=$enableval
3893 USE_MAINTAINER_MODE
=no
3896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
3897 $as_echo "$USE_MAINTAINER_MODE" >&6; }
3898 if test $USE_MAINTAINER_MODE = yes; then
3899 MAINTAINER_MODE_TRUE
=
3900 MAINTAINER_MODE_FALSE
='#'
3902 MAINTAINER_MODE_TRUE
='#'
3903 MAINTAINER_MODE_FALSE
=
3906 MAINT
=$MAINTAINER_MODE_TRUE
3911 ac_cpp
='$CPP $CPPFLAGS'
3912 ac_compile
='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3913 ac_link
='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3914 ac_compiler_gnu
=$ac_cv_c_compiler_gnu
3915 if test -n "$ac_tool_prefix"; then
3916 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3917 set dummy
${ac_tool_prefix}gcc
; ac_word
=$2
3918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3919 $as_echo_n "checking for $ac_word... " >&6; }
3920 if ${ac_cv_prog_CC+:} false
; then :
3921 $as_echo_n "(cached) " >&6
3923 if test -n "$CC"; then
3924 ac_cv_prog_CC
="$CC" # Let the user override the test.
3926 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
3930 test -z "$as_dir" && as_dir
=.
3931 for ac_exec_ext
in '' $ac_executable_extensions; do
3932 if as_fn_executable_p
"$as_dir/$ac_word$ac_exec_ext"; then
3933 ac_cv_prog_CC
="${ac_tool_prefix}gcc"
3934 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3944 if test -n "$CC"; then
3945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3946 $as_echo "$CC" >&6; }
3948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3949 $as_echo "no" >&6; }
3954 if test -z "$ac_cv_prog_CC"; then
3956 # Extract the first word of "gcc", so it can be a program name with args.
3957 set dummy gcc
; ac_word
=$2
3958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3959 $as_echo_n "checking for $ac_word... " >&6; }
3960 if ${ac_cv_prog_ac_ct_CC+:} false
; then :
3961 $as_echo_n "(cached) " >&6
3963 if test -n "$ac_ct_CC"; then
3964 ac_cv_prog_ac_ct_CC
="$ac_ct_CC" # Let the user override the test.
3966 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
3970 test -z "$as_dir" && as_dir
=.
3971 for ac_exec_ext
in '' $ac_executable_extensions; do
3972 if as_fn_executable_p
"$as_dir/$ac_word$ac_exec_ext"; then
3973 ac_cv_prog_ac_ct_CC
="gcc"
3974 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3983 ac_ct_CC
=$ac_cv_prog_ac_ct_CC
3984 if test -n "$ac_ct_CC"; then
3985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3986 $as_echo "$ac_ct_CC" >&6; }
3988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3989 $as_echo "no" >&6; }
3992 if test "x$ac_ct_CC" = x
; then
3995 case $cross_compiling:$ac_tool_warned in
3997 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3998 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3999 ac_tool_warned
=yes ;;
4007 if test -z "$CC"; then
4008 if test -n "$ac_tool_prefix"; then
4009 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4010 set dummy
${ac_tool_prefix}cc
; ac_word
=$2
4011 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4012 $as_echo_n "checking for $ac_word... " >&6; }
4013 if ${ac_cv_prog_CC+:} false
; then :
4014 $as_echo_n "(cached) " >&6
4016 if test -n "$CC"; then
4017 ac_cv_prog_CC
="$CC" # Let the user override the test.
4019 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
4023 test -z "$as_dir" && as_dir
=.
4024 for ac_exec_ext
in '' $ac_executable_extensions; do
4025 if as_fn_executable_p
"$as_dir/$ac_word$ac_exec_ext"; then
4026 ac_cv_prog_CC
="${ac_tool_prefix}cc"
4027 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4037 if test -n "$CC"; then
4038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4039 $as_echo "$CC" >&6; }
4041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4042 $as_echo "no" >&6; }
4048 if test -z "$CC"; then
4049 # Extract the first word of "cc", so it can be a program name with args.
4050 set dummy cc
; ac_word
=$2
4051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4052 $as_echo_n "checking for $ac_word... " >&6; }
4053 if ${ac_cv_prog_CC+:} false
; then :
4054 $as_echo_n "(cached) " >&6
4056 if test -n "$CC"; then
4057 ac_cv_prog_CC
="$CC" # Let the user override the test.
4060 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
4064 test -z "$as_dir" && as_dir
=.
4065 for ac_exec_ext
in '' $ac_executable_extensions; do
4066 if as_fn_executable_p
"$as_dir/$ac_word$ac_exec_ext"; then
4067 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4068 ac_prog_rejected
=yes
4072 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4079 if test $ac_prog_rejected = yes; then
4080 # We found a bogon in the path, so make sure we never use it.
4081 set dummy
$ac_cv_prog_CC
4083 if test $# != 0; then
4084 # We chose a different compiler from the bogus one.
4085 # However, it has the same basename, so the bogon will be chosen
4086 # first if we set CC to just the basename; use the full file name.
4088 ac_cv_prog_CC
="$as_dir/$ac_word${1+' '}$@"
4094 if test -n "$CC"; then
4095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4096 $as_echo "$CC" >&6; }
4098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4099 $as_echo "no" >&6; }
4104 if test -z "$CC"; then
4105 if test -n "$ac_tool_prefix"; then
4106 for ac_prog
in cl.exe
4108 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4109 set dummy
$ac_tool_prefix$ac_prog; ac_word
=$2
4110 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4111 $as_echo_n "checking for $ac_word... " >&6; }
4112 if ${ac_cv_prog_CC+:} false
; then :
4113 $as_echo_n "(cached) " >&6
4115 if test -n "$CC"; then
4116 ac_cv_prog_CC
="$CC" # Let the user override the test.
4118 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
4122 test -z "$as_dir" && as_dir
=.
4123 for ac_exec_ext
in '' $ac_executable_extensions; do
4124 if as_fn_executable_p
"$as_dir/$ac_word$ac_exec_ext"; then
4125 ac_cv_prog_CC
="$ac_tool_prefix$ac_prog"
4126 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4136 if test -n "$CC"; then
4137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4138 $as_echo "$CC" >&6; }
4140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4141 $as_echo "no" >&6; }
4145 test -n "$CC" && break
4148 if test -z "$CC"; then
4150 for ac_prog
in cl.exe
4152 # Extract the first word of "$ac_prog", so it can be a program name with args.
4153 set dummy
$ac_prog; ac_word
=$2
4154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4155 $as_echo_n "checking for $ac_word... " >&6; }
4156 if ${ac_cv_prog_ac_ct_CC+:} false
; then :
4157 $as_echo_n "(cached) " >&6
4159 if test -n "$ac_ct_CC"; then
4160 ac_cv_prog_ac_ct_CC
="$ac_ct_CC" # Let the user override the test.
4162 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
4166 test -z "$as_dir" && as_dir
=.
4167 for ac_exec_ext
in '' $ac_executable_extensions; do
4168 if as_fn_executable_p
"$as_dir/$ac_word$ac_exec_ext"; then
4169 ac_cv_prog_ac_ct_CC
="$ac_prog"
4170 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4179 ac_ct_CC
=$ac_cv_prog_ac_ct_CC
4180 if test -n "$ac_ct_CC"; then
4181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4182 $as_echo "$ac_ct_CC" >&6; }
4184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4185 $as_echo "no" >&6; }
4189 test -n "$ac_ct_CC" && break
4192 if test "x$ac_ct_CC" = x
; then
4195 case $cross_compiling:$ac_tool_warned in
4197 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4198 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4199 ac_tool_warned
=yes ;;
4206 if test -z "$CC"; then
4207 if test -n "$ac_tool_prefix"; then
4208 # Extract the first word of "${ac_tool_prefix}clang", so it can be a program name with args.
4209 set dummy
${ac_tool_prefix}clang
; ac_word
=$2
4210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4211 $as_echo_n "checking for $ac_word... " >&6; }
4212 if ${ac_cv_prog_CC+:} false
; then :
4213 $as_echo_n "(cached) " >&6
4215 if test -n "$CC"; then
4216 ac_cv_prog_CC
="$CC" # Let the user override the test.
4218 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
4222 test -z "$as_dir" && as_dir
=.
4223 for ac_exec_ext
in '' $ac_executable_extensions; do
4224 if as_fn_executable_p
"$as_dir/$ac_word$ac_exec_ext"; then
4225 ac_cv_prog_CC
="${ac_tool_prefix}clang"
4226 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4236 if test -n "$CC"; then
4237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4238 $as_echo "$CC" >&6; }
4240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4241 $as_echo "no" >&6; }
4246 if test -z "$ac_cv_prog_CC"; then
4248 # Extract the first word of "clang", so it can be a program name with args.
4249 set dummy clang
; ac_word
=$2
4250 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4251 $as_echo_n "checking for $ac_word... " >&6; }
4252 if ${ac_cv_prog_ac_ct_CC+:} false
; then :
4253 $as_echo_n "(cached) " >&6
4255 if test -n "$ac_ct_CC"; then
4256 ac_cv_prog_ac_ct_CC
="$ac_ct_CC" # Let the user override the test.
4258 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
4262 test -z "$as_dir" && as_dir
=.
4263 for ac_exec_ext
in '' $ac_executable_extensions; do
4264 if as_fn_executable_p
"$as_dir/$ac_word$ac_exec_ext"; then
4265 ac_cv_prog_ac_ct_CC
="clang"
4266 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4275 ac_ct_CC
=$ac_cv_prog_ac_ct_CC
4276 if test -n "$ac_ct_CC"; then
4277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4278 $as_echo "$ac_ct_CC" >&6; }
4280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4281 $as_echo "no" >&6; }
4284 if test "x$ac_ct_CC" = x
; then
4287 case $cross_compiling:$ac_tool_warned in
4289 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4290 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4291 ac_tool_warned
=yes ;;
4302 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4303 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4304 as_fn_error $?
"no acceptable C compiler found in \$PATH
4305 See \`config.log' for more details" "$LINENO" 5; }
4307 # Provide some information about the compiler.
4308 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4311 for ac_option
in --version -v -V -qversion -version; do
4312 { { ac_try
="$ac_compiler $ac_option >&5"
4314 *\"* |
*\
`* | *\\*) ac_try_echo=\$ac_try;;
4315 *) ac_try_echo=$ac_try;;
4317 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4318 $as_echo "$ac_try_echo"; } >&5
4319 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4321 if test -s conftest.err; then
4323 ... rest of stderr output deleted ...
4324 10q' conftest.err >conftest.er1
4325 cat conftest.er1 >&5
4327 rm -f conftest.er1 conftest.err
4328 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4329 test $ac_status = 0; }
4332 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4333 /* end confdefs.h. */
4343 ac_clean_files_save=$ac_clean_files
4344 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4345 # Try to create an executable without -o first, disregard a.out.
4346 # It will help us diagnose broken compilers, and finding out an intuition
4348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4349 $as_echo_n "checking whether the C compiler works... " >&6; }
4350 ac_link_default=`$as_echo "$ac_link" |
sed 's/ -o *conftest[^ ]*//'`
4352 # The possible output files:
4353 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4356 for ac_file in $ac_files
4359 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4360 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4365 if { { ac_try="$ac_link_default"
4367 *\"* | *\`* |
*\\*) ac_try_echo
=\
$ac_try;;
4368 *) ac_try_echo
=$ac_try;;
4370 eval ac_try_echo
="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4371 $as_echo "$ac_try_echo"; } >&5
4372 (eval "$ac_link_default") 2>&5
4374 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4375 test $ac_status = 0; }; then :
4376 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4377 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4378 # in a Makefile. We should not override ac_cv_exeext if it was cached,
4379 # so that the user can short-circuit this test for compilers unknown to
4381 for ac_file
in $ac_files ''
4383 test -f "$ac_file" ||
continue
4385 *.
$ac_ext |
*.xcoff |
*.tds |
*.d |
*.pdb |
*.xSYM |
*.bb |
*.bbg |
*.map |
*.inf |
*.dSYM |
*.o |
*.obj
)
4388 # We found the default executable, but exeext='' is most
4392 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no
;
4394 ac_cv_exeext
=`expr "$ac_file" : '[^.]*\(\..*\)'`
4396 # We set ac_cv_exeext here because the later test for it is not
4397 # safe: cross compilers may not add the suffix if given an `-o'
4398 # argument, so we may need to know it at that point already.
4399 # Even if this section looks crufty: it has the advantage of
4406 test "$ac_cv_exeext" = no
&& ac_cv_exeext
=
4411 if test -z "$ac_file"; then :
4412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4413 $as_echo "no" >&6; }
4414 $as_echo "$as_me: failed program was:" >&5
4415 sed 's/^/| /' conftest.
$ac_ext >&5
4417 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4418 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4419 as_fn_error
77 "C compiler cannot create executables
4420 See \`config.log' for more details" "$LINENO" 5; }
4422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4423 $as_echo "yes" >&6; }
4425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
4426 $as_echo_n "checking for C compiler default output file name... " >&6; }
4427 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
4428 $as_echo "$ac_file" >&6; }
4429 ac_exeext
=$ac_cv_exeext
4431 rm -f -r a.out a.out.dSYM a.exe conftest
$ac_cv_exeext b.out
4432 ac_clean_files
=$ac_clean_files_save
4433 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
4434 $as_echo_n "checking for suffix of executables... " >&6; }
4435 if { { ac_try
="$ac_link"
4437 *\"* |
*\
`* | *\\*) ac_try_echo=\$ac_try;;
4438 *) ac_try_echo=$ac_try;;
4440 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4441 $as_echo "$ac_try_echo"; } >&5
4442 (eval "$ac_link") 2>&5
4444 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4445 test $ac_status = 0; }; then :
4446 # If both `conftest.exe
' and `conftest' are
`present' (well, observable)
4447 # catch `conftest.exe
'. For instance with Cygwin, `ls conftest' will
4448 # work properly (i.e., refer to `conftest.exe'), while it won't with
4450 for ac_file
in conftest.exe conftest conftest.
*; do
4451 test -f "$ac_file" ||
continue
4453 *.
$ac_ext |
*.xcoff |
*.tds |
*.d |
*.pdb |
*.xSYM |
*.bb |
*.bbg |
*.map |
*.inf |
*.dSYM |
*.o |
*.obj
) ;;
4454 *.
* ) ac_cv_exeext
=`expr "$ac_file" : '[^.]*\(\..*\)'`
4460 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4461 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4462 as_fn_error $?
"cannot compute suffix of executables: cannot compile and link
4463 See \`config.log' for more details" "$LINENO" 5; }
4465 rm -f conftest conftest
$ac_cv_exeext
4466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4467 $as_echo "$ac_cv_exeext" >&6; }
4469 rm -f conftest.
$ac_ext
4470 EXEEXT
=$ac_cv_exeext
4472 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
4473 /* end confdefs.h. */
4478 FILE *f = fopen ("conftest.out", "w");
4479 return ferror (f) || fclose (f) != 0;
4485 ac_clean_files
="$ac_clean_files conftest.out"
4486 # Check that the compiler produces executables we can run. If not, either
4487 # the compiler is broken, or we cross compile.
4488 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4489 $as_echo_n "checking whether we are cross compiling... " >&6; }
4490 if test "$cross_compiling" != yes; then
4491 { { ac_try
="$ac_link"
4493 *\"* |
*\
`* | *\\*) ac_try_echo=\$ac_try;;
4494 *) ac_try_echo=$ac_try;;
4496 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4497 $as_echo "$ac_try_echo"; } >&5
4498 (eval "$ac_link") 2>&5
4500 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4501 test $ac_status = 0; }
4502 if { ac_try='./conftest$ac_cv_exeext'
4503 { { case "(($ac_try" in
4504 *\"* | *\`* |
*\\*) ac_try_echo
=\
$ac_try;;
4505 *) ac_try_echo
=$ac_try;;
4507 eval ac_try_echo
="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4508 $as_echo "$ac_try_echo"; } >&5
4509 (eval "$ac_try") 2>&5
4511 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4512 test $ac_status = 0; }; }; then
4515 if test "$cross_compiling" = maybe
; then
4518 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4519 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4520 as_fn_error $?
"cannot run C compiled programs.
4521 If you meant to cross compile, use \`--host'.
4522 See \`config.log' for more details" "$LINENO" 5; }
4526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4527 $as_echo "$cross_compiling" >&6; }
4529 rm -f conftest.
$ac_ext conftest
$ac_cv_exeext conftest.out
4530 ac_clean_files
=$ac_clean_files_save
4531 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4532 $as_echo_n "checking for suffix of object files... " >&6; }
4533 if ${ac_cv_objext+:} false
; then :
4534 $as_echo_n "(cached) " >&6
4536 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
4537 /* end confdefs.h. */
4547 rm -f conftest.o conftest.obj
4548 if { { ac_try
="$ac_compile"
4550 *\"* |
*\
`* | *\\*) ac_try_echo=\$ac_try;;
4551 *) ac_try_echo=$ac_try;;
4553 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4554 $as_echo "$ac_try_echo"; } >&5
4555 (eval "$ac_compile") 2>&5
4557 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4558 test $ac_status = 0; }; then :
4559 for ac_file in conftest.o conftest.obj conftest.*; do
4560 test -f "$ac_file" || continue;
4562 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
4563 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4568 $as_echo "$as_me: failed program was:" >&5
4569 sed 's/^/| /' conftest.$ac_ext >&5
4571 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4572 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4573 as_fn_error $? "cannot compute suffix of object files
: cannot compile
4574 See \
`config.log' for more details" "$LINENO" 5; }
4576 rm -f conftest.$ac_cv_objext conftest.$ac_ext
4578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4579 $as_echo "$ac_cv_objext" >&6; }
4580 OBJEXT=$ac_cv_objext
4582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4583 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4584 if ${ac_cv_c_compiler_gnu+:} false; then :
4585 $as_echo_n "(cached) " >&6
4587 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4588 /* end confdefs.h. */
4601 if ac_fn_c_try_compile "$LINENO"; then :
4606 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4607 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4611 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
4612 if test $ac_compiler_gnu = yes; then
4617 ac_test_CFLAGS=${CFLAGS+set}
4618 ac_save_CFLAGS=$CFLAGS
4619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4620 $as_echo_n "checking whether $CC accepts -g... " >&6; }
4621 if ${ac_cv_prog_cc_g+:} false; then :
4622 $as_echo_n "(cached) " >&6
4624 ac_save_c_werror_flag=$ac_c_werror_flag
4625 ac_c_werror_flag=yes
4628 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4629 /* end confdefs.h. */
4639 if ac_fn_c_try_compile "$LINENO"; then :
4643 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4644 /* end confdefs.h. */
4654 if ac_fn_c_try_compile "$LINENO"; then :
4657 ac_c_werror_flag=$ac_save_c_werror_flag
4659 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4660 /* end confdefs.h. */
4670 if ac_fn_c_try_compile "$LINENO"; then :
4673 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4675 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4677 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4678 ac_c_werror_flag=$ac_save_c_werror_flag
4680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4681 $as_echo "$ac_cv_prog_cc_g" >&6; }
4682 if test "$ac_test_CFLAGS" = set; then
4683 CFLAGS=$ac_save_CFLAGS
4684 elif test $ac_cv_prog_cc_g = yes; then
4685 if test "$GCC" = yes; then
4691 if test "$GCC" = yes; then
4697 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5
4698 $as_echo_n "checking for $CC option to enable C11 features... " >&6; }
4699 if ${ac_cv_prog_cc_c11+:} false; then :
4700 $as_echo_n "(cached) " >&6
4702 ac_cv_prog_cc_c11=no
4704 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4705 /* end confdefs.h. */
4707 #include <stdbool.h>
4713 // Check varargs macros. These examples are taken from C99 6.10.3.5.
4714 #define debug(...) fprintf (stderr, __VA_ARGS__)
4715 #define showlist(...) puts (#__VA_ARGS__)
4716 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
4718 test_varargs_macros (void)
4723 debug ("X = %d\n", x);
4724 showlist (The first, second, and third items.);
4725 report (x>y, "x is %d but y is %d", x, y);
4728 // Check long long types.
4729 #define BIG64 18446744073709551615ull
4730 #define BIG32 4294967295ul
4731 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
4733 your preprocessor is broken;
4737 your preprocessor is broken;
4739 static long long int bignum = -9223372036854775807LL;
4740 static unsigned long long int ubignum = BIG64;
4742 struct incomplete_array
4750 const wchar_t *name;
4754 typedef const char *ccp;
4757 test_restrict (ccp restrict text)
4759 // See if C++-style comments work.
4760 // Iterate through items via the restricted pointer.
4761 // Also check for declarations in for loops.
4762 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
4767 // Check varargs and va_copy.
4769 test_varargs (const char *format, ...)
4772 va_start (args, format);
4774 va_copy (args_copy, args);
4776 const char *str = "";
4785 str = va_arg (args_copy, const char *);
4788 number = va_arg (args_copy, int);
4791 fnumber = va_arg (args_copy, double);
4800 return *str && number && fnumber;
4803 char _Alignas (double) aligned_as_double;
4804 char _Alignas (0) no_special_alignment;
4805 extern char aligned_as_int;
4806 char _Alignas (0) _Alignas (int) aligned_as_int;
4811 int_alignment = _Alignof (int),
4812 int_array_alignment = _Alignof (int[100]),
4813 char_alignment = _Alignof (char)
4815 _Static_assert (0 < -_Alignof (int), "_Alignof is signed");
4818 int _Noreturn does_not_return (void) { for (;;) continue; }
4820 // Check _Static_assert.
4821 struct test_static_assert
4824 _Static_assert (sizeof (int) <= sizeof (long int),
4825 "_Static_assert does not work in struct");
4829 // Check UTF-8 literals.
4830 #define u8 syntax error!
4831 char const utf8_literal[] = u8"happens to be ASCII" "another string";
4833 // Check duplicate typedefs.
4834 typedef long *long_ptr;
4835 typedef long int *long_ptr;
4836 typedef long_ptr long_ptr;
4838 // Anonymous structures and unions -- taken from C11 6.7.2.1 Example 1.
4842 struct { int i; int j; };
4843 struct { int k; long int l; } w;
4853 _Bool success = false;
4856 if (test_restrict ("String literal") == 0)
4858 char *restrict newvar = "Another string";
4861 success &= test_varargs ("s, d' f .", "string", 65, 34.234);
4862 test_varargs_macros ();
4864 // Check flexible array members.
4865 struct incomplete_array *ia =
4866 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
4868 for (int i = 0; i < ia->datasize; ++i)
4869 ia->data[i] = i * 1.234;
4871 // Check named initializers.
4872 struct named_init ni = {
4874 .name = L"Test wide string",
4875 .average = 543.34343,
4880 int dynamic_array[ni.number];
4881 dynamic_array[ni.number - 1] = 543;
4883 // work around unused variable warnings
4884 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
4885 || dynamic_array[ni.number - 1] != 543);
4889 _Static_assert ((offsetof (struct anonymous, i)
4890 == offsetof (struct anonymous, w.k)),
4891 "Anonymous union alignment botch");
4897 for ac_arg in '' -std=gnu11
4899 CC="$ac_save_CC $ac_arg"
4900 if ac_fn_c_try_compile "$LINENO"; then :
4901 ac_cv_prog_cc_c11=$ac_arg
4903 rm -f core conftest.err conftest.$ac_objext
4904 test "x$ac_cv_prog_cc_c11" != "xno" && break
4906 rm -f conftest.$ac_ext
4911 ac_prog_cc_stdc_options=
4912 case "x$ac_cv_prog_cc_c11" in
4914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4915 $as_echo "none needed" >&6; } ;;
4917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4918 $as_echo "unsupported" >&6; } ;;
4920 ac_prog_cc_stdc_options=" $ac_cv_prog_cc_c11"
4921 CC=$CC$ac_prog_cc_stdc_options
4922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5
4923 $as_echo "$ac_cv_prog_cc_c11" >&6; } ;;
4925 if test "x$ac_cv_prog_cc_c11" != xno; then :
4927 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11
4929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C99 features" >&5
4930 $as_echo_n "checking for $CC option to enable C99 features... " >&6; }
4931 if ${ac_cv_prog_cc_c99+:} false; then :
4932 $as_echo_n "(cached) " >&6
4934 ac_cv_prog_cc_c99=no
4936 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4937 /* end confdefs.h. */
4939 #include <stdbool.h>
4945 // Check varargs macros. These examples are taken from C99 6.10.3.5.
4946 #define debug(...) fprintf (stderr, __VA_ARGS__)
4947 #define showlist(...) puts (#__VA_ARGS__)
4948 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
4950 test_varargs_macros (void)
4955 debug ("X = %d\n", x);
4956 showlist (The first, second, and third items.);
4957 report (x>y, "x is %d but y is %d", x, y);
4960 // Check long long types.
4961 #define BIG64 18446744073709551615ull
4962 #define BIG32 4294967295ul
4963 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
4965 your preprocessor is broken;
4969 your preprocessor is broken;
4971 static long long int bignum = -9223372036854775807LL;
4972 static unsigned long long int ubignum = BIG64;
4974 struct incomplete_array
4982 const wchar_t *name;
4986 typedef const char *ccp;
4989 test_restrict (ccp restrict text)
4991 // See if C++-style comments work.
4992 // Iterate through items via the restricted pointer.
4993 // Also check for declarations in for loops.
4994 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
4999 // Check varargs and va_copy.
5001 test_varargs (const char *format, ...)
5004 va_start (args, format);
5006 va_copy (args_copy, args);
5008 const char *str = "";
5017 str = va_arg (args_copy, const char *);
5020 number = va_arg (args_copy, int);
5023 fnumber = va_arg (args_copy, double);
5032 return *str && number && fnumber;
5039 _Bool success = false;
5042 if (test_restrict ("String literal") == 0)
5044 char *restrict newvar = "Another string";
5047 success &= test_varargs ("s, d' f .", "string", 65, 34.234);
5048 test_varargs_macros ();
5050 // Check flexible array members.
5051 struct incomplete_array *ia =
5052 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
5054 for (int i = 0; i < ia->datasize; ++i)
5055 ia->data[i] = i * 1.234;
5057 // Check named initializers.
5058 struct named_init ni = {
5060 .name = L"Test wide string",
5061 .average = 543.34343,
5066 int dynamic_array[ni.number];
5067 dynamic_array[ni.number - 1] = 543;
5069 // work around unused variable warnings
5070 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
5071 || dynamic_array[ni.number - 1] != 543);
5077 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc1x -qlanglvl=extc99
5079 CC="$ac_save_CC $ac_arg"
5080 if ac_fn_c_try_compile "$LINENO"; then :
5081 ac_cv_prog_cc_c99=$ac_arg
5083 rm -f core conftest.err conftest.$ac_objext
5084 test "x$ac_cv_prog_cc_c99" != "xno" && break
5086 rm -f conftest.$ac_ext
5091 ac_prog_cc_stdc_options=
5092 case "x$ac_cv_prog_cc_c99" in
5094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5095 $as_echo "none needed" >&6; } ;;
5097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5098 $as_echo "unsupported" >&6; } ;;
5100 ac_prog_cc_stdc_options=" $ac_cv_prog_cc_c99"
5101 CC=$CC$ac_prog_cc_stdc_options
5102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
5103 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
5105 if test "x$ac_cv_prog_cc_c99" != xno; then :
5107 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
5109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C89 features" >&5
5110 $as_echo_n "checking for $CC option to enable C89 features... " >&6; }
5111 if ${ac_cv_prog_cc_c89+:} false; then :
5112 $as_echo_n "(cached) " >&6
5114 ac_cv_prog_cc_c89=no
5116 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5117 /* end confdefs.h. */
5121 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5122 struct buf { int x; };
5123 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5124 static char *e (p, i)
5130 static char *f (char * (*g) (char **, int), char **p, ...)
5135 s = g (p, va_arg (v,int));
5140 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5141 function prototypes and stuff, but not '\xHH' hex character constants.
5142 These don't provoke an error unfortunately, instead are silently treated
5143 as 'x'. The following induces an error, until -std is added to get
5144 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5145 array size at least. It's necessary to write '\x00'==0 to get something
5146 that's true only with -std. */
5147 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5149 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5150 inside strings and character constants. */
5152 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5154 int test (int i, double x);
5155 struct s1 {int (*f) (int a);};
5156 struct s2 {int (*f) (double a);};
5157 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5163 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5168 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5169 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5171 CC="$ac_save_CC $ac_arg"
5172 if ac_fn_c_try_compile "$LINENO"; then :
5173 ac_cv_prog_cc_c89=$ac_arg
5175 rm -f core conftest.err conftest.$ac_objext
5176 test "x$ac_cv_prog_cc_c89" != "xno" && break
5178 rm -f conftest.$ac_ext
5183 ac_prog_cc_stdc_options=
5184 case "x$ac_cv_prog_cc_c89" in
5186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5187 $as_echo "none needed" >&6; } ;;
5189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5190 $as_echo "unsupported" >&6; } ;;
5192 ac_prog_cc_stdc_options=" $ac_cv_prog_cc_c89"
5193 CC=$CC$ac_prog_cc_stdc_options
5194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5195 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5197 if test "x$ac_cv_prog_cc_c89" != xno; then :
5199 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
5202 ac_cv_prog_cc_stdc=no
5210 ac_cpp='$CPP $CPPFLAGS'
5211 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5212 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5213 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler is clang" >&5
5217 $as_echo_n "checking whether the compiler is clang... " >&6; }
5218 if ${gl_cv_compiler_clang+:} false; then :
5219 $as_echo_n "(cached) " >&6
5221 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5222 /* end confdefs.h. */
5237 if ac_fn_c_try_compile "$LINENO"; then :
5238 gl_cv_compiler_clang=no
5240 gl_cv_compiler_clang=yes
5242 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_compiler_clang" >&5
5246 $as_echo "$gl_cv_compiler_clang" >&6; }
5249 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler option needed when checking for declarations" >&5
5250 $as_echo_n "checking for compiler option needed when checking for declarations... " >&6; }
5251 if ${gl_cv_compiler_check_decl_option+:} false; then :
5252 $as_echo_n "(cached) " >&6
5254 if test $gl_cv_compiler_clang = yes; then
5255 save_ac_compile="$ac_compile"
5256 ac_compile="$ac_compile -Werror=implicit-function-declaration"
5257 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5258 /* end confdefs.h. */
5268 if ac_fn_c_try_compile "$LINENO"; then :
5269 gl_cv_compiler_check_decl_option='-Werror=implicit-function-declaration'
5271 gl_cv_compiler_check_decl_option=none
5273 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5274 ac_compile="$save_ac_compile"
5276 gl_cv_compiler_check_decl_option=none
5280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_compiler_check_decl_option" >&5
5281 $as_echo "$gl_cv_compiler_check_decl_option" >&6; }
5282 if test "x$gl_cv_compiler_check_decl_option" != xnone; then
5283 ac_compile_for_check_decl="$ac_compile $gl_cv_compiler_check_decl_option"
5285 ac_compile_for_check_decl="$ac_compile"
5292 ac_cpp='$CPP $CPPFLAGS'
5293 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5294 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5295 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5297 $as_echo_n "checking how to run the C preprocessor... " >&6; }
5298 # On Suns, sometimes $CPP names a directory.
5299 if test -n "$CPP" && test -d "$CPP"; then
5302 if test -z "$CPP"; then
5303 if ${ac_cv_prog_CPP+:} false; then :
5304 $as_echo_n "(cached) " >&6
5306 # Double quotes because CPP needs to be expanded
5307 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5310 for ac_c_preproc_warn_flag in '' yes
5312 # Use a header file that comes with gcc, so configuring glibc
5313 # with a fresh cross-compiler works.
5314 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5315 # <limits.h> exists even on freestanding compilers.
5316 # On the NeXT, cc -E runs the code through the compiler's parser,
5317 # not just through cpp. "Syntax error" is here to catch this case.
5318 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5319 /* end confdefs.h. */
5321 # include <limits.h>
5323 # include <assert.h>
5327 if ac_fn_c_try_cpp "$LINENO"; then :
5330 # Broken: fails on valid input.
5333 rm -f conftest.err conftest.i conftest.$ac_ext
5335 # OK, works on sane cases. Now check whether nonexistent headers
5336 # can be detected and how.
5337 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5338 /* end confdefs.h. */
5339 #include <ac_nonexistent.h>
5341 if ac_fn_c_try_cpp "$LINENO"; then :
5342 # Broken: success on invalid input.
5345 # Passes both tests.
5349 rm -f conftest.err conftest.i conftest.$ac_ext
5352 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5353 rm -f conftest.i conftest.err conftest.
$ac_ext
5354 if $ac_preproc_ok; then :
5366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5367 $as_echo "$CPP" >&6; }
5369 for ac_c_preproc_warn_flag
in '' yes
5371 # Use a header file that comes with gcc, so configuring glibc
5372 # with a fresh cross-compiler works.
5373 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5374 # <limits.h> exists even on freestanding compilers.
5375 # On the NeXT, cc -E runs the code through the compiler's parser,
5376 # not just through cpp. "Syntax error" is here to catch this case.
5377 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
5378 /* end confdefs.h. */
5380 # include <limits.h>
5382 # include <assert.h>
5386 if ac_fn_c_try_cpp
"$LINENO"; then :
5389 # Broken: fails on valid input.
5392 rm -f conftest.err conftest.i conftest.
$ac_ext
5394 # OK, works on sane cases. Now check whether nonexistent headers
5395 # can be detected and how.
5396 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
5397 /* end confdefs.h. */
5398 #include <ac_nonexistent.h>
5400 if ac_fn_c_try_cpp
"$LINENO"; then :
5401 # Broken: success on invalid input.
5404 # Passes both tests.
5408 rm -f conftest.err conftest.i conftest.
$ac_ext
5411 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5412 rm -f conftest.i conftest.err conftest.
$ac_ext
5413 if $ac_preproc_ok; then :
5416 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5417 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5418 as_fn_error $?
"C preprocessor \"$CPP\" fails sanity check
5419 See \`config.log' for more details" "$LINENO" 5; }
5423 ac_cpp
='$CPP $CPPFLAGS'
5424 ac_compile
='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5425 ac_link
='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5426 ac_compiler_gnu
=$ac_cv_c_compiler_gnu
5429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
5430 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5431 if ${ac_cv_path_GREP+:} false
; then :
5432 $as_echo_n "(cached) " >&6
5434 if test -z "$GREP"; then
5435 ac_path_GREP_found
=false
5436 # Loop through the user's path and test for each of PROGNAME-LIST
5437 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
5438 for as_dir
in $PATH$PATH_SEPARATOR/usr
/xpg
4/bin
5441 test -z "$as_dir" && as_dir
=.
5442 for ac_prog
in grep ggrep
; do
5443 for ac_exec_ext
in '' $ac_executable_extensions; do
5444 ac_path_GREP
="$as_dir/$ac_prog$ac_exec_ext"
5445 as_fn_executable_p
"$ac_path_GREP" ||
continue
5446 # Check for GNU ac_path_GREP and select it if it is found.
5447 # Check for GNU $ac_path_GREP
5448 case `"$ac_path_GREP" --version 2>&1` in
5450 ac_cv_path_GREP
="$ac_path_GREP" ac_path_GREP_found
=:;;
5453 $as_echo_n 0123456789 >"conftest.in"
5456 cat "conftest.in" "conftest.in" >"conftest.tmp"
5457 mv "conftest.tmp" "conftest.in"
5458 cp "conftest.in" "conftest.nl"
5459 $as_echo 'GREP' >> "conftest.nl"
5460 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev
/null ||
break
5461 diff "conftest.out" "conftest.nl" >/dev
/null
2>&1 ||
break
5462 as_fn_arith
$ac_count + 1 && ac_count
=$as_val
5463 if test $ac_count -gt ${ac_path_GREP_max-0}; then
5464 # Best one so far, save it but keep looking for a better one
5465 ac_cv_path_GREP
="$ac_path_GREP"
5466 ac_path_GREP_max
=$ac_count
5468 # 10*(2^10) chars as input seems more than enough
5469 test $ac_count -gt 10 && break
5471 rm -f conftest.
in conftest.tmp conftest.
nl conftest.out
;;
5474 $ac_path_GREP_found && break 3
5479 if test -z "$ac_cv_path_GREP"; then
5480 as_fn_error $?
"no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5483 ac_cv_path_GREP
=$GREP
5487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
5488 $as_echo "$ac_cv_path_GREP" >&6; }
5489 GREP
="$ac_cv_path_GREP"
5492 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
5493 $as_echo_n "checking for egrep... " >&6; }
5494 if ${ac_cv_path_EGREP+:} false
; then :
5495 $as_echo_n "(cached) " >&6
5497 if echo a |
$GREP -E '(a|b)' >/dev
/null
2>&1
5498 then ac_cv_path_EGREP
="$GREP -E"
5500 if test -z "$EGREP"; then
5501 ac_path_EGREP_found
=false
5502 # Loop through the user's path and test for each of PROGNAME-LIST
5503 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
5504 for as_dir
in $PATH$PATH_SEPARATOR/usr
/xpg
4/bin
5507 test -z "$as_dir" && as_dir
=.
5508 for ac_prog
in egrep; do
5509 for ac_exec_ext
in '' $ac_executable_extensions; do
5510 ac_path_EGREP
="$as_dir/$ac_prog$ac_exec_ext"
5511 as_fn_executable_p
"$ac_path_EGREP" ||
continue
5512 # Check for GNU ac_path_EGREP and select it if it is found.
5513 # Check for GNU $ac_path_EGREP
5514 case `"$ac_path_EGREP" --version 2>&1` in
5516 ac_cv_path_EGREP
="$ac_path_EGREP" ac_path_EGREP_found
=:;;
5519 $as_echo_n 0123456789 >"conftest.in"
5522 cat "conftest.in" "conftest.in" >"conftest.tmp"
5523 mv "conftest.tmp" "conftest.in"
5524 cp "conftest.in" "conftest.nl"
5525 $as_echo 'EGREP' >> "conftest.nl"
5526 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev
/null ||
break
5527 diff "conftest.out" "conftest.nl" >/dev
/null
2>&1 ||
break
5528 as_fn_arith
$ac_count + 1 && ac_count
=$as_val
5529 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5530 # Best one so far, save it but keep looking for a better one
5531 ac_cv_path_EGREP
="$ac_path_EGREP"
5532 ac_path_EGREP_max
=$ac_count
5534 # 10*(2^10) chars as input seems more than enough
5535 test $ac_count -gt 10 && break
5537 rm -f conftest.
in conftest.tmp conftest.
nl conftest.out
;;
5540 $ac_path_EGREP_found && break 3
5545 if test -z "$ac_cv_path_EGREP"; then
5546 as_fn_error $?
"no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5549 ac_cv_path_EGREP
=$EGREP
5554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
5555 $as_echo "$ac_cv_path_EGREP" >&6; }
5556 EGREP
="$ac_cv_path_EGREP"
5559 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
5560 $as_echo_n "checking for ANSI C header files... " >&6; }
5561 if ${ac_cv_header_stdc+:} false
; then :
5562 $as_echo_n "(cached) " >&6
5564 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
5565 /* end confdefs.h. */
5579 if ac_fn_c_try_compile
"$LINENO"; then :
5580 ac_cv_header_stdc
=yes
5582 ac_cv_header_stdc
=no
5584 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
5586 if test $ac_cv_header_stdc = yes; then
5587 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5588 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
5589 /* end confdefs.h. */
5593 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5594 $EGREP "memchr" >/dev
/null
2>&1; then :
5597 ac_cv_header_stdc
=no
5603 if test $ac_cv_header_stdc = yes; then
5604 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5605 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
5606 /* end confdefs.h. */
5610 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5611 $EGREP "free" >/dev
/null
2>&1; then :
5614 ac_cv_header_stdc
=no
5620 if test $ac_cv_header_stdc = yes; then
5621 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5622 if test "$cross_compiling" = yes; then :
5625 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
5626 /* end confdefs.h. */
5629 #if ((' ' & 0x0FF) == 0x020)
5630 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5631 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5633 # define ISLOWER(c) \
5634 (('a' <= (c) && (c) <= 'i') \
5635 || ('j' <= (c) && (c) <= 'r') \
5636 || ('s' <= (c) && (c) <= 'z'))
5637 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5640 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
5645 for (i = 0; i < 256; i++)
5646 if (XOR (islower (i), ISLOWER (i))
5647 || toupper (i) != TOUPPER (i))
5652 if ac_fn_c_try_run
"$LINENO"; then :
5655 ac_cv_header_stdc
=no
5657 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
5658 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
5663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
5664 $as_echo "$ac_cv_header_stdc" >&6; }
5665 if test $ac_cv_header_stdc = yes; then
5667 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
5671 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
5672 for ac_header
in sys
/types.h sys
/stat.h stdlib.h string.h memory.h
strings.h \
5673 inttypes.h stdint.h unistd.h
5675 as_ac_Header
=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
5676 ac_fn_c_check_header_compile
"$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
5678 if eval test \"x\$
"$as_ac_Header"\" = x
"yes"; then :
5679 cat >>confdefs.h
<<_ACEOF
5680 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
5691 for ac_header
in $ac_header_list
5693 as_ac_Header
=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
5694 ac_fn_c_check_header_compile
"$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
5696 if eval test \"x\$
"$as_ac_Header"\" = x
"yes"; then :
5697 cat >>confdefs.h
<<_ACEOF
5698 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
5713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
5714 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
5715 if ${ac_cv_safe_to_define___extensions__+:} false
; then :
5716 $as_echo_n "(cached) " >&6
5718 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
5719 /* end confdefs.h. */
5721 # define __EXTENSIONS__ 1
5722 $ac_includes_default
5731 if ac_fn_c_try_compile
"$LINENO"; then :
5732 ac_cv_safe_to_define___extensions__
=yes
5734 ac_cv_safe_to_define___extensions__
=no
5736 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
5738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
5739 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
5741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5
5742 $as_echo_n "checking whether _XOPEN_SOURCE should be defined... " >&6; }
5743 if ${ac_cv_should_define__xopen_source+:} false
; then :
5744 $as_echo_n "(cached) " >&6
5746 ac_cv_should_define__xopen_source
=no
5747 if test $ac_cv_header_wchar_h = yes; then :
5748 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
5749 /* end confdefs.h. */
5761 if ac_fn_c_try_compile
"$LINENO"; then :
5764 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
5765 /* end confdefs.h. */
5767 #define _XOPEN_SOURCE 500
5778 if ac_fn_c_try_compile
"$LINENO"; then :
5779 ac_cv_should_define__xopen_source
=yes
5781 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
5783 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
5786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5
5787 $as_echo "$ac_cv_should_define__xopen_source" >&6; }
5789 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
5791 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
5793 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
5795 $as_echo "#define _HPUX_ALT_XOPEN_SOCKET_API 1" >>confdefs.h
5797 $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h
5799 $as_echo "#define _OPENBSD_SOURCE 1" >>confdefs.h
5801 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
5803 $as_echo "#define __STDC_WANT_IEC_60559_ATTRIBS_EXT__ 1" >>confdefs.h
5805 $as_echo "#define __STDC_WANT_IEC_60559_BFP_EXT__ 1" >>confdefs.h
5807 $as_echo "#define __STDC_WANT_IEC_60559_DFP_EXT__ 1" >>confdefs.h
5809 $as_echo "#define __STDC_WANT_IEC_60559_FUNCS_EXT__ 1" >>confdefs.h
5811 $as_echo "#define __STDC_WANT_IEC_60559_TYPES_EXT__ 1" >>confdefs.h
5813 $as_echo "#define __STDC_WANT_LIB_EXT2__ 1" >>confdefs.h
5815 $as_echo "#define __STDC_WANT_MATH_SPEC_FUNCS__ 1" >>confdefs.h
5817 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
5819 if test $ac_cv_header_minix_config_h = yes; then :
5821 $as_echo "#define _MINIX 1" >>confdefs.h
5823 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
5825 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
5830 if test $ac_cv_safe_to_define___extensions__ = yes; then :
5831 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
5834 if test $ac_cv_should_define__xopen_source = yes; then :
5835 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
5839 # Needs to run before gl_EARLY so it can override AC_SYS_LARGEFILE included
5842 for ac_dir
in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
5843 if test -f "$ac_dir/install-sh"; then
5845 ac_install_sh
="$ac_aux_dir/install-sh -c"
5847 elif test -f "$ac_dir/install.sh"; then
5849 ac_install_sh
="$ac_aux_dir/install.sh -c"
5851 elif test -f "$ac_dir/shtool"; then
5853 ac_install_sh
="$ac_aux_dir/shtool install -c"
5857 if test -z "$ac_aux_dir"; then
5858 as_fn_error $?
"cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
5861 # These three variables are undocumented and unsupported,
5862 # and are intended to be withdrawn in a future Autoconf release.
5863 # They can cause serious problems if a builder's source tree is in a directory
5864 # whose full name contains unusual characters.
5865 ac_config_guess
="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
5866 ac_config_sub
="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
5867 ac_configure
="$SHELL $ac_aux_dir/configure" # Please don't use this var.
5870 # Make sure we can run config.sub.
5871 $SHELL "$ac_aux_dir/config.sub" sun4
>/dev
/null
2>&1 ||
5872 as_fn_error $?
"cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
5874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
5875 $as_echo_n "checking build system type... " >&6; }
5876 if ${ac_cv_build+:} false
; then :
5877 $as_echo_n "(cached) " >&6
5879 ac_build_alias
=$build_alias
5880 test "x$ac_build_alias" = x
&&
5881 ac_build_alias
=`$SHELL "$ac_aux_dir/config.guess"`
5882 test "x$ac_build_alias" = x
&&
5883 as_fn_error $?
"cannot guess build type; you must specify one" "$LINENO" 5
5884 ac_cv_build
=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
5885 as_fn_error $?
"$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
5888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
5889 $as_echo "$ac_cv_build" >&6; }
5890 case $ac_cv_build in
5892 *) as_fn_error $?
"invalid value of canonical build" "$LINENO" 5;;
5895 ac_save_IFS
=$IFS; IFS
='-'
5901 # Remember, the first character of IFS is used to create $*,
5902 # except with old shells:
5905 case $build_os in *\
*) build_os
=`echo "$build_os" | sed 's/ /-/g'`;; esac
5908 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
5909 $as_echo_n "checking host system type... " >&6; }
5910 if ${ac_cv_host+:} false
; then :
5911 $as_echo_n "(cached) " >&6
5913 if test "x$host_alias" = x
; then
5914 ac_cv_host
=$ac_cv_build
5916 ac_cv_host
=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
5917 as_fn_error $?
"$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
5921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
5922 $as_echo "$ac_cv_host" >&6; }
5925 *) as_fn_error $?
"invalid value of canonical host" "$LINENO" 5;;
5928 ac_save_IFS
=$IFS; IFS
='-'
5934 # Remember, the first character of IFS is used to create $*,
5935 # except with old shells:
5938 case $host_os in *\
*) host_os
=`echo "$host_os" | sed 's/ /-/g'`;; esac
5941 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
5942 $as_echo_n "checking target system type... " >&6; }
5943 if ${ac_cv_target+:} false
; then :
5944 $as_echo_n "(cached) " >&6
5946 if test "x$target_alias" = x
; then
5947 ac_cv_target
=$ac_cv_host
5949 ac_cv_target
=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
5950 as_fn_error $?
"$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
5954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
5955 $as_echo "$ac_cv_target" >&6; }
5956 case $ac_cv_target in
5958 *) as_fn_error $?
"invalid value of canonical target" "$LINENO" 5;;
5960 target
=$ac_cv_target
5961 ac_save_IFS
=$IFS; IFS
='-'
5967 # Remember, the first character of IFS is used to create $*,
5968 # except with old shells:
5971 case $target_os in *\
*) target_os
=`echo "$target_os" | sed 's/ /-/g'`;; esac
5974 # The aliases save the names the user supplied, while $host etc.
5975 # will get canonicalized.
5976 test -n "$target_alias" &&
5977 test "$program_prefix$program_suffix$program_transform_name" = \
5979 program_prefix
=${target_alias}-
5981 # The tests for host and target for $enable_largefile require
5986 # As the $enable_largefile decision depends on --enable-plugins we must set it
5987 # even in directories otherwise not depending on the $plugins option.
5991 for ac_header
in dlfcn.h
5993 ac_fn_c_check_header_compile
"$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
5995 if test "x$ac_cv_header_dlfcn_h" = xyes
; then :
5996 cat >>confdefs.h
<<_ACEOF
5997 #define HAVE_DLFCN_H 1
6004 for ac_header
in windows.h
6006 ac_fn_c_check_header_compile
"$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default
6008 if test "x$ac_cv_header_windows_h" = xyes
; then :
6009 cat >>confdefs.h
<<_ACEOF
6010 #define HAVE_WINDOWS_H 1
6018 # Check whether --enable-plugins was given.
6019 if test "${enable_plugins+set}" = set; then :
6020 enableval
=$enable_plugins; case "${enableval}" in
6023 if test "$maybe_plugins" != "yes" ; then
6024 as_fn_error $?
"Building with plugin support requires a host that supports dlopen." "$LINENO" 5
6028 plugins
=$maybe_plugins
6032 if test "$plugins" = "yes"; then
6033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlsym" >&5
6034 $as_echo_n "checking for library containing dlsym... " >&6; }
6035 if ${ac_cv_search_dlsym+:} false
; then :
6036 $as_echo_n "(cached) " >&6
6038 ac_func_search_save_LIBS
=$LIBS
6039 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
6040 /* end confdefs.h. */
6042 /* Override any GCC internal prototype to avoid an error.
6043 Use char because int might match the return type of a GCC
6044 builtin and then its argument prototype would still apply. */
6057 for ac_lib
in '' dl
; do
6058 if test -z "$ac_lib"; then
6059 ac_res
="none required"
6062 LIBS
="-l$ac_lib $ac_func_search_save_LIBS"
6064 if ac_fn_c_try_link
"$LINENO"; then :
6065 ac_cv_search_dlsym
=$ac_res
6067 rm -f core conftest.err conftest.
$ac_objext \
6069 if ${ac_cv_search_dlsym+:} false
; then :
6073 if ${ac_cv_search_dlsym+:} false
; then :
6076 ac_cv_search_dlsym
=no
6079 LIBS
=$ac_func_search_save_LIBS
6081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlsym" >&5
6082 $as_echo "$ac_cv_search_dlsym" >&6; }
6083 ac_res
=$ac_cv_search_dlsym
6084 if test "$ac_res" != no
; then :
6085 test "$ac_res" = "none required" || LIBS
="$ac_res $LIBS"
6093 sparc-
*-solaris*|i?
86-*-solaris*)
6094 # On native 32-bit Solaris/SPARC and x86, large-file and procfs support
6095 # were mutually exclusive until Solaris 11.3. Without procfs support,
6096 # the bfd/ elf module cannot provide certain routines such as
6097 # elfcore_write_prpsinfo or elfcore_write_prstatus. So unless the user
6098 # explicitly requested large-file support through the
6099 # --enable-largefile switch, disable large-file support in favor of
6102 # Check if <sys/procfs.h> is incompatible with large-file support.
6103 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
6104 /* end confdefs.h. */
6105 #define _FILE_OFFSET_BITS 64
6106 #define _STRUCTURED_PROC 1
6107 #include <sys/procfs.h>
6116 if ac_fn_c_try_compile
"$LINENO"; then :
6117 acx_cv_procfs_lfs
=yes
6119 acx_cv_procfs_lfs
=no
6121 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
6123 # Forcefully disable large-file support only if necessary, gdb is in
6125 if test "${target}" = "${host}" -a "$acx_cv_procfs_lfs" = no \
6126 -a -d $srcdir/..
/gdb
-a "$enable_gdb" != no
; then
6127 : ${enable_largefile="no"}
6128 if test "$plugins" = yes; then
6129 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
6130 plugin support disabled; require large-file support which is incompatible with GDB." >&5
6131 $as_echo "$as_me: WARNING:
6132 plugin support disabled; require large-file support which is incompatible with GDB." >&2;}
6137 # Explicitly undef _FILE_OFFSET_BITS if enable_largefile=no for the
6138 # benefit of g++ 9+ which predefines it on Solaris.
6139 if test "$enable_largefile" = no
; then
6140 LARGEFILE_CPPFLAGS
="-U_FILE_OFFSET_BITS"
6146 # Check whether --enable-largefile was given.
6147 if test "${enable_largefile+set}" = set; then :
6148 enableval
=$enable_largefile;
6151 if test "$enable_largefile" != no
; then
6153 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
6154 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
6155 if ${ac_cv_sys_largefile_CC+:} false
; then :
6156 $as_echo_n "(cached) " >&6
6158 ac_cv_sys_largefile_CC
=no
6159 if test "$GCC" != yes; then
6162 # IRIX 6.2 and later do not support large files by default,
6163 # so use the C compiler's -n32 option if that helps.
6164 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
6165 /* end confdefs.h. */
6166 #include <sys/types.h>
6167 /* Check that off_t can represent 2**63 - 1 correctly.
6168 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6169 since some C++ compilers masquerading as C compilers
6170 incorrectly reject 9223372036854775807. */
6171 #define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31))
6172 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6173 && LARGE_OFF_T % 2147483647 == 1)
6183 if ac_fn_c_try_compile
"$LINENO"; then :
6186 rm -f core conftest.err conftest.
$ac_objext
6188 if ac_fn_c_try_compile
"$LINENO"; then :
6189 ac_cv_sys_largefile_CC
=' -n32'; break
6191 rm -f core conftest.err conftest.
$ac_objext
6195 rm -f conftest.
$ac_ext
6198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
6199 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
6200 if test "$ac_cv_sys_largefile_CC" != no
; then
6201 CC
=$CC$ac_cv_sys_largefile_CC
6204 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
6205 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
6206 if ${ac_cv_sys_file_offset_bits+:} false
; then :
6207 $as_echo_n "(cached) " >&6
6210 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
6211 /* end confdefs.h. */
6212 #include <sys/types.h>
6213 /* Check that off_t can represent 2**63 - 1 correctly.
6214 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6215 since some C++ compilers masquerading as C compilers
6216 incorrectly reject 9223372036854775807. */
6217 #define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31))
6218 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6219 && LARGE_OFF_T % 2147483647 == 1)
6229 if ac_fn_c_try_compile
"$LINENO"; then :
6230 ac_cv_sys_file_offset_bits
=no
; break
6232 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
6233 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
6234 /* end confdefs.h. */
6235 #define _FILE_OFFSET_BITS 64
6236 #include <sys/types.h>
6237 /* Check that off_t can represent 2**63 - 1 correctly.
6238 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6239 since some C++ compilers masquerading as C compilers
6240 incorrectly reject 9223372036854775807. */
6241 #define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31))
6242 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6243 && LARGE_OFF_T % 2147483647 == 1)
6253 if ac_fn_c_try_compile
"$LINENO"; then :
6254 ac_cv_sys_file_offset_bits
=64; break
6256 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
6257 ac_cv_sys_file_offset_bits
=unknown
6261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6262 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
6263 case $ac_cv_sys_file_offset_bits in #(
6266 cat >>confdefs.h
<<_ACEOF
6267 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6272 if test $ac_cv_sys_file_offset_bits = unknown
; then
6273 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6274 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
6275 if ${ac_cv_sys_large_files+:} false
; then :
6276 $as_echo_n "(cached) " >&6
6279 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
6280 /* end confdefs.h. */
6281 #include <sys/types.h>
6282 /* Check that off_t can represent 2**63 - 1 correctly.
6283 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6284 since some C++ compilers masquerading as C compilers
6285 incorrectly reject 9223372036854775807. */
6286 #define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31))
6287 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6288 && LARGE_OFF_T % 2147483647 == 1)
6298 if ac_fn_c_try_compile
"$LINENO"; then :
6299 ac_cv_sys_large_files
=no
; break
6301 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
6302 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
6303 /* end confdefs.h. */
6304 #define _LARGE_FILES 1
6305 #include <sys/types.h>
6306 /* Check that off_t can represent 2**63 - 1 correctly.
6307 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6308 since some C++ compilers masquerading as C compilers
6309 incorrectly reject 9223372036854775807. */
6310 #define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31))
6311 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6312 && LARGE_OFF_T % 2147483647 == 1)
6322 if ac_fn_c_try_compile
"$LINENO"; then :
6323 ac_cv_sys_large_files
=1; break
6325 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
6326 ac_cv_sys_large_files
=unknown
6330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6331 $as_echo "$ac_cv_sys_large_files" >&6; }
6332 case $ac_cv_sys_large_files in #(
6335 cat >>confdefs.h
<<_ACEOF
6336 #define _LARGE_FILES $ac_cv_sys_large_files
6352 $as_echo "#define _ISOC11_SOURCE 1" >>confdefs.h
6360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
6361 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
6362 if ${gl_cv_c_amsterdam_compiler+:} false
; then :
6363 $as_echo_n "(cached) " >&6
6366 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
6367 /* end confdefs.h. */
6374 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6375 $EGREP "Amsterdam" >/dev
/null
2>&1; then :
6376 gl_cv_c_amsterdam_compiler
=yes
6378 gl_cv_c_amsterdam_compiler
=no
6384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
6385 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
6387 if test $gl_cv_c_amsterdam_compiler = yes; then
6388 if test -z "$AR"; then
6391 if test -z "$ARFLAGS"; then
6398 if test -n "$ac_tool_prefix"; then
6399 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6400 set dummy
${ac_tool_prefix}ar; ac_word
=$2
6401 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6402 $as_echo_n "checking for $ac_word... " >&6; }
6403 if ${ac_cv_prog_AR+:} false
; then :
6404 $as_echo_n "(cached) " >&6
6406 if test -n "$AR"; then
6407 ac_cv_prog_AR
="$AR" # Let the user override the test.
6409 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
6413 test -z "$as_dir" && as_dir
=.
6414 for ac_exec_ext
in '' $ac_executable_extensions; do
6415 if as_fn_executable_p
"$as_dir/$ac_word$ac_exec_ext"; then
6416 ac_cv_prog_AR
="${ac_tool_prefix}ar"
6417 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6427 if test -n "$AR"; then
6428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6429 $as_echo "$AR" >&6; }
6431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6432 $as_echo "no" >&6; }
6437 if test -z "$ac_cv_prog_AR"; then
6439 # Extract the first word of "ar", so it can be a program name with args.
6440 set dummy
ar; ac_word
=$2
6441 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6442 $as_echo_n "checking for $ac_word... " >&6; }
6443 if ${ac_cv_prog_ac_ct_AR+:} false
; then :
6444 $as_echo_n "(cached) " >&6
6446 if test -n "$ac_ct_AR"; then
6447 ac_cv_prog_ac_ct_AR
="$ac_ct_AR" # Let the user override the test.
6449 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
6453 test -z "$as_dir" && as_dir
=.
6454 for ac_exec_ext
in '' $ac_executable_extensions; do
6455 if as_fn_executable_p
"$as_dir/$ac_word$ac_exec_ext"; then
6456 ac_cv_prog_ac_ct_AR
="ar"
6457 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6466 ac_ct_AR
=$ac_cv_prog_ac_ct_AR
6467 if test -n "$ac_ct_AR"; then
6468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6469 $as_echo "$ac_ct_AR" >&6; }
6471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6472 $as_echo "no" >&6; }
6475 if test "x$ac_ct_AR" = x
; then
6478 case $cross_compiling:$ac_tool_warned in
6480 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6481 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6482 ac_tool_warned
=yes ;;
6490 if test -z "$ARFLAGS"; then
6496 if test -z "$RANLIB"; then
6497 if test $gl_cv_c_amsterdam_compiler = yes; then
6500 if test -n "$ac_tool_prefix"; then
6501 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6502 set dummy
${ac_tool_prefix}ranlib
; ac_word
=$2
6503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6504 $as_echo_n "checking for $ac_word... " >&6; }
6505 if ${ac_cv_prog_RANLIB+:} false
; then :
6506 $as_echo_n "(cached) " >&6
6508 if test -n "$RANLIB"; then
6509 ac_cv_prog_RANLIB
="$RANLIB" # Let the user override the test.
6511 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
6515 test -z "$as_dir" && as_dir
=.
6516 for ac_exec_ext
in '' $ac_executable_extensions; do
6517 if as_fn_executable_p
"$as_dir/$ac_word$ac_exec_ext"; then
6518 ac_cv_prog_RANLIB
="${ac_tool_prefix}ranlib"
6519 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6528 RANLIB
=$ac_cv_prog_RANLIB
6529 if test -n "$RANLIB"; then
6530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6531 $as_echo "$RANLIB" >&6; }
6533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6534 $as_echo "no" >&6; }
6539 if test -z "$ac_cv_prog_RANLIB"; then
6540 ac_ct_RANLIB
=$RANLIB
6541 # Extract the first word of "ranlib", so it can be a program name with args.
6542 set dummy ranlib
; ac_word
=$2
6543 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6544 $as_echo_n "checking for $ac_word... " >&6; }
6545 if ${ac_cv_prog_ac_ct_RANLIB+:} false
; then :
6546 $as_echo_n "(cached) " >&6
6548 if test -n "$ac_ct_RANLIB"; then
6549 ac_cv_prog_ac_ct_RANLIB
="$ac_ct_RANLIB" # Let the user override the test.
6551 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
6555 test -z "$as_dir" && as_dir
=.
6556 for ac_exec_ext
in '' $ac_executable_extensions; do
6557 if as_fn_executable_p
"$as_dir/$ac_word$ac_exec_ext"; then
6558 ac_cv_prog_ac_ct_RANLIB
="ranlib"
6559 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6568 ac_ct_RANLIB
=$ac_cv_prog_ac_ct_RANLIB
6569 if test -n "$ac_ct_RANLIB"; then
6570 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6571 $as_echo "$ac_ct_RANLIB" >&6; }
6573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6574 $as_echo "no" >&6; }
6577 if test "x$ac_ct_RANLIB" = x
; then
6580 case $cross_compiling:$ac_tool_warned in
6582 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6583 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6584 ac_tool_warned
=yes ;;
6586 RANLIB
=$ac_ct_RANLIB
6589 RANLIB
="$ac_cv_prog_RANLIB"
6600 # IEEE behaviour is the default on all CPUs except Alpha and SH
6601 # (according to the test results of Bruno Haible's ieeefp/fenv_default.m4
6602 # and the GCC 4.1.2 manual).
6605 # On Alpha systems, a compiler option provides the behaviour.
6606 # See the ieee(3) manual page, also available at
6607 # <https://backdrift.org/man/tru64/man3/ieee.3.html>
6608 if test -n "$GCC"; then
6609 # GCC has the option -mieee.
6610 # For full IEEE compliance (rarely needed), use option -mieee-with-inexact.
6611 CPPFLAGS
="$CPPFLAGS -mieee"
6613 # Compaq (ex-DEC) C has the option -ieee, equivalent to -ieee_with_no_inexact.
6614 # For full IEEE compliance (rarely needed), use option -ieee_with_inexact.
6615 CPPFLAGS
="$CPPFLAGS -ieee"
6619 if test -n "$GCC"; then
6620 # GCC has the option -mieee.
6621 CPPFLAGS
="$CPPFLAGS -mieee"
6632 # Check whether --enable-threads was given.
6633 if test "${enable_threads+set}" = set; then :
6634 enableval
=$enable_threads; gl_use_threads
=$enableval
6636 if test -n "$gl_use_threads_default"; then
6637 gl_use_threads
="$gl_use_threads_default"
6640 osf
*) gl_use_threads
=no
;;
6643 1.
[0-5].
*) gl_use_threads
=no
;;
6644 *) gl_use_threads
=yes ;;
6648 case "$gl_use_winpthreads_default" in
6649 yes) gl_use_threads
=posix
;;
6650 no
) gl_use_threads
=windows
;;
6651 *) gl_use_threads
=yes ;;
6654 *) gl_use_threads
=yes ;;
6660 if test "$gl_use_threads" = yes \
6661 ||
test "$gl_use_threads" = isoc \
6662 ||
test "$gl_use_threads" = posix \
6663 ||
test "$gl_use_threads" = isoc
+posix
; then
6664 # For using <threads.h> or <pthread.h>:
6667 if test -z "$gl_anythreadlib_early_done"; then
6670 # On OSF/1, the compiler needs the flag -D_REENTRANT so that it
6671 # groks <pthread.h>. cc also understands the flag -pthread, but
6672 # we don't use it because 1. gcc-2.95 doesn't understand -pthread,
6673 # 2. putting a flag into CPPFLAGS that has an effect on the linker
6674 # causes the AC_LINK_IFELSE test below to succeed unexpectedly,
6675 # leading to wrong values of LIBTHREAD and LTLIBTHREAD.
6676 CPPFLAGS
="$CPPFLAGS -D_REENTRANT"
6679 # Some systems optimize for single-threaded programs by default, and
6680 # need special flags to disable these optimizations. For example, the
6681 # definition of 'errno' in <errno.h>.
6683 aix
* | freebsd
*) CPPFLAGS
="$CPPFLAGS -D_THREAD_SAFE" ;;
6684 solaris
*) CPPFLAGS
="$CPPFLAGS -D_REENTRANT" ;;
6686 gl_anythreadlib_early_done
=done
6693 # Pre-early section.
6698 # Code from module absolute-header:
6699 # Code from module alloca:
6700 # Code from module alloca-opt:
6701 # Code from module arpa_inet:
6702 # Code from module assure:
6703 # Code from module at-internal:
6704 # Code from module attribute:
6705 # Code from module basename-lgpl:
6706 # Code from module btowc:
6707 # Code from module builtin-expect:
6708 # Code from module c99:
6709 # Code from module canonicalize-lgpl:
6710 # Code from module chdir:
6711 # Code from module chdir-long:
6712 # Code from module chown:
6713 # Code from module clock-time:
6714 # Code from module cloexec:
6715 # Code from module close:
6716 # Code from module closedir:
6717 # Code from module count-one-bits:
6718 # Code from module ctype:
6719 # Code from module d-ino:
6720 # Code from module d-type:
6721 # Code from module dirent:
6722 # Code from module dirfd:
6723 # Code from module dirname-lgpl:
6724 # Code from module double-slash-root:
6725 # Code from module dup:
6726 # Code from module dup2:
6727 # Code from module eloop-threshold:
6728 # Code from module environ:
6729 # Code from module errno:
6730 # Code from module error:
6731 # Code from module exitfail:
6732 # Code from module extensions:
6733 # Code from module extern-inline:
6734 # Code from module fchdir:
6735 # Code from module fcntl:
6736 # Code from module fcntl-h:
6737 # Code from module fd-hook:
6738 # Code from module fd-safer-flag:
6739 # Code from module fdopendir:
6740 # Code from module ffs:
6741 # Code from module filename:
6742 # Code from module filenamecat-lgpl:
6743 # Code from module flexmember:
6744 # Code from module float:
6745 # Code from module fnmatch:
6746 # Code from module fnmatch-gnu:
6747 # Code from module fnmatch-h:
6748 # Code from module fpieee:
6750 # Code from module fpucw:
6751 # Code from module free-posix:
6752 # Code from module frexp:
6753 # Code from module frexpl:
6754 # Code from module fstat:
6755 # Code from module fstatat:
6756 # Code from module gendocs:
6757 # Code from module getcwd:
6758 # Code from module getcwd-lgpl:
6759 # Code from module getdelim:
6760 # Code from module getdtablesize:
6761 # Code from module getline:
6762 # Code from module getlogin_r:
6763 # Code from module getprogname:
6764 # Code from module getrandom:
6765 # Code from module gettext-h:
6766 # Code from module gettimeofday:
6767 # Code from module gitlog-to-changelog:
6768 # Code from module glob:
6769 # Code from module glob-h:
6770 # Code from module hard-locale:
6771 # Code from module idx:
6772 # Code from module include_next:
6773 # Code from module inet_ntop:
6774 # Code from module intprops:
6775 # Code from module inttypes:
6776 # Code from module inttypes-incomplete:
6777 # Code from module isblank:
6778 # Code from module isnand-nolibm:
6779 # Code from module isnanl-nolibm:
6780 # Code from module largefile:
6782 # Code from module libc-config:
6783 # Code from module limits-h:
6784 # Code from module localcharset:
6785 # Code from module locale:
6786 # Code from module lock:
6787 # Code from module lstat:
6788 # Code from module malloc-posix:
6789 # Code from module malloca:
6790 # Code from module math:
6791 # Code from module mbrtowc:
6792 # Code from module mbsinit:
6793 # Code from module mbsrtowcs:
6794 # Code from module mbtowc:
6795 # Code from module memchr:
6796 # Code from module memmem:
6797 # Code from module memmem-simple:
6798 # Code from module mempcpy:
6799 # Code from module memrchr:
6800 # Code from module minmax:
6801 # Code from module mkdir:
6802 # Code from module mkdtemp:
6803 # Code from module mkostemp:
6804 # Code from module msvc-inval:
6805 # Code from module msvc-nothrow:
6806 # Code from module multiarch:
6807 # Code from module netdb:
6808 # Code from module netinet_in:
6809 # Code from module nocrash:
6810 # Code from module open:
6811 # Code from module openat:
6812 # Code from module openat-die:
6813 # Code from module openat-h:
6814 # Code from module opendir:
6815 # Code from module pathmax:
6816 # Code from module pipe-posix:
6817 # Code from module rawmemchr:
6818 # Code from module readdir:
6819 # Code from module readlink:
6820 # Code from module realloc-posix:
6821 # Code from module rename:
6822 # Code from module rewinddir:
6823 # Code from module rmdir:
6824 # Code from module same-inode:
6825 # Code from module save-cwd:
6826 # Code from module scratch_buffer:
6827 # Code from module select:
6828 # Code from module setenv:
6829 # Code from module setlocale-null:
6830 # Code from module signal-h:
6831 # Code from module snippet/_Noreturn:
6832 # Code from module snippet/arg-nonnull:
6833 # Code from module snippet/c++defs:
6834 # Code from module snippet/warn-on-use:
6835 # Code from module socketlib:
6836 # Code from module sockets:
6837 # Code from module socklen:
6838 # Code from module ssize_t:
6839 # Code from module stat:
6840 # Code from module stat-time:
6841 # Code from module std-gnu11:
6842 # Code from module stdalign:
6843 # Code from module stdbool:
6844 # Code from module stddef:
6845 # Code from module stdint:
6846 # Code from module stdio:
6847 # Code from module stdlib:
6848 # Code from module strchrnul:
6849 # Code from module strdup-posix:
6850 # Code from module streq:
6851 # Code from module strerror:
6852 # Code from module strerror-override:
6853 # Code from module strerror_r-posix:
6854 # Code from module string:
6855 # Code from module strings:
6856 # Code from module strnlen:
6857 # Code from module strnlen1:
6858 # Code from module strstr:
6859 # Code from module strstr-simple:
6860 # Code from module strtok_r:
6861 # Code from module sys_random:
6862 # Code from module sys_select:
6863 # Code from module sys_socket:
6864 # Code from module sys_stat:
6865 # Code from module sys_time:
6866 # Code from module sys_types:
6867 # Code from module sys_uio:
6868 # Code from module tempname:
6869 # Code from module threadlib:
6873 # Code from module time:
6874 # Code from module time_r:
6875 # Code from module unistd:
6876 # Code from module unistd-safer:
6877 # Code from module unsetenv:
6878 # Code from module update-copyright:
6879 # Code from module verify:
6880 # Code from module wchar:
6881 # Code from module wctype-h:
6882 # Code from module windows-mutex:
6883 # Code from module windows-once:
6884 # Code from module windows-recmutex:
6885 # Code from module windows-rwlock:
6886 # Code from module wmemchr:
6887 # Code from module wmempcpy:
6888 # Code from module xalloc-oversized:
6891 am_cv_prog_cc_stdc
=$ac_cv_prog_cc_stdc
6895 for ac_dir
in ..
"$srcdir"/..
; do
6896 if test -f "$ac_dir/install-sh"; then
6898 ac_install_sh
="$ac_aux_dir/install-sh -c"
6900 elif test -f "$ac_dir/install.sh"; then
6902 ac_install_sh
="$ac_aux_dir/install.sh -c"
6904 elif test -f "$ac_dir/shtool"; then
6906 ac_install_sh
="$ac_aux_dir/shtool install -c"
6910 if test -z "$ac_aux_dir"; then
6911 as_fn_error $?
"cannot find install-sh, install.sh, or shtool in .. \"$srcdir\"/.." "$LINENO" 5
6914 # These three variables are undocumented and unsupported,
6915 # and are intended to be withdrawn in a future Autoconf release.
6916 # They can cause serious problems if a builder's source tree is in a directory
6917 # whose full name contains unusual characters.
6918 ac_config_guess
="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
6919 ac_config_sub
="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
6920 ac_configure
="$SHELL $ac_aux_dir/configure" # Please don't use this var.
6933 # Check whether --enable-cross-guesses was given.
6934 if test "${enable_cross_guesses+set}" = set; then :
6935 enableval
=$enable_cross_guesses; if test "x$enableval" != xconservative
&& test "x$enableval" != xrisky
; then
6936 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: invalid argument supplied to --enable-cross-guesses" >&5
6937 $as_echo "$as_me: WARNING: invalid argument supplied to --enable-cross-guesses" >&2;}
6938 enableval
=conservative
6940 gl_cross_guesses
="$enableval"
6942 gl_cross_guesses
=conservative
6945 if test $gl_cross_guesses = risky
; then
6946 gl_cross_guess_normal
="guessing yes"
6947 gl_cross_guess_inverted
="guessing no"
6949 gl_cross_guess_normal
="guessing no"
6950 gl_cross_guess_inverted
="guessing yes"
6952 LIBC_FATAL_STDERR_
=1
6953 export LIBC_FATAL_STDERR_
6956 ac_fn_c_check_type
"$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
6957 if test "x$ac_cv_type_size_t" = xyes
; then :
6961 cat >>confdefs.h
<<_ACEOF
6962 #define size_t unsigned int
6967 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
6968 # for constant arguments. Useless!
6969 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
6970 $as_echo_n "checking for working alloca.h... " >&6; }
6971 if ${ac_cv_working_alloca_h+:} false
; then :
6972 $as_echo_n "(cached) " >&6
6974 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
6975 /* end confdefs.h. */
6980 char *p = (char *) alloca (2 * sizeof (int));
6986 if ac_fn_c_try_link
"$LINENO"; then :
6987 ac_cv_working_alloca_h
=yes
6989 ac_cv_working_alloca_h
=no
6991 rm -f core conftest.err conftest.
$ac_objext \
6992 conftest
$ac_exeext conftest.
$ac_ext
6994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
6995 $as_echo "$ac_cv_working_alloca_h" >&6; }
6996 if test $ac_cv_working_alloca_h = yes; then
6998 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
7002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
7003 $as_echo_n "checking for alloca... " >&6; }
7004 if ${ac_cv_func_alloca_works+:} false
; then :
7005 $as_echo_n "(cached) " >&6
7007 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
7008 /* end confdefs.h. */
7010 # define alloca __builtin_alloca
7013 # include <malloc.h>
7014 # define alloca _alloca
7016 # ifdef HAVE_ALLOCA_H
7017 # include <alloca.h>
7022 # ifndef alloca /* predefined by HP cc +Olibcalls */
7023 void *alloca (size_t);
7033 char *p = (char *) alloca (1);
7039 if ac_fn_c_try_link
"$LINENO"; then :
7040 ac_cv_func_alloca_works
=yes
7042 ac_cv_func_alloca_works
=no
7044 rm -f core conftest.err conftest.
$ac_objext \
7045 conftest
$ac_exeext conftest.
$ac_ext
7047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
7048 $as_echo "$ac_cv_func_alloca_works" >&6; }
7050 if test $ac_cv_func_alloca_works = yes; then
7052 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
7055 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
7056 # that cause trouble. Some versions do not even contain alloca or
7057 # contain a buggy version. If you still want to use their alloca,
7058 # use ar to extract alloca.o from them instead of compiling alloca.c.
7064 ALLOCA
=\
${LIBOBJDIR}alloca.
$ac_objext
7066 $as_echo "#define C_ALLOCA 1" >>confdefs.h
7069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
7070 $as_echo_n "checking stack direction for C alloca... " >&6; }
7071 if ${ac_cv_c_stack_direction+:} false
; then :
7072 $as_echo_n "(cached) " >&6
7074 if test "$cross_compiling" = yes; then :
7075 ac_cv_c_stack_direction
=0
7077 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
7078 /* end confdefs.h. */
7079 $ac_includes_default
7081 find_stack_direction (int *addr, int depth)
7086 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
7087 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
7092 main (int argc, char **argv)
7094 return find_stack_direction (0, argc + !argv + 20) < 0;
7097 if ac_fn_c_try_run
"$LINENO"; then :
7098 ac_cv_c_stack_direction
=1
7100 ac_cv_c_stack_direction
=-1
7102 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
7103 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
7107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
7108 $as_echo "$ac_cv_c_stack_direction" >&6; }
7109 cat >>confdefs.h
<<_ACEOF
7110 #define STACK_DIRECTION $ac_cv_c_stack_direction
7119 HAVE_DECL_INET_NTOP
=1;
7120 HAVE_DECL_INET_PTON
=1;
7121 REPLACE_INET_NTOP
=0;
7122 REPLACE_INET_PTON
=0;
7128 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
7129 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
7130 if ${gl_cv_have_include_next+:} false
; then :
7131 $as_echo_n "(cached) " >&6
7133 rm -rf conftestd1a conftestd1b conftestd2
7134 mkdir conftestd1a conftestd1b conftestd2
7135 cat <<EOF > conftestd1a/conftest.h
7136 #define DEFINED_IN_CONFTESTD1
7137 #include_next <conftest.h>
7138 #ifdef DEFINED_IN_CONFTESTD2
7141 #error "include_next doesn't work"
7144 cat <<EOF > conftestd1b/conftest.h
7145 #define DEFINED_IN_CONFTESTD1
7147 #include_next <conftest.h>
7148 #ifdef DEFINED_IN_CONFTESTD2
7151 #error "include_next doesn't work"
7154 cat <<EOF > conftestd2/conftest.h
7155 #ifndef DEFINED_IN_CONFTESTD1
7156 #error "include_next test doesn't work"
7158 #define DEFINED_IN_CONFTESTD2
7160 gl_save_CPPFLAGS
="$CPPFLAGS"
7161 CPPFLAGS
="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
7162 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
7163 /* end confdefs.h. */
7164 #include <conftest.h>
7166 if ac_fn_c_try_compile
"$LINENO"; then :
7167 gl_cv_have_include_next
=yes
7169 CPPFLAGS
="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
7170 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
7171 /* end confdefs.h. */
7172 #include <conftest.h>
7174 if ac_fn_c_try_compile
"$LINENO"; then :
7175 gl_cv_have_include_next
=buggy
7177 gl_cv_have_include_next
=no
7179 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
7182 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
7183 CPPFLAGS
="$gl_save_CPPFLAGS"
7184 rm -rf conftestd1a conftestd1b conftestd2
7187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
7188 $as_echo "$gl_cv_have_include_next" >&6; }
7189 PRAGMA_SYSTEM_HEADER
=
7190 if test $gl_cv_have_include_next = yes; then
7191 INCLUDE_NEXT
=include_next
7192 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
=include_next
7193 if test -n "$GCC"; then
7194 PRAGMA_SYSTEM_HEADER
='#pragma GCC system_header'
7197 if test $gl_cv_have_include_next = buggy
; then
7198 INCLUDE_NEXT
=include
7199 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
=include_next
7201 INCLUDE_NEXT
=include
7202 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
=include
7209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether source code line length is unlimited" >&5
7210 $as_echo_n "checking whether source code line length is unlimited... " >&6; }
7211 if ${gl_cv_source_line_length_unlimited+:} false
; then :
7212 $as_echo_n "(cached) " >&6
7214 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
7215 /* end confdefs.h. */
7222 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7223 $EGREP "choke me" >/dev
/null
2>&1; then :
7224 gl_cv_source_line_length_unlimited
=no
7226 gl_cv_source_line_length_unlimited
=yes
7232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_source_line_length_unlimited" >&5
7233 $as_echo "$gl_cv_source_line_length_unlimited" >&6; }
7234 if test $gl_cv_source_line_length_unlimited = no
; then
7235 PRAGMA_COLUMNS
="#pragma COLUMNS 10000"
7245 if test $ac_cv_header_features_h = yes; then
7255 if test $ac_cv_header_sys_socket_h = no
; then
7256 for ac_header
in ws2tcpip.h
7258 ac_fn_c_check_header_mongrel
"$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
7259 if test "x$ac_cv_header_ws2tcpip_h" = xyes
; then :
7260 cat >>confdefs.h
<<_ACEOF
7261 #define HAVE_WS2TCPIP_H 1
7270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
7271 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
7272 if test -z "$MKDIR_P"; then
7273 if ${ac_cv_path_mkdir+:} false
; then :
7274 $as_echo_n "(cached) " >&6
7276 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
7277 for as_dir
in $PATH$PATH_SEPARATOR/opt
/sfw
/bin
7280 test -z "$as_dir" && as_dir
=.
7281 for ac_prog
in mkdir gmkdir
; do
7282 for ac_exec_ext
in '' $ac_executable_extensions; do
7283 as_fn_executable_p
"$as_dir/$ac_prog$ac_exec_ext" ||
continue
7284 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
7285 'mkdir (GNU coreutils) '* | \
7286 'mkdir (coreutils) '* | \
7287 'mkdir (fileutils) '4.1*)
7288 ac_cv_path_mkdir
=$as_dir/$ac_prog$ac_exec_ext
7298 test -d .
/--version && rmdir .
/--version
7299 if test "${ac_cv_path_mkdir+set}" = set; then
7300 MKDIR_P
="$ac_cv_path_mkdir -p"
7302 # As a last resort, use the slow shell script. Don't cache a
7303 # value for MKDIR_P within a source directory, because that will
7304 # break other packages using the cache if that directory is
7305 # removed, or if the value is a relative name.
7306 MKDIR_P
="$ac_install_sh -d"
7309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
7310 $as_echo "$MKDIR_P" >&6; }
7319 GNULIB_MBSNRTOWCS
=0;
7322 GNULIB_WCSNRTOMBS
=0;
7340 GNULIB_WCSCASECMP
=0;
7341 GNULIB_WCSNCASECMP
=0;
7354 GNULIB_MDA_WCSDUP
=1;
7396 HAVE_DECL_WCWIDTH
=1;
7397 REPLACE_MBSTATE_T
=0;
7403 REPLACE_MBSRTOWCS
=0;
7404 REPLACE_MBSNRTOWCS
=0;
7406 REPLACE_WCSRTOMBS
=0;
7407 REPLACE_WCSNRTOMBS
=0;
7415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <wchar.h> uses 'inline' correctly" >&5
7416 $as_echo_n "checking whether <wchar.h> uses 'inline' correctly... " >&6; }
7417 if ${gl_cv_header_wchar_h_correct_inline+:} false
; then :
7418 $as_echo_n "(cached) " >&6
7420 gl_cv_header_wchar_h_correct_inline
=yes
7423 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
7424 /* end confdefs.h. */
7427 #define wcstod renamed_wcstod
7429 extern int zero (void);
7430 int main () { return zero(); }
7433 save_ac_compile
="$ac_compile"
7434 ac_compile
=`echo "$save_ac_compile" | sed s/conftest/conftest1/`
7435 if echo '#include "conftest.c"' >conftest1.c \
7436 && { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
7437 (eval $ac_compile) 2>&5
7439 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7440 test $ac_status = 0; }; then
7441 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
7442 /* end confdefs.h. */
7445 #define wcstod renamed_wcstod
7447 int zero (void) { return 0; }
7450 ac_compile
=`echo "$save_ac_compile" | sed s/conftest/conftest2/`
7451 if echo '#include "conftest.c"' >conftest2.c \
7452 && { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
7453 (eval $ac_compile) 2>&5
7455 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7456 test $ac_status = 0; }; then
7457 if $CC -o conftest
$ac_exeext $CFLAGS $LDFLAGS conftest1.
$ac_objext conftest2.
$ac_objext $LIBS >&5 2>&1; then
7460 gl_cv_header_wchar_h_correct_inline
=no
7464 ac_compile
="$save_ac_compile"
7465 rm -f conftest12.c conftest12.
$ac_objext conftest
$ac_exeext
7470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_wchar_h_correct_inline" >&5
7471 $as_echo "$gl_cv_header_wchar_h_correct_inline" >&6; }
7472 if test $gl_cv_header_wchar_h_correct_inline = no
; then
7473 as_fn_error $?
"<wchar.h> cannot be used with this compiler ($CC $CFLAGS $CPPFLAGS).
7474 This is a known interoperability problem of glibc <= 2.5 with gcc >= 4.3 in
7475 C99 mode. You have four options:
7476 - Add the flag -fgnu89-inline to CC and reconfigure, or
7477 - Fix your include files, using parts of
7478 <https://sourceware.org/git/?p=glibc.git;a=commitdiff;h=b037a293a48718af30d706c2e18c929d0e69a621>, or
7479 - Use a gcc version older than 4.3, or
7480 - Don't use the flags -std=c99 or -std=gnu99.
7481 Configuration aborted." "$LINENO" 5
7487 for ac_func
in $ac_func_list
7489 as_ac_var
=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
7490 ac_fn_c_check_func
"$LINENO" "$ac_func" "$as_ac_var"
7491 if eval test \"x\$
"$as_ac_var"\" = x
"yes"; then :
7492 cat >>confdefs.h
<<_ACEOF
7493 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
7502 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
7503 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
7504 if ${am_cv_langinfo_codeset+:} false
; then :
7505 $as_echo_n "(cached) " >&6
7507 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
7508 /* end confdefs.h. */
7509 #include <langinfo.h>
7513 char* cs = nl_langinfo(CODESET); return !cs;
7518 if ac_fn_c_try_link
"$LINENO"; then :
7519 am_cv_langinfo_codeset
=yes
7521 am_cv_langinfo_codeset
=no
7523 rm -f core conftest.err conftest.
$ac_objext \
7524 conftest
$ac_exeext conftest.
$ac_ext
7527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
7528 $as_echo "$am_cv_langinfo_codeset" >&6; }
7529 if test $am_cv_langinfo_codeset = yes; then
7531 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
7538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
7539 $as_echo_n "checking for a traditional french locale... " >&6; }
7540 if ${gt_cv_locale_fr+:} false
; then :
7541 $as_echo_n "(cached) " >&6
7544 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
7545 /* end confdefs.h. */
7549 #if HAVE_LANGINFO_CODESET
7550 # include <langinfo.h>
7557 /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
7558 imitates locale dependent behaviour by looking at the environment
7559 variables, and all locales use the UTF-8 encoding. */
7560 #if defined __BEOS__ || defined __HAIKU__
7563 /* Check whether the given locale name is recognized by the system. */
7564 # if defined _WIN32 && !defined __CYGWIN__
7565 /* On native Windows, setlocale(category, "") looks at the system settings,
7566 not at the environment variables. Also, when an encoding suffix such
7567 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
7568 category of the locale to "C". */
7569 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
7570 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
7573 if (setlocale (LC_ALL, "") == NULL) return 1;
7575 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
7576 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
7577 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
7578 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
7579 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
7580 some unit tests fail.
7581 On MirBSD 10, when an unsupported locale is specified, setlocale()
7582 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
7583 # if HAVE_LANGINFO_CODESET
7585 const char *cs = nl_langinfo (CODESET);
7586 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
7587 || strcmp (cs, "UTF-8") == 0)
7592 /* On Cygwin, avoid locale names without encoding suffix, because the
7593 locale_charset() function relies on the encoding suffix. Note that
7594 LC_ALL is set on the command line. */
7595 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
7597 /* Check whether in the abbreviation of the second month, the second
7598 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
7599 one byte long. This excludes the UTF-8 encoding. */
7600 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
7601 if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
7602 # if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
7603 /* Check whether the decimal separator is a comma.
7604 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
7605 are nl_langinfo(RADIXCHAR) are both ".". */
7606 if (localeconv () ->decimal_point[0] != ',') return 1;
7613 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
7614 (eval $ac_link) 2>&5
7616 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7617 test $ac_status = 0; } && test -s conftest
$ac_exeext; then
7619 # Handle native Windows specially, because there setlocale() interprets
7620 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
7621 # "fr" or "fra" as "French" or "French_France.1252",
7622 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
7623 # "ja" as "Japanese" or "Japanese_Japan.932",
7626 # Test for the native Windows locale name.
7627 if (LC_ALL
=French_France
.1252 LC_TIME
= LC_CTYPE
= .
/conftest
; exit) 2>/dev
/null
; then
7628 gt_cv_locale_fr
=French_France
.1252
7631 gt_cv_locale_fr
=none
7635 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
7636 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
7637 # configure script would override the LC_ALL setting. Likewise for
7638 # LC_CTYPE, which is also set at the beginning of the configure script.
7639 # Test for the usual locale name.
7640 if (LC_ALL
=fr_FR LC_TIME
= LC_CTYPE
= .
/conftest
; exit) 2>/dev
/null
; then
7641 gt_cv_locale_fr
=fr_FR
7643 # Test for the locale name with explicit encoding suffix.
7644 if (LC_ALL
=fr_FR.ISO-8859-1 LC_TIME
= LC_CTYPE
= .
/conftest
; exit) 2>/dev
/null
; then
7645 gt_cv_locale_fr
=fr_FR.ISO-8859-1
7647 # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
7648 if (LC_ALL
=fr_FR.ISO8859-1 LC_TIME
= LC_CTYPE
= .
/conftest
; exit) 2>/dev
/null
; then
7649 gt_cv_locale_fr
=fr_FR.ISO8859-1
7651 # Test for the HP-UX locale name.
7652 if (LC_ALL
=fr_FR.iso88591 LC_TIME
= LC_CTYPE
= .
/conftest
; exit) 2>/dev
/null
; then
7653 gt_cv_locale_fr
=fr_FR.iso88591
7655 # Test for the Solaris 7 locale name.
7656 if (LC_ALL
=fr LC_TIME
= LC_CTYPE
= .
/conftest
; exit) 2>/dev
/null
; then
7660 gt_cv_locale_fr
=none
7672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
7673 $as_echo "$gt_cv_locale_fr" >&6; }
7674 LOCALE_FR
=$gt_cv_locale_fr
7679 GNULIB_ALIGNED_ALLOC
=0;
7681 GNULIB_CALLOC_POSIX
=0;
7682 GNULIB_CANONICALIZE_FILE_NAME
=0;
7683 GNULIB_FREE_POSIX
=0;
7684 GNULIB_GETLOADAVG
=0;
7687 GNULIB_MALLOC_POSIX
=0;
7694 GNULIB_POSIX_MEMALIGN
=0;
7695 GNULIB_POSIX_OPENPT
=0;
7702 GNULIB_REALLOCARRAY
=0;
7703 GNULIB_REALLOC_POSIX
=0;
7706 GNULIB_SECURE_GETENV
=0;
7712 GNULIB_SYSTEM_POSIX
=0;
7719 GNULIB_MDA_MKTEMP
=1;
7720 GNULIB_MDA_PUTENV
=1;
7722 HAVE_ALIGNED_ALLOC
=1;
7724 HAVE_CANONICALIZE_FILE_NAME
=1;
7728 HAVE_DECL_GETLOADAVG
=1;
7732 HAVE_DECL_INITSTATE
=1;
7739 HAVE_POSIX_MEMALIGN
=1;
7740 HAVE_POSIX_OPENPT
=1;
7747 HAVE_REALLOCARRAY
=1;
7750 HAVE_SECURE_GETENV
=1;
7754 HAVE_DECL_SETSTATE
=1;
7759 HAVE_STRUCT_RANDOM_DATA
=1;
7760 HAVE_SYS_LOADAVG_H
=0;
7762 HAVE_DECL_UNSETENV
=1;
7763 REPLACE_ALIGNED_ALLOC
=0;
7765 REPLACE_CANONICALIZE_FILE_NAME
=0;
7767 REPLACE_INITSTATE
=0;
7771 REPLACE_POSIX_MEMALIGN
=0;
7773 REPLACE_PTSNAME_R
=0;
7788 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
7789 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
7790 if ${gl_cv_func_lstat_dereferences_slashed_symlink+:} false
; then :
7791 $as_echo_n "(cached) " >&6
7793 rm -f conftest.sym conftest.
file
7795 if test "$cross_compiling" = yes; then :
7798 # Guess yes on Linux systems.
7799 gl_cv_func_lstat_dereferences_slashed_symlink
="guessing yes" ;;
7801 # Guess yes on glibc systems.
7802 gl_cv_func_lstat_dereferences_slashed_symlink
="guessing yes" ;;
7804 # Guess no on native Windows.
7805 gl_cv_func_lstat_dereferences_slashed_symlink
="guessing no" ;;
7807 # If we don't know, obey --enable-cross-guesses.
7808 gl_cv_func_lstat_dereferences_slashed_symlink
="$gl_cross_guess_normal" ;;
7812 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
7813 /* end confdefs.h. */
7814 $ac_includes_default
7819 if (symlink ("conftest.file", "conftest.sym") != 0)
7821 /* Linux will dereference the symlink and fail, as required by
7822 POSIX. That is better in the sense that it means we will not
7823 have to compile and use the lstat wrapper. */
7824 return lstat ("conftest.sym/", &sbuf) == 0;
7830 if ac_fn_c_try_run
"$LINENO"; then :
7831 gl_cv_func_lstat_dereferences_slashed_symlink
=yes
7833 gl_cv_func_lstat_dereferences_slashed_symlink
=no
7835 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
7836 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
7839 rm -f conftest.sym conftest.
file
7842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
7843 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
7844 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
7847 cat >>confdefs.h
<<_ACEOF
7848 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
7860 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether // is distinct from /" >&5
7861 $as_echo_n "checking whether // is distinct from /... " >&6; }
7862 if ${gl_cv_double_slash_root+:} false
; then :
7863 $as_echo_n "(cached) " >&6
7865 if test x
"$cross_compiling" = xyes
; then
7866 # When cross-compiling, there is no way to tell whether // is special
7867 # short of a list of hosts. However, the only known hosts to date
7868 # that have a distinct // are Apollo DomainOS (too old to port to),
7869 # Cygwin, and z/OS. If anyone knows of another system for which // has
7870 # special semantics and is distinct from /, please report it to
7871 # <bug-gnulib@gnu.org>.
7873 *-cygwin | i370-ibm-openedition
)
7874 gl_cv_double_slash_root
=yes ;;
7876 # Be optimistic and assume that / and // are the same when we
7878 gl_cv_double_slash_root
='unknown, assuming no' ;;
7881 set x
`ls -di / // 2>/dev/null`
7882 if test "$2" = "$4" && wc //dev
/null
>/dev
/null
2>&1; then
7883 gl_cv_double_slash_root
=no
7885 gl_cv_double_slash_root
=yes
7889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_double_slash_root" >&5
7890 $as_echo "$gl_cv_double_slash_root" >&6; }
7891 if test "$gl_cv_double_slash_root" = yes; then
7893 $as_echo "#define DOUBLE_SLASH_IS_DISTINCT_ROOT 1" >>confdefs.h
7901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether realpath works" >&5
7902 $as_echo_n "checking whether realpath works... " >&6; }
7903 if ${gl_cv_func_realpath_works+:} false
; then :
7904 $as_echo_n "(cached) " >&6
7907 rm -rf conftest.a conftest.d
7910 if test "$cross_compiling" = yes; then :
7912 # Guess yes on glibc systems.
7913 *-gnu* | gnu
*) gl_cv_func_realpath_works
="guessing yes" ;;
7914 # Guess yes on musl systems.
7915 *-musl*) gl_cv_func_realpath_works
="guessing yes" ;;
7916 # Guess no on native Windows.
7917 mingw
*) gl_cv_func_realpath_works
="guessing no" ;;
7918 # If we don't know, obey --enable-cross-guesses.
7919 *) gl_cv_func_realpath_works
="$gl_cross_guess_normal" ;;
7923 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
7924 /* end confdefs.h. */
7929 #if defined __MACH__ && defined __APPLE__
7930 /* Avoid a crash on Mac OS X. */
7931 #include <mach/mach.h>
7932 #include <mach/mach_error.h>
7933 #include <mach/thread_status.h>
7934 #include <mach/exception.h>
7935 #include <mach/task.h>
7936 #include <pthread.h>
7937 /* The exception port on which our thread listens. */
7938 static mach_port_t our_exception_port;
7939 /* The main function of the thread listening for exceptions of type
7942 mach_exception_thread (void *arg)
7944 /* Buffer for a message to be received. */
7946 mach_msg_header_t head;
7947 mach_msg_body_t msgh_body;
7950 mach_msg_return_t retval;
7951 /* Wait for a message on the exception port. */
7952 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
7953 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
7954 if (retval != MACH_MSG_SUCCESS)
7961 mach_port_t self = mach_task_self ();
7962 /* Allocate a port on which the thread shall listen for exceptions. */
7963 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
7965 /* See https://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
7966 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
7967 MACH_MSG_TYPE_MAKE_SEND)
7969 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
7971 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
7972 /* Create the thread listening on the exception port. */
7973 pthread_attr_t attr;
7975 if (pthread_attr_init (&attr) == 0
7976 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
7977 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
7978 pthread_attr_destroy (&attr);
7979 /* Replace the exception port info for these exceptions with our own.
7980 Note that we replace the exception port for the entire task, not only
7981 for a particular thread. This has the effect that when our exception
7982 port gets the message, the thread specific exception port has already
7983 been asked, and we don't need to bother about it.
7984 See https://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
7985 task_set_exception_ports (self, mask, our_exception_port,
7986 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
7991 #elif defined _WIN32 && ! defined __CYGWIN__
7992 /* Avoid a crash on native Windows. */
7993 #define WIN32_LEAN_AND_MEAN
7994 #include <windows.h>
7995 #include <winerror.h>
7997 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
7999 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
8001 case EXCEPTION_ACCESS_VIOLATION:
8002 case EXCEPTION_IN_PAGE_ERROR:
8003 case EXCEPTION_STACK_OVERFLOW:
8004 case EXCEPTION_GUARD_PAGE:
8005 case EXCEPTION_PRIV_INSTRUCTION:
8006 case EXCEPTION_ILLEGAL_INSTRUCTION:
8007 case EXCEPTION_DATATYPE_MISALIGNMENT:
8008 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
8009 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
8012 return EXCEPTION_CONTINUE_SEARCH;
8017 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
8020 /* Avoid a crash on POSIX systems. */
8023 /* A POSIX signal handler. */
8025 exception_handler (int sig)
8033 signal (SIGSEGV, exception_handler);
8036 signal (SIGBUS, exception_handler);
8050 char *name = realpath ("conftest.a", NULL);
8051 if (!(name && *name == '/'))
8056 char *name = realpath ("conftest.b/../conftest.a", NULL);
8062 char *name = realpath ("conftest.a/", NULL);
8068 char *name1 = realpath (".", NULL);
8069 char *name2 = realpath ("conftest.d//./..", NULL);
8070 if (! name1 || ! name2 || strcmp (name1, name2))
8082 if ac_fn_c_try_run
"$LINENO"; then :
8083 gl_cv_func_realpath_works
=yes
8085 gl_cv_func_realpath_works
=no
8087 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
8088 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
8091 rm -rf conftest.a conftest.d
8094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_realpath_works" >&5
8095 $as_echo "$gl_cv_func_realpath_works" >&6; }
8096 case "$gl_cv_func_realpath_works" in
8099 $as_echo "#define FUNC_REALPATH_WORKS 1" >>confdefs.h
8114 *) for ac_func
in getcwd
8116 ac_fn_c_check_func
"$LINENO" "getcwd" "ac_cv_func_getcwd"
8117 if test "x$ac_cv_func_getcwd" = xyes
; then :
8118 cat >>confdefs.h
<<_ACEOF
8119 #define HAVE_GETCWD 1
8136 GNULIB_COPY_FILE_RANGE
=0;
8141 GNULIB_EUIDACCESS
=0;
8156 GNULIB_GETDOMAINNAME
=0;
8157 GNULIB_GETDTABLESIZE
=0;
8158 GNULIB_GETENTROPY
=0;
8160 GNULIB_GETHOSTNAME
=0;
8162 GNULIB_GETLOGIN_R
=0;
8163 GNULIB_GETOPT_POSIX
=0;
8164 GNULIB_GETPAGESIZE
=0;
8166 GNULIB_GETUSERSHELL
=0;
8167 GNULIB_GROUP_MEMBER
=0;
8179 GNULIB_READLINKAT
=0;
8181 GNULIB_SETHOSTNAME
=0;
8187 GNULIB_UNISTD_H_NONBLOCKING
=0;
8188 GNULIB_UNISTD_H_SIGPIPE
=0;
8193 GNULIB_MDA_ACCESS
=1;
8199 GNULIB_MDA_EXECLE
=1;
8200 GNULIB_MDA_EXECLP
=1;
8202 GNULIB_MDA_EXECVE
=1;
8203 GNULIB_MDA_EXECVP
=1;
8204 GNULIB_MDA_EXECVPE
=1;
8205 GNULIB_MDA_GETCWD
=1;
8206 GNULIB_MDA_GETPID
=1;
8207 GNULIB_MDA_ISATTY
=1;
8212 GNULIB_MDA_UNLINK
=1;
8215 HAVE_COPY_FILE_RANGE
=1;
8225 HAVE_GETDTABLESIZE
=1;
8232 HAVE_GROUP_MEMBER
=1;
8248 HAVE_DECL_ENVIRON
=1;
8249 HAVE_DECL_EXECVPE
=1;
8251 HAVE_DECL_FDATASYNC
=1;
8252 HAVE_DECL_GETDOMAINNAME
=1;
8253 HAVE_DECL_GETLOGIN
=1;
8254 HAVE_DECL_GETLOGIN_R
=1;
8255 HAVE_DECL_GETPAGESIZE
=1;
8256 HAVE_DECL_GETUSERSHELL
=1;
8257 HAVE_DECL_SETHOSTNAME
=1;
8258 HAVE_DECL_TRUNCATE
=1;
8259 HAVE_DECL_TTYNAME_R
=1;
8274 REPLACE_FACCESSAT
=0;
8276 REPLACE_FTRUNCATE
=0;
8278 REPLACE_GETDOMAINNAME
=0;
8279 REPLACE_GETDTABLESIZE
=0;
8280 REPLACE_GETLOGIN_R
=0;
8281 REPLACE_GETGROUPS
=0;
8282 REPLACE_GETPAGESIZE
=0;
8293 REPLACE_READLINKAT
=0;
8297 REPLACE_SYMLINKAT
=0;
8299 REPLACE_TTYNAME_R
=0;
8304 UNISTD_H_HAVE_SYS_RANDOM_H
=0;
8305 UNISTD_H_HAVE_WINSOCK2_H
=0;
8306 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
=0;
8314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
8315 $as_echo_n "checking for uid_t in sys/types.h... " >&6; }
8316 if ${ac_cv_type_uid_t+:} false
; then :
8317 $as_echo_n "(cached) " >&6
8319 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
8320 /* end confdefs.h. */
8321 #include <sys/types.h>
8324 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8325 $EGREP "uid_t" >/dev
/null
2>&1; then :
8326 ac_cv_type_uid_t
=yes
8333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
8334 $as_echo "$ac_cv_type_uid_t" >&6; }
8335 if test $ac_cv_type_uid_t = no
; then
8337 $as_echo "#define uid_t int" >>confdefs.h
8340 $as_echo "#define gid_t int" >>confdefs.h
8345 #if defined _WIN32 && !defined __CYGWIN__
8346 #define access _access
8347 #define chdir _chdir
8348 #define chmod _chmod
8349 #define close _close
8350 #define creat _creat
8354 #define execl _execl
8355 #define execle _execle
8356 #define execlp _execlp
8357 #define execv _execv
8358 #define execve _execve
8359 #define execvp _execvp
8360 #define execvpe _execvpe
8361 #define fcloseall _fcloseall
8363 #define fdopen _fdopen
8364 #define fileno _fileno
8366 #define getcwd _getcwd
8367 #define getpid _getpid
8369 #define isatty _isatty
8373 #define lfind _lfind
8374 #define lsearch _lsearch
8375 #define lseek _lseek
8376 #define memccpy _memccpy
8377 #define mkdir _mkdir
8378 #define mktemp _mktemp
8380 #define putenv _putenv
8383 #define rmdir _rmdir
8384 #define strdup _strdup
8386 #define tempnam _tempnam
8387 #define tzset _tzset
8388 #define umask _umask
8389 #define unlink _unlink
8390 #define utime _utime
8391 #define wcsdup _wcsdup
8392 #define write _write
8400 for ac_header
in unistd.h
8402 ac_fn_c_check_header_mongrel
"$LINENO" "unistd.h" "ac_cv_header_unistd_h" "$ac_includes_default"
8403 if test "x$ac_cv_header_unistd_h" = xyes
; then :
8404 cat >>confdefs.h
<<_ACEOF
8405 #define HAVE_UNISTD_H 1
8412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working chown" >&5
8413 $as_echo_n "checking for working chown... " >&6; }
8414 if ${ac_cv_func_chown_works+:} false
; then :
8415 $as_echo_n "(cached) " >&6
8417 if test "$cross_compiling" = yes; then :
8418 case "$host_os" in # ((
8419 # Guess yes on Linux systems.
8420 linux-
* | linux
) ac_cv_func_chown_works
="guessing yes" ;;
8421 # Guess yes on glibc systems.
8422 *-gnu* | gnu
*) ac_cv_func_chown_works
="guessing yes" ;;
8423 # Guess no on native Windows.
8424 mingw
*) ac_cv_func_chown_works
="guessing no" ;;
8425 # If we don't know, obey --enable-cross-guesses.
8426 *) ac_cv_func_chown_works
="$gl_cross_guess_normal" ;;
8430 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
8431 /* end confdefs.h. */
8432 $ac_includes_default
8442 char *f = "conftest.chown";
8443 struct stat before, after;
8445 if (creat (f, 0600) < 0)
8447 if (stat (f, &before) < 0)
8449 if (chown (f, (uid_t) -1, (gid_t) -1) == -1)
8451 if (stat (f, &after) < 0)
8453 return ! (before.st_uid == after.st_uid && before.st_gid == after.st_gid);
8460 if ac_fn_c_try_run
"$LINENO"; then :
8461 ac_cv_func_chown_works
=yes
8463 ac_cv_func_chown_works
=no
8465 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
8466 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
8469 rm -f conftest.chown
8472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_chown_works" >&5
8473 $as_echo "$ac_cv_func_chown_works" >&6; }
8474 case "$ac_cv_func_chown_works" in
8477 $as_echo "#define HAVE_CHOWN 1" >>confdefs.h
8483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether chown dereferences symlinks" >&5
8484 $as_echo_n "checking whether chown dereferences symlinks... " >&6; }
8485 if ${gl_cv_func_chown_follows_symlink+:} false
; then :
8486 $as_echo_n "(cached) " >&6
8489 if test "$cross_compiling" = yes; then :
8490 gl_cv_func_chown_follows_symlink
="guessing yes"
8493 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
8494 /* end confdefs.h. */
8507 char const *dangling_symlink = "conftest.dangle";
8509 unlink (dangling_symlink);
8510 if (symlink ("conftest.no-such", dangling_symlink))
8513 /* Exit successfully on a conforming system,
8514 i.e., where chown must fail with ENOENT. */
8515 if (chown (dangling_symlink, getuid (), getgid ()) == 0)
8517 if (errno != ENOENT)
8523 if ac_fn_c_try_run
"$LINENO"; then :
8524 gl_cv_func_chown_follows_symlink
=yes
8526 gl_cv_func_chown_follows_symlink
=no
8528 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
8529 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
8535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_chown_follows_symlink" >&5
8536 $as_echo "$gl_cv_func_chown_follows_symlink" >&6; }
8538 case "$gl_cv_func_chown_follows_symlink" in
8542 $as_echo "#define CHOWN_MODIFIES_SYMLINK 1" >>confdefs.h
8558 if test $ac_cv_func_chown = no
; then
8561 case "$gl_cv_func_chown_follows_symlink" in
8563 *) REPLACE_CHOWN
=1 ;;
8566 case "$ac_cv_func_chown_works" in
8569 $as_echo "#define CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE 1" >>confdefs.h
8575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether chown honors trailing slash" >&5
8576 $as_echo_n "checking whether chown honors trailing slash... " >&6; }
8577 if ${gl_cv_func_chown_slash_works+:} false
; then :
8578 $as_echo_n "(cached) " >&6
8580 touch conftest.
file && rm -f conftest.link
8581 if test "$cross_compiling" = yes; then :
8583 # Guess yes on glibc systems.
8584 *-gnu*) gl_cv_func_chown_slash_works
="guessing yes" ;;
8585 # Guess yes on musl systems.
8586 *-musl*) gl_cv_func_chown_slash_works
="guessing yes" ;;
8587 # If we don't know, obey --enable-cross-guesses.
8588 *) gl_cv_func_chown_slash_works
="$gl_cross_guess_normal" ;;
8592 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
8593 /* end confdefs.h. */
8605 if (symlink ("conftest.file", "conftest.link")) return 1;
8606 if (chown ("conftest.link/", getuid (), getgid ()) == 0) return 2;
8612 if ac_fn_c_try_run
"$LINENO"; then :
8613 gl_cv_func_chown_slash_works
=yes
8615 gl_cv_func_chown_slash_works
=no
8617 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
8618 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
8621 rm -f conftest.link conftest.
file
8623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_chown_slash_works" >&5
8624 $as_echo "$gl_cv_func_chown_slash_works" >&6; }
8625 case "$gl_cv_func_chown_slash_works" in
8629 $as_echo "#define CHOWN_TRAILING_SLASH_BUG 1" >>confdefs.h
8635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether chown always updates ctime" >&5
8636 $as_echo_n "checking whether chown always updates ctime... " >&6; }
8637 if ${gl_cv_func_chown_ctime_works+:} false
; then :
8638 $as_echo_n "(cached) " >&6
8640 if test "$cross_compiling" = yes; then :
8642 # Guess yes on glibc systems.
8643 *-gnu*) gl_cv_func_chown_ctime_works
="guessing yes" ;;
8644 # Guess yes on musl systems.
8645 *-musl*) gl_cv_func_chown_ctime_works
="guessing yes" ;;
8646 # If we don't know, obey --enable-cross-guesses.
8647 *) gl_cv_func_chown_ctime_works
="$gl_cross_guess_normal" ;;
8651 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
8652 /* end confdefs.h. */
8658 #include <sys/stat.h>
8666 struct stat st1, st2;
8667 if (close (creat ("conftest.file", 0600))) return 1;
8668 if (stat ("conftest.file", &st1)) return 2;
8670 if (chown ("conftest.file", st1.st_uid, st1.st_gid)) return 3;
8671 if (stat ("conftest.file", &st2)) return 4;
8672 if (st2.st_ctime <= st1.st_ctime) return 5;
8678 if ac_fn_c_try_run
"$LINENO"; then :
8679 gl_cv_func_chown_ctime_works
=yes
8681 gl_cv_func_chown_ctime_works
=no
8683 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
8684 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
8689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_chown_ctime_works" >&5
8690 $as_echo "$gl_cv_func_chown_ctime_works" >&6; }
8691 case "$gl_cv_func_chown_ctime_works" in
8695 $as_echo "#define CHOWN_CHANGE_TIME_BUG 1" >>confdefs.h
8706 if test $ac_cv_func__set_invalid_parameter_handler = yes; then
8707 HAVE_MSVC_INVALID_PARAMETER_HANDLER
=1
8709 $as_echo "#define HAVE_MSVC_INVALID_PARAMETER_HANDLER 1" >>confdefs.h
8712 HAVE_MSVC_INVALID_PARAMETER_HANDLER
=0
8732 HAVE_DECL_FDOPENDIR
=1;
8739 REPLACE_FDOPENDIR
=0;
8754 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
8755 $as_echo_n "checking if environ is properly declared... " >&6; }
8756 if ${gt_cv_var_environ_declaration+:} false
; then :
8757 $as_echo_n "(cached) " >&6
8759 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
8760 /* end confdefs.h. */
8764 /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
8767 extern struct { int foo; } environ;
8776 if ac_fn_c_try_compile
"$LINENO"; then :
8777 gt_cv_var_environ_declaration
=no
8779 gt_cv_var_environ_declaration
=yes
8781 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
8783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
8784 $as_echo "$gt_cv_var_environ_declaration" >&6; }
8785 if test $gt_cv_var_environ_declaration = yes; then
8787 $as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
8792 if test $gt_cv_var_environ_declaration != yes; then
8798 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for complete errno.h" >&5
8799 $as_echo_n "checking for complete errno.h... " >&6; }
8800 if ${gl_cv_header_errno_h_complete+:} false
; then :
8801 $as_echo_n "(cached) " >&6
8804 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
8805 /* end confdefs.h. */
8808 #if !defined ETXTBSY
8817 #if !defined ENOLINK
8823 #if !defined EMULTIHOP
8826 #if !defined EBADMSG
8829 #if !defined EOVERFLOW
8832 #if !defined ENOTSUP
8835 #if !defined ENETRESET
8838 #if !defined ECONNABORTED
8847 #if !defined ECANCELED
8850 #if !defined EOWNERDEAD
8853 #if !defined ENOTRECOVERABLE
8861 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8862 $EGREP "booboo" >/dev
/null
2>&1; then :
8863 gl_cv_header_errno_h_complete
=no
8865 gl_cv_header_errno_h_complete
=yes
8871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_complete" >&5
8872 $as_echo "$gl_cv_header_errno_h_complete" >&6; }
8873 if test $gl_cv_header_errno_h_complete = yes; then
8884 if test $gl_cv_have_include_next = yes; then
8885 gl_cv_next_errno_h
='<'errno.h
'>'
8887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <errno.h>" >&5
8888 $as_echo_n "checking absolute name of <errno.h>... " >&6; }
8889 if ${gl_cv_next_errno_h+:} false
; then :
8890 $as_echo_n "(cached) " >&6
8895 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
8896 /* end confdefs.h. */
8900 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
8901 *) gl_absname_cpp
="$ac_cpp" ;;
8906 gl_dirsep_regex
='[/\\]'
8909 gl_dirsep_regex
='\/'
8912 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
8913 gl_header_literal_regex
=`echo 'errno.h' \
8914 | sed -e "$gl_make_literal_regex_sed"`
8915 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
8916 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
8922 gl_cv_absolute_errno_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
8923 sed -n "$gl_absolute_header_sed"`
8925 gl_header
=$gl_cv_absolute_errno_h
8926 gl_cv_next_errno_h
='"'$gl_header'"'
8930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_errno_h" >&5
8931 $as_echo "$gl_cv_next_errno_h" >&6; }
8933 NEXT_ERRNO_H
=$gl_cv_next_errno_h
8935 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
8936 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
8937 gl_next_as_first_directive
='<'errno.h
'>'
8939 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
8940 gl_next_as_first_directive
=$gl_cv_next_errno_h
8942 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H
=$gl_next_as_first_directive
8950 if test -n "$ERRNO_H"; then
8951 GL_GENERATE_ERRNO_H_TRUE
=
8952 GL_GENERATE_ERRNO_H_FALSE
='#'
8954 GL_GENERATE_ERRNO_H_TRUE
='#'
8955 GL_GENERATE_ERRNO_H_FALSE
=
8959 if test -n "$ERRNO_H"; then
8960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EMULTIHOP value" >&5
8961 $as_echo_n "checking for EMULTIHOP value... " >&6; }
8962 if ${gl_cv_header_errno_h_EMULTIHOP+:} false
; then :
8963 $as_echo_n "(cached) " >&6
8966 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
8967 /* end confdefs.h. */
8975 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8976 $EGREP "yes" >/dev
/null
2>&1; then :
8977 gl_cv_header_errno_h_EMULTIHOP
=yes
8979 gl_cv_header_errno_h_EMULTIHOP
=no
8983 if test $gl_cv_header_errno_h_EMULTIHOP = no
; then
8984 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
8985 /* end confdefs.h. */
8987 #define _XOPEN_SOURCE_EXTENDED 1
8994 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8995 $EGREP "yes" >/dev
/null
2>&1; then :
8996 gl_cv_header_errno_h_EMULTIHOP
=hidden
9000 if test $gl_cv_header_errno_h_EMULTIHOP = hidden
; then
9001 if ac_fn_c_compute_int
"$LINENO" "EMULTIHOP" "gl_cv_header_errno_h_EMULTIHOP" "
9002 #define _XOPEN_SOURCE_EXTENDED 1
9004 /* The following two lines are a workaround against an autoconf-2.52 bug. */
9015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EMULTIHOP" >&5
9016 $as_echo "$gl_cv_header_errno_h_EMULTIHOP" >&6; }
9017 case $gl_cv_header_errno_h_EMULTIHOP in
9019 EMULTIHOP_HIDDEN
=0; EMULTIHOP_VALUE
=
9022 EMULTIHOP_HIDDEN
=1; EMULTIHOP_VALUE
="$gl_cv_header_errno_h_EMULTIHOP"
9030 if test -n "$ERRNO_H"; then
9031 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ENOLINK value" >&5
9032 $as_echo_n "checking for ENOLINK value... " >&6; }
9033 if ${gl_cv_header_errno_h_ENOLINK+:} false
; then :
9034 $as_echo_n "(cached) " >&6
9037 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
9038 /* end confdefs.h. */
9046 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9047 $EGREP "yes" >/dev
/null
2>&1; then :
9048 gl_cv_header_errno_h_ENOLINK
=yes
9050 gl_cv_header_errno_h_ENOLINK
=no
9054 if test $gl_cv_header_errno_h_ENOLINK = no
; then
9055 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
9056 /* end confdefs.h. */
9058 #define _XOPEN_SOURCE_EXTENDED 1
9065 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9066 $EGREP "yes" >/dev
/null
2>&1; then :
9067 gl_cv_header_errno_h_ENOLINK
=hidden
9071 if test $gl_cv_header_errno_h_ENOLINK = hidden
; then
9072 if ac_fn_c_compute_int
"$LINENO" "ENOLINK" "gl_cv_header_errno_h_ENOLINK" "
9073 #define _XOPEN_SOURCE_EXTENDED 1
9075 /* The following two lines are a workaround against an autoconf-2.52 bug. */
9086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_ENOLINK" >&5
9087 $as_echo "$gl_cv_header_errno_h_ENOLINK" >&6; }
9088 case $gl_cv_header_errno_h_ENOLINK in
9090 ENOLINK_HIDDEN
=0; ENOLINK_VALUE
=
9093 ENOLINK_HIDDEN
=1; ENOLINK_VALUE
="$gl_cv_header_errno_h_ENOLINK"
9101 if test -n "$ERRNO_H"; then
9102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EOVERFLOW value" >&5
9103 $as_echo_n "checking for EOVERFLOW value... " >&6; }
9104 if ${gl_cv_header_errno_h_EOVERFLOW+:} false
; then :
9105 $as_echo_n "(cached) " >&6
9108 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
9109 /* end confdefs.h. */
9117 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9118 $EGREP "yes" >/dev
/null
2>&1; then :
9119 gl_cv_header_errno_h_EOVERFLOW
=yes
9121 gl_cv_header_errno_h_EOVERFLOW
=no
9125 if test $gl_cv_header_errno_h_EOVERFLOW = no
; then
9126 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
9127 /* end confdefs.h. */
9129 #define _XOPEN_SOURCE_EXTENDED 1
9136 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9137 $EGREP "yes" >/dev
/null
2>&1; then :
9138 gl_cv_header_errno_h_EOVERFLOW
=hidden
9142 if test $gl_cv_header_errno_h_EOVERFLOW = hidden
; then
9143 if ac_fn_c_compute_int
"$LINENO" "EOVERFLOW" "gl_cv_header_errno_h_EOVERFLOW" "
9144 #define _XOPEN_SOURCE_EXTENDED 1
9146 /* The following two lines are a workaround against an autoconf-2.52 bug. */
9157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EOVERFLOW" >&5
9158 $as_echo "$gl_cv_header_errno_h_EOVERFLOW" >&6; }
9159 case $gl_cv_header_errno_h_EOVERFLOW in
9161 EOVERFLOW_HIDDEN
=0; EOVERFLOW_VALUE
=
9164 EOVERFLOW_HIDDEN
=1; EOVERFLOW_VALUE
="$gl_cv_header_errno_h_EOVERFLOW"
9172 ac_fn_c_check_decl
"$LINENO" "strerror_r" "ac_cv_have_decl_strerror_r" "$ac_includes_default"
9173 if test "x$ac_cv_have_decl_strerror_r" = xyes
; then :
9179 cat >>confdefs.h
<<_ACEOF
9180 #define HAVE_DECL_STRERROR_R $ac_have_decl
9183 for ac_func
in strerror_r
9185 ac_fn_c_check_func
"$LINENO" "strerror_r" "ac_cv_func_strerror_r"
9186 if test "x$ac_cv_func_strerror_r" = xyes
; then :
9187 cat >>confdefs.h
<<_ACEOF
9188 #define HAVE_STRERROR_R 1
9194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror_r returns char *" >&5
9195 $as_echo_n "checking whether strerror_r returns char *... " >&6; }
9196 if ${ac_cv_func_strerror_r_char_p+:} false
; then :
9197 $as_echo_n "(cached) " >&6
9200 ac_cv_func_strerror_r_char_p
=no
9201 if test $ac_cv_have_decl_strerror_r = yes; then
9202 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
9203 /* end confdefs.h. */
9204 $ac_includes_default
9210 char x = *strerror_r (0, buf, sizeof buf);
9211 char *p = strerror_r (0, buf, sizeof buf);
9218 if ac_fn_c_try_compile
"$LINENO"; then :
9219 ac_cv_func_strerror_r_char_p
=yes
9221 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
9223 # strerror_r is not declared. Choose between
9224 # systems that have relatively inaccessible declarations for the
9225 # function. BeOS and DEC UNIX 4.0 fall in this category, but the
9226 # former has a strerror_r that returns char*, while the latter
9227 # has a strerror_r that returns `int'.
9228 # This test should segfault on the DEC system.
9229 if test "$cross_compiling" = yes; then :
9232 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
9233 /* end confdefs.h. */
9234 $ac_includes_default
9235 extern char *strerror_r ();
9240 char x = *strerror_r (0, buf, sizeof buf);
9241 return ! isalpha (x);
9246 if ac_fn_c_try_run
"$LINENO"; then :
9247 ac_cv_func_strerror_r_char_p
=yes
9249 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
9250 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
9256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strerror_r_char_p" >&5
9257 $as_echo "$ac_cv_func_strerror_r_char_p" >&6; }
9258 if test $ac_cv_func_strerror_r_char_p = yes; then
9260 $as_echo "#define STRERROR_R_CHAR_P 1" >>confdefs.h
9267 ac_fn_c_check_decl
"$LINENO" "fchdir" "ac_cv_have_decl_fchdir" "$ac_includes_default"
9268 if test "x$ac_cv_have_decl_fchdir" = xyes
; then :
9274 cat >>confdefs.h
<<_ACEOF
9275 #define HAVE_DECL_FCHDIR $ac_have_decl
9281 GNULIB_NONBLOCKING
=0;
9302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fcntl.h" >&5
9303 $as_echo_n "checking for working fcntl.h... " >&6; }
9304 if ${gl_cv_header_working_fcntl_h+:} false
; then :
9305 $as_echo_n "(cached) " >&6
9307 if test "$cross_compiling" = yes; then :
9309 # Guess 'no' on native Windows.
9310 mingw
*) gl_cv_header_working_fcntl_h
='no' ;;
9311 *) gl_cv_header_working_fcntl_h
=cross-compiling
;;
9315 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
9316 /* end confdefs.h. */
9317 #include <sys/types.h>
9318 #include <sys/stat.h>
9320 # include <unistd.h>
9321 #else /* on Windows with MSVC */
9323 # include <stdlib.h>
9324 # defined sleep(n) _sleep ((n) * 1000)
9335 #define O_NOFOLLOW 0
9337 static int const constants[] =
9339 O_CREAT, O_EXCL, O_NOCTTY, O_TRUNC, O_APPEND,
9340 O_NONBLOCK, O_SYNC, O_ACCMODE, O_RDONLY, O_RDWR, O_WRONLY
9347 int result = !constants;
9350 static char const sym[] = "conftest.sym";
9351 if (symlink ("/dev/null", sym) != 0)
9355 int fd = open (sym, O_WRONLY | O_NOFOLLOW | O_CREAT, 0);
9362 if (unlink (sym) != 0 || symlink (".", sym) != 0)
9366 int fd = open (sym, O_RDONLY | O_NOFOLLOW);
9377 static char const file[] = "confdefs.h";
9378 int fd = open (file, O_RDONLY | O_NOATIME);
9384 if (fstat (fd, &st0) != 0)
9390 if (read (fd, &c, 1) != 1)
9394 if (close (fd) != 0)
9399 if (stat (file, &st1) != 0)
9402 if (st0.st_atime != st1.st_atime)
9414 if ac_fn_c_try_run
"$LINENO"; then :
9415 gl_cv_header_working_fcntl_h
=yes
9418 4) gl_cv_header_working_fcntl_h
='no (bad O_NOFOLLOW)';; #(
9419 64) gl_cv_header_working_fcntl_h
='no (bad O_NOATIME)';; #(
9420 68) gl_cv_header_working_fcntl_h
='no (bad O_NOATIME, O_NOFOLLOW)';; #(
9421 *) gl_cv_header_working_fcntl_h
='no';;
9424 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
9425 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
9430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_fcntl_h" >&5
9431 $as_echo "$gl_cv_header_working_fcntl_h" >&6; }
9433 case $gl_cv_header_working_fcntl_h in #(
9434 *O_NOATIME
* | no | cross-compiling
) ac_val
=0;; #(
9438 cat >>confdefs.h
<<_ACEOF
9439 #define HAVE_WORKING_O_NOATIME $ac_val
9443 case $gl_cv_header_working_fcntl_h in #(
9444 *O_NOFOLLOW
* | no | cross-compiling
) ac_val
=0;; #(
9448 cat >>confdefs.h
<<_ACEOF
9449 #define HAVE_WORKING_O_NOFOLLOW $ac_val
9454 ac_fn_c_check_type
"$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default
9456 if test "x$ac_cv_type_pid_t" = xyes
; then :
9459 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
9460 /* end confdefs.h. */
9462 #if defined _WIN64 && !defined __CYGWIN__
9475 if ac_fn_c_try_compile
"$LINENO"; then :
9478 gl_pid_type
='__int64'
9480 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
9482 cat >>confdefs.h
<<_ACEOF
9483 #define pid_t $gl_pid_type
9490 ac_fn_c_check_type
"$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
9491 if test "x$ac_cv_type_mode_t" = xyes
; then :
9495 cat >>confdefs.h
<<_ACEOF
9507 HAVE_DECL_STRNCASECMP
=1;
9531 if test $gl_cv_have_include_next = yes; then
9532 gl_cv_next_fnmatch_h
='<'fnmatch.h
'>'
9534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <fnmatch.h>" >&5
9535 $as_echo_n "checking absolute name of <fnmatch.h>... " >&6; }
9536 if ${gl_cv_next_fnmatch_h+:} false
; then :
9537 $as_echo_n "(cached) " >&6
9540 if test $ac_cv_header_fnmatch_h = yes; then
9545 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
9546 /* end confdefs.h. */
9547 #include <fnmatch.h>
9550 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
9551 *) gl_absname_cpp
="$ac_cpp" ;;
9556 gl_dirsep_regex
='[/\\]'
9559 gl_dirsep_regex
='\/'
9562 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
9563 gl_header_literal_regex
=`echo 'fnmatch.h' \
9564 | sed -e "$gl_make_literal_regex_sed"`
9565 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
9566 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
9572 gl_cv_absolute_fnmatch_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
9573 sed -n "$gl_absolute_header_sed"`
9575 gl_header
=$gl_cv_absolute_fnmatch_h
9576 gl_cv_next_fnmatch_h
='"'$gl_header'"'
9578 gl_cv_next_fnmatch_h
='<'fnmatch.h
'>'
9583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_fnmatch_h" >&5
9584 $as_echo "$gl_cv_next_fnmatch_h" >&6; }
9586 NEXT_FNMATCH_H
=$gl_cv_next_fnmatch_h
9588 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
9589 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
9590 gl_next_as_first_directive
='<'fnmatch.h
'>'
9592 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
9593 gl_next_as_first_directive
=$gl_cv_next_fnmatch_h
9595 NEXT_AS_FIRST_DIRECTIVE_FNMATCH_H
=$gl_next_as_first_directive
9603 if test $ac_cv_header_fnmatch_h = yes; then
9614 if test $ac_cv_header_fnmatch_h != yes; then
9620 if test -n "$FNMATCH_H"; then
9621 GL_GENERATE_FNMATCH_H_TRUE
=
9622 GL_GENERATE_FNMATCH_H_FALSE
='#'
9624 GL_GENERATE_FNMATCH_H_TRUE
='#'
9625 GL_GENERATE_FNMATCH_H_FALSE
=
9637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
9638 $as_echo_n "checking for mbstate_t... " >&6; }
9639 if ${ac_cv_type_mbstate_t+:} false
; then :
9640 $as_echo_n "(cached) " >&6
9642 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
9643 /* end confdefs.h. */
9644 $ac_includes_default
9649 mbstate_t x; return sizeof x;
9654 if ac_fn_c_try_compile
"$LINENO"; then :
9655 ac_cv_type_mbstate_t
=yes
9657 ac_cv_type_mbstate_t
=no
9659 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
9661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
9662 $as_echo "$ac_cv_type_mbstate_t" >&6; }
9663 if test $ac_cv_type_mbstate_t = yes; then
9665 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
9669 $as_echo "#define mbstate_t int" >>confdefs.h
9751 GNULIB_REMAINDERF
=0;
9752 GNULIB_REMAINDERL
=0;
9844 HAVE_DECL_COPYSIGNF
=1;
9861 HAVE_DECL_REMAINDER
=1;
9862 HAVE_DECL_REMAINDERL
=1;
9934 REPLACE_REMAINDER
=0;
9935 REPLACE_REMAINDERF
=0;
9936 REPLACE_REMAINDERL
=0;
9942 REPLACE_SIGNBIT_USING_BUILTINS
=0;
9954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexp() can be used without linking with libm" >&5
9955 $as_echo_n "checking whether frexp() can be used without linking with libm... " >&6; }
9956 if ${gl_cv_func_frexp_no_libm+:} false
; then :
9957 $as_echo_n "(cached) " >&6
9960 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
9961 /* end confdefs.h. */
9967 int e; return frexp (x, &e) > 0;
9972 if ac_fn_c_try_link
"$LINENO"; then :
9973 gl_cv_func_frexp_no_libm
=yes
9975 gl_cv_func_frexp_no_libm
=no
9977 rm -f core conftest.err conftest.
$ac_objext \
9978 conftest
$ac_exeext conftest.
$ac_ext
9981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexp_no_libm" >&5
9982 $as_echo "$gl_cv_func_frexp_no_libm" >&6; }
9984 ac_fn_c_check_decl
"$LINENO" "alarm" "ac_cv_have_decl_alarm" "$ac_includes_default"
9985 if test "x$ac_cv_have_decl_alarm" = xyes
; then :
9991 cat >>confdefs.h
<<_ACEOF
9992 #define HAVE_DECL_ALARM $ac_have_decl
9999 if test $gl_cv_func_frexp_no_libm = no
; then
10000 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexp() can be used with libm" >&5
10001 $as_echo_n "checking whether frexp() can be used with libm... " >&6; }
10002 if ${gl_cv_func_frexp_in_libm+:} false
; then :
10003 $as_echo_n "(cached) " >&6
10008 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
10009 /* end confdefs.h. */
10015 int e; return frexp (x, &e) > 0;
10020 if ac_fn_c_try_link
"$LINENO"; then :
10021 gl_cv_func_frexp_in_libm
=yes
10023 gl_cv_func_frexp_in_libm
=no
10025 rm -f core conftest.err conftest.
$ac_objext \
10026 conftest
$ac_exeext conftest.
$ac_ext
10030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexp_in_libm" >&5
10031 $as_echo "$gl_cv_func_frexp_in_libm" >&6; }
10032 if test $gl_cv_func_frexp_in_libm = yes; then
10036 if test $gl_cv_func_frexp_no_libm = yes \
10037 ||
test $gl_cv_func_frexp_in_libm = yes; then
10039 LIBS
="$LIBS $FREXP_LIBM"
10043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexp works" >&5
10044 $as_echo_n "checking whether frexp works... " >&6; }
10045 if ${gl_cv_func_frexp_works+:} false
; then :
10046 $as_echo_n "(cached) " >&6
10049 if test "$cross_compiling" = yes; then :
10051 netbsd
* | irix
*) gl_cv_func_frexp_works
="guessing no" ;;
10052 mingw
*) # Guess yes with MSVC, no with mingw.
10053 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
10054 /* end confdefs.h. */
10061 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10062 $EGREP "Good" >/dev
/null
2>&1; then :
10063 gl_cv_func_frexp_works
="guessing yes"
10065 gl_cv_func_frexp_works
="guessing no"
10070 *) gl_cv_func_frexp_works
="guessing yes" ;;
10074 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
10075 /* end confdefs.h. */
10079 #include <string.h>
10080 #if HAVE_DECL_ALARM
10081 # include <signal.h>
10082 # include <unistd.h>
10084 /* HP cc on HP-UX 10.20 has a bug with the constant expression -0.0.
10085 ICC 10.0 has a bug when optimizing the expression -zero.
10086 The expression -DBL_MIN * DBL_MIN does not work when cross-compiling
10087 to PowerPC on Mac OS X 10.5. */
10088 #if defined __hpux || defined __sgi || defined __ICC
10090 compute_minus_zero (void)
10092 return -DBL_MIN * DBL_MIN;
10094 # define minus_zero compute_minus_zero ()
10096 double minus_zero = -0.0;
10104 #if HAVE_DECL_ALARM
10105 /* NeXTstep 3.3 frexp() runs into an endless loop when called on an infinite
10106 number. Let the test fail in this case. */
10107 signal (SIGALRM, SIG_DFL);
10110 /* Test on denormalized numbers. */
10111 for (i = 1, x = 1.0; i >= DBL_MIN_EXP; i--, x *= 0.5)
10116 double y = frexp (x, &exp);
10117 /* On machines with IEEE754 arithmetic: x = 1.11254e-308, exp = -1022.
10118 On NetBSD: y = 0.75. Correct: y = 0.5. */
10122 /* Test on infinite numbers. */
10126 double y = frexp (x, &exp);
10130 /* Test on negative zero. */
10134 double y = frexp (x, &exp);
10135 if (memcmp (&y, &x, sizeof x))
10141 if ac_fn_c_try_run
"$LINENO"; then :
10142 gl_cv_func_frexp_works
=yes
10144 gl_cv_func_frexp_works
=no
10146 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
10147 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
10152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexp_works" >&5
10153 $as_echo "$gl_cv_func_frexp_works" >&6; }
10156 case "$gl_cv_func_frexp_works" in
10157 *yes) gl_func_frexp
=yes ;;
10158 *) gl_func_frexp
=no
; REPLACE_FREXP
=1; FREXP_LIBM
= ;;
10163 if test $gl_func_frexp = yes; then
10165 $as_echo "#define HAVE_FREXP 1" >>confdefs.h
10171 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether long double and double are the same" >&5
10172 $as_echo_n "checking whether long double and double are the same... " >&6; }
10173 if ${gl_cv_long_double_equals_double+:} false
; then :
10174 $as_echo_n "(cached) " >&6
10176 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
10177 /* end confdefs.h. */
10182 typedef int check[sizeof (long double) == sizeof (double)
10183 && LDBL_MANT_DIG == DBL_MANT_DIG
10184 && LDBL_MAX_EXP == DBL_MAX_EXP
10185 && LDBL_MIN_EXP == DBL_MIN_EXP
10192 if ac_fn_c_try_compile
"$LINENO"; then :
10193 gl_cv_long_double_equals_double
=yes
10195 gl_cv_long_double_equals_double
=no
10197 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
10200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_long_double_equals_double" >&5
10201 $as_echo "$gl_cv_long_double_equals_double" >&6; }
10202 if test $gl_cv_long_double_equals_double = yes; then
10204 $as_echo "#define HAVE_SAME_LONG_DOUBLE_AS_DOUBLE 1" >>confdefs.h
10206 HAVE_SAME_LONG_DOUBLE_AS_DOUBLE
=1
10208 HAVE_SAME_LONG_DOUBLE_AS_DOUBLE
=0
10218 ac_fn_c_check_decl
"$LINENO" "frexpl" "ac_cv_have_decl_frexpl" "#include <math.h>
10220 if test "x$ac_cv_have_decl_frexpl" = xyes
; then :
10228 if test $HAVE_DECL_FREXPL = 1; then
10230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexpl() can be used without linking with libm" >&5
10231 $as_echo_n "checking whether frexpl() can be used without linking with libm... " >&6; }
10232 if ${gl_cv_func_frexpl_no_libm+:} false
; then :
10233 $as_echo_n "(cached) " >&6
10236 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
10237 /* end confdefs.h. */
10243 int e; return frexpl (x, &e) > 0;
10248 if ac_fn_c_try_link
"$LINENO"; then :
10249 gl_cv_func_frexpl_no_libm
=yes
10251 gl_cv_func_frexpl_no_libm
=no
10253 rm -f core conftest.err conftest.
$ac_objext \
10254 conftest
$ac_exeext conftest.
$ac_ext
10257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexpl_no_libm" >&5
10258 $as_echo "$gl_cv_func_frexpl_no_libm" >&6; }
10260 if test $gl_cv_func_frexpl_no_libm = no
; then
10261 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexpl() can be used with libm" >&5
10262 $as_echo_n "checking whether frexpl() can be used with libm... " >&6; }
10263 if ${gl_cv_func_frexpl_in_libm+:} false
; then :
10264 $as_echo_n "(cached) " >&6
10269 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
10270 /* end confdefs.h. */
10276 int e; return frexpl (x, &e) > 0;
10281 if ac_fn_c_try_link
"$LINENO"; then :
10282 gl_cv_func_frexpl_in_libm
=yes
10284 gl_cv_func_frexpl_in_libm
=no
10286 rm -f core conftest.err conftest.
$ac_objext \
10287 conftest
$ac_exeext conftest.
$ac_ext
10291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexpl_in_libm" >&5
10292 $as_echo "$gl_cv_func_frexpl_in_libm" >&6; }
10293 if test $gl_cv_func_frexpl_in_libm = yes; then
10297 if test $gl_cv_func_frexpl_no_libm = yes \
10298 ||
test $gl_cv_func_frexpl_in_libm = yes; then
10300 LIBS
="$LIBS $FREXPL_LIBM"
10303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexpl works" >&5
10304 $as_echo_n "checking whether frexpl works... " >&6; }
10305 if ${gl_cv_func_frexpl_works+:} false
; then :
10306 $as_echo_n "(cached) " >&6
10309 if test "$cross_compiling" = yes; then :
10312 aix | aix
[3-6]* | beos
* | darwin
* | irix
* | mingw
* | pw
*)
10313 gl_cv_func_frexpl_works
="guessing no";;
10314 *) gl_cv_func_frexpl_works
="guessing yes";;
10318 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
10319 /* end confdefs.h. */
10323 /* Override the values of <float.h>, like done in float.in.h. */
10324 #if defined __i386__ && (defined __BEOS__ || defined __OpenBSD__)
10325 # undef LDBL_MIN_EXP
10326 # define LDBL_MIN_EXP (-16381)
10328 #if defined __i386__ && (defined __FreeBSD__ || defined __DragonFly__)
10329 # undef LDBL_MIN_EXP
10330 # define LDBL_MIN_EXP (-16381)
10332 #if (defined _ARCH_PPC || defined _POWER) && defined _AIX && (LDBL_MANT_DIG == 106) && defined __GNUC__
10333 # undef LDBL_MIN_EXP
10334 # define LDBL_MIN_EXP DBL_MIN_EXP
10336 #if defined __sgi && (LDBL_MANT_DIG >= 106)
10337 # if defined __GNUC__
10338 # undef LDBL_MIN_EXP
10339 # define LDBL_MIN_EXP DBL_MIN_EXP
10346 long double frexpl (long double, int *);
10347 long double zero = 0.0L;
10351 volatile long double x;
10352 /* Test on finite numbers that fails on AIX 5.1. */
10360 /* Test on finite numbers that fails on Mac OS X 10.4, because its frexpl
10361 function returns an invalid (incorrectly normalized) value: it returns
10362 y = { 0x3fe028f5, 0xc28f5c28, 0x3c9eb851, 0xeb851eb8 }
10363 but the correct result is
10364 0.505L = { 0x3fe028f5, 0xc28f5c29, 0xbc547ae1, 0x47ae1480 } */
10368 long double y = frexpl (x, &exp);
10369 if (!(exp == 1 && y == 0.505L))
10372 /* Test on large finite numbers. This fails on BeOS at i = 16322, while
10373 LDBL_MAX_EXP = 16384.
10374 In the loop end test, we test x against Infinity, rather than comparing
10375 i with LDBL_MAX_EXP, because BeOS <float.h> has a wrong LDBL_MAX_EXP. */
10378 for (i = 1, x = 1.0L; x != x + x; i++, x *= 2.0L)
10389 /* Test on denormalized numbers. */
10392 for (i = 1, x = 1.0L; i >= LDBL_MIN_EXP; i--, x *= 0.5L)
10397 long double y = frexpl (x, &exp);
10398 /* On machines with IEEE854 arithmetic: x = 1.68105e-4932,
10399 exp = -16382, y = 0.5. On Mac OS X 10.5: exp = -16384, y = 0.5. */
10400 if (exp != LDBL_MIN_EXP - 1)
10404 /* Test on infinite numbers. */
10405 /* The Microsoft MSVC 14 compiler chokes on the expression 1.0 / 0.0. */
10409 long double y = frexpl (x, &exp);
10416 if ac_fn_c_try_run
"$LINENO"; then :
10417 gl_cv_func_frexpl_works
=yes
10419 gl_cv_func_frexpl_works
=no
10421 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
10422 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
10427 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexpl_works" >&5
10428 $as_echo "$gl_cv_func_frexpl_works" >&6; }
10431 case "$gl_cv_func_frexpl_works" in
10432 *yes) gl_func_frexpl
=yes ;;
10433 *) gl_func_frexpl
=no
; REPLACE_FREXPL
=1 ;;
10438 if test $gl_func_frexpl = yes; then
10440 $as_echo "#define HAVE_FREXPL 1" >>confdefs.h
10444 if test $HAVE_DECL_FREXPL = 0 ||
test $gl_func_frexpl = no
; then
10445 if test $HAVE_SAME_LONG_DOUBLE_AS_DOUBLE = 1; then
10447 FREXPL_LIBM
="$FREXP_LIBM"
10469 GNULIB_UTIMENSAT
=0;
10470 GNULIB_OVERRIDES_STRUCT_STAT
=0;
10471 GNULIB_MDA_CHMOD
=1;
10472 GNULIB_MDA_MKDIR
=1;
10473 GNULIB_MDA_UMASK
=1;
10486 REPLACE_FCHMODAT
=0;
10489 REPLACE_FUTIMENS
=0;
10493 REPLACE_MKFIFOAT
=0;
10497 REPLACE_UTIMENSAT
=0;
10499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
10500 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
10501 if ${ac_cv_header_stat_broken+:} false
; then :
10502 $as_echo_n "(cached) " >&6
10504 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
10505 /* end confdefs.h. */
10506 #include <sys/types.h>
10507 #include <sys/stat.h>
10509 #if defined S_ISBLK && defined S_IFDIR
10510 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
10513 #if defined S_ISBLK && defined S_IFCHR
10514 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
10517 #if defined S_ISLNK && defined S_IFREG
10518 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
10521 #if defined S_ISSOCK && defined S_IFREG
10522 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
10526 if ac_fn_c_try_compile
"$LINENO"; then :
10527 ac_cv_header_stat_broken
=no
10529 ac_cv_header_stat_broken
=yes
10531 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
10533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
10534 $as_echo "$ac_cv_header_stat_broken" >&6; }
10535 if test $ac_cv_header_stat_broken = yes; then
10537 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
10547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
10548 $as_echo_n "checking for 64-bit off_t... " >&6; }
10549 if ${gl_cv_type_off_t_64+:} false
; then :
10550 $as_echo_n "(cached) " >&6
10552 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
10553 /* end confdefs.h. */
10554 #include <sys/types.h>
10555 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
10565 if ac_fn_c_try_compile
"$LINENO"; then :
10566 gl_cv_type_off_t_64
=yes
10568 gl_cv_type_off_t_64
=no
10570 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
10573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
10574 $as_echo "$gl_cv_type_off_t_64" >&6; }
10575 if test $gl_cv_type_off_t_64 = no
; then
10576 WINDOWS_64_BIT_OFF_T
=1
10578 WINDOWS_64_BIT_OFF_T
=0
10580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit st_size" >&5
10581 $as_echo_n "checking for 64-bit st_size... " >&6; }
10582 if ${gl_cv_member_st_size_64+:} false
; then :
10583 $as_echo_n "(cached) " >&6
10585 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
10586 /* end confdefs.h. */
10587 #include <sys/types.h>
10589 int verify_st_size_size[sizeof (buf.st_size) >= 8 ? 1 : -1];
10599 if ac_fn_c_try_compile
"$LINENO"; then :
10600 gl_cv_member_st_size_64
=yes
10602 gl_cv_member_st_size_64
=no
10604 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
10607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_member_st_size_64" >&5
10608 $as_echo "$gl_cv_member_st_size_64" >&6; }
10609 if test $gl_cv_member_st_size_64 = no
; then
10610 WINDOWS_64_BIT_ST_SIZE
=1
10612 WINDOWS_64_BIT_ST_SIZE
=0
10616 WINDOWS_64_BIT_OFF_T
=0
10617 WINDOWS_64_BIT_ST_SIZE
=0
10621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
10622 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
10623 if ${ac_cv_c_restrict+:} false
; then :
10624 $as_echo_n "(cached) " >&6
10626 ac_cv_c_restrict
=no
10627 # Put '__restrict__' first, to avoid problems with glibc and non-GCC; see:
10628 # https://lists.gnu.org/archive/html/bug-autoconf/2016-02/msg00006.html
10629 # Put 'restrict' last, because C++ lacks it.
10630 for ac_kw
in __restrict__ __restrict _Restrict restrict
; do
10631 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
10632 /* end confdefs.h. */
10633 typedef int *int_ptr;
10634 int foo (int_ptr $ac_kw ip) { return ip[0]; }
10635 int bar (int [$ac_kw]); /* Catch GCC bug 14050. */
10636 int bar (int ip[$ac_kw]) { return ip[0]; }
10644 return foo (t) + bar (t);
10650 if ac_fn_c_try_compile
"$LINENO"; then :
10651 ac_cv_c_restrict
=$ac_kw
10653 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
10654 test "$ac_cv_c_restrict" != no
&& break
10658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
10659 $as_echo "$ac_cv_c_restrict" >&6; }
10661 case $ac_cv_c_restrict in
10663 no
) $as_echo "#define restrict /**/" >>confdefs.h
10665 *) cat >>confdefs.h
<<_ACEOF
10666 #define restrict $ac_cv_c_restrict
10685 if test $gl_cv_have_include_next = yes; then
10686 gl_cv_next_sys_stat_h
='<'sys
/stat.h
'>'
10688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
10689 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
10690 if ${gl_cv_next_sys_stat_h+:} false
; then :
10691 $as_echo_n "(cached) " >&6
10694 if test $ac_cv_header_sys_stat_h = yes; then
10699 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
10700 /* end confdefs.h. */
10701 #include <sys/stat.h>
10704 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
10705 *) gl_absname_cpp
="$ac_cpp" ;;
10710 gl_dirsep_regex
='[/\\]'
10713 gl_dirsep_regex
='\/'
10716 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
10717 gl_header_literal_regex
=`echo 'sys/stat.h' \
10718 | sed -e "$gl_make_literal_regex_sed"`
10719 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
10720 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
10726 gl_cv_absolute_sys_stat_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
10727 sed -n "$gl_absolute_header_sed"`
10729 gl_header
=$gl_cv_absolute_sys_stat_h
10730 gl_cv_next_sys_stat_h
='"'$gl_header'"'
10732 gl_cv_next_sys_stat_h
='<'sys
/stat.h
'>'
10737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
10738 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
10740 NEXT_SYS_STAT_H
=$gl_cv_next_sys_stat_h
10742 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
10743 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
10744 gl_next_as_first_directive
='<'sys
/stat.h
'>'
10746 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
10747 gl_next_as_first_directive
=$gl_cv_next_sys_stat_h
10749 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
=$gl_next_as_first_directive
10758 WINDOWS_STAT_TIMESPEC
=0
10767 ac_fn_c_check_type
"$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
10768 #include <sys/stat.h>
10770 if test "x$ac_cv_type_nlink_t" = xyes
; then :
10774 $as_echo "#define nlink_t int" >>confdefs.h
10789 for ac_header
in sdkddkver.h
10791 ac_fn_c_check_header_mongrel
"$LINENO" "sdkddkver.h" "ac_cv_header_sdkddkver_h" "$ac_includes_default"
10792 if test "x$ac_cv_header_sdkddkver_h" = xyes
; then :
10793 cat >>confdefs.h
<<_ACEOF
10794 #define HAVE_SDKDDKVER_H 1
10808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getcwd (NULL, 0) allocates memory for result" >&5
10809 $as_echo_n "checking whether getcwd (NULL, 0) allocates memory for result... " >&6; }
10810 if ${gl_cv_func_getcwd_null+:} false
; then :
10811 $as_echo_n "(cached) " >&6
10813 if test "$cross_compiling" = yes; then :
10815 # Guess yes on glibc systems.
10816 *-gnu* | gnu
*) gl_cv_func_getcwd_null
="guessing yes";;
10817 # Guess yes on musl systems.
10818 *-musl*) gl_cv_func_getcwd_null
="guessing yes";;
10819 # Guess yes on Cygwin.
10820 cygwin
*) gl_cv_func_getcwd_null
="guessing yes";;
10821 # If we don't know, obey --enable-cross-guesses.
10822 *) gl_cv_func_getcwd_null
="$gl_cross_guess_normal";;
10826 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
10827 /* end confdefs.h. */
10829 # include <stdlib.h>
10831 # include <unistd.h>
10832 # else /* on Windows with MSVC */
10833 # include <direct.h>
10847 #if defined _WIN32 && ! defined __CYGWIN__
10848 /* mingw cwd does not start with '/', but _getcwd does allocate.
10849 However, mingw fails to honor non-zero size. */
10851 if (chdir ("/") != 0)
10855 char *f = getcwd (NULL, 0);
10859 { free (f); return 3; }
10861 { free (f); return 4; }
10871 if ac_fn_c_try_run
"$LINENO"; then :
10872 gl_cv_func_getcwd_null
=yes
10874 gl_cv_func_getcwd_null
=no
10876 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
10877 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
10881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_null" >&5
10882 $as_echo "$gl_cv_func_getcwd_null" >&6; }
10885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getcwd with POSIX signature" >&5
10886 $as_echo_n "checking for getcwd with POSIX signature... " >&6; }
10887 if ${gl_cv_func_getcwd_posix_signature+:} false
; then :
10888 $as_echo_n "(cached) " >&6
10890 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
10891 /* end confdefs.h. */
10892 #include <unistd.h>
10904 char *getcwd (char *, size_t);
10911 if ac_fn_c_try_compile
"$LINENO"; then :
10912 gl_cv_func_getcwd_posix_signature
=yes
10914 gl_cv_func_getcwd_posix_signature
=no
10916 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
10919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_posix_signature" >&5
10920 $as_echo "$gl_cv_func_getcwd_posix_signature" >&6; }
10922 ac_fn_c_check_decl
"$LINENO" "getcwd" "ac_cv_have_decl_getcwd" "$ac_includes_default"
10923 if test "x$ac_cv_have_decl_getcwd" = xyes
; then :
10929 cat >>confdefs.h
<<_ACEOF
10930 #define HAVE_DECL_GETCWD $ac_have_decl
10942 GNULIB_FPRINTF_POSIX
=0;
10958 GNULIB_OBSTACK_PRINTF
=0;
10959 GNULIB_OBSTACK_PRINTF_POSIX
=0;
10964 GNULIB_PRINTF_POSIX
=0;
10973 GNULIB_SPRINTF_POSIX
=0;
10974 GNULIB_STDIO_H_NONBLOCKING
=0;
10975 GNULIB_STDIO_H_SIGPIPE
=0;
10977 GNULIB_VASPRINTF
=0;
10982 GNULIB_VFPRINTF_POSIX
=0;
10984 GNULIB_VPRINTF_POSIX
=0;
10985 GNULIB_VSNPRINTF
=0;
10986 GNULIB_VSPRINTF_POSIX
=0;
10987 GNULIB_MDA_FCLOSEALL
=1;
10988 GNULIB_MDA_FDOPEN
=1;
10989 GNULIB_MDA_FILENO
=1;
10992 GNULIB_MDA_TEMPNAM
=1;
10993 HAVE_DECL_FCLOSEALL
=1;
10994 HAVE_DECL_FPURGE
=1;
10995 HAVE_DECL_FSEEKO
=1;
10996 HAVE_DECL_FTELLO
=1;
10997 HAVE_DECL_GETDELIM
=1;
10998 HAVE_DECL_GETLINE
=1;
10999 HAVE_DECL_OBSTACK_PRINTF
=1;
11000 HAVE_DECL_SNPRINTF
=1;
11001 HAVE_DECL_VSNPRINTF
=1;
11022 REPLACE_GETDELIM
=0;
11024 REPLACE_OBSTACK_PRINTF
=0;
11030 REPLACE_RENAMEAT
=0;
11031 REPLACE_SNPRINTF
=0;
11033 REPLACE_STDIO_READ_FUNCS
=0;
11034 REPLACE_STDIO_WRITE_FUNCS
=0;
11036 REPLACE_VASPRINTF
=0;
11037 REPLACE_VDPRINTF
=0;
11038 REPLACE_VFPRINTF
=0;
11040 REPLACE_VSNPRINTF
=0;
11041 REPLACE_VSPRINTF
=0;
11043 ac_fn_c_check_decl
"$LINENO" "getdelim" "ac_cv_have_decl_getdelim" "$ac_includes_default"
11044 if test "x$ac_cv_have_decl_getdelim" = xyes
; then :
11050 cat >>confdefs.h
<<_ACEOF
11051 #define HAVE_DECL_GETDELIM $ac_have_decl
11058 ac_fn_c_check_decl
"$LINENO" "getdtablesize" "ac_cv_have_decl_getdtablesize" "$ac_includes_default"
11059 if test "x$ac_cv_have_decl_getdtablesize" = xyes
; then :
11065 cat >>confdefs.h
<<_ACEOF
11066 #define HAVE_DECL_GETDTABLESIZE $ac_have_decl
11069 ac_fn_c_check_decl
"$LINENO" "getline" "ac_cv_have_decl_getline" "$ac_includes_default"
11070 if test "x$ac_cv_have_decl_getline" = xyes
; then :
11076 cat >>confdefs.h
<<_ACEOF
11077 #define HAVE_DECL_GETLINE $ac_have_decl
11080 ac_fn_c_check_decl
"$LINENO" "getlogin_r" "ac_cv_have_decl_getlogin_r" "$ac_includes_default"
11081 if test "x$ac_cv_have_decl_getlogin_r" = xyes
; then :
11087 cat >>confdefs.h
<<_ACEOF
11088 #define HAVE_DECL_GETLOGIN_R $ac_have_decl
11093 ac_fn_c_check_decl
"$LINENO" "getlogin" "ac_cv_have_decl_getlogin" "$ac_includes_default"
11094 if test "x$ac_cv_have_decl_getlogin" = xyes
; then :
11100 cat >>confdefs.h
<<_ACEOF
11101 #define HAVE_DECL_GETLOGIN $ac_have_decl
11108 LIB_GETLOGIN
='-ladvapi32' ;;
11119 GNULIB_GETRANDOM
=0;
11121 REPLACE_GETRANDOM
=0;
11126 GNULIB_GETTIMEOFDAY
=0;
11127 HAVE_GETTIMEOFDAY
=1;
11128 HAVE_STRUCT_TIMEVAL
=1;
11130 REPLACE_GETTIMEOFDAY
=0;
11131 REPLACE_STRUCT_TIMEVAL
=0;
11148 if test $gl_cv_have_include_next = yes; then
11149 gl_cv_next_sys_time_h
='<'sys
/time.h
'>'
11151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
11152 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
11153 if ${gl_cv_next_sys_time_h+:} false
; then :
11154 $as_echo_n "(cached) " >&6
11157 if test $ac_cv_header_sys_time_h = yes; then
11162 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
11163 /* end confdefs.h. */
11164 #include <sys/time.h>
11167 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
11168 *) gl_absname_cpp
="$ac_cpp" ;;
11173 gl_dirsep_regex
='[/\\]'
11176 gl_dirsep_regex
='\/'
11179 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
11180 gl_header_literal_regex
=`echo 'sys/time.h' \
11181 | sed -e "$gl_make_literal_regex_sed"`
11182 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
11183 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
11189 gl_cv_absolute_sys_time_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
11190 sed -n "$gl_absolute_header_sed"`
11192 gl_header
=$gl_cv_absolute_sys_time_h
11193 gl_cv_next_sys_time_h
='"'$gl_header'"'
11195 gl_cv_next_sys_time_h
='<'sys
/time.h
'>'
11200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
11201 $as_echo "$gl_cv_next_sys_time_h" >&6; }
11203 NEXT_SYS_TIME_H
=$gl_cv_next_sys_time_h
11205 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
11206 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
11207 gl_next_as_first_directive
='<'sys
/time.h
'>'
11209 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
11210 gl_next_as_first_directive
=$gl_cv_next_sys_time_h
11212 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
=$gl_next_as_first_directive
11218 if test $ac_cv_header_sys_time_h != yes; then
11226 if test $ac_cv_header_sys_socket_h != yes; then
11227 for ac_header
in winsock2.h
11229 ac_fn_c_check_header_mongrel
"$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
11230 if test "x$ac_cv_header_winsock2_h" = xyes
; then :
11231 cat >>confdefs.h
<<_ACEOF
11232 #define HAVE_WINSOCK2_H 1
11240 if test "$ac_cv_header_winsock2_h" = yes; then
11242 UNISTD_H_HAVE_WINSOCK2_H
=1
11243 SYS_IOCTL_H_HAVE_WINSOCK2_H
=1
11249 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
11250 $as_echo_n "checking for struct timeval... " >&6; }
11251 if ${gl_cv_sys_struct_timeval+:} false
; then :
11252 $as_echo_n "(cached) " >&6
11254 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
11255 /* end confdefs.h. */
11256 #if HAVE_SYS_TIME_H
11257 #include <sys/time.h>
11260 #if HAVE_WINSOCK2_H
11261 # include <winsock2.h>
11267 static struct timeval x; x.tv_sec = x.tv_usec;
11272 if ac_fn_c_try_compile
"$LINENO"; then :
11273 gl_cv_sys_struct_timeval
=yes
11275 gl_cv_sys_struct_timeval
=no
11277 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
11280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
11281 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
11282 if test $gl_cv_sys_struct_timeval != yes; then
11283 HAVE_STRUCT_TIMEVAL
=0
11285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
11286 $as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
11287 if ${gl_cv_sys_struct_timeval_tv_sec+:} false
; then :
11288 $as_echo_n "(cached) " >&6
11290 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
11291 /* end confdefs.h. */
11292 #if HAVE_SYS_TIME_H
11293 #include <sys/time.h>
11296 #if HAVE_WINSOCK2_H
11297 # include <winsock2.h>
11303 static struct timeval x;
11304 typedef int verify_tv_sec_type[
11305 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
11312 if ac_fn_c_try_compile
"$LINENO"; then :
11313 gl_cv_sys_struct_timeval_tv_sec
=yes
11315 gl_cv_sys_struct_timeval_tv_sec
=no
11317 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
11320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
11321 $as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
11322 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
11323 REPLACE_STRUCT_TIMEVAL
=1
11339 HAVE_GLOB_PATTERN_P
=1;
11341 REPLACE_GLOB_PATTERN_P
=0;
11359 if test $gl_cv_have_include_next = yes; then
11360 gl_cv_next_glob_h
='<'glob.h
'>'
11362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <glob.h>" >&5
11363 $as_echo_n "checking absolute name of <glob.h>... " >&6; }
11364 if ${gl_cv_next_glob_h+:} false
; then :
11365 $as_echo_n "(cached) " >&6
11368 if test $ac_cv_header_glob_h = yes; then
11373 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
11374 /* end confdefs.h. */
11378 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
11379 *) gl_absname_cpp
="$ac_cpp" ;;
11384 gl_dirsep_regex
='[/\\]'
11387 gl_dirsep_regex
='\/'
11390 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
11391 gl_header_literal_regex
=`echo 'glob.h' \
11392 | sed -e "$gl_make_literal_regex_sed"`
11393 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
11394 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
11400 gl_cv_absolute_glob_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
11401 sed -n "$gl_absolute_header_sed"`
11403 gl_header
=$gl_cv_absolute_glob_h
11404 gl_cv_next_glob_h
='"'$gl_header'"'
11406 gl_cv_next_glob_h
='<'glob.h
'>'
11411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_glob_h" >&5
11412 $as_echo "$gl_cv_next_glob_h" >&6; }
11414 NEXT_GLOB_H
=$gl_cv_next_glob_h
11416 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
11417 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
11418 gl_next_as_first_directive
='<'glob.h
'>'
11420 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
11421 gl_next_as_first_directive
=$gl_cv_next_glob_h
11423 NEXT_AS_FIRST_DIRECTIVE_GLOB_H
=$gl_next_as_first_directive
11429 if test $ac_cv_header_glob_h = yes; then
11440 if test $ac_cv_header_glob_h != yes; then
11446 if test -n "$GLOB_H"; then
11447 GL_GENERATE_GLOB_H_TRUE
=
11448 GL_GENERATE_GLOB_H_FALSE
='#'
11450 GL_GENERATE_GLOB_H_TRUE
='#'
11451 GL_GENERATE_GLOB_H_FALSE
=
11469 if test -z "$gl_pthreadlib_body_done"; then
11473 # On OSF/1, the compiler needs the flag -pthread or -D_REENTRANT so that
11474 # it groks <pthread.h>. It's added above, in gl_ANYTHREADLIB_EARLY.
11475 ac_fn_c_check_header_mongrel
"$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
11476 if test "x$ac_cv_header_pthread_h" = xyes
; then :
11477 gl_have_pthread_h
=yes
11479 gl_have_pthread_h
=no
11483 if test "$gl_have_pthread_h" = yes; then
11484 # Other possible tests:
11485 # -lpthreads (FSU threads, PCthreads)
11487 # Test whether both pthread_mutex_lock and pthread_mutexattr_init exist
11488 # in libc. IRIX 6.5 has the first one in both libc and libpthread, but
11489 # the second one only in libpthread, and lock.c needs it.
11491 # If -pthread works, prefer it to -lpthread, since Ubuntu 14.04
11492 # needs -pthread for some reason. See:
11493 # https://lists.gnu.org/r/bug-gnulib/2014-09/msg00023.html
11495 for gl_pthread
in '' '-pthread'; do
11496 LIBS
="$LIBS $gl_pthread"
11497 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
11498 /* end confdefs.h. */
11499 #include <pthread.h>
11501 pthread_mutexattr_t ma;
11506 pthread_mutex_lock (&m);
11507 pthread_mutexattr_init (&ma);
11512 if ac_fn_c_try_link
"$LINENO"; then :
11514 LIBPTHREAD
=$gl_pthread
11515 LIBPMULTITHREAD
=$gl_pthread
11517 rm -f core conftest.err conftest.
$ac_objext \
11518 conftest
$ac_exeext conftest.
$ac_ext
11520 test $gl_pthread_api = yes && break
11523 # Test for libpthread by looking for pthread_kill. (Not pthread_self,
11524 # since it is defined as a macro on OSF/1.)
11525 if test $gl_pthread_api = yes && test -z "$LIBPTHREAD"; then
11526 # The program links fine without libpthread. But it may actually
11527 # need to link with libpthread in order to create multiple threads.
11528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lpthread" >&5
11529 $as_echo_n "checking for pthread_kill in -lpthread... " >&6; }
11530 if ${ac_cv_lib_pthread_pthread_kill+:} false
; then :
11531 $as_echo_n "(cached) " >&6
11533 ac_check_lib_save_LIBS
=$LIBS
11534 LIBS
="-lpthread $LIBS"
11535 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
11536 /* end confdefs.h. */
11538 /* Override any GCC internal prototype to avoid an error.
11539 Use char because int might match the return type of a GCC
11540 builtin and then its argument prototype would still apply. */
11544 char pthread_kill ();
11548 return pthread_kill ();
11553 if ac_fn_c_try_link
"$LINENO"; then :
11554 ac_cv_lib_pthread_pthread_kill
=yes
11556 ac_cv_lib_pthread_pthread_kill
=no
11558 rm -f core conftest.err conftest.
$ac_objext \
11559 conftest
$ac_exeext conftest.
$ac_ext
11560 LIBS
=$ac_check_lib_save_LIBS
11562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_kill" >&5
11563 $as_echo "$ac_cv_lib_pthread_pthread_kill" >&6; }
11564 if test "x$ac_cv_lib_pthread_pthread_kill" = xyes
; then :
11565 LIBPMULTITHREAD
=-lpthread
11566 # On Solaris and HP-UX, most pthread functions exist also in libc.
11567 # Therefore pthread_in_use() needs to actually try to create a
11568 # thread: pthread_create from libc will fail, whereas
11569 # pthread_create will actually create a thread.
11570 # On Solaris 10 or newer, this test is no longer needed, because
11571 # libc contains the fully functional pthread functions.
11573 solaris | solaris2.1
-9 | solaris2.1
-9.
* | hpux
*)
11575 $as_echo "#define PTHREAD_IN_USE_DETECTION_HARD 1" >>confdefs.h
11581 elif test $gl_pthread_api != yes; then
11582 # Some library is needed. Try libpthread and libc_r.
11583 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lpthread" >&5
11584 $as_echo_n "checking for pthread_kill in -lpthread... " >&6; }
11585 if ${ac_cv_lib_pthread_pthread_kill+:} false
; then :
11586 $as_echo_n "(cached) " >&6
11588 ac_check_lib_save_LIBS
=$LIBS
11589 LIBS
="-lpthread $LIBS"
11590 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
11591 /* end confdefs.h. */
11593 /* Override any GCC internal prototype to avoid an error.
11594 Use char because int might match the return type of a GCC
11595 builtin and then its argument prototype would still apply. */
11599 char pthread_kill ();
11603 return pthread_kill ();
11608 if ac_fn_c_try_link
"$LINENO"; then :
11609 ac_cv_lib_pthread_pthread_kill
=yes
11611 ac_cv_lib_pthread_pthread_kill
=no
11613 rm -f core conftest.err conftest.
$ac_objext \
11614 conftest
$ac_exeext conftest.
$ac_ext
11615 LIBS
=$ac_check_lib_save_LIBS
11617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_kill" >&5
11618 $as_echo "$ac_cv_lib_pthread_pthread_kill" >&6; }
11619 if test "x$ac_cv_lib_pthread_pthread_kill" = xyes
; then :
11621 LIBPTHREAD
=-lpthread
11622 LIBPMULTITHREAD
=-lpthread
11625 if test $gl_pthread_api != yes; then
11627 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lc_r" >&5
11628 $as_echo_n "checking for pthread_kill in -lc_r... " >&6; }
11629 if ${ac_cv_lib_c_r_pthread_kill+:} false
; then :
11630 $as_echo_n "(cached) " >&6
11632 ac_check_lib_save_LIBS
=$LIBS
11634 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
11635 /* end confdefs.h. */
11637 /* Override any GCC internal prototype to avoid an error.
11638 Use char because int might match the return type of a GCC
11639 builtin and then its argument prototype would still apply. */
11643 char pthread_kill ();
11647 return pthread_kill ();
11652 if ac_fn_c_try_link
"$LINENO"; then :
11653 ac_cv_lib_c_r_pthread_kill
=yes
11655 ac_cv_lib_c_r_pthread_kill
=no
11657 rm -f core conftest.err conftest.
$ac_objext \
11658 conftest
$ac_exeext conftest.
$ac_ext
11659 LIBS
=$ac_check_lib_save_LIBS
11661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_pthread_kill" >&5
11662 $as_echo "$ac_cv_lib_c_r_pthread_kill" >&6; }
11663 if test "x$ac_cv_lib_c_r_pthread_kill" = xyes
; then :
11666 LIBPMULTITHREAD
=-lc_r
11672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether POSIX threads API is available" >&5
11673 $as_echo_n "checking whether POSIX threads API is available... " >&6; }
11674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_pthread_api" >&5
11675 $as_echo "$gl_pthread_api" >&6; }
11678 if test $gl_pthread_api = yes; then
11680 $as_echo "#define HAVE_PTHREAD_API 1" >>confdefs.h
11684 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
11685 /* end confdefs.h. */
11695 if ac_fn_c_try_link
"$LINENO"; then :
11699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sched_yield in -lrt" >&5
11700 $as_echo_n "checking for sched_yield in -lrt... " >&6; }
11701 if ${ac_cv_lib_rt_sched_yield+:} false
; then :
11702 $as_echo_n "(cached) " >&6
11704 ac_check_lib_save_LIBS
=$LIBS
11706 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
11707 /* end confdefs.h. */
11709 /* Override any GCC internal prototype to avoid an error.
11710 Use char because int might match the return type of a GCC
11711 builtin and then its argument prototype would still apply. */
11715 char sched_yield ();
11719 return sched_yield ();
11724 if ac_fn_c_try_link
"$LINENO"; then :
11725 ac_cv_lib_rt_sched_yield
=yes
11727 ac_cv_lib_rt_sched_yield
=no
11729 rm -f core conftest.err conftest.
$ac_objext \
11730 conftest
$ac_exeext conftest.
$ac_ext
11731 LIBS
=$ac_check_lib_save_LIBS
11733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_sched_yield" >&5
11734 $as_echo "$ac_cv_lib_rt_sched_yield" >&6; }
11735 if test "x$ac_cv_lib_rt_sched_yield" = xyes
; then :
11736 LIB_SCHED_YIELD
=-lrt
11738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sched_yield in -lposix4" >&5
11739 $as_echo_n "checking for sched_yield in -lposix4... " >&6; }
11740 if ${ac_cv_lib_posix4_sched_yield+:} false
; then :
11741 $as_echo_n "(cached) " >&6
11743 ac_check_lib_save_LIBS
=$LIBS
11744 LIBS
="-lposix4 $LIBS"
11745 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
11746 /* end confdefs.h. */
11748 /* Override any GCC internal prototype to avoid an error.
11749 Use char because int might match the return type of a GCC
11750 builtin and then its argument prototype would still apply. */
11754 char sched_yield ();
11758 return sched_yield ();
11763 if ac_fn_c_try_link
"$LINENO"; then :
11764 ac_cv_lib_posix4_sched_yield
=yes
11766 ac_cv_lib_posix4_sched_yield
=no
11768 rm -f core conftest.err conftest.
$ac_objext \
11769 conftest
$ac_exeext conftest.
$ac_ext
11770 LIBS
=$ac_check_lib_save_LIBS
11772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix4_sched_yield" >&5
11773 $as_echo "$ac_cv_lib_posix4_sched_yield" >&6; }
11774 if test "x$ac_cv_lib_posix4_sched_yield" = xyes
; then :
11775 LIB_SCHED_YIELD
=-lposix4
11782 rm -f core conftest.err conftest.
$ac_objext \
11783 conftest
$ac_exeext conftest.
$ac_ext
11786 gl_pthreadlib_body_done
=done
11797 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setlocale (LC_ALL, NULL) is multithread-safe" >&5
11798 $as_echo_n "checking whether setlocale (LC_ALL, NULL) is multithread-safe... " >&6; }
11799 if ${gl_cv_func_setlocale_null_all_mtsafe+:} false
; then :
11800 $as_echo_n "(cached) " >&6
11803 # Guess no on musl libc, macOS, FreeBSD, NetBSD, OpenBSD, AIX, Haiku, Cygwin.
11804 *-musl* | darwin
* | freebsd
* | netbsd
* | openbsd
* | aix
* | haiku
* | cygwin
*)
11805 gl_cv_func_setlocale_null_all_mtsafe
=no
;;
11806 # Guess yes on glibc, HP-UX, IRIX, Solaris, native Windows.
11807 *-gnu* | gnu
* | hpux
* | irix
* | solaris
* | mingw
*)
11808 gl_cv_func_setlocale_null_all_mtsafe
=yes ;;
11809 # If we don't know, obey --enable-cross-guesses.
11811 gl_cv_func_setlocale_null_all_mtsafe
="$gl_cross_guess_normal" ;;
11815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_setlocale_null_all_mtsafe" >&5
11816 $as_echo "$gl_cv_func_setlocale_null_all_mtsafe" >&6; }
11820 if test $gl_pthread_api = no
&& test $ac_cv_header_threads_h = no
; then
11821 gl_cv_func_setlocale_null_all_mtsafe
="trivially yes"
11825 case "$gl_cv_func_setlocale_null_all_mtsafe" in
11826 *yes) SETLOCALE_NULL_ALL_MTSAFE
=1 ;;
11827 *) SETLOCALE_NULL_ALL_MTSAFE
=0 ;;
11830 cat >>confdefs.h
<<_ACEOF
11831 #define SETLOCALE_NULL_ALL_MTSAFE $SETLOCALE_NULL_ALL_MTSAFE
11835 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setlocale (category, NULL) is multithread-safe" >&5
11836 $as_echo_n "checking whether setlocale (category, NULL) is multithread-safe... " >&6; }
11837 if ${gl_cv_func_setlocale_null_one_mtsafe+:} false
; then :
11838 $as_echo_n "(cached) " >&6
11841 # Guess no on OpenBSD, AIX.
11843 gl_cv_func_setlocale_null_one_mtsafe
=no
;;
11844 # Guess yes on glibc, musl libc, macOS, FreeBSD, NetBSD, HP-UX, IRIX, Solaris, Haiku, Cygwin, native Windows.
11845 *-gnu* | gnu
* |
*-musl* | darwin
* | freebsd
* | netbsd
* | hpux
* | irix
* | solaris
* | haiku
* | cygwin
* | mingw
*)
11846 gl_cv_func_setlocale_null_one_mtsafe
=yes ;;
11847 # If we don't know, obey --enable-cross-guesses.
11849 gl_cv_func_setlocale_null_one_mtsafe
="$gl_cross_guess_normal" ;;
11853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_setlocale_null_one_mtsafe" >&5
11854 $as_echo "$gl_cv_func_setlocale_null_one_mtsafe" >&6; }
11858 if test $gl_pthread_api = no
&& test $ac_cv_header_threads_h = no
; then
11859 gl_cv_func_setlocale_null_one_mtsafe
="trivially yes"
11863 case "$gl_cv_func_setlocale_null_one_mtsafe" in
11864 *yes) SETLOCALE_NULL_ONE_MTSAFE
=1 ;;
11865 *) SETLOCALE_NULL_ONE_MTSAFE
=0 ;;
11868 cat >>confdefs.h
<<_ACEOF
11869 #define SETLOCALE_NULL_ONE_MTSAFE $SETLOCALE_NULL_ONE_MTSAFE
11873 if test $SETLOCALE_NULL_ALL_MTSAFE = 0 ||
test $SETLOCALE_NULL_ONE_MTSAFE = 0; then
11875 mingw
*) LIB_SETLOCALE_NULL
= ;;
11879 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether imported symbols can be declared weak" >&5
11880 $as_echo_n "checking whether imported symbols can be declared weak... " >&6; }
11881 if ${gl_cv_have_weak+:} false
; then :
11882 $as_echo_n "(cached) " >&6
11885 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
11886 /* end confdefs.h. */
11887 extern void xyzzy ();
11897 if ac_fn_c_try_link
"$LINENO"; then :
11898 gl_cv_have_weak
=maybe
11900 rm -f core conftest.err conftest.
$ac_objext \
11901 conftest
$ac_exeext conftest.
$ac_ext
11902 if test $gl_cv_have_weak = maybe
; then
11903 if test "$cross_compiling" = yes; then :
11904 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
11905 /* end confdefs.h. */
11907 Extensible Linking Format
11911 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11912 $EGREP "Extensible Linking Format" >/dev
/null
2>&1; then :
11913 gl_cv_have_weak
="guessing yes"
11915 gl_cv_have_weak
="guessing no"
11921 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
11922 /* end confdefs.h. */
11928 return (fputs == NULL);
11931 if ac_fn_c_try_run
"$LINENO"; then :
11932 gl_cv_have_weak
=yes
11936 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
11937 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
11941 case " $LDFLAGS " in
11942 *" -static "*) gl_cv_have_weak
=no
;;
11944 case "$gl_cv_have_weak" in
11947 freebsd
* | dragonfly
*)
11949 $CC $CPPFLAGS $CFLAGS $LDFLAGS -fPIC -shared -o libempty.so conftest1.c
-lpthread >&5 2>&1
11950 cat <<EOF > conftest2.c
11951 #include <pthread.h>
11952 #pragma weak pthread_mutexattr_gettype
11955 return (pthread_mutexattr_gettype != NULL);
11958 $CC $CPPFLAGS $CFLAGS $LDFLAGS -o conftest conftest2.c libempty.so
>&5 2>&1 \
11959 || gl_cv_have_weak
=no
11960 rm -f conftest1.c libempty.so conftest2.c conftest
11967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_weak" >&5
11968 $as_echo "$gl_cv_have_weak" >&6; }
11969 case "$gl_cv_have_weak" in
11972 $as_echo "#define HAVE_WEAK_SYMBOLS 1" >>confdefs.h
11977 case "$gl_cv_have_weak" in
11978 *yes) LIB_SETLOCALE_NULL
= ;;
11979 *) LIB_SETLOCALE_NULL
="$LIBPTHREAD" ;;
11984 LIB_SETLOCALE_NULL
=
11995 GNULIB_GETPEERNAME
=0;
11996 GNULIB_GETSOCKNAME
=0;
11997 GNULIB_GETSOCKOPT
=0;
12003 GNULIB_SETSOCKOPT
=0;
12006 HAVE_STRUCT_SOCKADDR_STORAGE
=1;
12007 HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY
=1;
12009 HAVE_SA_FAMILY_T
=1;
12019 $as_echo "#define _POSIX_PII_SOCKET 1" >>confdefs.h
12024 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/socket.h> is self-contained" >&5
12025 $as_echo_n "checking whether <sys/socket.h> is self-contained... " >&6; }
12026 if ${gl_cv_header_sys_socket_h_selfcontained+:} false
; then :
12027 $as_echo_n "(cached) " >&6
12030 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
12031 /* end confdefs.h. */
12032 #include <sys/socket.h>
12041 if ac_fn_c_try_compile
"$LINENO"; then :
12042 gl_cv_header_sys_socket_h_selfcontained
=yes
12044 gl_cv_header_sys_socket_h_selfcontained
=no
12046 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
12049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_socket_h_selfcontained" >&5
12050 $as_echo "$gl_cv_header_sys_socket_h_selfcontained" >&6; }
12051 if test $gl_cv_header_sys_socket_h_selfcontained = yes; then
12052 for ac_func
in shutdown
12054 ac_fn_c_check_func
"$LINENO" "shutdown" "ac_cv_func_shutdown"
12055 if test "x$ac_cv_func_shutdown" = xyes
; then :
12056 cat >>confdefs.h
<<_ACEOF
12057 #define HAVE_SHUTDOWN 1
12063 if test $ac_cv_func_shutdown = yes; then
12064 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/socket.h> defines the SHUT_* macros" >&5
12065 $as_echo_n "checking whether <sys/socket.h> defines the SHUT_* macros... " >&6; }
12066 if ${gl_cv_header_sys_socket_h_shut+:} false
; then :
12067 $as_echo_n "(cached) " >&6
12070 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
12071 /* end confdefs.h. */
12072 #include <sys/socket.h>
12076 int a[] = { SHUT_RD, SHUT_WR, SHUT_RDWR };
12081 if ac_fn_c_try_compile
"$LINENO"; then :
12082 gl_cv_header_sys_socket_h_shut
=yes
12084 gl_cv_header_sys_socket_h_shut
=no
12086 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
12089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_socket_h_shut" >&5
12090 $as_echo "$gl_cv_header_sys_socket_h_shut" >&6; }
12091 if test $gl_cv_header_sys_socket_h_shut = no
; then
12092 SYS_SOCKET_H
='sys/socket.h'
12096 # We need to check for ws2tcpip.h now.
12108 if test $gl_cv_have_include_next = yes; then
12109 gl_cv_next_sys_socket_h
='<'sys
/socket.h
'>'
12111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/socket.h>" >&5
12112 $as_echo_n "checking absolute name of <sys/socket.h>... " >&6; }
12113 if ${gl_cv_next_sys_socket_h+:} false
; then :
12114 $as_echo_n "(cached) " >&6
12117 if test $ac_cv_header_sys_socket_h = yes; then
12122 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
12123 /* end confdefs.h. */
12124 #include <sys/socket.h>
12127 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
12128 *) gl_absname_cpp
="$ac_cpp" ;;
12133 gl_dirsep_regex
='[/\\]'
12136 gl_dirsep_regex
='\/'
12139 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
12140 gl_header_literal_regex
=`echo 'sys/socket.h' \
12141 | sed -e "$gl_make_literal_regex_sed"`
12142 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
12143 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
12149 gl_cv_absolute_sys_socket_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
12150 sed -n "$gl_absolute_header_sed"`
12152 gl_header
=$gl_cv_absolute_sys_socket_h
12153 gl_cv_next_sys_socket_h
='"'$gl_header'"'
12155 gl_cv_next_sys_socket_h
='<'sys
/socket.h
'>'
12160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_socket_h" >&5
12161 $as_echo "$gl_cv_next_sys_socket_h" >&6; }
12163 NEXT_SYS_SOCKET_H
=$gl_cv_next_sys_socket_h
12165 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
12166 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
12167 gl_next_as_first_directive
='<'sys
/socket.h
'>'
12169 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
12170 gl_next_as_first_directive
=$gl_cv_next_sys_socket_h
12172 NEXT_AS_FIRST_DIRECTIVE_SYS_SOCKET_H
=$gl_next_as_first_directive
12177 if test $ac_cv_header_sys_socket_h = yes; then
12178 HAVE_SYS_SOCKET_H
=1
12180 HAVE_SYS_SOCKET_H
=0
12185 if test $ac_cv_header_sys_socket_h = yes; then
12188 if test $ac_cv_header_ws2tcpip_h = yes; then
12197 ac_fn_c_check_type
"$LINENO" "struct sockaddr_storage" "ac_cv_type_struct_sockaddr_storage" "
12198 /* sys/types.h is not needed according to POSIX, but the
12199 sys/socket.h in i386-unknown-freebsd4.10 and
12200 powerpc-apple-darwin5.5 required it. */
12201 #include <sys/types.h>
12202 #ifdef HAVE_SYS_SOCKET_H
12203 #include <sys/socket.h>
12205 #ifdef HAVE_WS2TCPIP_H
12206 #include <ws2tcpip.h>
12210 if test "x$ac_cv_type_struct_sockaddr_storage" = xyes
; then :
12212 cat >>confdefs.h
<<_ACEOF
12213 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
12218 ac_fn_c_check_type
"$LINENO" "sa_family_t" "ac_cv_type_sa_family_t" "
12219 /* sys/types.h is not needed according to POSIX, but the
12220 sys/socket.h in i386-unknown-freebsd4.10 and
12221 powerpc-apple-darwin5.5 required it. */
12222 #include <sys/types.h>
12223 #ifdef HAVE_SYS_SOCKET_H
12224 #include <sys/socket.h>
12226 #ifdef HAVE_WS2TCPIP_H
12227 #include <ws2tcpip.h>
12231 if test "x$ac_cv_type_sa_family_t" = xyes
; then :
12233 cat >>confdefs.h
<<_ACEOF
12234 #define HAVE_SA_FAMILY_T 1
12240 if test $ac_cv_type_struct_sockaddr_storage = no
; then
12241 HAVE_STRUCT_SOCKADDR_STORAGE
=0
12243 if test $ac_cv_type_sa_family_t = no
; then
12246 if test $ac_cv_type_struct_sockaddr_storage != no
; then
12247 ac_fn_c_check_member
"$LINENO" "struct sockaddr_storage" "ss_family" "ac_cv_member_struct_sockaddr_storage_ss_family" "#include <sys/types.h>
12248 #ifdef HAVE_SYS_SOCKET_H
12249 #include <sys/socket.h>
12251 #ifdef HAVE_WS2TCPIP_H
12252 #include <ws2tcpip.h>
12256 if test "x$ac_cv_member_struct_sockaddr_storage_ss_family" = xyes
; then :
12258 cat >>confdefs.h
<<_ACEOF
12259 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
12264 HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY
=0
12268 if test $HAVE_STRUCT_SOCKADDR_STORAGE = 0 ||
test $HAVE_SA_FAMILY_T = 0 \
12269 ||
test $HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY = 0; then
12270 SYS_SOCKET_H
='sys/socket.h'
12276 if test $ac_cv_header_sys_socket_h != yes; then
12277 for ac_header
in winsock2.h
12279 ac_fn_c_check_header_mongrel
"$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
12280 if test "x$ac_cv_header_winsock2_h" = xyes
; then :
12281 cat >>confdefs.h
<<_ACEOF
12282 #define HAVE_WINSOCK2_H 1
12290 if test "$ac_cv_header_winsock2_h" = yes; then
12292 UNISTD_H_HAVE_WINSOCK2_H
=1
12293 SYS_IOCTL_H_HAVE_WINSOCK2_H
=1
12312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IPv4 sockets" >&5
12313 $as_echo_n "checking for IPv4 sockets... " >&6; }
12314 if ${gl_cv_socket_ipv4+:} false
; then :
12315 $as_echo_n "(cached) " >&6
12317 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
12318 /* end confdefs.h. */
12319 #include <sys/types.h>
12320 #ifdef HAVE_SYS_SOCKET_H
12321 #include <sys/socket.h>
12323 #ifdef HAVE_NETINET_IN_H
12324 #include <netinet/in.h>
12326 #ifdef HAVE_WINSOCK2_H
12327 #include <winsock2.h>
12332 int x = AF_INET; struct in_addr y; struct sockaddr_in z;
12333 if (&x && &y && &z) return 0;
12338 if ac_fn_c_try_compile
"$LINENO"; then :
12339 gl_cv_socket_ipv4
=yes
12341 gl_cv_socket_ipv4
=no
12343 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
12345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socket_ipv4" >&5
12346 $as_echo "$gl_cv_socket_ipv4" >&6; }
12347 if test $gl_cv_socket_ipv4 = yes; then
12349 $as_echo "#define HAVE_IPV4 1" >>confdefs.h
12353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IPv6 sockets" >&5
12354 $as_echo_n "checking for IPv6 sockets... " >&6; }
12355 if ${gl_cv_socket_ipv6+:} false
; then :
12356 $as_echo_n "(cached) " >&6
12358 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
12359 /* end confdefs.h. */
12360 #include <sys/types.h>
12361 #ifdef HAVE_SYS_SOCKET_H
12362 #include <sys/socket.h>
12364 #ifdef HAVE_NETINET_IN_H
12365 #include <netinet/in.h>
12367 #ifdef HAVE_WINSOCK2_H
12368 #include <winsock2.h>
12370 #ifdef HAVE_WS2TCPIP_H
12371 #include <ws2tcpip.h>
12376 int x = AF_INET6; struct in6_addr y; struct sockaddr_in6 z;
12377 if (&x && &y && &z) return 0;
12382 if ac_fn_c_try_compile
"$LINENO"; then :
12383 gl_cv_socket_ipv6
=yes
12385 gl_cv_socket_ipv6
=no
12387 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
12389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socket_ipv6" >&5
12390 $as_echo "$gl_cv_socket_ipv6" >&6; }
12391 if test $gl_cv_socket_ipv6 = yes; then
12393 $as_echo "#define HAVE_IPV6 1" >>confdefs.h
12409 if test $gl_cv_have_include_next = yes; then
12410 gl_cv_next_limits_h
='<'limits.h
'>'
12412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <limits.h>" >&5
12413 $as_echo_n "checking absolute name of <limits.h>... " >&6; }
12414 if ${gl_cv_next_limits_h+:} false
; then :
12415 $as_echo_n "(cached) " >&6
12418 if test $ac_cv_header_limits_h = yes; then
12423 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
12424 /* end confdefs.h. */
12425 #include <limits.h>
12428 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
12429 *) gl_absname_cpp
="$ac_cpp" ;;
12434 gl_dirsep_regex
='[/\\]'
12437 gl_dirsep_regex
='\/'
12440 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
12441 gl_header_literal_regex
=`echo 'limits.h' \
12442 | sed -e "$gl_make_literal_regex_sed"`
12443 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
12444 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
12450 gl_cv_absolute_limits_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
12451 sed -n "$gl_absolute_header_sed"`
12453 gl_header
=$gl_cv_absolute_limits_h
12454 gl_cv_next_limits_h
='"'$gl_header'"'
12456 gl_cv_next_limits_h
='<'limits.h
'>'
12461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_limits_h" >&5
12462 $as_echo "$gl_cv_next_limits_h" >&6; }
12464 NEXT_LIMITS_H
=$gl_cv_next_limits_h
12466 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
12467 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
12468 gl_next_as_first_directive
='<'limits.h
'>'
12470 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
12471 gl_next_as_first_directive
=$gl_cv_next_limits_h
12473 NEXT_AS_FIRST_DIRECTIVE_LIMITS_H
=$gl_next_as_first_directive
12479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether limits.h has LLONG_MAX, WORD_BIT, ULLONG_WIDTH etc." >&5
12480 $as_echo_n "checking whether limits.h has LLONG_MAX, WORD_BIT, ULLONG_WIDTH etc.... " >&6; }
12481 if ${gl_cv_header_limits_width+:} false
; then :
12482 $as_echo_n "(cached) " >&6
12484 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
12485 /* end confdefs.h. */
12486 #ifndef __STDC_WANT_IEC_60559_BFP_EXT__
12487 #define __STDC_WANT_IEC_60559_BFP_EXT__ 1
12489 #include <limits.h>
12490 long long llm = LLONG_MAX;
12492 int ullw = ULLONG_WIDTH;
12502 if ac_fn_c_try_compile
"$LINENO"; then :
12503 gl_cv_header_limits_width
=yes
12505 gl_cv_header_limits_width
=no
12507 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
12509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_limits_width" >&5
12510 $as_echo "$gl_cv_header_limits_width" >&6; }
12511 if test "$gl_cv_header_limits_width" = yes; then
12517 if test -n "$LIMITS_H"; then
12518 GL_GENERATE_LIMITS_H_TRUE
=
12519 GL_GENERATE_LIMITS_H_FALSE
='#'
12521 GL_GENERATE_LIMITS_H_TRUE
='#'
12522 GL_GENERATE_LIMITS_H_FALSE
=
12527 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wint_t" >&5
12528 $as_echo_n "checking for wint_t... " >&6; }
12529 if ${gt_cv_c_wint_t+:} false
; then :
12530 $as_echo_n "(cached) " >&6
12532 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
12533 /* end confdefs.h. */
12535 wint_t foo = (wchar_t)'\0';
12544 if ac_fn_c_try_compile
"$LINENO"; then :
12549 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
12551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wint_t" >&5
12552 $as_echo "$gt_cv_c_wint_t" >&6; }
12553 if test $gt_cv_c_wint_t = yes; then
12555 $as_echo "#define HAVE_WINT_T 1" >>confdefs.h
12558 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether wint_t is large enough" >&5
12559 $as_echo_n "checking whether wint_t is large enough... " >&6; }
12560 if ${gl_cv_type_wint_t_large_enough+:} false
; then :
12561 $as_echo_n "(cached) " >&6
12563 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
12564 /* end confdefs.h. */
12566 int verify[sizeof (wint_t) < sizeof (int) ? -1 : 1];
12576 if ac_fn_c_try_compile
"$LINENO"; then :
12577 gl_cv_type_wint_t_large_enough
=yes
12579 gl_cv_type_wint_t_large_enough
=no
12581 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
12583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wint_t_large_enough" >&5
12584 $as_echo "$gl_cv_type_wint_t_large_enough" >&6; }
12585 if test $gl_cv_type_wint_t_large_enough = no
; then
12586 GNULIB_OVERRIDES_WINT_T
=1
12588 GNULIB_OVERRIDES_WINT_T
=0
12591 GNULIB_OVERRIDES_WINT_T
=0
12602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler produces multi-arch binaries" >&5
12603 $as_echo_n "checking whether the compiler produces multi-arch binaries... " >&6; }
12604 if ${gl_cv_c_multiarch+:} false
; then :
12605 $as_echo_n "(cached) " >&6
12607 gl_cv_c_multiarch
=no
12608 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
12609 /* end confdefs.h. */
12610 #ifndef __APPLE_CC__
12611 not a universal capable compiler
12616 if ac_fn_c_try_compile
"$LINENO"; then :
12620 for word
in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
12621 if test -n "$prev"; then
12623 i?
86 | x86_64 | ppc | ppc64 | arm | arm64
)
12624 if test -z "$arch" ||
test "$arch" = "$word"; then
12627 gl_cv_c_multiarch
=yes
12633 if test "x$word" = "x-arch"; then
12640 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
12643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_multiarch" >&5
12644 $as_echo "$gl_cv_c_multiarch" >&6; }
12645 if test $gl_cv_c_multiarch = yes; then
12646 APPLE_UNIVERSAL_BUILD
=1
12648 APPLE_UNIVERSAL_BUILD
=0
12658 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
12661 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
12665 if test $ac_cv_header_wchar_h = yes; then
12673 if test $ac_cv_header_inttypes_h = yes; then
12681 if test $ac_cv_header_sys_types_h = yes; then
12697 if test $gl_cv_have_include_next = yes; then
12698 gl_cv_next_stdint_h
='<'stdint.h
'>'
12700 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
12701 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
12702 if ${gl_cv_next_stdint_h+:} false
; then :
12703 $as_echo_n "(cached) " >&6
12706 if test $ac_cv_header_stdint_h = yes; then
12711 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
12712 /* end confdefs.h. */
12713 #include <stdint.h>
12716 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
12717 *) gl_absname_cpp
="$ac_cpp" ;;
12722 gl_dirsep_regex
='[/\\]'
12725 gl_dirsep_regex
='\/'
12728 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
12729 gl_header_literal_regex
=`echo 'stdint.h' \
12730 | sed -e "$gl_make_literal_regex_sed"`
12731 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
12732 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
12738 gl_cv_absolute_stdint_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
12739 sed -n "$gl_absolute_header_sed"`
12741 gl_header
=$gl_cv_absolute_stdint_h
12742 gl_cv_next_stdint_h
='"'$gl_header'"'
12744 gl_cv_next_stdint_h
='<'stdint.h
'>'
12749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
12750 $as_echo "$gl_cv_next_stdint_h" >&6; }
12752 NEXT_STDINT_H
=$gl_cv_next_stdint_h
12754 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
12755 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
12756 gl_next_as_first_directive
='<'stdint.h
'>'
12758 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
12759 gl_next_as_first_directive
=$gl_cv_next_stdint_h
12761 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
=$gl_next_as_first_directive
12766 if test $ac_cv_header_stdint_h = yes; then
12773 if test $ac_cv_header_stdint_h = yes; then
12774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
12775 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
12776 if ${gl_cv_header_working_stdint_h+:} false
; then :
12777 $as_echo_n "(cached) " >&6
12779 gl_cv_header_working_stdint_h
=no
12780 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
12781 /* end confdefs.h. */
12784 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
12785 #define __STDC_CONSTANT_MACROS 1
12786 #define __STDC_LIMIT_MACROS 1
12787 #include <stdint.h>
12788 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
12789 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
12790 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
12794 #include <stddef.h>
12795 #include <signal.h>
12797 # include <wchar.h>
12802 int8_t a1 = INT8_MAX;
12803 int8_t a1min = INT8_MIN;
12806 int16_t a2 = INT16_MAX;
12807 int16_t a2min = INT16_MIN;
12810 int32_t a3 = INT32_MAX;
12811 int32_t a3min = INT32_MIN;
12814 int64_t a4 = INT64_MAX;
12815 int64_t a4min = INT64_MIN;
12818 uint8_t b1 = UINT8_MAX;
12820 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
12823 uint16_t b2 = UINT16_MAX;
12826 uint32_t b3 = UINT32_MAX;
12829 uint64_t b4 = UINT64_MAX;
12831 int_least8_t c1 = INT8_C (0x7f);
12832 int_least8_t c1max = INT_LEAST8_MAX;
12833 int_least8_t c1min = INT_LEAST8_MIN;
12834 int_least16_t c2 = INT16_C (0x7fff);
12835 int_least16_t c2max = INT_LEAST16_MAX;
12836 int_least16_t c2min = INT_LEAST16_MIN;
12837 int_least32_t c3 = INT32_C (0x7fffffff);
12838 int_least32_t c3max = INT_LEAST32_MAX;
12839 int_least32_t c3min = INT_LEAST32_MIN;
12840 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
12841 int_least64_t c4max = INT_LEAST64_MAX;
12842 int_least64_t c4min = INT_LEAST64_MIN;
12843 uint_least8_t d1 = UINT8_C (0xff);
12844 uint_least8_t d1max = UINT_LEAST8_MAX;
12845 uint_least16_t d2 = UINT16_C (0xffff);
12846 uint_least16_t d2max = UINT_LEAST16_MAX;
12847 uint_least32_t d3 = UINT32_C (0xffffffff);
12848 uint_least32_t d3max = UINT_LEAST32_MAX;
12849 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
12850 uint_least64_t d4max = UINT_LEAST64_MAX;
12851 int_fast8_t e1 = INT_FAST8_MAX;
12852 int_fast8_t e1min = INT_FAST8_MIN;
12853 int_fast16_t e2 = INT_FAST16_MAX;
12854 int_fast16_t e2min = INT_FAST16_MIN;
12855 int_fast32_t e3 = INT_FAST32_MAX;
12856 int_fast32_t e3min = INT_FAST32_MIN;
12857 int_fast64_t e4 = INT_FAST64_MAX;
12858 int_fast64_t e4min = INT_FAST64_MIN;
12859 uint_fast8_t f1 = UINT_FAST8_MAX;
12860 uint_fast16_t f2 = UINT_FAST16_MAX;
12861 uint_fast32_t f3 = UINT_FAST32_MAX;
12862 uint_fast64_t f4 = UINT_FAST64_MAX;
12864 intptr_t g = INTPTR_MAX;
12865 intptr_t gmin = INTPTR_MIN;
12868 uintptr_t h = UINTPTR_MAX;
12870 intmax_t i = INTMAX_MAX;
12871 uintmax_t j = UINTMAX_MAX;
12873 /* Check that SIZE_MAX has the correct type, if possible. */
12874 #if 201112 <= __STDC_VERSION__
12875 int k = _Generic (SIZE_MAX, size_t: 0);
12876 #elif (2 <= __GNUC__ || 4 <= __clang_major__ || defined __IBM__TYPEOF__ \
12877 || (0x5110 <= __SUNPRO_C && !__STDC__))
12879 extern __typeof__ (SIZE_MAX) k;
12882 #include <limits.h> /* for CHAR_BIT */
12883 #define TYPE_MINIMUM(t) \
12884 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
12885 #define TYPE_MAXIMUM(t) \
12886 ((t) ((t) 0 < (t) -1 \
12888 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
12891 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
12892 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
12894 /* Detect bug in FreeBSD 6.0 / ia64. */
12895 int check_SIG_ATOMIC:
12896 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
12897 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
12899 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
12901 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
12902 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
12904 /* Detect bug in mingw. */
12906 WINT_MIN == TYPE_MINIMUM (wint_t)
12907 && WINT_MAX == TYPE_MAXIMUM (wint_t)
12910 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
12912 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
12913 int check_UINT16_C:
12914 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
12916 /* Detect bugs in OpenBSD 3.9 stdint.h. */
12918 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
12921 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
12924 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
12927 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
12929 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
12930 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
12931 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
12932 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
12933 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
12934 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
12935 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
12936 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
12937 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
12938 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
12939 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
12950 if ac_fn_c_try_compile
"$LINENO"; then :
12951 if test "$cross_compiling" = yes; then :
12953 # Guess yes on native Windows.
12954 mingw
*) gl_cv_header_working_stdint_h
="guessing yes" ;;
12955 # In general, assume it works.
12956 *) gl_cv_header_working_stdint_h
="guessing yes" ;;
12960 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
12961 /* end confdefs.h. */
12964 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
12965 #define __STDC_CONSTANT_MACROS 1
12966 #define __STDC_LIMIT_MACROS 1
12967 #include <stdint.h>
12970 #include <stddef.h>
12971 #include <signal.h>
12973 # include <wchar.h>
12978 #include <string.h>
12979 #define MVAL(macro) MVAL1(macro)
12980 #define MVAL1(expression) #expression
12981 static const char *macro_values[] =
13015 for (mv = macro_values; *mv != NULL; mv++)
13017 const char *value = *mv;
13018 /* Test whether it looks like a cast expression. */
13019 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
13020 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
13021 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
13022 || strncmp (value, "((int)"/*)*/, 6) == 0
13023 || strncmp (value, "((signed short)"/*)*/, 15) == 0
13024 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
13025 return mv - macro_values + 1;
13033 if ac_fn_c_try_run
"$LINENO"; then :
13034 gl_cv_header_working_stdint_h
=yes
13036 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
13037 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
13042 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
13045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
13046 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
13049 HAVE_C99_STDINT_H
=0
13050 HAVE_SYS_BITYPES_H
=0
13051 HAVE_SYS_INTTYPES_H
=0
13053 case "$gl_cv_header_working_stdint_h" in
13055 HAVE_C99_STDINT_H
=1
13056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h works without ISO C predefines" >&5
13057 $as_echo_n "checking whether stdint.h works without ISO C predefines... " >&6; }
13058 if ${gl_cv_header_stdint_without_STDC_macros+:} false
; then :
13059 $as_echo_n "(cached) " >&6
13061 gl_cv_header_stdint_without_STDC_macros
=no
13062 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
13063 /* end confdefs.h. */
13066 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
13067 #include <stdint.h>
13070 #include <stddef.h>
13071 #include <signal.h>
13073 # include <wchar.h>
13077 intmax_t im = INTMAX_MAX;
13078 int32_t i32 = INT32_C (0x7fffffff);
13088 if ac_fn_c_try_compile
"$LINENO"; then :
13089 gl_cv_header_stdint_without_STDC_macros
=yes
13091 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
13094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_stdint_without_STDC_macros" >&5
13095 $as_echo "$gl_cv_header_stdint_without_STDC_macros" >&6; }
13097 if test $gl_cv_header_stdint_without_STDC_macros = no
; then
13099 $as_echo "#define __STDC_CONSTANT_MACROS 1" >>confdefs.h
13102 $as_echo "#define __STDC_LIMIT_MACROS 1" >>confdefs.h
13105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h has UINTMAX_WIDTH etc." >&5
13106 $as_echo_n "checking whether stdint.h has UINTMAX_WIDTH etc.... " >&6; }
13107 if ${gl_cv_header_stdint_width+:} false
; then :
13108 $as_echo_n "(cached) " >&6
13110 gl_cv_header_stdint_width
=no
13111 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
13112 /* end confdefs.h. */
13114 /* Work if build is not clean. */
13115 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1
13116 #ifndef __STDC_WANT_IEC_60559_BFP_EXT__
13117 #define __STDC_WANT_IEC_60559_BFP_EXT__ 1
13119 #include <stdint.h>
13121 #include <stddef.h>
13122 #include <signal.h>
13124 # include <wchar.h>
13127 int iw = UINTMAX_WIDTH;
13137 if ac_fn_c_try_compile
"$LINENO"; then :
13138 gl_cv_header_stdint_width
=yes
13140 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
13142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_stdint_width" >&5
13143 $as_echo "$gl_cv_header_stdint_width" >&6; }
13144 if test "$gl_cv_header_stdint_width" = yes; then
13149 for ac_header
in sys
/inttypes.h sys
/bitypes.h
13151 as_ac_Header
=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13152 ac_fn_c_check_header_mongrel
"$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13153 if eval test \"x\$
"$as_ac_Header"\" = x
"yes"; then :
13154 cat >>confdefs.h
<<_ACEOF
13155 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13162 if test $ac_cv_header_sys_inttypes_h = yes; then
13163 HAVE_SYS_INTTYPES_H
=1
13165 if test $ac_cv_header_sys_bitypes_h = yes; then
13166 HAVE_SYS_BITYPES_H
=1
13170 if test $APPLE_UNIVERSAL_BUILD = 0; then
13173 for gltype
in ptrdiff_t size_t
; do
13174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
13175 $as_echo_n "checking for bit size of $gltype... " >&6; }
13176 if eval \
${gl_cv_bitsizeof_${gltype}+:} false
; then :
13177 $as_echo_n "(cached) " >&6
13179 if ac_fn_c_compute_int
"$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
13180 #include <stddef.h>
13181 #include <signal.h>
13183 # include <wchar.h>
13186 #include <limits.h>"; then :
13192 eval gl_cv_bitsizeof_
${gltype}=\
$result
13195 eval ac_res
=\
$gl_cv_bitsizeof_${gltype}
13196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
13197 $as_echo "$ac_res" >&6; }
13198 eval result
=\
$gl_cv_bitsizeof_${gltype}
13199 if test $result = unknown
; then
13202 GLTYPE
=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
13203 cat >>confdefs.h
<<_ACEOF
13204 #define BITSIZEOF_${GLTYPE} $result
13207 eval BITSIZEOF_
${GLTYPE}=\
$result
13214 for gltype
in sig_atomic_t wchar_t wint_t
; do
13215 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
13216 $as_echo_n "checking for bit size of $gltype... " >&6; }
13217 if eval \
${gl_cv_bitsizeof_${gltype}+:} false
; then :
13218 $as_echo_n "(cached) " >&6
13220 if ac_fn_c_compute_int
"$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
13221 #include <stddef.h>
13222 #include <signal.h>
13224 # include <wchar.h>
13227 #include <limits.h>"; then :
13233 eval gl_cv_bitsizeof_
${gltype}=\
$result
13236 eval ac_res
=\
$gl_cv_bitsizeof_${gltype}
13237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
13238 $as_echo "$ac_res" >&6; }
13239 eval result
=\
$gl_cv_bitsizeof_${gltype}
13240 if test $result = unknown
; then
13243 GLTYPE
=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
13244 cat >>confdefs.h
<<_ACEOF
13245 #define BITSIZEOF_${GLTYPE} $result
13248 eval BITSIZEOF_
${GLTYPE}=\
$result
13254 for gltype
in sig_atomic_t wchar_t wint_t
; do
13255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
13256 $as_echo_n "checking whether $gltype is signed... " >&6; }
13257 if eval \
${gl_cv_type_${gltype}_signed+:} false
; then :
13258 $as_echo_n "(cached) " >&6
13260 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
13261 /* end confdefs.h. */
13263 #include <stddef.h>
13264 #include <signal.h>
13266 # include <wchar.h>
13269 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
13278 if ac_fn_c_try_compile
"$LINENO"; then :
13283 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
13284 eval gl_cv_type_
${gltype}_signed
=\
$result
13287 eval ac_res
=\
$gl_cv_type_${gltype}_signed
13288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
13289 $as_echo "$ac_res" >&6; }
13290 eval result
=\
$gl_cv_type_${gltype}_signed
13291 GLTYPE
=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
13292 if test "$result" = yes; then
13293 cat >>confdefs.h
<<_ACEOF
13294 #define HAVE_SIGNED_${GLTYPE} 1
13297 eval HAVE_SIGNED_
${GLTYPE}=1
13299 eval HAVE_SIGNED_
${GLTYPE}=0
13304 gl_cv_type_ptrdiff_t_signed
=yes
13305 gl_cv_type_size_t_signed
=no
13306 if test $APPLE_UNIVERSAL_BUILD = 0; then
13309 for gltype
in ptrdiff_t size_t
; do
13310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
13311 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
13312 if eval \
${gl_cv_type_${gltype}_suffix+:} false
; then :
13313 $as_echo_n "(cached) " >&6
13315 eval gl_cv_type_
${gltype}_suffix
=no
13316 eval result
=\
$gl_cv_type_${gltype}_signed
13317 if test "$result" = yes; then
13322 for glsuf
in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64
; do
13324 '') gltype1
='int';;
13325 l
) gltype1
='long int';;
13326 ll
) gltype1
='long long int';;
13327 i64
) gltype1
='__int64';;
13328 u
) gltype1
='unsigned int';;
13329 ul
) gltype1
='unsigned long int';;
13330 ull
) gltype1
='unsigned long long int';;
13331 ui64
)gltype1
='unsigned __int64';;
13333 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
13334 /* end confdefs.h. */
13336 #include <stddef.h>
13337 #include <signal.h>
13339 # include <wchar.h>
13342 extern $gltype foo;
13343 extern $gltype1 foo;
13352 if ac_fn_c_try_compile
"$LINENO"; then :
13353 eval gl_cv_type_
${gltype}_suffix
=\
$glsuf
13355 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
13356 eval result
=\
$gl_cv_type_${gltype}_suffix
13357 test "$result" != no
&& break
13360 eval ac_res
=\
$gl_cv_type_${gltype}_suffix
13361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
13362 $as_echo "$ac_res" >&6; }
13363 GLTYPE
=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
13364 eval result
=\
$gl_cv_type_${gltype}_suffix
13365 test "$result" = no
&& result
=
13366 eval ${GLTYPE}_SUFFIX
=\
$result
13367 cat >>confdefs.h
<<_ACEOF
13368 #define ${GLTYPE}_SUFFIX $result
13377 for gltype
in sig_atomic_t wchar_t wint_t
; do
13378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
13379 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
13380 if eval \
${gl_cv_type_${gltype}_suffix+:} false
; then :
13381 $as_echo_n "(cached) " >&6
13383 eval gl_cv_type_
${gltype}_suffix
=no
13384 eval result
=\
$gl_cv_type_${gltype}_signed
13385 if test "$result" = yes; then
13390 for glsuf
in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64
; do
13392 '') gltype1
='int';;
13393 l
) gltype1
='long int';;
13394 ll
) gltype1
='long long int';;
13395 i64
) gltype1
='__int64';;
13396 u
) gltype1
='unsigned int';;
13397 ul
) gltype1
='unsigned long int';;
13398 ull
) gltype1
='unsigned long long int';;
13399 ui64
)gltype1
='unsigned __int64';;
13401 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
13402 /* end confdefs.h. */
13404 #include <stddef.h>
13405 #include <signal.h>
13407 # include <wchar.h>
13410 extern $gltype foo;
13411 extern $gltype1 foo;
13420 if ac_fn_c_try_compile
"$LINENO"; then :
13421 eval gl_cv_type_
${gltype}_suffix
=\
$glsuf
13423 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
13424 eval result
=\
$gl_cv_type_${gltype}_suffix
13425 test "$result" != no
&& break
13428 eval ac_res
=\
$gl_cv_type_${gltype}_suffix
13429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
13430 $as_echo "$ac_res" >&6; }
13431 GLTYPE
=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
13432 eval result
=\
$gl_cv_type_${gltype}_suffix
13433 test "$result" = no
&& result
=
13434 eval ${GLTYPE}_SUFFIX
=\
$result
13435 cat >>confdefs.h
<<_ACEOF
13436 #define ${GLTYPE}_SUFFIX $result
13443 if test $GNULIB_OVERRIDES_WINT_T = 1; then
13444 BITSIZEOF_WINT_T
=32
13452 LIMITS_H
='limits.h'
13453 if test -n "$LIMITS_H"; then
13454 GL_GENERATE_LIMITS_H_TRUE
=
13455 GL_GENERATE_LIMITS_H_FALSE
='#'
13457 GL_GENERATE_LIMITS_H_TRUE
='#'
13458 GL_GENERATE_LIMITS_H_FALSE
=
13467 if test -n "$STDINT_H"; then
13468 GL_GENERATE_STDINT_H_TRUE
=
13469 GL_GENERATE_STDINT_H_FALSE
='#'
13471 GL_GENERATE_STDINT_H_TRUE
='#'
13472 GL_GENERATE_STDINT_H_FALSE
=
13479 GNULIB_STRTOIMAX
=0;
13480 GNULIB_STRTOUMAX
=0;
13481 HAVE_DECL_IMAXABS
=1;
13482 HAVE_DECL_IMAXDIV
=1;
13483 HAVE_DECL_STRTOIMAX
=1;
13484 HAVE_DECL_STRTOUMAX
=1;
13486 REPLACE_STRTOIMAX
=0;
13487 REPLACE_STRTOUMAX
=0;
13488 INT32_MAX_LT_INTMAX_MAX
=1;
13489 INT64_MAX_EQ_LONG_MAX
='defined _LP64';
13490 PRIPTR_PREFIX
=__PRIPTR_PREFIX
;
13491 UINT32_MAX_LT_UINTMAX_MAX
=1;
13492 UINT64_MAX_EQ_ULONG_MAX
='defined _LP64';
13508 if test $gl_cv_have_include_next = yes; then
13509 gl_cv_next_inttypes_h
='<'inttypes.h
'>'
13511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
13512 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
13513 if ${gl_cv_next_inttypes_h+:} false
; then :
13514 $as_echo_n "(cached) " >&6
13517 if test $ac_cv_header_inttypes_h = yes; then
13522 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
13523 /* end confdefs.h. */
13524 #include <inttypes.h>
13527 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
13528 *) gl_absname_cpp
="$ac_cpp" ;;
13533 gl_dirsep_regex
='[/\\]'
13536 gl_dirsep_regex
='\/'
13539 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
13540 gl_header_literal_regex
=`echo 'inttypes.h' \
13541 | sed -e "$gl_make_literal_regex_sed"`
13542 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
13543 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
13549 gl_cv_absolute_inttypes_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
13550 sed -n "$gl_absolute_header_sed"`
13552 gl_header
=$gl_cv_absolute_inttypes_h
13553 gl_cv_next_inttypes_h
='"'$gl_header'"'
13555 gl_cv_next_inttypes_h
='<'inttypes.h
'>'
13560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
13561 $as_echo "$gl_cv_next_inttypes_h" >&6; }
13563 NEXT_INTTYPES_H
=$gl_cv_next_inttypes_h
13565 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
13566 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
13567 gl_next_as_first_directive
='<'inttypes.h
'>'
13569 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
13570 gl_next_as_first_directive
=$gl_cv_next_inttypes_h
13572 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
=$gl_next_as_first_directive
13589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'double'" >&5
13590 $as_echo_n "checking where to find the exponent in a 'double'... " >&6; }
13591 if ${gl_cv_cc_double_expbit0+:} false
; then :
13592 $as_echo_n "(cached) " >&6
13595 if test "$cross_compiling" = yes; then :
13597 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
13598 /* end confdefs.h. */
13600 #if defined arm || defined __arm || defined __arm__
13605 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13606 $EGREP "mixed_endianness" >/dev
/null
2>&1; then :
13607 gl_cv_cc_double_expbit0
="unknown"
13611 if ${ac_cv_c_bigendian+:} false
; then :
13612 $as_echo_n "(cached) " >&6
13614 ac_cv_c_bigendian
=unknown
13615 # See if we're dealing with a universal compiler.
13616 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
13617 /* end confdefs.h. */
13618 #ifndef __APPLE_CC__
13619 not a universal capable compiler
13624 if ac_fn_c_try_compile
"$LINENO"; then :
13626 # Check for potential -arch flags. It is not universal unless
13627 # there are at least two -arch flags with different values.
13630 for ac_word
in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
13631 if test -n "$ac_prev"; then
13633 i?
86 | x86_64 | ppc | ppc64
)
13634 if test -z "$ac_arch" ||
test "$ac_arch" = "$ac_word"; then
13637 ac_cv_c_bigendian
=universal
13643 elif test "x$ac_word" = "x-arch"; then
13648 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
13649 if test $ac_cv_c_bigendian = unknown
; then
13650 # See if sys/param.h defines the BYTE_ORDER macro.
13651 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
13652 /* end confdefs.h. */
13653 #include <sys/types.h>
13654 #include <sys/param.h>
13659 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
13660 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
13662 bogus endian macros
13669 if ac_fn_c_try_compile
"$LINENO"; then :
13670 # It does; now see whether it defined to BIG_ENDIAN or not.
13671 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
13672 /* end confdefs.h. */
13673 #include <sys/types.h>
13674 #include <sys/param.h>
13679 #if BYTE_ORDER != BIG_ENDIAN
13687 if ac_fn_c_try_compile
"$LINENO"; then :
13688 ac_cv_c_bigendian
=yes
13690 ac_cv_c_bigendian
=no
13692 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
13694 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
13696 if test $ac_cv_c_bigendian = unknown
; then
13697 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
13698 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
13699 /* end confdefs.h. */
13700 #include <limits.h>
13705 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
13706 bogus endian macros
13713 if ac_fn_c_try_compile
"$LINENO"; then :
13714 # It does; now see whether it defined to _BIG_ENDIAN or not.
13715 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
13716 /* end confdefs.h. */
13717 #include <limits.h>
13722 #ifndef _BIG_ENDIAN
13730 if ac_fn_c_try_compile
"$LINENO"; then :
13731 ac_cv_c_bigendian
=yes
13733 ac_cv_c_bigendian
=no
13735 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
13737 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
13739 if test $ac_cv_c_bigendian = unknown
; then
13740 # Compile a test program.
13741 if test "$cross_compiling" = yes; then :
13742 # Try to guess by grepping values from an object file.
13743 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
13744 /* end confdefs.h. */
13745 short int ascii_mm[] =
13746 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
13747 short int ascii_ii[] =
13748 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
13749 int use_ascii (int i) {
13750 return ascii_mm[i] + ascii_ii[i];
13752 short int ebcdic_ii[] =
13753 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
13754 short int ebcdic_mm[] =
13755 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
13756 int use_ebcdic (int i) {
13757 return ebcdic_mm[i] + ebcdic_ii[i];
13764 return use_ascii (foo) == use_ebcdic (foo);
13769 if ac_fn_c_try_compile
"$LINENO"; then :
13770 if grep BIGenDianSyS conftest.
$ac_objext >/dev
/null
; then
13771 ac_cv_c_bigendian
=yes
13773 if grep LiTTleEnDian conftest.
$ac_objext >/dev
/null
; then
13774 if test "$ac_cv_c_bigendian" = unknown
; then
13775 ac_cv_c_bigendian
=no
13777 # finding both strings is unlikely to happen, but who knows?
13778 ac_cv_c_bigendian
=unknown
13782 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
13784 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
13785 /* end confdefs.h. */
13786 $ac_includes_default
13791 /* Are we little or big endian? From Harbison&Steele. */
13795 char c[sizeof (long int)];
13798 return u.c[sizeof (long int) - 1] == 1;
13804 if ac_fn_c_try_run
"$LINENO"; then :
13805 ac_cv_c_bigendian
=no
13807 ac_cv_c_bigendian
=yes
13809 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
13810 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
13816 case $ac_cv_c_bigendian in #(
13818 gl_cv_cc_double_expbit0
="word 0 bit 20";; #(
13820 gl_cv_cc_double_expbit0
="word 1 bit 20" ;; #(
13823 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
13827 gl_cv_cc_double_expbit0
="unknown" ;;
13836 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
13837 /* end confdefs.h. */
13840 #include <stddef.h>
13842 #include <string.h>
13844 ((sizeof (double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
13845 typedef union { double value; unsigned int word[NWORDS]; } memory_double;
13846 static unsigned int ored_words[NWORDS];
13847 static unsigned int anded_words[NWORDS];
13848 static void add_to_ored_words (double x)
13852 /* Clear it first, in case sizeof (double) < sizeof (memory_double). */
13853 memset (&m, 0, sizeof (memory_double));
13855 for (i = 0; i < NWORDS; i++)
13857 ored_words[i] |= m.word[i];
13858 anded_words[i] &= m.word[i];
13864 FILE *fp = fopen ("conftest.out", "w");
13867 for (j = 0; j < NWORDS; j++)
13868 anded_words[j] = ~ (unsigned int) 0;
13869 add_to_ored_words (0.25);
13870 add_to_ored_words (0.5);
13871 add_to_ored_words (1.0);
13872 add_to_ored_words (2.0);
13873 add_to_ored_words (4.0);
13874 /* Remove bits that are common (e.g. if representation of the first mantissa
13875 bit is explicit). */
13876 for (j = 0; j < NWORDS; j++)
13877 ored_words[j] &= ~anded_words[j];
13878 /* Now find the nonzero word. */
13879 for (j = 0; j < NWORDS; j++)
13880 if (ored_words[j] != 0)
13885 for (i = j + 1; i < NWORDS; i++)
13886 if (ored_words[i] != 0)
13888 fprintf (fp, "unknown");
13889 return (fclose (fp) != 0);
13892 if ((ored_words[j] >> i) & 1)
13894 fprintf (fp, "word %d bit %d", (int) j, (int) i);
13895 return (fclose (fp) != 0);
13898 fprintf (fp, "unknown");
13899 return (fclose (fp) != 0);
13903 if ac_fn_c_try_run
"$LINENO"; then :
13904 gl_cv_cc_double_expbit0
=`cat conftest.out`
13906 gl_cv_cc_double_expbit0
="unknown"
13908 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
13909 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
13915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_double_expbit0" >&5
13916 $as_echo "$gl_cv_cc_double_expbit0" >&6; }
13917 case "$gl_cv_cc_double_expbit0" in
13919 word
=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
13920 bit
=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word.*bit //'`
13922 cat >>confdefs.h
<<_ACEOF
13923 #define DBL_EXPBIT0_WORD $word
13927 cat >>confdefs.h
<<_ACEOF
13928 #define DBL_EXPBIT0_BIT $bit
13935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
13936 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
13937 if ${ac_cv_c_bigendian+:} false
; then :
13938 $as_echo_n "(cached) " >&6
13940 ac_cv_c_bigendian
=unknown
13941 # See if we're dealing with a universal compiler.
13942 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
13943 /* end confdefs.h. */
13944 #ifndef __APPLE_CC__
13945 not a universal capable compiler
13950 if ac_fn_c_try_compile
"$LINENO"; then :
13952 # Check for potential -arch flags. It is not universal unless
13953 # there are at least two -arch flags with different values.
13956 for ac_word
in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
13957 if test -n "$ac_prev"; then
13959 i?
86 | x86_64 | ppc | ppc64
)
13960 if test -z "$ac_arch" ||
test "$ac_arch" = "$ac_word"; then
13963 ac_cv_c_bigendian
=universal
13969 elif test "x$ac_word" = "x-arch"; then
13974 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
13975 if test $ac_cv_c_bigendian = unknown
; then
13976 # See if sys/param.h defines the BYTE_ORDER macro.
13977 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
13978 /* end confdefs.h. */
13979 #include <sys/types.h>
13980 #include <sys/param.h>
13985 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
13986 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
13988 bogus endian macros
13995 if ac_fn_c_try_compile
"$LINENO"; then :
13996 # It does; now see whether it defined to BIG_ENDIAN or not.
13997 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
13998 /* end confdefs.h. */
13999 #include <sys/types.h>
14000 #include <sys/param.h>
14005 #if BYTE_ORDER != BIG_ENDIAN
14013 if ac_fn_c_try_compile
"$LINENO"; then :
14014 ac_cv_c_bigendian
=yes
14016 ac_cv_c_bigendian
=no
14018 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
14020 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
14022 if test $ac_cv_c_bigendian = unknown
; then
14023 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
14024 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14025 /* end confdefs.h. */
14026 #include <limits.h>
14031 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
14032 bogus endian macros
14039 if ac_fn_c_try_compile
"$LINENO"; then :
14040 # It does; now see whether it defined to _BIG_ENDIAN or not.
14041 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14042 /* end confdefs.h. */
14043 #include <limits.h>
14048 #ifndef _BIG_ENDIAN
14056 if ac_fn_c_try_compile
"$LINENO"; then :
14057 ac_cv_c_bigendian
=yes
14059 ac_cv_c_bigendian
=no
14061 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
14063 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
14065 if test $ac_cv_c_bigendian = unknown
; then
14066 # Compile a test program.
14067 if test "$cross_compiling" = yes; then :
14068 # Try to guess by grepping values from an object file.
14069 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14070 /* end confdefs.h. */
14071 short int ascii_mm[] =
14072 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
14073 short int ascii_ii[] =
14074 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
14075 int use_ascii (int i) {
14076 return ascii_mm[i] + ascii_ii[i];
14078 short int ebcdic_ii[] =
14079 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
14080 short int ebcdic_mm[] =
14081 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
14082 int use_ebcdic (int i) {
14083 return ebcdic_mm[i] + ebcdic_ii[i];
14090 return use_ascii (foo) == use_ebcdic (foo);
14095 if ac_fn_c_try_compile
"$LINENO"; then :
14096 if grep BIGenDianSyS conftest.
$ac_objext >/dev
/null
; then
14097 ac_cv_c_bigendian
=yes
14099 if grep LiTTleEnDian conftest.
$ac_objext >/dev
/null
; then
14100 if test "$ac_cv_c_bigendian" = unknown
; then
14101 ac_cv_c_bigendian
=no
14103 # finding both strings is unlikely to happen, but who knows?
14104 ac_cv_c_bigendian
=unknown
14108 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
14110 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14111 /* end confdefs.h. */
14112 $ac_includes_default
14117 /* Are we little or big endian? From Harbison&Steele. */
14121 char c[sizeof (long int)];
14124 return u.c[sizeof (long int) - 1] == 1;
14130 if ac_fn_c_try_run
"$LINENO"; then :
14131 ac_cv_c_bigendian
=no
14133 ac_cv_c_bigendian
=yes
14135 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
14136 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
14141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
14142 $as_echo "$ac_cv_c_bigendian" >&6; }
14143 case $ac_cv_c_bigendian in #(
14145 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
14151 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
14155 as_fn_error $?
"unknown endianness
14156 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
14161 GNULIB_LOCALECONV
=0;
14162 GNULIB_SETLOCALE
=0;
14163 GNULIB_SETLOCALE_NULL
=0;
14164 GNULIB_DUPLOCALE
=0;
14165 GNULIB_LOCALENAME
=0;
14169 REPLACE_LOCALECONV
=0;
14170 REPLACE_SETLOCALE
=0;
14171 REPLACE_NEWLOCALE
=0;
14172 REPLACE_DUPLOCALE
=0;
14173 REPLACE_FREELOCALE
=0;
14174 REPLACE_STRUCT_LCONV
=0;
14178 HAVE_MAX_ALIGN_T
=1;
14182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
14183 $as_echo_n "checking for wchar_t... " >&6; }
14184 if ${gt_cv_c_wchar_t+:} false
; then :
14185 $as_echo_n "(cached) " >&6
14187 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14188 /* end confdefs.h. */
14189 #include <stddef.h>
14190 wchar_t foo = (wchar_t)'\0';
14199 if ac_fn_c_try_compile
"$LINENO"; then :
14200 gt_cv_c_wchar_t
=yes
14204 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
14206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
14207 $as_echo "$gt_cv_c_wchar_t" >&6; }
14208 if test $gt_cv_c_wchar_t = yes; then
14210 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
14222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for good max_align_t" >&5
14223 $as_echo_n "checking for good max_align_t... " >&6; }
14224 if ${gl_cv_type_max_align_t+:} false
; then :
14225 $as_echo_n "(cached) " >&6
14227 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14228 /* end confdefs.h. */
14229 #include <stddef.h>
14230 unsigned int s = sizeof (max_align_t);
14231 #if defined __GNUC__ || defined __clang__ || defined __IBM__ALIGNOF__
14232 int check1[2 * (__alignof__ (double) <= __alignof__ (max_align_t)) - 1];
14233 int check2[2 * (__alignof__ (long double) <= __alignof__ (max_align_t)) - 1];
14235 typedef struct { char a; max_align_t b; } max_helper;
14236 typedef struct { char a; long b; } long_helper;
14237 typedef struct { char a; double b; } double_helper;
14238 typedef struct { char a; long double b; } long_double_helper;
14239 int check3[2 * (offsetof (long_helper, b) <= offsetof (max_helper, b)) - 1];
14240 int check4[2 * (offsetof (double_helper, b) <= offsetof (max_helper, b)) - 1];
14241 int check5[2 * (offsetof (long_double_helper, b) <= offsetof (max_helper, b)) - 1];
14251 if ac_fn_c_try_compile
"$LINENO"; then :
14252 gl_cv_type_max_align_t
=yes
14254 gl_cv_type_max_align_t
=no
14256 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
14259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_max_align_t" >&5
14260 $as_echo "$gl_cv_type_max_align_t" >&6; }
14261 if test $gl_cv_type_max_align_t = no
; then
14266 if test $gt_cv_c_wchar_t = no
; then
14271 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
14272 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
14273 if ${gl_cv_decl_null_works+:} false
; then :
14274 $as_echo_n "(cached) " >&6
14276 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14277 /* end confdefs.h. */
14278 #include <stddef.h>
14279 int test[2 * (sizeof NULL == sizeof (void *)) -1];
14289 if ac_fn_c_try_compile
"$LINENO"; then :
14290 gl_cv_decl_null_works
=yes
14292 gl_cv_decl_null_works
=no
14294 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
14296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
14297 $as_echo "$gl_cv_decl_null_works" >&6; }
14298 if test $gl_cv_decl_null_works = no
; then
14304 if test -n "$STDDEF_H"; then
14305 GL_GENERATE_STDDEF_H_TRUE
=
14306 GL_GENERATE_STDDEF_H_FALSE
='#'
14308 GL_GENERATE_STDDEF_H_TRUE
='#'
14309 GL_GENERATE_STDDEF_H_FALSE
=
14312 if test -n "$STDDEF_H"; then
14321 if test $gl_cv_have_include_next = yes; then
14322 gl_cv_next_stddef_h
='<'stddef.h
'>'
14324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
14325 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
14326 if ${gl_cv_next_stddef_h+:} false
; then :
14327 $as_echo_n "(cached) " >&6
14332 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14333 /* end confdefs.h. */
14334 #include <stddef.h>
14337 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
14338 *) gl_absname_cpp
="$ac_cpp" ;;
14343 gl_dirsep_regex
='[/\\]'
14346 gl_dirsep_regex
='\/'
14349 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
14350 gl_header_literal_regex
=`echo 'stddef.h' \
14351 | sed -e "$gl_make_literal_regex_sed"`
14352 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
14353 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
14359 gl_cv_absolute_stddef_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
14360 sed -n "$gl_absolute_header_sed"`
14362 gl_header
=$gl_cv_absolute_stddef_h
14363 gl_cv_next_stddef_h
='"'$gl_header'"'
14367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
14368 $as_echo "$gl_cv_next_stddef_h" >&6; }
14370 NEXT_STDDEF_H
=$gl_cv_next_stddef_h
14372 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
14373 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
14374 gl_next_as_first_directive
='<'stddef.h
'>'
14376 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
14377 gl_next_as_first_directive
=$gl_cv_next_stddef_h
14379 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
=$gl_next_as_first_directive
14391 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether locale.h defines locale_t" >&5
14392 $as_echo_n "checking whether locale.h defines locale_t... " >&6; }
14393 if ${gl_cv_header_locale_has_locale_t+:} false
; then :
14394 $as_echo_n "(cached) " >&6
14396 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14397 /* end confdefs.h. */
14398 #include <locale.h>
14408 if ac_fn_c_try_compile
"$LINENO"; then :
14409 gl_cv_header_locale_has_locale_t
=yes
14411 gl_cv_header_locale_has_locale_t
=no
14413 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
14416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_locale_has_locale_t" >&5
14417 $as_echo "$gl_cv_header_locale_has_locale_t" >&6; }
14420 if test $ac_cv_header_xlocale_h = yes; then
14422 if test $gl_cv_header_locale_has_locale_t = yes; then
14423 gl_cv_header_locale_h_needs_xlocale_h
=no
14425 gl_cv_header_locale_h_needs_xlocale_h
=yes
14430 gl_cv_header_locale_h_needs_xlocale_h
=no
14431 if test $gl_cv_header_locale_has_locale_t = yes; then
14441 gl_threads_api
=none
14446 if test "$gl_use_threads" != no
; then
14449 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether imported symbols can be declared weak" >&5
14450 $as_echo_n "checking whether imported symbols can be declared weak... " >&6; }
14451 if ${gl_cv_have_weak+:} false
; then :
14452 $as_echo_n "(cached) " >&6
14455 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14456 /* end confdefs.h. */
14457 extern void xyzzy ();
14467 if ac_fn_c_try_link
"$LINENO"; then :
14468 gl_cv_have_weak
=maybe
14470 rm -f core conftest.err conftest.
$ac_objext \
14471 conftest
$ac_exeext conftest.
$ac_ext
14472 if test $gl_cv_have_weak = maybe
; then
14473 if test "$cross_compiling" = yes; then :
14474 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14475 /* end confdefs.h. */
14477 Extensible Linking Format
14481 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14482 $EGREP "Extensible Linking Format" >/dev
/null
2>&1; then :
14483 gl_cv_have_weak
="guessing yes"
14485 gl_cv_have_weak
="guessing no"
14491 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14492 /* end confdefs.h. */
14498 return (fputs == NULL);
14501 if ac_fn_c_try_run
"$LINENO"; then :
14502 gl_cv_have_weak
=yes
14506 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
14507 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
14511 case " $LDFLAGS " in
14512 *" -static "*) gl_cv_have_weak
=no
;;
14514 case "$gl_cv_have_weak" in
14517 freebsd
* | dragonfly
*)
14519 $CC $CPPFLAGS $CFLAGS $LDFLAGS -fPIC -shared -o libempty.so conftest1.c
-lpthread >&5 2>&1
14520 cat <<EOF > conftest2.c
14521 #include <pthread.h>
14522 #pragma weak pthread_mutexattr_gettype
14525 return (pthread_mutexattr_gettype != NULL);
14528 $CC $CPPFLAGS $CFLAGS $LDFLAGS -o conftest conftest2.c libempty.so
>&5 2>&1 \
14529 || gl_cv_have_weak
=no
14530 rm -f conftest1.c libempty.so conftest2.c conftest
14537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_weak" >&5
14538 $as_echo "$gl_cv_have_weak" >&6; }
14539 case "$gl_cv_have_weak" in
14542 $as_echo "#define HAVE_WEAK_SYMBOLS 1" >>confdefs.h
14547 if case "$gl_cv_have_weak" in *yes) true
;; *) false
;; esac; then
14551 if test "$gl_use_threads" = isoc ||
test "$gl_use_threads" = isoc
+posix
; then
14553 gl_have_isoc_threads
="$ac_cv_header_threads_h"
14555 if test "$gl_use_threads" = yes \
14556 ||
test "$gl_use_threads" = posix \
14557 ||
test "$gl_use_threads" = isoc
+posix
; then
14560 if test -z "$gl_pthreadlib_body_done"; then
14564 # On OSF/1, the compiler needs the flag -pthread or -D_REENTRANT so that
14565 # it groks <pthread.h>. It's added above, in gl_ANYTHREADLIB_EARLY.
14566 ac_fn_c_check_header_mongrel
"$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
14567 if test "x$ac_cv_header_pthread_h" = xyes
; then :
14568 gl_have_pthread_h
=yes
14570 gl_have_pthread_h
=no
14574 if test "$gl_have_pthread_h" = yes; then
14575 # Other possible tests:
14576 # -lpthreads (FSU threads, PCthreads)
14578 # Test whether both pthread_mutex_lock and pthread_mutexattr_init exist
14579 # in libc. IRIX 6.5 has the first one in both libc and libpthread, but
14580 # the second one only in libpthread, and lock.c needs it.
14582 # If -pthread works, prefer it to -lpthread, since Ubuntu 14.04
14583 # needs -pthread for some reason. See:
14584 # https://lists.gnu.org/r/bug-gnulib/2014-09/msg00023.html
14586 for gl_pthread
in '' '-pthread'; do
14587 LIBS
="$LIBS $gl_pthread"
14588 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14589 /* end confdefs.h. */
14590 #include <pthread.h>
14592 pthread_mutexattr_t ma;
14597 pthread_mutex_lock (&m);
14598 pthread_mutexattr_init (&ma);
14603 if ac_fn_c_try_link
"$LINENO"; then :
14605 LIBPTHREAD
=$gl_pthread
14606 LIBPMULTITHREAD
=$gl_pthread
14608 rm -f core conftest.err conftest.
$ac_objext \
14609 conftest
$ac_exeext conftest.
$ac_ext
14611 test $gl_pthread_api = yes && break
14614 # Test for libpthread by looking for pthread_kill. (Not pthread_self,
14615 # since it is defined as a macro on OSF/1.)
14616 if test $gl_pthread_api = yes && test -z "$LIBPTHREAD"; then
14617 # The program links fine without libpthread. But it may actually
14618 # need to link with libpthread in order to create multiple threads.
14619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lpthread" >&5
14620 $as_echo_n "checking for pthread_kill in -lpthread... " >&6; }
14621 if ${ac_cv_lib_pthread_pthread_kill+:} false
; then :
14622 $as_echo_n "(cached) " >&6
14624 ac_check_lib_save_LIBS
=$LIBS
14625 LIBS
="-lpthread $LIBS"
14626 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14627 /* end confdefs.h. */
14629 /* Override any GCC internal prototype to avoid an error.
14630 Use char because int might match the return type of a GCC
14631 builtin and then its argument prototype would still apply. */
14635 char pthread_kill ();
14639 return pthread_kill ();
14644 if ac_fn_c_try_link
"$LINENO"; then :
14645 ac_cv_lib_pthread_pthread_kill
=yes
14647 ac_cv_lib_pthread_pthread_kill
=no
14649 rm -f core conftest.err conftest.
$ac_objext \
14650 conftest
$ac_exeext conftest.
$ac_ext
14651 LIBS
=$ac_check_lib_save_LIBS
14653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_kill" >&5
14654 $as_echo "$ac_cv_lib_pthread_pthread_kill" >&6; }
14655 if test "x$ac_cv_lib_pthread_pthread_kill" = xyes
; then :
14656 LIBPMULTITHREAD
=-lpthread
14657 # On Solaris and HP-UX, most pthread functions exist also in libc.
14658 # Therefore pthread_in_use() needs to actually try to create a
14659 # thread: pthread_create from libc will fail, whereas
14660 # pthread_create will actually create a thread.
14661 # On Solaris 10 or newer, this test is no longer needed, because
14662 # libc contains the fully functional pthread functions.
14664 solaris | solaris2.1
-9 | solaris2.1
-9.
* | hpux
*)
14666 $as_echo "#define PTHREAD_IN_USE_DETECTION_HARD 1" >>confdefs.h
14672 elif test $gl_pthread_api != yes; then
14673 # Some library is needed. Try libpthread and libc_r.
14674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lpthread" >&5
14675 $as_echo_n "checking for pthread_kill in -lpthread... " >&6; }
14676 if ${ac_cv_lib_pthread_pthread_kill+:} false
; then :
14677 $as_echo_n "(cached) " >&6
14679 ac_check_lib_save_LIBS
=$LIBS
14680 LIBS
="-lpthread $LIBS"
14681 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14682 /* end confdefs.h. */
14684 /* Override any GCC internal prototype to avoid an error.
14685 Use char because int might match the return type of a GCC
14686 builtin and then its argument prototype would still apply. */
14690 char pthread_kill ();
14694 return pthread_kill ();
14699 if ac_fn_c_try_link
"$LINENO"; then :
14700 ac_cv_lib_pthread_pthread_kill
=yes
14702 ac_cv_lib_pthread_pthread_kill
=no
14704 rm -f core conftest.err conftest.
$ac_objext \
14705 conftest
$ac_exeext conftest.
$ac_ext
14706 LIBS
=$ac_check_lib_save_LIBS
14708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_kill" >&5
14709 $as_echo "$ac_cv_lib_pthread_pthread_kill" >&6; }
14710 if test "x$ac_cv_lib_pthread_pthread_kill" = xyes
; then :
14712 LIBPTHREAD
=-lpthread
14713 LIBPMULTITHREAD
=-lpthread
14716 if test $gl_pthread_api != yes; then
14718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lc_r" >&5
14719 $as_echo_n "checking for pthread_kill in -lc_r... " >&6; }
14720 if ${ac_cv_lib_c_r_pthread_kill+:} false
; then :
14721 $as_echo_n "(cached) " >&6
14723 ac_check_lib_save_LIBS
=$LIBS
14725 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14726 /* end confdefs.h. */
14728 /* Override any GCC internal prototype to avoid an error.
14729 Use char because int might match the return type of a GCC
14730 builtin and then its argument prototype would still apply. */
14734 char pthread_kill ();
14738 return pthread_kill ();
14743 if ac_fn_c_try_link
"$LINENO"; then :
14744 ac_cv_lib_c_r_pthread_kill
=yes
14746 ac_cv_lib_c_r_pthread_kill
=no
14748 rm -f core conftest.err conftest.
$ac_objext \
14749 conftest
$ac_exeext conftest.
$ac_ext
14750 LIBS
=$ac_check_lib_save_LIBS
14752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_pthread_kill" >&5
14753 $as_echo "$ac_cv_lib_c_r_pthread_kill" >&6; }
14754 if test "x$ac_cv_lib_c_r_pthread_kill" = xyes
; then :
14757 LIBPMULTITHREAD
=-lc_r
14763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether POSIX threads API is available" >&5
14764 $as_echo_n "checking whether POSIX threads API is available... " >&6; }
14765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_pthread_api" >&5
14766 $as_echo "$gl_pthread_api" >&6; }
14769 if test $gl_pthread_api = yes; then
14771 $as_echo "#define HAVE_PTHREAD_API 1" >>confdefs.h
14775 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14776 /* end confdefs.h. */
14786 if ac_fn_c_try_link
"$LINENO"; then :
14790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sched_yield in -lrt" >&5
14791 $as_echo_n "checking for sched_yield in -lrt... " >&6; }
14792 if ${ac_cv_lib_rt_sched_yield+:} false
; then :
14793 $as_echo_n "(cached) " >&6
14795 ac_check_lib_save_LIBS
=$LIBS
14797 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14798 /* end confdefs.h. */
14800 /* Override any GCC internal prototype to avoid an error.
14801 Use char because int might match the return type of a GCC
14802 builtin and then its argument prototype would still apply. */
14806 char sched_yield ();
14810 return sched_yield ();
14815 if ac_fn_c_try_link
"$LINENO"; then :
14816 ac_cv_lib_rt_sched_yield
=yes
14818 ac_cv_lib_rt_sched_yield
=no
14820 rm -f core conftest.err conftest.
$ac_objext \
14821 conftest
$ac_exeext conftest.
$ac_ext
14822 LIBS
=$ac_check_lib_save_LIBS
14824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_sched_yield" >&5
14825 $as_echo "$ac_cv_lib_rt_sched_yield" >&6; }
14826 if test "x$ac_cv_lib_rt_sched_yield" = xyes
; then :
14827 LIB_SCHED_YIELD
=-lrt
14829 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sched_yield in -lposix4" >&5
14830 $as_echo_n "checking for sched_yield in -lposix4... " >&6; }
14831 if ${ac_cv_lib_posix4_sched_yield+:} false
; then :
14832 $as_echo_n "(cached) " >&6
14834 ac_check_lib_save_LIBS
=$LIBS
14835 LIBS
="-lposix4 $LIBS"
14836 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14837 /* end confdefs.h. */
14839 /* Override any GCC internal prototype to avoid an error.
14840 Use char because int might match the return type of a GCC
14841 builtin and then its argument prototype would still apply. */
14845 char sched_yield ();
14849 return sched_yield ();
14854 if ac_fn_c_try_link
"$LINENO"; then :
14855 ac_cv_lib_posix4_sched_yield
=yes
14857 ac_cv_lib_posix4_sched_yield
=no
14859 rm -f core conftest.err conftest.
$ac_objext \
14860 conftest
$ac_exeext conftest.
$ac_ext
14861 LIBS
=$ac_check_lib_save_LIBS
14863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix4_sched_yield" >&5
14864 $as_echo "$ac_cv_lib_posix4_sched_yield" >&6; }
14865 if test "x$ac_cv_lib_posix4_sched_yield" = xyes
; then :
14866 LIB_SCHED_YIELD
=-lposix4
14873 rm -f core conftest.err conftest.
$ac_objext \
14874 conftest
$ac_exeext conftest.
$ac_ext
14877 gl_pthreadlib_body_done
=done
14880 LIBTHREAD
=$LIBPTHREAD LTLIBTHREAD
=$LIBPTHREAD
14881 LIBMULTITHREAD
=$LIBPMULTITHREAD LTLIBMULTITHREAD
=$LIBPMULTITHREAD
14882 if test $gl_pthread_api = yes; then
14883 if test "$gl_use_threads" = isoc
+posix
&& test "$gl_have_isoc_threads" = yes; then
14884 gl_threads_api
='isoc+posix'
14886 $as_echo "#define USE_ISOC_AND_POSIX_THREADS 1" >>confdefs.h
14888 LIBTHREAD
= LTLIBTHREAD
=
14890 gl_threads_api
=posix
14892 $as_echo "#define USE_POSIX_THREADS 1" >>confdefs.h
14894 if test -n "$LIBMULTITHREAD" ||
test -n "$LTLIBMULTITHREAD"; then
14895 if case "$gl_cv_have_weak" in *yes) true
;; *) false
;; esac; then
14897 $as_echo "#define USE_POSIX_THREADS_WEAK 1" >>confdefs.h
14899 LIBTHREAD
= LTLIBTHREAD
=
14902 freebsd
* | dragonfly
*)
14903 if test "x$LIBTHREAD" != "x$LIBMULTITHREAD"; then
14905 $as_echo "#define PTHREAD_IN_USE_DETECTION_HARD 1" >>confdefs.h
14915 if test $gl_threads_api = none
; then
14916 if test "$gl_use_threads" = isoc
&& test "$gl_have_isoc_threads" = yes; then
14920 if test -z "$gl_stdthreadlib_body_done"; then
14930 if test -z "$gl_pthreadlib_body_done"; then
14934 # On OSF/1, the compiler needs the flag -pthread or -D_REENTRANT so that
14935 # it groks <pthread.h>. It's added above, in gl_ANYTHREADLIB_EARLY.
14936 ac_fn_c_check_header_mongrel
"$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
14937 if test "x$ac_cv_header_pthread_h" = xyes
; then :
14938 gl_have_pthread_h
=yes
14940 gl_have_pthread_h
=no
14944 if test "$gl_have_pthread_h" = yes; then
14945 # Other possible tests:
14946 # -lpthreads (FSU threads, PCthreads)
14948 # Test whether both pthread_mutex_lock and pthread_mutexattr_init exist
14949 # in libc. IRIX 6.5 has the first one in both libc and libpthread, but
14950 # the second one only in libpthread, and lock.c needs it.
14952 # If -pthread works, prefer it to -lpthread, since Ubuntu 14.04
14953 # needs -pthread for some reason. See:
14954 # https://lists.gnu.org/r/bug-gnulib/2014-09/msg00023.html
14956 for gl_pthread
in '' '-pthread'; do
14957 LIBS
="$LIBS $gl_pthread"
14958 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14959 /* end confdefs.h. */
14960 #include <pthread.h>
14962 pthread_mutexattr_t ma;
14967 pthread_mutex_lock (&m);
14968 pthread_mutexattr_init (&ma);
14973 if ac_fn_c_try_link
"$LINENO"; then :
14975 LIBPTHREAD
=$gl_pthread
14976 LIBPMULTITHREAD
=$gl_pthread
14978 rm -f core conftest.err conftest.
$ac_objext \
14979 conftest
$ac_exeext conftest.
$ac_ext
14981 test $gl_pthread_api = yes && break
14984 # Test for libpthread by looking for pthread_kill. (Not pthread_self,
14985 # since it is defined as a macro on OSF/1.)
14986 if test $gl_pthread_api = yes && test -z "$LIBPTHREAD"; then
14987 # The program links fine without libpthread. But it may actually
14988 # need to link with libpthread in order to create multiple threads.
14989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lpthread" >&5
14990 $as_echo_n "checking for pthread_kill in -lpthread... " >&6; }
14991 if ${ac_cv_lib_pthread_pthread_kill+:} false
; then :
14992 $as_echo_n "(cached) " >&6
14994 ac_check_lib_save_LIBS
=$LIBS
14995 LIBS
="-lpthread $LIBS"
14996 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
14997 /* end confdefs.h. */
14999 /* Override any GCC internal prototype to avoid an error.
15000 Use char because int might match the return type of a GCC
15001 builtin and then its argument prototype would still apply. */
15005 char pthread_kill ();
15009 return pthread_kill ();
15014 if ac_fn_c_try_link
"$LINENO"; then :
15015 ac_cv_lib_pthread_pthread_kill
=yes
15017 ac_cv_lib_pthread_pthread_kill
=no
15019 rm -f core conftest.err conftest.
$ac_objext \
15020 conftest
$ac_exeext conftest.
$ac_ext
15021 LIBS
=$ac_check_lib_save_LIBS
15023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_kill" >&5
15024 $as_echo "$ac_cv_lib_pthread_pthread_kill" >&6; }
15025 if test "x$ac_cv_lib_pthread_pthread_kill" = xyes
; then :
15026 LIBPMULTITHREAD
=-lpthread
15027 # On Solaris and HP-UX, most pthread functions exist also in libc.
15028 # Therefore pthread_in_use() needs to actually try to create a
15029 # thread: pthread_create from libc will fail, whereas
15030 # pthread_create will actually create a thread.
15031 # On Solaris 10 or newer, this test is no longer needed, because
15032 # libc contains the fully functional pthread functions.
15034 solaris | solaris2.1
-9 | solaris2.1
-9.
* | hpux
*)
15036 $as_echo "#define PTHREAD_IN_USE_DETECTION_HARD 1" >>confdefs.h
15042 elif test $gl_pthread_api != yes; then
15043 # Some library is needed. Try libpthread and libc_r.
15044 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lpthread" >&5
15045 $as_echo_n "checking for pthread_kill in -lpthread... " >&6; }
15046 if ${ac_cv_lib_pthread_pthread_kill+:} false
; then :
15047 $as_echo_n "(cached) " >&6
15049 ac_check_lib_save_LIBS
=$LIBS
15050 LIBS
="-lpthread $LIBS"
15051 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
15052 /* end confdefs.h. */
15054 /* Override any GCC internal prototype to avoid an error.
15055 Use char because int might match the return type of a GCC
15056 builtin and then its argument prototype would still apply. */
15060 char pthread_kill ();
15064 return pthread_kill ();
15069 if ac_fn_c_try_link
"$LINENO"; then :
15070 ac_cv_lib_pthread_pthread_kill
=yes
15072 ac_cv_lib_pthread_pthread_kill
=no
15074 rm -f core conftest.err conftest.
$ac_objext \
15075 conftest
$ac_exeext conftest.
$ac_ext
15076 LIBS
=$ac_check_lib_save_LIBS
15078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_kill" >&5
15079 $as_echo "$ac_cv_lib_pthread_pthread_kill" >&6; }
15080 if test "x$ac_cv_lib_pthread_pthread_kill" = xyes
; then :
15082 LIBPTHREAD
=-lpthread
15083 LIBPMULTITHREAD
=-lpthread
15086 if test $gl_pthread_api != yes; then
15088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lc_r" >&5
15089 $as_echo_n "checking for pthread_kill in -lc_r... " >&6; }
15090 if ${ac_cv_lib_c_r_pthread_kill+:} false
; then :
15091 $as_echo_n "(cached) " >&6
15093 ac_check_lib_save_LIBS
=$LIBS
15095 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
15096 /* end confdefs.h. */
15098 /* Override any GCC internal prototype to avoid an error.
15099 Use char because int might match the return type of a GCC
15100 builtin and then its argument prototype would still apply. */
15104 char pthread_kill ();
15108 return pthread_kill ();
15113 if ac_fn_c_try_link
"$LINENO"; then :
15114 ac_cv_lib_c_r_pthread_kill
=yes
15116 ac_cv_lib_c_r_pthread_kill
=no
15118 rm -f core conftest.err conftest.
$ac_objext \
15119 conftest
$ac_exeext conftest.
$ac_ext
15120 LIBS
=$ac_check_lib_save_LIBS
15122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_pthread_kill" >&5
15123 $as_echo "$ac_cv_lib_c_r_pthread_kill" >&6; }
15124 if test "x$ac_cv_lib_c_r_pthread_kill" = xyes
; then :
15127 LIBPMULTITHREAD
=-lc_r
15133 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether POSIX threads API is available" >&5
15134 $as_echo_n "checking whether POSIX threads API is available... " >&6; }
15135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_pthread_api" >&5
15136 $as_echo "$gl_pthread_api" >&6; }
15139 if test $gl_pthread_api = yes; then
15141 $as_echo "#define HAVE_PTHREAD_API 1" >>confdefs.h
15145 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
15146 /* end confdefs.h. */
15156 if ac_fn_c_try_link
"$LINENO"; then :
15160 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sched_yield in -lrt" >&5
15161 $as_echo_n "checking for sched_yield in -lrt... " >&6; }
15162 if ${ac_cv_lib_rt_sched_yield+:} false
; then :
15163 $as_echo_n "(cached) " >&6
15165 ac_check_lib_save_LIBS
=$LIBS
15167 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
15168 /* end confdefs.h. */
15170 /* Override any GCC internal prototype to avoid an error.
15171 Use char because int might match the return type of a GCC
15172 builtin and then its argument prototype would still apply. */
15176 char sched_yield ();
15180 return sched_yield ();
15185 if ac_fn_c_try_link
"$LINENO"; then :
15186 ac_cv_lib_rt_sched_yield
=yes
15188 ac_cv_lib_rt_sched_yield
=no
15190 rm -f core conftest.err conftest.
$ac_objext \
15191 conftest
$ac_exeext conftest.
$ac_ext
15192 LIBS
=$ac_check_lib_save_LIBS
15194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_sched_yield" >&5
15195 $as_echo "$ac_cv_lib_rt_sched_yield" >&6; }
15196 if test "x$ac_cv_lib_rt_sched_yield" = xyes
; then :
15197 LIB_SCHED_YIELD
=-lrt
15199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sched_yield in -lposix4" >&5
15200 $as_echo_n "checking for sched_yield in -lposix4... " >&6; }
15201 if ${ac_cv_lib_posix4_sched_yield+:} false
; then :
15202 $as_echo_n "(cached) " >&6
15204 ac_check_lib_save_LIBS
=$LIBS
15205 LIBS
="-lposix4 $LIBS"
15206 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
15207 /* end confdefs.h. */
15209 /* Override any GCC internal prototype to avoid an error.
15210 Use char because int might match the return type of a GCC
15211 builtin and then its argument prototype would still apply. */
15215 char sched_yield ();
15219 return sched_yield ();
15224 if ac_fn_c_try_link
"$LINENO"; then :
15225 ac_cv_lib_posix4_sched_yield
=yes
15227 ac_cv_lib_posix4_sched_yield
=no
15229 rm -f core conftest.err conftest.
$ac_objext \
15230 conftest
$ac_exeext conftest.
$ac_ext
15231 LIBS
=$ac_check_lib_save_LIBS
15233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix4_sched_yield" >&5
15234 $as_echo "$ac_cv_lib_posix4_sched_yield" >&6; }
15235 if test "x$ac_cv_lib_posix4_sched_yield" = xyes
; then :
15236 LIB_SCHED_YIELD
=-lposix4
15243 rm -f core conftest.err conftest.
$ac_objext \
15244 conftest
$ac_exeext conftest.
$ac_ext
15247 gl_pthreadlib_body_done
=done
15250 if test $ac_cv_header_threads_h = yes; then
15251 for ac_func
in thrd_create
15253 ac_fn_c_check_func
"$LINENO" "thrd_create" "ac_cv_func_thrd_create"
15254 if test "x$ac_cv_func_thrd_create" = xyes
; then :
15255 cat >>confdefs.h
<<_ACEOF
15256 #define HAVE_THRD_CREATE 1
15262 if test $ac_cv_func_thrd_create = yes; then
15265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for thrd_create in -lstdthreads" >&5
15266 $as_echo_n "checking for thrd_create in -lstdthreads... " >&6; }
15267 if ${ac_cv_lib_stdthreads_thrd_create+:} false
; then :
15268 $as_echo_n "(cached) " >&6
15270 ac_check_lib_save_LIBS
=$LIBS
15271 LIBS
="-lstdthreads $LIBS"
15272 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
15273 /* end confdefs.h. */
15275 /* Override any GCC internal prototype to avoid an error.
15276 Use char because int might match the return type of a GCC
15277 builtin and then its argument prototype would still apply. */
15281 char thrd_create ();
15285 return thrd_create ();
15290 if ac_fn_c_try_link
"$LINENO"; then :
15291 ac_cv_lib_stdthreads_thrd_create
=yes
15293 ac_cv_lib_stdthreads_thrd_create
=no
15295 rm -f core conftest.err conftest.
$ac_objext \
15296 conftest
$ac_exeext conftest.
$ac_ext
15297 LIBS
=$ac_check_lib_save_LIBS
15299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_stdthreads_thrd_create" >&5
15300 $as_echo "$ac_cv_lib_stdthreads_thrd_create" >&6; }
15301 if test "x$ac_cv_lib_stdthreads_thrd_create" = xyes
; then :
15303 LIBSTDTHREAD
='-lstdthreads -lpthread'
15307 LIBSTDTHREAD
="$LIBPMULTITHREAD"
15313 LIBSTDTHREAD
="$LIBPMULTITHREAD $LIB_SCHED_YIELD"
15319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ISO C threads API is available" >&5
15320 $as_echo_n "checking whether ISO C threads API is available... " >&6; }
15321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_threads_h" >&5
15322 $as_echo "$ac_cv_header_threads_h" >&6; }
15323 gl_stdthreadlib_body_done
=done
15326 LIBTHREAD
=$LIBSTDTHREAD LTLIBTHREAD
=$LIBSTDTHREAD
15327 LIBMULTITHREAD
=$LIBSTDTHREAD LTLIBMULTITHREAD
=$LIBSTDTHREAD
15328 gl_threads_api
=isoc
15330 $as_echo "#define USE_ISOC_THREADS 1" >>confdefs.h
15334 if test $gl_threads_api = none
; then
15335 case "$gl_use_threads" in
15336 yes | windows | win32
) # The 'win32' is for backward compatibility.
15337 if { case "$host_os" in
15342 gl_threads_api
=windows
15344 $as_echo "#define USE_WINDOWS_THREADS 1" >>confdefs.h
15351 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for multithread API to use" >&5
15352 $as_echo_n "checking for multithread API to use... " >&6; }
15353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_threads_api" >&5
15354 $as_echo "$gl_threads_api" >&6; }
15367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc, realloc, calloc are POSIX compliant" >&5
15368 $as_echo_n "checking whether malloc, realloc, calloc are POSIX compliant... " >&6; }
15369 if ${gl_cv_func_malloc_posix+:} false
; then :
15370 $as_echo_n "(cached) " >&6
15373 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
15374 /* end confdefs.h. */
15379 #if defined _WIN32 && ! defined __CYGWIN__
15387 if ac_fn_c_try_compile
"$LINENO"; then :
15388 gl_cv_func_malloc_posix
=yes
15390 gl_cv_func_malloc_posix
=no
15392 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
15395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_malloc_posix" >&5
15396 $as_echo "$gl_cv_func_malloc_posix" >&6; }
15400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5
15401 $as_echo_n "checking for GNU libc compatible malloc... " >&6; }
15402 if ${ac_cv_func_malloc_0_nonnull+:} false
; then :
15403 $as_echo_n "(cached) " >&6
15405 if test "$cross_compiling" = yes; then :
15407 # Guess yes on platforms where we know the result.
15408 *-gnu* | gnu
* |
*-musl* | freebsd
* | netbsd
* | openbsd
* \
15409 | hpux
* | solaris
* | cygwin
* | mingw
*)
15410 ac_cv_func_malloc_0_nonnull
="guessing yes" ;;
15411 # If we don't know, obey --enable-cross-guesses.
15412 *) ac_cv_func_malloc_0_nonnull
="$gl_cross_guess_normal" ;;
15416 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
15417 /* end confdefs.h. */
15418 #include <stdlib.h>
15423 char *p = malloc (0);
15432 if ac_fn_c_try_run
"$LINENO"; then :
15433 ac_cv_func_malloc_0_nonnull
=yes
15435 ac_cv_func_malloc_0_nonnull
=no
15437 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
15438 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
15443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_malloc_0_nonnull" >&5
15444 $as_echo "$ac_cv_func_malloc_0_nonnull" >&6; }
15445 case "$ac_cv_func_malloc_0_nonnull" in
15447 gl_cv_func_malloc_0_nonnull
=1
15450 gl_cv_func_malloc_0_nonnull
=0
15455 cat >>confdefs.h
<<_ACEOF
15456 #define MALLOC_0_IS_NONNULL $gl_cv_func_malloc_0_nonnull
15469 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional japanese locale" >&5
15470 $as_echo_n "checking for a traditional japanese locale... " >&6; }
15471 if ${gt_cv_locale_ja+:} false
; then :
15472 $as_echo_n "(cached) " >&6
15475 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
15476 /* end confdefs.h. */
15478 #include <locale.h>
15480 #if HAVE_LANGINFO_CODESET
15481 # include <langinfo.h>
15483 #include <stdlib.h>
15484 #include <string.h>
15489 /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
15490 imitates locale dependent behaviour by looking at the environment
15491 variables, and all locales use the UTF-8 encoding. */
15492 #if defined __BEOS__ || defined __HAIKU__
15495 /* Check whether the given locale name is recognized by the system. */
15496 # if defined _WIN32 && !defined __CYGWIN__
15497 /* On native Windows, setlocale(category, "") looks at the system settings,
15498 not at the environment variables. Also, when an encoding suffix such
15499 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
15500 category of the locale to "C". */
15501 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
15502 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
15505 if (setlocale (LC_ALL, "") == NULL) return 1;
15507 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
15508 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
15509 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
15510 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
15511 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
15512 some unit tests fail.
15513 On MirBSD 10, when an unsupported locale is specified, setlocale()
15514 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
15515 # if HAVE_LANGINFO_CODESET
15517 const char *cs = nl_langinfo (CODESET);
15518 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
15519 || strcmp (cs, "UTF-8") == 0)
15524 /* On Cygwin, avoid locale names without encoding suffix, because the
15525 locale_charset() function relies on the encoding suffix. Note that
15526 LC_ALL is set on the command line. */
15527 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
15529 /* Check whether MB_CUR_MAX is > 1. This excludes the dysfunctional locales
15530 on Cygwin 1.5.x. */
15531 if (MB_CUR_MAX == 1)
15533 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
15534 This excludes the UTF-8 encoding (except on MirBSD). */
15537 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
15538 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
15539 for (p = buf; *p != '\0'; p++)
15540 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
15548 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
15549 (eval $ac_link) 2>&5
15551 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
15552 test $ac_status = 0; } && test -s conftest
$ac_exeext; then
15554 # Handle native Windows specially, because there setlocale() interprets
15555 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
15556 # "fr" or "fra" as "French" or "French_France.1252",
15557 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
15558 # "ja" as "Japanese" or "Japanese_Japan.932",
15561 # Note that on native Windows, the Japanese locale is
15562 # Japanese_Japan.932, and CP932 is very different from EUC-JP, so we
15563 # cannot use it here.
15564 gt_cv_locale_ja
=none
15567 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
15568 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
15569 # configure script would override the LC_ALL setting. Likewise for
15570 # LC_CTYPE, which is also set at the beginning of the configure script.
15571 # Test for the AIX locale name.
15572 if (LC_ALL
=ja_JP LC_TIME
= LC_CTYPE
= .
/conftest
; exit) 2>/dev
/null
; then
15573 gt_cv_locale_ja
=ja_JP
15575 # Test for the locale name with explicit encoding suffix.
15576 if (LC_ALL
=ja_JP.EUC-JP LC_TIME
= LC_CTYPE
= .
/conftest
; exit) 2>/dev
/null
; then
15577 gt_cv_locale_ja
=ja_JP.EUC-JP
15579 # Test for the HP-UX, OSF/1, NetBSD locale name.
15580 if (LC_ALL
=ja_JP.eucJP LC_TIME
= LC_CTYPE
= .
/conftest
; exit) 2>/dev
/null
; then
15581 gt_cv_locale_ja
=ja_JP.eucJP
15583 # Test for the IRIX, FreeBSD locale name.
15584 if (LC_ALL
=ja_JP.EUC LC_TIME
= LC_CTYPE
= .
/conftest
; exit) 2>/dev
/null
; then
15585 gt_cv_locale_ja
=ja_JP.EUC
15587 # Test for the Solaris 7 locale name.
15588 if (LC_ALL
=ja LC_TIME
= LC_CTYPE
= .
/conftest
; exit) 2>/dev
/null
; then
15591 # Special test for NetBSD 1.6.
15592 if test -f /usr
/share
/locale
/ja_JP.eucJP
/LC_CTYPE
; then
15593 gt_cv_locale_ja
=ja_JP.eucJP
15596 gt_cv_locale_ja
=none
15609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_ja" >&5
15610 $as_echo "$gt_cv_locale_ja" >&6; }
15611 LOCALE_JA
=$gt_cv_locale_ja
15616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
15617 $as_echo_n "checking for a french Unicode locale... " >&6; }
15618 if ${gt_cv_locale_fr_utf8+:} false
; then :
15619 $as_echo_n "(cached) " >&6
15622 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
15623 /* end confdefs.h. */
15625 #include <locale.h>
15627 #if HAVE_LANGINFO_CODESET
15628 # include <langinfo.h>
15630 #include <stdlib.h>
15631 #include <string.h>
15635 /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
15636 imitates locale dependent behaviour by looking at the environment
15637 variables, and all locales use the UTF-8 encoding. */
15638 #if !(defined __BEOS__ || defined __HAIKU__)
15639 /* Check whether the given locale name is recognized by the system. */
15640 # if defined _WIN32 && !defined __CYGWIN__
15641 /* On native Windows, setlocale(category, "") looks at the system settings,
15642 not at the environment variables. Also, when an encoding suffix such
15643 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
15644 category of the locale to "C". */
15645 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
15646 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
15649 if (setlocale (LC_ALL, "") == NULL) return 1;
15651 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
15652 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
15653 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
15654 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
15655 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
15656 some unit tests fail. */
15657 # if HAVE_LANGINFO_CODESET
15659 const char *cs = nl_langinfo (CODESET);
15660 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
15665 /* On Cygwin, avoid locale names without encoding suffix, because the
15666 locale_charset() function relies on the encoding suffix. Note that
15667 LC_ALL is set on the command line. */
15668 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
15670 /* Check whether in the abbreviation of the second month, the second
15671 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
15672 two bytes long, with UTF-8 encoding. */
15673 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
15674 if (strftime (buf, sizeof (buf), "%b", &t) < 4
15675 || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
15678 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
15679 /* Check whether the decimal separator is a comma.
15680 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
15681 are nl_langinfo(RADIXCHAR) are both ".". */
15682 if (localeconv () ->decimal_point[0] != ',') return 1;
15688 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
15689 (eval $ac_link) 2>&5
15691 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
15692 test $ac_status = 0; } && test -s conftest
$ac_exeext; then
15694 # Handle native Windows specially, because there setlocale() interprets
15695 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
15696 # "fr" or "fra" as "French" or "French_France.1252",
15697 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
15698 # "ja" as "Japanese" or "Japanese_Japan.932",
15701 # Test for the hypothetical native Windows locale name.
15702 if (LC_ALL
=French_France
.65001 LC_TIME
= LC_CTYPE
= .
/conftest
; exit) 2>/dev
/null
; then
15703 gt_cv_locale_fr_utf8
=French_France
.65001
15706 gt_cv_locale_fr_utf8
=none
15710 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
15711 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
15712 # configure script would override the LC_ALL setting. Likewise for
15713 # LC_CTYPE, which is also set at the beginning of the configure script.
15714 # Test for the usual locale name.
15715 if (LC_ALL
=fr_FR LC_TIME
= LC_CTYPE
= .
/conftest
; exit) 2>/dev
/null
; then
15716 gt_cv_locale_fr_utf8
=fr_FR
15718 # Test for the locale name with explicit encoding suffix.
15719 if (LC_ALL
=fr_FR.UTF-8 LC_TIME
= LC_CTYPE
= .
/conftest
; exit) 2>/dev
/null
; then
15720 gt_cv_locale_fr_utf8
=fr_FR.UTF-8
15722 # Test for the Solaris 7 locale name.
15723 if (LC_ALL
=fr.UTF-8 LC_TIME
= LC_CTYPE
= .
/conftest
; exit) 2>/dev
/null
; then
15724 gt_cv_locale_fr_utf8
=fr.UTF-8
15727 gt_cv_locale_fr_utf8
=none
15737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
15738 $as_echo "$gt_cv_locale_fr_utf8" >&6; }
15739 LOCALE_FR_UTF8
=$gt_cv_locale_fr_utf8
15745 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a transitional chinese locale" >&5
15746 $as_echo_n "checking for a transitional chinese locale... " >&6; }
15747 if ${gt_cv_locale_zh_CN+:} false
; then :
15748 $as_echo_n "(cached) " >&6
15751 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
15752 /* end confdefs.h. */
15754 #include <locale.h>
15755 #include <stdlib.h>
15757 #if HAVE_LANGINFO_CODESET
15758 # include <langinfo.h>
15760 #include <stdlib.h>
15761 #include <string.h>
15766 /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
15767 imitates locale dependent behaviour by looking at the environment
15768 variables, and all locales use the UTF-8 encoding. */
15769 #if defined __BEOS__ || defined __HAIKU__
15772 /* Check whether the given locale name is recognized by the system. */
15773 # if defined _WIN32 && !defined __CYGWIN__
15774 /* On native Windows, setlocale(category, "") looks at the system settings,
15775 not at the environment variables. Also, when an encoding suffix such
15776 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
15777 category of the locale to "C". */
15778 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
15779 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
15782 if (setlocale (LC_ALL, "") == NULL) return 1;
15784 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
15785 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
15786 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
15787 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
15788 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
15789 some unit tests fail.
15790 On MirBSD 10, when an unsupported locale is specified, setlocale()
15791 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
15792 # if HAVE_LANGINFO_CODESET
15794 const char *cs = nl_langinfo (CODESET);
15795 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
15796 || strcmp (cs, "UTF-8") == 0)
15801 /* On Cygwin, avoid locale names without encoding suffix, because the
15802 locale_charset() function relies on the encoding suffix. Note that
15803 LC_ALL is set on the command line. */
15804 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
15806 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
15807 This excludes the UTF-8 encoding (except on MirBSD). */
15810 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
15811 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
15812 for (p = buf; *p != '\0'; p++)
15813 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
15816 /* Check whether a typical GB18030 multibyte sequence is recognized as a
15817 single wide character. This excludes the GB2312 and GBK encodings. */
15818 if (mblen ("\203\062\332\066", 5) != 4)
15825 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
15826 (eval $ac_link) 2>&5
15828 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
15829 test $ac_status = 0; } && test -s conftest
$ac_exeext; then
15831 # Handle native Windows specially, because there setlocale() interprets
15832 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
15833 # "fr" or "fra" as "French" or "French_France.1252",
15834 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
15835 # "ja" as "Japanese" or "Japanese_Japan.932",
15838 # Test for the hypothetical native Windows locale name.
15839 if (LC_ALL
=Chinese_China
.54936 LC_TIME
= LC_CTYPE
= .
/conftest
; exit) 2>/dev
/null
; then
15840 gt_cv_locale_zh_CN
=Chinese_China
.54936
15843 gt_cv_locale_zh_CN
=none
15847 # On Solaris 8, the locales zh_CN.GB18030, zh_CN.GBK, zh.GBK are
15848 # broken. One witness is the test case in gl_MBRTOWC_SANITYCHECK.
15849 # Another witness is that "LC_ALL=zh_CN.GB18030 bash -c true" dumps core.
15850 gt_cv_locale_zh_CN
=none
15853 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
15854 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
15855 # configure script would override the LC_ALL setting. Likewise for
15856 # LC_CTYPE, which is also set at the beginning of the configure script.
15857 # Test for the locale name without encoding suffix.
15858 if (LC_ALL
=zh_CN LC_TIME
= LC_CTYPE
= .
/conftest
; exit) 2>/dev
/null
; then
15859 gt_cv_locale_zh_CN
=zh_CN
15861 # Test for the locale name with explicit encoding suffix.
15862 if (LC_ALL
=zh_CN.GB18030 LC_TIME
= LC_CTYPE
= .
/conftest
; exit) 2>/dev
/null
; then
15863 gt_cv_locale_zh_CN
=zh_CN.GB18030
15866 gt_cv_locale_zh_CN
=none
15872 # If there was a link error, due to mblen(), the system is so old that
15873 # it certainly doesn't have a chinese locale.
15874 gt_cv_locale_zh_CN
=none
15879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_zh_CN" >&5
15880 $as_echo "$gt_cv_locale_zh_CN" >&6; }
15881 LOCALE_ZH_CN
=$gt_cv_locale_zh_CN
15884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
15885 $as_echo_n "checking for inline... " >&6; }
15886 if ${ac_cv_c_inline+:} false
; then :
15887 $as_echo_n "(cached) " >&6
15890 for ac_kw
in inline __inline__ __inline
; do
15891 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
15892 /* end confdefs.h. */
15893 #ifndef __cplusplus
15895 static $ac_kw foo_t static_foo () {return 0; }
15896 $ac_kw foo_t foo () {return 0; }
15900 if ac_fn_c_try_compile
"$LINENO"; then :
15901 ac_cv_c_inline
=$ac_kw
15903 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
15904 test "$ac_cv_c_inline" != no
&& break
15908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
15909 $as_echo "$ac_cv_c_inline" >&6; }
15911 case $ac_cv_c_inline in
15914 case $ac_cv_c_inline in
15916 *) ac_val
=$ac_cv_c_inline;;
15918 cat >>confdefs.h
<<_ACEOF
15919 #ifndef __cplusplus
15920 #define inline $ac_val
15931 GNULIB_EXPLICIT_BZERO
=0;
15938 GNULIB_RAWMEMCHR
=0;
15941 GNULIB_STRCHRNUL
=0;
15949 GNULIB_STRCASESTR
=0;
15956 GNULIB_MBSCASECMP
=0;
15957 GNULIB_MBSNCASECMP
=0;
15958 GNULIB_MBSPCASECMP
=0;
15959 GNULIB_MBSCASESTR
=0;
15966 GNULIB_STRERROR_R
=0;
15967 GNULIB_STRERRORNAME_NP
=0;
15968 GNULIB_SIGABBREV_NP
=0;
15969 GNULIB_SIGDESCR_NP
=0;
15970 GNULIB_STRSIGNAL
=0;
15971 GNULIB_STRVERSCMP
=0;
15973 GNULIB_MDA_MEMCCPY
=1;
15974 GNULIB_MDA_STRDUP
=1;
15975 HAVE_EXPLICIT_BZERO
=1;
15978 HAVE_DECL_MEMMEM
=1;
15980 HAVE_DECL_MEMRCHR
=1;
15985 HAVE_DECL_STRDUP
=1;
15986 HAVE_DECL_STRNDUP
=1;
15987 HAVE_DECL_STRNLEN
=1;
15991 HAVE_DECL_STRTOK_R
=1;
15992 HAVE_DECL_STRERROR_R
=1;
15993 HAVE_STRERRORNAME_NP
=1;
15994 HAVE_SIGABBREV_NP
=1;
15995 HAVE_SIGDESCR_NP
=1;
15996 HAVE_DECL_STRSIGNAL
=1;
16002 REPLACE_STRCHRNUL
=0;
16008 REPLACE_STRCASESTR
=0;
16009 REPLACE_STRTOK_R
=0;
16010 REPLACE_STRERROR
=0;
16011 REPLACE_STRERROR_R
=0;
16012 REPLACE_STRERRORNAME_NP
=0;
16013 REPLACE_STRSIGNAL
=0;
16014 UNDEFINE_STRTOK_R
=0;
16021 # Check for mmap(). Don't use AC_FUNC_MMAP, because it checks too much: it
16022 # fails on HP-UX 11, because MAP_FIXED mappings do not work. But this is
16023 # irrelevant for anonymous mappings.
16024 ac_fn_c_check_func
"$LINENO" "mmap" "ac_cv_func_mmap"
16025 if test "x$ac_cv_func_mmap" = xyes
; then :
16032 # Try to allow MAP_ANONYMOUS.
16033 gl_have_mmap_anonymous
=no
16034 if test $gl_have_mmap = yes; then
16035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAP_ANONYMOUS" >&5
16036 $as_echo_n "checking for MAP_ANONYMOUS... " >&6; }
16037 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
16038 /* end confdefs.h. */
16040 #include <sys/mman.h>
16041 #ifdef MAP_ANONYMOUS
16042 I cannot identify this map
16046 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16047 $EGREP "I cannot identify this map" >/dev
/null
2>&1; then :
16048 gl_have_mmap_anonymous
=yes
16052 if test $gl_have_mmap_anonymous != yes; then
16053 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
16054 /* end confdefs.h. */
16056 #include <sys/mman.h>
16058 I cannot identify this map
16062 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16063 $EGREP "I cannot identify this map" >/dev
/null
2>&1; then :
16065 $as_echo "#define MAP_ANONYMOUS MAP_ANON" >>confdefs.h
16067 gl_have_mmap_anonymous
=yes
16072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_have_mmap_anonymous" >&5
16073 $as_echo "$gl_have_mmap_anonymous" >&6; }
16074 if test $gl_have_mmap_anonymous = yes; then
16076 $as_echo "#define HAVE_MAP_ANONYMOUS 1" >>confdefs.h
16085 # Detect platform-specific bugs in some versions of glibc:
16086 # memchr should not dereference anything with length 0
16087 # https://bugzilla.redhat.com/show_bug.cgi?id=499689
16088 # memchr should not dereference overestimated length after a match
16089 # https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=521737
16090 # https://sourceware.org/bugzilla/show_bug.cgi?id=10162
16091 # memchr should cast the second argument to 'unsigned char'.
16092 # This bug exists in Android 4.3.
16093 # Assume that memchr works on platforms that lack mprotect.
16094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memchr works" >&5
16095 $as_echo_n "checking whether memchr works... " >&6; }
16096 if ${gl_cv_func_memchr_works+:} false
; then :
16097 $as_echo_n "(cached) " >&6
16099 if test "$cross_compiling" = yes; then :
16101 # Guess no on Android.
16102 linux
*-android*) gl_cv_func_memchr_works
="guessing no" ;;
16103 # Guess yes on native Windows.
16104 mingw
*) gl_cv_func_memchr_works
="guessing yes" ;;
16105 # If we don't know, obey --enable-cross-guesses.
16106 *) gl_cv_func_memchr_works
="$gl_cross_guess_normal" ;;
16110 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
16111 /* end confdefs.h. */
16113 #include <string.h>
16114 #if HAVE_SYS_MMAN_H
16115 # include <fcntl.h>
16116 # include <unistd.h>
16117 # include <sys/types.h>
16118 # include <sys/mman.h>
16120 # define MAP_FILE 0
16129 char *fence = NULL;
16130 #if HAVE_SYS_MMAN_H && HAVE_MPROTECT
16131 # if HAVE_MAP_ANONYMOUS
16132 const int flags = MAP_ANONYMOUS | MAP_PRIVATE;
16134 # else /* !HAVE_MAP_ANONYMOUS */
16135 const int flags = MAP_FILE | MAP_PRIVATE;
16136 int fd = open ("/dev/zero", O_RDONLY, 0666);
16140 int pagesize = getpagesize ();
16142 (char *) mmap (NULL, 2 * pagesize, PROT_READ | PROT_WRITE,
16144 if (two_pages != (char *)(-1)
16145 && mprotect (two_pages + pagesize, pagesize, PROT_NONE) == 0)
16146 fence = two_pages + pagesize;
16151 /* Test against bugs on glibc systems. */
16152 if (memchr (fence, 0, 0))
16154 strcpy (fence - 9, "12345678");
16155 if (memchr (fence - 9, 0, 79) != fence - 1)
16157 if (memchr (fence - 1, 0, 3) != fence - 1)
16159 /* Test against bug on AIX 7.2. */
16160 if (memchr (fence - 4, '6', 16) != fence - 4)
16163 /* Test against bug on Android 4.3. */
16169 if (memchr (input, 0x789abc00 | 'b', 3) != input + 1)
16178 if ac_fn_c_try_run
"$LINENO"; then :
16179 gl_cv_func_memchr_works
=yes
16181 gl_cv_func_memchr_works
=no
16183 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
16184 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
16189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memchr_works" >&5
16190 $as_echo "$gl_cv_func_memchr_works" >&6; }
16191 case "$gl_cv_func_memchr_works" in
16193 *) REPLACE_MEMCHR
=1 ;;
16196 ac_fn_c_check_decl
"$LINENO" "memmem" "ac_cv_have_decl_memmem" "$ac_includes_default"
16197 if test "x$ac_cv_have_decl_memmem" = xyes
; then :
16203 cat >>confdefs.h
<<_ACEOF
16204 #define HAVE_DECL_MEMMEM $ac_have_decl
16211 for ac_func
in memmem
16213 ac_fn_c_check_func
"$LINENO" "memmem" "ac_cv_func_memmem"
16214 if test "x$ac_cv_func_memmem" = xyes
; then :
16215 cat >>confdefs.h
<<_ACEOF
16216 #define HAVE_MEMMEM 1
16222 if test $ac_cv_func_memmem = yes; then
16228 if test $ac_cv_have_decl_memmem = no
; then
16231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memmem works" >&5
16232 $as_echo_n "checking whether memmem works... " >&6; }
16233 if ${gl_cv_func_memmem_works_always+:} false
; then :
16234 $as_echo_n "(cached) " >&6
16236 if test "$cross_compiling" = yes; then :
16237 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
16238 /* end confdefs.h. */
16240 #ifdef __GNU_LIBRARY__
16241 #include <features.h>
16242 #if ((__GLIBC__ == 2 && ((__GLIBC_MINOR > 0 && __GLIBC_MINOR__ < 9) \
16243 || __GLIBC_MINOR__ > 12)) \
16244 || (__GLIBC__ > 2)) \
16245 || defined __UCLIBC__
16248 #elif defined __CYGWIN__
16249 #include <cygwin/version.h>
16250 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
16258 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16259 $EGREP "Lucky user" >/dev
/null
2>&1; then :
16260 gl_cv_func_memmem_works_always
="guessing yes"
16262 gl_cv_func_memmem_works_always
="$gl_cross_guess_normal"
16268 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
16269 /* end confdefs.h. */
16271 #include <string.h> /* for memmem */
16272 #define P "_EF_BF_BD"
16273 #define HAYSTACK "F_BD_CE_BD" P P P P "_C3_88_20" P P P "_C3_A7_20" P
16274 #define NEEDLE P P P P P
16281 if (memmem (HAYSTACK, strlen (HAYSTACK), NEEDLE, strlen (NEEDLE)))
16283 /* Check for empty needle behavior. */
16285 const char *haystack = "AAA";
16286 if (memmem (haystack, 3, (const char *) 1, 0) != haystack)
16295 if ac_fn_c_try_run
"$LINENO"; then :
16296 gl_cv_func_memmem_works_always
=yes
16298 gl_cv_func_memmem_works_always
=no
16300 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
16301 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
16306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memmem_works_always" >&5
16307 $as_echo "$gl_cv_func_memmem_works_always" >&6; }
16308 case "$gl_cv_func_memmem_works_always" in
16317 ac_fn_c_check_decl
"$LINENO" "memrchr" "ac_cv_have_decl_memrchr" "$ac_includes_default"
16318 if test "x$ac_cv_have_decl_memrchr" = xyes
; then :
16324 cat >>confdefs.h
<<_ACEOF
16325 #define HAVE_DECL_MEMRCHR $ac_have_decl
16332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <limits.h> defines MIN and MAX" >&5
16333 $as_echo_n "checking whether <limits.h> defines MIN and MAX... " >&6; }
16334 if ${gl_cv_minmax_in_limits_h+:} false
; then :
16335 $as_echo_n "(cached) " >&6
16337 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
16338 /* end confdefs.h. */
16339 #include <limits.h>
16340 int x = MIN (42, 17);
16349 if ac_fn_c_try_compile
"$LINENO"; then :
16350 gl_cv_minmax_in_limits_h
=yes
16352 gl_cv_minmax_in_limits_h
=no
16354 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
16356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_minmax_in_limits_h" >&5
16357 $as_echo "$gl_cv_minmax_in_limits_h" >&6; }
16358 if test $gl_cv_minmax_in_limits_h = yes; then
16360 $as_echo "#define HAVE_MINMAX_IN_LIMITS_H 1" >>confdefs.h
16369 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/param.h> defines MIN and MAX" >&5
16370 $as_echo_n "checking whether <sys/param.h> defines MIN and MAX... " >&6; }
16371 if ${gl_cv_minmax_in_sys_param_h+:} false
; then :
16372 $as_echo_n "(cached) " >&6
16374 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
16375 /* end confdefs.h. */
16376 #include <sys/param.h>
16377 int x = MIN (42, 17);
16386 if ac_fn_c_try_compile
"$LINENO"; then :
16387 gl_cv_minmax_in_sys_param_h
=yes
16389 gl_cv_minmax_in_sys_param_h
=no
16391 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
16393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_minmax_in_sys_param_h" >&5
16394 $as_echo "$gl_cv_minmax_in_sys_param_h" >&6; }
16395 if test $gl_cv_minmax_in_sys_param_h = yes; then
16397 $as_echo "#define HAVE_MINMAX_IN_SYS_PARAM_H 1" >>confdefs.h
16410 GNULIB_GETADDRINFO
=0;
16411 HAVE_STRUCT_ADDRINFO
=1;
16412 HAVE_DECL_FREEADDRINFO
=1;
16413 HAVE_DECL_GAI_STRERROR
=1;
16414 HAVE_DECL_GETADDRINFO
=1;
16415 HAVE_DECL_GETNAMEINFO
=1;
16416 REPLACE_GAI_STRERROR
=0;
16417 REPLACE_GETADDRINFO
=0;
16420 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for O_CLOEXEC" >&5
16421 $as_echo_n "checking for O_CLOEXEC... " >&6; }
16422 if ${gl_cv_macro_O_CLOEXEC+:} false
; then :
16423 $as_echo_n "(cached) " >&6
16425 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
16426 /* end confdefs.h. */
16440 if ac_fn_c_try_compile
"$LINENO"; then :
16441 gl_cv_macro_O_CLOEXEC
=yes
16443 gl_cv_macro_O_CLOEXEC
=no
16445 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
16447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_macro_O_CLOEXEC" >&5
16448 $as_echo "$gl_cv_macro_O_CLOEXEC" >&6; }
16452 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for promoted mode_t type" >&5
16453 $as_echo_n "checking for promoted mode_t type... " >&6; }
16454 if ${gl_cv_promoted_mode_t+:} false
; then :
16455 $as_echo_n "(cached) " >&6
16458 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
16459 /* end confdefs.h. */
16460 #include <sys/types.h>
16464 typedef int array[2 * (sizeof (mode_t) < sizeof (int)) - 1];
16469 if ac_fn_c_try_compile
"$LINENO"; then :
16470 gl_cv_promoted_mode_t
='int'
16472 gl_cv_promoted_mode_t
='mode_t'
16474 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
16477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_promoted_mode_t" >&5
16478 $as_echo "$gl_cv_promoted_mode_t" >&6; }
16480 cat >>confdefs.h
<<_ACEOF
16481 #define PROMOTED_MODE_T $gl_cv_promoted_mode_t
16505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
16506 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
16507 if ${gl_cv_header_sys_select_h_selfcontained+:} false
; then :
16508 $as_echo_n "(cached) " >&6
16511 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
16512 /* end confdefs.h. */
16513 #include <sys/select.h>
16522 if ac_fn_c_try_compile
"$LINENO"; then :
16523 gl_cv_header_sys_select_h_selfcontained
=yes
16525 gl_cv_header_sys_select_h_selfcontained
=no
16527 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
16528 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
16529 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
16530 /* end confdefs.h. */
16531 #include <sys/select.h>
16535 int memset; int bzero;
16541 if ac_fn_c_try_compile
"$LINENO"; then :
16542 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
16543 /* end confdefs.h. */
16544 #include <sys/select.h>
16550 #define memset nonexistent_memset
16555 void *memset (void *, int, unsigned long);
16557 #define bzero nonexistent_bzero
16562 void bzero (void *, unsigned long);
16571 if ac_fn_c_try_link
"$LINENO"; then :
16574 gl_cv_header_sys_select_h_selfcontained
=no
16576 rm -f core conftest.err conftest.
$ac_objext \
16577 conftest
$ac_exeext conftest.
$ac_ext
16580 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
16584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
16585 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
16595 if test $gl_cv_have_include_next = yes; then
16596 gl_cv_next_sys_select_h
='<'sys
/select.h
'>'
16598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
16599 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
16600 if ${gl_cv_next_sys_select_h+:} false
; then :
16601 $as_echo_n "(cached) " >&6
16604 if test $ac_cv_header_sys_select_h = yes; then
16609 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
16610 /* end confdefs.h. */
16611 #include <sys/select.h>
16614 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
16615 *) gl_absname_cpp
="$ac_cpp" ;;
16620 gl_dirsep_regex
='[/\\]'
16623 gl_dirsep_regex
='\/'
16626 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
16627 gl_header_literal_regex
=`echo 'sys/select.h' \
16628 | sed -e "$gl_make_literal_regex_sed"`
16629 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
16630 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
16636 gl_cv_absolute_sys_select_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
16637 sed -n "$gl_absolute_header_sed"`
16639 gl_header
=$gl_cv_absolute_sys_select_h
16640 gl_cv_next_sys_select_h
='"'$gl_header'"'
16642 gl_cv_next_sys_select_h
='<'sys
/select.h
'>'
16647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
16648 $as_echo "$gl_cv_next_sys_select_h" >&6; }
16650 NEXT_SYS_SELECT_H
=$gl_cv_next_sys_select_h
16652 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
16653 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
16654 gl_next_as_first_directive
='<'sys
/select.h
'>'
16656 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
16657 gl_next_as_first_directive
=$gl_cv_next_sys_select_h
16659 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H
=$gl_next_as_first_directive
16664 if test $ac_cv_header_sys_select_h = yes; then
16665 HAVE_SYS_SELECT_H
=1
16667 HAVE_SYS_SELECT_H
=0
16674 if test $ac_cv_header_sys_socket_h != yes; then
16675 for ac_header
in winsock2.h
16677 ac_fn_c_check_header_mongrel
"$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
16678 if test "x$ac_cv_header_winsock2_h" = xyes
; then :
16679 cat >>confdefs.h
<<_ACEOF
16680 #define HAVE_WINSOCK2_H 1
16688 if test "$ac_cv_header_winsock2_h" = yes; then
16690 UNISTD_H_HAVE_WINSOCK2_H
=1
16691 SYS_IOCTL_H_HAVE_WINSOCK2_H
=1
16707 if test $ac_cv_header_sys_socket_h != yes; then
16708 for ac_header
in winsock2.h
16710 ac_fn_c_check_header_mongrel
"$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
16711 if test "x$ac_cv_header_winsock2_h" = xyes
; then :
16712 cat >>confdefs.h
<<_ACEOF
16713 #define HAVE_WINSOCK2_H 1
16721 if test "$ac_cv_header_winsock2_h" = yes; then
16723 UNISTD_H_HAVE_WINSOCK2_H
=1
16724 SYS_IOCTL_H_HAVE_WINSOCK2_H
=1
16730 if test $HAVE_WINSOCK2_H = 1; then
16731 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WSAStartup" >&5
16732 $as_echo_n "checking for WSAStartup... " >&6; }
16733 if ${gl_cv_func_wsastartup+:} false
; then :
16734 $as_echo_n "(cached) " >&6
16737 gl_save_LIBS
="$LIBS"
16738 LIBS
="$LIBS -lws2_32"
16739 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
16740 /* end confdefs.h. */
16742 #ifdef HAVE_WINSOCK2_H
16743 # include <winsock2.h>
16749 WORD wVersionRequested = MAKEWORD(1, 1);
16751 int err = WSAStartup(wVersionRequested, &wsaData);
16759 if ac_fn_c_try_link
"$LINENO"; then :
16760 gl_cv_func_wsastartup
=yes
16762 gl_cv_func_wsastartup
=no
16764 rm -f core conftest.err conftest.
$ac_objext \
16765 conftest
$ac_exeext conftest.
$ac_ext
16766 LIBS
="$gl_save_LIBS"
16769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_wsastartup" >&5
16770 $as_echo "$gl_cv_func_wsastartup" >&6; }
16771 if test "$gl_cv_func_wsastartup" = "yes"; then
16773 $as_echo "#define WINDOWS_SOCKETS 1" >>confdefs.h
16775 LIBSOCKET
='-lws2_32'
16778 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setsockopt" >&5
16779 $as_echo_n "checking for library containing setsockopt... " >&6; }
16780 if ${gl_cv_lib_socket+:} false
; then :
16781 $as_echo_n "(cached) " >&6
16785 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
16786 /* end confdefs.h. */
16800 if ac_fn_c_try_link
"$LINENO"; then :
16803 gl_save_LIBS
="$LIBS"
16804 LIBS
="$gl_save_LIBS -lsocket"
16805 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
16806 /* end confdefs.h. */
16820 if ac_fn_c_try_link
"$LINENO"; then :
16821 gl_cv_lib_socket
="-lsocket"
16823 rm -f core conftest.err conftest.
$ac_objext \
16824 conftest
$ac_exeext conftest.
$ac_ext
16825 if test -z "$gl_cv_lib_socket"; then
16826 LIBS
="$gl_save_LIBS -lnetwork"
16827 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
16828 /* end confdefs.h. */
16842 if ac_fn_c_try_link
"$LINENO"; then :
16843 gl_cv_lib_socket
="-lnetwork"
16845 rm -f core conftest.err conftest.
$ac_objext \
16846 conftest
$ac_exeext conftest.
$ac_ext
16847 if test -z "$gl_cv_lib_socket"; then
16848 LIBS
="$gl_save_LIBS -lnet"
16849 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
16850 /* end confdefs.h. */
16864 if ac_fn_c_try_link
"$LINENO"; then :
16865 gl_cv_lib_socket
="-lnet"
16867 rm -f core conftest.err conftest.
$ac_objext \
16868 conftest
$ac_exeext conftest.
$ac_ext
16871 LIBS
="$gl_save_LIBS"
16874 rm -f core conftest.err conftest.
$ac_objext \
16875 conftest
$ac_exeext conftest.
$ac_ext
16876 if test -z "$gl_cv_lib_socket"; then
16877 gl_cv_lib_socket
="none needed"
16881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_lib_socket" >&5
16882 $as_echo "$gl_cv_lib_socket" >&6; }
16883 if test "$gl_cv_lib_socket" != "none needed"; then
16884 LIBSOCKET
="$gl_cv_lib_socket"
16896 ac_fn_c_check_decl
"$LINENO" "setenv" "ac_cv_have_decl_setenv" "$ac_includes_default"
16897 if test "x$ac_cv_have_decl_setenv" = xyes
; then :
16903 cat >>confdefs.h
<<_ACEOF
16904 #define HAVE_DECL_SETENV $ac_have_decl
16912 if test $ac_cv_have_decl_setenv = no
; then
16920 for ac_header
in search.h
16922 ac_fn_c_check_header_mongrel
"$LINENO" "search.h" "ac_cv_header_search_h" "$ac_includes_default"
16923 if test "x$ac_cv_header_search_h" = xyes
; then :
16924 cat >>confdefs.h
<<_ACEOF
16925 #define HAVE_SEARCH_H 1
16932 for ac_func
in tsearch
16934 ac_fn_c_check_func
"$LINENO" "tsearch" "ac_cv_func_tsearch"
16935 if test "x$ac_cv_func_tsearch" = xyes
; then :
16936 cat >>confdefs.h
<<_ACEOF
16937 #define HAVE_TSEARCH 1
16946 GNULIB_PTHREAD_SIGMASK
=0;
16948 GNULIB_SIGNAL_H_SIGPIPE
=0;
16949 GNULIB_SIGPROCMASK
=0;
16950 GNULIB_SIGACTION
=0;
16951 HAVE_POSIX_SIGNALBLOCKING
=1;
16952 HAVE_PTHREAD_SIGMASK
=1;
16957 HAVE_STRUCT_SIGACTION_SA_SIGACTION
=1;
16959 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
=1;
16961 HAVE_SIGHANDLER_T
=1;
16962 REPLACE_PTHREAD_SIGMASK
=0;
16966 ac_fn_c_check_type
"$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
16967 #include <signal.h>
16968 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
16969 #include <sys/types.h>
16972 if test "x$ac_cv_type_sigset_t" = xyes
; then :
16974 cat >>confdefs.h
<<_ACEOF
16975 #define HAVE_SIGSET_T 1
16978 gl_cv_type_sigset_t
=yes
16980 gl_cv_type_sigset_t
=no
16983 if test $gl_cv_type_sigset_t != yes; then
16987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
16988 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
16989 if ${ac_cv_header_stdbool_h+:} false
; then :
16990 $as_echo_n "(cached) " >&6
16992 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
16993 /* end confdefs.h. */
16995 #include <stdbool.h>
17000 typedef _Bool Bool;
17002 "error: bool is not defined"
17005 "error: false is not defined"
17008 "error: false is not 0"
17011 "error: true is not defined"
17014 "error: true is not 1"
17018 #ifndef __bool_true_false_are_defined
17019 "error: __bool_true_false_are_defined is not defined"
17022 struct s { Bool s: 1; Bool t; bool u: 1; bool v; } s;
17024 char a[true == 1 ? 1 : -1];
17025 char b[false == 0 ? 1 : -1];
17026 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
17027 char d[(bool) 0.5 == true ? 1 : -1];
17028 /* See body of main program for 'e'. */
17029 char f[(Bool) 0.0 == false ? 1 : -1];
17031 char h[sizeof (Bool)];
17032 char i[sizeof s.t];
17033 enum { j = false, k = true, l = false * true, m = true * 256 };
17034 /* The following fails for
17035 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
17037 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
17038 char p[-1 - (Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
17039 /* Catch a bug in an HP-UX C compiler. See
17040 https://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
17041 https://lists.gnu.org/r/bug-coreutils/2005-11/msg00161.html
17052 *pq |= q; *pq |= ! q;
17053 *qq |= q; *qq |= ! q;
17054 /* Refer to every declared value, to avoid compiler optimizations. */
17055 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
17056 + !m + !n + !o + !p + !q + !pq + !qq);
17062 if ac_fn_c_try_compile
"$LINENO"; then :
17063 ac_cv_header_stdbool_h
=yes
17065 ac_cv_header_stdbool_h
=no
17067 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
17069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
17070 $as_echo "$ac_cv_header_stdbool_h" >&6; }
17071 ac_fn_c_check_type
"$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
17072 if test "x$ac_cv_type__Bool" = xyes
; then :
17074 cat >>confdefs.h
<<_ACEOF
17075 #define HAVE__BOOL 1
17082 ac_fn_c_check_decl
"$LINENO" "fcloseall" "ac_cv_have_decl_fcloseall" "$ac_includes_default"
17083 if test "x$ac_cv_have_decl_fcloseall" = xyes
; then :
17089 cat >>confdefs.h
<<_ACEOF
17090 #define HAVE_DECL_FCLOSEALL $ac_have_decl
17093 ac_fn_c_check_decl
"$LINENO" "ecvt" "ac_cv_have_decl_ecvt" "$ac_includes_default"
17094 if test "x$ac_cv_have_decl_ecvt" = xyes
; then :
17100 cat >>confdefs.h
<<_ACEOF
17101 #define HAVE_DECL_ECVT $ac_have_decl
17104 ac_fn_c_check_decl
"$LINENO" "fcvt" "ac_cv_have_decl_fcvt" "$ac_includes_default"
17105 if test "x$ac_cv_have_decl_fcvt" = xyes
; then :
17111 cat >>confdefs.h
<<_ACEOF
17112 #define HAVE_DECL_FCVT $ac_have_decl
17115 ac_fn_c_check_decl
"$LINENO" "gcvt" "ac_cv_have_decl_gcvt" "$ac_includes_default"
17116 if test "x$ac_cv_have_decl_gcvt" = xyes
; then :
17122 cat >>confdefs.h
<<_ACEOF
17123 #define HAVE_DECL_GCVT $ac_have_decl
17126 ac_fn_c_check_decl
"$LINENO" "strdup" "ac_cv_have_decl_strdup" "$ac_includes_default"
17127 if test "x$ac_cv_have_decl_strdup" = xyes
; then :
17133 cat >>confdefs.h
<<_ACEOF
17134 #define HAVE_DECL_STRDUP $ac_have_decl
17138 REPLACE_STRERROR_0
=0
17139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror(0) succeeds" >&5
17140 $as_echo_n "checking whether strerror(0) succeeds... " >&6; }
17141 if ${gl_cv_func_strerror_0_works+:} false
; then :
17142 $as_echo_n "(cached) " >&6
17144 if test "$cross_compiling" = yes; then :
17146 # Guess yes on glibc systems.
17147 *-gnu* | gnu
*) gl_cv_func_strerror_0_works
="guessing yes" ;;
17148 # Guess yes on musl systems.
17149 *-musl*) gl_cv_func_strerror_0_works
="guessing yes" ;;
17150 # Guess yes on native Windows.
17151 mingw
*) gl_cv_func_strerror_0_works
="guessing yes" ;;
17152 # If we don't know, obey --enable-cross-guesses.
17153 *) gl_cv_func_strerror_0_works
="$gl_cross_guess_normal" ;;
17157 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
17158 /* end confdefs.h. */
17159 #include <string.h>
17168 str = strerror (0);
17169 if (!*str) result |= 1;
17170 if (errno) result |= 2;
17171 if (strstr (str, "nknown") || strstr (str, "ndefined"))
17178 if ac_fn_c_try_run
"$LINENO"; then :
17179 gl_cv_func_strerror_0_works
=yes
17181 gl_cv_func_strerror_0_works
=no
17183 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
17184 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
17189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strerror_0_works" >&5
17190 $as_echo "$gl_cv_func_strerror_0_works" >&6; }
17191 case "$gl_cv_func_strerror_0_works" in
17194 REPLACE_STRERROR_0
=1
17196 $as_echo "#define REPLACE_STRERROR_0 1" >>confdefs.h
17210 if test $ac_cv_func_strerror_r = yes; then
17211 if test "$ERRNO_H:$REPLACE_STRERROR_0" = :0; then
17212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for strerror_r with POSIX signature" >&5
17213 $as_echo_n "checking for strerror_r with POSIX signature... " >&6; }
17214 if ${gl_cv_func_strerror_r_posix_signature+:} false
; then :
17215 $as_echo_n "(cached) " >&6
17217 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
17218 /* end confdefs.h. */
17219 #include <string.h>
17220 int strerror_r (int, char *, size_t);
17230 if ac_fn_c_try_compile
"$LINENO"; then :
17231 gl_cv_func_strerror_r_posix_signature
=yes
17233 gl_cv_func_strerror_r_posix_signature
=no
17235 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
17238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strerror_r_posix_signature" >&5
17239 $as_echo "$gl_cv_func_strerror_r_posix_signature" >&6; }
17240 if test $gl_cv_func_strerror_r_posix_signature = yes; then
17241 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror_r works" >&5
17242 $as_echo_n "checking whether strerror_r works... " >&6; }
17243 if ${gl_cv_func_strerror_r_works+:} false
; then :
17244 $as_echo_n "(cached) " >&6
17246 if test "$cross_compiling" = yes; then :
17250 aix
*) gl_cv_func_strerror_r_works
="guessing no";;
17251 # Guess no on HP-UX.
17252 hpux
*) gl_cv_func_strerror_r_works
="guessing no";;
17253 # Guess no on BSD variants.
17254 *bsd
*) gl_cv_func_strerror_r_works
="guessing no";;
17255 # Guess yes otherwise.
17256 *) gl_cv_func_strerror_r_works
="guessing yes";;
17260 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
17261 /* end confdefs.h. */
17263 #include <string.h>
17270 if (strerror_r (EACCES, buf, 0) < 0)
17273 if (strerror_r (EACCES, buf, sizeof buf) != 0)
17275 strcpy (buf, "Unknown");
17276 if (strerror_r (0, buf, sizeof buf) != 0)
17280 if (strstr (buf, "nknown") || strstr (buf, "ndefined"))
17284 if (strerror_r (-3, buf, sizeof buf) < 0)
17296 if ac_fn_c_try_run
"$LINENO"; then :
17297 gl_cv_func_strerror_r_works
=yes
17299 gl_cv_func_strerror_r_works
=no
17301 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
17302 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
17307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strerror_r_works" >&5
17308 $as_echo "$gl_cv_func_strerror_r_works" >&6; }
17311 if test $ac_cv_func___xpg_strerror_r = yes; then
17312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __xpg_strerror_r works" >&5
17313 $as_echo_n "checking whether __xpg_strerror_r works... " >&6; }
17314 if ${gl_cv_func_strerror_r_works+:} false
; then :
17315 $as_echo_n "(cached) " >&6
17317 if test "$cross_compiling" = yes; then :
17318 gl_cv_func_strerror_r_works
="$gl_cross_guess_normal"
17321 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
17322 /* end confdefs.h. */
17324 #include <string.h>
17329 int __xpg_strerror_r(int, char *, size_t);
17335 char buf[256] = "^";
17337 char *str = strerror (-1);
17338 strcpy (copy, str);
17339 if (__xpg_strerror_r (-2, buf, 1) == 0)
17343 __xpg_strerror_r (-2, buf, 256);
17344 if (strcmp (str, copy))
17352 if ac_fn_c_try_run
"$LINENO"; then :
17353 gl_cv_func_strerror_r_works
=yes
17355 gl_cv_func_strerror_r_works
=no
17357 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
17358 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
17363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strerror_r_works" >&5
17364 $as_echo "$gl_cv_func_strerror_r_works" >&6; }
17370 ac_fn_c_check_decl
"$LINENO" "strerror_r" "ac_cv_have_decl_strerror_r" "$ac_includes_default"
17371 if test "x$ac_cv_have_decl_strerror_r" = xyes
; then :
17377 cat >>confdefs.h
<<_ACEOF
17378 #define HAVE_DECL_STRERROR_R $ac_have_decl
17395 if test $gl_cv_have_include_next = yes; then
17396 gl_cv_next_string_h
='<'string.h
'>'
17398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <string.h>" >&5
17399 $as_echo_n "checking absolute name of <string.h>... " >&6; }
17400 if ${gl_cv_next_string_h+:} false
; then :
17401 $as_echo_n "(cached) " >&6
17406 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
17407 /* end confdefs.h. */
17408 #include <string.h>
17411 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
17412 *) gl_absname_cpp
="$ac_cpp" ;;
17417 gl_dirsep_regex
='[/\\]'
17420 gl_dirsep_regex
='\/'
17423 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
17424 gl_header_literal_regex
=`echo 'string.h' \
17425 | sed -e "$gl_make_literal_regex_sed"`
17426 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17427 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17433 gl_cv_absolute_string_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17434 sed -n "$gl_absolute_header_sed"`
17436 gl_header
=$gl_cv_absolute_string_h
17437 gl_cv_next_string_h
='"'$gl_header'"'
17441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_string_h" >&5
17442 $as_echo "$gl_cv_next_string_h" >&6; }
17444 NEXT_STRING_H
=$gl_cv_next_string_h
17446 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
17447 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17448 gl_next_as_first_directive
='<'string.h
'>'
17450 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17451 gl_next_as_first_directive
=$gl_cv_next_string_h
17453 NEXT_AS_FIRST_DIRECTIVE_STRING_H
=$gl_next_as_first_directive
17479 if test $gl_cv_have_include_next = yes; then
17480 gl_cv_next_strings_h
='<'strings.h
'>'
17482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <strings.h>" >&5
17483 $as_echo_n "checking absolute name of <strings.h>... " >&6; }
17484 if ${gl_cv_next_strings_h+:} false
; then :
17485 $as_echo_n "(cached) " >&6
17488 if test $ac_cv_header_strings_h = yes; then
17493 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
17494 /* end confdefs.h. */
17495 #include <strings.h>
17498 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
17499 *) gl_absname_cpp
="$ac_cpp" ;;
17504 gl_dirsep_regex
='[/\\]'
17507 gl_dirsep_regex
='\/'
17510 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
17511 gl_header_literal_regex
=`echo 'strings.h' \
17512 | sed -e "$gl_make_literal_regex_sed"`
17513 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17514 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17520 gl_cv_absolute_strings_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17521 sed -n "$gl_absolute_header_sed"`
17523 gl_header
=$gl_cv_absolute_strings_h
17524 gl_cv_next_strings_h
='"'$gl_header'"'
17526 gl_cv_next_strings_h
='<'strings.h
'>'
17531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_strings_h" >&5
17532 $as_echo "$gl_cv_next_strings_h" >&6; }
17534 NEXT_STRINGS_H
=$gl_cv_next_strings_h
17536 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
17537 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17538 gl_next_as_first_directive
='<'strings.h
'>'
17540 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17541 gl_next_as_first_directive
=$gl_cv_next_strings_h
17543 NEXT_AS_FIRST_DIRECTIVE_STRINGS_H
=$gl_next_as_first_directive
17548 if test $ac_cv_header_strings_h = yes; then
17559 ac_fn_c_check_decl
"$LINENO" "strnlen" "ac_cv_have_decl_strnlen" "$ac_includes_default"
17560 if test "x$ac_cv_have_decl_strnlen" = xyes
; then :
17566 cat >>confdefs.h
<<_ACEOF
17567 #define HAVE_DECL_STRNLEN $ac_have_decl
17573 if test $REPLACE_MEMCHR = 1; then
17576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strstr works" >&5
17577 $as_echo_n "checking whether strstr works... " >&6; }
17578 if ${gl_cv_func_strstr_works_always+:} false
; then :
17579 $as_echo_n "(cached) " >&6
17581 if test "$cross_compiling" = yes; then :
17582 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
17583 /* end confdefs.h. */
17585 #ifdef __GNU_LIBRARY__
17586 #include <features.h>
17587 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ > 12) || (__GLIBC__ > 2)) \
17588 || defined __UCLIBC__
17591 #elif defined __CYGWIN__
17592 #include <cygwin/version.h>
17593 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
17601 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17602 $EGREP "Lucky user" >/dev
/null
2>&1; then :
17603 gl_cv_func_strstr_works_always
="guessing yes"
17605 gl_cv_func_strstr_works_always
="$gl_cross_guess_normal"
17611 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
17612 /* end confdefs.h. */
17614 #include <string.h> /* for strstr */
17615 #ifdef __GNU_LIBRARY__
17616 #include <features.h>
17617 #if __GLIBC__ == 2 && __GLIBC_MINOR__ == 28
17621 #define P "_EF_BF_BD"
17622 #define HAYSTACK "F_BD_CE_BD" P P P P "_C3_88_20" P P P "_C3_A7_20" P
17623 #define NEEDLE P P P P P
17628 return !!strstr (HAYSTACK, NEEDLE);
17634 if ac_fn_c_try_run
"$LINENO"; then :
17635 gl_cv_func_strstr_works_always
=yes
17637 gl_cv_func_strstr_works_always
=no
17639 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
17640 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
17645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strstr_works_always" >&5
17646 $as_echo "$gl_cv_func_strstr_works_always" >&6; }
17647 case "$gl_cv_func_strstr_works_always" in
17655 ac_fn_c_check_decl
"$LINENO" "strtok_r" "ac_cv_have_decl_strtok_r" "$ac_includes_default"
17656 if test "x$ac_cv_have_decl_strtok_r" = xyes
; then :
17662 cat >>confdefs.h
<<_ACEOF
17663 #define HAVE_DECL_STRTOK_R $ac_have_decl
17678 $as_echo "#define _USE_STD_STAT 1" >>confdefs.h
17690 if test $gl_cv_have_include_next = yes; then
17691 gl_cv_next_sys_types_h
='<'sys
/types.h
'>'
17693 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/types.h>" >&5
17694 $as_echo_n "checking absolute name of <sys/types.h>... " >&6; }
17695 if ${gl_cv_next_sys_types_h+:} false
; then :
17696 $as_echo_n "(cached) " >&6
17701 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
17702 /* end confdefs.h. */
17703 #include <sys/types.h>
17706 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
17707 *) gl_absname_cpp
="$ac_cpp" ;;
17712 gl_dirsep_regex
='[/\\]'
17715 gl_dirsep_regex
='\/'
17718 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
17719 gl_header_literal_regex
=`echo 'sys/types.h' \
17720 | sed -e "$gl_make_literal_regex_sed"`
17721 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17722 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17728 gl_cv_absolute_sys_types_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17729 sed -n "$gl_absolute_header_sed"`
17731 gl_header
=$gl_cv_absolute_sys_types_h
17732 gl_cv_next_sys_types_h
='"'$gl_header'"'
17736 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_types_h" >&5
17737 $as_echo "$gl_cv_next_sys_types_h" >&6; }
17739 NEXT_SYS_TYPES_H
=$gl_cv_next_sys_types_h
17741 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
17742 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17743 gl_next_as_first_directive
='<'sys
/types.h
'>'
17745 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17746 gl_next_as_first_directive
=$gl_cv_next_sys_types_h
17748 NEXT_AS_FIRST_DIRECTIVE_SYS_TYPES_H
=$gl_next_as_first_directive
17761 WINDOWS_STAT_INODES
=0
17772 GNULIB_LOCALTIME
=0;
17773 GNULIB_NANOSLEEP
=0;
17777 GNULIB_TIMESPEC_GET
=0;
17781 GNULIB_MDA_TZSET
=1;
17782 HAVE_DECL_LOCALTIME_R
=1;
17786 HAVE_TIMESPEC_GET
=1;
17788 REPLACE_CTIME
=GNULIB_PORTCHECK
;
17789 REPLACE_LOCALTIME_R
=GNULIB_PORTCHECK
;
17790 REPLACE_MKTIME
=GNULIB_PORTCHECK
;
17791 REPLACE_NANOSLEEP
=GNULIB_PORTCHECK
;
17792 REPLACE_STRFTIME
=GNULIB_PORTCHECK
;
17793 REPLACE_TIMEGM
=GNULIB_PORTCHECK
;
17794 REPLACE_TZSET
=GNULIB_PORTCHECK
;
17796 : ${GNULIB_GETTIMEOFDAY=0};
17798 REPLACE_LOCALTIME
=0;
17802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
17803 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
17804 if ${gl_cv_sys_struct_timespec_in_time_h+:} false
; then :
17805 $as_echo_n "(cached) " >&6
17807 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
17808 /* end confdefs.h. */
17814 static struct timespec x; x.tv_sec = x.tv_nsec;
17819 if ac_fn_c_try_compile
"$LINENO"; then :
17820 gl_cv_sys_struct_timespec_in_time_h
=yes
17822 gl_cv_sys_struct_timespec_in_time_h
=no
17824 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
17826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
17827 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
17829 TIME_H_DEFINES_STRUCT_TIMESPEC
=0
17830 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
=0
17831 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
=0
17832 UNISTD_H_DEFINES_STRUCT_TIMESPEC
=0
17833 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
17834 TIME_H_DEFINES_STRUCT_TIMESPEC
=1
17836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
17837 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
17838 if ${gl_cv_sys_struct_timespec_in_sys_time_h+:} false
; then :
17839 $as_echo_n "(cached) " >&6
17841 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
17842 /* end confdefs.h. */
17843 #include <sys/time.h>
17848 static struct timespec x; x.tv_sec = x.tv_nsec;
17853 if ac_fn_c_try_compile
"$LINENO"; then :
17854 gl_cv_sys_struct_timespec_in_sys_time_h
=yes
17856 gl_cv_sys_struct_timespec_in_sys_time_h
=no
17858 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
17860 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
17861 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
17862 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
17863 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
=1
17865 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
17866 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
17867 if ${gl_cv_sys_struct_timespec_in_pthread_h+:} false
; then :
17868 $as_echo_n "(cached) " >&6
17870 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
17871 /* end confdefs.h. */
17872 #include <pthread.h>
17877 static struct timespec x; x.tv_sec = x.tv_nsec;
17882 if ac_fn_c_try_compile
"$LINENO"; then :
17883 gl_cv_sys_struct_timespec_in_pthread_h
=yes
17885 gl_cv_sys_struct_timespec_in_pthread_h
=no
17887 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
17889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
17890 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
17891 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
17892 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
=1
17894 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <unistd.h>" >&5
17895 $as_echo_n "checking for struct timespec in <unistd.h>... " >&6; }
17896 if ${gl_cv_sys_struct_timespec_in_unistd_h+:} false
; then :
17897 $as_echo_n "(cached) " >&6
17899 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
17900 /* end confdefs.h. */
17901 #include <unistd.h>
17906 static struct timespec x; x.tv_sec = x.tv_nsec;
17911 if ac_fn_c_try_compile
"$LINENO"; then :
17912 gl_cv_sys_struct_timespec_in_unistd_h
=yes
17914 gl_cv_sys_struct_timespec_in_unistd_h
=no
17916 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
17918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_unistd_h" >&5
17919 $as_echo "$gl_cv_sys_struct_timespec_in_unistd_h" >&6; }
17920 if test $gl_cv_sys_struct_timespec_in_unistd_h = yes; then
17921 UNISTD_H_DEFINES_STRUCT_TIMESPEC
=1
17942 if test $gl_cv_have_include_next = yes; then
17943 gl_cv_next_time_h
='<'time.h
'>'
17945 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
17946 $as_echo_n "checking absolute name of <time.h>... " >&6; }
17947 if ${gl_cv_next_time_h+:} false
; then :
17948 $as_echo_n "(cached) " >&6
17953 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
17954 /* end confdefs.h. */
17958 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
17959 *) gl_absname_cpp
="$ac_cpp" ;;
17964 gl_dirsep_regex
='[/\\]'
17967 gl_dirsep_regex
='\/'
17970 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
17971 gl_header_literal_regex
=`echo 'time.h' \
17972 | sed -e "$gl_make_literal_regex_sed"`
17973 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17974 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17980 gl_cv_absolute_time_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17981 sed -n "$gl_absolute_header_sed"`
17983 gl_header
=$gl_cv_absolute_time_h
17984 gl_cv_next_time_h
='"'$gl_header'"'
17988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
17989 $as_echo "$gl_cv_next_time_h" >&6; }
17991 NEXT_TIME_H
=$gl_cv_next_time_h
17993 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
17994 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17995 gl_next_as_first_directive
='<'time.h
'>'
17997 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17998 gl_next_as_first_directive
=$gl_cv_next_time_h
18000 NEXT_AS_FIRST_DIRECTIVE_TIME_H
=$gl_next_as_first_directive
18009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME_UTC in <time.h>" >&5
18010 $as_echo_n "checking for TIME_UTC in <time.h>... " >&6; }
18011 if ${gl_cv_time_h_has_TIME_UTC+:} false
; then :
18012 $as_echo_n "(cached) " >&6
18014 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
18015 /* end confdefs.h. */
18021 static int x = TIME_UTC; x++;
18026 if ac_fn_c_try_compile
"$LINENO"; then :
18027 gl_cv_time_h_has_TIME_UTC
=yes
18029 gl_cv_time_h_has_TIME_UTC
=no
18031 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
18033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_h_has_TIME_UTC" >&5
18034 $as_echo "$gl_cv_time_h_has_TIME_UTC" >&6; }
18035 if test $gl_cv_time_h_has_TIME_UTC = yes; then
18036 TIME_H_DEFINES_TIME_UTC
=1
18038 TIME_H_DEFINES_TIME_UTC
=0
18044 ac_fn_c_check_decl
"$LINENO" "execvpe" "ac_cv_have_decl_execvpe" "$ac_includes_default"
18045 if test "x$ac_cv_have_decl_execvpe" = xyes
; then :
18051 cat >>confdefs.h
<<_ACEOF
18052 #define HAVE_DECL_EXECVPE $ac_have_decl
18055 ac_fn_c_check_decl
"$LINENO" "unsetenv" "ac_cv_have_decl_unsetenv" "$ac_includes_default"
18056 if test "x$ac_cv_have_decl_unsetenv" = xyes
; then :
18062 cat >>confdefs.h
<<_ACEOF
18063 #define HAVE_DECL_UNSETENV $ac_have_decl
18070 if test $ac_cv_header_crtdefs_h = yes; then
18080 GNULIB_ISWXDIGIT
=0;
18084 GNULIB_TOWCTRANS
=0;
18088 REPLACE_ISWBLANK
=0;
18089 REPLACE_ISWDIGIT
=0;
18090 REPLACE_ISWXDIGIT
=0;
18100 GL_COND_LIBTOOL_TRUE
=
18101 GL_COND_LIBTOOL_FALSE
='#'
18103 GL_COND_LIBTOOL_TRUE
='#'
18104 GL_COND_LIBTOOL_FALSE
=
18107 gl_cond_libtool
=false
18110 gl_m4_base
='import/m4'
18121 gl_source_base
='import'
18124 if test $ac_cv_func_alloca_works = no
; then
18128 # Define an additional variable used in the Makefile substitution.
18129 if test $ac_cv_working_alloca_h = yes; then
18130 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
18131 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
18132 if ${gl_cv_rpl_alloca+:} false
; then :
18133 $as_echo_n "(cached) " >&6
18136 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
18137 /* end confdefs.h. */
18139 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
18144 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18145 $EGREP "Need own alloca" >/dev
/null
2>&1; then :
18146 gl_cv_rpl_alloca
=yes
18148 gl_cv_rpl_alloca
=no
18154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
18155 $as_echo "$gl_cv_rpl_alloca" >&6; }
18156 if test $gl_cv_rpl_alloca = yes; then
18158 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
18168 if test -n "$ALLOCA_H"; then
18169 GL_GENERATE_ALLOCA_H_TRUE
=
18170 GL_GENERATE_ALLOCA_H_FALSE
='#'
18172 GL_GENERATE_ALLOCA_H_TRUE
='#'
18173 GL_GENERATE_ALLOCA_H_FALSE
=
18177 if test $ac_cv_working_alloca_h = yes; then
18188 if test $ac_cv_header_arpa_inet_h = yes; then
18203 if test $gl_cv_have_include_next = yes; then
18204 gl_cv_next_arpa_inet_h
='<'arpa
/inet.h
'>'
18206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <arpa/inet.h>" >&5
18207 $as_echo_n "checking absolute name of <arpa/inet.h>... " >&6; }
18208 if ${gl_cv_next_arpa_inet_h+:} false
; then :
18209 $as_echo_n "(cached) " >&6
18212 if test $ac_cv_header_arpa_inet_h = yes; then
18217 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
18218 /* end confdefs.h. */
18219 #include <arpa/inet.h>
18222 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
18223 *) gl_absname_cpp
="$ac_cpp" ;;
18228 gl_dirsep_regex
='[/\\]'
18231 gl_dirsep_regex
='\/'
18234 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
18235 gl_header_literal_regex
=`echo 'arpa/inet.h' \
18236 | sed -e "$gl_make_literal_regex_sed"`
18237 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18238 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18244 gl_cv_absolute_arpa_inet_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18245 sed -n "$gl_absolute_header_sed"`
18247 gl_header
=$gl_cv_absolute_arpa_inet_h
18248 gl_cv_next_arpa_inet_h
='"'$gl_header'"'
18250 gl_cv_next_arpa_inet_h
='<'arpa
/inet.h
'>'
18255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_arpa_inet_h" >&5
18256 $as_echo "$gl_cv_next_arpa_inet_h" >&6; }
18258 NEXT_ARPA_INET_H
=$gl_cv_next_arpa_inet_h
18260 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
18261 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18262 gl_next_as_first_directive
='<'arpa
/inet.h
'>'
18264 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18265 gl_next_as_first_directive
=$gl_cv_next_arpa_inet_h
18267 NEXT_AS_FIRST_DIRECTIVE_ARPA_INET_H
=$gl_next_as_first_directive
18277 if test $ac_cv_header_sys_socket_h = yes; then
18280 if test $ac_cv_header_ws2tcpip_h = yes; then
18301 if test $ac_cv_func_btowc = no
; then
18308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether btowc(0) is correct" >&5
18309 $as_echo_n "checking whether btowc(0) is correct... " >&6; }
18310 if ${gl_cv_func_btowc_nul+:} false
; then :
18311 $as_echo_n "(cached) " >&6
18314 if test "$cross_compiling" = yes; then :
18317 # Guess no on Cygwin.
18318 cygwin
*) gl_cv_func_btowc_nul
="guessing no" ;;
18319 # Guess yes on native Windows.
18320 mingw
*) gl_cv_func_btowc_nul
="guessing yes" ;;
18321 # Guess yes otherwise.
18322 *) gl_cv_func_btowc_nul
="guessing yes" ;;
18326 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
18327 /* end confdefs.h. */
18332 if (btowc ('\0') != 0)
18337 if ac_fn_c_try_run
"$LINENO"; then :
18338 gl_cv_func_btowc_nul
=yes
18340 gl_cv_func_btowc_nul
=no
18342 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
18343 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
18348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_btowc_nul" >&5
18349 $as_echo "$gl_cv_func_btowc_nul" >&6; }
18351 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether btowc(EOF) is correct" >&5
18352 $as_echo_n "checking whether btowc(EOF) is correct... " >&6; }
18353 if ${gl_cv_func_btowc_eof+:} false
; then :
18354 $as_echo_n "(cached) " >&6
18358 # Guess no on IRIX.
18359 irix
*) gl_cv_func_btowc_eof
="guessing no" ;;
18360 # Guess yes on native Windows.
18361 mingw
*) gl_cv_func_btowc_eof
="guessing yes" ;;
18362 # Guess yes otherwise.
18363 *) gl_cv_func_btowc_eof
="guessing yes" ;;
18365 if test $LOCALE_FR != none
; then
18366 if test "$cross_compiling" = yes; then :
18369 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
18370 /* end confdefs.h. */
18372 #include <locale.h>
18377 if (setlocale (LC_ALL, "$LOCALE_FR") != NULL)
18379 if (btowc (EOF) != WEOF)
18385 if ac_fn_c_try_run
"$LINENO"; then :
18386 gl_cv_func_btowc_eof
=yes
18388 gl_cv_func_btowc_eof
=no
18390 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
18391 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
18397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_btowc_eof" >&5
18398 $as_echo "$gl_cv_func_btowc_eof" >&6; }
18400 case "$gl_cv_func_btowc_nul" in
18402 *) REPLACE_BTOWC
=1 ;;
18404 case "$gl_cv_func_btowc_eof" in
18406 *) REPLACE_BTOWC
=1 ;;
18410 if test $HAVE_BTOWC = 0 ||
test $REPLACE_BTOWC = 1; then
18419 gl_LIBOBJS
="$gl_LIBOBJS btowc.$ac_objext"
18436 $as_echo "#define GNULIB_TEST_BTOWC 1" >>confdefs.h
18441 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_expect" >&5
18442 $as_echo_n "checking for __builtin_expect... " >&6; }
18443 if ${gl_cv___builtin_expect+:} false
; then :
18444 $as_echo_n "(cached) " >&6
18446 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
18447 /* end confdefs.h. */
18450 main (int argc, char **argv)
18452 argc = __builtin_expect (argc, 100);
18453 return argv[argc != 100][0];
18456 if ac_fn_c_try_link
"$LINENO"; then :
18457 gl_cv___builtin_expect
=yes
18459 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
18460 /* end confdefs.h. */
18462 #include <builtins.h>
18464 main (int argc, char **argv)
18466 argc = __builtin_expect (argc, 100);
18467 return argv[argc != 100][0];
18470 if ac_fn_c_try_link
"$LINENO"; then :
18471 gl_cv___builtin_expect
="in <builtins.h>"
18473 gl_cv___builtin_expect
=no
18475 rm -f core conftest.err conftest.
$ac_objext \
18476 conftest
$ac_exeext conftest.
$ac_ext
18478 rm -f core conftest.err conftest.
$ac_objext \
18479 conftest
$ac_exeext conftest.
$ac_ext
18481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv___builtin_expect" >&5
18482 $as_echo "$gl_cv___builtin_expect" >&6; }
18483 if test "$gl_cv___builtin_expect" = yes; then
18484 $as_echo "#define HAVE___BUILTIN_EXPECT 1" >>confdefs.h
18486 elif test "$gl_cv___builtin_expect" = "in <builtins.h>"; then
18487 $as_echo "#define HAVE___BUILTIN_EXPECT 2" >>confdefs.h
18495 if test $ac_cv_func_canonicalize_file_name = no
; then
18496 HAVE_CANONICALIZE_FILE_NAME
=0
18497 if test $ac_cv_func_realpath = no
; then
18500 case "$gl_cv_func_realpath_works" in
18502 *) REPLACE_REALPATH
=1 ;;
18506 case "$gl_cv_func_realpath_works" in
18510 REPLACE_CANONICALIZE_FILE_NAME
=1
18516 if test $HAVE_CANONICALIZE_FILE_NAME = 0 ||
test $REPLACE_CANONICALIZE_FILE_NAME = 1; then
18525 gl_LIBOBJS
="$gl_LIBOBJS canonicalize-lgpl.$ac_objext"
18530 cat >>confdefs.h
<<_ACEOF
18531 #define GNULIB_CANONICALIZE_LGPL 1
18540 GNULIB_CANONICALIZE_FILE_NAME
=1
18546 $as_echo "#define GNULIB_TEST_CANONICALIZE_FILE_NAME 1" >>confdefs.h
18561 $as_echo "#define GNULIB_TEST_REALPATH 1" >>confdefs.h
18576 $as_echo "#define GNULIB_TEST_CHDIR 1" >>confdefs.h
18582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether this system supports file names of any length" >&5
18583 $as_echo_n "checking whether this system supports file names of any length... " >&6; }
18584 if ${gl_cv_have_unlimited_file_name_length+:} false
; then :
18585 $as_echo_n "(cached) " >&6
18587 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
18588 /* end confdefs.h. */
18590 /* Arrange to define PATH_MAX, like "pathmax.h" does. */
18592 # include <unistd.h>
18594 #include <limits.h>
18595 #if defined HAVE_SYS_PARAM_H && !defined PATH_MAX && !defined MAXPATHLEN
18596 # include <sys/param.h>
18598 #if !defined PATH_MAX && defined MAXPATHLEN
18599 # define PATH_MAX MAXPATHLEN
18603 # define PATH_MAX 1024
18605 #if defined _WIN32 && ! defined __CYGWIN__
18607 # define PATH_MAX 260
18611 have_arbitrary_file_name_length_limit
18614 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18615 $EGREP "have_arbitrary_file_name_length_limit" >/dev
/null
2>&1; then :
18616 gl_cv_have_unlimited_file_name_length
=no
18618 gl_cv_have_unlimited_file_name_length
=yes
18623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_unlimited_file_name_length" >&5
18624 $as_echo "$gl_cv_have_unlimited_file_name_length" >&6; }
18626 if test $gl_cv_have_unlimited_file_name_length = no
; then
18635 gl_LIBOBJS
="$gl_LIBOBJS chdir-long.$ac_objext"
18640 if test $HAVE_CHOWN = 0 ||
test $REPLACE_CHOWN = 1; then
18649 gl_LIBOBJS
="$gl_LIBOBJS chown.$ac_objext"
18652 if test $REPLACE_CHOWN = 1 && test $ac_cv_func_fchown = no
; then
18661 gl_LIBOBJS
="$gl_LIBOBJS fchown-stub.$ac_objext"
18675 $as_echo "#define GNULIB_TEST_CHOWN 1" >>confdefs.h
18682 # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
18683 # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
18685 # Save and restore LIBS so e.g., -lrt, isn't added to it. Otherwise, *all*
18686 # programs in the package would end up linked with that potentially-shared
18687 # library, inducing unnecessary run-time overhead.
18690 gl_saved_libs
=$LIBS
18691 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
18692 $as_echo_n "checking for library containing clock_gettime... " >&6; }
18693 if ${ac_cv_search_clock_gettime+:} false
; then :
18694 $as_echo_n "(cached) " >&6
18696 ac_func_search_save_LIBS
=$LIBS
18697 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
18698 /* end confdefs.h. */
18700 /* Override any GCC internal prototype to avoid an error.
18701 Use char because int might match the return type of a GCC
18702 builtin and then its argument prototype would still apply. */
18706 char clock_gettime ();
18710 return clock_gettime ();
18715 for ac_lib
in '' rt posix4
; do
18716 if test -z "$ac_lib"; then
18717 ac_res
="none required"
18720 LIBS
="-l$ac_lib $ac_func_search_save_LIBS"
18722 if ac_fn_c_try_link
"$LINENO"; then :
18723 ac_cv_search_clock_gettime
=$ac_res
18725 rm -f core conftest.err conftest.
$ac_objext \
18727 if ${ac_cv_search_clock_gettime+:} false
; then :
18731 if ${ac_cv_search_clock_gettime+:} false
; then :
18734 ac_cv_search_clock_gettime
=no
18736 rm conftest.
$ac_ext
18737 LIBS
=$ac_func_search_save_LIBS
18739 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
18740 $as_echo "$ac_cv_search_clock_gettime" >&6; }
18741 ac_res
=$ac_cv_search_clock_gettime
18742 if test "$ac_res" != no
; then :
18743 test "$ac_res" = "none required" || LIBS
="$ac_res $LIBS"
18744 test "$ac_cv_search_clock_gettime" = "none required" ||
18745 LIB_CLOCK_GETTIME
=$ac_cv_search_clock_gettime
18748 for ac_func
in clock_gettime clock_settime
18750 as_ac_var
=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18751 ac_fn_c_check_func
"$LINENO" "$ac_func" "$as_ac_var"
18752 if eval test \"x\$
"$as_ac_var"\" = x
"yes"; then :
18753 cat >>confdefs.h
<<_ACEOF
18754 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18760 LIBS
=$gl_saved_libs
18764 $as_echo "#define GNULIB_TEST_CLOEXEC 1" >>confdefs.h
18771 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
18780 if test $ac_cv_header_sys_socket_h != yes; then
18781 for ac_header
in winsock2.h
18783 ac_fn_c_check_header_mongrel
"$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
18784 if test "x$ac_cv_header_winsock2_h" = xyes
; then :
18785 cat >>confdefs.h
<<_ACEOF
18786 #define HAVE_WINSOCK2_H 1
18794 if test "$ac_cv_header_winsock2_h" = yes; then
18796 UNISTD_H_HAVE_WINSOCK2_H
=1
18797 SYS_IOCTL_H_HAVE_WINSOCK2_H
=1
18803 if test $UNISTD_H_HAVE_WINSOCK2_H = 1; then
18808 if test $REPLACE_CLOSE = 0; then
18812 if test $ac_cv_func_fchdir = no
; then
18816 if test $HAVE_FCHDIR = 0; then
18822 if test $REPLACE_CLOSE = 1; then
18831 gl_LIBOBJS
="$gl_LIBOBJS close.$ac_objext"
18845 $as_echo "#define GNULIB_TEST_CLOSE 1" >>confdefs.h
18852 for ac_func
in closedir
18854 ac_fn_c_check_func
"$LINENO" "closedir" "ac_cv_func_closedir"
18855 if test "x$ac_cv_func_closedir" = xyes
; then :
18856 cat >>confdefs.h
<<_ACEOF
18857 #define HAVE_CLOSEDIR 1
18863 if test $ac_cv_func_closedir = no
; then
18870 if test $ac_cv_func_fchdir = no
; then
18874 if test $HAVE_FCHDIR = 0; then
18875 if test $HAVE_CLOSEDIR = 1; then
18880 case $host_os,$HAVE_CLOSEDIR in
18882 REPLACE_CLOSEDIR
=1;;
18885 if test $HAVE_CLOSEDIR = 0 ||
test $REPLACE_CLOSEDIR = 1; then
18894 gl_LIBOBJS
="$gl_LIBOBJS closedir.$ac_objext"
18908 $as_echo "#define GNULIB_TEST_CLOSEDIR 1" >>confdefs.h
18923 if test $gl_cv_have_include_next = yes; then
18924 gl_cv_next_ctype_h
='<'ctype.h
'>'
18926 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <ctype.h>" >&5
18927 $as_echo_n "checking absolute name of <ctype.h>... " >&6; }
18928 if ${gl_cv_next_ctype_h+:} false
; then :
18929 $as_echo_n "(cached) " >&6
18934 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
18935 /* end confdefs.h. */
18939 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
18940 *) gl_absname_cpp
="$ac_cpp" ;;
18945 gl_dirsep_regex
='[/\\]'
18948 gl_dirsep_regex
='\/'
18951 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
18952 gl_header_literal_regex
=`echo 'ctype.h' \
18953 | sed -e "$gl_make_literal_regex_sed"`
18954 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18955 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18961 gl_cv_absolute_ctype_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18962 sed -n "$gl_absolute_header_sed"`
18964 gl_header
=$gl_cv_absolute_ctype_h
18965 gl_cv_next_ctype_h
='"'$gl_header'"'
18969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_ctype_h" >&5
18970 $as_echo "$gl_cv_next_ctype_h" >&6; }
18972 NEXT_CTYPE_H
=$gl_cv_next_ctype_h
18974 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
18975 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18976 gl_next_as_first_directive
='<'ctype.h
'>'
18978 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18979 gl_next_as_first_directive
=$gl_cv_next_ctype_h
18981 NEXT_AS_FIRST_DIRECTIVE_CTYPE_H
=$gl_next_as_first_directive
18991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for d_ino member in directory struct" >&5
18992 $as_echo_n "checking for d_ino member in directory struct... " >&6; }
18993 if ${gl_cv_struct_dirent_d_ino+:} false
; then :
18994 $as_echo_n "(cached) " >&6
18996 if test "$cross_compiling" = yes; then :
18998 # Guess yes on glibc systems with Linux kernel.
18999 linux
*-gnu*) gl_cv_struct_dirent_d_ino
="guessing yes" ;;
19000 # Guess yes on musl systems with Linux kernel.
19001 linux
*-musl*) gl_cv_struct_dirent_d_ino
="guessing yes" ;;
19002 # Guess no on native Windows.
19003 mingw
*) gl_cv_struct_dirent_d_ino
="guessing no" ;;
19004 # If we don't know, obey --enable-cross-guesses.
19005 *) gl_cv_struct_dirent_d_ino
="$gl_cross_guess_normal" ;;
19009 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
19010 /* end confdefs.h. */
19011 #include <sys/types.h>
19012 #include <sys/stat.h>
19013 #include <dirent.h>
19018 DIR *dp = opendir (".");
19025 { closedir (dp); return 2; }
19026 if (lstat (e->d_name, &st) != 0)
19027 { closedir (dp); return 3; }
19028 if (e->d_ino != st.st_ino)
19029 { closedir (dp); return 4; }
19037 if ac_fn_c_try_run
"$LINENO"; then :
19038 gl_cv_struct_dirent_d_ino
=yes
19040 gl_cv_struct_dirent_d_ino
=no
19042 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
19043 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
19047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_struct_dirent_d_ino" >&5
19048 $as_echo "$gl_cv_struct_dirent_d_ino" >&6; }
19049 case "$gl_cv_struct_dirent_d_ino" in
19052 $as_echo "#define D_INO_IN_DIRENT 1" >>confdefs.h
19058 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for d_type member in directory struct" >&5
19059 $as_echo_n "checking for d_type member in directory struct... " >&6; }
19060 if ${gl_cv_struct_dirent_d_type+:} false
; then :
19061 $as_echo_n "(cached) " >&6
19063 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
19064 /* end confdefs.h. */
19066 #include <sys/types.h>
19067 #include <dirent.h>
19072 struct dirent dp; dp.d_type = 0;
19077 if ac_fn_c_try_link
"$LINENO"; then :
19078 gl_cv_struct_dirent_d_type
=yes
19080 gl_cv_struct_dirent_d_type
=no
19082 rm -f core conftest.err conftest.
$ac_objext \
19083 conftest
$ac_exeext conftest.
$ac_ext
19087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_struct_dirent_d_type" >&5
19088 $as_echo "$gl_cv_struct_dirent_d_type" >&6; }
19089 if test $gl_cv_struct_dirent_d_type = yes; then
19091 $as_echo "#define HAVE_STRUCT_DIRENT_D_TYPE 1" >>confdefs.h
19108 if test $gl_cv_have_include_next = yes; then
19109 gl_cv_next_dirent_h
='<'dirent.h
'>'
19111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <dirent.h>" >&5
19112 $as_echo_n "checking absolute name of <dirent.h>... " >&6; }
19113 if ${gl_cv_next_dirent_h+:} false
; then :
19114 $as_echo_n "(cached) " >&6
19117 if test $ac_cv_header_dirent_h = yes; then
19122 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
19123 /* end confdefs.h. */
19124 #include <dirent.h>
19127 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
19128 *) gl_absname_cpp
="$ac_cpp" ;;
19133 gl_dirsep_regex
='[/\\]'
19136 gl_dirsep_regex
='\/'
19139 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
19140 gl_header_literal_regex
=`echo 'dirent.h' \
19141 | sed -e "$gl_make_literal_regex_sed"`
19142 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19143 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19149 gl_cv_absolute_dirent_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19150 sed -n "$gl_absolute_header_sed"`
19152 gl_header
=$gl_cv_absolute_dirent_h
19153 gl_cv_next_dirent_h
='"'$gl_header'"'
19155 gl_cv_next_dirent_h
='<'dirent.h
'>'
19160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_dirent_h" >&5
19161 $as_echo "$gl_cv_next_dirent_h" >&6; }
19163 NEXT_DIRENT_H
=$gl_cv_next_dirent_h
19165 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
19166 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19167 gl_next_as_first_directive
='<'dirent.h
'>'
19169 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19170 gl_next_as_first_directive
=$gl_cv_next_dirent_h
19172 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H
=$gl_next_as_first_directive
19177 if test $ac_cv_header_dirent_h = yes; then
19193 for ac_func
in dirfd
19195 ac_fn_c_check_func
"$LINENO" "dirfd" "ac_cv_func_dirfd"
19196 if test "x$ac_cv_func_dirfd" = xyes
; then :
19197 cat >>confdefs.h
<<_ACEOF
19198 #define HAVE_DIRFD 1
19204 ac_fn_c_check_decl
"$LINENO" "dirfd" "ac_cv_have_decl_dirfd" "#include <sys/types.h>
19205 #include <dirent.h>
19207 if test "x$ac_cv_have_decl_dirfd" = xyes
; then :
19213 cat >>confdefs.h
<<_ACEOF
19214 #define HAVE_DECL_DIRFD $ac_have_decl
19217 if test $ac_cv_have_decl_dirfd = no
; then
19221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dirfd is a macro" >&5
19222 $as_echo_n "checking whether dirfd is a macro... " >&6; }
19223 if ${gl_cv_func_dirfd_macro+:} false
; then :
19224 $as_echo_n "(cached) " >&6
19226 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
19227 /* end confdefs.h. */
19229 #include <sys/types.h>
19230 #include <dirent.h>
19232 dirent_header_defines_dirfd
19235 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19236 $EGREP "dirent_header_defines_dirfd" >/dev
/null
2>&1; then :
19237 gl_cv_func_dirfd_macro
=yes
19239 gl_cv_func_dirfd_macro
=no
19244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dirfd_macro" >&5
19245 $as_echo "$gl_cv_func_dirfd_macro" >&6; }
19247 # Use the replacement if we have no function or macro with that name,
19248 # or if OS/2 kLIBC whose dirfd() does not work.
19249 # Replace only if the system declares dirfd already.
19250 case $ac_cv_func_dirfd,$gl_cv_func_dirfd_macro,$host_os,$ac_cv_have_decl_dirfd in
19251 no
,no
,*,yes |
*,*,os2
*,yes)
19254 $as_echo "#define REPLACE_DIRFD 1" >>confdefs.h
19258 if test $ac_cv_func_dirfd = no
&& test $gl_cv_func_dirfd_macro = no \
19259 ||
test $REPLACE_DIRFD = 1; then
19268 gl_LIBOBJS
="$gl_LIBOBJS dirfd.$ac_objext"
19271 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to get the file descriptor associated with an open DIR*" >&5
19272 $as_echo_n "checking how to get the file descriptor associated with an open DIR*... " >&6; }
19273 if ${gl_cv_sys_dir_fd_member_name+:} false
; then :
19274 $as_echo_n "(cached) " >&6
19277 dirfd_save_CFLAGS
=$CFLAGS
19278 for ac_expr
in d_fd dd_fd
; do
19280 CFLAGS
="$CFLAGS -DDIR_FD_MEMBER_NAME=$ac_expr"
19281 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
19282 /* end confdefs.h. */
19284 #include <sys/types.h>
19285 #include <dirent.h>
19289 DIR *dir_p = opendir("."); (void) dir_p->DIR_FD_MEMBER_NAME;
19294 if ac_fn_c_try_compile
"$LINENO"; then :
19298 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
19299 CFLAGS
=$dirfd_save_CFLAGS
19300 test "$dir_fd_found" = yes && break
19302 test "$dir_fd_found" = yes || ac_expr
=no_such_member
19304 gl_cv_sys_dir_fd_member_name
=$ac_expr
19308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_dir_fd_member_name" >&5
19309 $as_echo "$gl_cv_sys_dir_fd_member_name" >&6; }
19310 if test $gl_cv_sys_dir_fd_member_name != no_such_member
; then
19312 cat >>confdefs.h
<<_ACEOF
19313 #define DIR_FD_MEMBER_NAME $gl_cv_sys_dir_fd_member_name
19331 $as_echo "#define GNULIB_TEST_DIRFD 1" >>confdefs.h
19337 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether // is distinct from /" >&5
19338 $as_echo_n "checking whether // is distinct from /... " >&6; }
19339 if ${gl_cv_double_slash_root+:} false
; then :
19340 $as_echo_n "(cached) " >&6
19342 if test x
"$cross_compiling" = xyes
; then
19343 # When cross-compiling, there is no way to tell whether // is special
19344 # short of a list of hosts. However, the only known hosts to date
19345 # that have a distinct // are Apollo DomainOS (too old to port to),
19346 # Cygwin, and z/OS. If anyone knows of another system for which // has
19347 # special semantics and is distinct from /, please report it to
19348 # <bug-gnulib@gnu.org>.
19350 *-cygwin | i370-ibm-openedition
)
19351 gl_cv_double_slash_root
=yes ;;
19353 # Be optimistic and assume that / and // are the same when we
19355 gl_cv_double_slash_root
='unknown, assuming no' ;;
19358 set x
`ls -di / // 2>/dev/null`
19359 if test "$2" = "$4" && wc //dev
/null
>/dev
/null
2>&1; then
19360 gl_cv_double_slash_root
=no
19362 gl_cv_double_slash_root
=yes
19366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_double_slash_root" >&5
19367 $as_echo "$gl_cv_double_slash_root" >&6; }
19368 if test "$gl_cv_double_slash_root" = yes; then
19370 $as_echo "#define DOUBLE_SLASH_IS_DISTINCT_ROOT 1" >>confdefs.h
19378 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
19386 if test $ac_cv_func_fchdir = no
; then
19390 if test $HAVE_FCHDIR = 0; then
19394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup works" >&5
19395 $as_echo_n "checking whether dup works... " >&6; }
19396 if ${gl_cv_func_dup_works+:} false
; then :
19397 $as_echo_n "(cached) " >&6
19399 if test "$cross_compiling" = yes; then :
19401 # Guess no on native Windows.
19402 mingw
*) gl_cv_func_dup_works
="guessing no" ;;
19403 *) gl_cv_func_dup_works
="guessing yes" ;;
19407 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
19408 /* end confdefs.h. */
19409 #include <unistd.h>
19419 /* On OS/2 kLIBC, dup does not work on a directory fd. */
19420 int fd = open (".", O_RDONLY);
19421 return fd < 0 ? 1 : dup (fd) < 0 ? 2 : 0;
19428 if ac_fn_c_try_run
"$LINENO"; then :
19429 gl_cv_func_dup_works
=yes
19431 gl_cv_func_dup_works
=no
19433 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
19434 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
19439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup_works" >&5
19440 $as_echo "$gl_cv_func_dup_works" >&6; }
19441 case "$gl_cv_func_dup_works" in
19448 if test $REPLACE_DUP = 1; then
19457 gl_LIBOBJS
="$gl_LIBOBJS dup.$ac_objext"
19472 $as_echo "#define GNULIB_TEST_DUP 1" >>confdefs.h
19479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
19480 $as_echo_n "checking whether dup2 works... " >&6; }
19481 if ${gl_cv_func_dup2_works+:} false
; then :
19482 $as_echo_n "(cached) " >&6
19484 if test "$cross_compiling" = yes; then :
19486 mingw
*) # on this platform, dup2 always returns 0 for success
19487 gl_cv_func_dup2_works
="guessing no" ;;
19488 cygwin
*) # on cygwin 1.5.x, dup2(1,1) returns 0
19489 gl_cv_func_dup2_works
="guessing no" ;;
19491 # on AIX 7.1 and FreeBSD 6.1, dup2 (1,toobig) gives EMFILE,
19493 gl_cv_func_dup2_works
="guessing no" ;;
19494 haiku
*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
19495 gl_cv_func_dup2_works
="guessing no" ;;
19496 *-android*) # implemented using dup3(), which fails if oldfd == newfd
19497 gl_cv_func_dup2_works
="guessing no" ;;
19498 os2
*) # on OS/2 kLIBC, dup2() does not work on a directory fd.
19499 gl_cv_func_dup2_works
="guessing no" ;;
19500 *) gl_cv_func_dup2_works
="guessing yes" ;;
19503 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
19504 /* end confdefs.h. */
19508 #include <limits.h>
19509 #include <sys/resource.h>
19510 #include <unistd.h>
19515 #ifndef RLIM_SAVED_CUR
19516 # define RLIM_SAVED_CUR RLIM_INFINITY
19518 #ifndef RLIM_SAVED_MAX
19519 # define RLIM_SAVED_MAX RLIM_INFINITY
19526 int bad_fd = INT_MAX;
19527 struct rlimit rlim;
19528 if (getrlimit (RLIMIT_NOFILE, &rlim) == 0
19529 && 0 <= rlim.rlim_cur && rlim.rlim_cur <= INT_MAX
19530 && rlim.rlim_cur != RLIM_INFINITY
19531 && rlim.rlim_cur != RLIM_SAVED_MAX
19532 && rlim.rlim_cur != RLIM_SAVED_CUR)
19533 bad_fd = rlim.rlim_cur;
19535 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
19538 if (dup2 (1, 1) != 1)
19541 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
19545 if (dup2 (0, 0) != -1)
19547 /* Many gnulib modules require POSIX conformance of EBADF. */
19548 if (dup2 (2, bad_fd) == -1 && errno != EBADF)
19550 /* Flush out some cygwin core dumps. */
19551 if (dup2 (2, -1) != -1 || errno != EBADF)
19555 /* On OS/2 kLIBC, dup2() does not work on a directory fd. */
19557 int fd = open (".", O_RDONLY);
19560 else if (dup2 (fd, fd + 1) == -1)
19570 if ac_fn_c_try_run
"$LINENO"; then :
19571 gl_cv_func_dup2_works
=yes
19573 gl_cv_func_dup2_works
=no
19575 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
19576 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
19581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
19582 $as_echo "$gl_cv_func_dup2_works" >&6; }
19583 case "$gl_cv_func_dup2_works" in
19587 for ac_func
in setdtablesize
19589 ac_fn_c_check_func
"$LINENO" "setdtablesize" "ac_cv_func_setdtablesize"
19590 if test "x$ac_cv_func_setdtablesize" = xyes
; then :
19591 cat >>confdefs.h
<<_ACEOF
19592 #define HAVE_SETDTABLESIZE 1
19604 if test $ac_cv_func_fchdir = no
; then
19608 if test $HAVE_FCHDIR = 0; then
19613 if test $REPLACE_DUP2 = 1; then
19622 gl_LIBOBJS
="$gl_LIBOBJS dup2.$ac_objext"
19637 $as_echo "#define GNULIB_TEST_DUP2 1" >>confdefs.h
19653 $as_echo "#define GNULIB_TEST_ENVIRON 1" >>confdefs.h
19659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for error_at_line" >&5
19660 $as_echo_n "checking for error_at_line... " >&6; }
19661 if ${ac_cv_lib_error_at_line+:} false
; then :
19662 $as_echo_n "(cached) " >&6
19664 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
19665 /* end confdefs.h. */
19670 error_at_line (0, 0, "", 0, "an error occurred");
19675 if ac_fn_c_try_link
"$LINENO"; then :
19676 ac_cv_lib_error_at_line
=yes
19678 ac_cv_lib_error_at_line
=no
19680 rm -f core conftest.err conftest.
$ac_objext \
19681 conftest
$ac_exeext conftest.
$ac_ext
19683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_error_at_line" >&5
19684 $as_echo "$ac_cv_lib_error_at_line" >&6; }
19686 if test $ac_cv_lib_error_at_line = no
; then
19695 gl_LIBOBJS
="$gl_LIBOBJS error.$ac_objext"
19709 if test $ac_cv_have_decl_fchdir = no
; then
19714 if test $HAVE_FCHDIR = 0; then
19723 gl_LIBOBJS
="$gl_LIBOBJS fchdir.$ac_objext"
19727 $as_echo "#define REPLACE_FCHDIR 1" >>confdefs.h
19729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether open can visit directories" >&5
19730 $as_echo_n "checking whether open can visit directories... " >&6; }
19731 if ${gl_cv_func_open_directory_works+:} false
; then :
19732 $as_echo_n "(cached) " >&6
19734 if test "$cross_compiling" = yes; then :
19736 # Guess yes on Linux systems.
19737 linux-
* | linux
) gl_cv_func_open_directory_works
="guessing yes" ;;
19738 # Guess yes on glibc systems.
19739 *-gnu* | gnu
*) gl_cv_func_open_directory_works
="guessing yes" ;;
19740 # Guess no on native Windows.
19741 mingw
*) gl_cv_func_open_directory_works
="guessing no" ;;
19742 # If we don't know, obey --enable-cross-guesses.
19743 *) gl_cv_func_open_directory_works
="$gl_cross_guess_normal" ;;
19747 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
19748 /* end confdefs.h. */
19757 return open(".", O_RDONLY) < 0;
19762 if ac_fn_c_try_run
"$LINENO"; then :
19763 gl_cv_func_open_directory_works
=yes
19765 gl_cv_func_open_directory_works
=no
19767 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
19768 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
19772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_open_directory_works" >&5
19773 $as_echo "$gl_cv_func_open_directory_works" >&6; }
19774 case "$gl_cv_func_open_directory_works" in
19778 $as_echo "#define REPLACE_OPEN_DIRECTORY 1" >>confdefs.h
19795 $as_echo "#define GNULIB_TEST_FCHDIR 1" >>confdefs.h
19804 if test $ac_cv_func_fcntl = no
; then
19808 if test $ac_cv_func_fcntl = no
; then
19815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl handles F_DUPFD correctly" >&5
19816 $as_echo_n "checking whether fcntl handles F_DUPFD correctly... " >&6; }
19817 if ${gl_cv_func_fcntl_f_dupfd_works+:} false
; then :
19818 $as_echo_n "(cached) " >&6
19820 if test "$cross_compiling" = yes; then :
19822 aix
* | cygwin
* | haiku
*)
19823 gl_cv_func_fcntl_f_dupfd_works
="guessing no" ;;
19824 *) gl_cv_func_fcntl_f_dupfd_works
="guessing yes" ;;
19827 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
19828 /* end confdefs.h. */
19831 #include <limits.h>
19832 #include <sys/resource.h>
19833 #include <unistd.h>
19838 #ifndef RLIM_SAVED_CUR
19839 # define RLIM_SAVED_CUR RLIM_INFINITY
19841 #ifndef RLIM_SAVED_MAX
19842 # define RLIM_SAVED_MAX RLIM_INFINITY
19849 int bad_fd = INT_MAX;
19850 struct rlimit rlim;
19851 if (getrlimit (RLIMIT_NOFILE, &rlim) == 0
19852 && 0 <= rlim.rlim_cur && rlim.rlim_cur <= INT_MAX
19853 && rlim.rlim_cur != RLIM_INFINITY
19854 && rlim.rlim_cur != RLIM_SAVED_MAX
19855 && rlim.rlim_cur != RLIM_SAVED_CUR)
19856 bad_fd = rlim.rlim_cur;
19857 if (fcntl (0, F_DUPFD, -1) != -1) result |= 1;
19858 if (errno != EINVAL) result |= 2;
19859 if (fcntl (0, F_DUPFD, bad_fd) != -1) result |= 4;
19860 if (errno != EINVAL) result |= 8;
19861 /* On OS/2 kLIBC, F_DUPFD does not work on a directory fd */
19864 fd = open (".", O_RDONLY);
19867 else if (fcntl (fd, F_DUPFD, STDERR_FILENO + 1) == -1)
19877 if ac_fn_c_try_run
"$LINENO"; then :
19878 gl_cv_func_fcntl_f_dupfd_works
=yes
19880 gl_cv_func_fcntl_f_dupfd_works
=no
19882 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
19883 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
19887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_works" >&5
19888 $as_echo "$gl_cv_func_fcntl_f_dupfd_works" >&6; }
19889 case $gl_cv_func_fcntl_f_dupfd_works in
19894 if test $ac_cv_func_fcntl = no
; then
19901 $as_echo "#define FCNTL_DUPFD_BUGGY 1" >>confdefs.h
19905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl understands F_DUPFD_CLOEXEC" >&5
19906 $as_echo_n "checking whether fcntl understands F_DUPFD_CLOEXEC... " >&6; }
19907 if ${gl_cv_func_fcntl_f_dupfd_cloexec+:} false
; then :
19908 $as_echo_n "(cached) " >&6
19910 if test "$cross_compiling" = yes; then :
19912 # Guess no on NetBSD.
19913 netbsd
*) gl_cv_func_fcntl_f_dupfd_cloexec
="guessing no" ;;
19914 *) gl_cv_func_fcntl_f_dupfd_cloexec
="$gl_cross_guess_normal" ;;
19918 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
19919 /* end confdefs.h. */
19921 #include <unistd.h>
19922 int main (int argc, char *argv[])
19925 /* parent process */
19927 if (fcntl (1, F_DUPFD_CLOEXEC, 10) < 0)
19929 return execl ("./conftest", "./conftest", "child", NULL);
19932 /* child process */
19933 return (fcntl (10, F_GETFL) < 0 ? 0 : 42);
19938 if ac_fn_c_try_run
"$LINENO"; then :
19939 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
19940 /* end confdefs.h. */
19943 /* The Linux kernel only added F_DUPFD_CLOEXEC in 2.6.24, so we always replace
19944 it to support the semantics on older kernels that failed with EINVAL. */
19956 if ac_fn_c_try_compile
"$LINENO"; then :
19957 gl_cv_func_fcntl_f_dupfd_cloexec
=yes
19959 gl_cv_func_fcntl_f_dupfd_cloexec
="needs runtime check"
19961 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
19964 gl_cv_func_fcntl_f_dupfd_cloexec
=no
19966 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
19967 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
19972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_cloexec" >&5
19973 $as_echo "$gl_cv_func_fcntl_f_dupfd_cloexec" >&6; }
19974 case "$gl_cv_func_fcntl_f_dupfd_cloexec" in
19979 if test $ac_cv_func_fcntl = no
; then
19992 if test $ac_cv_func_fchdir = no
; then
19996 if test $HAVE_FCHDIR = 0; then
20000 if test $ac_cv_func_fcntl = no
; then
20009 if test $HAVE_FCNTL = 0 ||
test $REPLACE_FCNTL = 1; then
20018 gl_LIBOBJS
="$gl_LIBOBJS fcntl.$ac_objext"
20032 $as_echo "#define GNULIB_TEST_FCNTL 1" >>confdefs.h
20047 if test $gl_cv_have_include_next = yes; then
20048 gl_cv_next_fcntl_h
='<'fcntl.h
'>'
20050 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <fcntl.h>" >&5
20051 $as_echo_n "checking absolute name of <fcntl.h>... " >&6; }
20052 if ${gl_cv_next_fcntl_h+:} false
; then :
20053 $as_echo_n "(cached) " >&6
20058 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
20059 /* end confdefs.h. */
20063 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
20064 *) gl_absname_cpp
="$ac_cpp" ;;
20069 gl_dirsep_regex
='[/\\]'
20072 gl_dirsep_regex
='\/'
20075 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
20076 gl_header_literal_regex
=`echo 'fcntl.h' \
20077 | sed -e "$gl_make_literal_regex_sed"`
20078 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
20079 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
20085 gl_cv_absolute_fcntl_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20086 sed -n "$gl_absolute_header_sed"`
20088 gl_header
=$gl_cv_absolute_fcntl_h
20089 gl_cv_next_fcntl_h
='"'$gl_header'"'
20093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_fcntl_h" >&5
20094 $as_echo "$gl_cv_next_fcntl_h" >&6; }
20096 NEXT_FCNTL_H
=$gl_cv_next_fcntl_h
20098 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
20099 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20100 gl_next_as_first_directive
='<'fcntl.h
'>'
20102 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20103 gl_next_as_first_directive
=$gl_cv_next_fcntl_h
20105 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H
=$gl_next_as_first_directive
20121 cat >>confdefs.h
<<_ACEOF
20122 #define GNULIB_FD_SAFER_FLAG 1
20131 ac_fn_c_check_decl
"$LINENO" "fdopendir" "ac_cv_have_decl_fdopendir" "
20132 #include <dirent.h>
20135 if test "x$ac_cv_have_decl_fdopendir" = xyes
; then :
20141 cat >>confdefs.h
<<_ACEOF
20142 #define HAVE_DECL_FDOPENDIR $ac_have_decl
20144 if test $ac_have_decl = 1; then :
20147 HAVE_DECL_FDOPENDIR
=0
20151 if test $ac_cv_func_fdopendir = no
; then
20154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fdopendir works" >&5
20155 $as_echo_n "checking whether fdopendir works... " >&6; }
20156 if ${gl_cv_func_fdopendir_works+:} false
; then :
20157 $as_echo_n "(cached) " >&6
20159 if test "$cross_compiling" = yes; then :
20161 # Guess yes on glibc systems.
20162 *-gnu*) gl_cv_func_fdopendir_works
="guessing yes" ;;
20163 # Guess yes on musl systems.
20164 *-musl*) gl_cv_func_fdopendir_works
="guessing yes" ;;
20165 # If we don't know, obey --enable-cross-guesses.
20166 *) gl_cv_func_fdopendir_works
="$gl_cross_guess_normal" ;;
20170 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
20171 /* end confdefs.h. */
20173 #include <dirent.h>
20175 #include <unistd.h>
20180 #if !HAVE_DECL_FDOPENDIR
20182 # ifdef __cplusplus
20185 DIR *fdopendir (int);
20192 int fd = open ("conftest.c", O_RDONLY);
20193 if (fd < 0) result |= 1;
20194 if (fdopendir (fd)) result |= 2;
20195 if (close (fd)) result |= 4;
20202 if ac_fn_c_try_run
"$LINENO"; then :
20203 gl_cv_func_fdopendir_works
=yes
20205 gl_cv_func_fdopendir_works
=no
20207 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
20208 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
20212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fdopendir_works" >&5
20213 $as_echo "$gl_cv_func_fdopendir_works" >&6; }
20214 case "$gl_cv_func_fdopendir_works" in
20217 REPLACE_FDOPENDIR
=1
20222 if test $HAVE_FDOPENDIR = 0 ||
test $REPLACE_FDOPENDIR = 1; then
20231 gl_LIBOBJS
="$gl_LIBOBJS fdopendir.$ac_objext"
20245 $as_echo "#define GNULIB_TEST_FDOPENDIR 1" >>confdefs.h
20251 cat >>confdefs.h
<<_ACEOF
20252 #define GNULIB_FDOPENDIR 1
20259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ffs" >&5
20260 $as_echo_n "checking for ffs... " >&6; }
20261 if ${gl_cv_func_ffs+:} false
; then :
20262 $as_echo_n "(cached) " >&6
20264 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
20265 /* end confdefs.h. */
20266 #include <strings.h>
20272 int (*func) (int) = ffs;
20280 if ac_fn_c_try_link
"$LINENO"; then :
20285 rm -f core conftest.err conftest.
$ac_objext \
20286 conftest
$ac_exeext conftest.
$ac_ext
20289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_ffs" >&5
20290 $as_echo "$gl_cv_func_ffs" >&6; }
20291 if test $gl_cv_func_ffs = no
; then
20295 if test $HAVE_FFS = 0; then
20304 gl_LIBOBJS
="$gl_LIBOBJS ffs.$ac_objext"
20321 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flexible array member" >&5
20322 $as_echo_n "checking for flexible array member... " >&6; }
20323 if ${ac_cv_c_flexmember+:} false
; then :
20324 $as_echo_n "(cached) " >&6
20326 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
20327 /* end confdefs.h. */
20328 #include <stdlib.h>
20330 #include <stddef.h>
20331 struct m { struct m *next, **list; char name[]; };
20332 struct s { struct s *p; struct m *m; int n; double d[]; };
20336 int m = getchar ();
20337 size_t nbytes = offsetof (struct s, d) + m * sizeof (double);
20338 nbytes += sizeof (struct s) - 1;
20339 nbytes -= nbytes % sizeof (struct s);
20340 struct s *p = malloc (nbytes);
20344 return p->d != (double *) NULL;
20349 if ac_fn_c_try_compile
"$LINENO"; then :
20350 ac_cv_c_flexmember
=yes
20352 ac_cv_c_flexmember
=no
20354 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
20356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_flexmember" >&5
20357 $as_echo "$ac_cv_c_flexmember" >&6; }
20358 if test $ac_cv_c_flexmember = yes; then
20360 $as_echo "#define FLEXIBLE_ARRAY_MEMBER /**/" >>confdefs.h
20363 $as_echo "#define FLEXIBLE_ARRAY_MEMBER 1" >>confdefs.h
20371 REPLACE_FLOAT_LDBL
=0
20373 aix
* | beos
* | openbsd
* | mirbsd
* | irix
*)
20376 freebsd
* | dragonfly
*)
20377 case "$host_cpu" in
20382 # On x86_64 systems, the C compiler may still be generating
20384 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
20385 /* end confdefs.h. */
20386 #if defined __LP64__ || defined __x86_64__ || defined __amd64__
20393 if ac_fn_c_try_compile
"$LINENO"; then :
20398 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
20403 case "$host_cpu" in
20411 aix
* | freebsd
* | dragonfly
* | linux
*)
20412 if test -n "$FLOAT_H"; then
20413 REPLACE_FLOAT_LDBL
=1
20419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether conversion from 'int' to 'long double' works" >&5
20420 $as_echo_n "checking whether conversion from 'int' to 'long double' works... " >&6; }
20421 if ${gl_cv_func_itold_works+:} false
; then :
20422 $as_echo_n "(cached) " >&6
20425 if test "$cross_compiling" = yes; then :
20428 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
20429 /* end confdefs.h. */
20430 #if defined __LP64__ || defined __arch64__
20437 if ac_fn_c_try_compile
"$LINENO"; then :
20438 gl_cv_func_itold_works
="guessing no"
20440 gl_cv_func_itold_works
="guessing yes"
20442 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
20444 # Guess yes on native Windows.
20445 mingw
*) gl_cv_func_itold_works
="guessing yes" ;;
20446 *) gl_cv_func_itold_works
="guessing yes" ;;
20450 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
20451 /* end confdefs.h. */
20454 volatile long double ld;
20463 if ac_fn_c_try_run
"$LINENO"; then :
20464 gl_cv_func_itold_works
=yes
20466 gl_cv_func_itold_works
=no
20468 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
20469 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
20474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_itold_works" >&5
20475 $as_echo "$gl_cv_func_itold_works" >&6; }
20476 case "$gl_cv_func_itold_works" in
20483 if test -n "$FLOAT_H"; then
20492 if test $gl_cv_have_include_next = yes; then
20493 gl_cv_next_float_h
='<'float.h
'>'
20495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <float.h>" >&5
20496 $as_echo_n "checking absolute name of <float.h>... " >&6; }
20497 if ${gl_cv_next_float_h+:} false
; then :
20498 $as_echo_n "(cached) " >&6
20503 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
20504 /* end confdefs.h. */
20508 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
20509 *) gl_absname_cpp
="$ac_cpp" ;;
20514 gl_dirsep_regex
='[/\\]'
20517 gl_dirsep_regex
='\/'
20520 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
20521 gl_header_literal_regex
=`echo 'float.h' \
20522 | sed -e "$gl_make_literal_regex_sed"`
20523 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
20524 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
20530 gl_cv_absolute_float_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20531 sed -n "$gl_absolute_header_sed"`
20533 gl_header
=$gl_cv_absolute_float_h
20534 gl_cv_next_float_h
='"'$gl_header'"'
20538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_float_h" >&5
20539 $as_echo "$gl_cv_next_float_h" >&6; }
20541 NEXT_FLOAT_H
=$gl_cv_next_float_h
20543 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
20544 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20545 gl_next_as_first_directive
='<'float.h
'>'
20547 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20548 gl_next_as_first_directive
=$gl_cv_next_float_h
20550 NEXT_AS_FIRST_DIRECTIVE_FLOAT_H
=$gl_next_as_first_directive
20557 if test -n "$FLOAT_H"; then
20558 GL_GENERATE_FLOAT_H_TRUE
=
20559 GL_GENERATE_FLOAT_H_FALSE
='#'
20561 GL_GENERATE_FLOAT_H_TRUE
='#'
20562 GL_GENERATE_FLOAT_H_FALSE
=
20567 if test $REPLACE_FLOAT_LDBL = 1; then
20576 gl_LIBOBJS
="$gl_LIBOBJS float.$ac_objext"
20579 if test $REPLACE_ITOLD = 1; then
20588 gl_LIBOBJS
="$gl_LIBOBJS itold.$ac_objext"
20595 gl_fnmatch_required_lowercase
=`
20596 echo $gl_fnmatch_required | LC_ALL=C tr '[A-Z]' '[a-z]'
20599 if test $ac_cv_func_fnmatch = no
; then
20602 gl_fnmatch_cache_var
="gl_cv_func_fnmatch_${gl_fnmatch_required_lowercase}"
20603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working $gl_fnmatch_required fnmatch" >&5
20604 $as_echo_n "checking for working $gl_fnmatch_required fnmatch... " >&6; }
20605 if eval \
${$gl_fnmatch_cache_var+:} false
; then :
20606 $as_echo_n "(cached) " >&6
20608 if test $gl_fnmatch_required = GNU
; then
20609 gl_fnmatch_gnu_start
=
20610 gl_fnmatch_gnu_end
=
20612 gl_fnmatch_gnu_start
='#if 0'
20613 gl_fnmatch_gnu_end
='#endif'
20615 if test "$cross_compiling" = yes; then :
20617 # Guess yes on musl systems.
20618 *-musl*) eval "$gl_fnmatch_cache_var=\"guessing yes\"" ;;
20619 # Guess no otherwise, even on glibc systems.
20620 *) eval "$gl_fnmatch_cache_var=\"guessing no\"" ;;
20624 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
20625 /* end confdefs.h. */
20626 #include <fnmatch.h>
20628 y (char const *pattern, char const *string, int flags)
20630 return fnmatch (pattern, string, flags) == 0;
20633 n (char const *pattern, char const *string, int flags)
20635 return fnmatch (pattern, string, flags) == FNM_NOMATCH;
20641 char const *Apat = 'A' < '\\\\' ? "[A-\\\\\\\\]" : "[\\\\\\\\-A]";
20642 char const *apat = 'a' < '\\\\' ? "[a-\\\\\\\\]" : "[\\\\\\\\-a]";
20643 static char const A_1[] = { 'A' - 1, 0 };
20644 static char const A01[] = { 'A' + 1, 0 };
20645 static char const a_1[] = { 'a' - 1, 0 };
20646 static char const a01[] = { 'a' + 1, 0 };
20647 static char const bs_1[] = { '\\\\' - 1, 0 };
20648 static char const bs01[] = { '\\\\' + 1, 0 };
20650 if (!n ("a*", "", 0))
20652 if (!y ("a*", "abc", 0))
20654 if (!y ("[/b", "[/b", 0)) /*"]]"*/ /* glibc Bugzilla bug 12378 */
20656 if (!n ("d*/*1", "d/s/1", FNM_PATHNAME))
20658 if (!y ("a\\\\bc", "abc", 0))
20660 if (!n ("a\\\\bc", "abc", FNM_NOESCAPE))
20662 if (!y ("*x", ".x", 0))
20664 if (!n ("*x", ".x", FNM_PERIOD))
20666 if (!y (Apat, "\\\\", 0))
20668 if (!y (Apat, "A", 0))
20670 if (!y (apat, "\\\\", 0))
20672 if (!y (apat, "a", 0))
20674 if (!(n (Apat, A_1, 0) == ('A' < '\\\\')))
20676 if (!(n (apat, a_1, 0) == ('a' < '\\\\')))
20678 if (!(y (Apat, A01, 0) == ('A' < '\\\\')))
20680 if (!(y (apat, a01, 0) == ('a' < '\\\\')))
20682 if (!(y (Apat, bs_1, 0) == ('A' < '\\\\')))
20684 if (!(y (apat, bs_1, 0) == ('a' < '\\\\')))
20686 if (!(n (Apat, bs01, 0) == ('A' < '\\\\')))
20688 if (!(n (apat, bs01, 0) == ('a' < '\\\\')))
20690 $gl_fnmatch_gnu_start
20691 if (!y ("xxXX", "xXxX", FNM_CASEFOLD))
20693 if (!y ("a++(x|yy)b", "a+xyyyyxb", FNM_EXTMATCH))
20695 if (!n ("d*/*1", "d/s/1", FNM_FILE_NAME))
20697 if (!y ("*", "x", FNM_FILE_NAME | FNM_LEADING_DIR))
20699 if (!y ("x*", "x/y/z", FNM_FILE_NAME | FNM_LEADING_DIR))
20701 if (!y ("*c*", "c/x", FNM_FILE_NAME | FNM_LEADING_DIR))
20703 $gl_fnmatch_gnu_end
20710 if ac_fn_c_try_run
"$LINENO"; then :
20711 eval "$gl_fnmatch_cache_var=yes"
20713 eval "$gl_fnmatch_cache_var=no"
20715 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
20716 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
20721 eval ac_res
=\$
$gl_fnmatch_cache_var
20722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20723 $as_echo "$ac_res" >&6; }
20724 eval "gl_fnmatch_result=\"\$$gl_fnmatch_cache_var\""
20725 case "$gl_fnmatch_result" in
20727 *) REPLACE_FNMATCH
=1 ;;
20730 if test $HAVE_FNMATCH = 0 ||
test $REPLACE_FNMATCH = 1; then
20733 FNMATCH_H
='fnmatch.h'
20734 if test -n "$FNMATCH_H"; then
20735 GL_GENERATE_FNMATCH_H_TRUE
=
20736 GL_GENERATE_FNMATCH_H_FALSE
='#'
20738 GL_GENERATE_FNMATCH_H_TRUE
='#'
20739 GL_GENERATE_FNMATCH_H_FALSE
=
20745 if test $HAVE_FNMATCH = 0 ||
test $REPLACE_FNMATCH = 1; then
20754 gl_LIBOBJS
="$gl_LIBOBJS fnmatch.$ac_objext"
20772 $as_echo "#define GNULIB_TEST_FNMATCH 1" >>confdefs.h
20781 if test $HAVE_FNMATCH = 0 ||
test $REPLACE_FNMATCH = 1; then
20790 gl_LIBOBJS
="$gl_LIBOBJS fnmatch.$ac_objext"
20799 cat >>confdefs.h
<<_ACEOF
20800 #define GNULIB_FNMATCH_GNU 1
20808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether free is known to preserve errno" >&5
20809 $as_echo_n "checking whether free is known to preserve errno... " >&6; }
20810 if ${gl_cv_func_free_preserves_errno+:} false
; then :
20811 $as_echo_n "(cached) " >&6
20813 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
20814 /* end confdefs.h. */
20815 #include <stdlib.h>
20820 #if 2 < __GLIBC__ + (33 <= __GLIBC_MINOR__)
20821 #elif defined __OpenBSD__
20822 #elif defined __sun
20824 #error "'free' is not known to preserve errno"
20831 if ac_fn_c_try_compile
"$LINENO"; then :
20832 gl_cv_func_free_preserves_errno
=yes
20834 gl_cv_func_free_preserves_errno
=no
20836 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
20839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_free_preserves_errno" >&5
20840 $as_echo "$gl_cv_func_free_preserves_errno" >&6; }
20842 case $gl_cv_func_free_preserves_errno in
20844 *) REPLACE_FREE
=1 ;;
20847 if test $REPLACE_FREE = 1; then
20856 gl_LIBOBJS
="$gl_LIBOBJS free.$ac_objext"
20865 GNULIB_FREE_POSIX
=1
20871 $as_echo "#define GNULIB_TEST_FREE_POSIX 1" >>confdefs.h
20876 if test $gl_func_frexp != yes; then
20885 gl_LIBOBJS
="$gl_LIBOBJS frexp.$ac_objext"
20899 $as_echo "#define GNULIB_TEST_FREXP 1" >>confdefs.h
20904 if test $HAVE_DECL_FREXPL = 0 ||
test $gl_func_frexpl = no
; then
20913 gl_LIBOBJS
="$gl_LIBOBJS frexpl.$ac_objext"
20927 $as_echo "#define GNULIB_TEST_FREXPL 1" >>confdefs.h
20945 if test $ac_cv_func_fchdir = no
; then
20949 if test $HAVE_FCHDIR = 0; then
20950 case "$gl_cv_func_open_directory_works" in
20959 if test $REPLACE_FSTAT = 1; then
20968 gl_LIBOBJS
="$gl_LIBOBJS fstat.$ac_objext"
20980 gl_LIBOBJS
="$gl_LIBOBJS stat-w32.$ac_objext"
21001 $as_echo "#define GNULIB_TEST_FSTAT 1" >>confdefs.h
21012 if test $ac_cv_func_fstatat = no
; then
21015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fstatat (..., 0) works" >&5
21016 $as_echo_n "checking whether fstatat (..., 0) works... " >&6; }
21017 if ${gl_cv_func_fstatat_zero_flag+:} false
; then :
21018 $as_echo_n "(cached) " >&6
21020 if test "$cross_compiling" = yes; then :
21022 aix
*) gl_cv_func_fstatat_zero_flag
="guessing no";;
21023 *) gl_cv_func_fstatat_zero_flag
="guessing yes";;
21027 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
21028 /* end confdefs.h. */
21031 #include <sys/stat.h>
21036 return fstatat (AT_FDCWD, ".", &a, 0) != 0;
21040 if ac_fn_c_try_run
"$LINENO"; then :
21041 gl_cv_func_fstatat_zero_flag
=yes
21043 gl_cv_func_fstatat_zero_flag
=no
21045 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
21046 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
21051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fstatat_zero_flag" >&5
21052 $as_echo "$gl_cv_func_fstatat_zero_flag" >&6; }
21054 case $gl_cv_func_fstatat_zero_flag+$gl_cv_func_lstat_dereferences_slashed_symlink in
21056 *) REPLACE_FSTATAT
=1 ;;
21061 REPLACE_FSTATAT
=1 ;;
21064 case $REPLACE_FSTATAT,$gl_cv_func_fstatat_zero_flag in
21067 $as_echo "#define HAVE_WORKING_FSTATAT_ZERO_FLAG 1" >>confdefs.h
21073 if test $HAVE_FSTATAT = 0 ||
test $REPLACE_FSTATAT = 1; then
21082 gl_LIBOBJS
="$gl_LIBOBJS fstatat.$ac_objext"
21096 $as_echo "#define GNULIB_TEST_FSTATAT 1" >>confdefs.h
21108 gl_cv_func_getcwd_path_max
=yes
21116 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getcwd handles long file names properly" >&5
21117 $as_echo_n "checking whether getcwd handles long file names properly... " >&6; }
21118 if ${gl_cv_func_getcwd_path_max+:} false
; then :
21119 $as_echo_n "(cached) " >&6
21121 # Arrange for deletion of the temporary directory this test creates.
21122 ac_clean_files
="$ac_clean_files confdir3"
21123 if test "$cross_compiling" = yes; then :
21124 # Cross-compilation guesses:
21126 aix
*) # On AIX, it has the AIX bug.
21127 gl_cv_func_getcwd_path_max
='guessing no, it has the AIX bug' ;;
21128 gnu
*) # On Hurd, it is 'yes'.
21129 gl_cv_func_getcwd_path_max
='guessing yes' ;;
21130 linux
* | kfreebsd
*)
21131 # On older Linux+glibc it's 'no, but it is partly working',
21132 # on newer Linux+glibc it's 'yes'.
21133 # On Linux+musl libc, it's 'no, but it is partly working'.
21134 # On kFreeBSD+glibc, it's 'no, but it is partly working'.
21135 gl_cv_func_getcwd_path_max
='guessing no, but it is partly working' ;;
21136 *) # If we don't know, obey --enable-cross-guesses.
21137 gl_cv_func_getcwd_path_max
="$gl_cross_guess_normal" ;;
21141 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
21142 /* end confdefs.h. */
21145 #include <stdlib.h>
21147 # include <unistd.h>
21149 # include <direct.h>
21151 #include <string.h>
21152 #include <limits.h>
21153 #include <sys/stat.h>
21154 #include <sys/types.h>
21158 /* Arrange to define PATH_MAX, like "pathmax.h" does. */
21160 # include <unistd.h>
21162 #include <limits.h>
21163 #if defined HAVE_SYS_PARAM_H && !defined PATH_MAX && !defined MAXPATHLEN
21164 # include <sys/param.h>
21166 #if !defined PATH_MAX && defined MAXPATHLEN
21167 # define PATH_MAX MAXPATHLEN
21171 # define PATH_MAX 1024
21173 #if defined _WIN32 && ! defined __CYGWIN__
21175 # define PATH_MAX 260
21180 # define AT_FDCWD 0
21182 #ifdef ENAMETOOLONG
21183 # define is_ENAMETOOLONG(x) ((x) == ENAMETOOLONG)
21185 # define is_ENAMETOOLONG(x) 0
21188 /* Use the getcwd function, not any macro. */
21197 # define S_IRWXU 0700
21200 /* The length of this name must be 8. */
21201 #define DIR_NAME "confdir3"
21202 #define DIR_NAME_LEN 8
21203 #define DIR_NAME_SIZE (DIR_NAME_LEN + 1)
21205 /* The length of "../". */
21206 #define DOTDOTSLASH_LEN 3
21208 /* Leftover bytes in the buffer, to work around library or OS bugs. */
21209 #define BUF_SLOP 20
21215 /* The Hurd doesn't define this, so getcwd can't exhibit the bug --
21216 at least not on a local file system. And if we were to start worrying
21217 about remote file systems, we'd have to enable the wrapper function
21218 all of the time, just to be safe. That's not worth the cost. */
21220 #elif ((INT_MAX / (DIR_NAME_SIZE / DOTDOTSLASH_LEN + 1) \
21221 - DIR_NAME_SIZE - BUF_SLOP) \
21223 /* FIXME: Assuming there's a system for which this is true,
21224 this should be done in a compile test. */
21227 char buf[PATH_MAX * (DIR_NAME_SIZE / DOTDOTSLASH_LEN + 1)
21228 + DIR_NAME_SIZE + BUF_SLOP];
21229 char *cwd = getcwd (buf, PATH_MAX);
21230 size_t initial_cwd_len;
21233 size_t n_chdirs = 0;
21238 cwd_len = initial_cwd_len = strlen (cwd);
21242 size_t dotdot_max = PATH_MAX * (DIR_NAME_SIZE / DOTDOTSLASH_LEN);
21245 cwd_len += DIR_NAME_SIZE;
21246 /* If mkdir or chdir fails, it could be that this system cannot create
21247 any file with an absolute name longer than PATH_MAX, such as cygwin.
21248 If so, leave fail as 0, because the current working directory can't
21249 be too long for getcwd if it can't even be created. On Linux with
21250 the 9p file system, mkdir fails with error EINVAL when cwd_len gets
21251 too long; ignore this failure because the getcwd() system call
21252 produces good results whereas the gnulib substitute calls getdents64
21253 which fails with error EPROTO.
21254 For other errors, be pessimistic and consider that as a failure,
21256 if (mkdir (DIR_NAME, S_IRWXU) < 0 || chdir (DIR_NAME) < 0)
21258 if (! (errno == ERANGE || is_ENAMETOOLONG (errno)))
21260 if (! (errno == EINVAL))
21266 if (PATH_MAX <= cwd_len && cwd_len < PATH_MAX + DIR_NAME_SIZE)
21270 c = getcwd (buf, PATH_MAX);
21271 if (!c && errno == ENOENT)
21281 if (! (errno == ERANGE || is_ENAMETOOLONG (errno)))
21287 /* Our replacement needs to be able to stat() long ../../paths,
21288 so generate a path larger than PATH_MAX to check,
21289 avoiding the replacement if we can't stat(). */
21290 c = getcwd (buf, cwd_len + 1);
21291 if (c && !AT_FDCWD && stat (c, &sb) != 0 && is_ENAMETOOLONG (errno))
21298 if (dotdot_max <= cwd_len - initial_cwd_len)
21300 if (dotdot_max + DIR_NAME_SIZE < cwd_len - initial_cwd_len)
21302 c = getcwd (buf, cwd_len + 1);
21305 if (! (errno == ERANGE || errno == ENOENT
21306 || is_ENAMETOOLONG (errno)))
21311 if (AT_FDCWD || errno == ERANGE || errno == ENOENT)
21319 if (c && strlen (c) != cwd_len)
21327 /* Leaving behind such a deep directory is not polite.
21328 So clean up here, right away, even though the driving
21329 shell script would also clean up. */
21333 /* Try rmdir first, in case the chdir failed. */
21335 for (i = 0; i <= n_chdirs; i++)
21337 if (chdir ("..") < 0)
21339 if (rmdir (DIR_NAME) != 0)
21349 if ac_fn_c_try_run
"$LINENO"; then :
21350 gl_cv_func_getcwd_path_max
=yes
21353 10|
11|
12) gl_cv_func_getcwd_path_max
='no, but it is partly working';;
21354 31) gl_cv_func_getcwd_path_max
='no, it has the AIX bug';;
21355 32) gl_cv_func_getcwd_path_max
='yes, but with shorter paths';;
21356 *) gl_cv_func_getcwd_path_max
=no
;;
21359 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
21360 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
21365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_path_max" >&5
21366 $as_echo "$gl_cv_func_getcwd_path_max" >&6; }
21368 case "$gl_cv_func_getcwd_null" in
21376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getpagesize" >&5
21377 $as_echo_n "checking for getpagesize... " >&6; }
21378 if ${gl_cv_func_getpagesize+:} false
; then :
21379 $as_echo_n "(cached) " >&6
21381 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
21382 /* end confdefs.h. */
21383 #include <unistd.h>
21387 return getpagesize();
21393 if ac_fn_c_try_link
"$LINENO"; then :
21394 gl_cv_func_getpagesize
=yes
21396 gl_cv_func_getpagesize
=no
21398 rm -f core conftest.err conftest.
$ac_objext \
21399 conftest
$ac_exeext conftest.
$ac_ext
21402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getpagesize" >&5
21403 $as_echo "$gl_cv_func_getpagesize" >&6; }
21405 if test $gl_cv_func_getpagesize = yes; then
21407 cat >>confdefs.h
<<_ACEOF
21408 #define HAVE_GETPAGESIZE 1
21413 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getcwd succeeds when 4k < cwd_length < 16k" >&5
21414 $as_echo_n "checking whether getcwd succeeds when 4k < cwd_length < 16k... " >&6; }
21415 if ${gl_cv_func_getcwd_succeeds_beyond_4k+:} false
; then :
21416 $as_echo_n "(cached) " >&6
21418 # Remove any remnants of a previous test.
21419 rm -rf confdir-14B---
21420 # Arrange for deletion of the temporary directory this test creates.
21421 ac_clean_files
="$ac_clean_files confdir-14B---"
21422 if test "$cross_compiling" = yes; then :
21424 # Guess yes on musl systems.
21425 *-musl*) gl_cv_func_getcwd_succeeds_beyond_4k
="guessing yes" ;;
21426 # Guess no otherwise, even on glibc systems.
21427 *) gl_cv_func_getcwd_succeeds_beyond_4k
="guessing no"
21431 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
21432 /* end confdefs.h. */
21435 #include <stdlib.h>
21437 # include <unistd.h>
21438 #else /* on Windows with MSVC */
21439 # include <direct.h>
21441 #include <string.h>
21442 #include <sys/stat.h>
21445 /* Arrange to define PATH_MAX, like "pathmax.h" does. */
21447 # include <unistd.h>
21449 #include <limits.h>
21450 #if defined HAVE_SYS_PARAM_H && !defined PATH_MAX && !defined MAXPATHLEN
21451 # include <sys/param.h>
21453 #if !defined PATH_MAX && defined MAXPATHLEN
21454 # define PATH_MAX MAXPATHLEN
21458 # define PATH_MAX 1024
21460 #if defined _WIN32 && ! defined __CYGWIN__
21462 # define PATH_MAX 260
21471 # define S_IRWXU 0700
21474 /* FIXME: skip the run-test altogether on systems without getpagesize. */
21475 #if ! HAVE_GETPAGESIZE
21476 # define getpagesize() 0
21479 /* This size is chosen to be larger than PATH_MAX (4k), yet smaller than
21480 the 16kB pagesize on ia64 linux. Those conditions make the code below
21481 trigger a bug in glibc's getcwd implementation before 2.4.90-10. */
21482 #define TARGET_LEN (5 * 1024)
21488 size_t initial_cwd_len;
21491 /* The bug is triggered when PATH_MAX < getpagesize (), so skip
21492 this relatively expensive and invasive test if that's not true. */
21494 int bug_possible = PATH_MAX < getpagesize ();
21496 int bug_possible = 0;
21498 if (! bug_possible)
21501 cwd = getcwd (NULL, 0);
21505 initial_cwd_len = strlen (cwd);
21510 static char const dir_name[] = "confdir-14B---";
21511 size_t desired_depth = ((TARGET_LEN - 1 - initial_cwd_len)
21512 / sizeof dir_name);
21514 for (d = 0; d < desired_depth; d++)
21516 if (mkdir (dir_name, S_IRWXU) < 0 || chdir (dir_name) < 0)
21518 if (! (errno == ERANGE || errno == ENAMETOOLONG
21519 || errno == ENOENT))
21520 fail = 3; /* Unable to construct deep hierarchy. */
21525 /* If libc has the bug in question, this invocation of getcwd
21526 results in a failed assertion. */
21527 cwd = getcwd (NULL, 0);
21529 fail = 4; /* getcwd didn't assert, but it failed for a long name
21530 where the answer could have been learned. */
21533 /* Call rmdir first, in case the above chdir failed. */
21537 if (chdir ("..") < 0)
21550 if ac_fn_c_try_run
"$LINENO"; then :
21551 gl_cv_func_getcwd_succeeds_beyond_4k
=yes
21554 if test $ret -ge 128 ||
test $ret = 4; then
21555 gl_cv_func_getcwd_succeeds_beyond_4k
=no
21557 gl_cv_func_getcwd_succeeds_beyond_4k
=yes
21561 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
21562 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
21567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_succeeds_beyond_4k" >&5
21568 $as_echo "$gl_cv_func_getcwd_succeeds_beyond_4k" >&6; }
21569 case "$gl_cv_func_getcwd_succeeds_beyond_4k" in
21582 case "$gl_cv_func_getcwd_path_max" in
21583 *"no" |
*"no, it has the AIX bug") ;;
21586 $as_echo "#define HAVE_MINIMALLY_WORKING_GETCWD 1" >>confdefs.h
21590 case "$gl_cv_func_getcwd_path_max" in
21591 *"no, but it is partly working")
21593 $as_echo "#define HAVE_PARTLY_WORKING_GETCWD 1" >>confdefs.h
21596 *"yes, but with shorter paths")
21598 $as_echo "#define HAVE_GETCWD_SHORTER 1" >>confdefs.h
21603 if { case "$gl_cv_func_getcwd_null" in *yes) false
;; *) true
;; esac; } \
21604 ||
test $gl_cv_func_getcwd_posix_signature != yes \
21605 ||
{ case "$gl_cv_func_getcwd_path_max" in *yes*) false
;; *) true
;; esac; } \
21606 ||
test $gl_abort_bug = yes; then
21610 if test $REPLACE_GETCWD = 1; then
21619 gl_LIBOBJS
="$gl_LIBOBJS getcwd.$ac_objext"
21629 cat >>confdefs.h
<<_ACEOF
21630 #define GNULIB_GETCWD 1
21645 $as_echo "#define GNULIB_TEST_GETCWD 1" >>confdefs.h
21654 case $gl_cv_func_getcwd_null,$gl_cv_func_getcwd_posix_signature in
21661 if test $REPLACE_GETCWD = 1; then
21670 gl_LIBOBJS
="$gl_LIBOBJS getcwd-lgpl.$ac_objext"
21684 $as_echo "#define GNULIB_TEST_GETCWD 1" >>confdefs.h
21696 if test $ac_cv_func_getdelim = yes; then
21698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getdelim function" >&5
21699 $as_echo_n "checking for working getdelim function... " >&6; }
21700 if ${gl_cv_func_working_getdelim+:} false
; then :
21701 $as_echo_n "(cached) " >&6
21703 echo fooNbarN |
tr -d '\012' |
tr N
'\012' > conftest.data
21704 if test "$cross_compiling" = yes; then :
21705 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
21706 /* end confdefs.h. */
21708 #include <features.h>
21709 #ifdef __GNU_LIBRARY__
21710 #if (__GLIBC__ >= 2) && !defined __UCLIBC__
21716 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
21717 $EGREP "Lucky GNU user" >/dev
/null
2>&1; then :
21718 gl_cv_func_working_getdelim
="guessing yes"
21721 *-musl*) gl_cv_func_working_getdelim
="guessing yes" ;;
21722 *) gl_cv_func_working_getdelim
="$gl_cross_guess_normal" ;;
21730 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
21731 /* end confdefs.h. */
21733 # include <stdio.h>
21734 # include <stdlib.h>
21735 # include <string.h>
21738 FILE *in = fopen ("./conftest.data", "r");
21742 /* Test result for a NULL buffer and a zero size.
21743 Based on a test program from Karl Heuer. */
21746 int len = getdelim (&line, &siz, '\n', in);
21747 if (!(len == 4 && line && strcmp (line, "foo\n") == 0))
21748 { free (line); fclose (in); return 2; }
21752 /* Test result for a NULL buffer and a non-zero size.
21753 This crashes on FreeBSD 8.0. */
21755 size_t siz = (size_t)(~0) / 4;
21756 if (getdelim (&line, &siz, '\n', in) == -1)
21757 { fclose (in); return 3; }
21765 if ac_fn_c_try_run
"$LINENO"; then :
21766 gl_cv_func_working_getdelim
=yes
21768 gl_cv_func_working_getdelim
=no
21770 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
21771 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
21776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_getdelim" >&5
21777 $as_echo "$gl_cv_func_working_getdelim" >&6; }
21778 case "$gl_cv_func_working_getdelim" in
21780 *) REPLACE_GETDELIM
=1 ;;
21786 if test $ac_cv_have_decl_getdelim = no
; then
21787 HAVE_DECL_GETDELIM
=0
21790 if test $HAVE_GETDELIM = 0 ||
test $REPLACE_GETDELIM = 1; then
21799 gl_LIBOBJS
="$gl_LIBOBJS getdelim.$ac_objext"
21802 for ac_func
in flockfile funlockfile
21804 as_ac_var
=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21805 ac_fn_c_check_func
"$LINENO" "$ac_func" "$as_ac_var"
21806 if eval test \"x\$
"$as_ac_var"\" = x
"yes"; then :
21807 cat >>confdefs.h
<<_ACEOF
21808 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21814 ac_fn_c_check_decl
"$LINENO" "getc_unlocked" "ac_cv_have_decl_getc_unlocked" "$ac_includes_default"
21815 if test "x$ac_cv_have_decl_getc_unlocked" = xyes
; then :
21821 cat >>confdefs.h
<<_ACEOF
21822 #define HAVE_DECL_GETC_UNLOCKED $ac_have_decl
21838 $as_echo "#define GNULIB_TEST_GETDELIM 1" >>confdefs.h
21847 if test $ac_cv_func_getdtablesize = yes &&
21848 test $ac_cv_have_decl_getdtablesize = yes; then
21849 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getdtablesize works" >&5
21850 $as_echo_n "checking whether getdtablesize works... " >&6; }
21851 if ${gl_cv_func_getdtablesize_works+:} false
; then :
21852 $as_echo_n "(cached) " >&6
21855 vms
*) gl_cv_func_getdtablesize_works
="no (limitation)" ;;
21857 if test "$cross_compiling" = yes; then :
21859 cygwin
*) # on cygwin 1.5.25, getdtablesize() automatically grows
21860 gl_cv_func_getdtablesize_works
="guessing no" ;;
21861 *) gl_cv_func_getdtablesize_works
="guessing yes" ;;
21865 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
21866 /* end confdefs.h. */
21868 #include <unistd.h>
21877 int size = getdtablesize();
21878 if (dup2 (0, getdtablesize()) != -1)
21880 if (size != getdtablesize())
21887 if ac_fn_c_try_run
"$LINENO"; then :
21888 gl_cv_func_getdtablesize_works
=yes
21890 gl_cv_func_getdtablesize_works
=no
21892 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
21893 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
21900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getdtablesize_works" >&5
21901 $as_echo "$gl_cv_func_getdtablesize_works" >&6; }
21902 case "$gl_cv_func_getdtablesize_works" in
21903 *yes |
"no (limitation)") ;;
21904 *) REPLACE_GETDTABLESIZE
=1 ;;
21907 HAVE_GETDTABLESIZE
=0
21910 if test $HAVE_GETDTABLESIZE = 0 ||
test $REPLACE_GETDTABLESIZE = 1; then
21919 gl_LIBOBJS
="$gl_LIBOBJS getdtablesize.$ac_objext"
21928 GNULIB_GETDTABLESIZE
=1
21934 $as_echo "#define GNULIB_TEST_GETDTABLESIZE 1" >>confdefs.h
21945 gl_getline_needs_run_time_check
=no
21946 ac_fn_c_check_func
"$LINENO" "getline" "ac_cv_func_getline"
21947 if test "x$ac_cv_func_getline" = xyes
; then :
21948 gl_getline_needs_run_time_check
=yes
21950 am_cv_func_working_getline
=no
21953 if test $gl_getline_needs_run_time_check = yes; then
21954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getline function" >&5
21955 $as_echo_n "checking for working getline function... " >&6; }
21956 if ${am_cv_func_working_getline+:} false
; then :
21957 $as_echo_n "(cached) " >&6
21959 echo fooNbarN |
tr -d '\012' |
tr N
'\012' > conftest.data
21960 if test "$cross_compiling" = yes; then :
21961 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
21962 /* end confdefs.h. */
21964 #include <features.h>
21965 #ifdef __GNU_LIBRARY__
21966 #if (__GLIBC__ >= 2) && !defined __UCLIBC__
21972 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
21973 $EGREP "Lucky GNU user" >/dev
/null
2>&1; then :
21974 am_cv_func_working_getline
="guessing yes"
21977 *-musl*) am_cv_func_working_getline
="guessing yes" ;;
21978 *) am_cv_func_working_getline
="$gl_cross_guess_normal" ;;
21986 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
21987 /* end confdefs.h. */
21989 # include <stdio.h>
21990 # include <stdlib.h>
21991 # include <string.h>
21994 FILE *in = fopen ("./conftest.data", "r");
21998 /* Test result for a NULL buffer and a zero size.
21999 Based on a test program from Karl Heuer. */
22002 int len = getline (&line, &siz, in);
22003 if (!(len == 4 && line && strcmp (line, "foo\n") == 0))
22004 { free (line); fclose (in); return 2; }
22008 /* Test result for a NULL buffer and a non-zero size.
22009 This crashes on FreeBSD 8.0. */
22011 size_t siz = (size_t)(~0) / 4;
22012 if (getline (&line, &siz, in) == -1)
22013 { fclose (in); return 3; }
22021 if ac_fn_c_try_run
"$LINENO"; then :
22022 am_cv_func_working_getline
=yes
22024 am_cv_func_working_getline
=no
22026 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
22027 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
22032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_working_getline" >&5
22033 $as_echo "$am_cv_func_working_getline" >&6; }
22036 if test $ac_cv_have_decl_getline = no
; then
22037 HAVE_DECL_GETLINE
=0
22040 case "$am_cv_func_working_getline" in
22047 if test $REPLACE_GETLINE = 1; then
22056 gl_LIBOBJS
="$gl_LIBOBJS getline.$ac_objext"
22073 $as_echo "#define GNULIB_TEST_GETLINE 1" >>confdefs.h
22083 if test $ac_cv_have_decl_getlogin_r = no
; then
22084 HAVE_DECL_GETLOGIN_R
=0
22088 if test $ac_cv_func_getlogin_r = no
; then
22093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getlogin_r works with small buffers" >&5
22094 $as_echo_n "checking whether getlogin_r works with small buffers... " >&6; }
22095 if ${gl_cv_func_getlogin_r_works+:} false
; then :
22096 $as_echo_n "(cached) " >&6
22100 # Guess no on Mac OS X, OSF/1.
22101 darwin
* | osf
*) gl_cv_func_getlogin_r_works
="guessing no" ;;
22102 # Guess yes otherwise.
22103 *) gl_cv_func_getlogin_r_works
="guessing yes" ;;
22105 if test "$cross_compiling" = yes; then :
22108 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
22109 /* end confdefs.h. */
22111 #include <stddef.h>
22112 #include <string.h>
22113 #include <unistd.h>
22114 #if !HAVE_DECL_GETLOGIN_R
22116 # ifdef __cplusplus
22119 int getlogin_r (char *, size_t);
22127 if (getlogin_r (buf, 0) == 0)
22129 if (getlogin_r (buf, 1) == 0)
22131 if (getlogin_r (buf, 100) == 0)
22133 size_t n = strlen (buf);
22134 if (getlogin_r (buf, n) == 0)
22140 if ac_fn_c_try_run
"$LINENO"; then :
22141 gl_cv_func_getlogin_r_works
=yes
22143 gl_cv_func_getlogin_r_works
=no
22145 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
22146 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
22151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getlogin_r_works" >&5
22152 $as_echo "$gl_cv_func_getlogin_r_works" >&6; }
22153 case "$gl_cv_func_getlogin_r_works" in
22155 *) REPLACE_GETLOGIN_R
=1 ;;
22159 if test $HAVE_GETLOGIN_R = 0 ||
test $REPLACE_GETLOGIN_R = 1; then
22168 gl_LIBOBJS
="$gl_LIBOBJS getlogin_r.$ac_objext"
22179 GNULIB_GETLOGIN_R
=1
22185 $as_echo "#define GNULIB_TEST_GETLOGIN_R 1" >>confdefs.h
22194 ac_fn_c_check_decl
"$LINENO" "program_invocation_name" "ac_cv_have_decl_program_invocation_name" "#include <errno.h>
22196 if test "x$ac_cv_have_decl_program_invocation_name" = xyes
; then :
22202 cat >>confdefs.h
<<_ACEOF
22203 #define HAVE_DECL_PROGRAM_INVOCATION_NAME $ac_have_decl
22205 if test $ac_have_decl = 1; then :
22209 ac_fn_c_check_decl
"$LINENO" "program_invocation_short_name" "ac_cv_have_decl_program_invocation_short_name" "#include <errno.h>
22211 if test "x$ac_cv_have_decl_program_invocation_short_name" = xyes
; then :
22217 cat >>confdefs.h
<<_ACEOF
22218 #define HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME $ac_have_decl
22220 if test $ac_have_decl = 1; then :
22224 ac_fn_c_check_decl
"$LINENO" "__argv" "ac_cv_have_decl___argv" "#include <stdlib.h>
22226 if test "x$ac_cv_have_decl___argv" = xyes
; then :
22232 cat >>confdefs.h
<<_ACEOF
22233 #define HAVE_DECL___ARGV $ac_have_decl
22235 if test $ac_have_decl = 1; then :
22240 # Incur the cost of this test only if none of the above worked.
22241 if test $ac_found = 0; then
22242 # On OpenBSD 5.1, using the global __progname variable appears to be
22243 # the only way to implement getprogname.
22244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __progname is defined in default libraries" >&5
22245 $as_echo_n "checking whether __progname is defined in default libraries... " >&6; }
22246 if ${gl_cv_var___progname+:} false
; then :
22247 $as_echo_n "(cached) " >&6
22250 gl_cv_var___progname
=
22251 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
22252 /* end confdefs.h. */
22253 extern char *__progname;
22257 return *__progname;
22263 if ac_fn_c_try_link
"$LINENO"; then :
22264 gl_cv_var___progname
=yes
22267 rm -f core conftest.err conftest.
$ac_objext \
22268 conftest
$ac_exeext conftest.
$ac_ext
22272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_var___progname" >&5
22273 $as_echo "$gl_cv_var___progname" >&6; }
22274 if test "$gl_cv_var___progname" = yes; then
22276 $as_echo "#define HAVE_VAR___PROGNAME 1" >>confdefs.h
22285 if test "$ac_cv_func_getrandom" != yes; then
22288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getrandom is compatible with its GNU+BSD signature" >&5
22289 $as_echo_n "checking whether getrandom is compatible with its GNU+BSD signature... " >&6; }
22290 if ${gl_cv_func_getrandom_ok+:} false
; then :
22291 $as_echo_n "(cached) " >&6
22293 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
22294 /* end confdefs.h. */
22295 /* Additional includes are needed before <sys/random.h> on uClibc
22297 #include <sys/types.h>
22298 #include <stdlib.h>
22299 #include <sys/random.h>
22300 ssize_t getrandom (void *, size_t, unsigned int);
22311 if ac_fn_c_try_compile
"$LINENO"; then :
22312 gl_cv_func_getrandom_ok
=yes
22314 gl_cv_func_getrandom_ok
=no
22316 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
22319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getrandom_ok" >&5
22320 $as_echo "$gl_cv_func_getrandom_ok" >&6; }
22321 if test $gl_cv_func_getrandom_ok = no
; then
22322 REPLACE_GETRANDOM
=1
22328 for ac_header
in bcrypt.h
22330 ac_fn_c_check_header_compile
"$LINENO" "bcrypt.h" "ac_cv_header_bcrypt_h" "#include <windows.h>
22333 if test "x$ac_cv_header_bcrypt_h" = xyes
; then :
22334 cat >>confdefs.h
<<_ACEOF
22335 #define HAVE_BCRYPT_H 1
22342 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the bcrypt library is guaranteed to be present" >&5
22343 $as_echo_n "checking whether the bcrypt library is guaranteed to be present... " >&6; }
22344 if ${gl_cv_lib_assume_bcrypt+:} false
; then :
22345 $as_echo_n "(cached) " >&6
22347 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
22348 /* end confdefs.h. */
22349 #include <windows.h>
22353 #if !(_WIN32_WINNT >= _WIN32_WINNT_WIN7)
22362 if ac_fn_c_try_compile
"$LINENO"; then :
22363 gl_cv_lib_assume_bcrypt
=yes
22365 gl_cv_lib_assume_bcrypt
=no
22367 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
22370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_lib_assume_bcrypt" >&5
22371 $as_echo "$gl_cv_lib_assume_bcrypt" >&6; }
22372 if test $gl_cv_lib_assume_bcrypt = yes; then
22374 $as_echo "#define HAVE_LIB_BCRYPT 1" >>confdefs.h
22376 LIB_GETRANDOM
='-lbcrypt'
22378 LIB_GETRANDOM
='-ladvapi32'
22386 if test $HAVE_GETRANDOM = 0 ||
test $REPLACE_GETRANDOM = 1; then
22395 gl_LIBOBJS
="$gl_LIBOBJS getrandom.$ac_objext"
22409 $as_echo "#define GNULIB_TEST_GETRANDOM 1" >>confdefs.h
22422 gl_gettimeofday_timezone
=void
22423 if test $ac_cv_func_gettimeofday != yes; then
22424 HAVE_GETTIMEOFDAY
=0
22426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
22427 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
22428 if ${gl_cv_func_gettimeofday_posix_signature+:} false
; then :
22429 $as_echo_n "(cached) " >&6
22431 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
22432 /* end confdefs.h. */
22433 #include <sys/time.h>
22435 int gettimeofday (struct timeval *restrict, void *restrict);
22440 /* glibc uses struct timezone * rather than the POSIX void *
22441 if _GNU_SOURCE is defined. However, since the only portable
22442 use of gettimeofday uses NULL as the second parameter, and
22443 since the glibc definition is actually more typesafe, it is
22444 not worth wrapping this to get a compliant signature. */
22445 int (*f) (struct timeval *restrict, void *restrict)
22448 return !(x | c.tv_sec | c.tv_usec);
22454 if ac_fn_c_try_compile
"$LINENO"; then :
22455 gl_cv_func_gettimeofday_posix_signature
=yes
22457 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
22458 /* end confdefs.h. */
22459 #include <sys/time.h>
22460 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
22470 if ac_fn_c_try_compile
"$LINENO"; then :
22471 gl_cv_func_gettimeofday_posix_signature
=almost
22473 gl_cv_func_gettimeofday_posix_signature
=no
22475 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
22477 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
22479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
22480 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
22481 if test $gl_cv_func_gettimeofday_posix_signature = almost
; then
22482 gl_gettimeofday_timezone
='struct timezone'
22483 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
22484 REPLACE_GETTIMEOFDAY
=1
22486 if test $REPLACE_STRUCT_TIMEVAL = 1; then
22487 REPLACE_GETTIMEOFDAY
=1
22490 mingw
*) REPLACE_GETTIMEOFDAY
=1 ;;
22494 cat >>confdefs.h
<<_ACEOF
22495 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
22499 if test $HAVE_GETTIMEOFDAY = 0 ||
test $REPLACE_GETTIMEOFDAY = 1; then
22508 gl_LIBOBJS
="$gl_LIBOBJS gettimeofday.$ac_objext"
22517 GNULIB_GETTIMEOFDAY
=1
22523 $as_echo "#define GNULIB_TEST_GETTIMEOFDAY 1" >>confdefs.h
22531 if test $ac_cv_func_glob = no
; then
22535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU glob interface version 1 or 2" >&5
22536 $as_echo_n "checking for GNU glob interface version 1 or 2... " >&6; }
22537 if ${gl_cv_gnu_glob_interface_version_1_2+:} false
; then :
22538 $as_echo_n "(cached) " >&6
22540 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
22541 /* end confdefs.h. */
22542 #include <gnu-versions.h>
22543 char a[_GNU_GLOB_INTERFACE_VERSION == 1 || _GNU_GLOB_INTERFACE_VERSION == 2 ? 1 : -1];
22545 if ac_fn_c_try_compile
"$LINENO"; then :
22546 gl_cv_gnu_glob_interface_version_1_2
=yes
22548 gl_cv_gnu_glob_interface_version_1_2
=no
22550 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
22552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_gnu_glob_interface_version_1_2" >&5
22553 $as_echo "$gl_cv_gnu_glob_interface_version_1_2" >&6; }
22554 if test "$gl_cv_gnu_glob_interface_version_1_2" = "no"; then
22558 if test $REPLACE_GLOB = 0; then
22559 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether glob lists broken symlinks" >&5
22560 $as_echo_n "checking whether glob lists broken symlinks... " >&6; }
22561 if ${gl_cv_glob_lists_symlinks+:} false
; then :
22562 $as_echo_n "(cached) " >&6
22564 if test $cross_compiling != yes; then
22565 if ln -s conf-doesntexist conf$$
-globtest 2>/dev
/null
; then
22566 gl_cv_glob_lists_symlinks
=maybe
22568 # If we can't make a symlink, then we cannot test this issue. Be
22569 # pessimistic about this.
22570 gl_cv_glob_lists_symlinks
=no
22572 if test $gl_cv_glob_lists_symlinks = maybe
; then
22573 if test "$cross_compiling" = yes; then :
22577 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
22578 /* end confdefs.h. */
22579 #include <stddef.h>
22585 if (glob ("conf*-globtest", 0, NULL, &found) == GLOB_NOMATCH)
22593 if ac_fn_c_try_run
"$LINENO"; then :
22594 gl_cv_glob_lists_symlinks
=yes
22596 gl_cv_glob_lists_symlinks
=no
22598 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
22599 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
22603 rm -f conf$$
-globtest
22605 gl_cv_glob_lists_symlinks
="$gl_cross_guess_normal"
22609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_glob_lists_symlinks" >&5
22610 $as_echo "$gl_cv_glob_lists_symlinks" >&6; }
22611 case "$gl_cv_glob_lists_symlinks" in
22613 *) REPLACE_GLOB
=1 ;;
22619 if test $ac_cv_func_glob_pattern_p = no
; then
22620 HAVE_GLOB_PATTERN_P
=0
22622 if test $REPLACE_GLOB = 1; then
22623 REPLACE_GLOB_PATTERN_P
=1
22627 if test $HAVE_GLOB = 0 ||
test $REPLACE_GLOB = 1; then
22631 if test -n "$GLOB_H"; then
22632 GL_GENERATE_GLOB_H_TRUE
=
22633 GL_GENERATE_GLOB_H_FALSE
='#'
22635 GL_GENERATE_GLOB_H_TRUE
='#'
22636 GL_GENERATE_GLOB_H_FALSE
=
22642 if test $HAVE_GLOB = 0 ||
test $REPLACE_GLOB = 1; then
22651 gl_LIBOBJS
="$gl_LIBOBJS glob.$ac_objext"
22661 gl_LIBOBJS
="$gl_LIBOBJS globfree.$ac_objext"
22669 if test $HAVE_GLOB_PATTERN_P = 0 ||
test $REPLACE_GLOB_PATTERN_P = 1; then
22678 gl_LIBOBJS
="$gl_LIBOBJS glob_pattern_p.$ac_objext"
22692 $as_echo "#define GNULIB_TEST_GLOB 1" >>confdefs.h
22698 LIB_HARD_LOCALE
="$LIB_SETLOCALE_NULL"
22713 if test $ac_cv_header_sys_socket_h != yes; then
22714 for ac_header
in winsock2.h
22716 ac_fn_c_check_header_mongrel
"$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
22717 if test "x$ac_cv_header_winsock2_h" = xyes
; then :
22718 cat >>confdefs.h
<<_ACEOF
22719 #define HAVE_WINSOCK2_H 1
22727 if test "$ac_cv_header_winsock2_h" = yes; then
22729 UNISTD_H_HAVE_WINSOCK2_H
=1
22730 SYS_IOCTL_H_HAVE_WINSOCK2_H
=1
22736 if test $HAVE_WINSOCK2_H = 1; then
22737 REPLACE_INET_NTOP
=1
22738 ac_fn_c_check_decl
"$LINENO" "inet_ntop" "ac_cv_have_decl_inet_ntop" "#include <ws2tcpip.h>
22740 if test "x$ac_cv_have_decl_inet_ntop" = xyes
; then :
22746 cat >>confdefs.h
<<_ACEOF
22747 #define HAVE_DECL_INET_NTOP $ac_have_decl
22750 if test $ac_cv_have_decl_inet_ntop = yes; then
22751 INET_NTOP_LIB
="-lws2_32"
22753 HAVE_DECL_INET_NTOP
=0
22757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_ntop" >&5
22758 $as_echo_n "checking for library containing inet_ntop... " >&6; }
22759 if ${ac_cv_search_inet_ntop+:} false
; then :
22760 $as_echo_n "(cached) " >&6
22762 ac_func_search_save_LIBS
=$LIBS
22763 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
22764 /* end confdefs.h. */
22766 /* Override any GCC internal prototype to avoid an error.
22767 Use char because int might match the return type of a GCC
22768 builtin and then its argument prototype would still apply. */
22776 return inet_ntop ();
22781 for ac_lib
in '' nsl resolv network
; do
22782 if test -z "$ac_lib"; then
22783 ac_res
="none required"
22786 LIBS
="-l$ac_lib $ac_func_search_save_LIBS"
22788 if ac_fn_c_try_link
"$LINENO"; then :
22789 ac_cv_search_inet_ntop
=$ac_res
22791 rm -f core conftest.err conftest.
$ac_objext \
22793 if ${ac_cv_search_inet_ntop+:} false
; then :
22797 if ${ac_cv_search_inet_ntop+:} false
; then :
22800 ac_cv_search_inet_ntop
=no
22802 rm conftest.
$ac_ext
22803 LIBS
=$ac_func_search_save_LIBS
22805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_ntop" >&5
22806 $as_echo "$ac_cv_search_inet_ntop" >&6; }
22807 ac_res
=$ac_cv_search_inet_ntop
22808 if test "$ac_res" != no
; then :
22809 test "$ac_res" = "none required" || LIBS
="$ac_res $LIBS"
22812 for ac_func
in inet_ntop
22814 ac_fn_c_check_func
"$LINENO" "inet_ntop" "ac_cv_func_inet_ntop"
22815 if test "x$ac_cv_func_inet_ntop" = xyes
; then :
22816 cat >>confdefs.h
<<_ACEOF
22817 #define HAVE_INET_NTOP 1
22823 if test $ac_cv_func_inet_ntop = no
; then
22831 if test "$ac_cv_search_inet_ntop" != "no" \
22832 && test "$ac_cv_search_inet_ntop" != "none required"; then
22833 INET_NTOP_LIB
="$ac_cv_search_inet_ntop"
22837 ac_fn_c_check_decl
"$LINENO" "inet_ntop" "ac_cv_have_decl_inet_ntop" "#include <arpa/inet.h>
22839 # include <netdb.h>
22843 if test "x$ac_cv_have_decl_inet_ntop" = xyes
; then :
22849 cat >>confdefs.h
<<_ACEOF
22850 #define HAVE_DECL_INET_NTOP $ac_have_decl
22853 if test $ac_cv_have_decl_inet_ntop = no
; then
22854 HAVE_DECL_INET_NTOP
=0
22859 if test $HAVE_INET_NTOP = 0 ||
test $REPLACE_INET_NTOP = 1; then
22868 gl_LIBOBJS
="$gl_LIBOBJS inet_ntop.$ac_objext"
22888 if test -n "$STDINT_H"; then
22889 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
22890 /* end confdefs.h. */
22905 if ac_fn_c_try_compile
"$LINENO"; then :
22906 PRIPTR_PREFIX
='"l"'
22908 PRIPTR_PREFIX
='"ll"'
22910 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
22912 for glpfx
in '' l ll I64
; do
22914 '') gltype1
='int';;
22915 l
) gltype1
='long int';;
22916 ll
) gltype1
='long long int';;
22917 I64
) gltype1
='__int64';;
22919 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
22920 /* end confdefs.h. */
22921 #include <stdint.h>
22922 extern intptr_t foo;
22923 extern $gltype1 foo;
22932 if ac_fn_c_try_compile
"$LINENO"; then :
22933 PRIPTR_PREFIX
='"'$glpfx'"'
22935 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
22936 test -n "$PRIPTR_PREFIX" && break
22942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether INT32_MAX < INTMAX_MAX" >&5
22943 $as_echo_n "checking whether INT32_MAX < INTMAX_MAX... " >&6; }
22944 if ${gl_cv_test_INT32_MAX_LT_INTMAX_MAX+:} false
; then :
22945 $as_echo_n "(cached) " >&6
22947 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
22948 /* end confdefs.h. */
22949 /* Work also in C++ mode. */
22950 #define __STDC_LIMIT_MACROS 1
22952 /* Work if build is not clean. */
22953 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
22955 #include <limits.h>
22957 #include <stdint.h>
22960 #if defined INT32_MAX && defined INTMAX_MAX
22961 #define CONDITION (INT32_MAX < INTMAX_MAX)
22963 #define CONDITION (sizeof (int) < sizeof (long long int))
22965 int test[CONDITION ? 1 : -1];
22974 if ac_fn_c_try_compile
"$LINENO"; then :
22975 gl_cv_test_INT32_MAX_LT_INTMAX_MAX
=yes
22977 gl_cv_test_INT32_MAX_LT_INTMAX_MAX
=no
22979 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
22981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_INT32_MAX_LT_INTMAX_MAX" >&5
22982 $as_echo "$gl_cv_test_INT32_MAX_LT_INTMAX_MAX" >&6; }
22983 if test $gl_cv_test_INT32_MAX_LT_INTMAX_MAX = yes; then
22984 INT32_MAX_LT_INTMAX_MAX
=1;
22986 INT32_MAX_LT_INTMAX_MAX
=0;
22990 if test $APPLE_UNIVERSAL_BUILD = 0; then
22992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether INT64_MAX == LONG_MAX" >&5
22993 $as_echo_n "checking whether INT64_MAX == LONG_MAX... " >&6; }
22994 if ${gl_cv_test_INT64_MAX_EQ_LONG_MAX+:} false
; then :
22995 $as_echo_n "(cached) " >&6
22997 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
22998 /* end confdefs.h. */
22999 /* Work also in C++ mode. */
23000 #define __STDC_LIMIT_MACROS 1
23002 /* Work if build is not clean. */
23003 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
23005 #include <limits.h>
23007 #include <stdint.h>
23010 #if defined INT64_MAX
23011 #define CONDITION (INT64_MAX == LONG_MAX)
23013 #define CONDITION (sizeof (long long int) == sizeof (long int))
23015 int test[CONDITION ? 1 : -1];
23024 if ac_fn_c_try_compile
"$LINENO"; then :
23025 gl_cv_test_INT64_MAX_EQ_LONG_MAX
=yes
23027 gl_cv_test_INT64_MAX_EQ_LONG_MAX
=no
23029 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
23031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_INT64_MAX_EQ_LONG_MAX" >&5
23032 $as_echo "$gl_cv_test_INT64_MAX_EQ_LONG_MAX" >&6; }
23033 if test $gl_cv_test_INT64_MAX_EQ_LONG_MAX = yes; then
23034 INT64_MAX_EQ_LONG_MAX
=1;
23036 INT64_MAX_EQ_LONG_MAX
=0;
23041 INT64_MAX_EQ_LONG_MAX
=-1
23044 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether UINT32_MAX < UINTMAX_MAX" >&5
23045 $as_echo_n "checking whether UINT32_MAX < UINTMAX_MAX... " >&6; }
23046 if ${gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX+:} false
; then :
23047 $as_echo_n "(cached) " >&6
23049 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
23050 /* end confdefs.h. */
23051 /* Work also in C++ mode. */
23052 #define __STDC_LIMIT_MACROS 1
23054 /* Work if build is not clean. */
23055 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
23057 #include <limits.h>
23059 #include <stdint.h>
23062 #if defined UINT32_MAX && defined UINTMAX_MAX
23063 #define CONDITION (UINT32_MAX < UINTMAX_MAX)
23065 #define CONDITION (sizeof (unsigned int) < sizeof (unsigned long long int))
23067 int test[CONDITION ? 1 : -1];
23076 if ac_fn_c_try_compile
"$LINENO"; then :
23077 gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX
=yes
23079 gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX
=no
23081 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
23083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX" >&5
23084 $as_echo "$gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX" >&6; }
23085 if test $gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX = yes; then
23086 UINT32_MAX_LT_UINTMAX_MAX
=1;
23088 UINT32_MAX_LT_UINTMAX_MAX
=0;
23092 if test $APPLE_UNIVERSAL_BUILD = 0; then
23094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether UINT64_MAX == ULONG_MAX" >&5
23095 $as_echo_n "checking whether UINT64_MAX == ULONG_MAX... " >&6; }
23096 if ${gl_cv_test_UINT64_MAX_EQ_ULONG_MAX+:} false
; then :
23097 $as_echo_n "(cached) " >&6
23099 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
23100 /* end confdefs.h. */
23101 /* Work also in C++ mode. */
23102 #define __STDC_LIMIT_MACROS 1
23104 /* Work if build is not clean. */
23105 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
23107 #include <limits.h>
23109 #include <stdint.h>
23112 #if defined UINT64_MAX
23113 #define CONDITION (UINT64_MAX == ULONG_MAX)
23115 #define CONDITION (sizeof (unsigned long long int) == sizeof (unsigned long int))
23117 int test[CONDITION ? 1 : -1];
23126 if ac_fn_c_try_compile
"$LINENO"; then :
23127 gl_cv_test_UINT64_MAX_EQ_ULONG_MAX
=yes
23129 gl_cv_test_UINT64_MAX_EQ_ULONG_MAX
=no
23131 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
23133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_UINT64_MAX_EQ_ULONG_MAX" >&5
23134 $as_echo "$gl_cv_test_UINT64_MAX_EQ_ULONG_MAX" >&6; }
23135 if test $gl_cv_test_UINT64_MAX_EQ_ULONG_MAX = yes; then
23136 UINT64_MAX_EQ_ULONG_MAX
=1;
23138 UINT64_MAX_EQ_ULONG_MAX
=0;
23143 UINT64_MAX_EQ_ULONG_MAX
=-1
23153 if test $ac_cv_func_isblank = no
; then
23157 if test $HAVE_ISBLANK = 0; then
23166 gl_LIBOBJS
="$gl_LIBOBJS isblank.$ac_objext"
23171 cat >>confdefs.h
<<_ACEOF
23172 #define GNULIB_ISBLANK 1
23188 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnan(double) can be used without linking with libm" >&5
23189 $as_echo_n "checking whether isnan(double) can be used without linking with libm... " >&6; }
23190 if ${gl_cv_func_isnand_no_libm+:} false
; then :
23191 $as_echo_n "(cached) " >&6
23194 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
23195 /* end confdefs.h. */
23197 #if (__GNUC__ >= 4) || (__clang_major__ >= 4)
23199 # define isnand(x) __builtin_isnan ((double)(x))
23202 # define isnand(x) isnan ((double)(x))
23213 if ac_fn_c_try_link
"$LINENO"; then :
23214 gl_cv_func_isnand_no_libm
=yes
23216 gl_cv_func_isnand_no_libm
=no
23218 rm -f core conftest.err conftest.
$ac_objext \
23219 conftest
$ac_exeext conftest.
$ac_ext
23222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnand_no_libm" >&5
23223 $as_echo "$gl_cv_func_isnand_no_libm" >&6; }
23225 gl_func_isnand_no_libm
=$gl_cv_func_isnand_no_libm
23226 if test $gl_cv_func_isnand_no_libm = yes; then
23228 $as_echo "#define HAVE_ISNAND_IN_LIBC 1" >>confdefs.h
23232 if test $gl_func_isnand_no_libm != yes; then
23241 gl_LIBOBJS
="$gl_LIBOBJS isnand.$ac_objext"
23249 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnan(long double) can be used without linking with libm" >&5
23250 $as_echo_n "checking whether isnan(long double) can be used without linking with libm... " >&6; }
23251 if ${gl_cv_func_isnanl_no_libm+:} false
; then :
23252 $as_echo_n "(cached) " >&6
23255 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
23256 /* end confdefs.h. */
23258 #if (__GNUC__ >= 4) || (__clang_major__ >= 4)
23260 # define isnanl(x) __builtin_isnan ((long double)(x))
23261 #elif defined isnan
23263 # define isnanl(x) isnan ((long double)(x))
23274 if ac_fn_c_try_link
"$LINENO"; then :
23275 gl_cv_func_isnanl_no_libm
=yes
23277 gl_cv_func_isnanl_no_libm
=no
23279 rm -f core conftest.err conftest.
$ac_objext \
23280 conftest
$ac_exeext conftest.
$ac_ext
23283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnanl_no_libm" >&5
23284 $as_echo "$gl_cv_func_isnanl_no_libm" >&6; }
23286 gl_func_isnanl_no_libm
=$gl_cv_func_isnanl_no_libm
23287 if test $gl_func_isnanl_no_libm = yes; then
23292 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnanl works" >&5
23293 $as_echo_n "checking whether isnanl works... " >&6; }
23294 if ${gl_cv_func_isnanl_works+:} false
; then :
23295 $as_echo_n "(cached) " >&6
23298 if test "$cross_compiling" = yes; then :
23300 mingw
*) # Guess yes on mingw, no on MSVC.
23301 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
23302 /* end confdefs.h. */
23309 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23310 $EGREP "Known" >/dev
/null
2>&1; then :
23311 gl_cv_func_isnanl_works
="guessing yes"
23313 gl_cv_func_isnanl_works
="guessing no"
23318 *) gl_cv_func_isnanl_works
="guessing yes" ;;
23322 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
23323 /* end confdefs.h. */
23326 #include <limits.h>
23328 #if (__GNUC__ >= 4) || (__clang_major__ >= 4)
23330 # define isnanl(x) __builtin_isnan ((long double)(x))
23331 #elif defined isnan
23333 # define isnanl(x) isnan ((long double)(x))
23336 ((sizeof (long double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
23337 typedef union { unsigned int word[NWORDS]; long double value; }
23338 memory_long_double;
23339 /* On Irix 6.5, gcc 3.4.3 can't compute compile-time NaN, and needs the
23340 runtime type conversion. */
23342 static long double NaNl ()
23345 return zero / zero;
23348 # define NaNl() (0.0L / 0.0L)
23354 if (!isnanl (NaNl ()))
23358 memory_long_double m;
23361 /* The isnanl function should be immune against changes in the sign bit and
23362 in the mantissa bits. The xor operation twiddles a bit that can only be
23363 a sign bit or a mantissa bit (since the exponent never extends to
23366 m.word[NWORDS / 2] ^= (unsigned int) 1 << (sizeof (unsigned int) * CHAR_BIT - 1);
23367 for (i = 0; i < NWORDS; i++)
23369 if (!isnanl (m.value))
23373 #if ((defined __ia64 && LDBL_MANT_DIG == 64) || (defined __x86_64__ || defined __amd64__) || (defined __i386 || defined __i386__ || defined _I386 || defined _M_IX86 || defined _X86_)) && !HAVE_SAME_LONG_DOUBLE_AS_DOUBLE
23374 /* Representation of an 80-bit 'long double' as an initializer for a sequence
23375 of 'unsigned int' words. */
23376 # ifdef WORDS_BIGENDIAN
23377 # define LDBL80_WORDS(exponent,manthi,mantlo) \
23378 { ((unsigned int) (exponent) << 16) | ((unsigned int) (manthi) >> 16), \
23379 ((unsigned int) (manthi) << 16) | ((unsigned int) (mantlo) >> 16), \
23380 (unsigned int) (mantlo) << 16 \
23383 # define LDBL80_WORDS(exponent,manthi,mantlo) \
23384 { mantlo, manthi, exponent }
23387 static memory_long_double x =
23388 { LDBL80_WORDS (0xFFFF, 0xC3333333, 0x00000000) };
23389 if (!isnanl (x.value))
23393 /* Signalling NaN. */
23394 static memory_long_double x =
23395 { LDBL80_WORDS (0xFFFF, 0x83333333, 0x00000000) };
23396 if (!isnanl (x.value))
23399 /* isnanl should return something even for noncanonical values. */
23400 { /* Pseudo-NaN. */
23401 static memory_long_double x =
23402 { LDBL80_WORDS (0xFFFF, 0x40000001, 0x00000000) };
23403 if (isnanl (x.value) && !isnanl (x.value))
23406 { /* Pseudo-Infinity. */
23407 static memory_long_double x =
23408 { LDBL80_WORDS (0xFFFF, 0x00000000, 0x00000000) };
23409 if (isnanl (x.value) && !isnanl (x.value))
23412 { /* Pseudo-Zero. */
23413 static memory_long_double x =
23414 { LDBL80_WORDS (0x4004, 0x00000000, 0x00000000) };
23415 if (isnanl (x.value) && !isnanl (x.value))
23418 { /* Unnormalized number. */
23419 static memory_long_double x =
23420 { LDBL80_WORDS (0x4000, 0x63333333, 0x00000000) };
23421 if (isnanl (x.value) && !isnanl (x.value))
23424 { /* Pseudo-Denormal. */
23425 static memory_long_double x =
23426 { LDBL80_WORDS (0x0000, 0x83333333, 0x00000000) };
23427 if (isnanl (x.value) && !isnanl (x.value))
23435 if ac_fn_c_try_run
"$LINENO"; then :
23436 gl_cv_func_isnanl_works
=yes
23438 gl_cv_func_isnanl_works
=no
23440 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
23441 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
23446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnanl_works" >&5
23447 $as_echo "$gl_cv_func_isnanl_works" >&6; }
23449 case "$gl_cv_func_isnanl_works" in
23451 *) gl_func_isnanl_no_libm
=no
;;
23454 if test $gl_func_isnanl_no_libm = yes; then
23456 $as_echo "#define HAVE_ISNANL_IN_LIBC 1" >>confdefs.h
23460 if test $gl_func_isnanl_no_libm != yes; then
23469 gl_LIBOBJS
="$gl_LIBOBJS isnanl.$ac_objext"
23474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'long double'" >&5
23475 $as_echo_n "checking where to find the exponent in a 'long double'... " >&6; }
23476 if ${gl_cv_cc_long_double_expbit0+:} false
; then :
23477 $as_echo_n "(cached) " >&6
23480 if test "$cross_compiling" = yes; then :
23482 gl_cv_cc_long_double_expbit0
="unknown"
23484 mingw
*) # On native Windows (little-endian), we know the result
23485 # in two cases: mingw, MSVC.
23486 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
23487 /* end confdefs.h. */
23494 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23495 $EGREP "Known" >/dev
/null
2>&1; then :
23496 gl_cv_cc_long_double_expbit0
="word 2 bit 0"
23500 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
23501 /* end confdefs.h. */
23508 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23509 $EGREP "Known" >/dev
/null
2>&1; then :
23510 gl_cv_cc_long_double_expbit0
="word 1 bit 20"
23518 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
23519 /* end confdefs.h. */
23522 #include <stddef.h>
23524 #include <string.h>
23526 ((sizeof (long double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
23527 typedef union { long double value; unsigned int word[NWORDS]; }
23528 memory_long_double;
23529 static unsigned int ored_words[NWORDS];
23530 static unsigned int anded_words[NWORDS];
23531 static void add_to_ored_words (long double *x)
23533 memory_long_double m;
23535 /* Clear it first, in case
23536 sizeof (long double) < sizeof (memory_long_double). */
23537 memset (&m, 0, sizeof (memory_long_double));
23539 for (i = 0; i < NWORDS; i++)
23541 ored_words[i] |= m.word[i];
23542 anded_words[i] &= m.word[i];
23547 static long double samples[5] = { 0.25L, 0.5L, 1.0L, 2.0L, 4.0L };
23549 FILE *fp = fopen ("conftest.out", "w");
23552 for (j = 0; j < NWORDS; j++)
23553 anded_words[j] = ~ (unsigned int) 0;
23554 for (j = 0; j < 5; j++)
23555 add_to_ored_words (&samples[j]);
23556 /* Remove bits that are common (e.g. if representation of the first mantissa
23557 bit is explicit). */
23558 for (j = 0; j < NWORDS; j++)
23559 ored_words[j] &= ~anded_words[j];
23560 /* Now find the nonzero word. */
23561 for (j = 0; j < NWORDS; j++)
23562 if (ored_words[j] != 0)
23567 for (i = j + 1; i < NWORDS; i++)
23568 if (ored_words[i] != 0)
23570 fprintf (fp, "unknown");
23571 return (fclose (fp) != 0);
23574 if ((ored_words[j] >> i) & 1)
23576 fprintf (fp, "word %d bit %d", (int) j, (int) i);
23577 return (fclose (fp) != 0);
23580 fprintf (fp, "unknown");
23581 return (fclose (fp) != 0);
23585 if ac_fn_c_try_run
"$LINENO"; then :
23586 gl_cv_cc_long_double_expbit0
=`cat conftest.out`
23588 gl_cv_cc_long_double_expbit0
="unknown"
23590 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
23591 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
23597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_long_double_expbit0" >&5
23598 $as_echo "$gl_cv_cc_long_double_expbit0" >&6; }
23599 case "$gl_cv_cc_long_double_expbit0" in
23601 word
=`echo "$gl_cv_cc_long_double_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
23602 bit
=`echo "$gl_cv_cc_long_double_expbit0" | sed -e 's/word.*bit //'`
23604 cat >>confdefs.h
<<_ACEOF
23605 #define LDBL_EXPBIT0_WORD $word
23609 cat >>confdefs.h
<<_ACEOF
23610 #define LDBL_EXPBIT0_BIT $bit
23621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports the __inline keyword" >&5
23622 $as_echo_n "checking whether the compiler supports the __inline keyword... " >&6; }
23623 if ${gl_cv_c___inline+:} false
; then :
23624 $as_echo_n "(cached) " >&6
23626 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
23627 /* end confdefs.h. */
23629 static __inline foo_t foo (void) { return 0; }
23638 if ac_fn_c_try_compile
"$LINENO"; then :
23639 gl_cv_c___inline
=yes
23641 gl_cv_c___inline
=no
23643 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
23645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c___inline" >&5
23646 $as_echo "$gl_cv_c___inline" >&6; }
23647 if test $gl_cv_c___inline = yes; then
23649 $as_echo "#define HAVE___INLINE 1" >>confdefs.h
23657 LOCALCHARSET_TESTS_ENVIRONMENT
=
23672 $as_echo "#define _LCONV_C99 1" >>confdefs.h
23677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether locale.h conforms to POSIX:2001" >&5
23678 $as_echo_n "checking whether locale.h conforms to POSIX:2001... " >&6; }
23679 if ${gl_cv_header_locale_h_posix2001+:} false
; then :
23680 $as_echo_n "(cached) " >&6
23682 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
23683 /* end confdefs.h. */
23684 #include <locale.h>
23685 int x = LC_MESSAGES;
23686 int y = sizeof (((struct lconv *) 0)->decimal_point);
23695 if ac_fn_c_try_compile
"$LINENO"; then :
23696 gl_cv_header_locale_h_posix2001
=yes
23698 gl_cv_header_locale_h_posix2001
=no
23700 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
23702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_locale_h_posix2001" >&5
23703 $as_echo "$gl_cv_header_locale_h_posix2001" >&6; }
23705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct lconv is properly defined" >&5
23706 $as_echo_n "checking whether struct lconv is properly defined... " >&6; }
23707 if ${gl_cv_sys_struct_lconv_ok+:} false
; then :
23708 $as_echo_n "(cached) " >&6
23710 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
23711 /* end confdefs.h. */
23712 #include <locale.h>
23714 int x = sizeof (l.decimal_point);
23715 int y = sizeof (l.int_p_cs_precedes);
23724 if ac_fn_c_try_compile
"$LINENO"; then :
23725 gl_cv_sys_struct_lconv_ok
=yes
23727 gl_cv_sys_struct_lconv_ok
=no
23729 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
23732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_lconv_ok" >&5
23733 $as_echo "$gl_cv_sys_struct_lconv_ok" >&6; }
23734 if test $gl_cv_sys_struct_lconv_ok = no
; then
23737 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
23738 /* end confdefs.h. */
23745 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23746 $EGREP "Special" >/dev
/null
2>&1; then :
23749 REPLACE_STRUCT_LCONV
=1
23754 *) REPLACE_STRUCT_LCONV
=1 ;;
23766 if test $gl_cv_have_include_next = yes; then
23767 gl_cv_next_locale_h
='<'locale.h
'>'
23769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <locale.h>" >&5
23770 $as_echo_n "checking absolute name of <locale.h>... " >&6; }
23771 if ${gl_cv_next_locale_h+:} false
; then :
23772 $as_echo_n "(cached) " >&6
23777 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
23778 /* end confdefs.h. */
23779 #include <locale.h>
23782 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
23783 *) gl_absname_cpp
="$ac_cpp" ;;
23788 gl_dirsep_regex
='[/\\]'
23791 gl_dirsep_regex
='\/'
23794 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
23795 gl_header_literal_regex
=`echo 'locale.h' \
23796 | sed -e "$gl_make_literal_regex_sed"`
23797 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23798 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23804 gl_cv_absolute_locale_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23805 sed -n "$gl_absolute_header_sed"`
23807 gl_header
=$gl_cv_absolute_locale_h
23808 gl_cv_next_locale_h
='"'$gl_header'"'
23812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_locale_h" >&5
23813 $as_echo "$gl_cv_next_locale_h" >&6; }
23815 NEXT_LOCALE_H
=$gl_cv_next_locale_h
23817 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
23818 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23819 gl_next_as_first_directive
='<'locale.h
'>'
23821 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23822 gl_next_as_first_directive
=$gl_cv_next_locale_h
23824 NEXT_AS_FIRST_DIRECTIVE_LOCALE_H
=$gl_next_as_first_directive
23836 if test "$gl_threads_api" = posix
; then
23837 # OSF/1 4.0 and Mac OS X 10.1 lack the pthread_rwlock_t type and the
23838 # pthread_rwlock_* functions.
23840 ac_fn_c_check_type
"$LINENO" "pthread_rwlock_t" "ac_cv_type_pthread_rwlock_t" "#include <pthread.h>
23842 if test "x$ac_cv_type_pthread_rwlock_t" = xyes
; then :
23845 $as_echo "#define HAVE_PTHREAD_RWLOCK 1" >>confdefs.h
23849 if $has_rwlock; then
23852 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_rwlock_rdlock prefers a writer to a reader" >&5
23853 $as_echo_n "checking whether pthread_rwlock_rdlock prefers a writer to a reader... " >&6; }
23854 if ${gl_cv_pthread_rwlock_rdlock_prefer_writer+:} false
; then :
23855 $as_echo_n "(cached) " >&6
23858 LIBS
="$LIBS $LIBMULTITHREAD"
23859 if test "$cross_compiling" = yes; then :
23861 # Guess no on glibc systems.
23862 *-gnu* | gnu
*) gl_cv_pthread_rwlock_rdlock_prefer_writer
="guessing no" ;;
23863 # Guess no on musl systems.
23864 *-musl*) gl_cv_pthread_rwlock_rdlock_prefer_writer
="guessing no" ;;
23865 # Guess no on bionic systems.
23866 *-android*) gl_cv_pthread_rwlock_rdlock_prefer_writer
="guessing no" ;;
23867 # Guess yes on native Windows with the mingw-w64 winpthreads library.
23868 # Guess no on native Windows with the gnulib windows-rwlock module.
23869 mingw
*) if test "$gl_use_threads" = yes ||
test "$gl_use_threads" = posix
; then
23870 gl_cv_pthread_rwlock_rdlock_prefer_writer
="guessing yes"
23872 gl_cv_pthread_rwlock_rdlock_prefer_writer
="guessing no"
23875 # If we don't know, obey --enable-cross-guesses.
23876 *) gl_cv_pthread_rwlock_rdlock_prefer_writer
="$gl_cross_guess_normal" ;;
23880 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
23881 /* end confdefs.h. */
23884 #include <pthread.h>
23885 #include <stdlib.h>
23886 #include <unistd.h>
23888 #define SUCCEED() exit (0)
23889 #define FAILURE() exit (1)
23890 #define UNEXPECTED(n) (exit (10 + (n)))
23892 /* The main thread creates the waiting writer and the requesting reader threads
23893 in the default way; this guarantees that they have the same priority.
23894 We can reuse the main thread as first reader thread. */
23896 static pthread_rwlock_t lock;
23897 static pthread_t reader1;
23898 static pthread_t writer;
23899 static pthread_t reader2;
23900 static pthread_t timer;
23901 /* Used to pass control from writer to reader2 and from reader2 to timer,
23902 as in a relay race.
23903 Passing control from one running thread to another running thread
23904 is most likely faster than to create the second thread. */
23905 static pthread_mutex_t baton;
23908 timer_func (void *ignored)
23910 /* Step 13 (can be before or after step 12):
23911 The timer thread takes the baton, then waits a moment to make sure
23912 it can tell whether the second reader thread is blocked at step 12. */
23913 if (pthread_mutex_lock (&baton))
23916 /* By the time we get here, it's clear that the second reader thread is
23917 blocked at step 12. This is the desired behaviour. */
23922 reader2_func (void *ignored)
23926 /* Step 8 (can be before or after step 7):
23927 The second reader thread takes the baton, then waits a moment to make sure
23928 the writer thread has reached step 7. */
23929 if (pthread_mutex_lock (&baton))
23932 /* Step 9: The second reader thread requests the lock. */
23933 err = pthread_rwlock_tryrdlock (&lock);
23936 else if (err != EBUSY)
23938 /* Step 10: Launch a timer, to test whether the next call blocks. */
23939 if (pthread_create (&timer, NULL, timer_func, NULL))
23941 /* Step 11: Release the baton. */
23942 if (pthread_mutex_unlock (&baton))
23944 /* Step 12: The second reader thread requests the lock. */
23945 err = pthread_rwlock_rdlock (&lock);
23953 writer_func (void *ignored)
23955 /* Step 4: Take the baton, so that the second reader thread does not go ahead
23957 if (pthread_mutex_lock (&baton))
23959 /* Step 5: Create the second reader thread. */
23960 if (pthread_create (&reader2, NULL, reader2_func, NULL))
23962 /* Step 6: Release the baton. */
23963 if (pthread_mutex_unlock (&baton))
23965 /* Step 7: The writer thread requests the lock. */
23966 if (pthread_rwlock_wrlock (&lock))
23974 reader1 = pthread_self ();
23976 /* Step 1: The main thread initializes the lock and the baton. */
23977 if (pthread_rwlock_init (&lock, NULL))
23979 if (pthread_mutex_init (&baton, NULL))
23981 /* Step 2: The main thread acquires the lock as a reader. */
23982 if (pthread_rwlock_rdlock (&lock))
23984 /* Step 3: Create the writer thread. */
23985 if (pthread_create (&writer, NULL, writer_func, NULL))
23987 /* Job done. Go to sleep. */
23995 if ac_fn_c_try_run
"$LINENO"; then :
23996 gl_cv_pthread_rwlock_rdlock_prefer_writer
=yes
23998 gl_cv_pthread_rwlock_rdlock_prefer_writer
=no
24000 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
24001 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
24007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pthread_rwlock_rdlock_prefer_writer" >&5
24008 $as_echo "$gl_cv_pthread_rwlock_rdlock_prefer_writer" >&6; }
24009 case "$gl_cv_pthread_rwlock_rdlock_prefer_writer" in
24012 $as_echo "#define HAVE_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER 1" >>confdefs.h
24018 # glibc defines PTHREAD_MUTEX_RECURSIVE as enum, not as a macro.
24019 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
24020 /* end confdefs.h. */
24022 #include <pthread.h>
24027 #if __FreeBSD__ == 4
24028 error "No, in FreeBSD 4.0 recursive mutexes actually don't work."
24029 #elif (defined __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ \
24030 && __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ < 1070)
24031 error "No, in Mac OS X < 10.7 recursive mutexes actually don't work."
24033 int x = (int)PTHREAD_MUTEX_RECURSIVE;
24041 if ac_fn_c_try_compile
"$LINENO"; then :
24043 $as_echo "#define HAVE_PTHREAD_MUTEX_RECURSIVE 1" >>confdefs.h
24046 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
24052 cat >>confdefs.h
<<_ACEOF
24053 #define GNULIB_LOCK 1
24061 if test $ac_cv_func_lstat = yes; then
24063 case $host_os,$gl_cv_func_lstat_dereferences_slashed_symlink in
24072 if test $REPLACE_LSTAT = 1; then
24081 gl_LIBOBJS
="$gl_LIBOBJS lstat.$ac_objext"
24096 $as_echo "#define GNULIB_TEST_LSTAT 1" >>confdefs.h
24103 if test $gl_cv_func_malloc_posix = yes; then
24105 $as_echo "#define HAVE_MALLOC_POSIX 1" >>confdefs.h
24111 if test $REPLACE_MALLOC = 1; then
24120 gl_LIBOBJS
="$gl_LIBOBJS malloc.$ac_objext"
24128 GNULIB_MALLOC_POSIX
=1
24134 $as_echo "#define GNULIB_TEST_MALLOC_POSIX 1" >>confdefs.h
24152 if test $gl_cv_have_include_next = yes; then
24153 gl_cv_next_math_h
='<'math.h
'>'
24155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <math.h>" >&5
24156 $as_echo_n "checking absolute name of <math.h>... " >&6; }
24157 if ${gl_cv_next_math_h+:} false
; then :
24158 $as_echo_n "(cached) " >&6
24161 if test $ac_cv_header_math_h = yes; then
24166 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
24167 /* end confdefs.h. */
24171 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
24172 *) gl_absname_cpp
="$ac_cpp" ;;
24177 gl_dirsep_regex
='[/\\]'
24180 gl_dirsep_regex
='\/'
24183 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
24184 gl_header_literal_regex
=`echo 'math.h' \
24185 | sed -e "$gl_make_literal_regex_sed"`
24186 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
24187 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
24193 gl_cv_absolute_math_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
24194 sed -n "$gl_absolute_header_sed"`
24196 gl_header
=$gl_cv_absolute_math_h
24197 gl_cv_next_math_h
='"'$gl_header'"'
24199 gl_cv_next_math_h
='<'math.h
'>'
24204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_math_h" >&5
24205 $as_echo "$gl_cv_next_math_h" >&6; }
24207 NEXT_MATH_H
=$gl_cv_next_math_h
24209 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
24210 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
24211 gl_next_as_first_directive
='<'math.h
'>'
24213 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
24214 gl_next_as_first_directive
=$gl_cv_next_math_h
24216 NEXT_AS_FIRST_DIRECTIVE_MATH_H
=$gl_next_as_first_directive
24222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NAN macro works" >&5
24223 $as_echo_n "checking whether NAN macro works... " >&6; }
24224 if ${gl_cv_header_math_nan_works+:} false
; then :
24225 $as_echo_n "(cached) " >&6
24227 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
24228 /* end confdefs.h. */
24233 /* Solaris 10 has a broken definition of NAN. Other platforms
24234 fail to provide NAN, or provide it only in C99 mode; this
24235 test only needs to fail when NAN is provided but wrong. */
24245 if ac_fn_c_try_compile
"$LINENO"; then :
24246 gl_cv_header_math_nan_works
=yes
24248 gl_cv_header_math_nan_works
=no
24250 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
24252 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_math_nan_works" >&5
24253 $as_echo "$gl_cv_header_math_nan_works" >&6; }
24254 if test $gl_cv_header_math_nan_works = no
; then
24257 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether HUGE_VAL works" >&5
24258 $as_echo_n "checking whether HUGE_VAL works... " >&6; }
24259 if ${gl_cv_header_math_huge_val_works+:} false
; then :
24260 $as_echo_n "(cached) " >&6
24262 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
24263 /* end confdefs.h. */
24268 /* Solaris 10 has a broken definition of HUGE_VAL. */
24269 double d = HUGE_VAL;
24275 if ac_fn_c_try_compile
"$LINENO"; then :
24276 gl_cv_header_math_huge_val_works
=yes
24278 gl_cv_header_math_huge_val_works
=no
24280 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
24282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_math_huge_val_works" >&5
24283 $as_echo "$gl_cv_header_math_huge_val_works" >&6; }
24284 if test $gl_cv_header_math_huge_val_works = no
; then
24305 if case "$host_os" in
24307 *) test $ac_cv_func_mbsinit = yes ;;
24309 && test $ac_cv_func_mbrtowc = yes; then
24314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
24315 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
24316 if ${gl_cv_func_mbrtowc_incomplete_state+:} false
; then :
24317 $as_echo_n "(cached) " >&6
24321 # Guess no on AIX and OSF/1.
24322 aix
* | osf
*) gl_cv_func_mbrtowc_incomplete_state
="guessing no" ;;
24323 # Guess yes otherwise.
24324 *) gl_cv_func_mbrtowc_incomplete_state
="guessing yes" ;;
24326 if test $LOCALE_JA != none
; then
24327 if test "$cross_compiling" = yes; then :
24330 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
24331 /* end confdefs.h. */
24333 #include <locale.h>
24334 #include <string.h>
24338 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
24340 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
24344 memset (&state, '\0', sizeof (mbstate_t));
24345 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
24346 if (mbsinit (&state))
24352 if ac_fn_c_try_run
"$LINENO"; then :
24353 gl_cv_func_mbrtowc_incomplete_state
=yes
24355 gl_cv_func_mbrtowc_incomplete_state
=no
24357 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
24358 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
24362 if test $LOCALE_FR_UTF8 != none
; then
24363 if test "$cross_compiling" = yes; then :
24366 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
24367 /* end confdefs.h. */
24369 #include <locale.h>
24370 #include <string.h>
24374 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
24376 const char input[] = "B\303\274\303\237er"; /* "Büßer" */
24380 memset (&state, '\0', sizeof (mbstate_t));
24381 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
24382 if (mbsinit (&state))
24388 if ac_fn_c_try_run
"$LINENO"; then :
24389 gl_cv_func_mbrtowc_incomplete_state
=yes
24391 gl_cv_func_mbrtowc_incomplete_state
=no
24393 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
24394 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
24401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
24402 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
24407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
24408 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
24409 if ${gl_cv_func_mbrtowc_sanitycheck+:} false
; then :
24410 $as_echo_n "(cached) " >&6
24414 # Guess no on Solaris 8.
24415 solaris2.8
) gl_cv_func_mbrtowc_sanitycheck
="guessing no" ;;
24416 # Guess yes otherwise.
24417 *) gl_cv_func_mbrtowc_sanitycheck
="guessing yes" ;;
24419 if test $LOCALE_ZH_CN != none
; then
24420 if test "$cross_compiling" = yes; then :
24423 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
24424 /* end confdefs.h. */
24426 #include <locale.h>
24427 #include <stdlib.h>
24428 #include <string.h>
24432 /* This fails on Solaris 8:
24433 mbrtowc returns 2, and sets wc to 0x00F0.
24434 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
24435 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
24437 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
24441 memset (&state, '\0', sizeof (mbstate_t));
24442 if (mbrtowc (&wc, input + 3, 6, &state) != 4
24443 && mbtowc (&wc, input + 3, 6) == 4)
24449 if ac_fn_c_try_run
"$LINENO"; then :
24450 gl_cv_func_mbrtowc_sanitycheck
=yes
24452 gl_cv_func_mbrtowc_sanitycheck
=no
24454 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
24455 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
24461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
24462 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
24464 REPLACE_MBSTATE_T
=0
24465 case "$gl_cv_func_mbrtowc_incomplete_state" in
24467 *) REPLACE_MBSTATE_T
=1 ;;
24469 case "$gl_cv_func_mbrtowc_sanitycheck" in
24471 *) REPLACE_MBSTATE_T
=1 ;;
24474 REPLACE_MBSTATE_T
=1
24479 if test $ac_cv_func_mbrtowc = no
; then
24481 ac_fn_c_check_decl
"$LINENO" "mbrtowc" "ac_cv_have_decl_mbrtowc" "
24485 if test "x$ac_cv_have_decl_mbrtowc" = xyes
; then :
24491 cat >>confdefs.h
<<_ACEOF
24492 #define HAVE_DECL_MBRTOWC $ac_have_decl
24495 if test $ac_cv_have_decl_mbrtowc = yes; then
24499 if test $REPLACE_MBSTATE_T = 1; then
24505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles a NULL pwc argument" >&5
24506 $as_echo_n "checking whether mbrtowc handles a NULL pwc argument... " >&6; }
24507 if ${gl_cv_func_mbrtowc_null_arg1+:} false
; then :
24508 $as_echo_n "(cached) " >&6
24512 # Guess no on Solaris.
24513 solaris
*) gl_cv_func_mbrtowc_null_arg1
="guessing no" ;;
24514 # Guess yes otherwise.
24515 *) gl_cv_func_mbrtowc_null_arg1
="guessing yes" ;;
24517 if test $LOCALE_FR_UTF8 != none
; then
24518 if test "$cross_compiling" = yes; then :
24521 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
24522 /* end confdefs.h. */
24524 #include <locale.h>
24525 #include <stdlib.h>
24526 #include <string.h>
24532 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
24534 char input[] = "\303\237er";
24539 memset (&state, '\0', sizeof (mbstate_t));
24540 wc = (wchar_t) 0xBADFACE;
24541 ret = mbrtowc (&wc, input, 5, &state);
24544 if (!mbsinit (&state))
24547 memset (&state, '\0', sizeof (mbstate_t));
24548 ret = mbrtowc (NULL, input, 5, &state);
24549 if (ret != 2) /* Solaris 7 fails here: ret is -1. */
24551 if (!mbsinit (&state))
24557 if ac_fn_c_try_run
"$LINENO"; then :
24558 gl_cv_func_mbrtowc_null_arg1
=yes
24560 gl_cv_func_mbrtowc_null_arg1
=no
24562 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
24563 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
24569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_null_arg1" >&5
24570 $as_echo "$gl_cv_func_mbrtowc_null_arg1" >&6; }
24575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles a NULL string argument" >&5
24576 $as_echo_n "checking whether mbrtowc handles a NULL string argument... " >&6; }
24577 if ${gl_cv_func_mbrtowc_null_arg2+:} false
; then :
24578 $as_echo_n "(cached) " >&6
24582 # Guess no on OSF/1.
24583 osf
*) gl_cv_func_mbrtowc_null_arg2
="guessing no" ;;
24584 # Guess yes otherwise.
24585 *) gl_cv_func_mbrtowc_null_arg2
="guessing yes" ;;
24587 if test $LOCALE_FR_UTF8 != none
; then
24588 if test "$cross_compiling" = yes; then :
24591 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
24592 /* end confdefs.h. */
24594 #include <locale.h>
24595 #include <string.h>
24599 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
24605 memset (&state, '\0', sizeof (mbstate_t));
24606 wc = (wchar_t) 0xBADFACE;
24607 mbrtowc (&wc, NULL, 5, &state);
24608 /* Check that wc was not modified. */
24609 if (wc != (wchar_t) 0xBADFACE)
24615 if ac_fn_c_try_run
"$LINENO"; then :
24616 gl_cv_func_mbrtowc_null_arg2
=yes
24618 gl_cv_func_mbrtowc_null_arg2
=no
24620 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
24621 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
24627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_null_arg2" >&5
24628 $as_echo "$gl_cv_func_mbrtowc_null_arg2" >&6; }
24635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc has a correct return value" >&5
24636 $as_echo_n "checking whether mbrtowc has a correct return value... " >&6; }
24637 if ${gl_cv_func_mbrtowc_retval+:} false
; then :
24638 $as_echo_n "(cached) " >&6
24642 # Guess no on HP-UX, Solaris, native Windows.
24643 hpux
* | solaris
* | mingw
*) gl_cv_func_mbrtowc_retval
="guessing no" ;;
24644 # Guess yes otherwise.
24645 *) gl_cv_func_mbrtowc_retval
="guessing yes" ;;
24647 if test $LOCALE_FR_UTF8 != none ||
test $LOCALE_JA != none \
24648 ||
{ case "$host_os" in mingw
*) true
;; *) false
;; esac; }; then
24649 if test "$cross_compiling" = yes; then :
24652 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
24653 /* end confdefs.h. */
24655 #include <locale.h>
24656 #include <string.h>
24661 int found_some_locale = 0;
24662 /* This fails on Solaris. */
24663 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
24665 char input[] = "B\303\274\303\237er"; /* "Büßer" */
24669 memset (&state, '\0', sizeof (mbstate_t));
24670 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
24673 if (mbrtowc (&wc, input + 2, 5, &state) != 1)
24676 found_some_locale = 1;
24678 /* This fails on HP-UX 11.11. */
24679 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
24681 char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
24685 memset (&state, '\0', sizeof (mbstate_t));
24686 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
24689 if (mbrtowc (&wc, input + 2, 5, &state) != 2)
24692 found_some_locale = 1;
24694 /* This fails on native Windows. */
24695 if (setlocale (LC_ALL, "Japanese_Japan.932") != NULL)
24697 char input[] = "<\223\372\226\173\214\352>"; /* "<日本語>" */
24701 memset (&state, '\0', sizeof (mbstate_t));
24702 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
24705 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
24708 found_some_locale = 1;
24710 if (setlocale (LC_ALL, "Chinese_Taiwan.950") != NULL)
24712 char input[] = "<\244\351\245\273\273\171>"; /* "<日本語>" */
24716 memset (&state, '\0', sizeof (mbstate_t));
24717 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
24720 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
24723 found_some_locale = 1;
24725 if (setlocale (LC_ALL, "Chinese_China.936") != NULL)
24727 char input[] = "<\310\325\261\276\325\132>"; /* "<日本語>" */
24731 memset (&state, '\0', sizeof (mbstate_t));
24732 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
24735 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
24738 found_some_locale = 1;
24740 return (found_some_locale ? result : 77);
24743 if ac_fn_c_try_run
"$LINENO"; then :
24744 gl_cv_func_mbrtowc_retval
=yes
24746 if test $?
!= 77; then
24747 gl_cv_func_mbrtowc_retval
=no
24751 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
24752 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
24758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_retval" >&5
24759 $as_echo "$gl_cv_func_mbrtowc_retval" >&6; }
24764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc returns 0 when parsing a NUL character" >&5
24765 $as_echo_n "checking whether mbrtowc returns 0 when parsing a NUL character... " >&6; }
24766 if ${gl_cv_func_mbrtowc_nul_retval+:} false
; then :
24767 $as_echo_n "(cached) " >&6
24771 # Guess no on Solaris 8 and 9.
24772 solaris2.
[89]) gl_cv_func_mbrtowc_nul_retval
="guessing no" ;;
24773 # Guess yes otherwise.
24774 *) gl_cv_func_mbrtowc_nul_retval
="guessing yes" ;;
24776 if test $LOCALE_ZH_CN != none
; then
24777 if test "$cross_compiling" = yes; then :
24780 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
24781 /* end confdefs.h. */
24783 #include <locale.h>
24784 #include <string.h>
24788 /* This fails on Solaris 8 and 9. */
24789 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
24794 memset (&state, '\0', sizeof (mbstate_t));
24795 if (mbrtowc (&wc, "", 1, &state) != 0)
24801 if ac_fn_c_try_run
"$LINENO"; then :
24802 gl_cv_func_mbrtowc_nul_retval
=yes
24804 gl_cv_func_mbrtowc_nul_retval
=no
24806 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
24807 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
24813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_nul_retval" >&5
24814 $as_echo "$gl_cv_func_mbrtowc_nul_retval" >&6; }
24818 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc stores incomplete characters" >&5
24819 $as_echo_n "checking whether mbrtowc stores incomplete characters... " >&6; }
24820 if ${gl_cv_func_mbrtowc_stores_incomplete+:} false
; then :
24821 $as_echo_n "(cached) " >&6
24825 # Guess yes on native Windows.
24826 mingw
*) gl_cv_func_mbrtowc_stores_incomplete
="guessing yes" ;;
24827 *) gl_cv_func_mbrtowc_stores_incomplete
="guessing no" ;;
24831 if test "$cross_compiling" = yes; then :
24834 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
24835 /* end confdefs.h. */
24837 #include <locale.h>
24838 #include <string.h>
24843 if (setlocale (LC_ALL, "French_France.65001") != NULL)
24845 wchar_t wc = (wchar_t) 0xBADFACE;
24848 memset (&state, '\0', sizeof (mbstate_t));
24849 if (mbrtowc (&wc, "\303", 1, &state) == (size_t)(-2)
24850 && wc != (wchar_t) 0xBADFACE)
24853 if (setlocale (LC_ALL, "Japanese_Japan.932") != NULL)
24855 wchar_t wc = (wchar_t) 0xBADFACE;
24858 memset (&state, '\0', sizeof (mbstate_t));
24859 if (mbrtowc (&wc, "\226", 1, &state) == (size_t)(-2)
24860 && wc != (wchar_t) 0xBADFACE)
24863 if (setlocale (LC_ALL, "Chinese_Taiwan.950") != NULL)
24865 wchar_t wc = (wchar_t) 0xBADFACE;
24868 memset (&state, '\0', sizeof (mbstate_t));
24869 if (mbrtowc (&wc, "\245", 1, &state) == (size_t)(-2)
24870 && wc != (wchar_t) 0xBADFACE)
24873 if (setlocale (LC_ALL, "Chinese_China.936") != NULL)
24875 wchar_t wc = (wchar_t) 0xBADFACE;
24878 memset (&state, '\0', sizeof (mbstate_t));
24879 if (mbrtowc (&wc, "\261", 1, &state) == (size_t)(-2)
24880 && wc != (wchar_t) 0xBADFACE)
24886 if ac_fn_c_try_run
"$LINENO"; then :
24887 gl_cv_func_mbrtowc_stores_incomplete
=no
24889 gl_cv_func_mbrtowc_stores_incomplete
=yes
24891 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
24892 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
24898 if test $LOCALE_FR_UTF8 != none
; then
24899 if test "$cross_compiling" = yes; then :
24902 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
24903 /* end confdefs.h. */
24905 #include <locale.h>
24906 #include <string.h>
24910 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
24912 wchar_t wc = (wchar_t) 0xBADFACE;
24915 memset (&state, '\0', sizeof (mbstate_t));
24916 if (mbrtowc (&wc, "\303", 1, &state) == (size_t)(-2)
24917 && wc != (wchar_t) 0xBADFACE)
24923 if ac_fn_c_try_run
"$LINENO"; then :
24924 gl_cv_func_mbrtowc_stores_incomplete
=no
24926 gl_cv_func_mbrtowc_stores_incomplete
=yes
24928 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
24929 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
24937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_stores_incomplete" >&5
24938 $as_echo "$gl_cv_func_mbrtowc_stores_incomplete" >&6; }
24942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works on empty input" >&5
24943 $as_echo_n "checking whether mbrtowc works on empty input... " >&6; }
24944 if ${gl_cv_func_mbrtowc_empty_input+:} false
; then :
24945 $as_echo_n "(cached) " >&6
24949 # Guess no on AIX and glibc systems.
24950 aix
* |
*-gnu* | gnu
*) gl_cv_func_mbrtowc_empty_input
="guessing no" ;;
24951 # Guess yes on native Windows.
24952 mingw
*) gl_cv_func_mbrtowc_empty_input
="guessing yes" ;;
24953 *) gl_cv_func_mbrtowc_empty_input
="guessing yes" ;;
24955 if test "$cross_compiling" = yes; then :
24958 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
24959 /* end confdefs.h. */
24963 static mbstate_t mbs;
24967 return mbrtowc (&wc, "", 0, &mbs) != (size_t) -2;
24970 if ac_fn_c_try_run
"$LINENO"; then :
24971 gl_cv_func_mbrtowc_empty_input
=yes
24973 gl_cv_func_mbrtowc_empty_input
=no
24975 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
24976 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
24981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_empty_input" >&5
24982 $as_echo "$gl_cv_func_mbrtowc_empty_input" >&6; }
24985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C locale is free of encoding errors" >&5
24986 $as_echo_n "checking whether the C locale is free of encoding errors... " >&6; }
24987 if ${gl_cv_func_mbrtowc_C_locale_sans_EILSEQ+:} false
; then :
24988 $as_echo_n "(cached) " >&6
24991 gl_cv_func_mbrtowc_C_locale_sans_EILSEQ
="$gl_cross_guess_normal"
24993 if test "$cross_compiling" = yes; then :
24995 # Guess yes on native Windows.
24996 mingw
*) gl_cv_func_mbrtowc_C_locale_sans_EILSEQ
="guessing yes" ;;
25000 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
25001 /* end confdefs.h. */
25002 #include <limits.h>
25003 #include <locale.h>
25011 char *locale = setlocale (LC_ALL, "C");
25014 for (i = CHAR_MIN; i <= CHAR_MAX; i++)
25018 mbstate_t mbs = { 0, };
25019 size_t ss = mbrtowc (&wc, &c, 1, &mbs);
25029 if ac_fn_c_try_run
"$LINENO"; then :
25030 gl_cv_func_mbrtowc_C_locale_sans_EILSEQ
=yes
25032 gl_cv_func_mbrtowc_C_locale_sans_EILSEQ
=no
25034 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
25035 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
25040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_C_locale_sans_EILSEQ" >&5
25041 $as_echo "$gl_cv_func_mbrtowc_C_locale_sans_EILSEQ" >&6; }
25043 case "$gl_cv_func_mbrtowc_null_arg1" in
25046 $as_echo "#define MBRTOWC_NULL_ARG1_BUG 1" >>confdefs.h
25051 case "$gl_cv_func_mbrtowc_null_arg2" in
25054 $as_echo "#define MBRTOWC_NULL_ARG2_BUG 1" >>confdefs.h
25059 case "$gl_cv_func_mbrtowc_retval" in
25062 $as_echo "#define MBRTOWC_RETVAL_BUG 1" >>confdefs.h
25067 case "$gl_cv_func_mbrtowc_nul_retval" in
25070 $as_echo "#define MBRTOWC_NUL_RETVAL_BUG 1" >>confdefs.h
25075 case "$gl_cv_func_mbrtowc_stores_incomplete" in
25078 $as_echo "#define MBRTOWC_STORES_INCOMPLETE_BUG 1" >>confdefs.h
25083 case "$gl_cv_func_mbrtowc_empty_input" in
25086 $as_echo "#define MBRTOWC_EMPTY_INPUT_BUG 1" >>confdefs.h
25091 case "$gl_cv_func_mbrtowc_C_locale_sans_EILSEQ" in
25094 $as_echo "#define MBRTOWC_IN_C_LOCALE_MAYBE_EILSEQ 1" >>confdefs.h
25101 if test $REPLACE_MBSTATE_T = 1; then
25103 mingw
*) LIB_MBRTOWC
= ;;
25107 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether imported symbols can be declared weak" >&5
25108 $as_echo_n "checking whether imported symbols can be declared weak... " >&6; }
25109 if ${gl_cv_have_weak+:} false
; then :
25110 $as_echo_n "(cached) " >&6
25113 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
25114 /* end confdefs.h. */
25115 extern void xyzzy ();
25125 if ac_fn_c_try_link
"$LINENO"; then :
25126 gl_cv_have_weak
=maybe
25128 rm -f core conftest.err conftest.
$ac_objext \
25129 conftest
$ac_exeext conftest.
$ac_ext
25130 if test $gl_cv_have_weak = maybe
; then
25131 if test "$cross_compiling" = yes; then :
25132 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
25133 /* end confdefs.h. */
25135 Extensible Linking Format
25139 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
25140 $EGREP "Extensible Linking Format" >/dev
/null
2>&1; then :
25141 gl_cv_have_weak
="guessing yes"
25143 gl_cv_have_weak
="guessing no"
25149 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
25150 /* end confdefs.h. */
25156 return (fputs == NULL);
25159 if ac_fn_c_try_run
"$LINENO"; then :
25160 gl_cv_have_weak
=yes
25164 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
25165 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
25169 case " $LDFLAGS " in
25170 *" -static "*) gl_cv_have_weak
=no
;;
25172 case "$gl_cv_have_weak" in
25175 freebsd
* | dragonfly
*)
25177 $CC $CPPFLAGS $CFLAGS $LDFLAGS -fPIC -shared -o libempty.so conftest1.c
-lpthread >&5 2>&1
25178 cat <<EOF > conftest2.c
25179 #include <pthread.h>
25180 #pragma weak pthread_mutexattr_gettype
25183 return (pthread_mutexattr_gettype != NULL);
25186 $CC $CPPFLAGS $CFLAGS $LDFLAGS -o conftest conftest2.c libempty.so
>&5 2>&1 \
25187 || gl_cv_have_weak
=no
25188 rm -f conftest1.c libempty.so conftest2.c conftest
25195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_weak" >&5
25196 $as_echo "$gl_cv_have_weak" >&6; }
25197 case "$gl_cv_have_weak" in
25200 $as_echo "#define HAVE_WEAK_SYMBOLS 1" >>confdefs.h
25205 case "$gl_cv_have_weak" in
25206 *yes) LIB_MBRTOWC
= ;;
25207 *) LIB_MBRTOWC
="$LIBPTHREAD" ;;
25216 if test $HAVE_MBRTOWC = 0 ||
test $REPLACE_MBRTOWC = 1; then
25225 gl_LIBOBJS
="$gl_LIBOBJS mbrtowc.$ac_objext"
25227 if test $REPLACE_MBSTATE_T = 1; then
25236 gl_LIBOBJS
="$gl_LIBOBJS lc-charset-dispatch.$ac_objext"
25246 gl_LIBOBJS
="$gl_LIBOBJS mbtowc-lock.$ac_objext"
25253 if test -n "$GCC"; then
25254 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the -Werror option is usable" >&5
25255 $as_echo_n "checking whether the -Werror option is usable... " >&6; }
25256 if ${gl_cv_cc_vis_werror+:} false
; then :
25257 $as_echo_n "(cached) " >&6
25259 gl_save_CFLAGS
="$CFLAGS"
25260 CFLAGS
="$CFLAGS -Werror"
25261 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
25262 /* end confdefs.h. */
25272 if ac_fn_c_try_compile
"$LINENO"; then :
25273 gl_cv_cc_vis_werror
=yes
25275 gl_cv_cc_vis_werror
=no
25277 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
25278 CFLAGS
="$gl_save_CFLAGS"
25281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_vis_werror" >&5
25282 $as_echo "$gl_cv_cc_vis_werror" >&6; }
25283 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for simple visibility declarations" >&5
25284 $as_echo_n "checking for simple visibility declarations... " >&6; }
25285 if ${gl_cv_cc_visibility+:} false
; then :
25286 $as_echo_n "(cached) " >&6
25288 gl_save_CFLAGS
="$CFLAGS"
25289 CFLAGS
="$CFLAGS -fvisibility=hidden"
25290 if test $gl_cv_cc_vis_werror = yes; then
25291 CFLAGS
="$CFLAGS -Werror"
25293 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
25294 /* end confdefs.h. */
25295 extern __attribute__((__visibility__("hidden"))) int hiddenvar;
25296 extern __attribute__((__visibility__("default"))) int exportedvar;
25297 extern __attribute__((__visibility__("hidden"))) int hiddenfunc (void);
25298 extern __attribute__((__visibility__("default"))) int exportedfunc (void);
25299 void dummyfunc (void) {}
25309 if ac_fn_c_try_compile
"$LINENO"; then :
25310 gl_cv_cc_visibility
=yes
25312 gl_cv_cc_visibility
=no
25314 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
25315 CFLAGS
="$gl_save_CFLAGS"
25318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_visibility" >&5
25319 $as_echo "$gl_cv_cc_visibility" >&6; }
25320 if test $gl_cv_cc_visibility = yes; then
25321 CFLAG_VISIBILITY
="-fvisibility=hidden"
25328 cat >>confdefs.h
<<_ACEOF
25329 #define HAVE_VISIBILITY $HAVE_VISIBILITY
25351 $as_echo "#define GNULIB_TEST_MBRTOWC 1" >>confdefs.h
25367 if case "$host_os" in
25369 *) test $ac_cv_func_mbsinit = yes ;;
25371 && test $ac_cv_func_mbrtowc = yes; then
25376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
25377 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
25378 if ${gl_cv_func_mbrtowc_incomplete_state+:} false
; then :
25379 $as_echo_n "(cached) " >&6
25383 # Guess no on AIX and OSF/1.
25384 aix
* | osf
*) gl_cv_func_mbrtowc_incomplete_state
="guessing no" ;;
25385 # Guess yes otherwise.
25386 *) gl_cv_func_mbrtowc_incomplete_state
="guessing yes" ;;
25388 if test $LOCALE_JA != none
; then
25389 if test "$cross_compiling" = yes; then :
25392 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
25393 /* end confdefs.h. */
25395 #include <locale.h>
25396 #include <string.h>
25400 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
25402 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
25406 memset (&state, '\0', sizeof (mbstate_t));
25407 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
25408 if (mbsinit (&state))
25414 if ac_fn_c_try_run
"$LINENO"; then :
25415 gl_cv_func_mbrtowc_incomplete_state
=yes
25417 gl_cv_func_mbrtowc_incomplete_state
=no
25419 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
25420 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
25424 if test $LOCALE_FR_UTF8 != none
; then
25425 if test "$cross_compiling" = yes; then :
25428 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
25429 /* end confdefs.h. */
25431 #include <locale.h>
25432 #include <string.h>
25436 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
25438 const char input[] = "B\303\274\303\237er"; /* "Büßer" */
25442 memset (&state, '\0', sizeof (mbstate_t));
25443 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
25444 if (mbsinit (&state))
25450 if ac_fn_c_try_run
"$LINENO"; then :
25451 gl_cv_func_mbrtowc_incomplete_state
=yes
25453 gl_cv_func_mbrtowc_incomplete_state
=no
25455 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
25456 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
25463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
25464 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
25469 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
25470 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
25471 if ${gl_cv_func_mbrtowc_sanitycheck+:} false
; then :
25472 $as_echo_n "(cached) " >&6
25476 # Guess no on Solaris 8.
25477 solaris2.8
) gl_cv_func_mbrtowc_sanitycheck
="guessing no" ;;
25478 # Guess yes otherwise.
25479 *) gl_cv_func_mbrtowc_sanitycheck
="guessing yes" ;;
25481 if test $LOCALE_ZH_CN != none
; then
25482 if test "$cross_compiling" = yes; then :
25485 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
25486 /* end confdefs.h. */
25488 #include <locale.h>
25489 #include <stdlib.h>
25490 #include <string.h>
25494 /* This fails on Solaris 8:
25495 mbrtowc returns 2, and sets wc to 0x00F0.
25496 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
25497 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
25499 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
25503 memset (&state, '\0', sizeof (mbstate_t));
25504 if (mbrtowc (&wc, input + 3, 6, &state) != 4
25505 && mbtowc (&wc, input + 3, 6) == 4)
25511 if ac_fn_c_try_run
"$LINENO"; then :
25512 gl_cv_func_mbrtowc_sanitycheck
=yes
25514 gl_cv_func_mbrtowc_sanitycheck
=no
25516 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
25517 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
25523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
25524 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
25526 REPLACE_MBSTATE_T
=0
25527 case "$gl_cv_func_mbrtowc_incomplete_state" in
25529 *) REPLACE_MBSTATE_T
=1 ;;
25531 case "$gl_cv_func_mbrtowc_sanitycheck" in
25533 *) REPLACE_MBSTATE_T
=1 ;;
25536 REPLACE_MBSTATE_T
=1
25541 if test $ac_cv_func_mbsinit = no
; then
25543 ac_fn_c_check_decl
"$LINENO" "mbsinit" "ac_cv_have_decl_mbsinit" "
25547 if test "x$ac_cv_have_decl_mbsinit" = xyes
; then :
25553 cat >>confdefs.h
<<_ACEOF
25554 #define HAVE_DECL_MBSINIT $ac_have_decl
25557 if test $ac_cv_have_decl_mbsinit = yes; then
25561 if test $REPLACE_MBSTATE_T = 1; then
25565 mingw
*) REPLACE_MBSINIT
=1 ;;
25570 if test $HAVE_MBSINIT = 0 ||
test $REPLACE_MBSINIT = 1; then
25579 gl_LIBOBJS
="$gl_LIBOBJS mbsinit.$ac_objext"
25596 $as_echo "#define GNULIB_TEST_MBSINIT 1" >>confdefs.h
25611 if case "$host_os" in
25613 *) test $ac_cv_func_mbsinit = yes ;;
25615 && test $ac_cv_func_mbrtowc = yes; then
25620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
25621 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
25622 if ${gl_cv_func_mbrtowc_incomplete_state+:} false
; then :
25623 $as_echo_n "(cached) " >&6
25627 # Guess no on AIX and OSF/1.
25628 aix
* | osf
*) gl_cv_func_mbrtowc_incomplete_state
="guessing no" ;;
25629 # Guess yes otherwise.
25630 *) gl_cv_func_mbrtowc_incomplete_state
="guessing yes" ;;
25632 if test $LOCALE_JA != none
; then
25633 if test "$cross_compiling" = yes; then :
25636 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
25637 /* end confdefs.h. */
25639 #include <locale.h>
25640 #include <string.h>
25644 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
25646 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
25650 memset (&state, '\0', sizeof (mbstate_t));
25651 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
25652 if (mbsinit (&state))
25658 if ac_fn_c_try_run
"$LINENO"; then :
25659 gl_cv_func_mbrtowc_incomplete_state
=yes
25661 gl_cv_func_mbrtowc_incomplete_state
=no
25663 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
25664 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
25668 if test $LOCALE_FR_UTF8 != none
; then
25669 if test "$cross_compiling" = yes; then :
25672 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
25673 /* end confdefs.h. */
25675 #include <locale.h>
25676 #include <string.h>
25680 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
25682 const char input[] = "B\303\274\303\237er"; /* "Büßer" */
25686 memset (&state, '\0', sizeof (mbstate_t));
25687 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
25688 if (mbsinit (&state))
25694 if ac_fn_c_try_run
"$LINENO"; then :
25695 gl_cv_func_mbrtowc_incomplete_state
=yes
25697 gl_cv_func_mbrtowc_incomplete_state
=no
25699 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
25700 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
25707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
25708 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
25713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
25714 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
25715 if ${gl_cv_func_mbrtowc_sanitycheck+:} false
; then :
25716 $as_echo_n "(cached) " >&6
25720 # Guess no on Solaris 8.
25721 solaris2.8
) gl_cv_func_mbrtowc_sanitycheck
="guessing no" ;;
25722 # Guess yes otherwise.
25723 *) gl_cv_func_mbrtowc_sanitycheck
="guessing yes" ;;
25725 if test $LOCALE_ZH_CN != none
; then
25726 if test "$cross_compiling" = yes; then :
25729 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
25730 /* end confdefs.h. */
25732 #include <locale.h>
25733 #include <stdlib.h>
25734 #include <string.h>
25738 /* This fails on Solaris 8:
25739 mbrtowc returns 2, and sets wc to 0x00F0.
25740 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
25741 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
25743 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
25747 memset (&state, '\0', sizeof (mbstate_t));
25748 if (mbrtowc (&wc, input + 3, 6, &state) != 4
25749 && mbtowc (&wc, input + 3, 6) == 4)
25755 if ac_fn_c_try_run
"$LINENO"; then :
25756 gl_cv_func_mbrtowc_sanitycheck
=yes
25758 gl_cv_func_mbrtowc_sanitycheck
=no
25760 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
25761 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
25767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
25768 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
25770 REPLACE_MBSTATE_T
=0
25771 case "$gl_cv_func_mbrtowc_incomplete_state" in
25773 *) REPLACE_MBSTATE_T
=1 ;;
25775 case "$gl_cv_func_mbrtowc_sanitycheck" in
25777 *) REPLACE_MBSTATE_T
=1 ;;
25780 REPLACE_MBSTATE_T
=1
25785 if test $ac_cv_func_mbsrtowcs = no
; then
25787 ac_fn_c_check_decl
"$LINENO" "mbsrtowcs" "ac_cv_have_decl_mbsrtowcs" "
25791 if test "x$ac_cv_have_decl_mbsrtowcs" = xyes
; then :
25797 cat >>confdefs.h
<<_ACEOF
25798 #define HAVE_DECL_MBSRTOWCS $ac_have_decl
25801 if test $ac_cv_have_decl_mbsrtowcs = yes; then
25802 REPLACE_MBSRTOWCS
=1
25805 if test $REPLACE_MBSTATE_T = 1; then
25806 REPLACE_MBSRTOWCS
=1
25814 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbsrtowcs works" >&5
25815 $as_echo_n "checking whether mbsrtowcs works... " >&6; }
25816 if ${gl_cv_func_mbsrtowcs_works+:} false
; then :
25817 $as_echo_n "(cached) " >&6
25821 # Guess no on HP-UX, Solaris, mingw.
25822 hpux
* | solaris
* | mingw
*) gl_cv_func_mbsrtowcs_works
="guessing no" ;;
25823 # Guess yes otherwise.
25824 *) gl_cv_func_mbsrtowcs_works
="guessing yes" ;;
25826 if test $LOCALE_FR != none ||
test $LOCALE_FR_UTF8 != none ||
test $LOCALE_JA != none ||
test $LOCALE_ZH_CN != none
; then
25827 if test "$cross_compiling" = yes; then :
25830 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
25831 /* end confdefs.h. */
25833 #include <locale.h>
25834 #include <string.h>
25839 /* Test whether the function supports a NULL destination argument.
25840 This fails on native Windows. */
25841 if (setlocale (LC_ALL, "$LOCALE_FR") != NULL)
25843 const char input[] = "\337er";
25844 const char *src = input;
25847 memset (&state, '\0', sizeof (mbstate_t));
25848 if (mbsrtowcs (NULL, &src, 1, &state) != 3
25852 /* Test whether the function works when started with a conversion state
25853 in non-initial state. This fails on HP-UX 11.11 and Solaris 10. */
25854 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
25856 const char input[] = "B\303\274\303\237er";
25859 memset (&state, '\0', sizeof (mbstate_t));
25860 if (mbrtowc (NULL, input + 1, 1, &state) == (size_t)(-2))
25861 if (!mbsinit (&state))
25863 const char *src = input + 2;
25864 if (mbsrtowcs (NULL, &src, 10, &state) != 4)
25868 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
25870 const char input[] = "<\306\374\313\334\270\354>";
25873 memset (&state, '\0', sizeof (mbstate_t));
25874 if (mbrtowc (NULL, input + 3, 1, &state) == (size_t)(-2))
25875 if (!mbsinit (&state))
25877 const char *src = input + 4;
25878 if (mbsrtowcs (NULL, &src, 10, &state) != 3)
25882 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
25884 const char input[] = "B\250\271\201\060\211\070er";
25887 memset (&state, '\0', sizeof (mbstate_t));
25888 if (mbrtowc (NULL, input + 1, 1, &state) == (size_t)(-2))
25889 if (!mbsinit (&state))
25891 const char *src = input + 2;
25892 if (mbsrtowcs (NULL, &src, 10, &state) != 4)
25899 if ac_fn_c_try_run
"$LINENO"; then :
25900 gl_cv_func_mbsrtowcs_works
=yes
25902 gl_cv_func_mbsrtowcs_works
=no
25904 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
25905 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
25911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbsrtowcs_works" >&5
25912 $as_echo "$gl_cv_func_mbsrtowcs_works" >&6; }
25914 case "$gl_cv_func_mbsrtowcs_works" in
25916 *) REPLACE_MBSRTOWCS
=1 ;;
25921 if test $HAVE_MBSRTOWCS = 0 ||
test $REPLACE_MBSRTOWCS = 1; then
25930 gl_LIBOBJS
="$gl_LIBOBJS mbsrtowcs.$ac_objext"
25940 gl_LIBOBJS
="$gl_LIBOBJS mbsrtowcs-state.$ac_objext"
25957 $as_echo "#define GNULIB_TEST_MBSRTOWCS 1" >>confdefs.h
25964 for ac_func
in mbtowc
25966 ac_fn_c_check_func
"$LINENO" "mbtowc" "ac_cv_func_mbtowc"
25967 if test "x$ac_cv_func_mbtowc" = xyes
; then :
25968 cat >>confdefs.h
<<_ACEOF
25969 #define HAVE_MBTOWC 1
25975 if test $ac_cv_func_mbtowc = no
; then
25983 if test $HAVE_MBTOWC = 0 ||
test $REPLACE_MBTOWC = 1; then
25992 gl_LIBOBJS
="$gl_LIBOBJS mbtowc.$ac_objext"
26009 $as_echo "#define GNULIB_TEST_MBTOWC 1" >>confdefs.h
26014 if test $REPLACE_MEMCHR = 1; then
26023 gl_LIBOBJS
="$gl_LIBOBJS memchr.$ac_objext"
26026 for ac_header
in bp-sym.h
26028 ac_fn_c_check_header_mongrel
"$LINENO" "bp-sym.h" "ac_cv_header_bp_sym_h" "$ac_includes_default"
26029 if test "x$ac_cv_header_bp_sym_h" = xyes
; then :
26030 cat >>confdefs.h
<<_ACEOF
26031 #define HAVE_BP_SYM_H 1
26051 $as_echo "#define GNULIB_TEST_MEMCHR 1" >>confdefs.h
26057 if test $HAVE_DECL_MEMMEM = 1 && test $REPLACE_MEMMEM = 0; then
26058 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memmem works in linear time" >&5
26059 $as_echo_n "checking whether memmem works in linear time... " >&6; }
26060 if ${gl_cv_func_memmem_works_fast+:} false
; then :
26061 $as_echo_n "(cached) " >&6
26063 if test "$cross_compiling" = yes; then :
26064 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
26065 /* end confdefs.h. */
26067 #include <features.h>
26068 #ifdef __GNU_LIBRARY__
26069 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 9) || (__GLIBC__ > 2)) \
26070 && !defined __UCLIBC__
26075 #include <cygwin/version.h>
26076 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 0)
26082 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
26083 $EGREP "Lucky user" >/dev
/null
2>&1; then :
26084 gl_cv_func_memmem_works_fast
="guessing yes"
26086 gl_cv_func_memmem_works_fast
="$gl_cross_guess_normal"
26092 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
26093 /* end confdefs.h. */
26095 #include <signal.h> /* for signal */
26096 #include <string.h> /* for memmem */
26097 #include <stdlib.h> /* for malloc */
26098 #include <unistd.h> /* for alarm */
26099 static void quit (int sig) { _exit (sig + 128); }
26106 size_t m = 1000000;
26107 char *haystack = (char *) malloc (2 * m + 1);
26108 char *needle = (char *) malloc (m + 1);
26109 /* Failure to compile this test due to missing alarm is okay,
26110 since all such platforms (mingw) also lack memmem. */
26111 signal (SIGALRM, quit);
26113 /* Check for quadratic performance. */
26114 if (haystack && needle)
26116 memset (haystack, 'A', 2 * m);
26117 haystack[2 * m] = 'B';
26118 memset (needle, 'A', m);
26120 if (!memmem (haystack, 2 * m + 1, needle, m + 1))
26123 /* Free allocated memory, in case some sanitizer is watching. */
26132 if ac_fn_c_try_run
"$LINENO"; then :
26133 gl_cv_func_memmem_works_fast
=yes
26135 gl_cv_func_memmem_works_fast
=no
26137 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
26138 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
26143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memmem_works_fast" >&5
26144 $as_echo "$gl_cv_func_memmem_works_fast" >&6; }
26145 case "$gl_cv_func_memmem_works_fast" in
26153 if test $HAVE_MEMMEM = 0 ||
test $REPLACE_MEMMEM = 1; then
26162 gl_LIBOBJS
="$gl_LIBOBJS memmem.$ac_objext"
26169 for ac_func
in memmem
26171 ac_fn_c_check_func
"$LINENO" "memmem" "ac_cv_func_memmem"
26172 if test "x$ac_cv_func_memmem" = xyes
; then :
26173 cat >>confdefs.h
<<_ACEOF
26174 #define HAVE_MEMMEM 1
26180 if test $ac_cv_func_memmem = yes; then
26186 if test $ac_cv_have_decl_memmem = no
; then
26189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memmem works" >&5
26190 $as_echo_n "checking whether memmem works... " >&6; }
26191 if ${gl_cv_func_memmem_works_always+:} false
; then :
26192 $as_echo_n "(cached) " >&6
26194 if test "$cross_compiling" = yes; then :
26195 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
26196 /* end confdefs.h. */
26198 #ifdef __GNU_LIBRARY__
26199 #include <features.h>
26200 #if ((__GLIBC__ == 2 && ((__GLIBC_MINOR > 0 && __GLIBC_MINOR__ < 9) \
26201 || __GLIBC_MINOR__ > 12)) \
26202 || (__GLIBC__ > 2)) \
26203 || defined __UCLIBC__
26206 #elif defined __CYGWIN__
26207 #include <cygwin/version.h>
26208 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
26216 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
26217 $EGREP "Lucky user" >/dev
/null
2>&1; then :
26218 gl_cv_func_memmem_works_always
="guessing yes"
26220 gl_cv_func_memmem_works_always
="$gl_cross_guess_normal"
26226 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
26227 /* end confdefs.h. */
26229 #include <string.h> /* for memmem */
26230 #define P "_EF_BF_BD"
26231 #define HAYSTACK "F_BD_CE_BD" P P P P "_C3_88_20" P P P "_C3_A7_20" P
26232 #define NEEDLE P P P P P
26239 if (memmem (HAYSTACK, strlen (HAYSTACK), NEEDLE, strlen (NEEDLE)))
26241 /* Check for empty needle behavior. */
26243 const char *haystack = "AAA";
26244 if (memmem (haystack, 3, (const char *) 1, 0) != haystack)
26253 if ac_fn_c_try_run
"$LINENO"; then :
26254 gl_cv_func_memmem_works_always
=yes
26256 gl_cv_func_memmem_works_always
=no
26258 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
26259 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
26264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memmem_works_always" >&5
26265 $as_echo "$gl_cv_func_memmem_works_always" >&6; }
26266 case "$gl_cv_func_memmem_works_always" in
26275 if test $HAVE_MEMMEM = 0 ||
test $REPLACE_MEMMEM = 1; then
26284 gl_LIBOBJS
="$gl_LIBOBJS memmem.$ac_objext"
26298 $as_echo "#define GNULIB_TEST_MEMMEM 1" >>confdefs.h
26308 for ac_func
in mempcpy
26310 ac_fn_c_check_func
"$LINENO" "mempcpy" "ac_cv_func_mempcpy"
26311 if test "x$ac_cv_func_mempcpy" = xyes
; then :
26312 cat >>confdefs.h
<<_ACEOF
26313 #define HAVE_MEMPCPY 1
26319 if test $ac_cv_func_mempcpy = no
; then
26323 if test $HAVE_MEMPCPY = 0; then
26332 gl_LIBOBJS
="$gl_LIBOBJS mempcpy.$ac_objext"
26349 $as_echo "#define GNULIB_TEST_MEMPCPY 1" >>confdefs.h
26358 if test $ac_cv_have_decl_memrchr = no
; then
26359 HAVE_DECL_MEMRCHR
=0
26362 for ac_func
in memrchr
26364 ac_fn_c_check_func
"$LINENO" "memrchr" "ac_cv_func_memrchr"
26365 if test "x$ac_cv_func_memrchr" = xyes
; then :
26366 cat >>confdefs.h
<<_ACEOF
26367 #define HAVE_MEMRCHR 1
26374 if test $ac_cv_func_memrchr = no
; then
26383 gl_LIBOBJS
="$gl_LIBOBJS memrchr.$ac_objext"
26398 $as_echo "#define GNULIB_TEST_MEMRCHR 1" >>confdefs.h
26407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mkdir handles trailing slash" >&5
26408 $as_echo_n "checking whether mkdir handles trailing slash... " >&6; }
26409 if ${gl_cv_func_mkdir_trailing_slash_works+:} false
; then :
26410 $as_echo_n "(cached) " >&6
26412 rm -rf conftest.dir
26413 if test "$cross_compiling" = yes; then :
26415 # Guess yes on Linux systems.
26416 linux-
* | linux
) gl_cv_func_mkdir_trailing_slash_works
="guessing yes" ;;
26417 # Guess yes on glibc systems.
26418 *-gnu* | gnu
*) gl_cv_func_mkdir_trailing_slash_works
="guessing yes" ;;
26419 # Guess yes on MSVC, no on mingw.
26420 mingw
*) cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
26421 /* end confdefs.h. */
26428 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
26429 $EGREP "Known" >/dev
/null
2>&1; then :
26430 gl_cv_func_mkdir_trailing_slash_works
="guessing yes"
26432 gl_cv_func_mkdir_trailing_slash_works
="guessing no"
26437 # If we don't know, obey --enable-cross-guesses.
26438 *) gl_cv_func_mkdir_trailing_slash_works
="$gl_cross_guess_normal" ;;
26442 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
26443 /* end confdefs.h. */
26445 #include <sys/types.h>
26446 #include <sys/stat.h>
26454 return mkdir ("conftest.dir/", 0700);
26459 if ac_fn_c_try_run
"$LINENO"; then :
26460 gl_cv_func_mkdir_trailing_slash_works
=yes
26462 gl_cv_func_mkdir_trailing_slash_works
=no
26464 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
26465 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
26468 rm -rf conftest.dir
26471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mkdir_trailing_slash_works" >&5
26472 $as_echo "$gl_cv_func_mkdir_trailing_slash_works" >&6; }
26473 case "$gl_cv_func_mkdir_trailing_slash_works" in
26480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mkdir handles trailing dot" >&5
26481 $as_echo_n "checking whether mkdir handles trailing dot... " >&6; }
26482 if ${gl_cv_func_mkdir_trailing_dot_works+:} false
; then :
26483 $as_echo_n "(cached) " >&6
26485 rm -rf conftest.dir
26486 if test "$cross_compiling" = yes; then :
26488 # Guess yes on glibc systems.
26489 *-gnu* | gnu
*) gl_cv_func_mkdir_trailing_dot_works
="guessing yes" ;;
26490 # Guess yes on musl systems.
26491 *-musl*) gl_cv_func_mkdir_trailing_dot_works
="guessing yes" ;;
26492 # Guess no on native Windows.
26493 mingw
*) gl_cv_func_mkdir_trailing_dot_works
="guessing no" ;;
26494 # If we don't know, obey --enable-cross-guesses.
26495 *) gl_cv_func_mkdir_trailing_dot_works
="$gl_cross_guess_normal" ;;
26499 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
26500 /* end confdefs.h. */
26502 #include <sys/types.h>
26503 #include <sys/stat.h>
26511 return !mkdir ("conftest.dir/./", 0700);
26516 if ac_fn_c_try_run
"$LINENO"; then :
26517 gl_cv_func_mkdir_trailing_dot_works
=yes
26519 gl_cv_func_mkdir_trailing_dot_works
=no
26521 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
26522 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
26525 rm -rf conftest.dir
26529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mkdir_trailing_dot_works" >&5
26530 $as_echo "$gl_cv_func_mkdir_trailing_dot_works" >&6; }
26531 case "$gl_cv_func_mkdir_trailing_dot_works" in
26536 $as_echo "#define FUNC_MKDIR_DOT_BUG 1" >>confdefs.h
26541 if test $REPLACE_MKDIR = 1; then
26550 gl_LIBOBJS
="$gl_LIBOBJS mkdir.$ac_objext"
26564 $as_echo "#define GNULIB_TEST_MKDIR 1" >>confdefs.h
26570 for ac_func
in mkdtemp
26572 ac_fn_c_check_func
"$LINENO" "mkdtemp" "ac_cv_func_mkdtemp"
26573 if test "x$ac_cv_func_mkdtemp" = xyes
; then :
26574 cat >>confdefs.h
<<_ACEOF
26575 #define HAVE_MKDTEMP 1
26581 if test $ac_cv_func_mkdtemp = no
; then
26585 if test $HAVE_MKDTEMP = 0; then
26594 gl_LIBOBJS
="$gl_LIBOBJS mkdtemp.$ac_objext"
26610 $as_echo "#define GNULIB_TEST_MKDTEMP 1" >>confdefs.h
26620 if test $ac_cv_func_mkostemp != yes; then
26624 if test $HAVE_MKOSTEMP = 0; then
26633 gl_LIBOBJS
="$gl_LIBOBJS mkostemp.$ac_objext"
26640 cat >>confdefs.h
<<_ACEOF
26641 #define GNULIB_MKOSTEMP 1
26656 $as_echo "#define GNULIB_TEST_MKOSTEMP 1" >>confdefs.h
26661 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
26670 gl_LIBOBJS
="$gl_LIBOBJS msvc-inval.$ac_objext"
26674 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
26683 gl_LIBOBJS
="$gl_LIBOBJS msvc-nothrow.$ac_objext"
26688 cat >>confdefs.h
<<_ACEOF
26689 #define GNULIB_MSVC_NOTHROW 1
26705 if test $gl_cv_have_include_next = yes; then
26706 gl_cv_next_netdb_h
='<'netdb.h
'>'
26708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <netdb.h>" >&5
26709 $as_echo_n "checking absolute name of <netdb.h>... " >&6; }
26710 if ${gl_cv_next_netdb_h+:} false
; then :
26711 $as_echo_n "(cached) " >&6
26714 if test $ac_cv_header_netdb_h = yes; then
26719 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
26720 /* end confdefs.h. */
26724 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
26725 *) gl_absname_cpp
="$ac_cpp" ;;
26730 gl_dirsep_regex
='[/\\]'
26733 gl_dirsep_regex
='\/'
26736 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
26737 gl_header_literal_regex
=`echo 'netdb.h' \
26738 | sed -e "$gl_make_literal_regex_sed"`
26739 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26740 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26746 gl_cv_absolute_netdb_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26747 sed -n "$gl_absolute_header_sed"`
26749 gl_header
=$gl_cv_absolute_netdb_h
26750 gl_cv_next_netdb_h
='"'$gl_header'"'
26752 gl_cv_next_netdb_h
='<'netdb.h
'>'
26757 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_netdb_h" >&5
26758 $as_echo "$gl_cv_next_netdb_h" >&6; }
26760 NEXT_NETDB_H
=$gl_cv_next_netdb_h
26762 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
26763 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26764 gl_next_as_first_directive
='<'netdb.h
'>'
26766 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26767 gl_next_as_first_directive
=$gl_cv_next_netdb_h
26769 NEXT_AS_FIRST_DIRECTIVE_NETDB_H
=$gl_next_as_first_directive
26774 if test $ac_cv_header_netdb_h = yes; then
26786 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <netinet/in.h> is self-contained" >&5
26787 $as_echo_n "checking whether <netinet/in.h> is self-contained... " >&6; }
26788 if ${gl_cv_header_netinet_in_h_selfcontained+:} false
; then :
26789 $as_echo_n "(cached) " >&6
26792 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
26793 /* end confdefs.h. */
26794 #include <netinet/in.h>
26803 if ac_fn_c_try_compile
"$LINENO"; then :
26804 gl_cv_header_netinet_in_h_selfcontained
=yes
26806 gl_cv_header_netinet_in_h_selfcontained
=no
26808 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
26811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_netinet_in_h_selfcontained" >&5
26812 $as_echo "$gl_cv_header_netinet_in_h_selfcontained" >&6; }
26813 if test $gl_cv_header_netinet_in_h_selfcontained = yes; then
26816 NETINET_IN_H
='netinet/in.h'
26817 for ac_header
in netinet
/in.h
26819 ac_fn_c_check_header_mongrel
"$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
26820 if test "x$ac_cv_header_netinet_in_h" = xyes
; then :
26821 cat >>confdefs.h
<<_ACEOF
26822 #define HAVE_NETINET_IN_H 1
26838 if test $gl_cv_have_include_next = yes; then
26839 gl_cv_next_netinet_in_h
='<'netinet
/in.h
'>'
26841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <netinet/in.h>" >&5
26842 $as_echo_n "checking absolute name of <netinet/in.h>... " >&6; }
26843 if ${gl_cv_next_netinet_in_h+:} false
; then :
26844 $as_echo_n "(cached) " >&6
26847 if test $ac_cv_header_netinet_in_h = yes; then
26852 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
26853 /* end confdefs.h. */
26854 #include <netinet/in.h>
26857 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
26858 *) gl_absname_cpp
="$ac_cpp" ;;
26863 gl_dirsep_regex
='[/\\]'
26866 gl_dirsep_regex
='\/'
26869 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
26870 gl_header_literal_regex
=`echo 'netinet/in.h' \
26871 | sed -e "$gl_make_literal_regex_sed"`
26872 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26873 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26879 gl_cv_absolute_netinet_in_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26880 sed -n "$gl_absolute_header_sed"`
26882 gl_header
=$gl_cv_absolute_netinet_in_h
26883 gl_cv_next_netinet_in_h
='"'$gl_header'"'
26885 gl_cv_next_netinet_in_h
='<'netinet
/in.h
'>'
26890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_netinet_in_h" >&5
26891 $as_echo "$gl_cv_next_netinet_in_h" >&6; }
26893 NEXT_NETINET_IN_H
=$gl_cv_next_netinet_in_h
26895 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
26896 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26897 gl_next_as_first_directive
='<'netinet
/in.h
'>'
26899 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26900 gl_next_as_first_directive
=$gl_cv_next_netinet_in_h
26902 NEXT_AS_FIRST_DIRECTIVE_NETINET_IN_H
=$gl_next_as_first_directive
26907 if test $ac_cv_header_netinet_in_h = yes; then
26908 HAVE_NETINET_IN_H
=1
26910 HAVE_NETINET_IN_H
=0
26915 if test -n "$NETINET_IN_H"; then
26916 GL_GENERATE_NETINET_IN_H_TRUE
=
26917 GL_GENERATE_NETINET_IN_H_FALSE
='#'
26919 GL_GENERATE_NETINET_IN_H_TRUE
='#'
26920 GL_GENERATE_NETINET_IN_H_FALSE
=
26934 if test "$gl_cv_macro_O_CLOEXEC" != yes; then
26939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether open recognizes a trailing slash" >&5
26940 $as_echo_n "checking whether open recognizes a trailing slash... " >&6; }
26941 if ${gl_cv_func_open_slash+:} false
; then :
26942 $as_echo_n "(cached) " >&6
26944 # Assume that if we have lstat, we can also check symlinks.
26945 if test $ac_cv_func_lstat = yes; then
26947 ln -s conftest.tmp conftest.lnk
26949 if test "$cross_compiling" = yes; then :
26952 freebsd
* | aix
* | hpux
* | solaris2.
[0-9] | solaris2.
[0-9].
*)
26953 gl_cv_func_open_slash
="guessing no" ;;
26955 gl_cv_func_open_slash
="guessing yes" ;;
26959 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
26960 /* end confdefs.h. */
26964 # include <unistd.h>
26974 if (open ("conftest.lnk/", O_RDONLY) != -1)
26977 if (open ("conftest.sl/", O_CREAT, 0600) >= 0)
26982 if ac_fn_c_try_run
"$LINENO"; then :
26983 gl_cv_func_open_slash
=yes
26985 gl_cv_func_open_slash
=no
26987 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
26988 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
26991 rm -f conftest.sl conftest.tmp conftest.lnk
26994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_open_slash" >&5
26995 $as_echo "$gl_cv_func_open_slash" >&6; }
26996 case "$gl_cv_func_open_slash" in
26999 $as_echo "#define OPEN_TRAILING_SLASH_BUG 1" >>confdefs.h
27004 case "$gl_cv_func_open_slash" in
27012 if test $REPLACE_OPEN = 0; then
27016 if test $ac_cv_func_fchdir = no
; then
27020 if test $HAVE_FCHDIR = 0; then
27027 if test $REPLACE_OPEN = 1; then
27036 gl_LIBOBJS
="$gl_LIBOBJS open.$ac_objext"
27054 $as_echo "#define GNULIB_TEST_OPEN 1" >>confdefs.h
27064 case $ac_cv_func_openat+$gl_cv_func_lstat_dereferences_slashed_symlink+$gl_cv_macro_O_CLOEXEC in
27068 # Solaris 10 lacks O_CLOEXEC.
27069 # Solaris 9 has *at functions, but uniformly mishandles trailing
27070 # slash in all of them.
27078 if test $HAVE_OPENAT = 0 ||
test $REPLACE_OPENAT = 1; then
27087 gl_LIBOBJS
="$gl_LIBOBJS openat.$ac_objext"
27096 cat >>confdefs.h
<<_ACEOF
27097 #define GNULIB_OPENAT 1
27111 $as_echo "#define GNULIB_TEST_OPENAT 1" >>confdefs.h
27118 for ac_func
in opendir
27120 ac_fn_c_check_func
"$LINENO" "opendir" "ac_cv_func_opendir"
27121 if test "x$ac_cv_func_opendir" = xyes
; then :
27122 cat >>confdefs.h
<<_ACEOF
27123 #define HAVE_OPENDIR 1
27129 if test $ac_cv_func_opendir = no
; then
27136 if test $ac_cv_func_fchdir = no
; then
27140 if test $HAVE_FCHDIR = 0; then
27141 if test $HAVE_OPENDIR = 1; then
27146 case $host_os,$HAVE_OPENDIR in
27148 REPLACE_OPENDIR
=1;;
27151 if test $HAVE_OPENDIR = 0 ||
test $REPLACE_OPENDIR = 1; then
27160 gl_LIBOBJS
="$gl_LIBOBJS opendir.$ac_objext"
27174 $as_echo "#define GNULIB_TEST_OPENDIR 1" >>confdefs.h
27185 if test $ac_cv_func_pipe != yes; then
27189 if test $HAVE_PIPE = 0; then
27198 gl_LIBOBJS
="$gl_LIBOBJS pipe.$ac_objext"
27212 $as_echo "#define GNULIB_TEST_PIPE 1" >>confdefs.h
27220 for ac_func
in rawmemchr
27222 ac_fn_c_check_func
"$LINENO" "rawmemchr" "ac_cv_func_rawmemchr"
27223 if test "x$ac_cv_func_rawmemchr" = xyes
; then :
27224 cat >>confdefs.h
<<_ACEOF
27225 #define HAVE_RAWMEMCHR 1
27231 if test $ac_cv_func_rawmemchr = no
; then
27235 if test $HAVE_RAWMEMCHR = 0; then
27244 gl_LIBOBJS
="$gl_LIBOBJS rawmemchr.$ac_objext"
27259 $as_echo "#define GNULIB_TEST_RAWMEMCHR 1" >>confdefs.h
27266 for ac_func
in readdir
27268 ac_fn_c_check_func
"$LINENO" "readdir" "ac_cv_func_readdir"
27269 if test "x$ac_cv_func_readdir" = xyes
; then :
27270 cat >>confdefs.h
<<_ACEOF
27271 #define HAVE_READDIR 1
27277 if test $ac_cv_func_readdir = no
; then
27281 if test $HAVE_READDIR = 0; then
27290 gl_LIBOBJS
="$gl_LIBOBJS readdir.$ac_objext"
27304 $as_echo "#define GNULIB_TEST_READDIR 1" >>confdefs.h
27311 if test $ac_cv_func_readlink = no
; then
27314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
27315 $as_echo_n "checking whether readlink signature is correct... " >&6; }
27316 if ${gl_cv_decl_readlink_works+:} false
; then :
27317 $as_echo_n "(cached) " >&6
27319 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
27320 /* end confdefs.h. */
27321 #include <unistd.h>
27322 /* Cause compilation failure if original declaration has wrong type. */
27323 ssize_t readlink (const char *, char *, size_t);
27332 if ac_fn_c_try_compile
"$LINENO"; then :
27333 gl_cv_decl_readlink_works
=yes
27335 gl_cv_decl_readlink_works
=no
27337 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
27339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
27340 $as_echo "$gl_cv_decl_readlink_works" >&6; }
27341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
27342 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
27343 if ${gl_cv_func_readlink_trailing_slash+:} false
; then :
27344 $as_echo_n "(cached) " >&6
27346 # We have readlink, so assume ln -s works.
27347 ln -s conftest.no-such conftest.link
27348 ln -s conftest.link conftest.lnk2
27349 if test "$cross_compiling" = yes; then :
27351 # Guess yes on Linux or glibc systems.
27352 linux-
* | linux |
*-gnu* | gnu
*)
27353 gl_cv_func_readlink_trailing_slash
="guessing yes" ;;
27354 # Guess no on AIX or HP-UX.
27356 gl_cv_func_readlink_trailing_slash
="guessing no" ;;
27357 # If we don't know, obey --enable-cross-guesses.
27359 gl_cv_func_readlink_trailing_slash
="$gl_cross_guess_normal" ;;
27363 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
27364 /* end confdefs.h. */
27365 #include <unistd.h>
27371 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
27376 if ac_fn_c_try_run
"$LINENO"; then :
27377 gl_cv_func_readlink_trailing_slash
=yes
27379 gl_cv_func_readlink_trailing_slash
=no
27381 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
27382 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
27385 rm -f conftest.link conftest.lnk2
27387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_trailing_slash" >&5
27388 $as_echo "$gl_cv_func_readlink_trailing_slash" >&6; }
27389 case "$gl_cv_func_readlink_trailing_slash" in
27391 if test "$gl_cv_decl_readlink_works" != yes; then
27397 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
27403 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink truncates results correctly" >&5
27404 $as_echo_n "checking whether readlink truncates results correctly... " >&6; }
27405 if ${gl_cv_func_readlink_truncate+:} false
; then :
27406 $as_echo_n "(cached) " >&6
27408 # We have readlink, so assume ln -s works.
27409 ln -s ab conftest.link
27410 if test "$cross_compiling" = yes; then :
27412 # Guess yes on Linux or glibc systems.
27413 linux-
* | linux |
*-gnu* | gnu
*)
27414 gl_cv_func_readlink_truncate
="guessing yes" ;;
27415 # Guess no on AIX or HP-UX.
27417 gl_cv_func_readlink_truncate
="guessing no" ;;
27418 # If we don't know, obey --enable-cross-guesses.
27420 gl_cv_func_readlink_truncate
="$gl_cross_guess_normal" ;;
27424 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
27425 /* end confdefs.h. */
27426 #include <unistd.h>
27432 return readlink ("conftest.link", &c, 1) != 1;
27437 if ac_fn_c_try_run
"$LINENO"; then :
27438 gl_cv_func_readlink_truncate
=yes
27440 gl_cv_func_readlink_truncate
=no
27442 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
27443 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
27446 rm -f conftest.link conftest.lnk2
27448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_truncate" >&5
27449 $as_echo "$gl_cv_func_readlink_truncate" >&6; }
27450 case $gl_cv_func_readlink_truncate in
27452 if test "$gl_cv_decl_readlink_works" != yes; then
27458 $as_echo "#define READLINK_TRUNCATE_BUG 1" >>confdefs.h
27465 if test $HAVE_READLINK = 0 ||
test $REPLACE_READLINK = 1; then
27474 gl_LIBOBJS
="$gl_LIBOBJS readlink.$ac_objext"
27491 $as_echo "#define GNULIB_TEST_READLINK 1" >>confdefs.h
27498 if test $gl_cv_func_malloc_posix = yes; then
27500 $as_echo "#define HAVE_REALLOC_POSIX 1" >>confdefs.h
27506 if test $REPLACE_REALLOC = 1; then
27515 gl_LIBOBJS
="$gl_LIBOBJS realloc.$ac_objext"
27523 GNULIB_REALLOC_POSIX
=1
27529 $as_echo "#define GNULIB_TEST_REALLOC_POSIX 1" >>confdefs.h
27538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename honors trailing slash on destination" >&5
27539 $as_echo_n "checking whether rename honors trailing slash on destination... " >&6; }
27540 if ${gl_cv_func_rename_slash_dst_works+:} false
; then :
27541 $as_echo_n "(cached) " >&6
27543 rm -rf conftest.f conftest.f1 conftest.f2 conftest.d1 conftest.d2 conftest.lnk
27544 touch conftest.f
&& touch conftest.f1
&& mkdir conftest.d1 ||
27545 as_fn_error $?
"cannot create temporary files" "$LINENO" 5
27546 # Assume that if we have lstat, we can also check symlinks.
27547 if test $ac_cv_func_lstat = yes; then
27548 ln -s conftest.f conftest.lnk
27550 if test "$cross_compiling" = yes; then :
27552 # Guess yes on Linux systems.
27553 linux-
* | linux
) gl_cv_func_rename_slash_dst_works
="guessing yes" ;;
27554 # Guess yes on glibc systems.
27555 *-gnu*) gl_cv_func_rename_slash_dst_works
="guessing yes" ;;
27556 # Guess no on native Windows.
27557 mingw
*) gl_cv_func_rename_slash_dst_works
="guessing no" ;;
27558 # If we don't know, obey --enable-cross-guesses.
27559 *) gl_cv_func_rename_slash_dst_works
="$gl_cross_guess_normal" ;;
27563 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
27564 /* end confdefs.h. */
27566 # include <stdio.h>
27567 # include <stdlib.h>
27573 if (rename ("conftest.f1", "conftest.f2/") == 0)
27575 if (rename ("conftest.d1", "conftest.d2/") != 0)
27578 if (rename ("conftest.f", "conftest.lnk/") == 0)
27587 if ac_fn_c_try_run
"$LINENO"; then :
27588 gl_cv_func_rename_slash_dst_works
=yes
27590 gl_cv_func_rename_slash_dst_works
=no
27592 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
27593 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
27596 rm -rf conftest.f conftest.f1 conftest.f2 conftest.d1 conftest.d2 conftest.lnk
27599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_slash_dst_works" >&5
27600 $as_echo "$gl_cv_func_rename_slash_dst_works" >&6; }
27601 case "$gl_cv_func_rename_slash_dst_works" in
27606 $as_echo "#define RENAME_TRAILING_SLASH_DEST_BUG 1" >>confdefs.h
27611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename honors trailing slash on source" >&5
27612 $as_echo_n "checking whether rename honors trailing slash on source... " >&6; }
27613 if ${gl_cv_func_rename_slash_src_works+:} false
; then :
27614 $as_echo_n "(cached) " >&6
27616 rm -rf conftest.f conftest.f1 conftest.d1 conftest.d2 conftest.d3 conftest.lnk
27617 touch conftest.f
&& touch conftest.f1
&& mkdir conftest.d1 ||
27618 as_fn_error $?
"cannot create temporary files" "$LINENO" 5
27619 # Assume that if we have lstat, we can also check symlinks.
27620 if test $ac_cv_func_lstat = yes; then
27621 ln -s conftest.f conftest.lnk
27623 if test "$cross_compiling" = yes; then :
27625 # Guess yes on Linux systems.
27626 linux-
* | linux
) gl_cv_func_rename_slash_src_works
="guessing yes" ;;
27627 # Guess yes on glibc systems.
27628 *-gnu*) gl_cv_func_rename_slash_src_works
="guessing yes" ;;
27629 # Guess yes on native Windows.
27630 mingw
*) gl_cv_func_rename_slash_src_works
="guessing yes" ;;
27631 # If we don't know, obey --enable-cross-guesses.
27632 *) gl_cv_func_rename_slash_src_works
="$gl_cross_guess_normal" ;;
27636 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
27637 /* end confdefs.h. */
27639 # include <stdio.h>
27640 # include <stdlib.h>
27646 if (rename ("conftest.f1/", "conftest.d3") == 0)
27648 if (rename ("conftest.d1/", "conftest.d2") != 0)
27651 if (rename ("conftest.lnk/", "conftest.f") == 0)
27660 if ac_fn_c_try_run
"$LINENO"; then :
27661 gl_cv_func_rename_slash_src_works
=yes
27663 gl_cv_func_rename_slash_src_works
=no
27665 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
27666 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
27669 rm -rf conftest.f conftest.f1 conftest.d1 conftest.d2 conftest.d3 conftest.lnk
27672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_slash_src_works" >&5
27673 $as_echo "$gl_cv_func_rename_slash_src_works" >&6; }
27674 case "$gl_cv_func_rename_slash_src_works" in
27679 $as_echo "#define RENAME_TRAILING_SLASH_SOURCE_BUG 1" >>confdefs.h
27685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename manages hard links correctly" >&5
27686 $as_echo_n "checking whether rename manages hard links correctly... " >&6; }
27687 if ${gl_cv_func_rename_link_works+:} false
; then :
27688 $as_echo_n "(cached) " >&6
27690 if test $ac_cv_func_link = yes; then
27691 if test $cross_compiling != yes; then
27692 rm -rf conftest.f conftest.f1 conftest.f2
27693 if touch conftest.f conftest.f2
&& ln conftest.f conftest.f1
&&
27694 set x
`ls -i conftest.f conftest.f1` && test "" = ""; then
27695 if test "$cross_compiling" = yes; then :
27699 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
27700 /* end confdefs.h. */
27702 # include <errno.h>
27703 # include <stdio.h>
27704 # include <stdlib.h>
27705 # include <unistd.h>
27714 if (rename ("conftest.f", "conftest.f1"))
27716 if (unlink ("conftest.f1"))
27719 /* Allow either the POSIX-required behavior, where the
27720 previous rename kept conftest.f, or the (better) NetBSD
27721 behavior, where it removed conftest.f. */
27722 if (rename ("conftest.f", "conftest.f") != 0
27723 && errno != ENOENT)
27726 if (rename ("conftest.f1", "conftest.f1") == 0)
27728 if (rename ("conftest.f2", "conftest.f2") != 0)
27736 if ac_fn_c_try_run
"$LINENO"; then :
27737 gl_cv_func_rename_link_works
=yes
27739 gl_cv_func_rename_link_works
=no
27741 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
27742 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
27746 gl_cv_func_rename_link_works
="guessing no"
27748 rm -rf conftest.f conftest.f1 conftest.f2
27751 # Guess yes on Linux systems.
27752 linux-
* | linux
) gl_cv_func_rename_link_works
="guessing yes" ;;
27753 # Guess yes on glibc systems.
27754 *-gnu*) gl_cv_func_rename_link_works
="guessing yes" ;;
27755 # Guess yes on native Windows.
27756 mingw
*) gl_cv_func_rename_link_works
="guessing yes" ;;
27757 # If we don't know, obey --enable-cross-guesses.
27758 *) gl_cv_func_rename_link_works
="$gl_cross_guess_normal" ;;
27762 gl_cv_func_rename_link_works
=yes
27766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_link_works" >&5
27767 $as_echo "$gl_cv_func_rename_link_works" >&6; }
27768 case "$gl_cv_func_rename_link_works" in
27773 $as_echo "#define RENAME_HARD_LINK_BUG 1" >>confdefs.h
27778 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename manages existing destinations correctly" >&5
27779 $as_echo_n "checking whether rename manages existing destinations correctly... " >&6; }
27780 if ${gl_cv_func_rename_dest_works+:} false
; then :
27781 $as_echo_n "(cached) " >&6
27783 rm -rf conftest.f conftest.d1 conftest.d2
27784 touch conftest.f
&& mkdir conftest.d1 conftest.d2 ||
27785 as_fn_error $?
"cannot create temporary files" "$LINENO" 5
27786 if test "$cross_compiling" = yes; then :
27788 # Guess yes on Linux systems.
27789 linux-
* | linux
) gl_cv_func_rename_dest_works
="guessing yes" ;;
27790 # Guess yes on glibc systems.
27791 *-gnu*) gl_cv_func_rename_dest_works
="guessing yes" ;;
27792 # Guess no on native Windows.
27793 mingw
*) gl_cv_func_rename_dest_works
="guessing no" ;;
27794 # If we don't know, obey --enable-cross-guesses.
27795 *) gl_cv_func_rename_dest_works
="$gl_cross_guess_normal" ;;
27799 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
27800 /* end confdefs.h. */
27802 # include <stdio.h>
27803 # include <stdlib.h>
27809 if (rename ("conftest.d1", "conftest.d2") != 0)
27811 if (rename ("conftest.d2", "conftest.f") == 0)
27819 if ac_fn_c_try_run
"$LINENO"; then :
27820 gl_cv_func_rename_dest_works
=yes
27822 gl_cv_func_rename_dest_works
=no
27824 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
27825 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
27828 rm -rf conftest.f conftest.d1 conftest.d2
27831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_dest_works" >&5
27832 $as_echo "$gl_cv_func_rename_dest_works" >&6; }
27833 case "$gl_cv_func_rename_dest_works" in
27838 $as_echo "#define RENAME_DEST_EXISTS_BUG 1" >>confdefs.h
27843 if test $REPLACE_RENAME = 1; then
27852 gl_LIBOBJS
="$gl_LIBOBJS rename.$ac_objext"
27866 $as_echo "#define GNULIB_TEST_RENAME 1" >>confdefs.h
27873 for ac_func
in rewinddir
27875 ac_fn_c_check_func
"$LINENO" "rewinddir" "ac_cv_func_rewinddir"
27876 if test "x$ac_cv_func_rewinddir" = xyes
; then :
27877 cat >>confdefs.h
<<_ACEOF
27878 #define HAVE_REWINDDIR 1
27884 if test $ac_cv_func_rewinddir = no
; then
27888 if test $HAVE_REWINDDIR = 0; then
27897 gl_LIBOBJS
="$gl_LIBOBJS rewinddir.$ac_objext"
27911 $as_echo "#define GNULIB_TEST_REWINDDIR 1" >>confdefs.h
27918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rmdir works" >&5
27919 $as_echo_n "checking whether rmdir works... " >&6; }
27920 if ${gl_cv_func_rmdir_works+:} false
; then :
27921 $as_echo_n "(cached) " >&6
27924 touch conftest.
file
27925 if test "$cross_compiling" = yes; then :
27927 # Guess yes on Linux systems.
27928 linux-
* | linux
) gl_cv_func_rmdir_works
="guessing yes" ;;
27929 # Guess yes on glibc systems.
27930 *-gnu* | gnu
*) gl_cv_func_rmdir_works
="guessing yes" ;;
27931 # Guess no on native Windows.
27932 mingw
*) gl_cv_func_rmdir_works
="guessing no" ;;
27933 # If we don't know, obey --enable-cross-guesses.
27934 *) gl_cv_func_rmdir_works
="$gl_cross_guess_normal" ;;
27938 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
27939 /* end confdefs.h. */
27943 # include <unistd.h>
27944 #else /* on Windows with MSVC */
27945 # include <direct.h>
27955 if (!rmdir ("conftest.file/"))
27957 else if (errno != ENOTDIR)
27959 if (!rmdir ("conftest.dir/./"))
27967 if ac_fn_c_try_run
"$LINENO"; then :
27968 gl_cv_func_rmdir_works
=yes
27970 gl_cv_func_rmdir_works
=no
27972 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
27973 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
27976 rm -rf conftest.dir conftest.
file
27978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rmdir_works" >&5
27979 $as_echo "$gl_cv_func_rmdir_works" >&6; }
27980 case "$gl_cv_func_rmdir_works" in
27987 if test $REPLACE_RMDIR = 1; then
27996 gl_LIBOBJS
="$gl_LIBOBJS rmdir.$ac_objext"
28010 $as_echo "#define GNULIB_TEST_RMDIR 1" >>confdefs.h
28021 if test "$ac_cv_header_winsock2_h" = yes; then
28025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether select supports a 0 argument" >&5
28026 $as_echo_n "checking whether select supports a 0 argument... " >&6; }
28027 if ${gl_cv_func_select_supports0+:} false
; then :
28028 $as_echo_n "(cached) " >&6
28031 if test "$cross_compiling" = yes; then :
28034 # Guess no on Interix.
28035 interix
*) gl_cv_func_select_supports0
="guessing no";;
28036 # Guess yes otherwise.
28037 *) gl_cv_func_select_supports0
="guessing yes";;
28041 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
28042 /* end confdefs.h. */
28044 #include <sys/types.h>
28045 #include <sys/time.h>
28046 #if HAVE_SYS_SELECT_H
28047 #include <sys/select.h>
28051 struct timeval timeout;
28052 timeout.tv_sec = 0;
28053 timeout.tv_usec = 5;
28054 return select (0, (fd_set *)0, (fd_set *)0, (fd_set *)0, &timeout) < 0;
28057 if ac_fn_c_try_run
"$LINENO"; then :
28058 gl_cv_func_select_supports0
=yes
28060 gl_cv_func_select_supports0
=no
28062 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
28063 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
28068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_select_supports0" >&5
28069 $as_echo "$gl_cv_func_select_supports0" >&6; }
28070 case "$gl_cv_func_select_supports0" in
28072 *) REPLACE_SELECT
=1 ;;
28075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether select detects invalid fds" >&5
28076 $as_echo_n "checking whether select detects invalid fds... " >&6; }
28077 if ${gl_cv_func_select_detects_ebadf+:} false
; then :
28078 $as_echo_n "(cached) " >&6
28081 if test "$cross_compiling" = yes; then :
28084 # Guess yes on Linux systems.
28085 linux-
* | linux
) gl_cv_func_select_detects_ebadf
="guessing yes" ;;
28086 # Guess yes on glibc systems.
28087 *-gnu* | gnu
*) gl_cv_func_select_detects_ebadf
="guessing yes" ;;
28088 # If we don't know, obey --enable-cross-guesses.
28089 *) gl_cv_func_select_detects_ebadf
="$gl_cross_guess_normal" ;;
28093 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
28094 /* end confdefs.h. */
28096 #include <sys/types.h>
28097 #include <sys/time.h>
28098 #if HAVE_SYS_SELECT_H
28099 # include <sys/select.h>
28101 #include <unistd.h>
28116 struct timeval timeout;
28117 timeout.tv_sec = 0;
28118 timeout.tv_usec = 5;
28119 return select (17, &set, NULL, NULL, &timeout) != -1 || errno != EBADF;
28125 if ac_fn_c_try_run
"$LINENO"; then :
28126 gl_cv_func_select_detects_ebadf
=yes
28128 gl_cv_func_select_detects_ebadf
=no
28130 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
28131 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
28136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_select_detects_ebadf" >&5
28137 $as_echo "$gl_cv_func_select_detects_ebadf" >&6; }
28138 case $gl_cv_func_select_detects_ebadf in
28140 *) REPLACE_SELECT
=1 ;;
28144 LIB_SELECT
="$LIBSOCKET"
28145 if test $REPLACE_SELECT = 1; then
28148 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
28149 /* end confdefs.h. */
28151 #define WIN32_LEAN_AND_MEAN
28152 #include <windows.h>
28156 MsgWaitForMultipleObjects (0, NULL, 0, 0, 0);
28160 if ac_fn_c_try_link
"$LINENO"; then :
28163 LIB_SELECT
="$LIB_SELECT -luser32"
28165 rm -f core conftest.err conftest.
$ac_objext \
28166 conftest
$ac_exeext conftest.
$ac_ext
28172 if test $REPLACE_SELECT = 1; then
28181 gl_LIBOBJS
="$gl_LIBOBJS select.$ac_objext"
28195 $as_echo "#define GNULIB_TEST_SELECT 1" >>confdefs.h
28201 if test $ac_cv_func_setenv = no
; then
28204 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setenv validates arguments" >&5
28205 $as_echo_n "checking whether setenv validates arguments... " >&6; }
28206 if ${gl_cv_func_setenv_works+:} false
; then :
28207 $as_echo_n "(cached) " >&6
28209 if test "$cross_compiling" = yes; then :
28211 # Guess yes on glibc systems.
28212 *-gnu* | gnu
*) gl_cv_func_setenv_works
="guessing yes" ;;
28213 # Guess yes on musl systems.
28214 *-musl*) gl_cv_func_setenv_works
="guessing yes" ;;
28215 # If we don't know, obey --enable-cross-guesses.
28216 *) gl_cv_func_setenv_works
="$gl_cross_guess_normal" ;;
28220 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
28221 /* end confdefs.h. */
28223 #include <stdlib.h>
28225 #include <string.h>
28233 if (setenv ("", "", 0) != -1)
28235 else if (errno != EINVAL)
28239 if (setenv ("a", "=", 1) != 0)
28241 else if (strcmp (getenv ("a"), "=") != 0)
28250 if ac_fn_c_try_run
"$LINENO"; then :
28251 gl_cv_func_setenv_works
=yes
28253 gl_cv_func_setenv_works
=no
28255 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
28256 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
28260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_setenv_works" >&5
28261 $as_echo "$gl_cv_func_setenv_works" >&6; }
28262 case "$gl_cv_func_setenv_works" in
28270 if test $HAVE_SETENV = 0 ||
test $REPLACE_SETENV = 1; then
28279 gl_LIBOBJS
="$gl_LIBOBJS setenv.$ac_objext"
28293 $as_echo "#define GNULIB_TEST_SETENV 1" >>confdefs.h
28302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setlocale (LC_ALL, NULL) is multithread-safe" >&5
28303 $as_echo_n "checking whether setlocale (LC_ALL, NULL) is multithread-safe... " >&6; }
28304 if ${gl_cv_func_setlocale_null_all_mtsafe+:} false
; then :
28305 $as_echo_n "(cached) " >&6
28308 # Guess no on musl libc, macOS, FreeBSD, NetBSD, OpenBSD, AIX, Haiku, Cygwin.
28309 *-musl* | darwin
* | freebsd
* | netbsd
* | openbsd
* | aix
* | haiku
* | cygwin
*)
28310 gl_cv_func_setlocale_null_all_mtsafe
=no
;;
28311 # Guess yes on glibc, HP-UX, IRIX, Solaris, native Windows.
28312 *-gnu* | gnu
* | hpux
* | irix
* | solaris
* | mingw
*)
28313 gl_cv_func_setlocale_null_all_mtsafe
=yes ;;
28314 # If we don't know, obey --enable-cross-guesses.
28316 gl_cv_func_setlocale_null_all_mtsafe
="$gl_cross_guess_normal" ;;
28320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_setlocale_null_all_mtsafe" >&5
28321 $as_echo "$gl_cv_func_setlocale_null_all_mtsafe" >&6; }
28325 if test $gl_pthread_api = no
&& test $ac_cv_header_threads_h = no
; then
28326 gl_cv_func_setlocale_null_all_mtsafe
="trivially yes"
28330 case "$gl_cv_func_setlocale_null_all_mtsafe" in
28331 *yes) SETLOCALE_NULL_ALL_MTSAFE
=1 ;;
28332 *) SETLOCALE_NULL_ALL_MTSAFE
=0 ;;
28335 cat >>confdefs.h
<<_ACEOF
28336 #define SETLOCALE_NULL_ALL_MTSAFE $SETLOCALE_NULL_ALL_MTSAFE
28340 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setlocale (category, NULL) is multithread-safe" >&5
28341 $as_echo_n "checking whether setlocale (category, NULL) is multithread-safe... " >&6; }
28342 if ${gl_cv_func_setlocale_null_one_mtsafe+:} false
; then :
28343 $as_echo_n "(cached) " >&6
28346 # Guess no on OpenBSD, AIX.
28348 gl_cv_func_setlocale_null_one_mtsafe
=no
;;
28349 # Guess yes on glibc, musl libc, macOS, FreeBSD, NetBSD, HP-UX, IRIX, Solaris, Haiku, Cygwin, native Windows.
28350 *-gnu* | gnu
* |
*-musl* | darwin
* | freebsd
* | netbsd
* | hpux
* | irix
* | solaris
* | haiku
* | cygwin
* | mingw
*)
28351 gl_cv_func_setlocale_null_one_mtsafe
=yes ;;
28352 # If we don't know, obey --enable-cross-guesses.
28354 gl_cv_func_setlocale_null_one_mtsafe
="$gl_cross_guess_normal" ;;
28358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_setlocale_null_one_mtsafe" >&5
28359 $as_echo "$gl_cv_func_setlocale_null_one_mtsafe" >&6; }
28363 if test $gl_pthread_api = no
&& test $ac_cv_header_threads_h = no
; then
28364 gl_cv_func_setlocale_null_one_mtsafe
="trivially yes"
28368 case "$gl_cv_func_setlocale_null_one_mtsafe" in
28369 *yes) SETLOCALE_NULL_ONE_MTSAFE
=1 ;;
28370 *) SETLOCALE_NULL_ONE_MTSAFE
=0 ;;
28373 cat >>confdefs.h
<<_ACEOF
28374 #define SETLOCALE_NULL_ONE_MTSAFE $SETLOCALE_NULL_ONE_MTSAFE
28378 if test $SETLOCALE_NULL_ALL_MTSAFE = 0 ||
test $SETLOCALE_NULL_ONE_MTSAFE = 0; then
28380 mingw
*) LIB_SETLOCALE_NULL
= ;;
28384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether imported symbols can be declared weak" >&5
28385 $as_echo_n "checking whether imported symbols can be declared weak... " >&6; }
28386 if ${gl_cv_have_weak+:} false
; then :
28387 $as_echo_n "(cached) " >&6
28390 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
28391 /* end confdefs.h. */
28392 extern void xyzzy ();
28402 if ac_fn_c_try_link
"$LINENO"; then :
28403 gl_cv_have_weak
=maybe
28405 rm -f core conftest.err conftest.
$ac_objext \
28406 conftest
$ac_exeext conftest.
$ac_ext
28407 if test $gl_cv_have_weak = maybe
; then
28408 if test "$cross_compiling" = yes; then :
28409 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
28410 /* end confdefs.h. */
28412 Extensible Linking Format
28416 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28417 $EGREP "Extensible Linking Format" >/dev
/null
2>&1; then :
28418 gl_cv_have_weak
="guessing yes"
28420 gl_cv_have_weak
="guessing no"
28426 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
28427 /* end confdefs.h. */
28433 return (fputs == NULL);
28436 if ac_fn_c_try_run
"$LINENO"; then :
28437 gl_cv_have_weak
=yes
28441 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
28442 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
28446 case " $LDFLAGS " in
28447 *" -static "*) gl_cv_have_weak
=no
;;
28449 case "$gl_cv_have_weak" in
28452 freebsd
* | dragonfly
*)
28454 $CC $CPPFLAGS $CFLAGS $LDFLAGS -fPIC -shared -o libempty.so conftest1.c
-lpthread >&5 2>&1
28455 cat <<EOF > conftest2.c
28456 #include <pthread.h>
28457 #pragma weak pthread_mutexattr_gettype
28460 return (pthread_mutexattr_gettype != NULL);
28463 $CC $CPPFLAGS $CFLAGS $LDFLAGS -o conftest conftest2.c libempty.so
>&5 2>&1 \
28464 || gl_cv_have_weak
=no
28465 rm -f conftest1.c libempty.so conftest2.c conftest
28472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_weak" >&5
28473 $as_echo "$gl_cv_have_weak" >&6; }
28474 case "$gl_cv_have_weak" in
28477 $as_echo "#define HAVE_WEAK_SYMBOLS 1" >>confdefs.h
28482 case "$gl_cv_have_weak" in
28483 *yes) LIB_SETLOCALE_NULL
= ;;
28484 *) LIB_SETLOCALE_NULL
="$LIBPTHREAD" ;;
28489 LIB_SETLOCALE_NULL
=
28493 if test $SETLOCALE_NULL_ALL_MTSAFE = 0 ||
test $SETLOCALE_NULL_ONE_MTSAFE = 0; then
28502 gl_LIBOBJS
="$gl_LIBOBJS setlocale-lock.$ac_objext"
28509 if test -n "$GCC"; then
28510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the -Werror option is usable" >&5
28511 $as_echo_n "checking whether the -Werror option is usable... " >&6; }
28512 if ${gl_cv_cc_vis_werror+:} false
; then :
28513 $as_echo_n "(cached) " >&6
28515 gl_save_CFLAGS
="$CFLAGS"
28516 CFLAGS
="$CFLAGS -Werror"
28517 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
28518 /* end confdefs.h. */
28528 if ac_fn_c_try_compile
"$LINENO"; then :
28529 gl_cv_cc_vis_werror
=yes
28531 gl_cv_cc_vis_werror
=no
28533 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
28534 CFLAGS
="$gl_save_CFLAGS"
28537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_vis_werror" >&5
28538 $as_echo "$gl_cv_cc_vis_werror" >&6; }
28539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for simple visibility declarations" >&5
28540 $as_echo_n "checking for simple visibility declarations... " >&6; }
28541 if ${gl_cv_cc_visibility+:} false
; then :
28542 $as_echo_n "(cached) " >&6
28544 gl_save_CFLAGS
="$CFLAGS"
28545 CFLAGS
="$CFLAGS -fvisibility=hidden"
28546 if test $gl_cv_cc_vis_werror = yes; then
28547 CFLAGS
="$CFLAGS -Werror"
28549 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
28550 /* end confdefs.h. */
28551 extern __attribute__((__visibility__("hidden"))) int hiddenvar;
28552 extern __attribute__((__visibility__("default"))) int exportedvar;
28553 extern __attribute__((__visibility__("hidden"))) int hiddenfunc (void);
28554 extern __attribute__((__visibility__("default"))) int exportedfunc (void);
28555 void dummyfunc (void) {}
28565 if ac_fn_c_try_compile
"$LINENO"; then :
28566 gl_cv_cc_visibility
=yes
28568 gl_cv_cc_visibility
=no
28570 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
28571 CFLAGS
="$gl_save_CFLAGS"
28574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_visibility" >&5
28575 $as_echo "$gl_cv_cc_visibility" >&6; }
28576 if test $gl_cv_cc_visibility = yes; then
28577 CFLAG_VISIBILITY
="-fvisibility=hidden"
28584 cat >>confdefs.h
<<_ACEOF
28585 #define HAVE_VISIBILITY $HAVE_VISIBILITY
28596 GNULIB_SETLOCALE_NULL
=1
28602 $as_echo "#define GNULIB_TEST_SETLOCALE_NULL 1" >>confdefs.h
28617 if test $gl_cv_have_include_next = yes; then
28618 gl_cv_next_signal_h
='<'signal.h
'>'
28620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
28621 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
28622 if ${gl_cv_next_signal_h+:} false
; then :
28623 $as_echo_n "(cached) " >&6
28628 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
28629 /* end confdefs.h. */
28630 #include <signal.h>
28633 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
28634 *) gl_absname_cpp
="$ac_cpp" ;;
28639 gl_dirsep_regex
='[/\\]'
28642 gl_dirsep_regex
='\/'
28645 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
28646 gl_header_literal_regex
=`echo 'signal.h' \
28647 | sed -e "$gl_make_literal_regex_sed"`
28648 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
28649 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
28655 gl_cv_absolute_signal_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
28656 sed -n "$gl_absolute_header_sed"`
28658 gl_header
=$gl_cv_absolute_signal_h
28659 gl_cv_next_signal_h
='"'$gl_header'"'
28663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
28664 $as_echo "$gl_cv_next_signal_h" >&6; }
28666 NEXT_SIGNAL_H
=$gl_cv_next_signal_h
28668 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
28669 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
28670 gl_next_as_first_directive
='<'signal.h
'>'
28672 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
28673 gl_next_as_first_directive
=$gl_cv_next_signal_h
28675 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
=$gl_next_as_first_directive
28681 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
28682 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
28683 ac_fn_c_check_type
"$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
28684 #include <signal.h>
28687 if test "x$ac_cv_type_volatile_sig_atomic_t" = xyes
; then :
28690 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
=0
28699 ac_fn_c_check_type
"$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
28700 #include <signal.h>
28703 if test "x$ac_cv_type_sighandler_t" = xyes
; then :
28706 HAVE_SIGHANDLER_T
=0
28718 ac_fn_c_check_type
"$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
28719 /* <sys/types.h> is not needed according to POSIX, but the
28720 <sys/socket.h> in i386-unknown-freebsd4.10 and
28721 powerpc-apple-darwin5.5 required it. */
28722 #include <sys/types.h>
28723 #if HAVE_SYS_SOCKET_H
28724 # include <sys/socket.h>
28725 #elif HAVE_WS2TCPIP_H
28726 # include <ws2tcpip.h>
28730 if test "x$ac_cv_type_socklen_t" = xyes
; then :
28733 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
28734 $as_echo_n "checking for socklen_t equivalent... " >&6; }
28735 if ${gl_cv_socklen_t_equiv+:} false
; then :
28736 $as_echo_n "(cached) " >&6
28738 # Systems have either "struct sockaddr *" or
28739 # "void *" as the second argument to getpeername
28740 gl_cv_socklen_t_equiv
=
28741 for arg2
in "struct sockaddr" void
; do
28742 for t
in int size_t
"unsigned int" "long int" "unsigned long int"; do
28743 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
28744 /* end confdefs.h. */
28745 #include <sys/types.h>
28746 #include <sys/socket.h>
28748 int getpeername (int, $arg2 *, $t *);
28753 getpeername (0, 0, &len);
28758 if ac_fn_c_try_compile
"$LINENO"; then :
28759 gl_cv_socklen_t_equiv
="$t"
28761 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
28762 test "$gl_cv_socklen_t_equiv" != "" && break
28764 test "$gl_cv_socklen_t_equiv" != "" && break
28766 if test "$gl_cv_socklen_t_equiv" = ""; then
28767 as_fn_error $?
"Cannot find a type to use in place of socklen_t" "$LINENO" 5
28771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5
28772 $as_echo "$gl_cv_socklen_t_equiv" >&6; }
28774 cat >>confdefs.h
<<_ACEOF
28775 #define socklen_t $gl_cv_socklen_t_equiv
28781 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
28782 $as_echo_n "checking for ssize_t... " >&6; }
28783 if ${gt_cv_ssize_t+:} false
; then :
28784 $as_echo_n "(cached) " >&6
28786 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
28787 /* end confdefs.h. */
28788 #include <sys/types.h>
28792 int x = sizeof (ssize_t *) + sizeof (ssize_t);
28798 if ac_fn_c_try_compile
"$LINENO"; then :
28803 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
28805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
28806 $as_echo "$gt_cv_ssize_t" >&6; }
28807 if test $gt_cv_ssize_t = no
; then
28809 $as_echo "#define ssize_t int" >>confdefs.h
28821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
28822 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
28823 if ${gl_cv_func_stat_file_slash+:} false
; then :
28824 $as_echo_n "(cached) " >&6
28827 # Assume that if we have lstat, we can also check symlinks.
28828 if test $ac_cv_func_lstat = yes; then
28829 ln -s conftest.tmp conftest.lnk
28831 if test "$cross_compiling" = yes; then :
28833 # Guess yes on Linux systems.
28834 linux-
* | linux
) gl_cv_func_stat_file_slash
="guessing yes" ;;
28835 # Guess yes on glibc systems.
28836 *-gnu* | gnu
*) gl_cv_func_stat_file_slash
="guessing yes" ;;
28837 # If we don't know, obey --enable-cross-guesses.
28838 *) gl_cv_func_stat_file_slash
="$gl_cross_guess_normal" ;;
28842 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
28843 /* end confdefs.h. */
28844 #include <sys/stat.h>
28851 if (!stat ("conftest.tmp/", &st))
28854 if (!stat ("conftest.lnk/", &st))
28863 if ac_fn_c_try_run
"$LINENO"; then :
28864 gl_cv_func_stat_file_slash
=yes
28866 gl_cv_func_stat_file_slash
=no
28868 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
28869 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
28872 rm -f conftest.tmp conftest.lnk
28874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
28875 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
28876 case $gl_cv_func_stat_file_slash in
28880 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
28890 if test $REPLACE_STAT = 1; then
28899 gl_LIBOBJS
="$gl_LIBOBJS stat.$ac_objext"
28911 gl_LIBOBJS
="$gl_LIBOBJS stat-w32.$ac_objext"
28932 $as_echo "#define GNULIB_TEST_STAT 1" >>confdefs.h
28940 ac_fn_c_check_member
"$LINENO" "struct stat" "st_atim.tv_nsec" "ac_cv_member_struct_stat_st_atim_tv_nsec" "#include <sys/types.h>
28941 #include <sys/stat.h>
28943 if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = xyes
; then :
28945 cat >>confdefs.h
<<_ACEOF
28946 #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
28949 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
28950 $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
28951 if ${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+:} false
; then :
28952 $as_echo_n "(cached) " >&6
28954 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
28955 /* end confdefs.h. */
28957 #include <sys/types.h>
28958 #include <sys/stat.h>
28959 #if HAVE_SYS_TIME_H
28960 # include <sys/time.h>
28963 struct timespec ts;
28976 if ac_fn_c_try_compile
"$LINENO"; then :
28977 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec
=yes
28979 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec
=no
28981 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
28983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
28984 $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
28985 if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
28987 $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
28991 ac_fn_c_check_member
"$LINENO" "struct stat" "st_atimespec.tv_nsec" "ac_cv_member_struct_stat_st_atimespec_tv_nsec" "#include <sys/types.h>
28992 #include <sys/stat.h>
28994 if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = xyes
; then :
28996 cat >>confdefs.h
<<_ACEOF
28997 #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
29002 ac_fn_c_check_member
"$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
29003 #include <sys/stat.h>
29005 if test "x$ac_cv_member_struct_stat_st_atimensec" = xyes
; then :
29007 cat >>confdefs.h
<<_ACEOF
29008 #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
29013 ac_fn_c_check_member
"$LINENO" "struct stat" "st_atim.st__tim.tv_nsec" "ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" "#include <sys/types.h>
29014 #include <sys/stat.h>
29016 if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = xyes
; then :
29018 cat >>confdefs.h
<<_ACEOF
29019 #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
29035 ac_fn_c_check_member
"$LINENO" "struct stat" "st_birthtimespec.tv_nsec" "ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" "#include <sys/types.h>
29036 #include <sys/stat.h>
29038 if test "x$ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" = xyes
; then :
29040 cat >>confdefs.h
<<_ACEOF
29041 #define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
29046 ac_fn_c_check_member
"$LINENO" "struct stat" "st_birthtimensec" "ac_cv_member_struct_stat_st_birthtimensec" "#include <sys/types.h>
29047 #include <sys/stat.h>
29049 if test "x$ac_cv_member_struct_stat_st_birthtimensec" = xyes
; then :
29051 cat >>confdefs.h
<<_ACEOF
29052 #define HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC 1
29057 ac_fn_c_check_member
"$LINENO" "struct stat" "st_birthtim.tv_nsec" "ac_cv_member_struct_stat_st_birthtim_tv_nsec" "#include <sys/types.h>
29058 #include <sys/stat.h>
29060 if test "x$ac_cv_member_struct_stat_st_birthtim_tv_nsec" = xyes
; then :
29062 cat >>confdefs.h
<<_ACEOF
29063 #define HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC 1
29075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdalign.h" >&5
29076 $as_echo_n "checking for working stdalign.h... " >&6; }
29077 if ${gl_cv_header_working_stdalign_h+:} false
; then :
29078 $as_echo_n "(cached) " >&6
29080 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
29081 /* end confdefs.h. */
29082 #include <stdalign.h>
29083 #include <stddef.h>
29085 /* Test that alignof yields a result consistent with offsetof.
29086 This catches GCC bug 52023
29087 <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023>. */
29089 template <class t> struct alignof_helper { char a; t b; };
29090 # define ao(type) offsetof (alignof_helper<type>, b)
29092 # define ao(type) offsetof (struct { char a; type b; }, b)
29094 char test_double[ao (double) % _Alignof (double) == 0 ? 1 : -1];
29095 char test_long[ao (long int) % _Alignof (long int) == 0 ? 1 : -1];
29096 char test_alignof[alignof (double) == _Alignof (double) ? 1 : -1];
29098 /* Test _Alignas only on platforms where gnulib can help. */
29100 ((defined __cplusplus && 201103 <= __cplusplus) \
29101 || (defined __APPLE__ && defined __MACH__ \
29102 ? 4 < __GNUC__ + (1 <= __GNUC_MINOR__) \
29104 || (__ia64 && (61200 <= __HP_cc || 61200 <= __HP_aCC)) \
29105 || __ICC || 0x590 <= __SUNPRO_C || 0x0600 <= __xlC__ \
29106 || 1300 <= _MSC_VER)
29107 struct alignas_test { char c; char alignas (8) alignas_8; };
29108 char test_alignas[offsetof (struct alignas_test, alignas_8) == 8
29120 if ac_fn_c_try_compile
"$LINENO"; then :
29121 gl_cv_header_working_stdalign_h
=yes
29123 gl_cv_header_working_stdalign_h
=no
29125 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
29127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdalign_h" >&5
29128 $as_echo "$gl_cv_header_working_stdalign_h" >&6; }
29130 if test $gl_cv_header_working_stdalign_h = yes; then
29133 STDALIGN_H
='stdalign.h'
29137 if test -n "$STDALIGN_H"; then
29138 GL_GENERATE_STDALIGN_H_TRUE
=
29139 GL_GENERATE_STDALIGN_H_FALSE
='#'
29141 GL_GENERATE_STDALIGN_H_TRUE
='#'
29142 GL_GENERATE_STDALIGN_H_FALSE
=
29150 if test "$ac_cv_header_stdbool_h" = yes; then
29153 if test -z "$GCC"; then
29154 STDBOOL_H
='stdbool.h'
29164 STDBOOL_H
='stdbool.h'
29167 if test -n "$STDBOOL_H"; then
29168 GL_GENERATE_STDBOOL_H_TRUE
=
29169 GL_GENERATE_STDBOOL_H_FALSE
='#'
29171 GL_GENERATE_STDBOOL_H_TRUE
='#'
29172 GL_GENERATE_STDBOOL_H_FALSE
=
29176 if test "$ac_cv_type__Bool" = yes; then
29191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for good max_align_t" >&5
29192 $as_echo_n "checking for good max_align_t... " >&6; }
29193 if ${gl_cv_type_max_align_t+:} false
; then :
29194 $as_echo_n "(cached) " >&6
29196 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
29197 /* end confdefs.h. */
29198 #include <stddef.h>
29199 unsigned int s = sizeof (max_align_t);
29200 #if defined __GNUC__ || defined __clang__ || defined __IBM__ALIGNOF__
29201 int check1[2 * (__alignof__ (double) <= __alignof__ (max_align_t)) - 1];
29202 int check2[2 * (__alignof__ (long double) <= __alignof__ (max_align_t)) - 1];
29204 typedef struct { char a; max_align_t b; } max_helper;
29205 typedef struct { char a; long b; } long_helper;
29206 typedef struct { char a; double b; } double_helper;
29207 typedef struct { char a; long double b; } long_double_helper;
29208 int check3[2 * (offsetof (long_helper, b) <= offsetof (max_helper, b)) - 1];
29209 int check4[2 * (offsetof (double_helper, b) <= offsetof (max_helper, b)) - 1];
29210 int check5[2 * (offsetof (long_double_helper, b) <= offsetof (max_helper, b)) - 1];
29220 if ac_fn_c_try_compile
"$LINENO"; then :
29221 gl_cv_type_max_align_t
=yes
29223 gl_cv_type_max_align_t
=no
29225 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
29228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_max_align_t" >&5
29229 $as_echo "$gl_cv_type_max_align_t" >&6; }
29230 if test $gl_cv_type_max_align_t = no
; then
29235 if test $gt_cv_c_wchar_t = no
; then
29240 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
29241 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
29242 if ${gl_cv_decl_null_works+:} false
; then :
29243 $as_echo_n "(cached) " >&6
29245 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
29246 /* end confdefs.h. */
29247 #include <stddef.h>
29248 int test[2 * (sizeof NULL == sizeof (void *)) -1];
29258 if ac_fn_c_try_compile
"$LINENO"; then :
29259 gl_cv_decl_null_works
=yes
29261 gl_cv_decl_null_works
=no
29263 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
29265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
29266 $as_echo "$gl_cv_decl_null_works" >&6; }
29267 if test $gl_cv_decl_null_works = no
; then
29273 if test -n "$STDDEF_H"; then
29274 GL_GENERATE_STDDEF_H_TRUE
=
29275 GL_GENERATE_STDDEF_H_FALSE
='#'
29277 GL_GENERATE_STDDEF_H_TRUE
='#'
29278 GL_GENERATE_STDDEF_H_FALSE
=
29281 if test -n "$STDDEF_H"; then
29290 if test $gl_cv_have_include_next = yes; then
29291 gl_cv_next_stddef_h
='<'stddef.h
'>'
29293 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
29294 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
29295 if ${gl_cv_next_stddef_h+:} false
; then :
29296 $as_echo_n "(cached) " >&6
29301 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
29302 /* end confdefs.h. */
29303 #include <stddef.h>
29306 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
29307 *) gl_absname_cpp
="$ac_cpp" ;;
29312 gl_dirsep_regex
='[/\\]'
29315 gl_dirsep_regex
='\/'
29318 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
29319 gl_header_literal_regex
=`echo 'stddef.h' \
29320 | sed -e "$gl_make_literal_regex_sed"`
29321 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
29322 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
29328 gl_cv_absolute_stddef_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
29329 sed -n "$gl_absolute_header_sed"`
29331 gl_header
=$gl_cv_absolute_stddef_h
29332 gl_cv_next_stddef_h
='"'$gl_header'"'
29336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
29337 $as_echo "$gl_cv_next_stddef_h" >&6; }
29339 NEXT_STDDEF_H
=$gl_cv_next_stddef_h
29341 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
29342 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
29343 gl_next_as_first_directive
='<'stddef.h
'>'
29345 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
29346 gl_next_as_first_directive
=$gl_cv_next_stddef_h
29348 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
=$gl_next_as_first_directive
29358 $as_echo "#define __USE_MINGW_ANSI_STDIO 1" >>confdefs.h
29369 if test $gl_cv_have_include_next = yes; then
29370 gl_cv_next_stdio_h
='<'stdio.h
'>'
29372 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
29373 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
29374 if ${gl_cv_next_stdio_h+:} false
; then :
29375 $as_echo_n "(cached) " >&6
29380 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
29381 /* end confdefs.h. */
29385 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
29386 *) gl_absname_cpp
="$ac_cpp" ;;
29391 gl_dirsep_regex
='[/\\]'
29394 gl_dirsep_regex
='\/'
29397 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
29398 gl_header_literal_regex
=`echo 'stdio.h' \
29399 | sed -e "$gl_make_literal_regex_sed"`
29400 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
29401 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
29407 gl_cv_absolute_stdio_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
29408 sed -n "$gl_absolute_header_sed"`
29410 gl_header
=$gl_cv_absolute_stdio_h
29411 gl_cv_next_stdio_h
='"'$gl_header'"'
29415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
29416 $as_echo "$gl_cv_next_stdio_h" >&6; }
29418 NEXT_STDIO_H
=$gl_cv_next_stdio_h
29420 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
29421 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
29422 gl_next_as_first_directive
='<'stdio.h
'>'
29424 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
29425 gl_next_as_first_directive
=$gl_cv_next_stdio_h
29427 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
=$gl_next_as_first_directive
29433 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which flavor of printf attribute matches inttypes macros" >&5
29434 $as_echo_n "checking which flavor of printf attribute matches inttypes macros... " >&6; }
29435 if ${gl_cv_func_printf_attribute_flavor+:} false
; then :
29436 $as_echo_n "(cached) " >&6
29438 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
29439 /* end confdefs.h. */
29441 #define __STDC_FORMAT_MACROS 1
29443 #include <inttypes.h>
29444 /* For non-mingw systems, compilation will trivially succeed.
29445 For mingw, compilation will succeed for older mingw (system
29446 printf, "I64d") and fail for newer mingw (gnu printf, "lld"). */
29447 #if (defined _WIN32 && ! defined __CYGWIN__) && \
29448 (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4))
29449 extern char PRIdMAX_probe[sizeof PRIdMAX == sizeof "I64d" ? 1 : -1];
29460 if ac_fn_c_try_compile
"$LINENO"; then :
29461 gl_cv_func_printf_attribute_flavor
=system
29463 gl_cv_func_printf_attribute_flavor
=gnu
29465 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
29467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_attribute_flavor" >&5
29468 $as_echo "$gl_cv_func_printf_attribute_flavor" >&6; }
29469 if test "$gl_cv_func_printf_attribute_flavor" = gnu
; then
29471 $as_echo "#define GNULIB_PRINTF_ATTRIBUTE_FLAVOR_GNU 1" >>confdefs.h
29478 cat >>confdefs.h
<<_ACEOF
29479 #define GNULIB_FSCANF 1
29486 cat >>confdefs.h
<<_ACEOF
29487 #define GNULIB_SCANF 1
29518 if test $ac_cv_have_decl_fcloseall = no
; then
29519 HAVE_DECL_FCLOSEALL
=0
29532 if test $gl_cv_have_include_next = yes; then
29533 gl_cv_next_stdlib_h
='<'stdlib.h
'>'
29535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
29536 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
29537 if ${gl_cv_next_stdlib_h+:} false
; then :
29538 $as_echo_n "(cached) " >&6
29543 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
29544 /* end confdefs.h. */
29545 #include <stdlib.h>
29548 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
29549 *) gl_absname_cpp
="$ac_cpp" ;;
29554 gl_dirsep_regex
='[/\\]'
29557 gl_dirsep_regex
='\/'
29560 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
29561 gl_header_literal_regex
=`echo 'stdlib.h' \
29562 | sed -e "$gl_make_literal_regex_sed"`
29563 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
29564 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
29570 gl_cv_absolute_stdlib_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
29571 sed -n "$gl_absolute_header_sed"`
29573 gl_header
=$gl_cv_absolute_stdlib_h
29574 gl_cv_next_stdlib_h
='"'$gl_header'"'
29578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
29579 $as_echo "$gl_cv_next_stdlib_h" >&6; }
29581 NEXT_STDLIB_H
=$gl_cv_next_stdlib_h
29583 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
29584 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
29585 gl_next_as_first_directive
='<'stdlib.h
'>'
29587 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
29588 gl_next_as_first_directive
=$gl_cv_next_stdlib_h
29590 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
=$gl_next_as_first_directive
29603 if test $ac_cv_have_decl_ecvt = no
; then
29607 if test $ac_cv_have_decl_fcvt = no
; then
29611 if test $ac_cv_have_decl_gcvt = no
; then
29619 for ac_func
in strchrnul
29621 ac_fn_c_check_func
"$LINENO" "strchrnul" "ac_cv_func_strchrnul"
29622 if test "x$ac_cv_func_strchrnul" = xyes
; then :
29623 cat >>confdefs.h
<<_ACEOF
29624 #define HAVE_STRCHRNUL 1
29630 if test $ac_cv_func_strchrnul = no
; then
29633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strchrnul works" >&5
29634 $as_echo_n "checking whether strchrnul works... " >&6; }
29635 if ${gl_cv_func_strchrnul_works+:} false
; then :
29636 $as_echo_n "(cached) " >&6
29638 if test "$cross_compiling" = yes; then :
29639 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
29640 /* end confdefs.h. */
29642 #if defined __CYGWIN__
29643 #include <cygwin/version.h>
29644 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 9)
29652 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
29653 $EGREP "Lucky user" >/dev
/null
2>&1; then :
29654 gl_cv_func_strchrnul_works
="guessing yes"
29656 gl_cv_func_strchrnul_works
="guessing no"
29662 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
29663 /* end confdefs.h. */
29665 #include <string.h> /* for strchrnul */
29670 const char *buf = "a";
29671 return strchrnul (buf, 'b') != buf + 1;
29677 if ac_fn_c_try_run
"$LINENO"; then :
29678 gl_cv_func_strchrnul_works
=yes
29680 gl_cv_func_strchrnul_works
=no
29682 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
29683 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
29688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strchrnul_works" >&5
29689 $as_echo "$gl_cv_func_strchrnul_works" >&6; }
29690 case "$gl_cv_func_strchrnul_works" in
29692 *) REPLACE_STRCHRNUL
=1 ;;
29696 if test $HAVE_STRCHRNUL = 0 ||
test $REPLACE_STRCHRNUL = 1; then
29705 gl_LIBOBJS
="$gl_LIBOBJS strchrnul.$ac_objext"
29720 $as_echo "#define GNULIB_TEST_STRCHRNUL 1" >>confdefs.h
29727 if test $gl_cv_func_malloc_posix != yes; then
29731 if test $ac_cv_have_decl_strdup = no
; then
29735 if test $REPLACE_STRDUP = 1; then
29744 gl_LIBOBJS
="$gl_LIBOBJS strdup.$ac_objext"
29759 $as_echo "#define GNULIB_TEST_STRDUP 1" >>confdefs.h
29770 if test "$ERRNO_H:$REPLACE_STRERROR_0" = :0; then
29771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strerror function" >&5
29772 $as_echo_n "checking for working strerror function... " >&6; }
29773 if ${gl_cv_func_working_strerror+:} false
; then :
29774 $as_echo_n "(cached) " >&6
29776 if test "$cross_compiling" = yes; then :
29778 # Guess yes on glibc systems.
29779 *-gnu* | gnu
*) gl_cv_func_working_strerror
="guessing yes" ;;
29780 # Guess yes on musl systems.
29781 *-musl*) gl_cv_func_working_strerror
="guessing yes" ;;
29782 # If we don't know, obey --enable-cross-guesses.
29783 *) gl_cv_func_working_strerror
="$gl_cross_guess_normal" ;;
29787 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
29788 /* end confdefs.h. */
29789 #include <string.h>
29794 if (!*strerror (-2)) return 1;
29799 if ac_fn_c_try_run
"$LINENO"; then :
29800 gl_cv_func_working_strerror
=yes
29802 gl_cv_func_working_strerror
=no
29804 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
29805 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
29810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_strerror" >&5
29811 $as_echo "$gl_cv_func_working_strerror" >&6; }
29812 case "$gl_cv_func_working_strerror" in
29819 case "$gl_cv_func_strerror_r_works" in
29820 *no
) REPLACE_STRERROR
=1 ;;
29827 if test $REPLACE_STRERROR = 1; then
29836 gl_LIBOBJS
="$gl_LIBOBJS strerror.$ac_objext"
29841 cat >>confdefs.h
<<_ACEOF
29842 #define GNULIB_STRERROR 1
29857 $as_echo "#define GNULIB_TEST_STRERROR 1" >>confdefs.h
29863 if test -n "$ERRNO_H" ||
test $REPLACE_STRERROR_0 = 1; then
29872 gl_LIBOBJS
="$gl_LIBOBJS strerror-override.$ac_objext"
29878 if test $ac_cv_header_sys_socket_h != yes; then
29879 for ac_header
in winsock2.h
29881 ac_fn_c_check_header_mongrel
"$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
29882 if test "x$ac_cv_header_winsock2_h" = xyes
; then :
29883 cat >>confdefs.h
<<_ACEOF
29884 #define HAVE_WINSOCK2_H 1
29892 if test "$ac_cv_header_winsock2_h" = yes; then
29894 UNISTD_H_HAVE_WINSOCK2_H
=1
29895 SYS_IOCTL_H_HAVE_WINSOCK2_H
=1
29909 if test $ac_cv_have_decl_strerror_r = no
; then
29910 HAVE_DECL_STRERROR_R
=0
29913 if test $ac_cv_func_strerror_r = yes; then
29914 if test "$ERRNO_H:$REPLACE_STRERROR_0" = :0; then
29915 if test $gl_cv_func_strerror_r_posix_signature = yes; then
29916 case "$gl_cv_func_strerror_r_works" in
29917 *no
) REPLACE_STRERROR_R
=1 ;;
29920 REPLACE_STRERROR_R
=1
29923 REPLACE_STRERROR_R
=1
29927 if test $HAVE_DECL_STRERROR_R = 0 ||
test $REPLACE_STRERROR_R = 1; then
29936 gl_LIBOBJS
="$gl_LIBOBJS strerror_r.$ac_objext"
29949 GNULIB_STRERROR_R
=1
29955 $as_echo "#define GNULIB_TEST_STRERROR_R 1" >>confdefs.h
29961 cat >>confdefs.h
<<_ACEOF
29962 #define GNULIB_STRERROR_R_POSIX 1
29978 if test $ac_cv_have_decl_strnlen = no
; then
29979 HAVE_DECL_STRNLEN
=0
29982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strnlen" >&5
29983 $as_echo_n "checking for working strnlen... " >&6; }
29984 if ${ac_cv_func_strnlen_working+:} false
; then :
29985 $as_echo_n "(cached) " >&6
29987 if test "$cross_compiling" = yes; then :
29988 # Guess no on AIX systems, yes otherwise.
29990 aix
*) ac_cv_func_strnlen_working
=no
;;
29991 *) ac_cv_func_strnlen_working
=yes;;
29994 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
29995 /* end confdefs.h. */
29996 $ac_includes_default
30002 #define S_LEN (sizeof S - 1)
30004 /* At least one implementation is buggy: that of AIX 4.3 would
30005 give strnlen (S, 1) == 3. */
30008 for (i = 0; i < S_LEN + 1; ++i)
30010 int expected = i <= S_LEN ? i : S_LEN;
30011 if (strnlen (S, i) != expected)
30020 if ac_fn_c_try_run
"$LINENO"; then :
30021 ac_cv_func_strnlen_working
=yes
30023 ac_cv_func_strnlen_working
=no
30025 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
30026 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
30030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strnlen_working" >&5
30031 $as_echo "$ac_cv_func_strnlen_working" >&6; }
30032 test $ac_cv_func_strnlen_working = no
&& :
30035 if test $ac_cv_func_strnlen_working = no
; then
30040 if test $HAVE_DECL_STRNLEN = 0 ||
test $REPLACE_STRNLEN = 1; then
30049 gl_LIBOBJS
="$gl_LIBOBJS strnlen.$ac_objext"
30064 $as_echo "#define GNULIB_TEST_STRNLEN 1" >>confdefs.h
30070 if test $REPLACE_STRSTR = 0; then
30071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strstr works in linear time" >&5
30072 $as_echo_n "checking whether strstr works in linear time... " >&6; }
30073 if ${gl_cv_func_strstr_linear+:} false
; then :
30074 $as_echo_n "(cached) " >&6
30076 if test "$cross_compiling" = yes; then :
30077 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
30078 /* end confdefs.h. */
30080 #include <features.h>
30081 #ifdef __GNU_LIBRARY__
30082 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ > 12) || (__GLIBC__ > 2)) \
30083 && !(defined __i386__ || defined __x86_64__) \
30084 && !defined __UCLIBC__
30089 #include <cygwin/version.h>
30090 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
30096 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
30097 $EGREP "Lucky user" >/dev
/null
2>&1; then :
30098 gl_cv_func_strstr_linear
="guessing yes"
30100 gl_cv_func_strstr_linear
="$gl_cross_guess_normal"
30106 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
30107 /* end confdefs.h. */
30110 /* z/OS does not deliver signals while strstr() is running (thanks to
30111 restrictions on its LE runtime), which prevents us from limiting the
30112 running time of this test. */
30113 # error "This test does not work properly on z/OS"
30115 #include <signal.h> /* for signal */
30116 #include <string.h> /* for strstr */
30117 #include <stdlib.h> /* for malloc */
30118 #include <unistd.h> /* for alarm */
30119 static void quit (int sig) { _exit (sig + 128); }
30126 size_t m = 1000000;
30127 char *haystack = (char *) malloc (2 * m + 2);
30128 char *needle = (char *) malloc (m + 2);
30129 /* Failure to compile this test due to missing alarm is okay,
30130 since all such platforms (mingw) also have quadratic strstr. */
30131 signal (SIGALRM, quit);
30133 /* Check for quadratic performance. */
30134 if (haystack && needle)
30136 memset (haystack, 'A', 2 * m);
30137 haystack[2 * m] = 'B';
30138 haystack[2 * m + 1] = 0;
30139 memset (needle, 'A', m);
30142 if (!strstr (haystack, needle))
30145 /* Free allocated memory, in case some sanitizer is watching. */
30154 if ac_fn_c_try_run
"$LINENO"; then :
30155 gl_cv_func_strstr_linear
=yes
30157 gl_cv_func_strstr_linear
=no
30159 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
30160 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
30165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strstr_linear" >&5
30166 $as_echo "$gl_cv_func_strstr_linear" >&6; }
30167 case "$gl_cv_func_strstr_linear" in
30175 if test $REPLACE_STRSTR = 1; then
30184 gl_LIBOBJS
="$gl_LIBOBJS strstr.$ac_objext"
30190 if test $REPLACE_MEMCHR = 1; then
30193 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strstr works" >&5
30194 $as_echo_n "checking whether strstr works... " >&6; }
30195 if ${gl_cv_func_strstr_works_always+:} false
; then :
30196 $as_echo_n "(cached) " >&6
30198 if test "$cross_compiling" = yes; then :
30199 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
30200 /* end confdefs.h. */
30202 #ifdef __GNU_LIBRARY__
30203 #include <features.h>
30204 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ > 12) || (__GLIBC__ > 2)) \
30205 || defined __UCLIBC__
30208 #elif defined __CYGWIN__
30209 #include <cygwin/version.h>
30210 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
30218 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
30219 $EGREP "Lucky user" >/dev
/null
2>&1; then :
30220 gl_cv_func_strstr_works_always
="guessing yes"
30222 gl_cv_func_strstr_works_always
="$gl_cross_guess_normal"
30228 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
30229 /* end confdefs.h. */
30231 #include <string.h> /* for strstr */
30232 #ifdef __GNU_LIBRARY__
30233 #include <features.h>
30234 #if __GLIBC__ == 2 && __GLIBC_MINOR__ == 28
30238 #define P "_EF_BF_BD"
30239 #define HAYSTACK "F_BD_CE_BD" P P P P "_C3_88_20" P P P "_C3_A7_20" P
30240 #define NEEDLE P P P P P
30245 return !!strstr (HAYSTACK, NEEDLE);
30251 if ac_fn_c_try_run
"$LINENO"; then :
30252 gl_cv_func_strstr_works_always
=yes
30254 gl_cv_func_strstr_works_always
=no
30256 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
30257 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
30262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strstr_works_always" >&5
30263 $as_echo "$gl_cv_func_strstr_works_always" >&6; }
30264 case "$gl_cv_func_strstr_works_always" in
30272 if test $REPLACE_STRSTR = 1; then
30281 gl_LIBOBJS
="$gl_LIBOBJS strstr.$ac_objext"
30295 $as_echo "#define GNULIB_TEST_STRSTR 1" >>confdefs.h
30303 for ac_func
in strtok_r
30305 ac_fn_c_check_func
"$LINENO" "strtok_r" "ac_cv_func_strtok_r"
30306 if test "x$ac_cv_func_strtok_r" = xyes
; then :
30307 cat >>confdefs.h
<<_ACEOF
30308 #define HAVE_STRTOK_R 1
30314 if test $ac_cv_func_strtok_r = yes; then
30316 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtok_r works" >&5
30317 $as_echo_n "checking whether strtok_r works... " >&6; }
30318 if ${gl_cv_func_strtok_r_works+:} false
; then :
30319 $as_echo_n "(cached) " >&6
30321 if test "$cross_compiling" = yes; then :
30323 # Guess no on glibc systems.
30324 *-gnu* | gnu
*) gl_cv_func_strtok_r_works
="guessing no" ;;
30325 # Guess yes on native Windows.
30326 mingw
*) gl_cv_func_strtok_r_works
="guessing yes" ;;
30327 *) gl_cv_func_strtok_r_works
="guessing yes" ;;
30331 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
30332 /* end confdefs.h. */
30334 #ifndef __OPTIMIZE__
30335 # define __OPTIMIZE__ 1
30337 #undef __OPTIMIZE_SIZE__
30338 #undef __NO_INLINE__
30339 #include <stdlib.h>
30340 #include <string.h>
30345 static const char dummy[] = "\177\01a";
30346 char delimiters[] = "xxxxxxxx";
30347 char *save_ptr = (char *) dummy;
30348 strtok_r (delimiters, "x", &save_ptr);
30349 strtok_r (NULL, "x", &save_ptr);
30357 if ac_fn_c_try_run
"$LINENO"; then :
30358 gl_cv_func_strtok_r_works
=yes
30360 gl_cv_func_strtok_r_works
=no
30362 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
30363 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
30368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strtok_r_works" >&5
30369 $as_echo "$gl_cv_func_strtok_r_works" >&6; }
30370 case "$gl_cv_func_strtok_r_works" in
30372 UNDEFINE_STRTOK_R
=1
30379 if test $ac_cv_have_decl_strtok_r = no
; then
30380 HAVE_DECL_STRTOK_R
=0
30383 if test $HAVE_STRTOK_R = 0 ||
test $REPLACE_STRTOK_R = 1; then
30392 gl_LIBOBJS
="$gl_LIBOBJS strtok_r.$ac_objext"
30409 $as_echo "#define GNULIB_TEST_STRTOK_R 1" >>confdefs.h
30424 if test $gl_cv_have_include_next = yes; then
30425 gl_cv_next_sys_random_h
='<'sys
/random.h
'>'
30427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/random.h>" >&5
30428 $as_echo_n "checking absolute name of <sys/random.h>... " >&6; }
30429 if ${gl_cv_next_sys_random_h+:} false
; then :
30430 $as_echo_n "(cached) " >&6
30433 if test $ac_cv_header_sys_random_h = yes; then
30438 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
30439 /* end confdefs.h. */
30440 #include <sys/random.h>
30443 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
30444 *) gl_absname_cpp
="$ac_cpp" ;;
30449 gl_dirsep_regex
='[/\\]'
30452 gl_dirsep_regex
='\/'
30455 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
30456 gl_header_literal_regex
=`echo 'sys/random.h' \
30457 | sed -e "$gl_make_literal_regex_sed"`
30458 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
30459 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
30465 gl_cv_absolute_sys_random_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
30466 sed -n "$gl_absolute_header_sed"`
30468 gl_header
=$gl_cv_absolute_sys_random_h
30469 gl_cv_next_sys_random_h
='"'$gl_header'"'
30471 gl_cv_next_sys_random_h
='<'sys
/random.h
'>'
30476 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_random_h" >&5
30477 $as_echo "$gl_cv_next_sys_random_h" >&6; }
30479 NEXT_SYS_RANDOM_H
=$gl_cv_next_sys_random_h
30481 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
30482 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
30483 gl_next_as_first_directive
='<'sys
/random.h
'>'
30485 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
30486 gl_next_as_first_directive
=$gl_cv_next_sys_random_h
30488 NEXT_AS_FIRST_DIRECTIVE_SYS_RANDOM_H
=$gl_next_as_first_directive
30493 if test $ac_cv_header_sys_random_h = yes; then
30494 HAVE_SYS_RANDOM_H
=1
30496 HAVE_SYS_RANDOM_H
=0
30501 if test $ac_cv_header_sys_random_h = yes; then
30502 UNISTD_H_HAVE_SYS_RANDOM_H
=1
30528 if test $gl_cv_have_include_next = yes; then
30529 gl_cv_next_sys_stat_h
='<'sys
/stat.h
'>'
30531 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
30532 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
30533 if ${gl_cv_next_sys_stat_h+:} false
; then :
30534 $as_echo_n "(cached) " >&6
30537 if test $ac_cv_header_sys_stat_h = yes; then
30542 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
30543 /* end confdefs.h. */
30544 #include <sys/stat.h>
30547 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
30548 *) gl_absname_cpp
="$ac_cpp" ;;
30553 gl_dirsep_regex
='[/\\]'
30556 gl_dirsep_regex
='\/'
30559 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
30560 gl_header_literal_regex
=`echo 'sys/stat.h' \
30561 | sed -e "$gl_make_literal_regex_sed"`
30562 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
30563 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
30569 gl_cv_absolute_sys_stat_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
30570 sed -n "$gl_absolute_header_sed"`
30572 gl_header
=$gl_cv_absolute_sys_stat_h
30573 gl_cv_next_sys_stat_h
='"'$gl_header'"'
30575 gl_cv_next_sys_stat_h
='<'sys
/stat.h
'>'
30580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
30581 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
30583 NEXT_SYS_STAT_H
=$gl_cv_next_sys_stat_h
30585 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
30586 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
30587 gl_next_as_first_directive
='<'sys
/stat.h
'>'
30589 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
30590 gl_next_as_first_directive
=$gl_cv_next_sys_stat_h
30592 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
=$gl_next_as_first_directive
30601 WINDOWS_STAT_TIMESPEC
=0
30610 ac_fn_c_check_type
"$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
30611 #include <sys/stat.h>
30613 if test "x$ac_cv_type_nlink_t" = xyes
; then :
30617 $as_echo "#define nlink_t int" >>confdefs.h
30646 if test $gl_cv_have_include_next = yes; then
30647 gl_cv_next_sys_uio_h
='<'sys
/uio.h
'>'
30649 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/uio.h>" >&5
30650 $as_echo_n "checking absolute name of <sys/uio.h>... " >&6; }
30651 if ${gl_cv_next_sys_uio_h+:} false
; then :
30652 $as_echo_n "(cached) " >&6
30655 if test $ac_cv_header_sys_uio_h = yes; then
30660 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
30661 /* end confdefs.h. */
30662 #include <sys/uio.h>
30665 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
30666 *) gl_absname_cpp
="$ac_cpp" ;;
30671 gl_dirsep_regex
='[/\\]'
30674 gl_dirsep_regex
='\/'
30677 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
30678 gl_header_literal_regex
=`echo 'sys/uio.h' \
30679 | sed -e "$gl_make_literal_regex_sed"`
30680 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
30681 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
30687 gl_cv_absolute_sys_uio_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
30688 sed -n "$gl_absolute_header_sed"`
30690 gl_header
=$gl_cv_absolute_sys_uio_h
30691 gl_cv_next_sys_uio_h
='"'$gl_header'"'
30693 gl_cv_next_sys_uio_h
='<'sys
/uio.h
'>'
30698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_uio_h" >&5
30699 $as_echo "$gl_cv_next_sys_uio_h" >&6; }
30701 NEXT_SYS_UIO_H
=$gl_cv_next_sys_uio_h
30703 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
30704 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
30705 gl_next_as_first_directive
='<'sys
/uio.h
'>'
30707 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
30708 gl_next_as_first_directive
=$gl_cv_next_sys_uio_h
30710 NEXT_AS_FIRST_DIRECTIVE_SYS_UIO_H
=$gl_next_as_first_directive
30715 if test $ac_cv_header_sys_uio_h = yes; then
30730 cat >>confdefs.h
<<_ACEOF
30731 #define GNULIB_TEMPNAME 1
30745 ac_fn_c_check_decl
"$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "/* mingw's <time.h> provides the functions asctime_r, ctime_r,
30746 gmtime_r, localtime_r only if <unistd.h> or <pthread.h> has
30747 been included before. */
30748 #if defined __MINGW32__
30749 # include <unistd.h>
30754 if test "x$ac_cv_have_decl_localtime_r" = xyes
; then :
30760 cat >>confdefs.h
<<_ACEOF
30761 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
30764 if test $ac_cv_have_decl_localtime_r = no
; then
30765 HAVE_DECL_LOCALTIME_R
=0
30769 if test $ac_cv_func_localtime_r = yes; then
30771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
30772 $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
30773 if ${gl_cv_time_r_posix+:} false
; then :
30774 $as_echo_n "(cached) " >&6
30776 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
30777 /* end confdefs.h. */
30778 /* mingw's <time.h> provides the functions asctime_r, ctime_r,
30779 gmtime_r, localtime_r only if <unistd.h> or <pthread.h> has
30780 been included before. */
30781 #if defined __MINGW32__
30782 # include <unistd.h>
30789 /* We don't need to append 'restrict's to the argument types,
30790 even though the POSIX signature has the 'restrict's,
30791 since C99 says they can't affect type compatibility. */
30792 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
30794 /* Check the return type is a pointer.
30795 On HP-UX 10 it is 'int'. */
30796 *localtime_r (0, 0);
30802 if ac_fn_c_try_compile
"$LINENO"; then :
30803 gl_cv_time_r_posix
=yes
30805 gl_cv_time_r_posix
=no
30807 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
30810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
30811 $as_echo "$gl_cv_time_r_posix" >&6; }
30812 if test $gl_cv_time_r_posix = yes; then
30813 REPLACE_LOCALTIME_R
=0
30815 REPLACE_LOCALTIME_R
=1
30819 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r exists as an inline function" >&5
30820 $as_echo_n "checking whether localtime_r exists as an inline function... " >&6; }
30821 if ${gl_cv_func_localtime_r_inline+:} false
; then :
30822 $as_echo_n "(cached) " >&6
30824 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
30825 /* end confdefs.h. */
30826 /* mingw's <time.h> provides the functions asctime_r, ctime_r,
30827 gmtime_r, localtime_r only if <unistd.h> or <pthread.h> has
30828 been included before. */
30829 #if defined __MINGW32__
30830 # include <unistd.h>
30839 localtime_r (&a, &r);
30846 if ac_fn_c_try_link
"$LINENO"; then :
30847 gl_cv_func_localtime_r_inline
=yes
30849 gl_cv_func_localtime_r_inline
=no
30851 rm -f core conftest.err conftest.
$ac_objext \
30852 conftest
$ac_exeext conftest.
$ac_ext
30855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_localtime_r_inline" >&5
30856 $as_echo "$gl_cv_func_localtime_r_inline" >&6; }
30857 if test $gl_cv_func_localtime_r_inline = yes; then
30858 REPLACE_LOCALTIME_R
=1
30862 if test $HAVE_LOCALTIME_R = 0 ||
test $REPLACE_LOCALTIME_R = 1; then
30871 gl_LIBOBJS
="$gl_LIBOBJS time_r.$ac_objext"
30888 $as_echo "#define GNULIB_TEST_TIME_R 1" >>confdefs.h
30904 if test $gl_cv_have_include_next = yes; then
30905 gl_cv_next_unistd_h
='<'unistd.h
'>'
30907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
30908 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
30909 if ${gl_cv_next_unistd_h+:} false
; then :
30910 $as_echo_n "(cached) " >&6
30913 if test $ac_cv_header_unistd_h = yes; then
30918 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
30919 /* end confdefs.h. */
30920 #include <unistd.h>
30923 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
30924 *) gl_absname_cpp
="$ac_cpp" ;;
30929 gl_dirsep_regex
='[/\\]'
30932 gl_dirsep_regex
='\/'
30935 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
30936 gl_header_literal_regex
=`echo 'unistd.h' \
30937 | sed -e "$gl_make_literal_regex_sed"`
30938 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
30939 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
30945 gl_cv_absolute_unistd_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
30946 sed -n "$gl_absolute_header_sed"`
30948 gl_header
=$gl_cv_absolute_unistd_h
30949 gl_cv_next_unistd_h
='"'$gl_header'"'
30951 gl_cv_next_unistd_h
='<'unistd.h
'>'
30956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
30957 $as_echo "$gl_cv_next_unistd_h" >&6; }
30959 NEXT_UNISTD_H
=$gl_cv_next_unistd_h
30961 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
30962 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
30963 gl_next_as_first_directive
='<'unistd.h
'>'
30965 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
30966 gl_next_as_first_directive
=$gl_cv_next_unistd_h
30968 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
=$gl_next_as_first_directive
30973 if test $ac_cv_header_unistd_h = yes; then
30991 if test $ac_cv_have_decl_execvpe = no
; then
30992 HAVE_DECL_EXECVPE
=0
31001 if test $ac_cv_have_decl_unsetenv = no
; then
31002 HAVE_DECL_UNSETENV
=0
31004 for ac_func
in unsetenv
31006 ac_fn_c_check_func
"$LINENO" "unsetenv" "ac_cv_func_unsetenv"
31007 if test "x$ac_cv_func_unsetenv" = xyes
; then :
31008 cat >>confdefs.h
<<_ACEOF
31009 #define HAVE_UNSETENV 1
31015 if test $ac_cv_func_unsetenv = no
; then
31019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsetenv() return type" >&5
31020 $as_echo_n "checking for unsetenv() return type... " >&6; }
31021 if ${gt_cv_func_unsetenv_ret+:} false
; then :
31022 $as_echo_n "(cached) " >&6
31024 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
31025 /* end confdefs.h. */
31028 #define _BSD 1 /* unhide unsetenv declaration in OSF/1 5.1 <stdlib.h> */
31029 #include <stdlib.h>
31034 int unsetenv (const char *name);
31044 if ac_fn_c_try_compile
"$LINENO"; then :
31045 gt_cv_func_unsetenv_ret
='int'
31047 gt_cv_func_unsetenv_ret
='void'
31049 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
31051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_unsetenv_ret" >&5
31052 $as_echo "$gt_cv_func_unsetenv_ret" >&6; }
31053 if test $gt_cv_func_unsetenv_ret = 'void'; then
31055 $as_echo "#define VOID_UNSETENV 1" >>confdefs.h
31060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether unsetenv obeys POSIX" >&5
31061 $as_echo_n "checking whether unsetenv obeys POSIX... " >&6; }
31062 if ${gl_cv_func_unsetenv_works+:} false
; then :
31063 $as_echo_n "(cached) " >&6
31065 if test "$cross_compiling" = yes; then :
31067 # Guess yes on glibc systems.
31068 *-gnu*) gl_cv_func_unsetenv_works
="guessing yes" ;;
31069 # If we don't know, obey --enable-cross-guesses.
31070 *) gl_cv_func_unsetenv_works
="$gl_cross_guess_normal" ;;
31074 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
31075 /* end confdefs.h. */
31077 #include <stdlib.h>
31079 extern char **environ;
31088 char entry1[] = "a=1";
31089 char entry2[] = "b=2";
31090 char *env[] = { entry1, entry2, NULL };
31091 if (putenv ((char *) "a=1")) return 1;
31092 if (putenv (entry2)) return 2;
31095 if (getenv ("a")) return 3;
31096 if (!unsetenv ("") || errno != EINVAL) return 4;
31099 if (!getenv ("a")) return 5;
31102 if (getenv ("a")) return 6;
31108 if ac_fn_c_try_run
"$LINENO"; then :
31109 gl_cv_func_unsetenv_works
=yes
31111 gl_cv_func_unsetenv_works
=no
31113 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
31114 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
31119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_unsetenv_works" >&5
31120 $as_echo "$gl_cv_func_unsetenv_works" >&6; }
31121 case "$gl_cv_func_unsetenv_works" in
31129 if test $HAVE_UNSETENV = 0 ||
test $REPLACE_UNSETENV = 1; then
31138 gl_LIBOBJS
="$gl_LIBOBJS unsetenv.$ac_objext"
31156 $as_echo "#define GNULIB_TEST_UNSETENV 1" >>confdefs.h
31172 if test $gl_cv_have_include_next = yes; then
31173 gl_cv_next_wchar_h
='<'wchar.h
'>'
31175 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <wchar.h>" >&5
31176 $as_echo_n "checking absolute name of <wchar.h>... " >&6; }
31177 if ${gl_cv_next_wchar_h+:} false
; then :
31178 $as_echo_n "(cached) " >&6
31181 if test $ac_cv_header_wchar_h = yes; then
31186 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
31187 /* end confdefs.h. */
31191 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
31192 *) gl_absname_cpp
="$ac_cpp" ;;
31197 gl_dirsep_regex
='[/\\]'
31200 gl_dirsep_regex
='\/'
31203 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
31204 gl_header_literal_regex
=`echo 'wchar.h' \
31205 | sed -e "$gl_make_literal_regex_sed"`
31206 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
31207 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
31213 gl_cv_absolute_wchar_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
31214 sed -n "$gl_absolute_header_sed"`
31216 gl_header
=$gl_cv_absolute_wchar_h
31217 gl_cv_next_wchar_h
='"'$gl_header'"'
31219 gl_cv_next_wchar_h
='<'wchar.h
'>'
31224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wchar_h" >&5
31225 $as_echo "$gl_cv_next_wchar_h" >&6; }
31227 NEXT_WCHAR_H
=$gl_cv_next_wchar_h
31229 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
31230 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
31231 gl_next_as_first_directive
='<'wchar.h
'>'
31233 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
31234 gl_next_as_first_directive
=$gl_cv_next_wchar_h
31236 NEXT_AS_FIRST_DIRECTIVE_WCHAR_H
=$gl_next_as_first_directive
31241 if test $ac_cv_header_wchar_h = yes; then
31251 if test $gt_cv_c_wint_t = yes; then
31266 ac_fn_c_check_decl
"$LINENO" "wcsdup" "ac_cv_have_decl_wcsdup" "
31270 if test "x$ac_cv_have_decl_wcsdup" = xyes
; then :
31276 cat >>confdefs.h
<<_ACEOF
31277 #define HAVE_DECL_WCSDUP $ac_have_decl
31280 if test $ac_cv_have_decl_wcsdup = no
; then
31289 if test $ac_cv_func_iswcntrl = yes; then
31297 if test $gt_cv_c_wint_t = yes; then
31315 if test $gl_cv_have_include_next = yes; then
31316 gl_cv_next_wctype_h
='<'wctype.h
'>'
31318 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <wctype.h>" >&5
31319 $as_echo_n "checking absolute name of <wctype.h>... " >&6; }
31320 if ${gl_cv_next_wctype_h+:} false
; then :
31321 $as_echo_n "(cached) " >&6
31324 if test $ac_cv_header_wctype_h = yes; then
31329 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
31330 /* end confdefs.h. */
31331 #include <wctype.h>
31334 aix
*) gl_absname_cpp
="$ac_cpp -C" ;;
31335 *) gl_absname_cpp
="$ac_cpp" ;;
31340 gl_dirsep_regex
='[/\\]'
31343 gl_dirsep_regex
='\/'
31346 gl_make_literal_regex_sed
='s,[]$^\\.*/[],\\&,g'
31347 gl_header_literal_regex
=`echo 'wctype.h' \
31348 | sed -e "$gl_make_literal_regex_sed"`
31349 gl_absolute_header_sed
="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
31350 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
31356 gl_cv_absolute_wctype_h
=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
31357 sed -n "$gl_absolute_header_sed"`
31359 gl_header
=$gl_cv_absolute_wctype_h
31360 gl_cv_next_wctype_h
='"'$gl_header'"'
31362 gl_cv_next_wctype_h
='<'wctype.h
'>'
31367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wctype_h" >&5
31368 $as_echo "$gl_cv_next_wctype_h" >&6; }
31370 NEXT_WCTYPE_H
=$gl_cv_next_wctype_h
31372 if test $gl_cv_have_include_next = yes ||
test $gl_cv_have_include_next = buggy
; then
31373 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
31374 gl_next_as_first_directive
='<'wctype.h
'>'
31376 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
31377 gl_next_as_first_directive
=$gl_cv_next_wctype_h
31379 NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H
=$gl_next_as_first_directive
31384 if test $ac_cv_header_wctype_h = yes; then
31385 if test $ac_cv_func_iswcntrl = yes; then
31386 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether iswcntrl works" >&5
31387 $as_echo_n "checking whether iswcntrl works... " >&6; }
31388 if ${gl_cv_func_iswcntrl_works+:} false
; then :
31389 $as_echo_n "(cached) " >&6
31392 if test "$cross_compiling" = yes; then :
31393 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
31394 /* end confdefs.h. */
31395 #include <stdlib.h>
31396 #if __GNU_LIBRARY__ == 1
31397 Linux libc5 i18n is broken.
31407 if ac_fn_c_try_compile
"$LINENO"; then :
31408 gl_cv_func_iswcntrl_works
="guessing yes"
31410 gl_cv_func_iswcntrl_works
="guessing no"
31412 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
31415 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
31416 /* end confdefs.h. */
31419 #include <wctype.h>
31420 int main () { return iswprint ('x') == 0; }
31423 if ac_fn_c_try_run
"$LINENO"; then :
31424 gl_cv_func_iswcntrl_works
=yes
31426 gl_cv_func_iswcntrl_works
=no
31428 rm -f core
*.core core.conftest.
* gmon.out bb.out conftest
$ac_exeext \
31429 conftest.
$ac_objext conftest.beam conftest.
$ac_ext
31434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_iswcntrl_works" >&5
31435 $as_echo "$gl_cv_func_iswcntrl_works" >&6; }
31443 if test $GNULIB_OVERRIDES_WINT_T = 1; then
31446 case "$gl_cv_func_iswcntrl_works" in
31447 *yes) REPLACE_ISWCNTRL
=0 ;;
31448 *) REPLACE_ISWCNTRL
=1 ;;
31453 if test $HAVE_ISWCNTRL = 0 ||
test $REPLACE_ISWCNTRL = 1; then
31457 if test $REPLACE_ISWCNTRL = 1; then
31460 for ac_func
in towlower
31462 ac_fn_c_check_func
"$LINENO" "towlower" "ac_cv_func_towlower"
31463 if test "x$ac_cv_func_towlower" = xyes
; then :
31464 cat >>confdefs.h
<<_ACEOF
31465 #define HAVE_TOWLOWER 1
31471 if test $ac_cv_func_towlower = yes; then
31474 ac_fn_c_check_decl
"$LINENO" "towlower" "ac_cv_have_decl_towlower" "#include <wchar.h>
31476 # include <wctype.h>
31480 if test "x$ac_cv_have_decl_towlower" = xyes
; then :
31486 cat >>confdefs.h
<<_ACEOF
31487 #define HAVE_DECL_TOWLOWER $ac_have_decl
31490 if test $ac_cv_have_decl_towlower = yes; then
31499 if test $HAVE_ISWCNTRL = 0 ||
test $REPLACE_TOWLOWER = 1; then
31503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctype_t" >&5
31504 $as_echo_n "checking for wctype_t... " >&6; }
31505 if ${gl_cv_type_wctype_t+:} false
; then :
31506 $as_echo_n "(cached) " >&6
31508 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
31509 /* end confdefs.h. */
31512 # include <wctype.h>
31524 if ac_fn_c_try_compile
"$LINENO"; then :
31525 gl_cv_type_wctype_t
=yes
31527 gl_cv_type_wctype_t
=no
31529 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
31532 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctype_t" >&5
31533 $as_echo "$gl_cv_type_wctype_t" >&6; }
31534 if test $gl_cv_type_wctype_t = no
; then
31538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctrans_t" >&5
31539 $as_echo_n "checking for wctrans_t... " >&6; }
31540 if ${gl_cv_type_wctrans_t+:} false
; then :
31541 $as_echo_n "(cached) " >&6
31543 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
31544 /* end confdefs.h. */
31546 #include <wctype.h>
31557 if ac_fn_c_try_compile
"$LINENO"; then :
31558 gl_cv_type_wctrans_t
=yes
31560 gl_cv_type_wctrans_t
=no
31562 rm -f core conftest.err conftest.
$ac_objext conftest.
$ac_ext
31565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctrans_t" >&5
31566 $as_echo "$gl_cv_type_wctrans_t" >&6; }
31567 if test $gl_cv_type_wctrans_t = no
; then
31586 gl_LIBOBJS
="$gl_LIBOBJS windows-mutex.$ac_objext"
31601 gl_LIBOBJS
="$gl_LIBOBJS windows-once.$ac_objext"
31616 gl_LIBOBJS
="$gl_LIBOBJS windows-recmutex.$ac_objext"
31631 gl_LIBOBJS
="$gl_LIBOBJS windows-rwlock.$ac_objext"
31637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wmemchr" >&5
31638 $as_echo_n "checking for wmemchr... " >&6; }
31639 if ${gl_cv_func_wmemchr+:} false
; then :
31640 $as_echo_n "(cached) " >&6
31642 cat confdefs.h
- <<_ACEOF >conftest.$ac_ext
31643 /* end confdefs.h. */
31649 return ! wmemchr ((const wchar_t *) 0, (wchar_t) ' ', 0);
31655 if ac_fn_c_try_link
"$LINENO"; then :
31656 gl_cv_func_wmemchr
=yes
31658 gl_cv_func_wmemchr
=no
31660 rm -f core conftest.err conftest.
$ac_objext \
31661 conftest
$ac_exeext conftest.
$ac_ext
31664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_wmemchr" >&5
31665 $as_echo "$gl_cv_func_wmemchr" >&6; }
31666 if test $gl_cv_func_wmemchr = no
; then
31670 if test $HAVE_WMEMCHR = 0; then
31679 gl_LIBOBJS
="$gl_LIBOBJS wmemchr.$ac_objext"
31693 $as_echo "#define GNULIB_TEST_WMEMCHR 1" >>confdefs.h
31705 if test $ac_cv_func_wmempcpy = no
; then
31709 if test $HAVE_WMEMPCPY = 0; then
31718 gl_LIBOBJS
="$gl_LIBOBJS wmempcpy.$ac_objext"
31732 $as_echo "#define GNULIB_TEST_WMEMPCPY 1" >>confdefs.h
31736 # End of code from modules
31758 gl_source_base
='tests'
31759 gltests_WITNESS
=IN_
`echo "${PACKAGE-$PACKAGE_TARNAME}" | LC_ALL=C tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ | LC_ALL=C sed -e 's/[^A-Z0-9_]/_/g'`_GNULIB_TESTS
31761 gl_module_indicator_condition
=$gltests_WITNESS
31771 LIBGNU_LIBDEPS
="$gl_libdeps"
31773 LIBGNU_LTLIBDEPS
="$gl_ltlibdeps"
31777 am__api_version
='1.15'
31779 # Find a good install program. We prefer a C program (faster),
31780 # so one script is as good as another. But avoid the broken or
31781 # incompatible versions:
31782 # SysV /etc/install, /usr/sbin/install
31783 # SunOS /usr/etc/install
31784 # IRIX /sbin/install
31786 # AmigaOS /C/install, which installs bootblocks on floppy discs
31787 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
31788 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
31789 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
31790 # OS/2's system install, which has a completely different semantic
31791 # ./install, which can be erroneously created by make from ./install.sh.
31792 # Reject install programs that cannot install multiple files.
31793 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
31794 $as_echo_n "checking for a BSD-compatible install... " >&6; }
31795 if test -z "$INSTALL"; then
31796 if ${ac_cv_path_install+:} false
; then :
31797 $as_echo_n "(cached) " >&6
31799 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
31800 for as_dir
in $PATH
31803 test -z "$as_dir" && as_dir
=.
31804 # Account for people who put trailing slashes in PATH elements.
31805 case $as_dir/ in #((
31806 .
/ | .
// |
/[cC
]/* | \
31807 /etc
/* |
/usr
/sbin
/* |
/usr
/etc
/* |
/sbin
/* |
/usr
/afsws
/bin
/* | \
31808 ?
:[\\/]os2
[\\/]install[\\/]* | ?
:[\\/]OS2
[\\/]INSTALL
[\\/]* | \
31811 # OSF1 and SCO ODT 3.0 have their own names for install.
31812 # Don't use installbsd from OSF since it installs stuff as root
31814 for ac_prog
in ginstall scoinst
install; do
31815 for ac_exec_ext
in '' $ac_executable_extensions; do
31816 if as_fn_executable_p
"$as_dir/$ac_prog$ac_exec_ext"; then
31817 if test $ac_prog = install &&
31818 grep dspmsg
"$as_dir/$ac_prog$ac_exec_ext" >/dev
/null
2>&1; then
31819 # AIX install. It has an incompatible calling convention.
31821 elif test $ac_prog = install &&
31822 grep pwplus
"$as_dir/$ac_prog$ac_exec_ext" >/dev
/null
2>&1; then
31823 # program-specific install script used by HP pwplus--don't use.
31826 rm -rf conftest.one conftest.two conftest.dir
31827 echo one
> conftest.one
31828 echo two
> conftest.two
31830 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two
"`pwd`/conftest.dir" &&
31831 test -s conftest.one
&& test -s conftest.two
&&
31832 test -s conftest.dir
/conftest.one
&&
31833 test -s conftest.dir
/conftest.two
31835 ac_cv_path_install
="$as_dir/$ac_prog$ac_exec_ext -c"
31848 rm -rf conftest.one conftest.two conftest.dir
31851 if test "${ac_cv_path_install+set}" = set; then
31852 INSTALL
=$ac_cv_path_install
31854 # As a last resort, use the slow shell script. Don't cache a
31855 # value for INSTALL within a source directory, because that will
31856 # break other packages using the cache if that directory is
31857 # removed, or if the value is a relative name.
31858 INSTALL
=$ac_install_sh
31861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
31862 $as_echo "$INSTALL" >&6; }
31864 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
31865 # It thinks the first close brace ends the variable substitution.
31866 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM
='${INSTALL}'
31868 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT
='${INSTALL}'
31870 test -z "$INSTALL_DATA" && INSTALL_DATA
='${INSTALL} -m 644'
31872 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
31873 $as_echo_n "checking whether build environment is sane... " >&6; }
31874 # Reject unsafe characters in $srcdir or the absolute working directory
31875 # name. Accept space and tab only in the latter.
31879 *[\\\"\
#\$\&\'\`$am_lf]*)
31880 as_fn_error $?
"unsafe absolute working directory name" "$LINENO" 5;;
31883 *[\\\"\
#\$\&\'\`$am_lf\ \ ]*)
31884 as_fn_error $?
"unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
31887 # Do 'set' in a subshell so we don't clobber the current shell's
31888 # arguments. Must try -L first in case configure is actually a
31889 # symlink; some systems play weird games with the mod time of symlinks
31890 # (eg FreeBSD returns the mod time of the symlink's containing
31894 for am_try
in 1 2; do
31895 echo "timestamp, slept: $am_has_slept" > conftest.
file
31896 set X
`ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
31897 if test "$*" = "X"; then
31899 set X
`ls -t "$srcdir/configure" conftest.file`
31901 if test "$*" != "X $srcdir/configure conftest.file" \
31902 && test "$*" != "X conftest.file $srcdir/configure"; then
31904 # If neither matched, then we have a broken ls. This can happen
31905 # if, for instance, CONFIG_SHELL is bash and it inherits a
31906 # broken ls alias from the environment. This has actually
31907 # happened. Such a system could not be considered "sane".
31908 as_fn_error $?
"ls -t appears to fail. Make sure there is not a broken
31909 alias in your environment" "$LINENO" 5
31911 if test "$2" = conftest.
file ||
test $am_try -eq 2; then
31918 test "$2" = conftest.
file
31924 as_fn_error $?
"newly created file is older than distributed files!
31925 Check your system clock" "$LINENO" 5
31927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31928 $as_echo "yes" >&6; }
31929 # If we didn't sleep, we still need to ensure time stamps of config.status and
31930 # generated files are strictly newer.
31932 if grep 'slept: no' conftest.
file >/dev
/null
2>&1; then
31937 rm -f conftest.
file
31939 test "$program_prefix" != NONE
&&
31940 program_transform_name
="s&^&$program_prefix&;$program_transform_name"
31941 # Use a double $ so make ignores it.
31942 test "$program_suffix" != NONE
&&
31943 program_transform_name
="s&\$&$program_suffix&;$program_transform_name"
31944 # Double any \ or $.
31945 # By default was `s,x,x', remove it if useless.
31946 ac_script
='s/[\\$]/&&/g;s/;s,x,x,$//'
31947 program_transform_name
=`$as_echo "$program_transform_name" | sed "$ac_script"`
31949 # Expand $ac_aux_dir to an absolute path.
31950 am_aux_dir
=`cd "$ac_aux_dir" && pwd`
31952 if test x
"${MISSING+set}" != xset
; then
31953 case $am_aux_dir in
31955 MISSING
="\${SHELL} \"$am_aux_dir/missing\"" ;;
31957 MISSING
="\${SHELL} $am_aux_dir/missing" ;;
31960 # Use eval to expand $SHELL
31961 if eval "$MISSING --is-lightweight"; then
31962 am_missing_run
="$MISSING "
31965 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
31966 $as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
31969 if test x
"${install_sh+set}" != xset
; then
31970 case $am_aux_dir in
31972 install_sh
="\${SHELL} '$am_aux_dir/install-sh'" ;;
31974 install_sh
="\${SHELL} $am_aux_dir/install-sh"
31978 # Installed binaries are usually stripped using 'strip' when the user
31979 # run "make install-strip". However 'strip' might not be the right
31980 # tool to use in cross-compilation environments, therefore Automake
31981 # will honor the 'STRIP' environment variable to overrule this program.
31982 if test "$cross_compiling" != no
; then
31983 if test -n "$ac_tool_prefix"; then
31984 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
31985 set dummy
${ac_tool_prefix}strip
; ac_word
=$2
31986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31987 $as_echo_n "checking for $ac_word... " >&6; }
31988 if ${ac_cv_prog_STRIP+:} false
; then :
31989 $as_echo_n "(cached) " >&6
31991 if test -n "$STRIP"; then
31992 ac_cv_prog_STRIP
="$STRIP" # Let the user override the test.
31994 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
31995 for as_dir
in $PATH
31998 test -z "$as_dir" && as_dir
=.
31999 for ac_exec_ext
in '' $ac_executable_extensions; do
32000 if as_fn_executable_p
"$as_dir/$ac_word$ac_exec_ext"; then
32001 ac_cv_prog_STRIP
="${ac_tool_prefix}strip"
32002 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32011 STRIP
=$ac_cv_prog_STRIP
32012 if test -n "$STRIP"; then
32013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
32014 $as_echo "$STRIP" >&6; }
32016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32017 $as_echo "no" >&6; }
32022 if test -z "$ac_cv_prog_STRIP"; then
32024 # Extract the first word of "strip", so it can be a program name with args.
32025 set dummy strip
; ac_word
=$2
32026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32027 $as_echo_n "checking for $ac_word... " >&6; }
32028 if ${ac_cv_prog_ac_ct_STRIP+:} false
; then :
32029 $as_echo_n "(cached) " >&6
32031 if test -n "$ac_ct_STRIP"; then
32032 ac_cv_prog_ac_ct_STRIP
="$ac_ct_STRIP" # Let the user override the test.
32034 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
32035 for as_dir
in $PATH
32038 test -z "$as_dir" && as_dir
=.
32039 for ac_exec_ext
in '' $ac_executable_extensions; do
32040 if as_fn_executable_p
"$as_dir/$ac_word$ac_exec_ext"; then
32041 ac_cv_prog_ac_ct_STRIP
="strip"
32042 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32051 ac_ct_STRIP
=$ac_cv_prog_ac_ct_STRIP
32052 if test -n "$ac_ct_STRIP"; then
32053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
32054 $as_echo "$ac_ct_STRIP" >&6; }
32056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32057 $as_echo "no" >&6; }
32060 if test "x$ac_ct_STRIP" = x
; then
32063 case $cross_compiling:$ac_tool_warned in
32065 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32066 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32067 ac_tool_warned
=yes ;;
32072 STRIP
="$ac_cv_prog_STRIP"
32076 INSTALL_STRIP_PROGRAM
="\$(install_sh) -c -s"
32078 for ac_prog
in gawk mawk nawk
awk
32080 # Extract the first word of "$ac_prog", so it can be a program name with args.
32081 set dummy
$ac_prog; ac_word
=$2
32082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32083 $as_echo_n "checking for $ac_word... " >&6; }
32084 if ${ac_cv_prog_AWK+:} false
; then :
32085 $as_echo_n "(cached) " >&6
32087 if test -n "$AWK"; then
32088 ac_cv_prog_AWK
="$AWK" # Let the user override the test.
32090 as_save_IFS
=$IFS; IFS
=$PATH_SEPARATOR
32091 for as_dir
in $PATH
32094 test -z "$as_dir" && as_dir
=.
32095 for ac_exec_ext
in '' $ac_executable_extensions; do
32096 if as_fn_executable_p
"$as_dir/$ac_word$ac_exec_ext"; then
32097 ac_cv_prog_AWK
="$ac_prog"
32098 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32107 AWK
=$ac_cv_prog_AWK
32108 if test -n "$AWK"; then
32109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
32110 $as_echo "$AWK" >&6; }
32112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32113 $as_echo "no" >&6; }
32117 test -n "$AWK" && break
32120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
32121 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
32123 ac_make
=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
32124 if eval \
${ac_cv_prog_make_${ac_make}_set+:} false
; then :
32125 $as_echo_n "(cached) " >&6
32127 cat >conftest.
make <<\_ACEOF
32130 @
echo '@@@%%%=$(MAKE)=@@@%%%'
32132 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
32133 case `${MAKE-make} -f conftest.make 2>/dev/null` in
32134 *@@@
%%%=?
*=@@@
%%%*)
32135 eval ac_cv_prog_make_
${ac_make}_set
=yes;;
32137 eval ac_cv_prog_make_
${ac_make}_set
=no
;;
32139 rm -f conftest.
make
32141 if eval test \
$ac_cv_prog_make_${ac_make}_set
= yes; then
32142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32143 $as_echo "yes" >&6; }
32146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32147 $as_echo "no" >&6; }
32148 SET_MAKE
="MAKE=${MAKE-make}"
32151 rm -rf .tst
2>/dev
/null
32152 mkdir .tst
2>/dev
/null
32153 if test -d .tst
; then
32158 rmdir .tst
2>/dev
/null
32160 DEPDIR
="${am__leading_dot}deps"
32162 ac_config_commands
="$ac_config_commands depfiles"
32165 am_make
=${MAKE-make}
32166 cat > confinc
<< 'END'
32168 @
echo this is the am__doit target
32171 # If we don't find an include directive, just comment out the code.
32172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
32173 $as_echo_n "checking for style of include used by $am_make... " >&6; }
32177 # First try GNU make style include.
32178 echo "include confinc" > confmf
32179 # Ignore all kinds of additional output from 'make'.
32180 case `$am_make -s -f confmf 2> /dev/null` in #(
32181 *the\ am__doit\ target
*)
32182 am__include
=include
32187 # Now try BSD make style include.
32188 if test "$am__include" = "#"; then
32189 echo '.include "confinc"' > confmf
32190 case `$am_make -s -f confmf 2> /dev/null` in #(
32191 *the\ am__doit\ target
*)
32192 am__include
=.include
32200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
32201 $as_echo "$_am_result" >&6; }
32202 rm -f confinc confmf
32204 # Check whether --enable-dependency-tracking was given.
32205 if test "${enable_dependency_tracking+set}" = set; then :
32206 enableval
=$enable_dependency_tracking;
32209 if test "x$enable_dependency_tracking" != xno
; then
32210 am_depcomp
="$ac_aux_dir/depcomp"
32214 if test "x$enable_dependency_tracking" != xno; then
32223 # Check whether --enable-silent-rules was given.
32224 if test "${enable_silent_rules+set}" = set; then :
32225 enableval
=$enable_silent_rules;
32228 case $enable_silent_rules in # (((
32229 yes) AM_DEFAULT_VERBOSITY
=0;;
32230 no
) AM_DEFAULT_VERBOSITY
=1;;
32231 *) AM_DEFAULT_VERBOSITY
=1;;
32233 am_make
=${MAKE-make}
32234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
32235 $as_echo_n "checking whether $am_make supports nested variables... " >&6; }
32236 if ${am_cv_make_support_nested_variables+:} false
; then :
32237 $as_echo_n "(cached) " >&6
32239 if $as_echo 'TRUE=$(BAR$(V))
32245 .PHONY: am__doit' |
$am_make -f - >/dev
/null
2>&1; then
32246 am_cv_make_support_nested_variables
=yes
32248 am_cv_make_support_nested_variables
=no
32251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
32252 $as_echo "$am_cv_make_support_nested_variables" >&6; }
32253 if test $am_cv_make_support_nested_variables = yes; then
32255 AM_DEFAULT_V
='$(AM_DEFAULT_VERBOSITY)'
32257 AM_V
=$AM_DEFAULT_VERBOSITY
32258 AM_DEFAULT_V
=$AM_DEFAULT_VERBOSITY
32262 if test "`cd $srcdir && pwd`" != "`pwd`"; then
32263 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
32264 # is not polluted with repeated "-I."
32265 am__isrc
=' -I$(srcdir)'
32266 # test to see if srcdir already configured
32267 if test -f $srcdir/config.status
; then
32268 as_fn_error $?
"source directory already configured; run \"make distclean\" there first" "$LINENO" 5
32272 # test whether we have cygpath
32273 if test -z "$CYGPATH_W"; then
32274 if (cygpath
--version) >/dev
/null
2>/dev
/null
; then
32275 CYGPATH_W
='cygpath -w'
32282 # Define the identity of the package.
32284 VERSION
='UNUSED-VERSION'
32287 # Some tools Automake needs.
32289 ACLOCAL
=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
32292 AUTOCONF
=${AUTOCONF-"${am_missing_run}autoconf"}
32295 AUTOMAKE
=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
32298 AUTOHEADER
=${AUTOHEADER-"${am_missing_run}autoheader"}
32301 MAKEINFO
=${MAKEINFO-"${am_missing_run}makeinfo"}
32303 # For better backward compatibility. To be removed once Automake 1.9.x
32304 # dies out for good. For more background, see:
32305 # <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
32306 # <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
32307 mkdir_p
='$(MKDIR_P)'
32309 # We need awk for the "check" target (and possibly the TAP driver). The
32310 # system "awk" is bad on some platforms.
32311 # Always define AMTAR for backward compatibility. Yes, it's still used
32312 # in the wild :-( We should find a proper way to deprecate it ...
32313 AMTAR
='$${TAR-tar}'
32316 # We'll loop over all known methods to create a tar archive until one works.
32317 _am_tools
='gnutar pax cpio none'
32319 am__tar
='$${TAR-tar} chof - "$$tardir"' am__untar
='$${TAR-tar} xf -'
32325 depcc
="$CC" am_compiler_list
=
32327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
32328 $as_echo_n "checking dependency style of $depcc... " >&6; }
32329 if ${am_cv_CC_dependencies_compiler_type+:} false
; then :
32330 $as_echo_n "(cached) " >&6
32332 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
32333 # We make a subdir and do the tests there. Otherwise we can end up
32334 # making bogus files that we don't know about and never remove. For
32335 # instance it was reported that on HP-UX the gcc test will end up
32336 # making a dummy file named 'D' -- because '-MD' means "put the output
32338 rm -rf conftest.dir
32340 # Copy depcomp to subdir because otherwise we won't find it if we're
32341 # using a relative directory.
32342 cp "$am_depcomp" conftest.dir
32344 # We will build objects and dependencies in a subdirectory because
32345 # it helps to detect inapplicable dependency modes. For instance
32346 # both Tru64's cc and ICC support -MD to output dependencies as a
32347 # side effect of compilation, but ICC will put the dependencies in
32348 # the current directory while Tru64 will put them in the object
32352 am_cv_CC_dependencies_compiler_type
=none
32353 if test "$am_compiler_list" = ""; then
32354 am_compiler_list
=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
32356 am__universal
=false
32357 case " $depcc " in #(
32358 *\
-arch\
*\
-arch\
*) am__universal
=true
;;
32361 for depmode
in $am_compiler_list; do
32362 # Setup a source with many dependencies, because some compilers
32363 # like to wrap large dependency lists on column 80 (with \), and
32364 # we should not choose a depcomp mode which is confused by this.
32366 # We need to recreate these files for each test, as the compiler may
32367 # overwrite some of them when testing with obscure command lines.
32368 # This happens at least with the AIX C compiler.
32370 for i
in 1 2 3 4 5 6; do
32371 echo '#include "conftst'$i'.h"' >> sub
/conftest.c
32372 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
32373 # Solaris 10 /bin/sh.
32374 echo '/* dummy */' > sub
/conftst
$i.h
32376 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
32378 # We check with '-c' and '-o' for the sake of the "dashmstdout"
32379 # mode. It turns out that the SunPro C++ compiler does not properly
32380 # handle '-M -o', and we need to detect this. Also, some Intel
32381 # versions had trouble with output in subdirs.
32382 am__obj
=sub
/conftest.
${OBJEXT-o}
32383 am__minus_obj
="-o $am__obj"
32386 # This depmode causes a compiler race in universal mode.
32387 test "$am__universal" = false ||
continue
32390 # After this tag, mechanisms are not by side-effect, so they'll
32391 # only be used when explicitly requested.
32392 if test "x$enable_dependency_tracking" = xyes
; then
32398 msvc7 | msvc7msys | msvisualcpp | msvcmsys
)
32399 # This compiler won't grok '-c -o', but also, the minuso test has
32400 # not run yet. These depmodes are late enough in the game, and
32401 # so weak that their functioning should not be impacted.
32402 am__obj
=conftest.
${OBJEXT-o}
32407 if depmode
=$depmode \
32408 source=sub
/conftest.c object
=$am__obj \
32409 depfile
=sub
/conftest.Po tmpdepfile
=sub
/conftest.TPo \
32410 $SHELL .
/depcomp
$depcc -c $am__minus_obj sub
/conftest.c \
32411 >/dev
/null
2>conftest.err
&&
32412 grep sub
/conftst1.h sub
/conftest.Po
> /dev
/null
2>&1 &&
32413 grep sub
/conftst6.h sub
/conftest.Po
> /dev
/null
2>&1 &&
32414 grep $am__obj sub
/conftest.Po
> /dev
/null
2>&1 &&
32415 ${MAKE-make} -s -f confmf
> /dev
/null
2>&1; then
32416 # icc doesn't choke on unknown options, it will just issue warnings
32417 # or remarks (even with -Werror). So we grep stderr for any message
32418 # that says an option was ignored or not supported.
32419 # When given -MP, icc 7.0 and 7.1 complain thusly:
32420 # icc: Command line warning: ignoring option '-M'; no argument required
32421 # The diagnosis changed in icc 8.0:
32422 # icc: Command line remark: option '-MP' not supported
32423 if (grep 'ignoring option' conftest.err ||
32424 grep 'not supported' conftest.err
) >/dev
/null
2>&1; then :; else
32425 am_cv_CC_dependencies_compiler_type
=$depmode
32432 rm -rf conftest.dir
32434 am_cv_CC_dependencies_compiler_type
=none
32438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
32439 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
32440 CCDEPMODE
=depmode
=$am_cv_CC_dependencies_compiler_type
32443 test "x$enable_dependency_tracking" != xno \
32444 && test "$am_cv_CC_dependencies_compiler_type" = gcc3
; then
32445 am__fastdepCC_TRUE
=
32446 am__fastdepCC_FALSE
='#'
32448 am__fastdepCC_TRUE
='#'
32449 am__fastdepCC_FALSE
=
32454 # POSIX will say in a future version that running "rm -f" with no argument
32455 # is OK; and we want to be able to make that assumption in our Makefile
32456 # recipes. So use an aggressive probe to check that the usage we want is
32457 # actually supported "in the wild" to an acceptable degree.
32458 # See automake bug#10828.
32459 # To make any issue more visible, cause the running configure to be aborted
32460 # by default if the 'rm' program in use doesn't match our expectations; the
32461 # user can still override this though.
32462 if rm -f && rm -fr && rm -rf; then : OK
; else
32466 Your 'rm' program seems unable to run without file operands specified
32467 on the command line, even when the '-f' option is present. This is contrary
32468 to the behaviour of most rm programs out there, and not conforming with
32469 the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
32471 Please tell bug-automake@gnu.org about your system, including the value
32472 of your $PATH and any error possibly output before this message. This
32473 can help us improve future automake versions.
32476 if test x
"$ACCEPT_INFERIOR_RM_PROGRAM" = x
"yes"; then
32477 echo 'Configuration will proceed anyway, since you have set the' >&2
32478 echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
32482 Aborting the configuration process, to ensure you take notice of the issue.
32484 You can download and install GNU coreutils to get an 'rm' implementation
32485 that behaves properly: <http://www.gnu.org/software/coreutils/>.
32487 If you want to complete the configuration process using your problematic
32488 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
32489 to "yes", and re-run configure.
32492 as_fn_error $?
"Your 'rm' program is bad, sorry." "$LINENO" 5
32497 # Check whether --enable-silent-rules was given.
32498 if test "${enable_silent_rules+set}" = set; then :
32499 enableval
=$enable_silent_rules;
32502 case $enable_silent_rules in # (((
32503 yes) AM_DEFAULT_VERBOSITY
=0;;
32504 no
) AM_DEFAULT_VERBOSITY
=1;;
32505 *) AM_DEFAULT_VERBOSITY
=0;;
32507 am_make
=${MAKE-make}
32508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
32509 $as_echo_n "checking whether $am_make supports nested variables... " >&6; }
32510 if ${am_cv_make_support_nested_variables+:} false
; then :
32511 $as_echo_n "(cached) " >&6
32513 if $as_echo 'TRUE=$(BAR$(V))
32519 .PHONY: am__doit' |
$am_make -f - >/dev
/null
2>&1; then
32520 am_cv_make_support_nested_variables
=yes
32522 am_cv_make_support_nested_variables
=no
32525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
32526 $as_echo "$am_cv_make_support_nested_variables" >&6; }
32527 if test $am_cv_make_support_nested_variables = yes; then
32529 AM_DEFAULT_V
='$(AM_DEFAULT_VERBOSITY)'
32531 AM_V
=$AM_DEFAULT_VERBOSITY
32532 AM_DEFAULT_V
=$AM_DEFAULT_VERBOSITY
32537 # --------------------- #
32538 # Checks for programs. #
32539 # --------------------- #
32542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
32543 $as_echo_n "checking whether ln -s works... " >&6; }
32545 if test "$LN_S" = "ln -s"; then
32546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32547 $as_echo "yes" >&6; }
32549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
32550 $as_echo "no, using $LN_S" >&6; }
32553 if test -n "$ac_tool_prefix"; then
32554 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
32555 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
32556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32557 $as_echo_n "checking for $ac_word... " >&6; }
32558 if ${ac_cv_prog_RANLIB+:} false; then :
32559 $as_echo_n "(cached) " >&6
32561 if test -n "$RANLIB"; then
32562 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
32564 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32565 for as_dir in $PATH
32568 test -z "$as_dir" && as_dir=.
32569 for ac_exec_ext in '' $ac_executable_extensions; do
32570 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32571 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
32572 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32581 RANLIB=$ac_cv_prog_RANLIB
32582 if test -n "$RANLIB"; then
32583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
32584 $as_echo "$RANLIB" >&6; }
32586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32587 $as_echo "no" >&6; }
32592 if test -z "$ac_cv_prog_RANLIB"; then
32593 ac_ct_RANLIB=$RANLIB
32594 # Extract the first word of "ranlib", so it can be a program name with args.
32595 set dummy ranlib; ac_word=$2
32596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32597 $as_echo_n "checking for $ac_word... " >&6; }
32598 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
32599 $as_echo_n "(cached) " >&6
32601 if test -n "$ac_ct_RANLIB"; then
32602 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
32604 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32605 for as_dir in $PATH
32608 test -z "$as_dir" && as_dir=.
32609 for ac_exec_ext in '' $ac_executable_extensions; do
32610 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32611 ac_cv_prog_ac_ct_RANLIB="ranlib"
32612 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32621 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
32622 if test -n "$ac_ct_RANLIB"; then
32623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
32624 $as_echo "$ac_ct_RANLIB" >&6; }
32626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32627 $as_echo "no" >&6; }
32630 if test "x$ac_ct_RANLIB" = x; then
32633 case $cross_compiling:$ac_tool_warned in
32635 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32636 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32637 ac_tool_warned=yes ;;
32639 RANLIB=$ac_ct_RANLIB
32642 RANLIB="$ac_cv_prog_RANLIB"
32646 if test -n "$ac_tool_prefix"; then
32647 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
32648 set dummy ${ac_tool_prefix}ar; ac_word=$2
32649 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32650 $as_echo_n "checking for $ac_word... " >&6; }
32651 if ${ac_cv_prog_AR+:} false; then :
32652 $as_echo_n "(cached) " >&6
32654 if test -n "$AR"; then
32655 ac_cv_prog_AR="$AR" # Let the user override the test.
32657 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32658 for as_dir in $PATH
32661 test -z "$as_dir" && as_dir=.
32662 for ac_exec_ext in '' $ac_executable_extensions; do
32663 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32664 ac_cv_prog_AR="${ac_tool_prefix}ar"
32665 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32675 if test -n "$AR"; then
32676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32677 $as_echo "$AR" >&6; }
32679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32680 $as_echo "no" >&6; }
32685 if test -z "$ac_cv_prog_AR"; then
32687 # Extract the first word of "ar", so it can be a program name with args.
32688 set dummy ar; ac_word=$2
32689 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32690 $as_echo_n "checking for $ac_word... " >&6; }
32691 if ${ac_cv_prog_ac_ct_AR+:} false; then :
32692 $as_echo_n "(cached) " >&6
32694 if test -n "$ac_ct_AR"; then
32695 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
32697 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32698 for as_dir in $PATH
32701 test -z "$as_dir" && as_dir=.
32702 for ac_exec_ext in '' $ac_executable_extensions; do
32703 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32704 ac_cv_prog_ac_ct_AR="ar"
32705 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32714 ac_ct_AR=$ac_cv_prog_ac_ct_AR
32715 if test -n "$ac_ct_AR"; then
32716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
32717 $as_echo "$ac_ct_AR" >&6; }
32719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32720 $as_echo "no" >&6; }
32723 if test "x$ac_ct_AR" = x; then
32726 case $cross_compiling:$ac_tool_warned in
32728 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32729 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32730 ac_tool_warned=yes ;;
32735 AR="$ac_cv_prog_AR"
32739 # ---------------------- #
32740 # Checks for libraries. #
32741 # ---------------------- #
32743 ac_config_files="$ac_config_files Makefile.gnulib.inc"
32746 ac_config_files="$ac_config_files Makefile import/Makefile"
32748 ac_config_commands="$ac_config_commands default"
32750 cat >confcache <<\_ACEOF
32751 # This file is a shell script that caches the results of configure
32752 # tests run on this system so they can be shared between configure
32753 # scripts and configure runs, see configure's option
--config-cache.
32754 # It is not useful on other systems. If it contains results you don't
32755 # want to keep, you may remove or edit it.
32757 # config.status only pays attention to the cache file if you give it
32758 # the --recheck option to rerun configure.
32760 # `ac_cv_env_foo' variables (set or unset) will be overridden when
32761 # loading this file, other *unset* `ac_cv_foo' will be assigned the
32762 # following values.
32766 # The following way of writing the cache mishandles newlines in values,
32767 # but we know of no workaround that is simple, portable, and efficient.
32768 # So, we kill variables containing newlines.
32769 # Ultrix sh set writes to stderr and can't be redirected directly,
32770 # and sets the high bit in the cache file unless we assign to the vars.
32772 for ac_var
in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
32773 eval ac_val
=\$
$ac_var
32777 *_cv_
*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
32778 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
32781 _ | IFS | as_nl
) ;; #(
32782 BASH_ARGV | BASH_SOURCE
) eval $ac_var= ;; #(
32783 *) { eval $ac_var=; unset $ac_var;} ;;
32789 case $as_nl`(ac_space=' '; set) 2>&1` in #(
32790 *${as_nl}ac_space
=\
*)
32791 # `set' does not quote correctly, so add quotes: double-quote
32792 # substitution turns \\\\ into \\, and sed turns \\ into \.
32795 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
32798 # `set' quotes correctly as required by POSIX, so do not add quotes.
32799 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
32808 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
32810 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
32812 if diff "$cache_file" confcache
>/dev
/null
2>&1; then :; else
32813 if test -w "$cache_file"; then
32814 if test "x$cache_file" != "x/dev/null"; then
32815 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
32816 $as_echo "$as_me: updating cache $cache_file" >&6;}
32817 if test ! -f "$cache_file" ||
test -h "$cache_file"; then
32818 cat confcache
>"$cache_file"
32820 case $cache_file in #(
32822 mv -f confcache
"$cache_file"$$
&&
32823 mv -f "$cache_file"$$
"$cache_file" ;; #(
32825 mv -f confcache
"$cache_file" ;;
32830 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
32831 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
32836 test "x$prefix" = xNONE
&& prefix
=$ac_default_prefix
32837 # Let make expand exec_prefix.
32838 test "x$exec_prefix" = xNONE
&& exec_prefix
='${prefix}'
32840 DEFS
=-DHAVE_CONFIG_H
32844 for ac_i
in : $LIBOBJS; do test "x$ac_i" = x
: && continue
32845 # 1. Remove the extension, and $U if already installed.
32846 ac_script
='s/\$U\././;s/\.o$//;s/\.obj$//'
32847 ac_i
=`$as_echo "$ac_i" | sed "$ac_script"`
32848 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
32849 # will be set to the directory where LIBOBJS objects are built.
32850 as_fn_append ac_libobjs
" \${LIBOBJDIR}$ac_i\$U.$ac_objext"
32851 as_fn_append ac_ltlibobjs
" \${LIBOBJDIR}$ac_i"'$U.lo'
32853 LIBOBJS
=$ac_libobjs
32855 LTLIBOBJS
=$ac_ltlibobjs
32858 if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
32859 as_fn_error $?
"conditional \"MAINTAINER_MODE\" was never defined.
32860 Usually this means the macro was only invoked conditionally." "$LINENO" 5
32862 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
32863 as_fn_error $?
"conditional \"GL_COND_LIBTOOL\" was never defined.
32864 Usually this means the macro was only invoked conditionally." "$LINENO" 5
32866 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
32867 as_fn_error $?
"conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
32868 Usually this means the macro was only invoked conditionally." "$LINENO" 5
32870 if test -z "${GL_GENERATE_ERRNO_H_TRUE}" && test -z "${GL_GENERATE_ERRNO_H_FALSE}"; then
32871 as_fn_error $?
"conditional \"GL_GENERATE_ERRNO_H\" was never defined.
32872 Usually this means the macro was only invoked conditionally." "$LINENO" 5
32874 if test -z "${GL_GENERATE_FLOAT_H_TRUE}" && test -z "${GL_GENERATE_FLOAT_H_FALSE}"; then
32875 as_fn_error $?
"conditional \"GL_GENERATE_FLOAT_H\" was never defined.
32876 Usually this means the macro was only invoked conditionally." "$LINENO" 5
32878 if test -z "${GL_GENERATE_FNMATCH_H_TRUE}" && test -z "${GL_GENERATE_FNMATCH_H_FALSE}"; then
32879 as_fn_error $?
"conditional \"GL_GENERATE_FNMATCH_H\" was never defined.
32880 Usually this means the macro was only invoked conditionally." "$LINENO" 5
32882 if test -z "${GL_GENERATE_FNMATCH_H_TRUE}" && test -z "${GL_GENERATE_FNMATCH_H_FALSE}"; then
32883 as_fn_error $?
"conditional \"GL_GENERATE_FNMATCH_H\" was never defined.
32884 Usually this means the macro was only invoked conditionally." "$LINENO" 5
32886 if test -z "${GL_GENERATE_GLOB_H_TRUE}" && test -z "${GL_GENERATE_GLOB_H_FALSE}"; then
32887 as_fn_error $?
"conditional \"GL_GENERATE_GLOB_H\" was never defined.
32888 Usually this means the macro was only invoked conditionally." "$LINENO" 5
32890 if test -z "${GL_GENERATE_GLOB_H_TRUE}" && test -z "${GL_GENERATE_GLOB_H_FALSE}"; then
32891 as_fn_error $?
"conditional \"GL_GENERATE_GLOB_H\" was never defined.
32892 Usually this means the macro was only invoked conditionally." "$LINENO" 5
32894 if test -z "${GL_GENERATE_LIMITS_H_TRUE}" && test -z "${GL_GENERATE_LIMITS_H_FALSE}"; then
32895 as_fn_error $?
"conditional \"GL_GENERATE_LIMITS_H\" was never defined.
32896 Usually this means the macro was only invoked conditionally." "$LINENO" 5
32898 if test -z "${GL_GENERATE_LIMITS_H_TRUE}" && test -z "${GL_GENERATE_LIMITS_H_FALSE}"; then
32899 as_fn_error $?
"conditional \"GL_GENERATE_LIMITS_H\" was never defined.
32900 Usually this means the macro was only invoked conditionally." "$LINENO" 5
32902 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
32903 as_fn_error $?
"conditional \"GL_GENERATE_STDINT_H\" was never defined.
32904 Usually this means the macro was only invoked conditionally." "$LINENO" 5
32908 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
32909 as_fn_error $?
"conditional \"GL_GENERATE_STDDEF_H\" was never defined.
32910 Usually this means the macro was only invoked conditionally." "$LINENO" 5
32912 if test -z "${GL_GENERATE_NETINET_IN_H_TRUE}" && test -z "${GL_GENERATE_NETINET_IN_H_FALSE}"; then
32913 as_fn_error $?
"conditional \"GL_GENERATE_NETINET_IN_H\" was never defined.
32914 Usually this means the macro was only invoked conditionally." "$LINENO" 5
32916 if test -z "${GL_GENERATE_STDALIGN_H_TRUE}" && test -z "${GL_GENERATE_STDALIGN_H_FALSE}"; then
32917 as_fn_error $?
"conditional \"GL_GENERATE_STDALIGN_H\" was never defined.
32918 Usually this means the macro was only invoked conditionally." "$LINENO" 5
32920 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
32921 as_fn_error $?
"conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
32922 Usually this means the macro was only invoked conditionally." "$LINENO" 5
32924 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
32925 as_fn_error $?
"conditional \"GL_GENERATE_STDDEF_H\" was never defined.
32926 Usually this means the macro was only invoked conditionally." "$LINENO" 5
32931 if test -n "$gl_LIBOBJS"; then
32932 # Remove the extension.
32933 sed_drop_objext
='s/\.o$//;s/\.obj$//'
32934 for i
in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
32935 gl_libobjs
="$gl_libobjs $i.$ac_objext"
32936 gl_ltlibobjs
="$gl_ltlibobjs $i.lo"
32939 gl_LIBOBJS
=$gl_libobjs
32941 gl_LTLIBOBJS
=$gl_ltlibobjs
32947 if test -n "$gltests_LIBOBJS"; then
32948 # Remove the extension.
32949 sed_drop_objext
='s/\.o$//;s/\.obj$//'
32950 for i
in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
32951 gltests_libobjs
="$gltests_libobjs $i.$ac_objext"
32952 gltests_ltlibobjs
="$gltests_ltlibobjs $i.lo"
32955 gltests_LIBOBJS
=$gltests_libobjs
32957 gltests_LTLIBOBJS
=$gltests_ltlibobjs
32960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
32961 $as_echo_n "checking that generated files are newer than configure... " >&6; }
32962 if test -n "$am_sleep_pid"; then
32963 # Hide warnings about reused PIDs.
32964 wait $am_sleep_pid 2>/dev
/null
32966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
32967 $as_echo "done" >&6; }
32968 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
32969 as_fn_error $?
"conditional \"AMDEP\" was never defined.
32970 Usually this means the macro was only invoked conditionally." "$LINENO" 5
32972 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
32973 as_fn_error $?
"conditional \"am__fastdepCC\" was never defined.
32974 Usually this means the macro was only invoked conditionally." "$LINENO" 5
32976 if test -n "$EXEEXT"; then
32978 am__EXEEXT_FALSE
='#'
32980 am__EXEEXT_TRUE
='#'
32985 : "${CONFIG_STATUS=./config.status}"
32987 ac_clean_files_save
=$ac_clean_files
32988 ac_clean_files
="$ac_clean_files $CONFIG_STATUS"
32989 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
32990 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
32992 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
32994 # Generated by $as_me.
32995 # Run this file to recreate the current configuration.
32996 # Compiler output produced by configure, useful for debugging
32997 # configure, is in config.log if it exists.
33000 ac_cs_recheck=false
33003 SHELL=\${CONFIG_SHELL-$SHELL}
33006 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail
=1
33007 ## -------------------- ##
33008 ## M4sh Initialization. ##
33009 ## -------------------- ##
33011 # Be more Bourne compatible
33012 DUALCASE
=1; export DUALCASE
# for MKS sh
33013 if test -n "${ZSH_VERSION+set}" && (emulate sh
) >/dev
/null
2>&1; then :
33016 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
33017 # is contrary to our usage. Disable this feature.
33018 alias -g '${1+"$@"}'='"$@"'
33019 setopt NO_GLOB_SUBST
33021 case `(set -o) 2>/dev/null` in #(
33033 # Printing a long string crashes Solaris 7 /usr/bin/printf.
33034 as_echo
='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
33035 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
33036 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
33037 # Prefer a ksh shell builtin over an external printf program on Solaris,
33038 # but without wasting forks for bash or zsh.
33039 if test -z "$BASH_VERSION$ZSH_VERSION" \
33040 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
33041 as_echo='print
-r --'
33042 as_echo_n='print
-rn --'
33043 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
33044 as_echo='printf %s
\n'
33045 as_echo_n='printf %s
'
33047 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
33048 as_echo_body='eval /usr
/ucb
/echo -n "$1$as_nl"'
33049 as_echo_n='/usr
/ucb
/echo -n'
33051 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
33052 as_echo_n_body='eval
33056 expr "X$arg" : "X\\(.*\\)$as_nl";
33057 arg
=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
33059 expr "X$arg" : "X\\(.*\\)" |
tr -d "$as_nl"
33061 export as_echo_n_body
33062 as_echo_n='sh
-c $as_echo_n_body as_echo
'
33064 export as_echo_body
33065 as_echo='sh
-c $as_echo_body as_echo
'
33068 # The user is always right.
33069 if test "${PATH_SEPARATOR+set}" != set; then
33071 (PATH='/bin
;/bin
'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
33072 (PATH='/bin
:/bin
'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
33079 # We need space, tab and new line, in precisely that order. Quoting is
33080 # there to prevent editors from complaining about space-tab.
33081 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
33082 # splitting by setting IFS to empty value.)
33085 # Find who we are. Look in the path if we contain no directory separator.
33088 *[\\/]* ) as_myself=$0 ;;
33089 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33090 for as_dir in $PATH
33093 test -z "$as_dir" && as_dir=.
33094 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
33100 # We did not find ourselves, most probably we were run as `sh COMMAND'
33101 # in which case we are not to be found in the path.
33102 if test "x$as_myself" = x
; then
33105 if test ! -f "$as_myself"; then
33106 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
33110 # Unset variables that we do not need and which cause bugs (e.g. in
33111 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
33112 # suppresses any "Segmentation fault" message there. '((' could
33113 # trigger a bug in pdksh 5.2.14.
33114 for as_var
in BASH_ENV ENV MAIL MAILPATH
33115 do eval test x\
${$as_var+set} = xset \
33116 && ( (unset $as_var) ||
exit 1) >/dev
/null
2>&1 && unset $as_var ||
:
33129 (unset CDPATH
) >/dev
/null
2>&1 && unset CDPATH
33132 # as_fn_error STATUS ERROR [LINENO LOG_FD]
33133 # ----------------------------------------
33134 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
33135 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
33136 # script with STATUS, using 1 if that was 0.
33139 as_status
=$1; test $as_status -eq 0 && as_status
=1
33141 as_lineno
=${as_lineno-"$3"} as_lineno_stack
=as_lineno_stack
=$as_lineno_stack
33142 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
33144 $as_echo "$as_me: error: $2" >&2
33145 as_fn_exit
$as_status
33149 # as_fn_set_status STATUS
33150 # -----------------------
33151 # Set $? to STATUS, without forking.
33152 as_fn_set_status
()
33155 } # as_fn_set_status
33157 # as_fn_exit STATUS
33158 # -----------------
33159 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
33163 as_fn_set_status
$1
33169 # Portably unset VAR.
33172 { eval $1=; unset $1;}
33174 as_unset
=as_fn_unset
33175 # as_fn_append VAR VALUE
33176 # ----------------------
33177 # Append the text in VALUE to the end of the definition contained in VAR. Take
33178 # advantage of any shell optimizations that allow amortized linear growth over
33179 # repeated appends, instead of the typical quadratic growth present in naive
33181 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev
/null
; then :
33182 eval 'as_fn_append ()
33193 # as_fn_arith ARG...
33194 # ------------------
33195 # Perform arithmetic evaluation on the ARGs, and store the result in the
33196 # global $as_val. Take advantage of shells that can avoid forks. The arguments
33197 # must be portable across $(()) and expr.
33198 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev
/null
; then :
33199 eval 'as_fn_arith ()
33206 as_val
=`expr "$@" || test $? -eq 1`
33211 if expr a
: '\(a\)' >/dev
/null
2>&1 &&
33212 test "X`expr 00001 : '.*\(...\)'`" = X001
; then
33218 if (basename -- /) >/dev
/null
2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
33219 as_basename
=basename
33224 if (as_dir
=`dirname -- /` && test "X$as_dir" = X
/) >/dev
/null
2>&1; then
33230 as_me
=`$as_basename -- "$0" ||
33231 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
33232 X"$0" : 'X\(//\)$' \| \
33233 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
33235 sed '/^.*\/\([^/][^/]*\)\/*$/{
33249 # Avoid depending upon Character Ranges.
33250 as_cr_letters
='abcdefghijklmnopqrstuvwxyz'
33251 as_cr_LETTERS
='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
33252 as_cr_Letters
=$as_cr_letters$as_cr_LETTERS
33253 as_cr_digits
='0123456789'
33254 as_cr_alnum
=$as_cr_Letters$as_cr_digits
33256 ECHO_C
= ECHO_N
= ECHO_T
=
33257 case `echo -n x` in #(((((
33259 case `echo 'xy\c'` in
33260 *c
*) ECHO_T
=' ';; # ECHO_T is single tab character.
33262 *) echo `echo ksh88 bug on AIX 6.1` > /dev
/null
33269 rm -f conf$$ conf$$.exe conf$$.
file
33270 if test -d conf$$.dir
; then
33271 rm -f conf$$.dir
/conf$$.
file
33274 mkdir conf$$.dir
2>/dev
/null
33276 if (echo >conf$$.
file) 2>/dev
/null
; then
33277 if ln -s conf$$.
file conf$$
2>/dev
/null
; then
33279 # ... but there are two gotchas:
33280 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
33281 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
33282 # In both cases, we have to default to `cp -pR'.
33283 ln -s conf$$.
file conf$$.dir
2>/dev
/null
&& test ! -f conf$$.exe ||
33285 elif ln conf$$.
file conf$$
2>/dev
/null
; then
33293 rm -f conf$$ conf$$.exe conf$$.dir
/conf$$.
file conf$$.
file
33294 rmdir conf$$.dir
2>/dev
/null
33299 # Create "$as_dir" as a directory, including parents if necessary.
33304 -*) as_dir
=.
/$as_dir;;
33306 test -d "$as_dir" ||
eval $as_mkdir_p ||
{
33310 *\'*) as_qdir
=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
33311 *) as_qdir
=$as_dir;;
33313 as_dirs
="'$as_qdir' $as_dirs"
33314 as_dir
=`$as_dirname -- "$as_dir" ||
33315 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
33316 X"$as_dir" : 'X\(//\)[^/]' \| \
33317 X"$as_dir" : 'X\(//\)$' \| \
33318 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
33319 $as_echo X"$as_dir" |
33320 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
33324 /^X\(\/\/\)[^/].*/{
33337 test -d "$as_dir" && break
33339 test -z "$as_dirs" ||
eval "mkdir $as_dirs"
33340 } ||
test -d "$as_dir" || as_fn_error $?
"cannot create directory $as_dir"
33344 if mkdir
-p .
2>/dev
/null
; then
33345 as_mkdir_p
='mkdir -p "$as_dir"'
33347 test -d .
/-p && rmdir .
/-p
33352 # as_fn_executable_p FILE
33353 # -----------------------
33354 # Test if FILE is an executable regular file.
33355 as_fn_executable_p
()
33357 test -f "$1" && test -x "$1"
33358 } # as_fn_executable_p
33359 as_test_x
='test -x'
33360 as_executable_p
=as_fn_executable_p
33362 # Sed expression to map a string onto a valid CPP name.
33363 as_tr_cpp
="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
33365 # Sed expression to map a string onto a valid variable name.
33366 as_tr_sh
="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
33370 ## ----------------------------------- ##
33371 ## Main body of $CONFIG_STATUS script. ##
33372 ## ----------------------------------- ##
33374 test $as_write_fail = 0 && chmod +x
$CONFIG_STATUS || ac_write_fail
=1
33376 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail
=1
33377 # Save the log message, to keep $0 and so on meaningful, and to
33378 # report actual input values of CONFIG_FILES etc. instead of their
33379 # values after options handling.
33381 This file was extended by libgnu $as_me UNUSED-VERSION, which was
33382 generated by GNU Autoconf 2.69. Invocation command line was
33384 CONFIG_FILES = $CONFIG_FILES
33385 CONFIG_HEADERS = $CONFIG_HEADERS
33386 CONFIG_LINKS = $CONFIG_LINKS
33387 CONFIG_COMMANDS = $CONFIG_COMMANDS
33390 on `(hostname || uname -n) 2>/dev/null | sed 1q`
33395 case $ac_config_files in *"
33396 "*) set x
$ac_config_files; shift; ac_config_files
=$
*;;
33399 case $ac_config_headers in *"
33400 "*) set x
$ac_config_headers; shift; ac_config_headers
=$
*;;
33404 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
33405 # Files that config.status was made for.
33406 config_files="$ac_config_files"
33407 config_headers="$ac_config_headers"
33408 config_commands="$ac_config_commands"
33412 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail
=1
33414 \`$as_me' instantiates files and other configuration actions
33415 from templates according to the current configuration. Unless the files
33416 and actions are specified as TAGs, all are instantiated by default.
33418 Usage: $0 [OPTION]... [TAG]...
33420 -h, --help print this help, then exit
33421 -V, --version print version number and configuration settings, then exit
33422 --config print configuration, then exit
33423 -q, --quiet, --silent
33424 do not print progress messages
33425 -d, --debug don't remove temporary files
33426 --recheck update $as_me by reconfiguring in the same conditions
33427 --file=FILE[:TEMPLATE]
33428 instantiate the configuration file FILE
33429 --header=FILE[:TEMPLATE]
33430 instantiate the configuration header FILE
33432 Configuration files:
33435 Configuration headers:
33438 Configuration commands:
33441 Report bugs to the package provider."
33444 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
33445 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
33447 libgnu config.status UNUSED-VERSION
33448 configured by $0, generated by GNU Autoconf 2.69,
33449 with options \\"\$ac_cs_config\\"
33451 Copyright (C) 2012 Free Software Foundation, Inc.
33452 This config.status script is free software; the Free Software Foundation
33453 gives unlimited permission to copy, distribute and modify it."
33460 test -n "\$AWK" || AWK=awk
33463 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail
=1
33464 # The default lists apply if the user does not specify any file.
33470 ac_option
=`expr "X$1" : 'X\([^=]*\)='`
33471 ac_optarg
=`expr "X$1" : 'X[^=]*=\(.*\)'`
33475 ac_option
=`expr "X$1" : 'X\([^=]*\)='`
33487 # Handling of the options.
33488 -recheck |
--recheck |
--rechec |
--reche |
--rech |
--rec |
--re |
--r)
33490 --version |
--versio |
--versi |
--vers |
--ver |
--ve |
--v |
-V )
33491 $as_echo "$ac_cs_version"; exit ;;
33492 --config |
--confi |
--conf |
--con |
--co |
--c )
33493 $as_echo "$ac_cs_config"; exit ;;
33494 --debug |
--debu |
--deb |
--de |
--d |
-d )
33496 --file |
--fil |
--fi |
--f )
33499 *\'*) ac_optarg
=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
33500 '') as_fn_error $?
"missing file argument" ;;
33502 as_fn_append CONFIG_FILES
" '$ac_optarg'"
33503 ac_need_defaults
=false
;;
33504 --header |
--heade |
--head |
--hea )
33507 *\'*) ac_optarg
=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
33509 as_fn_append CONFIG_HEADERS
" '$ac_optarg'"
33510 ac_need_defaults
=false
;;
33512 # Conflict between --help and --header
33513 as_fn_error $?
"ambiguous option: \`$1'
33514 Try \`$0 --help' for more information.";;
33515 --help |
--hel |
-h )
33516 $as_echo "$ac_cs_usage"; exit ;;
33517 -q |
-quiet |
--quiet |
--quie |
--qui |
--qu |
--q \
33518 |
-silent |
--silent |
--silen |
--sile |
--sil |
--si |
--s)
33521 # This is an error.
33522 -*) as_fn_error $?
"unrecognized option: \`$1'
33523 Try \`$0 --help' for more information." ;;
33525 *) as_fn_append ac_config_targets
" $1"
33526 ac_need_defaults
=false
;;
33532 ac_configure_extra_args
=
33534 if $ac_cs_silent; then
33536 ac_configure_extra_args
="$ac_configure_extra_args --silent"
33540 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
33541 if \$ac_cs_recheck; then
33542 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
33544 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
33545 CONFIG_SHELL='$SHELL'
33546 export CONFIG_SHELL
33551 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail
=1
33555 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
33556 ## Running $as_me. ##
33562 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
33566 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
33570 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail
=1
33572 # Handling of arguments.
33573 for ac_config_target
in $ac_config_targets
33575 case $ac_config_target in
33576 "config.h") CONFIG_HEADERS
="$CONFIG_HEADERS config.h:config.in" ;;
33577 "depfiles") CONFIG_COMMANDS
="$CONFIG_COMMANDS depfiles" ;;
33578 "Makefile.gnulib.inc") CONFIG_FILES
="$CONFIG_FILES Makefile.gnulib.inc" ;;
33579 "Makefile") CONFIG_FILES
="$CONFIG_FILES Makefile" ;;
33580 "import/Makefile") CONFIG_FILES
="$CONFIG_FILES import/Makefile" ;;
33581 "default") CONFIG_COMMANDS
="$CONFIG_COMMANDS default" ;;
33583 *) as_fn_error $?
"invalid argument: \`$ac_config_target'" "$LINENO" 5;;
33588 # If the user did not use the arguments to specify the items to instantiate,
33589 # then the envvar interface is used. Set only those that are not.
33590 # We use the long form for the default assignment because of an extremely
33591 # bizarre bug on SunOS 4.1.3.
33592 if $ac_need_defaults; then
33593 test "${CONFIG_FILES+set}" = set || CONFIG_FILES
=$config_files
33594 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS
=$config_headers
33595 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS
=$config_commands
33598 # Have a temporary directory for convenience. Make it in the build tree
33599 # simply because there is no reason against having it here, and in addition,
33600 # creating and moving files from /tmp can sometimes cause problems.
33601 # Hook for its removal unless debugging.
33602 # Note that there is a small window in which the directory will not be cleaned:
33603 # after its creation but before its name has been assigned to `$tmp'.
33607 trap 'exit_status=$?
33608 : "${ac_tmp:=$tmp}"
33609 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
33611 trap 'as_fn_exit 1' 1 2 13 15
33613 # Create a (secure) tmp directory for tmp files.
33616 tmp
=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
33620 tmp
=.
/conf$$
-$RANDOM
33621 (umask 077 && mkdir
"$tmp")
33622 } || as_fn_error $?
"cannot create a temporary directory in ." "$LINENO" 5
33625 # Set up the scripts for CONFIG_FILES section.
33626 # No need to generate them if there are no CONFIG_FILES.
33627 # This happens for instance with `./config.status config.h'.
33628 if test -n "$CONFIG_FILES"; then
33631 ac_cr
=`echo X | tr X '\015'`
33632 # On cygwin, bash can eat \r inside `` if the user requested igncr.
33633 # But we know of no other shell where ac_cr would be empty at this
33634 # point, so we can use a bashism as a fallback.
33635 if test "x$ac_cr" = x
; then
33636 eval ac_cr
=\$
\'\\r
\'
33638 ac_cs_awk_cr
=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
33639 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
33642 ac_cs_awk_cr
=$ac_cr
33645 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
33650 echo "cat >conf$$subs.awk <<_ACEOF" &&
33651 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
33653 } >conf$$subs.sh ||
33654 as_fn_error $? "could not
make $CONFIG_STATUS" "$LINENO" 5
33655 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
33657 for ac_last_try in false false false false false :; do
33658 . ./conf$$subs.sh ||
33659 as_fn_error $? "could not
make $CONFIG_STATUS" "$LINENO" 5
33661 ac_delim_n=`sed -n "s
/.
*$ac_delim\$
/X
/p
" conf$$subs.awk | grep -c X`
33662 if test $ac_delim_n = $ac_delim_num; then
33664 elif $ac_last_try; then
33665 as_fn_error $? "could not
make $CONFIG_STATUS" "$LINENO" 5
33667 ac_delim="$ac_delim!$ac_delim _
$ac_delim!! "
33670 rm -f conf$$subs.sh
33672 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
33673 cat >>"\
$ac_tmp/subs1.
awk" <<\\_ACAWK &&
33677 s/^/S["/; s
/!.
*/"]=/
33687 s/\(.\{148\}\)..*/\1/
33689 s/["\\]/\\&/g
; s
/^
/"/; s/$/\\n"\\/
33694 s
/["\\]/\\&/g; s/^/"/; s
/$
/"\\/
33701 s/\(.\{148\}\)..*/\1/
33703 s/["\\]/\\&/g
; s
/^
/"/; s/$/"/
33707 s
/["\\]/\\&/g; s/^/"/; s
/$
/"\\/
33712 ' <conf$$subs.awk | sed '
33717 ' >>$CONFIG_STATUS || ac_write_fail=1
33718 rm -f conf$$subs.awk
33719 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
33721 cat >>"\
$ac_tmp/subs1.
awk" <<_ACAWK &&
33722 for (key in S) S_is_set[key] = 1
33728 nfields = split(line, field, "@
")
33730 len = length(field[1])
33731 for (i = 2; i < nfields; i++) {
33733 keylen = length(key)
33734 if (S_is_set[key]) {
33736 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
33737 len += length(value) + length(field[++i])
33748 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
33749 if sed "s
/$ac_cr//" < /dev/null > /dev/null 2>&1; then
33750 sed "s
/$ac_cr\$
//; s
/$ac_cr/$ac_cs_awk_cr/g
"
33753 fi < "$ac_tmp/subs1.
awk" > "$ac_tmp/subs.
awk" \
33754 || as_fn_error $? "could not setup config files machinery
" "$LINENO" 5
33757 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
33758 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".
", strip leading and
33759 # trailing colons and then remove the whole line if VPATH becomes empty
33760 # (actually we leave an empty line to preserve line numbers).
33761 if test "x
$srcdir" = x.; then
33762 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
33780 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
33781 fi # test -n "$CONFIG_FILES"
33783 # Set up the scripts for CONFIG_HEADERS section.
33784 # No need to generate them if there are no CONFIG_HEADERS.
33785 # This happens for instance with `./config.status Makefile'.
33786 if test -n "$CONFIG_HEADERS"; then
33787 cat >"$ac_tmp/defines.
awk" <<\_ACAWK ||
33791 # Transform confdefs.h into an awk script `defines.awk', embedded as
33792 # here-document in config.status, that substitutes the proper values into
33793 # config.h.in to produce config.h.
33795 # Create a delimiter string that does not exist in confdefs.h, to ease
33796 # handling of long lines.
33798 for ac_last_try in false false :; do
33799 ac_tt=`sed -n "/$ac_delim/p
" confdefs.h`
33800 if test -z "$ac_tt"; then
33802 elif $ac_last_try; then
33803 as_fn_error $? "could not
make $CONFIG_HEADERS" "$LINENO" 5
33805 ac_delim="$ac_delim!$ac_delim _
$ac_delim!! "
33809 # For the awk script, D is an array of macro values keyed by name,
33810 # likewise P contains macro parameters if any. Preserve backslash
33811 # newline sequences.
33813 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
33815 s/.\{148\}/&'"$ac_delim"'/g
33818 s/^[ ]*#[ ]*define[ ][ ]*/ /
33825 s
/^ \
('"$ac_word_re"'\
)\
(([^
()]*)\
)[ ]*\
(.
*\
)/P
["\1"]="\2"\
33827 s
/^ \
('"$ac_word_re"'\
)[ ]*\
(.
*\
)/D
["\1"]=" \2"/p
33831 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\
1"]="\
2"\
33832 D["\
1"]=" \
3\\\\\\n
"\\/p
33834 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\
1"]=" \
2\\\\\\n
"\\/p
33839 s/.\{148\}/&'"$ac_delim"'/g
33844 s/["\\]/\\&/g
; s
/^
/"/; s/$/"/p
33847 s
/["\\]/\\&/g; s/^/"/; s
/$
/\\\\\\n
"\\/p
33849 ' <confdefs.h | sed '
33850 s/'"$ac_delim"'/"\\\
33851 "/g' >>$CONFIG_STATUS || ac_write_fail=1
33853 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
33854 for (key in D) D_is_set[key] = 1
33857 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
33859 split(line, arg, " ")
33860 if (arg[1] == "#") {
33864 defundef
= substr
(arg
[1], 2)
33867 split(mac1
, mac2
, "(") #)
33869 prefix
= substr
(line
, 1, index
(line
, defundef
) - 1)
33870 if (D_is_set
[macro
]) {
33871 # Preserve the white space surrounding the "#".
33872 print prefix
"define", macro P
[macro
] D
[macro
]
33875 # Replace #undef with comments. This is necessary, for example,
33876 # in the case of _POSIX_SOURCE, which is predefined and required
33877 # on some systems where configure will not decide to define it.
33878 if (defundef
== "undef") {
33879 print
"/*", prefix defundef
, macro
, "*/"
33887 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail
=1
33888 as_fn_error $?
"could not setup config headers machinery" "$LINENO" 5
33889 fi # test -n "$CONFIG_HEADERS"
33892 eval set X
" :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
33897 :[FHLC
]) ac_mode
=$ac_tag; continue;;
33899 case $ac_mode$ac_tag in
33901 :L
* |
:C
*:*) as_fn_error $?
"invalid tag \`$ac_tag'" "$LINENO" 5;;
33902 :[FH
]-) ac_tag
=-:-;;
33903 :[FH
]*) ac_tag
=$ac_tag:$ac_tag.
in;;
33920 -) ac_f
="$ac_tmp/stdin";;
33921 *) # Look for the file first in the build tree, then in the source tree
33922 # (if the path is not absolute). The absolute path cannot be DOS-style,
33923 # because $ac_f cannot contain `:'.
33927 *) test -f "$srcdir/$ac_f" && ac_f
="$srcdir/$ac_f";;
33929 as_fn_error
1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
33931 case $ac_f in *\'*) ac_f
=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
33932 as_fn_append ac_file_inputs
" '$ac_f'"
33935 # Let's still pretend it is `configure' which instantiates (i.e., don't
33936 # use $as_me), people would be surprised to read:
33937 # /* config.h. Generated by config.status. */
33938 configure_input
='Generated from '`
33939 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
33941 if test x
"$ac_file" != x-
; then
33942 configure_input
="$ac_file. $configure_input"
33943 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
33944 $as_echo "$as_me: creating $ac_file" >&6;}
33946 # Neutralize special characters interpreted by sed in replacement strings.
33947 case $configure_input in #(
33948 *\
&* |
*\|
* |
*\\* )
33949 ac_sed_conf_input
=`$as_echo "$configure_input" |
33950 sed 's/[\\\\&|]/\\\\&/g'`;; #(
33951 *) ac_sed_conf_input
=$configure_input;;
33955 *:-:* |
*:-) cat >"$ac_tmp/stdin" \
33956 || as_fn_error $?
"could not create $ac_file" "$LINENO" 5 ;;
33961 ac_dir
=`$as_dirname -- "$ac_file" ||
33962 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
33963 X"$ac_file" : 'X\(//\)[^/]' \| \
33964 X"$ac_file" : 'X\(//\)$' \| \
33965 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
33966 $as_echo X"$ac_file" |
33967 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
33971 /^X\(\/\/\)[^/].*/{
33984 as_dir
="$ac_dir"; as_fn_mkdir_p
33988 .
) ac_dir_suffix
= ac_top_builddir_sub
=. ac_top_build_prefix
= ;;
33990 ac_dir_suffix
=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
33991 # A ".." for each directory in $ac_dir_suffix.
33992 ac_top_builddir_sub
=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
33993 case $ac_top_builddir_sub in
33994 "") ac_top_builddir_sub
=. ac_top_build_prefix
= ;;
33995 *) ac_top_build_prefix
=$ac_top_builddir_sub/ ;;
33998 ac_abs_top_builddir
=$ac_pwd
33999 ac_abs_builddir
=$ac_pwd$ac_dir_suffix
34000 # for backward compatibility:
34001 ac_top_builddir
=$ac_top_build_prefix
34004 .
) # We are building in place.
34006 ac_top_srcdir
=$ac_top_builddir_sub
34007 ac_abs_top_srcdir
=$ac_pwd ;;
34008 [\\/]* | ?
:[\\/]* ) # Absolute name.
34009 ac_srcdir
=$srcdir$ac_dir_suffix;
34010 ac_top_srcdir
=$srcdir
34011 ac_abs_top_srcdir
=$srcdir ;;
34012 *) # Relative name.
34013 ac_srcdir
=$ac_top_build_prefix$srcdir$ac_dir_suffix
34014 ac_top_srcdir
=$ac_top_build_prefix$srcdir
34015 ac_abs_top_srcdir
=$ac_pwd/$srcdir ;;
34017 ac_abs_srcdir
=$ac_abs_top_srcdir$ac_dir_suffix
34027 [\\/$
]* | ?
:[\\/]* ) ac_INSTALL
=$INSTALL ;;
34028 *) ac_INSTALL
=$ac_top_build_prefix$INSTALL ;;
34030 ac_MKDIR_P
=$MKDIR_P
34032 [\\/$
]* | ?
:[\\/]* ) ;;
34033 */*) ac_MKDIR_P
=$ac_top_build_prefix$MKDIR_P ;;
34037 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail
=1
34038 # If the template does not know about datarootdir, expand it.
34039 # FIXME: This hack should be removed a few years after 2.60.
34040 ac_datarootdir_hack
=; ac_datarootdir_seen
=
34051 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
34052 *datarootdir
*) ac_datarootdir_seen
=yes;;
34053 *@datadir@
*|
*@docdir@
*|
*@infodir@
*|
*@localedir@
*|
*@mandir@
*)
34054 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
34055 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
34057 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
34058 ac_datarootdir_hack='
34059 s&@datadir@&$datadir&g
34060 s&@docdir@&$docdir&g
34061 s&@infodir@&$infodir&g
34062 s&@localedir@&$localedir&g
34063 s&@mandir@&$mandir&g
34064 s&\\\${datarootdir}&$datarootdir&g' ;;
34068 # Neutralize VPATH when `$srcdir' = `.'.
34069 # Shell code in configure.ac might set extrasub.
34070 # FIXME: do we really want to maintain this feature?
34071 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
34072 ac_sed_extra="$ac_vpsub
34075 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail
=1
34077 /@
[a-zA-Z_
][a-zA-Z_0-9
]*@
/!b
34078 s|@configure_input@|
$ac_sed_conf_input|
;t t
34079 s
&@top_builddir@
&$ac_top_builddir_sub&;t t
34080 s
&@top_build_prefix@
&$ac_top_build_prefix&;t t
34081 s
&@srcdir@
&$ac_srcdir&;t t
34082 s
&@abs_srcdir@
&$ac_abs_srcdir&;t t
34083 s
&@top_srcdir@
&$ac_top_srcdir&;t t
34084 s
&@abs_top_srcdir@
&$ac_abs_top_srcdir&;t t
34085 s
&@builddir@
&$ac_builddir&;t t
34086 s
&@abs_builddir@
&$ac_abs_builddir&;t t
34087 s
&@abs_top_builddir@
&$ac_abs_top_builddir&;t t
34088 s
&@INSTALL@
&$ac_INSTALL&;t t
34089 s
&@MKDIR_P@
&$ac_MKDIR_P&;t t
34090 $ac_datarootdir_hack
34092 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.
awk" \
34093 >$ac_tmp/out || as_fn_error $? "could not create
$ac_file" "$LINENO" 5
34095 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
34096 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out
"`; test -n "$ac_out"; } &&
34097 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
34098 "$ac_tmp/out
"`; test -z "$ac_out"; } &&
34099 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING
: $ac_file contains a reference to the variable \
`datarootdir'
34100 which seems to be undefined. Please make sure it is defined" >&5
34101 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir
'
34102 which seems to be undefined. Please make sure it is defined" >&2;}
34104 rm -f "$ac_tmp/stdin"
34106 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
34107 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
34109 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
34115 if test x"$ac_file" != x-; then
34117 $as_echo "/* $configure_input */" \
34118 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
34119 } >"$ac_tmp/config.h" \
34120 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
34121 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
34122 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
34123 $as_echo "$as_me: $ac_file is unchanged" >&6;}
34126 mv "$ac_tmp/config.h" "$ac_file" \
34127 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
34130 $as_echo "/* $configure_input */" \
34131 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
34132 || as_fn_error $? "could not create -" "$LINENO" 5
34134 # Compute "$ac_file"'s index
in $config_headers.
34137 for _am_header
in $config_headers :; do
34138 case $_am_header in
34139 $_am_arg |
$_am_arg:* )
34142 _am_stamp_count
=`expr $_am_stamp_count + 1` ;;
34145 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
34146 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
34147 X"$_am_arg" : 'X\(//\)[^/]' \| \
34148 X"$_am_arg" : 'X\(//\)$' \| \
34149 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
34150 $as_echo X"$_am_arg" |
34151 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
34155 /^X\(\/\/\)[^/].*/{
34167 s/.*/./; q'`/stamp-h
$_am_stamp_count
34170 :C
) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
34171 $as_echo "$as_me: executing $ac_file commands" >&6;}
34176 case $ac_file$ac_mode in
34177 "depfiles":C
) test x
"$AMDEP_TRUE" != x
"" ||
{
34178 # Older Autoconf quotes --file arguments for eval, but not when files
34179 # are listed without --file. Let's play safe and only enable the eval
34180 # if we detect the quoting.
34181 case $CONFIG_FILES in
34182 *\'*) eval set x
"$CONFIG_FILES" ;;
34183 *) set x
$CONFIG_FILES ;;
34188 # Strip MF so we end up with the name of the file.
34189 mf
=`echo "$mf" | sed -e 's/:.*$//'`
34190 # Check whether this is an Automake generated Makefile or not.
34191 # We used to match only the files named 'Makefile.in', but
34192 # some people rename them; so instead we look at the file content.
34193 # Grep'ing the first line is not enough: some people post-process
34194 # each Makefile.in and add a new line on top of each file to say so.
34195 # Grep'ing the whole file is not good either: AIX grep has a line
34196 # limit of 2048, but all sed's we know have understand at least 4000.
34197 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" |
grep X
>/dev
/null
2>&1; then
34198 dirpart
=`$as_dirname -- "$mf" ||
34199 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
34200 X"$mf" : 'X\(//\)[^/]' \| \
34201 X"$mf" : 'X\(//\)$' \| \
34202 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
34204 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
34208 /^X\(\/\/\)[^/].*/{
34224 # Extract the definition of DEPDIR, am__include, and am__quote
34225 # from the Makefile without running 'make'.
34226 DEPDIR
=`sed -n 's/^DEPDIR = //p' < "$mf"`
34227 test -z "$DEPDIR" && continue
34228 am__include
=`sed -n 's/^am__include = //p' < "$mf"`
34229 test -z "$am__include" && continue
34230 am__quote
=`sed -n 's/^am__quote = //p' < "$mf"`
34231 # Find all dependency output files, they are included files with
34232 # $(DEPDIR) in their names. We invoke sed twice because it is the
34233 # simplest approach to changing $(DEPDIR) to its actual value in the
34235 for file in `sed -n "
34236 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
34237 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
34238 # Make sure the directory exists.
34239 test -f "$dirpart/$file" && continue
34240 fdir
=`$as_dirname -- "$file" ||
34241 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
34242 X"$file" : 'X\(//\)[^/]' \| \
34243 X"$file" : 'X\(//\)$' \| \
34244 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
34245 $as_echo X"$file" |
34246 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
34250 /^X\(\/\/\)[^/].*/{
34263 as_dir
=$dirpart/$fdir; as_fn_mkdir_p
34264 # echo "creating $dirpart/$file"
34265 echo '# dummy' > "$dirpart/$file"
34271 case x
$CONFIG_HEADERS in
34272 xconfig.h
:config.
in)
34283 ac_clean_files
=$ac_clean_files_save
34285 test $ac_write_fail = 0 ||
34286 as_fn_error $?
"write failure creating $CONFIG_STATUS" "$LINENO" 5
34289 # configure is writing to config.log, and then calls config.status.
34290 # config.status does its own redirection, appending to config.log.
34291 # Unfortunately, on DOS this fails, as config.log is still kept open
34292 # by configure, so config.status won't be able to write to it; its
34293 # output is simply discarded. So we exec the FD to /dev/null,
34294 # effectively closing config.log, so it can be properly (re)opened and
34295 # appended to by config.status. When coming back to configure, we
34296 # need to make the FD available again.
34297 if test "$no_create" != yes; then
34299 ac_config_status_args
=
34300 test "$silent" = yes &&
34301 ac_config_status_args
="$ac_config_status_args --quiet"
34303 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success
=false
34305 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
34306 # would make configure fail if this is the last instruction.
34307 $ac_cs_success || as_fn_exit
1
34309 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no
; then
34310 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
34311 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}