2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.69.79-0bdae for GNU diffutils 3.3.
5 # Report bugs to <bug-diffutils@gnu.org>.
8 # Copyright (C) 1992-1996, 1998-2013 Free Software Foundation, Inc.
11 # This configure script is free software; the Free Software Foundation
12 # gives unlimited permission to copy, distribute and modify it.
13 ## -------------------- ##
14 ## M4sh Initialization. ##
15 ## -------------------- ##
17 # Be more Bourne compatible
18 DUALCASE=1; export DUALCASE # for MKS sh
19 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
22 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23 # is contrary to our usage. Disable this feature.
24 alias -g '${1+"$@"}'='"$@"'
27 case `(set -o) 2>/dev/null` in #(
36 # The user is always right.
37 if test "${PATH_SEPARATOR+set}" != set; then
39 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
40 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
47 # We need space, tab and new line, in precisely that order. Quoting is
48 # there to prevent editors from complaining about space-tab.
49 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
50 # splitting by setting IFS to empty value.)
56 # Find who we are. Look in the path if we contain no directory separator.
59 *[\\/]* ) as_myself=$0 ;;
60 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
69 test -r "$as_dir$0" && as_myself=$as_dir$0 && break
75 # We did not find ourselves, most probably we were run as `sh COMMAND'
76 # in which case we are not to be found in the path.
77 if test "x$as_myself" = x; then
80 if test ! -f "$as_myself"; then
81 printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
85 # Unset variables that we do not need and which cause bugs (e.g. in
86 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
87 # suppresses any "Segmentation fault" message there. '((' could
88 # trigger a bug in pdksh 5.2.14.
89 for as_var in BASH_ENV ENV MAIL MAILPATH
90 do eval test x\${$as_var+set} = xset \
91 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
104 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
106 # Use a proper internal environment variable to ensure we don't fall
107 # into an infinite loop, continuously re-executing ourselves.
108 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
109 _as_can_reexec=no; export _as_can_reexec;
110 # We cannot yet assume a decent shell, so we have to provide a
111 # neutralization value for shells without unset; and this also
112 # works around shells that cannot unset nonexistent variables.
113 # Preserve -v and -x to the replacement shell.
116 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
118 *v*x* | *x*v* ) as_opts=-vx ;;
123 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
124 # Admittedly, this is quite paranoid, since all the known shells bail
125 # out after a failed `exec'.
126 printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2
129 # We don't want this to propagate to other subprocesses.
130 { _as_can_reexec=; unset _as_can_reexec;}
131 if test "x$CONFIG_SHELL" = x; then
132 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
135 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
136 # is contrary to our usage. Disable this feature.
137 alias -g '\${1+\"\$@\"}'='\"\$@\"'
140 case \`(set -o) 2>/dev/null\` in #(
148 as_required="as_fn_return () { (exit \$1); }
149 as_fn_success () { as_fn_return 0; }
150 as_fn_failure () { as_fn_return 1; }
151 as_fn_ret_success () { return 0; }
152 as_fn_ret_failure () { return 1; }
155 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
156 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
157 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
158 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
159 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
162 exitcode=1; echo positional parameters were not saved.
164 test x\$exitcode = x0 || exit 1
166 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
167 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
168 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
169 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
170 test \$(( 1 + 1 )) = 2 || exit 1"
171 if (eval "$as_required") 2>/dev/null; then :
176 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
179 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
181 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
187 *) as_dir=$as_dir/ ;;
192 for as_base in sh bash ksh sh5; do
193 # Try only shells that exist, to save several forks.
194 as_shell=$as_dir$as_base
195 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
196 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
197 CONFIG_SHELL=$as_shell as_have_required=yes
198 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
207 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
208 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
209 CONFIG_SHELL=$SHELL as_have_required=yes
213 if test "x$CONFIG_SHELL" != x; then :
215 # We cannot yet assume a decent shell, so we have to provide a
216 # neutralization value for shells without unset; and this also
217 # works around shells that cannot unset nonexistent variables.
218 # Preserve -v and -x to the replacement shell.
221 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
223 *v*x* | *x*v* ) as_opts=-vx ;;
228 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
229 # Admittedly, this is quite paranoid, since all the known shells bail
230 # out after a failed `exec'.
231 printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2
235 if test x$as_have_required = xno; then :
236 printf "%s\n" "$0: This script requires a shell more modern than all"
237 printf "%s\n" "$0: the shells that I found on your system."
238 if test x${ZSH_VERSION+set} = xset ; then
239 printf "%s\n" "$0: In particular, zsh $ZSH_VERSION has bugs and should"
240 printf "%s\n" "$0: be upgraded to zsh 4.3.4 or later."
242 printf "%s\n" "$0: Please tell bug-autoconf@gnu.org and
243 $0: bug-diffutils@gnu.org about your system, including any
244 $0: error possibly output before this message. Then install
245 $0: a modern shell, or manually run the script under such a
246 $0: shell if you do have one."
252 SHELL=${CONFIG_SHELL-/bin/sh}
254 # Unset more variables known to interfere with behavior of common tools.
255 CLICOLOR_FORCE= GREP_OPTIONS=
256 unset CLICOLOR_FORCE GREP_OPTIONS
258 ## --------------------- ##
259 ## M4sh Shell Functions. ##
260 ## --------------------- ##
263 # Portably unset VAR.
266 { eval $1=; unset $1;}
270 # as_fn_set_status STATUS
271 # -----------------------
272 # Set $? to STATUS, without forking.
280 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
290 # Create "$as_dir" as a directory, including parents if necessary.
295 -*) as_dir=./$as_dir;;
297 test -d "$as_dir" || eval $as_mkdir_p || {
301 *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
304 as_dirs="'$as_qdir' $as_dirs"
305 as_dir=`$as_dirname -- "$as_dir" ||
306 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
307 X"$as_dir" : 'X\(//\)[^/]' \| \
308 X"$as_dir" : 'X\(//\)$' \| \
309 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
310 printf "%s\n" X"$as_dir" |
311 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
328 test -d "$as_dir" && break
330 test -z "$as_dirs" || eval "mkdir $as_dirs"
331 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
336 # as_fn_executable_p FILE
337 # -----------------------
338 # Test if FILE is an executable regular file.
339 as_fn_executable_p ()
341 test -f "$1" && test -x "$1"
342 } # as_fn_executable_p
343 # as_fn_append VAR VALUE
344 # ----------------------
345 # Append the text in VALUE to the end of the definition contained in VAR. Take
346 # advantage of any shell optimizations that allow amortized linear growth over
347 # repeated appends, instead of the typical quadratic growth present in naive
349 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
350 eval 'as_fn_append ()
363 # Perform arithmetic evaluation on the ARGs, and store the result in the
364 # global $as_val. Take advantage of shells that can avoid forks. The arguments
365 # must be portable across $(()) and expr.
366 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
374 as_val=`expr "$@" || test $? -eq 1`
379 # as_fn_error STATUS ERROR [LINENO LOG_FD]
380 # ----------------------------------------
381 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
382 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
383 # script with STATUS, using 1 if that was 0.
386 as_status=$1; test $as_status -eq 0 && as_status=1
388 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
389 printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
391 printf "%s\n" "$as_me: error: $2" >&2
392 as_fn_exit $as_status
395 if expr a : '\(a\)' >/dev/null 2>&1 &&
396 test "X`expr 00001 : '.*\(...\)'`" = X001; then
402 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
408 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
414 as_me=`$as_basename -- "$0" ||
415 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
416 X"$0" : 'X\(//\)$' \| \
417 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
418 printf "%s\n" X/"$0" |
419 sed '/^.*\/\([^/][^/]*\)\/*$/{
433 # Avoid depending upon Character Ranges.
434 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
435 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
436 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
437 as_cr_digits='0123456789'
438 as_cr_alnum=$as_cr_Letters$as_cr_digits
441 as_lineno_1=$LINENO as_lineno_1a=$LINENO
442 as_lineno_2=$LINENO as_lineno_2a=$LINENO
443 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
444 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
445 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
457 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
461 chmod +x "$as_me.lineno" ||
462 { printf "%s\n" "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
464 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
465 # already done that, so ensure we don't try to do so again and fall
466 # in an infinite loop. This has already happened in practice.
467 _as_can_reexec=no; export _as_can_reexec
468 # Don't try to exec as it changes $[0], causing all sort of problems
469 # (the dirname of $[0] is not the place where we might find the
470 # original and so on. Autoconf is especially sensitive to this).
472 # Exit status is that of the last command.
476 ECHO_C= ECHO_N= ECHO_T=
477 case `echo -n x` in #(((((
479 case `echo 'xy\c'` in
480 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
482 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
489 rm -f conf$$ conf$$.exe conf$$.file
490 if test -d conf$$.dir; then
491 rm -f conf$$.dir/conf$$.file
494 mkdir conf$$.dir 2>/dev/null
496 if (echo >conf$$.file) 2>/dev/null; then
497 if ln -s conf$$.file conf$$ 2>/dev/null; then
499 # ... but there are two gotchas:
500 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
501 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
502 # In both cases, we have to default to `cp -pR'.
503 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
505 elif ln conf$$.file conf$$ 2>/dev/null; then
513 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
514 rmdir conf$$.dir 2>/dev/null
516 if mkdir -p . 2>/dev/null; then
517 as_mkdir_p='mkdir -p "$as_dir"'
519 test -d ./-p && rmdir ./-p
524 as_executable_p=as_fn_executable_p
526 # Sed expression to map a string onto a valid CPP name.
527 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
529 # Sed expression to map a string onto a valid variable name.
530 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
533 test -n "$DJDIR" || exec 7<&0 </dev/null
537 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
538 # so uname gets run too.
539 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
544 ac_default_prefix=/usr/local
546 ac_config_libobj_dir=.
553 # Identity of this package.
554 PACKAGE_NAME='GNU diffutils'
555 PACKAGE_TARNAME='diffutils'
556 PACKAGE_VERSION='3.3'
557 PACKAGE_STRING='GNU diffutils 3.3'
558 PACKAGE_BUGREPORT='bug-diffutils@gnu.org'
559 PACKAGE_URL='http://www.gnu.org/software/diffutils/'
561 ac_unique_file="src/diff.c"
562 # Factoring default headers for most tests.
563 ac_includes_default="\
565 #ifdef HAVE_SYS_TYPES_H
566 # include <sys/types.h>
568 #ifdef HAVE_SYS_STAT_H
569 # include <sys/stat.h>
571 #if defined STDC_HEADERS || defined HAVE_STDLIB_H
576 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
581 #ifdef HAVE_STRINGS_H
582 # include <strings.h>
584 #ifdef HAVE_INTTYPES_H
585 # include <inttypes.h>
596 gl_fnmatch_required=POSIX
597 gl_getopt_required=POSIX
598 gl_getopt_required=POSIX
600 ac_subst_vars='gltests_LTLIBOBJS
612 XGETTEXT_EXTRA_OPTIONS
620 GETTEXT_MACRO_VERSION
628 LIBDIFFUTILS_LTLIBDEPS
633 NEXT_AS_FIRST_DIRECTIVE_WCHAR_H
636 LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_FALSE
637 LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_TRUE
638 LIBUNISTRING_UNIWIDTH_H
639 LIBUNISTRING_UNITYPES_H
640 LIBUNISTRING_COMPILE_UNISTR_U8_UCTOMB_FALSE
641 LIBUNISTRING_COMPILE_UNISTR_U8_UCTOMB_TRUE
642 LIBUNISTRING_COMPILE_UNISTR_U8_MBTOUCR_FALSE
643 LIBUNISTRING_COMPILE_UNISTR_U8_MBTOUCR_TRUE
644 LIBUNISTRING_UNISTR_H
646 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
648 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
649 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
650 TIME_H_DEFINES_STRUCT_TIMESPEC
651 NEXT_AS_FIRST_DIRECTIVE_TIME_H
653 NEXT_AS_FIRST_DIRECTIVE_SYS_WAIT_H
657 NEXT_AS_FIRST_DIRECTIVE_SYS_TYPES_H
660 NEXT_AS_FIRST_DIRECTIVE_STRINGS_H
662 NEXT_AS_FIRST_DIRECTIVE_STRING_H
664 HAVE_DECL_STRNCASECMP
668 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
670 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
673 GL_GENERATE_STDBOOL_H_FALSE
674 GL_GENERATE_STDBOOL_H_TRUE
676 GL_GENERATE_STDARG_H_FALSE
677 GL_GENERATE_STDARG_H_TRUE
679 NEXT_AS_FIRST_DIRECTIVE_STDARG_H
681 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
684 REPLACE_PTHREAD_SIGMASK
686 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
687 HAVE_STRUCT_SIGACTION_SA_SIGACTION
693 HAVE_POSIX_SIGNALBLOCKING
696 GNULIB_SIGNAL_H_SIGPIPE
698 GNULIB_PTHREAD_SIGMASK
706 HAVE_DECL_LOCALTIME_R
801 REPLACE_CANONICALIZE_FILE_NAME
806 HAVE_STRUCT_RANDOM_DATA
829 HAVE_CANONICALIZE_FILE_NAME
860 GNULIB_CANONICALIZE_FILE_NAME
864 NEXT_AS_FIRST_DIRECTIVE_LOCALE_H
867 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
869 GL_GENERATE_STDDEF_H_FALSE
870 GL_GENERATE_STDDEF_H_TRUE
882 LOCALCHARSET_TESTS_ENVIRONMENT
884 HAVE_LANGINFO_YESEXPR
886 HAVE_LANGINFO_T_FMT_AMPM
887 HAVE_LANGINFO_CODESET
889 NEXT_AS_FIRST_DIRECTIVE_LANGINFO_H
897 NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H
910 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
912 UINT64_MAX_EQ_ULONG_MAX
913 UINT32_MAX_LT_UINTMAX_MAX
916 INT64_MAX_EQ_LONG_MAX
917 INT32_MAX_LT_INTMAX_MAX
927 GL_GENERATE_STDINT_H_FALSE
928 GL_GENERATE_STDINT_H_TRUE
937 HAVE_SIGNED_SIG_ATOMIC_T
940 BITSIZEOF_SIG_ATOMIC_T
943 APPLE_UNIVERSAL_BUILD
947 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
952 HAVE_UNSIGNED_LONG_LONG_INT
954 NEXT_AS_FIRST_DIRECTIVE_ICONV_H
956 GL_GENERATE_ICONV_H_FALSE
957 GL_GENERATE_ICONV_H_TRUE
968 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
970 REPLACE_STRUCT_TIMEVAL
978 GNULIB_GL_UNISTD_H_GETOPT
981 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H
983 WINDOWS_64_BIT_ST_SIZE
984 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
1026 REPLACE_STDIO_WRITE_FUNCS
1027 REPLACE_STDIO_READ_FUNCS
1036 REPLACE_OBSTACK_PRINTF
1061 HAVE_DECL_OBSTACK_PRINTF
1067 GNULIB_VSPRINTF_POSIX
1069 GNULIB_VPRINTF_POSIX
1071 GNULIB_VFPRINTF_POSIX
1078 GNULIB_STDIO_H_SIGPIPE
1079 GNULIB_STDIO_H_NONBLOCKING
1080 GNULIB_SPRINTF_POSIX
1094 GNULIB_OBSTACK_PRINTF_POSIX
1095 GNULIB_OBSTACK_PRINTF
1111 GNULIB_FPRINTF_POSIX
1120 GL_GENERATE_FNMATCH_H_FALSE
1121 GL_GENERATE_FNMATCH_H_TRUE
1124 GL_GENERATE_FLOAT_H_FALSE
1125 GL_GENERATE_FLOAT_H_TRUE
1127 NEXT_AS_FIRST_DIRECTIVE_FLOAT_H
1129 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H
1146 GL_GENERATE_ERRNO_H_FALSE
1147 GL_GENERATE_ERRNO_H_TRUE
1149 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H
1152 PRAGMA_SYSTEM_HEADER
1153 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
1158 HAVE_MSVC_INVALID_PARAMETER_HANDLER
1159 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
1160 UNISTD_H_HAVE_WINSOCK2_H
1181 REPLACE_GETDOMAINNAME
1192 HAVE_DECL_SETHOSTNAME
1193 HAVE_DECL_GETUSERSHELL
1194 HAVE_DECL_GETPAGESIZE
1195 HAVE_DECL_GETLOGIN_R
1196 HAVE_DECL_GETDOMAINNAME
1235 GNULIB_UNISTD_H_SIGPIPE
1236 GNULIB_UNISTD_H_NONBLOCKING
1262 GNULIB_GETDTABLESIZE
1263 GNULIB_GETDOMAINNAME
1378 GL_GENERATE_ALLOCA_H_FALSE
1379 GL_GENERATE_ALLOCA_H_TRUE
1382 GL_COND_LIBTOOL_FALSE
1383 GL_COND_LIBTOOL_TRUE
1417 AM_DEFAULT_VERBOSITY
1426 INSTALL_STRIP_PROGRAM
1468 program_transform_name
1481 enable_option_checking
1483 enable_dependency_tracking
1487 with_libsigsegv_prefix
1488 with_libiconv_prefix
1491 with_packager_version
1492 with_packager_bug_reports
1497 ac_precious_vars='build_alias
1508 # Initialize some variables set by options.
1510 ac_init_version=false
1511 ac_unrecognized_opts=
1512 ac_unrecognized_sep=
1513 # The variables have the same names as the options, with
1514 # dashes changed to underlines.
1515 cache_file=/dev/null
1522 program_transform_name=s,x,x,
1530 # Installation directory options.
1531 # These are left unexpanded so users can "make install exec_prefix=/foo"
1532 # and all the variables that are supposed to be based on exec_prefix
1533 # by default will actually change.
1534 # Use braces instead of parens because sh, perl, etc. also accept them.
1535 # (The list follows the same order as the GNU Coding Standards.)
1536 bindir='${exec_prefix}/bin'
1537 sbindir='${exec_prefix}/sbin'
1538 libexecdir='${exec_prefix}/libexec'
1539 datarootdir='${prefix}/share'
1540 datadir='${datarootdir}'
1541 sysconfdir='${prefix}/etc'
1542 sharedstatedir='${prefix}/com'
1543 localstatedir='${prefix}/var'
1544 includedir='${prefix}/include'
1545 oldincludedir='/usr/include'
1546 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1547 infodir='${datarootdir}/info'
1552 libdir='${exec_prefix}/lib'
1553 localedir='${datarootdir}/locale'
1554 mandir='${datarootdir}/man'
1560 # If the previous option needs an argument, assign it.
1561 if test -n "$ac_prev"; then
1562 eval $ac_prev=\$ac_option
1568 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1573 # Accept the important Cygnus configure options, so we can diagnose typos.
1575 case $ac_dashdash$ac_option in
1579 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1581 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1582 bindir=$ac_optarg ;;
1584 -build | --build | --buil | --bui | --bu)
1585 ac_prev=build_alias ;;
1586 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1587 build_alias=$ac_optarg ;;
1589 -cache-file | --cache-file | --cache-fil | --cache-fi \
1590 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1591 ac_prev=cache_file ;;
1592 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1593 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1594 cache_file=$ac_optarg ;;
1596 --config-cache | -C)
1597 cache_file=config.cache ;;
1599 -datadir | --datadir | --datadi | --datad)
1601 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1602 datadir=$ac_optarg ;;
1604 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1605 | --dataroo | --dataro | --datar)
1606 ac_prev=datarootdir ;;
1607 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1608 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1609 datarootdir=$ac_optarg ;;
1611 -disable-* | --disable-*)
1612 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1613 # Reject names that are not valid shell variable names.
1614 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1615 as_fn_error $? "invalid feature name: $ac_useropt"
1616 ac_useropt_orig=$ac_useropt
1617 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
1618 case $ac_user_opts in
1620 "enable_$ac_useropt"
1622 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1623 ac_unrecognized_sep=', ';;
1625 eval enable_$ac_useropt=no ;;
1627 -docdir | --docdir | --docdi | --doc | --do)
1629 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1630 docdir=$ac_optarg ;;
1632 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1634 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1635 dvidir=$ac_optarg ;;
1637 -enable-* | --enable-*)
1638 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1639 # Reject names that are not valid shell variable names.
1640 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1641 as_fn_error $? "invalid feature name: $ac_useropt"
1642 ac_useropt_orig=$ac_useropt
1643 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
1644 case $ac_user_opts in
1646 "enable_$ac_useropt"
1648 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1649 ac_unrecognized_sep=', ';;
1651 eval enable_$ac_useropt=\$ac_optarg ;;
1653 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1654 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1655 | --exec | --exe | --ex)
1656 ac_prev=exec_prefix ;;
1657 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1658 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1659 | --exec=* | --exe=* | --ex=*)
1660 exec_prefix=$ac_optarg ;;
1662 -gas | --gas | --ga | --g)
1663 # Obsolete; use --with-gas.
1666 -help | --help | --hel | --he | -h)
1667 ac_init_help=long ;;
1668 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1669 ac_init_help=recursive ;;
1670 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1671 ac_init_help=short ;;
1673 -host | --host | --hos | --ho)
1674 ac_prev=host_alias ;;
1675 -host=* | --host=* | --hos=* | --ho=*)
1676 host_alias=$ac_optarg ;;
1678 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1680 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1682 htmldir=$ac_optarg ;;
1684 -includedir | --includedir | --includedi | --included | --include \
1685 | --includ | --inclu | --incl | --inc)
1686 ac_prev=includedir ;;
1687 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1688 | --includ=* | --inclu=* | --incl=* | --inc=*)
1689 includedir=$ac_optarg ;;
1691 -infodir | --infodir | --infodi | --infod | --info | --inf)
1693 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1694 infodir=$ac_optarg ;;
1696 -libdir | --libdir | --libdi | --libd)
1698 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1699 libdir=$ac_optarg ;;
1701 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1702 | --libexe | --libex | --libe)
1703 ac_prev=libexecdir ;;
1704 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1705 | --libexe=* | --libex=* | --libe=*)
1706 libexecdir=$ac_optarg ;;
1708 -localedir | --localedir | --localedi | --localed | --locale)
1709 ac_prev=localedir ;;
1710 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1711 localedir=$ac_optarg ;;
1713 -localstatedir | --localstatedir | --localstatedi | --localstated \
1714 | --localstate | --localstat | --localsta | --localst | --locals)
1715 ac_prev=localstatedir ;;
1716 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1717 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1718 localstatedir=$ac_optarg ;;
1720 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1722 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1723 mandir=$ac_optarg ;;
1725 -nfp | --nfp | --nf)
1726 # Obsolete; use --without-fp.
1729 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1730 | --no-cr | --no-c | -n)
1733 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1734 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1737 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1738 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1739 | --oldin | --oldi | --old | --ol | --o)
1740 ac_prev=oldincludedir ;;
1741 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1742 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1743 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1744 oldincludedir=$ac_optarg ;;
1746 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1748 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1749 prefix=$ac_optarg ;;
1751 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1752 | --program-pre | --program-pr | --program-p)
1753 ac_prev=program_prefix ;;
1754 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1755 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1756 program_prefix=$ac_optarg ;;
1758 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1759 | --program-suf | --program-su | --program-s)
1760 ac_prev=program_suffix ;;
1761 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1762 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1763 program_suffix=$ac_optarg ;;
1765 -program-transform-name | --program-transform-name \
1766 | --program-transform-nam | --program-transform-na \
1767 | --program-transform-n | --program-transform- \
1768 | --program-transform | --program-transfor \
1769 | --program-transfo | --program-transf \
1770 | --program-trans | --program-tran \
1771 | --progr-tra | --program-tr | --program-t)
1772 ac_prev=program_transform_name ;;
1773 -program-transform-name=* | --program-transform-name=* \
1774 | --program-transform-nam=* | --program-transform-na=* \
1775 | --program-transform-n=* | --program-transform-=* \
1776 | --program-transform=* | --program-transfor=* \
1777 | --program-transfo=* | --program-transf=* \
1778 | --program-trans=* | --program-tran=* \
1779 | --progr-tra=* | --program-tr=* | --program-t=*)
1780 program_transform_name=$ac_optarg ;;
1782 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1784 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1785 pdfdir=$ac_optarg ;;
1787 -psdir | --psdir | --psdi | --psd | --ps)
1789 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1792 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1793 | -silent | --silent | --silen | --sile | --sil)
1796 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1798 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1800 sbindir=$ac_optarg ;;
1802 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1803 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1804 | --sharedst | --shareds | --shared | --share | --shar \
1806 ac_prev=sharedstatedir ;;
1807 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1808 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1809 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1811 sharedstatedir=$ac_optarg ;;
1813 -site | --site | --sit)
1815 -site=* | --site=* | --sit=*)
1818 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1820 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1821 srcdir=$ac_optarg ;;
1823 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1824 | --syscon | --sysco | --sysc | --sys | --sy)
1825 ac_prev=sysconfdir ;;
1826 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1827 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1828 sysconfdir=$ac_optarg ;;
1830 -target | --target | --targe | --targ | --tar | --ta | --t)
1831 ac_prev=target_alias ;;
1832 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1833 target_alias=$ac_optarg ;;
1835 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1838 -version | --version | --versio | --versi | --vers | -V)
1839 ac_init_version=: ;;
1842 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1843 # Reject names that are not valid shell variable names.
1844 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1845 as_fn_error $? "invalid package name: $ac_useropt"
1846 ac_useropt_orig=$ac_useropt
1847 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
1848 case $ac_user_opts in
1852 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1853 ac_unrecognized_sep=', ';;
1855 eval with_$ac_useropt=\$ac_optarg ;;
1857 -without-* | --without-*)
1858 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1859 # Reject names that are not valid shell variable names.
1860 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1861 as_fn_error $? "invalid package name: $ac_useropt"
1862 ac_useropt_orig=$ac_useropt
1863 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
1864 case $ac_user_opts in
1868 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1869 ac_unrecognized_sep=', ';;
1871 eval with_$ac_useropt=no ;;
1874 # Obsolete; use --with-x.
1877 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1878 | --x-incl | --x-inc | --x-in | --x-i)
1879 ac_prev=x_includes ;;
1880 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1881 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1882 x_includes=$ac_optarg ;;
1884 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1885 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1886 ac_prev=x_libraries ;;
1887 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1888 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1889 x_libraries=$ac_optarg ;;
1891 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1892 Try \`$0 --help' for more information"
1896 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1897 # Reject names that are not valid shell variable names.
1898 case $ac_envvar in #(
1899 '' | [0-9]* | *[!_$as_cr_alnum]* )
1900 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1902 eval $ac_envvar=\$ac_optarg
1903 export $ac_envvar ;;
1906 # FIXME: should be removed in autoconf 3.0.
1907 printf "%s\n" "$as_me: WARNING: you should use --build, --host, --target" >&2
1908 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1909 printf "%s\n" "$as_me: WARNING: invalid host type: $ac_option" >&2
1910 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1916 if test -n "$ac_prev"; then
1917 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1918 as_fn_error $? "missing argument to $ac_option"
1921 if test -n "$ac_unrecognized_opts"; then
1922 case $enable_option_checking in
1924 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1925 *) printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1929 # Check all directory arguments for consistency.
1930 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1931 datadir sysconfdir sharedstatedir localstatedir includedir \
1932 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1933 libdir localedir mandir
1935 eval ac_val=\$$ac_var
1936 # Remove trailing slashes.
1939 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1940 eval $ac_var=\$ac_val;;
1942 # Be sure to have absolute directory names.
1944 [\\/$]* | ?:[\\/]* ) continue;;
1945 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1947 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1950 # There might be people who depend on the old broken behavior: `$host'
1951 # used to hold the argument of --host etc.
1952 # FIXME: To remove some day.
1955 target=$target_alias
1957 # FIXME: To remove some day.
1958 if test "x$host_alias" != x; then
1959 if test "x$build_alias" = x; then
1960 cross_compiling=maybe
1961 elif test "x$build_alias" != "x$host_alias"; then
1967 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1969 test "$silent" = yes && exec 6>/dev/null
1972 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1973 ac_ls_di=`ls -di .` &&
1974 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1975 as_fn_error $? "working directory cannot be determined"
1976 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1977 as_fn_error $? "pwd does not report name of working directory"
1980 # Find the source files, if location was not specified.
1981 if test -z "$srcdir"; then
1982 ac_srcdir_defaulted=yes
1983 # Try the directory containing this script, then the parent directory.
1984 ac_confdir=`$as_dirname -- "$as_myself" ||
1985 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1986 X"$as_myself" : 'X\(//\)[^/]' \| \
1987 X"$as_myself" : 'X\(//\)$' \| \
1988 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1989 printf "%s\n" X"$as_myself" |
1990 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
2008 if test ! -r "$srcdir/$ac_unique_file"; then
2012 ac_srcdir_defaulted=no
2014 if test ! -r "$srcdir/$ac_unique_file"; then
2015 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
2016 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
2018 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
2020 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
2022 # When building in place, set srcdir=.
2023 if test "$ac_abs_confdir" = "$ac_pwd"; then
2026 # Remove unnecessary trailing slashes from srcdir.
2027 # Double slashes in file names in object file debugging info
2028 # mess up M-x gdb in Emacs.
2030 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
2032 for ac_var in $ac_precious_vars; do
2033 eval ac_env_${ac_var}_set=\${${ac_var}+set}
2034 eval ac_env_${ac_var}_value=\$${ac_var}
2035 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
2036 eval ac_cv_env_${ac_var}_value=\$${ac_var}
2040 # Report the --help message.
2042 if test "$ac_init_help" = "long"; then
2043 # Omit some internal or obsolete options to make the list less imposing.
2044 # This message is too long to be a string in the A/UX 3.1 sh.
2046 \`configure' configures GNU diffutils 3.3 to adapt to many kinds of systems.
2048 Usage: $0 [OPTION]... [VAR=VALUE]...
2050 To assign environment variables (e.g., CC, CFLAGS...), specify them as
2051 VAR=VALUE. See below for descriptions of some of the useful variables.
2053 Defaults for the options are specified in brackets.
2056 -h, --help display this help and exit
2057 --help=short display options specific to this package
2058 --help=recursive display the short help of all the included packages
2059 -V, --version display version information and exit
2060 -q, --quiet, --silent do not print \`checking ...' messages
2061 --cache-file=FILE cache test results in FILE [disabled]
2062 -C, --config-cache alias for \`--cache-file=config.cache'
2063 -n, --no-create do not create output files
2064 --srcdir=DIR find the sources in DIR [configure dir or \`..']
2066 Installation directories:
2067 --prefix=PREFIX install architecture-independent files in PREFIX
2068 [$ac_default_prefix]
2069 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
2072 By default, \`make install' will install all the files in
2073 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
2074 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
2075 for instance \`--prefix=\$HOME'.
2077 For better control, use the options below.
2079 Fine tuning of the installation directories:
2080 --bindir=DIR user executables [EPREFIX/bin]
2081 --sbindir=DIR system admin executables [EPREFIX/sbin]
2082 --libexecdir=DIR program executables [EPREFIX/libexec]
2083 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
2084 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
2085 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
2086 --libdir=DIR object code libraries [EPREFIX/lib]
2087 --includedir=DIR C header files [PREFIX/include]
2088 --oldincludedir=DIR C header files for non-gcc [/usr/include]
2089 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
2090 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
2091 --infodir=DIR info documentation [DATAROOTDIR/info]
2092 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
2093 --mandir=DIR man documentation [DATAROOTDIR/man]
2094 --docdir=DIR documentation root [DATAROOTDIR/doc/diffutils]
2095 --htmldir=DIR html documentation [DOCDIR]
2096 --dvidir=DIR dvi documentation [DOCDIR]
2097 --pdfdir=DIR pdf documentation [DOCDIR]
2098 --psdir=DIR ps documentation [DOCDIR]
2104 --program-prefix=PREFIX prepend PREFIX to installed program names
2105 --program-suffix=SUFFIX append SUFFIX to installed program names
2106 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
2109 --build=BUILD configure for building on BUILD [guessed]
2110 --host=HOST cross-compile to build programs to run on HOST [BUILD]
2114 if test -n "$ac_init_help"; then
2115 case $ac_init_help in
2116 short | recursive ) echo "Configuration of GNU diffutils 3.3:";;
2121 --disable-option-checking ignore unrecognized --enable/--with options
2122 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
2123 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
2124 --enable-silent-rules less verbose build output (undo: "make V=1")
2125 --disable-silent-rules verbose build output (undo: "make V=0")
2126 --enable-dependency-tracking
2127 do not reject slow dependency extractors
2128 --disable-dependency-tracking
2129 speeds up one-time build
2130 --disable-largefile omit support for large files
2131 --disable-rpath do not hardcode runtime library paths
2132 --enable-gcc-warnings turn on lots of GCC warnings (for developers)
2133 --disable-nls do not use Native Language Support
2136 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
2137 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
2138 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
2139 --with-libsigsegv-prefix[=DIR] search for libsigsegv in DIR/include and DIR/lib
2140 --without-libsigsegv-prefix don't search for libsigsegv in includedir and libdir
2141 --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
2142 --without-libiconv-prefix don't search for libiconv in includedir and libdir
2143 --without-included-regex
2144 don't compile regex; this is the default on systems
2145 with recent-enough versions of the GNU C Library
2146 (use with caution on other systems).
2147 --with-packager String identifying the packager of this software
2148 --with-packager-version Packager-specific version information
2149 --with-packager-bug-reports
2150 Packager info for bug reports (URL/e-mail/...)
2151 --with-libintl-prefix[=DIR] search for libintl in DIR/include and DIR/lib
2152 --without-libintl-prefix don't search for libintl in includedir and libdir
2154 Some influential environment variables:
2155 CC C compiler command
2156 CFLAGS C compiler flags
2157 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2158 nonstandard directory <lib dir>
2159 LIBS libraries to pass to the linker, e.g. -l<library>
2160 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2161 you have headers in a nonstandard directory <include dir>
2164 Use these variables to override the choices made by `configure' or to help
2165 it to find libraries and programs with nonstandard names/locations.
2167 Report bugs to <bug-diffutils@gnu.org>.
2168 GNU diffutils home page: <http://www.gnu.org/software/diffutils/>.
2169 General help using GNU software: <http://www.gnu.org/gethelp/>.
2174 if test "$ac_init_help" = "recursive"; then
2175 # If there are subdirs, report their specific --help.
2176 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2177 test -d "$ac_dir" ||
2178 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2183 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2185 ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'`
2186 # A ".." for each directory in $ac_dir_suffix.
2187 ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2188 case $ac_top_builddir_sub in
2189 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2190 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2193 ac_abs_top_builddir=$ac_pwd
2194 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2195 # for backward compatibility:
2196 ac_top_builddir=$ac_top_build_prefix
2199 .) # We are building in place.
2201 ac_top_srcdir=$ac_top_builddir_sub
2202 ac_abs_top_srcdir=$ac_pwd ;;
2203 [\\/]* | ?:[\\/]* ) # Absolute name.
2204 ac_srcdir=$srcdir$ac_dir_suffix;
2205 ac_top_srcdir=$srcdir
2206 ac_abs_top_srcdir=$srcdir ;;
2208 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2209 ac_top_srcdir=$ac_top_build_prefix$srcdir
2210 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2212 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2214 cd "$ac_dir" || { ac_status=$?; continue; }
2215 # Check for guested configure.
2216 if test -f "$ac_srcdir/configure.gnu"; then
2218 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2219 elif test -f "$ac_srcdir/configure"; then
2221 $SHELL "$ac_srcdir/configure" --help=recursive
2223 printf "%s\n" "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2225 cd "$ac_pwd" || { ac_status=$?; break; }
2229 test -n "$ac_init_help" && exit $ac_status
2230 if $ac_init_version; then
2232 GNU diffutils configure 3.3
2233 generated by GNU Autoconf 2.69.79-0bdae
2235 Copyright (C) 2013 Free Software Foundation, Inc.
2236 This configure script is free software; the Free Software Foundation
2237 gives unlimited permission to copy, distribute and modify it.
2242 ## ------------------------ ##
2243 ## Autoconf initialization. ##
2244 ## ------------------------ ##
2246 # ac_fn_c_try_compile LINENO
2247 # --------------------------
2248 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2249 ac_fn_c_try_compile ()
2251 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2252 rm -f conftest.$ac_objext
2253 if { { ac_try="$ac_compile"
2255 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2256 *) ac_try_echo=$ac_try;;
2258 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2259 printf "%s\n" "$ac_try_echo"; } >&5
2260 (eval "$ac_compile") 2>conftest.err
2262 if test -s conftest.err; then
2263 grep -v '^ *+' conftest.err >conftest.er1
2264 cat conftest.er1 >&5
2265 mv -f conftest.er1 conftest.err
2267 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2268 test $ac_status = 0; } && {
2269 test -z "$ac_c_werror_flag" ||
2270 test ! -s conftest.err
2271 } && test -s conftest.$ac_objext; then :
2274 printf "%s\n" "$as_me: failed program was:" >&5
2275 sed 's/^/| /' conftest.$ac_ext >&5
2279 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2280 as_fn_set_status $ac_retval
2282 } # ac_fn_c_try_compile
2284 # ac_fn_c_try_cpp LINENO
2285 # ----------------------
2286 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2289 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2290 if { { ac_try="$ac_cpp conftest.$ac_ext"
2292 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2293 *) ac_try_echo=$ac_try;;
2295 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2296 printf "%s\n" "$ac_try_echo"; } >&5
2297 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2299 if test -s conftest.err; then
2300 grep -v '^ *+' conftest.err >conftest.er1
2301 cat conftest.er1 >&5
2302 mv -f conftest.er1 conftest.err
2304 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2305 test $ac_status = 0; } > conftest.i && {
2306 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2307 test ! -s conftest.err
2311 printf "%s\n" "$as_me: failed program was:" >&5
2312 sed 's/^/| /' conftest.$ac_ext >&5
2316 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2317 as_fn_set_status $ac_retval
2321 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2322 # -------------------------------------------------------
2323 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2324 # the include files in INCLUDES and setting the cache variable VAR
2326 ac_fn_c_check_header_mongrel ()
2328 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2329 if eval \${$3+:} false; then :
2330 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2331 printf %s "checking for $2... " >&6; }
2332 if eval \${$3+:} false; then :
2333 printf %s "(cached) " >&6
2336 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2337 printf "%s\n" "$ac_res" >&6; }
2339 # Is the header compilable?
2340 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2341 printf %s "checking $2 usability... " >&6; }
2342 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2343 /* end confdefs.h. */
2347 if ac_fn_c_try_compile "$LINENO"; then :
2348 ac_header_compiler=yes
2350 ac_header_compiler=no
2352 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2353 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2354 printf "%s\n" "$ac_header_compiler" >&6; }
2356 # Is the header present?
2357 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2358 printf %s "checking $2 presence... " >&6; }
2359 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2360 /* end confdefs.h. */
2363 if ac_fn_c_try_cpp "$LINENO"; then :
2364 ac_header_preproc=yes
2366 ac_header_preproc=no
2368 rm -f conftest.err conftest.i conftest.$ac_ext
2369 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2370 printf "%s\n" "$ac_header_preproc" >&6; }
2372 # So? What about this header?
2373 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2375 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2376 printf "%s\n" "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2377 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2378 printf "%s\n" "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2381 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2382 printf "%s\n" "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2383 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2384 printf "%s\n" "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2385 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2386 printf "%s\n" "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2387 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2388 printf "%s\n" "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2389 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2390 printf "%s\n" "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2391 ( printf "%s\n" "## ------------------------------------ ##
2392 ## Report this to bug-diffutils@gnu.org ##
2393 ## ------------------------------------ ##"
2394 ) | sed "s/^/$as_me: WARNING: /" >&2
2397 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2398 printf %s "checking for $2... " >&6; }
2399 if eval \${$3+:} false; then :
2400 printf %s "(cached) " >&6
2402 eval "$3=\$ac_header_compiler"
2405 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2406 printf "%s\n" "$ac_res" >&6; }
2408 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2410 } # ac_fn_c_check_header_mongrel
2412 # ac_fn_c_try_run LINENO
2413 # ----------------------
2414 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2415 # that executables *can* be run.
2418 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2419 if { { ac_try="$ac_link"
2421 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2422 *) ac_try_echo=$ac_try;;
2424 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2425 printf "%s\n" "$ac_try_echo"; } >&5
2426 (eval "$ac_link") 2>&5
2428 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2429 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2430 { { case "(($ac_try" in
2431 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2432 *) ac_try_echo=$ac_try;;
2434 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2435 printf "%s\n" "$ac_try_echo"; } >&5
2436 (eval "$ac_try") 2>&5
2438 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2439 test $ac_status = 0; }; }; then :
2442 printf "%s\n" "$as_me: program exited with status $ac_status" >&5
2443 printf "%s\n" "$as_me: failed program was:" >&5
2444 sed 's/^/| /' conftest.$ac_ext >&5
2446 ac_retval=$ac_status
2448 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2449 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2450 as_fn_set_status $ac_retval
2454 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2455 # -------------------------------------------------------
2456 # Tests whether HEADER exists and can be compiled using the include files in
2457 # INCLUDES, setting the cache variable VAR accordingly.
2458 ac_fn_c_check_header_compile ()
2460 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2461 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2462 printf %s "checking for $2... " >&6; }
2463 if eval \${$3+:} false; then :
2464 printf %s "(cached) " >&6
2466 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2467 /* end confdefs.h. */
2471 if ac_fn_c_try_compile "$LINENO"; then :
2476 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2479 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2480 printf "%s\n" "$ac_res" >&6; }
2481 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2483 } # ac_fn_c_check_header_compile
2485 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2486 # -------------------------------------------
2487 # Tests whether TYPE exists after having included INCLUDES, setting cache
2488 # variable VAR accordingly.
2489 ac_fn_c_check_type ()
2491 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2492 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2493 printf %s "checking for $2... " >&6; }
2494 if eval \${$3+:} false; then :
2495 printf %s "(cached) " >&6
2498 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2499 /* end confdefs.h. */
2510 if ac_fn_c_try_compile "$LINENO"; then :
2511 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2512 /* end confdefs.h. */
2523 if ac_fn_c_try_compile "$LINENO"; then :
2528 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2530 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2533 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2534 printf "%s\n" "$ac_res" >&6; }
2535 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2537 } # ac_fn_c_check_type
2539 # ac_fn_c_try_link LINENO
2540 # -----------------------
2541 # Try to link conftest.$ac_ext, and return whether this succeeded.
2544 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2545 rm -f conftest.$ac_objext conftest$ac_exeext
2546 if { { ac_try="$ac_link"
2548 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2549 *) ac_try_echo=$ac_try;;
2551 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2552 printf "%s\n" "$ac_try_echo"; } >&5
2553 (eval "$ac_link") 2>conftest.err
2555 if test -s conftest.err; then
2556 grep -v '^ *+' conftest.err >conftest.er1
2557 cat conftest.er1 >&5
2558 mv -f conftest.er1 conftest.err
2560 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2561 test $ac_status = 0; } && {
2562 test -z "$ac_c_werror_flag" ||
2563 test ! -s conftest.err
2564 } && test -s conftest$ac_exeext && {
2565 test "$cross_compiling" = yes ||
2566 test -x conftest$ac_exeext
2570 printf "%s\n" "$as_me: failed program was:" >&5
2571 sed 's/^/| /' conftest.$ac_ext >&5
2575 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2576 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2577 # interfere with the next link command; also delete a directory that is
2578 # left behind by Apple's compiler. We do this before executing the actions.
2579 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2580 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2581 as_fn_set_status $ac_retval
2583 } # ac_fn_c_try_link
2585 # ac_fn_c_check_func LINENO FUNC VAR
2586 # ----------------------------------
2587 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2588 ac_fn_c_check_func ()
2590 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2591 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2592 printf %s "checking for $2... " >&6; }
2593 if eval \${$3+:} false; then :
2594 printf %s "(cached) " >&6
2596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2597 /* end confdefs.h. */
2598 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2599 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2600 #define $2 innocuous_$2
2602 /* System header to define __stub macros and hopefully few prototypes,
2603 which can conflict with char $2 (); below. */
2608 /* Override any GCC internal prototype to avoid an error.
2609 Use char because int might match the return type of a GCC
2610 builtin and then its argument prototype would still apply. */
2615 /* The GNU C library defines this for functions which it implements
2616 to always fail with ENOSYS. Some functions are actually named
2617 something starting with __ and the normal name is an alias. */
2618 #if defined __stub_$2 || defined __stub___$2
2630 if ac_fn_c_try_link "$LINENO"; then :
2635 rm -f core conftest.err conftest.$ac_objext \
2636 conftest$ac_exeext conftest.$ac_ext
2639 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2640 printf "%s\n" "$ac_res" >&6; }
2641 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2643 } # ac_fn_c_check_func
2645 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2646 # ---------------------------------------------
2647 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2649 ac_fn_c_check_decl ()
2651 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2652 as_decl_name=`echo $2|sed 's/ *(.*//'`
2653 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2654 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2655 printf %s "checking whether $as_decl_name is declared... " >&6; }
2656 if eval \${$3+:} false; then :
2657 printf %s "(cached) " >&6
2659 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2660 /* end confdefs.h. */
2665 #ifndef $as_decl_name
2667 (void) $as_decl_use;
2669 (void) $as_decl_name;
2677 if ac_fn_c_try_compile "$LINENO"; then :
2682 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2685 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2686 printf "%s\n" "$ac_res" >&6; }
2687 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2689 } # ac_fn_c_check_decl
2691 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2692 # --------------------------------------------
2693 # Tries to find the compile-time value of EXPR in a program that includes
2694 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2696 ac_fn_c_compute_int ()
2698 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2699 if test "$cross_compiling" = yes; then
2700 # Depending upon the size, compute the lo and hi bounds.
2701 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2702 /* end confdefs.h. */
2707 static int test_array [1 - 2 * !(($2) >= 0)];
2709 return test_array [0];
2715 if ac_fn_c_try_compile "$LINENO"; then :
2718 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2719 /* end confdefs.h. */
2724 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2726 return test_array [0];
2732 if ac_fn_c_try_compile "$LINENO"; then :
2733 ac_hi=$ac_mid; break
2735 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2736 if test $ac_lo -le $ac_mid; then
2740 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2742 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2745 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2746 /* end confdefs.h. */
2751 static int test_array [1 - 2 * !(($2) < 0)];
2753 return test_array [0];
2759 if ac_fn_c_try_compile "$LINENO"; then :
2762 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2763 /* end confdefs.h. */
2768 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2770 return test_array [0];
2776 if ac_fn_c_try_compile "$LINENO"; then :
2777 ac_lo=$ac_mid; break
2779 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2780 if test $ac_mid -le $ac_hi; then
2784 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2786 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2791 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2793 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2794 # Binary search between lo and hi bounds.
2795 while test "x$ac_lo" != "x$ac_hi"; do
2796 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2797 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2798 /* end confdefs.h. */
2803 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2805 return test_array [0];
2811 if ac_fn_c_try_compile "$LINENO"; then :
2814 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2816 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2819 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2823 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2824 /* end confdefs.h. */
2826 static long int longval () { return $2; }
2827 static unsigned long int ulongval () { return $2; }
2834 FILE *f = fopen ("conftest.val", "w");
2839 long int i = longval ();
2842 fprintf (f, "%ld", i);
2846 unsigned long int i = ulongval ();
2849 fprintf (f, "%lu", i);
2851 /* Do not output a trailing newline, as this causes \r\n confusion
2852 on some platforms. */
2853 return ferror (f) || fclose (f) != 0;
2859 if ac_fn_c_try_run "$LINENO"; then :
2860 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2864 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2865 conftest.$ac_objext conftest.beam conftest.$ac_ext
2869 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2870 as_fn_set_status $ac_retval
2872 } # ac_fn_c_compute_int
2874 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2875 # ----------------------------------------------------
2876 # Tries to find if the field MEMBER exists in type AGGR, after including
2877 # INCLUDES, setting cache variable VAR accordingly.
2878 ac_fn_c_check_member ()
2880 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2881 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2882 printf %s "checking for $2.$3... " >&6; }
2883 if eval \${$4+:} false; then :
2884 printf %s "(cached) " >&6
2886 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2887 /* end confdefs.h. */
2899 if ac_fn_c_try_compile "$LINENO"; then :
2902 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2903 /* end confdefs.h. */
2909 if (sizeof ac_aggr.$3)
2915 if ac_fn_c_try_compile "$LINENO"; then :
2920 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2922 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2925 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2926 printf "%s\n" "$ac_res" >&6; }
2927 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2929 } # ac_fn_c_check_member
2930 cat >config.log <<_ACEOF
2931 This file contains any messages produced by compilers while
2932 running configure, to aid debugging if configure makes a mistake.
2934 It was created by GNU diffutils $as_me 3.3, which was
2935 generated by GNU Autoconf 2.69.79-0bdae. Invocation command line was
2947 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2948 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2949 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2950 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2951 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2953 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2954 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2956 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2957 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2958 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2959 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2960 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2961 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2962 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2966 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2970 case $as_dir in #(((
2973 *) as_dir=$as_dir/ ;;
2975 printf "%s\n" "PATH: $as_dir"
2991 # Keep a trace of the command line.
2992 # Strip out --no-create and --no-recursion so they do not pile up.
2993 # Strip out --silent because we don't want to record it for future runs.
2994 # Also quote any args containing shell meta-characters.
2995 # Make two passes to allow for proper duplicate-argument suppression.
2999 ac_must_keep_next=false
3005 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
3006 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
3007 | -silent | --silent | --silen | --sile | --sil)
3010 ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
3013 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
3015 as_fn_append ac_configure_args1 " '$ac_arg'"
3016 if test $ac_must_keep_next = true; then
3017 ac_must_keep_next=false # Got value, back to normal.
3020 *=* | --config-cache | -C | -disable-* | --disable-* \
3021 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
3022 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
3023 | -with-* | --with-* | -without-* | --without-* | --x)
3024 case "$ac_configure_args0 " in
3025 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
3028 -* ) ac_must_keep_next=true ;;
3031 as_fn_append ac_configure_args " '$ac_arg'"
3036 { ac_configure_args0=; unset ac_configure_args0;}
3037 { ac_configure_args1=; unset ac_configure_args1;}
3039 # When interrupted or exit'd, cleanup temporary files, and complete
3040 # config.log. We remove comments because anyway the quotes in there
3041 # would cause problems or look ugly.
3042 # WARNING: Use '\'' to represent an apostrophe within the trap.
3043 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3044 trap 'exit_status=$?
3047 # Save into config.log some information that might help in debugging.
3051 printf "%s\n" "## ---------------- ##
3052 ## Cache variables. ##
3053 ## ---------------- ##"
3055 # The following way of writing the cache mishandles newlines in values,
3057 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3058 eval ac_val=\$$ac_var
3062 *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3063 printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3066 _ | IFS | as_nl) ;; #(
3067 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3068 *) { eval $ac_var=; unset $ac_var;} ;;
3073 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3074 *${as_nl}ac_space=\ *)
3076 "s/'\''/'\''\\\\'\'''\''/g;
3077 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3080 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3087 printf "%s\n" "## ----------------- ##
3088 ## Output variables. ##
3089 ## ----------------- ##"
3091 for ac_var in $ac_subst_vars
3093 eval ac_val=\$$ac_var
3095 *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3097 printf "%s\n" "$ac_var='\''$ac_val'\''"
3101 if test -n "$ac_subst_files"; then
3102 printf "%s\n" "## ------------------- ##
3103 ## File substitutions. ##
3104 ## ------------------- ##"
3106 for ac_var in $ac_subst_files
3108 eval ac_val=\$$ac_var
3110 *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3112 printf "%s\n" "$ac_var='\''$ac_val'\''"
3117 if test -s confdefs.h; then
3118 printf "%s\n" "## ----------- ##
3125 test "$ac_signal" != 0 &&
3126 printf "%s\n" "$as_me: caught signal $ac_signal"
3127 printf "%s\n" "$as_me: exit $exit_status"
3129 rm -f core *.core core.conftest.* &&
3130 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3133 for ac_signal in 1 2 13 15; do
3134 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3138 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3139 rm -f -r conftest* confdefs.h
3141 printf "%s\n" "/* confdefs.h */" > confdefs.h
3143 # Predefined preprocessor variables.
3145 cat >>confdefs.h <<_ACEOF
3146 #define PACKAGE_NAME "$PACKAGE_NAME"
3149 cat >>confdefs.h <<_ACEOF
3150 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3153 cat >>confdefs.h <<_ACEOF
3154 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3157 cat >>confdefs.h <<_ACEOF
3158 #define PACKAGE_STRING "$PACKAGE_STRING"
3161 cat >>confdefs.h <<_ACEOF
3162 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3165 cat >>confdefs.h <<_ACEOF
3166 #define PACKAGE_URL "$PACKAGE_URL"
3170 # Let the site file select an alternate cache file if it wants to.
3171 # Prefer an explicitly selected file to automatically selected ones.
3174 if test -n "$CONFIG_SITE"; then
3175 # We do not want a PATH search for config.site.
3176 case $CONFIG_SITE in #((
3177 -*) ac_site_file1=./$CONFIG_SITE;;
3178 */*) ac_site_file1=$CONFIG_SITE;;
3179 *) ac_site_file1=./$CONFIG_SITE;;
3181 elif test "x$prefix" != xNONE; then
3182 ac_site_file1=$prefix/share/config.site
3183 ac_site_file2=$prefix/etc/config.site
3185 ac_site_file1=$ac_default_prefix/share/config.site
3186 ac_site_file2=$ac_default_prefix/etc/config.site
3188 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3190 test "x$ac_site_file" = xNONE && continue
3191 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3192 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3193 printf "%s\n" "$as_me: loading site script $ac_site_file" >&6;}
3194 sed 's/^/| /' "$ac_site_file" >&5
3196 || { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3197 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
3198 as_fn_error $? "failed to load site script $ac_site_file
3199 See \`config.log' for more details" "$LINENO" 5; }
3203 if test -r "$cache_file"; then
3204 # Some versions of bash will fail to source /dev/null (special files
3205 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3206 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3207 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3208 printf "%s\n" "$as_me: loading cache $cache_file" >&6;}
3210 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3211 *) . "./$cache_file";;
3215 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3216 printf "%s\n" "$as_me: creating cache $cache_file" >&6;}
3220 as_fn_append ac_func_list " btowc"
3221 as_fn_append ac_func_list " setrlimit"
3222 as_fn_append ac_header_list " ucontext.h"
3223 as_fn_append ac_func_list " sigaltstack"
3224 as_fn_append ac_header_list " unistd.h"
3225 as_fn_append ac_func_list " readlinkat"
3226 as_fn_append ac_func_list " _set_invalid_parameter_handler"
3227 as_fn_append ac_header_list " sys/socket.h"
3228 as_fn_append ac_func_list " fcntl"
3229 as_fn_append ac_func_list " symlink"
3230 as_fn_append ac_func_list " mempcpy"
3231 as_fn_append ac_func_list " isblank"
3232 as_fn_append ac_func_list " iswctype"
3233 as_fn_append ac_func_list " mbsrtowcs"
3234 as_fn_append ac_func_list " wmemchr"
3235 as_fn_append ac_func_list " wmemcpy"
3236 as_fn_append ac_func_list " wmempcpy"
3237 as_fn_append ac_header_list " wctype.h"
3238 gl_fnmatch_required=GNU
3239 as_fn_append ac_header_list " sys/stat.h"
3240 as_fn_append ac_func_list " getdtablesize"
3241 gl_getopt_required=GNU
3242 as_fn_append ac_header_list " getopt.h"
3243 as_fn_append ac_func_list " gettimeofday"
3244 as_fn_append ac_func_list " nanotime"
3245 as_fn_append ac_header_list " sys/time.h"
3246 as_fn_append ac_header_list " iconv.h"
3247 as_fn_append ac_header_list " wchar.h"
3248 as_fn_append ac_header_list " stdint.h"
3249 as_fn_append ac_header_list " inttypes.h"
3250 as_fn_append ac_func_list " iswcntrl"
3251 as_fn_append ac_func_list " iswblank"
3252 as_fn_append ac_header_list " langinfo.h"
3253 as_fn_append ac_header_list " xlocale.h"
3254 as_fn_append ac_func_list " lstat"
3255 as_fn_append ac_func_list " mbsinit"
3256 as_fn_append ac_func_list " mbrtowc"
3257 as_fn_append ac_func_list " mbslen"
3258 as_fn_append ac_header_list " sys/mman.h"
3259 as_fn_append ac_func_list " mprotect"
3260 as_fn_append ac_func_list " mkstemp"
3261 as_fn_append ac_func_list " nl_langinfo"
3262 as_fn_append ac_header_list " sys/param.h"
3263 as_fn_append ac_func_list " readlink"
3264 as_fn_append ac_func_list " wcscoll"
3265 as_fn_append ac_func_list " secure_getenv"
3266 as_fn_append ac_func_list " sigaction"
3267 as_fn_append ac_func_list " siginterrupt"
3268 as_fn_append ac_func_list " tzset"
3269 as_fn_append ac_header_list " strings.h"
3270 as_fn_append ac_func_list " strndup"
3271 as_fn_append ac_func_list " strptime"
3272 as_fn_append ac_func_list " strtoumax"
3273 as_fn_append ac_header_list " sys/wait.h"
3274 as_fn_append ac_func_list " localtime_r"
3275 as_fn_append ac_func_list " vasnprintf"
3276 as_fn_append ac_header_list " features.h"
3277 as_fn_append ac_func_list " snprintf"
3278 as_fn_append ac_func_list " wcrtomb"
3279 as_fn_append ac_func_list " wcwidth"
3280 as_fn_append ac_func_list " newlocale"
3281 as_fn_append ac_func_list " setenv"
3282 as_fn_append ac_func_list " sleep"
3283 as_fn_append ac_func_list " usleep"
3284 as_fn_append ac_func_list " wctob"
3285 as_fn_append ac_func_list " sigprocmask"
3286 as_fn_append ac_func_list " strcasecoll"
3287 as_fn_append ac_func_list " stricoll"
3288 gt_needs="$gt_needs need-ngettext"
3289 # Check that the precious variables saved in the cache have kept the same
3291 ac_cache_corrupted=false
3292 for ac_var in $ac_precious_vars; do
3293 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3294 eval ac_new_set=\$ac_env_${ac_var}_set
3295 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3296 eval ac_new_val=\$ac_env_${ac_var}_value
3297 case $ac_old_set,$ac_new_set in
3299 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3300 printf "%s\n" "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3301 ac_cache_corrupted=: ;;
3303 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3304 printf "%s\n" "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3305 ac_cache_corrupted=: ;;
3308 if test "x$ac_old_val" != "x$ac_new_val"; then
3309 # differences in whitespace do not lead to failure.
3310 ac_old_val_w=`echo x $ac_old_val`
3311 ac_new_val_w=`echo x $ac_new_val`
3312 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3313 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3314 printf "%s\n" "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3315 ac_cache_corrupted=:
3317 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3318 printf "%s\n" "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3319 eval $ac_var=\$ac_old_val
3321 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3322 printf "%s\n" "$as_me: former value: \`$ac_old_val'" >&2;}
3323 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3324 printf "%s\n" "$as_me: current value: \`$ac_new_val'" >&2;}
3327 # Pass precious variables to config.status.
3328 if test "$ac_new_set" = set; then
3330 *\'*) ac_arg=$ac_var=`printf "%s\n" "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3331 *) ac_arg=$ac_var=$ac_new_val ;;
3333 case " $ac_configure_args " in
3334 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3335 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3339 if $ac_cache_corrupted; then
3340 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3341 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
3342 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3343 printf "%s\n" "$as_me: error: changes in the environment can compromise the build" >&2;}
3344 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3346 ## -------------------- ##
3347 ## Main body of script. ##
3348 ## -------------------- ##
3351 ac_cpp='$CPP $CPPFLAGS'
3352 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3353 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3354 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3360 for ac_dir in build-aux "$srcdir"/build-aux; do
3361 if test -f "$ac_dir/install-sh"; then
3363 ac_install_sh="$ac_aux_dir/install-sh -c"
3365 elif test -f "$ac_dir/install.sh"; then
3367 ac_install_sh="$ac_aux_dir/install.sh -c"
3369 elif test -f "$ac_dir/shtool"; then
3371 ac_install_sh="$ac_aux_dir/shtool install -c"
3375 if test -z "$ac_aux_dir"; then
3376 as_fn_error $? "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
3379 # These three variables are undocumented and unsupported,
3380 # and are intended to be withdrawn in a future Autoconf release.
3381 # They can cause serious problems if a builder's source tree is in a directory
3382 # whose full name contains unusual characters.
3383 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3384 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3385 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3390 am__api_version='1.13a'
3392 # Find a good install program. We prefer a C program (faster),
3393 # so one script is as good as another. But avoid the broken or
3394 # incompatible versions:
3395 # SysV /etc/install, /usr/sbin/install
3396 # SunOS /usr/etc/install
3397 # IRIX /sbin/install
3399 # AmigaOS /C/install, which installs bootblocks on floppy discs
3400 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3401 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3402 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3403 # OS/2's system install, which has a completely different semantic
3404 # ./install, which can be erroneously created by make from ./install.sh.
3405 # Reject install programs that cannot install multiple files.
3406 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3407 printf %s "checking for a BSD-compatible install... " >&6; }
3408 if test -z "$INSTALL"; then
3409 if ${ac_cv_path_install+:} false; then :
3410 printf %s "(cached) " >&6
3412 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3416 case $as_dir in #(((
3419 *) as_dir=$as_dir/ ;;
3421 # Account for fact that we put trailing slashes in our PATH walk.
3424 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3425 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3428 # OSF1 and SCO ODT 3.0 have their own names for install.
3429 # Don't use installbsd from OSF since it installs stuff as root
3431 for ac_prog in ginstall scoinst install; do
3432 for ac_exec_ext in '' $ac_executable_extensions; do
3433 if as_fn_executable_p "$as_dir$ac_prog$ac_exec_ext"; then
3434 if test $ac_prog = install &&
3435 grep dspmsg "$as_dir$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3436 # AIX install. It has an incompatible calling convention.
3438 elif test $ac_prog = install &&
3439 grep pwplus "$as_dir$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3440 # program-specific install script used by HP pwplus--don't use.
3443 rm -rf conftest.one conftest.two conftest.dir
3444 echo one > conftest.one
3445 echo two > conftest.two
3447 if "$as_dir$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3448 test -s conftest.one && test -s conftest.two &&
3449 test -s conftest.dir/conftest.one &&
3450 test -s conftest.dir/conftest.two
3452 ac_cv_path_install="$as_dir$ac_prog$ac_exec_ext -c"
3465 rm -rf conftest.one conftest.two conftest.dir
3468 if test "${ac_cv_path_install+set}" = set; then
3469 INSTALL=$ac_cv_path_install
3471 # As a last resort, use the slow shell script. Don't cache a
3472 # value for INSTALL within a source directory, because that will
3473 # break other packages using the cache if that directory is
3474 # removed, or if the value is a relative name.
3475 INSTALL=$ac_install_sh
3478 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3479 printf "%s\n" "$INSTALL" >&6; }
3481 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3482 # It thinks the first close brace ends the variable substitution.
3483 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3485 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3487 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3489 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3490 printf %s "checking whether build environment is sane... " >&6; }
3491 # Reject unsafe characters in $srcdir or the absolute working directory
3492 # name. Accept space and tab only in the latter.
3496 *[\\\"\#\$\&\'\`$am_lf]*)
3497 as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
3500 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3501 as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
3504 # Do 'set' in a subshell so we don't clobber the current shell's
3505 # arguments. Must try -L first in case configure is actually a
3506 # symlink; some systems play weird games with the mod time of symlinks
3507 # (eg FreeBSD returns the mod time of the symlink's containing
3511 for am_try in 1 2; do
3512 echo "timestamp, slept: $am_has_slept" > conftest.file
3513 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3514 if test "$*" = "X"; then
3516 set X `ls -t "$srcdir/configure" conftest.file`
3518 if test "$*" != "X $srcdir/configure conftest.file" \
3519 && test "$*" != "X conftest.file $srcdir/configure"; then
3521 # If neither matched, then we have a broken ls. This can happen
3522 # if, for instance, CONFIG_SHELL is bash and it inherits a
3523 # broken ls alias from the environment. This has actually
3524 # happened. Such a system could not be considered "sane".
3525 as_fn_error $? "ls -t appears to fail. Make sure there is not a broken
3526 alias in your environment" "$LINENO" 5
3528 if test "$2" = conftest.file || test $am_try -eq 2; then
3535 test "$2" = conftest.file
3541 as_fn_error $? "newly created file is older than distributed files!
3542 Check your system clock" "$LINENO" 5
3544 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3545 printf "%s\n" "yes" >&6; }
3546 # If we didn't sleep, we still need to ensure time stamps of config.status and
3547 # generated files are strictly newer.
3549 if grep 'slept: no' conftest.file >/dev/null 2>&1; then
3556 test "$program_prefix" != NONE &&
3557 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3558 # Use a double $ so make ignores it.
3559 test "$program_suffix" != NONE &&
3560 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3561 # Double any \ or $.
3562 # By default was `s,x,x', remove it if useless.
3563 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3564 program_transform_name=`printf "%s\n" "$program_transform_name" | sed "$ac_script"`
3566 # expand $ac_aux_dir to an absolute path
3567 am_aux_dir=`cd $ac_aux_dir && pwd`
3569 if test x"${MISSING+set}" != xset; then
3572 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3574 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3577 # Use eval to expand $SHELL
3578 if eval "$MISSING --is-lightweight"; then
3579 am_missing_run="$MISSING "
3582 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
3583 printf "%s\n" "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
3586 if test x"${install_sh}" != xset; then
3589 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3591 install_sh="\${SHELL} $am_aux_dir/install-sh"
3595 # Installed binaries are usually stripped using 'strip' when the user
3596 # run "make install-strip". However 'strip' might not be the right
3597 # tool to use in cross-compilation environments, therefore Automake
3598 # will honor the 'STRIP' environment variable to overrule this program.
3599 if test "$cross_compiling" != no; then
3600 if test -n "$ac_tool_prefix"; then
3601 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3602 set dummy ${ac_tool_prefix}strip; ac_word=$2
3603 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3604 printf %s "checking for $ac_word... " >&6; }
3605 if ${ac_cv_prog_STRIP+:} false; then :
3606 printf %s "(cached) " >&6
3608 if test -n "$STRIP"; then
3609 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3611 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3615 case $as_dir in #(((
3618 *) as_dir=$as_dir/ ;;
3620 for ac_exec_ext in '' $ac_executable_extensions; do
3621 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3622 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3623 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3632 STRIP=$ac_cv_prog_STRIP
3633 if test -n "$STRIP"; then
3634 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3635 printf "%s\n" "$STRIP" >&6; }
3637 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3638 printf "%s\n" "no" >&6; }
3643 if test -z "$ac_cv_prog_STRIP"; then
3645 # Extract the first word of "strip", so it can be a program name with args.
3646 set dummy strip; ac_word=$2
3647 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3648 printf %s "checking for $ac_word... " >&6; }
3649 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
3650 printf %s "(cached) " >&6
3652 if test -n "$ac_ct_STRIP"; then
3653 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3655 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3659 case $as_dir in #(((
3662 *) as_dir=$as_dir/ ;;
3664 for ac_exec_ext in '' $ac_executable_extensions; do
3665 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3666 ac_cv_prog_ac_ct_STRIP="strip"
3667 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3676 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3677 if test -n "$ac_ct_STRIP"; then
3678 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3679 printf "%s\n" "$ac_ct_STRIP" >&6; }
3681 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3682 printf "%s\n" "no" >&6; }
3685 if test "x$ac_ct_STRIP" = x; then
3688 case $cross_compiling:$ac_tool_warned in
3690 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3691 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3692 ac_tool_warned=yes ;;
3697 STRIP="$ac_cv_prog_STRIP"
3701 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3703 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3704 printf %s "checking for a thread-safe mkdir -p... " >&6; }
3705 if test -z "$MKDIR_P"; then
3706 if ${ac_cv_path_mkdir+:} false; then :
3707 printf %s "(cached) " >&6
3709 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3710 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3713 case $as_dir in #(((
3716 *) as_dir=$as_dir/ ;;
3718 for ac_prog in mkdir gmkdir; do
3719 for ac_exec_ext in '' $ac_executable_extensions; do
3720 as_fn_executable_p "$as_dir$ac_prog$ac_exec_ext" || continue
3721 case `"$as_dir$ac_prog$ac_exec_ext" --version 2>&1` in #(
3722 'mkdir (GNU coreutils) '* | \
3723 'mkdir (coreutils) '* | \
3724 'mkdir (fileutils) '4.1*)
3725 ac_cv_path_mkdir=$as_dir$ac_prog$ac_exec_ext
3735 test -d ./--version && rmdir ./--version
3736 if test "${ac_cv_path_mkdir+set}" = set; then
3737 MKDIR_P="$ac_cv_path_mkdir -p"
3739 # As a last resort, use the slow shell script. Don't cache a
3740 # value for MKDIR_P within a source directory, because that will
3741 # break other packages using the cache if that directory is
3742 # removed, or if the value is a relative name.
3743 MKDIR_P="$ac_install_sh -d"
3746 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3747 printf "%s\n" "$MKDIR_P" >&6; }
3749 for ac_prog in gawk mawk nawk awk
3751 # Extract the first word of "$ac_prog", so it can be a program name with args.
3752 set dummy $ac_prog; ac_word=$2
3753 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3754 printf %s "checking for $ac_word... " >&6; }
3755 if ${ac_cv_prog_AWK+:} false; then :
3756 printf %s "(cached) " >&6
3758 if test -n "$AWK"; then
3759 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3761 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3765 case $as_dir in #(((
3768 *) as_dir=$as_dir/ ;;
3770 for ac_exec_ext in '' $ac_executable_extensions; do
3771 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3772 ac_cv_prog_AWK="$ac_prog"
3773 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3783 if test -n "$AWK"; then
3784 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3785 printf "%s\n" "$AWK" >&6; }
3787 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3788 printf "%s\n" "no" >&6; }
3792 test -n "$AWK" && break
3795 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3796 printf %s "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3798 ac_make=`printf "%s\n" "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3799 if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
3800 printf %s "(cached) " >&6
3802 cat >conftest.make <<\_ACEOF
3805 @echo '@@@%%%=$(MAKE)=@@@%%%'
3807 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
3808 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3810 eval ac_cv_prog_make_${ac_make}_set=yes;;
3812 eval ac_cv_prog_make_${ac_make}_set=no;;
3816 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3817 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3818 printf "%s\n" "yes" >&6; }
3821 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3822 printf "%s\n" "no" >&6; }
3823 SET_MAKE="MAKE=${MAKE-make}"
3826 # Check whether --enable-silent-rules was given.
3827 if test "${enable_silent_rules+set}" = set; then :
3828 enableval=$enable_silent_rules;
3831 case $enable_silent_rules in # (((
3832 yes) AM_DEFAULT_VERBOSITY=0;;
3833 no) AM_DEFAULT_VERBOSITY=1;;
3834 *) AM_DEFAULT_VERBOSITY=1;;
3836 am_make=${MAKE-make}
3837 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
3838 printf %s "checking whether $am_make supports nested variables... " >&6; }
3839 if ${am_cv_make_support_nested_variables+:} false; then :
3840 printf %s "(cached) " >&6
3842 if printf "%s\n" 'TRUE=$(BAR$(V))
3848 .PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
3849 am_cv_make_support_nested_variables=yes
3851 am_cv_make_support_nested_variables=no
3854 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
3855 printf "%s\n" "$am_cv_make_support_nested_variables" >&6; }
3856 if test $am_cv_make_support_nested_variables = yes; then
3858 AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
3860 AM_V=$AM_DEFAULT_VERBOSITY
3861 AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
3865 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3866 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3867 # is not polluted with repeated "-I."
3868 am__isrc=' -I$(srcdir)'
3869 # test to see if srcdir already configured
3870 if test -f $srcdir/config.status; then
3871 as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3875 # test whether we have cygpath
3876 if test -z "$CYGPATH_W"; then
3877 if (cygpath --version) >/dev/null 2>/dev/null; then
3878 CYGPATH_W='cygpath -w'
3885 # Define the identity of the package.
3890 cat >>confdefs.h <<_ACEOF
3891 #define PACKAGE "$PACKAGE"
3895 cat >>confdefs.h <<_ACEOF
3896 #define VERSION "$VERSION"
3899 # Some tools Automake needs.
3901 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3904 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3907 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3910 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3913 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3915 # We need awk for the "check" target. The system "awk" is bad on
3917 # Always define AMTAR for backward compatibility. Yes, it's still used
3918 # in the wild :-( We should find a proper way to deprecate it ...
3921 am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
3927 # POSIX will say in a future version that running "rm -f" with no argument
3928 # is OK; and we want to be able to make that assumption in our Makefile
3929 # recipes. So use an aggressive probe to check that the usage we want is
3930 # actually supported "in the wild" to an acceptable degree.
3931 # See automake bug#10828.
3932 # To make any issue more visible, cause the running configure to be aborted
3933 # by default if the 'rm' program in use doesn't match our expectations; the
3934 # user can still override this though.
3935 if rm -f && rm -fr && rm -rf; then : OK; else
3939 Your 'rm' program seems unable to run without file operands specified
3940 on the command line, even when the '-f' option is present. This is contrary
3941 to the behaviour of most rm programs out there, and not conforming with
3942 the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
3944 Please tell bug-automake@gnu.org about your system, including the value
3945 of your $PATH and any error possibly output before this message. This
3946 can help us improve future automake versions.
3949 if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
3950 echo 'Configuration will proceed anyway, since you have set the' >&2
3951 echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
3955 Aborting the configuration process, to ensure you take notice of the issue.
3957 You can download and install GNU coreutils to get an 'rm' implementation
3958 that behaves properly: <http://www.gnu.org/software/coreutils/>.
3960 If you want to complete the configuration process using your problematic
3961 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
3962 to "yes", and re-run configure.
3965 as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5
3968 # Check whether --enable-silent-rules was given.
3969 if test "${enable_silent_rules+set}" = set; then :
3970 enableval=$enable_silent_rules;
3973 case $enable_silent_rules in # (((
3974 yes) AM_DEFAULT_VERBOSITY=0;;
3975 no) AM_DEFAULT_VERBOSITY=1;;
3976 *) AM_DEFAULT_VERBOSITY=0;;
3978 am_make=${MAKE-make}
3979 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
3980 printf %s "checking whether $am_make supports nested variables... " >&6; }
3981 if ${am_cv_make_support_nested_variables+:} false; then :
3982 printf %s "(cached) " >&6
3984 if printf "%s\n" 'TRUE=$(BAR$(V))
3990 .PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
3991 am_cv_make_support_nested_variables=yes
3993 am_cv_make_support_nested_variables=no
3996 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
3997 printf "%s\n" "$am_cv_make_support_nested_variables" >&6; }
3998 if test $am_cv_make_support_nested_variables = yes; then
4000 AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
4002 AM_V=$AM_DEFAULT_VERBOSITY
4003 AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
4006 # make --enable-silent-rules the default.
4008 ac_config_headers="$ac_config_headers lib/config.h:lib/config.hin"
4011 for ac_prog in gawk mawk nawk awk
4013 # Extract the first word of "$ac_prog", so it can be a program name with args.
4014 set dummy $ac_prog; ac_word=$2
4015 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4016 printf %s "checking for $ac_word... " >&6; }
4017 if ${ac_cv_prog_AWK+:} false; then :
4018 printf %s "(cached) " >&6
4020 if test -n "$AWK"; then
4021 ac_cv_prog_AWK="$AWK" # Let the user override the test.
4023 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4027 case $as_dir in #(((
4030 *) as_dir=$as_dir/ ;;
4032 for ac_exec_ext in '' $ac_executable_extensions; do
4033 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4034 ac_cv_prog_AWK="$ac_prog"
4035 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4045 if test -n "$AWK"; then
4046 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
4047 printf "%s\n" "$AWK" >&6; }
4049 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4050 printf "%s\n" "no" >&6; }
4054 test -n "$AWK" && break
4058 ac_cpp='$CPP $CPPFLAGS'
4059 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4060 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4061 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4062 if test -n "$ac_tool_prefix"; then
4063 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4064 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4065 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4066 printf %s "checking for $ac_word... " >&6; }
4067 if ${ac_cv_prog_CC+:} false; then :
4068 printf %s "(cached) " >&6
4070 if test -n "$CC"; then
4071 ac_cv_prog_CC="$CC" # Let the user override the test.
4073 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4077 case $as_dir in #(((
4080 *) as_dir=$as_dir/ ;;
4082 for ac_exec_ext in '' $ac_executable_extensions; do
4083 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4084 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4085 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4095 if test -n "$CC"; then
4096 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4097 printf "%s\n" "$CC" >&6; }
4099 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4100 printf "%s\n" "no" >&6; }
4105 if test -z "$ac_cv_prog_CC"; then
4107 # Extract the first word of "gcc", so it can be a program name with args.
4108 set dummy gcc; ac_word=$2
4109 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4110 printf %s "checking for $ac_word... " >&6; }
4111 if ${ac_cv_prog_ac_ct_CC+:} false; then :
4112 printf %s "(cached) " >&6
4114 if test -n "$ac_ct_CC"; then
4115 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4117 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4121 case $as_dir in #(((
4124 *) as_dir=$as_dir/ ;;
4126 for ac_exec_ext in '' $ac_executable_extensions; do
4127 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4128 ac_cv_prog_ac_ct_CC="gcc"
4129 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4138 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4139 if test -n "$ac_ct_CC"; then
4140 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4141 printf "%s\n" "$ac_ct_CC" >&6; }
4143 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4144 printf "%s\n" "no" >&6; }
4147 if test "x$ac_ct_CC" = x; then
4150 case $cross_compiling:$ac_tool_warned in
4152 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4153 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4154 ac_tool_warned=yes ;;
4162 if test -z "$CC"; then
4163 if test -n "$ac_tool_prefix"; then
4164 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4165 set dummy ${ac_tool_prefix}cc; ac_word=$2
4166 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4167 printf %s "checking for $ac_word... " >&6; }
4168 if ${ac_cv_prog_CC+:} false; then :
4169 printf %s "(cached) " >&6
4171 if test -n "$CC"; then
4172 ac_cv_prog_CC="$CC" # Let the user override the test.
4174 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4178 case $as_dir in #(((
4181 *) as_dir=$as_dir/ ;;
4183 for ac_exec_ext in '' $ac_executable_extensions; do
4184 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4185 ac_cv_prog_CC="${ac_tool_prefix}cc"
4186 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4196 if test -n "$CC"; then
4197 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4198 printf "%s\n" "$CC" >&6; }
4200 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4201 printf "%s\n" "no" >&6; }
4207 if test -z "$CC"; then
4208 # Extract the first word of "cc", so it can be a program name with args.
4209 set dummy cc; ac_word=$2
4210 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4211 printf %s "checking for $ac_word... " >&6; }
4212 if ${ac_cv_prog_CC+:} false; then :
4213 printf %s "(cached) " >&6
4215 if test -n "$CC"; then
4216 ac_cv_prog_CC="$CC" # Let the user override the test.
4219 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4223 case $as_dir in #(((
4226 *) as_dir=$as_dir/ ;;
4228 for ac_exec_ext in '' $ac_executable_extensions; do
4229 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4230 if test "$as_dir$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4231 ac_prog_rejected=yes
4235 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4242 if test $ac_prog_rejected = yes; then
4243 # We found a bogon in the path, so make sure we never use it.
4244 set dummy $ac_cv_prog_CC
4246 if test $# != 0; then
4247 # We chose a different compiler from the bogus one.
4248 # However, it has the same basename, so the bogon will be chosen
4249 # first if we set CC to just the basename; use the full file name.
4251 ac_cv_prog_CC="$as_dir$ac_word${1+' '}$@"
4257 if test -n "$CC"; then
4258 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4259 printf "%s\n" "$CC" >&6; }
4261 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4262 printf "%s\n" "no" >&6; }
4267 if test -z "$CC"; then
4268 if test -n "$ac_tool_prefix"; then
4269 for ac_prog in cl.exe
4271 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4272 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4273 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4274 printf %s "checking for $ac_word... " >&6; }
4275 if ${ac_cv_prog_CC+:} false; then :
4276 printf %s "(cached) " >&6
4278 if test -n "$CC"; then
4279 ac_cv_prog_CC="$CC" # Let the user override the test.
4281 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4285 case $as_dir in #(((
4288 *) as_dir=$as_dir/ ;;
4290 for ac_exec_ext in '' $ac_executable_extensions; do
4291 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4292 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4293 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4303 if test -n "$CC"; then
4304 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4305 printf "%s\n" "$CC" >&6; }
4307 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4308 printf "%s\n" "no" >&6; }
4312 test -n "$CC" && break
4315 if test -z "$CC"; then
4317 for ac_prog in cl.exe
4319 # Extract the first word of "$ac_prog", so it can be a program name with args.
4320 set dummy $ac_prog; ac_word=$2
4321 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4322 printf %s "checking for $ac_word... " >&6; }
4323 if ${ac_cv_prog_ac_ct_CC+:} false; then :
4324 printf %s "(cached) " >&6
4326 if test -n "$ac_ct_CC"; then
4327 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4329 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4333 case $as_dir in #(((
4336 *) as_dir=$as_dir/ ;;
4338 for ac_exec_ext in '' $ac_executable_extensions; do
4339 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4340 ac_cv_prog_ac_ct_CC="$ac_prog"
4341 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4350 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4351 if test -n "$ac_ct_CC"; then
4352 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4353 printf "%s\n" "$ac_ct_CC" >&6; }
4355 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4356 printf "%s\n" "no" >&6; }
4360 test -n "$ac_ct_CC" && break
4363 if test "x$ac_ct_CC" = x; then
4366 case $cross_compiling:$ac_tool_warned in
4368 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4369 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4370 ac_tool_warned=yes ;;
4379 test -z "$CC" && { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4380 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
4381 as_fn_error $? "no acceptable C compiler found in \$PATH
4382 See \`config.log' for more details" "$LINENO" 5; }
4384 # Provide some information about the compiler.
4385 printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4388 for ac_option in --version -v -V -qversion; do
4389 { { ac_try="$ac_compiler $ac_option >&5"
4391 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4392 *) ac_try_echo=$ac_try;;
4394 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4395 printf "%s\n" "$ac_try_echo"; } >&5
4396 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4398 if test -s conftest.err; then
4400 ... rest of stderr output deleted ...
4401 10q' conftest.err >conftest.er1
4402 cat conftest.er1 >&5
4404 rm -f conftest.er1 conftest.err
4405 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4406 test $ac_status = 0; }
4409 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4410 /* end confdefs.h. */
4420 ac_clean_files_save=$ac_clean_files
4421 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4422 # Try to create an executable without -o first, disregard a.out.
4423 # It will help us diagnose broken compilers, and finding out an intuition
4425 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4426 printf %s "checking whether the C compiler works... " >&6; }
4427 ac_link_default=`printf "%s\n" "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4429 # The possible output files:
4430 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4433 for ac_file in $ac_files
4436 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4437 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4442 if { { ac_try="$ac_link_default"
4444 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4445 *) ac_try_echo=$ac_try;;
4447 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4448 printf "%s\n" "$ac_try_echo"; } >&5
4449 (eval "$ac_link_default") 2>&5
4451 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4452 test $ac_status = 0; }; then :
4453 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4454 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4455 # in a Makefile. We should not override ac_cv_exeext if it was cached,
4456 # so that the user can short-circuit this test for compilers unknown to
4458 for ac_file in $ac_files ''
4460 test -f "$ac_file" || continue
4462 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
4465 # We found the default executable, but exeext='' is most
4469 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
4471 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4473 # We set ac_cv_exeext here because the later test for it is not
4474 # safe: cross compilers may not add the suffix if given an `-o'
4475 # argument, so we may need to know it at that point already.
4476 # Even if this section looks crufty: it has the advantage of
4483 test "$ac_cv_exeext" = no && ac_cv_exeext=
4488 if test -z "$ac_file"; then :
4489 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4490 printf "%s\n" "no" >&6; }
4491 printf "%s\n" "$as_me: failed program was:" >&5
4492 sed 's/^/| /' conftest.$ac_ext >&5
4494 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4495 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
4496 as_fn_error 77 "C compiler cannot create executables
4497 See \`config.log' for more details" "$LINENO" 5; }
4499 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4500 printf "%s\n" "yes" >&6; }
4502 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
4503 printf %s "checking for C compiler default output file name... " >&6; }
4504 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
4505 printf "%s\n" "$ac_file" >&6; }
4506 ac_exeext=$ac_cv_exeext
4508 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
4509 ac_clean_files=$ac_clean_files_save
4510 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
4511 printf %s "checking for suffix of executables... " >&6; }
4512 if { { ac_try="$ac_link"
4514 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4515 *) ac_try_echo=$ac_try;;
4517 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4518 printf "%s\n" "$ac_try_echo"; } >&5
4519 (eval "$ac_link") 2>&5
4521 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4522 test $ac_status = 0; }; then :
4523 # If both `conftest.exe' and `conftest' are `present' (well, observable)
4524 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
4525 # work properly (i.e., refer to `conftest.exe'), while it won't with
4527 for ac_file in conftest.exe conftest conftest.*; do
4528 test -f "$ac_file" || continue
4530 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4531 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4537 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4538 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
4539 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
4540 See \`config.log' for more details" "$LINENO" 5; }
4542 rm -f conftest conftest$ac_cv_exeext
4543 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4544 printf "%s\n" "$ac_cv_exeext" >&6; }
4546 rm -f conftest.$ac_ext
4547 EXEEXT=$ac_cv_exeext
4549 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4550 /* end confdefs.h. */
4555 FILE *f = fopen ("conftest.out", "w");
4556 return ferror (f) || fclose (f) != 0;
4562 ac_clean_files="$ac_clean_files conftest.out"
4563 # Check that the compiler produces executables we can run. If not, either
4564 # the compiler is broken, or we cross compile.
4565 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4566 printf %s "checking whether we are cross compiling... " >&6; }
4567 if test "$cross_compiling" != yes; then
4568 { { ac_try="$ac_link"
4570 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4571 *) ac_try_echo=$ac_try;;
4573 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4574 printf "%s\n" "$ac_try_echo"; } >&5
4575 (eval "$ac_link") 2>&5
4577 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4578 test $ac_status = 0; }
4579 if { ac_try='./conftest$ac_cv_exeext'
4580 { { case "(($ac_try" in
4581 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4582 *) ac_try_echo=$ac_try;;
4584 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4585 printf "%s\n" "$ac_try_echo"; } >&5
4586 (eval "$ac_try") 2>&5
4588 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4589 test $ac_status = 0; }; }; then
4592 if test "$cross_compiling" = maybe; then
4595 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4596 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
4597 as_fn_error $? "cannot run C compiled programs.
4598 If you meant to cross compile, use \`--host'.
4599 See \`config.log' for more details" "$LINENO" 5; }
4603 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4604 printf "%s\n" "$cross_compiling" >&6; }
4606 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
4607 ac_clean_files=$ac_clean_files_save
4608 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4609 printf %s "checking for suffix of object files... " >&6; }
4610 if ${ac_cv_objext+:} false; then :
4611 printf %s "(cached) " >&6
4613 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4614 /* end confdefs.h. */
4624 rm -f conftest.o conftest.obj
4625 if { { ac_try="$ac_compile"
4627 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4628 *) ac_try_echo=$ac_try;;
4630 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4631 printf "%s\n" "$ac_try_echo"; } >&5
4632 (eval "$ac_compile") 2>&5
4634 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4635 test $ac_status = 0; }; then :
4636 for ac_file in conftest.o conftest.obj conftest.*; do
4637 test -f "$ac_file" || continue;
4639 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
4640 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4645 printf "%s\n" "$as_me: failed program was:" >&5
4646 sed 's/^/| /' conftest.$ac_ext >&5
4648 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4649 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
4650 as_fn_error $? "cannot compute suffix of object files: cannot compile
4651 See \`config.log' for more details" "$LINENO" 5; }
4653 rm -f conftest.$ac_cv_objext conftest.$ac_ext
4655 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4656 printf "%s\n" "$ac_cv_objext" >&6; }
4657 OBJEXT=$ac_cv_objext
4659 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4660 printf %s "checking whether we are using the GNU C compiler... " >&6; }
4661 if ${ac_cv_c_compiler_gnu+:} false; then :
4662 printf %s "(cached) " >&6
4664 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4665 /* end confdefs.h. */
4678 if ac_fn_c_try_compile "$LINENO"; then :
4683 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4684 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4687 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4688 printf "%s\n" "$ac_cv_c_compiler_gnu" >&6; }
4689 if test $ac_compiler_gnu = yes; then
4694 ac_test_CFLAGS=${CFLAGS+set}
4695 ac_save_CFLAGS=$CFLAGS
4696 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4697 printf %s "checking whether $CC accepts -g... " >&6; }
4698 if ${ac_cv_prog_cc_g+:} false; then :
4699 printf %s "(cached) " >&6
4701 ac_save_c_werror_flag=$ac_c_werror_flag
4702 ac_c_werror_flag=yes
4705 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4706 /* end confdefs.h. */
4716 if ac_fn_c_try_compile "$LINENO"; then :
4720 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4721 /* end confdefs.h. */
4731 if ac_fn_c_try_compile "$LINENO"; then :
4734 ac_c_werror_flag=$ac_save_c_werror_flag
4736 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4737 /* end confdefs.h. */
4747 if ac_fn_c_try_compile "$LINENO"; then :
4750 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4752 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4754 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4755 ac_c_werror_flag=$ac_save_c_werror_flag
4757 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4758 printf "%s\n" "$ac_cv_prog_cc_g" >&6; }
4759 if test "$ac_test_CFLAGS" = set; then
4760 CFLAGS=$ac_save_CFLAGS
4761 elif test $ac_cv_prog_cc_g = yes; then
4762 if test "$GCC" = yes; then
4768 if test "$GCC" = yes; then
4774 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5
4775 printf %s "checking for $CC option to enable C11 features... " >&6; }
4776 if ${ac_cv_prog_cc_c11+:} false; then :
4777 printf %s "(cached) " >&6
4779 ac_cv_prog_cc_c11=no
4781 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4782 /* end confdefs.h. */
4784 #include <stdbool.h>
4789 // Check varargs macros. These examples are taken from C99 6.10.3.5.
4790 #define debug(...) fprintf (stderr, __VA_ARGS__)
4791 #define showlist(...) puts (#__VA_ARGS__)
4792 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
4794 test_varargs_macros (void)
4799 debug ("X = %d\n", x);
4800 showlist (The first, second, and third items.);
4801 report (x>y, "x is %d but y is %d", x, y);
4804 // Check long long types.
4805 #define BIG64 18446744073709551615ull
4806 #define BIG32 4294967295ul
4807 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
4809 your preprocessor is broken;
4813 your preprocessor is broken;
4815 static long long int bignum = -9223372036854775807LL;
4816 static unsigned long long int ubignum = BIG64;
4818 struct incomplete_array
4826 const wchar_t *name;
4830 typedef const char *ccp;
4833 test_restrict (ccp restrict text)
4835 // See if C++-style comments work.
4836 // Iterate through items via the restricted pointer.
4837 // Also check for declarations in for loops.
4838 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
4843 // Check varargs and va_copy.
4845 test_varargs (const char *format, ...)
4848 va_start (args, format);
4850 va_copy (args_copy, args);
4852 const char *str = "";
4861 str = va_arg (args_copy, const char *);
4864 number = va_arg (args_copy, int);
4867 fnumber = va_arg (args_copy, double);
4876 return *str && number && fnumber;
4879 char _Alignas (double) aligned_as_double;
4880 char _Alignas (0) no_special_alignment;
4881 extern char aligned_as_int;
4882 char _Alignas (0) _Alignas (int) aligned_as_int;
4887 int_alignment = _Alignof (int),
4888 int_array_alignment = _Alignof (int[100]),
4889 char_alignment = _Alignof (char)
4891 _Static_assert (0 < -_Alignof (int), "_Alignof is signed");
4894 int _Noreturn does_not_return (void) { for (;;) continue; }
4896 // Check _Static_assert.
4897 struct test_static_assert
4900 _Static_assert (sizeof (int) <= sizeof (long int),
4901 "_Static_assert does not work in struct");
4905 // Check UTF-8 literals.
4906 #define u8 syntax error!
4907 char const utf8_literal[] = u8"happens to be ASCII" "another string";
4909 // Check duplicate typedefs.
4910 typedef long *long_ptr;
4911 typedef long int *long_ptr;
4912 typedef long_ptr long_ptr;
4914 // Anonymous structures and unions -- taken from C11 6.7.2.1 Example 1.
4918 struct { int i; int j; };
4919 struct { int k; long int l; } w;
4929 _Bool success = false;
4932 if (test_restrict ("String literal") == 0)
4934 char *restrict newvar = "Another string";
4937 success &= test_varargs ("s, d' f .", "string", 65, 34.234);
4938 test_varargs_macros ();
4940 // Check flexible array members.
4941 struct incomplete_array *ia =
4942 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
4944 for (int i = 0; i < ia->datasize; ++i)
4945 ia->data[i] = i * 1.234;
4947 // Check named initializers.
4948 struct named_init ni = {
4950 .name = L"Test wide string",
4951 .average = 543.34343,
4956 int dynamic_array[ni.number];
4957 dynamic_array[ni.number - 1] = 543;
4959 // work around unused variable warnings
4960 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
4961 || dynamic_array[ni.number - 1] != 543);
4965 _Static_assert (&v1.i == &v1.w.k, "Anonymous union alignment botch");
4971 for ac_arg in '' -std=gnu11
4973 CC="$ac_save_CC $ac_arg"
4974 if ac_fn_c_try_compile "$LINENO"; then :
4975 ac_cv_prog_cc_c11=$ac_arg
4977 rm -f core conftest.err conftest.$ac_objext
4978 test "x$ac_cv_prog_cc_c11" != "xno" && break
4980 rm -f conftest.$ac_ext
4985 ac_prog_cc_stdc_options=
4986 case "x$ac_cv_prog_cc_c11" in
4988 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4989 printf "%s\n" "none needed" >&6; } ;;
4991 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4992 printf "%s\n" "unsupported" >&6; } ;;
4994 ac_prog_cc_stdc_options=" $ac_cv_prog_cc_c11"
4995 CC=$CC$ac_prog_cc_stdc_options
4996 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5
4997 printf "%s\n" "$ac_cv_prog_cc_c11" >&6; } ;;
4999 if test "x$ac_cv_prog_cc_c11" != xno; then :
5001 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11
5003 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C99 features" >&5
5004 printf %s "checking for $CC option to enable C99 features... " >&6; }
5005 if ${ac_cv_prog_cc_c99+:} false; then :
5006 printf %s "(cached) " >&6
5008 ac_cv_prog_cc_c99=no
5010 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5011 /* end confdefs.h. */
5013 #include <stdbool.h>
5018 // Check varargs macros. These examples are taken from C99 6.10.3.5.
5019 #define debug(...) fprintf (stderr, __VA_ARGS__)
5020 #define showlist(...) puts (#__VA_ARGS__)
5021 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
5023 test_varargs_macros (void)
5028 debug ("X = %d\n", x);
5029 showlist (The first, second, and third items.);
5030 report (x>y, "x is %d but y is %d", x, y);
5033 // Check long long types.
5034 #define BIG64 18446744073709551615ull
5035 #define BIG32 4294967295ul
5036 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
5038 your preprocessor is broken;
5042 your preprocessor is broken;
5044 static long long int bignum = -9223372036854775807LL;
5045 static unsigned long long int ubignum = BIG64;
5047 struct incomplete_array
5055 const wchar_t *name;
5059 typedef const char *ccp;
5062 test_restrict (ccp restrict text)
5064 // See if C++-style comments work.
5065 // Iterate through items via the restricted pointer.
5066 // Also check for declarations in for loops.
5067 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
5072 // Check varargs and va_copy.
5074 test_varargs (const char *format, ...)
5077 va_start (args, format);
5079 va_copy (args_copy, args);
5081 const char *str = "";
5090 str = va_arg (args_copy, const char *);
5093 number = va_arg (args_copy, int);
5096 fnumber = va_arg (args_copy, double);
5105 return *str && number && fnumber;
5112 _Bool success = false;
5115 if (test_restrict ("String literal") == 0)
5117 char *restrict newvar = "Another string";
5120 success &= test_varargs ("s, d' f .", "string", 65, 34.234);
5121 test_varargs_macros ();
5123 // Check flexible array members.
5124 struct incomplete_array *ia =
5125 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
5127 for (int i = 0; i < ia->datasize; ++i)
5128 ia->data[i] = i * 1.234;
5130 // Check named initializers.
5131 struct named_init ni = {
5133 .name = L"Test wide string",
5134 .average = 543.34343,
5139 int dynamic_array[ni.number];
5140 dynamic_array[ni.number - 1] = 543;
5142 // work around unused variable warnings
5143 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
5144 || dynamic_array[ni.number - 1] != 543);
5150 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc1x -qlanglvl=extc99
5152 CC="$ac_save_CC $ac_arg"
5153 if ac_fn_c_try_compile "$LINENO"; then :
5154 ac_cv_prog_cc_c99=$ac_arg
5156 rm -f core conftest.err conftest.$ac_objext
5157 test "x$ac_cv_prog_cc_c99" != "xno" && break
5159 rm -f conftest.$ac_ext
5164 ac_prog_cc_stdc_options=
5165 case "x$ac_cv_prog_cc_c99" in
5167 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5168 printf "%s\n" "none needed" >&6; } ;;
5170 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5171 printf "%s\n" "unsupported" >&6; } ;;
5173 ac_prog_cc_stdc_options=" $ac_cv_prog_cc_c99"
5174 CC=$CC$ac_prog_cc_stdc_options
5175 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
5176 printf "%s\n" "$ac_cv_prog_cc_c99" >&6; } ;;
5178 if test "x$ac_cv_prog_cc_c99" != xno; then :
5180 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
5182 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C89 features" >&5
5183 printf %s "checking for $CC option to enable C89 features... " >&6; }
5184 if ${ac_cv_prog_cc_c89+:} false; then :
5185 printf %s "(cached) " >&6
5187 ac_cv_prog_cc_c89=no
5189 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5190 /* end confdefs.h. */
5194 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5195 struct buf { int x; };
5196 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5197 static char *e (p, i)
5203 static char *f (char * (*g) (char **, int), char **p, ...)
5208 s = g (p, va_arg (v,int));
5213 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5214 function prototypes and stuff, but not '\xHH' hex character constants.
5215 These don't provoke an error unfortunately, instead are silently treated
5216 as 'x'. The following induces an error, until -std is added to get
5217 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5218 array size at least. It's necessary to write '\x00'==0 to get something
5219 that's true only with -std. */
5220 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5222 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5223 inside strings and character constants. */
5225 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5227 int test (int i, double x);
5228 struct s1 {int (*f) (int a);};
5229 struct s2 {int (*f) (double a);};
5230 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5236 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5241 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5242 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5244 CC="$ac_save_CC $ac_arg"
5245 if ac_fn_c_try_compile "$LINENO"; then :
5246 ac_cv_prog_cc_c89=$ac_arg
5248 rm -f core conftest.err conftest.$ac_objext
5249 test "x$ac_cv_prog_cc_c89" != "xno" && break
5251 rm -f conftest.$ac_ext
5256 ac_prog_cc_stdc_options=
5257 case "x$ac_cv_prog_cc_c89" in
5259 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5260 printf "%s\n" "none needed" >&6; } ;;
5262 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5263 printf "%s\n" "unsupported" >&6; } ;;
5265 ac_prog_cc_stdc_options=" $ac_cv_prog_cc_c89"
5266 CC=$CC$ac_prog_cc_stdc_options
5267 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5268 printf "%s\n" "$ac_cv_prog_cc_c89" >&6; } ;;
5270 if test "x$ac_cv_prog_cc_c89" != xno; then :
5272 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
5275 ac_cv_prog_cc_stdc=no
5283 ac_cpp='$CPP $CPPFLAGS'
5284 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5285 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5286 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5288 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
5289 printf %s "checking whether $CC understands -c and -o together... " >&6; }
5290 set dummy $CC; am__cc=`printf "%s\n" "$2" | \
5291 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5292 if eval \${am_cv_prog_cc_${am__cc}_c_o+:} false; then :
5293 printf %s "(cached) " >&6
5295 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5296 /* end confdefs.h. */
5306 # Make sure it works both with $CC and with simple cc.
5307 # We do the test twice because some compilers refuse to overwrite an
5308 # existing .o file with -o, though they will create one.
5309 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5311 if { { case "(($ac_try" in
5312 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5313 *) ac_try_echo=$ac_try;;
5315 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5316 printf "%s\n" "$ac_try_echo"; } >&5
5317 (eval "$ac_try") 2>&5
5319 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5320 test $ac_status = 0; } && test -f conftest2.$ac_objext
5322 eval am_cv_prog_cc_${am__cc}_c_o=yes
5324 eval am_cv_prog_cc_${am__cc}_c_o=no
5326 rm -f core conftest*
5329 if eval test \"\$am_cv_prog_cc_${am__cc}_c_o\" = yes; then
5330 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5331 printf "%s\n" "yes" >&6; }
5333 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5334 printf "%s\n" "no" >&6; }
5335 # Losing compiler, so wrap it with the 'compile' script.
5336 # FIXME: It is wrong to rewrite CC.
5337 # But if we don't then we get into trouble of one sort or another.
5338 # A longer-term fix would be to have automake use am__CC in this case,
5339 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5340 CC="$am_aux_dir/compile $CC"
5344 ac_config_commands="$ac_config_commands depfiles"
5347 am_make=${MAKE-make}
5348 cat > confinc << 'END'
5350 @echo this is the am__doit target
5353 # If we don't find an include directive, just comment out the code.
5354 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5355 printf %s "checking for style of include used by $am_make... " >&6; }
5359 # First try GNU make style include.
5360 echo "include confinc" > confmf
5361 # Ignore all kinds of additional output from 'make'.
5362 case `$am_make -s -f confmf 2> /dev/null` in #(
5363 *the\ am__doit\ target*)
5369 # Now try BSD make style include.
5370 if test "$am__include" = "#"; then
5371 echo '.include "confinc"' > confmf
5372 case `$am_make -s -f confmf 2> /dev/null` in #(
5373 *the\ am__doit\ target*)
5374 am__include=.include
5382 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5383 printf "%s\n" "$_am_result" >&6; }
5384 rm -f confinc confmf
5386 # Check whether --enable-dependency-tracking was given.
5387 if test "${enable_dependency_tracking+set}" = set; then :
5388 enableval=$enable_dependency_tracking;
5391 if test "x$enable_dependency_tracking" != xno; then
5392 am_depcomp="$ac_aux_dir/depcomp"
5396 if test "x$enable_dependency_tracking" != xno; then
5406 depcc="$CC" am_compiler_list=
5408 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5409 printf %s "checking dependency style of $depcc... " >&6; }
5410 if ${am_cv_CC_dependencies_compiler_type+:} false; then :
5411 printf %s "(cached) " >&6
5413 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5414 # We make a subdir and do the tests there. Otherwise we can end up
5415 # making bogus files that we don't know about and never remove. For
5416 # instance it was reported that on HP-UX the gcc test will end up
5417 # making a dummy file named 'D' -- because '-MD' means "put the output
5421 # Copy depcomp to subdir because otherwise we won't find it if we're
5422 # using a relative directory.
5423 cp "$am_depcomp" conftest.dir
5425 # We will build objects and dependencies in a subdirectory because
5426 # it helps to detect inapplicable dependency modes. For instance
5427 # both Tru64's cc and ICC support -MD to output dependencies as a
5428 # side effect of compilation, but ICC will put the dependencies in
5429 # the current directory while Tru64 will put them in the object
5433 am_cv_CC_dependencies_compiler_type=none
5434 if test "$am_compiler_list" = ""; then
5435 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5438 case " $depcc " in #(
5439 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5442 for depmode in $am_compiler_list; do
5443 # Setup a source with many dependencies, because some compilers
5444 # like to wrap large dependency lists on column 80 (with \), and
5445 # we should not choose a depcomp mode which is confused by this.
5447 # We need to recreate these files for each test, as the compiler may
5448 # overwrite some of them when testing with obscure command lines.
5449 # This happens at least with the AIX C compiler.
5451 for i in 1 2 3 4 5 6; do
5452 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5453 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
5454 # Solaris 10 /bin/sh.
5455 echo '/* dummy */' > sub/conftst$i.h
5457 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5459 # We check with '-c' and '-o' for the sake of the "dashmstdout"
5460 # mode. It turns out that the SunPro C++ compiler does not properly
5461 # handle '-M -o', and we need to detect this. Also, some Intel
5462 # versions had trouble with output in subdirs.
5463 am__obj=sub/conftest.${OBJEXT-o}
5464 am__minus_obj="-o $am__obj"
5467 # This depmode causes a compiler race in universal mode.
5468 test "$am__universal" = false || continue
5471 # After this tag, mechanisms are not by side-effect, so they'll
5472 # only be used when explicitly requested.
5473 if test "x$enable_dependency_tracking" = xyes; then
5479 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
5480 # This compiler won't grok '-c -o', but also, the minuso test has
5481 # not run yet. These depmodes are late enough in the game, and
5482 # so weak that their functioning should not be impacted.
5483 am__obj=conftest.${OBJEXT-o}
5488 if depmode=$depmode \
5489 source=sub/conftest.c object=$am__obj \
5490 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5491 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5492 >/dev/null 2>conftest.err &&
5493 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5494 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5495 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5496 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5497 # icc doesn't choke on unknown options, it will just issue warnings
5498 # or remarks (even with -Werror). So we grep stderr for any message
5499 # that says an option was ignored or not supported.
5500 # When given -MP, icc 7.0 and 7.1 complain thusly:
5501 # icc: Command line warning: ignoring option '-M'; no argument required
5502 # The diagnosis changed in icc 8.0:
5503 # icc: Command line remark: option '-MP' not supported
5504 if (grep 'ignoring option' conftest.err ||
5505 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5506 am_cv_CC_dependencies_compiler_type=$depmode
5515 am_cv_CC_dependencies_compiler_type=none
5519 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5520 printf "%s\n" "$am_cv_CC_dependencies_compiler_type" >&6; }
5521 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5524 test "x$enable_dependency_tracking" != xno \
5525 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5527 am__fastdepCC_FALSE='#'
5529 am__fastdepCC_TRUE='#'
5530 am__fastdepCC_FALSE=
5535 HELP2MAN=${HELP2MAN-"${am_missing_run}help2man"}
5537 if test -n "$ac_tool_prefix"; then
5538 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5539 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5540 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5541 printf %s "checking for $ac_word... " >&6; }
5542 if ${ac_cv_prog_RANLIB+:} false; then :
5543 printf %s "(cached) " >&6
5545 if test -n "$RANLIB"; then
5546 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5548 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5552 case $as_dir in #(((
5555 *) as_dir=$as_dir/ ;;
5557 for ac_exec_ext in '' $ac_executable_extensions; do
5558 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
5559 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5560 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
5569 RANLIB=$ac_cv_prog_RANLIB
5570 if test -n "$RANLIB"; then
5571 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
5572 printf "%s\n" "$RANLIB" >&6; }
5574 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5575 printf "%s\n" "no" >&6; }
5580 if test -z "$ac_cv_prog_RANLIB"; then
5581 ac_ct_RANLIB=$RANLIB
5582 # Extract the first word of "ranlib", so it can be a program name with args.
5583 set dummy ranlib; ac_word=$2
5584 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5585 printf %s "checking for $ac_word... " >&6; }
5586 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
5587 printf %s "(cached) " >&6
5589 if test -n "$ac_ct_RANLIB"; then
5590 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
5592 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5596 case $as_dir in #(((
5599 *) as_dir=$as_dir/ ;;
5601 for ac_exec_ext in '' $ac_executable_extensions; do
5602 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
5603 ac_cv_prog_ac_ct_RANLIB="ranlib"
5604 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
5613 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
5614 if test -n "$ac_ct_RANLIB"; then
5615 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
5616 printf "%s\n" "$ac_ct_RANLIB" >&6; }
5618 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5619 printf "%s\n" "no" >&6; }
5622 if test "x$ac_ct_RANLIB" = x; then
5625 case $cross_compiling:$ac_tool_warned in
5627 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5628 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5629 ac_tool_warned=yes ;;
5631 RANLIB=$ac_ct_RANLIB
5634 RANLIB="$ac_cv_prog_RANLIB"
5639 ac_cpp='$CPP $CPPFLAGS'
5640 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5641 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5642 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5643 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5644 printf %s "checking how to run the C preprocessor... " >&6; }
5645 # On Suns, sometimes $CPP names a directory.
5646 if test -n "$CPP" && test -d "$CPP"; then
5649 if test -z "$CPP"; then
5650 if ${ac_cv_prog_CPP+:} false; then :
5651 printf %s "(cached) " >&6
5653 # Double quotes because CPP needs to be expanded
5654 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5657 for ac_c_preproc_warn_flag in '' yes
5659 # Use a header file that comes with gcc, so configuring glibc
5660 # with a fresh cross-compiler works.
5661 # On the NeXT, cc -E runs the code through the compiler's parser,
5662 # not just through cpp. "Syntax error" is here to catch this case.
5663 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5664 /* end confdefs.h. */
5668 if ac_fn_c_try_cpp "$LINENO"; then :
5671 # Broken: fails on valid input.
5674 rm -f conftest.err conftest.i conftest.$ac_ext
5676 # OK, works on sane cases. Now check whether nonexistent headers
5677 # can be detected and how.
5678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5679 /* end confdefs.h. */
5680 #include <ac_nonexistent.h>
5682 if ac_fn_c_try_cpp "$LINENO"; then :
5683 # Broken: success on invalid input.
5686 # Passes both tests.
5690 rm -f conftest.err conftest.i conftest.$ac_ext
5693 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5694 rm -f conftest.i conftest.err conftest.$ac_ext
5695 if $ac_preproc_ok; then :
5707 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5708 printf "%s\n" "$CPP" >&6; }
5710 for ac_c_preproc_warn_flag in '' yes
5712 # Use a header file that comes with gcc, so configuring glibc
5713 # with a fresh cross-compiler works.
5714 # On the NeXT, cc -E runs the code through the compiler's parser,
5715 # not just through cpp. "Syntax error" is here to catch this case.
5716 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5717 /* end confdefs.h. */
5721 if ac_fn_c_try_cpp "$LINENO"; then :
5724 # Broken: fails on valid input.
5727 rm -f conftest.err conftest.i conftest.$ac_ext
5729 # OK, works on sane cases. Now check whether nonexistent headers
5730 # can be detected and how.
5731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5732 /* end confdefs.h. */
5733 #include <ac_nonexistent.h>
5735 if ac_fn_c_try_cpp "$LINENO"; then :
5736 # Broken: success on invalid input.
5739 # Passes both tests.
5743 rm -f conftest.err conftest.i conftest.$ac_ext
5746 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5747 rm -f conftest.i conftest.err conftest.$ac_ext
5748 if $ac_preproc_ok; then :
5751 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5752 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
5753 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
5754 See \`config.log' for more details" "$LINENO" 5; }
5758 ac_cpp='$CPP $CPPFLAGS'
5759 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5760 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5761 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5764 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
5765 printf %s "checking for grep that handles long lines and -e... " >&6; }
5766 if ${ac_cv_path_GREP+:} false; then :
5767 printf %s "(cached) " >&6
5769 if test -z "$GREP"; then
5770 ac_path_GREP_found=false
5771 # Loop through the user's path and test for each of PROGNAME-LIST
5772 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5773 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5776 case $as_dir in #(((
5779 *) as_dir=$as_dir/ ;;
5781 for ac_prog in grep ggrep; do
5782 for ac_exec_ext in '' $ac_executable_extensions; do
5783 ac_path_GREP="$as_dir$ac_prog$ac_exec_ext"
5784 as_fn_executable_p "$ac_path_GREP" || continue
5785 # Check for GNU ac_path_GREP and select it if it is found.
5786 # Check for GNU $ac_path_GREP
5787 case `"$ac_path_GREP" --version 2>&1` in
5789 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5792 printf %s 0123456789 >"conftest.in"
5795 cat "conftest.in" "conftest.in" >"conftest.tmp"
5796 mv "conftest.tmp" "conftest.in"
5797 cp "conftest.in" "conftest.nl"
5798 printf "%s\n" 'GREP' >> "conftest.nl"
5799 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5800 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5801 as_fn_arith $ac_count + 1 && ac_count=$as_val
5802 if test $ac_count -gt ${ac_path_GREP_max-0}; then
5803 # Best one so far, save it but keep looking for a better one
5804 ac_cv_path_GREP="$ac_path_GREP"
5805 ac_path_GREP_max=$ac_count
5807 # 10*(2^10) chars as input seems more than enough
5808 test $ac_count -gt 10 && break
5810 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5813 $ac_path_GREP_found && break 3
5818 if test -z "$ac_cv_path_GREP"; then
5819 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5822 ac_cv_path_GREP=$GREP
5826 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
5827 printf "%s\n" "$ac_cv_path_GREP" >&6; }
5828 GREP="$ac_cv_path_GREP"
5831 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
5832 printf %s "checking for egrep... " >&6; }
5833 if ${ac_cv_path_EGREP+:} false; then :
5834 printf %s "(cached) " >&6
5836 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5837 then ac_cv_path_EGREP="$GREP -E"
5839 if test -z "$EGREP"; then
5840 ac_path_EGREP_found=false
5841 # Loop through the user's path and test for each of PROGNAME-LIST
5842 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5843 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5846 case $as_dir in #(((
5849 *) as_dir=$as_dir/ ;;
5851 for ac_prog in egrep; do
5852 for ac_exec_ext in '' $ac_executable_extensions; do
5853 ac_path_EGREP="$as_dir$ac_prog$ac_exec_ext"
5854 as_fn_executable_p "$ac_path_EGREP" || continue
5855 # Check for GNU ac_path_EGREP and select it if it is found.
5856 # Check for GNU $ac_path_EGREP
5857 case `"$ac_path_EGREP" --version 2>&1` in
5859 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5862 printf %s 0123456789 >"conftest.in"
5865 cat "conftest.in" "conftest.in" >"conftest.tmp"
5866 mv "conftest.tmp" "conftest.in"
5867 cp "conftest.in" "conftest.nl"
5868 printf "%s\n" 'EGREP' >> "conftest.nl"
5869 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5870 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5871 as_fn_arith $ac_count + 1 && ac_count=$as_val
5872 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5873 # Best one so far, save it but keep looking for a better one
5874 ac_cv_path_EGREP="$ac_path_EGREP"
5875 ac_path_EGREP_max=$ac_count
5877 # 10*(2^10) chars as input seems more than enough
5878 test $ac_count -gt 10 && break
5880 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5883 $ac_path_EGREP_found && break 3
5888 if test -z "$ac_cv_path_EGREP"; then
5889 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5892 ac_cv_path_EGREP=$EGREP
5897 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
5898 printf "%s\n" "$ac_cv_path_EGREP" >&6; }
5899 EGREP="$ac_cv_path_EGREP"
5904 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
5905 printf %s "checking for Minix Amsterdam compiler... " >&6; }
5906 if ${gl_cv_c_amsterdam_compiler+:} false; then :
5907 printf %s "(cached) " >&6
5910 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5911 /* end confdefs.h. */
5918 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5919 $EGREP "Amsterdam" >/dev/null 2>&1; then :
5920 gl_cv_c_amsterdam_compiler=yes
5922 gl_cv_c_amsterdam_compiler=no
5928 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
5929 printf "%s\n" "$gl_cv_c_amsterdam_compiler" >&6; }
5930 if test -z "$AR"; then
5931 if test $gl_cv_c_amsterdam_compiler = yes; then
5933 if test -z "$ARFLAGS"; then
5937 if test -n "$ac_tool_prefix"; then
5938 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
5939 set dummy ${ac_tool_prefix}ar; ac_word=$2
5940 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5941 printf %s "checking for $ac_word... " >&6; }
5942 if ${ac_cv_prog_AR+:} false; then :
5943 printf %s "(cached) " >&6
5945 if test -n "$AR"; then
5946 ac_cv_prog_AR="$AR" # Let the user override the test.
5948 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5952 case $as_dir in #(((
5955 *) as_dir=$as_dir/ ;;
5957 for ac_exec_ext in '' $ac_executable_extensions; do
5958 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
5959 ac_cv_prog_AR="${ac_tool_prefix}ar"
5960 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
5970 if test -n "$AR"; then
5971 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
5972 printf "%s\n" "$AR" >&6; }
5974 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5975 printf "%s\n" "no" >&6; }
5980 if test -z "$ac_cv_prog_AR"; then
5982 # Extract the first word of "ar", so it can be a program name with args.
5983 set dummy ar; ac_word=$2
5984 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5985 printf %s "checking for $ac_word... " >&6; }
5986 if ${ac_cv_prog_ac_ct_AR+:} false; then :
5987 printf %s "(cached) " >&6
5989 if test -n "$ac_ct_AR"; then
5990 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
5992 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5996 case $as_dir in #(((
5999 *) as_dir=$as_dir/ ;;
6001 for ac_exec_ext in '' $ac_executable_extensions; do
6002 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6003 ac_cv_prog_ac_ct_AR="ar"
6004 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
6013 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6014 if test -n "$ac_ct_AR"; then
6015 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6016 printf "%s\n" "$ac_ct_AR" >&6; }
6018 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6019 printf "%s\n" "no" >&6; }
6022 if test "x$ac_ct_AR" = x; then
6025 case $cross_compiling:$ac_tool_warned in
6027 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6028 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6029 ac_tool_warned=yes ;;
6037 if test -z "$ARFLAGS"; then
6042 if test -z "$ARFLAGS"; then
6048 if test -z "$RANLIB"; then
6049 if test $gl_cv_c_amsterdam_compiler = yes; then
6052 if test -n "$ac_tool_prefix"; then
6053 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6054 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6055 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6056 printf %s "checking for $ac_word... " >&6; }
6057 if ${ac_cv_prog_RANLIB+:} false; then :
6058 printf %s "(cached) " >&6
6060 if test -n "$RANLIB"; then
6061 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6063 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6067 case $as_dir in #(((
6070 *) as_dir=$as_dir/ ;;
6072 for ac_exec_ext in '' $ac_executable_extensions; do
6073 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6074 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6075 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
6084 RANLIB=$ac_cv_prog_RANLIB
6085 if test -n "$RANLIB"; then
6086 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6087 printf "%s\n" "$RANLIB" >&6; }
6089 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6090 printf "%s\n" "no" >&6; }
6095 if test -z "$ac_cv_prog_RANLIB"; then
6096 ac_ct_RANLIB=$RANLIB
6097 # Extract the first word of "ranlib", so it can be a program name with args.
6098 set dummy ranlib; ac_word=$2
6099 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6100 printf %s "checking for $ac_word... " >&6; }
6101 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
6102 printf %s "(cached) " >&6
6104 if test -n "$ac_ct_RANLIB"; then
6105 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6107 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6111 case $as_dir in #(((
6114 *) as_dir=$as_dir/ ;;
6116 for ac_exec_ext in '' $ac_executable_extensions; do
6117 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6118 ac_cv_prog_ac_ct_RANLIB="ranlib"
6119 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
6128 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6129 if test -n "$ac_ct_RANLIB"; then
6130 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6131 printf "%s\n" "$ac_ct_RANLIB" >&6; }
6133 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6134 printf "%s\n" "no" >&6; }
6137 if test "x$ac_ct_RANLIB" = x; then
6140 case $cross_compiling:$ac_tool_warned in
6142 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6143 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6144 ac_tool_warned=yes ;;
6146 RANLIB=$ac_ct_RANLIB
6149 RANLIB="$ac_cv_prog_RANLIB"
6157 # For better backward-compatibility. Users are advised to stop
6158 # relying on this cache variable and C preprocessor symbol ASAP.
6159 eval ac_cv_prog_cc_${am__cc}_c_o=\$am_cv_prog_cc_${am__cc}_c_o
6160 if eval test \"\$ac_cv_prog_cc_${am__cc}_c_o\" != yes; then
6162 printf "%s\n" "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
6166 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6167 printf %s "checking for ANSI C header files... " >&6; }
6168 if ${ac_cv_header_stdc+:} false; then :
6169 printf %s "(cached) " >&6
6171 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6172 /* end confdefs.h. */
6186 if ac_fn_c_try_compile "$LINENO"; then :
6187 ac_cv_header_stdc=yes
6189 ac_cv_header_stdc=no
6191 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6193 if test $ac_cv_header_stdc = yes; then
6194 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6195 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6196 /* end confdefs.h. */
6200 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6201 $EGREP "memchr" >/dev/null 2>&1; then :
6204 ac_cv_header_stdc=no
6210 if test $ac_cv_header_stdc = yes; then
6211 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6212 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6213 /* end confdefs.h. */
6217 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6218 $EGREP "free" >/dev/null 2>&1; then :
6221 ac_cv_header_stdc=no
6227 if test $ac_cv_header_stdc = yes; then
6228 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6229 if test "$cross_compiling" = yes; then :
6232 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6233 /* end confdefs.h. */
6236 #if ((' ' & 0x0FF) == 0x020)
6237 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6238 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6240 # define ISLOWER(c) \
6241 (('a' <= (c) && (c) <= 'i') \
6242 || ('j' <= (c) && (c) <= 'r') \
6243 || ('s' <= (c) && (c) <= 'z'))
6244 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6247 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6252 for (i = 0; i < 256; i++)
6253 if (XOR (islower (i), ISLOWER (i))
6254 || toupper (i) != TOUPPER (i))
6259 if ac_fn_c_try_run "$LINENO"; then :
6262 ac_cv_header_stdc=no
6264 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6265 conftest.$ac_objext conftest.beam conftest.$ac_ext
6270 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6271 printf "%s\n" "$ac_cv_header_stdc" >&6; }
6272 if test $ac_cv_header_stdc = yes; then
6274 printf "%s\n" "#define STDC_HEADERS 1" >>confdefs.h
6278 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6279 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6280 inttypes.h stdint.h unistd.h
6282 as_ac_Header=`printf "%s\n" "ac_cv_header_$ac_header" | $as_tr_sh`
6283 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6285 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
6286 cat >>confdefs.h <<_ACEOF
6287 #define `printf "%s\n" "HAVE_$ac_header" | $as_tr_cpp` 1
6296 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
6297 if test "x$ac_cv_header_minix_config_h" = xyes; then :
6304 if test "$MINIX" = yes; then
6306 printf "%s\n" "#define _POSIX_SOURCE 1" >>confdefs.h
6309 printf "%s\n" "#define _POSIX_1_SOURCE 2" >>confdefs.h
6312 printf "%s\n" "#define _MINIX 1" >>confdefs.h
6315 printf "%s\n" "#define _NETBSD_SOURCE 1" >>confdefs.h
6320 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6321 printf %s "checking whether it is safe to define __EXTENSIONS__... " >&6; }
6322 if ${ac_cv_safe_to_define___extensions__+:} false; then :
6323 printf %s "(cached) " >&6
6325 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6326 /* end confdefs.h. */
6328 # define __EXTENSIONS__ 1
6329 $ac_includes_default
6338 if ac_fn_c_try_compile "$LINENO"; then :
6339 ac_cv_safe_to_define___extensions__=yes
6341 ac_cv_safe_to_define___extensions__=no
6343 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6345 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6346 printf "%s\n" "$ac_cv_safe_to_define___extensions__" >&6; }
6347 test $ac_cv_safe_to_define___extensions__ = yes &&
6348 printf "%s\n" "#define __EXTENSIONS__ 1" >>confdefs.h
6350 printf "%s\n" "#define _ALL_SOURCE 1" >>confdefs.h
6352 printf "%s\n" "#define _DARWIN_C_SOURCE 1" >>confdefs.h
6354 printf "%s\n" "#define _GNU_SOURCE 1" >>confdefs.h
6356 printf "%s\n" "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6358 printf "%s\n" "#define _TANDEM_SOURCE 1" >>confdefs.h
6360 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5
6361 printf %s "checking whether _XOPEN_SOURCE should be defined... " >&6; }
6362 if ${ac_cv_should_define__xopen_source+:} false; then :
6363 printf %s "(cached) " >&6
6365 ac_cv_should_define__xopen_source=no
6366 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6367 /* end confdefs.h. */
6379 if ac_fn_c_try_compile "$LINENO"; then :
6382 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6383 /* end confdefs.h. */
6385 #define _XOPEN_SOURCE 500
6396 if ac_fn_c_try_compile "$LINENO"; then :
6397 ac_cv_should_define__xopen_source=yes
6399 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6401 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6403 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5
6404 printf "%s\n" "$ac_cv_should_define__xopen_source" >&6; }
6405 test $ac_cv_should_define__xopen_source = yes &&
6406 printf "%s\n" "#define _XOPEN_SOURCE 500" >>confdefs.h
6415 # Make sure we can run config.sub.
6416 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
6417 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
6419 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
6420 printf %s "checking build system type... " >&6; }
6421 if ${ac_cv_build+:} false; then :
6422 printf %s "(cached) " >&6
6424 ac_build_alias=$build_alias
6425 test "x$ac_build_alias" = x &&
6426 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
6427 test "x$ac_build_alias" = x &&
6428 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
6429 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
6430 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
6433 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
6434 printf "%s\n" "$ac_cv_build" >&6; }
6435 case $ac_cv_build in
6437 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
6440 ac_save_IFS=$IFS; IFS='-'
6446 # Remember, the first character of IFS is used to create $*,
6447 # except with old shells:
6450 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
6453 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
6454 printf %s "checking host system type... " >&6; }
6455 if ${ac_cv_host+:} false; then :
6456 printf %s "(cached) " >&6
6458 if test "x$host_alias" = x; then
6459 ac_cv_host=$ac_cv_build
6461 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
6462 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
6466 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
6467 printf "%s\n" "$ac_cv_host" >&6; }
6470 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
6473 ac_save_IFS=$IFS; IFS='-'
6479 # Remember, the first character of IFS is used to create $*,
6480 # except with old shells:
6483 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
6489 # IEEE behaviour is the default on all CPUs except Alpha and SH
6490 # (according to the test results of Bruno Haible's ieeefp/fenv_default.m4
6491 # and the GCC 4.1.2 manual).
6494 # On Alpha systems, a compiler option provides the behaviour.
6495 # See the ieee(3) manual page, also available at
6496 # <http://h30097.www3.hp.com/docs/base_doc/DOCUMENTATION/V51B_HTML/MAN/MAN3/0600____.HTM>
6497 if test -n "$GCC"; then
6498 # GCC has the option -mieee.
6499 # For full IEEE compliance (rarely needed), use option -mieee-with-inexact.
6500 CPPFLAGS="$CPPFLAGS -mieee"
6502 # Compaq (ex-DEC) C has the option -ieee, equivalent to -ieee_with_no_inexact.
6503 # For full IEEE compliance (rarely needed), use option -ieee_with_inexact.
6504 CPPFLAGS="$CPPFLAGS -ieee"
6508 if test -n "$GCC"; then
6509 # GCC has the option -mieee.
6510 CPPFLAGS="$CPPFLAGS -mieee"
6515 # Check whether --enable-largefile was given.
6516 if test "${enable_largefile+set}" = set; then :
6517 enableval=$enable_largefile;
6520 if test "$enable_largefile" != no; then
6522 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
6523 printf %s "checking for special C compiler options needed for large files... " >&6; }
6524 if ${ac_cv_sys_largefile_CC+:} false; then :
6525 printf %s "(cached) " >&6
6527 ac_cv_sys_largefile_CC=no
6528 if test "$GCC" != yes; then
6531 # IRIX 6.2 and later do not support large files by default,
6532 # so use the C compiler's -n32 option if that helps.
6533 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6534 /* end confdefs.h. */
6535 #include <sys/types.h>
6536 /* Check that off_t can represent 2**63 - 1 correctly.
6537 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6538 since some C++ compilers masquerading as C compilers
6539 incorrectly reject 9223372036854775807. */
6540 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6541 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6542 && LARGE_OFF_T % 2147483647 == 1)
6552 if ac_fn_c_try_compile "$LINENO"; then :
6555 rm -f core conftest.err conftest.$ac_objext
6557 if ac_fn_c_try_compile "$LINENO"; then :
6558 ac_cv_sys_largefile_CC=' -n32'; break
6560 rm -f core conftest.err conftest.$ac_objext
6564 rm -f conftest.$ac_ext
6567 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
6568 printf "%s\n" "$ac_cv_sys_largefile_CC" >&6; }
6569 if test "$ac_cv_sys_largefile_CC" != no; then
6570 CC=$CC$ac_cv_sys_largefile_CC
6573 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
6574 printf %s "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
6575 if ${ac_cv_sys_file_offset_bits+:} false; then :
6576 printf %s "(cached) " >&6
6579 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6580 /* end confdefs.h. */
6581 #include <sys/types.h>
6582 /* Check that off_t can represent 2**63 - 1 correctly.
6583 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6584 since some C++ compilers masquerading as C compilers
6585 incorrectly reject 9223372036854775807. */
6586 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6587 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6588 && LARGE_OFF_T % 2147483647 == 1)
6598 if ac_fn_c_try_compile "$LINENO"; then :
6599 ac_cv_sys_file_offset_bits=no; break
6601 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6602 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6603 /* end confdefs.h. */
6604 #define _FILE_OFFSET_BITS 64
6605 #include <sys/types.h>
6606 /* Check that off_t can represent 2**63 - 1 correctly.
6607 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6608 since some C++ compilers masquerading as C compilers
6609 incorrectly reject 9223372036854775807. */
6610 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6611 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6612 && LARGE_OFF_T % 2147483647 == 1)
6622 if ac_fn_c_try_compile "$LINENO"; then :
6623 ac_cv_sys_file_offset_bits=64; break
6625 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6626 ac_cv_sys_file_offset_bits=unknown
6630 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6631 printf "%s\n" "$ac_cv_sys_file_offset_bits" >&6; }
6632 case $ac_cv_sys_file_offset_bits in #(
6635 cat >>confdefs.h <<_ACEOF
6636 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6641 if test $ac_cv_sys_file_offset_bits = unknown; then
6642 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6643 printf %s "checking for _LARGE_FILES value needed for large files... " >&6; }
6644 if ${ac_cv_sys_large_files+:} false; then :
6645 printf %s "(cached) " >&6
6648 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6649 /* end confdefs.h. */
6650 #include <sys/types.h>
6651 /* Check that off_t can represent 2**63 - 1 correctly.
6652 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6653 since some C++ compilers masquerading as C compilers
6654 incorrectly reject 9223372036854775807. */
6655 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6656 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6657 && LARGE_OFF_T % 2147483647 == 1)
6667 if ac_fn_c_try_compile "$LINENO"; then :
6668 ac_cv_sys_large_files=no; break
6670 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6671 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6672 /* end confdefs.h. */
6673 #define _LARGE_FILES 1
6674 #include <sys/types.h>
6675 /* Check that off_t can represent 2**63 - 1 correctly.
6676 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6677 since some C++ compilers masquerading as C compilers
6678 incorrectly reject 9223372036854775807. */
6679 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6680 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6681 && LARGE_OFF_T % 2147483647 == 1)
6691 if ac_fn_c_try_compile "$LINENO"; then :
6692 ac_cv_sys_large_files=1; break
6694 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6695 ac_cv_sys_large_files=unknown
6699 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6700 printf "%s\n" "$ac_cv_sys_large_files" >&6; }
6701 case $ac_cv_sys_large_files in #(
6704 cat >>confdefs.h <<_ACEOF
6705 #define _LARGE_FILES $ac_cv_sys_large_files
6713 printf "%s\n" "#define _DARWIN_USE_64_BIT_INODE 1" >>confdefs.h
6721 # Code from module alloca:
6722 # Code from module alloca-opt:
6723 # Code from module alloca-opt-tests:
6724 # Code from module allocator:
6725 # Code from module announce-gen:
6726 # Code from module areadlink:
6727 # Code from module areadlink-tests:
6728 # Code from module argmatch:
6729 # Code from module argmatch-tests:
6730 # Code from module binary-io:
6731 # Code from module binary-io-tests:
6732 # Code from module bitrotate:
6733 # Code from module bitrotate-tests:
6734 # Code from module btowc:
6735 # Code from module btowc-tests:
6736 # Code from module c-ctype:
6737 # Code from module c-ctype-tests:
6738 # Code from module c-stack:
6739 # Code from module c-stack-tests:
6740 # Code from module c-strcase:
6741 # Code from module c-strcase-tests:
6742 # Code from module c-strcaseeq:
6743 # Code from module careadlinkat:
6744 # Code from module clock-time:
6745 # Code from module close:
6746 # Code from module close-tests:
6747 # Code from module config-h:
6748 # Code from module configmake:
6749 # Code from module diffseq:
6750 # Code from module dirname:
6751 # Code from module dirname-lgpl:
6752 # Code from module dirname-tests:
6753 # Code from module do-release-commit-and-tag:
6754 # Code from module dosname:
6755 # Code from module double-slash-root:
6756 # Code from module dup2:
6757 # Code from module dup2-tests:
6758 # Code from module environ:
6759 # Code from module environ-tests:
6760 # Code from module errno:
6761 # Code from module errno-tests:
6762 # Code from module error:
6763 # Code from module exclude:
6764 # Code from module exclude-tests:
6765 # Code from module exitfail:
6766 # Code from module extensions:
6768 # Code from module extern-inline:
6769 # Code from module fcntl:
6770 # Code from module fcntl-h:
6771 # Code from module fcntl-h-tests:
6772 # Code from module fcntl-tests:
6773 # Code from module fd-hook:
6774 # Code from module fdl:
6775 # Code from module fdopen:
6776 # Code from module fdopen-tests:
6777 # Code from module fgetc-tests:
6778 # Code from module file-type:
6779 # Code from module filenamecat:
6780 # Code from module filenamecat-lgpl:
6781 # Code from module filenamecat-tests:
6782 # Code from module float:
6783 # Code from module float-tests:
6784 # Code from module fnmatch:
6785 # Code from module fnmatch-gnu:
6786 # Code from module fnmatch-tests:
6787 # Code from module fpieee:
6789 # Code from module fpucw:
6790 # Code from module fputc-tests:
6791 # Code from module fread-tests:
6792 # Code from module freopen:
6793 # Code from module freopen-safer:
6794 # Code from module freopen-safer-tests:
6795 # Code from module freopen-tests:
6796 # Code from module fstat:
6797 # Code from module fstat-tests:
6798 # Code from module fwrite-tests:
6799 # Code from module gendocs:
6800 # Code from module getcwd-lgpl:
6801 # Code from module getcwd-lgpl-tests:
6802 # Code from module getdtablesize:
6803 # Code from module getdtablesize-tests:
6804 # Code from module getopt:
6805 # Code from module getopt-gnu:
6806 # Code from module getopt-posix:
6807 # Code from module getopt-posix-tests:
6808 # Code from module getpagesize:
6809 # Code from module gettext-h:
6810 # Code from module gettime:
6811 # Code from module gettimeofday:
6812 # Code from module gettimeofday-tests:
6813 # Code from module git-version-gen:
6814 # Code from module gitlog-to-changelog:
6815 # Code from module gnu-make:
6816 # Code from module gnu-web-doc-update:
6817 # Code from module gnumakefile:
6818 # Code from module gnupload:
6819 # Code from module gperf:
6820 # Code from module hard-locale:
6821 # Code from module hash:
6822 # Code from module hash-pjw:
6823 # Code from module hash-tests:
6824 # Code from module havelib:
6825 # Code from module iconv:
6826 # Code from module iconv-h:
6827 # Code from module iconv-h-tests:
6828 # Code from module iconv-tests:
6829 # Code from module iconv_open:
6830 # Code from module ignore-value:
6831 # Code from module ignore-value-tests:
6832 # Code from module include_next:
6833 # Code from module inline:
6834 # Code from module intprops:
6835 # Code from module intprops-tests:
6836 # Code from module inttostr:
6837 # Code from module inttostr-tests:
6838 # Code from module inttypes:
6839 # Code from module inttypes-incomplete:
6840 # Code from module inttypes-tests:
6841 # Code from module iswblank:
6842 # Code from module iswblank-tests:
6843 # Code from module langinfo:
6844 # Code from module langinfo-tests:
6845 # Code from module largefile:
6847 # Code from module libsigsegv:
6848 # Code from module localcharset:
6849 # Code from module locale:
6850 # Code from module locale-tests:
6851 # Code from module localeconv:
6852 # Code from module localeconv-tests:
6853 # Code from module lstat:
6854 # Code from module lstat-tests:
6855 # Code from module maintainer-makefile:
6856 # Code from module malloc-gnu:
6857 # Code from module malloc-gnu-tests:
6858 # Code from module malloc-posix:
6859 # Code from module malloca:
6860 # Code from module malloca-tests:
6861 # Code from module manywarnings:
6862 # Code from module mbchar:
6863 # Code from module mbiter:
6864 # Code from module mbrtowc:
6865 # Code from module mbrtowc-tests:
6866 # Code from module mbscasecmp:
6867 # Code from module mbscasecmp-tests:
6868 # Code from module mbsinit:
6869 # Code from module mbsinit-tests:
6870 # Code from module mbslen:
6871 # Code from module mbsrtowcs:
6872 # Code from module mbsrtowcs-tests:
6873 # Code from module mbsstr:
6874 # Code from module mbsstr-tests:
6875 # Code from module mbtowc:
6876 # Code from module mbuiter:
6877 # Code from module memchr:
6878 # Code from module memchr-tests:
6879 # Code from module mkstemp:
6880 # Code from module mktime:
6881 # Code from module msvc-inval:
6882 # Code from module msvc-nothrow:
6883 # Code from module multiarch:
6884 # Code from module nl_langinfo:
6885 # Code from module nl_langinfo-tests:
6886 # Code from module nocrash:
6887 # Code from module open:
6888 # Code from module open-tests:
6889 # Code from module pathmax:
6890 # Code from module pathmax-tests:
6891 # Code from module progname:
6892 # Code from module propername:
6893 # Code from module putenv:
6894 # Code from module quote:
6895 # Code from module quotearg:
6896 # Code from module quotearg-simple:
6897 # Code from module quotearg-simple-tests:
6898 # Code from module raise:
6899 # Code from module raise-tests:
6900 # Code from module readlink:
6901 # Code from module readlink-tests:
6902 # Code from module readme-release:
6903 # Code from module regex:
6904 # Code from module regex-tests:
6905 # Code from module same-inode:
6906 # Code from module secure_getenv:
6907 # Code from module setenv:
6908 # Code from module setenv-tests:
6909 # Code from module setlocale:
6910 # Code from module setlocale-tests:
6911 # Code from module sh-quote:
6912 # Code from module sh-quote-tests:
6913 # Code from module sigaction:
6914 # Code from module sigaction-tests:
6915 # Code from module signal:
6916 # Code from module signal-h:
6917 # Code from module signal-h-tests:
6918 # Code from module sigprocmask:
6919 # Code from module sigprocmask-tests:
6920 # Code from module size_max:
6921 # Code from module sleep:
6922 # Code from module sleep-tests:
6923 # Code from module snippet/_Noreturn:
6924 # Code from module snippet/arg-nonnull:
6925 # Code from module snippet/c++defs:
6926 # Code from module snippet/unused-parameter:
6927 # Code from module snippet/warn-on-use:
6928 # Code from module snprintf:
6929 # Code from module snprintf-tests:
6930 # Code from module ssize_t:
6931 # Code from module stat:
6932 # Code from module stat-macros:
6933 # Code from module stat-tests:
6934 # Code from module stat-time:
6935 # Code from module stat-time-tests:
6936 # Code from module stdarg:
6940 # Code from module stdbool:
6941 # Code from module stdbool-tests:
6942 # Code from module stddef:
6943 # Code from module stddef-tests:
6944 # Code from module stdint:
6945 # Code from module stdint-tests:
6946 # Code from module stdio:
6947 # Code from module stdio-tests:
6948 # Code from module stdlib:
6949 # Code from module stdlib-tests:
6950 # Code from module strcase:
6951 # Code from module streq:
6952 # Code from module strerror:
6953 # Code from module strerror-override:
6954 # Code from module strerror-tests:
6955 # Code from module strftime:
6956 # Code from module strftime-tests:
6957 # Code from module striconv:
6958 # Code from module striconv-tests:
6959 # Code from module string:
6960 # Code from module string-tests:
6961 # Code from module strings:
6962 # Code from module strings-tests:
6963 # Code from module strndup:
6964 # Code from module strnlen:
6965 # Code from module strnlen-tests:
6966 # Code from module strnlen1:
6967 # Code from module strptime:
6968 # Code from module strtoull:
6969 # Code from module strtoull-tests:
6970 # Code from module strtoumax:
6971 # Code from module strtoumax-tests:
6972 # Code from module symlink:
6973 # Code from module symlink-tests:
6974 # Code from module sys_stat:
6975 # Code from module sys_stat-tests:
6976 # Code from module sys_time:
6977 # Code from module sys_time-tests:
6978 # Code from module sys_types:
6979 # Code from module sys_types-tests:
6980 # Code from module sys_wait:
6981 # Code from module sys_wait-tests:
6982 # Code from module system-quote:
6983 # Code from module tempname:
6984 # Code from module test-framework-sh:
6985 # Code from module test-framework-sh-tests:
6986 # Code from module time:
6987 # Code from module time-tests:
6988 # Code from module time_r:
6989 # Code from module timespec:
6990 # Code from module trim:
6991 # Code from module unistd:
6992 # Code from module unistd-tests:
6993 # Code from module unistr/base:
6994 # Code from module unistr/u8-mbtoucr:
6995 # Code from module unistr/u8-mbtoucr-tests:
6996 # Code from module unistr/u8-uctomb:
6997 # Code from module unistr/u8-uctomb-tests:
6998 # Code from module unitypes:
6999 # Code from module uniwidth/base:
7000 # Code from module uniwidth/width:
7001 # Code from module uniwidth/width-tests:
7002 # Code from module unlocked-io:
7003 # Code from module unsetenv:
7004 # Code from module unsetenv-tests:
7005 # Code from module update-copyright:
7006 # Code from module update-copyright-tests:
7007 # Code from module useless-if-before-free:
7008 # Code from module usleep:
7009 # Code from module usleep-tests:
7010 # Code from module vararrays:
7011 # Code from module vasnprintf:
7012 # Code from module vasnprintf-tests:
7013 # Code from module vasprintf:
7014 # Code from module vasprintf-tests:
7015 # Code from module vc-list-files:
7016 # Code from module vc-list-files-tests:
7017 # Code from module verify:
7018 # Code from module verify-tests:
7019 # Code from module version-etc:
7020 # Code from module version-etc-fsf:
7021 # Code from module version-etc-tests:
7022 # Code from module warnings:
7023 # Code from module wchar:
7024 # Code from module wchar-tests:
7025 # Code from module wcrtomb:
7026 # Code from module wcrtomb-tests:
7027 # Code from module wctob:
7028 # Code from module wctomb:
7029 # Code from module wctype-h:
7030 # Code from module wctype-h-tests:
7031 # Code from module wcwidth:
7032 # Code from module wcwidth-tests:
7033 # Code from module xalloc:
7034 # Code from module xalloc-die:
7035 # Code from module xalloc-die-tests:
7036 # Code from module xalloc-oversized:
7037 # Code from module xfreopen:
7038 # Code from module xreadlink:
7039 # Code from module xsize:
7040 # Code from module xstriconv:
7041 # Code from module xstrndup:
7042 # Code from module xstrtol:
7043 # Code from module xstrtol-tests:
7044 # Code from module xstrtoumax:
7045 # Code from module xstrtoumax-tests:
7046 # Code from module xvasprintf:
7047 # Code from module xvasprintf-tests:
7055 LIBC_FATAL_STDERR_=1
7056 export LIBC_FATAL_STDERR_
7058 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
7059 if test "x$ac_cv_type_size_t" = xyes; then :
7063 cat >>confdefs.h <<_ACEOF
7064 #define size_t unsigned int
7069 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
7070 # for constant arguments. Useless!
7071 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
7072 printf %s "checking for working alloca.h... " >&6; }
7073 if ${ac_cv_working_alloca_h+:} false; then :
7074 printf %s "(cached) " >&6
7076 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7077 /* end confdefs.h. */
7082 char *p = (char *) alloca (2 * sizeof (int));
7088 if ac_fn_c_try_link "$LINENO"; then :
7089 ac_cv_working_alloca_h=yes
7091 ac_cv_working_alloca_h=no
7093 rm -f core conftest.err conftest.$ac_objext \
7094 conftest$ac_exeext conftest.$ac_ext
7096 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
7097 printf "%s\n" "$ac_cv_working_alloca_h" >&6; }
7098 if test $ac_cv_working_alloca_h = yes; then
7100 printf "%s\n" "#define HAVE_ALLOCA_H 1" >>confdefs.h
7104 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
7105 printf %s "checking for alloca... " >&6; }
7106 if ${ac_cv_func_alloca_works+:} false; then :
7107 printf %s "(cached) " >&6
7109 if test $ac_cv_working_alloca_h = yes; then
7110 ac_cv_func_alloca_works=yes
7112 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7113 /* end confdefs.h. */
7114 #if defined STDC_HEADERS || defined HAVE_STDLIB_H
7115 # include <stdlib.h>
7120 # define alloca __builtin_alloca
7121 # elif defined _MSC_VER
7122 # include <malloc.h>
7123 # define alloca _alloca
7128 void *alloca (size_t);
7135 char *p = (char *) alloca (1);
7141 if ac_fn_c_try_link "$LINENO"; then :
7142 ac_cv_func_alloca_works=yes
7144 ac_cv_func_alloca_works=no
7146 rm -f core conftest.err conftest.$ac_objext \
7147 conftest$ac_exeext conftest.$ac_ext
7149 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
7150 printf "%s\n" "$ac_cv_func_alloca_works" >&6; }
7153 if test $ac_cv_func_alloca_works = yes; then
7155 printf "%s\n" "#define HAVE_ALLOCA 1" >>confdefs.h
7158 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
7159 # that cause trouble. Some versions do not even contain alloca or
7160 # contain a buggy version. If you still want to use their alloca,
7161 # use ar to extract alloca.o from them instead of compiling alloca.c.
7167 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
7169 printf "%s\n" "#define C_ALLOCA 1" >>confdefs.h
7172 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
7173 printf %s "checking whether \`alloca.c' needs Cray hooks... " >&6; }
7174 if ${ac_cv_os_cray+:} false; then :
7175 printf %s "(cached) " >&6
7177 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7178 /* end confdefs.h. */
7179 #if defined CRAY && ! defined CRAY2
7186 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7187 $EGREP "webecray" >/dev/null 2>&1; then :
7195 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
7196 printf "%s\n" "$ac_cv_os_cray" >&6; }
7197 if test $ac_cv_os_cray = yes; then
7198 for ac_func in _getb67 GETB67 getb67; do
7199 as_ac_var=`printf "%s\n" "ac_cv_func_$ac_func" | $as_tr_sh`
7200 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
7201 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
7203 cat >>confdefs.h <<_ACEOF
7204 #define CRAY_STACKSEG_END $ac_func
7213 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
7214 printf %s "checking stack direction for C alloca... " >&6; }
7215 if ${ac_cv_c_stack_direction+:} false; then :
7216 printf %s "(cached) " >&6
7218 if test "$cross_compiling" = yes; then :
7219 ac_cv_c_stack_direction=0
7221 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7222 /* end confdefs.h. */
7223 $ac_includes_default
7225 find_stack_direction (int *addr, int depth)
7230 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
7231 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
7236 main (int argc, char **argv)
7238 return find_stack_direction (0, argc + !argv + 20) < 0;
7241 if ac_fn_c_try_run "$LINENO"; then :
7242 ac_cv_c_stack_direction=1
7244 ac_cv_c_stack_direction=-1
7246 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7247 conftest.$ac_objext conftest.beam conftest.$ac_ext
7251 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
7252 printf "%s\n" "$ac_cv_c_stack_direction" >&6; }
7253 cat >>confdefs.h <<_ACEOF
7254 #define STACK_DIRECTION $ac_cv_c_stack_direction
7267 GNULIB_MBSNRTOWCS=0;
7270 GNULIB_WCSNRTOMBS=0;
7287 GNULIB_WCSCASECMP=0;
7288 GNULIB_WCSNCASECMP=0;
7338 HAVE_DECL_WCWIDTH=1;
7339 REPLACE_MBSTATE_T=0;
7345 REPLACE_MBSRTOWCS=0;
7346 REPLACE_MBSNRTOWCS=0;
7348 REPLACE_WCSRTOMBS=0;
7349 REPLACE_WCSNRTOMBS=0;
7354 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether <wchar.h> uses 'inline' correctly" >&5
7355 printf %s "checking whether <wchar.h> uses 'inline' correctly... " >&6; }
7356 if ${gl_cv_header_wchar_h_correct_inline+:} false; then :
7357 printf %s "(cached) " >&6
7359 gl_cv_header_wchar_h_correct_inline=yes
7360 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7361 /* end confdefs.h. */
7363 #define wcstod renamed_wcstod
7364 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
7366 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
7367 included before <wchar.h>. */
7372 extern int zero (void);
7373 int main () { return zero(); }
7376 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
7377 (eval $ac_compile) 2>&5
7379 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7380 test $ac_status = 0; }; then
7381 mv conftest.$ac_objext conftest1.$ac_objext
7382 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7383 /* end confdefs.h. */
7385 #define wcstod renamed_wcstod
7386 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
7388 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
7389 included before <wchar.h>. */
7394 int zero (void) { return 0; }
7397 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
7398 (eval $ac_compile) 2>&5
7400 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7401 test $ac_status = 0; }; then
7402 mv conftest.$ac_objext conftest2.$ac_objext
7403 if $CC -o conftest$ac_exeext $CFLAGS $LDFLAGS conftest1.$ac_objext conftest2.$ac_objext $LIBS >&5 2>&1; then
7406 gl_cv_header_wchar_h_correct_inline=no
7410 rm -f conftest1.$ac_objext conftest2.$ac_objext conftest$ac_exeext
7413 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_wchar_h_correct_inline" >&5
7414 printf "%s\n" "$gl_cv_header_wchar_h_correct_inline" >&6; }
7415 if test $gl_cv_header_wchar_h_correct_inline = no; then
7416 as_fn_error $? "<wchar.h> cannot be used with this compiler ($CC $CFLAGS $CPPFLAGS).
7417 This is a known interoperability problem of glibc <= 2.5 with gcc >= 4.3 in
7418 C99 mode. You have four options:
7419 - Add the flag -fgnu89-inline to CC and reconfigure, or
7420 - Fix your include files, using parts of
7421 <http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=b037a293a48718af30d706c2e18c929d0e69a621>, or
7422 - Use a gcc version older than 4.3, or
7423 - Don't use the flags -std=c99 or -std=gnu99.
7424 Configuration aborted." "$LINENO" 5
7430 for ac_func in $ac_func_list
7432 as_ac_var=`printf "%s\n" "ac_cv_func_$ac_func" | $as_tr_sh`
7433 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
7434 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
7435 cat >>confdefs.h <<_ACEOF
7436 #define `printf "%s\n" "HAVE_$ac_func" | $as_tr_cpp` 1
7445 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
7446 printf %s "checking for nl_langinfo and CODESET... " >&6; }
7447 if ${am_cv_langinfo_codeset+:} false; then :
7448 printf %s "(cached) " >&6
7450 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7451 /* end confdefs.h. */
7452 #include <langinfo.h>
7456 char* cs = nl_langinfo(CODESET); return !cs;
7461 if ac_fn_c_try_link "$LINENO"; then :
7462 am_cv_langinfo_codeset=yes
7464 am_cv_langinfo_codeset=no
7466 rm -f core conftest.err conftest.$ac_objext \
7467 conftest$ac_exeext conftest.$ac_ext
7470 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
7471 printf "%s\n" "$am_cv_langinfo_codeset" >&6; }
7472 if test $am_cv_langinfo_codeset = yes; then
7474 printf "%s\n" "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
7481 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
7482 printf %s "checking for a traditional french locale... " >&6; }
7483 if ${gt_cv_locale_fr+:} false; then :
7484 printf %s "(cached) " >&6
7487 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7488 /* end confdefs.h. */
7492 #if HAVE_LANGINFO_CODESET
7493 # include <langinfo.h>
7500 /* Check whether the given locale name is recognized by the system. */
7501 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
7502 /* On native Windows, setlocale(category, "") looks at the system settings,
7503 not at the environment variables. Also, when an encoding suffix such
7504 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
7505 category of the locale to "C". */
7506 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
7507 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
7510 if (setlocale (LC_ALL, "") == NULL) return 1;
7512 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
7513 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
7514 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
7515 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
7516 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
7517 some unit tests fail.
7518 On MirBSD 10, when an unsupported locale is specified, setlocale()
7519 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
7520 #if HAVE_LANGINFO_CODESET
7522 const char *cs = nl_langinfo (CODESET);
7523 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
7524 || strcmp (cs, "UTF-8") == 0)
7529 /* On Cygwin, avoid locale names without encoding suffix, because the
7530 locale_charset() function relies on the encoding suffix. Note that
7531 LC_ALL is set on the command line. */
7532 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
7534 /* Check whether in the abbreviation of the second month, the second
7535 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
7536 one byte long. This excludes the UTF-8 encoding. */
7537 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
7538 if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
7539 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
7540 /* Check whether the decimal separator is a comma.
7541 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
7542 are nl_langinfo(RADIXCHAR) are both ".". */
7543 if (localeconv () ->decimal_point[0] != ',') return 1;
7549 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
7550 (eval $ac_link) 2>&5
7552 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7553 test $ac_status = 0; } && test -s conftest$ac_exeext; then
7555 # Handle native Windows specially, because there setlocale() interprets
7556 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
7557 # "fr" or "fra" as "French" or "French_France.1252",
7558 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
7559 # "ja" as "Japanese" or "Japanese_Japan.932",
7562 # Test for the native Windows locale name.
7563 if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
7564 gt_cv_locale_fr=French_France.1252
7567 gt_cv_locale_fr=none
7571 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
7572 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
7573 # configure script would override the LC_ALL setting. Likewise for
7574 # LC_CTYPE, which is also set at the beginning of the configure script.
7575 # Test for the usual locale name.
7576 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
7577 gt_cv_locale_fr=fr_FR
7579 # Test for the locale name with explicit encoding suffix.
7580 if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
7581 gt_cv_locale_fr=fr_FR.ISO-8859-1
7583 # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
7584 if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
7585 gt_cv_locale_fr=fr_FR.ISO8859-1
7587 # Test for the HP-UX locale name.
7588 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
7589 gt_cv_locale_fr=fr_FR.iso88591
7591 # Test for the Solaris 7 locale name.
7592 if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
7596 gt_cv_locale_fr=none
7608 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
7609 printf "%s\n" "$gt_cv_locale_fr" >&6; }
7610 LOCALE_FR=$gt_cv_locale_fr
7618 for ac_header in $ac_header_list
7620 as_ac_Header=`printf "%s\n" "ac_cv_header_$ac_header" | $as_tr_sh`
7621 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
7623 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
7624 cat >>confdefs.h <<_ACEOF
7625 #define `printf "%s\n" "HAVE_$ac_header" | $as_tr_cpp` 1
7640 sunos4* | freebsd* | dragonfly* | openbsd* | mirbsd* | netbsd* | kfreebsd* | knetbsd*) # BSD systems
7641 FAULT_YIELDS_SIGBUS=1 ;;
7643 FAULT_YIELDS_SIGBUS=1 ;;
7644 macos* | darwin*) # Mac OS X
7645 FAULT_YIELDS_SIGBUS=1 ;;
7647 FAULT_YIELDS_SIGBUS=1 ;;
7649 FAULT_YIELDS_SIGBUS=0 ;;
7652 cat >>confdefs.h <<_ACEOF
7653 #define FAULT_YIELDS_SIGBUS $FAULT_YIELDS_SIGBUS
7657 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working C stack overflow detection" >&5
7658 printf %s "checking for working C stack overflow detection... " >&6; }
7659 if ${ac_cv_sys_stack_overflow_works+:} false; then :
7660 printf %s "(cached) " >&6
7662 if test "$cross_compiling" = yes; then :
7663 ac_cv_sys_stack_overflow_works=cross-compiling
7665 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7666 /* end confdefs.h. */
7671 # include <sys/types.h>
7672 # include <sys/time.h>
7673 # include <sys/resource.h>
7676 # define SIGSTKSZ 16384
7681 char buffer[2 * SIGSTKSZ];
7685 } alternate_signal_stack;
7688 segv_handler (int signo)
7697 struct sigaction act;
7701 /* Use the midpoint to avoid Irix sigaltstack bug. */
7702 st.ss_sp = alternate_signal_stack.buffer + SIGSTKSZ;
7703 st.ss_size = SIGSTKSZ;
7704 r = sigaltstack (&st, 0);
7708 sigemptyset (&act.sa_mask);
7709 act.sa_flags = SA_NODEFER | SA_ONSTACK | SA_RESETHAND;
7710 act.sa_handler = segv_handler;
7711 #if FAULT_YIELDS_SIGBUS
7712 if (sigaction (SIGBUS, &act, 0) < 0)
7715 if (sigaction (SIGSEGV, &act, 0) < 0)
7719 static volatile int *
7720 recurse_1 (volatile int n, volatile int *p)
7723 *recurse_1 (n + 1, p) += n;
7727 recurse (volatile int n)
7730 return *recurse_1 (n, &sum);
7736 #if HAVE_SETRLIMIT && defined RLIMIT_STACK
7737 /* Before starting the endless recursion, try to be friendly
7738 to the user's machine. On some Linux 2.2.x systems, there
7739 is no stack limit for user processes at all. We don't want
7740 to kill such systems. */
7742 rl.rlim_cur = rl.rlim_max = 0x100000; /* 1 MB */
7743 setrlimit (RLIMIT_STACK, &rl);
7746 result = c_stack_action ();
7753 if ac_fn_c_try_run "$LINENO"; then :
7754 ac_cv_sys_stack_overflow_works=yes
7756 ac_cv_sys_stack_overflow_works=no
7758 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7759 conftest.$ac_objext conftest.beam conftest.$ac_ext
7763 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_stack_overflow_works" >&5
7764 printf "%s\n" "$ac_cv_sys_stack_overflow_works" >&6; }
7766 if test $ac_cv_sys_stack_overflow_works = yes; then
7768 printf "%s\n" "#define HAVE_STACK_OVERFLOW_HANDLING 1" >>confdefs.h
7771 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for correct stack_t interpretation" >&5
7772 printf %s "checking for correct stack_t interpretation... " >&6; }
7773 if ${gl_cv_sigaltstack_low_base+:} false; then :
7774 printf %s "(cached) " >&6
7777 if test "$cross_compiling" = yes; then :
7778 gl_cv_sigaltstack_low_base=cross-compiling
7780 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7781 /* end confdefs.h. */
7786 #if HAVE_SYS_SIGNAL_H
7787 # include <sys/signal.h>
7790 # define SIGSTKSZ 16384
7792 volatile char *stack_lower_bound;
7793 volatile char *stack_upper_bound;
7794 static void check_stack_location (volatile char *addr)
7796 if (addr >= stack_lower_bound && addr <= stack_upper_bound)
7801 static void stackoverflow_handler (int sig)
7804 check_stack_location (&dummy);
7808 char mystack[2 * SIGSTKSZ];
7810 struct sigaction action;
7811 /* Install the alternate stack. */
7812 altstack.ss_sp = mystack + SIGSTKSZ;
7813 altstack.ss_size = SIGSTKSZ;
7814 stack_lower_bound = (char *) altstack.ss_sp;
7815 stack_upper_bound = (char *) altstack.ss_sp + altstack.ss_size - 1;
7816 altstack.ss_flags = 0; /* no SS_DISABLE */
7817 if (sigaltstack (&altstack, NULL) < 0)
7819 /* Install the SIGSEGV handler. */
7820 sigemptyset (&action.sa_mask);
7821 action.sa_handler = &stackoverflow_handler;
7822 action.sa_flags = SA_ONSTACK;
7823 if (sigaction (SIGSEGV, &action, (struct sigaction *) NULL) < 0)
7825 /* Provoke a SIGSEGV. */
7830 if ac_fn_c_try_run "$LINENO"; then :
7831 gl_cv_sigaltstack_low_base=yes
7833 gl_cv_sigaltstack_low_base=no
7835 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7836 conftest.$ac_objext conftest.beam conftest.$ac_ext
7840 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sigaltstack_low_base" >&5
7841 printf "%s\n" "$gl_cv_sigaltstack_low_base" >&6; }
7842 if test "$gl_cv_sigaltstack_low_base" = no; then
7844 printf "%s\n" "#define SIGALTSTACK_SS_REVERSED 1" >>confdefs.h
7848 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for precise C stack overflow detection" >&5
7849 printf %s "checking for precise C stack overflow detection... " >&6; }
7850 if ${ac_cv_sys_xsi_stack_overflow_heuristic+:} false; then :
7851 printf %s "(cached) " >&6
7853 if test "$cross_compiling" = yes; then :
7854 ac_cv_sys_xsi_stack_overflow_heuristic=cross-compiling
7856 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7857 /* end confdefs.h. */
7862 # include <ucontext.h>
7865 # include <sys/types.h>
7866 # include <sys/time.h>
7867 # include <sys/resource.h>
7870 # define SIGSTKSZ 16384
7875 char buffer[2 * SIGSTKSZ];
7879 } alternate_signal_stack;
7882 # define find_stack_direction(ptr) STACK_DIRECTION
7885 find_stack_direction (char const *addr)
7888 return (! addr ? find_stack_direction (&dummy)
7889 : addr < &dummy ? 1 : -1);
7894 segv_handler (int signo, siginfo_t *info, void *context)
7896 if (0 < info->si_code)
7898 /* For XSI heuristics to work, we need uc_stack to describe
7899 the interrupted stack (as on Solaris), and not the
7900 currently executing stack (as on Linux). */
7901 ucontext_t const *user_context = context;
7902 char const *stack_min = user_context->uc_stack.ss_sp;
7903 size_t stack_size = user_context->uc_stack.ss_size;
7904 char const *faulting_address = info->si_addr;
7905 size_t s = faulting_address - stack_min;
7906 size_t page_size = sysconf (_SC_PAGESIZE);
7907 if (find_stack_direction (0) < 0)
7909 if (s < stack_size + page_size)
7920 struct sigaction act;
7924 /* Use the midpoint to avoid Irix sigaltstack bug. */
7925 st.ss_sp = alternate_signal_stack.buffer + SIGSTKSZ;
7926 st.ss_size = SIGSTKSZ;
7927 r = sigaltstack (&st, 0);
7931 sigemptyset (&act.sa_mask);
7932 act.sa_flags = SA_NODEFER | SA_ONSTACK | SA_RESETHAND | SA_SIGINFO;
7933 act.sa_sigaction = segv_handler;
7934 #if FAULT_YIELDS_SIGBUS
7935 if (sigaction (SIGBUS, &act, 0) < 0)
7938 if (sigaction (SIGSEGV, &act, 0) < 0)
7942 static volatile int *
7943 recurse_1 (volatile int n, volatile int *p)
7946 *recurse_1 (n + 1, p) += n;
7950 recurse (volatile int n)
7953 return *recurse_1 (n, &sum);
7959 #if HAVE_SETRLIMIT && defined RLIMIT_STACK
7960 /* Before starting the endless recursion, try to be friendly
7961 to the user's machine. On some Linux 2.2.x systems, there
7962 is no stack limit for user processes at all. We don't want
7963 to kill such systems. */
7965 rl.rlim_cur = rl.rlim_max = 0x100000; /* 1 MB */
7966 setrlimit (RLIMIT_STACK, &rl);
7969 result = c_stack_action ();
7976 if ac_fn_c_try_run "$LINENO"; then :
7977 ac_cv_sys_xsi_stack_overflow_heuristic=yes
7979 ac_cv_sys_xsi_stack_overflow_heuristic=no
7981 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7982 conftest.$ac_objext conftest.beam conftest.$ac_ext
7986 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_xsi_stack_overflow_heuristic" >&5
7987 printf "%s\n" "$ac_cv_sys_xsi_stack_overflow_heuristic" >&6; }
7989 if test $ac_cv_sys_xsi_stack_overflow_heuristic = yes; then
7991 printf "%s\n" "#define HAVE_XSI_STACK_OVERFLOW_HEURISTIC 1" >>confdefs.h
7996 if test "X$prefix" = "XNONE"; then
7997 acl_final_prefix="$ac_default_prefix"
7999 acl_final_prefix="$prefix"
8001 if test "X$exec_prefix" = "XNONE"; then
8002 acl_final_exec_prefix='${prefix}'
8004 acl_final_exec_prefix="$exec_prefix"
8006 acl_save_prefix="$prefix"
8007 prefix="$acl_final_prefix"
8008 eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
8009 prefix="$acl_save_prefix"
8013 # Check whether --with-gnu-ld was given.
8014 if test "${with_gnu_ld+set}" = set; then :
8015 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
8020 # Prepare PATH_SEPARATOR.
8021 # The user is always right.
8022 if test "${PATH_SEPARATOR+set}" != set; then
8023 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
8024 # contains only /bin. Note that ksh looks also at the FPATH variable,
8025 # so we have to set that as well for the test.
8027 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8028 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8029 || PATH_SEPARATOR=';'
8034 if test "$GCC" = yes; then
8035 # Check if gcc -print-prog-name=ld gives a path.
8036 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
8037 printf %s "checking for ld used by $CC... " >&6; }
8040 # gcc leaves a trailing carriage return which upsets mingw
8041 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
8043 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
8046 # Accept absolute paths.
8048 re_direlt='/[^/][^/]*/\.\./'
8049 # Canonicalize the pathname of ld
8050 ac_prog=`echo "$ac_prog"| sed 's%\\\\%/%g'`
8051 while echo "$ac_prog" | grep "$re_direlt" > /dev/null 2>&1; do
8052 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
8054 test -z "$LD" && LD="$ac_prog"
8057 # If it fails, then pretend we aren't using GCC.
8061 # If it is relative, then search for the first ld in PATH.
8065 elif test "$with_gnu_ld" = yes; then
8066 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
8067 printf %s "checking for GNU ld... " >&6; }
8069 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
8070 printf %s "checking for non-GNU ld... " >&6; }
8072 if ${acl_cv_path_LD+:} false; then :
8073 printf %s "(cached) " >&6
8075 if test -z "$LD"; then
8076 acl_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
8077 for ac_dir in $PATH; do
8079 test -z "$ac_dir" && ac_dir=.
8080 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
8081 acl_cv_path_LD="$ac_dir/$ac_prog"
8082 # Check to see if the program is GNU ld. I'd rather use --version,
8083 # but apparently some variants of GNU ld only accept -v.
8084 # Break only if it was the GNU/non-GNU ld that we prefer.
8085 case `"$acl_cv_path_LD" -v 2>&1 </dev/null` in
8086 *GNU* | *'with BFD'*)
8087 test "$with_gnu_ld" != no && break
8090 test "$with_gnu_ld" != yes && break
8097 acl_cv_path_LD="$LD" # Let the user override the test with a path.
8101 LD="$acl_cv_path_LD"
8102 if test -n "$LD"; then
8103 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
8104 printf "%s\n" "$LD" >&6; }
8106 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8107 printf "%s\n" "no" >&6; }
8109 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
8110 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
8111 printf %s "checking if the linker ($LD) is GNU ld... " >&6; }
8112 if ${acl_cv_prog_gnu_ld+:} false; then :
8113 printf %s "(cached) " >&6
8115 # I'd rather use --version here, but apparently some GNU lds only accept -v.
8116 case `$LD -v 2>&1 </dev/null` in
8117 *GNU* | *'with BFD'*)
8118 acl_cv_prog_gnu_ld=yes
8121 acl_cv_prog_gnu_ld=no
8125 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
8126 printf "%s\n" "$acl_cv_prog_gnu_ld" >&6; }
8127 with_gnu_ld=$acl_cv_prog_gnu_ld
8132 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
8133 printf %s "checking for shared library run path origin... " >&6; }
8134 if ${acl_cv_rpath+:} false; then :
8135 printf %s "(cached) " >&6
8138 CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
8139 ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
8145 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
8146 printf "%s\n" "$acl_cv_rpath" >&6; }
8148 acl_libext="$acl_cv_libext"
8149 acl_shlibext="$acl_cv_shlibext"
8150 acl_libname_spec="$acl_cv_libname_spec"
8151 acl_library_names_spec="$acl_cv_library_names_spec"
8152 acl_hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
8153 acl_hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
8154 acl_hardcode_direct="$acl_cv_hardcode_direct"
8155 acl_hardcode_minus_L="$acl_cv_hardcode_minus_L"
8156 # Check whether --enable-rpath was given.
8157 if test "${enable_rpath+set}" = set; then :
8158 enableval=$enable_rpath; :
8170 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for 64-bit host" >&5
8171 printf %s "checking for 64-bit host... " >&6; }
8172 if ${gl_cv_solaris_64bit+:} false; then :
8173 printf %s "(cached) " >&6
8175 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8176 /* end confdefs.h. */
8183 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8184 $EGREP "sixtyfour bits" >/dev/null 2>&1; then :
8185 gl_cv_solaris_64bit=yes
8187 gl_cv_solaris_64bit=no
8193 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_solaris_64bit" >&5
8194 printf "%s\n" "$gl_cv_solaris_64bit" >&6; }
8195 if test $gl_cv_solaris_64bit = yes; then
8196 acl_libdirstem=lib/64
8198 sparc*) acl_libdirstem2=lib/sparcv9 ;;
8199 i*86 | x86_64) acl_libdirstem2=lib/amd64 ;;
8204 searchpath=`(LC_ALL=C $CC -print-search-dirs) 2>/dev/null | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'`
8205 if test -n "$searchpath"; then
8206 acl_save_IFS="${IFS= }"; IFS=":"
8207 for searchdir in $searchpath; do
8208 if test -d "$searchdir"; then
8209 case "$searchdir" in
8210 */lib64/ | */lib64 ) acl_libdirstem=lib64 ;;
8212 # Better ignore directories of this form. They are misleading.
8214 *) searchdir=`cd "$searchdir" && pwd`
8215 case "$searchdir" in
8216 */lib64 ) acl_libdirstem=lib64 ;;
8225 test -n "$acl_libdirstem2" || acl_libdirstem2="$acl_libdirstem"
8243 acl_save_prefix="$prefix"
8244 prefix="$acl_final_prefix"
8245 acl_save_exec_prefix="$exec_prefix"
8246 exec_prefix="$acl_final_exec_prefix"
8248 eval additional_includedir=\"$includedir\"
8249 eval additional_libdir=\"$libdir\"
8251 exec_prefix="$acl_save_exec_prefix"
8252 prefix="$acl_save_prefix"
8255 # Check whether --with-libsigsegv-prefix was given.
8256 if test "${with_libsigsegv_prefix+set}" = set; then :
8257 withval=$with_libsigsegv_prefix;
8258 if test "X$withval" = "Xno"; then
8261 if test "X$withval" = "X"; then
8263 acl_save_prefix="$prefix"
8264 prefix="$acl_final_prefix"
8265 acl_save_exec_prefix="$exec_prefix"
8266 exec_prefix="$acl_final_exec_prefix"
8268 eval additional_includedir=\"$includedir\"
8269 eval additional_libdir=\"$libdir\"
8271 exec_prefix="$acl_save_exec_prefix"
8272 prefix="$acl_save_prefix"
8275 additional_includedir="$withval/include"
8276 additional_libdir="$withval/$acl_libdirstem"
8277 if test "$acl_libdirstem2" != "$acl_libdirstem" \
8278 && ! test -d "$withval/$acl_libdirstem"; then
8279 additional_libdir="$withval/$acl_libdirstem2"
8293 names_already_handled=
8294 names_next_round='sigsegv '
8295 while test -n "$names_next_round"; do
8296 names_this_round="$names_next_round"
8298 for name in $names_this_round; do
8300 for n in $names_already_handled; do
8301 if test "$n" = "$name"; then
8306 if test -z "$already_handled"; then
8307 names_already_handled="$names_already_handled $name"
8308 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./+-|ABCDEFGHIJKLMNOPQRSTUVWXYZ____|'`
8309 eval value=\"\$HAVE_LIB$uppername\"
8310 if test -n "$value"; then
8311 if test "$value" = yes; then
8312 eval value=\"\$LIB$uppername\"
8313 test -z "$value" || LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }$value"
8314 eval value=\"\$LTLIB$uppername\"
8315 test -z "$value" || LTLIBSIGSEGV="${LTLIBSIGSEGV}${LTLIBSIGSEGV:+ }$value"
8324 eval libname=\"$acl_libname_spec\" # typically: libname=lib$name
8325 if test -n "$acl_shlibext"; then
8326 shrext=".$acl_shlibext" # typically: shrext=.so
8330 if test $use_additional = yes; then
8331 dir="$additional_libdir"
8332 if test -n "$acl_shlibext"; then
8333 if test -f "$dir/$libname$shrext"; then
8335 found_so="$dir/$libname$shrext"
8337 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
8338 ver=`(cd "$dir" && \
8339 for f in "$libname$shrext".*; do echo "$f"; done \
8340 | sed -e "s,^$libname$shrext\\\\.,," \
8341 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
8342 | sed 1q ) 2>/dev/null`
8343 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
8345 found_so="$dir/$libname$shrext.$ver"
8348 eval library_names=\"$acl_library_names_spec\"
8349 for f in $library_names; do
8350 if test -f "$dir/$f"; then
8359 if test "X$found_dir" = "X"; then
8360 if test -f "$dir/$libname.$acl_libext"; then
8362 found_a="$dir/$libname.$acl_libext"
8365 if test "X$found_dir" != "X"; then
8366 if test -f "$dir/$libname.la"; then
8367 found_la="$dir/$libname.la"
8371 if test "X$found_dir" = "X"; then
8372 for x in $LDFLAGS $LTLIBSIGSEGV; do
8374 acl_save_prefix="$prefix"
8375 prefix="$acl_final_prefix"
8376 acl_save_exec_prefix="$exec_prefix"
8377 exec_prefix="$acl_final_exec_prefix"
8379 exec_prefix="$acl_save_exec_prefix"
8380 prefix="$acl_save_prefix"
8384 dir=`echo "X$x" | sed -e 's/^X-L//'`
8385 if test -n "$acl_shlibext"; then
8386 if test -f "$dir/$libname$shrext"; then
8388 found_so="$dir/$libname$shrext"
8390 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
8391 ver=`(cd "$dir" && \
8392 for f in "$libname$shrext".*; do echo "$f"; done \
8393 | sed -e "s,^$libname$shrext\\\\.,," \
8394 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
8395 | sed 1q ) 2>/dev/null`
8396 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
8398 found_so="$dir/$libname$shrext.$ver"
8401 eval library_names=\"$acl_library_names_spec\"
8402 for f in $library_names; do
8403 if test -f "$dir/$f"; then
8412 if test "X$found_dir" = "X"; then
8413 if test -f "$dir/$libname.$acl_libext"; then
8415 found_a="$dir/$libname.$acl_libext"
8418 if test "X$found_dir" != "X"; then
8419 if test -f "$dir/$libname.la"; then
8420 found_la="$dir/$libname.la"
8425 if test "X$found_dir" != "X"; then
8430 if test "X$found_dir" != "X"; then
8431 LTLIBSIGSEGV="${LTLIBSIGSEGV}${LTLIBSIGSEGV:+ }-L$found_dir -l$name"
8432 if test "X$found_so" != "X"; then
8433 if test "$enable_rpath" = no \
8434 || test "X$found_dir" = "X/usr/$acl_libdirstem" \
8435 || test "X$found_dir" = "X/usr/$acl_libdirstem2"; then
8436 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }$found_so"
8439 for x in $ltrpathdirs; do
8440 if test "X$x" = "X$found_dir"; then
8445 if test -z "$haveit"; then
8446 ltrpathdirs="$ltrpathdirs $found_dir"
8448 if test "$acl_hardcode_direct" = yes; then
8449 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }$found_so"
8451 if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
8452 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }$found_so"
8454 for x in $rpathdirs; do
8455 if test "X$x" = "X$found_dir"; then
8460 if test -z "$haveit"; then
8461 rpathdirs="$rpathdirs $found_dir"
8465 for x in $LDFLAGS $LIBSIGSEGV; do
8467 acl_save_prefix="$prefix"
8468 prefix="$acl_final_prefix"
8469 acl_save_exec_prefix="$exec_prefix"
8470 exec_prefix="$acl_final_exec_prefix"
8472 exec_prefix="$acl_save_exec_prefix"
8473 prefix="$acl_save_prefix"
8475 if test "X$x" = "X-L$found_dir"; then
8480 if test -z "$haveit"; then
8481 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }-L$found_dir"
8483 if test "$acl_hardcode_minus_L" != no; then
8484 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }$found_so"
8486 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }-l$name"
8492 if test "X$found_a" != "X"; then
8493 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }$found_a"
8495 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }-L$found_dir -l$name"
8498 additional_includedir=
8499 case "$found_dir" in
8500 */$acl_libdirstem | */$acl_libdirstem/)
8501 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
8502 if test "$name" = 'sigsegv'; then
8503 LIBSIGSEGV_PREFIX="$basedir"
8505 additional_includedir="$basedir/include"
8507 */$acl_libdirstem2 | */$acl_libdirstem2/)
8508 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
8509 if test "$name" = 'sigsegv'; then
8510 LIBSIGSEGV_PREFIX="$basedir"
8512 additional_includedir="$basedir/include"
8515 if test "X$additional_includedir" != "X"; then
8516 if test "X$additional_includedir" != "X/usr/include"; then
8518 if test "X$additional_includedir" = "X/usr/local/include"; then
8519 if test -n "$GCC"; then
8521 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
8525 if test -z "$haveit"; then
8526 for x in $CPPFLAGS $INCSIGSEGV; do
8528 acl_save_prefix="$prefix"
8529 prefix="$acl_final_prefix"
8530 acl_save_exec_prefix="$exec_prefix"
8531 exec_prefix="$acl_final_exec_prefix"
8533 exec_prefix="$acl_save_exec_prefix"
8534 prefix="$acl_save_prefix"
8536 if test "X$x" = "X-I$additional_includedir"; then
8541 if test -z "$haveit"; then
8542 if test -d "$additional_includedir"; then
8543 INCSIGSEGV="${INCSIGSEGV}${INCSIGSEGV:+ }-I$additional_includedir"
8549 if test -n "$found_la"; then
8550 save_libdir="$libdir"
8552 */* | *\\*) . "$found_la" ;;
8553 *) . "./$found_la" ;;
8555 libdir="$save_libdir"
8556 for dep in $dependency_libs; do
8559 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
8560 if test "X$additional_libdir" != "X/usr/$acl_libdirstem" \
8561 && test "X$additional_libdir" != "X/usr/$acl_libdirstem2"; then
8563 if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem" \
8564 || test "X$additional_libdir" = "X/usr/local/$acl_libdirstem2"; then
8565 if test -n "$GCC"; then
8567 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
8571 if test -z "$haveit"; then
8573 for x in $LDFLAGS $LIBSIGSEGV; do
8575 acl_save_prefix="$prefix"
8576 prefix="$acl_final_prefix"
8577 acl_save_exec_prefix="$exec_prefix"
8578 exec_prefix="$acl_final_exec_prefix"
8580 exec_prefix="$acl_save_exec_prefix"
8581 prefix="$acl_save_prefix"
8583 if test "X$x" = "X-L$additional_libdir"; then
8588 if test -z "$haveit"; then
8589 if test -d "$additional_libdir"; then
8590 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }-L$additional_libdir"
8594 for x in $LDFLAGS $LTLIBSIGSEGV; do
8596 acl_save_prefix="$prefix"
8597 prefix="$acl_final_prefix"
8598 acl_save_exec_prefix="$exec_prefix"
8599 exec_prefix="$acl_final_exec_prefix"
8601 exec_prefix="$acl_save_exec_prefix"
8602 prefix="$acl_save_prefix"
8604 if test "X$x" = "X-L$additional_libdir"; then
8609 if test -z "$haveit"; then
8610 if test -d "$additional_libdir"; then
8611 LTLIBSIGSEGV="${LTLIBSIGSEGV}${LTLIBSIGSEGV:+ }-L$additional_libdir"
8618 dir=`echo "X$dep" | sed -e 's/^X-R//'`
8619 if test "$enable_rpath" != no; then
8621 for x in $rpathdirs; do
8622 if test "X$x" = "X$dir"; then
8627 if test -z "$haveit"; then
8628 rpathdirs="$rpathdirs $dir"
8631 for x in $ltrpathdirs; do
8632 if test "X$x" = "X$dir"; then
8637 if test -z "$haveit"; then
8638 ltrpathdirs="$ltrpathdirs $dir"
8643 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
8646 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
8649 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }$dep"
8650 LTLIBSIGSEGV="${LTLIBSIGSEGV}${LTLIBSIGSEGV:+ }$dep"
8656 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }-l$name"
8657 LTLIBSIGSEGV="${LTLIBSIGSEGV}${LTLIBSIGSEGV:+ }-l$name"
8663 if test "X$rpathdirs" != "X"; then
8664 if test -n "$acl_hardcode_libdir_separator"; then
8666 for found_dir in $rpathdirs; do
8667 alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir"
8669 acl_save_libdir="$libdir"
8671 eval flag=\"$acl_hardcode_libdir_flag_spec\"
8672 libdir="$acl_save_libdir"
8673 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }$flag"
8675 for found_dir in $rpathdirs; do
8676 acl_save_libdir="$libdir"
8678 eval flag=\"$acl_hardcode_libdir_flag_spec\"
8679 libdir="$acl_save_libdir"
8680 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }$flag"
8684 if test "X$ltrpathdirs" != "X"; then
8685 for found_dir in $ltrpathdirs; do
8686 LTLIBSIGSEGV="${LTLIBSIGSEGV}${LTLIBSIGSEGV:+ }-R$found_dir"
8696 ac_save_CPPFLAGS="$CPPFLAGS"
8698 for element in $INCSIGSEGV; do
8700 for x in $CPPFLAGS; do
8702 acl_save_prefix="$prefix"
8703 prefix="$acl_final_prefix"
8704 acl_save_exec_prefix="$exec_prefix"
8705 exec_prefix="$acl_final_exec_prefix"
8707 exec_prefix="$acl_save_exec_prefix"
8708 prefix="$acl_save_prefix"
8710 if test "X$x" = "X$element"; then
8715 if test -z "$haveit"; then
8716 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
8721 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libsigsegv" >&5
8722 printf %s "checking for libsigsegv... " >&6; }
8723 if ${ac_cv_libsigsegv+:} false; then :
8724 printf %s "(cached) " >&6
8727 ac_save_LIBS="$LIBS"
8728 case " $LIBSIGSEGV" in
8729 *" -l"*) LIBS="$LIBS $LIBSIGSEGV" ;;
8730 *) LIBS="$LIBSIGSEGV $LIBS" ;;
8732 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8733 /* end confdefs.h. */
8734 #include <sigsegv.h>
8738 sigsegv_deinstall_handler();
8743 if ac_fn_c_try_link "$LINENO"; then :
8744 ac_cv_libsigsegv=yes
8746 ac_cv_libsigsegv='no, consider installing GNU libsigsegv'
8748 rm -f core conftest.err conftest.$ac_objext \
8749 conftest$ac_exeext conftest.$ac_ext
8750 LIBS="$ac_save_LIBS"
8753 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libsigsegv" >&5
8754 printf "%s\n" "$ac_cv_libsigsegv" >&6; }
8755 if test "$ac_cv_libsigsegv" = yes; then
8758 printf "%s\n" "#define HAVE_LIBSIGSEGV 1" >>confdefs.h
8760 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to link with libsigsegv" >&5
8761 printf %s "checking how to link with libsigsegv... " >&6; }
8762 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LIBSIGSEGV" >&5
8763 printf "%s\n" "$LIBSIGSEGV" >&6; }
8766 CPPFLAGS="$ac_save_CPPFLAGS"
8778 gl_cv_lib_sigsegv="$ac_cv_libsigsegv"
8794 GNULIB_EUIDACCESS=0;
8802 GNULIB_GETDOMAINNAME=0;
8803 GNULIB_GETDTABLESIZE=0;
8805 GNULIB_GETHOSTNAME=0;
8807 GNULIB_GETLOGIN_R=0;
8808 GNULIB_GETPAGESIZE=0;
8809 GNULIB_GETUSERSHELL=0;
8810 GNULIB_GROUP_MEMBER=0;
8822 GNULIB_READLINKAT=0;
8824 GNULIB_SETHOSTNAME=0;
8829 GNULIB_UNISTD_H_NONBLOCKING=0;
8830 GNULIB_UNISTD_H_SIGPIPE=0;
8845 HAVE_GETDTABLESIZE=1;
8850 HAVE_GROUP_MEMBER=1;
8866 HAVE_DECL_ENVIRON=1;
8868 HAVE_DECL_FDATASYNC=1;
8869 HAVE_DECL_GETDOMAINNAME=1;
8870 HAVE_DECL_GETLOGIN_R=1;
8871 HAVE_DECL_GETPAGESIZE=1;
8872 HAVE_DECL_GETUSERSHELL=1;
8873 HAVE_DECL_SETHOSTNAME=1;
8874 HAVE_DECL_TTYNAME_R=1;
8882 REPLACE_FTRUNCATE=0;
8884 REPLACE_GETDOMAINNAME=0;
8885 REPLACE_GETLOGIN_R=0;
8886 REPLACE_GETGROUPS=0;
8887 REPLACE_GETPAGESIZE=0;
8900 REPLACE_TTYNAME_R=0;
8905 UNISTD_H_HAVE_WINSOCK2_H=0;
8906 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
8913 if test $ac_cv_func__set_invalid_parameter_handler = yes; then
8914 HAVE_MSVC_INVALID_PARAMETER_HANDLER=1
8916 printf "%s\n" "#define HAVE_MSVC_INVALID_PARAMETER_HANDLER 1" >>confdefs.h
8919 HAVE_MSVC_INVALID_PARAMETER_HANDLER=0
8927 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether // is distinct from /" >&5
8928 printf %s "checking whether // is distinct from /... " >&6; }
8929 if ${gl_cv_double_slash_root+:} false; then :
8930 printf %s "(cached) " >&6
8932 if test x"$cross_compiling" = xyes ; then
8933 # When cross-compiling, there is no way to tell whether // is special
8934 # short of a list of hosts. However, the only known hosts to date
8935 # that have a distinct // are Apollo DomainOS (too old to port to),
8936 # Cygwin, and z/OS. If anyone knows of another system for which // has
8937 # special semantics and is distinct from /, please report it to
8938 # <bug-gnulib@gnu.org>.
8940 *-cygwin | i370-ibm-openedition)
8941 gl_cv_double_slash_root=yes ;;
8943 # Be optimistic and assume that / and // are the same when we
8945 gl_cv_double_slash_root='unknown, assuming no' ;;
8948 set x `ls -di / // 2>/dev/null`
8949 if test "$2" = "$4" && wc //dev/null >/dev/null 2>&1; then
8950 gl_cv_double_slash_root=no
8952 gl_cv_double_slash_root=yes
8956 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_double_slash_root" >&5
8957 printf "%s\n" "$gl_cv_double_slash_root" >&6; }
8958 if test "$gl_cv_double_slash_root" = yes; then
8960 printf "%s\n" "#define DOUBLE_SLASH_IS_DISTINCT_ROOT 1" >>confdefs.h
8970 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
8971 printf %s "checking whether the preprocessor supports include_next... " >&6; }
8972 if ${gl_cv_have_include_next+:} false; then :
8973 printf %s "(cached) " >&6
8975 rm -rf conftestd1a conftestd1b conftestd2
8976 mkdir conftestd1a conftestd1b conftestd2
8977 cat <<EOF > conftestd1a/conftest.h
8978 #define DEFINED_IN_CONFTESTD1
8979 #include_next <conftest.h>
8980 #ifdef DEFINED_IN_CONFTESTD2
8983 #error "include_next doesn't work"
8986 cat <<EOF > conftestd1b/conftest.h
8987 #define DEFINED_IN_CONFTESTD1
8989 #include_next <conftest.h>
8990 #ifdef DEFINED_IN_CONFTESTD2
8993 #error "include_next doesn't work"
8996 cat <<EOF > conftestd2/conftest.h
8997 #ifndef DEFINED_IN_CONFTESTD1
8998 #error "include_next test doesn't work"
9000 #define DEFINED_IN_CONFTESTD2
9002 gl_save_CPPFLAGS="$CPPFLAGS"
9003 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
9004 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9005 /* end confdefs.h. */
9006 #include <conftest.h>
9008 if ac_fn_c_try_compile "$LINENO"; then :
9009 gl_cv_have_include_next=yes
9011 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
9012 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9013 /* end confdefs.h. */
9014 #include <conftest.h>
9016 if ac_fn_c_try_compile "$LINENO"; then :
9017 gl_cv_have_include_next=buggy
9019 gl_cv_have_include_next=no
9021 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9024 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9025 CPPFLAGS="$gl_save_CPPFLAGS"
9026 rm -rf conftestd1a conftestd1b conftestd2
9029 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
9030 printf "%s\n" "$gl_cv_have_include_next" >&6; }
9031 PRAGMA_SYSTEM_HEADER=
9032 if test $gl_cv_have_include_next = yes; then
9033 INCLUDE_NEXT=include_next
9034 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
9035 if test -n "$GCC"; then
9036 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
9039 if test $gl_cv_have_include_next = buggy; then
9040 INCLUDE_NEXT=include
9041 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
9043 INCLUDE_NEXT=include
9044 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
9050 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
9051 printf %s "checking whether system header files limit the line length... " >&6; }
9052 if ${gl_cv_pragma_columns+:} false; then :
9053 printf %s "(cached) " >&6
9055 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9056 /* end confdefs.h. */
9063 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9064 $EGREP "choke me" >/dev/null 2>&1; then :
9065 gl_cv_pragma_columns=yes
9067 gl_cv_pragma_columns=no
9073 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
9074 printf "%s\n" "$gl_cv_pragma_columns" >&6; }
9075 if test $gl_cv_pragma_columns = yes; then
9076 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
9084 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for complete errno.h" >&5
9085 printf %s "checking for complete errno.h... " >&6; }
9086 if ${gl_cv_header_errno_h_complete+:} false; then :
9087 printf %s "(cached) " >&6
9090 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9091 /* end confdefs.h. */
9094 #if !defined ETXTBSY
9103 #if !defined ENOLINK
9109 #if !defined EMULTIHOP
9112 #if !defined EBADMSG
9115 #if !defined EOVERFLOW
9118 #if !defined ENOTSUP
9121 #if !defined ENETRESET
9124 #if !defined ECONNABORTED
9133 #if !defined ECANCELED
9136 #if !defined EOWNERDEAD
9139 #if !defined ENOTRECOVERABLE
9147 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9148 $EGREP "booboo" >/dev/null 2>&1; then :
9149 gl_cv_header_errno_h_complete=no
9151 gl_cv_header_errno_h_complete=yes
9157 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_complete" >&5
9158 printf "%s\n" "$gl_cv_header_errno_h_complete" >&6; }
9159 if test $gl_cv_header_errno_h_complete = yes; then
9170 if test $gl_cv_have_include_next = yes; then
9171 gl_cv_next_errno_h='<'errno.h'>'
9173 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <errno.h>" >&5
9174 printf %s "checking absolute name of <errno.h>... " >&6; }
9175 if ${gl_cv_next_errno_h+:} false; then :
9176 printf %s "(cached) " >&6
9179 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9180 /* end confdefs.h. */
9185 aix*) gl_absname_cpp="$ac_cpp -C" ;;
9186 *) gl_absname_cpp="$ac_cpp" ;;
9191 gl_dirsep_regex='[/\\]'
9194 gl_dirsep_regex='\/'
9197 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
9199 gl_header_literal_regex=`echo 'errno.h' \
9200 | sed -e "$gl_make_literal_regex_sed"`
9201 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
9202 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
9207 gl_cv_next_errno_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
9208 sed -n "$gl_absolute_header_sed"`'"'
9212 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_errno_h" >&5
9213 printf "%s\n" "$gl_cv_next_errno_h" >&6; }
9215 NEXT_ERRNO_H=$gl_cv_next_errno_h
9217 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
9218 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
9219 gl_next_as_first_directive='<'errno.h'>'
9221 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
9222 gl_next_as_first_directive=$gl_cv_next_errno_h
9224 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H=$gl_next_as_first_directive
9232 if test -n "$ERRNO_H"; then
9233 GL_GENERATE_ERRNO_H_TRUE=
9234 GL_GENERATE_ERRNO_H_FALSE='#'
9236 GL_GENERATE_ERRNO_H_TRUE='#'
9237 GL_GENERATE_ERRNO_H_FALSE=
9241 if test -n "$ERRNO_H"; then
9242 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for EMULTIHOP value" >&5
9243 printf %s "checking for EMULTIHOP value... " >&6; }
9244 if ${gl_cv_header_errno_h_EMULTIHOP+:} false; then :
9245 printf %s "(cached) " >&6
9248 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9249 /* end confdefs.h. */
9257 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9258 $EGREP "yes" >/dev/null 2>&1; then :
9259 gl_cv_header_errno_h_EMULTIHOP=yes
9261 gl_cv_header_errno_h_EMULTIHOP=no
9265 if test $gl_cv_header_errno_h_EMULTIHOP = no; then
9266 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9267 /* end confdefs.h. */
9269 #define _XOPEN_SOURCE_EXTENDED 1
9276 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9277 $EGREP "yes" >/dev/null 2>&1; then :
9278 gl_cv_header_errno_h_EMULTIHOP=hidden
9282 if test $gl_cv_header_errno_h_EMULTIHOP = hidden; then
9283 if ac_fn_c_compute_int "$LINENO" "EMULTIHOP" "gl_cv_header_errno_h_EMULTIHOP" "
9284 #define _XOPEN_SOURCE_EXTENDED 1
9286 /* The following two lines are a workaround against an autoconf-2.52 bug. */
9297 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EMULTIHOP" >&5
9298 printf "%s\n" "$gl_cv_header_errno_h_EMULTIHOP" >&6; }
9299 case $gl_cv_header_errno_h_EMULTIHOP in
9301 EMULTIHOP_HIDDEN=0; EMULTIHOP_VALUE=
9304 EMULTIHOP_HIDDEN=1; EMULTIHOP_VALUE="$gl_cv_header_errno_h_EMULTIHOP"
9312 if test -n "$ERRNO_H"; then
9313 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ENOLINK value" >&5
9314 printf %s "checking for ENOLINK value... " >&6; }
9315 if ${gl_cv_header_errno_h_ENOLINK+:} false; then :
9316 printf %s "(cached) " >&6
9319 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9320 /* end confdefs.h. */
9328 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9329 $EGREP "yes" >/dev/null 2>&1; then :
9330 gl_cv_header_errno_h_ENOLINK=yes
9332 gl_cv_header_errno_h_ENOLINK=no
9336 if test $gl_cv_header_errno_h_ENOLINK = no; then
9337 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9338 /* end confdefs.h. */
9340 #define _XOPEN_SOURCE_EXTENDED 1
9347 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9348 $EGREP "yes" >/dev/null 2>&1; then :
9349 gl_cv_header_errno_h_ENOLINK=hidden
9353 if test $gl_cv_header_errno_h_ENOLINK = hidden; then
9354 if ac_fn_c_compute_int "$LINENO" "ENOLINK" "gl_cv_header_errno_h_ENOLINK" "
9355 #define _XOPEN_SOURCE_EXTENDED 1
9357 /* The following two lines are a workaround against an autoconf-2.52 bug. */
9368 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_ENOLINK" >&5
9369 printf "%s\n" "$gl_cv_header_errno_h_ENOLINK" >&6; }
9370 case $gl_cv_header_errno_h_ENOLINK in
9372 ENOLINK_HIDDEN=0; ENOLINK_VALUE=
9375 ENOLINK_HIDDEN=1; ENOLINK_VALUE="$gl_cv_header_errno_h_ENOLINK"
9383 if test -n "$ERRNO_H"; then
9384 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for EOVERFLOW value" >&5
9385 printf %s "checking for EOVERFLOW value... " >&6; }
9386 if ${gl_cv_header_errno_h_EOVERFLOW+:} false; then :
9387 printf %s "(cached) " >&6
9390 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9391 /* end confdefs.h. */
9399 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9400 $EGREP "yes" >/dev/null 2>&1; then :
9401 gl_cv_header_errno_h_EOVERFLOW=yes
9403 gl_cv_header_errno_h_EOVERFLOW=no
9407 if test $gl_cv_header_errno_h_EOVERFLOW = no; then
9408 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9409 /* end confdefs.h. */
9411 #define _XOPEN_SOURCE_EXTENDED 1
9418 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9419 $EGREP "yes" >/dev/null 2>&1; then :
9420 gl_cv_header_errno_h_EOVERFLOW=hidden
9424 if test $gl_cv_header_errno_h_EOVERFLOW = hidden; then
9425 if ac_fn_c_compute_int "$LINENO" "EOVERFLOW" "gl_cv_header_errno_h_EOVERFLOW" "
9426 #define _XOPEN_SOURCE_EXTENDED 1
9428 /* The following two lines are a workaround against an autoconf-2.52 bug. */
9439 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EOVERFLOW" >&5
9440 printf "%s\n" "$gl_cv_header_errno_h_EOVERFLOW" >&6; }
9441 case $gl_cv_header_errno_h_EOVERFLOW in
9443 EOVERFLOW_HIDDEN=0; EOVERFLOW_VALUE=
9446 EOVERFLOW_HIDDEN=1; EOVERFLOW_VALUE="$gl_cv_header_errno_h_EOVERFLOW"
9454 ac_fn_c_check_decl "$LINENO" "strerror_r" "ac_cv_have_decl_strerror_r" "$ac_includes_default"
9455 if test "x$ac_cv_have_decl_strerror_r" = xyes; then :
9461 cat >>confdefs.h <<_ACEOF
9462 #define HAVE_DECL_STRERROR_R $ac_have_decl
9465 for ac_func in strerror_r
9467 ac_fn_c_check_func "$LINENO" "strerror_r" "ac_cv_func_strerror_r"
9468 if test "x$ac_cv_func_strerror_r" = xyes; then :
9469 cat >>confdefs.h <<_ACEOF
9470 #define HAVE_STRERROR_R 1
9476 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether strerror_r returns char *" >&5
9477 printf %s "checking whether strerror_r returns char *... " >&6; }
9478 if ${ac_cv_func_strerror_r_char_p+:} false; then :
9479 printf %s "(cached) " >&6
9482 ac_cv_func_strerror_r_char_p=no
9483 if test $ac_cv_have_decl_strerror_r = yes; then
9484 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9485 /* end confdefs.h. */
9486 $ac_includes_default
9492 char x = *strerror_r (0, buf, sizeof buf);
9493 char *p = strerror_r (0, buf, sizeof buf);
9500 if ac_fn_c_try_compile "$LINENO"; then :
9501 ac_cv_func_strerror_r_char_p=yes
9503 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9505 # strerror_r is not declared. Choose between
9506 # systems that have relatively inaccessible declarations for the
9507 # function. BeOS and DEC UNIX 4.0 fall in this category, but the
9508 # former has a strerror_r that returns char*, while the latter
9509 # has a strerror_r that returns `int'.
9510 # This test should segfault on the DEC system.
9511 if test "$cross_compiling" = yes; then :
9514 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9515 /* end confdefs.h. */
9516 $ac_includes_default
9517 extern char *strerror_r ();
9522 char x = *strerror_r (0, buf, sizeof buf);
9523 return ! isalpha (x);
9528 if ac_fn_c_try_run "$LINENO"; then :
9529 ac_cv_func_strerror_r_char_p=yes
9531 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9532 conftest.$ac_objext conftest.beam conftest.$ac_ext
9538 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strerror_r_char_p" >&5
9539 printf "%s\n" "$ac_cv_func_strerror_r_char_p" >&6; }
9540 if test $ac_cv_func_strerror_r_char_p = yes; then
9542 printf "%s\n" "#define STRERROR_R_CHAR_P 1" >>confdefs.h
9547 XGETTEXT_EXTRA_OPTIONS=
9554 GNULIB_NONBLOCKING=0;
9572 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working fcntl.h" >&5
9573 printf %s "checking for working fcntl.h... " >&6; }
9574 if ${gl_cv_header_working_fcntl_h+:} false; then :
9575 printf %s "(cached) " >&6
9577 if test "$cross_compiling" = yes; then :
9578 gl_cv_header_working_fcntl_h=cross-compiling
9580 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9581 /* end confdefs.h. */
9582 #include <sys/types.h>
9583 #include <sys/stat.h>
9585 # include <unistd.h>
9586 #else /* on Windows with MSVC */
9588 # include <stdlib.h>
9589 # defined sleep(n) _sleep ((n) * 1000)
9596 #define O_NOFOLLOW 0
9598 static int const constants[] =
9600 O_CREAT, O_EXCL, O_NOCTTY, O_TRUNC, O_APPEND,
9601 O_NONBLOCK, O_SYNC, O_ACCMODE, O_RDONLY, O_RDWR, O_WRONLY
9608 int result = !constants;
9611 static char const sym[] = "conftest.sym";
9612 if (symlink ("/dev/null", sym) != 0)
9616 int fd = open (sym, O_WRONLY | O_NOFOLLOW | O_CREAT, 0);
9623 if (unlink (sym) != 0 || symlink (".", sym) != 0)
9627 int fd = open (sym, O_RDONLY | O_NOFOLLOW);
9638 static char const file[] = "confdefs.h";
9639 int fd = open (file, O_RDONLY | O_NOATIME);
9645 if (fstat (fd, &st0) != 0)
9651 if (read (fd, &c, 1) != 1)
9655 if (close (fd) != 0)
9660 if (stat (file, &st1) != 0)
9663 if (st0.st_atime != st1.st_atime)
9675 if ac_fn_c_try_run "$LINENO"; then :
9676 gl_cv_header_working_fcntl_h=yes
9679 4) gl_cv_header_working_fcntl_h='no (bad O_NOFOLLOW)';; #(
9680 64) gl_cv_header_working_fcntl_h='no (bad O_NOATIME)';; #(
9681 68) gl_cv_header_working_fcntl_h='no (bad O_NOATIME, O_NOFOLLOW)';; #(
9682 *) gl_cv_header_working_fcntl_h='no';;
9685 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9686 conftest.$ac_objext conftest.beam conftest.$ac_ext
9690 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_fcntl_h" >&5
9691 printf "%s\n" "$gl_cv_header_working_fcntl_h" >&6; }
9693 case $gl_cv_header_working_fcntl_h in #(
9694 *O_NOATIME* | no | cross-compiling) ac_val=0;; #(
9698 cat >>confdefs.h <<_ACEOF
9699 #define HAVE_WORKING_O_NOATIME $ac_val
9703 case $gl_cv_header_working_fcntl_h in #(
9704 *O_NOFOLLOW* | no | cross-compiling) ac_val=0;; #(
9708 cat >>confdefs.h <<_ACEOF
9709 #define HAVE_WORKING_O_NOFOLLOW $ac_val
9713 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
9714 if test "x$ac_cv_type_pid_t" = xyes; then :
9718 cat >>confdefs.h <<_ACEOF
9724 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
9725 if test "x$ac_cv_type_mode_t" = xyes; then :
9729 cat >>confdefs.h <<_ACEOF
9742 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
9743 printf %s "checking for mbstate_t... " >&6; }
9744 if ${ac_cv_type_mbstate_t+:} false; then :
9745 printf %s "(cached) " >&6
9747 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9748 /* end confdefs.h. */
9749 $ac_includes_default
9750 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
9752 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
9753 included before <wchar.h>. */
9761 mbstate_t x; return sizeof x;
9766 if ac_fn_c_try_compile "$LINENO"; then :
9767 ac_cv_type_mbstate_t=yes
9769 ac_cv_type_mbstate_t=no
9771 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9773 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
9774 printf "%s\n" "$ac_cv_type_mbstate_t" >&6; }
9775 if test $ac_cv_type_mbstate_t = yes; then
9777 printf "%s\n" "#define HAVE_MBSTATE_T 1" >>confdefs.h
9781 printf "%s\n" "#define mbstate_t int" >>confdefs.h
9808 GNULIB_FPRINTF_POSIX=0;
9824 GNULIB_OBSTACK_PRINTF=0;
9825 GNULIB_OBSTACK_PRINTF_POSIX=0;
9830 GNULIB_PRINTF_POSIX=0;
9839 GNULIB_SPRINTF_POSIX=0;
9840 GNULIB_STDIO_H_NONBLOCKING=0;
9841 GNULIB_STDIO_H_SIGPIPE=0;
9848 GNULIB_VFPRINTF_POSIX=0;
9850 GNULIB_VPRINTF_POSIX=0;
9852 GNULIB_VSPRINTF_POSIX=0;
9856 HAVE_DECL_GETDELIM=1;
9857 HAVE_DECL_GETLINE=1;
9858 HAVE_DECL_OBSTACK_PRINTF=1;
9859 HAVE_DECL_SNPRINTF=1;
9860 HAVE_DECL_VSNPRINTF=1;
9883 REPLACE_OBSTACK_PRINTF=0;
9892 REPLACE_STDIO_READ_FUNCS=0;
9893 REPLACE_STDIO_WRITE_FUNCS=0;
9895 REPLACE_VASPRINTF=0;
9899 REPLACE_VSNPRINTF=0;
9935 REPLACE_UTIMENSAT=0;
9937 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
9938 printf %s "checking whether stat file-mode macros are broken... " >&6; }
9939 if ${ac_cv_header_stat_broken+:} false; then :
9940 printf %s "(cached) " >&6
9942 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9943 /* end confdefs.h. */
9944 #include <sys/types.h>
9945 #include <sys/stat.h>
9947 #if defined S_ISBLK && defined S_IFDIR
9948 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
9951 #if defined S_ISBLK && defined S_IFCHR
9952 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
9955 #if defined S_ISLNK && defined S_IFREG
9956 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
9959 #if defined S_ISSOCK && defined S_IFREG
9960 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
9964 if ac_fn_c_try_compile "$LINENO"; then :
9965 ac_cv_header_stat_broken=no
9967 ac_cv_header_stat_broken=yes
9969 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9971 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
9972 printf "%s\n" "$ac_cv_header_stat_broken" >&6; }
9973 if test $ac_cv_header_stat_broken = yes; then
9975 printf "%s\n" "#define STAT_MACROS_BROKEN 1" >>confdefs.h
9985 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
9986 printf %s "checking for 64-bit off_t... " >&6; }
9987 if ${gl_cv_type_off_t_64+:} false; then :
9988 printf %s "(cached) " >&6
9990 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9991 /* end confdefs.h. */
9992 #include <sys/types.h>
9993 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
10003 if ac_fn_c_try_compile "$LINENO"; then :
10004 gl_cv_type_off_t_64=yes
10006 gl_cv_type_off_t_64=no
10008 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10011 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
10012 printf "%s\n" "$gl_cv_type_off_t_64" >&6; }
10013 if test $gl_cv_type_off_t_64 = no; then
10014 WINDOWS_64_BIT_OFF_T=1
10016 WINDOWS_64_BIT_OFF_T=0
10018 WINDOWS_64_BIT_ST_SIZE=1
10021 WINDOWS_64_BIT_OFF_T=0
10022 WINDOWS_64_BIT_ST_SIZE=0
10040 if test $gl_cv_have_include_next = yes; then
10041 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
10043 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
10044 printf %s "checking absolute name of <sys/stat.h>... " >&6; }
10045 if ${gl_cv_next_sys_stat_h+:} false; then :
10046 printf %s "(cached) " >&6
10049 if test $ac_cv_header_sys_stat_h = yes; then
10052 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10053 /* end confdefs.h. */
10054 #include <sys/stat.h>
10058 aix*) gl_absname_cpp="$ac_cpp -C" ;;
10059 *) gl_absname_cpp="$ac_cpp" ;;
10064 gl_dirsep_regex='[/\\]'
10067 gl_dirsep_regex='\/'
10070 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
10072 gl_header_literal_regex=`echo 'sys/stat.h' \
10073 | sed -e "$gl_make_literal_regex_sed"`
10074 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
10075 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
10080 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
10081 sed -n "$gl_absolute_header_sed"`'"'
10083 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
10088 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
10089 printf "%s\n" "$gl_cv_next_sys_stat_h" >&6; }
10091 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
10093 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
10094 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
10095 gl_next_as_first_directive='<'sys/stat.h'>'
10097 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
10098 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
10100 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
10112 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
10114 printf "%s\n" "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
10118 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
10119 #include <sys/stat.h>
10121 if test "x$ac_cv_type_nlink_t" = xyes; then :
10125 printf "%s\n" "#define nlink_t int" >>confdefs.h
10131 for gl_func in fchmodat fstat fstatat futimens lchmod lstat mkdirat mkfifo mkfifoat mknod mknodat stat utimensat; do
10132 as_gl_Symbol=`printf "%s\n" "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
10133 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
10134 printf %s "checking whether $gl_func is declared without a macro... " >&6; }
10135 if eval \${$as_gl_Symbol+:} false; then :
10136 printf %s "(cached) " >&6
10138 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10139 /* end confdefs.h. */
10140 #include <sys/stat.h>
10151 if ac_fn_c_try_compile "$LINENO"; then :
10152 eval "$as_gl_Symbol=yes"
10154 eval "$as_gl_Symbol=no"
10156 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10158 eval ac_res=\$$as_gl_Symbol
10159 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10160 printf "%s\n" "$ac_res" >&6; }
10161 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
10162 cat >>confdefs.h <<_ACEOF
10163 #define `printf "%s\n" "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
10166 eval ac_cv_have_decl_$gl_func=yes
10188 if test $gl_cv_have_include_next = yes; then
10189 gl_cv_next_getopt_h='<'getopt.h'>'
10191 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
10192 printf %s "checking absolute name of <getopt.h>... " >&6; }
10193 if ${gl_cv_next_getopt_h+:} false; then :
10194 printf %s "(cached) " >&6
10197 if test $ac_cv_header_getopt_h = yes; then
10200 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10201 /* end confdefs.h. */
10202 #include <getopt.h>
10206 aix*) gl_absname_cpp="$ac_cpp -C" ;;
10207 *) gl_absname_cpp="$ac_cpp" ;;
10212 gl_dirsep_regex='[/\\]'
10215 gl_dirsep_regex='\/'
10218 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
10220 gl_header_literal_regex=`echo 'getopt.h' \
10221 | sed -e "$gl_make_literal_regex_sed"`
10222 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
10223 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
10228 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
10229 sed -n "$gl_absolute_header_sed"`'"'
10231 gl_cv_next_getopt_h='<'getopt.h'>'
10236 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
10237 printf "%s\n" "$gl_cv_next_getopt_h" >&6; }
10239 NEXT_GETOPT_H=$gl_cv_next_getopt_h
10241 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
10242 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
10243 gl_next_as_first_directive='<'getopt.h'>'
10245 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
10246 gl_next_as_first_directive=$gl_cv_next_getopt_h
10248 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
10253 if test $ac_cv_header_getopt_h = yes; then
10262 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
10263 for ac_header in getopt.h
10265 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
10266 if test "x$ac_cv_header_getopt_h" = xyes; then :
10267 cat >>confdefs.h <<_ACEOF
10268 #define HAVE_GETOPT_H 1
10272 gl_replace_getopt=yes
10279 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
10280 for ac_func in getopt_long_only
10282 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
10283 if test "x$ac_cv_func_getopt_long_only" = xyes; then :
10284 cat >>confdefs.h <<_ACEOF
10285 #define HAVE_GETOPT_LONG_ONLY 1
10289 gl_replace_getopt=yes
10295 if test -z "$gl_replace_getopt"; then
10296 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
10297 printf %s "checking whether getopt is POSIX compatible... " >&6; }
10298 if ${gl_cv_func_getopt_posix+:} false; then :
10299 printf %s "(cached) " >&6
10302 if test $cross_compiling = no; then
10303 if test "$cross_compiling" = yes; then :
10304 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10305 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
10306 as_fn_error $? "cannot run test program while cross compiling
10307 See \`config.log' for more details" "$LINENO" 5; }
10309 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10310 /* end confdefs.h. */
10312 #include <unistd.h>
10313 #include <stdlib.h>
10314 #include <string.h>
10319 static char program[] = "program";
10320 static char a[] = "-a";
10321 static char foo[] = "foo";
10322 static char bar[] = "bar";
10323 char *argv[] = { program, a, foo, bar, NULL };
10326 c = getopt (4, argv, "ab");
10329 c = getopt (4, argv, "ab");
10332 if (!(optind == 2))
10338 if ac_fn_c_try_run "$LINENO"; then :
10339 gl_cv_func_getopt_posix=maybe
10341 gl_cv_func_getopt_posix=no
10343 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10344 conftest.$ac_objext conftest.beam conftest.$ac_ext
10347 if test $gl_cv_func_getopt_posix = maybe; then
10348 if test "$cross_compiling" = yes; then :
10349 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10350 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
10351 as_fn_error $? "cannot run test program while cross compiling
10352 See \`config.log' for more details" "$LINENO" 5; }
10354 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10355 /* end confdefs.h. */
10357 #include <unistd.h>
10358 #include <stdlib.h>
10359 #include <string.h>
10364 static char program[] = "program";
10365 static char donald[] = "donald";
10366 static char p[] = "-p";
10367 static char billy[] = "billy";
10368 static char duck[] = "duck";
10369 static char a[] = "-a";
10370 static char bar[] = "bar";
10371 char *argv[] = { program, donald, p, billy, duck, a, bar, NULL };
10374 c = getopt (7, argv, "+abp:q:");
10377 if (!(strcmp (argv[0], "program") == 0))
10379 if (!(strcmp (argv[1], "donald") == 0))
10381 if (!(strcmp (argv[2], "-p") == 0))
10383 if (!(strcmp (argv[3], "billy") == 0))
10385 if (!(strcmp (argv[4], "duck") == 0))
10387 if (!(strcmp (argv[5], "-a") == 0))
10389 if (!(strcmp (argv[6], "bar") == 0))
10391 if (!(optind == 1))
10397 if ac_fn_c_try_run "$LINENO"; then :
10398 gl_cv_func_getopt_posix=maybe
10400 gl_cv_func_getopt_posix=no
10402 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10403 conftest.$ac_objext conftest.beam conftest.$ac_ext
10407 if test $gl_cv_func_getopt_posix = maybe; then
10408 if test "$cross_compiling" = yes; then :
10409 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10410 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
10411 as_fn_error $? "cannot run test program while cross compiling
10412 See \`config.log' for more details" "$LINENO" 5; }
10414 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10415 /* end confdefs.h. */
10417 #include <unistd.h>
10418 #include <stdlib.h>
10419 #include <string.h>
10424 static char program[] = "program";
10425 static char ab[] = "-ab";
10426 char *argv[3] = { program, ab, NULL };
10427 if (getopt (2, argv, "ab:") != 'a')
10429 if (getopt (2, argv, "ab:") != '?')
10439 if ac_fn_c_try_run "$LINENO"; then :
10440 gl_cv_func_getopt_posix=yes
10442 gl_cv_func_getopt_posix=no
10444 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10445 conftest.$ac_objext conftest.beam conftest.$ac_ext
10451 darwin* | aix* | mingw*) gl_cv_func_getopt_posix="guessing no";;
10452 *) gl_cv_func_getopt_posix="guessing yes";;
10457 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
10458 printf "%s\n" "$gl_cv_func_getopt_posix" >&6; }
10459 case "$gl_cv_func_getopt_posix" in
10460 *no) gl_replace_getopt=yes ;;
10464 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
10465 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
10466 printf %s "checking for working GNU getopt function... " >&6; }
10467 if ${gl_cv_func_getopt_gnu+:} false; then :
10468 printf %s "(cached) " >&6
10470 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
10471 # optstring is necessary for programs like m4 that have POSIX-mandated
10472 # semantics for supporting options interspersed with files.
10473 # Also, since getopt_long is a GNU extension, we require optind=0.
10474 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
10475 # so take care to revert to the correct (non-)export state.
10476 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
10477 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
10478 xx) gl_had_POSIXLY_CORRECT=exported ;;
10479 x) gl_had_POSIXLY_CORRECT=yes ;;
10480 *) gl_had_POSIXLY_CORRECT= ;;
10483 export POSIXLY_CORRECT
10484 if test "$cross_compiling" = yes; then :
10485 gl_cv_func_getopt_gnu="guessing no"
10488 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10489 /* end confdefs.h. */
10490 #include <getopt.h>
10491 #include <stddef.h>
10492 #include <string.h>
10494 #include <stdlib.h>
10495 #if defined __MACH__ && defined __APPLE__
10496 /* Avoid a crash on Mac OS X. */
10497 #include <mach/mach.h>
10498 #include <mach/mach_error.h>
10499 #include <mach/thread_status.h>
10500 #include <mach/exception.h>
10501 #include <mach/task.h>
10502 #include <pthread.h>
10503 /* The exception port on which our thread listens. */
10504 static mach_port_t our_exception_port;
10505 /* The main function of the thread listening for exceptions of type
10508 mach_exception_thread (void *arg)
10510 /* Buffer for a message to be received. */
10512 mach_msg_header_t head;
10513 mach_msg_body_t msgh_body;
10516 mach_msg_return_t retval;
10517 /* Wait for a message on the exception port. */
10518 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
10519 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
10520 if (retval != MACH_MSG_SUCCESS)
10525 nocrash_init (void)
10527 mach_port_t self = mach_task_self ();
10528 /* Allocate a port on which the thread shall listen for exceptions. */
10529 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
10531 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
10532 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
10533 MACH_MSG_TYPE_MAKE_SEND)
10535 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
10537 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
10538 /* Create the thread listening on the exception port. */
10539 pthread_attr_t attr;
10541 if (pthread_attr_init (&attr) == 0
10542 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
10543 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
10544 pthread_attr_destroy (&attr);
10545 /* Replace the exception port info for these exceptions with our own.
10546 Note that we replace the exception port for the entire task, not only
10547 for a particular thread. This has the effect that when our exception
10548 port gets the message, the thread specific exception port has already
10549 been asked, and we don't need to bother about it.
10550 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
10551 task_set_exception_ports (self, mask, our_exception_port,
10552 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
10557 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
10558 /* Avoid a crash on native Windows. */
10559 #define WIN32_LEAN_AND_MEAN
10560 #include <windows.h>
10561 #include <winerror.h>
10563 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
10565 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
10567 case EXCEPTION_ACCESS_VIOLATION:
10568 case EXCEPTION_IN_PAGE_ERROR:
10569 case EXCEPTION_STACK_OVERFLOW:
10570 case EXCEPTION_GUARD_PAGE:
10571 case EXCEPTION_PRIV_INSTRUCTION:
10572 case EXCEPTION_ILLEGAL_INSTRUCTION:
10573 case EXCEPTION_DATATYPE_MISALIGNMENT:
10574 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
10575 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
10578 return EXCEPTION_CONTINUE_SEARCH;
10581 nocrash_init (void)
10583 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
10586 /* Avoid a crash on POSIX systems. */
10587 #include <signal.h>
10588 /* A POSIX signal handler. */
10590 exception_handler (int sig)
10595 nocrash_init (void)
10598 signal (SIGSEGV, exception_handler);
10601 signal (SIGBUS, exception_handler);
10615 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
10616 and fails on Mac OS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
10617 OSF/1 5.1, Solaris 10. */
10619 static char conftest[] = "conftest";
10620 static char plus[] = "-+";
10621 char *argv[3] = { conftest, plus, NULL };
10623 if (getopt (2, argv, "+a") != '?')
10626 /* This code succeeds on glibc 2.8, mingw,
10627 and fails on Mac OS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
10628 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
10630 static char program[] = "program";
10631 static char p[] = "-p";
10632 static char foo[] = "foo";
10633 static char bar[] = "bar";
10634 char *argv[] = { program, p, foo, bar, NULL };
10637 if (getopt (4, argv, "p::") != 'p')
10639 else if (optarg != NULL)
10641 else if (getopt (4, argv, "p::") != -1)
10643 else if (optind != 2)
10646 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
10648 static char program[] = "program";
10649 static char foo[] = "foo";
10650 static char p[] = "-p";
10651 char *argv[] = { program, foo, p, NULL };
10653 if (getopt (3, argv, "-p") != 1)
10655 else if (getopt (3, argv, "-p") != 'p')
10658 /* This code fails on glibc 2.11. */
10660 static char program[] = "program";
10661 static char b[] = "-b";
10662 static char a[] = "-a";
10663 char *argv[] = { program, b, a, NULL };
10664 optind = opterr = 0;
10665 if (getopt (3, argv, "+:a:b") != 'b')
10667 else if (getopt (3, argv, "+:a:b") != ':')
10670 /* This code dumps core on glibc 2.14. */
10672 static char program[] = "program";
10673 static char w[] = "-W";
10674 static char dummy[] = "dummy";
10675 char *argv[] = { program, w, dummy, NULL };
10676 optind = opterr = 1;
10677 if (getopt (3, argv, "W;") != 'W')
10686 if ac_fn_c_try_run "$LINENO"; then :
10687 gl_cv_func_getopt_gnu=yes
10689 gl_cv_func_getopt_gnu=no
10691 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10692 conftest.$ac_objext conftest.beam conftest.$ac_ext
10695 case $gl_had_POSIXLY_CORRECT in
10697 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
10698 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
10702 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
10703 printf "%s\n" "$gl_cv_func_getopt_gnu" >&6; }
10704 if test "$gl_cv_func_getopt_gnu" != yes; then
10705 gl_replace_getopt=yes
10707 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt_long function" >&5
10708 printf %s "checking for working GNU getopt_long function... " >&6; }
10709 if ${gl_cv_func_getopt_long_gnu+:} false; then :
10710 printf %s "(cached) " >&6
10712 if test "$cross_compiling" = yes; then :
10714 openbsd*) gl_cv_func_getopt_long_gnu="guessing no";;
10715 *) gl_cv_func_getopt_long_gnu="guessing yes";;
10719 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10720 /* end confdefs.h. */
10721 #include <getopt.h>
10722 #include <stddef.h>
10723 #include <string.h>
10728 static const struct option long_options[] =
10730 { "xtremely-",no_argument, NULL, 1003 },
10731 { "xtra", no_argument, NULL, 1001 },
10732 { "xtreme", no_argument, NULL, 1002 },
10733 { "xtremely", no_argument, NULL, 1003 },
10734 { NULL, 0, NULL, 0 }
10736 /* This code fails on OpenBSD 5.0. */
10738 static char program[] = "program";
10739 static char xtremel[] = "--xtremel";
10740 char *argv[] = { program, xtremel, NULL };
10742 optind = 1; opterr = 0;
10743 if (getopt_long (2, argv, "", long_options, &option_index) != 1003)
10752 if ac_fn_c_try_run "$LINENO"; then :
10753 gl_cv_func_getopt_long_gnu=yes
10755 gl_cv_func_getopt_long_gnu=no
10757 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10758 conftest.$ac_objext conftest.beam conftest.$ac_ext
10763 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_long_gnu" >&5
10764 printf "%s\n" "$gl_cv_func_getopt_long_gnu" >&6; }
10765 case "$gl_cv_func_getopt_long_gnu" in
10767 *) gl_replace_getopt=yes ;;
10778 if test -n "$gl_replace_getopt"; then
10782 if test $REPLACE_GETOPT = 1; then
10786 printf "%s\n" "#define __GETOPT_PREFIX rpl_" >>confdefs.h
10792 ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
10793 if test "x$ac_cv_have_decl_getenv" = xyes; then :
10799 cat >>confdefs.h <<_ACEOF
10800 #define HAVE_DECL_GETENV $ac_have_decl
10808 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
10809 printf %s "checking for C/C++ restrict keyword... " >&6; }
10810 if ${ac_cv_c_restrict+:} false; then :
10811 printf %s "(cached) " >&6
10813 ac_cv_c_restrict=no
10814 # The order here caters to the fact that C++ does not require restrict.
10815 for ac_kw in __restrict __restrict__ _Restrict restrict; do
10816 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10817 /* end confdefs.h. */
10818 typedef int * int_ptr;
10819 int foo (int_ptr $ac_kw ip) {
10826 int * $ac_kw t = s;
10833 if ac_fn_c_try_compile "$LINENO"; then :
10834 ac_cv_c_restrict=$ac_kw
10836 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10837 test "$ac_cv_c_restrict" != no && break
10841 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
10842 printf "%s\n" "$ac_cv_c_restrict" >&6; }
10844 case $ac_cv_c_restrict in
10846 no) printf "%s\n" "#define restrict /**/" >>confdefs.h
10848 *) cat >>confdefs.h <<_ACEOF
10849 #define restrict $ac_cv_c_restrict
10855 GNULIB_GETTIMEOFDAY=0;
10856 HAVE_GETTIMEOFDAY=1;
10857 HAVE_STRUCT_TIMEVAL=1;
10859 REPLACE_GETTIMEOFDAY=0;
10860 REPLACE_STRUCT_TIMEVAL=0;
10877 if test $gl_cv_have_include_next = yes; then
10878 gl_cv_next_sys_time_h='<'sys/time.h'>'
10880 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
10881 printf %s "checking absolute name of <sys/time.h>... " >&6; }
10882 if ${gl_cv_next_sys_time_h+:} false; then :
10883 printf %s "(cached) " >&6
10886 if test $ac_cv_header_sys_time_h = yes; then
10889 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10890 /* end confdefs.h. */
10891 #include <sys/time.h>
10895 aix*) gl_absname_cpp="$ac_cpp -C" ;;
10896 *) gl_absname_cpp="$ac_cpp" ;;
10901 gl_dirsep_regex='[/\\]'
10904 gl_dirsep_regex='\/'
10907 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
10909 gl_header_literal_regex=`echo 'sys/time.h' \
10910 | sed -e "$gl_make_literal_regex_sed"`
10911 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
10912 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
10917 gl_cv_next_sys_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
10918 sed -n "$gl_absolute_header_sed"`'"'
10920 gl_cv_next_sys_time_h='<'sys/time.h'>'
10925 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
10926 printf "%s\n" "$gl_cv_next_sys_time_h" >&6; }
10928 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
10930 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
10931 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
10932 gl_next_as_first_directive='<'sys/time.h'>'
10934 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
10935 gl_next_as_first_directive=$gl_cv_next_sys_time_h
10937 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
10943 if test $ac_cv_header_sys_time_h != yes; then
10951 if test $ac_cv_header_sys_socket_h != yes; then
10952 for ac_header in winsock2.h
10954 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
10955 if test "x$ac_cv_header_winsock2_h" = xyes; then :
10956 cat >>confdefs.h <<_ACEOF
10957 #define HAVE_WINSOCK2_H 1
10965 if test "$ac_cv_header_winsock2_h" = yes; then
10967 UNISTD_H_HAVE_WINSOCK2_H=1
10968 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
10974 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
10975 printf %s "checking for struct timeval... " >&6; }
10976 if ${gl_cv_sys_struct_timeval+:} false; then :
10977 printf %s "(cached) " >&6
10979 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10980 /* end confdefs.h. */
10981 #if HAVE_SYS_TIME_H
10982 #include <sys/time.h>
10985 #if HAVE_WINSOCK2_H
10986 # include <winsock2.h>
10992 static struct timeval x; x.tv_sec = x.tv_usec;
10997 if ac_fn_c_try_compile "$LINENO"; then :
10998 gl_cv_sys_struct_timeval=yes
11000 gl_cv_sys_struct_timeval=no
11002 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11005 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
11006 printf "%s\n" "$gl_cv_sys_struct_timeval" >&6; }
11007 if test $gl_cv_sys_struct_timeval != yes; then
11008 HAVE_STRUCT_TIMEVAL=0
11010 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
11011 printf %s "checking for wide-enough struct timeval.tv_sec member... " >&6; }
11012 if ${gl_cv_sys_struct_timeval_tv_sec+:} false; then :
11013 printf %s "(cached) " >&6
11015 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11016 /* end confdefs.h. */
11017 #if HAVE_SYS_TIME_H
11018 #include <sys/time.h>
11021 #if HAVE_WINSOCK2_H
11022 # include <winsock2.h>
11028 static struct timeval x;
11029 typedef int verify_tv_sec_type[
11030 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
11037 if ac_fn_c_try_compile "$LINENO"; then :
11038 gl_cv_sys_struct_timeval_tv_sec=yes
11040 gl_cv_sys_struct_timeval_tv_sec=no
11042 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11045 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
11046 printf "%s\n" "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
11047 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
11048 REPLACE_STRUCT_TIMEVAL=1
11053 for gl_func in gettimeofday; do
11054 as_gl_Symbol=`printf "%s\n" "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
11055 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
11056 printf %s "checking whether $gl_func is declared without a macro... " >&6; }
11057 if eval \${$as_gl_Symbol+:} false; then :
11058 printf %s "(cached) " >&6
11060 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11061 /* end confdefs.h. */
11063 #if HAVE_SYS_TIME_H
11064 # include <sys/time.h>
11077 if ac_fn_c_try_compile "$LINENO"; then :
11078 eval "$as_gl_Symbol=yes"
11080 eval "$as_gl_Symbol=no"
11082 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11084 eval ac_res=\$$as_gl_Symbol
11085 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
11086 printf "%s\n" "$ac_res" >&6; }
11087 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
11088 cat >>confdefs.h <<_ACEOF
11089 #define `printf "%s\n" "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
11092 eval ac_cv_have_decl_$gl_func=yes
11113 acl_save_prefix="$prefix"
11114 prefix="$acl_final_prefix"
11115 acl_save_exec_prefix="$exec_prefix"
11116 exec_prefix="$acl_final_exec_prefix"
11118 eval additional_includedir=\"$includedir\"
11119 eval additional_libdir=\"$libdir\"
11121 exec_prefix="$acl_save_exec_prefix"
11122 prefix="$acl_save_prefix"
11125 # Check whether --with-libiconv-prefix was given.
11126 if test "${with_libiconv_prefix+set}" = set; then :
11127 withval=$with_libiconv_prefix;
11128 if test "X$withval" = "Xno"; then
11131 if test "X$withval" = "X"; then
11133 acl_save_prefix="$prefix"
11134 prefix="$acl_final_prefix"
11135 acl_save_exec_prefix="$exec_prefix"
11136 exec_prefix="$acl_final_exec_prefix"
11138 eval additional_includedir=\"$includedir\"
11139 eval additional_libdir=\"$libdir\"
11141 exec_prefix="$acl_save_exec_prefix"
11142 prefix="$acl_save_prefix"
11145 additional_includedir="$withval/include"
11146 additional_libdir="$withval/$acl_libdirstem"
11147 if test "$acl_libdirstem2" != "$acl_libdirstem" \
11148 && ! test -d "$withval/$acl_libdirstem"; then
11149 additional_libdir="$withval/$acl_libdirstem2"
11163 names_already_handled=
11164 names_next_round='iconv '
11165 while test -n "$names_next_round"; do
11166 names_this_round="$names_next_round"
11168 for name in $names_this_round; do
11170 for n in $names_already_handled; do
11171 if test "$n" = "$name"; then
11172 already_handled=yes
11176 if test -z "$already_handled"; then
11177 names_already_handled="$names_already_handled $name"
11178 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./+-|ABCDEFGHIJKLMNOPQRSTUVWXYZ____|'`
11179 eval value=\"\$HAVE_LIB$uppername\"
11180 if test -n "$value"; then
11181 if test "$value" = yes; then
11182 eval value=\"\$LIB$uppername\"
11183 test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
11184 eval value=\"\$LTLIB$uppername\"
11185 test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
11194 eval libname=\"$acl_libname_spec\" # typically: libname=lib$name
11195 if test -n "$acl_shlibext"; then
11196 shrext=".$acl_shlibext" # typically: shrext=.so
11200 if test $use_additional = yes; then
11201 dir="$additional_libdir"
11202 if test -n "$acl_shlibext"; then
11203 if test -f "$dir/$libname$shrext"; then
11205 found_so="$dir/$libname$shrext"
11207 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
11208 ver=`(cd "$dir" && \
11209 for f in "$libname$shrext".*; do echo "$f"; done \
11210 | sed -e "s,^$libname$shrext\\\\.,," \
11211 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
11212 | sed 1q ) 2>/dev/null`
11213 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
11215 found_so="$dir/$libname$shrext.$ver"
11218 eval library_names=\"$acl_library_names_spec\"
11219 for f in $library_names; do
11220 if test -f "$dir/$f"; then
11229 if test "X$found_dir" = "X"; then
11230 if test -f "$dir/$libname.$acl_libext"; then
11232 found_a="$dir/$libname.$acl_libext"
11235 if test "X$found_dir" != "X"; then
11236 if test -f "$dir/$libname.la"; then
11237 found_la="$dir/$libname.la"
11241 if test "X$found_dir" = "X"; then
11242 for x in $LDFLAGS $LTLIBICONV; do
11244 acl_save_prefix="$prefix"
11245 prefix="$acl_final_prefix"
11246 acl_save_exec_prefix="$exec_prefix"
11247 exec_prefix="$acl_final_exec_prefix"
11249 exec_prefix="$acl_save_exec_prefix"
11250 prefix="$acl_save_prefix"
11254 dir=`echo "X$x" | sed -e 's/^X-L//'`
11255 if test -n "$acl_shlibext"; then
11256 if test -f "$dir/$libname$shrext"; then
11258 found_so="$dir/$libname$shrext"
11260 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
11261 ver=`(cd "$dir" && \
11262 for f in "$libname$shrext".*; do echo "$f"; done \
11263 | sed -e "s,^$libname$shrext\\\\.,," \
11264 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
11265 | sed 1q ) 2>/dev/null`
11266 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
11268 found_so="$dir/$libname$shrext.$ver"
11271 eval library_names=\"$acl_library_names_spec\"
11272 for f in $library_names; do
11273 if test -f "$dir/$f"; then
11282 if test "X$found_dir" = "X"; then
11283 if test -f "$dir/$libname.$acl_libext"; then
11285 found_a="$dir/$libname.$acl_libext"
11288 if test "X$found_dir" != "X"; then
11289 if test -f "$dir/$libname.la"; then
11290 found_la="$dir/$libname.la"
11295 if test "X$found_dir" != "X"; then
11300 if test "X$found_dir" != "X"; then
11301 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
11302 if test "X$found_so" != "X"; then
11303 if test "$enable_rpath" = no \
11304 || test "X$found_dir" = "X/usr/$acl_libdirstem" \
11305 || test "X$found_dir" = "X/usr/$acl_libdirstem2"; then
11306 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11309 for x in $ltrpathdirs; do
11310 if test "X$x" = "X$found_dir"; then
11315 if test -z "$haveit"; then
11316 ltrpathdirs="$ltrpathdirs $found_dir"
11318 if test "$acl_hardcode_direct" = yes; then
11319 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11321 if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
11322 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11324 for x in $rpathdirs; do
11325 if test "X$x" = "X$found_dir"; then
11330 if test -z "$haveit"; then
11331 rpathdirs="$rpathdirs $found_dir"
11335 for x in $LDFLAGS $LIBICONV; do
11337 acl_save_prefix="$prefix"
11338 prefix="$acl_final_prefix"
11339 acl_save_exec_prefix="$exec_prefix"
11340 exec_prefix="$acl_final_exec_prefix"
11342 exec_prefix="$acl_save_exec_prefix"
11343 prefix="$acl_save_prefix"
11345 if test "X$x" = "X-L$found_dir"; then
11350 if test -z "$haveit"; then
11351 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
11353 if test "$acl_hardcode_minus_L" != no; then
11354 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11356 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
11362 if test "X$found_a" != "X"; then
11363 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
11365 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
11368 additional_includedir=
11369 case "$found_dir" in
11370 */$acl_libdirstem | */$acl_libdirstem/)
11371 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
11372 if test "$name" = 'iconv'; then
11373 LIBICONV_PREFIX="$basedir"
11375 additional_includedir="$basedir/include"
11377 */$acl_libdirstem2 | */$acl_libdirstem2/)
11378 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
11379 if test "$name" = 'iconv'; then
11380 LIBICONV_PREFIX="$basedir"
11382 additional_includedir="$basedir/include"
11385 if test "X$additional_includedir" != "X"; then
11386 if test "X$additional_includedir" != "X/usr/include"; then
11388 if test "X$additional_includedir" = "X/usr/local/include"; then
11389 if test -n "$GCC"; then
11391 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
11395 if test -z "$haveit"; then
11396 for x in $CPPFLAGS $INCICONV; do
11398 acl_save_prefix="$prefix"
11399 prefix="$acl_final_prefix"
11400 acl_save_exec_prefix="$exec_prefix"
11401 exec_prefix="$acl_final_exec_prefix"
11403 exec_prefix="$acl_save_exec_prefix"
11404 prefix="$acl_save_prefix"
11406 if test "X$x" = "X-I$additional_includedir"; then
11411 if test -z "$haveit"; then
11412 if test -d "$additional_includedir"; then
11413 INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
11419 if test -n "$found_la"; then
11420 save_libdir="$libdir"
11421 case "$found_la" in
11422 */* | *\\*) . "$found_la" ;;
11423 *) . "./$found_la" ;;
11425 libdir="$save_libdir"
11426 for dep in $dependency_libs; do
11429 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
11430 if test "X$additional_libdir" != "X/usr/$acl_libdirstem" \
11431 && test "X$additional_libdir" != "X/usr/$acl_libdirstem2"; then
11433 if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem" \
11434 || test "X$additional_libdir" = "X/usr/local/$acl_libdirstem2"; then
11435 if test -n "$GCC"; then
11437 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
11441 if test -z "$haveit"; then
11443 for x in $LDFLAGS $LIBICONV; do
11445 acl_save_prefix="$prefix"
11446 prefix="$acl_final_prefix"
11447 acl_save_exec_prefix="$exec_prefix"
11448 exec_prefix="$acl_final_exec_prefix"
11450 exec_prefix="$acl_save_exec_prefix"
11451 prefix="$acl_save_prefix"
11453 if test "X$x" = "X-L$additional_libdir"; then
11458 if test -z "$haveit"; then
11459 if test -d "$additional_libdir"; then
11460 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir"
11464 for x in $LDFLAGS $LTLIBICONV; do
11466 acl_save_prefix="$prefix"
11467 prefix="$acl_final_prefix"
11468 acl_save_exec_prefix="$exec_prefix"
11469 exec_prefix="$acl_final_exec_prefix"
11471 exec_prefix="$acl_save_exec_prefix"
11472 prefix="$acl_save_prefix"
11474 if test "X$x" = "X-L$additional_libdir"; then
11479 if test -z "$haveit"; then
11480 if test -d "$additional_libdir"; then
11481 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir"
11488 dir=`echo "X$dep" | sed -e 's/^X-R//'`
11489 if test "$enable_rpath" != no; then
11491 for x in $rpathdirs; do
11492 if test "X$x" = "X$dir"; then
11497 if test -z "$haveit"; then
11498 rpathdirs="$rpathdirs $dir"
11501 for x in $ltrpathdirs; do
11502 if test "X$x" = "X$dir"; then
11507 if test -z "$haveit"; then
11508 ltrpathdirs="$ltrpathdirs $dir"
11513 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
11516 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
11519 LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
11520 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
11526 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
11527 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
11533 if test "X$rpathdirs" != "X"; then
11534 if test -n "$acl_hardcode_libdir_separator"; then
11536 for found_dir in $rpathdirs; do
11537 alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir"
11539 acl_save_libdir="$libdir"
11541 eval flag=\"$acl_hardcode_libdir_flag_spec\"
11542 libdir="$acl_save_libdir"
11543 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
11545 for found_dir in $rpathdirs; do
11546 acl_save_libdir="$libdir"
11547 libdir="$found_dir"
11548 eval flag=\"$acl_hardcode_libdir_flag_spec\"
11549 libdir="$acl_save_libdir"
11550 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
11554 if test "X$ltrpathdirs" != "X"; then
11555 for found_dir in $ltrpathdirs; do
11556 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
11570 REPLACE_ICONV_OPEN=0;
11571 REPLACE_ICONV_UTF=0;
11573 if test -n "$ICONV_H"; then
11574 GL_GENERATE_ICONV_H_TRUE=
11575 GL_GENERATE_ICONV_H_FALSE='#'
11577 GL_GENERATE_ICONV_H_TRUE='#'
11578 GL_GENERATE_ICONV_H_FALSE=
11587 am_save_CPPFLAGS="$CPPFLAGS"
11589 for element in $INCICONV; do
11591 for x in $CPPFLAGS; do
11593 acl_save_prefix="$prefix"
11594 prefix="$acl_final_prefix"
11595 acl_save_exec_prefix="$exec_prefix"
11596 exec_prefix="$acl_final_exec_prefix"
11598 exec_prefix="$acl_save_exec_prefix"
11599 prefix="$acl_save_prefix"
11601 if test "X$x" = "X$element"; then
11606 if test -z "$haveit"; then
11607 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
11612 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
11613 printf %s "checking for iconv... " >&6; }
11614 if ${am_cv_func_iconv+:} false; then :
11615 printf %s "(cached) " >&6
11618 am_cv_func_iconv="no, consider installing GNU libiconv"
11620 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11621 /* end confdefs.h. */
11623 #include <stdlib.h>
11629 iconv_t cd = iconv_open("","");
11630 iconv(cd,NULL,NULL,NULL,NULL);
11636 if ac_fn_c_try_link "$LINENO"; then :
11637 am_cv_func_iconv=yes
11639 rm -f core conftest.err conftest.$ac_objext \
11640 conftest$ac_exeext conftest.$ac_ext
11641 if test "$am_cv_func_iconv" != yes; then
11642 am_save_LIBS="$LIBS"
11643 LIBS="$LIBS $LIBICONV"
11644 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11645 /* end confdefs.h. */
11647 #include <stdlib.h>
11653 iconv_t cd = iconv_open("","");
11654 iconv(cd,NULL,NULL,NULL,NULL);
11660 if ac_fn_c_try_link "$LINENO"; then :
11661 am_cv_lib_iconv=yes
11662 am_cv_func_iconv=yes
11664 rm -f core conftest.err conftest.$ac_objext \
11665 conftest$ac_exeext conftest.$ac_ext
11666 LIBS="$am_save_LIBS"
11670 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
11671 printf "%s\n" "$am_cv_func_iconv" >&6; }
11672 if test "$am_cv_func_iconv" = yes; then
11673 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
11674 printf %s "checking for working iconv... " >&6; }
11675 if ${am_cv_func_iconv_works+:} false; then :
11676 printf %s "(cached) " >&6
11679 am_save_LIBS="$LIBS"
11680 if test $am_cv_lib_iconv = yes; then
11681 LIBS="$LIBS $LIBICONV"
11683 if test "$cross_compiling" = yes; then :
11686 aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
11687 *) am_cv_func_iconv_works="guessing yes" ;;
11691 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11692 /* end confdefs.h. */
11695 #include <string.h>
11699 /* Test against AIX 5.1 bug: Failures are not distinguishable from successful
11702 iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
11703 if (cd_utf8_to_88591 != (iconv_t)(-1))
11705 static const char input[] = "\342\202\254"; /* EURO SIGN */
11707 const char *inptr = input;
11708 size_t inbytesleft = strlen (input);
11709 char *outptr = buf;
11710 size_t outbytesleft = sizeof (buf);
11711 size_t res = iconv (cd_utf8_to_88591,
11712 (char **) &inptr, &inbytesleft,
11713 &outptr, &outbytesleft);
11716 iconv_close (cd_utf8_to_88591);
11719 /* Test against Solaris 10 bug: Failures are not distinguishable from
11720 successful returns. */
11722 iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
11723 if (cd_ascii_to_88591 != (iconv_t)(-1))
11725 static const char input[] = "\263";
11727 const char *inptr = input;
11728 size_t inbytesleft = strlen (input);
11729 char *outptr = buf;
11730 size_t outbytesleft = sizeof (buf);
11731 size_t res = iconv (cd_ascii_to_88591,
11732 (char **) &inptr, &inbytesleft,
11733 &outptr, &outbytesleft);
11736 iconv_close (cd_ascii_to_88591);
11739 /* Test against AIX 6.1..7.1 bug: Buffer overrun. */
11741 iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1");
11742 if (cd_88591_to_utf8 != (iconv_t)(-1))
11744 static const char input[] = "\304";
11745 static char buf[2] = { (char)0xDE, (char)0xAD };
11746 const char *inptr = input;
11747 size_t inbytesleft = 1;
11748 char *outptr = buf;
11749 size_t outbytesleft = 1;
11750 size_t res = iconv (cd_88591_to_utf8,
11751 (char **) &inptr, &inbytesleft,
11752 &outptr, &outbytesleft);
11753 if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD)
11755 iconv_close (cd_88591_to_utf8);
11758 #if 0 /* This bug could be worked around by the caller. */
11759 /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */
11761 iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
11762 if (cd_88591_to_utf8 != (iconv_t)(-1))
11764 static const char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
11766 const char *inptr = input;
11767 size_t inbytesleft = strlen (input);
11768 char *outptr = buf;
11769 size_t outbytesleft = sizeof (buf);
11770 size_t res = iconv (cd_88591_to_utf8,
11771 (char **) &inptr, &inbytesleft,
11772 &outptr, &outbytesleft);
11775 iconv_close (cd_88591_to_utf8);
11779 /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
11781 if (/* Try standardized names. */
11782 iconv_open ("UTF-8", "EUC-JP") == (iconv_t)(-1)
11783 /* Try IRIX, OSF/1 names. */
11784 && iconv_open ("UTF-8", "eucJP") == (iconv_t)(-1)
11785 /* Try AIX names. */
11786 && iconv_open ("UTF-8", "IBM-eucJP") == (iconv_t)(-1)
11787 /* Try HP-UX names. */
11788 && iconv_open ("utf8", "eucJP") == (iconv_t)(-1))
11793 if ac_fn_c_try_run "$LINENO"; then :
11794 am_cv_func_iconv_works=yes
11796 am_cv_func_iconv_works=no
11798 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11799 conftest.$ac_objext conftest.beam conftest.$ac_ext
11802 LIBS="$am_save_LIBS"
11805 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5
11806 printf "%s\n" "$am_cv_func_iconv_works" >&6; }
11807 case "$am_cv_func_iconv_works" in
11808 *no) am_func_iconv=no am_cv_lib_iconv=no ;;
11809 *) am_func_iconv=yes ;;
11812 am_func_iconv=no am_cv_lib_iconv=no
11814 if test "$am_func_iconv" = yes; then
11816 printf "%s\n" "#define HAVE_ICONV 1" >>confdefs.h
11819 if test "$am_cv_lib_iconv" = yes; then
11820 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
11821 printf %s "checking how to link with libiconv... " >&6; }
11822 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
11823 printf "%s\n" "$LIBICONV" >&6; }
11825 CPPFLAGS="$am_save_CPPFLAGS"
11832 if test "$am_cv_func_iconv" = yes; then
11833 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for iconv declaration" >&5
11834 printf %s "checking for iconv declaration... " >&6; }
11835 if ${am_cv_proto_iconv+:} false; then :
11836 printf %s "(cached) " >&6
11839 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11840 /* end confdefs.h. */
11842 #include <stdlib.h>
11848 #if defined(__STDC__) || defined(_MSC_VER) || defined(__cplusplus)
11849 size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
11862 if ac_fn_c_try_compile "$LINENO"; then :
11863 am_cv_proto_iconv_arg1=""
11865 am_cv_proto_iconv_arg1="const"
11867 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11868 am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);"
11871 am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
11872 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result:
11873 $am_cv_proto_iconv" >&5
11875 $am_cv_proto_iconv" >&6; }
11877 cat >>confdefs.h <<_ACEOF
11878 #define ICONV_CONST $am_cv_proto_iconv_arg1
11882 if test -n "$am_cv_proto_iconv_arg1"; then
11883 ICONV_CONST="const"
11890 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
11891 printf %s "checking for inline... " >&6; }
11892 if ${ac_cv_c_inline+:} false; then :
11893 printf %s "(cached) " >&6
11896 for ac_kw in inline __inline__ __inline; do
11897 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11898 /* end confdefs.h. */
11899 #ifndef __cplusplus
11901 static $ac_kw foo_t static_foo () {return 0; }
11902 $ac_kw foo_t foo () {return 0; }
11906 if ac_fn_c_try_compile "$LINENO"; then :
11907 ac_cv_c_inline=$ac_kw
11909 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11910 test "$ac_cv_c_inline" != no && break
11914 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
11915 printf "%s\n" "$ac_cv_c_inline" >&6; }
11917 case $ac_cv_c_inline in
11920 case $ac_cv_c_inline in
11922 *) ac_val=$ac_cv_c_inline;;
11924 cat >>confdefs.h <<_ACEOF
11925 #ifndef __cplusplus
11926 #define inline $ac_val
11932 ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default"
11933 if test "x$ac_cv_type_off_t" = xyes; then :
11937 cat >>confdefs.h <<_ACEOF
11938 #define off_t long int
11944 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
11945 printf %s "checking for unsigned long long int... " >&6; }
11946 if ${ac_cv_type_unsigned_long_long_int+:} false; then :
11947 printf %s "(cached) " >&6
11949 ac_cv_type_unsigned_long_long_int=yes
11950 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
11951 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11952 /* end confdefs.h. */
11954 /* For now, do not test the preprocessor; as of 2007 there are too many
11955 implementations with broken preprocessors. Perhaps this can
11956 be revisited in 2012. In the meantime, code should not expect
11957 #if to work with literals wider than 32 bits. */
11958 /* Test literals. */
11959 long long int ll = 9223372036854775807ll;
11960 long long int nll = -9223372036854775807LL;
11961 unsigned long long int ull = 18446744073709551615ULL;
11962 /* Test constant expressions. */
11963 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
11965 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
11971 /* Test availability of runtime routines for shift and division. */
11972 long long int llmax = 9223372036854775807ll;
11973 unsigned long long int ullmax = 18446744073709551615ull;
11974 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
11975 | (llmax / ll) | (llmax % ll)
11976 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
11977 | (ullmax / ull) | (ullmax % ull));
11983 if ac_fn_c_try_link "$LINENO"; then :
11986 ac_cv_type_unsigned_long_long_int=no
11988 rm -f core conftest.err conftest.$ac_objext \
11989 conftest$ac_exeext conftest.$ac_ext
11992 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
11993 printf "%s\n" "$ac_cv_type_unsigned_long_long_int" >&6; }
11994 if test $ac_cv_type_unsigned_long_long_int = yes; then
11996 printf "%s\n" "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
12002 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
12003 printf %s "checking for long long int... " >&6; }
12004 if ${ac_cv_type_long_long_int+:} false; then :
12005 printf %s "(cached) " >&6
12007 ac_cv_type_long_long_int=yes
12008 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
12009 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
12010 if test $ac_cv_type_long_long_int = yes; then
12011 if test "$cross_compiling" = yes; then :
12014 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12015 /* end confdefs.h. */
12016 #include <limits.h>
12019 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
12020 # define LLONG_MAX (HALF - 1 + HALF)
12025 long long int n = 1;
12029 long long int m = n << i;
12032 if (LLONG_MAX / 2 < m)
12040 if ac_fn_c_try_run "$LINENO"; then :
12043 ac_cv_type_long_long_int=no
12045 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12046 conftest.$ac_objext conftest.beam conftest.$ac_ext
12052 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
12053 printf "%s\n" "$ac_cv_type_long_long_int" >&6; }
12054 if test $ac_cv_type_long_long_int = yes; then
12056 printf "%s\n" "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
12065 gl_cv_c_multiarch=no
12066 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12067 /* end confdefs.h. */
12068 #ifndef __APPLE_CC__
12069 not a universal capable compiler
12074 if ac_fn_c_try_compile "$LINENO"; then :
12078 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
12079 if test -n "$prev"; then
12081 i?86 | x86_64 | ppc | ppc64)
12082 if test -z "$arch" || test "$arch" = "$word"; then
12085 gl_cv_c_multiarch=yes
12091 if test "x$word" = "x-arch"; then
12098 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12099 if test $gl_cv_c_multiarch = yes; then
12100 APPLE_UNIVERSAL_BUILD=1
12102 APPLE_UNIVERSAL_BUILD=0
12109 if test $ac_cv_type_long_long_int = yes; then
12110 HAVE_LONG_LONG_INT=1
12112 HAVE_LONG_LONG_INT=0
12116 if test $ac_cv_type_unsigned_long_long_int = yes; then
12117 HAVE_UNSIGNED_LONG_LONG_INT=1
12119 HAVE_UNSIGNED_LONG_LONG_INT=0
12124 if test $ac_cv_header_wchar_h = yes; then
12131 if test $ac_cv_header_inttypes_h = yes; then
12138 if test $ac_cv_header_sys_types_h = yes; then
12154 if test $gl_cv_have_include_next = yes; then
12155 gl_cv_next_stdint_h='<'stdint.h'>'
12157 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
12158 printf %s "checking absolute name of <stdint.h>... " >&6; }
12159 if ${gl_cv_next_stdint_h+:} false; then :
12160 printf %s "(cached) " >&6
12163 if test $ac_cv_header_stdint_h = yes; then
12166 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12167 /* end confdefs.h. */
12168 #include <stdint.h>
12172 aix*) gl_absname_cpp="$ac_cpp -C" ;;
12173 *) gl_absname_cpp="$ac_cpp" ;;
12178 gl_dirsep_regex='[/\\]'
12181 gl_dirsep_regex='\/'
12184 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
12186 gl_header_literal_regex=`echo 'stdint.h' \
12187 | sed -e "$gl_make_literal_regex_sed"`
12188 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
12189 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
12194 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
12195 sed -n "$gl_absolute_header_sed"`'"'
12197 gl_cv_next_stdint_h='<'stdint.h'>'
12202 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
12203 printf "%s\n" "$gl_cv_next_stdint_h" >&6; }
12205 NEXT_STDINT_H=$gl_cv_next_stdint_h
12207 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
12208 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
12209 gl_next_as_first_directive='<'stdint.h'>'
12211 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
12212 gl_next_as_first_directive=$gl_cv_next_stdint_h
12214 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
12219 if test $ac_cv_header_stdint_h = yes; then
12226 if test $ac_cv_header_stdint_h = yes; then
12227 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
12228 printf %s "checking whether stdint.h conforms to C99... " >&6; }
12229 if ${gl_cv_header_working_stdint_h+:} false; then :
12230 printf %s "(cached) " >&6
12232 gl_cv_header_working_stdint_h=no
12233 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12234 /* end confdefs.h. */
12237 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
12238 #include <stdint.h>
12239 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
12240 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
12241 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
12245 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
12246 included before <wchar.h>. */
12247 #include <stddef.h>
12248 #include <signal.h>
12250 # include <stdio.h>
12252 # include <wchar.h>
12257 int8_t a1 = INT8_MAX;
12258 int8_t a1min = INT8_MIN;
12261 int16_t a2 = INT16_MAX;
12262 int16_t a2min = INT16_MIN;
12265 int32_t a3 = INT32_MAX;
12266 int32_t a3min = INT32_MIN;
12269 int64_t a4 = INT64_MAX;
12270 int64_t a4min = INT64_MIN;
12273 uint8_t b1 = UINT8_MAX;
12275 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
12278 uint16_t b2 = UINT16_MAX;
12281 uint32_t b3 = UINT32_MAX;
12284 uint64_t b4 = UINT64_MAX;
12286 int_least8_t c1 = INT8_C (0x7f);
12287 int_least8_t c1max = INT_LEAST8_MAX;
12288 int_least8_t c1min = INT_LEAST8_MIN;
12289 int_least16_t c2 = INT16_C (0x7fff);
12290 int_least16_t c2max = INT_LEAST16_MAX;
12291 int_least16_t c2min = INT_LEAST16_MIN;
12292 int_least32_t c3 = INT32_C (0x7fffffff);
12293 int_least32_t c3max = INT_LEAST32_MAX;
12294 int_least32_t c3min = INT_LEAST32_MIN;
12295 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
12296 int_least64_t c4max = INT_LEAST64_MAX;
12297 int_least64_t c4min = INT_LEAST64_MIN;
12298 uint_least8_t d1 = UINT8_C (0xff);
12299 uint_least8_t d1max = UINT_LEAST8_MAX;
12300 uint_least16_t d2 = UINT16_C (0xffff);
12301 uint_least16_t d2max = UINT_LEAST16_MAX;
12302 uint_least32_t d3 = UINT32_C (0xffffffff);
12303 uint_least32_t d3max = UINT_LEAST32_MAX;
12304 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
12305 uint_least64_t d4max = UINT_LEAST64_MAX;
12306 int_fast8_t e1 = INT_FAST8_MAX;
12307 int_fast8_t e1min = INT_FAST8_MIN;
12308 int_fast16_t e2 = INT_FAST16_MAX;
12309 int_fast16_t e2min = INT_FAST16_MIN;
12310 int_fast32_t e3 = INT_FAST32_MAX;
12311 int_fast32_t e3min = INT_FAST32_MIN;
12312 int_fast64_t e4 = INT_FAST64_MAX;
12313 int_fast64_t e4min = INT_FAST64_MIN;
12314 uint_fast8_t f1 = UINT_FAST8_MAX;
12315 uint_fast16_t f2 = UINT_FAST16_MAX;
12316 uint_fast32_t f3 = UINT_FAST32_MAX;
12317 uint_fast64_t f4 = UINT_FAST64_MAX;
12319 intptr_t g = INTPTR_MAX;
12320 intptr_t gmin = INTPTR_MIN;
12323 uintptr_t h = UINTPTR_MAX;
12325 intmax_t i = INTMAX_MAX;
12326 uintmax_t j = UINTMAX_MAX;
12328 #include <limits.h> /* for CHAR_BIT */
12329 #define TYPE_MINIMUM(t) \
12330 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
12331 #define TYPE_MAXIMUM(t) \
12332 ((t) ((t) 0 < (t) -1 \
12334 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
12337 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
12338 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
12340 /* Detect bug in FreeBSD 6.0 / ia64. */
12341 int check_SIG_ATOMIC:
12342 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
12343 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
12345 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
12347 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
12348 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
12350 /* Detect bug in mingw. */
12352 WINT_MIN == TYPE_MINIMUM (wint_t)
12353 && WINT_MAX == TYPE_MAXIMUM (wint_t)
12356 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
12358 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
12359 int check_UINT16_C:
12360 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
12362 /* Detect bugs in OpenBSD 3.9 stdint.h. */
12364 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
12367 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
12370 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
12373 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
12375 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
12376 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
12377 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
12378 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
12379 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
12380 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
12381 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
12382 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
12383 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
12384 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
12385 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
12396 if ac_fn_c_try_compile "$LINENO"; then :
12397 if test "$cross_compiling" = yes; then :
12398 gl_cv_header_working_stdint_h=yes
12401 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12402 /* end confdefs.h. */
12405 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
12406 #include <stdint.h>
12409 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
12410 included before <wchar.h>. */
12411 #include <stddef.h>
12412 #include <signal.h>
12414 # include <stdio.h>
12416 # include <wchar.h>
12421 #include <string.h>
12422 #define MVAL(macro) MVAL1(macro)
12423 #define MVAL1(expression) #expression
12424 static const char *macro_values[] =
12458 for (mv = macro_values; *mv != NULL; mv++)
12460 const char *value = *mv;
12461 /* Test whether it looks like a cast expression. */
12462 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
12463 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
12464 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
12465 || strncmp (value, "((int)"/*)*/, 6) == 0
12466 || strncmp (value, "((signed short)"/*)*/, 15) == 0
12467 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
12468 return mv - macro_values + 1;
12476 if ac_fn_c_try_run "$LINENO"; then :
12477 gl_cv_header_working_stdint_h=yes
12479 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12480 conftest.$ac_objext conftest.beam conftest.$ac_ext
12485 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12488 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
12489 printf "%s\n" "$gl_cv_header_working_stdint_h" >&6; }
12491 if test "$gl_cv_header_working_stdint_h" = yes; then
12494 for ac_header in sys/inttypes.h sys/bitypes.h
12496 as_ac_Header=`printf "%s\n" "ac_cv_header_$ac_header" | $as_tr_sh`
12497 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12498 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
12499 cat >>confdefs.h <<_ACEOF
12500 #define `printf "%s\n" "HAVE_$ac_header" | $as_tr_cpp` 1
12507 if test $ac_cv_header_sys_inttypes_h = yes; then
12508 HAVE_SYS_INTTYPES_H=1
12510 HAVE_SYS_INTTYPES_H=0
12513 if test $ac_cv_header_sys_bitypes_h = yes; then
12514 HAVE_SYS_BITYPES_H=1
12516 HAVE_SYS_BITYPES_H=0
12522 if test $APPLE_UNIVERSAL_BUILD = 0; then
12525 for gltype in ptrdiff_t size_t ; do
12526 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
12527 printf %s "checking for bit size of $gltype... " >&6; }
12528 if eval \${gl_cv_bitsizeof_${gltype}+:} false; then :
12529 printf %s "(cached) " >&6
12531 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
12532 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
12533 included before <wchar.h>. */
12534 #include <stddef.h>
12535 #include <signal.h>
12537 # include <stdio.h>
12539 # include <wchar.h>
12542 #include <limits.h>"; then :
12548 eval gl_cv_bitsizeof_${gltype}=\$result
12551 eval ac_res=\$gl_cv_bitsizeof_${gltype}
12552 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
12553 printf "%s\n" "$ac_res" >&6; }
12554 eval result=\$gl_cv_bitsizeof_${gltype}
12555 if test $result = unknown; then
12558 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
12559 cat >>confdefs.h <<_ACEOF
12560 #define BITSIZEOF_${GLTYPE} $result
12563 eval BITSIZEOF_${GLTYPE}=\$result
12570 for gltype in sig_atomic_t wchar_t wint_t ; do
12571 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
12572 printf %s "checking for bit size of $gltype... " >&6; }
12573 if eval \${gl_cv_bitsizeof_${gltype}+:} false; then :
12574 printf %s "(cached) " >&6
12576 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
12577 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
12578 included before <wchar.h>. */
12579 #include <stddef.h>
12580 #include <signal.h>
12582 # include <stdio.h>
12584 # include <wchar.h>
12587 #include <limits.h>"; then :
12593 eval gl_cv_bitsizeof_${gltype}=\$result
12596 eval ac_res=\$gl_cv_bitsizeof_${gltype}
12597 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
12598 printf "%s\n" "$ac_res" >&6; }
12599 eval result=\$gl_cv_bitsizeof_${gltype}
12600 if test $result = unknown; then
12603 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
12604 cat >>confdefs.h <<_ACEOF
12605 #define BITSIZEOF_${GLTYPE} $result
12608 eval BITSIZEOF_${GLTYPE}=\$result
12614 for gltype in sig_atomic_t wchar_t wint_t ; do
12615 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
12616 printf %s "checking whether $gltype is signed... " >&6; }
12617 if eval \${gl_cv_type_${gltype}_signed+:} false; then :
12618 printf %s "(cached) " >&6
12620 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12621 /* end confdefs.h. */
12623 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
12624 included before <wchar.h>. */
12625 #include <stddef.h>
12626 #include <signal.h>
12628 # include <stdio.h>
12630 # include <wchar.h>
12633 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
12642 if ac_fn_c_try_compile "$LINENO"; then :
12647 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12648 eval gl_cv_type_${gltype}_signed=\$result
12651 eval ac_res=\$gl_cv_type_${gltype}_signed
12652 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
12653 printf "%s\n" "$ac_res" >&6; }
12654 eval result=\$gl_cv_type_${gltype}_signed
12655 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
12656 if test "$result" = yes; then
12657 cat >>confdefs.h <<_ACEOF
12658 #define HAVE_SIGNED_${GLTYPE} 1
12661 eval HAVE_SIGNED_${GLTYPE}=1
12663 eval HAVE_SIGNED_${GLTYPE}=0
12668 gl_cv_type_ptrdiff_t_signed=yes
12669 gl_cv_type_size_t_signed=no
12670 if test $APPLE_UNIVERSAL_BUILD = 0; then
12673 for gltype in ptrdiff_t size_t ; do
12674 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
12675 printf %s "checking for $gltype integer literal suffix... " >&6; }
12676 if eval \${gl_cv_type_${gltype}_suffix+:} false; then :
12677 printf %s "(cached) " >&6
12679 eval gl_cv_type_${gltype}_suffix=no
12680 eval result=\$gl_cv_type_${gltype}_signed
12681 if test "$result" = yes; then
12686 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
12688 '') gltype1='int';;
12689 l) gltype1='long int';;
12690 ll) gltype1='long long int';;
12691 i64) gltype1='__int64';;
12692 u) gltype1='unsigned int';;
12693 ul) gltype1='unsigned long int';;
12694 ull) gltype1='unsigned long long int';;
12695 ui64)gltype1='unsigned __int64';;
12697 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12698 /* end confdefs.h. */
12700 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
12701 included before <wchar.h>. */
12702 #include <stddef.h>
12703 #include <signal.h>
12705 # include <stdio.h>
12707 # include <wchar.h>
12710 extern $gltype foo;
12711 extern $gltype1 foo;
12720 if ac_fn_c_try_compile "$LINENO"; then :
12721 eval gl_cv_type_${gltype}_suffix=\$glsuf
12723 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12724 eval result=\$gl_cv_type_${gltype}_suffix
12725 test "$result" != no && break
12728 eval ac_res=\$gl_cv_type_${gltype}_suffix
12729 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
12730 printf "%s\n" "$ac_res" >&6; }
12731 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
12732 eval result=\$gl_cv_type_${gltype}_suffix
12733 test "$result" = no && result=
12734 eval ${GLTYPE}_SUFFIX=\$result
12735 cat >>confdefs.h <<_ACEOF
12736 #define ${GLTYPE}_SUFFIX $result
12745 for gltype in sig_atomic_t wchar_t wint_t ; do
12746 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
12747 printf %s "checking for $gltype integer literal suffix... " >&6; }
12748 if eval \${gl_cv_type_${gltype}_suffix+:} false; then :
12749 printf %s "(cached) " >&6
12751 eval gl_cv_type_${gltype}_suffix=no
12752 eval result=\$gl_cv_type_${gltype}_signed
12753 if test "$result" = yes; then
12758 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
12760 '') gltype1='int';;
12761 l) gltype1='long int';;
12762 ll) gltype1='long long int';;
12763 i64) gltype1='__int64';;
12764 u) gltype1='unsigned int';;
12765 ul) gltype1='unsigned long int';;
12766 ull) gltype1='unsigned long long int';;
12767 ui64)gltype1='unsigned __int64';;
12769 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12770 /* end confdefs.h. */
12772 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
12773 included before <wchar.h>. */
12774 #include <stddef.h>
12775 #include <signal.h>
12777 # include <stdio.h>
12779 # include <wchar.h>
12782 extern $gltype foo;
12783 extern $gltype1 foo;
12792 if ac_fn_c_try_compile "$LINENO"; then :
12793 eval gl_cv_type_${gltype}_suffix=\$glsuf
12795 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12796 eval result=\$gl_cv_type_${gltype}_suffix
12797 test "$result" != no && break
12800 eval ac_res=\$gl_cv_type_${gltype}_suffix
12801 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
12802 printf "%s\n" "$ac_res" >&6; }
12803 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
12804 eval result=\$gl_cv_type_${gltype}_suffix
12805 test "$result" = no && result=
12806 eval ${GLTYPE}_SUFFIX=\$result
12807 cat >>confdefs.h <<_ACEOF
12808 #define ${GLTYPE}_SUFFIX $result
12815 if test $BITSIZEOF_WINT_T -lt 32; then
12816 BITSIZEOF_WINT_T=32
12822 if test -n "$STDINT_H"; then
12823 GL_GENERATE_STDINT_H_TRUE=
12824 GL_GENERATE_STDINT_H_FALSE='#'
12826 GL_GENERATE_STDINT_H_TRUE='#'
12827 GL_GENERATE_STDINT_H_FALSE=
12836 GNULIB_STRTOIMAX=0;
12837 GNULIB_STRTOUMAX=0;
12838 HAVE_DECL_IMAXABS=1;
12839 HAVE_DECL_IMAXDIV=1;
12840 HAVE_DECL_STRTOIMAX=1;
12841 HAVE_DECL_STRTOUMAX=1;
12842 REPLACE_STRTOIMAX=0;
12843 INT32_MAX_LT_INTMAX_MAX=1;
12844 INT64_MAX_EQ_LONG_MAX='defined _LP64';
12845 PRI_MACROS_BROKEN=0;
12846 PRIPTR_PREFIX=__PRIPTR_PREFIX;
12847 UINT32_MAX_LT_UINTMAX_MAX=1;
12848 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
12864 if test $gl_cv_have_include_next = yes; then
12865 gl_cv_next_inttypes_h='<'inttypes.h'>'
12867 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
12868 printf %s "checking absolute name of <inttypes.h>... " >&6; }
12869 if ${gl_cv_next_inttypes_h+:} false; then :
12870 printf %s "(cached) " >&6
12873 if test $ac_cv_header_inttypes_h = yes; then
12876 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12877 /* end confdefs.h. */
12878 #include <inttypes.h>
12882 aix*) gl_absname_cpp="$ac_cpp -C" ;;
12883 *) gl_absname_cpp="$ac_cpp" ;;
12888 gl_dirsep_regex='[/\\]'
12891 gl_dirsep_regex='\/'
12894 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
12896 gl_header_literal_regex=`echo 'inttypes.h' \
12897 | sed -e "$gl_make_literal_regex_sed"`
12898 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
12899 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
12904 gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
12905 sed -n "$gl_absolute_header_sed"`'"'
12907 gl_cv_next_inttypes_h='<'inttypes.h'>'
12912 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
12913 printf "%s\n" "$gl_cv_next_inttypes_h" >&6; }
12915 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
12917 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
12918 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
12919 gl_next_as_first_directive='<'inttypes.h'>'
12921 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
12922 gl_next_as_first_directive=$gl_cv_next_inttypes_h
12924 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
12933 for gl_func in imaxabs imaxdiv strtoimax strtoumax; do
12934 as_gl_Symbol=`printf "%s\n" "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
12935 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
12936 printf %s "checking whether $gl_func is declared without a macro... " >&6; }
12937 if eval \${$as_gl_Symbol+:} false; then :
12938 printf %s "(cached) " >&6
12940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12941 /* end confdefs.h. */
12942 #include <inttypes.h>
12953 if ac_fn_c_try_compile "$LINENO"; then :
12954 eval "$as_gl_Symbol=yes"
12956 eval "$as_gl_Symbol=no"
12958 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12960 eval ac_res=\$$as_gl_Symbol
12961 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
12962 printf "%s\n" "$ac_res" >&6; }
12963 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
12964 cat >>confdefs.h <<_ACEOF
12965 #define `printf "%s\n" "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
12968 eval ac_cv_have_decl_$gl_func=yes
12974 for ac_header in inttypes.h
12976 ac_fn_c_check_header_mongrel "$LINENO" "inttypes.h" "ac_cv_header_inttypes_h" "$ac_includes_default"
12977 if test "x$ac_cv_header_inttypes_h" = xyes; then :
12978 cat >>confdefs.h <<_ACEOF
12979 #define HAVE_INTTYPES_H 1
12986 if test $ac_cv_header_inttypes_h = yes; then
12987 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the inttypes.h PRIxNN macros are broken" >&5
12988 printf %s "checking whether the inttypes.h PRIxNN macros are broken... " >&6; }
12989 if ${gt_cv_inttypes_pri_broken+:} false; then :
12990 printf %s "(cached) " >&6
12993 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12994 /* end confdefs.h. */
12996 #include <inttypes.h>
13009 if ac_fn_c_try_compile "$LINENO"; then :
13010 gt_cv_inttypes_pri_broken=no
13012 gt_cv_inttypes_pri_broken=yes
13014 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13017 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_inttypes_pri_broken" >&5
13018 printf "%s\n" "$gt_cv_inttypes_pri_broken" >&6; }
13020 if test "$gt_cv_inttypes_pri_broken" = yes; then
13022 cat >>confdefs.h <<_ACEOF
13023 #define PRI_MACROS_BROKEN 1
13026 PRI_MACROS_BROKEN=1
13028 PRI_MACROS_BROKEN=0
13037 GNULIB_TOWCTRANS=0;
13041 REPLACE_ISWBLANK=0;
13046 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for wint_t" >&5
13047 printf %s "checking for wint_t... " >&6; }
13048 if ${gt_cv_c_wint_t+:} false; then :
13049 printf %s "(cached) " >&6
13051 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13052 /* end confdefs.h. */
13054 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
13056 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
13057 before <wchar.h>. */
13058 #include <stddef.h>
13062 wint_t foo = (wchar_t)'\0';
13071 if ac_fn_c_try_compile "$LINENO"; then :
13076 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13078 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wint_t" >&5
13079 printf "%s\n" "$gt_cv_c_wint_t" >&6; }
13080 if test $gt_cv_c_wint_t = yes; then
13082 printf "%s\n" "#define HAVE_WINT_T 1" >>confdefs.h
13091 if test $ac_cv_func_iswcntrl = yes; then
13099 if test $gt_cv_c_wint_t = yes; then
13115 if test $gl_cv_have_include_next = yes; then
13116 gl_cv_next_wctype_h='<'wctype.h'>'
13118 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <wctype.h>" >&5
13119 printf %s "checking absolute name of <wctype.h>... " >&6; }
13120 if ${gl_cv_next_wctype_h+:} false; then :
13121 printf %s "(cached) " >&6
13124 if test $ac_cv_header_wctype_h = yes; then
13127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13128 /* end confdefs.h. */
13129 #include <wctype.h>
13133 aix*) gl_absname_cpp="$ac_cpp -C" ;;
13134 *) gl_absname_cpp="$ac_cpp" ;;
13139 gl_dirsep_regex='[/\\]'
13142 gl_dirsep_regex='\/'
13145 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
13147 gl_header_literal_regex=`echo 'wctype.h' \
13148 | sed -e "$gl_make_literal_regex_sed"`
13149 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
13150 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
13155 gl_cv_next_wctype_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
13156 sed -n "$gl_absolute_header_sed"`'"'
13158 gl_cv_next_wctype_h='<'wctype.h'>'
13163 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wctype_h" >&5
13164 printf "%s\n" "$gl_cv_next_wctype_h" >&6; }
13166 NEXT_WCTYPE_H=$gl_cv_next_wctype_h
13168 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
13169 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
13170 gl_next_as_first_directive='<'wctype.h'>'
13172 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
13173 gl_next_as_first_directive=$gl_cv_next_wctype_h
13175 NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H=$gl_next_as_first_directive
13180 if test $ac_cv_header_wctype_h = yes; then
13181 if test $ac_cv_func_iswcntrl = yes; then
13182 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether iswcntrl works" >&5
13183 printf %s "checking whether iswcntrl works... " >&6; }
13184 if ${gl_cv_func_iswcntrl_works+:} false; then :
13185 printf %s "(cached) " >&6
13188 if test "$cross_compiling" = yes; then :
13189 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13190 /* end confdefs.h. */
13191 #include <stdlib.h>
13192 #if __GNU_LIBRARY__ == 1
13193 Linux libc5 i18n is broken.
13203 if ac_fn_c_try_compile "$LINENO"; then :
13204 gl_cv_func_iswcntrl_works="guessing yes"
13206 gl_cv_func_iswcntrl_works="guessing no"
13208 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13211 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13212 /* end confdefs.h. */
13214 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
13215 included before <wchar.h>.
13216 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
13217 must be included before <wchar.h>. */
13218 #include <stddef.h>
13222 #include <wctype.h>
13223 int main () { return iswprint ('x') == 0; }
13226 if ac_fn_c_try_run "$LINENO"; then :
13227 gl_cv_func_iswcntrl_works=yes
13229 gl_cv_func_iswcntrl_works=no
13231 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13232 conftest.$ac_objext conftest.beam conftest.$ac_ext
13237 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_iswcntrl_works" >&5
13238 printf "%s\n" "$gl_cv_func_iswcntrl_works" >&6; }
13246 case "$gl_cv_func_iswcntrl_works" in
13247 *yes) REPLACE_ISWCNTRL=0 ;;
13248 *) REPLACE_ISWCNTRL=1 ;;
13252 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_ISWCNTRL = 1; then
13256 if test $REPLACE_ISWCNTRL = 1; then
13259 for ac_func in towlower
13261 ac_fn_c_check_func "$LINENO" "towlower" "ac_cv_func_towlower"
13262 if test "x$ac_cv_func_towlower" = xyes; then :
13263 cat >>confdefs.h <<_ACEOF
13264 #define HAVE_TOWLOWER 1
13270 if test $ac_cv_func_towlower = yes; then
13273 ac_fn_c_check_decl "$LINENO" "towlower" "ac_cv_have_decl_towlower" "/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
13274 included before <wchar.h>.
13275 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
13276 must be included before <wchar.h>. */
13277 #include <stddef.h>
13282 # include <wctype.h>
13286 if test "x$ac_cv_have_decl_towlower" = xyes; then :
13292 cat >>confdefs.h <<_ACEOF
13293 #define HAVE_DECL_TOWLOWER $ac_have_decl
13296 if test $ac_cv_have_decl_towlower = yes; then
13305 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_TOWLOWER = 1; then
13309 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for wctype_t" >&5
13310 printf %s "checking for wctype_t... " >&6; }
13311 if ${gl_cv_type_wctype_t+:} false; then :
13312 printf %s "(cached) " >&6
13314 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13315 /* end confdefs.h. */
13316 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
13317 included before <wchar.h>.
13318 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
13319 must be included before <wchar.h>. */
13320 #include <stddef.h>
13325 # include <wctype.h>
13337 if ac_fn_c_try_compile "$LINENO"; then :
13338 gl_cv_type_wctype_t=yes
13340 gl_cv_type_wctype_t=no
13342 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13345 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctype_t" >&5
13346 printf "%s\n" "$gl_cv_type_wctype_t" >&6; }
13347 if test $gl_cv_type_wctype_t = no; then
13351 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for wctrans_t" >&5
13352 printf %s "checking for wctrans_t... " >&6; }
13353 if ${gl_cv_type_wctrans_t+:} false; then :
13354 printf %s "(cached) " >&6
13356 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13357 /* end confdefs.h. */
13358 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
13359 included before <wchar.h>.
13360 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
13361 must be included before <wchar.h>. */
13362 #include <stddef.h>
13366 #include <wctype.h>
13377 if ac_fn_c_try_compile "$LINENO"; then :
13378 gl_cv_type_wctrans_t=yes
13380 gl_cv_type_wctrans_t=no
13382 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13385 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctrans_t" >&5
13386 printf "%s\n" "$gl_cv_type_wctrans_t" >&6; }
13387 if test $gl_cv_type_wctrans_t = no; then
13392 for gl_func in wctype iswctype wctrans towctrans ; do
13393 as_gl_Symbol=`printf "%s\n" "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
13394 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
13395 printf %s "checking whether $gl_func is declared without a macro... " >&6; }
13396 if eval \${$as_gl_Symbol+:} false; then :
13397 printf %s "(cached) " >&6
13399 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13400 /* end confdefs.h. */
13402 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
13404 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
13405 included before <wchar.h>. */
13406 #if !(defined __GLIBC__ && !defined __UCLIBC__)
13407 # include <stddef.h>
13408 # include <stdio.h>
13410 # include <wchar.h>
13412 #include <wctype.h>
13423 if ac_fn_c_try_compile "$LINENO"; then :
13424 eval "$as_gl_Symbol=yes"
13426 eval "$as_gl_Symbol=no"
13428 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13430 eval ac_res=\$$as_gl_Symbol
13431 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
13432 printf "%s\n" "$ac_res" >&6; }
13433 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
13434 cat >>confdefs.h <<_ACEOF
13435 #define `printf "%s\n" "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
13438 eval ac_cv_have_decl_$gl_func=yes
13446 GNULIB_NL_LANGINFO=0;
13447 HAVE_NL_LANGINFO=1;
13448 REPLACE_NL_LANGINFO=0;
13452 ac_fn_c_check_decl "$LINENO" "getc_unlocked" "ac_cv_have_decl_getc_unlocked" "$ac_includes_default"
13453 if test "x$ac_cv_have_decl_getc_unlocked" = xyes; then :
13459 cat >>confdefs.h <<_ACEOF
13460 #define HAVE_DECL_GETC_UNLOCKED $ac_have_decl
13464 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C Library >= 2.1 or uClibc" >&5
13465 printf %s "checking whether we are using the GNU C Library >= 2.1 or uClibc... " >&6; }
13466 if ${ac_cv_gnu_library_2_1+:} false; then :
13467 printf %s "(cached) " >&6
13469 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13470 /* end confdefs.h. */
13472 #include <features.h>
13473 #ifdef __GNU_LIBRARY__
13474 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)
13483 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13484 $EGREP "Lucky" >/dev/null 2>&1; then :
13485 ac_cv_gnu_library_2_1=yes
13487 ac_cv_gnu_library_2_1=no
13494 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gnu_library_2_1" >&5
13495 printf "%s\n" "$ac_cv_gnu_library_2_1" >&6; }
13497 GLIBC21="$ac_cv_gnu_library_2_1"
13501 GNULIB_LOCALECONV=0;
13502 GNULIB_SETLOCALE=0;
13503 GNULIB_DUPLOCALE=0;
13505 REPLACE_LOCALECONV=0;
13506 REPLACE_SETLOCALE=0;
13507 REPLACE_DUPLOCALE=0;
13508 REPLACE_STRUCT_LCONV=0;
13515 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
13516 printf %s "checking for wchar_t... " >&6; }
13517 if ${gt_cv_c_wchar_t+:} false; then :
13518 printf %s "(cached) " >&6
13520 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13521 /* end confdefs.h. */
13522 #include <stddef.h>
13523 wchar_t foo = (wchar_t)'\0';
13532 if ac_fn_c_try_compile "$LINENO"; then :
13533 gt_cv_c_wchar_t=yes
13537 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13539 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
13540 printf "%s\n" "$gt_cv_c_wchar_t" >&6; }
13541 if test $gt_cv_c_wchar_t = yes; then
13543 printf "%s\n" "#define HAVE_WCHAR_T 1" >>confdefs.h
13551 if test $gt_cv_c_wchar_t = no; then
13555 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
13556 printf %s "checking whether NULL can be used in arbitrary expressions... " >&6; }
13557 if ${gl_cv_decl_null_works+:} false; then :
13558 printf %s "(cached) " >&6
13560 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13561 /* end confdefs.h. */
13562 #include <stddef.h>
13563 int test[2 * (sizeof NULL == sizeof (void *)) -1];
13573 if ac_fn_c_try_compile "$LINENO"; then :
13574 gl_cv_decl_null_works=yes
13576 gl_cv_decl_null_works=no
13578 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13580 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
13581 printf "%s\n" "$gl_cv_decl_null_works" >&6; }
13582 if test $gl_cv_decl_null_works = no; then
13587 if test -n "$STDDEF_H"; then
13588 GL_GENERATE_STDDEF_H_TRUE=
13589 GL_GENERATE_STDDEF_H_FALSE='#'
13591 GL_GENERATE_STDDEF_H_TRUE='#'
13592 GL_GENERATE_STDDEF_H_FALSE=
13595 if test -n "$STDDEF_H"; then
13604 if test $gl_cv_have_include_next = yes; then
13605 gl_cv_next_stddef_h='<'stddef.h'>'
13607 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
13608 printf %s "checking absolute name of <stddef.h>... " >&6; }
13609 if ${gl_cv_next_stddef_h+:} false; then :
13610 printf %s "(cached) " >&6
13613 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13614 /* end confdefs.h. */
13615 #include <stddef.h>
13619 aix*) gl_absname_cpp="$ac_cpp -C" ;;
13620 *) gl_absname_cpp="$ac_cpp" ;;
13625 gl_dirsep_regex='[/\\]'
13628 gl_dirsep_regex='\/'
13631 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
13633 gl_header_literal_regex=`echo 'stddef.h' \
13634 | sed -e "$gl_make_literal_regex_sed"`
13635 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
13636 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
13641 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
13642 sed -n "$gl_absolute_header_sed"`'"'
13646 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
13647 printf "%s\n" "$gl_cv_next_stddef_h" >&6; }
13649 NEXT_STDDEF_H=$gl_cv_next_stddef_h
13651 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
13652 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
13653 gl_next_as_first_directive='<'stddef.h'>'
13655 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
13656 gl_next_as_first_directive=$gl_cv_next_stddef_h
13658 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
13670 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
13671 printf %s "checking whether lstat correctly handles trailing slash... " >&6; }
13672 if ${gl_cv_func_lstat_dereferences_slashed_symlink+:} false; then :
13673 printf %s "(cached) " >&6
13675 rm -f conftest.sym conftest.file
13676 echo >conftest.file
13677 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
13678 if test "$cross_compiling" = yes; then :
13680 # Guess yes on glibc systems.
13681 *-gnu*) gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
13682 # If we don't know, assume the worst.
13683 *) gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
13687 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13688 /* end confdefs.h. */
13689 $ac_includes_default
13694 /* Linux will dereference the symlink and fail, as required by
13695 POSIX. That is better in the sense that it means we will not
13696 have to compile and use the lstat wrapper. */
13697 return lstat ("conftest.sym/", &sbuf) == 0;
13703 if ac_fn_c_try_run "$LINENO"; then :
13704 gl_cv_func_lstat_dereferences_slashed_symlink=yes
13706 gl_cv_func_lstat_dereferences_slashed_symlink=no
13708 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13709 conftest.$ac_objext conftest.beam conftest.$ac_ext
13713 # If the 'ln -s' command failed, then we probably don't even
13714 # have an lstat function.
13715 gl_cv_func_lstat_dereferences_slashed_symlink="guessing no"
13717 rm -f conftest.sym conftest.file
13720 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
13721 printf "%s\n" "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
13722 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
13725 cat >>confdefs.h <<_ACEOF
13726 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
13735 GNULIB_CALLOC_POSIX=0;
13736 GNULIB_CANONICALIZE_FILE_NAME=0;
13737 GNULIB_GETLOADAVG=0;
13738 GNULIB_GETSUBOPT=0;
13740 GNULIB_MALLOC_POSIX=0;
13744 GNULIB_MKOSTEMPS=0;
13747 GNULIB_POSIX_OPENPT=0;
13749 GNULIB_PTSNAME_R=0;
13753 GNULIB_REALLOC_POSIX=0;
13756 GNULIB_SECURE_GETENV=0;
13761 GNULIB_SYSTEM_POSIX=0;
13767 HAVE_CANONICALIZE_FILE_NAME=1;
13768 HAVE_DECL_GETLOADAVG=1;
13776 HAVE_POSIX_OPENPT=1;
13784 HAVE_SECURE_GETENV=1;
13786 HAVE_DECL_SETENV=1;
13790 HAVE_STRUCT_RANDOM_DATA=1;
13791 HAVE_SYS_LOADAVG_H=0;
13793 HAVE_DECL_UNSETENV=1;
13795 REPLACE_CANONICALIZE_FILE_NAME=0;
13800 REPLACE_PTSNAME_R=0;
13802 REPLACE_RANDOM_R=0;
13804 REPLACE_REALPATH=0;
13807 REPLACE_UNSETENV=0;
13811 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether malloc, realloc, calloc are POSIX compliant" >&5
13812 printf %s "checking whether malloc, realloc, calloc are POSIX compliant... " >&6; }
13813 if ${gl_cv_func_malloc_posix+:} false; then :
13814 printf %s "(cached) " >&6
13817 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13818 /* end confdefs.h. */
13823 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
13831 if ac_fn_c_try_compile "$LINENO"; then :
13832 gl_cv_func_malloc_posix=yes
13834 gl_cv_func_malloc_posix=no
13836 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13839 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_malloc_posix" >&5
13840 printf "%s\n" "$gl_cv_func_malloc_posix" >&6; }
13844 for ac_header in stdlib.h
13846 ac_fn_c_check_header_mongrel "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default"
13847 if test "x$ac_cv_header_stdlib_h" = xyes; then :
13848 cat >>confdefs.h <<_ACEOF
13849 #define HAVE_STDLIB_H 1
13856 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5
13857 printf %s "checking for GNU libc compatible malloc... " >&6; }
13858 if ${ac_cv_func_malloc_0_nonnull+:} false; then :
13859 printf %s "(cached) " >&6
13861 if test "$cross_compiling" = yes; then :
13863 # Guess yes on platforms where we know the result.
13864 *-gnu* | freebsd* | netbsd* | openbsd* \
13865 | hpux* | solaris* | cygwin* | mingw*)
13866 ac_cv_func_malloc_0_nonnull=yes ;;
13867 # If we don't know, assume the worst.
13868 *) ac_cv_func_malloc_0_nonnull=no ;;
13872 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13873 /* end confdefs.h. */
13874 #if defined STDC_HEADERS || defined HAVE_STDLIB_H
13875 # include <stdlib.h>
13883 return ! malloc (0);
13889 if ac_fn_c_try_run "$LINENO"; then :
13890 ac_cv_func_malloc_0_nonnull=yes
13892 ac_cv_func_malloc_0_nonnull=no
13894 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13895 conftest.$ac_objext conftest.beam conftest.$ac_ext
13900 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_malloc_0_nonnull" >&5
13901 printf "%s\n" "$ac_cv_func_malloc_0_nonnull" >&6; }
13902 if test $ac_cv_func_malloc_0_nonnull = yes; then :
13903 gl_cv_func_malloc_0_nonnull=1
13905 gl_cv_func_malloc_0_nonnull=0
13909 cat >>confdefs.h <<_ACEOF
13910 #define MALLOC_0_IS_NONNULL $gl_cv_func_malloc_0_nonnull
13921 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a traditional japanese locale" >&5
13922 printf %s "checking for a traditional japanese locale... " >&6; }
13923 if ${gt_cv_locale_ja+:} false; then :
13924 printf %s "(cached) " >&6
13927 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13928 /* end confdefs.h. */
13930 #include <locale.h>
13932 #if HAVE_LANGINFO_CODESET
13933 # include <langinfo.h>
13935 #include <stdlib.h>
13936 #include <string.h>
13942 /* Check whether the given locale name is recognized by the system. */
13943 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
13944 /* On native Windows, setlocale(category, "") looks at the system settings,
13945 not at the environment variables. Also, when an encoding suffix such
13946 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
13947 category of the locale to "C". */
13948 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
13949 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
13952 if (setlocale (LC_ALL, "") == NULL) return 1;
13954 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
13955 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
13956 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
13957 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
13958 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
13959 some unit tests fail.
13960 On MirBSD 10, when an unsupported locale is specified, setlocale()
13961 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
13962 #if HAVE_LANGINFO_CODESET
13964 const char *cs = nl_langinfo (CODESET);
13965 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
13966 || strcmp (cs, "UTF-8") == 0)
13971 /* On Cygwin, avoid locale names without encoding suffix, because the
13972 locale_charset() function relies on the encoding suffix. Note that
13973 LC_ALL is set on the command line. */
13974 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
13976 /* Check whether MB_CUR_MAX is > 1. This excludes the dysfunctional locales
13977 on Cygwin 1.5.x. */
13978 if (MB_CUR_MAX == 1)
13980 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
13981 This excludes the UTF-8 encoding (except on MirBSD). */
13982 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
13983 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
13984 for (p = buf; *p != '\0'; p++)
13985 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
13991 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
13992 (eval $ac_link) 2>&5
13994 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
13995 test $ac_status = 0; } && test -s conftest$ac_exeext; then
13997 # Handle native Windows specially, because there setlocale() interprets
13998 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
13999 # "fr" or "fra" as "French" or "French_France.1252",
14000 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
14001 # "ja" as "Japanese" or "Japanese_Japan.932",
14004 # Note that on native Windows, the Japanese locale is
14005 # Japanese_Japan.932, and CP932 is very different from EUC-JP, so we
14006 # cannot use it here.
14007 gt_cv_locale_ja=none
14010 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
14011 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
14012 # configure script would override the LC_ALL setting. Likewise for
14013 # LC_CTYPE, which is also set at the beginning of the configure script.
14014 # Test for the AIX locale name.
14015 if (LC_ALL=ja_JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14016 gt_cv_locale_ja=ja_JP
14018 # Test for the locale name with explicit encoding suffix.
14019 if (LC_ALL=ja_JP.EUC-JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14020 gt_cv_locale_ja=ja_JP.EUC-JP
14022 # Test for the HP-UX, OSF/1, NetBSD locale name.
14023 if (LC_ALL=ja_JP.eucJP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14024 gt_cv_locale_ja=ja_JP.eucJP
14026 # Test for the IRIX, FreeBSD locale name.
14027 if (LC_ALL=ja_JP.EUC LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14028 gt_cv_locale_ja=ja_JP.EUC
14030 # Test for the Solaris 7 locale name.
14031 if (LC_ALL=ja LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14034 # Special test for NetBSD 1.6.
14035 if test -f /usr/share/locale/ja_JP.eucJP/LC_CTYPE; then
14036 gt_cv_locale_ja=ja_JP.eucJP
14039 gt_cv_locale_ja=none
14052 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_ja" >&5
14053 printf "%s\n" "$gt_cv_locale_ja" >&6; }
14054 LOCALE_JA=$gt_cv_locale_ja
14060 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a transitional chinese locale" >&5
14061 printf %s "checking for a transitional chinese locale... " >&6; }
14062 if ${gt_cv_locale_zh_CN+:} false; then :
14063 printf %s "(cached) " >&6
14066 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14067 /* end confdefs.h. */
14069 #include <locale.h>
14070 #include <stdlib.h>
14072 #if HAVE_LANGINFO_CODESET
14073 # include <langinfo.h>
14075 #include <stdlib.h>
14076 #include <string.h>
14082 /* Check whether the given locale name is recognized by the system. */
14083 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
14084 /* On native Windows, setlocale(category, "") looks at the system settings,
14085 not at the environment variables. Also, when an encoding suffix such
14086 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
14087 category of the locale to "C". */
14088 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
14089 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
14092 if (setlocale (LC_ALL, "") == NULL) return 1;
14094 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
14095 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
14096 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
14097 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
14098 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
14099 some unit tests fail.
14100 On MirBSD 10, when an unsupported locale is specified, setlocale()
14101 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
14102 #if HAVE_LANGINFO_CODESET
14104 const char *cs = nl_langinfo (CODESET);
14105 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
14106 || strcmp (cs, "UTF-8") == 0)
14111 /* On Cygwin, avoid locale names without encoding suffix, because the
14112 locale_charset() function relies on the encoding suffix. Note that
14113 LC_ALL is set on the command line. */
14114 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
14116 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
14117 This excludes the UTF-8 encoding (except on MirBSD). */
14118 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
14119 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
14120 for (p = buf; *p != '\0'; p++)
14121 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
14123 /* Check whether a typical GB18030 multibyte sequence is recognized as a
14124 single wide character. This excludes the GB2312 and GBK encodings. */
14125 if (mblen ("\203\062\332\066", 5) != 4)
14131 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
14132 (eval $ac_link) 2>&5
14134 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14135 test $ac_status = 0; } && test -s conftest$ac_exeext; then
14137 # Handle native Windows specially, because there setlocale() interprets
14138 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
14139 # "fr" or "fra" as "French" or "French_France.1252",
14140 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
14141 # "ja" as "Japanese" or "Japanese_Japan.932",
14144 # Test for the hypothetical native Windows locale name.
14145 if (LC_ALL=Chinese_China.54936 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14146 gt_cv_locale_zh_CN=Chinese_China.54936
14149 gt_cv_locale_zh_CN=none
14153 # On Solaris 8, the locales zh_CN.GB18030, zh_CN.GBK, zh.GBK are
14154 # broken. One witness is the test case in gl_MBRTOWC_SANITYCHECK.
14155 # Another witness is that "LC_ALL=zh_CN.GB18030 bash -c true" dumps core.
14156 gt_cv_locale_zh_CN=none
14159 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
14160 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
14161 # configure script would override the LC_ALL setting. Likewise for
14162 # LC_CTYPE, which is also set at the beginning of the configure script.
14163 # Test for the locale name without encoding suffix.
14164 if (LC_ALL=zh_CN LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14165 gt_cv_locale_zh_CN=zh_CN
14167 # Test for the locale name with explicit encoding suffix.
14168 if (LC_ALL=zh_CN.GB18030 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14169 gt_cv_locale_zh_CN=zh_CN.GB18030
14172 gt_cv_locale_zh_CN=none
14178 # If there was a link error, due to mblen(), the system is so old that
14179 # it certainly doesn't have a chinese locale.
14180 gt_cv_locale_zh_CN=none
14185 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_zh_CN" >&5
14186 printf "%s\n" "$gt_cv_locale_zh_CN" >&6; }
14187 LOCALE_ZH_CN=$gt_cv_locale_zh_CN
14192 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
14193 printf %s "checking for a french Unicode locale... " >&6; }
14194 if ${gt_cv_locale_fr_utf8+:} false; then :
14195 printf %s "(cached) " >&6
14198 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14199 /* end confdefs.h. */
14201 #include <locale.h>
14203 #if HAVE_LANGINFO_CODESET
14204 # include <langinfo.h>
14206 #include <stdlib.h>
14207 #include <string.h>
14211 /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
14212 imitates locale dependent behaviour by looking at the environment
14213 variables, and all locales use the UTF-8 encoding. */
14214 #if !(defined __BEOS__ || defined __HAIKU__)
14215 /* Check whether the given locale name is recognized by the system. */
14216 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
14217 /* On native Windows, setlocale(category, "") looks at the system settings,
14218 not at the environment variables. Also, when an encoding suffix such
14219 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
14220 category of the locale to "C". */
14221 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
14222 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
14225 if (setlocale (LC_ALL, "") == NULL) return 1;
14227 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
14228 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
14229 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
14230 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
14231 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
14232 some unit tests fail. */
14233 # if HAVE_LANGINFO_CODESET
14235 const char *cs = nl_langinfo (CODESET);
14236 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
14241 /* On Cygwin, avoid locale names without encoding suffix, because the
14242 locale_charset() function relies on the encoding suffix. Note that
14243 LC_ALL is set on the command line. */
14244 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
14246 /* Check whether in the abbreviation of the second month, the second
14247 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
14248 two bytes long, with UTF-8 encoding. */
14249 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
14250 if (strftime (buf, sizeof (buf), "%b", &t) < 4
14251 || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
14254 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
14255 /* Check whether the decimal separator is a comma.
14256 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
14257 are nl_langinfo(RADIXCHAR) are both ".". */
14258 if (localeconv () ->decimal_point[0] != ',') return 1;
14264 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
14265 (eval $ac_link) 2>&5
14267 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14268 test $ac_status = 0; } && test -s conftest$ac_exeext; then
14270 # Handle native Windows specially, because there setlocale() interprets
14271 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
14272 # "fr" or "fra" as "French" or "French_France.1252",
14273 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
14274 # "ja" as "Japanese" or "Japanese_Japan.932",
14277 # Test for the hypothetical native Windows locale name.
14278 if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14279 gt_cv_locale_fr_utf8=French_France.65001
14282 gt_cv_locale_fr_utf8=none
14286 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
14287 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
14288 # configure script would override the LC_ALL setting. Likewise for
14289 # LC_CTYPE, which is also set at the beginning of the configure script.
14290 # Test for the usual locale name.
14291 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14292 gt_cv_locale_fr_utf8=fr_FR
14294 # Test for the locale name with explicit encoding suffix.
14295 if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14296 gt_cv_locale_fr_utf8=fr_FR.UTF-8
14298 # Test for the Solaris 7 locale name.
14299 if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14300 gt_cv_locale_fr_utf8=fr.UTF-8
14303 gt_cv_locale_fr_utf8=none
14313 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
14314 printf "%s\n" "$gt_cv_locale_fr_utf8" >&6; }
14315 LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
14325 GNULIB_RAWMEMCHR=0;
14328 GNULIB_STRCHRNUL=0;
14336 GNULIB_STRCASESTR=0;
14343 GNULIB_MBSCASECMP=0;
14344 GNULIB_MBSNCASECMP=0;
14345 GNULIB_MBSPCASECMP=0;
14346 GNULIB_MBSCASESTR=0;
14353 GNULIB_STRERROR_R=0;
14354 GNULIB_STRSIGNAL=0;
14355 GNULIB_STRVERSCMP=0;
14360 HAVE_DECL_MEMMEM=1;
14362 HAVE_DECL_MEMRCHR=1;
14367 HAVE_DECL_STRDUP=1;
14368 HAVE_DECL_STRNDUP=1;
14369 HAVE_DECL_STRNLEN=1;
14373 HAVE_DECL_STRTOK_R=1;
14374 HAVE_DECL_STRERROR_R=1;
14375 HAVE_DECL_STRSIGNAL=1;
14382 REPLACE_STRCASESTR=0;
14383 REPLACE_STRCHRNUL=0;
14384 REPLACE_STRERROR=0;
14385 REPLACE_STRERROR_R=0;
14389 REPLACE_STRSIGNAL=0;
14390 REPLACE_STRTOK_R=0;
14391 UNDEFINE_STRTOK_R=0;
14403 # Check for mmap(). Don't use AC_FUNC_MMAP, because it checks too much: it
14404 # fails on HP-UX 11, because MAP_FIXED mappings do not work. But this is
14405 # irrelevant for anonymous mappings.
14406 ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap"
14407 if test "x$ac_cv_func_mmap" = xyes; then :
14414 # Try to allow MAP_ANONYMOUS.
14415 gl_have_mmap_anonymous=no
14416 if test $gl_have_mmap = yes; then
14417 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for MAP_ANONYMOUS" >&5
14418 printf %s "checking for MAP_ANONYMOUS... " >&6; }
14419 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14420 /* end confdefs.h. */
14422 #include <sys/mman.h>
14423 #ifdef MAP_ANONYMOUS
14424 I cannot identify this map
14428 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14429 $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
14430 gl_have_mmap_anonymous=yes
14434 if test $gl_have_mmap_anonymous != yes; then
14435 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14436 /* end confdefs.h. */
14438 #include <sys/mman.h>
14440 I cannot identify this map
14444 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14445 $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
14447 printf "%s\n" "#define MAP_ANONYMOUS MAP_ANON" >>confdefs.h
14449 gl_have_mmap_anonymous=yes
14454 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_have_mmap_anonymous" >&5
14455 printf "%s\n" "$gl_have_mmap_anonymous" >&6; }
14456 if test $gl_have_mmap_anonymous = yes; then
14458 printf "%s\n" "#define HAVE_MAP_ANONYMOUS 1" >>confdefs.h
14468 if test $HAVE_MEMCHR = 1; then
14469 # Detect platform-specific bugs in some versions of glibc:
14470 # memchr should not dereference anything with length 0
14471 # http://bugzilla.redhat.com/499689
14472 # memchr should not dereference overestimated length after a match
14473 # http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=521737
14474 # http://sourceware.org/bugzilla/show_bug.cgi?id=10162
14475 # Assume that memchr works on platforms that lack mprotect.
14476 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether memchr works" >&5
14477 printf %s "checking whether memchr works... " >&6; }
14478 if ${gl_cv_func_memchr_works+:} false; then :
14479 printf %s "(cached) " >&6
14481 if test "$cross_compiling" = yes; then :
14482 gl_cv_func_memchr_works="guessing no"
14484 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14485 /* end confdefs.h. */
14487 #include <string.h>
14488 #if HAVE_SYS_MMAN_H
14489 # include <fcntl.h>
14490 # include <unistd.h>
14491 # include <sys/types.h>
14492 # include <sys/mman.h>
14494 # define MAP_FILE 0
14503 char *fence = NULL;
14504 #if HAVE_SYS_MMAN_H && HAVE_MPROTECT
14505 # if HAVE_MAP_ANONYMOUS
14506 const int flags = MAP_ANONYMOUS | MAP_PRIVATE;
14508 # else /* !HAVE_MAP_ANONYMOUS */
14509 const int flags = MAP_FILE | MAP_PRIVATE;
14510 int fd = open ("/dev/zero", O_RDONLY, 0666);
14514 int pagesize = getpagesize ();
14516 (char *) mmap (NULL, 2 * pagesize, PROT_READ | PROT_WRITE,
14518 if (two_pages != (char *)(-1)
14519 && mprotect (two_pages + pagesize, pagesize, PROT_NONE) == 0)
14520 fence = two_pages + pagesize;
14525 if (memchr (fence, 0, 0))
14527 strcpy (fence - 9, "12345678");
14528 if (memchr (fence - 9, 0, 79) != fence - 1)
14530 if (memchr (fence - 1, 0, 3) != fence - 1)
14539 if ac_fn_c_try_run "$LINENO"; then :
14540 gl_cv_func_memchr_works=yes
14542 gl_cv_func_memchr_works=no
14544 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14545 conftest.$ac_objext conftest.beam conftest.$ac_ext
14549 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memchr_works" >&5
14550 printf "%s\n" "$gl_cv_func_memchr_works" >&6; }
14551 if test "$gl_cv_func_memchr_works" != yes; then
14560 GNULIB_NANOSLEEP=0;
14564 HAVE_DECL_LOCALTIME_R=1;
14568 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
14569 REPLACE_MKTIME=GNULIB_PORTCHECK;
14570 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
14571 REPLACE_TIMEGM=GNULIB_PORTCHECK;
14573 ac_fn_c_check_decl "$LINENO" "alarm" "ac_cv_have_decl_alarm" "$ac_includes_default"
14574 if test "x$ac_cv_have_decl_alarm" = xyes; then :
14580 cat >>confdefs.h <<_ACEOF
14581 #define HAVE_DECL_ALARM $ac_have_decl
14588 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for promoted mode_t type" >&5
14589 printf %s "checking for promoted mode_t type... " >&6; }
14590 if ${gl_cv_promoted_mode_t+:} false; then :
14591 printf %s "(cached) " >&6
14594 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14595 /* end confdefs.h. */
14596 #include <sys/types.h>
14600 typedef int array[2 * (sizeof (mode_t) < sizeof (int)) - 1];
14605 if ac_fn_c_try_compile "$LINENO"; then :
14606 gl_cv_promoted_mode_t='int'
14608 gl_cv_promoted_mode_t='mode_t'
14610 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14613 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_promoted_mode_t" >&5
14614 printf "%s\n" "$gl_cv_promoted_mode_t" >&6; }
14616 cat >>confdefs.h <<_ACEOF
14617 #define PROMOTED_MODE_T $gl_cv_promoted_mode_t
14624 GNULIB_PTHREAD_SIGMASK=0;
14626 GNULIB_SIGNAL_H_SIGPIPE=0;
14627 GNULIB_SIGPROCMASK=0;
14628 GNULIB_SIGACTION=0;
14629 HAVE_POSIX_SIGNALBLOCKING=1;
14630 HAVE_PTHREAD_SIGMASK=1;
14635 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
14637 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
14639 HAVE_SIGHANDLER_T=1;
14640 REPLACE_PTHREAD_SIGMASK=0;
14644 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
14645 #include <signal.h>
14646 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
14647 #include <sys/types.h>
14650 if test "x$ac_cv_type_sigset_t" = xyes; then :
14652 cat >>confdefs.h <<_ACEOF
14653 #define HAVE_SIGSET_T 1
14656 gl_cv_type_sigset_t=yes
14658 gl_cv_type_sigset_t=no
14661 if test $gl_cv_type_sigset_t != yes; then
14673 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
14674 printf %s "checking for uid_t in sys/types.h... " >&6; }
14675 if ${ac_cv_type_uid_t+:} false; then :
14676 printf %s "(cached) " >&6
14678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14679 /* end confdefs.h. */
14680 #include <sys/types.h>
14683 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14684 $EGREP "uid_t" >/dev/null 2>&1; then :
14685 ac_cv_type_uid_t=yes
14687 ac_cv_type_uid_t=no
14692 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
14693 printf "%s\n" "$ac_cv_type_uid_t" >&6; }
14694 if test $ac_cv_type_uid_t = no; then
14696 printf "%s\n" "#define uid_t int" >>confdefs.h
14699 printf "%s\n" "#define gid_t int" >>confdefs.h
14706 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
14707 printf %s "checking for stdbool.h that conforms to C99... " >&6; }
14708 if ${ac_cv_header_stdbool_h+:} false; then :
14709 printf %s "(cached) " >&6
14711 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14712 /* end confdefs.h. */
14714 #include <stdbool.h>
14716 "error: bool is not defined"
14719 "error: false is not defined"
14722 "error: false is not 0"
14725 "error: true is not defined"
14728 "error: true is not 1"
14730 #ifndef __bool_true_false_are_defined
14731 "error: __bool_true_false_are_defined is not defined"
14734 struct s { _Bool s: 1; _Bool t; } s;
14736 char a[true == 1 ? 1 : -1];
14737 char b[false == 0 ? 1 : -1];
14738 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
14739 char d[(bool) 0.5 == true ? 1 : -1];
14740 /* See body of main program for 'e'. */
14741 char f[(_Bool) 0.0 == false ? 1 : -1];
14743 char h[sizeof (_Bool)];
14744 char i[sizeof s.t];
14745 enum { j = false, k = true, l = false * true, m = true * 256 };
14746 /* The following fails for
14747 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
14749 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
14750 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
14751 /* Catch a bug in an HP-UX C compiler. See
14752 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
14753 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
14765 /* Refer to every declared value, to avoid compiler optimizations. */
14766 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
14767 + !m + !n + !o + !p + !q + !pq);
14773 if ac_fn_c_try_compile "$LINENO"; then :
14774 ac_cv_header_stdbool_h=yes
14776 ac_cv_header_stdbool_h=no
14778 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14780 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
14781 printf "%s\n" "$ac_cv_header_stdbool_h" >&6; }
14782 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
14783 if test "x$ac_cv_type__Bool" = xyes; then :
14785 cat >>confdefs.h <<_ACEOF
14786 #define HAVE__BOOL 1
14797 HAVE_DECL_STRNCASECMP=1;
14800 REPLACE_STRERROR_0=0
14801 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether strerror(0) succeeds" >&5
14802 printf %s "checking whether strerror(0) succeeds... " >&6; }
14803 if ${gl_cv_func_strerror_0_works+:} false; then :
14804 printf %s "(cached) " >&6
14806 if test "$cross_compiling" = yes; then :
14808 # Guess yes on glibc systems.
14809 *-gnu*) gl_cv_func_strerror_0_works="guessing yes" ;;
14810 # If we don't know, assume the worst.
14811 *) gl_cv_func_strerror_0_works="guessing no" ;;
14815 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14816 /* end confdefs.h. */
14817 #include <string.h>
14826 str = strerror (0);
14827 if (!*str) result |= 1;
14828 if (errno) result |= 2;
14829 if (strstr (str, "nknown") || strstr (str, "ndefined"))
14836 if ac_fn_c_try_run "$LINENO"; then :
14837 gl_cv_func_strerror_0_works=yes
14839 gl_cv_func_strerror_0_works=no
14841 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14842 conftest.$ac_objext conftest.beam conftest.$ac_ext
14847 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strerror_0_works" >&5
14848 printf "%s\n" "$gl_cv_func_strerror_0_works" >&6; }
14849 case "$gl_cv_func_strerror_0_works" in
14852 REPLACE_STRERROR_0=1
14854 printf "%s\n" "#define REPLACE_STRERROR_0 1" >>confdefs.h
14859 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
14860 printf %s "checking whether struct tm is in sys/time.h or time.h... " >&6; }
14861 if ${ac_cv_struct_tm+:} false; then :
14862 printf %s "(cached) " >&6
14864 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14865 /* end confdefs.h. */
14866 #include <sys/types.h>
14873 int *p = &tm.tm_sec;
14879 if ac_fn_c_try_compile "$LINENO"; then :
14880 ac_cv_struct_tm=time.h
14882 ac_cv_struct_tm=sys/time.h
14884 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14886 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
14887 printf "%s\n" "$ac_cv_struct_tm" >&6; }
14888 if test $ac_cv_struct_tm = sys/time.h; then
14890 printf "%s\n" "#define TM_IN_SYS_TIME 1" >>confdefs.h
14894 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
14895 #include <$ac_cv_struct_tm>
14898 if test "x$ac_cv_member_struct_tm_tm_zone" = xyes; then :
14900 cat >>confdefs.h <<_ACEOF
14901 #define HAVE_STRUCT_TM_TM_ZONE 1
14907 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
14909 printf "%s\n" "#define HAVE_TM_ZONE 1" >>confdefs.h
14912 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
14914 if test "x$ac_cv_have_decl_tzname" = xyes; then :
14920 cat >>confdefs.h <<_ACEOF
14921 #define HAVE_DECL_TZNAME $ac_have_decl
14924 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
14925 printf %s "checking for tzname... " >&6; }
14926 if ${ac_cv_var_tzname+:} false; then :
14927 printf %s "(cached) " >&6
14929 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14930 /* end confdefs.h. */
14932 #if !HAVE_DECL_TZNAME
14933 extern char *tzname[];
14939 return tzname[0][0];
14944 if ac_fn_c_try_link "$LINENO"; then :
14945 ac_cv_var_tzname=yes
14947 ac_cv_var_tzname=no
14949 rm -f core conftest.err conftest.$ac_objext \
14950 conftest$ac_exeext conftest.$ac_ext
14952 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
14953 printf "%s\n" "$ac_cv_var_tzname" >&6; }
14954 if test $ac_cv_var_tzname = yes; then
14956 printf "%s\n" "#define HAVE_TZNAME 1" >>confdefs.h
14962 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
14964 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = xyes; then :
14966 printf "%s\n" "#define HAVE_TM_GMTOFF 1" >>confdefs.h
14984 if test $gl_cv_have_include_next = yes; then
14985 gl_cv_next_string_h='<'string.h'>'
14987 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <string.h>" >&5
14988 printf %s "checking absolute name of <string.h>... " >&6; }
14989 if ${gl_cv_next_string_h+:} false; then :
14990 printf %s "(cached) " >&6
14993 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14994 /* end confdefs.h. */
14995 #include <string.h>
14999 aix*) gl_absname_cpp="$ac_cpp -C" ;;
15000 *) gl_absname_cpp="$ac_cpp" ;;
15005 gl_dirsep_regex='[/\\]'
15008 gl_dirsep_regex='\/'
15011 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
15013 gl_header_literal_regex=`echo 'string.h' \
15014 | sed -e "$gl_make_literal_regex_sed"`
15015 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
15016 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
15021 gl_cv_next_string_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
15022 sed -n "$gl_absolute_header_sed"`'"'
15026 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_string_h" >&5
15027 printf "%s\n" "$gl_cv_next_string_h" >&6; }
15029 NEXT_STRING_H=$gl_cv_next_string_h
15031 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
15032 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
15033 gl_next_as_first_directive='<'string.h'>'
15035 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
15036 gl_next_as_first_directive=$gl_cv_next_string_h
15038 NEXT_AS_FIRST_DIRECTIVE_STRING_H=$gl_next_as_first_directive
15045 for gl_func in ffsl ffsll memmem mempcpy memrchr rawmemchr stpcpy stpncpy strchrnul strdup strncat strndup strnlen strpbrk strsep strcasestr strtok_r strerror_r strsignal strverscmp; do
15046 as_gl_Symbol=`printf "%s\n" "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
15047 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
15048 printf %s "checking whether $gl_func is declared without a macro... " >&6; }
15049 if eval \${$as_gl_Symbol+:} false; then :
15050 printf %s "(cached) " >&6
15052 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15053 /* end confdefs.h. */
15054 #include <string.h>
15065 if ac_fn_c_try_compile "$LINENO"; then :
15066 eval "$as_gl_Symbol=yes"
15068 eval "$as_gl_Symbol=no"
15070 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15072 eval ac_res=\$$as_gl_Symbol
15073 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15074 printf "%s\n" "$ac_res" >&6; }
15075 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
15076 cat >>confdefs.h <<_ACEOF
15077 #define `printf "%s\n" "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
15080 eval ac_cv_have_decl_$gl_func=yes
15099 if test $gl_cv_have_include_next = yes; then
15100 gl_cv_next_strings_h='<'strings.h'>'
15102 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <strings.h>" >&5
15103 printf %s "checking absolute name of <strings.h>... " >&6; }
15104 if ${gl_cv_next_strings_h+:} false; then :
15105 printf %s "(cached) " >&6
15108 if test $ac_cv_header_strings_h = yes; then
15111 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15112 /* end confdefs.h. */
15113 #include <strings.h>
15117 aix*) gl_absname_cpp="$ac_cpp -C" ;;
15118 *) gl_absname_cpp="$ac_cpp" ;;
15123 gl_dirsep_regex='[/\\]'
15126 gl_dirsep_regex='\/'
15129 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
15131 gl_header_literal_regex=`echo 'strings.h' \
15132 | sed -e "$gl_make_literal_regex_sed"`
15133 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
15134 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
15139 gl_cv_next_strings_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
15140 sed -n "$gl_absolute_header_sed"`'"'
15142 gl_cv_next_strings_h='<'strings.h'>'
15147 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_strings_h" >&5
15148 printf "%s\n" "$gl_cv_next_strings_h" >&6; }
15150 NEXT_STRINGS_H=$gl_cv_next_strings_h
15152 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
15153 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
15154 gl_next_as_first_directive='<'strings.h'>'
15156 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
15157 gl_next_as_first_directive=$gl_cv_next_strings_h
15159 NEXT_AS_FIRST_DIRECTIVE_STRINGS_H=$gl_next_as_first_directive
15164 if test $ac_cv_header_strings_h = yes; then
15172 for gl_func in ffs strcasecmp strncasecmp; do
15173 as_gl_Symbol=`printf "%s\n" "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
15174 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
15175 printf %s "checking whether $gl_func is declared without a macro... " >&6; }
15176 if eval \${$as_gl_Symbol+:} false; then :
15177 printf %s "(cached) " >&6
15179 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15180 /* end confdefs.h. */
15182 /* Minix 3.1.8 has a bug: <sys/types.h> must be included before
15184 #include <sys/types.h>
15185 #include <strings.h>
15196 if ac_fn_c_try_compile "$LINENO"; then :
15197 eval "$as_gl_Symbol=yes"
15199 eval "$as_gl_Symbol=no"
15201 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15203 eval ac_res=\$$as_gl_Symbol
15204 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15205 printf "%s\n" "$ac_res" >&6; }
15206 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
15207 cat >>confdefs.h <<_ACEOF
15208 #define `printf "%s\n" "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
15211 eval ac_cv_have_decl_$gl_func=yes
15216 ac_fn_c_check_decl "$LINENO" "strndup" "ac_cv_have_decl_strndup" "$ac_includes_default"
15217 if test "x$ac_cv_have_decl_strndup" = xyes; then :
15223 cat >>confdefs.h <<_ACEOF
15224 #define HAVE_DECL_STRNDUP $ac_have_decl
15229 ac_fn_c_check_decl "$LINENO" "strnlen" "ac_cv_have_decl_strnlen" "$ac_includes_default"
15230 if test "x$ac_cv_have_decl_strnlen" = xyes; then :
15236 cat >>confdefs.h <<_ACEOF
15237 #define HAVE_DECL_STRNLEN $ac_have_decl
15244 ac_fn_c_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default"
15245 if test "x$ac_cv_have_decl_strtoumax" = xyes; then :
15251 cat >>confdefs.h <<_ACEOF
15252 #define HAVE_DECL_STRTOUMAX $ac_have_decl
15273 if test $gl_cv_have_include_next = yes; then
15274 gl_cv_next_sys_types_h='<'sys/types.h'>'
15276 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/types.h>" >&5
15277 printf %s "checking absolute name of <sys/types.h>... " >&6; }
15278 if ${gl_cv_next_sys_types_h+:} false; then :
15279 printf %s "(cached) " >&6
15282 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15283 /* end confdefs.h. */
15284 #include <sys/types.h>
15288 aix*) gl_absname_cpp="$ac_cpp -C" ;;
15289 *) gl_absname_cpp="$ac_cpp" ;;
15294 gl_dirsep_regex='[/\\]'
15297 gl_dirsep_regex='\/'
15300 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
15302 gl_header_literal_regex=`echo 'sys/types.h' \
15303 | sed -e "$gl_make_literal_regex_sed"`
15304 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
15305 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
15310 gl_cv_next_sys_types_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
15311 sed -n "$gl_absolute_header_sed"`'"'
15315 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_types_h" >&5
15316 printf "%s\n" "$gl_cv_next_sys_types_h" >&6; }
15318 NEXT_SYS_TYPES_H=$gl_cv_next_sys_types_h
15320 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
15321 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
15322 gl_next_as_first_directive='<'sys/types.h'>'
15324 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
15325 gl_next_as_first_directive=$gl_cv_next_sys_types_h
15327 NEXT_AS_FIRST_DIRECTIVE_SYS_TYPES_H=$gl_next_as_first_directive
15346 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
15347 printf %s "checking for struct timespec in <time.h>... " >&6; }
15348 if ${gl_cv_sys_struct_timespec_in_time_h+:} false; then :
15349 printf %s "(cached) " >&6
15351 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15352 /* end confdefs.h. */
15358 static struct timespec x; x.tv_sec = x.tv_nsec;
15363 if ac_fn_c_try_compile "$LINENO"; then :
15364 gl_cv_sys_struct_timespec_in_time_h=yes
15366 gl_cv_sys_struct_timespec_in_time_h=no
15368 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15370 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
15371 printf "%s\n" "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
15373 TIME_H_DEFINES_STRUCT_TIMESPEC=0
15374 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
15375 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
15376 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
15377 TIME_H_DEFINES_STRUCT_TIMESPEC=1
15379 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
15380 printf %s "checking for struct timespec in <sys/time.h>... " >&6; }
15381 if ${gl_cv_sys_struct_timespec_in_sys_time_h+:} false; then :
15382 printf %s "(cached) " >&6
15384 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15385 /* end confdefs.h. */
15386 #include <sys/time.h>
15391 static struct timespec x; x.tv_sec = x.tv_nsec;
15396 if ac_fn_c_try_compile "$LINENO"; then :
15397 gl_cv_sys_struct_timespec_in_sys_time_h=yes
15399 gl_cv_sys_struct_timespec_in_sys_time_h=no
15401 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15403 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
15404 printf "%s\n" "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
15405 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
15406 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
15408 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
15409 printf %s "checking for struct timespec in <pthread.h>... " >&6; }
15410 if ${gl_cv_sys_struct_timespec_in_pthread_h+:} false; then :
15411 printf %s "(cached) " >&6
15413 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15414 /* end confdefs.h. */
15415 #include <pthread.h>
15420 static struct timespec x; x.tv_sec = x.tv_nsec;
15425 if ac_fn_c_try_compile "$LINENO"; then :
15426 gl_cv_sys_struct_timespec_in_pthread_h=yes
15428 gl_cv_sys_struct_timespec_in_pthread_h=no
15430 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15432 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
15433 printf "%s\n" "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
15434 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
15435 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
15454 if test $gl_cv_have_include_next = yes; then
15455 gl_cv_next_time_h='<'time.h'>'
15457 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
15458 printf %s "checking absolute name of <time.h>... " >&6; }
15459 if ${gl_cv_next_time_h+:} false; then :
15460 printf %s "(cached) " >&6
15463 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15464 /* end confdefs.h. */
15469 aix*) gl_absname_cpp="$ac_cpp -C" ;;
15470 *) gl_absname_cpp="$ac_cpp" ;;
15475 gl_dirsep_regex='[/\\]'
15478 gl_dirsep_regex='\/'
15481 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
15483 gl_header_literal_regex=`echo 'time.h' \
15484 | sed -e "$gl_make_literal_regex_sed"`
15485 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
15486 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
15491 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
15492 sed -n "$gl_absolute_header_sed"`'"'
15496 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
15497 printf "%s\n" "$gl_cv_next_time_h" >&6; }
15499 NEXT_TIME_H=$gl_cv_next_time_h
15501 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
15502 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
15503 gl_next_as_first_directive='<'time.h'>'
15505 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
15506 gl_next_as_first_directive=$gl_cv_next_time_h
15508 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
15523 gl_libunistring_sed_extract_major='/^[0-9]/{s/^\([0-9]*\).*/\1/p;q;}
15528 gl_libunistring_sed_extract_minor='/^[0-9][0-9]*[.][0-9]/{s/^[0-9]*[.]\([0-9]*\).*/\1/p;q;}
15533 gl_libunistring_sed_extract_subminor='/^[0-9][0-9]*[.][0-9][0-9]*[.][0-9]/{s/^[0-9]*[.][0-9]*[.]\([0-9]*\).*/\1/p;q;}
15540 if test "$HAVE_LIBUNISTRING" = yes; then
15541 LIBUNISTRING_VERSION_MAJOR=`echo "$LIBUNISTRING_VERSION" | sed -n -e "$gl_libunistring_sed_extract_major"`
15542 LIBUNISTRING_VERSION_MINOR=`echo "$LIBUNISTRING_VERSION" | sed -n -e "$gl_libunistring_sed_extract_minor"`
15543 LIBUNISTRING_VERSION_SUBMINOR=`echo "$LIBUNISTRING_VERSION" | sed -n -e "$gl_libunistring_sed_extract_subminor"`
15546 ac_fn_c_check_decl "$LINENO" "clearerr_unlocked" "ac_cv_have_decl_clearerr_unlocked" "$ac_includes_default"
15547 if test "x$ac_cv_have_decl_clearerr_unlocked" = xyes; then :
15553 cat >>confdefs.h <<_ACEOF
15554 #define HAVE_DECL_CLEARERR_UNLOCKED $ac_have_decl
15557 ac_fn_c_check_decl "$LINENO" "feof_unlocked" "ac_cv_have_decl_feof_unlocked" "$ac_includes_default"
15558 if test "x$ac_cv_have_decl_feof_unlocked" = xyes; then :
15564 cat >>confdefs.h <<_ACEOF
15565 #define HAVE_DECL_FEOF_UNLOCKED $ac_have_decl
15568 ac_fn_c_check_decl "$LINENO" "ferror_unlocked" "ac_cv_have_decl_ferror_unlocked" "$ac_includes_default"
15569 if test "x$ac_cv_have_decl_ferror_unlocked" = xyes; then :
15575 cat >>confdefs.h <<_ACEOF
15576 #define HAVE_DECL_FERROR_UNLOCKED $ac_have_decl
15579 ac_fn_c_check_decl "$LINENO" "fflush_unlocked" "ac_cv_have_decl_fflush_unlocked" "$ac_includes_default"
15580 if test "x$ac_cv_have_decl_fflush_unlocked" = xyes; then :
15586 cat >>confdefs.h <<_ACEOF
15587 #define HAVE_DECL_FFLUSH_UNLOCKED $ac_have_decl
15590 ac_fn_c_check_decl "$LINENO" "fgets_unlocked" "ac_cv_have_decl_fgets_unlocked" "$ac_includes_default"
15591 if test "x$ac_cv_have_decl_fgets_unlocked" = xyes; then :
15597 cat >>confdefs.h <<_ACEOF
15598 #define HAVE_DECL_FGETS_UNLOCKED $ac_have_decl
15601 ac_fn_c_check_decl "$LINENO" "fputc_unlocked" "ac_cv_have_decl_fputc_unlocked" "$ac_includes_default"
15602 if test "x$ac_cv_have_decl_fputc_unlocked" = xyes; then :
15608 cat >>confdefs.h <<_ACEOF
15609 #define HAVE_DECL_FPUTC_UNLOCKED $ac_have_decl
15612 ac_fn_c_check_decl "$LINENO" "fputs_unlocked" "ac_cv_have_decl_fputs_unlocked" "$ac_includes_default"
15613 if test "x$ac_cv_have_decl_fputs_unlocked" = xyes; then :
15619 cat >>confdefs.h <<_ACEOF
15620 #define HAVE_DECL_FPUTS_UNLOCKED $ac_have_decl
15623 ac_fn_c_check_decl "$LINENO" "fread_unlocked" "ac_cv_have_decl_fread_unlocked" "$ac_includes_default"
15624 if test "x$ac_cv_have_decl_fread_unlocked" = xyes; then :
15630 cat >>confdefs.h <<_ACEOF
15631 #define HAVE_DECL_FREAD_UNLOCKED $ac_have_decl
15634 ac_fn_c_check_decl "$LINENO" "fwrite_unlocked" "ac_cv_have_decl_fwrite_unlocked" "$ac_includes_default"
15635 if test "x$ac_cv_have_decl_fwrite_unlocked" = xyes; then :
15641 cat >>confdefs.h <<_ACEOF
15642 #define HAVE_DECL_FWRITE_UNLOCKED $ac_have_decl
15645 ac_fn_c_check_decl "$LINENO" "getchar_unlocked" "ac_cv_have_decl_getchar_unlocked" "$ac_includes_default"
15646 if test "x$ac_cv_have_decl_getchar_unlocked" = xyes; then :
15652 cat >>confdefs.h <<_ACEOF
15653 #define HAVE_DECL_GETCHAR_UNLOCKED $ac_have_decl
15656 ac_fn_c_check_decl "$LINENO" "putc_unlocked" "ac_cv_have_decl_putc_unlocked" "$ac_includes_default"
15657 if test "x$ac_cv_have_decl_putc_unlocked" = xyes; then :
15663 cat >>confdefs.h <<_ACEOF
15664 #define HAVE_DECL_PUTC_UNLOCKED $ac_have_decl
15667 ac_fn_c_check_decl "$LINENO" "putchar_unlocked" "ac_cv_have_decl_putchar_unlocked" "$ac_includes_default"
15668 if test "x$ac_cv_have_decl_putchar_unlocked" = xyes; then :
15674 cat >>confdefs.h <<_ACEOF
15675 #define HAVE_DECL_PUTCHAR_UNLOCKED $ac_have_decl
15684 if test $ac_cv_header_features_h = yes; then
15692 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inttypes.h" >&5
15693 printf %s "checking for inttypes.h... " >&6; }
15694 if ${gl_cv_header_inttypes_h+:} false; then :
15695 printf %s "(cached) " >&6
15697 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15698 /* end confdefs.h. */
15700 #include <sys/types.h>
15701 #include <inttypes.h>
15706 uintmax_t i = (uintmax_t) -1; return !i;
15711 if ac_fn_c_try_compile "$LINENO"; then :
15712 gl_cv_header_inttypes_h=yes
15714 gl_cv_header_inttypes_h=no
15716 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15718 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_inttypes_h" >&5
15719 printf "%s\n" "$gl_cv_header_inttypes_h" >&6; }
15720 if test $gl_cv_header_inttypes_h = yes; then
15722 cat >>confdefs.h <<_ACEOF
15723 #define HAVE_INTTYPES_H_WITH_UINTMAX 1
15729 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for stdint.h" >&5
15730 printf %s "checking for stdint.h... " >&6; }
15731 if ${gl_cv_header_stdint_h+:} false; then :
15732 printf %s "(cached) " >&6
15734 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15735 /* end confdefs.h. */
15736 #include <sys/types.h>
15737 #include <stdint.h>
15741 uintmax_t i = (uintmax_t) -1; return !i;
15746 if ac_fn_c_try_compile "$LINENO"; then :
15747 gl_cv_header_stdint_h=yes
15749 gl_cv_header_stdint_h=no
15751 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15753 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_stdint_h" >&5
15754 printf "%s\n" "$gl_cv_header_stdint_h" >&6; }
15755 if test $gl_cv_header_stdint_h = yes; then
15757 cat >>confdefs.h <<_ACEOF
15758 #define HAVE_STDINT_H_WITH_UINTMAX 1
15766 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for intmax_t" >&5
15767 printf %s "checking for intmax_t... " >&6; }
15768 if ${gt_cv_c_intmax_t+:} false; then :
15769 printf %s "(cached) " >&6
15771 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15772 /* end confdefs.h. */
15774 #include <stddef.h>
15775 #include <stdlib.h>
15776 #if HAVE_STDINT_H_WITH_UINTMAX
15777 #include <stdint.h>
15779 #if HAVE_INTTYPES_H_WITH_UINTMAX
15780 #include <inttypes.h>
15786 intmax_t x = -1; return !x;
15791 if ac_fn_c_try_compile "$LINENO"; then :
15792 gt_cv_c_intmax_t=yes
15794 gt_cv_c_intmax_t=no
15796 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15798 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_intmax_t" >&5
15799 printf "%s\n" "$gt_cv_c_intmax_t" >&6; }
15800 if test $gt_cv_c_intmax_t = yes; then
15802 printf "%s\n" "#define HAVE_INTMAX_T 1" >>confdefs.h
15806 test $ac_cv_type_long_long_int = yes \
15807 && ac_type='long long' \
15810 cat >>confdefs.h <<_ACEOF
15811 #define intmax_t $ac_type
15817 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'double'" >&5
15818 printf %s "checking where to find the exponent in a 'double'... " >&6; }
15819 if ${gl_cv_cc_double_expbit0+:} false; then :
15820 printf %s "(cached) " >&6
15823 if test "$cross_compiling" = yes; then :
15825 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15826 /* end confdefs.h. */
15828 #if defined arm || defined __arm || defined __arm__
15833 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15834 $EGREP "mixed_endianness" >/dev/null 2>&1; then :
15835 gl_cv_cc_double_expbit0="unknown"
15839 if ${ac_cv_c_bigendian+:} false; then :
15840 printf %s "(cached) " >&6
15842 ac_cv_c_bigendian=unknown
15843 # See if we're dealing with a universal compiler.
15844 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15845 /* end confdefs.h. */
15846 #ifndef __APPLE_CC__
15847 not a universal capable compiler
15852 if ac_fn_c_try_compile "$LINENO"; then :
15854 # Check for potential -arch flags. It is not universal unless
15855 # there are at least two -arch flags with different values.
15858 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
15859 if test -n "$ac_prev"; then
15861 i?86 | x86_64 | ppc | ppc64)
15862 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
15865 ac_cv_c_bigendian=universal
15871 elif test "x$ac_word" = "x-arch"; then
15876 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15877 if test $ac_cv_c_bigendian = unknown; then
15878 # See if sys/param.h defines the BYTE_ORDER macro.
15879 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15880 /* end confdefs.h. */
15881 #include <sys/types.h>
15882 #include <sys/param.h>
15887 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
15888 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
15890 bogus endian macros
15897 if ac_fn_c_try_compile "$LINENO"; then :
15898 # It does; now see whether it defined to BIG_ENDIAN or not.
15899 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15900 /* end confdefs.h. */
15901 #include <sys/types.h>
15902 #include <sys/param.h>
15907 #if BYTE_ORDER != BIG_ENDIAN
15915 if ac_fn_c_try_compile "$LINENO"; then :
15916 ac_cv_c_bigendian=yes
15918 ac_cv_c_bigendian=no
15920 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15922 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15924 if test $ac_cv_c_bigendian = unknown; then
15925 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
15926 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15927 /* end confdefs.h. */
15928 #include <limits.h>
15933 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
15934 bogus endian macros
15941 if ac_fn_c_try_compile "$LINENO"; then :
15942 # It does; now see whether it defined to _BIG_ENDIAN or not.
15943 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15944 /* end confdefs.h. */
15945 #include <limits.h>
15950 #ifndef _BIG_ENDIAN
15958 if ac_fn_c_try_compile "$LINENO"; then :
15959 ac_cv_c_bigendian=yes
15961 ac_cv_c_bigendian=no
15963 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15965 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15967 if test $ac_cv_c_bigendian = unknown; then
15968 # Compile a test program.
15969 if test "$cross_compiling" = yes; then :
15970 # Try to guess by grepping values from an object file.
15971 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15972 /* end confdefs.h. */
15973 short int ascii_mm[] =
15974 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
15975 short int ascii_ii[] =
15976 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
15977 int use_ascii (int i) {
15978 return ascii_mm[i] + ascii_ii[i];
15980 short int ebcdic_ii[] =
15981 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
15982 short int ebcdic_mm[] =
15983 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
15984 int use_ebcdic (int i) {
15985 return ebcdic_mm[i] + ebcdic_ii[i];
15992 return use_ascii (foo) == use_ebcdic (foo);
15997 if ac_fn_c_try_compile "$LINENO"; then :
15998 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
15999 ac_cv_c_bigendian=yes
16001 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
16002 if test "$ac_cv_c_bigendian" = unknown; then
16003 ac_cv_c_bigendian=no
16005 # finding both strings is unlikely to happen, but who knows?
16006 ac_cv_c_bigendian=unknown
16010 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16012 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16013 /* end confdefs.h. */
16014 $ac_includes_default
16019 /* Are we little or big endian? From Harbison&Steele. */
16023 char c[sizeof (long int)];
16026 return u.c[sizeof (long int) - 1] == 1;
16032 if ac_fn_c_try_run "$LINENO"; then :
16033 ac_cv_c_bigendian=no
16035 ac_cv_c_bigendian=yes
16037 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16038 conftest.$ac_objext conftest.beam conftest.$ac_ext
16044 case $ac_cv_c_bigendian in #(
16046 gl_cv_cc_double_expbit0="word 0 bit 20";; #(
16048 gl_cv_cc_double_expbit0="word 1 bit 20" ;; #(
16051 printf "%s\n" "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
16055 gl_cv_cc_double_expbit0="unknown" ;;
16064 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16065 /* end confdefs.h. */
16068 #include <stddef.h>
16070 #include <string.h>
16072 ((sizeof (double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
16073 typedef union { double value; unsigned int word[NWORDS]; } memory_double;
16074 static unsigned int ored_words[NWORDS];
16075 static unsigned int anded_words[NWORDS];
16076 static void add_to_ored_words (double x)
16080 /* Clear it first, in case sizeof (double) < sizeof (memory_double). */
16081 memset (&m, 0, sizeof (memory_double));
16083 for (i = 0; i < NWORDS; i++)
16085 ored_words[i] |= m.word[i];
16086 anded_words[i] &= m.word[i];
16092 FILE *fp = fopen ("conftest.out", "w");
16095 for (j = 0; j < NWORDS; j++)
16096 anded_words[j] = ~ (unsigned int) 0;
16097 add_to_ored_words (0.25);
16098 add_to_ored_words (0.5);
16099 add_to_ored_words (1.0);
16100 add_to_ored_words (2.0);
16101 add_to_ored_words (4.0);
16102 /* Remove bits that are common (e.g. if representation of the first mantissa
16103 bit is explicit). */
16104 for (j = 0; j < NWORDS; j++)
16105 ored_words[j] &= ~anded_words[j];
16106 /* Now find the nonzero word. */
16107 for (j = 0; j < NWORDS; j++)
16108 if (ored_words[j] != 0)
16113 for (i = j + 1; i < NWORDS; i++)
16114 if (ored_words[i] != 0)
16116 fprintf (fp, "unknown");
16117 return (fclose (fp) != 0);
16120 if ((ored_words[j] >> i) & 1)
16122 fprintf (fp, "word %d bit %d", (int) j, (int) i);
16123 return (fclose (fp) != 0);
16126 fprintf (fp, "unknown");
16127 return (fclose (fp) != 0);
16131 if ac_fn_c_try_run "$LINENO"; then :
16132 gl_cv_cc_double_expbit0=`cat conftest.out`
16134 gl_cv_cc_double_expbit0="unknown"
16136 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16137 conftest.$ac_objext conftest.beam conftest.$ac_ext
16143 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_double_expbit0" >&5
16144 printf "%s\n" "$gl_cv_cc_double_expbit0" >&6; }
16145 case "$gl_cv_cc_double_expbit0" in
16147 word=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
16148 bit=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word.*bit //'`
16150 cat >>confdefs.h <<_ACEOF
16151 #define DBL_EXPBIT0_WORD $word
16155 cat >>confdefs.h <<_ACEOF
16156 #define DBL_EXPBIT0_BIT $bit
16170 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether snprintf returns a byte count as in C99" >&5
16171 printf %s "checking whether snprintf returns a byte count as in C99... " >&6; }
16172 if ${gl_cv_func_snprintf_retval_c99+:} false; then :
16173 printf %s "(cached) " >&6
16176 if test "$cross_compiling" = yes; then :
16179 # Guess yes on glibc systems.
16180 *-gnu*) gl_cv_func_snprintf_retval_c99="guessing yes";;
16181 # Guess yes on FreeBSD >= 5.
16182 freebsd[1-4]*) gl_cv_func_snprintf_retval_c99="guessing no";;
16183 freebsd* | kfreebsd*) gl_cv_func_snprintf_retval_c99="guessing yes";;
16184 # Guess yes on Mac OS X >= 10.3.
16185 darwin[1-6].*) gl_cv_func_snprintf_retval_c99="guessing no";;
16186 darwin*) gl_cv_func_snprintf_retval_c99="guessing yes";;
16187 # Guess yes on OpenBSD >= 3.9.
16188 openbsd[1-2].* | openbsd3.[0-8] | openbsd3.[0-8].*)
16189 gl_cv_func_snprintf_retval_c99="guessing no";;
16190 openbsd*) gl_cv_func_snprintf_retval_c99="guessing yes";;
16191 # Guess yes on Solaris >= 2.10.
16192 solaris2.[1-9][0-9]*) gl_cv_func_printf_sizes_c99="guessing yes";;
16193 solaris*) gl_cv_func_printf_sizes_c99="guessing no";;
16194 # Guess yes on AIX >= 4.
16195 aix[1-3]*) gl_cv_func_snprintf_retval_c99="guessing no";;
16196 aix*) gl_cv_func_snprintf_retval_c99="guessing yes";;
16197 # Guess yes on NetBSD >= 3.
16198 netbsd[1-2]* | netbsdelf[1-2]* | netbsdaout[1-2]* | netbsdcoff[1-2]*)
16199 gl_cv_func_snprintf_retval_c99="guessing no";;
16200 netbsd*) gl_cv_func_snprintf_retval_c99="guessing yes";;
16201 # Guess yes on BeOS.
16202 beos*) gl_cv_func_snprintf_retval_c99="guessing yes";;
16203 # If we don't know, assume the worst.
16204 *) gl_cv_func_snprintf_retval_c99="guessing no";;
16208 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16209 /* end confdefs.h. */
16212 #include <string.h>
16214 # define my_snprintf snprintf
16216 # include <stdarg.h>
16217 static int my_snprintf (char *buf, int size, const char *format, ...)
16221 va_start (args, format);
16222 ret = vsnprintf (buf, size, format, args);
16227 static char buf[100];
16230 strcpy (buf, "ABCDEF");
16231 if (my_snprintf (buf, 3, "%d %d", 4567, 89) != 7)
16233 if (my_snprintf (buf, 0, "%d %d", 4567, 89) != 7)
16235 if (my_snprintf (NULL, 0, "%d %d", 4567, 89) != 7)
16240 if ac_fn_c_try_run "$LINENO"; then :
16241 gl_cv_func_snprintf_retval_c99=yes
16243 gl_cv_func_snprintf_retval_c99=no
16245 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16246 conftest.$ac_objext conftest.beam conftest.$ac_ext
16251 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_snprintf_retval_c99" >&5
16252 printf "%s\n" "$gl_cv_func_snprintf_retval_c99" >&6; }
16259 for ac_func in snprintf strnlen wcslen wcsnlen mbrtowc wcrtomb
16261 as_ac_var=`printf "%s\n" "ac_cv_func_$ac_func" | $as_tr_sh`
16262 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16263 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
16264 cat >>confdefs.h <<_ACEOF
16265 #define `printf "%s\n" "HAVE_$ac_func" | $as_tr_cpp` 1
16271 ac_fn_c_check_decl "$LINENO" "_snprintf" "ac_cv_have_decl__snprintf" "#include <stdio.h>
16273 if test "x$ac_cv_have_decl__snprintf" = xyes; then :
16279 cat >>confdefs.h <<_ACEOF
16280 #define HAVE_DECL__SNPRINTF $ac_have_decl
16285 case "$gl_cv_func_snprintf_retval_c99" in
16288 printf "%s\n" "#define HAVE_SNPRINTF_RETVAL_C99 1" >>confdefs.h
16304 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
16305 printf %s "checking if environ is properly declared... " >&6; }
16306 if ${gt_cv_var_environ_declaration+:} false; then :
16307 printf %s "(cached) " >&6
16310 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16311 /* end confdefs.h. */
16313 #include <unistd.h>
16315 /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
16316 #include <stdlib.h>
16318 extern struct { int foo; } environ;
16327 if ac_fn_c_try_compile "$LINENO"; then :
16328 gt_cv_var_environ_declaration=no
16330 gt_cv_var_environ_declaration=yes
16332 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16335 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
16336 printf "%s\n" "$gt_cv_var_environ_declaration" >&6; }
16337 if test $gt_cv_var_environ_declaration = yes; then
16339 printf "%s\n" "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
16344 if test $gt_cv_var_environ_declaration != yes; then
16345 HAVE_DECL_ENVIRON=0
16350 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether getcwd (NULL, 0) allocates memory for result" >&5
16351 printf %s "checking whether getcwd (NULL, 0) allocates memory for result... " >&6; }
16352 if ${gl_cv_func_getcwd_null+:} false; then :
16353 printf %s "(cached) " >&6
16355 if test "$cross_compiling" = yes; then :
16357 # Guess yes on glibc systems.
16358 *-gnu*) gl_cv_func_getcwd_null="guessing yes";;
16359 # Guess yes on Cygwin.
16360 cygwin*) gl_cv_func_getcwd_null="guessing yes";;
16361 # If we don't know, assume the worst.
16362 *) gl_cv_func_getcwd_null="guessing no";;
16366 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16367 /* end confdefs.h. */
16370 # include <unistd.h>
16371 # else /* on Windows with MSVC */
16372 # include <direct.h>
16382 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
16383 /* mingw cwd does not start with '/', but getcwd does allocate.
16384 However, mingw fails to honor non-zero size. */
16386 if (chdir ("/") != 0)
16390 char *f = getcwd (NULL, 0);
16405 if ac_fn_c_try_run "$LINENO"; then :
16406 gl_cv_func_getcwd_null=yes
16408 gl_cv_func_getcwd_null=no
16410 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16411 conftest.$ac_objext conftest.beam conftest.$ac_ext
16415 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_null" >&5
16416 printf "%s\n" "$gl_cv_func_getcwd_null" >&6; }
16419 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for getcwd with POSIX signature" >&5
16420 printf %s "checking for getcwd with POSIX signature... " >&6; }
16421 if ${gl_cv_func_getcwd_posix_signature+:} false; then :
16422 printf %s "(cached) " >&6
16424 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16425 /* end confdefs.h. */
16426 #include <unistd.h>
16434 char *getcwd (char *, size_t);
16441 if ac_fn_c_try_compile "$LINENO"; then :
16442 gl_cv_func_getcwd_posix_signature=yes
16444 gl_cv_func_getcwd_posix_signature=no
16446 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16449 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_posix_signature" >&5
16450 printf "%s\n" "$gl_cv_func_getcwd_posix_signature" >&6; }
16454 ac_fn_c_check_decl "$LINENO" "setenv" "ac_cv_have_decl_setenv" "$ac_includes_default"
16455 if test "x$ac_cv_have_decl_setenv" = xyes; then :
16461 cat >>confdefs.h <<_ACEOF
16462 #define HAVE_DECL_SETENV $ac_have_decl
16470 if test $ac_cv_have_decl_setenv = no; then
16478 for ac_header in search.h
16480 ac_fn_c_check_header_mongrel "$LINENO" "search.h" "ac_cv_header_search_h" "$ac_includes_default"
16481 if test "x$ac_cv_header_search_h" = xyes; then :
16482 cat >>confdefs.h <<_ACEOF
16483 #define HAVE_SEARCH_H 1
16490 for ac_func in tsearch
16492 ac_fn_c_check_func "$LINENO" "tsearch" "ac_cv_func_tsearch"
16493 if test "x$ac_cv_func_tsearch" = xyes; then :
16494 cat >>confdefs.h <<_ACEOF
16495 #define HAVE_TSEARCH 1
16505 ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
16506 if test "x$ac_cv_have_decl_snprintf" = xyes; then :
16512 cat >>confdefs.h <<_ACEOF
16513 #define HAVE_DECL_SNPRINTF $ac_have_decl
16516 ac_fn_c_check_decl "$LINENO" "unsetenv" "ac_cv_have_decl_unsetenv" "$ac_includes_default"
16517 if test "x$ac_cv_have_decl_unsetenv" = xyes; then :
16523 cat >>confdefs.h <<_ACEOF
16524 #define HAVE_DECL_UNSETENV $ac_have_decl
16533 GL_COND_LIBTOOL_TRUE=
16534 GL_COND_LIBTOOL_FALSE='#'
16536 GL_COND_LIBTOOL_TRUE='#'
16537 GL_COND_LIBTOOL_FALSE=
16540 gl_cond_libtool=false
16553 gl_source_base='lib'
16556 if test $ac_cv_func_alloca_works = no; then
16560 # Define an additional variable used in the Makefile substitution.
16561 if test $ac_cv_working_alloca_h = yes; then
16562 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
16563 printf %s "checking for alloca as a compiler built-in... " >&6; }
16564 if ${gl_cv_rpl_alloca+:} false; then :
16565 printf %s "(cached) " >&6
16568 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16569 /* end confdefs.h. */
16571 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
16576 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16577 $EGREP "Need own alloca" >/dev/null 2>&1; then :
16578 gl_cv_rpl_alloca=yes
16580 gl_cv_rpl_alloca=no
16586 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
16587 printf "%s\n" "$gl_cv_rpl_alloca" >&6; }
16588 if test $gl_cv_rpl_alloca = yes; then
16590 printf "%s\n" "#define HAVE_ALLOCA 1" >>confdefs.h
16600 if test -n "$ALLOCA_H"; then
16601 GL_GENERATE_ALLOCA_H_TRUE=
16602 GL_GENERATE_ALLOCA_H_FALSE='#'
16604 GL_GENERATE_ALLOCA_H_TRUE='#'
16605 GL_GENERATE_ALLOCA_H_FALSE=
16615 if test $ac_cv_func_btowc = no; then
16622 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether btowc(0) is correct" >&5
16623 printf %s "checking whether btowc(0) is correct... " >&6; }
16624 if ${gl_cv_func_btowc_nul+:} false; then :
16625 printf %s "(cached) " >&6
16628 if test "$cross_compiling" = yes; then :
16631 # Guess no on Cygwin.
16632 cygwin*) gl_cv_func_btowc_nul="guessing no" ;;
16633 # Guess yes otherwise.
16634 *) gl_cv_func_btowc_nul="guessing yes" ;;
16638 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16639 /* end confdefs.h. */
16641 #include <string.h>
16642 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
16644 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
16645 included before <wchar.h>. */
16646 #include <stddef.h>
16652 if (btowc ('\0') != 0)
16657 if ac_fn_c_try_run "$LINENO"; then :
16658 gl_cv_func_btowc_nul=yes
16660 gl_cv_func_btowc_nul=no
16662 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16663 conftest.$ac_objext conftest.beam conftest.$ac_ext
16668 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_btowc_nul" >&5
16669 printf "%s\n" "$gl_cv_func_btowc_nul" >&6; }
16671 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether btowc(EOF) is correct" >&5
16672 printf %s "checking whether btowc(EOF) is correct... " >&6; }
16673 if ${gl_cv_func_btowc_eof+:} false; then :
16674 printf %s "(cached) " >&6
16678 # Guess no on IRIX.
16679 irix*) gl_cv_func_btowc_eof="guessing no" ;;
16680 # Guess yes otherwise.
16681 *) gl_cv_func_btowc_eof="guessing yes" ;;
16683 if test $LOCALE_FR != none; then
16684 if test "$cross_compiling" = yes; then :
16687 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16688 /* end confdefs.h. */
16690 #include <locale.h>
16691 #include <string.h>
16692 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
16694 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
16695 included before <wchar.h>. */
16696 #include <stddef.h>
16702 if (setlocale (LC_ALL, "$LOCALE_FR") != NULL)
16704 if (btowc (EOF) != WEOF)
16710 if ac_fn_c_try_run "$LINENO"; then :
16711 gl_cv_func_btowc_eof=yes
16713 gl_cv_func_btowc_eof=no
16715 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16716 conftest.$ac_objext conftest.beam conftest.$ac_ext
16722 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_btowc_eof" >&5
16723 printf "%s\n" "$gl_cv_func_btowc_eof" >&6; }
16725 case "$gl_cv_func_btowc_nul" in
16727 *) REPLACE_BTOWC=1 ;;
16729 case "$gl_cv_func_btowc_eof" in
16731 *) REPLACE_BTOWC=1 ;;
16735 if test $HAVE_BTOWC = 0 || test $REPLACE_BTOWC = 1; then
16744 gl_LIBOBJS="$gl_LIBOBJS btowc.$ac_objext"
16761 printf "%s\n" "#define GNULIB_TEST_BTOWC 1" >>confdefs.h
16769 # for STACK_DIRECTION
16773 ac_fn_c_check_decl "$LINENO" "sigaltstack" "ac_cv_have_decl_sigaltstack" "#include <signal.h>
16775 if test "x$ac_cv_have_decl_sigaltstack" = xyes; then :
16781 cat >>confdefs.h <<_ACEOF
16782 #define HAVE_DECL_SIGALTSTACK $ac_have_decl
16788 ac_fn_c_check_type "$LINENO" "stack_t" "ac_cv_type_stack_t" "#include <signal.h>
16790 if test "x$ac_cv_type_stack_t" = xyes; then :
16792 cat >>confdefs.h <<_ACEOF
16793 #define HAVE_STACK_T 1
16800 if test "$gl_cv_lib_sigsegv" = yes \
16801 && test $"ac_cv_sys_xsi_stack_overflow_heuristic" != yes ; then
16802 LIBCSTACK=$LIBSIGSEGV
16804 LTLIBCSTACK=$LTLIBSIGSEGV
16813 # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
16814 # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
16816 # Save and restore LIBS so e.g., -lrt, isn't added to it. Otherwise, *all*
16817 # programs in the package would end up linked with that potentially-shared
16818 # library, inducing unnecessary run-time overhead.
16821 gl_saved_libs=$LIBS
16822 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
16823 printf %s "checking for library containing clock_gettime... " >&6; }
16824 if ${ac_cv_search_clock_gettime+:} false; then :
16825 printf %s "(cached) " >&6
16827 ac_func_search_save_LIBS=$LIBS
16828 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16829 /* end confdefs.h. */
16831 /* Override any GCC internal prototype to avoid an error.
16832 Use char because int might match the return type of a GCC
16833 builtin and then its argument prototype would still apply. */
16837 char clock_gettime ();
16841 return clock_gettime ();
16846 for ac_lib in '' rt posix4; do
16847 if test -z "$ac_lib"; then
16848 ac_res="none required"
16851 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
16853 if ac_fn_c_try_link "$LINENO"; then :
16854 ac_cv_search_clock_gettime=$ac_res
16856 rm -f core conftest.err conftest.$ac_objext \
16858 if ${ac_cv_search_clock_gettime+:} false; then :
16862 if ${ac_cv_search_clock_gettime+:} false; then :
16865 ac_cv_search_clock_gettime=no
16867 rm conftest.$ac_ext
16868 LIBS=$ac_func_search_save_LIBS
16870 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
16871 printf "%s\n" "$ac_cv_search_clock_gettime" >&6; }
16872 ac_res=$ac_cv_search_clock_gettime
16873 if test "$ac_res" != no; then :
16874 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
16875 test "$ac_cv_search_clock_gettime" = "none required" ||
16876 LIB_CLOCK_GETTIME=$ac_cv_search_clock_gettime
16879 for ac_func in clock_gettime clock_settime
16881 as_ac_var=`printf "%s\n" "ac_cv_func_$ac_func" | $as_tr_sh`
16882 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16883 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
16884 cat >>confdefs.h <<_ACEOF
16885 #define `printf "%s\n" "HAVE_$ac_func" | $as_tr_cpp` 1
16891 LIBS=$gl_saved_libs
16896 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
16904 if test $ac_cv_header_sys_socket_h != yes; then
16905 for ac_header in winsock2.h
16907 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
16908 if test "x$ac_cv_header_winsock2_h" = xyes; then :
16909 cat >>confdefs.h <<_ACEOF
16910 #define HAVE_WINSOCK2_H 1
16918 if test "$ac_cv_header_winsock2_h" = yes; then
16920 UNISTD_H_HAVE_WINSOCK2_H=1
16921 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
16927 if test $UNISTD_H_HAVE_WINSOCK2_H = 1; then
16933 if test $REPLACE_CLOSE = 1; then
16942 gl_LIBOBJS="$gl_LIBOBJS close.$ac_objext"
16956 printf "%s\n" "#define GNULIB_TEST_CLOSE 1" >>confdefs.h
16962 if test "x$datarootdir" = x; then
16963 datarootdir='${datadir}'
16966 if test "x$docdir" = x; then
16967 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
16970 if test "x$htmldir" = x; then
16971 htmldir='${docdir}'
16974 if test "x$dvidir" = x; then
16978 if test "x$pdfdir" = x; then
16982 if test "x$psdir" = x; then
16986 if test "x$lispdir" = x; then
16987 lispdir='${datarootdir}/emacs/site-lisp'
16990 if test "x$localedir" = x; then
16991 localedir='${datarootdir}/locale'
16995 pkglibexecdir='${libexecdir}/${PACKAGE}'
17003 cat >>confdefs.h <<_ACEOF
17004 #define GNULIB_DIRNAME 1
17014 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether // is distinct from /" >&5
17015 printf %s "checking whether // is distinct from /... " >&6; }
17016 if ${gl_cv_double_slash_root+:} false; then :
17017 printf %s "(cached) " >&6
17019 if test x"$cross_compiling" = xyes ; then
17020 # When cross-compiling, there is no way to tell whether // is special
17021 # short of a list of hosts. However, the only known hosts to date
17022 # that have a distinct // are Apollo DomainOS (too old to port to),
17023 # Cygwin, and z/OS. If anyone knows of another system for which // has
17024 # special semantics and is distinct from /, please report it to
17025 # <bug-gnulib@gnu.org>.
17027 *-cygwin | i370-ibm-openedition)
17028 gl_cv_double_slash_root=yes ;;
17030 # Be optimistic and assume that / and // are the same when we
17032 gl_cv_double_slash_root='unknown, assuming no' ;;
17035 set x `ls -di / // 2>/dev/null`
17036 if test "$2" = "$4" && wc //dev/null >/dev/null 2>&1; then
17037 gl_cv_double_slash_root=no
17039 gl_cv_double_slash_root=yes
17043 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_double_slash_root" >&5
17044 printf "%s\n" "$gl_cv_double_slash_root" >&6; }
17045 if test "$gl_cv_double_slash_root" = yes; then
17047 printf "%s\n" "#define DOUBLE_SLASH_IS_DISTINCT_ROOT 1" >>confdefs.h
17056 printf "%s\n" "#define HAVE_DUP2 1" >>confdefs.h
17059 if test $HAVE_DUP2 = 1; then
17060 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
17061 printf %s "checking whether dup2 works... " >&6; }
17062 if ${gl_cv_func_dup2_works+:} false; then :
17063 printf %s "(cached) " >&6
17065 if test "$cross_compiling" = yes; then :
17067 mingw*) # on this platform, dup2 always returns 0 for success
17068 gl_cv_func_dup2_works="guessing no" ;;
17069 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
17070 gl_cv_func_dup2_works="guessing no" ;;
17071 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
17072 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
17073 gl_cv_func_dup2_works="guessing no" ;;
17074 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
17075 gl_cv_func_dup2_works="guessing no" ;;
17076 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
17077 gl_cv_func_dup2_works="guessing no" ;;
17078 *) gl_cv_func_dup2_works="guessing yes" ;;
17081 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17082 /* end confdefs.h. */
17084 #include <unistd.h>
17092 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
17095 if (dup2 (1, 1) == 0)
17098 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
17102 if (dup2 (0, 0) != -1)
17104 /* Many gnulib modules require POSIX conformance of EBADF. */
17105 if (dup2 (2, 1000000) == -1 && errno != EBADF)
17107 /* Flush out a cygwin core dump. */
17108 if (dup2 (2, -1) != -1 || errno != EBADF)
17117 if ac_fn_c_try_run "$LINENO"; then :
17118 gl_cv_func_dup2_works=yes
17120 gl_cv_func_dup2_works=no
17122 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17123 conftest.$ac_objext conftest.beam conftest.$ac_ext
17128 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
17129 printf "%s\n" "$gl_cv_func_dup2_works" >&6; }
17130 case "$gl_cv_func_dup2_works" in
17139 if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
17148 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
17163 printf "%s\n" "#define GNULIB_TEST_DUP2 1" >>confdefs.h
17169 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for error_at_line" >&5
17170 printf %s "checking for error_at_line... " >&6; }
17171 if ${ac_cv_lib_error_at_line+:} false; then :
17172 printf %s "(cached) " >&6
17174 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17175 /* end confdefs.h. */
17180 error_at_line (0, 0, "", 0, "an error occurred");
17185 if ac_fn_c_try_link "$LINENO"; then :
17186 ac_cv_lib_error_at_line=yes
17188 ac_cv_lib_error_at_line=no
17190 rm -f core conftest.err conftest.$ac_objext \
17191 conftest$ac_exeext conftest.$ac_ext
17193 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_error_at_line" >&5
17194 printf "%s\n" "$ac_cv_lib_error_at_line" >&6; }
17196 if test $ac_cv_lib_error_at_line = no; then
17205 gl_LIBOBJS="$gl_LIBOBJS error.$ac_objext"
17214 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=error:3:c-format"
17218 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=error_at_line:5:c-format"
17226 if test $ac_cv_func_fcntl = no; then
17230 if test $ac_cv_func_fcntl = no; then
17237 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether fcntl handles F_DUPFD correctly" >&5
17238 printf %s "checking whether fcntl handles F_DUPFD correctly... " >&6; }
17239 if ${gl_cv_func_fcntl_f_dupfd_works+:} false; then :
17240 printf %s "(cached) " >&6
17242 if test "$cross_compiling" = yes; then :
17243 # Guess that it works on glibc systems
17244 case $host_os in #((
17245 *-gnu*) gl_cv_func_fcntl_f_dupfd_works="guessing yes";;
17246 *) gl_cv_func_fcntl_f_dupfd_works="guessing no";;
17249 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17250 /* end confdefs.h. */
17259 if (fcntl (0, F_DUPFD, -1) != -1) result |= 1;
17260 if (errno != EINVAL) result |= 2;
17267 if ac_fn_c_try_run "$LINENO"; then :
17268 gl_cv_func_fcntl_f_dupfd_works=yes
17270 gl_cv_func_fcntl_f_dupfd_works=no
17272 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17273 conftest.$ac_objext conftest.beam conftest.$ac_ext
17277 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_works" >&5
17278 printf "%s\n" "$gl_cv_func_fcntl_f_dupfd_works" >&6; }
17279 case $gl_cv_func_fcntl_f_dupfd_works in
17284 if test $ac_cv_func_fcntl = no; then
17291 printf "%s\n" "#define FCNTL_DUPFD_BUGGY 1" >>confdefs.h
17295 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether fcntl understands F_DUPFD_CLOEXEC" >&5
17296 printf %s "checking whether fcntl understands F_DUPFD_CLOEXEC... " >&6; }
17297 if ${gl_cv_func_fcntl_f_dupfd_cloexec+:} false; then :
17298 printf %s "(cached) " >&6
17300 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17301 /* end confdefs.h. */
17304 #ifndef F_DUPFD_CLOEXEC
17316 if ac_fn_c_try_compile "$LINENO"; then :
17317 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17318 /* end confdefs.h. */
17321 /* The Linux kernel only added F_DUPFD_CLOEXEC in 2.6.24, so we always replace
17322 it to support the semantics on older kernels that failed with EINVAL. */
17334 if ac_fn_c_try_compile "$LINENO"; then :
17335 gl_cv_func_fcntl_f_dupfd_cloexec=yes
17337 gl_cv_func_fcntl_f_dupfd_cloexec="needs runtime check"
17339 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17341 gl_cv_func_fcntl_f_dupfd_cloexec=no
17343 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17345 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_cloexec" >&5
17346 printf "%s\n" "$gl_cv_func_fcntl_f_dupfd_cloexec" >&6; }
17347 if test "$gl_cv_func_fcntl_f_dupfd_cloexec" != yes; then
17351 if test $ac_cv_func_fcntl = no; then
17361 if test $HAVE_FCNTL = 0 || test $REPLACE_FCNTL = 1; then
17370 gl_LIBOBJS="$gl_LIBOBJS fcntl.$ac_objext"
17384 printf "%s\n" "#define GNULIB_TEST_FCNTL 1" >>confdefs.h
17399 if test $gl_cv_have_include_next = yes; then
17400 gl_cv_next_fcntl_h='<'fcntl.h'>'
17402 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <fcntl.h>" >&5
17403 printf %s "checking absolute name of <fcntl.h>... " >&6; }
17404 if ${gl_cv_next_fcntl_h+:} false; then :
17405 printf %s "(cached) " >&6
17408 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17409 /* end confdefs.h. */
17414 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17415 *) gl_absname_cpp="$ac_cpp" ;;
17420 gl_dirsep_regex='[/\\]'
17423 gl_dirsep_regex='\/'
17426 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17428 gl_header_literal_regex=`echo 'fcntl.h' \
17429 | sed -e "$gl_make_literal_regex_sed"`
17430 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17431 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17436 gl_cv_next_fcntl_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17437 sed -n "$gl_absolute_header_sed"`'"'
17441 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_fcntl_h" >&5
17442 printf "%s\n" "$gl_cv_next_fcntl_h" >&6; }
17444 NEXT_FCNTL_H=$gl_cv_next_fcntl_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='<'fcntl.h'>'
17450 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17451 gl_next_as_first_directive=$gl_cv_next_fcntl_h
17453 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H=$gl_next_as_first_directive
17464 for gl_func in fcntl openat; do
17465 as_gl_Symbol=`printf "%s\n" "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
17466 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
17467 printf %s "checking whether $gl_func is declared without a macro... " >&6; }
17468 if eval \${$as_gl_Symbol+:} false; then :
17469 printf %s "(cached) " >&6
17471 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17472 /* end confdefs.h. */
17484 if ac_fn_c_try_compile "$LINENO"; then :
17485 eval "$as_gl_Symbol=yes"
17487 eval "$as_gl_Symbol=no"
17489 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17491 eval ac_res=\$$as_gl_Symbol
17492 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
17493 printf "%s\n" "$ac_res" >&6; }
17494 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
17495 cat >>confdefs.h <<_ACEOF
17496 #define `printf "%s\n" "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
17499 eval ac_cv_have_decl_$gl_func=yes
17509 cat >>confdefs.h <<_ACEOF
17510 #define GNULIB_FILENAMECAT 1
17521 REPLACE_FLOAT_LDBL=0
17523 aix* | beos* | openbsd* | mirbsd* | irix*)
17527 case "$host_cpu" in
17532 # On x86_64 systems, the C compiler may still be generating
17534 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17535 /* end confdefs.h. */
17536 #if defined __LP64__ || defined __x86_64__ || defined __amd64__
17540 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17541 $EGREP "yes" >/dev/null 2>&1; then :
17552 case "$host_cpu" in
17560 aix* | freebsd* | linux*)
17561 if test -n "$FLOAT_H"; then
17562 REPLACE_FLOAT_LDBL=1
17568 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether conversion from 'int' to 'long double' works" >&5
17569 printf %s "checking whether conversion from 'int' to 'long double' works... " >&6; }
17570 if ${gl_cv_func_itold_works+:} false; then :
17571 printf %s "(cached) " >&6
17574 if test "$cross_compiling" = yes; then :
17577 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17578 /* end confdefs.h. */
17579 #if defined __LP64__ || defined __arch64__
17583 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17584 $EGREP "yes" >/dev/null 2>&1; then :
17585 gl_cv_func_itold_works="guessing no"
17587 gl_cv_func_itold_works="guessing yes"
17592 *) gl_cv_func_itold_works="guessing yes" ;;
17596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17597 /* end confdefs.h. */
17600 volatile long double ld;
17609 if ac_fn_c_try_run "$LINENO"; then :
17610 gl_cv_func_itold_works=yes
17612 gl_cv_func_itold_works=no
17614 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17615 conftest.$ac_objext conftest.beam conftest.$ac_ext
17620 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_itold_works" >&5
17621 printf "%s\n" "$gl_cv_func_itold_works" >&6; }
17622 case "$gl_cv_func_itold_works" in
17629 if test -n "$FLOAT_H"; then
17638 if test $gl_cv_have_include_next = yes; then
17639 gl_cv_next_float_h='<'float.h'>'
17641 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <float.h>" >&5
17642 printf %s "checking absolute name of <float.h>... " >&6; }
17643 if ${gl_cv_next_float_h+:} false; then :
17644 printf %s "(cached) " >&6
17647 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17648 /* end confdefs.h. */
17653 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17654 *) gl_absname_cpp="$ac_cpp" ;;
17659 gl_dirsep_regex='[/\\]'
17662 gl_dirsep_regex='\/'
17665 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17667 gl_header_literal_regex=`echo 'float.h' \
17668 | sed -e "$gl_make_literal_regex_sed"`
17669 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17670 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17675 gl_cv_next_float_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17676 sed -n "$gl_absolute_header_sed"`'"'
17680 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_float_h" >&5
17681 printf "%s\n" "$gl_cv_next_float_h" >&6; }
17683 NEXT_FLOAT_H=$gl_cv_next_float_h
17685 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17686 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17687 gl_next_as_first_directive='<'float.h'>'
17689 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17690 gl_next_as_first_directive=$gl_cv_next_float_h
17692 NEXT_AS_FIRST_DIRECTIVE_FLOAT_H=$gl_next_as_first_directive
17699 if test -n "$FLOAT_H"; then
17700 GL_GENERATE_FLOAT_H_TRUE=
17701 GL_GENERATE_FLOAT_H_FALSE='#'
17703 GL_GENERATE_FLOAT_H_TRUE='#'
17704 GL_GENERATE_FLOAT_H_FALSE=
17709 if test $REPLACE_FLOAT_LDBL = 1; then
17718 gl_LIBOBJS="$gl_LIBOBJS float.$ac_objext"
17721 if test $REPLACE_ITOLD = 1; then
17730 gl_LIBOBJS="$gl_LIBOBJS itold.$ac_objext"
17739 gl_fnmatch_required_lowercase=`
17740 echo $gl_fnmatch_required | LC_ALL=C tr '[A-Z]' '[a-z]'
17742 gl_fnmatch_cache_var="gl_cv_func_fnmatch_${gl_fnmatch_required_lowercase}"
17743 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working $gl_fnmatch_required fnmatch" >&5
17744 printf %s "checking for working $gl_fnmatch_required fnmatch... " >&6; }
17745 if eval \${$gl_fnmatch_cache_var+:} false; then :
17746 printf %s "(cached) " >&6
17748 if test $gl_fnmatch_required = GNU; then
17749 gl_fnmatch_gnu_start=
17750 gl_fnmatch_gnu_end=
17752 gl_fnmatch_gnu_start='#if 0'
17753 gl_fnmatch_gnu_end='#endif'
17755 if test "$cross_compiling" = yes; then :
17756 eval "$gl_fnmatch_cache_var=\"guessing no\""
17758 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17759 /* end confdefs.h. */
17760 #include <fnmatch.h>
17762 y (char const *pattern, char const *string, int flags)
17764 return fnmatch (pattern, string, flags) == 0;
17767 n (char const *pattern, char const *string, int flags)
17769 return fnmatch (pattern, string, flags) == FNM_NOMATCH;
17775 char const *Apat = 'A' < '\\\\' ? "[A-\\\\\\\\]" : "[\\\\\\\\-A]";
17776 char const *apat = 'a' < '\\\\' ? "[a-\\\\\\\\]" : "[\\\\\\\\-a]";
17777 static char const A_1[] = { 'A' - 1, 0 };
17778 static char const A01[] = { 'A' + 1, 0 };
17779 static char const a_1[] = { 'a' - 1, 0 };
17780 static char const a01[] = { 'a' + 1, 0 };
17781 static char const bs_1[] = { '\\\\' - 1, 0 };
17782 static char const bs01[] = { '\\\\' + 1, 0 };
17784 if (!n ("a*", "", 0))
17786 if (!y ("a*", "abc", 0))
17788 if (!y ("[/b", "[/b", 0)) /*"]]"*/ /* glibc Bugzilla bug 12378 */
17790 if (!n ("d*/*1", "d/s/1", FNM_PATHNAME))
17792 if (!y ("a\\\\bc", "abc", 0))
17794 if (!n ("a\\\\bc", "abc", FNM_NOESCAPE))
17796 if (!y ("*x", ".x", 0))
17798 if (!n ("*x", ".x", FNM_PERIOD))
17800 if (!y (Apat, "\\\\", 0))
17802 if (!y (Apat, "A", 0))
17804 if (!y (apat, "\\\\", 0))
17806 if (!y (apat, "a", 0))
17808 if (!(n (Apat, A_1, 0) == ('A' < '\\\\')))
17810 if (!(n (apat, a_1, 0) == ('a' < '\\\\')))
17812 if (!(y (Apat, A01, 0) == ('A' < '\\\\')))
17814 if (!(y (apat, a01, 0) == ('a' < '\\\\')))
17816 if (!(y (Apat, bs_1, 0) == ('A' < '\\\\')))
17818 if (!(y (apat, bs_1, 0) == ('a' < '\\\\')))
17820 if (!(n (Apat, bs01, 0) == ('A' < '\\\\')))
17822 if (!(n (apat, bs01, 0) == ('a' < '\\\\')))
17824 $gl_fnmatch_gnu_start
17825 if (!y ("xxXX", "xXxX", FNM_CASEFOLD))
17827 if (!y ("a++(x|yy)b", "a+xyyyyxb", FNM_EXTMATCH))
17829 if (!n ("d*/*1", "d/s/1", FNM_FILE_NAME))
17831 if (!y ("*", "x", FNM_FILE_NAME | FNM_LEADING_DIR))
17833 if (!y ("x*", "x/y/z", FNM_FILE_NAME | FNM_LEADING_DIR))
17835 if (!y ("*c*", "c/x", FNM_FILE_NAME | FNM_LEADING_DIR))
17837 $gl_fnmatch_gnu_end
17844 if ac_fn_c_try_run "$LINENO"; then :
17845 eval "$gl_fnmatch_cache_var=yes"
17847 eval "$gl_fnmatch_cache_var=no"
17849 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17850 conftest.$ac_objext conftest.beam conftest.$ac_ext
17855 eval ac_res=\$$gl_fnmatch_cache_var
17856 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
17857 printf "%s\n" "$ac_res" >&6; }
17858 eval "gl_fnmatch_result=\"\$$gl_fnmatch_cache_var\""
17859 if test "$gl_fnmatch_result" = yes; then
17860 rm -f "$gl_source_base/fnmatch.h"
17862 FNMATCH_H=fnmatch.h
17865 if test -n "$FNMATCH_H"; then
17866 GL_GENERATE_FNMATCH_H_TRUE=
17867 GL_GENERATE_FNMATCH_H_FALSE='#'
17869 GL_GENERATE_FNMATCH_H_TRUE='#'
17870 GL_GENERATE_FNMATCH_H_FALSE=
17874 if test -n "$FNMATCH_H"; then
17883 gl_LIBOBJS="$gl_LIBOBJS fnmatch.$ac_objext"
17887 cat >>confdefs.h <<_ACEOF
17888 #define fnmatch ${gl_fnmatch_required_lowercase}_fnmatch
17892 ac_fn_c_check_decl "$LINENO" "isblank" "ac_cv_have_decl_isblank" "#include <ctype.h>
17894 if test "x$ac_cv_have_decl_isblank" = xyes; then :
17900 cat >>confdefs.h <<_ACEOF
17901 #define HAVE_DECL_ISBLANK $ac_have_decl
17913 if test -n "$FNMATCH_H"; then
17922 gl_LIBOBJS="$gl_LIBOBJS fnmatch.$ac_objext"
17926 cat >>confdefs.h <<_ACEOF
17927 #define fnmatch ${gl_fnmatch_required_lowercase}_fnmatch
17931 ac_fn_c_check_decl "$LINENO" "isblank" "ac_cv_have_decl_isblank" "#include <ctype.h>
17933 if test "x$ac_cv_have_decl_isblank" = xyes; then :
17939 cat >>confdefs.h <<_ACEOF
17940 #define HAVE_DECL_ISBLANK $ac_have_decl
17956 if test $REPLACE_FREOPEN = 1; then
17965 gl_LIBOBJS="$gl_LIBOBJS freopen.$ac_objext"
17980 printf "%s\n" "#define GNULIB_TEST_FREOPEN 1" >>confdefs.h
17986 cat >>confdefs.h <<_ACEOF
17987 #define GNULIB_FREOPEN_SAFER 1
17995 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
18000 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
18006 if test $REPLACE_FSTAT = 1; then
18015 gl_LIBOBJS="$gl_LIBOBJS fstat.$ac_objext"
18030 printf "%s\n" "#define GNULIB_TEST_FSTAT 1" >>confdefs.h
18037 if test $ac_cv_func_getdtablesize != yes; then
18038 HAVE_GETDTABLESIZE=0
18041 if test $HAVE_GETDTABLESIZE = 0; then
18050 gl_LIBOBJS="$gl_LIBOBJS getdtablesize.$ac_objext"
18059 GNULIB_GETDTABLESIZE=1
18065 printf "%s\n" "#define GNULIB_TEST_GETDTABLESIZE 1" >>confdefs.h
18074 if test $REPLACE_GETOPT = 1; then
18083 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
18093 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
18098 GNULIB_GL_UNISTD_H_GETOPT=1
18103 printf "%s\n" "#define GNULIB_TEST_GETOPT_GNU 1" >>confdefs.h
18112 if test -n "$gl_replace_getopt"; then
18116 if test $REPLACE_GETOPT = 1; then
18120 printf "%s\n" "#define __GETOPT_PREFIX rpl_" >>confdefs.h
18126 if test $REPLACE_GETOPT = 1; then
18135 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
18145 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
18150 GNULIB_GL_UNISTD_H_GETOPT=1
18166 gl_gettimeofday_timezone=void
18167 if test $ac_cv_func_gettimeofday != yes; then
18168 HAVE_GETTIMEOFDAY=0
18173 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
18174 printf %s "checking whether gettimeofday clobbers localtime buffer... " >&6; }
18175 if ${gl_cv_func_gettimeofday_clobber+:} false; then :
18176 printf %s "(cached) " >&6
18178 if test "$cross_compiling" = yes; then :
18179 # When cross-compiling:
18181 # Guess all is fine on glibc systems.
18182 *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
18183 # If we don't know, assume the worst.
18184 *) gl_cv_func_gettimeofday_clobber="guessing yes" ;;
18188 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18189 /* end confdefs.h. */
18190 #include <string.h>
18191 #include <sys/time.h>
18193 #include <stdlib.h>
18201 struct tm saved_lt;
18203 lt = localtime (&t);
18205 gettimeofday (&tv, NULL);
18206 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
18212 if ac_fn_c_try_run "$LINENO"; then :
18213 gl_cv_func_gettimeofday_clobber=no
18215 gl_cv_func_gettimeofday_clobber=yes
18217 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18218 conftest.$ac_objext conftest.beam conftest.$ac_ext
18222 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
18223 printf "%s\n" "$gl_cv_func_gettimeofday_clobber" >&6; }
18225 case "$gl_cv_func_gettimeofday_clobber" in
18227 REPLACE_GETTIMEOFDAY=1
18230 printf "%s\n" "#define gmtime rpl_gmtime" >>confdefs.h
18233 printf "%s\n" "#define localtime rpl_localtime" >>confdefs.h
18237 printf "%s\n" "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
18242 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
18243 printf %s "checking for gettimeofday with POSIX signature... " >&6; }
18244 if ${gl_cv_func_gettimeofday_posix_signature+:} false; then :
18245 printf %s "(cached) " >&6
18247 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18248 /* end confdefs.h. */
18249 #include <sys/time.h>
18251 int gettimeofday (struct timeval *restrict, void *restrict);
18256 /* glibc uses struct timezone * rather than the POSIX void *
18257 if _GNU_SOURCE is defined. However, since the only portable
18258 use of gettimeofday uses NULL as the second parameter, and
18259 since the glibc definition is actually more typesafe, it is
18260 not worth wrapping this to get a compliant signature. */
18261 int (*f) (struct timeval *restrict, void *restrict)
18264 return !(x | c.tv_sec | c.tv_usec);
18270 if ac_fn_c_try_compile "$LINENO"; then :
18271 gl_cv_func_gettimeofday_posix_signature=yes
18273 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18274 /* end confdefs.h. */
18275 #include <sys/time.h>
18276 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
18286 if ac_fn_c_try_compile "$LINENO"; then :
18287 gl_cv_func_gettimeofday_posix_signature=almost
18289 gl_cv_func_gettimeofday_posix_signature=no
18291 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18293 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18295 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
18296 printf "%s\n" "$gl_cv_func_gettimeofday_posix_signature" >&6; }
18297 if test $gl_cv_func_gettimeofday_posix_signature = almost; then
18298 gl_gettimeofday_timezone='struct timezone'
18299 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
18300 REPLACE_GETTIMEOFDAY=1
18302 if test $REPLACE_STRUCT_TIMEVAL = 1; then
18303 REPLACE_GETTIMEOFDAY=1
18308 cat >>confdefs.h <<_ACEOF
18309 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
18313 if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
18322 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
18325 for ac_header in sys/timeb.h
18327 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
18328 if test "x$ac_cv_header_sys_timeb_h" = xyes; then :
18329 cat >>confdefs.h <<_ACEOF
18330 #define HAVE_SYS_TIMEB_H 1
18337 for ac_func in _ftime
18339 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
18340 if test "x$ac_cv_func__ftime" = xyes; then :
18341 cat >>confdefs.h <<_ACEOF
18342 #define HAVE__FTIME 1
18355 GNULIB_GETTIMEOFDAY=1
18361 printf "%s\n" "#define GNULIB_TEST_GETTIMEOFDAY 1" >>confdefs.h
18366 if ${MAKE-make} --version /cannot/make/this >/dev/null 2>&1; then
18375 # Autoconf 2.61a.99 and earlier don't support linking a file only
18376 # in VPATH builds. But since GNUmakefile is for maintainer use
18377 # only, it does not matter if we skip the link with older autoconf.
18378 # Automake 1.10.1 and earlier try to remove GNUmakefile in non-VPATH
18379 # builds, so use a shell variable to bypass this.
18380 GNUmakefile=GNUmakefile
18381 ac_config_links="$ac_config_links $GNUmakefile:$GNUmakefile"
18409 if test $gl_cv_have_include_next = yes; then
18410 gl_cv_next_iconv_h='<'iconv.h'>'
18412 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <iconv.h>" >&5
18413 printf %s "checking absolute name of <iconv.h>... " >&6; }
18414 if ${gl_cv_next_iconv_h+:} false; then :
18415 printf %s "(cached) " >&6
18418 if test $ac_cv_header_iconv_h = yes; then
18421 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18422 /* end confdefs.h. */
18427 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18428 *) gl_absname_cpp="$ac_cpp" ;;
18433 gl_dirsep_regex='[/\\]'
18436 gl_dirsep_regex='\/'
18439 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18441 gl_header_literal_regex=`echo 'iconv.h' \
18442 | sed -e "$gl_make_literal_regex_sed"`
18443 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18444 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18449 gl_cv_next_iconv_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18450 sed -n "$gl_absolute_header_sed"`'"'
18452 gl_cv_next_iconv_h='<'iconv.h'>'
18457 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_iconv_h" >&5
18458 printf "%s\n" "$gl_cv_next_iconv_h" >&6; }
18460 NEXT_ICONV_H=$gl_cv_next_iconv_h
18462 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18463 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18464 gl_next_as_first_directive='<'iconv.h'>'
18466 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18467 gl_next_as_first_directive=$gl_cv_next_iconv_h
18469 NEXT_AS_FIRST_DIRECTIVE_ICONV_H=$gl_next_as_first_directive
18479 if test "$am_cv_func_iconv" = yes; then
18483 if test -n "$ICONV_H"; then
18484 GL_GENERATE_ICONV_H_TRUE=
18485 GL_GENERATE_ICONV_H_FALSE='#'
18487 GL_GENERATE_ICONV_H_TRUE='#'
18488 GL_GENERATE_ICONV_H_FALSE=
18492 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18493 /* end confdefs.h. */
18496 #if defined _LIBICONV_VERSION || (defined __GLIBC__ && !defined __UCLIBC__)
18501 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18502 $EGREP "gnu_iconv" >/dev/null 2>&1; then :
18503 gl_func_iconv_gnu=yes
18505 gl_func_iconv_gnu=no
18509 if test $gl_func_iconv_gnu = no; then
18512 aix*) iconv_flavor=ICONV_FLAVOR_AIX ;;
18513 irix*) iconv_flavor=ICONV_FLAVOR_IRIX ;;
18514 hpux*) iconv_flavor=ICONV_FLAVOR_HPUX ;;
18515 osf*) iconv_flavor=ICONV_FLAVOR_OSF ;;
18516 solaris*) iconv_flavor=ICONV_FLAVOR_SOLARIS ;;
18518 if test -n "$iconv_flavor"; then
18520 cat >>confdefs.h <<_ACEOF
18521 #define ICONV_FLAVOR $iconv_flavor
18528 if test -n "$ICONV_H"; then
18529 GL_GENERATE_ICONV_H_TRUE=
18530 GL_GENERATE_ICONV_H_FALSE='#'
18532 GL_GENERATE_ICONV_H_TRUE='#'
18533 GL_GENERATE_ICONV_H_FALSE=
18537 REPLACE_ICONV_OPEN=1
18544 if test $REPLACE_ICONV_OPEN = 1; then
18553 gl_LIBOBJS="$gl_LIBOBJS iconv_open.$ac_objext"
18556 if test $REPLACE_ICONV = 1; then
18565 gl_LIBOBJS="$gl_LIBOBJS iconv.$ac_objext"
18575 gl_LIBOBJS="$gl_LIBOBJS iconv_close.$ac_objext"
18580 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler generally respects inline" >&5
18581 printf %s "checking whether the compiler generally respects inline... " >&6; }
18582 if ${gl_cv_c_inline_effective+:} false; then :
18583 printf %s "(cached) " >&6
18585 if test $ac_cv_c_inline = no; then
18586 gl_cv_c_inline_effective=no
18588 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18589 /* end confdefs.h. */
18594 #ifdef __NO_INLINE__
18595 #error "inline is not effective"
18601 if ac_fn_c_try_compile "$LINENO"; then :
18602 gl_cv_c_inline_effective=yes
18604 gl_cv_c_inline_effective=no
18606 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18610 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_inline_effective" >&5
18611 printf "%s\n" "$gl_cv_c_inline_effective" >&6; }
18612 if test $gl_cv_c_inline_effective = yes; then
18614 printf "%s\n" "#define HAVE_INLINE 1" >>confdefs.h
18634 if test -n "$STDINT_H"; then
18635 PRIPTR_PREFIX='"l"'
18637 for glpfx in '' l ll I64; do
18639 '') gltype1='int';;
18640 l) gltype1='long int';;
18641 ll) gltype1='long long int';;
18642 I64) gltype1='__int64';;
18644 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18645 /* end confdefs.h. */
18646 #include <stdint.h>
18647 extern intptr_t foo;
18648 extern $gltype1 foo;
18657 if ac_fn_c_try_compile "$LINENO"; then :
18658 PRIPTR_PREFIX='"'$glpfx'"'
18660 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18661 test -n "$PRIPTR_PREFIX" && break
18667 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether INT32_MAX < INTMAX_MAX" >&5
18668 printf %s "checking whether INT32_MAX < INTMAX_MAX... " >&6; }
18669 if ${gl_cv_test_INT32_MAX_LT_INTMAX_MAX+:} false; then :
18670 printf %s "(cached) " >&6
18672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18673 /* end confdefs.h. */
18674 /* Work also in C++ mode. */
18675 #define __STDC_LIMIT_MACROS 1
18677 /* Work if build is not clean. */
18678 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
18680 #include <limits.h>
18682 #include <stdint.h>
18685 #if defined INT32_MAX && defined INTMAX_MAX
18686 #define CONDITION (INT32_MAX < INTMAX_MAX)
18687 #elif HAVE_LONG_LONG_INT
18688 #define CONDITION (sizeof (int) < sizeof (long long int))
18690 #define CONDITION 0
18692 int test[CONDITION ? 1 : -1];
18701 if ac_fn_c_try_compile "$LINENO"; then :
18702 gl_cv_test_INT32_MAX_LT_INTMAX_MAX=yes
18704 gl_cv_test_INT32_MAX_LT_INTMAX_MAX=no
18706 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18708 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_INT32_MAX_LT_INTMAX_MAX" >&5
18709 printf "%s\n" "$gl_cv_test_INT32_MAX_LT_INTMAX_MAX" >&6; }
18710 if test $gl_cv_test_INT32_MAX_LT_INTMAX_MAX = yes; then
18711 INT32_MAX_LT_INTMAX_MAX=1;
18713 INT32_MAX_LT_INTMAX_MAX=0;
18717 if test $APPLE_UNIVERSAL_BUILD = 0; then
18719 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether INT64_MAX == LONG_MAX" >&5
18720 printf %s "checking whether INT64_MAX == LONG_MAX... " >&6; }
18721 if ${gl_cv_test_INT64_MAX_EQ_LONG_MAX+:} false; then :
18722 printf %s "(cached) " >&6
18724 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18725 /* end confdefs.h. */
18726 /* Work also in C++ mode. */
18727 #define __STDC_LIMIT_MACROS 1
18729 /* Work if build is not clean. */
18730 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
18732 #include <limits.h>
18734 #include <stdint.h>
18737 #if defined INT64_MAX
18738 #define CONDITION (INT64_MAX == LONG_MAX)
18739 #elif HAVE_LONG_LONG_INT
18740 #define CONDITION (sizeof (long long int) == sizeof (long int))
18742 #define CONDITION 0
18744 int test[CONDITION ? 1 : -1];
18753 if ac_fn_c_try_compile "$LINENO"; then :
18754 gl_cv_test_INT64_MAX_EQ_LONG_MAX=yes
18756 gl_cv_test_INT64_MAX_EQ_LONG_MAX=no
18758 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18760 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_INT64_MAX_EQ_LONG_MAX" >&5
18761 printf "%s\n" "$gl_cv_test_INT64_MAX_EQ_LONG_MAX" >&6; }
18762 if test $gl_cv_test_INT64_MAX_EQ_LONG_MAX = yes; then
18763 INT64_MAX_EQ_LONG_MAX=1;
18765 INT64_MAX_EQ_LONG_MAX=0;
18770 INT64_MAX_EQ_LONG_MAX=-1
18773 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether UINT32_MAX < UINTMAX_MAX" >&5
18774 printf %s "checking whether UINT32_MAX < UINTMAX_MAX... " >&6; }
18775 if ${gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX+:} false; then :
18776 printf %s "(cached) " >&6
18778 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18779 /* end confdefs.h. */
18780 /* Work also in C++ mode. */
18781 #define __STDC_LIMIT_MACROS 1
18783 /* Work if build is not clean. */
18784 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
18786 #include <limits.h>
18788 #include <stdint.h>
18791 #if defined UINT32_MAX && defined UINTMAX_MAX
18792 #define CONDITION (UINT32_MAX < UINTMAX_MAX)
18793 #elif HAVE_LONG_LONG_INT
18794 #define CONDITION (sizeof (unsigned int) < sizeof (unsigned long long int))
18796 #define CONDITION 0
18798 int test[CONDITION ? 1 : -1];
18807 if ac_fn_c_try_compile "$LINENO"; then :
18808 gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX=yes
18810 gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX=no
18812 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18814 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX" >&5
18815 printf "%s\n" "$gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX" >&6; }
18816 if test $gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX = yes; then
18817 UINT32_MAX_LT_UINTMAX_MAX=1;
18819 UINT32_MAX_LT_UINTMAX_MAX=0;
18823 if test $APPLE_UNIVERSAL_BUILD = 0; then
18825 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether UINT64_MAX == ULONG_MAX" >&5
18826 printf %s "checking whether UINT64_MAX == ULONG_MAX... " >&6; }
18827 if ${gl_cv_test_UINT64_MAX_EQ_ULONG_MAX+:} false; then :
18828 printf %s "(cached) " >&6
18830 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18831 /* end confdefs.h. */
18832 /* Work also in C++ mode. */
18833 #define __STDC_LIMIT_MACROS 1
18835 /* Work if build is not clean. */
18836 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
18838 #include <limits.h>
18840 #include <stdint.h>
18843 #if defined UINT64_MAX
18844 #define CONDITION (UINT64_MAX == ULONG_MAX)
18845 #elif HAVE_LONG_LONG_INT
18846 #define CONDITION (sizeof (unsigned long long int) == sizeof (unsigned long int))
18848 #define CONDITION 0
18850 int test[CONDITION ? 1 : -1];
18859 if ac_fn_c_try_compile "$LINENO"; then :
18860 gl_cv_test_UINT64_MAX_EQ_ULONG_MAX=yes
18862 gl_cv_test_UINT64_MAX_EQ_ULONG_MAX=no
18864 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18866 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_UINT64_MAX_EQ_ULONG_MAX" >&5
18867 printf "%s\n" "$gl_cv_test_UINT64_MAX_EQ_ULONG_MAX" >&6; }
18868 if test $gl_cv_test_UINT64_MAX_EQ_ULONG_MAX = yes; then
18869 UINT64_MAX_EQ_ULONG_MAX=1;
18871 UINT64_MAX_EQ_ULONG_MAX=0;
18876 UINT64_MAX_EQ_ULONG_MAX=-1
18886 ac_fn_c_check_decl "$LINENO" "iswblank" "ac_cv_have_decl_iswblank" "
18887 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
18889 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
18890 before <wchar.h>. */
18891 #include <stddef.h>
18895 #include <wctype.h>
18898 if test "x$ac_cv_have_decl_iswblank" = xyes; then :
18904 cat >>confdefs.h <<_ACEOF
18905 #define HAVE_DECL_ISWBLANK $ac_have_decl
18908 if test $ac_cv_func_iswblank = no; then
18910 if test $ac_cv_have_decl_iswblank = yes; then
18914 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_ISWCNTRL = 1; then
18917 if test $HAVE_ISWBLANK = 0 || test $REPLACE_ISWBLANK = 1; then
18923 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_ISWCNTRL = 1; then
18926 if test $HAVE_ISWBLANK = 0 || test $REPLACE_ISWBLANK = 1; then
18935 gl_LIBOBJS="$gl_LIBOBJS iswblank.$ac_objext"
18950 printf "%s\n" "#define GNULIB_TEST_ISWBLANK 1" >>confdefs.h
18968 if test $gl_cv_have_include_next = yes; then
18969 gl_cv_next_langinfo_h='<'langinfo.h'>'
18971 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <langinfo.h>" >&5
18972 printf %s "checking absolute name of <langinfo.h>... " >&6; }
18973 if ${gl_cv_next_langinfo_h+:} false; then :
18974 printf %s "(cached) " >&6
18977 if test $ac_cv_header_langinfo_h = yes; then
18980 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18981 /* end confdefs.h. */
18982 #include <langinfo.h>
18986 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18987 *) gl_absname_cpp="$ac_cpp" ;;
18992 gl_dirsep_regex='[/\\]'
18995 gl_dirsep_regex='\/'
18998 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19000 gl_header_literal_regex=`echo 'langinfo.h' \
19001 | sed -e "$gl_make_literal_regex_sed"`
19002 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19003 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19008 gl_cv_next_langinfo_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19009 sed -n "$gl_absolute_header_sed"`'"'
19011 gl_cv_next_langinfo_h='<'langinfo.h'>'
19016 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_langinfo_h" >&5
19017 printf "%s\n" "$gl_cv_next_langinfo_h" >&6; }
19019 NEXT_LANGINFO_H=$gl_cv_next_langinfo_h
19021 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19022 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19023 gl_next_as_first_directive='<'langinfo.h'>'
19025 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19026 gl_next_as_first_directive=$gl_cv_next_langinfo_h
19028 NEXT_AS_FIRST_DIRECTIVE_LANGINFO_H=$gl_next_as_first_directive
19034 HAVE_LANGINFO_CODESET=0
19035 HAVE_LANGINFO_T_FMT_AMPM=0
19036 HAVE_LANGINFO_ERA=0
19037 HAVE_LANGINFO_YESEXPR=0
19039 if test $ac_cv_header_langinfo_h = yes; then
19041 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether langinfo.h defines CODESET" >&5
19042 printf %s "checking whether langinfo.h defines CODESET... " >&6; }
19043 if ${gl_cv_header_langinfo_codeset+:} false; then :
19044 printf %s "(cached) " >&6
19046 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19047 /* end confdefs.h. */
19048 #include <langinfo.h>
19059 if ac_fn_c_try_compile "$LINENO"; then :
19060 gl_cv_header_langinfo_codeset=yes
19062 gl_cv_header_langinfo_codeset=no
19064 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19067 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_langinfo_codeset" >&5
19068 printf "%s\n" "$gl_cv_header_langinfo_codeset" >&6; }
19069 if test $gl_cv_header_langinfo_codeset = yes; then
19070 HAVE_LANGINFO_CODESET=1
19072 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether langinfo.h defines T_FMT_AMPM" >&5
19073 printf %s "checking whether langinfo.h defines T_FMT_AMPM... " >&6; }
19074 if ${gl_cv_header_langinfo_t_fmt_ampm+:} false; then :
19075 printf %s "(cached) " >&6
19077 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19078 /* end confdefs.h. */
19079 #include <langinfo.h>
19080 int a = T_FMT_AMPM;
19090 if ac_fn_c_try_compile "$LINENO"; then :
19091 gl_cv_header_langinfo_t_fmt_ampm=yes
19093 gl_cv_header_langinfo_t_fmt_ampm=no
19095 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19098 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_langinfo_t_fmt_ampm" >&5
19099 printf "%s\n" "$gl_cv_header_langinfo_t_fmt_ampm" >&6; }
19100 if test $gl_cv_header_langinfo_t_fmt_ampm = yes; then
19101 HAVE_LANGINFO_T_FMT_AMPM=1
19103 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether langinfo.h defines ERA" >&5
19104 printf %s "checking whether langinfo.h defines ERA... " >&6; }
19105 if ${gl_cv_header_langinfo_era+:} false; then :
19106 printf %s "(cached) " >&6
19108 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19109 /* end confdefs.h. */
19110 #include <langinfo.h>
19121 if ac_fn_c_try_compile "$LINENO"; then :
19122 gl_cv_header_langinfo_era=yes
19124 gl_cv_header_langinfo_era=no
19126 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19129 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_langinfo_era" >&5
19130 printf "%s\n" "$gl_cv_header_langinfo_era" >&6; }
19131 if test $gl_cv_header_langinfo_era = yes; then
19132 HAVE_LANGINFO_ERA=1
19134 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether langinfo.h defines YESEXPR" >&5
19135 printf %s "checking whether langinfo.h defines YESEXPR... " >&6; }
19136 if ${gl_cv_header_langinfo_yesexpr+:} false; then :
19137 printf %s "(cached) " >&6
19139 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19140 /* end confdefs.h. */
19141 #include <langinfo.h>
19152 if ac_fn_c_try_compile "$LINENO"; then :
19153 gl_cv_header_langinfo_yesexpr=yes
19155 gl_cv_header_langinfo_yesexpr=no
19157 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19160 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_langinfo_yesexpr" >&5
19161 printf "%s\n" "$gl_cv_header_langinfo_yesexpr" >&6; }
19162 if test $gl_cv_header_langinfo_yesexpr = yes; then
19163 HAVE_LANGINFO_YESEXPR=1
19175 for gl_func in nl_langinfo; do
19176 as_gl_Symbol=`printf "%s\n" "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
19177 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
19178 printf %s "checking whether $gl_func is declared without a macro... " >&6; }
19179 if eval \${$as_gl_Symbol+:} false; then :
19180 printf %s "(cached) " >&6
19182 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19183 /* end confdefs.h. */
19184 #include <langinfo.h>
19195 if ac_fn_c_try_compile "$LINENO"; then :
19196 eval "$as_gl_Symbol=yes"
19198 eval "$as_gl_Symbol=no"
19200 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19202 eval ac_res=\$$as_gl_Symbol
19203 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
19204 printf "%s\n" "$ac_res" >&6; }
19205 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
19206 cat >>confdefs.h <<_ACEOF
19207 #define `printf "%s\n" "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
19210 eval ac_cv_have_decl_$gl_func=yes
19232 acl_save_prefix="$prefix"
19233 prefix="$acl_final_prefix"
19234 acl_save_exec_prefix="$exec_prefix"
19235 exec_prefix="$acl_final_exec_prefix"
19237 eval additional_includedir=\"$includedir\"
19238 eval additional_libdir=\"$libdir\"
19240 exec_prefix="$acl_save_exec_prefix"
19241 prefix="$acl_save_prefix"
19244 # Check whether --with-libsigsegv-prefix was given.
19245 if test "${with_libsigsegv_prefix+set}" = set; then :
19246 withval=$with_libsigsegv_prefix;
19247 if test "X$withval" = "Xno"; then
19250 if test "X$withval" = "X"; then
19252 acl_save_prefix="$prefix"
19253 prefix="$acl_final_prefix"
19254 acl_save_exec_prefix="$exec_prefix"
19255 exec_prefix="$acl_final_exec_prefix"
19257 eval additional_includedir=\"$includedir\"
19258 eval additional_libdir=\"$libdir\"
19260 exec_prefix="$acl_save_exec_prefix"
19261 prefix="$acl_save_prefix"
19264 additional_includedir="$withval/include"
19265 additional_libdir="$withval/$acl_libdirstem"
19266 if test "$acl_libdirstem2" != "$acl_libdirstem" \
19267 && ! test -d "$withval/$acl_libdirstem"; then
19268 additional_libdir="$withval/$acl_libdirstem2"
19282 names_already_handled=
19283 names_next_round='sigsegv '
19284 while test -n "$names_next_round"; do
19285 names_this_round="$names_next_round"
19287 for name in $names_this_round; do
19289 for n in $names_already_handled; do
19290 if test "$n" = "$name"; then
19291 already_handled=yes
19295 if test -z "$already_handled"; then
19296 names_already_handled="$names_already_handled $name"
19297 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./+-|ABCDEFGHIJKLMNOPQRSTUVWXYZ____|'`
19298 eval value=\"\$HAVE_LIB$uppername\"
19299 if test -n "$value"; then
19300 if test "$value" = yes; then
19301 eval value=\"\$LIB$uppername\"
19302 test -z "$value" || LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }$value"
19303 eval value=\"\$LTLIB$uppername\"
19304 test -z "$value" || LTLIBSIGSEGV="${LTLIBSIGSEGV}${LTLIBSIGSEGV:+ }$value"
19313 eval libname=\"$acl_libname_spec\" # typically: libname=lib$name
19314 if test -n "$acl_shlibext"; then
19315 shrext=".$acl_shlibext" # typically: shrext=.so
19319 if test $use_additional = yes; then
19320 dir="$additional_libdir"
19321 if test -n "$acl_shlibext"; then
19322 if test -f "$dir/$libname$shrext"; then
19324 found_so="$dir/$libname$shrext"
19326 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
19327 ver=`(cd "$dir" && \
19328 for f in "$libname$shrext".*; do echo "$f"; done \
19329 | sed -e "s,^$libname$shrext\\\\.,," \
19330 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
19331 | sed 1q ) 2>/dev/null`
19332 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
19334 found_so="$dir/$libname$shrext.$ver"
19337 eval library_names=\"$acl_library_names_spec\"
19338 for f in $library_names; do
19339 if test -f "$dir/$f"; then
19348 if test "X$found_dir" = "X"; then
19349 if test -f "$dir/$libname.$acl_libext"; then
19351 found_a="$dir/$libname.$acl_libext"
19354 if test "X$found_dir" != "X"; then
19355 if test -f "$dir/$libname.la"; then
19356 found_la="$dir/$libname.la"
19360 if test "X$found_dir" = "X"; then
19361 for x in $LDFLAGS $LTLIBSIGSEGV; do
19363 acl_save_prefix="$prefix"
19364 prefix="$acl_final_prefix"
19365 acl_save_exec_prefix="$exec_prefix"
19366 exec_prefix="$acl_final_exec_prefix"
19368 exec_prefix="$acl_save_exec_prefix"
19369 prefix="$acl_save_prefix"
19373 dir=`echo "X$x" | sed -e 's/^X-L//'`
19374 if test -n "$acl_shlibext"; then
19375 if test -f "$dir/$libname$shrext"; then
19377 found_so="$dir/$libname$shrext"
19379 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
19380 ver=`(cd "$dir" && \
19381 for f in "$libname$shrext".*; do echo "$f"; done \
19382 | sed -e "s,^$libname$shrext\\\\.,," \
19383 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
19384 | sed 1q ) 2>/dev/null`
19385 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
19387 found_so="$dir/$libname$shrext.$ver"
19390 eval library_names=\"$acl_library_names_spec\"
19391 for f in $library_names; do
19392 if test -f "$dir/$f"; then
19401 if test "X$found_dir" = "X"; then
19402 if test -f "$dir/$libname.$acl_libext"; then
19404 found_a="$dir/$libname.$acl_libext"
19407 if test "X$found_dir" != "X"; then
19408 if test -f "$dir/$libname.la"; then
19409 found_la="$dir/$libname.la"
19414 if test "X$found_dir" != "X"; then
19419 if test "X$found_dir" != "X"; then
19420 LTLIBSIGSEGV="${LTLIBSIGSEGV}${LTLIBSIGSEGV:+ }-L$found_dir -l$name"
19421 if test "X$found_so" != "X"; then
19422 if test "$enable_rpath" = no \
19423 || test "X$found_dir" = "X/usr/$acl_libdirstem" \
19424 || test "X$found_dir" = "X/usr/$acl_libdirstem2"; then
19425 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }$found_so"
19428 for x in $ltrpathdirs; do
19429 if test "X$x" = "X$found_dir"; then
19434 if test -z "$haveit"; then
19435 ltrpathdirs="$ltrpathdirs $found_dir"
19437 if test "$acl_hardcode_direct" = yes; then
19438 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }$found_so"
19440 if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
19441 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }$found_so"
19443 for x in $rpathdirs; do
19444 if test "X$x" = "X$found_dir"; then
19449 if test -z "$haveit"; then
19450 rpathdirs="$rpathdirs $found_dir"
19454 for x in $LDFLAGS $LIBSIGSEGV; do
19456 acl_save_prefix="$prefix"
19457 prefix="$acl_final_prefix"
19458 acl_save_exec_prefix="$exec_prefix"
19459 exec_prefix="$acl_final_exec_prefix"
19461 exec_prefix="$acl_save_exec_prefix"
19462 prefix="$acl_save_prefix"
19464 if test "X$x" = "X-L$found_dir"; then
19469 if test -z "$haveit"; then
19470 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }-L$found_dir"
19472 if test "$acl_hardcode_minus_L" != no; then
19473 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }$found_so"
19475 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }-l$name"
19481 if test "X$found_a" != "X"; then
19482 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }$found_a"
19484 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }-L$found_dir -l$name"
19487 additional_includedir=
19488 case "$found_dir" in
19489 */$acl_libdirstem | */$acl_libdirstem/)
19490 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
19491 if test "$name" = 'sigsegv'; then
19492 LIBSIGSEGV_PREFIX="$basedir"
19494 additional_includedir="$basedir/include"
19496 */$acl_libdirstem2 | */$acl_libdirstem2/)
19497 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
19498 if test "$name" = 'sigsegv'; then
19499 LIBSIGSEGV_PREFIX="$basedir"
19501 additional_includedir="$basedir/include"
19504 if test "X$additional_includedir" != "X"; then
19505 if test "X$additional_includedir" != "X/usr/include"; then
19507 if test "X$additional_includedir" = "X/usr/local/include"; then
19508 if test -n "$GCC"; then
19510 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
19514 if test -z "$haveit"; then
19515 for x in $CPPFLAGS $INCSIGSEGV; do
19517 acl_save_prefix="$prefix"
19518 prefix="$acl_final_prefix"
19519 acl_save_exec_prefix="$exec_prefix"
19520 exec_prefix="$acl_final_exec_prefix"
19522 exec_prefix="$acl_save_exec_prefix"
19523 prefix="$acl_save_prefix"
19525 if test "X$x" = "X-I$additional_includedir"; then
19530 if test -z "$haveit"; then
19531 if test -d "$additional_includedir"; then
19532 INCSIGSEGV="${INCSIGSEGV}${INCSIGSEGV:+ }-I$additional_includedir"
19538 if test -n "$found_la"; then
19539 save_libdir="$libdir"
19540 case "$found_la" in
19541 */* | *\\*) . "$found_la" ;;
19542 *) . "./$found_la" ;;
19544 libdir="$save_libdir"
19545 for dep in $dependency_libs; do
19548 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
19549 if test "X$additional_libdir" != "X/usr/$acl_libdirstem" \
19550 && test "X$additional_libdir" != "X/usr/$acl_libdirstem2"; then
19552 if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem" \
19553 || test "X$additional_libdir" = "X/usr/local/$acl_libdirstem2"; then
19554 if test -n "$GCC"; then
19556 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
19560 if test -z "$haveit"; then
19562 for x in $LDFLAGS $LIBSIGSEGV; do
19564 acl_save_prefix="$prefix"
19565 prefix="$acl_final_prefix"
19566 acl_save_exec_prefix="$exec_prefix"
19567 exec_prefix="$acl_final_exec_prefix"
19569 exec_prefix="$acl_save_exec_prefix"
19570 prefix="$acl_save_prefix"
19572 if test "X$x" = "X-L$additional_libdir"; then
19577 if test -z "$haveit"; then
19578 if test -d "$additional_libdir"; then
19579 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }-L$additional_libdir"
19583 for x in $LDFLAGS $LTLIBSIGSEGV; do
19585 acl_save_prefix="$prefix"
19586 prefix="$acl_final_prefix"
19587 acl_save_exec_prefix="$exec_prefix"
19588 exec_prefix="$acl_final_exec_prefix"
19590 exec_prefix="$acl_save_exec_prefix"
19591 prefix="$acl_save_prefix"
19593 if test "X$x" = "X-L$additional_libdir"; then
19598 if test -z "$haveit"; then
19599 if test -d "$additional_libdir"; then
19600 LTLIBSIGSEGV="${LTLIBSIGSEGV}${LTLIBSIGSEGV:+ }-L$additional_libdir"
19607 dir=`echo "X$dep" | sed -e 's/^X-R//'`
19608 if test "$enable_rpath" != no; then
19610 for x in $rpathdirs; do
19611 if test "X$x" = "X$dir"; then
19616 if test -z "$haveit"; then
19617 rpathdirs="$rpathdirs $dir"
19620 for x in $ltrpathdirs; do
19621 if test "X$x" = "X$dir"; then
19626 if test -z "$haveit"; then
19627 ltrpathdirs="$ltrpathdirs $dir"
19632 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
19635 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
19638 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }$dep"
19639 LTLIBSIGSEGV="${LTLIBSIGSEGV}${LTLIBSIGSEGV:+ }$dep"
19645 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }-l$name"
19646 LTLIBSIGSEGV="${LTLIBSIGSEGV}${LTLIBSIGSEGV:+ }-l$name"
19652 if test "X$rpathdirs" != "X"; then
19653 if test -n "$acl_hardcode_libdir_separator"; then
19655 for found_dir in $rpathdirs; do
19656 alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir"
19658 acl_save_libdir="$libdir"
19660 eval flag=\"$acl_hardcode_libdir_flag_spec\"
19661 libdir="$acl_save_libdir"
19662 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }$flag"
19664 for found_dir in $rpathdirs; do
19665 acl_save_libdir="$libdir"
19666 libdir="$found_dir"
19667 eval flag=\"$acl_hardcode_libdir_flag_spec\"
19668 libdir="$acl_save_libdir"
19669 LIBSIGSEGV="${LIBSIGSEGV}${LIBSIGSEGV:+ }$flag"
19673 if test "X$ltrpathdirs" != "X"; then
19674 for found_dir in $ltrpathdirs; do
19675 LTLIBSIGSEGV="${LTLIBSIGSEGV}${LTLIBSIGSEGV:+ }-R$found_dir"
19685 ac_save_CPPFLAGS="$CPPFLAGS"
19687 for element in $INCSIGSEGV; do
19689 for x in $CPPFLAGS; do
19691 acl_save_prefix="$prefix"
19692 prefix="$acl_final_prefix"
19693 acl_save_exec_prefix="$exec_prefix"
19694 exec_prefix="$acl_final_exec_prefix"
19696 exec_prefix="$acl_save_exec_prefix"
19697 prefix="$acl_save_prefix"
19699 if test "X$x" = "X$element"; then
19704 if test -z "$haveit"; then
19705 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
19710 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libsigsegv" >&5
19711 printf %s "checking for libsigsegv... " >&6; }
19712 if ${ac_cv_libsigsegv+:} false; then :
19713 printf %s "(cached) " >&6
19716 ac_save_LIBS="$LIBS"
19717 case " $LIBSIGSEGV" in
19718 *" -l"*) LIBS="$LIBS $LIBSIGSEGV" ;;
19719 *) LIBS="$LIBSIGSEGV $LIBS" ;;
19721 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19722 /* end confdefs.h. */
19723 #include <sigsegv.h>
19727 sigsegv_deinstall_handler();
19732 if ac_fn_c_try_link "$LINENO"; then :
19733 ac_cv_libsigsegv=yes
19735 ac_cv_libsigsegv='no, consider installing GNU libsigsegv'
19737 rm -f core conftest.err conftest.$ac_objext \
19738 conftest$ac_exeext conftest.$ac_ext
19739 LIBS="$ac_save_LIBS"
19742 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libsigsegv" >&5
19743 printf "%s\n" "$ac_cv_libsigsegv" >&6; }
19744 if test "$ac_cv_libsigsegv" = yes; then
19745 HAVE_LIBSIGSEGV=yes
19747 printf "%s\n" "#define HAVE_LIBSIGSEGV 1" >>confdefs.h
19749 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to link with libsigsegv" >&5
19750 printf %s "checking how to link with libsigsegv... " >&6; }
19751 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LIBSIGSEGV" >&5
19752 printf "%s\n" "$LIBSIGSEGV" >&6; }
19755 CPPFLAGS="$ac_save_CPPFLAGS"
19767 gl_cv_lib_sigsegv="$ac_cv_libsigsegv"
19777 LOCALCHARSET_TESTS_ENVIRONMENT="CHARSETALIASDIR=\"\$(abs_top_builddir)/$gl_source_base\""
19790 printf "%s\n" "#define _LCONV_C99 1" >>confdefs.h
19795 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether locale.h conforms to POSIX:2001" >&5
19796 printf %s "checking whether locale.h conforms to POSIX:2001... " >&6; }
19797 if ${gl_cv_header_locale_h_posix2001+:} false; then :
19798 printf %s "(cached) " >&6
19800 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19801 /* end confdefs.h. */
19802 #include <locale.h>
19803 int x = LC_MESSAGES;
19804 int y = sizeof (((struct lconv *) 0)->decimal_point);
19813 if ac_fn_c_try_compile "$LINENO"; then :
19814 gl_cv_header_locale_h_posix2001=yes
19816 gl_cv_header_locale_h_posix2001=no
19818 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19820 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_locale_h_posix2001" >&5
19821 printf "%s\n" "$gl_cv_header_locale_h_posix2001" >&6; }
19824 if test $ac_cv_header_xlocale_h = yes; then
19826 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether locale.h defines locale_t" >&5
19827 printf %s "checking whether locale.h defines locale_t... " >&6; }
19828 if ${gl_cv_header_locale_has_locale_t+:} false; then :
19829 printf %s "(cached) " >&6
19831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19832 /* end confdefs.h. */
19833 #include <locale.h>
19843 if ac_fn_c_try_compile "$LINENO"; then :
19844 gl_cv_header_locale_has_locale_t=yes
19846 gl_cv_header_locale_has_locale_t=no
19848 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19851 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_locale_has_locale_t" >&5
19852 printf "%s\n" "$gl_cv_header_locale_has_locale_t" >&6; }
19853 if test $gl_cv_header_locale_has_locale_t = yes; then
19854 gl_cv_header_locale_h_needs_xlocale_h=no
19856 gl_cv_header_locale_h_needs_xlocale_h=yes
19860 gl_cv_header_locale_h_needs_xlocale_h=no
19864 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether struct lconv is properly defined" >&5
19865 printf %s "checking whether struct lconv is properly defined... " >&6; }
19866 if ${gl_cv_sys_struct_lconv_ok+:} false; then :
19867 printf %s "(cached) " >&6
19869 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19870 /* end confdefs.h. */
19871 #include <locale.h>
19873 int x = sizeof (l.decimal_point);
19874 int y = sizeof (l.int_p_cs_precedes);
19883 if ac_fn_c_try_compile "$LINENO"; then :
19884 gl_cv_sys_struct_lconv_ok=yes
19886 gl_cv_sys_struct_lconv_ok=no
19888 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19891 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_lconv_ok" >&5
19892 printf "%s\n" "$gl_cv_sys_struct_lconv_ok" >&6; }
19893 if test $gl_cv_sys_struct_lconv_ok = no; then
19894 REPLACE_STRUCT_LCONV=1
19905 if test $gl_cv_have_include_next = yes; then
19906 gl_cv_next_locale_h='<'locale.h'>'
19908 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <locale.h>" >&5
19909 printf %s "checking absolute name of <locale.h>... " >&6; }
19910 if ${gl_cv_next_locale_h+:} false; then :
19911 printf %s "(cached) " >&6
19914 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19915 /* end confdefs.h. */
19916 #include <locale.h>
19920 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19921 *) gl_absname_cpp="$ac_cpp" ;;
19926 gl_dirsep_regex='[/\\]'
19929 gl_dirsep_regex='\/'
19932 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19934 gl_header_literal_regex=`echo 'locale.h' \
19935 | sed -e "$gl_make_literal_regex_sed"`
19936 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19937 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19942 gl_cv_next_locale_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19943 sed -n "$gl_absolute_header_sed"`'"'
19947 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_locale_h" >&5
19948 printf "%s\n" "$gl_cv_next_locale_h" >&6; }
19950 NEXT_LOCALE_H=$gl_cv_next_locale_h
19952 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19953 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19954 gl_next_as_first_directive='<'locale.h'>'
19956 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19957 gl_next_as_first_directive=$gl_cv_next_locale_h
19959 NEXT_AS_FIRST_DIRECTIVE_LOCALE_H=$gl_next_as_first_directive
19966 for gl_func in setlocale duplocale; do
19967 as_gl_Symbol=`printf "%s\n" "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
19968 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
19969 printf %s "checking whether $gl_func is declared without a macro... " >&6; }
19970 if eval \${$as_gl_Symbol+:} false; then :
19971 printf %s "(cached) " >&6
19973 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19974 /* end confdefs.h. */
19975 #include <locale.h>
19976 /* Some systems provide declarations in a non-standard header. */
19978 # include <xlocale.h>
19990 if ac_fn_c_try_compile "$LINENO"; then :
19991 eval "$as_gl_Symbol=yes"
19993 eval "$as_gl_Symbol=no"
19995 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19997 eval ac_res=\$$as_gl_Symbol
19998 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
19999 printf "%s\n" "$ac_res" >&6; }
20000 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
20001 cat >>confdefs.h <<_ACEOF
20002 #define `printf "%s\n" "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
20005 eval ac_cv_have_decl_$gl_func=yes
20014 if test $REPLACE_STRUCT_LCONV = 1; then
20015 REPLACE_LOCALECONV=1
20018 if test $REPLACE_LOCALECONV = 1; then
20027 gl_LIBOBJS="$gl_LIBOBJS localeconv.$ac_objext"
20030 ac_fn_c_check_member "$LINENO" "struct lconv" "decimal_point" "ac_cv_member_struct_lconv_decimal_point" "#include <locale.h>
20032 if test "x$ac_cv_member_struct_lconv_decimal_point" = xyes; then :
20034 cat >>confdefs.h <<_ACEOF
20035 #define HAVE_STRUCT_LCONV_DECIMAL_POINT 1
20048 GNULIB_LOCALECONV=1
20054 printf "%s\n" "#define GNULIB_TEST_LOCALECONV 1" >>confdefs.h
20061 if test $ac_cv_func_lstat = yes; then
20063 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
20072 if test $REPLACE_LSTAT = 1; then
20081 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
20096 printf "%s\n" "#define GNULIB_TEST_LSTAT 1" >>confdefs.h
20104 for ac_header in stdlib.h
20106 ac_fn_c_check_header_mongrel "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default"
20107 if test "x$ac_cv_header_stdlib_h" = xyes; then :
20108 cat >>confdefs.h <<_ACEOF
20109 #define HAVE_STDLIB_H 1
20116 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5
20117 printf %s "checking for GNU libc compatible malloc... " >&6; }
20118 if ${ac_cv_func_malloc_0_nonnull+:} false; then :
20119 printf %s "(cached) " >&6
20121 if test "$cross_compiling" = yes; then :
20123 # Guess yes on platforms where we know the result.
20124 *-gnu* | freebsd* | netbsd* | openbsd* \
20125 | hpux* | solaris* | cygwin* | mingw*)
20126 ac_cv_func_malloc_0_nonnull=yes ;;
20127 # If we don't know, assume the worst.
20128 *) ac_cv_func_malloc_0_nonnull=no ;;
20132 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20133 /* end confdefs.h. */
20134 #if defined STDC_HEADERS || defined HAVE_STDLIB_H
20135 # include <stdlib.h>
20143 return ! malloc (0);
20149 if ac_fn_c_try_run "$LINENO"; then :
20150 ac_cv_func_malloc_0_nonnull=yes
20152 ac_cv_func_malloc_0_nonnull=no
20154 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20155 conftest.$ac_objext conftest.beam conftest.$ac_ext
20160 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_malloc_0_nonnull" >&5
20161 printf "%s\n" "$ac_cv_func_malloc_0_nonnull" >&6; }
20162 if test $ac_cv_func_malloc_0_nonnull = yes; then :
20164 printf "%s\n" "#define HAVE_MALLOC_GNU 1" >>confdefs.h
20167 printf "%s\n" "#define HAVE_MALLOC_GNU 0" >>confdefs.h
20174 if test $REPLACE_MALLOC = 1; then
20183 gl_LIBOBJS="$gl_LIBOBJS malloc.$ac_objext"
20188 cat >>confdefs.h <<_ACEOF
20189 #define GNULIB_MALLOC_GNU 1
20196 if test $gl_cv_func_malloc_posix = yes; then
20198 printf "%s\n" "#define HAVE_MALLOC_POSIX 1" >>confdefs.h
20204 if test $REPLACE_MALLOC = 1; then
20213 gl_LIBOBJS="$gl_LIBOBJS malloc.$ac_objext"
20221 GNULIB_MALLOC_POSIX=1
20227 printf "%s\n" "#define GNULIB_TEST_MALLOC_POSIX 1" >>confdefs.h
20252 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
20256 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
20257 printf %s "checking whether mbrtowc handles incomplete characters... " >&6; }
20258 if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then :
20259 printf %s "(cached) " >&6
20263 # Guess no on AIX and OSF/1.
20264 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
20265 # Guess yes otherwise.
20266 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
20268 if test $LOCALE_JA != none; then
20269 if test "$cross_compiling" = yes; then :
20272 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20273 /* end confdefs.h. */
20275 #include <locale.h>
20276 #include <string.h>
20277 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
20279 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20280 included before <wchar.h>. */
20281 #include <stddef.h>
20287 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
20289 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
20293 memset (&state, '\0', sizeof (mbstate_t));
20294 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
20295 if (mbsinit (&state))
20301 if ac_fn_c_try_run "$LINENO"; then :
20302 gl_cv_func_mbrtowc_incomplete_state=yes
20304 gl_cv_func_mbrtowc_incomplete_state=no
20306 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20307 conftest.$ac_objext conftest.beam conftest.$ac_ext
20313 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
20314 printf "%s\n" "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
20319 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
20320 printf %s "checking whether mbrtowc works as well as mbtowc... " >&6; }
20321 if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then :
20322 printf %s "(cached) " >&6
20326 # Guess no on Solaris 8.
20327 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
20328 # Guess yes otherwise.
20329 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
20331 if test $LOCALE_ZH_CN != none; then
20332 if test "$cross_compiling" = yes; then :
20335 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20336 /* end confdefs.h. */
20338 #include <locale.h>
20339 #include <stdlib.h>
20340 #include <string.h>
20341 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
20343 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20344 included before <wchar.h>. */
20345 #include <stddef.h>
20351 /* This fails on Solaris 8:
20352 mbrtowc returns 2, and sets wc to 0x00F0.
20353 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
20354 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
20356 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
20360 memset (&state, '\0', sizeof (mbstate_t));
20361 if (mbrtowc (&wc, input + 3, 6, &state) != 4
20362 && mbtowc (&wc, input + 3, 6) == 4)
20368 if ac_fn_c_try_run "$LINENO"; then :
20369 gl_cv_func_mbrtowc_sanitycheck=yes
20371 gl_cv_func_mbrtowc_sanitycheck=no
20373 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20374 conftest.$ac_objext conftest.beam conftest.$ac_ext
20380 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
20381 printf "%s\n" "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
20383 REPLACE_MBSTATE_T=0
20384 case "$gl_cv_func_mbrtowc_incomplete_state" in
20386 *) REPLACE_MBSTATE_T=1 ;;
20388 case "$gl_cv_func_mbrtowc_sanitycheck" in
20390 *) REPLACE_MBSTATE_T=1 ;;
20393 REPLACE_MBSTATE_T=1
20398 if test $ac_cv_func_mbrtowc = no; then
20400 ac_fn_c_check_decl "$LINENO" "mbrtowc" "ac_cv_have_decl_mbrtowc" "
20401 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
20403 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20404 included before <wchar.h>. */
20405 #include <stddef.h>
20411 if test "x$ac_cv_have_decl_mbrtowc" = xyes; then :
20417 cat >>confdefs.h <<_ACEOF
20418 #define HAVE_DECL_MBRTOWC $ac_have_decl
20421 if test $ac_cv_have_decl_mbrtowc = yes; then
20425 if test $REPLACE_MBSTATE_T = 1; then
20431 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles a NULL pwc argument" >&5
20432 printf %s "checking whether mbrtowc handles a NULL pwc argument... " >&6; }
20433 if ${gl_cv_func_mbrtowc_null_arg1+:} false; then :
20434 printf %s "(cached) " >&6
20438 # Guess no on Solaris.
20439 solaris*) gl_cv_func_mbrtowc_null_arg1="guessing no" ;;
20440 # Guess yes otherwise.
20441 *) gl_cv_func_mbrtowc_null_arg1="guessing yes" ;;
20443 if test $LOCALE_FR_UTF8 != none; then
20444 if test "$cross_compiling" = yes; then :
20447 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20448 /* end confdefs.h. */
20450 #include <locale.h>
20451 #include <stdlib.h>
20452 #include <string.h>
20453 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
20455 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20456 included before <wchar.h>. */
20457 #include <stddef.h>
20465 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
20467 char input[] = "\303\237er";
20472 memset (&state, '\0', sizeof (mbstate_t));
20473 wc = (wchar_t) 0xBADFACE;
20474 ret = mbrtowc (&wc, input, 5, &state);
20477 if (!mbsinit (&state))
20480 memset (&state, '\0', sizeof (mbstate_t));
20481 ret = mbrtowc (NULL, input, 5, &state);
20482 if (ret != 2) /* Solaris 7 fails here: ret is -1. */
20484 if (!mbsinit (&state))
20490 if ac_fn_c_try_run "$LINENO"; then :
20491 gl_cv_func_mbrtowc_null_arg1=yes
20493 gl_cv_func_mbrtowc_null_arg1=no
20495 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20496 conftest.$ac_objext conftest.beam conftest.$ac_ext
20502 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_null_arg1" >&5
20503 printf "%s\n" "$gl_cv_func_mbrtowc_null_arg1" >&6; }
20508 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles a NULL string argument" >&5
20509 printf %s "checking whether mbrtowc handles a NULL string argument... " >&6; }
20510 if ${gl_cv_func_mbrtowc_null_arg2+:} false; then :
20511 printf %s "(cached) " >&6
20515 # Guess no on OSF/1.
20516 osf*) gl_cv_func_mbrtowc_null_arg2="guessing no" ;;
20517 # Guess yes otherwise.
20518 *) gl_cv_func_mbrtowc_null_arg2="guessing yes" ;;
20520 if test $LOCALE_FR_UTF8 != none; then
20521 if test "$cross_compiling" = yes; then :
20524 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20525 /* end confdefs.h. */
20527 #include <locale.h>
20528 #include <string.h>
20529 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
20531 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20532 included before <wchar.h>. */
20533 #include <stddef.h>
20539 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
20545 memset (&state, '\0', sizeof (mbstate_t));
20546 wc = (wchar_t) 0xBADFACE;
20547 mbrtowc (&wc, NULL, 5, &state);
20548 /* Check that wc was not modified. */
20549 if (wc != (wchar_t) 0xBADFACE)
20555 if ac_fn_c_try_run "$LINENO"; then :
20556 gl_cv_func_mbrtowc_null_arg2=yes
20558 gl_cv_func_mbrtowc_null_arg2=no
20560 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20561 conftest.$ac_objext conftest.beam conftest.$ac_ext
20567 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_null_arg2" >&5
20568 printf "%s\n" "$gl_cv_func_mbrtowc_null_arg2" >&6; }
20575 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc has a correct return value" >&5
20576 printf %s "checking whether mbrtowc has a correct return value... " >&6; }
20577 if ${gl_cv_func_mbrtowc_retval+:} false; then :
20578 printf %s "(cached) " >&6
20582 # Guess no on HP-UX, Solaris, native Windows.
20583 hpux* | solaris* | mingw*) gl_cv_func_mbrtowc_retval="guessing no" ;;
20584 # Guess yes otherwise.
20585 *) gl_cv_func_mbrtowc_retval="guessing yes" ;;
20587 if test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none \
20588 || { case "$host_os" in mingw*) true;; *) false;; esac; }; then
20589 if test "$cross_compiling" = yes; then :
20592 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20593 /* end confdefs.h. */
20595 #include <locale.h>
20596 #include <string.h>
20597 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
20599 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20600 included before <wchar.h>. */
20601 #include <stddef.h>
20608 int found_some_locale = 0;
20609 /* This fails on Solaris. */
20610 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
20612 char input[] = "B\303\274\303\237er"; /* "Büßer" */
20616 memset (&state, '\0', sizeof (mbstate_t));
20617 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
20620 if (mbrtowc (&wc, input + 2, 5, &state) != 1)
20623 found_some_locale = 1;
20625 /* This fails on HP-UX 11.11. */
20626 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
20628 char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
20632 memset (&state, '\0', sizeof (mbstate_t));
20633 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
20636 if (mbrtowc (&wc, input + 2, 5, &state) != 2)
20639 found_some_locale = 1;
20641 /* This fails on native Windows. */
20642 if (setlocale (LC_ALL, "Japanese_Japan.932") != NULL)
20644 char input[] = "<\223\372\226\173\214\352>"; /* "<日本語>" */
20648 memset (&state, '\0', sizeof (mbstate_t));
20649 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
20652 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
20655 found_some_locale = 1;
20657 if (setlocale (LC_ALL, "Chinese_Taiwan.950") != NULL)
20659 char input[] = "<\244\351\245\273\273\171>"; /* "<日本語>" */
20663 memset (&state, '\0', sizeof (mbstate_t));
20664 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
20667 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
20670 found_some_locale = 1;
20672 if (setlocale (LC_ALL, "Chinese_China.936") != NULL)
20674 char input[] = "<\310\325\261\276\325\132>"; /* "<日本語>" */
20678 memset (&state, '\0', sizeof (mbstate_t));
20679 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
20682 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
20685 found_some_locale = 1;
20687 return (found_some_locale ? result : 77);
20690 if ac_fn_c_try_run "$LINENO"; then :
20691 gl_cv_func_mbrtowc_retval=yes
20693 if test $? != 77; then
20694 gl_cv_func_mbrtowc_retval=no
20698 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20699 conftest.$ac_objext conftest.beam conftest.$ac_ext
20705 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_retval" >&5
20706 printf "%s\n" "$gl_cv_func_mbrtowc_retval" >&6; }
20711 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc returns 0 when parsing a NUL character" >&5
20712 printf %s "checking whether mbrtowc returns 0 when parsing a NUL character... " >&6; }
20713 if ${gl_cv_func_mbrtowc_nul_retval+:} false; then :
20714 printf %s "(cached) " >&6
20718 # Guess no on Solaris 8 and 9.
20719 solaris2.[89]) gl_cv_func_mbrtowc_nul_retval="guessing no" ;;
20720 # Guess yes otherwise.
20721 *) gl_cv_func_mbrtowc_nul_retval="guessing yes" ;;
20723 if test $LOCALE_ZH_CN != none; then
20724 if test "$cross_compiling" = yes; then :
20727 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20728 /* end confdefs.h. */
20730 #include <locale.h>
20731 #include <string.h>
20732 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
20734 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20735 included before <wchar.h>. */
20736 #include <stddef.h>
20742 /* This fails on Solaris 8 and 9. */
20743 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
20748 memset (&state, '\0', sizeof (mbstate_t));
20749 if (mbrtowc (&wc, "", 1, &state) != 0)
20755 if ac_fn_c_try_run "$LINENO"; then :
20756 gl_cv_func_mbrtowc_nul_retval=yes
20758 gl_cv_func_mbrtowc_nul_retval=no
20760 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20761 conftest.$ac_objext conftest.beam conftest.$ac_ext
20767 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_nul_retval" >&5
20768 printf "%s\n" "$gl_cv_func_mbrtowc_nul_retval" >&6; }
20770 case "$gl_cv_func_mbrtowc_null_arg1" in
20773 printf "%s\n" "#define MBRTOWC_NULL_ARG1_BUG 1" >>confdefs.h
20778 case "$gl_cv_func_mbrtowc_null_arg2" in
20781 printf "%s\n" "#define MBRTOWC_NULL_ARG2_BUG 1" >>confdefs.h
20786 case "$gl_cv_func_mbrtowc_retval" in
20789 printf "%s\n" "#define MBRTOWC_RETVAL_BUG 1" >>confdefs.h
20794 case "$gl_cv_func_mbrtowc_nul_retval" in
20797 printf "%s\n" "#define MBRTOWC_NUL_RETVAL_BUG 1" >>confdefs.h
20805 if test $HAVE_MBRTOWC = 0 || test $REPLACE_MBRTOWC = 1; then
20814 gl_LIBOBJS="$gl_LIBOBJS mbrtowc.$ac_objext"
20831 printf "%s\n" "#define GNULIB_TEST_MBRTOWC 1" >>confdefs.h
20840 GNULIB_MBSCASECMP=1
20846 printf "%s\n" "#define GNULIB_TEST_MBSCASECMP 1" >>confdefs.h
20861 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
20865 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
20866 printf %s "checking whether mbrtowc handles incomplete characters... " >&6; }
20867 if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then :
20868 printf %s "(cached) " >&6
20872 # Guess no on AIX and OSF/1.
20873 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
20874 # Guess yes otherwise.
20875 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
20877 if test $LOCALE_JA != none; then
20878 if test "$cross_compiling" = yes; then :
20881 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20882 /* end confdefs.h. */
20884 #include <locale.h>
20885 #include <string.h>
20886 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
20888 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20889 included before <wchar.h>. */
20890 #include <stddef.h>
20896 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
20898 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
20902 memset (&state, '\0', sizeof (mbstate_t));
20903 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
20904 if (mbsinit (&state))
20910 if ac_fn_c_try_run "$LINENO"; then :
20911 gl_cv_func_mbrtowc_incomplete_state=yes
20913 gl_cv_func_mbrtowc_incomplete_state=no
20915 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20916 conftest.$ac_objext conftest.beam conftest.$ac_ext
20922 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
20923 printf "%s\n" "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
20928 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
20929 printf %s "checking whether mbrtowc works as well as mbtowc... " >&6; }
20930 if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then :
20931 printf %s "(cached) " >&6
20935 # Guess no on Solaris 8.
20936 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
20937 # Guess yes otherwise.
20938 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
20940 if test $LOCALE_ZH_CN != none; then
20941 if test "$cross_compiling" = yes; then :
20944 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20945 /* end confdefs.h. */
20947 #include <locale.h>
20948 #include <stdlib.h>
20949 #include <string.h>
20950 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
20952 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20953 included before <wchar.h>. */
20954 #include <stddef.h>
20960 /* This fails on Solaris 8:
20961 mbrtowc returns 2, and sets wc to 0x00F0.
20962 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
20963 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
20965 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
20969 memset (&state, '\0', sizeof (mbstate_t));
20970 if (mbrtowc (&wc, input + 3, 6, &state) != 4
20971 && mbtowc (&wc, input + 3, 6) == 4)
20977 if ac_fn_c_try_run "$LINENO"; then :
20978 gl_cv_func_mbrtowc_sanitycheck=yes
20980 gl_cv_func_mbrtowc_sanitycheck=no
20982 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20983 conftest.$ac_objext conftest.beam conftest.$ac_ext
20989 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
20990 printf "%s\n" "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
20992 REPLACE_MBSTATE_T=0
20993 case "$gl_cv_func_mbrtowc_incomplete_state" in
20995 *) REPLACE_MBSTATE_T=1 ;;
20997 case "$gl_cv_func_mbrtowc_sanitycheck" in
20999 *) REPLACE_MBSTATE_T=1 ;;
21002 REPLACE_MBSTATE_T=1
21007 if test $ac_cv_func_mbsinit = no; then
21009 ac_fn_c_check_decl "$LINENO" "mbsinit" "ac_cv_have_decl_mbsinit" "
21010 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
21012 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
21013 included before <wchar.h>. */
21014 #include <stddef.h>
21020 if test "x$ac_cv_have_decl_mbsinit" = xyes; then :
21026 cat >>confdefs.h <<_ACEOF
21027 #define HAVE_DECL_MBSINIT $ac_have_decl
21030 if test $ac_cv_have_decl_mbsinit = yes; then
21034 if test $REPLACE_MBSTATE_T = 1; then
21038 mingw*) REPLACE_MBSINIT=1 ;;
21043 if test $HAVE_MBSINIT = 0 || test $REPLACE_MBSINIT = 1; then
21052 gl_LIBOBJS="$gl_LIBOBJS mbsinit.$ac_objext"
21069 printf "%s\n" "#define GNULIB_TEST_MBSINIT 1" >>confdefs.h
21076 if test $ac_cv_func_mbslen = yes; then
21093 printf "%s\n" "#define GNULIB_TEST_MBSLEN 1" >>confdefs.h
21107 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
21111 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
21112 printf %s "checking whether mbrtowc handles incomplete characters... " >&6; }
21113 if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then :
21114 printf %s "(cached) " >&6
21118 # Guess no on AIX and OSF/1.
21119 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
21120 # Guess yes otherwise.
21121 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
21123 if test $LOCALE_JA != none; then
21124 if test "$cross_compiling" = yes; then :
21127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21128 /* end confdefs.h. */
21130 #include <locale.h>
21131 #include <string.h>
21132 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
21134 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
21135 included before <wchar.h>. */
21136 #include <stddef.h>
21142 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
21144 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
21148 memset (&state, '\0', sizeof (mbstate_t));
21149 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
21150 if (mbsinit (&state))
21156 if ac_fn_c_try_run "$LINENO"; then :
21157 gl_cv_func_mbrtowc_incomplete_state=yes
21159 gl_cv_func_mbrtowc_incomplete_state=no
21161 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21162 conftest.$ac_objext conftest.beam conftest.$ac_ext
21168 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
21169 printf "%s\n" "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
21174 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
21175 printf %s "checking whether mbrtowc works as well as mbtowc... " >&6; }
21176 if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then :
21177 printf %s "(cached) " >&6
21181 # Guess no on Solaris 8.
21182 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
21183 # Guess yes otherwise.
21184 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
21186 if test $LOCALE_ZH_CN != none; then
21187 if test "$cross_compiling" = yes; then :
21190 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21191 /* end confdefs.h. */
21193 #include <locale.h>
21194 #include <stdlib.h>
21195 #include <string.h>
21196 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
21198 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
21199 included before <wchar.h>. */
21200 #include <stddef.h>
21206 /* This fails on Solaris 8:
21207 mbrtowc returns 2, and sets wc to 0x00F0.
21208 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
21209 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
21211 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
21215 memset (&state, '\0', sizeof (mbstate_t));
21216 if (mbrtowc (&wc, input + 3, 6, &state) != 4
21217 && mbtowc (&wc, input + 3, 6) == 4)
21223 if ac_fn_c_try_run "$LINENO"; then :
21224 gl_cv_func_mbrtowc_sanitycheck=yes
21226 gl_cv_func_mbrtowc_sanitycheck=no
21228 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21229 conftest.$ac_objext conftest.beam conftest.$ac_ext
21235 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
21236 printf "%s\n" "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
21238 REPLACE_MBSTATE_T=0
21239 case "$gl_cv_func_mbrtowc_incomplete_state" in
21241 *) REPLACE_MBSTATE_T=1 ;;
21243 case "$gl_cv_func_mbrtowc_sanitycheck" in
21245 *) REPLACE_MBSTATE_T=1 ;;
21248 REPLACE_MBSTATE_T=1
21253 if test $ac_cv_func_mbsrtowcs = no; then
21255 ac_fn_c_check_decl "$LINENO" "mbsrtowcs" "ac_cv_have_decl_mbsrtowcs" "
21256 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
21258 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
21259 included before <wchar.h>. */
21260 #include <stddef.h>
21266 if test "x$ac_cv_have_decl_mbsrtowcs" = xyes; then :
21272 cat >>confdefs.h <<_ACEOF
21273 #define HAVE_DECL_MBSRTOWCS $ac_have_decl
21276 if test $ac_cv_have_decl_mbsrtowcs = yes; then
21277 REPLACE_MBSRTOWCS=1
21280 if test $REPLACE_MBSTATE_T = 1; then
21281 REPLACE_MBSRTOWCS=1
21289 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether mbsrtowcs works" >&5
21290 printf %s "checking whether mbsrtowcs works... " >&6; }
21291 if ${gl_cv_func_mbsrtowcs_works+:} false; then :
21292 printf %s "(cached) " >&6
21296 # Guess no on HP-UX, Solaris, mingw.
21297 hpux* | solaris* | mingw*) gl_cv_func_mbsrtowcs_works="guessing no" ;;
21298 # Guess yes otherwise.
21299 *) gl_cv_func_mbsrtowcs_works="guessing yes" ;;
21301 if test $LOCALE_FR != none || test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none || test $LOCALE_ZH_CN != none; then
21302 if test "$cross_compiling" = yes; then :
21305 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21306 /* end confdefs.h. */
21308 #include <locale.h>
21309 #include <string.h>
21310 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
21312 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
21313 included before <wchar.h>. */
21314 #include <stddef.h>
21321 /* Test whether the function supports a NULL destination argument.
21322 This fails on native Windows. */
21323 if (setlocale (LC_ALL, "$LOCALE_FR") != NULL)
21325 const char input[] = "\337er";
21326 const char *src = input;
21329 memset (&state, '\0', sizeof (mbstate_t));
21330 if (mbsrtowcs (NULL, &src, 1, &state) != 3
21334 /* Test whether the function works when started with a conversion state
21335 in non-initial state. This fails on HP-UX 11.11 and Solaris 10. */
21336 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
21338 const char input[] = "B\303\274\303\237er";
21341 memset (&state, '\0', sizeof (mbstate_t));
21342 if (mbrtowc (NULL, input + 1, 1, &state) == (size_t)(-2))
21343 if (!mbsinit (&state))
21345 const char *src = input + 2;
21346 if (mbsrtowcs (NULL, &src, 10, &state) != 4)
21350 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
21352 const char input[] = "<\306\374\313\334\270\354>";
21355 memset (&state, '\0', sizeof (mbstate_t));
21356 if (mbrtowc (NULL, input + 3, 1, &state) == (size_t)(-2))
21357 if (!mbsinit (&state))
21359 const char *src = input + 4;
21360 if (mbsrtowcs (NULL, &src, 10, &state) != 3)
21364 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
21366 const char input[] = "B\250\271\201\060\211\070er";
21369 memset (&state, '\0', sizeof (mbstate_t));
21370 if (mbrtowc (NULL, input + 1, 1, &state) == (size_t)(-2))
21371 if (!mbsinit (&state))
21373 const char *src = input + 2;
21374 if (mbsrtowcs (NULL, &src, 10, &state) != 4)
21381 if ac_fn_c_try_run "$LINENO"; then :
21382 gl_cv_func_mbsrtowcs_works=yes
21384 gl_cv_func_mbsrtowcs_works=no
21386 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21387 conftest.$ac_objext conftest.beam conftest.$ac_ext
21393 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbsrtowcs_works" >&5
21394 printf "%s\n" "$gl_cv_func_mbsrtowcs_works" >&6; }
21396 case "$gl_cv_func_mbsrtowcs_works" in
21398 *) REPLACE_MBSRTOWCS=1 ;;
21403 if test $HAVE_MBSRTOWCS = 0 || test $REPLACE_MBSRTOWCS = 1; then
21412 gl_LIBOBJS="$gl_LIBOBJS mbsrtowcs.$ac_objext"
21422 gl_LIBOBJS="$gl_LIBOBJS mbsrtowcs-state.$ac_objext"
21439 printf "%s\n" "#define GNULIB_TEST_MBSRTOWCS 1" >>confdefs.h
21454 printf "%s\n" "#define GNULIB_TEST_MBSSTR 1" >>confdefs.h
21465 if test $REPLACE_MBTOWC = 1; then
21474 gl_LIBOBJS="$gl_LIBOBJS mbtowc.$ac_objext"
21491 printf "%s\n" "#define GNULIB_TEST_MBTOWC 1" >>confdefs.h
21500 if test $HAVE_MEMCHR = 0 || test $REPLACE_MEMCHR = 1; then
21509 gl_LIBOBJS="$gl_LIBOBJS memchr.$ac_objext"
21512 for ac_header in bp-sym.h
21514 ac_fn_c_check_header_mongrel "$LINENO" "bp-sym.h" "ac_cv_header_bp_sym_h" "$ac_includes_default"
21515 if test "x$ac_cv_header_bp_sym_h" = xyes; then :
21516 cat >>confdefs.h <<_ACEOF
21517 #define HAVE_BP_SYM_H 1
21537 printf "%s\n" "#define GNULIB_TEST_MEMCHR 1" >>confdefs.h
21545 if test $ac_cv_func_mkstemp = yes; then
21546 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working mkstemp" >&5
21547 printf %s "checking for working mkstemp... " >&6; }
21548 if ${gl_cv_func_working_mkstemp+:} false; then :
21549 printf %s "(cached) " >&6
21552 mkdir conftest.mkstemp
21553 if test "$cross_compiling" = yes; then :
21555 # Guess yes on glibc systems.
21556 *-gnu*) gl_cv_func_working_mkstemp="guessing yes" ;;
21557 # If we don't know, assume the worst.
21558 *) gl_cv_func_working_mkstemp="guessing no" ;;
21562 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21563 /* end confdefs.h. */
21564 $ac_includes_default
21570 off_t large = (off_t) 4294967295u;
21572 large = 2147483647;
21574 for (i = 0; i < 70; i++)
21576 char templ[] = "conftest.mkstemp/coXXXXXX";
21577 int (*mkstemp_function) (char *) = mkstemp;
21578 int fd = mkstemp_function (templ);
21584 if (lseek (fd, large, SEEK_SET) != large)
21586 if (fstat (fd, &st) < 0)
21588 else if (st.st_mode & 0077)
21599 if ac_fn_c_try_run "$LINENO"; then :
21600 gl_cv_func_working_mkstemp=yes
21602 gl_cv_func_working_mkstemp=no
21604 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21605 conftest.$ac_objext conftest.beam conftest.$ac_ext
21608 rm -rf conftest.mkstemp
21611 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mkstemp" >&5
21612 printf "%s\n" "$gl_cv_func_working_mkstemp" >&6; }
21613 case "$gl_cv_func_working_mkstemp" in
21623 if test $HAVE_MKSTEMP = 0 || test $REPLACE_MKSTEMP = 1; then
21632 gl_LIBOBJS="$gl_LIBOBJS mkstemp.$ac_objext"
21648 printf "%s\n" "#define GNULIB_TEST_MKSTEMP 1" >>confdefs.h
21658 if test $APPLE_UNIVERSAL_BUILD = 1; then
21659 # A universal build on Apple Mac OS X platforms.
21660 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
21661 # But we need a configuration result that is valid in both modes.
21662 gl_cv_func_working_mktime=no
21664 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
21665 printf %s "checking for working mktime... " >&6; }
21666 if ${gl_cv_func_working_mktime+:} false; then :
21667 printf %s "(cached) " >&6
21669 if test "$cross_compiling" = yes; then :
21670 gl_cv_func_working_mktime=no
21672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21673 /* end confdefs.h. */
21674 /* Test program from Paul Eggert and Tony Leneis. */
21675 #include <limits.h>
21676 #include <stdlib.h>
21679 #ifdef HAVE_UNISTD_H
21680 # include <unistd.h>
21683 #if HAVE_DECL_ALARM
21684 # include <signal.h>
21687 /* Work around redefinition to rpl_putenv by other config tests. */
21690 static time_t time_t_max;
21691 static time_t time_t_min;
21693 /* Values we'll use to set the TZ environment variable. */
21694 static char *tz_strings[] = {
21695 (char *) 0, "TZ=GMT0", "TZ=JST-9",
21696 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
21698 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
21700 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
21701 Based on a problem report from Andreas Jaeger. */
21703 spring_forward_gap ()
21705 /* glibc (up to about 1998-10-07) failed this test. */
21708 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
21709 instead of "TZ=America/Vancouver" in order to detect the bug even
21710 on systems that don't support the Olson extension, or don't have the
21711 full zoneinfo tables installed. */
21712 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
21721 return mktime (&tm) != (time_t) -1;
21725 mktime_test1 (time_t now)
21728 return ! (lt = localtime (&now)) || mktime (lt) == now;
21732 mktime_test (time_t now)
21734 return (mktime_test1 (now)
21735 && mktime_test1 ((time_t) (time_t_max - now))
21736 && mktime_test1 ((time_t) (time_t_min + now)));
21742 /* Based on code from Ariel Faigon. */
21752 return tm.tm_mon == 2 && tm.tm_mday == 31;
21756 bigtime_test (int j)
21760 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
21761 now = mktime (&tm);
21762 if (now != (time_t) -1)
21764 struct tm *lt = localtime (&now);
21766 && lt->tm_year == tm.tm_year
21767 && lt->tm_mon == tm.tm_mon
21768 && lt->tm_mday == tm.tm_mday
21769 && lt->tm_hour == tm.tm_hour
21770 && lt->tm_min == tm.tm_min
21771 && lt->tm_sec == tm.tm_sec
21772 && lt->tm_yday == tm.tm_yday
21773 && lt->tm_wday == tm.tm_wday
21774 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
21775 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
21784 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
21785 ignoring leap seconds. */
21786 unsigned long int answer = 2527315200UL;
21790 tm.tm_year = 2050 - 1900;
21793 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
21796 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
21797 instead of "TZ=America/Vancouver" in order to detect the bug even
21798 on systems that don't support the Olson extension, or don't have the
21799 full zoneinfo tables installed. */
21800 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
21804 /* Check that the result is either a failure, or close enough
21805 to the correct answer that we can assume the discrepancy is
21806 due to leap seconds. */
21807 return (t == (time_t) -1
21808 || (0 < t && answer - 120 <= t && t <= answer + 120));
21817 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
21818 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
21820 #if HAVE_DECL_ALARM
21821 /* This test makes some buggy mktime implementations loop.
21822 Give up after 60 seconds; a mktime slower than that
21823 isn't worth using anyway. */
21824 signal (SIGALRM, SIG_DFL);
21828 time_t_max = (! time_t_signed
21830 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
21832 time_t_min = (! time_t_signed
21834 : time_t_signed_magnitude
21838 delta = time_t_max / 997; /* a suitable prime number */
21839 for (i = 0; i < N_STRINGS; i++)
21842 putenv (tz_strings[i]);
21844 for (t = 0; t <= time_t_max - delta && (result & 1) == 0; t += delta)
21845 if (! mktime_test (t))
21847 if ((result & 2) == 0
21848 && ! (mktime_test ((time_t) 1)
21849 && mktime_test ((time_t) (60 * 60))
21850 && mktime_test ((time_t) (60 * 60 * 24))))
21853 for (j = 1; (result & 4) == 0; j <<= 1)
21855 if (! bigtime_test (j))
21857 if (INT_MAX / 2 < j)
21860 if ((result & 8) == 0 && ! bigtime_test (INT_MAX))
21863 if (! irix_6_4_bug ())
21865 if (! spring_forward_gap ())
21867 if (! year_2050_test ())
21872 if ac_fn_c_try_run "$LINENO"; then :
21873 gl_cv_func_working_mktime=yes
21875 gl_cv_func_working_mktime=no
21877 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21878 conftest.$ac_objext conftest.beam conftest.$ac_ext
21883 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
21884 printf "%s\n" "$gl_cv_func_working_mktime" >&6; }
21886 if test $gl_cv_func_working_mktime = no; then
21892 if test $REPLACE_MKTIME = 1; then
21901 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
21916 printf "%s\n" "#define GNULIB_TEST_MKTIME 1" >>confdefs.h
21922 if test $ac_cv_func__set_invalid_parameter_handler = yes; then
21923 HAVE_MSVC_INVALID_PARAMETER_HANDLER=1
21925 printf "%s\n" "#define HAVE_MSVC_INVALID_PARAMETER_HANDLER 1" >>confdefs.h
21928 HAVE_MSVC_INVALID_PARAMETER_HANDLER=0
21932 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
21941 gl_LIBOBJS="$gl_LIBOBJS msvc-inval.$ac_objext"
21947 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
21956 gl_LIBOBJS="$gl_LIBOBJS msvc-nothrow.$ac_objext"
21964 if test $ac_cv_func_nl_langinfo = yes; then
21965 # On Irix 6.5, YESEXPR is defined, but nl_langinfo(YESEXPR) is broken.
21966 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether YESEXPR works" >&5
21967 printf %s "checking whether YESEXPR works... " >&6; }
21968 if ${gl_cv_func_nl_langinfo_yesexpr_works+:} false; then :
21969 printf %s "(cached) " >&6
21971 if test "$cross_compiling" = yes; then :
21974 # Guess no on irix systems.
21975 irix*) gl_cv_func_nl_langinfo_yesexpr_works="guessing no";;
21976 # Guess yes elsewhere.
21977 *) gl_cv_func_nl_langinfo_yesexpr_works="guessing yes";;
21981 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21982 /* end confdefs.h. */
21983 #include <langinfo.h>
21988 return !*nl_langinfo(YESEXPR);
21994 if ac_fn_c_try_run "$LINENO"; then :
21995 gl_cv_func_nl_langinfo_yesexpr_works=yes
21997 gl_cv_func_nl_langinfo_yesexpr_works=no
21999 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22000 conftest.$ac_objext conftest.beam conftest.$ac_ext
22005 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_nl_langinfo_yesexpr_works" >&5
22006 printf "%s\n" "$gl_cv_func_nl_langinfo_yesexpr_works" >&6; }
22007 case $gl_cv_func_nl_langinfo_yesexpr_works in
22008 *yes) FUNC_NL_LANGINFO_YESEXPR_WORKS=1 ;;
22009 *) FUNC_NL_LANGINFO_YESEXPR_WORKS=0 ;;
22012 cat >>confdefs.h <<_ACEOF
22013 #define FUNC_NL_LANGINFO_YESEXPR_WORKS $FUNC_NL_LANGINFO_YESEXPR_WORKS
22016 if test $HAVE_LANGINFO_CODESET = 1 && test $HAVE_LANGINFO_ERA = 1 \
22017 && test $FUNC_NL_LANGINFO_YESEXPR_WORKS = 1; then
22020 REPLACE_NL_LANGINFO=1
22022 printf "%s\n" "#define REPLACE_NL_LANGINFO 1" >>confdefs.h
22029 if test $HAVE_NL_LANGINFO = 0 || test $REPLACE_NL_LANGINFO = 1; then
22038 gl_LIBOBJS="$gl_LIBOBJS nl_langinfo.$ac_objext"
22046 GNULIB_NL_LANGINFO=1
22052 printf "%s\n" "#define GNULIB_TEST_NL_LANGINFO 1" >>confdefs.h
22064 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether open recognizes a trailing slash" >&5
22065 printf %s "checking whether open recognizes a trailing slash... " >&6; }
22066 if ${gl_cv_func_open_slash+:} false; then :
22067 printf %s "(cached) " >&6
22069 # Assume that if we have lstat, we can also check symlinks.
22070 if test $ac_cv_func_lstat = yes; then
22072 ln -s conftest.tmp conftest.lnk
22074 if test "$cross_compiling" = yes; then :
22077 freebsd* | aix* | hpux* | solaris2.[0-9] | solaris2.[0-9].*)
22078 gl_cv_func_open_slash="guessing no" ;;
22080 gl_cv_func_open_slash="guessing yes" ;;
22084 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22085 /* end confdefs.h. */
22089 # include <unistd.h>
22095 if (open ("conftest.lnk/", O_RDONLY) != -1)
22098 if (open ("conftest.sl/", O_CREAT, 0600) >= 0)
22103 if ac_fn_c_try_run "$LINENO"; then :
22104 gl_cv_func_open_slash=yes
22106 gl_cv_func_open_slash=no
22108 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22109 conftest.$ac_objext conftest.beam conftest.$ac_ext
22112 rm -f conftest.sl conftest.tmp conftest.lnk
22115 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_open_slash" >&5
22116 printf "%s\n" "$gl_cv_func_open_slash" >&6; }
22117 case "$gl_cv_func_open_slash" in
22120 printf "%s\n" "#define OPEN_TRAILING_SLASH_BUG 1" >>confdefs.h
22130 if test $REPLACE_OPEN = 1; then
22139 gl_LIBOBJS="$gl_LIBOBJS open.$ac_objext"
22157 printf "%s\n" "#define GNULIB_TEST_OPEN 1" >>confdefs.h
22164 ac_fn_c_check_decl "$LINENO" "program_invocation_name" "ac_cv_have_decl_program_invocation_name" "#include <errno.h>
22166 if test "x$ac_cv_have_decl_program_invocation_name" = xyes; then :
22172 cat >>confdefs.h <<_ACEOF
22173 #define HAVE_DECL_PROGRAM_INVOCATION_NAME $ac_have_decl
22176 ac_fn_c_check_decl "$LINENO" "program_invocation_short_name" "ac_cv_have_decl_program_invocation_short_name" "#include <errno.h>
22178 if test "x$ac_cv_have_decl_program_invocation_short_name" = xyes; then :
22184 cat >>confdefs.h <<_ACEOF
22185 #define HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME $ac_have_decl
22190 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --keyword='proper_name:1,\"This is a proper name. See the gettext manual, section Names.\"'"
22194 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --keyword='proper_name_utf8:1,\"This is a proper name. See the gettext manual, section Names.\"'"
22206 for ac_func in raise
22208 ac_fn_c_check_func "$LINENO" "raise" "ac_cv_func_raise"
22209 if test "x$ac_cv_func_raise" = xyes; then :
22210 cat >>confdefs.h <<_ACEOF
22211 #define HAVE_RAISE 1
22217 if test $ac_cv_func_raise = no; then
22220 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
22227 if test $gl_cv_type_sigset_t = yes; then
22228 ac_fn_c_check_func "$LINENO" "sigprocmask" "ac_cv_func_sigprocmask"
22229 if test "x$ac_cv_func_sigprocmask" = xyes; then :
22230 gl_cv_func_sigprocmask=1
22234 if test -z "$gl_cv_func_sigprocmask"; then
22235 HAVE_POSIX_SIGNALBLOCKING=0
22238 if test $HAVE_POSIX_SIGNALBLOCKING = 0; then
22244 if test $HAVE_RAISE = 0 || test $REPLACE_RAISE = 1; then
22253 gl_LIBOBJS="$gl_LIBOBJS raise.$ac_objext"
22268 printf "%s\n" "#define GNULIB_TEST_RAISE 1" >>confdefs.h
22275 if test $ac_cv_func_readlink = no; then
22278 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
22279 printf %s "checking whether readlink signature is correct... " >&6; }
22280 if ${gl_cv_decl_readlink_works+:} false; then :
22281 printf %s "(cached) " >&6
22283 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22284 /* end confdefs.h. */
22285 #include <unistd.h>
22286 /* Cause compilation failure if original declaration has wrong type. */
22287 ssize_t readlink (const char *, char *, size_t);
22296 if ac_fn_c_try_compile "$LINENO"; then :
22297 gl_cv_decl_readlink_works=yes
22299 gl_cv_decl_readlink_works=no
22301 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22303 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
22304 printf "%s\n" "$gl_cv_decl_readlink_works" >&6; }
22305 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
22306 printf %s "checking whether readlink handles trailing slash correctly... " >&6; }
22307 if ${gl_cv_func_readlink_works+:} false; then :
22308 printf %s "(cached) " >&6
22310 # We have readlink, so assume ln -s works.
22311 ln -s conftest.no-such conftest.link
22312 ln -s conftest.link conftest.lnk2
22313 if test "$cross_compiling" = yes; then :
22315 # Guess yes on glibc systems.
22316 *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
22317 # If we don't know, assume the worst.
22318 *) gl_cv_func_readlink_works="guessing no" ;;
22322 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22323 /* end confdefs.h. */
22324 #include <unistd.h>
22330 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
22335 if ac_fn_c_try_run "$LINENO"; then :
22336 gl_cv_func_readlink_works=yes
22338 gl_cv_func_readlink_works=no
22340 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22341 conftest.$ac_objext conftest.beam conftest.$ac_ext
22344 rm -f conftest.link conftest.lnk2
22346 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
22347 printf "%s\n" "$gl_cv_func_readlink_works" >&6; }
22348 case "$gl_cv_func_readlink_works" in
22350 if test "$gl_cv_decl_readlink_works" != yes; then
22356 printf "%s\n" "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
22363 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
22372 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
22389 printf "%s\n" "#define GNULIB_TEST_READLINK 1" >>confdefs.h
22395 # Check whether --with-included-regex was given.
22396 if test "${with_included_regex+set}" = set; then :
22397 withval=$with_included_regex;
22401 case $with_included_regex in #(
22402 yes|no) ac_use_included_regex=$with_included_regex
22405 # If the system regex support is good enough that it passes the
22406 # following run test, then default to *not* using the included regex.c.
22407 # If cross compiling, assume the test would fail and use the included
22410 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working re_compile_pattern" >&5
22411 printf %s "checking for working re_compile_pattern... " >&6; }
22412 if ${gl_cv_func_re_compile_pattern_working+:} false; then :
22413 printf %s "(cached) " >&6
22415 if test "$cross_compiling" = yes; then :
22416 gl_cv_func_re_compile_pattern_working=no
22418 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22419 /* end confdefs.h. */
22422 #include <locale.h>
22423 #include <limits.h>
22424 #include <string.h>
22425 #if HAVE_DECL_ALARM
22426 # include <unistd.h>
22427 # include <signal.h>
22434 static struct re_pattern_buffer regex;
22435 unsigned char folded_chars[UCHAR_MAX + 1];
22438 struct re_registers regs;
22440 #if HAVE_DECL_ALARM
22441 /* Some builds of glibc go into an infinite loop on this test. */
22442 signal (SIGALRM, SIG_DFL);
22445 if (setlocale (LC_ALL, "en_US.UTF-8"))
22448 /* http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html
22449 This test needs valgrind to catch the bug on Debian
22450 GNU/Linux 3.1 x86, but it might catch the bug better
22451 on other platforms and it shouldn't hurt to try the
22453 static char const pat[] = "insert into";
22454 static char const data[] =
22455 "\xFF\0\x12\xA2\xAA\xC4\xB1,K\x12\xC4\xB1*\xACK";
22456 re_set_syntax (RE_SYNTAX_GREP | RE_HAT_LISTS_NOT_NEWLINE
22458 memset (®ex, 0, sizeof regex);
22459 s = re_compile_pattern (pat, sizeof pat - 1, ®ex);
22462 else if (re_search (®ex, data, sizeof data - 1,
22463 0, sizeof data - 1, ®s)
22469 /* This test is from glibc bug 15078.
22470 The test case is from Andreas Schwab in
22471 <http://www.sourceware.org/ml/libc-alpha/2013-01/msg00967.html>.
22473 static char const pat[] = "[^x]x";
22474 static char const data[] =
22475 "\xe1\x80\x80\xe1\x80\xbb\xe1\x80\xbd\xe1\x80\x94\xe1\x80"
22476 "\xba\xe1\x80\xaf\xe1\x80\x95\xe1\x80\xbax";
22478 memset (®ex, 0, sizeof regex);
22479 s = re_compile_pattern (pat, sizeof pat - 1, ®ex);
22482 else if (re_search (®ex, data, sizeof data - 1,
22483 0, sizeof data - 1, 0)
22488 if (! setlocale (LC_ALL, "C"))
22492 /* This test is from glibc bug 3957, reported by Andrew Mackey. */
22493 re_set_syntax (RE_SYNTAX_EGREP | RE_HAT_LISTS_NOT_NEWLINE);
22494 memset (®ex, 0, sizeof regex);
22495 s = re_compile_pattern ("a[^x]b", 6, ®ex);
22498 /* This should fail, but succeeds for glibc-2.5. */
22499 else if (re_search (®ex, "a\nb", 3, 0, 3, ®s) != -1)
22502 /* This regular expression is from Spencer ere test number 75
22504 re_set_syntax (RE_SYNTAX_POSIX_EGREP);
22505 memset (®ex, 0, sizeof regex);
22506 for (i = 0; i <= UCHAR_MAX; i++)
22507 folded_chars[i] = i;
22508 regex.translate = folded_chars;
22509 s = re_compile_pattern ("a[[:]:]]b\n", 11, ®ex);
22510 /* This should fail with _Invalid character class name_ error. */
22514 /* Ensure that [b-a] is diagnosed as invalid, when
22515 using RE_NO_EMPTY_RANGES. */
22516 re_set_syntax (RE_SYNTAX_POSIX_EGREP | RE_NO_EMPTY_RANGES);
22517 memset (®ex, 0, sizeof regex);
22518 s = re_compile_pattern ("a[b-a]", 6, ®ex);
22522 /* This should succeed, but does not for glibc-2.1.3. */
22523 memset (®ex, 0, sizeof regex);
22524 s = re_compile_pattern ("{1", 2, ®ex);
22528 /* The following example is derived from a problem report
22529 against gawk from Jorge Stolfi <stolfi@ic.unicamp.br>. */
22530 memset (®ex, 0, sizeof regex);
22531 s = re_compile_pattern ("[an\371]*n", 7, ®ex);
22534 /* This should match, but does not for glibc-2.2.1. */
22535 else if (re_match (®ex, "an", 2, 0, ®s) != 2)
22538 memset (®ex, 0, sizeof regex);
22539 s = re_compile_pattern ("x", 1, ®ex);
22542 /* glibc-2.2.93 does not work with a negative RANGE argument. */
22543 else if (re_search (®ex, "wxy", 3, 2, -2, ®s) != 1)
22546 /* The version of regex.c in older versions of gnulib
22547 ignored RE_ICASE. Detect that problem too. */
22548 re_set_syntax (RE_SYNTAX_EMACS | RE_ICASE);
22549 memset (®ex, 0, sizeof regex);
22550 s = re_compile_pattern ("x", 1, ®ex);
22553 else if (re_search (®ex, "WXY", 3, 0, 3, ®s) < 0)
22556 /* Catch a bug reported by Vin Shelton in
22557 http://lists.gnu.org/archive/html/bug-coreutils/2007-06/msg00089.html
22559 re_set_syntax (RE_SYNTAX_POSIX_BASIC
22560 & ~RE_CONTEXT_INVALID_DUP
22561 & ~RE_NO_EMPTY_RANGES);
22562 memset (®ex, 0, sizeof regex);
22563 s = re_compile_pattern ("[[:alnum:]_-]\\\\+$", 16, ®ex);
22567 /* REG_STARTEND was added to glibc on 2004-01-15.
22568 Reject older versions. */
22569 if (! REG_STARTEND)
22573 /* It would be nice to reject hosts whose regoff_t values are too
22574 narrow (including glibc on hosts with 64-bit ptrdiff_t and
22575 32-bit int), but we should wait until glibc implements this
22576 feature. Otherwise, support for equivalence classes and
22577 multibyte collation symbols would always be broken except
22578 when compiling --without-included-regex. */
22579 if (sizeof (regoff_t) < sizeof (ptrdiff_t)
22580 || sizeof (regoff_t) < sizeof (ssize_t))
22590 if ac_fn_c_try_run "$LINENO"; then :
22591 gl_cv_func_re_compile_pattern_working=yes
22593 gl_cv_func_re_compile_pattern_working=no
22595 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22596 conftest.$ac_objext conftest.beam conftest.$ac_ext
22600 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_re_compile_pattern_working" >&5
22601 printf "%s\n" "$gl_cv_func_re_compile_pattern_working" >&6; }
22602 case $gl_cv_func_re_compile_pattern_working in #(
22603 yes) ac_use_included_regex=no;; #(
22604 no) ac_use_included_regex=yes;;
22607 *) as_fn_error $? "Invalid value for --with-included-regex: $with_included_regex" "$LINENO" 5
22611 if test $ac_use_included_regex = yes; then
22613 printf "%s\n" "#define _REGEX_INCLUDE_LIMITS_H 1" >>confdefs.h
22616 printf "%s\n" "#define _REGEX_LARGE_OFFSETS 1" >>confdefs.h
22619 printf "%s\n" "#define re_syntax_options rpl_re_syntax_options" >>confdefs.h
22622 printf "%s\n" "#define re_set_syntax rpl_re_set_syntax" >>confdefs.h
22625 printf "%s\n" "#define re_compile_pattern rpl_re_compile_pattern" >>confdefs.h
22628 printf "%s\n" "#define re_compile_fastmap rpl_re_compile_fastmap" >>confdefs.h
22631 printf "%s\n" "#define re_search rpl_re_search" >>confdefs.h
22634 printf "%s\n" "#define re_search_2 rpl_re_search_2" >>confdefs.h
22637 printf "%s\n" "#define re_match rpl_re_match" >>confdefs.h
22640 printf "%s\n" "#define re_match_2 rpl_re_match_2" >>confdefs.h
22643 printf "%s\n" "#define re_set_registers rpl_re_set_registers" >>confdefs.h
22646 printf "%s\n" "#define re_comp rpl_re_comp" >>confdefs.h
22649 printf "%s\n" "#define re_exec rpl_re_exec" >>confdefs.h
22652 printf "%s\n" "#define regcomp rpl_regcomp" >>confdefs.h
22655 printf "%s\n" "#define regexec rpl_regexec" >>confdefs.h
22658 printf "%s\n" "#define regerror rpl_regerror" >>confdefs.h
22661 printf "%s\n" "#define regfree rpl_regfree" >>confdefs.h
22665 if test $ac_use_included_regex = yes; then
22674 gl_LIBOBJS="$gl_LIBOBJS regex.$ac_objext"
22682 for ac_header in libintl.h
22684 ac_fn_c_check_header_mongrel "$LINENO" "libintl.h" "ac_cv_header_libintl_h" "$ac_includes_default"
22685 if test "x$ac_cv_header_libintl_h" = xyes; then :
22686 cat >>confdefs.h <<_ACEOF
22687 #define HAVE_LIBINTL_H 1
22695 ac_fn_c_check_decl "$LINENO" "isblank" "ac_cv_have_decl_isblank" "#include <ctype.h>
22697 if test "x$ac_cv_have_decl_isblank" = xyes; then :
22703 cat >>confdefs.h <<_ACEOF
22704 #define HAVE_DECL_ISBLANK $ac_have_decl
22714 if test $ac_cv_func_secure_getenv = no; then
22715 HAVE_SECURE_GETENV=0
22718 if test $HAVE_SECURE_GETENV = 0; then
22727 gl_LIBOBJS="$gl_LIBOBJS secure_getenv.$ac_objext"
22730 for ac_func in __secure_getenv
22732 ac_fn_c_check_func "$LINENO" "__secure_getenv" "ac_cv_func___secure_getenv"
22733 if test "x$ac_cv_func___secure_getenv" = xyes; then :
22734 cat >>confdefs.h <<_ACEOF
22735 #define HAVE___SECURE_GETENV 1
22741 if test $ac_cv_func___secure_getenv = no; then
22742 for ac_func in issetugid
22744 ac_fn_c_check_func "$LINENO" "issetugid" "ac_cv_func_issetugid"
22745 if test "x$ac_cv_func_issetugid" = xyes; then :
22746 cat >>confdefs.h <<_ACEOF
22747 #define HAVE_ISSETUGID 1
22761 GNULIB_SECURE_GETENV=1
22767 printf "%s\n" "#define GNULIB_TEST_SECURE_GETENV 1" >>confdefs.h
22774 if test $ac_cv_func_sigaction = yes; then
22775 ac_fn_c_check_member "$LINENO" "struct sigaction" "sa_sigaction" "ac_cv_member_struct_sigaction_sa_sigaction" "#include <signal.h>
22777 if test "x$ac_cv_member_struct_sigaction_sa_sigaction" = xyes; then :
22779 cat >>confdefs.h <<_ACEOF
22780 #define HAVE_STRUCT_SIGACTION_SA_SIGACTION 1
22786 if test $ac_cv_member_struct_sigaction_sa_sigaction = no; then
22787 HAVE_STRUCT_SIGACTION_SA_SIGACTION=0
22793 if test $HAVE_SIGACTION = 0; then
22802 gl_LIBOBJS="$gl_LIBOBJS sigaction.$ac_objext"
22810 ac_fn_c_check_type "$LINENO" "siginfo_t" "ac_cv_type_siginfo_t" "
22811 #include <signal.h>
22814 if test "x$ac_cv_type_siginfo_t" = xyes; then :
22816 cat >>confdefs.h <<_ACEOF
22817 #define HAVE_SIGINFO_T 1
22823 if test $ac_cv_type_siginfo_t = no; then
22839 printf "%s\n" "#define GNULIB_TEST_SIGACTION 1" >>confdefs.h
22854 if test $gl_cv_have_include_next = yes; then
22855 gl_cv_next_signal_h='<'signal.h'>'
22857 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
22858 printf %s "checking absolute name of <signal.h>... " >&6; }
22859 if ${gl_cv_next_signal_h+:} false; then :
22860 printf %s "(cached) " >&6
22863 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22864 /* end confdefs.h. */
22865 #include <signal.h>
22869 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22870 *) gl_absname_cpp="$ac_cpp" ;;
22875 gl_dirsep_regex='[/\\]'
22878 gl_dirsep_regex='\/'
22881 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22883 gl_header_literal_regex=`echo 'signal.h' \
22884 | sed -e "$gl_make_literal_regex_sed"`
22885 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22886 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22891 gl_cv_next_signal_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22892 sed -n "$gl_absolute_header_sed"`'"'
22896 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
22897 printf "%s\n" "$gl_cv_next_signal_h" >&6; }
22899 NEXT_SIGNAL_H=$gl_cv_next_signal_h
22901 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22902 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22903 gl_next_as_first_directive='<'signal.h'>'
22905 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22906 gl_next_as_first_directive=$gl_cv_next_signal_h
22908 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
22914 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
22915 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
22916 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
22917 #include <signal.h>
22920 if test "x$ac_cv_type_volatile_sig_atomic_t" = xyes; then :
22923 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
22932 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
22933 #include <signal.h>
22936 if test "x$ac_cv_type_sighandler_t" = xyes; then :
22939 HAVE_SIGHANDLER_T=0
22944 for gl_func in pthread_sigmask sigaction sigaddset sigdelset sigemptyset sigfillset sigismember sigpending sigprocmask; do
22945 as_gl_Symbol=`printf "%s\n" "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
22946 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
22947 printf %s "checking whether $gl_func is declared without a macro... " >&6; }
22948 if eval \${$as_gl_Symbol+:} false; then :
22949 printf %s "(cached) " >&6
22951 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22952 /* end confdefs.h. */
22953 #include <signal.h>
22964 if ac_fn_c_try_compile "$LINENO"; then :
22965 eval "$as_gl_Symbol=yes"
22967 eval "$as_gl_Symbol=no"
22969 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22971 eval ac_res=\$$as_gl_Symbol
22972 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
22973 printf "%s\n" "$ac_res" >&6; }
22974 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
22975 cat >>confdefs.h <<_ACEOF
22976 #define `printf "%s\n" "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
22979 eval ac_cv_have_decl_$gl_func=yes
22987 if test $gl_cv_type_sigset_t = yes; then
22988 ac_fn_c_check_func "$LINENO" "sigprocmask" "ac_cv_func_sigprocmask"
22989 if test "x$ac_cv_func_sigprocmask" = xyes; then :
22990 gl_cv_func_sigprocmask=1
22994 if test -z "$gl_cv_func_sigprocmask"; then
22995 HAVE_POSIX_SIGNALBLOCKING=0
22998 if test $HAVE_POSIX_SIGNALBLOCKING = 0; then
23007 gl_LIBOBJS="$gl_LIBOBJS sigprocmask.$ac_objext"
23016 GNULIB_SIGPROCMASK=1
23022 printf "%s\n" "#define GNULIB_TEST_SIGPROCMASK 1" >>confdefs.h
23027 for ac_header in stdint.h
23029 ac_fn_c_check_header_mongrel "$LINENO" "stdint.h" "ac_cv_header_stdint_h" "$ac_includes_default"
23030 if test "x$ac_cv_header_stdint_h" = xyes; then :
23031 cat >>confdefs.h <<_ACEOF
23032 #define HAVE_STDINT_H 1
23039 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for SIZE_MAX" >&5
23040 printf %s "checking for SIZE_MAX... " >&6; }
23041 if ${gl_cv_size_max+:} false; then :
23042 printf %s "(cached) " >&6
23046 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23047 /* end confdefs.h. */
23049 #include <limits.h>
23051 #include <stdint.h>
23058 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23059 $EGREP "Found it" >/dev/null 2>&1; then :
23064 if test -z "$gl_cv_size_max"; then
23065 if ac_fn_c_compute_int "$LINENO" "sizeof (size_t) * CHAR_BIT - 1" "size_t_bits_minus_1" "#include <stddef.h>
23066 #include <limits.h>"; then :
23069 size_t_bits_minus_1=
23072 if ac_fn_c_compute_int "$LINENO" "sizeof (size_t) <= sizeof (unsigned int)" "fits_in_uint" "#include <stddef.h>"; then :
23078 if test -n "$size_t_bits_minus_1" && test -n "$fits_in_uint"; then
23079 if test $fits_in_uint = 1; then
23080 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23081 /* end confdefs.h. */
23082 #include <stddef.h>
23084 extern unsigned long foo;
23094 if ac_fn_c_try_compile "$LINENO"; then :
23097 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23099 if test $fits_in_uint = 1; then
23100 gl_cv_size_max="(((1U << $size_t_bits_minus_1) - 1) * 2 + 1)"
23102 gl_cv_size_max="(((1UL << $size_t_bits_minus_1) - 1) * 2 + 1)"
23105 gl_cv_size_max='((size_t)~(size_t)0)'
23110 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_size_max" >&5
23111 printf "%s\n" "$gl_cv_size_max" >&6; }
23112 if test "$gl_cv_size_max" != yes; then
23114 cat >>confdefs.h <<_ACEOF
23115 #define SIZE_MAX $gl_cv_size_max
23122 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
23123 printf %s "checking for ssize_t... " >&6; }
23124 if ${gt_cv_ssize_t+:} false; then :
23125 printf %s "(cached) " >&6
23127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23128 /* end confdefs.h. */
23129 #include <sys/types.h>
23133 int x = sizeof (ssize_t *) + sizeof (ssize_t);
23139 if ac_fn_c_try_compile "$LINENO"; then :
23144 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23146 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
23147 printf "%s\n" "$gt_cv_ssize_t" >&6; }
23148 if test $gt_cv_ssize_t = no; then
23150 printf "%s\n" "#define ssize_t int" >>confdefs.h
23157 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
23158 printf %s "checking whether stat handles trailing slashes on directories... " >&6; }
23159 if ${gl_cv_func_stat_dir_slash+:} false; then :
23160 printf %s "(cached) " >&6
23162 if test "$cross_compiling" = yes; then :
23164 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
23165 *) gl_cv_func_stat_dir_slash="guessing yes";;
23168 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23169 /* end confdefs.h. */
23170 #include <sys/stat.h>
23175 struct stat st; return stat (".", &st) != stat ("./", &st);
23180 if ac_fn_c_try_run "$LINENO"; then :
23181 gl_cv_func_stat_dir_slash=yes
23183 gl_cv_func_stat_dir_slash=no
23185 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23186 conftest.$ac_objext conftest.beam conftest.$ac_ext
23190 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
23191 printf "%s\n" "$gl_cv_func_stat_dir_slash" >&6; }
23192 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
23193 printf %s "checking whether stat handles trailing slashes on files... " >&6; }
23194 if ${gl_cv_func_stat_file_slash+:} false; then :
23195 printf %s "(cached) " >&6
23198 # Assume that if we have lstat, we can also check symlinks.
23199 if test $ac_cv_func_lstat = yes; then
23200 ln -s conftest.tmp conftest.lnk
23202 if test "$cross_compiling" = yes; then :
23204 # Guess yes on glibc systems.
23205 *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
23206 # If we don't know, assume the worst.
23207 *) gl_cv_func_stat_file_slash="guessing no" ;;
23211 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23212 /* end confdefs.h. */
23213 #include <sys/stat.h>
23220 if (!stat ("conftest.tmp/", &st))
23223 if (!stat ("conftest.lnk/", &st))
23232 if ac_fn_c_try_run "$LINENO"; then :
23233 gl_cv_func_stat_file_slash=yes
23235 gl_cv_func_stat_file_slash=no
23237 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23238 conftest.$ac_objext conftest.beam conftest.$ac_ext
23241 rm -f conftest.tmp conftest.lnk
23243 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
23244 printf "%s\n" "$gl_cv_func_stat_file_slash" >&6; }
23245 case $gl_cv_func_stat_dir_slash in
23246 *no) REPLACE_STAT=1
23248 printf "%s\n" "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
23251 case $gl_cv_func_stat_file_slash in
23252 *no) REPLACE_STAT=1
23254 printf "%s\n" "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
23258 if test $REPLACE_STAT = 1; then
23267 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
23282 printf "%s\n" "#define GNULIB_TEST_STAT 1" >>confdefs.h
23290 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>
23291 #include <sys/stat.h>
23293 if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = xyes; then :
23295 cat >>confdefs.h <<_ACEOF
23296 #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
23299 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
23300 printf %s "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
23301 if ${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+:} false; then :
23302 printf %s "(cached) " >&6
23304 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23305 /* end confdefs.h. */
23307 #include <sys/types.h>
23308 #include <sys/stat.h>
23309 #if HAVE_SYS_TIME_H
23310 # include <sys/time.h>
23313 struct timespec ts;
23326 if ac_fn_c_try_compile "$LINENO"; then :
23327 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
23329 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no
23331 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23333 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
23334 printf "%s\n" "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
23335 if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
23337 printf "%s\n" "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
23341 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>
23342 #include <sys/stat.h>
23344 if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = xyes; then :
23346 cat >>confdefs.h <<_ACEOF
23347 #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
23352 ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
23353 #include <sys/stat.h>
23355 if test "x$ac_cv_member_struct_stat_st_atimensec" = xyes; then :
23357 cat >>confdefs.h <<_ACEOF
23358 #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
23363 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>
23364 #include <sys/stat.h>
23366 if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = xyes; then :
23368 cat >>confdefs.h <<_ACEOF
23369 #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
23385 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>
23386 #include <sys/stat.h>
23388 if test "x$ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" = xyes; then :
23390 cat >>confdefs.h <<_ACEOF
23391 #define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
23396 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimensec" "ac_cv_member_struct_stat_st_birthtimensec" "#include <sys/types.h>
23397 #include <sys/stat.h>
23399 if test "x$ac_cv_member_struct_stat_st_birthtimensec" = xyes; then :
23401 cat >>confdefs.h <<_ACEOF
23402 #define HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC 1
23407 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>
23408 #include <sys/stat.h>
23410 if test "x$ac_cv_member_struct_stat_st_birthtim_tv_nsec" = xyes; then :
23412 cat >>confdefs.h <<_ACEOF
23413 #define HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC 1
23426 NEXT_STDARG_H='<stdarg.h>'
23427 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
23428 printf %s "checking for va_copy... " >&6; }
23429 if ${gl_cv_func_va_copy+:} false; then :
23430 printf %s "(cached) " >&6
23433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23434 /* end confdefs.h. */
23435 #include <stdarg.h>
23441 void (*func) (va_list, va_list) = va_copy;
23448 if ac_fn_c_try_compile "$LINENO"; then :
23449 gl_cv_func_va_copy=yes
23451 gl_cv_func_va_copy=no
23453 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23456 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
23457 printf "%s\n" "$gl_cv_func_va_copy" >&6; }
23458 if test $gl_cv_func_va_copy = no; then
23459 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23460 /* end confdefs.h. */
23461 #if defined _AIX && !defined __GNUC__
23466 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23467 $EGREP "vaccine" >/dev/null 2>&1; then :
23474 if test $gl_aixcc = yes; then
23484 if test $gl_cv_have_include_next = yes; then
23485 gl_cv_next_stdarg_h='<'stdarg.h'>'
23487 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
23488 printf %s "checking absolute name of <stdarg.h>... " >&6; }
23489 if ${gl_cv_next_stdarg_h+:} false; then :
23490 printf %s "(cached) " >&6
23493 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23494 /* end confdefs.h. */
23495 #include <stdarg.h>
23499 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23500 *) gl_absname_cpp="$ac_cpp" ;;
23505 gl_dirsep_regex='[/\\]'
23508 gl_dirsep_regex='\/'
23511 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23513 gl_header_literal_regex=`echo 'stdarg.h' \
23514 | sed -e "$gl_make_literal_regex_sed"`
23515 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23516 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23521 gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23522 sed -n "$gl_absolute_header_sed"`'"'
23526 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
23527 printf "%s\n" "$gl_cv_next_stdarg_h" >&6; }
23529 NEXT_STDARG_H=$gl_cv_next_stdarg_h
23531 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23532 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23533 gl_next_as_first_directive='<'stdarg.h'>'
23535 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23536 gl_next_as_first_directive=$gl_cv_next_stdarg_h
23538 NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
23543 if test "$gl_cv_next_stdarg_h" = '""'; then
23544 gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
23545 NEXT_STDARG_H="$gl_cv_next_stdarg_h"
23549 saved_as_echo_n="$as_echo_n"
23551 if ${gl_cv_func___va_copy+:} false; then :
23552 printf %s "(cached) " >&6
23555 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23556 /* end confdefs.h. */
23557 #include <stdarg.h>
23570 if ac_fn_c_try_compile "$LINENO"; then :
23571 gl_cv_func___va_copy=yes
23573 gl_cv_func___va_copy=no
23575 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23578 as_echo_n="$saved_as_echo_n"
23580 if test $gl_cv_func___va_copy = yes; then
23582 printf "%s\n" "#define va_copy __va_copy" >>confdefs.h
23587 printf "%s\n" "#define va_copy gl_va_copy" >>confdefs.h
23593 if test -n "$STDARG_H"; then
23594 GL_GENERATE_STDARG_H_TRUE=
23595 GL_GENERATE_STDARG_H_FALSE='#'
23597 GL_GENERATE_STDARG_H_TRUE='#'
23598 GL_GENERATE_STDARG_H_FALSE=
23606 # Define two additional variables used in the Makefile substitution.
23608 if test "$ac_cv_header_stdbool_h" = yes; then
23611 STDBOOL_H='stdbool.h'
23614 if test -n "$STDBOOL_H"; then
23615 GL_GENERATE_STDBOOL_H_TRUE=
23616 GL_GENERATE_STDBOOL_H_FALSE='#'
23618 GL_GENERATE_STDBOOL_H_TRUE='#'
23619 GL_GENERATE_STDBOOL_H_FALSE=
23623 if test "$ac_cv_type__Bool" = yes; then
23634 if test $gt_cv_c_wchar_t = no; then
23638 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
23639 printf %s "checking whether NULL can be used in arbitrary expressions... " >&6; }
23640 if ${gl_cv_decl_null_works+:} false; then :
23641 printf %s "(cached) " >&6
23643 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23644 /* end confdefs.h. */
23645 #include <stddef.h>
23646 int test[2 * (sizeof NULL == sizeof (void *)) -1];
23656 if ac_fn_c_try_compile "$LINENO"; then :
23657 gl_cv_decl_null_works=yes
23659 gl_cv_decl_null_works=no
23661 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23663 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
23664 printf "%s\n" "$gl_cv_decl_null_works" >&6; }
23665 if test $gl_cv_decl_null_works = no; then
23670 if test -n "$STDDEF_H"; then
23671 GL_GENERATE_STDDEF_H_TRUE=
23672 GL_GENERATE_STDDEF_H_FALSE='#'
23674 GL_GENERATE_STDDEF_H_TRUE='#'
23675 GL_GENERATE_STDDEF_H_FALSE=
23678 if test -n "$STDDEF_H"; then
23687 if test $gl_cv_have_include_next = yes; then
23688 gl_cv_next_stddef_h='<'stddef.h'>'
23690 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
23691 printf %s "checking absolute name of <stddef.h>... " >&6; }
23692 if ${gl_cv_next_stddef_h+:} false; then :
23693 printf %s "(cached) " >&6
23696 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23697 /* end confdefs.h. */
23698 #include <stddef.h>
23702 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23703 *) gl_absname_cpp="$ac_cpp" ;;
23708 gl_dirsep_regex='[/\\]'
23711 gl_dirsep_regex='\/'
23714 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23716 gl_header_literal_regex=`echo 'stddef.h' \
23717 | sed -e "$gl_make_literal_regex_sed"`
23718 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23719 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23724 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23725 sed -n "$gl_absolute_header_sed"`'"'
23729 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
23730 printf "%s\n" "$gl_cv_next_stddef_h" >&6; }
23732 NEXT_STDDEF_H=$gl_cv_next_stddef_h
23734 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23735 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23736 gl_next_as_first_directive='<'stddef.h'>'
23738 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23739 gl_next_as_first_directive=$gl_cv_next_stddef_h
23741 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
23759 if test $gl_cv_have_include_next = yes; then
23760 gl_cv_next_stdio_h='<'stdio.h'>'
23762 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
23763 printf %s "checking absolute name of <stdio.h>... " >&6; }
23764 if ${gl_cv_next_stdio_h+:} false; then :
23765 printf %s "(cached) " >&6
23768 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23769 /* end confdefs.h. */
23774 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23775 *) gl_absname_cpp="$ac_cpp" ;;
23780 gl_dirsep_regex='[/\\]'
23783 gl_dirsep_regex='\/'
23786 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23788 gl_header_literal_regex=`echo 'stdio.h' \
23789 | sed -e "$gl_make_literal_regex_sed"`
23790 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23791 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23796 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23797 sed -n "$gl_absolute_header_sed"`'"'
23801 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
23802 printf "%s\n" "$gl_cv_next_stdio_h" >&6; }
23804 NEXT_STDIO_H=$gl_cv_next_stdio_h
23806 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23807 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23808 gl_next_as_first_directive='<'stdio.h'>'
23810 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23811 gl_next_as_first_directive=$gl_cv_next_stdio_h
23813 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
23822 cat >>confdefs.h <<_ACEOF
23823 #define GNULIB_FSCANF 1
23830 cat >>confdefs.h <<_ACEOF
23831 #define GNULIB_SCANF 1
23856 for gl_func in dprintf fpurge fseeko ftello getdelim getline gets pclose popen renameat snprintf tmpfile vdprintf vsnprintf; do
23857 as_gl_Symbol=`printf "%s\n" "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
23858 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
23859 printf %s "checking whether $gl_func is declared without a macro... " >&6; }
23860 if eval \${$as_gl_Symbol+:} false; then :
23861 printf %s "(cached) " >&6
23863 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23864 /* end confdefs.h. */
23876 if ac_fn_c_try_compile "$LINENO"; then :
23877 eval "$as_gl_Symbol=yes"
23879 eval "$as_gl_Symbol=no"
23881 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23883 eval ac_res=\$$as_gl_Symbol
23884 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
23885 printf "%s\n" "$ac_res" >&6; }
23886 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
23887 cat >>confdefs.h <<_ACEOF
23888 #define `printf "%s\n" "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
23891 eval ac_cv_have_decl_$gl_func=yes
23906 if test $gl_cv_have_include_next = yes; then
23907 gl_cv_next_stdlib_h='<'stdlib.h'>'
23909 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
23910 printf %s "checking absolute name of <stdlib.h>... " >&6; }
23911 if ${gl_cv_next_stdlib_h+:} false; then :
23912 printf %s "(cached) " >&6
23915 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23916 /* end confdefs.h. */
23917 #include <stdlib.h>
23921 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23922 *) gl_absname_cpp="$ac_cpp" ;;
23927 gl_dirsep_regex='[/\\]'
23930 gl_dirsep_regex='\/'
23933 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23935 gl_header_literal_regex=`echo 'stdlib.h' \
23936 | sed -e "$gl_make_literal_regex_sed"`
23937 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23938 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23943 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23944 sed -n "$gl_absolute_header_sed"`'"'
23948 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
23949 printf "%s\n" "$gl_cv_next_stdlib_h" >&6; }
23951 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
23953 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23954 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23955 gl_next_as_first_directive='<'stdlib.h'>'
23957 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23958 gl_next_as_first_directive=$gl_cv_next_stdlib_h
23960 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
23967 for gl_func in _Exit atoll canonicalize_file_name getloadavg getsubopt grantpt initstate initstate_r mkdtemp mkostemp mkostemps mkstemp mkstemps posix_openpt ptsname ptsname_r random random_r realpath rpmatch secure_getenv setenv setstate setstate_r srandom srandom_r strtod strtoll strtoull unlockpt unsetenv; do
23968 as_gl_Symbol=`printf "%s\n" "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
23969 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
23970 printf %s "checking whether $gl_func is declared without a macro... " >&6; }
23971 if eval \${$as_gl_Symbol+:} false; then :
23972 printf %s "(cached) " >&6
23974 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23975 /* end confdefs.h. */
23976 #include <stdlib.h>
23977 #if HAVE_SYS_LOADAVG_H
23978 # include <sys/loadavg.h>
23981 # include <random.h>
23993 if ac_fn_c_try_compile "$LINENO"; then :
23994 eval "$as_gl_Symbol=yes"
23996 eval "$as_gl_Symbol=no"
23998 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24000 eval ac_res=\$$as_gl_Symbol
24001 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
24002 printf "%s\n" "$ac_res" >&6; }
24003 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
24004 cat >>confdefs.h <<_ACEOF
24005 #define `printf "%s\n" "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
24008 eval ac_cv_have_decl_$gl_func=yes
24016 for ac_func in strcasecmp
24018 ac_fn_c_check_func "$LINENO" "strcasecmp" "ac_cv_func_strcasecmp"
24019 if test "x$ac_cv_func_strcasecmp" = xyes; then :
24020 cat >>confdefs.h <<_ACEOF
24021 #define HAVE_STRCASECMP 1
24027 if test $ac_cv_func_strcasecmp = no; then
24033 for ac_func in strncasecmp
24035 ac_fn_c_check_func "$LINENO" "strncasecmp" "ac_cv_func_strncasecmp"
24036 if test "x$ac_cv_func_strncasecmp" = xyes; then :
24037 cat >>confdefs.h <<_ACEOF
24038 #define HAVE_STRNCASECMP 1
24044 if test $ac_cv_func_strncasecmp = yes; then
24049 ac_fn_c_check_decl "$LINENO" "strncasecmp" "ac_cv_have_decl_strncasecmp" "$ac_includes_default"
24050 if test "x$ac_cv_have_decl_strncasecmp" = xyes; then :
24056 cat >>confdefs.h <<_ACEOF
24057 #define HAVE_DECL_STRNCASECMP $ac_have_decl
24060 if test $ac_cv_have_decl_strncasecmp = no; then
24061 HAVE_DECL_STRNCASECMP=0
24065 if test $HAVE_STRCASECMP = 0; then
24074 gl_LIBOBJS="$gl_LIBOBJS strcasecmp.$ac_objext"
24080 if test $HAVE_STRNCASECMP = 0; then
24089 gl_LIBOBJS="$gl_LIBOBJS strncasecmp.$ac_objext"
24100 if test "$ERRNO_H:$REPLACE_STRERROR_0" = :0; then
24101 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working strerror function" >&5
24102 printf %s "checking for working strerror function... " >&6; }
24103 if ${gl_cv_func_working_strerror+:} false; then :
24104 printf %s "(cached) " >&6
24106 if test "$cross_compiling" = yes; then :
24108 # Guess yes on glibc systems.
24109 *-gnu*) gl_cv_func_working_strerror="guessing yes" ;;
24110 # If we don't know, assume the worst.
24111 *) gl_cv_func_working_strerror="guessing no" ;;
24115 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24116 /* end confdefs.h. */
24117 #include <string.h>
24122 if (!*strerror (-2)) return 1;
24127 if ac_fn_c_try_run "$LINENO"; then :
24128 gl_cv_func_working_strerror=yes
24130 gl_cv_func_working_strerror=no
24132 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24133 conftest.$ac_objext conftest.beam conftest.$ac_ext
24138 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_strerror" >&5
24139 printf "%s\n" "$gl_cv_func_working_strerror" >&6; }
24140 case "$gl_cv_func_working_strerror" in
24151 if test $REPLACE_STRERROR = 1; then
24160 gl_LIBOBJS="$gl_LIBOBJS strerror.$ac_objext"
24165 cat >>confdefs.h <<_ACEOF
24166 #define GNULIB_STRERROR 1
24181 printf "%s\n" "#define GNULIB_TEST_STRERROR 1" >>confdefs.h
24187 if test -n "$ERRNO_H" || test $REPLACE_STRERROR_0 = 1; then
24196 gl_LIBOBJS="$gl_LIBOBJS strerror-override.$ac_objext"
24202 if test $ac_cv_header_sys_socket_h != yes; then
24203 for ac_header in winsock2.h
24205 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
24206 if test "x$ac_cv_header_winsock2_h" = xyes; then :
24207 cat >>confdefs.h <<_ACEOF
24208 #define HAVE_WINSOCK2_H 1
24216 if test "$ac_cv_header_winsock2_h" = yes; then
24218 UNISTD_H_HAVE_WINSOCK2_H=1
24219 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
24228 # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
24236 printf "%s\n" "#define my_strftime nstrftime" >>confdefs.h
24240 if test $gl_cond_libtool = false; then
24241 gl_ltlibdeps="$gl_ltlibdeps $LTLIBICONV"
24242 gl_libdeps="$gl_libdeps $LIBICONV"
24256 if test $ac_cv_have_decl_strndup = no; then
24257 HAVE_DECL_STRNDUP=0
24260 if test $ac_cv_func_strndup = yes; then
24262 # AIX 4.3.3, AIX 5.1 have a function that fails to add the terminating '\0'.
24263 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working strndup" >&5
24264 printf %s "checking for working strndup... " >&6; }
24265 if ${gl_cv_func_strndup_works+:} false; then :
24266 printf %s "(cached) " >&6
24268 if test "$cross_compiling" = yes; then :
24271 aix | aix[3-6]*) gl_cv_func_strndup_works="guessing no";;
24272 *) gl_cv_func_strndup_works="guessing yes";;
24276 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24277 /* end confdefs.h. */
24279 #include <string.h>
24280 #include <stdlib.h>
24285 #if !HAVE_DECL_STRNDUP
24290 char *strndup (const char *, size_t);
24293 s = strndup ("some longer string", 15);
24295 s = strndup ("shorter string", 13);
24296 return s[13] != '\0';
24301 if ac_fn_c_try_run "$LINENO"; then :
24302 gl_cv_func_strndup_works=yes
24304 gl_cv_func_strndup_works=no
24306 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24307 conftest.$ac_objext conftest.beam conftest.$ac_ext
24311 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strndup_works" >&5
24312 printf "%s\n" "$gl_cv_func_strndup_works" >&6; }
24313 case $gl_cv_func_strndup_works in
24314 *no) REPLACE_STRNDUP=1 ;;
24320 if test $HAVE_STRNDUP = 0 || test $REPLACE_STRNDUP = 1; then
24329 gl_LIBOBJS="$gl_LIBOBJS strndup.$ac_objext"
24343 printf "%s\n" "#define GNULIB_TEST_STRNDUP 1" >>confdefs.h
24353 if test $ac_cv_have_decl_strnlen = no; then
24354 HAVE_DECL_STRNLEN=0
24357 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working strnlen" >&5
24358 printf %s "checking for working strnlen... " >&6; }
24359 if ${ac_cv_func_strnlen_working+:} false; then :
24360 printf %s "(cached) " >&6
24362 if test "$cross_compiling" = yes; then :
24363 # Guess no on AIX systems, yes otherwise.
24365 aix*) ac_cv_func_strnlen_working=no;;
24366 *) ac_cv_func_strnlen_working=yes;;
24369 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24370 /* end confdefs.h. */
24371 $ac_includes_default
24377 #define S_LEN (sizeof S - 1)
24379 /* At least one implementation is buggy: that of AIX 4.3 would
24380 give strnlen (S, 1) == 3. */
24383 for (i = 0; i < S_LEN + 1; ++i)
24385 int expected = i <= S_LEN ? i : S_LEN;
24386 if (strnlen (S, i) != expected)
24395 if ac_fn_c_try_run "$LINENO"; then :
24396 ac_cv_func_strnlen_working=yes
24398 ac_cv_func_strnlen_working=no
24400 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24401 conftest.$ac_objext conftest.beam conftest.$ac_ext
24405 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strnlen_working" >&5
24406 printf "%s\n" "$ac_cv_func_strnlen_working" >&6; }
24407 test $ac_cv_func_strnlen_working = no && :
24410 if test $ac_cv_func_strnlen_working = no; then
24415 if test $HAVE_DECL_STRNLEN = 0 || test $REPLACE_STRNLEN = 1; then
24424 gl_LIBOBJS="$gl_LIBOBJS strnlen.$ac_objext"
24439 printf "%s\n" "#define GNULIB_TEST_STRNLEN 1" >>confdefs.h
24447 if test $ac_cv_func_strptime != yes; then
24451 if test $HAVE_STRPTIME = 0; then
24460 gl_LIBOBJS="$gl_LIBOBJS strptime.$ac_objext"
24478 printf "%s\n" "#define GNULIB_TEST_STRPTIME 1" >>confdefs.h
24485 if test "$ac_cv_type_unsigned_long_long_int" = yes; then
24486 for ac_func in strtoull
24488 ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
24489 if test "x$ac_cv_func_strtoull" = xyes; then :
24490 cat >>confdefs.h <<_ACEOF
24491 #define HAVE_STRTOULL 1
24497 if test $ac_cv_func_strtoull = no; then
24502 if test $HAVE_STRTOULL = 0; then
24511 gl_LIBOBJS="$gl_LIBOBJS strtoull.$ac_objext"
24528 printf "%s\n" "#define GNULIB_TEST_STRTOULL 1" >>confdefs.h
24537 if test "$ac_cv_have_decl_strtoumax" != yes; then
24538 HAVE_DECL_STRTOUMAX=0
24541 if test $ac_cv_func_strtoumax = no; then
24550 gl_LIBOBJS="$gl_LIBOBJS strtoumax.$ac_objext"
24553 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
24554 if test "x$ac_cv_have_decl_strtoull" = xyes; then :
24560 cat >>confdefs.h <<_ACEOF
24561 #define HAVE_DECL_STRTOULL $ac_have_decl
24591 if test $gl_cv_have_include_next = yes; then
24592 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
24594 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
24595 printf %s "checking absolute name of <sys/stat.h>... " >&6; }
24596 if ${gl_cv_next_sys_stat_h+:} false; then :
24597 printf %s "(cached) " >&6
24600 if test $ac_cv_header_sys_stat_h = yes; then
24603 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24604 /* end confdefs.h. */
24605 #include <sys/stat.h>
24609 aix*) gl_absname_cpp="$ac_cpp -C" ;;
24610 *) gl_absname_cpp="$ac_cpp" ;;
24615 gl_dirsep_regex='[/\\]'
24618 gl_dirsep_regex='\/'
24621 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
24623 gl_header_literal_regex=`echo 'sys/stat.h' \
24624 | sed -e "$gl_make_literal_regex_sed"`
24625 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
24626 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
24631 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
24632 sed -n "$gl_absolute_header_sed"`'"'
24634 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
24639 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
24640 printf "%s\n" "$gl_cv_next_sys_stat_h" >&6; }
24642 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
24644 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
24645 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
24646 gl_next_as_first_directive='<'sys/stat.h'>'
24648 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
24649 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
24651 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
24663 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
24665 printf "%s\n" "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
24669 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
24670 #include <sys/stat.h>
24672 if test "x$ac_cv_type_nlink_t" = xyes; then :
24676 printf "%s\n" "#define nlink_t int" >>confdefs.h
24682 for gl_func in fchmodat fstat fstatat futimens lchmod lstat mkdirat mkfifo mkfifoat mknod mknodat stat utimensat; do
24683 as_gl_Symbol=`printf "%s\n" "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
24684 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
24685 printf %s "checking whether $gl_func is declared without a macro... " >&6; }
24686 if eval \${$as_gl_Symbol+:} false; then :
24687 printf %s "(cached) " >&6
24689 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24690 /* end confdefs.h. */
24691 #include <sys/stat.h>
24702 if ac_fn_c_try_compile "$LINENO"; then :
24703 eval "$as_gl_Symbol=yes"
24705 eval "$as_gl_Symbol=no"
24707 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24709 eval ac_res=\$$as_gl_Symbol
24710 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
24711 printf "%s\n" "$ac_res" >&6; }
24712 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
24713 cat >>confdefs.h <<_ACEOF
24714 #define `printf "%s\n" "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
24717 eval ac_cv_have_decl_$gl_func=yes
24741 if test $gl_cv_have_include_next = yes; then
24742 gl_cv_next_sys_wait_h='<'sys/wait.h'>'
24744 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/wait.h>" >&5
24745 printf %s "checking absolute name of <sys/wait.h>... " >&6; }
24746 if ${gl_cv_next_sys_wait_h+:} false; then :
24747 printf %s "(cached) " >&6
24750 if test $ac_cv_header_sys_wait_h = yes; then
24753 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24754 /* end confdefs.h. */
24755 #include <sys/wait.h>
24759 aix*) gl_absname_cpp="$ac_cpp -C" ;;
24760 *) gl_absname_cpp="$ac_cpp" ;;
24765 gl_dirsep_regex='[/\\]'
24768 gl_dirsep_regex='\/'
24771 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
24773 gl_header_literal_regex=`echo 'sys/wait.h' \
24774 | sed -e "$gl_make_literal_regex_sed"`
24775 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
24776 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
24781 gl_cv_next_sys_wait_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
24782 sed -n "$gl_absolute_header_sed"`'"'
24784 gl_cv_next_sys_wait_h='<'sys/wait.h'>'
24789 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_wait_h" >&5
24790 printf "%s\n" "$gl_cv_next_sys_wait_h" >&6; }
24792 NEXT_SYS_WAIT_H=$gl_cv_next_sys_wait_h
24794 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
24795 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
24796 gl_next_as_first_directive='<'sys/wait.h'>'
24798 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
24799 gl_next_as_first_directive=$gl_cv_next_sys_wait_h
24801 NEXT_AS_FIRST_DIRECTIVE_SYS_WAIT_H=$gl_next_as_first_directive
24810 for gl_func in waitpid; do
24811 as_gl_Symbol=`printf "%s\n" "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
24812 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
24813 printf %s "checking whether $gl_func is declared without a macro... " >&6; }
24814 if eval \${$as_gl_Symbol+:} false; then :
24815 printf %s "(cached) " >&6
24817 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24818 /* end confdefs.h. */
24819 #include <sys/wait.h>
24829 if ac_fn_c_try_compile "$LINENO"; then :
24830 eval "$as_gl_Symbol=yes"
24832 eval "$as_gl_Symbol=no"
24834 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24836 eval ac_res=\$$as_gl_Symbol
24837 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
24838 printf "%s\n" "$ac_res" >&6; }
24839 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
24840 cat >>confdefs.h <<_ACEOF
24841 #define `printf "%s\n" "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
24844 eval ac_cv_have_decl_$gl_func=yes
24864 ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "#include <time.h>
24866 if test "x$ac_cv_have_decl_localtime_r" = xyes; then :
24872 cat >>confdefs.h <<_ACEOF
24873 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
24876 if test $ac_cv_have_decl_localtime_r = no; then
24877 HAVE_DECL_LOCALTIME_R=0
24881 if test $ac_cv_func_localtime_r = yes; then
24883 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
24884 printf %s "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
24885 if ${gl_cv_time_r_posix+:} false; then :
24886 printf %s "(cached) " >&6
24888 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24889 /* end confdefs.h. */
24894 /* We don't need to append 'restrict's to the argument types,
24895 even though the POSIX signature has the 'restrict's,
24896 since C99 says they can't affect type compatibility. */
24897 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
24899 /* Check the return type is a pointer.
24900 On HP-UX 10 it is 'int'. */
24901 *localtime_r (0, 0);
24907 if ac_fn_c_try_compile "$LINENO"; then :
24908 gl_cv_time_r_posix=yes
24910 gl_cv_time_r_posix=no
24912 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24915 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
24916 printf "%s\n" "$gl_cv_time_r_posix" >&6; }
24917 if test $gl_cv_time_r_posix = yes; then
24918 REPLACE_LOCALTIME_R=0
24920 REPLACE_LOCALTIME_R=1
24926 if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
24935 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
24952 printf "%s\n" "#define GNULIB_TEST_TIME_R 1" >>confdefs.h
24969 if test $gl_cv_have_include_next = yes; then
24970 gl_cv_next_unistd_h='<'unistd.h'>'
24972 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
24973 printf %s "checking absolute name of <unistd.h>... " >&6; }
24974 if ${gl_cv_next_unistd_h+:} false; then :
24975 printf %s "(cached) " >&6
24978 if test $ac_cv_header_unistd_h = yes; then
24981 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24982 /* end confdefs.h. */
24983 #include <unistd.h>
24987 aix*) gl_absname_cpp="$ac_cpp -C" ;;
24988 *) gl_absname_cpp="$ac_cpp" ;;
24993 gl_dirsep_regex='[/\\]'
24996 gl_dirsep_regex='\/'
24999 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
25001 gl_header_literal_regex=`echo 'unistd.h' \
25002 | sed -e "$gl_make_literal_regex_sed"`
25003 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
25004 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
25009 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
25010 sed -n "$gl_absolute_header_sed"`'"'
25012 gl_cv_next_unistd_h='<'unistd.h'>'
25017 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
25018 printf "%s\n" "$gl_cv_next_unistd_h" >&6; }
25020 NEXT_UNISTD_H=$gl_cv_next_unistd_h
25022 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
25023 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
25024 gl_next_as_first_directive='<'unistd.h'>'
25026 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
25027 gl_next_as_first_directive=$gl_cv_next_unistd_h
25029 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
25034 if test $ac_cv_header_unistd_h = yes; then
25046 for gl_func in chdir chown dup dup2 dup3 environ euidaccess faccessat fchdir fchownat fdatasync fsync ftruncate getcwd getdomainname getdtablesize getgroups gethostname getlogin getlogin_r getpagesize getusershell setusershell endusershell group_member isatty lchown link linkat lseek pipe pipe2 pread pwrite readlink readlinkat rmdir sethostname sleep symlink symlinkat ttyname_r unlink unlinkat usleep; do
25047 as_gl_Symbol=`printf "%s\n" "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
25048 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
25049 printf %s "checking whether $gl_func is declared without a macro... " >&6; }
25050 if eval \${$as_gl_Symbol+:} false; then :
25051 printf %s "(cached) " >&6
25053 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25054 /* end confdefs.h. */
25057 # include <unistd.h>
25059 /* Some systems declare various items in the wrong headers. */
25060 #if !(defined __GLIBC__ && !defined __UCLIBC__)
25061 # include <fcntl.h>
25062 # include <stdio.h>
25063 # include <stdlib.h>
25064 # if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
25078 if ac_fn_c_try_compile "$LINENO"; then :
25079 eval "$as_gl_Symbol=yes"
25081 eval "$as_gl_Symbol=no"
25083 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25085 eval ac_res=\$$as_gl_Symbol
25086 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
25087 printf "%s\n" "$ac_res" >&6; }
25088 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
25089 cat >>confdefs.h <<_ACEOF
25090 #define `printf "%s\n" "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
25093 eval ac_cv_have_decl_$gl_func=yes
25100 if { test "$HAVE_LIBUNISTRING" != yes \
25105 test $LIBUNISTRING_VERSION_MAJOR -lt 0 \
25106 || { test $LIBUNISTRING_VERSION_MAJOR -eq 0 \
25107 && { test $LIBUNISTRING_VERSION_MINOR -lt 9 \
25108 || { test $LIBUNISTRING_VERSION_MINOR -eq 9 \
25109 && test $LIBUNISTRING_VERSION_SUBMINOR -lt 2
25119 LIBUNISTRING_UNISTR_H='unistr.h'
25121 LIBUNISTRING_UNISTR_H=
25127 cat >>confdefs.h <<_ACEOF
25128 #define GNULIB_UNISTR_U8_MBTOUCR 1
25134 if { test "$HAVE_LIBUNISTRING" != yes \
25139 test $LIBUNISTRING_VERSION_MAJOR -lt 0 \
25140 || { test $LIBUNISTRING_VERSION_MAJOR -eq 0 \
25141 && { test $LIBUNISTRING_VERSION_MINOR -lt 9 \
25142 || { test $LIBUNISTRING_VERSION_MINOR -eq 9 \
25143 && test $LIBUNISTRING_VERSION_SUBMINOR -lt 0
25153 LIBUNISTRING_COMPILE_UNISTR_U8_MBTOUCR_TRUE=
25154 LIBUNISTRING_COMPILE_UNISTR_U8_MBTOUCR_FALSE='#'
25156 LIBUNISTRING_COMPILE_UNISTR_U8_MBTOUCR_TRUE='#'
25157 LIBUNISTRING_COMPILE_UNISTR_U8_MBTOUCR_FALSE=
25163 cat >>confdefs.h <<_ACEOF
25164 #define GNULIB_UNISTR_U8_UCTOMB 1
25170 if { test "$HAVE_LIBUNISTRING" != yes \
25175 test $LIBUNISTRING_VERSION_MAJOR -lt 0 \
25176 || { test $LIBUNISTRING_VERSION_MAJOR -eq 0 \
25177 && { test $LIBUNISTRING_VERSION_MINOR -lt 9 \
25178 || { test $LIBUNISTRING_VERSION_MINOR -eq 9 \
25179 && test $LIBUNISTRING_VERSION_SUBMINOR -lt 0
25189 LIBUNISTRING_COMPILE_UNISTR_U8_UCTOMB_TRUE=
25190 LIBUNISTRING_COMPILE_UNISTR_U8_UCTOMB_FALSE='#'
25192 LIBUNISTRING_COMPILE_UNISTR_U8_UCTOMB_TRUE='#'
25193 LIBUNISTRING_COMPILE_UNISTR_U8_UCTOMB_FALSE=
25199 if { test "$HAVE_LIBUNISTRING" != yes \
25204 test $LIBUNISTRING_VERSION_MAJOR -lt 0 \
25205 || { test $LIBUNISTRING_VERSION_MAJOR -eq 0 \
25206 && { test $LIBUNISTRING_VERSION_MINOR -lt 9 \
25207 || { test $LIBUNISTRING_VERSION_MINOR -eq 9 \
25208 && test $LIBUNISTRING_VERSION_SUBMINOR -lt 0
25218 LIBUNISTRING_UNITYPES_H='unitypes.h'
25220 LIBUNISTRING_UNITYPES_H=
25226 if { test "$HAVE_LIBUNISTRING" != yes \
25231 test $LIBUNISTRING_VERSION_MAJOR -lt 0 \
25232 || { test $LIBUNISTRING_VERSION_MAJOR -eq 0 \
25233 && { test $LIBUNISTRING_VERSION_MINOR -lt 9 \
25234 || { test $LIBUNISTRING_VERSION_MINOR -eq 9 \
25235 && test $LIBUNISTRING_VERSION_SUBMINOR -lt 0
25245 LIBUNISTRING_UNIWIDTH_H='uniwidth.h'
25247 LIBUNISTRING_UNIWIDTH_H=
25253 if { test "$HAVE_LIBUNISTRING" != yes \
25258 test $LIBUNISTRING_VERSION_MAJOR -lt 0 \
25259 || { test $LIBUNISTRING_VERSION_MAJOR -eq 0 \
25260 && { test $LIBUNISTRING_VERSION_MINOR -lt 9 \
25261 || { test $LIBUNISTRING_VERSION_MINOR -eq 9 \
25262 && test $LIBUNISTRING_VERSION_SUBMINOR -lt 4
25272 LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_TRUE=
25273 LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_FALSE='#'
25275 LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_TRUE='#'
25276 LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_FALSE=
25282 printf "%s\n" "#define USE_UNLOCKED_IO 1" >>confdefs.h
25302 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for variable-length arrays" >&5
25303 printf %s "checking for variable-length arrays... " >&6; }
25304 if ${ac_cv_c_vararrays+:} false; then :
25305 printf %s "(cached) " >&6
25307 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25308 /* end confdefs.h. */
25313 static int x; char a[++x]; a[sizeof a - 1] = 0; return a[0];
25318 if ac_fn_c_try_compile "$LINENO"; then :
25319 ac_cv_c_vararrays=yes
25321 ac_cv_c_vararrays=no
25323 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25325 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_vararrays" >&5
25326 printf "%s\n" "$ac_cv_c_vararrays" >&6; }
25327 if test $ac_cv_c_vararrays = yes; then
25329 printf "%s\n" "#define HAVE_C_VARARRAYS 1" >>confdefs.h
25335 if test $ac_cv_func_vasnprintf = no; then
25346 gl_LIBOBJS="$gl_LIBOBJS vasnprintf.$ac_objext"
25356 gl_LIBOBJS="$gl_LIBOBJS printf-args.$ac_objext"
25366 gl_LIBOBJS="$gl_LIBOBJS printf-parse.$ac_objext"
25376 gl_LIBOBJS="$gl_LIBOBJS asnprintf.$ac_objext"
25378 if test $ac_cv_func_vasnprintf = yes; then
25380 printf "%s\n" "#define REPLACE_VASNPRINTF 1" >>confdefs.h
25394 ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
25395 if test "x$ac_cv_type_ptrdiff_t" = xyes; then :
25399 printf "%s\n" "#define ptrdiff_t long" >>confdefs.h
25413 for ac_func in vasprintf
25415 ac_fn_c_check_func "$LINENO" "vasprintf" "ac_cv_func_vasprintf"
25416 if test "x$ac_cv_func_vasprintf" = xyes; then :
25417 cat >>confdefs.h <<_ACEOF
25418 #define HAVE_VASPRINTF 1
25424 if test $ac_cv_func_vasprintf = no; then
25434 gl_LIBOBJS="$gl_LIBOBJS vasprintf.$ac_objext"
25444 gl_LIBOBJS="$gl_LIBOBJS asprintf.$ac_objext"
25447 if test $ac_cv_func_vasprintf = yes; then
25448 REPLACE_VASPRINTF=1
25473 printf "%s\n" "#define GNULIB_TEST_VASPRINTF 1" >>confdefs.h
25479 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=asprintf:2:c-format"
25483 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=vasprintf:2:c-format"
25486 # Check whether --with-packager was given.
25487 if test "${with_packager+set}" = set; then :
25488 withval=$with_packager; case $withval in
25491 cat >>confdefs.h <<_ACEOF
25492 #define PACKAGE_PACKAGER "$withval"
25501 # Check whether --with-packager-version was given.
25502 if test "${with_packager_version+set}" = set; then :
25503 withval=$with_packager_version; case $withval in
25506 cat >>confdefs.h <<_ACEOF
25507 #define PACKAGE_PACKAGER_VERSION "$withval"
25516 # Check whether --with-packager-bug-reports was given.
25517 if test "${with_packager_bug_reports+set}" = set; then :
25518 withval=$with_packager_bug_reports; case $withval in
25521 cat >>confdefs.h <<_ACEOF
25522 #define PACKAGE_PACKAGER_BUG_REPORTS "$withval"
25530 if test "X$with_packager" = "X" && \
25531 test "X$with_packager_version$with_packager_bug_reports" != "X"
25533 as_fn_error $? "The --with-packager-{bug-reports,version} options require --with-packager" "$LINENO" 5
25548 if test $gl_cv_have_include_next = yes; then
25549 gl_cv_next_wchar_h='<'wchar.h'>'
25551 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <wchar.h>" >&5
25552 printf %s "checking absolute name of <wchar.h>... " >&6; }
25553 if ${gl_cv_next_wchar_h+:} false; then :
25554 printf %s "(cached) " >&6
25557 if test $ac_cv_header_wchar_h = yes; then
25560 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25561 /* end confdefs.h. */
25566 aix*) gl_absname_cpp="$ac_cpp -C" ;;
25567 *) gl_absname_cpp="$ac_cpp" ;;
25572 gl_dirsep_regex='[/\\]'
25575 gl_dirsep_regex='\/'
25578 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
25580 gl_header_literal_regex=`echo 'wchar.h' \
25581 | sed -e "$gl_make_literal_regex_sed"`
25582 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
25583 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
25588 gl_cv_next_wchar_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
25589 sed -n "$gl_absolute_header_sed"`'"'
25591 gl_cv_next_wchar_h='<'wchar.h'>'
25596 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wchar_h" >&5
25597 printf "%s\n" "$gl_cv_next_wchar_h" >&6; }
25599 NEXT_WCHAR_H=$gl_cv_next_wchar_h
25601 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
25602 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
25603 gl_next_as_first_directive='<'wchar.h'>'
25605 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
25606 gl_next_as_first_directive=$gl_cv_next_wchar_h
25608 NEXT_AS_FIRST_DIRECTIVE_WCHAR_H=$gl_next_as_first_directive
25613 if test $ac_cv_header_wchar_h = yes; then
25623 if test $gt_cv_c_wint_t = yes; then
25631 for gl_func in btowc wctob mbsinit mbrtowc mbrlen mbsrtowcs mbsnrtowcs wcrtomb wcsrtombs wcsnrtombs wcwidth wmemchr wmemcmp wmemcpy wmemmove wmemset wcslen wcsnlen wcscpy wcpcpy wcsncpy wcpncpy wcscat wcsncat wcscmp wcsncmp wcscasecmp wcsncasecmp wcscoll wcsxfrm wcsdup wcschr wcsrchr wcscspn wcsspn wcspbrk wcsstr wcstok wcswidth ; do
25632 as_gl_Symbol=`printf "%s\n" "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
25633 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
25634 printf %s "checking whether $gl_func is declared without a macro... " >&6; }
25635 if eval \${$as_gl_Symbol+:} false; then :
25636 printf %s "(cached) " >&6
25638 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25639 /* end confdefs.h. */
25641 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
25643 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
25644 included before <wchar.h>. */
25645 #if !(defined __GLIBC__ && !defined __UCLIBC__)
25646 # include <stddef.h>
25647 # include <stdio.h>
25661 if ac_fn_c_try_compile "$LINENO"; then :
25662 eval "$as_gl_Symbol=yes"
25664 eval "$as_gl_Symbol=no"
25666 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25668 eval ac_res=\$$as_gl_Symbol
25669 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
25670 printf "%s\n" "$ac_res" >&6; }
25671 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
25672 cat >>confdefs.h <<_ACEOF
25673 #define `printf "%s\n" "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
25676 eval ac_cv_have_decl_$gl_func=yes
25691 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
25695 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
25696 printf %s "checking whether mbrtowc handles incomplete characters... " >&6; }
25697 if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then :
25698 printf %s "(cached) " >&6
25702 # Guess no on AIX and OSF/1.
25703 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
25704 # Guess yes otherwise.
25705 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
25707 if test $LOCALE_JA != none; then
25708 if test "$cross_compiling" = yes; then :
25711 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25712 /* end confdefs.h. */
25714 #include <locale.h>
25715 #include <string.h>
25716 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
25718 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
25719 included before <wchar.h>. */
25720 #include <stddef.h>
25726 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
25728 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
25732 memset (&state, '\0', sizeof (mbstate_t));
25733 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
25734 if (mbsinit (&state))
25740 if ac_fn_c_try_run "$LINENO"; then :
25741 gl_cv_func_mbrtowc_incomplete_state=yes
25743 gl_cv_func_mbrtowc_incomplete_state=no
25745 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25746 conftest.$ac_objext conftest.beam conftest.$ac_ext
25752 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
25753 printf "%s\n" "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
25758 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
25759 printf %s "checking whether mbrtowc works as well as mbtowc... " >&6; }
25760 if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then :
25761 printf %s "(cached) " >&6
25765 # Guess no on Solaris 8.
25766 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
25767 # Guess yes otherwise.
25768 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
25770 if test $LOCALE_ZH_CN != none; then
25771 if test "$cross_compiling" = yes; then :
25774 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25775 /* end confdefs.h. */
25777 #include <locale.h>
25778 #include <stdlib.h>
25779 #include <string.h>
25780 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
25782 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
25783 included before <wchar.h>. */
25784 #include <stddef.h>
25790 /* This fails on Solaris 8:
25791 mbrtowc returns 2, and sets wc to 0x00F0.
25792 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
25793 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
25795 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
25799 memset (&state, '\0', sizeof (mbstate_t));
25800 if (mbrtowc (&wc, input + 3, 6, &state) != 4
25801 && mbtowc (&wc, input + 3, 6) == 4)
25807 if ac_fn_c_try_run "$LINENO"; then :
25808 gl_cv_func_mbrtowc_sanitycheck=yes
25810 gl_cv_func_mbrtowc_sanitycheck=no
25812 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25813 conftest.$ac_objext conftest.beam conftest.$ac_ext
25819 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
25820 printf "%s\n" "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
25822 REPLACE_MBSTATE_T=0
25823 case "$gl_cv_func_mbrtowc_incomplete_state" in
25825 *) REPLACE_MBSTATE_T=1 ;;
25827 case "$gl_cv_func_mbrtowc_sanitycheck" in
25829 *) REPLACE_MBSTATE_T=1 ;;
25832 REPLACE_MBSTATE_T=1
25837 if test $ac_cv_func_wcrtomb = no; then
25839 ac_fn_c_check_decl "$LINENO" "wcrtomb" "ac_cv_have_decl_wcrtomb" "
25840 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
25842 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
25843 included before <wchar.h>. */
25844 #include <stddef.h>
25850 if test "x$ac_cv_have_decl_wcrtomb" = xyes; then :
25856 cat >>confdefs.h <<_ACEOF
25857 #define HAVE_DECL_WCRTOMB $ac_have_decl
25860 if test $ac_cv_have_decl_wcrtomb = yes; then
25864 if test $REPLACE_MBSTATE_T = 1; then
25872 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether wcrtomb return value is correct" >&5
25873 printf %s "checking whether wcrtomb return value is correct... " >&6; }
25874 if ${gl_cv_func_wcrtomb_retval+:} false; then :
25875 printf %s "(cached) " >&6
25879 # Guess no on AIX 4, OSF/1 and Solaris.
25880 aix4* | osf* | solaris*) gl_cv_func_wcrtomb_retval="guessing no" ;;
25881 # Guess yes otherwise.
25882 *) gl_cv_func_wcrtomb_retval="guessing yes" ;;
25884 if test $LOCALE_FR != none || test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none || test $LOCALE_ZH_CN != none; then
25885 if test "$cross_compiling" = yes; then :
25888 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25889 /* end confdefs.h. */
25891 #include <locale.h>
25892 #include <string.h>
25893 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
25895 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
25896 included before <wchar.h>. */
25897 #include <stddef.h>
25904 if (setlocale (LC_ALL, "$LOCALE_FR") != NULL)
25906 if (wcrtomb (NULL, 0, NULL) != 1)
25909 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
25911 if (wcrtomb (NULL, 0, NULL) != 1)
25914 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
25916 if (wcrtomb (NULL, 0, NULL) != 1)
25919 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
25921 if (wcrtomb (NULL, 0, NULL) != 1)
25927 if ac_fn_c_try_run "$LINENO"; then :
25928 gl_cv_func_wcrtomb_retval=yes
25930 gl_cv_func_wcrtomb_retval=no
25932 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25933 conftest.$ac_objext conftest.beam conftest.$ac_ext
25939 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_wcrtomb_retval" >&5
25940 printf "%s\n" "$gl_cv_func_wcrtomb_retval" >&6; }
25941 case "$gl_cv_func_wcrtomb_retval" in
25943 *) REPLACE_WCRTOMB=1 ;;
25948 if test $HAVE_WCRTOMB = 0 || test $REPLACE_WCRTOMB = 1; then
25957 gl_LIBOBJS="$gl_LIBOBJS wcrtomb.$ac_objext"
25974 printf "%s\n" "#define GNULIB_TEST_WCRTOMB 1" >>confdefs.h
25983 if test $ac_cv_func_iswcntrl = yes; then
25991 if test $gt_cv_c_wint_t = yes; then
26007 if test $gl_cv_have_include_next = yes; then
26008 gl_cv_next_wctype_h='<'wctype.h'>'
26010 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking absolute name of <wctype.h>" >&5
26011 printf %s "checking absolute name of <wctype.h>... " >&6; }
26012 if ${gl_cv_next_wctype_h+:} false; then :
26013 printf %s "(cached) " >&6
26016 if test $ac_cv_header_wctype_h = yes; then
26019 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26020 /* end confdefs.h. */
26021 #include <wctype.h>
26025 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26026 *) gl_absname_cpp="$ac_cpp" ;;
26031 gl_dirsep_regex='[/\\]'
26034 gl_dirsep_regex='\/'
26037 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26039 gl_header_literal_regex=`echo 'wctype.h' \
26040 | sed -e "$gl_make_literal_regex_sed"`
26041 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26042 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26047 gl_cv_next_wctype_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26048 sed -n "$gl_absolute_header_sed"`'"'
26050 gl_cv_next_wctype_h='<'wctype.h'>'
26055 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wctype_h" >&5
26056 printf "%s\n" "$gl_cv_next_wctype_h" >&6; }
26058 NEXT_WCTYPE_H=$gl_cv_next_wctype_h
26060 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26061 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26062 gl_next_as_first_directive='<'wctype.h'>'
26064 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26065 gl_next_as_first_directive=$gl_cv_next_wctype_h
26067 NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H=$gl_next_as_first_directive
26072 if test $ac_cv_header_wctype_h = yes; then
26073 if test $ac_cv_func_iswcntrl = yes; then
26074 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether iswcntrl works" >&5
26075 printf %s "checking whether iswcntrl works... " >&6; }
26076 if ${gl_cv_func_iswcntrl_works+:} false; then :
26077 printf %s "(cached) " >&6
26080 if test "$cross_compiling" = yes; then :
26081 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26082 /* end confdefs.h. */
26083 #include <stdlib.h>
26084 #if __GNU_LIBRARY__ == 1
26085 Linux libc5 i18n is broken.
26095 if ac_fn_c_try_compile "$LINENO"; then :
26096 gl_cv_func_iswcntrl_works="guessing yes"
26098 gl_cv_func_iswcntrl_works="guessing no"
26100 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26103 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26104 /* end confdefs.h. */
26106 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
26107 included before <wchar.h>.
26108 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
26109 must be included before <wchar.h>. */
26110 #include <stddef.h>
26114 #include <wctype.h>
26115 int main () { return iswprint ('x') == 0; }
26118 if ac_fn_c_try_run "$LINENO"; then :
26119 gl_cv_func_iswcntrl_works=yes
26121 gl_cv_func_iswcntrl_works=no
26123 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
26124 conftest.$ac_objext conftest.beam conftest.$ac_ext
26129 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_iswcntrl_works" >&5
26130 printf "%s\n" "$gl_cv_func_iswcntrl_works" >&6; }
26138 case "$gl_cv_func_iswcntrl_works" in
26139 *yes) REPLACE_ISWCNTRL=0 ;;
26140 *) REPLACE_ISWCNTRL=1 ;;
26144 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_ISWCNTRL = 1; then
26148 if test $REPLACE_ISWCNTRL = 1; then
26151 for ac_func in towlower
26153 ac_fn_c_check_func "$LINENO" "towlower" "ac_cv_func_towlower"
26154 if test "x$ac_cv_func_towlower" = xyes; then :
26155 cat >>confdefs.h <<_ACEOF
26156 #define HAVE_TOWLOWER 1
26162 if test $ac_cv_func_towlower = yes; then
26165 ac_fn_c_check_decl "$LINENO" "towlower" "ac_cv_have_decl_towlower" "/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
26166 included before <wchar.h>.
26167 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
26168 must be included before <wchar.h>. */
26169 #include <stddef.h>
26174 # include <wctype.h>
26178 if test "x$ac_cv_have_decl_towlower" = xyes; then :
26184 cat >>confdefs.h <<_ACEOF
26185 #define HAVE_DECL_TOWLOWER $ac_have_decl
26188 if test $ac_cv_have_decl_towlower = yes; then
26197 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_TOWLOWER = 1; then
26201 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for wctype_t" >&5
26202 printf %s "checking for wctype_t... " >&6; }
26203 if ${gl_cv_type_wctype_t+:} false; then :
26204 printf %s "(cached) " >&6
26206 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26207 /* end confdefs.h. */
26208 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
26209 included before <wchar.h>.
26210 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
26211 must be included before <wchar.h>. */
26212 #include <stddef.h>
26217 # include <wctype.h>
26229 if ac_fn_c_try_compile "$LINENO"; then :
26230 gl_cv_type_wctype_t=yes
26232 gl_cv_type_wctype_t=no
26234 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26237 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctype_t" >&5
26238 printf "%s\n" "$gl_cv_type_wctype_t" >&6; }
26239 if test $gl_cv_type_wctype_t = no; then
26243 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for wctrans_t" >&5
26244 printf %s "checking for wctrans_t... " >&6; }
26245 if ${gl_cv_type_wctrans_t+:} false; then :
26246 printf %s "(cached) " >&6
26248 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26249 /* end confdefs.h. */
26250 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
26251 included before <wchar.h>.
26252 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
26253 must be included before <wchar.h>. */
26254 #include <stddef.h>
26258 #include <wctype.h>
26269 if ac_fn_c_try_compile "$LINENO"; then :
26270 gl_cv_type_wctrans_t=yes
26272 gl_cv_type_wctrans_t=no
26274 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26277 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctrans_t" >&5
26278 printf "%s\n" "$gl_cv_type_wctrans_t" >&6; }
26279 if test $gl_cv_type_wctrans_t = no; then
26284 for gl_func in wctype iswctype wctrans towctrans ; do
26285 as_gl_Symbol=`printf "%s\n" "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
26286 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
26287 printf %s "checking whether $gl_func is declared without a macro... " >&6; }
26288 if eval \${$as_gl_Symbol+:} false; then :
26289 printf %s "(cached) " >&6
26291 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26292 /* end confdefs.h. */
26294 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
26296 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
26297 included before <wchar.h>. */
26298 #if !(defined __GLIBC__ && !defined __UCLIBC__)
26299 # include <stddef.h>
26300 # include <stdio.h>
26302 # include <wchar.h>
26304 #include <wctype.h>
26315 if ac_fn_c_try_compile "$LINENO"; then :
26316 eval "$as_gl_Symbol=yes"
26318 eval "$as_gl_Symbol=no"
26320 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26322 eval ac_res=\$$as_gl_Symbol
26323 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
26324 printf "%s\n" "$ac_res" >&6; }
26325 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
26326 cat >>confdefs.h <<_ACEOF
26327 #define `printf "%s\n" "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
26330 eval ac_cv_have_decl_$gl_func=yes
26346 ac_fn_c_check_decl "$LINENO" "wcwidth" "ac_cv_have_decl_wcwidth" "
26347 /* AIX 3.2.5 declares wcwidth in <string.h>. */
26348 #include <string.h>
26349 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
26351 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
26352 before <wchar.h>. */
26353 #include <stddef.h>
26359 if test "x$ac_cv_have_decl_wcwidth" = xyes; then :
26365 cat >>confdefs.h <<_ACEOF
26366 #define HAVE_DECL_WCWIDTH $ac_have_decl
26369 if test $ac_cv_have_decl_wcwidth != yes; then
26370 HAVE_DECL_WCWIDTH=0
26373 if test $ac_cv_func_wcwidth = yes; then
26375 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether wcwidth works reasonably in UTF-8 locales" >&5
26376 printf %s "checking whether wcwidth works reasonably in UTF-8 locales... " >&6; }
26377 if ${gl_cv_func_wcwidth_works+:} false; then :
26378 printf %s "(cached) " >&6
26381 if test "$cross_compiling" = yes; then :
26384 # Guess yes on glibc and AIX 7 systems.
26385 *-gnu* | aix[7-9]*) gl_cv_func_wcwidth_works="guessing yes";;
26386 *) gl_cv_func_wcwidth_works="guessing no";;
26390 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26391 /* end confdefs.h. */
26393 #include <locale.h>
26394 /* AIX 3.2.5 declares wcwidth in <string.h>. */
26395 #include <string.h>
26396 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
26398 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
26399 before <wchar.h>. */
26400 #include <stddef.h>
26404 #if !HAVE_DECL_WCWIDTH
26406 # ifdef __cplusplus
26414 if (setlocale (LC_ALL, "fr_FR.UTF-8") != NULL)
26416 if (wcwidth (0x0301) > 0)
26418 if (wcwidth (0x05B0) > 0)
26420 if (wcwidth (0x200B) > 0)
26426 if ac_fn_c_try_run "$LINENO"; then :
26427 gl_cv_func_wcwidth_works=yes
26429 gl_cv_func_wcwidth_works=no
26431 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
26432 conftest.$ac_objext conftest.beam conftest.$ac_ext
26437 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_wcwidth_works" >&5
26438 printf "%s\n" "$gl_cv_func_wcwidth_works" >&6; }
26439 case "$gl_cv_func_wcwidth_works" in
26441 *no) REPLACE_WCWIDTH=1 ;;
26447 if test $HAVE_WCWIDTH = 0 || test $REPLACE_WCWIDTH = 1; then
26456 gl_LIBOBJS="$gl_LIBOBJS wcwidth.$ac_objext"
26470 printf "%s\n" "#define GNULIB_TEST_WCWIDTH 1" >>confdefs.h
26477 for ac_header in stdint.h
26479 ac_fn_c_check_header_mongrel "$LINENO" "stdint.h" "ac_cv_header_stdint_h" "$ac_includes_default"
26480 if test "x$ac_cv_header_stdint_h" = xyes; then :
26481 cat >>confdefs.h <<_ACEOF
26482 #define HAVE_STDINT_H 1
26501 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=xasprintf:1:c-format"
26503 # End of code from modules
26524 gl_source_base='gnulib-tests'
26525 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
26527 gl_module_indicator_condition=$gltests_WITNESS
26532 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
26533 printf %s "checking for a traditional french locale... " >&6; }
26534 if ${gt_cv_locale_fr+:} false; then :
26535 printf %s "(cached) " >&6
26538 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26539 /* end confdefs.h. */
26541 #include <locale.h>
26543 #if HAVE_LANGINFO_CODESET
26544 # include <langinfo.h>
26546 #include <stdlib.h>
26547 #include <string.h>
26551 /* Check whether the given locale name is recognized by the system. */
26552 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
26553 /* On native Windows, setlocale(category, "") looks at the system settings,
26554 not at the environment variables. Also, when an encoding suffix such
26555 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
26556 category of the locale to "C". */
26557 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
26558 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
26561 if (setlocale (LC_ALL, "") == NULL) return 1;
26563 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
26564 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
26565 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
26566 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
26567 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
26568 some unit tests fail.
26569 On MirBSD 10, when an unsupported locale is specified, setlocale()
26570 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
26571 #if HAVE_LANGINFO_CODESET
26573 const char *cs = nl_langinfo (CODESET);
26574 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
26575 || strcmp (cs, "UTF-8") == 0)
26580 /* On Cygwin, avoid locale names without encoding suffix, because the
26581 locale_charset() function relies on the encoding suffix. Note that
26582 LC_ALL is set on the command line. */
26583 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
26585 /* Check whether in the abbreviation of the second month, the second
26586 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
26587 one byte long. This excludes the UTF-8 encoding. */
26588 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
26589 if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
26590 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
26591 /* Check whether the decimal separator is a comma.
26592 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
26593 are nl_langinfo(RADIXCHAR) are both ".". */
26594 if (localeconv () ->decimal_point[0] != ',') return 1;
26600 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
26601 (eval $ac_link) 2>&5
26603 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
26604 test $ac_status = 0; } && test -s conftest$ac_exeext; then
26606 # Handle native Windows specially, because there setlocale() interprets
26607 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
26608 # "fr" or "fra" as "French" or "French_France.1252",
26609 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
26610 # "ja" as "Japanese" or "Japanese_Japan.932",
26613 # Test for the native Windows locale name.
26614 if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
26615 gt_cv_locale_fr=French_France.1252
26618 gt_cv_locale_fr=none
26622 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
26623 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
26624 # configure script would override the LC_ALL setting. Likewise for
26625 # LC_CTYPE, which is also set at the beginning of the configure script.
26626 # Test for the usual locale name.
26627 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
26628 gt_cv_locale_fr=fr_FR
26630 # Test for the locale name with explicit encoding suffix.
26631 if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
26632 gt_cv_locale_fr=fr_FR.ISO-8859-1
26634 # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
26635 if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
26636 gt_cv_locale_fr=fr_FR.ISO8859-1
26638 # Test for the HP-UX locale name.
26639 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
26640 gt_cv_locale_fr=fr_FR.iso88591
26642 # Test for the Solaris 7 locale name.
26643 if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
26647 gt_cv_locale_fr=none
26659 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
26660 printf "%s\n" "$gt_cv_locale_fr" >&6; }
26661 LOCALE_FR=$gt_cv_locale_fr
26666 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
26667 printf %s "checking for a french Unicode locale... " >&6; }
26668 if ${gt_cv_locale_fr_utf8+:} false; then :
26669 printf %s "(cached) " >&6
26672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26673 /* end confdefs.h. */
26675 #include <locale.h>
26677 #if HAVE_LANGINFO_CODESET
26678 # include <langinfo.h>
26680 #include <stdlib.h>
26681 #include <string.h>
26685 /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
26686 imitates locale dependent behaviour by looking at the environment
26687 variables, and all locales use the UTF-8 encoding. */
26688 #if !(defined __BEOS__ || defined __HAIKU__)
26689 /* Check whether the given locale name is recognized by the system. */
26690 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
26691 /* On native Windows, setlocale(category, "") looks at the system settings,
26692 not at the environment variables. Also, when an encoding suffix such
26693 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
26694 category of the locale to "C". */
26695 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
26696 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
26699 if (setlocale (LC_ALL, "") == NULL) return 1;
26701 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
26702 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
26703 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
26704 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
26705 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
26706 some unit tests fail. */
26707 # if HAVE_LANGINFO_CODESET
26709 const char *cs = nl_langinfo (CODESET);
26710 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
26715 /* On Cygwin, avoid locale names without encoding suffix, because the
26716 locale_charset() function relies on the encoding suffix. Note that
26717 LC_ALL is set on the command line. */
26718 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
26720 /* Check whether in the abbreviation of the second month, the second
26721 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
26722 two bytes long, with UTF-8 encoding. */
26723 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
26724 if (strftime (buf, sizeof (buf), "%b", &t) < 4
26725 || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
26728 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
26729 /* Check whether the decimal separator is a comma.
26730 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
26731 are nl_langinfo(RADIXCHAR) are both ".". */
26732 if (localeconv () ->decimal_point[0] != ',') return 1;
26738 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
26739 (eval $ac_link) 2>&5
26741 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
26742 test $ac_status = 0; } && test -s conftest$ac_exeext; then
26744 # Handle native Windows specially, because there setlocale() interprets
26745 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
26746 # "fr" or "fra" as "French" or "French_France.1252",
26747 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
26748 # "ja" as "Japanese" or "Japanese_Japan.932",
26751 # Test for the hypothetical native Windows locale name.
26752 if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
26753 gt_cv_locale_fr_utf8=French_France.65001
26756 gt_cv_locale_fr_utf8=none
26760 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
26761 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
26762 # configure script would override the LC_ALL setting. Likewise for
26763 # LC_CTYPE, which is also set at the beginning of the configure script.
26764 # Test for the usual locale name.
26765 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
26766 gt_cv_locale_fr_utf8=fr_FR
26768 # Test for the locale name with explicit encoding suffix.
26769 if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
26770 gt_cv_locale_fr_utf8=fr_FR.UTF-8
26772 # Test for the Solaris 7 locale name.
26773 if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
26774 gt_cv_locale_fr_utf8=fr.UTF-8
26777 gt_cv_locale_fr_utf8=none
26787 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
26788 printf "%s\n" "$gt_cv_locale_fr_utf8" >&6; }
26789 LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
26795 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
26796 printf %s "checking for a traditional french locale... " >&6; }
26797 if ${gt_cv_locale_fr+:} false; then :
26798 printf %s "(cached) " >&6
26801 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26802 /* end confdefs.h. */
26804 #include <locale.h>
26806 #if HAVE_LANGINFO_CODESET
26807 # include <langinfo.h>
26809 #include <stdlib.h>
26810 #include <string.h>
26814 /* Check whether the given locale name is recognized by the system. */
26815 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
26816 /* On native Windows, setlocale(category, "") looks at the system settings,
26817 not at the environment variables. Also, when an encoding suffix such
26818 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
26819 category of the locale to "C". */
26820 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
26821 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
26824 if (setlocale (LC_ALL, "") == NULL) return 1;
26826 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
26827 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
26828 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
26829 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
26830 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
26831 some unit tests fail.
26832 On MirBSD 10, when an unsupported locale is specified, setlocale()
26833 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
26834 #if HAVE_LANGINFO_CODESET
26836 const char *cs = nl_langinfo (CODESET);
26837 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
26838 || strcmp (cs, "UTF-8") == 0)
26843 /* On Cygwin, avoid locale names without encoding suffix, because the
26844 locale_charset() function relies on the encoding suffix. Note that
26845 LC_ALL is set on the command line. */
26846 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
26848 /* Check whether in the abbreviation of the second month, the second
26849 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
26850 one byte long. This excludes the UTF-8 encoding. */
26851 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
26852 if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
26853 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
26854 /* Check whether the decimal separator is a comma.
26855 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
26856 are nl_langinfo(RADIXCHAR) are both ".". */
26857 if (localeconv () ->decimal_point[0] != ',') return 1;
26863 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
26864 (eval $ac_link) 2>&5
26866 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
26867 test $ac_status = 0; } && test -s conftest$ac_exeext; then
26869 # Handle native Windows specially, because there setlocale() interprets
26870 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
26871 # "fr" or "fra" as "French" or "French_France.1252",
26872 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
26873 # "ja" as "Japanese" or "Japanese_Japan.932",
26876 # Test for the native Windows locale name.
26877 if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
26878 gt_cv_locale_fr=French_France.1252
26881 gt_cv_locale_fr=none
26885 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
26886 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
26887 # configure script would override the LC_ALL setting. Likewise for
26888 # LC_CTYPE, which is also set at the beginning of the configure script.
26889 # Test for the usual locale name.
26890 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
26891 gt_cv_locale_fr=fr_FR
26893 # Test for the locale name with explicit encoding suffix.
26894 if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
26895 gt_cv_locale_fr=fr_FR.ISO-8859-1
26897 # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
26898 if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
26899 gt_cv_locale_fr=fr_FR.ISO8859-1
26901 # Test for the HP-UX locale name.
26902 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
26903 gt_cv_locale_fr=fr_FR.iso88591
26905 # Test for the Solaris 7 locale name.
26906 if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
26910 gt_cv_locale_fr=none
26922 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
26923 printf "%s\n" "$gt_cv_locale_fr" >&6; }
26924 LOCALE_FR=$gt_cv_locale_fr
26930 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a turkish Unicode locale" >&5
26931 printf %s "checking for a turkish Unicode locale... " >&6; }
26932 if ${gt_cv_locale_tr_utf8+:} false; then :
26933 printf %s "(cached) " >&6
26936 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26937 /* end confdefs.h. */
26939 #include <locale.h>
26941 #if HAVE_LANGINFO_CODESET
26942 # include <langinfo.h>
26944 #include <stdlib.h>
26945 #include <string.h>
26949 /* On BeOS, locales are not implemented in libc. Rather, libintl
26950 imitates locale dependent behaviour by looking at the environment
26951 variables, and all locales use the UTF-8 encoding. But BeOS does not
26952 implement the Turkish upper-/lowercase mappings. Therefore, let this
26953 program return 1 on BeOS. */
26954 /* Check whether the given locale name is recognized by the system. */
26955 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
26956 /* On native Windows, setlocale(category, "") looks at the system settings,
26957 not at the environment variables. Also, when an encoding suffix such
26958 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
26959 category of the locale to "C". */
26960 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
26961 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
26964 if (setlocale (LC_ALL, "") == NULL) return 1;
26966 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
26967 On Mac OS X 10.3.5 (Darwin 7.5) in the tr_TR locale, nl_langinfo(CODESET)
26968 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
26969 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
26970 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
26971 some unit tests fail. */
26972 #if HAVE_LANGINFO_CODESET
26974 const char *cs = nl_langinfo (CODESET);
26975 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
26980 /* On Cygwin, avoid locale names without encoding suffix, because the
26981 locale_charset() function relies on the encoding suffix. Note that
26982 LC_ALL is set on the command line. */
26983 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
26985 /* Check whether in the abbreviation of the eighth month, the second
26986 character (should be U+011F: LATIN SMALL LETTER G WITH BREVE) is
26987 two bytes long, with UTF-8 encoding. */
26988 t.tm_year = 1992 - 1900; t.tm_mon = 8 - 1; t.tm_mday = 19;
26989 if (strftime (buf, sizeof (buf), "%b", &t) < 4
26990 || buf[1] != (char) 0xc4 || buf[2] != (char) 0x9f)
26992 /* Check whether the upper-/lowercase mappings are as expected for
26994 if (towupper ('i') != 0x0130 || towlower (0x0130) != 'i'
26995 || towupper(0x0131) != 'I' || towlower ('I') != 0x0131)
27001 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
27002 (eval $ac_link) 2>&5
27004 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
27005 test $ac_status = 0; } && test -s conftest$ac_exeext; then
27007 # Handle native Windows specially, because there setlocale() interprets
27008 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
27009 # "fr" or "fra" as "French" or "French_France.1252",
27010 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
27011 # "ja" as "Japanese" or "Japanese_Japan.932",
27014 # Test for the hypothetical native Windows locale name.
27015 if (LC_ALL=Turkish_Turkey.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27016 gt_cv_locale_tr_utf8=Turkish_Turkey.65001
27019 gt_cv_locale_tr_utf8=none
27023 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
27024 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
27025 # configure script would override the LC_ALL setting. Likewise for
27026 # LC_CTYPE, which is also set at the beginning of the configure script.
27027 # Test for the usual locale name.
27028 if (LC_ALL=tr_TR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27029 gt_cv_locale_tr_utf8=tr_TR
27031 # Test for the locale name with explicit encoding suffix.
27032 if (LC_ALL=tr_TR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27033 gt_cv_locale_tr_utf8=tr_TR.UTF-8
27035 # Test for the Solaris 7 locale name.
27036 if (LC_ALL=tr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27037 gt_cv_locale_tr_utf8=tr.UTF-8
27040 gt_cv_locale_tr_utf8=none
27047 gt_cv_locale_tr_utf8=none
27052 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_tr_utf8" >&5
27053 printf "%s\n" "$gt_cv_locale_tr_utf8" >&6; }
27054 LOCALE_TR_UTF8=$gt_cv_locale_tr_utf8
27063 if test "$GNULIB_ENVIRON" != 1; then
27064 if test "$GNULIB_ENVIRON" = 0; then
27065 GNULIB_ENVIRON=$gl_module_indicator_condition
27067 GNULIB_ENVIRON="($GNULIB_ENVIRON || $gl_module_indicator_condition)"
27075 printf "%s\n" "#define GNULIB_TEST_ENVIRON 1" >>confdefs.h
27082 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
27085 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether fdopen sets errno" >&5
27086 printf %s "checking whether fdopen sets errno... " >&6; }
27087 if ${gl_cv_func_fdopen_works+:} false; then :
27088 printf %s "(cached) " >&6
27091 if test "$cross_compiling" = yes; then :
27093 mingw*) gl_cv_func_fdopen_works="guessing no" ;;
27094 *) gl_cv_func_fdopen_works="guessing yes" ;;
27098 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27099 /* end confdefs.h. */
27108 fp = fdopen (-1, "r");
27109 if (fp == NULL && errno == 0)
27114 if ac_fn_c_try_run "$LINENO"; then :
27115 gl_cv_func_fdopen_works=yes
27117 gl_cv_func_fdopen_works=no
27119 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27120 conftest.$ac_objext conftest.beam conftest.$ac_ext
27125 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fdopen_works" >&5
27126 printf "%s\n" "$gl_cv_func_fdopen_works" >&6; }
27127 case "$gl_cv_func_fdopen_works" in
27128 *no) REPLACE_FDOPEN=1 ;;
27132 if test $REPLACE_FDOPEN = 1; then
27141 gltests_LIBOBJS="$gltests_LIBOBJS fdopen.$ac_objext"
27150 if test "$GNULIB_FDOPEN" != 1; then
27151 if test "$GNULIB_FDOPEN" = 0; then
27152 GNULIB_FDOPEN=$gl_module_indicator_condition
27154 GNULIB_FDOPEN="($GNULIB_FDOPEN || $gl_module_indicator_condition)"
27162 printf "%s\n" "#define GNULIB_TEST_FDOPEN 1" >>confdefs.h
27171 case $gl_cv_func_getcwd_null,$gl_cv_func_getcwd_posix_signature in
27178 if test $REPLACE_GETCWD = 1; then
27187 gltests_LIBOBJS="$gltests_LIBOBJS getcwd-lgpl.$ac_objext"
27195 if test "$GNULIB_GETCWD" != 1; then
27196 if test "$GNULIB_GETCWD" = 0; then
27197 GNULIB_GETCWD=$gl_module_indicator_condition
27199 GNULIB_GETCWD="($GNULIB_GETCWD || $gl_module_indicator_condition)"
27207 printf "%s\n" "#define GNULIB_TEST_GETCWD 1" >>confdefs.h
27214 for ac_func in getpagesize
27216 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
27217 if test "x$ac_cv_func_getpagesize" = xyes; then :
27218 cat >>confdefs.h <<_ACEOF
27219 #define HAVE_GETPAGESIZE 1
27225 if test $ac_cv_func_getpagesize = no; then
27227 for ac_header in OS.h
27229 ac_fn_c_check_header_mongrel "$LINENO" "OS.h" "ac_cv_header_OS_h" "$ac_includes_default"
27230 if test "x$ac_cv_header_OS_h" = xyes; then :
27231 cat >>confdefs.h <<_ACEOF
27232 #define HAVE_OS_H 1
27239 if test $ac_cv_header_OS_h = yes; then
27242 for ac_header in sys/param.h
27244 ac_fn_c_check_header_mongrel "$LINENO" "sys/param.h" "ac_cv_header_sys_param_h" "$ac_includes_default"
27245 if test "x$ac_cv_header_sys_param_h" = xyes; then :
27246 cat >>confdefs.h <<_ACEOF
27247 #define HAVE_SYS_PARAM_H 1
27254 if test $ac_cv_header_sys_param_h = yes; then
27260 REPLACE_GETPAGESIZE=1
27263 ac_fn_c_check_decl "$LINENO" "getpagesize" "ac_cv_have_decl_getpagesize" "$ac_includes_default"
27264 if test "x$ac_cv_have_decl_getpagesize" = xyes; then :
27267 HAVE_DECL_GETPAGESIZE=0
27271 if test $REPLACE_GETPAGESIZE = 1; then
27280 gltests_LIBOBJS="$gltests_LIBOBJS getpagesize.$ac_objext"
27288 if test "$GNULIB_GETPAGESIZE" != 1; then
27289 if test "$GNULIB_GETPAGESIZE" = 0; then
27290 GNULIB_GETPAGESIZE=$gl_module_indicator_condition
27292 GNULIB_GETPAGESIZE="($GNULIB_GETPAGESIZE || $gl_module_indicator_condition)"
27300 printf "%s\n" "#define GNULIB_TEST_GETPAGESIZE 1" >>confdefs.h
27308 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
27309 printf %s "checking for a traditional french locale... " >&6; }
27310 if ${gt_cv_locale_fr+:} false; then :
27311 printf %s "(cached) " >&6
27314 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27315 /* end confdefs.h. */
27317 #include <locale.h>
27319 #if HAVE_LANGINFO_CODESET
27320 # include <langinfo.h>
27322 #include <stdlib.h>
27323 #include <string.h>
27327 /* Check whether the given locale name is recognized by the system. */
27328 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
27329 /* On native Windows, setlocale(category, "") looks at the system settings,
27330 not at the environment variables. Also, when an encoding suffix such
27331 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
27332 category of the locale to "C". */
27333 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
27334 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
27337 if (setlocale (LC_ALL, "") == NULL) return 1;
27339 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
27340 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
27341 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
27342 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
27343 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
27344 some unit tests fail.
27345 On MirBSD 10, when an unsupported locale is specified, setlocale()
27346 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
27347 #if HAVE_LANGINFO_CODESET
27349 const char *cs = nl_langinfo (CODESET);
27350 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
27351 || strcmp (cs, "UTF-8") == 0)
27356 /* On Cygwin, avoid locale names without encoding suffix, because the
27357 locale_charset() function relies on the encoding suffix. Note that
27358 LC_ALL is set on the command line. */
27359 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
27361 /* Check whether in the abbreviation of the second month, the second
27362 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
27363 one byte long. This excludes the UTF-8 encoding. */
27364 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
27365 if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
27366 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
27367 /* Check whether the decimal separator is a comma.
27368 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
27369 are nl_langinfo(RADIXCHAR) are both ".". */
27370 if (localeconv () ->decimal_point[0] != ',') return 1;
27376 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
27377 (eval $ac_link) 2>&5
27379 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
27380 test $ac_status = 0; } && test -s conftest$ac_exeext; then
27382 # Handle native Windows specially, because there setlocale() interprets
27383 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
27384 # "fr" or "fra" as "French" or "French_France.1252",
27385 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
27386 # "ja" as "Japanese" or "Japanese_Japan.932",
27389 # Test for the native Windows locale name.
27390 if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27391 gt_cv_locale_fr=French_France.1252
27394 gt_cv_locale_fr=none
27398 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
27399 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
27400 # configure script would override the LC_ALL setting. Likewise for
27401 # LC_CTYPE, which is also set at the beginning of the configure script.
27402 # Test for the usual locale name.
27403 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27404 gt_cv_locale_fr=fr_FR
27406 # Test for the locale name with explicit encoding suffix.
27407 if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27408 gt_cv_locale_fr=fr_FR.ISO-8859-1
27410 # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
27411 if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27412 gt_cv_locale_fr=fr_FR.ISO8859-1
27414 # Test for the HP-UX locale name.
27415 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27416 gt_cv_locale_fr=fr_FR.iso88591
27418 # Test for the Solaris 7 locale name.
27419 if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27423 gt_cv_locale_fr=none
27435 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
27436 printf "%s\n" "$gt_cv_locale_fr" >&6; }
27437 LOCALE_FR=$gt_cv_locale_fr
27442 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
27443 printf %s "checking for a french Unicode locale... " >&6; }
27444 if ${gt_cv_locale_fr_utf8+:} false; then :
27445 printf %s "(cached) " >&6
27448 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27449 /* end confdefs.h. */
27451 #include <locale.h>
27453 #if HAVE_LANGINFO_CODESET
27454 # include <langinfo.h>
27456 #include <stdlib.h>
27457 #include <string.h>
27461 /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
27462 imitates locale dependent behaviour by looking at the environment
27463 variables, and all locales use the UTF-8 encoding. */
27464 #if !(defined __BEOS__ || defined __HAIKU__)
27465 /* Check whether the given locale name is recognized by the system. */
27466 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
27467 /* On native Windows, setlocale(category, "") looks at the system settings,
27468 not at the environment variables. Also, when an encoding suffix such
27469 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
27470 category of the locale to "C". */
27471 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
27472 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
27475 if (setlocale (LC_ALL, "") == NULL) return 1;
27477 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
27478 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
27479 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
27480 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
27481 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
27482 some unit tests fail. */
27483 # if HAVE_LANGINFO_CODESET
27485 const char *cs = nl_langinfo (CODESET);
27486 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
27491 /* On Cygwin, avoid locale names without encoding suffix, because the
27492 locale_charset() function relies on the encoding suffix. Note that
27493 LC_ALL is set on the command line. */
27494 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
27496 /* Check whether in the abbreviation of the second month, the second
27497 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
27498 two bytes long, with UTF-8 encoding. */
27499 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
27500 if (strftime (buf, sizeof (buf), "%b", &t) < 4
27501 || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
27504 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
27505 /* Check whether the decimal separator is a comma.
27506 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
27507 are nl_langinfo(RADIXCHAR) are both ".". */
27508 if (localeconv () ->decimal_point[0] != ',') return 1;
27514 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
27515 (eval $ac_link) 2>&5
27517 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
27518 test $ac_status = 0; } && test -s conftest$ac_exeext; then
27520 # Handle native Windows specially, because there setlocale() interprets
27521 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
27522 # "fr" or "fra" as "French" or "French_France.1252",
27523 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
27524 # "ja" as "Japanese" or "Japanese_Japan.932",
27527 # Test for the hypothetical native Windows locale name.
27528 if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27529 gt_cv_locale_fr_utf8=French_France.65001
27532 gt_cv_locale_fr_utf8=none
27536 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
27537 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
27538 # configure script would override the LC_ALL setting. Likewise for
27539 # LC_CTYPE, which is also set at the beginning of the configure script.
27540 # Test for the usual locale name.
27541 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27542 gt_cv_locale_fr_utf8=fr_FR
27544 # Test for the locale name with explicit encoding suffix.
27545 if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27546 gt_cv_locale_fr_utf8=fr_FR.UTF-8
27548 # Test for the Solaris 7 locale name.
27549 if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27550 gt_cv_locale_fr_utf8=fr.UTF-8
27553 gt_cv_locale_fr_utf8=none
27563 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
27564 printf "%s\n" "$gt_cv_locale_fr_utf8" >&6; }
27565 LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
27571 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a traditional japanese locale" >&5
27572 printf %s "checking for a traditional japanese locale... " >&6; }
27573 if ${gt_cv_locale_ja+:} false; then :
27574 printf %s "(cached) " >&6
27577 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27578 /* end confdefs.h. */
27580 #include <locale.h>
27582 #if HAVE_LANGINFO_CODESET
27583 # include <langinfo.h>
27585 #include <stdlib.h>
27586 #include <string.h>
27592 /* Check whether the given locale name is recognized by the system. */
27593 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
27594 /* On native Windows, setlocale(category, "") looks at the system settings,
27595 not at the environment variables. Also, when an encoding suffix such
27596 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
27597 category of the locale to "C". */
27598 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
27599 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
27602 if (setlocale (LC_ALL, "") == NULL) return 1;
27604 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
27605 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
27606 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
27607 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
27608 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
27609 some unit tests fail.
27610 On MirBSD 10, when an unsupported locale is specified, setlocale()
27611 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
27612 #if HAVE_LANGINFO_CODESET
27614 const char *cs = nl_langinfo (CODESET);
27615 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
27616 || strcmp (cs, "UTF-8") == 0)
27621 /* On Cygwin, avoid locale names without encoding suffix, because the
27622 locale_charset() function relies on the encoding suffix. Note that
27623 LC_ALL is set on the command line. */
27624 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
27626 /* Check whether MB_CUR_MAX is > 1. This excludes the dysfunctional locales
27627 on Cygwin 1.5.x. */
27628 if (MB_CUR_MAX == 1)
27630 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
27631 This excludes the UTF-8 encoding (except on MirBSD). */
27632 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
27633 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
27634 for (p = buf; *p != '\0'; p++)
27635 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
27641 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
27642 (eval $ac_link) 2>&5
27644 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
27645 test $ac_status = 0; } && test -s conftest$ac_exeext; then
27647 # Handle native Windows specially, because there setlocale() interprets
27648 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
27649 # "fr" or "fra" as "French" or "French_France.1252",
27650 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
27651 # "ja" as "Japanese" or "Japanese_Japan.932",
27654 # Note that on native Windows, the Japanese locale is
27655 # Japanese_Japan.932, and CP932 is very different from EUC-JP, so we
27656 # cannot use it here.
27657 gt_cv_locale_ja=none
27660 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
27661 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
27662 # configure script would override the LC_ALL setting. Likewise for
27663 # LC_CTYPE, which is also set at the beginning of the configure script.
27664 # Test for the AIX locale name.
27665 if (LC_ALL=ja_JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27666 gt_cv_locale_ja=ja_JP
27668 # Test for the locale name with explicit encoding suffix.
27669 if (LC_ALL=ja_JP.EUC-JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27670 gt_cv_locale_ja=ja_JP.EUC-JP
27672 # Test for the HP-UX, OSF/1, NetBSD locale name.
27673 if (LC_ALL=ja_JP.eucJP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27674 gt_cv_locale_ja=ja_JP.eucJP
27676 # Test for the IRIX, FreeBSD locale name.
27677 if (LC_ALL=ja_JP.EUC LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27678 gt_cv_locale_ja=ja_JP.EUC
27680 # Test for the Solaris 7 locale name.
27681 if (LC_ALL=ja LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27684 # Special test for NetBSD 1.6.
27685 if test -f /usr/share/locale/ja_JP.eucJP/LC_CTYPE; then
27686 gt_cv_locale_ja=ja_JP.eucJP
27689 gt_cv_locale_ja=none
27702 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_ja" >&5
27703 printf "%s\n" "$gt_cv_locale_ja" >&6; }
27704 LOCALE_JA=$gt_cv_locale_ja
27710 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a transitional chinese locale" >&5
27711 printf %s "checking for a transitional chinese locale... " >&6; }
27712 if ${gt_cv_locale_zh_CN+:} false; then :
27713 printf %s "(cached) " >&6
27716 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27717 /* end confdefs.h. */
27719 #include <locale.h>
27720 #include <stdlib.h>
27722 #if HAVE_LANGINFO_CODESET
27723 # include <langinfo.h>
27725 #include <stdlib.h>
27726 #include <string.h>
27732 /* Check whether the given locale name is recognized by the system. */
27733 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
27734 /* On native Windows, setlocale(category, "") looks at the system settings,
27735 not at the environment variables. Also, when an encoding suffix such
27736 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
27737 category of the locale to "C". */
27738 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
27739 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
27742 if (setlocale (LC_ALL, "") == NULL) return 1;
27744 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
27745 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
27746 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
27747 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
27748 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
27749 some unit tests fail.
27750 On MirBSD 10, when an unsupported locale is specified, setlocale()
27751 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
27752 #if HAVE_LANGINFO_CODESET
27754 const char *cs = nl_langinfo (CODESET);
27755 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
27756 || strcmp (cs, "UTF-8") == 0)
27761 /* On Cygwin, avoid locale names without encoding suffix, because the
27762 locale_charset() function relies on the encoding suffix. Note that
27763 LC_ALL is set on the command line. */
27764 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
27766 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
27767 This excludes the UTF-8 encoding (except on MirBSD). */
27768 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
27769 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
27770 for (p = buf; *p != '\0'; p++)
27771 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
27773 /* Check whether a typical GB18030 multibyte sequence is recognized as a
27774 single wide character. This excludes the GB2312 and GBK encodings. */
27775 if (mblen ("\203\062\332\066", 5) != 4)
27781 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
27782 (eval $ac_link) 2>&5
27784 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
27785 test $ac_status = 0; } && test -s conftest$ac_exeext; then
27787 # Handle native Windows specially, because there setlocale() interprets
27788 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
27789 # "fr" or "fra" as "French" or "French_France.1252",
27790 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
27791 # "ja" as "Japanese" or "Japanese_Japan.932",
27794 # Test for the hypothetical native Windows locale name.
27795 if (LC_ALL=Chinese_China.54936 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27796 gt_cv_locale_zh_CN=Chinese_China.54936
27799 gt_cv_locale_zh_CN=none
27803 # On Solaris 8, the locales zh_CN.GB18030, zh_CN.GBK, zh.GBK are
27804 # broken. One witness is the test case in gl_MBRTOWC_SANITYCHECK.
27805 # Another witness is that "LC_ALL=zh_CN.GB18030 bash -c true" dumps core.
27806 gt_cv_locale_zh_CN=none
27809 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
27810 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
27811 # configure script would override the LC_ALL setting. Likewise for
27812 # LC_CTYPE, which is also set at the beginning of the configure script.
27813 # Test for the locale name without encoding suffix.
27814 if (LC_ALL=zh_CN LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27815 gt_cv_locale_zh_CN=zh_CN
27817 # Test for the locale name with explicit encoding suffix.
27818 if (LC_ALL=zh_CN.GB18030 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27819 gt_cv_locale_zh_CN=zh_CN.GB18030
27822 gt_cv_locale_zh_CN=none
27828 # If there was a link error, due to mblen(), the system is so old that
27829 # it certainly doesn't have a chinese locale.
27830 gt_cv_locale_zh_CN=none
27835 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_zh_CN" >&5
27836 printf "%s\n" "$gt_cv_locale_zh_CN" >&6; }
27837 LOCALE_ZH_CN=$gt_cv_locale_zh_CN
27843 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a turkish Unicode locale" >&5
27844 printf %s "checking for a turkish Unicode locale... " >&6; }
27845 if ${gt_cv_locale_tr_utf8+:} false; then :
27846 printf %s "(cached) " >&6
27849 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27850 /* end confdefs.h. */
27852 #include <locale.h>
27854 #if HAVE_LANGINFO_CODESET
27855 # include <langinfo.h>
27857 #include <stdlib.h>
27858 #include <string.h>
27862 /* On BeOS, locales are not implemented in libc. Rather, libintl
27863 imitates locale dependent behaviour by looking at the environment
27864 variables, and all locales use the UTF-8 encoding. But BeOS does not
27865 implement the Turkish upper-/lowercase mappings. Therefore, let this
27866 program return 1 on BeOS. */
27867 /* Check whether the given locale name is recognized by the system. */
27868 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
27869 /* On native Windows, setlocale(category, "") looks at the system settings,
27870 not at the environment variables. Also, when an encoding suffix such
27871 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
27872 category of the locale to "C". */
27873 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
27874 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
27877 if (setlocale (LC_ALL, "") == NULL) return 1;
27879 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
27880 On Mac OS X 10.3.5 (Darwin 7.5) in the tr_TR locale, nl_langinfo(CODESET)
27881 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
27882 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
27883 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
27884 some unit tests fail. */
27885 #if HAVE_LANGINFO_CODESET
27887 const char *cs = nl_langinfo (CODESET);
27888 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
27893 /* On Cygwin, avoid locale names without encoding suffix, because the
27894 locale_charset() function relies on the encoding suffix. Note that
27895 LC_ALL is set on the command line. */
27896 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
27898 /* Check whether in the abbreviation of the eighth month, the second
27899 character (should be U+011F: LATIN SMALL LETTER G WITH BREVE) is
27900 two bytes long, with UTF-8 encoding. */
27901 t.tm_year = 1992 - 1900; t.tm_mon = 8 - 1; t.tm_mday = 19;
27902 if (strftime (buf, sizeof (buf), "%b", &t) < 4
27903 || buf[1] != (char) 0xc4 || buf[2] != (char) 0x9f)
27905 /* Check whether the upper-/lowercase mappings are as expected for
27907 if (towupper ('i') != 0x0130 || towlower (0x0130) != 'i'
27908 || towupper(0x0131) != 'I' || towlower ('I') != 0x0131)
27914 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
27915 (eval $ac_link) 2>&5
27917 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
27918 test $ac_status = 0; } && test -s conftest$ac_exeext; then
27920 # Handle native Windows specially, because there setlocale() interprets
27921 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
27922 # "fr" or "fra" as "French" or "French_France.1252",
27923 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
27924 # "ja" as "Japanese" or "Japanese_Japan.932",
27927 # Test for the hypothetical native Windows locale name.
27928 if (LC_ALL=Turkish_Turkey.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27929 gt_cv_locale_tr_utf8=Turkish_Turkey.65001
27932 gt_cv_locale_tr_utf8=none
27936 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
27937 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
27938 # configure script would override the LC_ALL setting. Likewise for
27939 # LC_CTYPE, which is also set at the beginning of the configure script.
27940 # Test for the usual locale name.
27941 if (LC_ALL=tr_TR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27942 gt_cv_locale_tr_utf8=tr_TR
27944 # Test for the locale name with explicit encoding suffix.
27945 if (LC_ALL=tr_TR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27946 gt_cv_locale_tr_utf8=tr_TR.UTF-8
27948 # Test for the Solaris 7 locale name.
27949 if (LC_ALL=tr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
27950 gt_cv_locale_tr_utf8=tr.UTF-8
27953 gt_cv_locale_tr_utf8=none
27960 gt_cv_locale_tr_utf8=none
27965 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_tr_utf8" >&5
27966 printf "%s\n" "$gt_cv_locale_tr_utf8" >&6; }
27967 LOCALE_TR_UTF8=$gt_cv_locale_tr_utf8
27972 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
27973 printf %s "checking for a french Unicode locale... " >&6; }
27974 if ${gt_cv_locale_fr_utf8+:} false; then :
27975 printf %s "(cached) " >&6
27978 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27979 /* end confdefs.h. */
27981 #include <locale.h>
27983 #if HAVE_LANGINFO_CODESET
27984 # include <langinfo.h>
27986 #include <stdlib.h>
27987 #include <string.h>
27991 /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
27992 imitates locale dependent behaviour by looking at the environment
27993 variables, and all locales use the UTF-8 encoding. */
27994 #if !(defined __BEOS__ || defined __HAIKU__)
27995 /* Check whether the given locale name is recognized by the system. */
27996 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
27997 /* On native Windows, setlocale(category, "") looks at the system settings,
27998 not at the environment variables. Also, when an encoding suffix such
27999 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
28000 category of the locale to "C". */
28001 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
28002 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
28005 if (setlocale (LC_ALL, "") == NULL) return 1;
28007 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
28008 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
28009 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
28010 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
28011 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
28012 some unit tests fail. */
28013 # if HAVE_LANGINFO_CODESET
28015 const char *cs = nl_langinfo (CODESET);
28016 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
28021 /* On Cygwin, avoid locale names without encoding suffix, because the
28022 locale_charset() function relies on the encoding suffix. Note that
28023 LC_ALL is set on the command line. */
28024 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
28026 /* Check whether in the abbreviation of the second month, the second
28027 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
28028 two bytes long, with UTF-8 encoding. */
28029 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
28030 if (strftime (buf, sizeof (buf), "%b", &t) < 4
28031 || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
28034 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
28035 /* Check whether the decimal separator is a comma.
28036 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
28037 are nl_langinfo(RADIXCHAR) are both ".". */
28038 if (localeconv () ->decimal_point[0] != ',') return 1;
28044 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
28045 (eval $ac_link) 2>&5
28047 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28048 test $ac_status = 0; } && test -s conftest$ac_exeext; then
28050 # Handle native Windows specially, because there setlocale() interprets
28051 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
28052 # "fr" or "fra" as "French" or "French_France.1252",
28053 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
28054 # "ja" as "Japanese" or "Japanese_Japan.932",
28057 # Test for the hypothetical native Windows locale name.
28058 if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28059 gt_cv_locale_fr_utf8=French_France.65001
28062 gt_cv_locale_fr_utf8=none
28066 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
28067 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
28068 # configure script would override the LC_ALL setting. Likewise for
28069 # LC_CTYPE, which is also set at the beginning of the configure script.
28070 # Test for the usual locale name.
28071 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28072 gt_cv_locale_fr_utf8=fr_FR
28074 # Test for the locale name with explicit encoding suffix.
28075 if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28076 gt_cv_locale_fr_utf8=fr_FR.UTF-8
28078 # Test for the Solaris 7 locale name.
28079 if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28080 gt_cv_locale_fr_utf8=fr.UTF-8
28083 gt_cv_locale_fr_utf8=none
28093 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
28094 printf "%s\n" "$gt_cv_locale_fr_utf8" >&6; }
28095 LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
28101 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
28102 printf %s "checking for a traditional french locale... " >&6; }
28103 if ${gt_cv_locale_fr+:} false; then :
28104 printf %s "(cached) " >&6
28107 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28108 /* end confdefs.h. */
28110 #include <locale.h>
28112 #if HAVE_LANGINFO_CODESET
28113 # include <langinfo.h>
28115 #include <stdlib.h>
28116 #include <string.h>
28120 /* Check whether the given locale name is recognized by the system. */
28121 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
28122 /* On native Windows, setlocale(category, "") looks at the system settings,
28123 not at the environment variables. Also, when an encoding suffix such
28124 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
28125 category of the locale to "C". */
28126 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
28127 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
28130 if (setlocale (LC_ALL, "") == NULL) return 1;
28132 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
28133 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
28134 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
28135 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
28136 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
28137 some unit tests fail.
28138 On MirBSD 10, when an unsupported locale is specified, setlocale()
28139 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
28140 #if HAVE_LANGINFO_CODESET
28142 const char *cs = nl_langinfo (CODESET);
28143 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
28144 || strcmp (cs, "UTF-8") == 0)
28149 /* On Cygwin, avoid locale names without encoding suffix, because the
28150 locale_charset() function relies on the encoding suffix. Note that
28151 LC_ALL is set on the command line. */
28152 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
28154 /* Check whether in the abbreviation of the second month, the second
28155 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
28156 one byte long. This excludes the UTF-8 encoding. */
28157 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
28158 if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
28159 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
28160 /* Check whether the decimal separator is a comma.
28161 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
28162 are nl_langinfo(RADIXCHAR) are both ".". */
28163 if (localeconv () ->decimal_point[0] != ',') return 1;
28169 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
28170 (eval $ac_link) 2>&5
28172 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28173 test $ac_status = 0; } && test -s conftest$ac_exeext; then
28175 # Handle native Windows specially, because there setlocale() interprets
28176 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
28177 # "fr" or "fra" as "French" or "French_France.1252",
28178 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
28179 # "ja" as "Japanese" or "Japanese_Japan.932",
28182 # Test for the native Windows locale name.
28183 if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28184 gt_cv_locale_fr=French_France.1252
28187 gt_cv_locale_fr=none
28191 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
28192 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
28193 # configure script would override the LC_ALL setting. Likewise for
28194 # LC_CTYPE, which is also set at the beginning of the configure script.
28195 # Test for the usual locale name.
28196 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28197 gt_cv_locale_fr=fr_FR
28199 # Test for the locale name with explicit encoding suffix.
28200 if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28201 gt_cv_locale_fr=fr_FR.ISO-8859-1
28203 # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
28204 if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28205 gt_cv_locale_fr=fr_FR.ISO8859-1
28207 # Test for the HP-UX locale name.
28208 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28209 gt_cv_locale_fr=fr_FR.iso88591
28211 # Test for the Solaris 7 locale name.
28212 if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28216 gt_cv_locale_fr=none
28228 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
28229 printf "%s\n" "$gt_cv_locale_fr" >&6; }
28230 LOCALE_FR=$gt_cv_locale_fr
28235 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
28236 printf %s "checking for a french Unicode locale... " >&6; }
28237 if ${gt_cv_locale_fr_utf8+:} false; then :
28238 printf %s "(cached) " >&6
28241 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28242 /* end confdefs.h. */
28244 #include <locale.h>
28246 #if HAVE_LANGINFO_CODESET
28247 # include <langinfo.h>
28249 #include <stdlib.h>
28250 #include <string.h>
28254 /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
28255 imitates locale dependent behaviour by looking at the environment
28256 variables, and all locales use the UTF-8 encoding. */
28257 #if !(defined __BEOS__ || defined __HAIKU__)
28258 /* Check whether the given locale name is recognized by the system. */
28259 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
28260 /* On native Windows, setlocale(category, "") looks at the system settings,
28261 not at the environment variables. Also, when an encoding suffix such
28262 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
28263 category of the locale to "C". */
28264 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
28265 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
28268 if (setlocale (LC_ALL, "") == NULL) return 1;
28270 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
28271 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
28272 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
28273 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
28274 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
28275 some unit tests fail. */
28276 # if HAVE_LANGINFO_CODESET
28278 const char *cs = nl_langinfo (CODESET);
28279 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
28284 /* On Cygwin, avoid locale names without encoding suffix, because the
28285 locale_charset() function relies on the encoding suffix. Note that
28286 LC_ALL is set on the command line. */
28287 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
28289 /* Check whether in the abbreviation of the second month, the second
28290 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
28291 two bytes long, with UTF-8 encoding. */
28292 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
28293 if (strftime (buf, sizeof (buf), "%b", &t) < 4
28294 || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
28297 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
28298 /* Check whether the decimal separator is a comma.
28299 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
28300 are nl_langinfo(RADIXCHAR) are both ".". */
28301 if (localeconv () ->decimal_point[0] != ',') return 1;
28307 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
28308 (eval $ac_link) 2>&5
28310 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28311 test $ac_status = 0; } && test -s conftest$ac_exeext; then
28313 # Handle native Windows specially, because there setlocale() interprets
28314 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
28315 # "fr" or "fra" as "French" or "French_France.1252",
28316 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
28317 # "ja" as "Japanese" or "Japanese_Japan.932",
28320 # Test for the hypothetical native Windows locale name.
28321 if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28322 gt_cv_locale_fr_utf8=French_France.65001
28325 gt_cv_locale_fr_utf8=none
28329 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
28330 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
28331 # configure script would override the LC_ALL setting. Likewise for
28332 # LC_CTYPE, which is also set at the beginning of the configure script.
28333 # Test for the usual locale name.
28334 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28335 gt_cv_locale_fr_utf8=fr_FR
28337 # Test for the locale name with explicit encoding suffix.
28338 if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28339 gt_cv_locale_fr_utf8=fr_FR.UTF-8
28341 # Test for the Solaris 7 locale name.
28342 if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28343 gt_cv_locale_fr_utf8=fr.UTF-8
28346 gt_cv_locale_fr_utf8=none
28356 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
28357 printf "%s\n" "$gt_cv_locale_fr_utf8" >&6; }
28358 LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
28364 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a traditional japanese locale" >&5
28365 printf %s "checking for a traditional japanese locale... " >&6; }
28366 if ${gt_cv_locale_ja+:} false; then :
28367 printf %s "(cached) " >&6
28370 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28371 /* end confdefs.h. */
28373 #include <locale.h>
28375 #if HAVE_LANGINFO_CODESET
28376 # include <langinfo.h>
28378 #include <stdlib.h>
28379 #include <string.h>
28385 /* Check whether the given locale name is recognized by the system. */
28386 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
28387 /* On native Windows, setlocale(category, "") looks at the system settings,
28388 not at the environment variables. Also, when an encoding suffix such
28389 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
28390 category of the locale to "C". */
28391 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
28392 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
28395 if (setlocale (LC_ALL, "") == NULL) return 1;
28397 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
28398 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
28399 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
28400 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
28401 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
28402 some unit tests fail.
28403 On MirBSD 10, when an unsupported locale is specified, setlocale()
28404 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
28405 #if HAVE_LANGINFO_CODESET
28407 const char *cs = nl_langinfo (CODESET);
28408 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
28409 || strcmp (cs, "UTF-8") == 0)
28414 /* On Cygwin, avoid locale names without encoding suffix, because the
28415 locale_charset() function relies on the encoding suffix. Note that
28416 LC_ALL is set on the command line. */
28417 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
28419 /* Check whether MB_CUR_MAX is > 1. This excludes the dysfunctional locales
28420 on Cygwin 1.5.x. */
28421 if (MB_CUR_MAX == 1)
28423 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
28424 This excludes the UTF-8 encoding (except on MirBSD). */
28425 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
28426 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
28427 for (p = buf; *p != '\0'; p++)
28428 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
28434 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
28435 (eval $ac_link) 2>&5
28437 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28438 test $ac_status = 0; } && test -s conftest$ac_exeext; then
28440 # Handle native Windows specially, because there setlocale() interprets
28441 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
28442 # "fr" or "fra" as "French" or "French_France.1252",
28443 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
28444 # "ja" as "Japanese" or "Japanese_Japan.932",
28447 # Note that on native Windows, the Japanese locale is
28448 # Japanese_Japan.932, and CP932 is very different from EUC-JP, so we
28449 # cannot use it here.
28450 gt_cv_locale_ja=none
28453 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
28454 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
28455 # configure script would override the LC_ALL setting. Likewise for
28456 # LC_CTYPE, which is also set at the beginning of the configure script.
28457 # Test for the AIX locale name.
28458 if (LC_ALL=ja_JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28459 gt_cv_locale_ja=ja_JP
28461 # Test for the locale name with explicit encoding suffix.
28462 if (LC_ALL=ja_JP.EUC-JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28463 gt_cv_locale_ja=ja_JP.EUC-JP
28465 # Test for the HP-UX, OSF/1, NetBSD locale name.
28466 if (LC_ALL=ja_JP.eucJP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28467 gt_cv_locale_ja=ja_JP.eucJP
28469 # Test for the IRIX, FreeBSD locale name.
28470 if (LC_ALL=ja_JP.EUC LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28471 gt_cv_locale_ja=ja_JP.EUC
28473 # Test for the Solaris 7 locale name.
28474 if (LC_ALL=ja LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28477 # Special test for NetBSD 1.6.
28478 if test -f /usr/share/locale/ja_JP.eucJP/LC_CTYPE; then
28479 gt_cv_locale_ja=ja_JP.eucJP
28482 gt_cv_locale_ja=none
28495 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_ja" >&5
28496 printf "%s\n" "$gt_cv_locale_ja" >&6; }
28497 LOCALE_JA=$gt_cv_locale_ja
28503 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a transitional chinese locale" >&5
28504 printf %s "checking for a transitional chinese locale... " >&6; }
28505 if ${gt_cv_locale_zh_CN+:} false; then :
28506 printf %s "(cached) " >&6
28509 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28510 /* end confdefs.h. */
28512 #include <locale.h>
28513 #include <stdlib.h>
28515 #if HAVE_LANGINFO_CODESET
28516 # include <langinfo.h>
28518 #include <stdlib.h>
28519 #include <string.h>
28525 /* Check whether the given locale name is recognized by the system. */
28526 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
28527 /* On native Windows, setlocale(category, "") looks at the system settings,
28528 not at the environment variables. Also, when an encoding suffix such
28529 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
28530 category of the locale to "C". */
28531 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
28532 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
28535 if (setlocale (LC_ALL, "") == NULL) return 1;
28537 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
28538 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
28539 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
28540 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
28541 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
28542 some unit tests fail.
28543 On MirBSD 10, when an unsupported locale is specified, setlocale()
28544 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
28545 #if HAVE_LANGINFO_CODESET
28547 const char *cs = nl_langinfo (CODESET);
28548 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
28549 || strcmp (cs, "UTF-8") == 0)
28554 /* On Cygwin, avoid locale names without encoding suffix, because the
28555 locale_charset() function relies on the encoding suffix. Note that
28556 LC_ALL is set on the command line. */
28557 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
28559 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
28560 This excludes the UTF-8 encoding (except on MirBSD). */
28561 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
28562 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
28563 for (p = buf; *p != '\0'; p++)
28564 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
28566 /* Check whether a typical GB18030 multibyte sequence is recognized as a
28567 single wide character. This excludes the GB2312 and GBK encodings. */
28568 if (mblen ("\203\062\332\066", 5) != 4)
28574 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
28575 (eval $ac_link) 2>&5
28577 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28578 test $ac_status = 0; } && test -s conftest$ac_exeext; then
28580 # Handle native Windows specially, because there setlocale() interprets
28581 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
28582 # "fr" or "fra" as "French" or "French_France.1252",
28583 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
28584 # "ja" as "Japanese" or "Japanese_Japan.932",
28587 # Test for the hypothetical native Windows locale name.
28588 if (LC_ALL=Chinese_China.54936 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28589 gt_cv_locale_zh_CN=Chinese_China.54936
28592 gt_cv_locale_zh_CN=none
28596 # On Solaris 8, the locales zh_CN.GB18030, zh_CN.GBK, zh.GBK are
28597 # broken. One witness is the test case in gl_MBRTOWC_SANITYCHECK.
28598 # Another witness is that "LC_ALL=zh_CN.GB18030 bash -c true" dumps core.
28599 gt_cv_locale_zh_CN=none
28602 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
28603 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
28604 # configure script would override the LC_ALL setting. Likewise for
28605 # LC_CTYPE, which is also set at the beginning of the configure script.
28606 # Test for the locale name without encoding suffix.
28607 if (LC_ALL=zh_CN LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28608 gt_cv_locale_zh_CN=zh_CN
28610 # Test for the locale name with explicit encoding suffix.
28611 if (LC_ALL=zh_CN.GB18030 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28612 gt_cv_locale_zh_CN=zh_CN.GB18030
28615 gt_cv_locale_zh_CN=none
28621 # If there was a link error, due to mblen(), the system is so old that
28622 # it certainly doesn't have a chinese locale.
28623 gt_cv_locale_zh_CN=none
28628 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_zh_CN" >&5
28629 printf "%s\n" "$gt_cv_locale_zh_CN" >&6; }
28630 LOCALE_ZH_CN=$gt_cv_locale_zh_CN
28635 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
28636 printf %s "checking for a french Unicode locale... " >&6; }
28637 if ${gt_cv_locale_fr_utf8+:} false; then :
28638 printf %s "(cached) " >&6
28641 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28642 /* end confdefs.h. */
28644 #include <locale.h>
28646 #if HAVE_LANGINFO_CODESET
28647 # include <langinfo.h>
28649 #include <stdlib.h>
28650 #include <string.h>
28654 /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
28655 imitates locale dependent behaviour by looking at the environment
28656 variables, and all locales use the UTF-8 encoding. */
28657 #if !(defined __BEOS__ || defined __HAIKU__)
28658 /* Check whether the given locale name is recognized by the system. */
28659 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
28660 /* On native Windows, setlocale(category, "") looks at the system settings,
28661 not at the environment variables. Also, when an encoding suffix such
28662 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
28663 category of the locale to "C". */
28664 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
28665 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
28668 if (setlocale (LC_ALL, "") == NULL) return 1;
28670 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
28671 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
28672 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
28673 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
28674 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
28675 some unit tests fail. */
28676 # if HAVE_LANGINFO_CODESET
28678 const char *cs = nl_langinfo (CODESET);
28679 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
28684 /* On Cygwin, avoid locale names without encoding suffix, because the
28685 locale_charset() function relies on the encoding suffix. Note that
28686 LC_ALL is set on the command line. */
28687 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
28689 /* Check whether in the abbreviation of the second month, the second
28690 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
28691 two bytes long, with UTF-8 encoding. */
28692 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
28693 if (strftime (buf, sizeof (buf), "%b", &t) < 4
28694 || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
28697 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
28698 /* Check whether the decimal separator is a comma.
28699 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
28700 are nl_langinfo(RADIXCHAR) are both ".". */
28701 if (localeconv () ->decimal_point[0] != ',') return 1;
28707 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
28708 (eval $ac_link) 2>&5
28710 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28711 test $ac_status = 0; } && test -s conftest$ac_exeext; then
28713 # Handle native Windows specially, because there setlocale() interprets
28714 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
28715 # "fr" or "fra" as "French" or "French_France.1252",
28716 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
28717 # "ja" as "Japanese" or "Japanese_Japan.932",
28720 # Test for the hypothetical native Windows locale name.
28721 if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28722 gt_cv_locale_fr_utf8=French_France.65001
28725 gt_cv_locale_fr_utf8=none
28729 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
28730 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
28731 # configure script would override the LC_ALL setting. Likewise for
28732 # LC_CTYPE, which is also set at the beginning of the configure script.
28733 # Test for the usual locale name.
28734 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28735 gt_cv_locale_fr_utf8=fr_FR
28737 # Test for the locale name with explicit encoding suffix.
28738 if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28739 gt_cv_locale_fr_utf8=fr_FR.UTF-8
28741 # Test for the Solaris 7 locale name.
28742 if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28743 gt_cv_locale_fr_utf8=fr.UTF-8
28746 gt_cv_locale_fr_utf8=none
28756 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
28757 printf "%s\n" "$gt_cv_locale_fr_utf8" >&6; }
28758 LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
28764 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a transitional chinese locale" >&5
28765 printf %s "checking for a transitional chinese locale... " >&6; }
28766 if ${gt_cv_locale_zh_CN+:} false; then :
28767 printf %s "(cached) " >&6
28770 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28771 /* end confdefs.h. */
28773 #include <locale.h>
28774 #include <stdlib.h>
28776 #if HAVE_LANGINFO_CODESET
28777 # include <langinfo.h>
28779 #include <stdlib.h>
28780 #include <string.h>
28786 /* Check whether the given locale name is recognized by the system. */
28787 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
28788 /* On native Windows, setlocale(category, "") looks at the system settings,
28789 not at the environment variables. Also, when an encoding suffix such
28790 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
28791 category of the locale to "C". */
28792 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
28793 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
28796 if (setlocale (LC_ALL, "") == NULL) return 1;
28798 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
28799 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
28800 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
28801 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
28802 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
28803 some unit tests fail.
28804 On MirBSD 10, when an unsupported locale is specified, setlocale()
28805 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
28806 #if HAVE_LANGINFO_CODESET
28808 const char *cs = nl_langinfo (CODESET);
28809 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
28810 || strcmp (cs, "UTF-8") == 0)
28815 /* On Cygwin, avoid locale names without encoding suffix, because the
28816 locale_charset() function relies on the encoding suffix. Note that
28817 LC_ALL is set on the command line. */
28818 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
28820 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
28821 This excludes the UTF-8 encoding (except on MirBSD). */
28822 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
28823 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
28824 for (p = buf; *p != '\0'; p++)
28825 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
28827 /* Check whether a typical GB18030 multibyte sequence is recognized as a
28828 single wide character. This excludes the GB2312 and GBK encodings. */
28829 if (mblen ("\203\062\332\066", 5) != 4)
28835 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
28836 (eval $ac_link) 2>&5
28838 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28839 test $ac_status = 0; } && test -s conftest$ac_exeext; then
28841 # Handle native Windows specially, because there setlocale() interprets
28842 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
28843 # "fr" or "fra" as "French" or "French_France.1252",
28844 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
28845 # "ja" as "Japanese" or "Japanese_Japan.932",
28848 # Test for the hypothetical native Windows locale name.
28849 if (LC_ALL=Chinese_China.54936 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28850 gt_cv_locale_zh_CN=Chinese_China.54936
28853 gt_cv_locale_zh_CN=none
28857 # On Solaris 8, the locales zh_CN.GB18030, zh_CN.GBK, zh.GBK are
28858 # broken. One witness is the test case in gl_MBRTOWC_SANITYCHECK.
28859 # Another witness is that "LC_ALL=zh_CN.GB18030 bash -c true" dumps core.
28860 gt_cv_locale_zh_CN=none
28863 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
28864 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
28865 # configure script would override the LC_ALL setting. Likewise for
28866 # LC_CTYPE, which is also set at the beginning of the configure script.
28867 # Test for the locale name without encoding suffix.
28868 if (LC_ALL=zh_CN LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28869 gt_cv_locale_zh_CN=zh_CN
28871 # Test for the locale name with explicit encoding suffix.
28872 if (LC_ALL=zh_CN.GB18030 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
28873 gt_cv_locale_zh_CN=zh_CN.GB18030
28876 gt_cv_locale_zh_CN=none
28882 # If there was a link error, due to mblen(), the system is so old that
28883 # it certainly doesn't have a chinese locale.
28884 gt_cv_locale_zh_CN=none
28889 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_zh_CN" >&5
28890 printf "%s\n" "$gt_cv_locale_zh_CN" >&6; }
28891 LOCALE_ZH_CN=$gt_cv_locale_zh_CN
28897 # Check for mmap(). Don't use AC_FUNC_MMAP, because it checks too much: it
28898 # fails on HP-UX 11, because MAP_FIXED mappings do not work. But this is
28899 # irrelevant for anonymous mappings.
28900 ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap"
28901 if test "x$ac_cv_func_mmap" = xyes; then :
28908 # Try to allow MAP_ANONYMOUS.
28909 gl_have_mmap_anonymous=no
28910 if test $gl_have_mmap = yes; then
28911 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for MAP_ANONYMOUS" >&5
28912 printf %s "checking for MAP_ANONYMOUS... " >&6; }
28913 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28914 /* end confdefs.h. */
28916 #include <sys/mman.h>
28917 #ifdef MAP_ANONYMOUS
28918 I cannot identify this map
28922 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28923 $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
28924 gl_have_mmap_anonymous=yes
28928 if test $gl_have_mmap_anonymous != yes; then
28929 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28930 /* end confdefs.h. */
28932 #include <sys/mman.h>
28934 I cannot identify this map
28938 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28939 $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
28941 printf "%s\n" "#define MAP_ANONYMOUS MAP_ANON" >>confdefs.h
28943 gl_have_mmap_anonymous=yes
28948 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_have_mmap_anonymous" >&5
28949 printf "%s\n" "$gl_have_mmap_anonymous" >&6; }
28950 if test $gl_have_mmap_anonymous = yes; then
28952 printf "%s\n" "#define HAVE_MAP_ANONYMOUS 1" >>confdefs.h
28962 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
28963 printf %s "checking for a traditional french locale... " >&6; }
28964 if ${gt_cv_locale_fr+:} false; then :
28965 printf %s "(cached) " >&6
28968 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28969 /* end confdefs.h. */
28971 #include <locale.h>
28973 #if HAVE_LANGINFO_CODESET
28974 # include <langinfo.h>
28976 #include <stdlib.h>
28977 #include <string.h>
28981 /* Check whether the given locale name is recognized by the system. */
28982 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
28983 /* On native Windows, setlocale(category, "") looks at the system settings,
28984 not at the environment variables. Also, when an encoding suffix such
28985 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
28986 category of the locale to "C". */
28987 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
28988 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
28991 if (setlocale (LC_ALL, "") == NULL) return 1;
28993 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
28994 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
28995 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
28996 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
28997 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
28998 some unit tests fail.
28999 On MirBSD 10, when an unsupported locale is specified, setlocale()
29000 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
29001 #if HAVE_LANGINFO_CODESET
29003 const char *cs = nl_langinfo (CODESET);
29004 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
29005 || strcmp (cs, "UTF-8") == 0)
29010 /* On Cygwin, avoid locale names without encoding suffix, because the
29011 locale_charset() function relies on the encoding suffix. Note that
29012 LC_ALL is set on the command line. */
29013 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
29015 /* Check whether in the abbreviation of the second month, the second
29016 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
29017 one byte long. This excludes the UTF-8 encoding. */
29018 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
29019 if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
29020 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
29021 /* Check whether the decimal separator is a comma.
29022 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
29023 are nl_langinfo(RADIXCHAR) are both ".". */
29024 if (localeconv () ->decimal_point[0] != ',') return 1;
29030 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
29031 (eval $ac_link) 2>&5
29033 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
29034 test $ac_status = 0; } && test -s conftest$ac_exeext; then
29036 # Handle native Windows specially, because there setlocale() interprets
29037 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
29038 # "fr" or "fra" as "French" or "French_France.1252",
29039 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
29040 # "ja" as "Japanese" or "Japanese_Japan.932",
29043 # Test for the native Windows locale name.
29044 if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29045 gt_cv_locale_fr=French_France.1252
29048 gt_cv_locale_fr=none
29052 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
29053 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
29054 # configure script would override the LC_ALL setting. Likewise for
29055 # LC_CTYPE, which is also set at the beginning of the configure script.
29056 # Test for the usual locale name.
29057 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29058 gt_cv_locale_fr=fr_FR
29060 # Test for the locale name with explicit encoding suffix.
29061 if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29062 gt_cv_locale_fr=fr_FR.ISO-8859-1
29064 # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
29065 if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29066 gt_cv_locale_fr=fr_FR.ISO8859-1
29068 # Test for the HP-UX locale name.
29069 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29070 gt_cv_locale_fr=fr_FR.iso88591
29072 # Test for the Solaris 7 locale name.
29073 if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29077 gt_cv_locale_fr=none
29089 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
29090 printf "%s\n" "$gt_cv_locale_fr" >&6; }
29091 LOCALE_FR=$gt_cv_locale_fr
29096 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
29097 printf %s "checking for a french Unicode locale... " >&6; }
29098 if ${gt_cv_locale_fr_utf8+:} false; then :
29099 printf %s "(cached) " >&6
29102 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29103 /* end confdefs.h. */
29105 #include <locale.h>
29107 #if HAVE_LANGINFO_CODESET
29108 # include <langinfo.h>
29110 #include <stdlib.h>
29111 #include <string.h>
29115 /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
29116 imitates locale dependent behaviour by looking at the environment
29117 variables, and all locales use the UTF-8 encoding. */
29118 #if !(defined __BEOS__ || defined __HAIKU__)
29119 /* Check whether the given locale name is recognized by the system. */
29120 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
29121 /* On native Windows, setlocale(category, "") looks at the system settings,
29122 not at the environment variables. Also, when an encoding suffix such
29123 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
29124 category of the locale to "C". */
29125 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
29126 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
29129 if (setlocale (LC_ALL, "") == NULL) return 1;
29131 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
29132 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
29133 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
29134 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
29135 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
29136 some unit tests fail. */
29137 # if HAVE_LANGINFO_CODESET
29139 const char *cs = nl_langinfo (CODESET);
29140 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
29145 /* On Cygwin, avoid locale names without encoding suffix, because the
29146 locale_charset() function relies on the encoding suffix. Note that
29147 LC_ALL is set on the command line. */
29148 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
29150 /* Check whether in the abbreviation of the second month, the second
29151 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
29152 two bytes long, with UTF-8 encoding. */
29153 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
29154 if (strftime (buf, sizeof (buf), "%b", &t) < 4
29155 || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
29158 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
29159 /* Check whether the decimal separator is a comma.
29160 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
29161 are nl_langinfo(RADIXCHAR) are both ".". */
29162 if (localeconv () ->decimal_point[0] != ',') return 1;
29168 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
29169 (eval $ac_link) 2>&5
29171 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
29172 test $ac_status = 0; } && test -s conftest$ac_exeext; then
29174 # Handle native Windows specially, because there setlocale() interprets
29175 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
29176 # "fr" or "fra" as "French" or "French_France.1252",
29177 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
29178 # "ja" as "Japanese" or "Japanese_Japan.932",
29181 # Test for the hypothetical native Windows locale name.
29182 if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29183 gt_cv_locale_fr_utf8=French_France.65001
29186 gt_cv_locale_fr_utf8=none
29190 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
29191 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
29192 # configure script would override the LC_ALL setting. Likewise for
29193 # LC_CTYPE, which is also set at the beginning of the configure script.
29194 # Test for the usual locale name.
29195 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29196 gt_cv_locale_fr_utf8=fr_FR
29198 # Test for the locale name with explicit encoding suffix.
29199 if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29200 gt_cv_locale_fr_utf8=fr_FR.UTF-8
29202 # Test for the Solaris 7 locale name.
29203 if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29204 gt_cv_locale_fr_utf8=fr.UTF-8
29207 gt_cv_locale_fr_utf8=none
29217 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
29218 printf "%s\n" "$gt_cv_locale_fr_utf8" >&6; }
29219 LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
29224 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for putenv compatible with GNU and SVID" >&5
29225 printf %s "checking for putenv compatible with GNU and SVID... " >&6; }
29226 if ${gl_cv_func_svid_putenv+:} false; then :
29227 printf %s "(cached) " >&6
29229 if test "$cross_compiling" = yes; then :
29231 # Guess yes on glibc systems.
29232 *-gnu*) gl_cv_func_svid_putenv="guessing yes" ;;
29233 # If we don't know, assume the worst.
29234 *) gl_cv_func_svid_putenv="guessing no" ;;
29238 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29239 /* end confdefs.h. */
29240 $ac_includes_default
29245 /* Put it in env. */
29246 if (putenv ("CONFTEST_putenv=val"))
29249 /* Try to remove it. */
29250 if (putenv ("CONFTEST_putenv"))
29253 /* Make sure it was deleted. */
29254 if (getenv ("CONFTEST_putenv") != 0)
29263 if ac_fn_c_try_run "$LINENO"; then :
29264 gl_cv_func_svid_putenv=yes
29266 gl_cv_func_svid_putenv=no
29268 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
29269 conftest.$ac_objext conftest.beam conftest.$ac_ext
29274 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_svid_putenv" >&5
29275 printf "%s\n" "$gl_cv_func_svid_putenv" >&6; }
29276 case "$gl_cv_func_svid_putenv" in
29283 if test $REPLACE_PUTENV = 1; then
29292 gltests_LIBOBJS="$gltests_LIBOBJS putenv.$ac_objext"
29295 ac_fn_c_check_decl "$LINENO" "_putenv" "ac_cv_have_decl__putenv" "$ac_includes_default"
29296 if test "x$ac_cv_have_decl__putenv" = xyes; then :
29302 cat >>confdefs.h <<_ACEOF
29303 #define HAVE_DECL__PUTENV $ac_have_decl
29313 if test "$GNULIB_PUTENV" != 1; then
29314 if test "$GNULIB_PUTENV" = 0; then
29315 GNULIB_PUTENV=$gl_module_indicator_condition
29317 GNULIB_PUTENV="($GNULIB_PUTENV || $gl_module_indicator_condition)"
29325 printf "%s\n" "#define GNULIB_TEST_PUTENV 1" >>confdefs.h
29331 if test $ac_cv_func_setenv = no; then
29334 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether setenv validates arguments" >&5
29335 printf %s "checking whether setenv validates arguments... " >&6; }
29336 if ${gl_cv_func_setenv_works+:} false; then :
29337 printf %s "(cached) " >&6
29339 if test "$cross_compiling" = yes; then :
29341 # Guess yes on glibc systems.
29342 *-gnu*) gl_cv_func_setenv_works="guessing yes" ;;
29343 # If we don't know, assume the worst.
29344 *) gl_cv_func_setenv_works="guessing no" ;;
29348 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29349 /* end confdefs.h. */
29351 #include <stdlib.h>
29353 #include <string.h>
29361 if (setenv ("", "", 0) != -1)
29363 else if (errno != EINVAL)
29367 if (setenv ("a", "=", 1) != 0)
29369 else if (strcmp (getenv ("a"), "=") != 0)
29378 if ac_fn_c_try_run "$LINENO"; then :
29379 gl_cv_func_setenv_works=yes
29381 gl_cv_func_setenv_works=no
29383 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
29384 conftest.$ac_objext conftest.beam conftest.$ac_ext
29388 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_setenv_works" >&5
29389 printf "%s\n" "$gl_cv_func_setenv_works" >&6; }
29390 case "$gl_cv_func_setenv_works" in
29398 if test $HAVE_SETENV = 0 || test $REPLACE_SETENV = 1; then
29407 gltests_LIBOBJS="$gltests_LIBOBJS setenv.$ac_objext"
29415 if test "$GNULIB_SETENV" != 1; then
29416 if test "$GNULIB_SETENV" = 0; then
29417 GNULIB_SETENV=$gl_module_indicator_condition
29419 GNULIB_SETENV="($GNULIB_SETENV || $gl_module_indicator_condition)"
29427 printf "%s\n" "#define GNULIB_TEST_SETENV 1" >>confdefs.h
29435 mingw*) REPLACE_SETLOCALE=1 ;;
29438 1.5.*) REPLACE_SETLOCALE=1 ;;
29443 if test $REPLACE_SETLOCALE = 1; then
29452 gltests_LIBOBJS="$gltests_LIBOBJS setlocale.$ac_objext"
29463 if test "$GNULIB_SETLOCALE" != 1; then
29464 if test "$GNULIB_SETLOCALE" = 0; then
29465 GNULIB_SETLOCALE=$gl_module_indicator_condition
29467 GNULIB_SETLOCALE="($GNULIB_SETLOCALE || $gl_module_indicator_condition)"
29475 printf "%s\n" "#define GNULIB_TEST_SETLOCALE 1" >>confdefs.h
29482 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
29483 printf %s "checking for a traditional french locale... " >&6; }
29484 if ${gt_cv_locale_fr+:} false; then :
29485 printf %s "(cached) " >&6
29488 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29489 /* end confdefs.h. */
29491 #include <locale.h>
29493 #if HAVE_LANGINFO_CODESET
29494 # include <langinfo.h>
29496 #include <stdlib.h>
29497 #include <string.h>
29501 /* Check whether the given locale name is recognized by the system. */
29502 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
29503 /* On native Windows, setlocale(category, "") looks at the system settings,
29504 not at the environment variables. Also, when an encoding suffix such
29505 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
29506 category of the locale to "C". */
29507 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
29508 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
29511 if (setlocale (LC_ALL, "") == NULL) return 1;
29513 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
29514 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
29515 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
29516 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
29517 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
29518 some unit tests fail.
29519 On MirBSD 10, when an unsupported locale is specified, setlocale()
29520 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
29521 #if HAVE_LANGINFO_CODESET
29523 const char *cs = nl_langinfo (CODESET);
29524 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
29525 || strcmp (cs, "UTF-8") == 0)
29530 /* On Cygwin, avoid locale names without encoding suffix, because the
29531 locale_charset() function relies on the encoding suffix. Note that
29532 LC_ALL is set on the command line. */
29533 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
29535 /* Check whether in the abbreviation of the second month, the second
29536 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
29537 one byte long. This excludes the UTF-8 encoding. */
29538 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
29539 if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
29540 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
29541 /* Check whether the decimal separator is a comma.
29542 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
29543 are nl_langinfo(RADIXCHAR) are both ".". */
29544 if (localeconv () ->decimal_point[0] != ',') return 1;
29550 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
29551 (eval $ac_link) 2>&5
29553 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
29554 test $ac_status = 0; } && test -s conftest$ac_exeext; then
29556 # Handle native Windows specially, because there setlocale() interprets
29557 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
29558 # "fr" or "fra" as "French" or "French_France.1252",
29559 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
29560 # "ja" as "Japanese" or "Japanese_Japan.932",
29563 # Test for the native Windows locale name.
29564 if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29565 gt_cv_locale_fr=French_France.1252
29568 gt_cv_locale_fr=none
29572 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
29573 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
29574 # configure script would override the LC_ALL setting. Likewise for
29575 # LC_CTYPE, which is also set at the beginning of the configure script.
29576 # Test for the usual locale name.
29577 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29578 gt_cv_locale_fr=fr_FR
29580 # Test for the locale name with explicit encoding suffix.
29581 if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29582 gt_cv_locale_fr=fr_FR.ISO-8859-1
29584 # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
29585 if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29586 gt_cv_locale_fr=fr_FR.ISO8859-1
29588 # Test for the HP-UX locale name.
29589 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29590 gt_cv_locale_fr=fr_FR.iso88591
29592 # Test for the Solaris 7 locale name.
29593 if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29597 gt_cv_locale_fr=none
29609 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
29610 printf "%s\n" "$gt_cv_locale_fr" >&6; }
29611 LOCALE_FR=$gt_cv_locale_fr
29616 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
29617 printf %s "checking for a french Unicode locale... " >&6; }
29618 if ${gt_cv_locale_fr_utf8+:} false; then :
29619 printf %s "(cached) " >&6
29622 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29623 /* end confdefs.h. */
29625 #include <locale.h>
29627 #if HAVE_LANGINFO_CODESET
29628 # include <langinfo.h>
29630 #include <stdlib.h>
29631 #include <string.h>
29635 /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
29636 imitates locale dependent behaviour by looking at the environment
29637 variables, and all locales use the UTF-8 encoding. */
29638 #if !(defined __BEOS__ || defined __HAIKU__)
29639 /* Check whether the given locale name is recognized by the system. */
29640 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
29641 /* On native Windows, setlocale(category, "") looks at the system settings,
29642 not at the environment variables. Also, when an encoding suffix such
29643 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
29644 category of the locale to "C". */
29645 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
29646 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
29649 if (setlocale (LC_ALL, "") == NULL) return 1;
29651 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
29652 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
29653 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
29654 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
29655 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
29656 some unit tests fail. */
29657 # if HAVE_LANGINFO_CODESET
29659 const char *cs = nl_langinfo (CODESET);
29660 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
29665 /* On Cygwin, avoid locale names without encoding suffix, because the
29666 locale_charset() function relies on the encoding suffix. Note that
29667 LC_ALL is set on the command line. */
29668 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
29670 /* Check whether in the abbreviation of the second month, the second
29671 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
29672 two bytes long, with UTF-8 encoding. */
29673 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
29674 if (strftime (buf, sizeof (buf), "%b", &t) < 4
29675 || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
29678 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
29679 /* Check whether the decimal separator is a comma.
29680 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
29681 are nl_langinfo(RADIXCHAR) are both ".". */
29682 if (localeconv () ->decimal_point[0] != ',') return 1;
29688 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
29689 (eval $ac_link) 2>&5
29691 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
29692 test $ac_status = 0; } && test -s conftest$ac_exeext; then
29694 # Handle native Windows specially, because there setlocale() interprets
29695 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
29696 # "fr" or "fra" as "French" or "French_France.1252",
29697 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
29698 # "ja" as "Japanese" or "Japanese_Japan.932",
29701 # Test for the hypothetical native Windows locale name.
29702 if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29703 gt_cv_locale_fr_utf8=French_France.65001
29706 gt_cv_locale_fr_utf8=none
29710 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
29711 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
29712 # configure script would override the LC_ALL setting. Likewise for
29713 # LC_CTYPE, which is also set at the beginning of the configure script.
29714 # Test for the usual locale name.
29715 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29716 gt_cv_locale_fr_utf8=fr_FR
29718 # Test for the locale name with explicit encoding suffix.
29719 if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29720 gt_cv_locale_fr_utf8=fr_FR.UTF-8
29722 # Test for the Solaris 7 locale name.
29723 if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29724 gt_cv_locale_fr_utf8=fr.UTF-8
29727 gt_cv_locale_fr_utf8=none
29737 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
29738 printf "%s\n" "$gt_cv_locale_fr_utf8" >&6; }
29739 LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
29745 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a traditional japanese locale" >&5
29746 printf %s "checking for a traditional japanese locale... " >&6; }
29747 if ${gt_cv_locale_ja+:} false; then :
29748 printf %s "(cached) " >&6
29751 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29752 /* end confdefs.h. */
29754 #include <locale.h>
29756 #if HAVE_LANGINFO_CODESET
29757 # include <langinfo.h>
29759 #include <stdlib.h>
29760 #include <string.h>
29766 /* Check whether the given locale name is recognized by the system. */
29767 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
29768 /* On native Windows, setlocale(category, "") looks at the system settings,
29769 not at the environment variables. Also, when an encoding suffix such
29770 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
29771 category of the locale to "C". */
29772 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
29773 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
29776 if (setlocale (LC_ALL, "") == NULL) return 1;
29778 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
29779 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
29780 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
29781 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
29782 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
29783 some unit tests fail.
29784 On MirBSD 10, when an unsupported locale is specified, setlocale()
29785 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
29786 #if HAVE_LANGINFO_CODESET
29788 const char *cs = nl_langinfo (CODESET);
29789 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
29790 || strcmp (cs, "UTF-8") == 0)
29795 /* On Cygwin, avoid locale names without encoding suffix, because the
29796 locale_charset() function relies on the encoding suffix. Note that
29797 LC_ALL is set on the command line. */
29798 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
29800 /* Check whether MB_CUR_MAX is > 1. This excludes the dysfunctional locales
29801 on Cygwin 1.5.x. */
29802 if (MB_CUR_MAX == 1)
29804 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
29805 This excludes the UTF-8 encoding (except on MirBSD). */
29806 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
29807 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
29808 for (p = buf; *p != '\0'; p++)
29809 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
29815 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
29816 (eval $ac_link) 2>&5
29818 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
29819 test $ac_status = 0; } && test -s conftest$ac_exeext; then
29821 # Handle native Windows specially, because there setlocale() interprets
29822 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
29823 # "fr" or "fra" as "French" or "French_France.1252",
29824 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
29825 # "ja" as "Japanese" or "Japanese_Japan.932",
29828 # Note that on native Windows, the Japanese locale is
29829 # Japanese_Japan.932, and CP932 is very different from EUC-JP, so we
29830 # cannot use it here.
29831 gt_cv_locale_ja=none
29834 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
29835 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
29836 # configure script would override the LC_ALL setting. Likewise for
29837 # LC_CTYPE, which is also set at the beginning of the configure script.
29838 # Test for the AIX locale name.
29839 if (LC_ALL=ja_JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29840 gt_cv_locale_ja=ja_JP
29842 # Test for the locale name with explicit encoding suffix.
29843 if (LC_ALL=ja_JP.EUC-JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29844 gt_cv_locale_ja=ja_JP.EUC-JP
29846 # Test for the HP-UX, OSF/1, NetBSD locale name.
29847 if (LC_ALL=ja_JP.eucJP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29848 gt_cv_locale_ja=ja_JP.eucJP
29850 # Test for the IRIX, FreeBSD locale name.
29851 if (LC_ALL=ja_JP.EUC LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29852 gt_cv_locale_ja=ja_JP.EUC
29854 # Test for the Solaris 7 locale name.
29855 if (LC_ALL=ja LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29858 # Special test for NetBSD 1.6.
29859 if test -f /usr/share/locale/ja_JP.eucJP/LC_CTYPE; then
29860 gt_cv_locale_ja=ja_JP.eucJP
29863 gt_cv_locale_ja=none
29876 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_ja" >&5
29877 printf "%s\n" "$gt_cv_locale_ja" >&6; }
29878 LOCALE_JA=$gt_cv_locale_ja
29884 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a transitional chinese locale" >&5
29885 printf %s "checking for a transitional chinese locale... " >&6; }
29886 if ${gt_cv_locale_zh_CN+:} false; then :
29887 printf %s "(cached) " >&6
29890 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29891 /* end confdefs.h. */
29893 #include <locale.h>
29894 #include <stdlib.h>
29896 #if HAVE_LANGINFO_CODESET
29897 # include <langinfo.h>
29899 #include <stdlib.h>
29900 #include <string.h>
29906 /* Check whether the given locale name is recognized by the system. */
29907 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
29908 /* On native Windows, setlocale(category, "") looks at the system settings,
29909 not at the environment variables. Also, when an encoding suffix such
29910 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
29911 category of the locale to "C". */
29912 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
29913 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
29916 if (setlocale (LC_ALL, "") == NULL) return 1;
29918 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
29919 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
29920 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
29921 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
29922 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
29923 some unit tests fail.
29924 On MirBSD 10, when an unsupported locale is specified, setlocale()
29925 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
29926 #if HAVE_LANGINFO_CODESET
29928 const char *cs = nl_langinfo (CODESET);
29929 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
29930 || strcmp (cs, "UTF-8") == 0)
29935 /* On Cygwin, avoid locale names without encoding suffix, because the
29936 locale_charset() function relies on the encoding suffix. Note that
29937 LC_ALL is set on the command line. */
29938 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
29940 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
29941 This excludes the UTF-8 encoding (except on MirBSD). */
29942 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
29943 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
29944 for (p = buf; *p != '\0'; p++)
29945 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
29947 /* Check whether a typical GB18030 multibyte sequence is recognized as a
29948 single wide character. This excludes the GB2312 and GBK encodings. */
29949 if (mblen ("\203\062\332\066", 5) != 4)
29955 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
29956 (eval $ac_link) 2>&5
29958 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
29959 test $ac_status = 0; } && test -s conftest$ac_exeext; then
29961 # Handle native Windows specially, because there setlocale() interprets
29962 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
29963 # "fr" or "fra" as "French" or "French_France.1252",
29964 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
29965 # "ja" as "Japanese" or "Japanese_Japan.932",
29968 # Test for the hypothetical native Windows locale name.
29969 if (LC_ALL=Chinese_China.54936 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29970 gt_cv_locale_zh_CN=Chinese_China.54936
29973 gt_cv_locale_zh_CN=none
29977 # On Solaris 8, the locales zh_CN.GB18030, zh_CN.GBK, zh.GBK are
29978 # broken. One witness is the test case in gl_MBRTOWC_SANITYCHECK.
29979 # Another witness is that "LC_ALL=zh_CN.GB18030 bash -c true" dumps core.
29980 gt_cv_locale_zh_CN=none
29983 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
29984 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
29985 # configure script would override the LC_ALL setting. Likewise for
29986 # LC_CTYPE, which is also set at the beginning of the configure script.
29987 # Test for the locale name without encoding suffix.
29988 if (LC_ALL=zh_CN LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29989 gt_cv_locale_zh_CN=zh_CN
29991 # Test for the locale name with explicit encoding suffix.
29992 if (LC_ALL=zh_CN.GB18030 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
29993 gt_cv_locale_zh_CN=zh_CN.GB18030
29996 gt_cv_locale_zh_CN=none
30002 # If there was a link error, due to mblen(), the system is so old that
30003 # it certainly doesn't have a chinese locale.
30004 gt_cv_locale_zh_CN=none
30009 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_zh_CN" >&5
30010 printf "%s\n" "$gt_cv_locale_zh_CN" >&6; }
30011 LOCALE_ZH_CN=$gt_cv_locale_zh_CN
30016 ac_fn_c_check_decl "$LINENO" "sleep" "ac_cv_have_decl_sleep" "#include <unistd.h>
30018 if test "x$ac_cv_have_decl_sleep" = xyes; then :
30024 cat >>confdefs.h <<_ACEOF
30025 #define HAVE_DECL_SLEEP $ac_have_decl
30029 if test $ac_cv_have_decl_sleep != yes; then
30032 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working sleep" >&5
30033 printf %s "checking for working sleep... " >&6; }
30034 if ${gl_cv_func_sleep_works+:} false; then :
30035 printf %s "(cached) " >&6
30037 if test "$cross_compiling" = yes; then :
30039 # Guess yes on glibc systems.
30040 *-gnu*) gl_cv_func_sleep_works="guessing yes" ;;
30041 # If we don't know, assume the worst.
30042 *) gl_cv_func_sleep_works="guessing no" ;;
30046 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30047 /* end confdefs.h. */
30050 #include <unistd.h>
30051 #include <signal.h>
30053 handle_alarm (int sig)
30055 if (sig != SIGALRM)
30063 /* Failure to compile this test due to missing alarm is okay,
30064 since all such platforms (mingw) also lack sleep. */
30065 unsigned int pentecost = 50 * 24 * 60 * 60; /* 50 days. */
30066 unsigned int remaining;
30067 signal (SIGALRM, handle_alarm);
30069 remaining = sleep (pentecost);
30070 if (remaining > pentecost)
30072 if (remaining <= pentecost - 10)
30080 if ac_fn_c_try_run "$LINENO"; then :
30081 gl_cv_func_sleep_works=yes
30083 gl_cv_func_sleep_works=no
30085 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
30086 conftest.$ac_objext conftest.beam conftest.$ac_ext
30090 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_sleep_works" >&5
30091 printf "%s\n" "$gl_cv_func_sleep_works" >&6; }
30092 case "$gl_cv_func_sleep_works" in
30100 if test $HAVE_SLEEP = 0 || test $REPLACE_SLEEP = 1; then
30109 gltests_LIBOBJS="$gltests_LIBOBJS sleep.$ac_objext"
30117 if test "$GNULIB_SLEEP" != 1; then
30118 if test "$GNULIB_SLEEP" = 0; then
30119 GNULIB_SLEEP=$gl_module_indicator_condition
30121 GNULIB_SLEEP="($GNULIB_SLEEP || $gl_module_indicator_condition)"
30129 printf "%s\n" "#define GNULIB_TEST_SLEEP 1" >>confdefs.h
30136 gl_cv_func_snprintf_usable=no
30137 for ac_func in snprintf
30139 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
30140 if test "x$ac_cv_func_snprintf" = xyes; then :
30141 cat >>confdefs.h <<_ACEOF
30142 #define HAVE_SNPRINTF 1
30148 if test $ac_cv_func_snprintf = yes; then
30152 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether snprintf respects a size of 1" >&5
30153 printf %s "checking whether snprintf respects a size of 1... " >&6; }
30154 if ${gl_cv_func_snprintf_size1+:} false; then :
30155 printf %s "(cached) " >&6
30158 if test "$cross_compiling" = yes; then :
30159 gl_cv_func_snprintf_size1="guessing yes"
30161 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30162 /* end confdefs.h. */
30166 # define my_snprintf snprintf
30168 # include <stdarg.h>
30169 static int my_snprintf (char *buf, int size, const char *format, ...)
30173 va_start (args, format);
30174 ret = vsnprintf (buf, size, format, args);
30181 static char buf[8] = { 'D', 'E', 'A', 'D', 'B', 'E', 'E', 'F' };
30182 my_snprintf (buf, 1, "%d", 12345);
30183 return buf[1] != 'E';
30186 if ac_fn_c_try_run "$LINENO"; then :
30187 gl_cv_func_snprintf_size1=yes
30189 gl_cv_func_snprintf_size1=no
30191 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
30192 conftest.$ac_objext conftest.beam conftest.$ac_ext
30197 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_snprintf_size1" >&5
30198 printf "%s\n" "$gl_cv_func_snprintf_size1" >&6; }
30200 case "$gl_cv_func_snprintf_size1" in
30203 case "$gl_cv_func_snprintf_retval_c99" in
30207 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether printf supports POSIX/XSI format strings with positions" >&5
30208 printf %s "checking whether printf supports POSIX/XSI format strings with positions... " >&6; }
30209 if ${gl_cv_func_printf_positions+:} false; then :
30210 printf %s "(cached) " >&6
30213 if test "$cross_compiling" = yes; then :
30216 netbsd[1-3]* | netbsdelf[1-3]* | netbsdaout[1-3]* | netbsdcoff[1-3]*)
30217 gl_cv_func_printf_positions="guessing no";;
30218 beos*) gl_cv_func_printf_positions="guessing no";;
30219 mingw* | pw*) gl_cv_func_printf_positions="guessing no";;
30220 *) gl_cv_func_printf_positions="guessing yes";;
30224 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30225 /* end confdefs.h. */
30228 #include <string.h>
30229 /* The string "%2$d %1$d", with dollar characters protected from the shell's
30230 dollar expansion (possibly an autoconf bug). */
30231 static char format[] = { '%', '2', '$', 'd', ' ', '%', '1', '$', 'd', '\0' };
30232 static char buf[100];
30235 sprintf (buf, format, 33, 55);
30236 return (strcmp (buf, "55 33") != 0);
30239 if ac_fn_c_try_run "$LINENO"; then :
30240 gl_cv_func_printf_positions=yes
30242 gl_cv_func_printf_positions=no
30244 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
30245 conftest.$ac_objext conftest.beam conftest.$ac_ext
30250 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_positions" >&5
30251 printf "%s\n" "$gl_cv_func_printf_positions" >&6; }
30253 case "$gl_cv_func_printf_positions" in
30255 gl_cv_func_snprintf_usable=yes
30263 if test $gl_cv_func_snprintf_usable = no; then
30274 gltests_LIBOBJS="$gltests_LIBOBJS snprintf.$ac_objext"
30276 if test $ac_cv_func_snprintf = yes; then
30283 if test $ac_cv_have_decl_snprintf = no; then
30284 HAVE_DECL_SNPRINTF=0
30292 if test "$GNULIB_SNPRINTF" != 1; then
30293 if test "$GNULIB_SNPRINTF" = 0; then
30294 GNULIB_SNPRINTF=$gl_module_indicator_condition
30296 GNULIB_SNPRINTF="($GNULIB_SNPRINTF || $gl_module_indicator_condition)"
30304 printf "%s\n" "#define GNULIB_TEST_SNPRINTF 1" >>confdefs.h
30310 cat >>confdefs.h <<_ACEOF
30311 #define GNULIB_SNPRINTF $gl_module_indicator_condition
30320 # Check for mmap(). Don't use AC_FUNC_MMAP, because it checks too much: it
30321 # fails on HP-UX 11, because MAP_FIXED mappings do not work. But this is
30322 # irrelevant for anonymous mappings.
30323 ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap"
30324 if test "x$ac_cv_func_mmap" = xyes; then :
30331 # Try to allow MAP_ANONYMOUS.
30332 gl_have_mmap_anonymous=no
30333 if test $gl_have_mmap = yes; then
30334 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for MAP_ANONYMOUS" >&5
30335 printf %s "checking for MAP_ANONYMOUS... " >&6; }
30336 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30337 /* end confdefs.h. */
30339 #include <sys/mman.h>
30340 #ifdef MAP_ANONYMOUS
30341 I cannot identify this map
30345 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
30346 $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
30347 gl_have_mmap_anonymous=yes
30351 if test $gl_have_mmap_anonymous != yes; then
30352 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30353 /* end confdefs.h. */
30355 #include <sys/mman.h>
30357 I cannot identify this map
30361 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
30362 $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
30364 printf "%s\n" "#define MAP_ANONYMOUS MAP_ANON" >>confdefs.h
30366 gl_have_mmap_anonymous=yes
30371 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_have_mmap_anonymous" >&5
30372 printf "%s\n" "$gl_have_mmap_anonymous" >&6; }
30373 if test $gl_have_mmap_anonymous = yes; then
30375 printf "%s\n" "#define HAVE_MAP_ANONYMOUS 1" >>confdefs.h
30385 if test $ac_cv_func_symlink = no; then
30388 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
30389 printf %s "checking whether symlink handles trailing slash correctly... " >&6; }
30390 if ${gl_cv_func_symlink_works+:} false; then :
30391 printf %s "(cached) " >&6
30393 if test "$cross_compiling" = yes; then :
30395 # Guess yes on glibc systems.
30396 *-gnu*) gl_cv_func_symlink_works="guessing yes" ;;
30397 # If we don't know, assume the worst.
30398 *) gl_cv_func_symlink_works="guessing no" ;;
30402 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30403 /* end confdefs.h. */
30404 #include <unistd.h>
30410 if (!symlink ("a", "conftest.link/"))
30412 if (symlink ("conftest.f", "conftest.lnk2"))
30414 else if (!symlink ("a", "conftest.lnk2/"))
30422 if ac_fn_c_try_run "$LINENO"; then :
30423 gl_cv_func_symlink_works=yes
30425 gl_cv_func_symlink_works=no
30427 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
30428 conftest.$ac_objext conftest.beam conftest.$ac_ext
30431 rm -f conftest.f conftest.link conftest.lnk2
30433 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
30434 printf "%s\n" "$gl_cv_func_symlink_works" >&6; }
30435 case "$gl_cv_func_symlink_works" in
30443 if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
30452 gltests_LIBOBJS="$gltests_LIBOBJS symlink.$ac_objext"
30460 if test "$GNULIB_SYMLINK" != 1; then
30461 if test "$GNULIB_SYMLINK" = 0; then
30462 GNULIB_SYMLINK=$gl_module_indicator_condition
30464 GNULIB_SYMLINK="($GNULIB_SYMLINK || $gl_module_indicator_condition)"
30472 printf "%s\n" "#define GNULIB_TEST_SYMLINK 1" >>confdefs.h
30479 if test $ac_cv_have_decl_unsetenv = no; then
30480 HAVE_DECL_UNSETENV=0
30482 for ac_func in unsetenv
30484 ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv"
30485 if test "x$ac_cv_func_unsetenv" = xyes; then :
30486 cat >>confdefs.h <<_ACEOF
30487 #define HAVE_UNSETENV 1
30493 if test $ac_cv_func_unsetenv = no; then
30497 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for unsetenv() return type" >&5
30498 printf %s "checking for unsetenv() return type... " >&6; }
30499 if ${gt_cv_func_unsetenv_ret+:} false; then :
30500 printf %s "(cached) " >&6
30502 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30503 /* end confdefs.h. */
30506 #define _BSD 1 /* unhide unsetenv declaration in OSF/1 5.1 <stdlib.h> */
30507 #include <stdlib.h>
30512 int unsetenv (const char *name);
30522 if ac_fn_c_try_compile "$LINENO"; then :
30523 gt_cv_func_unsetenv_ret='int'
30525 gt_cv_func_unsetenv_ret='void'
30527 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30529 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_unsetenv_ret" >&5
30530 printf "%s\n" "$gt_cv_func_unsetenv_ret" >&6; }
30531 if test $gt_cv_func_unsetenv_ret = 'void'; then
30533 printf "%s\n" "#define VOID_UNSETENV 1" >>confdefs.h
30538 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether unsetenv obeys POSIX" >&5
30539 printf %s "checking whether unsetenv obeys POSIX... " >&6; }
30540 if ${gl_cv_func_unsetenv_works+:} false; then :
30541 printf %s "(cached) " >&6
30543 if test "$cross_compiling" = yes; then :
30545 # Guess yes on glibc systems.
30546 *-gnu*) gl_cv_func_unsetenv_works="guessing yes" ;;
30547 # If we don't know, assume the worst.
30548 *) gl_cv_func_unsetenv_works="guessing no" ;;
30552 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30553 /* end confdefs.h. */
30555 #include <stdlib.h>
30557 extern char **environ;
30563 char entry1[] = "a=1";
30564 char entry2[] = "b=2";
30565 char *env[] = { entry1, entry2, NULL };
30566 if (putenv ((char *) "a=1")) return 1;
30567 if (putenv (entry2)) return 2;
30570 if (getenv ("a")) return 3;
30571 if (!unsetenv ("") || errno != EINVAL) return 4;
30574 if (!getenv ("a")) return 5;
30577 if (getenv ("a")) return 6;
30583 if ac_fn_c_try_run "$LINENO"; then :
30584 gl_cv_func_unsetenv_works=yes
30586 gl_cv_func_unsetenv_works=no
30588 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
30589 conftest.$ac_objext conftest.beam conftest.$ac_ext
30593 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_unsetenv_works" >&5
30594 printf "%s\n" "$gl_cv_func_unsetenv_works" >&6; }
30595 case "$gl_cv_func_unsetenv_works" in
30603 if test $HAVE_UNSETENV = 0 || test $REPLACE_UNSETENV = 1; then
30612 gltests_LIBOBJS="$gltests_LIBOBJS unsetenv.$ac_objext"
30624 if test "$GNULIB_UNSETENV" != 1; then
30625 if test "$GNULIB_UNSETENV" = 0; then
30626 GNULIB_UNSETENV=$gl_module_indicator_condition
30628 GNULIB_UNSETENV="($GNULIB_UNSETENV || $gl_module_indicator_condition)"
30636 printf "%s\n" "#define GNULIB_TEST_UNSETENV 1" >>confdefs.h
30640 abs_aux_dir=`cd "$ac_aux_dir"; pwd`
30646 ac_fn_c_check_type "$LINENO" "useconds_t" "ac_cv_type_useconds_t" "$ac_includes_default"
30647 if test "x$ac_cv_type_useconds_t" = xyes; then :
30651 printf "%s\n" "#define useconds_t unsigned int" >>confdefs.h
30655 if test $ac_cv_func_usleep = no; then
30658 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether usleep allows large arguments" >&5
30659 printf %s "checking whether usleep allows large arguments... " >&6; }
30660 if ${gl_cv_func_usleep_works+:} false; then :
30661 printf %s "(cached) " >&6
30663 if test "$cross_compiling" = yes; then :
30665 # Guess yes on glibc systems.
30666 *-gnu*) gl_cv_func_usleep_works="guessing yes" ;;
30667 # If we don't know, assume the worst.
30668 *) gl_cv_func_usleep_works="guessing no" ;;
30672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30673 /* end confdefs.h. */
30675 #include <unistd.h>
30680 return !!usleep (1000000);
30685 if ac_fn_c_try_run "$LINENO"; then :
30686 gl_cv_func_usleep_works=yes
30688 gl_cv_func_usleep_works=no
30690 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
30691 conftest.$ac_objext conftest.beam conftest.$ac_ext
30695 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_usleep_works" >&5
30696 printf "%s\n" "$gl_cv_func_usleep_works" >&6; }
30697 case "$gl_cv_func_usleep_works" in
30705 if test $HAVE_USLEEP = 0 || test $REPLACE_USLEEP = 1; then
30714 gltests_LIBOBJS="$gltests_LIBOBJS usleep.$ac_objext"
30722 if test "$GNULIB_USLEEP" != 1; then
30723 if test "$GNULIB_USLEEP" = 0; then
30724 GNULIB_USLEEP=$gl_module_indicator_condition
30726 GNULIB_USLEEP="($GNULIB_USLEEP || $gl_module_indicator_condition)"
30734 printf "%s\n" "#define GNULIB_TEST_USLEEP 1" >>confdefs.h
30738 abs_aux_dir=`cd "$ac_aux_dir"; pwd`
30743 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
30744 printf %s "checking for a traditional french locale... " >&6; }
30745 if ${gt_cv_locale_fr+:} false; then :
30746 printf %s "(cached) " >&6
30749 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30750 /* end confdefs.h. */
30752 #include <locale.h>
30754 #if HAVE_LANGINFO_CODESET
30755 # include <langinfo.h>
30757 #include <stdlib.h>
30758 #include <string.h>
30762 /* Check whether the given locale name is recognized by the system. */
30763 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
30764 /* On native Windows, setlocale(category, "") looks at the system settings,
30765 not at the environment variables. Also, when an encoding suffix such
30766 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
30767 category of the locale to "C". */
30768 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
30769 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
30772 if (setlocale (LC_ALL, "") == NULL) return 1;
30774 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
30775 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
30776 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
30777 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
30778 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
30779 some unit tests fail.
30780 On MirBSD 10, when an unsupported locale is specified, setlocale()
30781 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
30782 #if HAVE_LANGINFO_CODESET
30784 const char *cs = nl_langinfo (CODESET);
30785 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
30786 || strcmp (cs, "UTF-8") == 0)
30791 /* On Cygwin, avoid locale names without encoding suffix, because the
30792 locale_charset() function relies on the encoding suffix. Note that
30793 LC_ALL is set on the command line. */
30794 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
30796 /* Check whether in the abbreviation of the second month, the second
30797 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
30798 one byte long. This excludes the UTF-8 encoding. */
30799 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
30800 if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
30801 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
30802 /* Check whether the decimal separator is a comma.
30803 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
30804 are nl_langinfo(RADIXCHAR) are both ".". */
30805 if (localeconv () ->decimal_point[0] != ',') return 1;
30811 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
30812 (eval $ac_link) 2>&5
30814 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
30815 test $ac_status = 0; } && test -s conftest$ac_exeext; then
30817 # Handle native Windows specially, because there setlocale() interprets
30818 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
30819 # "fr" or "fra" as "French" or "French_France.1252",
30820 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
30821 # "ja" as "Japanese" or "Japanese_Japan.932",
30824 # Test for the native Windows locale name.
30825 if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
30826 gt_cv_locale_fr=French_France.1252
30829 gt_cv_locale_fr=none
30833 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
30834 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
30835 # configure script would override the LC_ALL setting. Likewise for
30836 # LC_CTYPE, which is also set at the beginning of the configure script.
30837 # Test for the usual locale name.
30838 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
30839 gt_cv_locale_fr=fr_FR
30841 # Test for the locale name with explicit encoding suffix.
30842 if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
30843 gt_cv_locale_fr=fr_FR.ISO-8859-1
30845 # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
30846 if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
30847 gt_cv_locale_fr=fr_FR.ISO8859-1
30849 # Test for the HP-UX locale name.
30850 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
30851 gt_cv_locale_fr=fr_FR.iso88591
30853 # Test for the Solaris 7 locale name.
30854 if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
30858 gt_cv_locale_fr=none
30870 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
30871 printf "%s\n" "$gt_cv_locale_fr" >&6; }
30872 LOCALE_FR=$gt_cv_locale_fr
30877 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
30878 printf %s "checking for a french Unicode locale... " >&6; }
30879 if ${gt_cv_locale_fr_utf8+:} false; then :
30880 printf %s "(cached) " >&6
30883 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30884 /* end confdefs.h. */
30886 #include <locale.h>
30888 #if HAVE_LANGINFO_CODESET
30889 # include <langinfo.h>
30891 #include <stdlib.h>
30892 #include <string.h>
30896 /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
30897 imitates locale dependent behaviour by looking at the environment
30898 variables, and all locales use the UTF-8 encoding. */
30899 #if !(defined __BEOS__ || defined __HAIKU__)
30900 /* Check whether the given locale name is recognized by the system. */
30901 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
30902 /* On native Windows, setlocale(category, "") looks at the system settings,
30903 not at the environment variables. Also, when an encoding suffix such
30904 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
30905 category of the locale to "C". */
30906 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
30907 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
30910 if (setlocale (LC_ALL, "") == NULL) return 1;
30912 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
30913 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
30914 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
30915 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
30916 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
30917 some unit tests fail. */
30918 # if HAVE_LANGINFO_CODESET
30920 const char *cs = nl_langinfo (CODESET);
30921 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
30926 /* On Cygwin, avoid locale names without encoding suffix, because the
30927 locale_charset() function relies on the encoding suffix. Note that
30928 LC_ALL is set on the command line. */
30929 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
30931 /* Check whether in the abbreviation of the second month, the second
30932 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
30933 two bytes long, with UTF-8 encoding. */
30934 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
30935 if (strftime (buf, sizeof (buf), "%b", &t) < 4
30936 || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
30939 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
30940 /* Check whether the decimal separator is a comma.
30941 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
30942 are nl_langinfo(RADIXCHAR) are both ".". */
30943 if (localeconv () ->decimal_point[0] != ',') return 1;
30949 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
30950 (eval $ac_link) 2>&5
30952 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
30953 test $ac_status = 0; } && test -s conftest$ac_exeext; then
30955 # Handle native Windows specially, because there setlocale() interprets
30956 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
30957 # "fr" or "fra" as "French" or "French_France.1252",
30958 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
30959 # "ja" as "Japanese" or "Japanese_Japan.932",
30962 # Test for the hypothetical native Windows locale name.
30963 if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
30964 gt_cv_locale_fr_utf8=French_France.65001
30967 gt_cv_locale_fr_utf8=none
30971 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
30972 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
30973 # configure script would override the LC_ALL setting. Likewise for
30974 # LC_CTYPE, which is also set at the beginning of the configure script.
30975 # Test for the usual locale name.
30976 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
30977 gt_cv_locale_fr_utf8=fr_FR
30979 # Test for the locale name with explicit encoding suffix.
30980 if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
30981 gt_cv_locale_fr_utf8=fr_FR.UTF-8
30983 # Test for the Solaris 7 locale name.
30984 if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
30985 gt_cv_locale_fr_utf8=fr.UTF-8
30988 gt_cv_locale_fr_utf8=none
30998 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
30999 printf "%s\n" "$gt_cv_locale_fr_utf8" >&6; }
31000 LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
31006 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a traditional japanese locale" >&5
31007 printf %s "checking for a traditional japanese locale... " >&6; }
31008 if ${gt_cv_locale_ja+:} false; then :
31009 printf %s "(cached) " >&6
31012 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31013 /* end confdefs.h. */
31015 #include <locale.h>
31017 #if HAVE_LANGINFO_CODESET
31018 # include <langinfo.h>
31020 #include <stdlib.h>
31021 #include <string.h>
31027 /* Check whether the given locale name is recognized by the system. */
31028 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
31029 /* On native Windows, setlocale(category, "") looks at the system settings,
31030 not at the environment variables. Also, when an encoding suffix such
31031 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
31032 category of the locale to "C". */
31033 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
31034 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
31037 if (setlocale (LC_ALL, "") == NULL) return 1;
31039 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
31040 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
31041 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
31042 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
31043 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
31044 some unit tests fail.
31045 On MirBSD 10, when an unsupported locale is specified, setlocale()
31046 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
31047 #if HAVE_LANGINFO_CODESET
31049 const char *cs = nl_langinfo (CODESET);
31050 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
31051 || strcmp (cs, "UTF-8") == 0)
31056 /* On Cygwin, avoid locale names without encoding suffix, because the
31057 locale_charset() function relies on the encoding suffix. Note that
31058 LC_ALL is set on the command line. */
31059 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
31061 /* Check whether MB_CUR_MAX is > 1. This excludes the dysfunctional locales
31062 on Cygwin 1.5.x. */
31063 if (MB_CUR_MAX == 1)
31065 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
31066 This excludes the UTF-8 encoding (except on MirBSD). */
31067 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
31068 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
31069 for (p = buf; *p != '\0'; p++)
31070 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
31076 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
31077 (eval $ac_link) 2>&5
31079 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
31080 test $ac_status = 0; } && test -s conftest$ac_exeext; then
31082 # Handle native Windows specially, because there setlocale() interprets
31083 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
31084 # "fr" or "fra" as "French" or "French_France.1252",
31085 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
31086 # "ja" as "Japanese" or "Japanese_Japan.932",
31089 # Note that on native Windows, the Japanese locale is
31090 # Japanese_Japan.932, and CP932 is very different from EUC-JP, so we
31091 # cannot use it here.
31092 gt_cv_locale_ja=none
31095 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
31096 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
31097 # configure script would override the LC_ALL setting. Likewise for
31098 # LC_CTYPE, which is also set at the beginning of the configure script.
31099 # Test for the AIX locale name.
31100 if (LC_ALL=ja_JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
31101 gt_cv_locale_ja=ja_JP
31103 # Test for the locale name with explicit encoding suffix.
31104 if (LC_ALL=ja_JP.EUC-JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
31105 gt_cv_locale_ja=ja_JP.EUC-JP
31107 # Test for the HP-UX, OSF/1, NetBSD locale name.
31108 if (LC_ALL=ja_JP.eucJP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
31109 gt_cv_locale_ja=ja_JP.eucJP
31111 # Test for the IRIX, FreeBSD locale name.
31112 if (LC_ALL=ja_JP.EUC LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
31113 gt_cv_locale_ja=ja_JP.EUC
31115 # Test for the Solaris 7 locale name.
31116 if (LC_ALL=ja LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
31119 # Special test for NetBSD 1.6.
31120 if test -f /usr/share/locale/ja_JP.eucJP/LC_CTYPE; then
31121 gt_cv_locale_ja=ja_JP.eucJP
31124 gt_cv_locale_ja=none
31137 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_ja" >&5
31138 printf "%s\n" "$gt_cv_locale_ja" >&6; }
31139 LOCALE_JA=$gt_cv_locale_ja
31145 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a transitional chinese locale" >&5
31146 printf %s "checking for a transitional chinese locale... " >&6; }
31147 if ${gt_cv_locale_zh_CN+:} false; then :
31148 printf %s "(cached) " >&6
31151 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31152 /* end confdefs.h. */
31154 #include <locale.h>
31155 #include <stdlib.h>
31157 #if HAVE_LANGINFO_CODESET
31158 # include <langinfo.h>
31160 #include <stdlib.h>
31161 #include <string.h>
31167 /* Check whether the given locale name is recognized by the system. */
31168 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
31169 /* On native Windows, setlocale(category, "") looks at the system settings,
31170 not at the environment variables. Also, when an encoding suffix such
31171 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
31172 category of the locale to "C". */
31173 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
31174 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
31177 if (setlocale (LC_ALL, "") == NULL) return 1;
31179 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
31180 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
31181 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
31182 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
31183 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
31184 some unit tests fail.
31185 On MirBSD 10, when an unsupported locale is specified, setlocale()
31186 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
31187 #if HAVE_LANGINFO_CODESET
31189 const char *cs = nl_langinfo (CODESET);
31190 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
31191 || strcmp (cs, "UTF-8") == 0)
31196 /* On Cygwin, avoid locale names without encoding suffix, because the
31197 locale_charset() function relies on the encoding suffix. Note that
31198 LC_ALL is set on the command line. */
31199 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
31201 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
31202 This excludes the UTF-8 encoding (except on MirBSD). */
31203 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
31204 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
31205 for (p = buf; *p != '\0'; p++)
31206 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
31208 /* Check whether a typical GB18030 multibyte sequence is recognized as a
31209 single wide character. This excludes the GB2312 and GBK encodings. */
31210 if (mblen ("\203\062\332\066", 5) != 4)
31216 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
31217 (eval $ac_link) 2>&5
31219 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
31220 test $ac_status = 0; } && test -s conftest$ac_exeext; then
31222 # Handle native Windows specially, because there setlocale() interprets
31223 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
31224 # "fr" or "fra" as "French" or "French_France.1252",
31225 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
31226 # "ja" as "Japanese" or "Japanese_Japan.932",
31229 # Test for the hypothetical native Windows locale name.
31230 if (LC_ALL=Chinese_China.54936 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
31231 gt_cv_locale_zh_CN=Chinese_China.54936
31234 gt_cv_locale_zh_CN=none
31238 # On Solaris 8, the locales zh_CN.GB18030, zh_CN.GBK, zh.GBK are
31239 # broken. One witness is the test case in gl_MBRTOWC_SANITYCHECK.
31240 # Another witness is that "LC_ALL=zh_CN.GB18030 bash -c true" dumps core.
31241 gt_cv_locale_zh_CN=none
31244 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
31245 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
31246 # configure script would override the LC_ALL setting. Likewise for
31247 # LC_CTYPE, which is also set at the beginning of the configure script.
31248 # Test for the locale name without encoding suffix.
31249 if (LC_ALL=zh_CN LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
31250 gt_cv_locale_zh_CN=zh_CN
31252 # Test for the locale name with explicit encoding suffix.
31253 if (LC_ALL=zh_CN.GB18030 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
31254 gt_cv_locale_zh_CN=zh_CN.GB18030
31257 gt_cv_locale_zh_CN=none
31263 # If there was a link error, due to mblen(), the system is so old that
31264 # it certainly doesn't have a chinese locale.
31265 gt_cv_locale_zh_CN=none
31270 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_zh_CN" >&5
31271 printf "%s\n" "$gt_cv_locale_zh_CN" >&6; }
31272 LOCALE_ZH_CN=$gt_cv_locale_zh_CN
31279 if test $ac_cv_func_wctob = no; then
31287 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether wctob works" >&5
31288 printf %s "checking whether wctob works... " >&6; }
31289 if ${gl_cv_func_wctob_works+:} false; then :
31290 printf %s "(cached) " >&6
31294 # Guess no on Solaris <= 9 and Cygwin.
31295 solaris2.[1-9] | solaris2.[1-9].* | cygwin*)
31296 gl_cv_func_wctob_works="guessing no" ;;
31297 # Guess yes otherwise.
31298 *) gl_cv_func_wctob_works="guessing yes" ;;
31302 if test "$cross_compiling" = yes; then :
31305 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31306 /* end confdefs.h. */
31308 #include <locale.h>
31309 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
31311 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
31312 included before <wchar.h>. */
31313 #include <stddef.h>
31318 register long global __asm__ ("%ebx");
31322 setlocale (LC_ALL, "en_US.UTF-8");
31324 global = 0x12345678;
31325 if (wctob (0x00FC) != -1)
31327 if (global != 0x12345678)
31332 if ac_fn_c_try_run "$LINENO"; then :
31335 gl_cv_func_wctob_works=no
31337 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
31338 conftest.$ac_objext conftest.beam conftest.$ac_ext
31343 if test "$gl_cv_func_wctob_works" != no && test $LOCALE_FR != none; then
31344 if test "$cross_compiling" = yes; then :
31347 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31348 /* end confdefs.h. */
31350 #include <locale.h>
31351 #include <string.h>
31352 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
31354 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
31355 included before <wchar.h>. */
31356 #include <stddef.h>
31362 if (setlocale (LC_ALL, "$LOCALE_FR") != NULL)
31366 if (mbtowc (&wc, "\374", 1) == 1)
31367 if (wctob (wc) != (unsigned char) '\374')
31373 if ac_fn_c_try_run "$LINENO"; then :
31374 gl_cv_func_wctob_works=yes
31376 gl_cv_func_wctob_works=no
31378 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
31379 conftest.$ac_objext conftest.beam conftest.$ac_ext
31385 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_wctob_works" >&5
31386 printf "%s\n" "$gl_cv_func_wctob_works" >&6; }
31387 case "$gl_cv_func_wctob_works" in
31389 *) REPLACE_WCTOB=1 ;;
31391 if test $REPLACE_WCTOB = 0; then
31393 ac_fn_c_check_decl "$LINENO" "wctob" "ac_cv_have_decl_wctob" "
31394 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
31396 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
31397 before <wchar.h>. */
31398 #include <stddef.h>
31404 if test "x$ac_cv_have_decl_wctob" = xyes; then :
31410 cat >>confdefs.h <<_ACEOF
31411 #define HAVE_DECL_WCTOB $ac_have_decl
31414 if test $ac_cv_have_decl_wctob != yes; then
31420 if test $HAVE_WCTOB = 0 || test $REPLACE_WCTOB = 1; then
31429 gltests_LIBOBJS="$gltests_LIBOBJS wctob.$ac_objext"
31440 if test "$GNULIB_WCTOB" != 1; then
31441 if test "$GNULIB_WCTOB" = 0; then
31442 GNULIB_WCTOB=$gl_module_indicator_condition
31444 GNULIB_WCTOB="($GNULIB_WCTOB || $gl_module_indicator_condition)"
31452 printf "%s\n" "#define GNULIB_TEST_WCTOB 1" >>confdefs.h
31463 if test $REPLACE_WCTOMB = 1; then
31472 gltests_LIBOBJS="$gltests_LIBOBJS wctomb.$ac_objext"
31483 if test "$GNULIB_WCTOMB" != 1; then
31484 if test "$GNULIB_WCTOMB" = 0; then
31485 GNULIB_WCTOMB=$gl_module_indicator_condition
31487 GNULIB_WCTOMB="($GNULIB_WCTOMB || $gl_module_indicator_condition)"
31495 printf "%s\n" "#define GNULIB_TEST_WCTOMB 1" >>confdefs.h
31509 LIBDIFFUTILS_LIBDEPS="$gl_libdeps"
31511 LIBDIFFUTILS_LTLIBDEPS="$gl_ltlibdeps"
31513 LIBTESTS_LIBDEPS="$gltests_libdeps"
31517 # Check whether --enable-gcc-warnings was given.
31518 if test "${enable_gcc_warnings+set}" = set; then :
31519 enableval=$enable_gcc_warnings; case $enableval in
31521 *) as_fn_error $? "bad value $enableval for gcc-warnings option" "$LINENO" 5 ;;
31523 gl_gcc_warnings=$enableval
31525 if test -d "$srcdir"/.git; then
31526 gl_gcc_warnings=yes
31534 if test "$gl_gcc_warnings" = yes; then
31535 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror" >&5
31536 printf %s "checking whether C compiler handles -Werror... " >&6; }
31537 if ${gl_cv_warn_c__Werror+:} false; then :
31538 printf %s "(cached) " >&6
31541 gl_save_compiler_FLAGS="$CFLAGS"
31542 as_fn_append CFLAGS " -Werror"
31543 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31544 /* end confdefs.h. */
31554 if ac_fn_c_try_compile "$LINENO"; then :
31555 gl_cv_warn_c__Werror=yes
31557 gl_cv_warn_c__Werror=no
31559 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31560 CFLAGS="$gl_save_compiler_FLAGS"
31563 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror" >&5
31564 printf "%s\n" "$gl_cv_warn_c__Werror" >&6; }
31565 if test "x$gl_cv_warn_c__Werror" = xyes; then :
31566 as_fn_append WERROR_CFLAGS " -Werror"
31573 # This, $nw, is the list of warnings we disable.
31574 nw="$nw -Wdeclaration-after-statement" # too useful to forbid
31575 nw="$nw -Waggregate-return" # anachronistic
31576 nw="$nw -Wlong-long" # C90 is anachronistic (lib/gethrxtime.h)
31577 nw="$nw -Wc++-compat" # We don't care about C++ compilers
31578 nw="$nw -Wundef" # Warns on '#if GNULIB_FOO' etc in gnulib
31579 nw="$nw -Wtraditional" # Warns on #elif which we use often
31580 nw="$nw -Wcast-qual" # Too many warnings for now
31581 nw="$nw -Wconversion" # Too many warnings for now
31582 nw="$nw -Wsystem-headers" # Don't let system headers trigger warnings
31583 nw="$nw -Wsign-conversion" # Too many warnings for now
31584 nw="$nw -Wtraditional-conversion" # Too many warnings for now
31585 nw="$nw -Wunreachable-code" # Too many warnings for now
31586 nw="$nw -Wpadded" # Our structs are not padded
31587 nw="$nw -Wredundant-decls" # openat.h declares e.g., mkdirat
31588 nw="$nw -Wlogical-op" # any use of fwrite provokes this
31589 nw="$nw -Wformat-nonliteral" # who.c and pinky.c strftime uses
31590 nw="$nw -Wvla" # warnings in gettext.h
31591 nw="$nw -Wnested-externs" # use of XARGMATCH/verify_function__
31592 nw="$nw -Wswitch-enum" # Too many warnings for now
31593 nw="$nw -Wswitch-default" # Too many warnings for now
31594 nw="$nw -Wstack-protector" # not worth working around
31595 # things I might fix soon:
31596 nw="$nw -Wfloat-equal" # sort.c, seq.c
31597 nw="$nw -Wmissing-format-attribute" # copy.c
31598 nw="$nw -Wunsafe-loop-optimizations" # a few src/*.c
31599 nw="$nw -Winline" # system.h's readdir_ignoring_dot_and_dotdot
31600 nw="$nw -Wstrict-overflow" # expr.c, pr.c, tr.c, factor.c
31601 nw="$nw -Wformat-extra-args" # sdiff.c
31602 # ?? -Wstrict-overflow
31606 if test -n "$GCC"; then
31608 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is supported" >&5
31609 printf %s "checking whether -Wno-missing-field-initializers is supported... " >&6; }
31610 if ${gl_cv_cc_nomfi_supported+:} false; then :
31611 printf %s "(cached) " >&6
31614 gl_save_CFLAGS="$CFLAGS"
31615 CFLAGS="$CFLAGS -W -Werror -Wno-missing-field-initializers"
31616 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31617 /* end confdefs.h. */
31627 if ac_fn_c_try_compile "$LINENO"; then :
31628 gl_cv_cc_nomfi_supported=yes
31630 gl_cv_cc_nomfi_supported=no
31632 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31633 CFLAGS="$gl_save_CFLAGS"
31636 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_supported" >&5
31637 printf "%s\n" "$gl_cv_cc_nomfi_supported" >&6; }
31639 if test "$gl_cv_cc_nomfi_supported" = yes; then
31640 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is needed" >&5
31641 printf %s "checking whether -Wno-missing-field-initializers is needed... " >&6; }
31642 if ${gl_cv_cc_nomfi_needed+:} false; then :
31643 printf %s "(cached) " >&6
31646 gl_save_CFLAGS="$CFLAGS"
31647 CFLAGS="$CFLAGS -W -Werror"
31648 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31649 /* end confdefs.h. */
31652 typedef struct { int a; int b; } s_t;
31664 if ac_fn_c_try_compile "$LINENO"; then :
31665 gl_cv_cc_nomfi_needed=no
31667 gl_cv_cc_nomfi_needed=yes
31669 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31670 CFLAGS="$gl_save_CFLAGS"
31674 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_needed" >&5
31675 printf "%s\n" "$gl_cv_cc_nomfi_needed" >&6; }
31678 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether -Wuninitialized is supported" >&5
31679 printf %s "checking whether -Wuninitialized is supported... " >&6; }
31680 if ${gl_cv_cc_uninitialized_supported+:} false; then :
31681 printf %s "(cached) " >&6
31684 gl_save_CFLAGS="$CFLAGS"
31685 CFLAGS="$CFLAGS -Werror -Wuninitialized"
31686 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31687 /* end confdefs.h. */
31697 if ac_fn_c_try_compile "$LINENO"; then :
31698 gl_cv_cc_uninitialized_supported=yes
31700 gl_cv_cc_uninitialized_supported=no
31702 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31703 CFLAGS="$gl_save_CFLAGS"
31706 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_uninitialized_supported" >&5
31707 printf "%s\n" "$gl_cv_cc_uninitialized_supported" >&6; }
31711 # List all gcc warning categories.
31713 for gl_manywarn_item in \
31720 -Wbad-function-cast \
31721 -Wbuiltin-macro-redefined \
31723 -Wchar-subscripts \
31727 -Wcoverage-mismatch \
31730 -Wdeprecated-declarations \
31731 -Wdisabled-optimization \
31733 -Wdouble-promotion \
31738 -Wformat-contains-nul \
31739 -Wformat-extra-args \
31740 -Wformat-nonliteral \
31741 -Wformat-security \
31743 -Wformat-zero-length \
31745 -Wfree-nonheap-object \
31746 -Wignored-qualifiers \
31748 -Wimplicit-function-declaration \
31752 -Wint-to-pointer-cast \
31753 -Winvalid-memory-model \
31755 -Wjump-misses-init \
31758 -Wmaybe-uninitialized \
31760 -Wmissing-declarations \
31761 -Wmissing-field-initializers \
31762 -Wmissing-format-attribute \
31763 -Wmissing-include-dirs \
31764 -Wmissing-noreturn \
31765 -Wmissing-parameter-type \
31766 -Wmissing-prototypes \
31773 -Wold-style-declaration \
31774 -Wold-style-definition \
31776 -Woverlength-strings \
31779 -Wpacked-bitfield-compat \
31783 -Wpointer-to-int-cast \
31788 -Wsizeof-pointer-memaccess \
31789 -Wstack-protector \
31790 -Wstrict-aliasing \
31791 -Wstrict-overflow \
31792 -Wstrict-prototypes \
31793 -Wsuggest-attribute=const \
31794 -Wsuggest-attribute=format \
31795 -Wsuggest-attribute=noreturn \
31796 -Wsuggest-attribute=pure \
31805 -Wunknown-pragmas \
31806 -Wunreachable-code \
31807 -Wunsafe-loop-optimizations \
31809 -Wunused-but-set-parameter \
31810 -Wunused-but-set-variable \
31811 -Wunused-function \
31813 -Wunused-local-typedefs \
31815 -Wunused-parameter \
31818 -Wunused-variable \
31820 -Wvariadic-macros \
31821 -Wvector-operation-performance \
31823 -Wvolatile-register-var \
31827 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
31830 # Disable specific options as needed.
31831 if test "$gl_cv_cc_nomfi_needed" = yes; then
31832 gl_manywarn_set="$gl_manywarn_set -Wno-missing-field-initializers"
31835 if test "$gl_cv_cc_uninitialized_supported" = no; then
31836 gl_manywarn_set="$gl_manywarn_set -Wno-uninitialized"
31839 ws=$gl_manywarn_set
31847 *" $gl_warn_item "*)
31850 gl_warn_set="$gl_warn_set $gl_warn_item"
31857 as_gl_Warn=`printf "%s\n" "gl_cv_warn_c_$w" | $as_tr_sh`
31858 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles $w" >&5
31859 printf %s "checking whether C compiler handles $w... " >&6; }
31860 if eval \${$as_gl_Warn+:} false; then :
31861 printf %s "(cached) " >&6
31864 gl_save_compiler_FLAGS="$CFLAGS"
31865 as_fn_append CFLAGS " $w"
31866 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31867 /* end confdefs.h. */
31877 if ac_fn_c_try_compile "$LINENO"; then :
31878 eval "$as_gl_Warn=yes"
31880 eval "$as_gl_Warn=no"
31882 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31883 CFLAGS="$gl_save_compiler_FLAGS"
31886 eval ac_res=\$$as_gl_Warn
31887 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
31888 printf "%s\n" "$ac_res" >&6; }
31889 if eval test \"x\$"$as_gl_Warn"\" = x"yes"; then :
31890 as_fn_append WARN_CFLAGS " $w"
31895 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-missing-field-initializers" >&5
31896 printf %s "checking whether C compiler handles -Wno-missing-field-initializers... " >&6; }
31897 if ${gl_cv_warn_c__Wno_missing_field_initializers+:} false; then :
31898 printf %s "(cached) " >&6
31901 gl_save_compiler_FLAGS="$CFLAGS"
31902 as_fn_append CFLAGS " -Wno-missing-field-initializers"
31903 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31904 /* end confdefs.h. */
31914 if ac_fn_c_try_compile "$LINENO"; then :
31915 gl_cv_warn_c__Wno_missing_field_initializers=yes
31917 gl_cv_warn_c__Wno_missing_field_initializers=no
31919 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31920 CFLAGS="$gl_save_compiler_FLAGS"
31923 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_missing_field_initializers" >&5
31924 printf "%s\n" "$gl_cv_warn_c__Wno_missing_field_initializers" >&6; }
31925 if test "x$gl_cv_warn_c__Wno_missing_field_initializers" = xyes; then :
31926 as_fn_append WARN_CFLAGS " -Wno-missing-field-initializers"
31930 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-sign-compare" >&5
31931 printf %s "checking whether C compiler handles -Wno-sign-compare... " >&6; }
31932 if ${gl_cv_warn_c__Wno_sign_compare+:} false; then :
31933 printf %s "(cached) " >&6
31936 gl_save_compiler_FLAGS="$CFLAGS"
31937 as_fn_append CFLAGS " -Wno-sign-compare"
31938 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31939 /* end confdefs.h. */
31949 if ac_fn_c_try_compile "$LINENO"; then :
31950 gl_cv_warn_c__Wno_sign_compare=yes
31952 gl_cv_warn_c__Wno_sign_compare=no
31954 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31955 CFLAGS="$gl_save_compiler_FLAGS"
31958 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_sign_compare" >&5
31959 printf "%s\n" "$gl_cv_warn_c__Wno_sign_compare" >&6; }
31960 if test "x$gl_cv_warn_c__Wno_sign_compare" = xyes; then :
31961 as_fn_append WARN_CFLAGS " -Wno-sign-compare"
31964 # Too many warnings for now
31965 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-pointer-sign" >&5
31966 printf %s "checking whether C compiler handles -Wno-pointer-sign... " >&6; }
31967 if ${gl_cv_warn_c__Wno_pointer_sign+:} false; then :
31968 printf %s "(cached) " >&6
31971 gl_save_compiler_FLAGS="$CFLAGS"
31972 as_fn_append CFLAGS " -Wno-pointer-sign"
31973 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31974 /* end confdefs.h. */
31984 if ac_fn_c_try_compile "$LINENO"; then :
31985 gl_cv_warn_c__Wno_pointer_sign=yes
31987 gl_cv_warn_c__Wno_pointer_sign=no
31989 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31990 CFLAGS="$gl_save_compiler_FLAGS"
31993 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_pointer_sign" >&5
31994 printf "%s\n" "$gl_cv_warn_c__Wno_pointer_sign" >&6; }
31995 if test "x$gl_cv_warn_c__Wno_pointer_sign" = xyes; then :
31996 as_fn_append WARN_CFLAGS " -Wno-pointer-sign"
31999 # Too many warnings for now
32000 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-parameter" >&5
32001 printf %s "checking whether C compiler handles -Wno-unused-parameter... " >&6; }
32002 if ${gl_cv_warn_c__Wno_unused_parameter+:} false; then :
32003 printf %s "(cached) " >&6
32006 gl_save_compiler_FLAGS="$CFLAGS"
32007 as_fn_append CFLAGS " -Wno-unused-parameter"
32008 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32009 /* end confdefs.h. */
32019 if ac_fn_c_try_compile "$LINENO"; then :
32020 gl_cv_warn_c__Wno_unused_parameter=yes
32022 gl_cv_warn_c__Wno_unused_parameter=no
32024 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32025 CFLAGS="$gl_save_compiler_FLAGS"
32028 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_parameter" >&5
32029 printf "%s\n" "$gl_cv_warn_c__Wno_unused_parameter" >&6; }
32030 if test "x$gl_cv_warn_c__Wno_unused_parameter" = xyes; then :
32031 as_fn_append WARN_CFLAGS " -Wno-unused-parameter"
32034 # Too many warnings for now
32035 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-nonliteral" >&5
32036 printf %s "checking whether C compiler handles -Wno-format-nonliteral... " >&6; }
32037 if ${gl_cv_warn_c__Wno_format_nonliteral+:} false; then :
32038 printf %s "(cached) " >&6
32041 gl_save_compiler_FLAGS="$CFLAGS"
32042 as_fn_append CFLAGS " -Wno-format-nonliteral"
32043 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32044 /* end confdefs.h. */
32054 if ac_fn_c_try_compile "$LINENO"; then :
32055 gl_cv_warn_c__Wno_format_nonliteral=yes
32057 gl_cv_warn_c__Wno_format_nonliteral=no
32059 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32060 CFLAGS="$gl_save_compiler_FLAGS"
32063 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_nonliteral" >&5
32064 printf "%s\n" "$gl_cv_warn_c__Wno_format_nonliteral" >&6; }
32065 if test "x$gl_cv_warn_c__Wno_format_nonliteral" = xyes; then :
32066 as_fn_append WARN_CFLAGS " -Wno-format-nonliteral"
32071 # In spite of excluding -Wlogical-op above, it is enabled, as of
32072 # gcc 4.5.0 20090517, and it provokes warnings in cat.c, dd.c, truncate.c
32073 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-logical-op" >&5
32074 printf %s "checking whether C compiler handles -Wno-logical-op... " >&6; }
32075 if ${gl_cv_warn_c__Wno_logical_op+:} false; then :
32076 printf %s "(cached) " >&6
32079 gl_save_compiler_FLAGS="$CFLAGS"
32080 as_fn_append CFLAGS " -Wno-logical-op"
32081 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32082 /* end confdefs.h. */
32092 if ac_fn_c_try_compile "$LINENO"; then :
32093 gl_cv_warn_c__Wno_logical_op=yes
32095 gl_cv_warn_c__Wno_logical_op=no
32097 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32098 CFLAGS="$gl_save_compiler_FLAGS"
32101 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_logical_op" >&5
32102 printf "%s\n" "$gl_cv_warn_c__Wno_logical_op" >&6; }
32103 if test "x$gl_cv_warn_c__Wno_logical_op" = xyes; then :
32104 as_fn_append WARN_CFLAGS " -Wno-logical-op"
32109 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -fdiagnostics-show-option" >&5
32110 printf %s "checking whether C compiler handles -fdiagnostics-show-option... " >&6; }
32111 if ${gl_cv_warn_c__fdiagnostics_show_option+:} false; then :
32112 printf %s "(cached) " >&6
32115 gl_save_compiler_FLAGS="$CFLAGS"
32116 as_fn_append CFLAGS " -fdiagnostics-show-option"
32117 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32118 /* end confdefs.h. */
32128 if ac_fn_c_try_compile "$LINENO"; then :
32129 gl_cv_warn_c__fdiagnostics_show_option=yes
32131 gl_cv_warn_c__fdiagnostics_show_option=no
32133 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32134 CFLAGS="$gl_save_compiler_FLAGS"
32137 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__fdiagnostics_show_option" >&5
32138 printf "%s\n" "$gl_cv_warn_c__fdiagnostics_show_option" >&6; }
32139 if test "x$gl_cv_warn_c__fdiagnostics_show_option" = xyes; then :
32140 as_fn_append WARN_CFLAGS " -fdiagnostics-show-option"
32144 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -funit-at-a-time" >&5
32145 printf %s "checking whether C compiler handles -funit-at-a-time... " >&6; }
32146 if ${gl_cv_warn_c__funit_at_a_time+:} false; then :
32147 printf %s "(cached) " >&6
32150 gl_save_compiler_FLAGS="$CFLAGS"
32151 as_fn_append CFLAGS " -funit-at-a-time"
32152 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32153 /* end confdefs.h. */
32163 if ac_fn_c_try_compile "$LINENO"; then :
32164 gl_cv_warn_c__funit_at_a_time=yes
32166 gl_cv_warn_c__funit_at_a_time=no
32168 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32169 CFLAGS="$gl_save_compiler_FLAGS"
32172 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__funit_at_a_time" >&5
32173 printf "%s\n" "$gl_cv_warn_c__funit_at_a_time" >&6; }
32174 if test "x$gl_cv_warn_c__funit_at_a_time" = xyes; then :
32175 as_fn_append WARN_CFLAGS " -funit-at-a-time"
32183 printf "%s\n" "#define lint 1" >>confdefs.h
32186 printf "%s\n" "#define _FORTIFY_SOURCE 2" >>confdefs.h
32189 printf "%s\n" "#define GNULIB_PORTCHECK 1" >>confdefs.h
32192 # We use a slightly smaller set of warning options for lib/.
32193 # Remove the following and save the result in GNULIB_WARN_CFLAGS.
32195 nw="$nw -Wunused-macros"
32196 nw="$nw -Wmissing-prototypes"
32197 nw="$nw -Wold-style-definition"
32200 set x $WARN_CFLAGS; shift
32204 *" $gl_warn_item "*)
32207 gl_warn_set="$gl_warn_set $gl_warn_item"
32211 GNULIB_WARN_CFLAGS=$gl_warn_set
32216 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
32217 printf %s "checking for inline... " >&6; }
32218 if ${ac_cv_c_inline+:} false; then :
32219 printf %s "(cached) " >&6
32222 for ac_kw in inline __inline__ __inline; do
32223 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32224 /* end confdefs.h. */
32225 #ifndef __cplusplus
32227 static $ac_kw foo_t static_foo () {return 0; }
32228 $ac_kw foo_t foo () {return 0; }
32232 if ac_fn_c_try_compile "$LINENO"; then :
32233 ac_cv_c_inline=$ac_kw
32235 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32236 test "$ac_cv_c_inline" != no && break
32240 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
32241 printf "%s\n" "$ac_cv_c_inline" >&6; }
32243 case $ac_cv_c_inline in
32246 case $ac_cv_c_inline in
32248 *) ac_val=$ac_cv_c_inline;;
32250 cat >>confdefs.h <<_ACEOF
32251 #ifndef __cplusplus
32252 #define inline $ac_val
32259 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for variable-length arrays" >&5
32260 printf %s "checking for variable-length arrays... " >&6; }
32261 if ${ac_cv_c_vararrays+:} false; then :
32262 printf %s "(cached) " >&6
32264 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32265 /* end confdefs.h. */
32270 static int x; char a[++x]; a[sizeof a - 1] = 0; return a[0];
32275 if ac_fn_c_try_compile "$LINENO"; then :
32276 ac_cv_c_vararrays=yes
32278 ac_cv_c_vararrays=no
32280 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32282 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_vararrays" >&5
32283 printf "%s\n" "$ac_cv_c_vararrays" >&6; }
32284 if test $ac_cv_c_vararrays = yes; then
32286 printf "%s\n" "#define HAVE_C_VARARRAYS 1" >>confdefs.h
32292 printf "%s\n" "#define DEFAULT_EDITOR_PROGRAM \"ed\"" >>confdefs.h
32295 # Extract the first word of "pr", so it can be a program name with args.
32296 set dummy pr; ac_word=$2
32297 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32298 printf %s "checking for $ac_word... " >&6; }
32299 if ${ac_cv_path_PR_PROGRAM+:} false; then :
32300 printf %s "(cached) " >&6
32302 case $PR_PROGRAM in
32304 ac_cv_path_PR_PROGRAM="$PR_PROGRAM" # Let the user override the test with a path.
32307 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32308 for as_dir in $PATH
32311 case $as_dir in #(((
32314 *) as_dir=$as_dir/ ;;
32316 for ac_exec_ext in '' $ac_executable_extensions; do
32317 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
32318 ac_cv_path_PR_PROGRAM="$as_dir$ac_word$ac_exec_ext"
32319 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
32326 test -z "$ac_cv_path_PR_PROGRAM" && ac_cv_path_PR_PROGRAM=""""
32330 PR_PROGRAM=$ac_cv_path_PR_PROGRAM
32331 if test -n "$PR_PROGRAM"; then
32332 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PR_PROGRAM" >&5
32333 printf "%s\n" "$PR_PROGRAM" >&6; }
32335 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
32336 printf "%s\n" "no" >&6; }
32341 cat >>confdefs.h <<_ACEOF
32342 #define PR_PROGRAM "$PR_PROGRAM"
32346 ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
32347 if test "x$ac_cv_member_struct_stat_st_blksize" = xyes; then :
32349 cat >>confdefs.h <<_ACEOF
32350 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
32356 ac_fn_c_check_member "$LINENO" "struct stat" "st_rdev" "ac_cv_member_struct_stat_st_rdev" "$ac_includes_default"
32357 if test "x$ac_cv_member_struct_stat_st_rdev" = xyes; then :
32359 cat >>confdefs.h <<_ACEOF
32360 #define HAVE_STRUCT_STAT_ST_RDEV 1
32366 ac_header_dirent=no
32367 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
32368 as_ac_Header=`printf "%s\n" "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
32369 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5
32370 printf %s "checking for $ac_hdr that defines DIR... " >&6; }
32371 if eval \${$as_ac_Header+:} false; then :
32372 printf %s "(cached) " >&6
32374 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32375 /* end confdefs.h. */
32376 #include <sys/types.h>
32388 if ac_fn_c_try_compile "$LINENO"; then :
32389 eval "$as_ac_Header=yes"
32391 eval "$as_ac_Header=no"
32393 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32395 eval ac_res=\$$as_ac_Header
32396 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
32397 printf "%s\n" "$ac_res" >&6; }
32398 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
32399 cat >>confdefs.h <<_ACEOF
32400 #define `printf "%s\n" "HAVE_$ac_hdr" | $as_tr_cpp` 1
32403 ac_header_dirent=$ac_hdr; break
32407 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
32408 if test $ac_header_dirent = dirent.h; then
32409 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
32410 printf %s "checking for library containing opendir... " >&6; }
32411 if ${ac_cv_search_opendir+:} false; then :
32412 printf %s "(cached) " >&6
32414 ac_func_search_save_LIBS=$LIBS
32415 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32416 /* end confdefs.h. */
32418 /* Override any GCC internal prototype to avoid an error.
32419 Use char because int might match the return type of a GCC
32420 builtin and then its argument prototype would still apply. */
32433 for ac_lib in '' dir; do
32434 if test -z "$ac_lib"; then
32435 ac_res="none required"
32438 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
32440 if ac_fn_c_try_link "$LINENO"; then :
32441 ac_cv_search_opendir=$ac_res
32443 rm -f core conftest.err conftest.$ac_objext \
32445 if ${ac_cv_search_opendir+:} false; then :
32449 if ${ac_cv_search_opendir+:} false; then :
32452 ac_cv_search_opendir=no
32454 rm conftest.$ac_ext
32455 LIBS=$ac_func_search_save_LIBS
32457 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
32458 printf "%s\n" "$ac_cv_search_opendir" >&6; }
32459 ac_res=$ac_cv_search_opendir
32460 if test "$ac_res" != no; then :
32461 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
32466 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
32467 printf %s "checking for library containing opendir... " >&6; }
32468 if ${ac_cv_search_opendir+:} false; then :
32469 printf %s "(cached) " >&6
32471 ac_func_search_save_LIBS=$LIBS
32472 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32473 /* end confdefs.h. */
32475 /* Override any GCC internal prototype to avoid an error.
32476 Use char because int might match the return type of a GCC
32477 builtin and then its argument prototype would still apply. */
32490 for ac_lib in '' x; do
32491 if test -z "$ac_lib"; then
32492 ac_res="none required"
32495 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
32497 if ac_fn_c_try_link "$LINENO"; then :
32498 ac_cv_search_opendir=$ac_res
32500 rm -f core conftest.err conftest.$ac_objext \
32502 if ${ac_cv_search_opendir+:} false; then :
32506 if ${ac_cv_search_opendir+:} false; then :
32509 ac_cv_search_opendir=no
32511 rm conftest.$ac_ext
32512 LIBS=$ac_func_search_save_LIBS
32514 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
32515 printf "%s\n" "$ac_cv_search_opendir" >&6; }
32516 ac_res=$ac_cv_search_opendir
32517 if test "$ac_res" != no; then :
32518 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
32524 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
32525 printf %s "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
32526 if ${ac_cv_header_sys_wait_h+:} false; then :
32527 printf %s "(cached) " >&6
32529 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32530 /* end confdefs.h. */
32531 #include <sys/types.h>
32532 #include <sys/wait.h>
32533 #ifndef WEXITSTATUS
32534 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
32537 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
32545 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
32550 if ac_fn_c_try_compile "$LINENO"; then :
32551 ac_cv_header_sys_wait_h=yes
32553 ac_cv_header_sys_wait_h=no
32555 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32557 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
32558 printf "%s\n" "$ac_cv_header_sys_wait_h" >&6; }
32559 if test $ac_cv_header_sys_wait_h = yes; then
32561 printf "%s\n" "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
32565 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
32566 if test "x$ac_cv_type_pid_t" = xyes; then :
32570 cat >>confdefs.h <<_ACEOF
32584 if test $ac_cv_func_sigprocmask = no; then
32585 for ac_func in sigblock
32587 ac_fn_c_check_func "$LINENO" "sigblock" "ac_cv_func_sigblock"
32588 if test "x$ac_cv_func_sigblock" = xyes; then :
32589 cat >>confdefs.h <<_ACEOF
32590 #define HAVE_SIGBLOCK 1
32597 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether closedir returns void" >&5
32598 printf %s "checking whether closedir returns void... " >&6; }
32599 if ${ac_cv_func_closedir_void+:} false; then :
32600 printf %s "(cached) " >&6
32602 if test "$cross_compiling" = yes; then :
32603 ac_cv_func_closedir_void=yes
32605 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32606 /* end confdefs.h. */
32607 $ac_includes_default
32608 #include <$ac_header_dirent>
32609 #ifndef __cplusplus
32616 return closedir (opendir (".")) != 0;
32621 if ac_fn_c_try_run "$LINENO"; then :
32622 ac_cv_func_closedir_void=no
32624 ac_cv_func_closedir_void=yes
32626 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
32627 conftest.$ac_objext conftest.beam conftest.$ac_ext
32631 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_closedir_void" >&5
32632 printf "%s\n" "$ac_cv_func_closedir_void" >&6; }
32633 if test $ac_cv_func_closedir_void = yes; then
32635 printf "%s\n" "#define CLOSEDIR_VOID 1" >>confdefs.h
32639 for ac_header in vfork.h
32641 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
32642 if test "x$ac_cv_header_vfork_h" = xyes; then :
32643 cat >>confdefs.h <<_ACEOF
32644 #define HAVE_VFORK_H 1
32651 for ac_func in fork vfork
32653 as_ac_var=`printf "%s\n" "ac_cv_func_$ac_func" | $as_tr_sh`
32654 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
32655 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
32656 cat >>confdefs.h <<_ACEOF
32657 #define `printf "%s\n" "HAVE_$ac_func" | $as_tr_cpp` 1
32663 if test "x$ac_cv_func_fork" = xyes; then
32664 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
32665 printf %s "checking for working fork... " >&6; }
32666 if ${ac_cv_func_fork_works+:} false; then :
32667 printf %s "(cached) " >&6
32669 if test "$cross_compiling" = yes; then :
32670 ac_cv_func_fork_works=cross
32672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32673 /* end confdefs.h. */
32674 $ac_includes_default
32679 /* By Ruediger Kuhlmann. */
32680 return fork () < 0;
32686 if ac_fn_c_try_run "$LINENO"; then :
32687 ac_cv_func_fork_works=yes
32689 ac_cv_func_fork_works=no
32691 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
32692 conftest.$ac_objext conftest.beam conftest.$ac_ext
32696 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
32697 printf "%s\n" "$ac_cv_func_fork_works" >&6; }
32700 ac_cv_func_fork_works=$ac_cv_func_fork
32702 if test "x$ac_cv_func_fork_works" = xcross; then
32704 *-*-amigaos* | *-*-msdosdjgpp*)
32705 # Override, as these systems have only a dummy fork() stub
32706 ac_cv_func_fork_works=no
32709 ac_cv_func_fork_works=yes
32712 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
32713 printf "%s\n" "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
32715 ac_cv_func_vfork_works=$ac_cv_func_vfork
32716 if test "x$ac_cv_func_vfork" = xyes; then
32717 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
32718 printf %s "checking for working vfork... " >&6; }
32719 if ${ac_cv_func_vfork_works+:} false; then :
32720 printf %s "(cached) " >&6
32722 if test "$cross_compiling" = yes; then :
32723 ac_cv_func_vfork_works=cross
32725 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32726 /* end confdefs.h. */
32727 /* Thanks to Paul Eggert for this test. */
32728 $ac_includes_default
32729 #include <signal.h>
32730 #include <sys/wait.h>
32731 #ifdef HAVE_VFORK_H
32732 # include <vfork.h>
32736 do_nothing (int sig)
32741 /* On some sparc systems, changes by the child to local and incoming
32742 argument registers are propagated back to the parent. The compiler
32743 is told about this with #include <vfork.h>, but some compilers
32744 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
32745 static variable whose address is put into a register that is
32746 clobbered by the vfork. */
32748 sparc_address_test (int arg)
32750 static pid_t child;
32768 pid_t parent = getpid ();
32771 sparc_address_test (0);
32773 /* On Solaris 2.4, changes by the child to the signal handler
32774 also munge signal handlers in the parent. To detect this,
32775 start by putting the parent's handler in a known state. */
32776 signal (SIGTERM, SIG_DFL);
32781 /* Here is another test for sparc vfork register problems. This
32782 test uses lots of local variables, at least as many local
32783 variables as main has allocated so far including compiler
32784 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
32785 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
32786 reuse the register of parent for one of the local variables,
32787 since it will think that parent can't possibly be used any more
32788 in this routine. Assigning to the local variable will thus
32789 munge parent in the parent process. */
32791 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
32792 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
32793 /* Convince the compiler that p..p7 are live; otherwise, it might
32794 use the same hardware register for all 8 local variables. */
32795 if (p != p1 || p != p2 || p != p3 || p != p4
32796 || p != p5 || p != p6 || p != p7)
32799 /* Alter the child's signal handler. */
32800 if (signal (SIGTERM, do_nothing) != SIG_DFL)
32803 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
32804 from child file descriptors. If the child closes a descriptor
32805 before it execs or exits, this munges the parent's descriptor
32806 as well. Test for this by closing stdout in the child. */
32807 _exit(close(fileno(stdout)) != 0);
32812 while (wait(&status) != child)
32815 /* Was there some problem with vforking? */
32818 /* Did the child munge the parent's signal handler? */
32819 || signal (SIGTERM, SIG_DFL) != SIG_DFL
32821 /* Did the child fail? (This shouldn't happen.) */
32824 /* Did the vfork/compiler bug occur? */
32825 || parent != getpid()
32827 /* Did the file descriptor bug occur? */
32828 || fstat(fileno(stdout), &st) != 0
32833 if ac_fn_c_try_run "$LINENO"; then :
32834 ac_cv_func_vfork_works=yes
32836 ac_cv_func_vfork_works=no
32838 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
32839 conftest.$ac_objext conftest.beam conftest.$ac_ext
32843 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
32844 printf "%s\n" "$ac_cv_func_vfork_works" >&6; }
32847 if test "x$ac_cv_func_fork_works" = xcross; then
32848 ac_cv_func_vfork_works=$ac_cv_func_vfork
32849 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
32850 printf "%s\n" "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
32853 if test "x$ac_cv_func_vfork_works" = xyes; then
32855 printf "%s\n" "#define HAVE_WORKING_VFORK 1" >>confdefs.h
32859 printf "%s\n" "#define vfork fork" >>confdefs.h
32862 if test "x$ac_cv_func_fork_works" = xyes; then
32864 printf "%s\n" "#define HAVE_WORKING_FORK 1" >>confdefs.h
32869 # When .tarball-version exists, we're building from a tarball
32870 # and must not make man/*.1 files depend on the generated src/version.c,
32871 # because that would induce a requirement to run the help2man perl script.
32872 # We are not yet prepared to make perl a build-from-tarball requirement.
32873 # Hence, here we detect .tarball-version existence. When not present,
32874 # we define a variable to be used in man/Makefile.am to induce the
32875 # proper dependency (so that man/*.1 will be rebuilt upon any version change),
32876 # but not when built from a tarball.
32878 test -f $srcdir/.tarball-version \
32879 && SRC_VERSION_C= \
32880 || SRC_VERSION_C=../src/version.c
32883 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
32884 printf %s "checking whether NLS is requested... " >&6; }
32885 # Check whether --enable-nls was given.
32886 if test "${enable_nls+set}" = set; then :
32887 enableval=$enable_nls; USE_NLS=$enableval
32892 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
32893 printf "%s\n" "$USE_NLS" >&6; }
32898 GETTEXT_MACRO_VERSION=0.18
32903 # Prepare PATH_SEPARATOR.
32904 # The user is always right.
32905 if test "${PATH_SEPARATOR+set}" != set; then
32906 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
32907 # contains only /bin. Note that ksh looks also at the FPATH variable,
32908 # so we have to set that as well for the test.
32910 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
32911 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
32912 || PATH_SEPARATOR=';'
32916 # Find out how to test for executable files. Don't use a zero-byte file,
32917 # as systems may use methods other than mode bits to determine executability.
32918 cat >conf$$.file <<_ASEOF
32922 chmod +x conf$$.file
32923 if test -x conf$$.file >/dev/null 2>&1; then
32924 ac_executable_p="test -x"
32926 ac_executable_p="test -f"
32930 # Extract the first word of "msgfmt", so it can be a program name with args.
32931 set dummy msgfmt; ac_word=$2
32932 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32933 printf %s "checking for $ac_word... " >&6; }
32934 if ${ac_cv_path_MSGFMT+:} false; then :
32935 printf %s "(cached) " >&6
32939 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
32942 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
32943 for ac_dir in $PATH; do
32945 test -z "$ac_dir" && ac_dir=.
32946 for ac_exec_ext in '' $ac_executable_extensions; do
32947 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
32948 echo "$as_me: trying $ac_dir/$ac_word..." >&5
32949 if $ac_dir/$ac_word --statistics /dev/null >&5 2>&1 &&
32950 (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
32951 ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
32958 test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
32962 MSGFMT="$ac_cv_path_MSGFMT"
32963 if test "$MSGFMT" != ":"; then
32964 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
32965 printf "%s\n" "$MSGFMT" >&6; }
32967 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
32968 printf "%s\n" "no" >&6; }
32971 # Extract the first word of "gmsgfmt", so it can be a program name with args.
32972 set dummy gmsgfmt; ac_word=$2
32973 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32974 printf %s "checking for $ac_word... " >&6; }
32975 if ${ac_cv_path_GMSGFMT+:} false; then :
32976 printf %s "(cached) " >&6
32980 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
32983 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32984 for as_dir in $PATH
32987 case $as_dir in #(((
32990 *) as_dir=$as_dir/ ;;
32992 for ac_exec_ext in '' $ac_executable_extensions; do
32993 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
32994 ac_cv_path_GMSGFMT="$as_dir$ac_word$ac_exec_ext"
32995 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
33002 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
33006 GMSGFMT=$ac_cv_path_GMSGFMT
33007 if test -n "$GMSGFMT"; then
33008 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
33009 printf "%s\n" "$GMSGFMT" >&6; }
33011 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
33012 printf "%s\n" "no" >&6; }
33017 case `$MSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
33018 '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) MSGFMT_015=: ;;
33019 *) MSGFMT_015=$MSGFMT ;;
33022 case `$GMSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
33023 '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) GMSGFMT_015=: ;;
33024 *) GMSGFMT_015=$GMSGFMT ;;
33029 # Prepare PATH_SEPARATOR.
33030 # The user is always right.
33031 if test "${PATH_SEPARATOR+set}" != set; then
33032 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
33033 # contains only /bin. Note that ksh looks also at the FPATH variable,
33034 # so we have to set that as well for the test.
33036 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
33037 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
33038 || PATH_SEPARATOR=';'
33042 # Find out how to test for executable files. Don't use a zero-byte file,
33043 # as systems may use methods other than mode bits to determine executability.
33044 cat >conf$$.file <<_ASEOF
33048 chmod +x conf$$.file
33049 if test -x conf$$.file >/dev/null 2>&1; then
33050 ac_executable_p="test -x"
33052 ac_executable_p="test -f"
33056 # Extract the first word of "xgettext", so it can be a program name with args.
33057 set dummy xgettext; ac_word=$2
33058 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33059 printf %s "checking for $ac_word... " >&6; }
33060 if ${ac_cv_path_XGETTEXT+:} false; then :
33061 printf %s "(cached) " >&6
33063 case "$XGETTEXT" in
33065 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
33068 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
33069 for ac_dir in $PATH; do
33071 test -z "$ac_dir" && ac_dir=.
33072 for ac_exec_ext in '' $ac_executable_extensions; do
33073 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
33074 echo "$as_me: trying $ac_dir/$ac_word..." >&5
33075 if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >&5 2>&1 &&
33076 (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
33077 ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
33084 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
33088 XGETTEXT="$ac_cv_path_XGETTEXT"
33089 if test "$XGETTEXT" != ":"; then
33090 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
33091 printf "%s\n" "$XGETTEXT" >&6; }
33093 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
33094 printf "%s\n" "no" >&6; }
33099 case `$XGETTEXT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
33100 '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) XGETTEXT_015=: ;;
33101 *) XGETTEXT_015=$XGETTEXT ;;
33106 # Prepare PATH_SEPARATOR.
33107 # The user is always right.
33108 if test "${PATH_SEPARATOR+set}" != set; then
33109 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
33110 # contains only /bin. Note that ksh looks also at the FPATH variable,
33111 # so we have to set that as well for the test.
33113 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
33114 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
33115 || PATH_SEPARATOR=';'
33119 # Find out how to test for executable files. Don't use a zero-byte file,
33120 # as systems may use methods other than mode bits to determine executability.
33121 cat >conf$$.file <<_ASEOF
33125 chmod +x conf$$.file
33126 if test -x conf$$.file >/dev/null 2>&1; then
33127 ac_executable_p="test -x"
33129 ac_executable_p="test -f"
33133 # Extract the first word of "msgmerge", so it can be a program name with args.
33134 set dummy msgmerge; ac_word=$2
33135 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33136 printf %s "checking for $ac_word... " >&6; }
33137 if ${ac_cv_path_MSGMERGE+:} false; then :
33138 printf %s "(cached) " >&6
33140 case "$MSGMERGE" in
33142 ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
33145 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
33146 for ac_dir in $PATH; do
33148 test -z "$ac_dir" && ac_dir=.
33149 for ac_exec_ext in '' $ac_executable_extensions; do
33150 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
33151 echo "$as_me: trying $ac_dir/$ac_word..." >&5
33152 if $ac_dir/$ac_word --update -q /dev/null /dev/null >&5 2>&1; then
33153 ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
33160 test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
33164 MSGMERGE="$ac_cv_path_MSGMERGE"
33165 if test "$MSGMERGE" != ":"; then
33166 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
33167 printf "%s\n" "$MSGMERGE" >&6; }
33169 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
33170 printf "%s\n" "no" >&6; }
33174 test -n "$localedir" || localedir='${datadir}/locale'
33177 test -n "${XGETTEXT_EXTRA_OPTIONS+set}" || XGETTEXT_EXTRA_OPTIONS=
33180 ac_config_commands="$ac_config_commands po-directories"
33207 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5
33208 printf %s "checking for CFPreferencesCopyAppValue... " >&6; }
33209 if ${gt_cv_func_CFPreferencesCopyAppValue+:} false; then :
33210 printf %s "(cached) " >&6
33212 gt_save_LIBS="$LIBS"
33213 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
33214 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33215 /* end confdefs.h. */
33216 #include <CoreFoundation/CFPreferences.h>
33220 CFPreferencesCopyAppValue(NULL, NULL)
33225 if ac_fn_c_try_link "$LINENO"; then :
33226 gt_cv_func_CFPreferencesCopyAppValue=yes
33228 gt_cv_func_CFPreferencesCopyAppValue=no
33230 rm -f core conftest.err conftest.$ac_objext \
33231 conftest$ac_exeext conftest.$ac_ext
33232 LIBS="$gt_save_LIBS"
33234 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5
33235 printf "%s\n" "$gt_cv_func_CFPreferencesCopyAppValue" >&6; }
33236 if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
33238 printf "%s\n" "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h
33241 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyCurrent" >&5
33242 printf %s "checking for CFLocaleCopyCurrent... " >&6; }
33243 if ${gt_cv_func_CFLocaleCopyCurrent+:} false; then :
33244 printf %s "(cached) " >&6
33246 gt_save_LIBS="$LIBS"
33247 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
33248 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33249 /* end confdefs.h. */
33250 #include <CoreFoundation/CFLocale.h>
33254 CFLocaleCopyCurrent();
33259 if ac_fn_c_try_link "$LINENO"; then :
33260 gt_cv_func_CFLocaleCopyCurrent=yes
33262 gt_cv_func_CFLocaleCopyCurrent=no
33264 rm -f core conftest.err conftest.$ac_objext \
33265 conftest$ac_exeext conftest.$ac_ext
33266 LIBS="$gt_save_LIBS"
33268 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyCurrent" >&5
33269 printf "%s\n" "$gt_cv_func_CFLocaleCopyCurrent" >&6; }
33270 if test $gt_cv_func_CFLocaleCopyCurrent = yes; then
33272 printf "%s\n" "#define HAVE_CFLOCALECOPYCURRENT 1" >>confdefs.h
33276 if test $gt_cv_func_CFPreferencesCopyAppValue = yes || test $gt_cv_func_CFLocaleCopyCurrent = yes; then
33277 INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation"
33289 case " $gt_needs " in
33290 *" need-formatstring-macros "*) gt_api_version=3 ;;
33291 *" need-ngettext "*) gt_api_version=2 ;;
33292 *) gt_api_version=1 ;;
33294 gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc"
33295 gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl"
33297 if test "$USE_NLS" = "yes"; then
33298 gt_use_preinstalled_gnugettext=no
33301 if test $gt_api_version -ge 3; then
33302 gt_revision_test_code='
33303 #ifndef __GNU_GETTEXT_SUPPORTED_REVISION
33304 #define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
33306 typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
33309 gt_revision_test_code=
33311 if test $gt_api_version -ge 2; then
33312 gt_expression_test_code=' + * ngettext ("", "", 0)'
33314 gt_expression_test_code=
33317 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5
33318 printf %s "checking for GNU gettext in libc... " >&6; }
33319 if eval \${$gt_func_gnugettext_libc+:} false; then :
33320 printf %s "(cached) " >&6
33322 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33323 /* end confdefs.h. */
33325 #include <libintl.h>
33326 $gt_revision_test_code
33327 extern int _nl_msg_cat_cntr;
33328 extern int *_nl_domain_bindings;
33334 bindtextdomain ("", "");
33335 return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_domain_bindings
33341 if ac_fn_c_try_link "$LINENO"; then :
33342 eval "$gt_func_gnugettext_libc=yes"
33344 eval "$gt_func_gnugettext_libc=no"
33346 rm -f core conftest.err conftest.$ac_objext \
33347 conftest$ac_exeext conftest.$ac_ext
33349 eval ac_res=\$$gt_func_gnugettext_libc
33350 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
33351 printf "%s\n" "$ac_res" >&6; }
33353 if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
33359 am_save_CPPFLAGS="$CPPFLAGS"
33361 for element in $INCICONV; do
33363 for x in $CPPFLAGS; do
33365 acl_save_prefix="$prefix"
33366 prefix="$acl_final_prefix"
33367 acl_save_exec_prefix="$exec_prefix"
33368 exec_prefix="$acl_final_exec_prefix"
33370 exec_prefix="$acl_save_exec_prefix"
33371 prefix="$acl_save_prefix"
33373 if test "X$x" = "X$element"; then
33378 if test -z "$haveit"; then
33379 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
33384 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
33385 printf %s "checking for iconv... " >&6; }
33386 if ${am_cv_func_iconv+:} false; then :
33387 printf %s "(cached) " >&6
33390 am_cv_func_iconv="no, consider installing GNU libiconv"
33392 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33393 /* end confdefs.h. */
33395 #include <stdlib.h>
33401 iconv_t cd = iconv_open("","");
33402 iconv(cd,NULL,NULL,NULL,NULL);
33408 if ac_fn_c_try_link "$LINENO"; then :
33409 am_cv_func_iconv=yes
33411 rm -f core conftest.err conftest.$ac_objext \
33412 conftest$ac_exeext conftest.$ac_ext
33413 if test "$am_cv_func_iconv" != yes; then
33414 am_save_LIBS="$LIBS"
33415 LIBS="$LIBS $LIBICONV"
33416 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33417 /* end confdefs.h. */
33419 #include <stdlib.h>
33425 iconv_t cd = iconv_open("","");
33426 iconv(cd,NULL,NULL,NULL,NULL);
33432 if ac_fn_c_try_link "$LINENO"; then :
33433 am_cv_lib_iconv=yes
33434 am_cv_func_iconv=yes
33436 rm -f core conftest.err conftest.$ac_objext \
33437 conftest$ac_exeext conftest.$ac_ext
33438 LIBS="$am_save_LIBS"
33442 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
33443 printf "%s\n" "$am_cv_func_iconv" >&6; }
33444 if test "$am_cv_func_iconv" = yes; then
33445 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
33446 printf %s "checking for working iconv... " >&6; }
33447 if ${am_cv_func_iconv_works+:} false; then :
33448 printf %s "(cached) " >&6
33451 am_save_LIBS="$LIBS"
33452 if test $am_cv_lib_iconv = yes; then
33453 LIBS="$LIBS $LIBICONV"
33455 if test "$cross_compiling" = yes; then :
33458 aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
33459 *) am_cv_func_iconv_works="guessing yes" ;;
33463 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33464 /* end confdefs.h. */
33467 #include <string.h>
33471 /* Test against AIX 5.1 bug: Failures are not distinguishable from successful
33474 iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
33475 if (cd_utf8_to_88591 != (iconv_t)(-1))
33477 static const char input[] = "\342\202\254"; /* EURO SIGN */
33479 const char *inptr = input;
33480 size_t inbytesleft = strlen (input);
33481 char *outptr = buf;
33482 size_t outbytesleft = sizeof (buf);
33483 size_t res = iconv (cd_utf8_to_88591,
33484 (char **) &inptr, &inbytesleft,
33485 &outptr, &outbytesleft);
33488 iconv_close (cd_utf8_to_88591);
33491 /* Test against Solaris 10 bug: Failures are not distinguishable from
33492 successful returns. */
33494 iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
33495 if (cd_ascii_to_88591 != (iconv_t)(-1))
33497 static const char input[] = "\263";
33499 const char *inptr = input;
33500 size_t inbytesleft = strlen (input);
33501 char *outptr = buf;
33502 size_t outbytesleft = sizeof (buf);
33503 size_t res = iconv (cd_ascii_to_88591,
33504 (char **) &inptr, &inbytesleft,
33505 &outptr, &outbytesleft);
33508 iconv_close (cd_ascii_to_88591);
33511 /* Test against AIX 6.1..7.1 bug: Buffer overrun. */
33513 iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1");
33514 if (cd_88591_to_utf8 != (iconv_t)(-1))
33516 static const char input[] = "\304";
33517 static char buf[2] = { (char)0xDE, (char)0xAD };
33518 const char *inptr = input;
33519 size_t inbytesleft = 1;
33520 char *outptr = buf;
33521 size_t outbytesleft = 1;
33522 size_t res = iconv (cd_88591_to_utf8,
33523 (char **) &inptr, &inbytesleft,
33524 &outptr, &outbytesleft);
33525 if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD)
33527 iconv_close (cd_88591_to_utf8);
33530 #if 0 /* This bug could be worked around by the caller. */
33531 /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */
33533 iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
33534 if (cd_88591_to_utf8 != (iconv_t)(-1))
33536 static const char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
33538 const char *inptr = input;
33539 size_t inbytesleft = strlen (input);
33540 char *outptr = buf;
33541 size_t outbytesleft = sizeof (buf);
33542 size_t res = iconv (cd_88591_to_utf8,
33543 (char **) &inptr, &inbytesleft,
33544 &outptr, &outbytesleft);
33547 iconv_close (cd_88591_to_utf8);
33551 /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
33553 if (/* Try standardized names. */
33554 iconv_open ("UTF-8", "EUC-JP") == (iconv_t)(-1)
33555 /* Try IRIX, OSF/1 names. */
33556 && iconv_open ("UTF-8", "eucJP") == (iconv_t)(-1)
33557 /* Try AIX names. */
33558 && iconv_open ("UTF-8", "IBM-eucJP") == (iconv_t)(-1)
33559 /* Try HP-UX names. */
33560 && iconv_open ("utf8", "eucJP") == (iconv_t)(-1))
33565 if ac_fn_c_try_run "$LINENO"; then :
33566 am_cv_func_iconv_works=yes
33568 am_cv_func_iconv_works=no
33570 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
33571 conftest.$ac_objext conftest.beam conftest.$ac_ext
33574 LIBS="$am_save_LIBS"
33577 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5
33578 printf "%s\n" "$am_cv_func_iconv_works" >&6; }
33579 case "$am_cv_func_iconv_works" in
33580 *no) am_func_iconv=no am_cv_lib_iconv=no ;;
33581 *) am_func_iconv=yes ;;
33584 am_func_iconv=no am_cv_lib_iconv=no
33586 if test "$am_func_iconv" = yes; then
33588 printf "%s\n" "#define HAVE_ICONV 1" >>confdefs.h
33591 if test "$am_cv_lib_iconv" = yes; then
33592 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
33593 printf %s "checking how to link with libiconv... " >&6; }
33594 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
33595 printf "%s\n" "$LIBICONV" >&6; }
33597 CPPFLAGS="$am_save_CPPFLAGS"
33614 acl_save_prefix="$prefix"
33615 prefix="$acl_final_prefix"
33616 acl_save_exec_prefix="$exec_prefix"
33617 exec_prefix="$acl_final_exec_prefix"
33619 eval additional_includedir=\"$includedir\"
33620 eval additional_libdir=\"$libdir\"
33622 exec_prefix="$acl_save_exec_prefix"
33623 prefix="$acl_save_prefix"
33626 # Check whether --with-libintl-prefix was given.
33627 if test "${with_libintl_prefix+set}" = set; then :
33628 withval=$with_libintl_prefix;
33629 if test "X$withval" = "Xno"; then
33632 if test "X$withval" = "X"; then
33634 acl_save_prefix="$prefix"
33635 prefix="$acl_final_prefix"
33636 acl_save_exec_prefix="$exec_prefix"
33637 exec_prefix="$acl_final_exec_prefix"
33639 eval additional_includedir=\"$includedir\"
33640 eval additional_libdir=\"$libdir\"
33642 exec_prefix="$acl_save_exec_prefix"
33643 prefix="$acl_save_prefix"
33646 additional_includedir="$withval/include"
33647 additional_libdir="$withval/$acl_libdirstem"
33648 if test "$acl_libdirstem2" != "$acl_libdirstem" \
33649 && ! test -d "$withval/$acl_libdirstem"; then
33650 additional_libdir="$withval/$acl_libdirstem2"
33664 names_already_handled=
33665 names_next_round='intl '
33666 while test -n "$names_next_round"; do
33667 names_this_round="$names_next_round"
33669 for name in $names_this_round; do
33671 for n in $names_already_handled; do
33672 if test "$n" = "$name"; then
33673 already_handled=yes
33677 if test -z "$already_handled"; then
33678 names_already_handled="$names_already_handled $name"
33679 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./+-|ABCDEFGHIJKLMNOPQRSTUVWXYZ____|'`
33680 eval value=\"\$HAVE_LIB$uppername\"
33681 if test -n "$value"; then
33682 if test "$value" = yes; then
33683 eval value=\"\$LIB$uppername\"
33684 test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value"
33685 eval value=\"\$LTLIB$uppername\"
33686 test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value"
33695 eval libname=\"$acl_libname_spec\" # typically: libname=lib$name
33696 if test -n "$acl_shlibext"; then
33697 shrext=".$acl_shlibext" # typically: shrext=.so
33701 if test $use_additional = yes; then
33702 dir="$additional_libdir"
33703 if test -n "$acl_shlibext"; then
33704 if test -f "$dir/$libname$shrext"; then
33706 found_so="$dir/$libname$shrext"
33708 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
33709 ver=`(cd "$dir" && \
33710 for f in "$libname$shrext".*; do echo "$f"; done \
33711 | sed -e "s,^$libname$shrext\\\\.,," \
33712 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
33713 | sed 1q ) 2>/dev/null`
33714 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
33716 found_so="$dir/$libname$shrext.$ver"
33719 eval library_names=\"$acl_library_names_spec\"
33720 for f in $library_names; do
33721 if test -f "$dir/$f"; then
33730 if test "X$found_dir" = "X"; then
33731 if test -f "$dir/$libname.$acl_libext"; then
33733 found_a="$dir/$libname.$acl_libext"
33736 if test "X$found_dir" != "X"; then
33737 if test -f "$dir/$libname.la"; then
33738 found_la="$dir/$libname.la"
33742 if test "X$found_dir" = "X"; then
33743 for x in $LDFLAGS $LTLIBINTL; do
33745 acl_save_prefix="$prefix"
33746 prefix="$acl_final_prefix"
33747 acl_save_exec_prefix="$exec_prefix"
33748 exec_prefix="$acl_final_exec_prefix"
33750 exec_prefix="$acl_save_exec_prefix"
33751 prefix="$acl_save_prefix"
33755 dir=`echo "X$x" | sed -e 's/^X-L//'`
33756 if test -n "$acl_shlibext"; then
33757 if test -f "$dir/$libname$shrext"; then
33759 found_so="$dir/$libname$shrext"
33761 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
33762 ver=`(cd "$dir" && \
33763 for f in "$libname$shrext".*; do echo "$f"; done \
33764 | sed -e "s,^$libname$shrext\\\\.,," \
33765 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
33766 | sed 1q ) 2>/dev/null`
33767 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
33769 found_so="$dir/$libname$shrext.$ver"
33772 eval library_names=\"$acl_library_names_spec\"
33773 for f in $library_names; do
33774 if test -f "$dir/$f"; then
33783 if test "X$found_dir" = "X"; then
33784 if test -f "$dir/$libname.$acl_libext"; then
33786 found_a="$dir/$libname.$acl_libext"
33789 if test "X$found_dir" != "X"; then
33790 if test -f "$dir/$libname.la"; then
33791 found_la="$dir/$libname.la"
33796 if test "X$found_dir" != "X"; then
33801 if test "X$found_dir" != "X"; then
33802 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name"
33803 if test "X$found_so" != "X"; then
33804 if test "$enable_rpath" = no \
33805 || test "X$found_dir" = "X/usr/$acl_libdirstem" \
33806 || test "X$found_dir" = "X/usr/$acl_libdirstem2"; then
33807 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
33810 for x in $ltrpathdirs; do
33811 if test "X$x" = "X$found_dir"; then
33816 if test -z "$haveit"; then
33817 ltrpathdirs="$ltrpathdirs $found_dir"
33819 if test "$acl_hardcode_direct" = yes; then
33820 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
33822 if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
33823 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
33825 for x in $rpathdirs; do
33826 if test "X$x" = "X$found_dir"; then
33831 if test -z "$haveit"; then
33832 rpathdirs="$rpathdirs $found_dir"
33836 for x in $LDFLAGS $LIBINTL; do
33838 acl_save_prefix="$prefix"
33839 prefix="$acl_final_prefix"
33840 acl_save_exec_prefix="$exec_prefix"
33841 exec_prefix="$acl_final_exec_prefix"
33843 exec_prefix="$acl_save_exec_prefix"
33844 prefix="$acl_save_prefix"
33846 if test "X$x" = "X-L$found_dir"; then
33851 if test -z "$haveit"; then
33852 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir"
33854 if test "$acl_hardcode_minus_L" != no; then
33855 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
33857 LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
33863 if test "X$found_a" != "X"; then
33864 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a"
33866 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name"
33869 additional_includedir=
33870 case "$found_dir" in
33871 */$acl_libdirstem | */$acl_libdirstem/)
33872 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
33873 if test "$name" = 'intl'; then
33874 LIBINTL_PREFIX="$basedir"
33876 additional_includedir="$basedir/include"
33878 */$acl_libdirstem2 | */$acl_libdirstem2/)
33879 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
33880 if test "$name" = 'intl'; then
33881 LIBINTL_PREFIX="$basedir"
33883 additional_includedir="$basedir/include"
33886 if test "X$additional_includedir" != "X"; then
33887 if test "X$additional_includedir" != "X/usr/include"; then
33889 if test "X$additional_includedir" = "X/usr/local/include"; then
33890 if test -n "$GCC"; then
33892 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
33896 if test -z "$haveit"; then
33897 for x in $CPPFLAGS $INCINTL; do
33899 acl_save_prefix="$prefix"
33900 prefix="$acl_final_prefix"
33901 acl_save_exec_prefix="$exec_prefix"
33902 exec_prefix="$acl_final_exec_prefix"
33904 exec_prefix="$acl_save_exec_prefix"
33905 prefix="$acl_save_prefix"
33907 if test "X$x" = "X-I$additional_includedir"; then
33912 if test -z "$haveit"; then
33913 if test -d "$additional_includedir"; then
33914 INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir"
33920 if test -n "$found_la"; then
33921 save_libdir="$libdir"
33922 case "$found_la" in
33923 */* | *\\*) . "$found_la" ;;
33924 *) . "./$found_la" ;;
33926 libdir="$save_libdir"
33927 for dep in $dependency_libs; do
33930 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
33931 if test "X$additional_libdir" != "X/usr/$acl_libdirstem" \
33932 && test "X$additional_libdir" != "X/usr/$acl_libdirstem2"; then
33934 if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem" \
33935 || test "X$additional_libdir" = "X/usr/local/$acl_libdirstem2"; then
33936 if test -n "$GCC"; then
33938 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
33942 if test -z "$haveit"; then
33944 for x in $LDFLAGS $LIBINTL; do
33946 acl_save_prefix="$prefix"
33947 prefix="$acl_final_prefix"
33948 acl_save_exec_prefix="$exec_prefix"
33949 exec_prefix="$acl_final_exec_prefix"
33951 exec_prefix="$acl_save_exec_prefix"
33952 prefix="$acl_save_prefix"
33954 if test "X$x" = "X-L$additional_libdir"; then
33959 if test -z "$haveit"; then
33960 if test -d "$additional_libdir"; then
33961 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir"
33965 for x in $LDFLAGS $LTLIBINTL; do
33967 acl_save_prefix="$prefix"
33968 prefix="$acl_final_prefix"
33969 acl_save_exec_prefix="$exec_prefix"
33970 exec_prefix="$acl_final_exec_prefix"
33972 exec_prefix="$acl_save_exec_prefix"
33973 prefix="$acl_save_prefix"
33975 if test "X$x" = "X-L$additional_libdir"; then
33980 if test -z "$haveit"; then
33981 if test -d "$additional_libdir"; then
33982 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir"
33989 dir=`echo "X$dep" | sed -e 's/^X-R//'`
33990 if test "$enable_rpath" != no; then
33992 for x in $rpathdirs; do
33993 if test "X$x" = "X$dir"; then
33998 if test -z "$haveit"; then
33999 rpathdirs="$rpathdirs $dir"
34002 for x in $ltrpathdirs; do
34003 if test "X$x" = "X$dir"; then
34008 if test -z "$haveit"; then
34009 ltrpathdirs="$ltrpathdirs $dir"
34014 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
34017 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
34020 LIBINTL="${LIBINTL}${LIBINTL:+ }$dep"
34021 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep"
34027 LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
34028 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name"
34034 if test "X$rpathdirs" != "X"; then
34035 if test -n "$acl_hardcode_libdir_separator"; then
34037 for found_dir in $rpathdirs; do
34038 alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir"
34040 acl_save_libdir="$libdir"
34042 eval flag=\"$acl_hardcode_libdir_flag_spec\"
34043 libdir="$acl_save_libdir"
34044 LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
34046 for found_dir in $rpathdirs; do
34047 acl_save_libdir="$libdir"
34048 libdir="$found_dir"
34049 eval flag=\"$acl_hardcode_libdir_flag_spec\"
34050 libdir="$acl_save_libdir"
34051 LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
34055 if test "X$ltrpathdirs" != "X"; then
34056 for found_dir in $ltrpathdirs; do
34057 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir"
34066 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5
34067 printf %s "checking for GNU gettext in libintl... " >&6; }
34068 if eval \${$gt_func_gnugettext_libintl+:} false; then :
34069 printf %s "(cached) " >&6
34071 gt_save_CPPFLAGS="$CPPFLAGS"
34072 CPPFLAGS="$CPPFLAGS $INCINTL"
34073 gt_save_LIBS="$LIBS"
34074 LIBS="$LIBS $LIBINTL"
34075 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34076 /* end confdefs.h. */
34078 #include <libintl.h>
34079 $gt_revision_test_code
34080 extern int _nl_msg_cat_cntr;
34085 const char *_nl_expand_alias (const char *);
34091 bindtextdomain ("", "");
34092 return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_alias ("")
34098 if ac_fn_c_try_link "$LINENO"; then :
34099 eval "$gt_func_gnugettext_libintl=yes"
34101 eval "$gt_func_gnugettext_libintl=no"
34103 rm -f core conftest.err conftest.$ac_objext \
34104 conftest$ac_exeext conftest.$ac_ext
34105 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then
34106 LIBS="$LIBS $LIBICONV"
34107 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34108 /* end confdefs.h. */
34110 #include <libintl.h>
34111 $gt_revision_test_code
34112 extern int _nl_msg_cat_cntr;
34117 const char *_nl_expand_alias (const char *);
34123 bindtextdomain ("", "");
34124 return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_alias ("")
34130 if ac_fn_c_try_link "$LINENO"; then :
34131 LIBINTL="$LIBINTL $LIBICONV"
34132 LTLIBINTL="$LTLIBINTL $LTLIBICONV"
34133 eval "$gt_func_gnugettext_libintl=yes"
34136 rm -f core conftest.err conftest.$ac_objext \
34137 conftest$ac_exeext conftest.$ac_ext
34139 CPPFLAGS="$gt_save_CPPFLAGS"
34140 LIBS="$gt_save_LIBS"
34142 eval ac_res=\$$gt_func_gnugettext_libintl
34143 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
34144 printf "%s\n" "$ac_res" >&6; }
34147 if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \
34148 || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \
34149 && test "$PACKAGE" != gettext-runtime \
34150 && test "$PACKAGE" != gettext-tools; }; then
34151 gt_use_preinstalled_gnugettext=yes
34160 if test -n "$INTL_MACOSX_LIBS"; then
34161 if test "$gt_use_preinstalled_gnugettext" = "yes" \
34162 || test "$nls_cv_use_gnu_gettext" = "yes"; then
34163 LIBINTL="$LIBINTL $INTL_MACOSX_LIBS"
34164 LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS"
34168 if test "$gt_use_preinstalled_gnugettext" = "yes" \
34169 || test "$nls_cv_use_gnu_gettext" = "yes"; then
34171 printf "%s\n" "#define ENABLE_NLS 1" >>confdefs.h
34178 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5
34179 printf %s "checking whether to use NLS... " >&6; }
34180 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
34181 printf "%s\n" "$USE_NLS" >&6; }
34182 if test "$USE_NLS" = "yes"; then
34183 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5
34184 printf %s "checking where the gettext function comes from... " >&6; }
34185 if test "$gt_use_preinstalled_gnugettext" = "yes"; then
34186 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
34187 gt_source="external libintl"
34192 gt_source="included intl directory"
34194 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5
34195 printf "%s\n" "$gt_source" >&6; }
34198 if test "$USE_NLS" = "yes"; then
34200 if test "$gt_use_preinstalled_gnugettext" = "yes"; then
34201 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
34202 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5
34203 printf %s "checking how to link with libintl... " >&6; }
34204 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5
34205 printf "%s\n" "$LIBINTL" >&6; }
34207 for element in $INCINTL; do
34209 for x in $CPPFLAGS; do
34211 acl_save_prefix="$prefix"
34212 prefix="$acl_final_prefix"
34213 acl_save_exec_prefix="$exec_prefix"
34214 exec_prefix="$acl_final_exec_prefix"
34216 exec_prefix="$acl_save_exec_prefix"
34217 prefix="$acl_save_prefix"
34219 if test "X$x" = "X$element"; then
34224 if test -z "$haveit"; then
34225 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
34232 printf "%s\n" "#define HAVE_GETTEXT 1" >>confdefs.h
34235 printf "%s\n" "#define HAVE_DCGETTEXT 1" >>confdefs.h
34244 INTLLIBS="$LIBINTL"
34252 XGETTEXT="AWK='$AWK' \$(SHELL) \$(top_srcdir)/exgettext $XGETTEXT"
34254 ac_config_files="$ac_config_files Makefile doc/Makefile lib/Makefile src/Makefile tests/Makefile gnulib-tests/Makefile man/Makefile po/Makefile.in"
34256 cat >confcache <<\_ACEOF
34257 # This file is a shell script that caches the results of configure
34258 # tests run on this system so they can be shared between configure
34259 # scripts and configure runs, see configure's option --config-cache.
34260 # It is not useful on other systems. If it contains results you don't
34261 # want to keep, you may remove or edit it.
34263 # config.status only pays attention to the cache file if you give it
34264 # the --recheck option to rerun configure.
34266 # `ac_cv_env_foo' variables (set or unset) will be overridden when
34267 # loading this file, other *unset* `ac_cv_foo' will be assigned the
34268 # following values.
34272 # The following way of writing the cache mishandles newlines in values,
34273 # but we know of no workaround that is simple, portable, and efficient.
34274 # So, we kill variables containing newlines.
34275 # Ultrix sh set writes to stderr and can't be redirected directly,
34276 # and sets the high bit in the cache file unless we assign to the vars.
34278 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
34279 eval ac_val=\$$ac_var
34283 *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
34284 printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
34287 _ | IFS | as_nl) ;; #(
34288 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
34289 *) { eval $ac_var=; unset $ac_var;} ;;
34295 case $as_nl`(ac_space=' '; set) 2>&1` in #(
34296 *${as_nl}ac_space=\ *)
34297 # `set' does not quote correctly, so add quotes: double-quote
34298 # substitution turns \\\\ into \\, and sed turns \\ into \.
34301 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
34304 # `set' quotes correctly as required by POSIX, so do not add quotes.
34305 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
34314 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
34316 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
34318 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
34319 if test -w "$cache_file"; then
34320 if test "x$cache_file" != "x/dev/null"; then
34321 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
34322 printf "%s\n" "$as_me: updating cache $cache_file" >&6;}
34323 if test ! -f "$cache_file" || test -h "$cache_file"; then
34324 cat confcache >"$cache_file"
34326 case $cache_file in #(
34328 mv -f confcache "$cache_file"$$ &&
34329 mv -f "$cache_file"$$ "$cache_file" ;; #(
34331 mv -f confcache "$cache_file" ;;
34336 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
34337 printf "%s\n" "$as_me: not updating unwritable cache $cache_file" >&6;}
34342 test "x$prefix" = xNONE && prefix=$ac_default_prefix
34343 # Let make expand exec_prefix.
34344 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
34346 DEFS=-DHAVE_CONFIG_H
34351 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
34352 # 1. Remove the extension, and $U if already installed.
34353 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
34354 ac_i=`printf "%s\n" "$ac_i" | sed "$ac_script"`
34355 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
34356 # will be set to the directory where LIBOBJS objects are built.
34357 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
34358 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
34360 LIBOBJS=$ac_libobjs
34362 LTLIBOBJS=$ac_ltlibobjs
34365 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
34366 printf %s "checking that generated files are newer than configure... " >&6; }
34367 if test -n "$am_sleep_pid"; then
34368 # Hide warnings about reused PIDs.
34369 wait $am_sleep_pid 2>/dev/null
34371 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: done" >&5
34372 printf "%s\n" "done" >&6; }
34373 if test -n "$EXEEXT"; then
34375 am__EXEEXT_FALSE='#'
34377 am__EXEEXT_TRUE='#'
34381 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
34382 as_fn_error $? "conditional \"AMDEP\" was never defined.
34383 Usually this means the macro was only invoked conditionally." "$LINENO" 5
34385 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
34386 as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
34387 Usually this means the macro was only invoked conditionally." "$LINENO" 5
34389 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
34390 as_fn_error $? "conditional \"GL_COND_LIBTOOL\" was never defined.
34391 Usually this means the macro was only invoked conditionally." "$LINENO" 5
34393 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
34394 as_fn_error $? "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
34395 Usually this means the macro was only invoked conditionally." "$LINENO" 5
34397 test "X$DEFS" = X-DHAVE_CONFIG_H && DEFS=
34398 if test -z "${GL_GENERATE_ERRNO_H_TRUE}" && test -z "${GL_GENERATE_ERRNO_H_FALSE}"; then
34399 as_fn_error $? "conditional \"GL_GENERATE_ERRNO_H\" was never defined.
34400 Usually this means the macro was only invoked conditionally." "$LINENO" 5
34402 if test -z "${GL_GENERATE_FLOAT_H_TRUE}" && test -z "${GL_GENERATE_FLOAT_H_FALSE}"; then
34403 as_fn_error $? "conditional \"GL_GENERATE_FLOAT_H\" was never defined.
34404 Usually this means the macro was only invoked conditionally." "$LINENO" 5
34406 if test -z "${GL_GENERATE_FNMATCH_H_TRUE}" && test -z "${GL_GENERATE_FNMATCH_H_FALSE}"; then
34407 as_fn_error $? "conditional \"GL_GENERATE_FNMATCH_H\" was never defined.
34408 Usually this means the macro was only invoked conditionally." "$LINENO" 5
34410 if test -z "${GNU_MAKE_TRUE}" && test -z "${GNU_MAKE_FALSE}"; then
34411 as_fn_error $? "conditional \"GNU_MAKE\" was never defined.
34412 Usually this means the macro was only invoked conditionally." "$LINENO" 5
34414 if test -z "${GL_GENERATE_ICONV_H_TRUE}" && test -z "${GL_GENERATE_ICONV_H_FALSE}"; then
34415 as_fn_error $? "conditional \"GL_GENERATE_ICONV_H\" was never defined.
34416 Usually this means the macro was only invoked conditionally." "$LINENO" 5
34418 if test -z "${GL_GENERATE_ICONV_H_TRUE}" && test -z "${GL_GENERATE_ICONV_H_FALSE}"; then
34419 as_fn_error $? "conditional \"GL_GENERATE_ICONV_H\" was never defined.
34420 Usually this means the macro was only invoked conditionally." "$LINENO" 5
34422 if test -z "${GL_GENERATE_ICONV_H_TRUE}" && test -z "${GL_GENERATE_ICONV_H_FALSE}"; then
34423 as_fn_error $? "conditional \"GL_GENERATE_ICONV_H\" was never defined.
34424 Usually this means the macro was only invoked conditionally." "$LINENO" 5
34426 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
34427 as_fn_error $? "conditional \"GL_GENERATE_STDINT_H\" was never defined.
34428 Usually this means the macro was only invoked conditionally." "$LINENO" 5
34430 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
34431 as_fn_error $? "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
34432 Usually this means the macro was only invoked conditionally." "$LINENO" 5
34434 CONFIG_INCLUDE=lib/config.h
34436 if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
34437 as_fn_error $? "conditional \"GL_GENERATE_STDARG_H\" was never defined.
34438 Usually this means the macro was only invoked conditionally." "$LINENO" 5
34440 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
34441 as_fn_error $? "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
34442 Usually this means the macro was only invoked conditionally." "$LINENO" 5
34444 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
34445 as_fn_error $? "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
34446 Usually this means the macro was only invoked conditionally." "$LINENO" 5
34448 if test -z "${LIBUNISTRING_COMPILE_UNISTR_U8_MBTOUCR_TRUE}" && test -z "${LIBUNISTRING_COMPILE_UNISTR_U8_MBTOUCR_FALSE}"; then
34449 as_fn_error $? "conditional \"LIBUNISTRING_COMPILE_UNISTR_U8_MBTOUCR\" was never defined.
34450 Usually this means the macro was only invoked conditionally." "$LINENO" 5
34452 if test -z "${LIBUNISTRING_COMPILE_UNISTR_U8_UCTOMB_TRUE}" && test -z "${LIBUNISTRING_COMPILE_UNISTR_U8_UCTOMB_FALSE}"; then
34453 as_fn_error $? "conditional \"LIBUNISTRING_COMPILE_UNISTR_U8_UCTOMB\" was never defined.
34454 Usually this means the macro was only invoked conditionally." "$LINENO" 5
34456 if test -z "${LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_TRUE}" && test -z "${LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_FALSE}"; then
34457 as_fn_error $? "conditional \"LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH\" was never defined.
34458 Usually this means the macro was only invoked conditionally." "$LINENO" 5
34464 if test -n "$gl_LIBOBJS"; then
34465 # Remove the extension.
34466 sed_drop_objext='s/\.o$//;s/\.obj$//'
34467 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
34468 gl_libobjs="$gl_libobjs $i.$ac_objext"
34469 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
34472 gl_LIBOBJS=$gl_libobjs
34474 gl_LTLIBOBJS=$gl_ltlibobjs
34480 if test -n "$gltests_LIBOBJS"; then
34481 # Remove the extension.
34482 sed_drop_objext='s/\.o$//;s/\.obj$//'
34483 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
34484 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
34485 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
34488 gltests_LIBOBJS=$gltests_libobjs
34490 gltests_LTLIBOBJS=$gltests_ltlibobjs
34494 : "${CONFIG_STATUS=./config.status}"
34496 ac_clean_files_save=$ac_clean_files
34497 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
34498 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
34499 printf "%s\n" "$as_me: creating $CONFIG_STATUS" >&6;}
34501 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
34503 # Generated by $as_me.
34504 # Run this file to recreate the current configuration.
34505 # Compiler output produced by configure, useful for debugging
34506 # configure, is in config.log if it exists.
34509 ac_cs_recheck=false
34512 SHELL=\${CONFIG_SHELL-$SHELL}
34515 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
34516 ## -------------------- ##
34517 ## M4sh Initialization. ##
34518 ## -------------------- ##
34520 # Be more Bourne compatible
34521 DUALCASE=1; export DUALCASE # for MKS sh
34522 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
34525 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
34526 # is contrary to our usage. Disable this feature.
34527 alias -g '${1+"$@"}'='"$@"'
34528 setopt NO_GLOB_SUBST
34530 case `(set -o) 2>/dev/null` in #(
34539 # The user is always right.
34540 if test "${PATH_SEPARATOR+set}" != set; then
34542 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
34543 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
34550 # We need space, tab and new line, in precisely that order. Quoting is
34551 # there to prevent editors from complaining about space-tab.
34552 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
34553 # splitting by setting IFS to empty value.)
34559 # Find who we are. Look in the path if we contain no directory separator.
34562 *[\\/]* ) as_myself=$0 ;;
34563 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34564 for as_dir in $PATH
34567 case $as_dir in #(((
34570 *) as_dir=$as_dir/ ;;
34572 test -r "$as_dir$0" && as_myself=$as_dir$0 && break
34578 # We did not find ourselves, most probably we were run as `sh COMMAND'
34579 # in which case we are not to be found in the path.
34580 if test "x$as_myself" = x; then
34583 if test ! -f "$as_myself"; then
34584 printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
34588 # Unset variables that we do not need and which cause bugs (e.g. in
34589 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
34590 # suppresses any "Segmentation fault" message there. '((' could
34591 # trigger a bug in pdksh 5.2.14.
34592 for as_var in BASH_ENV ENV MAIL MAILPATH
34593 do eval test x\${$as_var+set} = xset \
34594 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
34607 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
34610 # as_fn_error STATUS ERROR [LINENO LOG_FD]
34611 # ----------------------------------------
34612 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
34613 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
34614 # script with STATUS, using 1 if that was 0.
34617 as_status=$1; test $as_status -eq 0 && as_status=1
34619 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
34620 printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
34622 printf "%s\n" "$as_me: error: $2" >&2
34623 as_fn_exit $as_status
34627 # as_fn_set_status STATUS
34628 # -----------------------
34629 # Set $? to STATUS, without forking.
34630 as_fn_set_status ()
34633 } # as_fn_set_status
34635 # as_fn_exit STATUS
34636 # -----------------
34637 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
34641 as_fn_set_status $1
34647 # Portably unset VAR.
34650 { eval $1=; unset $1;}
34652 as_unset=as_fn_unset
34653 # as_fn_append VAR VALUE
34654 # ----------------------
34655 # Append the text in VALUE to the end of the definition contained in VAR. Take
34656 # advantage of any shell optimizations that allow amortized linear growth over
34657 # repeated appends, instead of the typical quadratic growth present in naive
34659 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
34660 eval 'as_fn_append ()
34671 # as_fn_arith ARG...
34672 # ------------------
34673 # Perform arithmetic evaluation on the ARGs, and store the result in the
34674 # global $as_val. Take advantage of shells that can avoid forks. The arguments
34675 # must be portable across $(()) and expr.
34676 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
34677 eval 'as_fn_arith ()
34684 as_val=`expr "$@" || test $? -eq 1`
34689 if expr a : '\(a\)' >/dev/null 2>&1 &&
34690 test "X`expr 00001 : '.*\(...\)'`" = X001; then
34696 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
34697 as_basename=basename
34702 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
34708 as_me=`$as_basename -- "$0" ||
34709 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
34710 X"$0" : 'X\(//\)$' \| \
34711 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
34712 printf "%s\n" X/"$0" |
34713 sed '/^.*\/\([^/][^/]*\)\/*$/{
34727 # Avoid depending upon Character Ranges.
34728 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
34729 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
34730 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
34731 as_cr_digits='0123456789'
34732 as_cr_alnum=$as_cr_Letters$as_cr_digits
34734 ECHO_C= ECHO_N= ECHO_T=
34735 case `echo -n x` in #(((((
34737 case `echo 'xy\c'` in
34738 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
34740 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
34747 rm -f conf$$ conf$$.exe conf$$.file
34748 if test -d conf$$.dir; then
34749 rm -f conf$$.dir/conf$$.file
34752 mkdir conf$$.dir 2>/dev/null
34754 if (echo >conf$$.file) 2>/dev/null; then
34755 if ln -s conf$$.file conf$$ 2>/dev/null; then
34757 # ... but there are two gotchas:
34758 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
34759 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
34760 # In both cases, we have to default to `cp -pR'.
34761 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
34763 elif ln conf$$.file conf$$ 2>/dev/null; then
34771 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
34772 rmdir conf$$.dir 2>/dev/null
34777 # Create "$as_dir" as a directory, including parents if necessary.
34782 -*) as_dir=./$as_dir;;
34784 test -d "$as_dir" || eval $as_mkdir_p || {
34788 *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
34789 *) as_qdir=$as_dir;;
34791 as_dirs="'$as_qdir' $as_dirs"
34792 as_dir=`$as_dirname -- "$as_dir" ||
34793 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
34794 X"$as_dir" : 'X\(//\)[^/]' \| \
34795 X"$as_dir" : 'X\(//\)$' \| \
34796 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
34797 printf "%s\n" X"$as_dir" |
34798 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
34802 /^X\(\/\/\)[^/].*/{
34815 test -d "$as_dir" && break
34817 test -z "$as_dirs" || eval "mkdir $as_dirs"
34818 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
34822 if mkdir -p . 2>/dev/null; then
34823 as_mkdir_p='mkdir -p "$as_dir"'
34825 test -d ./-p && rmdir ./-p
34830 # as_fn_executable_p FILE
34831 # -----------------------
34832 # Test if FILE is an executable regular file.
34833 as_fn_executable_p ()
34835 test -f "$1" && test -x "$1"
34836 } # as_fn_executable_p
34837 as_test_x='test -x'
34838 as_executable_p=as_fn_executable_p
34840 # Sed expression to map a string onto a valid CPP name.
34841 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
34843 # Sed expression to map a string onto a valid variable name.
34844 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
34848 ## ----------------------------------- ##
34849 ## Main body of $CONFIG_STATUS script. ##
34850 ## ----------------------------------- ##
34852 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
34854 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
34855 # Save the log message, to keep $0 and so on meaningful, and to
34856 # report actual input values of CONFIG_FILES etc. instead of their
34857 # values after options handling.
34859 This file was extended by GNU diffutils $as_me 3.3, which was
34860 generated by GNU Autoconf 2.69.79-0bdae. Invocation command line was
34862 CONFIG_FILES = $CONFIG_FILES
34863 CONFIG_HEADERS = $CONFIG_HEADERS
34864 CONFIG_LINKS = $CONFIG_LINKS
34865 CONFIG_COMMANDS = $CONFIG_COMMANDS
34868 on `(hostname || uname -n) 2>/dev/null | sed 1q`
34873 case $ac_config_files in *"
34874 "*) set x $ac_config_files; shift; ac_config_files=$*;;
34877 case $ac_config_headers in *"
34878 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
34882 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
34883 # Files that config.status was made for.
34884 config_files="$ac_config_files"
34885 config_headers="$ac_config_headers"
34886 config_links="$ac_config_links"
34887 config_commands="$ac_config_commands"
34891 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
34893 \`$as_me' instantiates files and other configuration actions
34894 from templates according to the current configuration. Unless the files
34895 and actions are specified as TAGs, all are instantiated by default.
34897 Usage: $0 [OPTION]... [TAG]...
34899 -h, --help print this help, then exit
34900 -V, --version print version number and configuration settings, then exit
34901 --config print configuration, then exit
34902 -q, --quiet, --silent
34903 do not print progress messages
34904 -d, --debug don't remove temporary files
34905 --recheck update $as_me by reconfiguring in the same conditions
34906 --file=FILE[:TEMPLATE]
34907 instantiate the configuration file FILE
34908 --header=FILE[:TEMPLATE]
34909 instantiate the configuration header FILE
34911 Configuration files:
34914 Configuration headers:
34917 Configuration links:
34920 Configuration commands:
34923 Report bugs to <bug-diffutils@gnu.org>.
34924 GNU diffutils home page: <http://www.gnu.org/software/diffutils/>.
34925 General help using GNU software: <http://www.gnu.org/gethelp/>."
34928 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
34929 ac_cs_config="`printf "%s\n" "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
34931 GNU diffutils config.status 3.3
34932 configured by $0, generated by GNU Autoconf 2.69.79-0bdae,
34933 with options \\"\$ac_cs_config\\"
34935 Copyright (C) Free Software Foundation, Inc.
34936 This config.status script is free software; the Free Software Foundation
34937 gives unlimited permission to copy, distribute and modify it."
34944 test -n "\$AWK" || AWK=awk
34947 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
34948 # The default lists apply if the user does not specify any file.
34954 ac_option=`expr "X$1" : 'X\([^=]*\)='`
34955 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
34959 ac_option=`expr "X$1" : 'X\([^=]*\)='`
34971 # Handling of the options.
34972 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
34974 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
34975 printf "%s\n" "$ac_cs_version"; exit ;;
34976 --config | --confi | --conf | --con | --co | --c )
34977 printf "%s\n" "$ac_cs_config"; exit ;;
34978 --debug | --debu | --deb | --de | --d | -d )
34980 --file | --fil | --fi | --f )
34983 *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
34984 '') as_fn_error $? "missing file argument" ;;
34986 as_fn_append CONFIG_FILES " '$ac_optarg'"
34987 ac_need_defaults=false;;
34988 --header | --heade | --head | --hea )
34991 *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
34993 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
34994 ac_need_defaults=false;;
34996 # Conflict between --help and --header
34997 as_fn_error $? "ambiguous option: \`$1'
34998 Try \`$0 --help' for more information.";;
34999 --help | --hel | -h )
35000 printf "%s\n" "$ac_cs_usage"; exit ;;
35001 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
35002 | -silent | --silent | --silen | --sile | --sil | --si | --s)
35005 # This is an error.
35006 -*) as_fn_error $? "unrecognized option: \`$1'
35007 Try \`$0 --help' for more information." ;;
35009 *) as_fn_append ac_config_targets " $1"
35010 ac_need_defaults=false ;;
35016 ac_configure_extra_args=
35018 if $ac_cs_silent; then
35020 ac_configure_extra_args="$ac_configure_extra_args --silent"
35024 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
35025 if \$ac_cs_recheck; then
35026 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
35028 \printf "%s\n" "running CONFIG_SHELL=$SHELL \$*" >&6
35029 CONFIG_SHELL='$SHELL'
35030 export CONFIG_SHELL
35035 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
35039 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
35040 ## Running $as_me. ##
35042 printf "%s\n" "$ac_log"
35046 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
35050 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
35051 GNUmakefile=$GNUmakefile
35052 # Capture the value of obsolete ALL_LINGUAS because we need it to compute
35053 # POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES, CATALOGS. But hide it
35054 # from automake < 1.5.
35055 eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
35056 # Capture the value of LINGUAS because we need it to compute CATALOGS.
35057 LINGUAS="${LINGUAS-%UNSET%}"
35062 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
35064 # Handling of arguments.
35065 for ac_config_target in $ac_config_targets
35067 case $ac_config_target in
35068 "lib/config.h") CONFIG_HEADERS="$CONFIG_HEADERS lib/config.h:lib/config.hin" ;;
35069 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
35070 "$GNUmakefile") CONFIG_LINKS="$CONFIG_LINKS $GNUmakefile:$GNUmakefile" ;;
35071 "po-directories") CONFIG_COMMANDS="$CONFIG_COMMANDS po-directories" ;;
35072 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
35073 "doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
35074 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
35075 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
35076 "tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;;
35077 "gnulib-tests/Makefile") CONFIG_FILES="$CONFIG_FILES gnulib-tests/Makefile" ;;
35078 "man/Makefile") CONFIG_FILES="$CONFIG_FILES man/Makefile" ;;
35079 "po/Makefile.in") CONFIG_FILES="$CONFIG_FILES po/Makefile.in" ;;
35081 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
35086 # If the user did not use the arguments to specify the items to instantiate,
35087 # then the envvar interface is used. Set only those that are not.
35088 # We use the long form for the default assignment because of an extremely
35089 # bizarre bug on SunOS 4.1.3.
35090 if $ac_need_defaults; then
35091 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
35092 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
35093 test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
35094 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
35097 # Have a temporary directory for convenience. Make it in the build tree
35098 # simply because there is no reason against having it here, and in addition,
35099 # creating and moving files from /tmp can sometimes cause problems.
35100 # Hook for its removal unless debugging.
35101 # Note that there is a small window in which the directory will not be cleaned:
35102 # after its creation but before its name has been assigned to `$tmp'.
35106 trap 'exit_status=$?
35107 : "${ac_tmp:=$tmp}"
35108 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
35110 trap 'as_fn_exit 1' 1 2 13 15
35112 # Create a (secure) tmp directory for tmp files.
35115 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
35119 tmp=./conf$$-$RANDOM
35120 (umask 077 && mkdir "$tmp")
35121 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
35124 # Set up the scripts for CONFIG_FILES section.
35125 # No need to generate them if there are no CONFIG_FILES.
35126 # This happens for instance with `./config.status config.h'.
35127 if test -n "$CONFIG_FILES"; then
35130 ac_cr=`echo X | tr X '\015'`
35131 # On cygwin, bash can eat \r inside `` if the user requested igncr.
35132 # But we know of no other shell where ac_cr would be empty at this
35133 # point, so we can use a bashism as a fallback.
35134 if test "x$ac_cr" = x; then
35135 eval ac_cr=\$\'\\r\'
35137 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
35138 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
35141 ac_cs_awk_cr=$ac_cr
35144 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
35149 echo "cat >conf$$subs.awk <<_ACEOF" &&
35150 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
35152 } >conf$$subs.sh ||
35153 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
35154 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
35156 for ac_last_try in false false false false false :; do
35157 . ./conf$$subs.sh ||
35158 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
35160 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
35161 if test $ac_delim_n = $ac_delim_num; then
35163 elif $ac_last_try; then
35164 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
35166 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
35169 rm -f conf$$subs.sh
35171 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
35172 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
35176 s/^/S["/; s/!.*/"]=/
35186 s/\(.\{148\}\)..*/\1/
35188 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
35193 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
35200 s/\(.\{148\}\)..*/\1/
35202 s/["\\]/\\&/g; s/^/"/; s/$/"/
35206 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
35211 ' <conf$$subs.awk | sed '
35216 ' >>$CONFIG_STATUS || ac_write_fail=1
35217 rm -f conf$$subs.awk
35218 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
35220 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
35221 for (key in S) S_is_set[key] = 1
35227 nfields = split(line, field, "@")
35229 len = length(field[1])
35230 for (i = 2; i < nfields; i++) {
35232 keylen = length(key)
35233 if (S_is_set[key]) {
35235 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
35236 len += length(value) + length(field[++i])
35247 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
35248 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
35249 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
35252 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
35253 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
35256 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
35257 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
35258 # trailing colons and then remove the whole line if VPATH becomes empty
35259 # (actually we leave an empty line to preserve line numbers).
35260 if test "x$srcdir" = x.; then
35261 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
35279 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
35280 fi # test -n "$CONFIG_FILES"
35282 # Set up the scripts for CONFIG_HEADERS section.
35283 # No need to generate them if there are no CONFIG_HEADERS.
35284 # This happens for instance with `./config.status Makefile'.
35285 if test -n "$CONFIG_HEADERS"; then
35286 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
35290 # Transform confdefs.h into an awk script `defines.awk', embedded as
35291 # here-document in config.status, that substitutes the proper values into
35292 # config.h.in to produce config.h.
35294 # Create a delimiter string that does not exist in confdefs.h, to ease
35295 # handling of long lines.
35297 for ac_last_try in false false :; do
35298 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
35299 if test -z "$ac_tt"; then
35301 elif $ac_last_try; then
35302 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
35304 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
35308 # For the awk script, D is an array of macro values keyed by name,
35309 # likewise P contains macro parameters if any. Preserve backslash
35310 # newline sequences.
35312 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
35314 s/.\{148\}/&'"$ac_delim"'/g
35317 s/^[ ]*#[ ]*define[ ][ ]*/ /
35324 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
35326 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
35330 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
35331 D["\1"]=" \3\\\\\\n"\\/p
35333 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
35338 s/.\{148\}/&'"$ac_delim"'/g
35343 s/["\\]/\\&/g; s/^/"/; s/$/"/p
35346 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
35348 ' <confdefs.h | sed '
35349 s/'"$ac_delim"'/"\\\
35350 "/g' >>$CONFIG_STATUS || ac_write_fail=1
35352 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
35353 for (key in D) D_is_set[key] = 1
35356 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
35358 split(line, arg, " ")
35359 if (arg[1] == "#") {
35363 defundef = substr(arg[1], 2)
35366 split(mac1, mac2, "(") #)
35368 prefix = substr(line, 1, index(line, defundef) - 1)
35369 if (D_is_set[macro]) {
35370 # Preserve the white space surrounding the "#".
35371 print prefix "define", macro P[macro] D[macro]
35374 # Replace #undef with comments. This is necessary, for example,
35375 # in the case of _POSIX_SOURCE, which is predefined and required
35376 # on some systems where configure will not decide to define it.
35377 if (defundef == "undef") {
35378 print "/*", prefix defundef, macro, "*/"
35386 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
35387 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
35388 fi # test -n "$CONFIG_HEADERS"
35391 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :L $CONFIG_LINKS :C $CONFIG_COMMANDS"
35396 :[FHLC]) ac_mode=$ac_tag; continue;;
35398 case $ac_mode$ac_tag in
35400 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
35401 :[FH]-) ac_tag=-:-;;
35402 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
35419 -) ac_f="$ac_tmp/stdin";;
35420 *) # Look for the file first in the build tree, then in the source tree
35421 # (if the path is not absolute). The absolute path cannot be DOS-style,
35422 # because $ac_f cannot contain `:'.
35426 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
35428 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
35430 case $ac_f in *\'*) ac_f=`printf "%s\n" "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
35431 as_fn_append ac_file_inputs " '$ac_f'"
35434 # Let's still pretend it is `configure' which instantiates (i.e., don't
35435 # use $as_me), people would be surprised to read:
35436 # /* config.h. Generated by config.status. */
35437 configure_input='Generated from '`
35438 printf "%s\n" "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
35440 if test x"$ac_file" != x-; then
35441 configure_input="$ac_file. $configure_input"
35442 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
35443 printf "%s\n" "$as_me: creating $ac_file" >&6;}
35445 # Neutralize special characters interpreted by sed in replacement strings.
35446 case $configure_input in #(
35447 *\&* | *\|* | *\\* )
35448 ac_sed_conf_input=`printf "%s\n" "$configure_input" |
35449 sed 's/[\\\\&|]/\\\\&/g'`;; #(
35450 *) ac_sed_conf_input=$configure_input;;
35454 *:-:* | *:-) cat >"$ac_tmp/stdin" \
35455 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
35460 ac_dir=`$as_dirname -- "$ac_file" ||
35461 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35462 X"$ac_file" : 'X\(//\)[^/]' \| \
35463 X"$ac_file" : 'X\(//\)$' \| \
35464 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
35465 printf "%s\n" X"$ac_file" |
35466 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
35470 /^X\(\/\/\)[^/].*/{
35483 as_dir="$ac_dir"; as_fn_mkdir_p
35487 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
35489 ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'`
35490 # A ".." for each directory in $ac_dir_suffix.
35491 ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
35492 case $ac_top_builddir_sub in
35493 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
35494 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
35497 ac_abs_top_builddir=$ac_pwd
35498 ac_abs_builddir=$ac_pwd$ac_dir_suffix
35499 # for backward compatibility:
35500 ac_top_builddir=$ac_top_build_prefix
35503 .) # We are building in place.
35505 ac_top_srcdir=$ac_top_builddir_sub
35506 ac_abs_top_srcdir=$ac_pwd ;;
35507 [\\/]* | ?:[\\/]* ) # Absolute name.
35508 ac_srcdir=$srcdir$ac_dir_suffix;
35509 ac_top_srcdir=$srcdir
35510 ac_abs_top_srcdir=$srcdir ;;
35511 *) # Relative name.
35512 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
35513 ac_top_srcdir=$ac_top_build_prefix$srcdir
35514 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
35516 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
35526 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
35527 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
35529 ac_MKDIR_P=$MKDIR_P
35531 [\\/$]* | ?:[\\/]* ) ;;
35532 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
35536 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
35537 # If the template does not know about datarootdir, expand it.
35538 # FIXME: This hack should be removed a few years after 2.60.
35539 ac_datarootdir_hack=; ac_datarootdir_seen=
35550 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
35551 *datarootdir*) ac_datarootdir_seen=yes;;
35552 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
35553 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
35554 printf "%s\n" "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
35556 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
35557 ac_datarootdir_hack='
35558 s&@datadir@&$datadir&g
35559 s&@docdir@&$docdir&g
35560 s&@infodir@&$infodir&g
35561 s&@localedir@&$localedir&g
35562 s&@mandir@&$mandir&g
35563 s&\\\${datarootdir}&$datarootdir&g' ;;
35567 # Neutralize VPATH when `$srcdir' = `.'.
35568 # Shell code in configure.ac might set extrasub.
35569 # FIXME: do we really want to maintain this feature?
35570 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
35571 ac_sed_extra="$ac_vpsub
35574 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
35576 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
35577 s|@configure_input@|$ac_sed_conf_input|;t t
35578 s&@top_builddir@&$ac_top_builddir_sub&;t t
35579 s&@top_build_prefix@&$ac_top_build_prefix&;t t
35580 s&@srcdir@&$ac_srcdir&;t t
35581 s&@abs_srcdir@&$ac_abs_srcdir&;t t
35582 s&@top_srcdir@&$ac_top_srcdir&;t t
35583 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
35584 s&@builddir@&$ac_builddir&;t t
35585 s&@abs_builddir@&$ac_abs_builddir&;t t
35586 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
35587 s&@INSTALL@&$ac_INSTALL&;t t
35588 s&@MKDIR_P@&$ac_MKDIR_P&;t t
35589 $ac_datarootdir_hack
35591 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
35592 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
35594 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
35595 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
35596 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
35597 "$ac_tmp/out"`; test -z "$ac_out"; } &&
35598 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
35599 which seems to be undefined. Please make sure it is defined" >&5
35600 printf "%s\n" "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
35601 which seems to be undefined. Please make sure it is defined" >&2;}
35603 rm -f "$ac_tmp/stdin"
35605 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
35606 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
35608 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
35614 if test x"$ac_file" != x-; then
35616 printf "%s\n" "/* $configure_input */" \
35617 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
35618 } >"$ac_tmp/config.h" \
35619 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
35620 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
35621 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
35622 printf "%s\n" "$as_me: $ac_file is unchanged" >&6;}
35625 mv "$ac_tmp/config.h" "$ac_file" \
35626 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
35629 printf "%s\n" "/* $configure_input */" \
35630 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
35631 || as_fn_error $? "could not create -" "$LINENO" 5
35633 # Compute "$ac_file"'s index in $config_headers.
35636 for _am_header in $config_headers :; do
35637 case $_am_header in
35638 $_am_arg | $_am_arg:* )
35641 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
35644 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
35645 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35646 X"$_am_arg" : 'X\(//\)[^/]' \| \
35647 X"$_am_arg" : 'X\(//\)$' \| \
35648 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
35649 printf "%s\n" X"$_am_arg" |
35650 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
35654 /^X\(\/\/\)[^/].*/{
35666 s/.*/./; q'`/stamp-h$_am_stamp_count
35673 if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
35676 # Prefer the file from the source tree if names are identical.
35677 if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
35678 ac_source=$srcdir/$ac_source
35681 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: linking $ac_source to $ac_file" >&5
35682 printf "%s\n" "$as_me: linking $ac_source to $ac_file" >&6;}
35684 if test ! -r "$ac_source"; then
35685 as_fn_error $? "$ac_source: file not found" "$LINENO" 5
35689 # Try a relative symlink, then a hard link, then a copy.
35691 [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
35692 *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
35694 ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
35695 ln "$ac_source" "$ac_file" 2>/dev/null ||
35696 cp -p "$ac_source" "$ac_file" ||
35697 as_fn_error $? "cannot link or copy $ac_source to $ac_file" "$LINENO" 5
35700 :C) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
35701 printf "%s\n" "$as_me: executing $ac_file commands" >&6;}
35706 case $ac_file$ac_mode in
35707 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
35708 # Older Autoconf quotes --file arguments for eval, but not when files
35709 # are listed without --file. Let's play safe and only enable the eval
35710 # if we detect the quoting.
35711 case $CONFIG_FILES in
35712 *\'*) eval set x "$CONFIG_FILES" ;;
35713 *) set x $CONFIG_FILES ;;
35718 # Strip MF so we end up with the name of the file.
35719 mf=`echo "$mf" | sed -e 's/:.*$//'`
35720 # Check whether this is an Automake generated Makefile or not.
35721 # We used to match only the files named 'Makefile.in', but
35722 # some people rename them; so instead we look at the file content.
35723 # Grep'ing the first line is not enough: some people post-process
35724 # each Makefile.in and add a new line on top of each file to say so.
35725 # Grep'ing the whole file is not good either: AIX grep has a line
35726 # limit of 2048, but all sed's we know have understand at least 4000.
35727 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
35728 dirpart=`$as_dirname -- "$mf" ||
35729 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35730 X"$mf" : 'X\(//\)[^/]' \| \
35731 X"$mf" : 'X\(//\)$' \| \
35732 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
35733 printf "%s\n" X"$mf" |
35734 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
35738 /^X\(\/\/\)[^/].*/{
35754 # Extract the definition of DEPDIR, am__include, and am__quote
35755 # from the Makefile without running 'make'.
35756 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
35757 test -z "$DEPDIR" && continue
35758 am__include=`sed -n 's/^am__include = //p' < "$mf"`
35759 test -z "am__include" && continue
35760 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
35761 # Find all dependency output files, they are included files with
35762 # $(DEPDIR) in their names. We invoke sed twice because it is the
35763 # simplest approach to changing $(DEPDIR) to its actual value in the
35765 for file in `sed -n "
35766 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
35767 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
35768 # Make sure the directory exists.
35769 test -f "$dirpart/$file" && continue
35770 fdir=`$as_dirname -- "$file" ||
35771 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35772 X"$file" : 'X\(//\)[^/]' \| \
35773 X"$file" : 'X\(//\)$' \| \
35774 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
35775 printf "%s\n" X"$file" |
35776 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
35780 /^X\(\/\/\)[^/].*/{
35793 as_dir=$dirpart/$fdir; as_fn_mkdir_p
35794 # echo "creating $dirpart/$file"
35795 echo '# dummy' > "$dirpart/$file"
35800 "po-directories":C)
35801 for ac_file in $CONFIG_FILES; do
35802 # Support "outfile[:infile[:infile...]]"
35804 *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
35806 # PO directories have a Makefile.in generated from Makefile.in.in.
35807 case "$ac_file" in */Makefile.in)
35808 # Adjust a relative srcdir.
35809 ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
35810 ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
35811 ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
35812 # In autoconf-2.13 it is called $ac_given_srcdir.
35813 # In autoconf-2.50 it is called $srcdir.
35814 test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
35815 case "$ac_given_srcdir" in
35816 .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
35817 /*) top_srcdir="$ac_given_srcdir" ;;
35818 *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
35820 # Treat a directory as a PO directory if and only if it has a
35821 # POTFILES.in file. This allows packages to have multiple PO
35822 # directories under different names or in different locations.
35823 if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
35824 rm -f "$ac_dir/POTFILES"
35825 test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
35826 gt_tab=`printf '\t'`
35827 cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ${gt_tab}]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
35828 POMAKEFILEDEPS="POTFILES.in"
35829 # ALL_LINGUAS, POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES depend
35830 # on $ac_dir but don't depend on user-specified configuration
35832 if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
35833 # The LINGUAS file contains the set of available languages.
35834 if test -n "$OBSOLETE_ALL_LINGUAS"; then
35835 test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete"
35837 ALL_LINGUAS_=`sed -e "/^#/d" -e "s/#.*//" "$ac_given_srcdir/$ac_dir/LINGUAS"`
35838 # Hide the ALL_LINGUAS assignment from automake < 1.5.
35839 eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
35840 POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
35842 # The set of available languages was given in configure.in.
35843 # Hide the ALL_LINGUAS assignment from automake < 1.5.
35844 eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
35847 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).po)
35848 # Compute UPDATEPOFILES
35849 # as $(foreach lang, $(ALL_LINGUAS), $(lang).po-update)
35850 # Compute DUMMYPOFILES
35851 # as $(foreach lang, $(ALL_LINGUAS), $(lang).nop)
35853 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).gmo)
35854 case "$ac_given_srcdir" in
35856 *) srcdirpre='$(srcdir)/' ;;
35862 for lang in $ALL_LINGUAS; do
35863 POFILES="$POFILES $srcdirpre$lang.po"
35864 UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
35865 DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
35866 GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
35868 # CATALOGS depends on both $ac_dir and the user's LINGUAS
35869 # environment variable.
35871 if test -n "$ALL_LINGUAS"; then
35872 for presentlang in $ALL_LINGUAS; do
35874 if test "%UNSET%" != "$LINGUAS"; then
35875 desiredlanguages="$LINGUAS"
35877 desiredlanguages="$ALL_LINGUAS"
35879 for desiredlang in $desiredlanguages; do
35880 # Use the presentlang catalog if desiredlang is
35881 # a. equal to presentlang, or
35882 # b. a variant of presentlang (because in this case,
35883 # presentlang can be used as a fallback for messages
35884 # which are not translated in the desiredlang catalog).
35885 case "$desiredlang" in
35886 "$presentlang"*) useit=yes;;
35889 if test $useit = yes; then
35890 INST_LINGUAS="$INST_LINGUAS $presentlang"
35895 if test -n "$INST_LINGUAS"; then
35896 for lang in $INST_LINGUAS; do
35897 CATALOGS="$CATALOGS $lang.gmo"
35900 test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
35901 sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
35902 for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
35903 if test -f "$f"; then
35905 *.orig | *.bak | *~) ;;
35906 *) cat "$f" >> "$ac_dir/Makefile" ;;
35921 ac_clean_files=$ac_clean_files_save
35923 test $ac_write_fail = 0 ||
35924 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
35927 # configure is writing to config.log, and then calls config.status.
35928 # config.status does its own redirection, appending to config.log.
35929 # Unfortunately, on DOS this fails, as config.log is still kept open
35930 # by configure, so config.status won't be able to write to it; its
35931 # output is simply discarded. So we exec the FD to /dev/null,
35932 # effectively closing config.log, so it can be properly (re)opened and
35933 # appended to by config.status. When coming back to configure, we
35934 # need to make the FD available again.
35935 if test "$no_create" != yes; then
35937 ac_config_status_args=
35938 test "$silent" = yes &&
35939 ac_config_status_args="$ac_config_status_args --quiet"
35941 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
35943 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
35944 # would make configure fail if this is the last instruction.
35945 $ac_cs_success || as_fn_exit 1
35947 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
35948 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
35949 printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}