Check addr32flag instead of sizeflag for rip/eip
[deliverable/binutils-gdb.git] / gdb / gnulib / configure
CommitLineData
c971b7fa
PA
1#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.
3# Generated by GNU Autoconf 2.64.
4#
5# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
6# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software
7# Foundation, Inc.
8#
9# This configure script is free software; the Free Software Foundation
10# gives unlimited permission to copy, distribute and modify it.
11## -------------------- ##
12## M4sh Initialization. ##
13## -------------------- ##
14
15# Be more Bourne compatible
16DUALCASE=1; export DUALCASE # for MKS sh
17if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
18 emulate sh
19 NULLCMD=:
20 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
21 # is contrary to our usage. Disable this feature.
22 alias -g '${1+"$@"}'='"$@"'
23 setopt NO_GLOB_SUBST
24else
25 case `(set -o) 2>/dev/null` in #(
26 *posix*) :
27 set -o posix ;; #(
28 *) :
29 ;;
30esac
31fi
32
33
34as_nl='
35'
36export as_nl
37# Printing a long string crashes Solaris 7 /usr/bin/printf.
38as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
39as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
40as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
41# Prefer a ksh shell builtin over an external printf program on Solaris,
42# but without wasting forks for bash or zsh.
43if test -z "$BASH_VERSION$ZSH_VERSION" \
44 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
45 as_echo='print -r --'
46 as_echo_n='print -rn --'
47elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
48 as_echo='printf %s\n'
49 as_echo_n='printf %s'
50else
51 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
52 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
53 as_echo_n='/usr/ucb/echo -n'
54 else
55 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
56 as_echo_n_body='eval
57 arg=$1;
58 case $arg in #(
59 *"$as_nl"*)
60 expr "X$arg" : "X\\(.*\\)$as_nl";
61 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
62 esac;
63 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
64 '
65 export as_echo_n_body
66 as_echo_n='sh -c $as_echo_n_body as_echo'
67 fi
68 export as_echo_body
69 as_echo='sh -c $as_echo_body as_echo'
70fi
71
72# The user is always right.
73if test "${PATH_SEPARATOR+set}" != set; then
74 PATH_SEPARATOR=:
75 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
76 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
77 PATH_SEPARATOR=';'
78 }
79fi
80
81
82# IFS
83# We need space, tab and new line, in precisely that order. Quoting is
84# there to prevent editors from complaining about space-tab.
85# (If _AS_PATH_WALK were called with IFS unset, it would disable word
86# splitting by setting IFS to empty value.)
87IFS=" "" $as_nl"
88
89# Find who we are. Look in the path if we contain no directory separator.
90case $0 in #((
91 *[\\/]* ) as_myself=$0 ;;
92 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
93for as_dir in $PATH
94do
95 IFS=$as_save_IFS
96 test -z "$as_dir" && as_dir=.
97 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
98 done
99IFS=$as_save_IFS
100
101 ;;
102esac
103# We did not find ourselves, most probably we were run as `sh COMMAND'
104# in which case we are not to be found in the path.
105if test "x$as_myself" = x; then
106 as_myself=$0
107fi
108if test ! -f "$as_myself"; then
109 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
110 exit 1
111fi
112
113# Unset variables that we do not need and which cause bugs (e.g. in
114# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
115# suppresses any "Segmentation fault" message there. '((' could
116# trigger a bug in pdksh 5.2.14.
117for as_var in BASH_ENV ENV MAIL MAILPATH
118do eval test x\${$as_var+set} = xset \
119 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
120done
121PS1='$ '
122PS2='> '
123PS4='+ '
124
125# NLS nuisances.
126LC_ALL=C
127export LC_ALL
128LANGUAGE=C
129export LANGUAGE
130
131# CDPATH.
132(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
133
134if test "x$CONFIG_SHELL" = x; then
135 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
136 emulate sh
137 NULLCMD=:
138 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
139 # is contrary to our usage. Disable this feature.
140 alias -g '\${1+\"\$@\"}'='\"\$@\"'
141 setopt NO_GLOB_SUBST
142else
143 case \`(set -o) 2>/dev/null\` in #(
144 *posix*) :
145 set -o posix ;; #(
146 *) :
147 ;;
148esac
149fi
150"
151 as_required="as_fn_return () { (exit \$1); }
152as_fn_success () { as_fn_return 0; }
153as_fn_failure () { as_fn_return 1; }
154as_fn_ret_success () { return 0; }
155as_fn_ret_failure () { return 1; }
156
157exitcode=0
158as_fn_success || { exitcode=1; echo as_fn_success failed.; }
159as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
160as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
161as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
162if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
163
164else
165 exitcode=1; echo positional parameters were not saved.
166fi
167test x\$exitcode = x0 || exit 1"
168 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
169 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
170 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
171 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
172test \$(( 1 + 1 )) = 2 || exit 1"
173 if (eval "$as_required") 2>/dev/null; then :
174 as_have_required=yes
175else
176 as_have_required=no
177fi
178 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
179
180else
181 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
182as_found=false
183for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
184do
185 IFS=$as_save_IFS
186 test -z "$as_dir" && as_dir=.
187 as_found=:
188 case $as_dir in #(
189 /*)
190 for as_base in sh bash ksh sh5; do
191 # Try only shells that exist, to save several forks.
192 as_shell=$as_dir/$as_base
193 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
194 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
195 CONFIG_SHELL=$as_shell as_have_required=yes
196 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
197 break 2
198fi
199fi
200 done;;
201 esac
202 as_found=false
203done
204$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
205 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
206 CONFIG_SHELL=$SHELL as_have_required=yes
207fi; }
208IFS=$as_save_IFS
209
210
211 if test "x$CONFIG_SHELL" != x; then :
212 # We cannot yet assume a decent shell, so we have to provide a
213 # neutralization value for shells without unset; and this also
214 # works around shells that cannot unset nonexistent variables.
215 BASH_ENV=/dev/null
216 ENV=/dev/null
217 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
218 export CONFIG_SHELL
219 exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
220fi
221
222 if test x$as_have_required = xno; then :
223 $as_echo "$0: This script requires a shell more modern than all"
224 $as_echo "$0: the shells that I found on your system."
225 if test x${ZSH_VERSION+set} = xset ; then
226 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
227 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
228 else
229 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
230$0: including any error possibly output before this
231$0: message. Then install a modern shell, or manually run
232$0: the script under such a shell if you do have one."
233 fi
234 exit 1
235fi
236fi
237fi
238SHELL=${CONFIG_SHELL-/bin/sh}
239export SHELL
240# Unset more variables known to interfere with behavior of common tools.
241CLICOLOR_FORCE= GREP_OPTIONS=
242unset CLICOLOR_FORCE GREP_OPTIONS
243
244## --------------------- ##
245## M4sh Shell Functions. ##
246## --------------------- ##
247# as_fn_unset VAR
248# ---------------
249# Portably unset VAR.
250as_fn_unset ()
251{
252 { eval $1=; unset $1;}
253}
254as_unset=as_fn_unset
255
256# as_fn_set_status STATUS
257# -----------------------
258# Set $? to STATUS, without forking.
259as_fn_set_status ()
260{
261 return $1
262} # as_fn_set_status
263
264# as_fn_exit STATUS
265# -----------------
266# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
267as_fn_exit ()
268{
269 set +e
270 as_fn_set_status $1
271 exit $1
272} # as_fn_exit
273
274# as_fn_mkdir_p
275# -------------
276# Create "$as_dir" as a directory, including parents if necessary.
277as_fn_mkdir_p ()
278{
279
280 case $as_dir in #(
281 -*) as_dir=./$as_dir;;
282 esac
283 test -d "$as_dir" || eval $as_mkdir_p || {
284 as_dirs=
285 while :; do
286 case $as_dir in #(
287 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
288 *) as_qdir=$as_dir;;
289 esac
290 as_dirs="'$as_qdir' $as_dirs"
291 as_dir=`$as_dirname -- "$as_dir" ||
292$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
293 X"$as_dir" : 'X\(//\)[^/]' \| \
294 X"$as_dir" : 'X\(//\)$' \| \
295 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
296$as_echo X"$as_dir" |
297 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
298 s//\1/
299 q
300 }
301 /^X\(\/\/\)[^/].*/{
302 s//\1/
303 q
304 }
305 /^X\(\/\/\)$/{
306 s//\1/
307 q
308 }
309 /^X\(\/\).*/{
310 s//\1/
311 q
312 }
313 s/.*/./; q'`
314 test -d "$as_dir" && break
315 done
316 test -z "$as_dirs" || eval "mkdir $as_dirs"
317 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
318
319
320} # as_fn_mkdir_p
321# as_fn_append VAR VALUE
322# ----------------------
323# Append the text in VALUE to the end of the definition contained in VAR. Take
324# advantage of any shell optimizations that allow amortized linear growth over
325# repeated appends, instead of the typical quadratic growth present in naive
326# implementations.
327if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
328 eval 'as_fn_append ()
329 {
330 eval $1+=\$2
331 }'
332else
333 as_fn_append ()
334 {
335 eval $1=\$$1\$2
336 }
337fi # as_fn_append
338
339# as_fn_arith ARG...
340# ------------------
341# Perform arithmetic evaluation on the ARGs, and store the result in the
342# global $as_val. Take advantage of shells that can avoid forks. The arguments
343# must be portable across $(()) and expr.
344if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
345 eval 'as_fn_arith ()
346 {
347 as_val=$(( $* ))
348 }'
349else
350 as_fn_arith ()
351 {
352 as_val=`expr "$@" || test $? -eq 1`
353 }
354fi # as_fn_arith
355
356
357# as_fn_error ERROR [LINENO LOG_FD]
358# ---------------------------------
359# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
360# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
361# script with status $?, using 1 if that was 0.
362as_fn_error ()
363{
364 as_status=$?; test $as_status -eq 0 && as_status=1
365 if test "$3"; then
366 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
367 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
368 fi
369 $as_echo "$as_me: error: $1" >&2
370 as_fn_exit $as_status
371} # as_fn_error
372
373if expr a : '\(a\)' >/dev/null 2>&1 &&
374 test "X`expr 00001 : '.*\(...\)'`" = X001; then
375 as_expr=expr
376else
377 as_expr=false
378fi
379
380if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
381 as_basename=basename
382else
383 as_basename=false
384fi
385
386if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
387 as_dirname=dirname
388else
389 as_dirname=false
390fi
391
392as_me=`$as_basename -- "$0" ||
393$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
394 X"$0" : 'X\(//\)$' \| \
395 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
396$as_echo X/"$0" |
397 sed '/^.*\/\([^/][^/]*\)\/*$/{
398 s//\1/
399 q
400 }
401 /^X\/\(\/\/\)$/{
402 s//\1/
403 q
404 }
405 /^X\/\(\/\).*/{
406 s//\1/
407 q
408 }
409 s/.*/./; q'`
410
411# Avoid depending upon Character Ranges.
412as_cr_letters='abcdefghijklmnopqrstuvwxyz'
413as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
414as_cr_Letters=$as_cr_letters$as_cr_LETTERS
415as_cr_digits='0123456789'
416as_cr_alnum=$as_cr_Letters$as_cr_digits
417
418
419 as_lineno_1=$LINENO as_lineno_1a=$LINENO
420 as_lineno_2=$LINENO as_lineno_2a=$LINENO
421 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
422 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
423 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
424 sed -n '
425 p
426 /[$]LINENO/=
427 ' <$as_myself |
428 sed '
429 s/[$]LINENO.*/&-/
430 t lineno
431 b
432 :lineno
433 N
434 :loop
435 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
436 t loop
437 s/-\n.*//
438 ' >$as_me.lineno &&
439 chmod +x "$as_me.lineno" ||
440 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
441
442 # Don't try to exec as it changes $[0], causing all sort of problems
443 # (the dirname of $[0] is not the place where we might find the
444 # original and so on. Autoconf is especially sensitive to this).
445 . "./$as_me.lineno"
446 # Exit status is that of the last command.
447 exit
448}
449
450ECHO_C= ECHO_N= ECHO_T=
451case `echo -n x` in #(((((
452-n*)
453 case `echo 'xy\c'` in
454 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
455 xy) ECHO_C='\c';;
456 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
457 ECHO_T=' ';;
458 esac;;
459*)
460 ECHO_N='-n';;
461esac
462
463rm -f conf$$ conf$$.exe conf$$.file
464if test -d conf$$.dir; then
465 rm -f conf$$.dir/conf$$.file
466else
467 rm -f conf$$.dir
468 mkdir conf$$.dir 2>/dev/null
469fi
470if (echo >conf$$.file) 2>/dev/null; then
471 if ln -s conf$$.file conf$$ 2>/dev/null; then
472 as_ln_s='ln -s'
473 # ... but there are two gotchas:
474 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
475 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
476 # In both cases, we have to default to `cp -p'.
477 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
478 as_ln_s='cp -p'
479 elif ln conf$$.file conf$$ 2>/dev/null; then
480 as_ln_s=ln
481 else
482 as_ln_s='cp -p'
483 fi
484else
485 as_ln_s='cp -p'
486fi
487rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
488rmdir conf$$.dir 2>/dev/null
489
490if mkdir -p . 2>/dev/null; then
491 as_mkdir_p='mkdir -p "$as_dir"'
492else
493 test -d ./-p && rmdir ./-p
494 as_mkdir_p=false
495fi
496
497if test -x / >/dev/null 2>&1; then
498 as_test_x='test -x'
499else
500 if ls -dL / >/dev/null 2>&1; then
501 as_ls_L_option=L
502 else
503 as_ls_L_option=
504 fi
505 as_test_x='
506 eval sh -c '\''
507 if test -d "$1"; then
508 test -d "$1/.";
509 else
510 case $1 in #(
511 -*)set "./$1";;
512 esac;
513 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
514 ???[sx]*):;;*)false;;esac;fi
515 '\'' sh
516 '
517fi
518as_executable_p=$as_test_x
519
520# Sed expression to map a string onto a valid CPP name.
521as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
522
523# Sed expression to map a string onto a valid variable name.
524as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
525
526
527exec 7<&0 </dev/null 6>&1
528
529# Name of the host.
530# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
531# so uname gets run too.
532ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
533
534#
535# Initializations.
536#
537ac_default_prefix=/usr/local
538ac_clean_files=
539ac_config_libobj_dir=.
540LIBOBJS=
541cross_compiling=no
542subdirs=
543MFLAGS=
544MAKEFLAGS=
545
546# Identity of this package.
547PACKAGE_NAME=
548PACKAGE_TARNAME=
549PACKAGE_VERSION=
550PACKAGE_STRING=
551PACKAGE_BUGREPORT=
552PACKAGE_URL=
553
8690e634 554ac_unique_file="import/memmem.c"
c971b7fa
PA
555# Factoring default headers for most tests.
556ac_includes_default="\
557#include <stdio.h>
558#ifdef HAVE_SYS_TYPES_H
559# include <sys/types.h>
560#endif
561#ifdef HAVE_SYS_STAT_H
562# include <sys/stat.h>
563#endif
564#ifdef STDC_HEADERS
565# include <stdlib.h>
566# include <stddef.h>
567#else
568# ifdef HAVE_STDLIB_H
569# include <stdlib.h>
570# endif
571#endif
572#ifdef HAVE_STRING_H
573# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
574# include <memory.h>
575# endif
576# include <string.h>
577#endif
578#ifdef HAVE_STRINGS_H
579# include <strings.h>
580#endif
581#ifdef HAVE_INTTYPES_H
582# include <inttypes.h>
583#endif
584#ifdef HAVE_STDINT_H
585# include <stdint.h>
586#endif
587#ifdef HAVE_UNISTD_H
588# include <unistd.h>
589#endif"
590
98399780 591ac_func_list=
e26b6bb0 592ac_header_list=
8690e634 593gl_fnmatch_required=POSIX
c971b7fa
PA
594ac_subst_vars='am__EXEEXT_FALSE
595am__EXEEXT_TRUE
596gltests_LTLIBOBJS
597gltests_LIBOBJS
598gl_LTLIBOBJS
599gl_LIBOBJS
600LTLIBOBJS
601LIBOBJS
602LN_S
603am__fastdepCC_FALSE
604am__fastdepCC_TRUE
605CCDEPMODE
606AMDEPBACKSLASH
607AMDEP_FALSE
608AMDEP_TRUE
609am__quote
610am__include
611DEPDIR
612am__untar
613am__tar
614AMTAR
615am__leading_dot
616SET_MAKE
617AWK
618mkdir_p
c971b7fa
PA
619INSTALL_STRIP_PROGRAM
620STRIP
621install_sh
622MAKEINFO
623AUTOHEADER
624AUTOMAKE
625AUTOCONF
626ACLOCAL
627VERSION
628PACKAGE
629CYGPATH_W
630am__isrc
631INSTALL_DATA
632INSTALL_SCRIPT
633INSTALL_PROGRAM
634LIBGNU_LTLIBDEPS
635LIBGNU_LIBDEPS
636gltests_WITNESS
8690e634
JK
637REPLACE_TOWLOWER
638REPLACE_ISWCNTRL
639HAVE_WCTYPE_H
640NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H
641NEXT_WCTYPE_H
642HAVE_ISWCNTRL
643REPLACE_ISWBLANK
644HAVE_WCTRANS_T
645HAVE_WCTYPE_T
646HAVE_ISWBLANK
647GNULIB_TOWCTRANS
648GNULIB_WCTRANS
649GNULIB_ISWCTYPE
650GNULIB_WCTYPE
651GNULIB_ISWBLANK
652HAVE_WINT_T
653HAVE_FEATURES_H
654NEXT_AS_FIRST_DIRECTIVE_WCHAR_H
655NEXT_WCHAR_H
8839a007
PA
656HAVE_UNISTD_H
657NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
658NEXT_UNISTD_H
4a626d0a 659UNISTD_H_DEFINES_STRUCT_TIMESPEC
09607c9e
TT
660PTHREAD_H_DEFINES_STRUCT_TIMESPEC
661SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
662TIME_H_DEFINES_STRUCT_TIMESPEC
663NEXT_AS_FIRST_DIRECTIVE_TIME_H
664NEXT_TIME_H
4a626d0a
PA
665REPLACE_LOCALTIME
666REPLACE_GMTIME
09607c9e
TT
667REPLACE_TIMEGM
668REPLACE_NANOSLEEP
669REPLACE_MKTIME
670REPLACE_LOCALTIME_R
671HAVE_TIMEGM
672HAVE_STRPTIME
673HAVE_NANOSLEEP
674HAVE_DECL_LOCALTIME_R
4a626d0a 675GNULIB_TIME_RZ
09607c9e
TT
676GNULIB_TIME_R
677GNULIB_TIMEGM
678GNULIB_STRPTIME
679GNULIB_NANOSLEEP
680GNULIB_MKTIME
63ce7108
TT
681WINDOWS_64_BIT_OFF_T
682NEXT_AS_FIRST_DIRECTIVE_SYS_TYPES_H
683NEXT_SYS_TYPES_H
09607c9e
TT
684MKDIR_P
685WINDOWS_64_BIT_ST_SIZE
686NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
687NEXT_SYS_STAT_H
2196f55f
YQ
688NEXT_AS_FIRST_DIRECTIVE_STRING_H
689NEXT_STRING_H
98399780
YQ
690NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
691NEXT_STDLIB_H
6a29c58e
YQ
692NEXT_AS_FIRST_DIRECTIVE_STDIO_H
693NEXT_STDIO_H
2196f55f
YQ
694NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
695NEXT_STDDEF_H
696GL_GENERATE_STDDEF_H_FALSE
697GL_GENERATE_STDDEF_H_TRUE
698STDDEF_H
699HAVE_WCHAR_T
4a626d0a 700HAVE_MAX_ALIGN_T
2196f55f
YQ
701REPLACE_NULL
702HAVE__BOOL
703GL_GENERATE_STDBOOL_H_FALSE
704GL_GENERATE_STDBOOL_H_TRUE
705STDBOOL_H
0750520d
PA
706NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
707NEXT_SIGNAL_H
708REPLACE_RAISE
709REPLACE_PTHREAD_SIGMASK
710HAVE_SIGHANDLER_T
711HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
712HAVE_STRUCT_SIGACTION_SA_SIGACTION
713HAVE_SIGACTION
714HAVE_SIGINFO_T
715HAVE_SIGSET_T
716HAVE_RAISE
717HAVE_PTHREAD_SIGMASK
718HAVE_POSIX_SIGNALBLOCKING
719GNULIB_SIGACTION
720GNULIB_SIGPROCMASK
721GNULIB_SIGNAL_H_SIGPIPE
722GNULIB_RAISE
723GNULIB_PTHREAD_SIGMASK
6a29c58e
YQ
724REPLACE_VSPRINTF
725REPLACE_VSNPRINTF
726REPLACE_VPRINTF
727REPLACE_VFPRINTF
728REPLACE_VDPRINTF
729REPLACE_VASPRINTF
730REPLACE_TMPFILE
731REPLACE_STDIO_WRITE_FUNCS
732REPLACE_STDIO_READ_FUNCS
733REPLACE_SPRINTF
734REPLACE_SNPRINTF
735REPLACE_RENAMEAT
736REPLACE_RENAME
737REPLACE_REMOVE
738REPLACE_PRINTF
739REPLACE_POPEN
740REPLACE_PERROR
741REPLACE_OBSTACK_PRINTF
742REPLACE_GETLINE
743REPLACE_GETDELIM
744REPLACE_FTELLO
745REPLACE_FTELL
746REPLACE_FSEEKO
747REPLACE_FSEEK
748REPLACE_FREOPEN
749REPLACE_FPURGE
750REPLACE_FPRINTF
751REPLACE_FOPEN
752REPLACE_FFLUSH
753REPLACE_FDOPEN
754REPLACE_FCLOSE
755REPLACE_DPRINTF
756HAVE_VDPRINTF
757HAVE_VASPRINTF
758HAVE_RENAMEAT
759HAVE_POPEN
760HAVE_PCLOSE
761HAVE_FTELLO
762HAVE_FSEEKO
763HAVE_DPRINTF
764HAVE_DECL_VSNPRINTF
765HAVE_DECL_SNPRINTF
766HAVE_DECL_OBSTACK_PRINTF
767HAVE_DECL_GETLINE
768HAVE_DECL_GETDELIM
769HAVE_DECL_FTELLO
770HAVE_DECL_FSEEKO
771HAVE_DECL_FPURGE
772GNULIB_VSPRINTF_POSIX
773GNULIB_VSNPRINTF
774GNULIB_VPRINTF_POSIX
775GNULIB_VPRINTF
776GNULIB_VFPRINTF_POSIX
777GNULIB_VFPRINTF
778GNULIB_VDPRINTF
779GNULIB_VSCANF
780GNULIB_VFSCANF
781GNULIB_VASPRINTF
782GNULIB_TMPFILE
783GNULIB_STDIO_H_SIGPIPE
784GNULIB_STDIO_H_NONBLOCKING
785GNULIB_SPRINTF_POSIX
786GNULIB_SNPRINTF
787GNULIB_SCANF
788GNULIB_RENAMEAT
789GNULIB_RENAME
790GNULIB_REMOVE
791GNULIB_PUTS
792GNULIB_PUTCHAR
793GNULIB_PUTC
794GNULIB_PRINTF_POSIX
795GNULIB_PRINTF
796GNULIB_POPEN
797GNULIB_PERROR
798GNULIB_PCLOSE
799GNULIB_OBSTACK_PRINTF_POSIX
800GNULIB_OBSTACK_PRINTF
801GNULIB_GETLINE
802GNULIB_GETDELIM
803GNULIB_GETCHAR
804GNULIB_GETC
805GNULIB_FWRITE
806GNULIB_FTELLO
807GNULIB_FTELL
808GNULIB_FSEEKO
809GNULIB_FSEEK
810GNULIB_FSCANF
811GNULIB_FREOPEN
812GNULIB_FREAD
813GNULIB_FPUTS
814GNULIB_FPUTC
815GNULIB_FPURGE
816GNULIB_FPRINTF_POSIX
817GNULIB_FPRINTF
818GNULIB_FOPEN
819GNULIB_FGETS
820GNULIB_FGETC
821GNULIB_FFLUSH
822GNULIB_FDOPEN
823GNULIB_FCLOSE
824GNULIB_DPRINTF
c971b7fa
PA
825UNDEFINE_STRTOK_R
826REPLACE_STRTOK_R
827REPLACE_STRSIGNAL
828REPLACE_STRNLEN
829REPLACE_STRNDUP
830REPLACE_STRNCAT
831REPLACE_STRERROR_R
832REPLACE_STRERROR
833REPLACE_STRCHRNUL
834REPLACE_STRCASESTR
835REPLACE_STRSTR
836REPLACE_STRDUP
837REPLACE_STPNCPY
838REPLACE_MEMMEM
839REPLACE_MEMCHR
840HAVE_STRVERSCMP
841HAVE_DECL_STRSIGNAL
842HAVE_DECL_STRERROR_R
843HAVE_DECL_STRTOK_R
844HAVE_STRCASESTR
845HAVE_STRSEP
846HAVE_STRPBRK
847HAVE_DECL_STRNLEN
848HAVE_DECL_STRNDUP
849HAVE_DECL_STRDUP
850HAVE_STRCHRNUL
851HAVE_STPNCPY
852HAVE_STPCPY
853HAVE_RAWMEMCHR
854HAVE_DECL_MEMRCHR
855HAVE_MEMPCPY
856HAVE_DECL_MEMMEM
857HAVE_MEMCHR
858HAVE_FFSLL
859HAVE_FFSL
860HAVE_MBSLEN
861GNULIB_STRVERSCMP
862GNULIB_STRSIGNAL
863GNULIB_STRERROR_R
864GNULIB_STRERROR
865GNULIB_MBSTOK_R
866GNULIB_MBSSEP
867GNULIB_MBSSPN
868GNULIB_MBSPBRK
869GNULIB_MBSCSPN
870GNULIB_MBSCASESTR
871GNULIB_MBSPCASECMP
872GNULIB_MBSNCASECMP
873GNULIB_MBSCASECMP
874GNULIB_MBSSTR
875GNULIB_MBSRCHR
876GNULIB_MBSCHR
877GNULIB_MBSNLEN
878GNULIB_MBSLEN
879GNULIB_STRTOK_R
880GNULIB_STRCASESTR
881GNULIB_STRSTR
882GNULIB_STRSEP
883GNULIB_STRPBRK
884GNULIB_STRNLEN
885GNULIB_STRNDUP
886GNULIB_STRNCAT
887GNULIB_STRDUP
888GNULIB_STRCHRNUL
889GNULIB_STPNCPY
890GNULIB_STPCPY
891GNULIB_RAWMEMCHR
892GNULIB_MEMRCHR
893GNULIB_MEMPCPY
894GNULIB_MEMMEM
895GNULIB_MEMCHR
896GNULIB_FFSLL
897GNULIB_FFSL
8690e634
JK
898LOCALE_FR
899LOCALE_FR_UTF8
900LOCALE_ZH_CN
901LOCALE_JA
902REPLACE_WCSWIDTH
903REPLACE_WCWIDTH
904REPLACE_WCSNRTOMBS
905REPLACE_WCSRTOMBS
906REPLACE_WCRTOMB
907REPLACE_MBSNRTOWCS
908REPLACE_MBSRTOWCS
909REPLACE_MBRLEN
910REPLACE_MBRTOWC
911REPLACE_MBSINIT
912REPLACE_WCTOB
913REPLACE_BTOWC
914REPLACE_MBSTATE_T
915HAVE_DECL_WCWIDTH
916HAVE_DECL_WCTOB
917HAVE_WCSWIDTH
918HAVE_WCSTOK
919HAVE_WCSSTR
920HAVE_WCSPBRK
921HAVE_WCSSPN
922HAVE_WCSCSPN
923HAVE_WCSRCHR
924HAVE_WCSCHR
925HAVE_WCSDUP
926HAVE_WCSXFRM
927HAVE_WCSCOLL
928HAVE_WCSNCASECMP
929HAVE_WCSCASECMP
930HAVE_WCSNCMP
931HAVE_WCSCMP
932HAVE_WCSNCAT
933HAVE_WCSCAT
934HAVE_WCPNCPY
935HAVE_WCSNCPY
936HAVE_WCPCPY
937HAVE_WCSCPY
938HAVE_WCSNLEN
939HAVE_WCSLEN
940HAVE_WMEMSET
941HAVE_WMEMMOVE
942HAVE_WMEMCPY
943HAVE_WMEMCMP
944HAVE_WMEMCHR
945HAVE_WCSNRTOMBS
946HAVE_WCSRTOMBS
947HAVE_WCRTOMB
948HAVE_MBSNRTOWCS
949HAVE_MBSRTOWCS
950HAVE_MBRLEN
951HAVE_MBRTOWC
952HAVE_MBSINIT
953HAVE_BTOWC
954GNULIB_WCSWIDTH
955GNULIB_WCSTOK
956GNULIB_WCSSTR
957GNULIB_WCSPBRK
958GNULIB_WCSSPN
959GNULIB_WCSCSPN
960GNULIB_WCSRCHR
961GNULIB_WCSCHR
962GNULIB_WCSDUP
963GNULIB_WCSXFRM
964GNULIB_WCSCOLL
965GNULIB_WCSNCASECMP
966GNULIB_WCSCASECMP
967GNULIB_WCSNCMP
968GNULIB_WCSCMP
969GNULIB_WCSNCAT
970GNULIB_WCSCAT
971GNULIB_WCPNCPY
972GNULIB_WCSNCPY
973GNULIB_WCPCPY
974GNULIB_WCSCPY
975GNULIB_WCSNLEN
976GNULIB_WCSLEN
977GNULIB_WMEMSET
978GNULIB_WMEMMOVE
979GNULIB_WMEMCPY
980GNULIB_WMEMCMP
981GNULIB_WMEMCHR
982GNULIB_WCWIDTH
983GNULIB_WCSNRTOMBS
984GNULIB_WCSRTOMBS
985GNULIB_WCRTOMB
986GNULIB_MBSNRTOWCS
987GNULIB_MBSRTOWCS
988GNULIB_MBRLEN
989GNULIB_MBRTOWC
990GNULIB_MBSINIT
991GNULIB_WCTOB
992GNULIB_BTOWC
88b48903
WN
993NEXT_AS_FIRST_DIRECTIVE_MATH_H
994NEXT_MATH_H
f45c62c4
YQ
995REPLACE_UTIMENSAT
996REPLACE_STAT
997REPLACE_MKNOD
998REPLACE_MKFIFO
999REPLACE_MKDIR
1000REPLACE_LSTAT
1001REPLACE_FUTIMENS
1002REPLACE_FSTATAT
1003REPLACE_FSTAT
1004HAVE_UTIMENSAT
1005HAVE_MKNODAT
1006HAVE_MKNOD
1007HAVE_MKFIFOAT
1008HAVE_MKFIFO
1009HAVE_MKDIRAT
1010HAVE_LSTAT
1011HAVE_LCHMOD
1012HAVE_FUTIMENS
1013HAVE_FSTATAT
1014HAVE_FCHMODAT
1015GNULIB_UTIMENSAT
1016GNULIB_STAT
1017GNULIB_MKNODAT
1018GNULIB_MKNOD
1019GNULIB_MKFIFOAT
1020GNULIB_MKFIFO
1021GNULIB_MKDIRAT
1022GNULIB_LSTAT
1023GNULIB_LCHMOD
1024GNULIB_FUTIMENS
1025GNULIB_FSTATAT
1026GNULIB_FSTAT
1027GNULIB_FCHMODAT
8690e634
JK
1028LOCALCHARSET_TESTS_ENVIRONMENT
1029GLIBC21
c971b7fa
PA
1030NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
1031NEXT_INTTYPES_H
1032UINT64_MAX_EQ_ULONG_MAX
1033UINT32_MAX_LT_UINTMAX_MAX
1034PRIPTR_PREFIX
1035PRI_MACROS_BROKEN
1036INT64_MAX_EQ_LONG_MAX
1037INT32_MAX_LT_INTMAX_MAX
4a626d0a 1038REPLACE_STRTOUMAX
c971b7fa
PA
1039REPLACE_STRTOIMAX
1040HAVE_DECL_STRTOUMAX
1041HAVE_DECL_STRTOIMAX
1042HAVE_DECL_IMAXDIV
1043HAVE_DECL_IMAXABS
1044GNULIB_STRTOUMAX
1045GNULIB_STRTOIMAX
1046GNULIB_IMAXDIV
1047GNULIB_IMAXABS
1048GL_GENERATE_STDINT_H_FALSE
1049GL_GENERATE_STDINT_H_TRUE
1050STDINT_H
1051WINT_T_SUFFIX
1052WCHAR_T_SUFFIX
1053SIG_ATOMIC_T_SUFFIX
1054SIZE_T_SUFFIX
1055PTRDIFF_T_SUFFIX
1056HAVE_SIGNED_WINT_T
1057HAVE_SIGNED_WCHAR_T
1058HAVE_SIGNED_SIG_ATOMIC_T
1059BITSIZEOF_WINT_T
1060BITSIZEOF_WCHAR_T
1061BITSIZEOF_SIG_ATOMIC_T
1062BITSIZEOF_SIZE_T
1063BITSIZEOF_PTRDIFF_T
1064APPLE_UNIVERSAL_BUILD
1065HAVE_SYS_BITYPES_H
1066HAVE_SYS_INTTYPES_H
1067HAVE_STDINT_H
1068NEXT_AS_FIRST_DIRECTIVE_STDINT_H
1069NEXT_STDINT_H
c971b7fa
PA
1070HAVE_SYS_TYPES_H
1071HAVE_INTTYPES_H
1072HAVE_WCHAR_H
1073HAVE_UNSIGNED_LONG_LONG_INT
1074HAVE_LONG_LONG_INT
4a626d0a
PA
1075HAVE_WINSOCK2_H
1076NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
1077NEXT_SYS_TIME_H
1078REPLACE_STRUCT_TIMEVAL
1079REPLACE_GETTIMEOFDAY
1080HAVE_TIMEZONE_T
1081HAVE_SYS_TIME_H
1082HAVE_STRUCT_TIMEVAL
1083HAVE_GETTIMEOFDAY
1084GNULIB_GETTIMEOFDAY
88b48903
WN
1085FREXPL_LIBM
1086HAVE_SAME_LONG_DOUBLE_AS_DOUBLE
1087FREXP_LIBM
1088REPLACE_TRUNCL
1089REPLACE_TRUNCF
1090REPLACE_TRUNC
1091REPLACE_SQRTL
1092REPLACE_SIGNBIT_USING_GCC
1093REPLACE_SIGNBIT
1094REPLACE_ROUNDL
1095REPLACE_ROUNDF
1096REPLACE_ROUND
1097REPLACE_REMAINDERL
1098REPLACE_REMAINDERF
1099REPLACE_REMAINDER
1100REPLACE_NAN
1101REPLACE_MODFL
1102REPLACE_MODFF
1103REPLACE_MODF
1104REPLACE_LOGBL
1105REPLACE_LOGBF
1106REPLACE_LOGB
1107REPLACE_LOG2L
1108REPLACE_LOG2F
1109REPLACE_LOG2
1110REPLACE_LOG1PL
1111REPLACE_LOG1PF
1112REPLACE_LOG1P
1113REPLACE_LOG10L
1114REPLACE_LOG10F
1115REPLACE_LOG10
1116REPLACE_LOGL
1117REPLACE_LOGF
1118REPLACE_LOG
1119REPLACE_LDEXPL
1120REPLACE_ISNAN
1121REPLACE_ISINF
1122REPLACE_ISFINITE
1123REPLACE_ILOGBF
1124REPLACE_ILOGB
1125REPLACE_HYPOTL
1126REPLACE_HYPOTF
1127REPLACE_HYPOT
1128REPLACE_HUGE_VAL
1129REPLACE_FREXPL
1130REPLACE_FREXP
1131REPLACE_FREXPF
1132REPLACE_FMODL
1133REPLACE_FMODF
1134REPLACE_FMOD
1135REPLACE_FMAL
1136REPLACE_FMAF
1137REPLACE_FMA
1138REPLACE_FLOORL
1139REPLACE_FLOORF
1140REPLACE_FLOOR
1141REPLACE_FABSL
1142REPLACE_EXP2L
1143REPLACE_EXP2
1144REPLACE_EXPM1F
1145REPLACE_EXPM1
1146REPLACE_CEILL
1147REPLACE_CEILF
1148REPLACE_CEIL
1149REPLACE_CBRTL
1150REPLACE_CBRTF
1151HAVE_DECL_TRUNCL
1152HAVE_DECL_TRUNCF
1153HAVE_DECL_TRUNC
1154HAVE_DECL_TANL
1155HAVE_DECL_SQRTL
1156HAVE_DECL_SINL
1157HAVE_DECL_ROUNDL
1158HAVE_DECL_ROUNDF
1159HAVE_DECL_ROUND
1160HAVE_DECL_RINTF
1161HAVE_DECL_REMAINDERL
1162HAVE_DECL_REMAINDER
1163HAVE_DECL_LOGB
1164HAVE_DECL_LOG2L
1165HAVE_DECL_LOG2F
1166HAVE_DECL_LOG2
1167HAVE_DECL_LOG10L
1168HAVE_DECL_LOGL
1169HAVE_DECL_LDEXPL
1170HAVE_DECL_FREXPL
1171HAVE_DECL_FLOORL
1172HAVE_DECL_FLOORF
1173HAVE_DECL_EXPM1L
1174HAVE_DECL_EXP2L
1175HAVE_DECL_EXP2F
1176HAVE_DECL_EXP2
1177HAVE_DECL_EXPL
1178HAVE_DECL_COSL
1179HAVE_DECL_COPYSIGNF
1180HAVE_DECL_CEILL
1181HAVE_DECL_CEILF
1182HAVE_DECL_CBRTL
1183HAVE_DECL_CBRTF
1184HAVE_DECL_ATANL
1185HAVE_DECL_ASINL
1186HAVE_DECL_ACOSL
1187HAVE_TANHF
1188HAVE_TANL
1189HAVE_TANF
1190HAVE_SQRTL
1191HAVE_SQRTF
1192HAVE_SINHF
1193HAVE_SINL
1194HAVE_SINF
1195HAVE_RINTL
1196HAVE_RINT
1197HAVE_REMAINDERF
1198HAVE_REMAINDER
1199HAVE_POWF
1200HAVE_MODFL
1201HAVE_MODFF
1202HAVE_LOGBL
1203HAVE_LOGBF
1204HAVE_LOG1PL
1205HAVE_LOG1PF
1206HAVE_LOG1P
1207HAVE_LOG10L
1208HAVE_LOG10F
1209HAVE_LOGL
1210HAVE_LOGF
1211HAVE_LDEXPF
1212HAVE_ISNANL
1213HAVE_ISNAND
1214HAVE_ISNANF
1215HAVE_ILOGBL
1216HAVE_ILOGBF
1217HAVE_ILOGB
1218HAVE_HYPOTL
1219HAVE_HYPOTF
1220HAVE_FREXPF
1221HAVE_FMODL
1222HAVE_FMODF
1223HAVE_FMAL
1224HAVE_FMAF
1225HAVE_FMA
1226HAVE_FABSL
1227HAVE_FABSF
1228HAVE_EXPM1F
1229HAVE_EXPM1
1230HAVE_EXPL
1231HAVE_EXPF
1232HAVE_COSHF
1233HAVE_COSL
1234HAVE_COSF
1235HAVE_COPYSIGNL
1236HAVE_COPYSIGN
1237HAVE_CBRTL
1238HAVE_CBRTF
1239HAVE_CBRT
1240HAVE_ATAN2F
1241HAVE_ATANL
1242HAVE_ATANF
1243HAVE_ASINL
1244HAVE_ASINF
1245HAVE_ACOSL
1246HAVE_ACOSF
1247GNULIB_TRUNCL
1248GNULIB_TRUNCF
1249GNULIB_TRUNC
1250GNULIB_TANHF
1251GNULIB_TANL
1252GNULIB_TANF
1253GNULIB_SQRTL
1254GNULIB_SQRTF
1255GNULIB_SINHF
1256GNULIB_SINL
1257GNULIB_SINF
1258GNULIB_SIGNBIT
1259GNULIB_ROUNDL
1260GNULIB_ROUNDF
1261GNULIB_ROUND
1262GNULIB_RINTL
1263GNULIB_RINTF
1264GNULIB_RINT
1265GNULIB_REMAINDERL
1266GNULIB_REMAINDERF
1267GNULIB_REMAINDER
1268GNULIB_POWF
1269GNULIB_MODFL
1270GNULIB_MODFF
1271GNULIB_MODF
1272GNULIB_LOGBL
1273GNULIB_LOGBF
1274GNULIB_LOGB
1275GNULIB_LOG2L
1276GNULIB_LOG2F
1277GNULIB_LOG2
1278GNULIB_LOG1PL
1279GNULIB_LOG1PF
1280GNULIB_LOG1P
1281GNULIB_LOG10L
1282GNULIB_LOG10F
1283GNULIB_LOG10
1284GNULIB_LOGL
1285GNULIB_LOGF
1286GNULIB_LOG
1287GNULIB_LDEXPL
1288GNULIB_LDEXPF
1289GNULIB_ISNANL
1290GNULIB_ISNAND
1291GNULIB_ISNANF
1292GNULIB_ISNAN
1293GNULIB_ISINF
1294GNULIB_ISFINITE
1295GNULIB_ILOGBL
1296GNULIB_ILOGBF
1297GNULIB_ILOGB
1298GNULIB_HYPOTL
1299GNULIB_HYPOTF
1300GNULIB_HYPOT
1301GNULIB_FREXPL
1302GNULIB_FREXP
1303GNULIB_FREXPF
1304GNULIB_FMODL
1305GNULIB_FMODF
1306GNULIB_FMOD
1307GNULIB_FMAL
1308GNULIB_FMAF
1309GNULIB_FMA
1310GNULIB_FLOORL
1311GNULIB_FLOORF
1312GNULIB_FLOOR
1313GNULIB_FABSL
1314GNULIB_FABSF
1315GNULIB_EXPM1L
1316GNULIB_EXPM1F
1317GNULIB_EXPM1
1318GNULIB_EXP2L
1319GNULIB_EXP2F
1320GNULIB_EXP2
1321GNULIB_EXPL
1322GNULIB_EXPF
1323GNULIB_COSHF
1324GNULIB_COSL
1325GNULIB_COSF
1326GNULIB_COPYSIGNL
1327GNULIB_COPYSIGNF
1328GNULIB_COPYSIGN
1329GNULIB_CEILL
1330GNULIB_CEILF
1331GNULIB_CEIL
1332GNULIB_CBRTL
1333GNULIB_CBRTF
1334GNULIB_CBRT
1335GNULIB_ATAN2F
1336GNULIB_ATANL
1337GNULIB_ATANF
1338GNULIB_ASINL
1339GNULIB_ASINF
1340GNULIB_ACOSL
1341GNULIB_ACOSF
8690e634
JK
1342GL_GENERATE_FNMATCH_H_FALSE
1343GL_GENERATE_FNMATCH_H_TRUE
1344FNMATCH_H
88b48903
WN
1345REPLACE_ITOLD
1346GL_GENERATE_FLOAT_H_FALSE
1347GL_GENERATE_FLOAT_H_TRUE
1348FLOAT_H
1349NEXT_AS_FIRST_DIRECTIVE_FLOAT_H
1350NEXT_FLOAT_H
18848e28
GF
1351EOVERFLOW_VALUE
1352EOVERFLOW_HIDDEN
1353ENOLINK_VALUE
1354ENOLINK_HIDDEN
1355EMULTIHOP_VALUE
1356EMULTIHOP_HIDDEN
1357GL_GENERATE_ERRNO_H_FALSE
1358GL_GENERATE_ERRNO_H_TRUE
1359ERRNO_H
1360NEXT_AS_FIRST_DIRECTIVE_ERRNO_H
1361NEXT_ERRNO_H
e26b6bb0
TT
1362HAVE_DIRENT_H
1363NEXT_AS_FIRST_DIRECTIVE_DIRENT_H
1364NEXT_DIRENT_H
88b48903
WN
1365PRAGMA_COLUMNS
1366PRAGMA_SYSTEM_HEADER
1367INCLUDE_NEXT_AS_FIRST_DIRECTIVE
1368INCLUDE_NEXT
e26b6bb0
TT
1369REPLACE_FDOPENDIR
1370REPLACE_DIRFD
1371REPLACE_CLOSEDIR
1372REPLACE_OPENDIR
1373HAVE_ALPHASORT
1374HAVE_SCANDIR
1375HAVE_FDOPENDIR
1376HAVE_DECL_FDOPENDIR
1377HAVE_DECL_DIRFD
1378HAVE_CLOSEDIR
1379HAVE_REWINDDIR
1380HAVE_READDIR
1381HAVE_OPENDIR
1382GNULIB_ALPHASORT
1383GNULIB_SCANDIR
1384GNULIB_FDOPENDIR
1385GNULIB_DIRFD
1386GNULIB_CLOSEDIR
1387GNULIB_REWINDDIR
1388GNULIB_READDIR
1389GNULIB_OPENDIR
6a29c58e 1390pkglibexecdir
4a626d0a 1391runstatedir
6a29c58e 1392lispdir
e26b6bb0
TT
1393UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
1394UNISTD_H_HAVE_WINSOCK2_H
1395REPLACE_WRITE
1396REPLACE_USLEEP
1397REPLACE_UNLINKAT
1398REPLACE_UNLINK
1399REPLACE_TTYNAME_R
4a626d0a 1400REPLACE_SYMLINKAT
e26b6bb0
TT
1401REPLACE_SYMLINK
1402REPLACE_SLEEP
1403REPLACE_RMDIR
4a626d0a 1404REPLACE_READLINKAT
e26b6bb0
TT
1405REPLACE_READLINK
1406REPLACE_READ
1407REPLACE_PWRITE
1408REPLACE_PREAD
1409REPLACE_LSEEK
1410REPLACE_LINKAT
1411REPLACE_LINK
1412REPLACE_LCHOWN
1413REPLACE_ISATTY
1414REPLACE_GETPAGESIZE
1415REPLACE_GETGROUPS
1416REPLACE_GETLOGIN_R
4a626d0a 1417REPLACE_GETDTABLESIZE
e26b6bb0
TT
1418REPLACE_GETDOMAINNAME
1419REPLACE_GETCWD
1420REPLACE_FTRUNCATE
1421REPLACE_FCHOWNAT
1422REPLACE_DUP2
1423REPLACE_DUP
1424REPLACE_CLOSE
1425REPLACE_CHOWN
1426HAVE_SYS_PARAM_H
1427HAVE_OS_H
1428HAVE_DECL_TTYNAME_R
1429HAVE_DECL_SETHOSTNAME
1430HAVE_DECL_GETUSERSHELL
1431HAVE_DECL_GETPAGESIZE
1432HAVE_DECL_GETLOGIN_R
1433HAVE_DECL_GETDOMAINNAME
1434HAVE_DECL_FDATASYNC
1435HAVE_DECL_FCHDIR
1436HAVE_DECL_ENVIRON
1437HAVE_USLEEP
1438HAVE_UNLINKAT
1439HAVE_SYMLINKAT
1440HAVE_SYMLINK
1441HAVE_SLEEP
1442HAVE_SETHOSTNAME
1443HAVE_READLINKAT
1444HAVE_READLINK
1445HAVE_PWRITE
1446HAVE_PREAD
1447HAVE_PIPE2
1448HAVE_PIPE
1449HAVE_LINKAT
1450HAVE_LINK
1451HAVE_LCHOWN
1452HAVE_GROUP_MEMBER
1453HAVE_GETPAGESIZE
1454HAVE_GETLOGIN
1455HAVE_GETHOSTNAME
1456HAVE_GETGROUPS
1457HAVE_GETDTABLESIZE
1458HAVE_FTRUNCATE
1459HAVE_FSYNC
1460HAVE_FDATASYNC
1461HAVE_FCHOWNAT
1462HAVE_FCHDIR
1463HAVE_FACCESSAT
1464HAVE_EUIDACCESS
1465HAVE_DUP3
1466HAVE_DUP2
1467HAVE_CHOWN
1468GNULIB_WRITE
1469GNULIB_USLEEP
1470GNULIB_UNLINKAT
1471GNULIB_UNLINK
1472GNULIB_UNISTD_H_SIGPIPE
1473GNULIB_UNISTD_H_NONBLOCKING
1474GNULIB_TTYNAME_R
1475GNULIB_SYMLINKAT
1476GNULIB_SYMLINK
1477GNULIB_SLEEP
1478GNULIB_SETHOSTNAME
1479GNULIB_RMDIR
1480GNULIB_READLINKAT
1481GNULIB_READLINK
1482GNULIB_READ
1483GNULIB_PWRITE
1484GNULIB_PREAD
1485GNULIB_PIPE2
1486GNULIB_PIPE
1487GNULIB_LSEEK
1488GNULIB_LINKAT
1489GNULIB_LINK
1490GNULIB_LCHOWN
1491GNULIB_ISATTY
1492GNULIB_GROUP_MEMBER
1493GNULIB_GETUSERSHELL
1494GNULIB_GETPAGESIZE
1495GNULIB_GETLOGIN_R
1496GNULIB_GETLOGIN
1497GNULIB_GETHOSTNAME
1498GNULIB_GETGROUPS
1499GNULIB_GETDTABLESIZE
1500GNULIB_GETDOMAINNAME
1501GNULIB_GETCWD
1502GNULIB_FTRUNCATE
1503GNULIB_FSYNC
1504GNULIB_FDATASYNC
1505GNULIB_FCHOWNAT
1506GNULIB_FCHDIR
1507GNULIB_FACCESSAT
1508GNULIB_EUIDACCESS
1509GNULIB_ENVIRON
1510GNULIB_DUP3
1511GNULIB_DUP2
1512GNULIB_DUP
1513GNULIB_CLOSE
1514GNULIB_CHOWN
1515GNULIB_CHDIR
98399780
YQ
1516REPLACE_WCTOMB
1517REPLACE_UNSETENV
1518REPLACE_STRTOD
1519REPLACE_SETENV
1520REPLACE_REALPATH
1521REPLACE_REALLOC
1522REPLACE_RANDOM_R
4a626d0a 1523REPLACE_QSORT_R
98399780
YQ
1524REPLACE_PUTENV
1525REPLACE_PTSNAME_R
1526REPLACE_PTSNAME
1527REPLACE_MKSTEMP
1528REPLACE_MBTOWC
1529REPLACE_MALLOC
1530REPLACE_CANONICALIZE_FILE_NAME
1531REPLACE_CALLOC
1532HAVE_DECL_UNSETENV
1533HAVE_UNLOCKPT
1534HAVE_SYS_LOADAVG_H
1535HAVE_STRUCT_RANDOM_DATA
1536HAVE_STRTOULL
1537HAVE_STRTOLL
1538HAVE_STRTOD
1539HAVE_DECL_SETENV
1540HAVE_SETENV
4a626d0a 1541HAVE_SECURE_GETENV
98399780
YQ
1542HAVE_RPMATCH
1543HAVE_REALPATH
1544HAVE_RANDOM_R
1545HAVE_RANDOM_H
1546HAVE_RANDOM
1547HAVE_PTSNAME_R
1548HAVE_PTSNAME
1549HAVE_POSIX_OPENPT
1550HAVE_MKSTEMPS
1551HAVE_MKSTEMP
1552HAVE_MKOSTEMPS
1553HAVE_MKOSTEMP
1554HAVE_MKDTEMP
1555HAVE_GRANTPT
1556HAVE_GETSUBOPT
1557HAVE_DECL_GETLOADAVG
1558HAVE_CANONICALIZE_FILE_NAME
1559HAVE_ATOLL
1560HAVE__EXIT
1561GNULIB_WCTOMB
1562GNULIB_UNSETENV
1563GNULIB_UNLOCKPT
1564GNULIB_SYSTEM_POSIX
1565GNULIB_STRTOULL
1566GNULIB_STRTOLL
1567GNULIB_STRTOD
1568GNULIB_SETENV
4a626d0a 1569GNULIB_SECURE_GETENV
98399780
YQ
1570GNULIB_RPMATCH
1571GNULIB_REALPATH
1572GNULIB_REALLOC_POSIX
1573GNULIB_RANDOM_R
1574GNULIB_RANDOM
4a626d0a 1575GNULIB_QSORT_R
98399780
YQ
1576GNULIB_PUTENV
1577GNULIB_PTSNAME_R
1578GNULIB_PTSNAME
1579GNULIB_POSIX_OPENPT
1580GNULIB_MKSTEMPS
1581GNULIB_MKSTEMP
1582GNULIB_MKOSTEMPS
1583GNULIB_MKOSTEMP
1584GNULIB_MKDTEMP
1585GNULIB_MBTOWC
1586GNULIB_MALLOC_POSIX
1587GNULIB_GRANTPT
1588GNULIB_GETSUBOPT
1589GNULIB_GETLOADAVG
1590GNULIB_CANONICALIZE_FILE_NAME
1591GNULIB_CALLOC_POSIX
1592GNULIB_ATOLL
1593GNULIB__EXIT
8690e634
JK
1594GL_GENERATE_ALLOCA_H_FALSE
1595GL_GENERATE_ALLOCA_H_TRUE
1596ALLOCA_H
1597ALLOCA
c971b7fa
PA
1598GL_COND_LIBTOOL_FALSE
1599GL_COND_LIBTOOL_TRUE
1600target_os
1601target_vendor
1602target_cpu
1603target
c971b7fa
PA
1604host_os
1605host_vendor
1606host_cpu
1607host
1608build_os
1609build_vendor
1610build_cpu
1611build
4a626d0a
PA
1612RANLIB
1613ARFLAGS
1614AR
1615EGREP
1616GREP
1617CPP
c971b7fa
PA
1618OBJEXT
1619EXEEXT
1620ac_ct_CC
1621CPPFLAGS
1622LDFLAGS
1623CFLAGS
1624CC
1625MAINT
1626MAINTAINER_MODE_FALSE
1627MAINTAINER_MODE_TRUE
1628target_alias
1629host_alias
1630build_alias
1631LIBS
1632ECHO_T
1633ECHO_N
1634ECHO_C
1635DEFS
1636mandir
1637localedir
1638libdir
1639psdir
1640pdfdir
1641dvidir
1642htmldir
1643infodir
1644docdir
1645oldincludedir
1646includedir
1647localstatedir
1648sharedstatedir
1649sysconfdir
1650datadir
1651datarootdir
1652libexecdir
1653sbindir
1654bindir
1655program_transform_name
1656prefix
1657exec_prefix
1658PACKAGE_URL
1659PACKAGE_BUGREPORT
1660PACKAGE_STRING
1661PACKAGE_VERSION
1662PACKAGE_TARNAME
1663PACKAGE_NAME
1664PATH_SEPARATOR
1665SHELL'
1666ac_subst_files=''
1667ac_user_opts='
1668enable_option_checking
1669enable_maintainer_mode
2196f55f 1670enable_largefile
c971b7fa
PA
1671enable_dependency_tracking
1672'
1673 ac_precious_vars='build_alias
1674host_alias
1675target_alias
1676CC
1677CFLAGS
1678LDFLAGS
1679LIBS
1680CPPFLAGS
1681CPP'
1682
1683
1684# Initialize some variables set by options.
1685ac_init_help=
1686ac_init_version=false
1687ac_unrecognized_opts=
1688ac_unrecognized_sep=
1689# The variables have the same names as the options, with
1690# dashes changed to underlines.
1691cache_file=/dev/null
1692exec_prefix=NONE
1693no_create=
1694no_recursion=
1695prefix=NONE
1696program_prefix=NONE
1697program_suffix=NONE
1698program_transform_name=s,x,x,
1699silent=
1700site=
1701srcdir=
1702verbose=
1703x_includes=NONE
1704x_libraries=NONE
1705
1706# Installation directory options.
1707# These are left unexpanded so users can "make install exec_prefix=/foo"
1708# and all the variables that are supposed to be based on exec_prefix
1709# by default will actually change.
1710# Use braces instead of parens because sh, perl, etc. also accept them.
1711# (The list follows the same order as the GNU Coding Standards.)
1712bindir='${exec_prefix}/bin'
1713sbindir='${exec_prefix}/sbin'
1714libexecdir='${exec_prefix}/libexec'
1715datarootdir='${prefix}/share'
1716datadir='${datarootdir}'
1717sysconfdir='${prefix}/etc'
1718sharedstatedir='${prefix}/com'
1719localstatedir='${prefix}/var'
1720includedir='${prefix}/include'
1721oldincludedir='/usr/include'
1722docdir='${datarootdir}/doc/${PACKAGE}'
1723infodir='${datarootdir}/info'
1724htmldir='${docdir}'
1725dvidir='${docdir}'
1726pdfdir='${docdir}'
1727psdir='${docdir}'
1728libdir='${exec_prefix}/lib'
1729localedir='${datarootdir}/locale'
1730mandir='${datarootdir}/man'
1731
1732ac_prev=
1733ac_dashdash=
1734for ac_option
1735do
1736 # If the previous option needs an argument, assign it.
1737 if test -n "$ac_prev"; then
1738 eval $ac_prev=\$ac_option
1739 ac_prev=
1740 continue
1741 fi
1742
1743 case $ac_option in
1744 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1745 *) ac_optarg=yes ;;
1746 esac
1747
1748 # Accept the important Cygnus configure options, so we can diagnose typos.
1749
1750 case $ac_dashdash$ac_option in
1751 --)
1752 ac_dashdash=yes ;;
1753
1754 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1755 ac_prev=bindir ;;
1756 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1757 bindir=$ac_optarg ;;
1758
1759 -build | --build | --buil | --bui | --bu)
1760 ac_prev=build_alias ;;
1761 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1762 build_alias=$ac_optarg ;;
1763
1764 -cache-file | --cache-file | --cache-fil | --cache-fi \
1765 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1766 ac_prev=cache_file ;;
1767 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1768 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1769 cache_file=$ac_optarg ;;
1770
1771 --config-cache | -C)
1772 cache_file=config.cache ;;
1773
1774 -datadir | --datadir | --datadi | --datad)
1775 ac_prev=datadir ;;
1776 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1777 datadir=$ac_optarg ;;
1778
1779 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1780 | --dataroo | --dataro | --datar)
1781 ac_prev=datarootdir ;;
1782 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1783 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1784 datarootdir=$ac_optarg ;;
1785
1786 -disable-* | --disable-*)
1787 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1788 # Reject names that are not valid shell variable names.
1789 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1790 as_fn_error "invalid feature name: $ac_useropt"
1791 ac_useropt_orig=$ac_useropt
1792 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1793 case $ac_user_opts in
1794 *"
1795"enable_$ac_useropt"
1796"*) ;;
1797 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1798 ac_unrecognized_sep=', ';;
1799 esac
1800 eval enable_$ac_useropt=no ;;
1801
1802 -docdir | --docdir | --docdi | --doc | --do)
1803 ac_prev=docdir ;;
1804 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1805 docdir=$ac_optarg ;;
1806
1807 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1808 ac_prev=dvidir ;;
1809 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1810 dvidir=$ac_optarg ;;
1811
1812 -enable-* | --enable-*)
1813 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1814 # Reject names that are not valid shell variable names.
1815 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1816 as_fn_error "invalid feature name: $ac_useropt"
1817 ac_useropt_orig=$ac_useropt
1818 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1819 case $ac_user_opts in
1820 *"
1821"enable_$ac_useropt"
1822"*) ;;
1823 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1824 ac_unrecognized_sep=', ';;
1825 esac
1826 eval enable_$ac_useropt=\$ac_optarg ;;
1827
1828 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1829 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1830 | --exec | --exe | --ex)
1831 ac_prev=exec_prefix ;;
1832 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1833 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1834 | --exec=* | --exe=* | --ex=*)
1835 exec_prefix=$ac_optarg ;;
1836
1837 -gas | --gas | --ga | --g)
1838 # Obsolete; use --with-gas.
1839 with_gas=yes ;;
1840
1841 -help | --help | --hel | --he | -h)
1842 ac_init_help=long ;;
1843 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1844 ac_init_help=recursive ;;
1845 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1846 ac_init_help=short ;;
1847
1848 -host | --host | --hos | --ho)
1849 ac_prev=host_alias ;;
1850 -host=* | --host=* | --hos=* | --ho=*)
1851 host_alias=$ac_optarg ;;
1852
1853 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1854 ac_prev=htmldir ;;
1855 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1856 | --ht=*)
1857 htmldir=$ac_optarg ;;
1858
1859 -includedir | --includedir | --includedi | --included | --include \
1860 | --includ | --inclu | --incl | --inc)
1861 ac_prev=includedir ;;
1862 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1863 | --includ=* | --inclu=* | --incl=* | --inc=*)
1864 includedir=$ac_optarg ;;
1865
1866 -infodir | --infodir | --infodi | --infod | --info | --inf)
1867 ac_prev=infodir ;;
1868 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1869 infodir=$ac_optarg ;;
1870
1871 -libdir | --libdir | --libdi | --libd)
1872 ac_prev=libdir ;;
1873 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1874 libdir=$ac_optarg ;;
1875
1876 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1877 | --libexe | --libex | --libe)
1878 ac_prev=libexecdir ;;
1879 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1880 | --libexe=* | --libex=* | --libe=*)
1881 libexecdir=$ac_optarg ;;
1882
1883 -localedir | --localedir | --localedi | --localed | --locale)
1884 ac_prev=localedir ;;
1885 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1886 localedir=$ac_optarg ;;
1887
1888 -localstatedir | --localstatedir | --localstatedi | --localstated \
1889 | --localstate | --localstat | --localsta | --localst | --locals)
1890 ac_prev=localstatedir ;;
1891 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1892 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1893 localstatedir=$ac_optarg ;;
1894
1895 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1896 ac_prev=mandir ;;
1897 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1898 mandir=$ac_optarg ;;
1899
1900 -nfp | --nfp | --nf)
1901 # Obsolete; use --without-fp.
1902 with_fp=no ;;
1903
1904 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1905 | --no-cr | --no-c | -n)
1906 no_create=yes ;;
1907
1908 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1909 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1910 no_recursion=yes ;;
1911
1912 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1913 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1914 | --oldin | --oldi | --old | --ol | --o)
1915 ac_prev=oldincludedir ;;
1916 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1917 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1918 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1919 oldincludedir=$ac_optarg ;;
1920
1921 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1922 ac_prev=prefix ;;
1923 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1924 prefix=$ac_optarg ;;
1925
1926 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1927 | --program-pre | --program-pr | --program-p)
1928 ac_prev=program_prefix ;;
1929 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1930 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1931 program_prefix=$ac_optarg ;;
1932
1933 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1934 | --program-suf | --program-su | --program-s)
1935 ac_prev=program_suffix ;;
1936 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1937 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1938 program_suffix=$ac_optarg ;;
1939
1940 -program-transform-name | --program-transform-name \
1941 | --program-transform-nam | --program-transform-na \
1942 | --program-transform-n | --program-transform- \
1943 | --program-transform | --program-transfor \
1944 | --program-transfo | --program-transf \
1945 | --program-trans | --program-tran \
1946 | --progr-tra | --program-tr | --program-t)
1947 ac_prev=program_transform_name ;;
1948 -program-transform-name=* | --program-transform-name=* \
1949 | --program-transform-nam=* | --program-transform-na=* \
1950 | --program-transform-n=* | --program-transform-=* \
1951 | --program-transform=* | --program-transfor=* \
1952 | --program-transfo=* | --program-transf=* \
1953 | --program-trans=* | --program-tran=* \
1954 | --progr-tra=* | --program-tr=* | --program-t=*)
1955 program_transform_name=$ac_optarg ;;
1956
1957 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1958 ac_prev=pdfdir ;;
1959 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1960 pdfdir=$ac_optarg ;;
1961
1962 -psdir | --psdir | --psdi | --psd | --ps)
1963 ac_prev=psdir ;;
1964 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1965 psdir=$ac_optarg ;;
1966
1967 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1968 | -silent | --silent | --silen | --sile | --sil)
1969 silent=yes ;;
1970
1971 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1972 ac_prev=sbindir ;;
1973 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1974 | --sbi=* | --sb=*)
1975 sbindir=$ac_optarg ;;
1976
1977 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1978 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1979 | --sharedst | --shareds | --shared | --share | --shar \
1980 | --sha | --sh)
1981 ac_prev=sharedstatedir ;;
1982 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1983 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1984 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1985 | --sha=* | --sh=*)
1986 sharedstatedir=$ac_optarg ;;
1987
1988 -site | --site | --sit)
1989 ac_prev=site ;;
1990 -site=* | --site=* | --sit=*)
1991 site=$ac_optarg ;;
1992
1993 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1994 ac_prev=srcdir ;;
1995 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1996 srcdir=$ac_optarg ;;
1997
1998 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1999 | --syscon | --sysco | --sysc | --sys | --sy)
2000 ac_prev=sysconfdir ;;
2001 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
2002 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
2003 sysconfdir=$ac_optarg ;;
2004
2005 -target | --target | --targe | --targ | --tar | --ta | --t)
2006 ac_prev=target_alias ;;
2007 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
2008 target_alias=$ac_optarg ;;
2009
2010 -v | -verbose | --verbose | --verbos | --verbo | --verb)
2011 verbose=yes ;;
2012
2013 -version | --version | --versio | --versi | --vers | -V)
2014 ac_init_version=: ;;
2015
2016 -with-* | --with-*)
2017 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
2018 # Reject names that are not valid shell variable names.
2019 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
2020 as_fn_error "invalid package name: $ac_useropt"
2021 ac_useropt_orig=$ac_useropt
2022 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
2023 case $ac_user_opts in
2024 *"
2025"with_$ac_useropt"
2026"*) ;;
2027 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
2028 ac_unrecognized_sep=', ';;
2029 esac
2030 eval with_$ac_useropt=\$ac_optarg ;;
2031
2032 -without-* | --without-*)
2033 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
2034 # Reject names that are not valid shell variable names.
2035 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
2036 as_fn_error "invalid package name: $ac_useropt"
2037 ac_useropt_orig=$ac_useropt
2038 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
2039 case $ac_user_opts in
2040 *"
2041"with_$ac_useropt"
2042"*) ;;
2043 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
2044 ac_unrecognized_sep=', ';;
2045 esac
2046 eval with_$ac_useropt=no ;;
2047
2048 --x)
2049 # Obsolete; use --with-x.
2050 with_x=yes ;;
2051
2052 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
2053 | --x-incl | --x-inc | --x-in | --x-i)
2054 ac_prev=x_includes ;;
2055 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
2056 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
2057 x_includes=$ac_optarg ;;
2058
2059 -x-libraries | --x-libraries | --x-librarie | --x-librari \
2060 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
2061 ac_prev=x_libraries ;;
2062 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
2063 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
2064 x_libraries=$ac_optarg ;;
2065
2066 -*) as_fn_error "unrecognized option: \`$ac_option'
2067Try \`$0 --help' for more information."
2068 ;;
2069
2070 *=*)
2071 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
2072 # Reject names that are not valid shell variable names.
2073 case $ac_envvar in #(
2074 '' | [0-9]* | *[!_$as_cr_alnum]* )
2075 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
2076 esac
2077 eval $ac_envvar=\$ac_optarg
2078 export $ac_envvar ;;
2079
2080 *)
2081 # FIXME: should be removed in autoconf 3.0.
2082 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
2083 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
2084 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
2085 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
2086 ;;
2087
2088 esac
2089done
2090
2091if test -n "$ac_prev"; then
2092 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
2093 as_fn_error "missing argument to $ac_option"
2094fi
2095
2096if test -n "$ac_unrecognized_opts"; then
2097 case $enable_option_checking in
2098 no) ;;
2099 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
2100 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
2101 esac
2102fi
2103
2104# Check all directory arguments for consistency.
2105for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
2106 datadir sysconfdir sharedstatedir localstatedir includedir \
2107 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
2108 libdir localedir mandir
2109do
2110 eval ac_val=\$$ac_var
2111 # Remove trailing slashes.
2112 case $ac_val in
2113 */ )
2114 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
2115 eval $ac_var=\$ac_val;;
2116 esac
2117 # Be sure to have absolute directory names.
2118 case $ac_val in
2119 [\\/$]* | ?:[\\/]* ) continue;;
2120 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
2121 esac
2122 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
2123done
2124
2125# There might be people who depend on the old broken behavior: `$host'
2126# used to hold the argument of --host etc.
2127# FIXME: To remove some day.
2128build=$build_alias
2129host=$host_alias
2130target=$target_alias
2131
2132# FIXME: To remove some day.
2133if test "x$host_alias" != x; then
2134 if test "x$build_alias" = x; then
2135 cross_compiling=maybe
2136 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
2137 If a cross compiler is detected then cross compile mode will be used." >&2
2138 elif test "x$build_alias" != "x$host_alias"; then
2139 cross_compiling=yes
2140 fi
2141fi
2142
2143ac_tool_prefix=
2144test -n "$host_alias" && ac_tool_prefix=$host_alias-
2145
2146test "$silent" = yes && exec 6>/dev/null
2147
2148
2149ac_pwd=`pwd` && test -n "$ac_pwd" &&
2150ac_ls_di=`ls -di .` &&
2151ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
2152 as_fn_error "working directory cannot be determined"
2153test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
2154 as_fn_error "pwd does not report name of working directory"
2155
2156
2157# Find the source files, if location was not specified.
2158if test -z "$srcdir"; then
2159 ac_srcdir_defaulted=yes
2160 # Try the directory containing this script, then the parent directory.
2161 ac_confdir=`$as_dirname -- "$as_myself" ||
2162$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
2163 X"$as_myself" : 'X\(//\)[^/]' \| \
2164 X"$as_myself" : 'X\(//\)$' \| \
2165 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
2166$as_echo X"$as_myself" |
2167 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
2168 s//\1/
2169 q
2170 }
2171 /^X\(\/\/\)[^/].*/{
2172 s//\1/
2173 q
2174 }
2175 /^X\(\/\/\)$/{
2176 s//\1/
2177 q
2178 }
2179 /^X\(\/\).*/{
2180 s//\1/
2181 q
2182 }
2183 s/.*/./; q'`
2184 srcdir=$ac_confdir
2185 if test ! -r "$srcdir/$ac_unique_file"; then
2186 srcdir=..
2187 fi
2188else
2189 ac_srcdir_defaulted=no
2190fi
2191if test ! -r "$srcdir/$ac_unique_file"; then
2192 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
2193 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
2194fi
2195ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
2196ac_abs_confdir=`(
2197 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
2198 pwd)`
2199# When building in place, set srcdir=.
2200if test "$ac_abs_confdir" = "$ac_pwd"; then
2201 srcdir=.
2202fi
2203# Remove unnecessary trailing slashes from srcdir.
2204# Double slashes in file names in object file debugging info
2205# mess up M-x gdb in Emacs.
2206case $srcdir in
2207*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
2208esac
2209for ac_var in $ac_precious_vars; do
2210 eval ac_env_${ac_var}_set=\${${ac_var}+set}
2211 eval ac_env_${ac_var}_value=\$${ac_var}
2212 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
2213 eval ac_cv_env_${ac_var}_value=\$${ac_var}
2214done
2215
2216#
2217# Report the --help message.
2218#
2219if test "$ac_init_help" = "long"; then
2220 # Omit some internal or obsolete options to make the list less imposing.
2221 # This message is too long to be a string in the A/UX 3.1 sh.
2222 cat <<_ACEOF
2223\`configure' configures this package to adapt to many kinds of systems.
2224
2225Usage: $0 [OPTION]... [VAR=VALUE]...
2226
2227To assign environment variables (e.g., CC, CFLAGS...), specify them as
2228VAR=VALUE. See below for descriptions of some of the useful variables.
2229
2230Defaults for the options are specified in brackets.
2231
2232Configuration:
2233 -h, --help display this help and exit
2234 --help=short display options specific to this package
2235 --help=recursive display the short help of all the included packages
2236 -V, --version display version information and exit
2237 -q, --quiet, --silent do not print \`checking...' messages
2238 --cache-file=FILE cache test results in FILE [disabled]
2239 -C, --config-cache alias for \`--cache-file=config.cache'
2240 -n, --no-create do not create output files
2241 --srcdir=DIR find the sources in DIR [configure dir or \`..']
2242
2243Installation directories:
2244 --prefix=PREFIX install architecture-independent files in PREFIX
2245 [$ac_default_prefix]
2246 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
2247 [PREFIX]
2248
2249By default, \`make install' will install all the files in
2250\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
2251an installation prefix other than \`$ac_default_prefix' using \`--prefix',
2252for instance \`--prefix=\$HOME'.
2253
2254For better control, use the options below.
2255
2256Fine tuning of the installation directories:
2257 --bindir=DIR user executables [EPREFIX/bin]
2258 --sbindir=DIR system admin executables [EPREFIX/sbin]
2259 --libexecdir=DIR program executables [EPREFIX/libexec]
2260 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
2261 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
2262 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
2263 --libdir=DIR object code libraries [EPREFIX/lib]
2264 --includedir=DIR C header files [PREFIX/include]
2265 --oldincludedir=DIR C header files for non-gcc [/usr/include]
2266 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
2267 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
2268 --infodir=DIR info documentation [DATAROOTDIR/info]
2269 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
2270 --mandir=DIR man documentation [DATAROOTDIR/man]
2271 --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE]
2272 --htmldir=DIR html documentation [DOCDIR]
2273 --dvidir=DIR dvi documentation [DOCDIR]
2274 --pdfdir=DIR pdf documentation [DOCDIR]
2275 --psdir=DIR ps documentation [DOCDIR]
2276_ACEOF
2277
2278 cat <<\_ACEOF
2279
2280Program names:
2281 --program-prefix=PREFIX prepend PREFIX to installed program names
2282 --program-suffix=SUFFIX append SUFFIX to installed program names
2283 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
2284
2285System types:
2286 --build=BUILD configure for building on BUILD [guessed]
2287 --host=HOST cross-compile to build programs to run on HOST [BUILD]
2288 --target=TARGET configure for building compilers for TARGET [HOST]
2289_ACEOF
2290fi
2291
2292if test -n "$ac_init_help"; then
2293
2294 cat <<\_ACEOF
2295
2296Optional Features:
2297 --disable-option-checking ignore unrecognized --enable/--with options
2298 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
2299 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
2300 --enable-maintainer-mode enable make rules and dependencies not useful
2301 (and sometimes confusing) to the casual installer
2196f55f 2302 --disable-largefile omit support for large files
c971b7fa
PA
2303 --disable-dependency-tracking speeds up one-time build
2304 --enable-dependency-tracking do not reject slow dependency extractors
2305
2306Some influential environment variables:
2307 CC C compiler command
2308 CFLAGS C compiler flags
2309 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2310 nonstandard directory <lib dir>
2311 LIBS libraries to pass to the linker, e.g. -l<library>
2312 CPPFLAGS C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
2313 you have headers in a nonstandard directory <include dir>
2314 CPP C preprocessor
2315
2316Use these variables to override the choices made by `configure' or to help
2317it to find libraries and programs with nonstandard names/locations.
2318
2319Report bugs to the package provider.
2320_ACEOF
2321ac_status=$?
2322fi
2323
2324if test "$ac_init_help" = "recursive"; then
2325 # If there are subdirs, report their specific --help.
2326 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2327 test -d "$ac_dir" ||
2328 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2329 continue
2330 ac_builddir=.
2331
2332case "$ac_dir" in
2333.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2334*)
2335 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2336 # A ".." for each directory in $ac_dir_suffix.
2337 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2338 case $ac_top_builddir_sub in
2339 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2340 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2341 esac ;;
2342esac
2343ac_abs_top_builddir=$ac_pwd
2344ac_abs_builddir=$ac_pwd$ac_dir_suffix
2345# for backward compatibility:
2346ac_top_builddir=$ac_top_build_prefix
2347
2348case $srcdir in
2349 .) # We are building in place.
2350 ac_srcdir=.
2351 ac_top_srcdir=$ac_top_builddir_sub
2352 ac_abs_top_srcdir=$ac_pwd ;;
2353 [\\/]* | ?:[\\/]* ) # Absolute name.
2354 ac_srcdir=$srcdir$ac_dir_suffix;
2355 ac_top_srcdir=$srcdir
2356 ac_abs_top_srcdir=$srcdir ;;
2357 *) # Relative name.
2358 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2359 ac_top_srcdir=$ac_top_build_prefix$srcdir
2360 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2361esac
2362ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2363
2364 cd "$ac_dir" || { ac_status=$?; continue; }
2365 # Check for guested configure.
2366 if test -f "$ac_srcdir/configure.gnu"; then
2367 echo &&
2368 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2369 elif test -f "$ac_srcdir/configure"; then
2370 echo &&
2371 $SHELL "$ac_srcdir/configure" --help=recursive
2372 else
2373 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2374 fi || ac_status=$?
2375 cd "$ac_pwd" || { ac_status=$?; break; }
2376 done
2377fi
2378
2379test -n "$ac_init_help" && exit $ac_status
2380if $ac_init_version; then
2381 cat <<\_ACEOF
2382configure
2383generated by GNU Autoconf 2.64
2384
2385Copyright (C) 2009 Free Software Foundation, Inc.
2386This configure script is free software; the Free Software Foundation
2387gives unlimited permission to copy, distribute and modify it.
2388_ACEOF
2389 exit
2390fi
2391
2392## ------------------------ ##
2393## Autoconf initialization. ##
2394## ------------------------ ##
2395
2396# ac_fn_c_try_compile LINENO
2397# --------------------------
2398# Try to compile conftest.$ac_ext, and return whether this succeeded.
2399ac_fn_c_try_compile ()
2400{
2401 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2402 rm -f conftest.$ac_objext
2403 if { { ac_try="$ac_compile"
2404case "(($ac_try" in
2405 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2406 *) ac_try_echo=$ac_try;;
2407esac
2408eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2409$as_echo "$ac_try_echo"; } >&5
2410 (eval "$ac_compile") 2>conftest.err
2411 ac_status=$?
2412 if test -s conftest.err; then
2413 grep -v '^ *+' conftest.err >conftest.er1
2414 cat conftest.er1 >&5
2415 mv -f conftest.er1 conftest.err
2416 fi
2417 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2418 test $ac_status = 0; } && {
2419 test -z "$ac_c_werror_flag" ||
2420 test ! -s conftest.err
2421 } && test -s conftest.$ac_objext; then :
2422 ac_retval=0
2423else
2424 $as_echo "$as_me: failed program was:" >&5
2425sed 's/^/| /' conftest.$ac_ext >&5
2426
2427 ac_retval=1
2428fi
2429 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2430 return $ac_retval
2431
2432} # ac_fn_c_try_compile
2433
2434# ac_fn_c_try_cpp LINENO
2435# ----------------------
2436# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2437ac_fn_c_try_cpp ()
2438{
2439 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2440 if { { ac_try="$ac_cpp conftest.$ac_ext"
2441case "(($ac_try" in
2442 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2443 *) ac_try_echo=$ac_try;;
2444esac
2445eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2446$as_echo "$ac_try_echo"; } >&5
2447 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2448 ac_status=$?
2449 if test -s conftest.err; then
2450 grep -v '^ *+' conftest.err >conftest.er1
2451 cat conftest.er1 >&5
2452 mv -f conftest.er1 conftest.err
2453 fi
2454 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2455 test $ac_status = 0; } >/dev/null && {
2456 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2457 test ! -s conftest.err
2458 }; then :
2459 ac_retval=0
2460else
2461 $as_echo "$as_me: failed program was:" >&5
2462sed 's/^/| /' conftest.$ac_ext >&5
2463
2464 ac_retval=1
2465fi
2466 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2467 return $ac_retval
2468
2469} # ac_fn_c_try_cpp
2470
2471# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2472# -------------------------------------------------------
2473# Tests whether HEADER exists, giving a warning if it cannot be compiled using
2474# the include files in INCLUDES and setting the cache variable VAR
2475# accordingly.
2476ac_fn_c_check_header_mongrel ()
2477{
2478 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2479 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2481$as_echo_n "checking for $2... " >&6; }
2482if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2483 $as_echo_n "(cached) " >&6
2484fi
2485eval ac_res=\$$3
2486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2487$as_echo "$ac_res" >&6; }
2488else
2489 # Is the header compilable?
2490{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2491$as_echo_n "checking $2 usability... " >&6; }
2492cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2493/* end confdefs.h. */
2494$4
2495#include <$2>
2496_ACEOF
2497if ac_fn_c_try_compile "$LINENO"; then :
2498 ac_header_compiler=yes
2499else
2500 ac_header_compiler=no
2501fi
2502rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2503{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2504$as_echo "$ac_header_compiler" >&6; }
2505
2506# Is the header present?
2507{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2508$as_echo_n "checking $2 presence... " >&6; }
2509cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2510/* end confdefs.h. */
2511#include <$2>
2512_ACEOF
2513if ac_fn_c_try_cpp "$LINENO"; then :
2514 ac_header_preproc=yes
2515else
2516 ac_header_preproc=no
2517fi
2518rm -f conftest.err conftest.$ac_ext
2519{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2520$as_echo "$ac_header_preproc" >&6; }
2521
2522# So? What about this header?
2523case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2524 yes:no: )
2525 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2526$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2527 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2528$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2529 ;;
2530 no:yes:* )
2531 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2532$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2533 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2534$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2535 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2536$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2537 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2538$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2539 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2540$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2541 ;;
2542esac
2543 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2544$as_echo_n "checking for $2... " >&6; }
2545if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2546 $as_echo_n "(cached) " >&6
2547else
2548 eval "$3=\$ac_header_compiler"
2549fi
2550eval ac_res=\$$3
2551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2552$as_echo "$ac_res" >&6; }
2553fi
2554 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2555
2556} # ac_fn_c_check_header_mongrel
2557
2558# ac_fn_c_try_run LINENO
2559# ----------------------
2560# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2561# that executables *can* be run.
2562ac_fn_c_try_run ()
2563{
2564 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2565 if { { ac_try="$ac_link"
2566case "(($ac_try" in
2567 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2568 *) ac_try_echo=$ac_try;;
2569esac
2570eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2571$as_echo "$ac_try_echo"; } >&5
2572 (eval "$ac_link") 2>&5
2573 ac_status=$?
2574 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2575 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2576 { { case "(($ac_try" in
2577 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2578 *) ac_try_echo=$ac_try;;
2579esac
2580eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2581$as_echo "$ac_try_echo"; } >&5
2582 (eval "$ac_try") 2>&5
2583 ac_status=$?
2584 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2585 test $ac_status = 0; }; }; then :
2586 ac_retval=0
2587else
2588 $as_echo "$as_me: program exited with status $ac_status" >&5
2589 $as_echo "$as_me: failed program was:" >&5
2590sed 's/^/| /' conftest.$ac_ext >&5
2591
2592 ac_retval=$ac_status
2593fi
2594 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2595 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2596 return $ac_retval
2597
2598} # ac_fn_c_try_run
2599
2600# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2601# -------------------------------------------------------
2602# Tests whether HEADER exists and can be compiled using the include files in
2603# INCLUDES, setting the cache variable VAR accordingly.
2604ac_fn_c_check_header_compile ()
2605{
2606 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2607 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2608$as_echo_n "checking for $2... " >&6; }
2609if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2610 $as_echo_n "(cached) " >&6
2611else
2612 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2613/* end confdefs.h. */
2614$4
2615#include <$2>
2616_ACEOF
2617if ac_fn_c_try_compile "$LINENO"; then :
2618 eval "$3=yes"
2619else
2620 eval "$3=no"
2621fi
2622rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2623fi
2624eval ac_res=\$$3
2625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2626$as_echo "$ac_res" >&6; }
2627 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2628
2629} # ac_fn_c_check_header_compile
2630
2631# ac_fn_c_try_link LINENO
2632# -----------------------
2633# Try to link conftest.$ac_ext, and return whether this succeeded.
2634ac_fn_c_try_link ()
2635{
2636 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2637 rm -f conftest.$ac_objext conftest$ac_exeext
2638 if { { ac_try="$ac_link"
2639case "(($ac_try" in
2640 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2641 *) ac_try_echo=$ac_try;;
2642esac
2643eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2644$as_echo "$ac_try_echo"; } >&5
2645 (eval "$ac_link") 2>conftest.err
2646 ac_status=$?
2647 if test -s conftest.err; then
2648 grep -v '^ *+' conftest.err >conftest.er1
2649 cat conftest.er1 >&5
2650 mv -f conftest.er1 conftest.err
2651 fi
2652 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2653 test $ac_status = 0; } && {
2654 test -z "$ac_c_werror_flag" ||
2655 test ! -s conftest.err
2656 } && test -s conftest$ac_exeext && {
2657 test "$cross_compiling" = yes ||
2658 $as_test_x conftest$ac_exeext
2659 }; then :
2660 ac_retval=0
2661else
2662 $as_echo "$as_me: failed program was:" >&5
2663sed 's/^/| /' conftest.$ac_ext >&5
2664
2665 ac_retval=1
2666fi
2667 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2668 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2669 # interfere with the next link command; also delete a directory that is
2670 # left behind by Apple's compiler. We do this before executing the actions.
2671 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2672 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2673 return $ac_retval
2674
2675} # ac_fn_c_try_link
2676
8690e634
JK
2677# ac_fn_c_check_func LINENO FUNC VAR
2678# ----------------------------------
2679# Tests whether FUNC exists, setting the cache variable VAR accordingly
2680ac_fn_c_check_func ()
2681{
2682 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2683 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2684$as_echo_n "checking for $2... " >&6; }
2685if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2686 $as_echo_n "(cached) " >&6
2687else
2688 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2689/* end confdefs.h. */
2690/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2691 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2692#define $2 innocuous_$2
2693
2694/* System header to define __stub macros and hopefully few prototypes,
2695 which can conflict with char $2 (); below.
2696 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2697 <limits.h> exists even on freestanding compilers. */
2698
2699#ifdef __STDC__
2700# include <limits.h>
2701#else
2702# include <assert.h>
2703#endif
2704
2705#undef $2
2706
2707/* Override any GCC internal prototype to avoid an error.
2708 Use char because int might match the return type of a GCC
2709 builtin and then its argument prototype would still apply. */
2710#ifdef __cplusplus
2711extern "C"
2712#endif
2713char $2 ();
2714/* The GNU C library defines this for functions which it implements
2715 to always fail with ENOSYS. Some functions are actually named
2716 something starting with __ and the normal name is an alias. */
2717#if defined __stub_$2 || defined __stub___$2
2718choke me
2719#endif
2720
2721int
2722main ()
2723{
2724return $2 ();
2725 ;
2726 return 0;
2727}
2728_ACEOF
2729if ac_fn_c_try_link "$LINENO"; then :
2730 eval "$3=yes"
2731else
2732 eval "$3=no"
2733fi
2734rm -f core conftest.err conftest.$ac_objext \
2735 conftest$ac_exeext conftest.$ac_ext
2736fi
2737eval ac_res=\$$3
2738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2739$as_echo "$ac_res" >&6; }
2740 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2741
2742} # ac_fn_c_check_func
2743
8986e351
TT
2744# ac_fn_c_check_decl LINENO SYMBOL VAR
2745# ------------------------------------
2746# Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2747ac_fn_c_check_decl ()
2748{
2749 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
2751$as_echo_n "checking whether $2 is declared... " >&6; }
2752if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2753 $as_echo_n "(cached) " >&6
2754else
2755 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2756/* end confdefs.h. */
2757$4
2758int
2759main ()
2760{
2761#ifndef $2
2762 (void) $2;
2763#endif
2764
2765 ;
2766 return 0;
2767}
2768_ACEOF
2769if ac_fn_c_try_compile "$LINENO"; then :
2770 eval "$3=yes"
2771else
2772 eval "$3=no"
2773fi
2774rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2775fi
2776eval ac_res=\$$3
2777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2778$as_echo "$ac_res" >&6; }
2779 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2780
2781} # ac_fn_c_check_decl
2782
c971b7fa
PA
2783# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2784# --------------------------------------------
2785# Tries to find the compile-time value of EXPR in a program that includes
2786# INCLUDES, setting VAR accordingly. Returns whether the value could be
2787# computed
2788ac_fn_c_compute_int ()
2789{
2790 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2791 if test "$cross_compiling" = yes; then
2792 # Depending upon the size, compute the lo and hi bounds.
2793cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2794/* end confdefs.h. */
2795$4
2796int
2797main ()
2798{
2799static int test_array [1 - 2 * !(($2) >= 0)];
2800test_array [0] = 0
2801
2802 ;
2803 return 0;
2804}
2805_ACEOF
2806if ac_fn_c_try_compile "$LINENO"; then :
2807 ac_lo=0 ac_mid=0
2808 while :; do
2809 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2810/* end confdefs.h. */
2811$4
2812int
2813main ()
2814{
2815static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2816test_array [0] = 0
2817
2818 ;
2819 return 0;
2820}
2821_ACEOF
2822if ac_fn_c_try_compile "$LINENO"; then :
2823 ac_hi=$ac_mid; break
2824else
2825 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2826 if test $ac_lo -le $ac_mid; then
2827 ac_lo= ac_hi=
2828 break
2829 fi
2830 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2831fi
2832rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2833 done
2834else
2835 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2836/* end confdefs.h. */
2837$4
2838int
2839main ()
2840{
2841static int test_array [1 - 2 * !(($2) < 0)];
2842test_array [0] = 0
2843
2844 ;
2845 return 0;
2846}
2847_ACEOF
2848if ac_fn_c_try_compile "$LINENO"; then :
2849 ac_hi=-1 ac_mid=-1
2850 while :; do
2851 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2852/* end confdefs.h. */
2853$4
2854int
2855main ()
2856{
2857static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2858test_array [0] = 0
2859
2860 ;
2861 return 0;
2862}
2863_ACEOF
2864if ac_fn_c_try_compile "$LINENO"; then :
2865 ac_lo=$ac_mid; break
2866else
2867 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2868 if test $ac_mid -le $ac_hi; then
2869 ac_lo= ac_hi=
2870 break
2871 fi
2872 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2873fi
2874rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2875 done
2876else
2877 ac_lo= ac_hi=
2878fi
2879rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2880fi
2881rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2882# Binary search between lo and hi bounds.
2883while test "x$ac_lo" != "x$ac_hi"; do
2884 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2885 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2886/* end confdefs.h. */
2887$4
2888int
2889main ()
2890{
2891static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2892test_array [0] = 0
2893
2894 ;
2895 return 0;
2896}
2897_ACEOF
2898if ac_fn_c_try_compile "$LINENO"; then :
2899 ac_hi=$ac_mid
2900else
2901 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2902fi
2903rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2904done
2905case $ac_lo in #((
2906?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2907'') ac_retval=1 ;;
2908esac
2909 else
2910 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2911/* end confdefs.h. */
2912$4
2913static long int longval () { return $2; }
2914static unsigned long int ulongval () { return $2; }
2915#include <stdio.h>
2916#include <stdlib.h>
2917int
2918main ()
2919{
2920
2921 FILE *f = fopen ("conftest.val", "w");
2922 if (! f)
2923 return 1;
2924 if (($2) < 0)
2925 {
2926 long int i = longval ();
2927 if (i != ($2))
2928 return 1;
2929 fprintf (f, "%ld", i);
2930 }
2931 else
2932 {
2933 unsigned long int i = ulongval ();
2934 if (i != ($2))
2935 return 1;
2936 fprintf (f, "%lu", i);
2937 }
2938 /* Do not output a trailing newline, as this causes \r\n confusion
2939 on some platforms. */
2940 return ferror (f) || fclose (f) != 0;
2941
2942 ;
2943 return 0;
2944}
2945_ACEOF
2946if ac_fn_c_try_run "$LINENO"; then :
2947 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2948else
2949 ac_retval=1
2950fi
2951rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2952 conftest.$ac_objext conftest.beam conftest.$ac_ext
2953rm -f conftest.val
2954
2955 fi
2956 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2957 return $ac_retval
2958
2959} # ac_fn_c_compute_int
2960
8690e634
JK
2961# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2962# -------------------------------------------
2963# Tests whether TYPE exists after having included INCLUDES, setting cache
2964# variable VAR accordingly.
2965ac_fn_c_check_type ()
c971b7fa
PA
2966{
2967 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2968 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2969$as_echo_n "checking for $2... " >&6; }
2970if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2971 $as_echo_n "(cached) " >&6
2972else
8690e634 2973 eval "$3=no"
c971b7fa
PA
2974 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2975/* end confdefs.h. */
8690e634 2976$4
c971b7fa
PA
2977int
2978main ()
2979{
8690e634
JK
2980if (sizeof ($2))
2981 return 0;
c971b7fa
PA
2982 ;
2983 return 0;
2984}
2985_ACEOF
8690e634 2986if ac_fn_c_try_compile "$LINENO"; then :
c971b7fa
PA
2987 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2988/* end confdefs.h. */
2989$4
2990int
2991main ()
2992{
8690e634
JK
2993if (sizeof (($2)))
2994 return 0;
c971b7fa
PA
2995 ;
2996 return 0;
2997}
2998_ACEOF
2999if ac_fn_c_try_compile "$LINENO"; then :
8690e634 3000
c971b7fa 3001else
8690e634
JK
3002 eval "$3=yes"
3003fi
3004rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c971b7fa
PA
3005fi
3006rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3007fi
3008eval ac_res=\$$3
3009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
3010$as_echo "$ac_res" >&6; }
3011 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
3012
8690e634 3013} # ac_fn_c_check_type
c971b7fa
PA
3014cat >config.log <<_ACEOF
3015This file contains any messages produced by compilers while
3016running configure, to aid debugging if configure makes a mistake.
3017
3018It was created by $as_me, which was
3019generated by GNU Autoconf 2.64. Invocation command line was
3020
3021 $ $0 $@
3022
3023_ACEOF
3024exec 5>>config.log
3025{
3026cat <<_ASUNAME
3027## --------- ##
3028## Platform. ##
3029## --------- ##
3030
3031hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
3032uname -m = `(uname -m) 2>/dev/null || echo unknown`
3033uname -r = `(uname -r) 2>/dev/null || echo unknown`
3034uname -s = `(uname -s) 2>/dev/null || echo unknown`
3035uname -v = `(uname -v) 2>/dev/null || echo unknown`
3036
3037/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
3038/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
3039
3040/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
3041/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
3042/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
3043/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
3044/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
3045/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
3046/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
3047
3048_ASUNAME
3049
3050as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3051for as_dir in $PATH
3052do
3053 IFS=$as_save_IFS
3054 test -z "$as_dir" && as_dir=.
3055 $as_echo "PATH: $as_dir"
3056 done
3057IFS=$as_save_IFS
3058
3059} >&5
3060
3061cat >&5 <<_ACEOF
3062
3063
3064## ----------- ##
3065## Core tests. ##
3066## ----------- ##
3067
3068_ACEOF
3069
3070
3071# Keep a trace of the command line.
3072# Strip out --no-create and --no-recursion so they do not pile up.
3073# Strip out --silent because we don't want to record it for future runs.
3074# Also quote any args containing shell meta-characters.
3075# Make two passes to allow for proper duplicate-argument suppression.
3076ac_configure_args=
3077ac_configure_args0=
3078ac_configure_args1=
3079ac_must_keep_next=false
3080for ac_pass in 1 2
3081do
3082 for ac_arg
3083 do
3084 case $ac_arg in
3085 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
3086 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
3087 | -silent | --silent | --silen | --sile | --sil)
3088 continue ;;
3089 *\'*)
3090 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
3091 esac
3092 case $ac_pass in
3093 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
3094 2)
3095 as_fn_append ac_configure_args1 " '$ac_arg'"
3096 if test $ac_must_keep_next = true; then
3097 ac_must_keep_next=false # Got value, back to normal.
3098 else
3099 case $ac_arg in
3100 *=* | --config-cache | -C | -disable-* | --disable-* \
3101 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
3102 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
3103 | -with-* | --with-* | -without-* | --without-* | --x)
3104 case "$ac_configure_args0 " in
3105 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
3106 esac
3107 ;;
3108 -* ) ac_must_keep_next=true ;;
3109 esac
3110 fi
3111 as_fn_append ac_configure_args " '$ac_arg'"
3112 ;;
3113 esac
3114 done
3115done
3116{ ac_configure_args0=; unset ac_configure_args0;}
3117{ ac_configure_args1=; unset ac_configure_args1;}
3118
3119# When interrupted or exit'd, cleanup temporary files, and complete
3120# config.log. We remove comments because anyway the quotes in there
3121# would cause problems or look ugly.
3122# WARNING: Use '\'' to represent an apostrophe within the trap.
3123# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3124trap 'exit_status=$?
3125 # Save into config.log some information that might help in debugging.
3126 {
3127 echo
3128
3129 cat <<\_ASBOX
3130## ---------------- ##
3131## Cache variables. ##
3132## ---------------- ##
3133_ASBOX
3134 echo
3135 # The following way of writing the cache mishandles newlines in values,
3136(
3137 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3138 eval ac_val=\$$ac_var
3139 case $ac_val in #(
3140 *${as_nl}*)
3141 case $ac_var in #(
3142 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3143$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3144 esac
3145 case $ac_var in #(
3146 _ | IFS | as_nl) ;; #(
3147 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3148 *) { eval $ac_var=; unset $ac_var;} ;;
3149 esac ;;
3150 esac
3151 done
3152 (set) 2>&1 |
3153 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3154 *${as_nl}ac_space=\ *)
3155 sed -n \
3156 "s/'\''/'\''\\\\'\'''\''/g;
3157 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3158 ;; #(
3159 *)
3160 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3161 ;;
3162 esac |
3163 sort
3164)
3165 echo
3166
3167 cat <<\_ASBOX
3168## ----------------- ##
3169## Output variables. ##
3170## ----------------- ##
3171_ASBOX
3172 echo
3173 for ac_var in $ac_subst_vars
3174 do
3175 eval ac_val=\$$ac_var
3176 case $ac_val in
3177 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3178 esac
3179 $as_echo "$ac_var='\''$ac_val'\''"
3180 done | sort
3181 echo
3182
3183 if test -n "$ac_subst_files"; then
3184 cat <<\_ASBOX
3185## ------------------- ##
3186## File substitutions. ##
3187## ------------------- ##
3188_ASBOX
3189 echo
3190 for ac_var in $ac_subst_files
3191 do
3192 eval ac_val=\$$ac_var
3193 case $ac_val in
3194 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3195 esac
3196 $as_echo "$ac_var='\''$ac_val'\''"
3197 done | sort
3198 echo
3199 fi
3200
3201 if test -s confdefs.h; then
3202 cat <<\_ASBOX
3203## ----------- ##
3204## confdefs.h. ##
3205## ----------- ##
3206_ASBOX
3207 echo
3208 cat confdefs.h
3209 echo
3210 fi
3211 test "$ac_signal" != 0 &&
3212 $as_echo "$as_me: caught signal $ac_signal"
3213 $as_echo "$as_me: exit $exit_status"
3214 } >&5
3215 rm -f core *.core core.conftest.* &&
3216 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3217 exit $exit_status
3218' 0
3219for ac_signal in 1 2 13 15; do
3220 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3221done
3222ac_signal=0
3223
3224# confdefs.h avoids OS command line length limits that DEFS can exceed.
3225rm -f -r conftest* confdefs.h
3226
3227$as_echo "/* confdefs.h */" > confdefs.h
3228
3229# Predefined preprocessor variables.
3230
3231cat >>confdefs.h <<_ACEOF
3232#define PACKAGE_NAME "$PACKAGE_NAME"
3233_ACEOF
3234
3235cat >>confdefs.h <<_ACEOF
3236#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3237_ACEOF
3238
3239cat >>confdefs.h <<_ACEOF
3240#define PACKAGE_VERSION "$PACKAGE_VERSION"
3241_ACEOF
3242
3243cat >>confdefs.h <<_ACEOF
3244#define PACKAGE_STRING "$PACKAGE_STRING"
3245_ACEOF
3246
3247cat >>confdefs.h <<_ACEOF
3248#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3249_ACEOF
3250
3251cat >>confdefs.h <<_ACEOF
3252#define PACKAGE_URL "$PACKAGE_URL"
3253_ACEOF
3254
3255
3256# Let the site file select an alternate cache file if it wants to.
3257# Prefer an explicitly selected file to automatically selected ones.
3258ac_site_file1=NONE
3259ac_site_file2=NONE
3260if test -n "$CONFIG_SITE"; then
3261 ac_site_file1=$CONFIG_SITE
3262elif test "x$prefix" != xNONE; then
3263 ac_site_file1=$prefix/share/config.site
3264 ac_site_file2=$prefix/etc/config.site
3265else
3266 ac_site_file1=$ac_default_prefix/share/config.site
3267 ac_site_file2=$ac_default_prefix/etc/config.site
3268fi
3269for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3270do
3271 test "x$ac_site_file" = xNONE && continue
3272 if test -r "$ac_site_file"; then
3273 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3274$as_echo "$as_me: loading site script $ac_site_file" >&6;}
3275 sed 's/^/| /' "$ac_site_file" >&5
3276 . "$ac_site_file"
3277 fi
3278done
3279
3280if test -r "$cache_file"; then
3281 # Some versions of bash will fail to source /dev/null (special
3282 # files actually), so we avoid doing that.
3283 if test -f "$cache_file"; then
3284 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3285$as_echo "$as_me: loading cache $cache_file" >&6;}
3286 case $cache_file in
3287 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3288 *) . "./$cache_file";;
3289 esac
3290 fi
3291else
3292 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3293$as_echo "$as_me: creating cache $cache_file" >&6;}
3294 >$cache_file
3295fi
3296
98399780
YQ
3297as_fn_append ac_func_list " canonicalize_file_name"
3298as_fn_append ac_func_list " getcwd"
3299as_fn_append ac_func_list " readlink"
3300as_fn_append ac_func_list " realpath"
3301as_fn_append ac_header_list " sys/param.h"
e26b6bb0 3302as_fn_append ac_header_list " dirent.h"
3574124b
PA
3303as_fn_append ac_func_list " btowc"
3304as_fn_append ac_func_list " isblank"
3305as_fn_append ac_func_list " iswctype"
3306as_fn_append ac_func_list " mbsrtowcs"
3307as_fn_append ac_func_list " mempcpy"
3308as_fn_append ac_func_list " wmemchr"
3309as_fn_append ac_func_list " wmemcpy"
3310as_fn_append ac_func_list " wmempcpy"
3311as_fn_append ac_header_list " wctype.h"
8690e634 3312gl_fnmatch_required=GNU
4a626d0a
PA
3313as_fn_append ac_header_list " sys/time.h"
3314as_fn_append ac_header_list " sys/socket.h"
3315as_fn_append ac_func_list " gettimeofday"
3574124b
PA
3316as_fn_append ac_header_list " wchar.h"
3317as_fn_append ac_header_list " stdint.h"
3318as_fn_append ac_header_list " inttypes.h"
3319as_fn_append ac_header_list " unistd.h"
3320as_fn_append ac_func_list " symlink"
f45c62c4 3321as_fn_append ac_func_list " lstat"
3574124b
PA
3322as_fn_append ac_header_list " math.h"
3323as_fn_append ac_func_list " mbsinit"
3324as_fn_append ac_func_list " mbrtowc"
3325as_fn_append ac_header_list " sys/mman.h"
3326as_fn_append ac_func_list " mprotect"
6a29c58e 3327as_fn_append ac_func_list " link"
09607c9e 3328as_fn_append ac_header_list " sys/stat.h"
3574124b
PA
3329as_fn_append ac_header_list " features.h"
3330as_fn_append ac_func_list " iswcntrl"
c971b7fa
PA
3331# Check that the precious variables saved in the cache have kept the same
3332# value.
3333ac_cache_corrupted=false
3334for ac_var in $ac_precious_vars; do
3335 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3336 eval ac_new_set=\$ac_env_${ac_var}_set
3337 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3338 eval ac_new_val=\$ac_env_${ac_var}_value
3339 case $ac_old_set,$ac_new_set in
3340 set,)
3341 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3342$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3343 ac_cache_corrupted=: ;;
3344 ,set)
3345 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3346$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3347 ac_cache_corrupted=: ;;
3348 ,);;
3349 *)
3350 if test "x$ac_old_val" != "x$ac_new_val"; then
3351 # differences in whitespace do not lead to failure.
3352 ac_old_val_w=`echo x $ac_old_val`
3353 ac_new_val_w=`echo x $ac_new_val`
3354 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3355 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3356$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3357 ac_cache_corrupted=:
3358 else
3359 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3360$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3361 eval $ac_var=\$ac_old_val
3362 fi
3363 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3364$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3365 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3366$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3367 fi;;
3368 esac
3369 # Pass precious variables to config.status.
3370 if test "$ac_new_set" = set; then
3371 case $ac_new_val in
3372 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3373 *) ac_arg=$ac_var=$ac_new_val ;;
3374 esac
3375 case " $ac_configure_args " in
3376 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3377 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3378 esac
3379 fi
3380done
3381if $ac_cache_corrupted; then
3382 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3383$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3384 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3385$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3386 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3387fi
3388## -------------------- ##
3389## Main body of script. ##
3390## -------------------- ##
3391
3392ac_ext=c
3393ac_cpp='$CPP $CPPFLAGS'
3394ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3395ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3396ac_compiler_gnu=$ac_cv_c_compiler_gnu
3397
3398
3399ac_config_headers="$ac_config_headers config.h:config.in"
3400
3401
3402{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
3403$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
3404 # Check whether --enable-maintainer-mode was given.
3405if test "${enable_maintainer_mode+set}" = set; then :
3406 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
3407else
3408 USE_MAINTAINER_MODE=no
3409fi
3410
3411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
3412$as_echo "$USE_MAINTAINER_MODE" >&6; }
3413 if test $USE_MAINTAINER_MODE = yes; then
3414 MAINTAINER_MODE_TRUE=
3415 MAINTAINER_MODE_FALSE='#'
3416else
3417 MAINTAINER_MODE_TRUE='#'
3418 MAINTAINER_MODE_FALSE=
3419fi
3420
3421 MAINT=$MAINTAINER_MODE_TRUE
3422
3423
3424
3425ac_ext=c
3426ac_cpp='$CPP $CPPFLAGS'
3427ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3428ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3429ac_compiler_gnu=$ac_cv_c_compiler_gnu
3430if test -n "$ac_tool_prefix"; then
3431 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3432set dummy ${ac_tool_prefix}gcc; ac_word=$2
3433{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3434$as_echo_n "checking for $ac_word... " >&6; }
3435if test "${ac_cv_prog_CC+set}" = set; then :
3436 $as_echo_n "(cached) " >&6
3437else
3438 if test -n "$CC"; then
3439 ac_cv_prog_CC="$CC" # Let the user override the test.
3440else
3441as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3442for as_dir in $PATH
3443do
3444 IFS=$as_save_IFS
3445 test -z "$as_dir" && as_dir=.
3446 for ac_exec_ext in '' $ac_executable_extensions; do
3447 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3448 ac_cv_prog_CC="${ac_tool_prefix}gcc"
3449 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3450 break 2
3451 fi
3452done
3453 done
3454IFS=$as_save_IFS
3455
3456fi
3457fi
3458CC=$ac_cv_prog_CC
3459if test -n "$CC"; then
3460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3461$as_echo "$CC" >&6; }
3462else
3463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3464$as_echo "no" >&6; }
3465fi
3466
3467
3468fi
3469if test -z "$ac_cv_prog_CC"; then
3470 ac_ct_CC=$CC
3471 # Extract the first word of "gcc", so it can be a program name with args.
3472set dummy gcc; ac_word=$2
3473{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3474$as_echo_n "checking for $ac_word... " >&6; }
3475if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
3476 $as_echo_n "(cached) " >&6
3477else
3478 if test -n "$ac_ct_CC"; then
3479 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3480else
3481as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3482for as_dir in $PATH
3483do
3484 IFS=$as_save_IFS
3485 test -z "$as_dir" && as_dir=.
3486 for ac_exec_ext in '' $ac_executable_extensions; do
3487 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3488 ac_cv_prog_ac_ct_CC="gcc"
3489 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3490 break 2
3491 fi
3492done
3493 done
3494IFS=$as_save_IFS
3495
3496fi
3497fi
3498ac_ct_CC=$ac_cv_prog_ac_ct_CC
3499if test -n "$ac_ct_CC"; then
3500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3501$as_echo "$ac_ct_CC" >&6; }
3502else
3503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3504$as_echo "no" >&6; }
3505fi
3506
3507 if test "x$ac_ct_CC" = x; then
3508 CC=""
3509 else
3510 case $cross_compiling:$ac_tool_warned in
3511yes:)
3512{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3513$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3514ac_tool_warned=yes ;;
3515esac
3516 CC=$ac_ct_CC
3517 fi
3518else
3519 CC="$ac_cv_prog_CC"
3520fi
3521
3522if test -z "$CC"; then
3523 if test -n "$ac_tool_prefix"; then
3524 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3525set dummy ${ac_tool_prefix}cc; ac_word=$2
3526{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3527$as_echo_n "checking for $ac_word... " >&6; }
3528if test "${ac_cv_prog_CC+set}" = set; then :
3529 $as_echo_n "(cached) " >&6
3530else
3531 if test -n "$CC"; then
3532 ac_cv_prog_CC="$CC" # Let the user override the test.
3533else
3534as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3535for as_dir in $PATH
3536do
3537 IFS=$as_save_IFS
3538 test -z "$as_dir" && as_dir=.
3539 for ac_exec_ext in '' $ac_executable_extensions; do
3540 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3541 ac_cv_prog_CC="${ac_tool_prefix}cc"
3542 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3543 break 2
3544 fi
3545done
3546 done
3547IFS=$as_save_IFS
3548
3549fi
3550fi
3551CC=$ac_cv_prog_CC
3552if test -n "$CC"; then
3553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3554$as_echo "$CC" >&6; }
3555else
3556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3557$as_echo "no" >&6; }
3558fi
3559
3560
3561 fi
3562fi
3563if test -z "$CC"; then
3564 # Extract the first word of "cc", so it can be a program name with args.
3565set dummy cc; ac_word=$2
3566{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3567$as_echo_n "checking for $ac_word... " >&6; }
3568if test "${ac_cv_prog_CC+set}" = set; then :
3569 $as_echo_n "(cached) " >&6
3570else
3571 if test -n "$CC"; then
3572 ac_cv_prog_CC="$CC" # Let the user override the test.
3573else
3574 ac_prog_rejected=no
3575as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3576for as_dir in $PATH
3577do
3578 IFS=$as_save_IFS
3579 test -z "$as_dir" && as_dir=.
3580 for ac_exec_ext in '' $ac_executable_extensions; do
3581 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3582 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3583 ac_prog_rejected=yes
3584 continue
3585 fi
3586 ac_cv_prog_CC="cc"
3587 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3588 break 2
3589 fi
3590done
3591 done
3592IFS=$as_save_IFS
3593
3594if test $ac_prog_rejected = yes; then
3595 # We found a bogon in the path, so make sure we never use it.
3596 set dummy $ac_cv_prog_CC
3597 shift
3598 if test $# != 0; then
3599 # We chose a different compiler from the bogus one.
3600 # However, it has the same basename, so the bogon will be chosen
3601 # first if we set CC to just the basename; use the full file name.
3602 shift
3603 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3604 fi
3605fi
3606fi
3607fi
3608CC=$ac_cv_prog_CC
3609if test -n "$CC"; then
3610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3611$as_echo "$CC" >&6; }
3612else
3613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3614$as_echo "no" >&6; }
3615fi
3616
3617
3618fi
3619if test -z "$CC"; then
3620 if test -n "$ac_tool_prefix"; then
3621 for ac_prog in cl.exe
3622 do
3623 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3624set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3625{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3626$as_echo_n "checking for $ac_word... " >&6; }
3627if test "${ac_cv_prog_CC+set}" = set; then :
3628 $as_echo_n "(cached) " >&6
3629else
3630 if test -n "$CC"; then
3631 ac_cv_prog_CC="$CC" # Let the user override the test.
3632else
3633as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3634for as_dir in $PATH
3635do
3636 IFS=$as_save_IFS
3637 test -z "$as_dir" && as_dir=.
3638 for ac_exec_ext in '' $ac_executable_extensions; do
3639 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3640 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3641 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3642 break 2
3643 fi
3644done
3645 done
3646IFS=$as_save_IFS
3647
3648fi
3649fi
3650CC=$ac_cv_prog_CC
3651if test -n "$CC"; then
3652 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3653$as_echo "$CC" >&6; }
3654else
3655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3656$as_echo "no" >&6; }
3657fi
3658
3659
3660 test -n "$CC" && break
3661 done
3662fi
3663if test -z "$CC"; then
3664 ac_ct_CC=$CC
3665 for ac_prog in cl.exe
3666do
3667 # Extract the first word of "$ac_prog", so it can be a program name with args.
3668set dummy $ac_prog; ac_word=$2
3669{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3670$as_echo_n "checking for $ac_word... " >&6; }
3671if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
3672 $as_echo_n "(cached) " >&6
3673else
3674 if test -n "$ac_ct_CC"; then
3675 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3676else
3677as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3678for as_dir in $PATH
3679do
3680 IFS=$as_save_IFS
3681 test -z "$as_dir" && as_dir=.
3682 for ac_exec_ext in '' $ac_executable_extensions; do
3683 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3684 ac_cv_prog_ac_ct_CC="$ac_prog"
3685 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3686 break 2
3687 fi
3688done
3689 done
3690IFS=$as_save_IFS
3691
3692fi
3693fi
3694ac_ct_CC=$ac_cv_prog_ac_ct_CC
3695if test -n "$ac_ct_CC"; then
3696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3697$as_echo "$ac_ct_CC" >&6; }
3698else
3699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3700$as_echo "no" >&6; }
3701fi
3702
3703
3704 test -n "$ac_ct_CC" && break
3705done
3706
3707 if test "x$ac_ct_CC" = x; then
3708 CC=""
3709 else
3710 case $cross_compiling:$ac_tool_warned in
3711yes:)
3712{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3713$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3714ac_tool_warned=yes ;;
3715esac
3716 CC=$ac_ct_CC
3717 fi
3718fi
3719
3720fi
3721
3722
3723test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3724$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3725as_fn_error "no acceptable C compiler found in \$PATH
3726See \`config.log' for more details." "$LINENO" 5; }
3727
3728# Provide some information about the compiler.
3729$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3730set X $ac_compile
3731ac_compiler=$2
3732for ac_option in --version -v -V -qversion; do
3733 { { ac_try="$ac_compiler $ac_option >&5"
3734case "(($ac_try" in
3735 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3736 *) ac_try_echo=$ac_try;;
3737esac
3738eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3739$as_echo "$ac_try_echo"; } >&5
3740 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3741 ac_status=$?
3742 if test -s conftest.err; then
3743 sed '10a\
3744... rest of stderr output deleted ...
3745 10q' conftest.err >conftest.er1
3746 cat conftest.er1 >&5
3747 rm -f conftest.er1 conftest.err
3748 fi
3749 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3750 test $ac_status = 0; }
3751done
3752
3753cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3754/* end confdefs.h. */
3755#include <stdio.h>
3756int
3757main ()
3758{
3759FILE *f = fopen ("conftest.out", "w");
3760 return ferror (f) || fclose (f) != 0;
3761
3762 ;
3763 return 0;
3764}
3765_ACEOF
3766ac_clean_files_save=$ac_clean_files
3767ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out conftest.out"
3768# Try to create an executable without -o first, disregard a.out.
3769# It will help us diagnose broken compilers, and finding out an intuition
3770# of exeext.
3771{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3772$as_echo_n "checking for C compiler default output file name... " >&6; }
3773ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3774
3775# The possible output files:
3776ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3777
3778ac_rmfiles=
3779for ac_file in $ac_files
3780do
3781 case $ac_file in
3782 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3783 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3784 esac
3785done
3786rm -f $ac_rmfiles
3787
3788if { { ac_try="$ac_link_default"
3789case "(($ac_try" in
3790 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3791 *) ac_try_echo=$ac_try;;
3792esac
3793eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3794$as_echo "$ac_try_echo"; } >&5
3795 (eval "$ac_link_default") 2>&5
3796 ac_status=$?
3797 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3798 test $ac_status = 0; }; then :
3799 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3800# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3801# in a Makefile. We should not override ac_cv_exeext if it was cached,
3802# so that the user can short-circuit this test for compilers unknown to
3803# Autoconf.
3804for ac_file in $ac_files ''
3805do
3806 test -f "$ac_file" || continue
3807 case $ac_file in
3808 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3809 ;;
3810 [ab].out )
3811 # We found the default executable, but exeext='' is most
3812 # certainly right.
3813 break;;
3814 *.* )
3815 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3816 then :; else
3817 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3818 fi
3819 # We set ac_cv_exeext here because the later test for it is not
3820 # safe: cross compilers may not add the suffix if given an `-o'
3821 # argument, so we may need to know it at that point already.
3822 # Even if this section looks crufty: it has the advantage of
3823 # actually working.
3824 break;;
3825 * )
3826 break;;
3827 esac
3828done
3829test "$ac_cv_exeext" = no && ac_cv_exeext=
3830
3831else
3832 ac_file=''
3833fi
3834{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3835$as_echo "$ac_file" >&6; }
3836if test -z "$ac_file"; then :
3837 $as_echo "$as_me: failed program was:" >&5
3838sed 's/^/| /' conftest.$ac_ext >&5
3839
3840{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3841$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3842{ as_fn_set_status 77
3843as_fn_error "C compiler cannot create executables
3844See \`config.log' for more details." "$LINENO" 5; }; }
3845fi
3846ac_exeext=$ac_cv_exeext
3847
3848# Check that the compiler produces executables we can run. If not, either
3849# the compiler is broken, or we cross compile.
3850{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3851$as_echo_n "checking whether the C compiler works... " >&6; }
3852# If not cross compiling, check that we can run a simple program.
3853if test "$cross_compiling" != yes; then
3854 if { ac_try='./$ac_file'
3855 { { case "(($ac_try" in
3856 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3857 *) ac_try_echo=$ac_try;;
3858esac
3859eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3860$as_echo "$ac_try_echo"; } >&5
3861 (eval "$ac_try") 2>&5
3862 ac_status=$?
3863 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3864 test $ac_status = 0; }; }; then
3865 cross_compiling=no
3866 else
3867 if test "$cross_compiling" = maybe; then
3868 cross_compiling=yes
3869 else
3870 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3871$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3872as_fn_error "cannot run C compiled programs.
3873If you meant to cross compile, use \`--host'.
3874See \`config.log' for more details." "$LINENO" 5; }
3875 fi
3876 fi
3877fi
3878{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3879$as_echo "yes" >&6; }
3880
3881rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out conftest.out
3882ac_clean_files=$ac_clean_files_save
3883# Check that the compiler produces executables we can run. If not, either
3884# the compiler is broken, or we cross compile.
3885{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3886$as_echo_n "checking whether we are cross compiling... " >&6; }
3887{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3888$as_echo "$cross_compiling" >&6; }
3889
3890{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3891$as_echo_n "checking for suffix of executables... " >&6; }
3892if { { ac_try="$ac_link"
3893case "(($ac_try" in
3894 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3895 *) ac_try_echo=$ac_try;;
3896esac
3897eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3898$as_echo "$ac_try_echo"; } >&5
3899 (eval "$ac_link") 2>&5
3900 ac_status=$?
3901 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3902 test $ac_status = 0; }; then :
3903 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3904# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3905# work properly (i.e., refer to `conftest.exe'), while it won't with
3906# `rm'.
3907for ac_file in conftest.exe conftest conftest.*; do
3908 test -f "$ac_file" || continue
3909 case $ac_file in
3910 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3911 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3912 break;;
3913 * ) break;;
3914 esac
3915done
3916else
3917 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3918$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3919as_fn_error "cannot compute suffix of executables: cannot compile and link
3920See \`config.log' for more details." "$LINENO" 5; }
3921fi
3922rm -f conftest$ac_cv_exeext
3923{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3924$as_echo "$ac_cv_exeext" >&6; }
3925
3926rm -f conftest.$ac_ext
3927EXEEXT=$ac_cv_exeext
3928ac_exeext=$EXEEXT
3929{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3930$as_echo_n "checking for suffix of object files... " >&6; }
3931if test "${ac_cv_objext+set}" = set; then :
3932 $as_echo_n "(cached) " >&6
3933else
3934 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3935/* end confdefs.h. */
3936
3937int
3938main ()
3939{
3940
3941 ;
3942 return 0;
3943}
3944_ACEOF
3945rm -f conftest.o conftest.obj
3946if { { ac_try="$ac_compile"
3947case "(($ac_try" in
3948 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3949 *) ac_try_echo=$ac_try;;
3950esac
3951eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3952$as_echo "$ac_try_echo"; } >&5
3953 (eval "$ac_compile") 2>&5
3954 ac_status=$?
3955 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3956 test $ac_status = 0; }; then :
3957 for ac_file in conftest.o conftest.obj conftest.*; do
3958 test -f "$ac_file" || continue;
3959 case $ac_file in
3960 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3961 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3962 break;;
3963 esac
3964done
3965else
3966 $as_echo "$as_me: failed program was:" >&5
3967sed 's/^/| /' conftest.$ac_ext >&5
3968
3969{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3970$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3971as_fn_error "cannot compute suffix of object files: cannot compile
3972See \`config.log' for more details." "$LINENO" 5; }
3973fi
3974rm -f conftest.$ac_cv_objext conftest.$ac_ext
3975fi
3976{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3977$as_echo "$ac_cv_objext" >&6; }
3978OBJEXT=$ac_cv_objext
3979ac_objext=$OBJEXT
3980{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3981$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3982if test "${ac_cv_c_compiler_gnu+set}" = set; then :
3983 $as_echo_n "(cached) " >&6
3984else
3985 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3986/* end confdefs.h. */
3987
3988int
3989main ()
3990{
3991#ifndef __GNUC__
3992 choke me
3993#endif
3994
3995 ;
3996 return 0;
3997}
3998_ACEOF
3999if ac_fn_c_try_compile "$LINENO"; then :
4000 ac_compiler_gnu=yes
4001else
4002 ac_compiler_gnu=no
4003fi
4004rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4005ac_cv_c_compiler_gnu=$ac_compiler_gnu
4006
4007fi
4008{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4009$as_echo "$ac_cv_c_compiler_gnu" >&6; }
4010if test $ac_compiler_gnu = yes; then
4011 GCC=yes
4012else
4013 GCC=
4014fi
4015ac_test_CFLAGS=${CFLAGS+set}
4016ac_save_CFLAGS=$CFLAGS
4017{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4018$as_echo_n "checking whether $CC accepts -g... " >&6; }
4019if test "${ac_cv_prog_cc_g+set}" = set; then :
4020 $as_echo_n "(cached) " >&6
4021else
4022 ac_save_c_werror_flag=$ac_c_werror_flag
4023 ac_c_werror_flag=yes
4024 ac_cv_prog_cc_g=no
4025 CFLAGS="-g"
4026 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4027/* end confdefs.h. */
4028
4029int
4030main ()
4031{
4032
4033 ;
4034 return 0;
4035}
4036_ACEOF
4037if ac_fn_c_try_compile "$LINENO"; then :
4038 ac_cv_prog_cc_g=yes
4039else
4040 CFLAGS=""
4041 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4042/* end confdefs.h. */
4043
4044int
4045main ()
4046{
4047
4048 ;
4049 return 0;
4050}
4051_ACEOF
4052if ac_fn_c_try_compile "$LINENO"; then :
4053
4054else
4055 ac_c_werror_flag=$ac_save_c_werror_flag
4056 CFLAGS="-g"
4057 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4058/* end confdefs.h. */
4059
4060int
4061main ()
4062{
4063
4064 ;
4065 return 0;
4066}
4067_ACEOF
4068if ac_fn_c_try_compile "$LINENO"; then :
4069 ac_cv_prog_cc_g=yes
4070fi
4071rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4072fi
4073rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4074fi
4075rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4076 ac_c_werror_flag=$ac_save_c_werror_flag
4077fi
4078{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4079$as_echo "$ac_cv_prog_cc_g" >&6; }
4080if test "$ac_test_CFLAGS" = set; then
4081 CFLAGS=$ac_save_CFLAGS
4082elif test $ac_cv_prog_cc_g = yes; then
4083 if test "$GCC" = yes; then
4084 CFLAGS="-g -O2"
4085 else
4086 CFLAGS="-g"
4087 fi
4088else
4089 if test "$GCC" = yes; then
4090 CFLAGS="-O2"
4091 else
4092 CFLAGS=
4093 fi
4094fi
4095{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4096$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4097if test "${ac_cv_prog_cc_c89+set}" = set; then :
4098 $as_echo_n "(cached) " >&6
4099else
4100 ac_cv_prog_cc_c89=no
4101ac_save_CC=$CC
4102cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4103/* end confdefs.h. */
4104#include <stdarg.h>
4105#include <stdio.h>
4106#include <sys/types.h>
4107#include <sys/stat.h>
4108/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4109struct buf { int x; };
4110FILE * (*rcsopen) (struct buf *, struct stat *, int);
4111static char *e (p, i)
4112 char **p;
4113 int i;
4114{
4115 return p[i];
4116}
4117static char *f (char * (*g) (char **, int), char **p, ...)
4118{
4119 char *s;
4120 va_list v;
4121 va_start (v,p);
4122 s = g (p, va_arg (v,int));
4123 va_end (v);
4124 return s;
4125}
4126
4127/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
4128 function prototypes and stuff, but not '\xHH' hex character constants.
4129 These don't provoke an error unfortunately, instead are silently treated
4130 as 'x'. The following induces an error, until -std is added to get
4131 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
4132 array size at least. It's necessary to write '\x00'==0 to get something
4133 that's true only with -std. */
4134int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4135
4136/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4137 inside strings and character constants. */
4138#define FOO(x) 'x'
4139int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4140
4141int test (int i, double x);
4142struct s1 {int (*f) (int a);};
4143struct s2 {int (*f) (double a);};
4144int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4145int argc;
4146char **argv;
4147int
4148main ()
4149{
4150return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4151 ;
4152 return 0;
4153}
4154_ACEOF
4155for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4156 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4157do
4158 CC="$ac_save_CC $ac_arg"
4159 if ac_fn_c_try_compile "$LINENO"; then :
4160 ac_cv_prog_cc_c89=$ac_arg
4161fi
4162rm -f core conftest.err conftest.$ac_objext
4163 test "x$ac_cv_prog_cc_c89" != "xno" && break
4164done
4165rm -f conftest.$ac_ext
4166CC=$ac_save_CC
4167
4168fi
4169# AC_CACHE_VAL
4170case "x$ac_cv_prog_cc_c89" in
4171 x)
4172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4173$as_echo "none needed" >&6; } ;;
4174 xno)
4175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4176$as_echo "unsupported" >&6; } ;;
4177 *)
4178 CC="$CC $ac_cv_prog_cc_c89"
4179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4180$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
4181esac
4182if test "x$ac_cv_prog_cc_c89" != xno; then :
4183
4184fi
4185
4186ac_ext=c
4187ac_cpp='$CPP $CPPFLAGS'
4188ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4189ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4190ac_compiler_gnu=$ac_cv_c_compiler_gnu
4191
c971b7fa
PA
4192
4193ac_ext=c
4194ac_cpp='$CPP $CPPFLAGS'
4195ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4196ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4197ac_compiler_gnu=$ac_cv_c_compiler_gnu
4198{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
4199$as_echo_n "checking how to run the C preprocessor... " >&6; }
4200# On Suns, sometimes $CPP names a directory.
4201if test -n "$CPP" && test -d "$CPP"; then
4202 CPP=
4203fi
4204if test -z "$CPP"; then
4205 if test "${ac_cv_prog_CPP+set}" = set; then :
4206 $as_echo_n "(cached) " >&6
4207else
4208 # Double quotes because CPP needs to be expanded
4209 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4210 do
4211 ac_preproc_ok=false
4212for ac_c_preproc_warn_flag in '' yes
4213do
4214 # Use a header file that comes with gcc, so configuring glibc
4215 # with a fresh cross-compiler works.
4216 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4217 # <limits.h> exists even on freestanding compilers.
4218 # On the NeXT, cc -E runs the code through the compiler's parser,
4219 # not just through cpp. "Syntax error" is here to catch this case.
4220 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4221/* end confdefs.h. */
4222#ifdef __STDC__
4223# include <limits.h>
4224#else
4225# include <assert.h>
4226#endif
4227 Syntax error
4228_ACEOF
4229if ac_fn_c_try_cpp "$LINENO"; then :
4230
4231else
4232 # Broken: fails on valid input.
4233continue
4234fi
4235rm -f conftest.err conftest.$ac_ext
4236
4237 # OK, works on sane cases. Now check whether nonexistent headers
4238 # can be detected and how.
4239 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4240/* end confdefs.h. */
4241#include <ac_nonexistent.h>
4242_ACEOF
4243if ac_fn_c_try_cpp "$LINENO"; then :
4244 # Broken: success on invalid input.
4245continue
4246else
4247 # Passes both tests.
4248ac_preproc_ok=:
4249break
4250fi
4251rm -f conftest.err conftest.$ac_ext
4252
4253done
4254# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4255rm -f conftest.err conftest.$ac_ext
4256if $ac_preproc_ok; then :
4257 break
4258fi
4259
4260 done
4261 ac_cv_prog_CPP=$CPP
4262
4263fi
4264 CPP=$ac_cv_prog_CPP
4265else
4266 ac_cv_prog_CPP=$CPP
4267fi
4268{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
4269$as_echo "$CPP" >&6; }
4270ac_preproc_ok=false
4271for ac_c_preproc_warn_flag in '' yes
4272do
4273 # Use a header file that comes with gcc, so configuring glibc
4274 # with a fresh cross-compiler works.
4275 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4276 # <limits.h> exists even on freestanding compilers.
4277 # On the NeXT, cc -E runs the code through the compiler's parser,
4278 # not just through cpp. "Syntax error" is here to catch this case.
4279 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4280/* end confdefs.h. */
4281#ifdef __STDC__
4282# include <limits.h>
4283#else
4284# include <assert.h>
4285#endif
4286 Syntax error
4287_ACEOF
4288if ac_fn_c_try_cpp "$LINENO"; then :
4289
4290else
4291 # Broken: fails on valid input.
4292continue
4293fi
4294rm -f conftest.err conftest.$ac_ext
4295
4296 # OK, works on sane cases. Now check whether nonexistent headers
4297 # can be detected and how.
4298 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4299/* end confdefs.h. */
4300#include <ac_nonexistent.h>
4301_ACEOF
4302if ac_fn_c_try_cpp "$LINENO"; then :
4303 # Broken: success on invalid input.
4304continue
4305else
4306 # Passes both tests.
4307ac_preproc_ok=:
4308break
4309fi
4310rm -f conftest.err conftest.$ac_ext
4311
4312done
4313# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4314rm -f conftest.err conftest.$ac_ext
4315if $ac_preproc_ok; then :
4316
4317else
4318 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4319$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4320as_fn_error "C preprocessor \"$CPP\" fails sanity check
4321See \`config.log' for more details." "$LINENO" 5; }
4322fi
4323
4324ac_ext=c
4325ac_cpp='$CPP $CPPFLAGS'
4326ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4327ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4328ac_compiler_gnu=$ac_cv_c_compiler_gnu
4329
4330
4331{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
4332$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
4333if test "${ac_cv_path_GREP+set}" = set; then :
4334 $as_echo_n "(cached) " >&6
4335else
4336 if test -z "$GREP"; then
4337 ac_path_GREP_found=false
4338 # Loop through the user's path and test for each of PROGNAME-LIST
4339 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4340for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4341do
4342 IFS=$as_save_IFS
4343 test -z "$as_dir" && as_dir=.
4344 for ac_prog in grep ggrep; do
4345 for ac_exec_ext in '' $ac_executable_extensions; do
4346 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
4347 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
4348# Check for GNU ac_path_GREP and select it if it is found.
4349 # Check for GNU $ac_path_GREP
4350case `"$ac_path_GREP" --version 2>&1` in
4351*GNU*)
4352 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4353*)
4354 ac_count=0
4355 $as_echo_n 0123456789 >"conftest.in"
4356 while :
4357 do
4358 cat "conftest.in" "conftest.in" >"conftest.tmp"
4359 mv "conftest.tmp" "conftest.in"
4360 cp "conftest.in" "conftest.nl"
4361 $as_echo 'GREP' >> "conftest.nl"
4362 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4363 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4364 as_fn_arith $ac_count + 1 && ac_count=$as_val
4365 if test $ac_count -gt ${ac_path_GREP_max-0}; then
4366 # Best one so far, save it but keep looking for a better one
4367 ac_cv_path_GREP="$ac_path_GREP"
4368 ac_path_GREP_max=$ac_count
4369 fi
4370 # 10*(2^10) chars as input seems more than enough
4371 test $ac_count -gt 10 && break
4372 done
4373 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4374esac
4375
4376 $ac_path_GREP_found && break 3
4377 done
4378 done
4379 done
4380IFS=$as_save_IFS
4381 if test -z "$ac_cv_path_GREP"; then
4382 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4383 fi
4384else
4385 ac_cv_path_GREP=$GREP
4386fi
4387
4388fi
4389{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4390$as_echo "$ac_cv_path_GREP" >&6; }
4391 GREP="$ac_cv_path_GREP"
4392
4393
4394{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4395$as_echo_n "checking for egrep... " >&6; }
4396if test "${ac_cv_path_EGREP+set}" = set; then :
4397 $as_echo_n "(cached) " >&6
4398else
4399 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4400 then ac_cv_path_EGREP="$GREP -E"
4401 else
4402 if test -z "$EGREP"; then
4403 ac_path_EGREP_found=false
4404 # Loop through the user's path and test for each of PROGNAME-LIST
4405 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4406for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4407do
4408 IFS=$as_save_IFS
4409 test -z "$as_dir" && as_dir=.
4410 for ac_prog in egrep; do
4411 for ac_exec_ext in '' $ac_executable_extensions; do
4412 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4413 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
4414# Check for GNU ac_path_EGREP and select it if it is found.
4415 # Check for GNU $ac_path_EGREP
4416case `"$ac_path_EGREP" --version 2>&1` in
4417*GNU*)
4418 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4419*)
4420 ac_count=0
4421 $as_echo_n 0123456789 >"conftest.in"
4422 while :
4423 do
4424 cat "conftest.in" "conftest.in" >"conftest.tmp"
4425 mv "conftest.tmp" "conftest.in"
4426 cp "conftest.in" "conftest.nl"
4427 $as_echo 'EGREP' >> "conftest.nl"
4428 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4429 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4430 as_fn_arith $ac_count + 1 && ac_count=$as_val
4431 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4432 # Best one so far, save it but keep looking for a better one
4433 ac_cv_path_EGREP="$ac_path_EGREP"
4434 ac_path_EGREP_max=$ac_count
4435 fi
4436 # 10*(2^10) chars as input seems more than enough
4437 test $ac_count -gt 10 && break
4438 done
4439 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4440esac
4441
4442 $ac_path_EGREP_found && break 3
4443 done
4444 done
4445 done
4446IFS=$as_save_IFS
4447 if test -z "$ac_cv_path_EGREP"; then
4448 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4449 fi
4450else
4451 ac_cv_path_EGREP=$EGREP
4452fi
4453
4454 fi
4455fi
4456{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4457$as_echo "$ac_cv_path_EGREP" >&6; }
4458 EGREP="$ac_cv_path_EGREP"
4459
4460
4461{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4462$as_echo_n "checking for ANSI C header files... " >&6; }
4463if test "${ac_cv_header_stdc+set}" = set; then :
4464 $as_echo_n "(cached) " >&6
4465else
4466 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4467/* end confdefs.h. */
4468#include <stdlib.h>
4469#include <stdarg.h>
4470#include <string.h>
4471#include <float.h>
4472
4473int
4474main ()
4475{
4476
4477 ;
4478 return 0;
4479}
4480_ACEOF
4481if ac_fn_c_try_compile "$LINENO"; then :
4482 ac_cv_header_stdc=yes
4483else
4484 ac_cv_header_stdc=no
4485fi
4486rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4487
4488if test $ac_cv_header_stdc = yes; then
4489 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4490 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4491/* end confdefs.h. */
4492#include <string.h>
4493
4494_ACEOF
4495if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4496 $EGREP "memchr" >/dev/null 2>&1; then :
4497
4498else
4499 ac_cv_header_stdc=no
4500fi
4501rm -f conftest*
4502
4503fi
4504
4505if test $ac_cv_header_stdc = yes; then
4506 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4507 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4508/* end confdefs.h. */
4509#include <stdlib.h>
4510
4511_ACEOF
4512if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4513 $EGREP "free" >/dev/null 2>&1; then :
4514
4515else
4516 ac_cv_header_stdc=no
4517fi
4518rm -f conftest*
4519
4520fi
4521
4522if test $ac_cv_header_stdc = yes; then
4523 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4524 if test "$cross_compiling" = yes; then :
4525 :
4526else
4527 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4528/* end confdefs.h. */
4529#include <ctype.h>
4530#include <stdlib.h>
4531#if ((' ' & 0x0FF) == 0x020)
4532# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4533# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4534#else
4535# define ISLOWER(c) \
4536 (('a' <= (c) && (c) <= 'i') \
4537 || ('j' <= (c) && (c) <= 'r') \
4538 || ('s' <= (c) && (c) <= 'z'))
4539# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4540#endif
4541
4542#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4543int
4544main ()
4545{
4546 int i;
4547 for (i = 0; i < 256; i++)
4548 if (XOR (islower (i), ISLOWER (i))
4549 || toupper (i) != TOUPPER (i))
4550 return 2;
4551 return 0;
4552}
4553_ACEOF
4554if ac_fn_c_try_run "$LINENO"; then :
4555
4556else
4557 ac_cv_header_stdc=no
4558fi
4559rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4560 conftest.$ac_objext conftest.beam conftest.$ac_ext
4561fi
4562
4563fi
4564fi
4565{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4566$as_echo "$ac_cv_header_stdc" >&6; }
4567if test $ac_cv_header_stdc = yes; then
4568
4569$as_echo "#define STDC_HEADERS 1" >>confdefs.h
4570
4571fi
4572
4573# On IRIX 5.3, sys/types and inttypes.h are conflicting.
4574for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4575 inttypes.h stdint.h unistd.h
4576do :
4577 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4578ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4579"
4580eval as_val=\$$as_ac_Header
4581 if test "x$as_val" = x""yes; then :
4582 cat >>confdefs.h <<_ACEOF
4583#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4584_ACEOF
4585
4586fi
4587
4588done
4589
4590
4591
c971b7fa
PA
4592 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4593if test "x$ac_cv_header_minix_config_h" = x""yes; then :
4594 MINIX=yes
4595else
4596 MINIX=
4597fi
4598
4599
4600 if test "$MINIX" = yes; then
4601
4602$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
4603
4604
4605$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
4606
4607
4608$as_echo "#define _MINIX 1" >>confdefs.h
4609
c971b7fa 4610
4a626d0a 4611$as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h
c971b7fa 4612
4a626d0a 4613 fi
c971b7fa
PA
4614
4615
4616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4617$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4618if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
4619 $as_echo_n "(cached) " >&6
4620else
4621 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4622/* end confdefs.h. */
4623
4624# define __EXTENSIONS__ 1
4625 $ac_includes_default
4626int
4627main ()
4628{
4629
4630 ;
4631 return 0;
4632}
4633_ACEOF
4634if ac_fn_c_try_compile "$LINENO"; then :
4635 ac_cv_safe_to_define___extensions__=yes
4636else
4637 ac_cv_safe_to_define___extensions__=no
4638fi
4639rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4640fi
4641{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4642$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
4643 test $ac_cv_safe_to_define___extensions__ = yes &&
4644 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
4645
4646 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
4647
4648 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
4649
4650 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
4651
4a626d0a
PA
4652 $as_echo "#define __USE_MINGW_ANSI_STDIO 1" >>confdefs.h
4653
c971b7fa
PA
4654 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
4655
4656 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
4657
4a626d0a
PA
4658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5
4659$as_echo_n "checking whether _XOPEN_SOURCE should be defined... " >&6; }
4660if test "${ac_cv_should_define__xopen_source+set}" = set; then :
4661 $as_echo_n "(cached) " >&6
4662else
4663 ac_cv_should_define__xopen_source=no
4664 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4665/* end confdefs.h. */
4666
4667 #include <wchar.h>
4668 mbstate_t x;
4669int
4670main ()
4671{
4672
4673 ;
4674 return 0;
4675}
4676_ACEOF
4677if ac_fn_c_try_compile "$LINENO"; then :
4678
4679else
4680 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4681/* end confdefs.h. */
4682
4683 #define _XOPEN_SOURCE 500
4684 #include <wchar.h>
4685 mbstate_t x;
4686int
4687main ()
4688{
4689
4690 ;
4691 return 0;
4692}
4693_ACEOF
4694if ac_fn_c_try_compile "$LINENO"; then :
4695 ac_cv_should_define__xopen_source=yes
4696fi
4697rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4698fi
4699rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4700fi
4701{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5
4702$as_echo "$ac_cv_should_define__xopen_source" >&6; }
4703 test $ac_cv_should_define__xopen_source = yes &&
4704 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
4705
c971b7fa
PA
4706
4707
4708
4709 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
4710$as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
4711if test "${gl_cv_c_amsterdam_compiler+set}" = set; then :
4712 $as_echo_n "(cached) " >&6
4713else
4714
4715 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4716/* end confdefs.h. */
4717
4718#ifdef __ACK__
4719Amsterdam
4720#endif
4721
4722_ACEOF
4723if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4724 $EGREP "Amsterdam" >/dev/null 2>&1; then :
4725 gl_cv_c_amsterdam_compiler=yes
4726else
4727 gl_cv_c_amsterdam_compiler=no
4728fi
4729rm -f conftest*
4730
4731
4732fi
4733{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
4734$as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
4735 if test -z "$AR"; then
4736 if test $gl_cv_c_amsterdam_compiler = yes; then
4737 AR='cc -c.a'
4738 if test -z "$ARFLAGS"; then
4739 ARFLAGS='-o'
4740 fi
4741 else
4742 if test -n "$ac_tool_prefix"; then
4743 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
4744set dummy ${ac_tool_prefix}ar; ac_word=$2
4745{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4746$as_echo_n "checking for $ac_word... " >&6; }
4747if test "${ac_cv_prog_AR+set}" = set; then :
4748 $as_echo_n "(cached) " >&6
4749else
4750 if test -n "$AR"; then
4751 ac_cv_prog_AR="$AR" # Let the user override the test.
4752else
4753as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4754for as_dir in $PATH
4755do
4756 IFS=$as_save_IFS
4757 test -z "$as_dir" && as_dir=.
4758 for ac_exec_ext in '' $ac_executable_extensions; do
4759 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4760 ac_cv_prog_AR="${ac_tool_prefix}ar"
4761 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4762 break 2
4763 fi
4764done
4765 done
4766IFS=$as_save_IFS
4767
4768fi
4769fi
4770AR=$ac_cv_prog_AR
4771if test -n "$AR"; then
4772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
4773$as_echo "$AR" >&6; }
4774else
4775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4776$as_echo "no" >&6; }
4777fi
4778
4779
4780fi
4781if test -z "$ac_cv_prog_AR"; then
4782 ac_ct_AR=$AR
4783 # Extract the first word of "ar", so it can be a program name with args.
4784set dummy ar; ac_word=$2
4785{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4786$as_echo_n "checking for $ac_word... " >&6; }
4787if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
4788 $as_echo_n "(cached) " >&6
4789else
4790 if test -n "$ac_ct_AR"; then
4791 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
4792else
4793as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4794for as_dir in $PATH
4795do
4796 IFS=$as_save_IFS
4797 test -z "$as_dir" && as_dir=.
4798 for ac_exec_ext in '' $ac_executable_extensions; do
4799 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4800 ac_cv_prog_ac_ct_AR="ar"
4801 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4802 break 2
4803 fi
4804done
4805 done
4806IFS=$as_save_IFS
4807
4808fi
4809fi
4810ac_ct_AR=$ac_cv_prog_ac_ct_AR
4811if test -n "$ac_ct_AR"; then
4812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
4813$as_echo "$ac_ct_AR" >&6; }
4814else
4815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4816$as_echo "no" >&6; }
4817fi
4818
4819 if test "x$ac_ct_AR" = x; then
4820 AR="ar"
4821 else
4822 case $cross_compiling:$ac_tool_warned in
4823yes:)
4824{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4825$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4826ac_tool_warned=yes ;;
4827esac
4828 AR=$ac_ct_AR
4829 fi
4830else
4831 AR="$ac_cv_prog_AR"
4832fi
4833
4834 if test -z "$ARFLAGS"; then
4a626d0a 4835 ARFLAGS='cr'
c971b7fa
PA
4836 fi
4837 fi
4838 else
4839 if test -z "$ARFLAGS"; then
4a626d0a 4840 ARFLAGS='cr'
c971b7fa
PA
4841 fi
4842 fi
4843
4844
4845 if test -z "$RANLIB"; then
4846 if test $gl_cv_c_amsterdam_compiler = yes; then
4847 RANLIB=':'
4848 else
4849 if test -n "$ac_tool_prefix"; then
4850 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
4851set dummy ${ac_tool_prefix}ranlib; ac_word=$2
4852{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4853$as_echo_n "checking for $ac_word... " >&6; }
4854if test "${ac_cv_prog_RANLIB+set}" = set; then :
4855 $as_echo_n "(cached) " >&6
4856else
4857 if test -n "$RANLIB"; then
4858 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4859else
4860as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4861for as_dir in $PATH
4862do
4863 IFS=$as_save_IFS
4864 test -z "$as_dir" && as_dir=.
4865 for ac_exec_ext in '' $ac_executable_extensions; do
4866 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4867 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
4868 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4869 break 2
4870 fi
4871done
4872 done
4873IFS=$as_save_IFS
4874
4875fi
4876fi
4877RANLIB=$ac_cv_prog_RANLIB
4878if test -n "$RANLIB"; then
4879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
4880$as_echo "$RANLIB" >&6; }
4881else
4882 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4883$as_echo "no" >&6; }
4884fi
4885
4886
4887fi
4888if test -z "$ac_cv_prog_RANLIB"; then
4889 ac_ct_RANLIB=$RANLIB
4890 # Extract the first word of "ranlib", so it can be a program name with args.
4891set dummy ranlib; ac_word=$2
4892{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4893$as_echo_n "checking for $ac_word... " >&6; }
4894if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
4895 $as_echo_n "(cached) " >&6
4896else
4897 if test -n "$ac_ct_RANLIB"; then
4898 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4899else
4900as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4901for as_dir in $PATH
4902do
4903 IFS=$as_save_IFS
4904 test -z "$as_dir" && as_dir=.
4905 for ac_exec_ext in '' $ac_executable_extensions; do
4906 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4907 ac_cv_prog_ac_ct_RANLIB="ranlib"
4908 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4909 break 2
4910 fi
4911done
4912 done
4913IFS=$as_save_IFS
4914
4915fi
4916fi
4917ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4918if test -n "$ac_ct_RANLIB"; then
4919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
4920$as_echo "$ac_ct_RANLIB" >&6; }
4921else
4922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4923$as_echo "no" >&6; }
4924fi
4925
4926 if test "x$ac_ct_RANLIB" = x; then
4927 RANLIB=":"
4928 else
4929 case $cross_compiling:$ac_tool_warned in
4930yes:)
4931{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4932$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4933ac_tool_warned=yes ;;
4934esac
4935 RANLIB=$ac_ct_RANLIB
4936 fi
4937else
4938 RANLIB="$ac_cv_prog_RANLIB"
4939fi
4940
4941 fi
4942 fi
4943
4944
4945
4946
4947
4948
4949
4950
4a626d0a
PA
4951ac_aux_dir=
4952for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
4953 for ac_t in install-sh install.sh shtool; do
4954 if test -f "$ac_dir/$ac_t"; then
4955 ac_aux_dir=$ac_dir
4956 ac_install_sh="$ac_aux_dir/$ac_t -c"
4957 break 2
4958 fi
4959 done
4960done
4961if test -z "$ac_aux_dir"; then
4962 as_fn_error "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
4963fi
4964
4965# These three variables are undocumented and unsupported,
4966# and are intended to be withdrawn in a future Autoconf release.
4967# They can cause serious problems if a builder's source tree is in a directory
4968# whose full name contains unusual characters.
4969ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
4970ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
4971ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
4972
4973
4974# Make sure we can run config.sub.
4975$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4976 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4977
4978{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4979$as_echo_n "checking build system type... " >&6; }
4980if test "${ac_cv_build+set}" = set; then :
4981 $as_echo_n "(cached) " >&6
4982else
4983 ac_build_alias=$build_alias
4984test "x$ac_build_alias" = x &&
4985 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4986test "x$ac_build_alias" = x &&
4987 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
4988ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4989 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4990
4991fi
4992{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4993$as_echo "$ac_cv_build" >&6; }
4994case $ac_cv_build in
4995*-*-*) ;;
4996*) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
4997esac
4998build=$ac_cv_build
4999ac_save_IFS=$IFS; IFS='-'
5000set x $ac_cv_build
5001shift
5002build_cpu=$1
5003build_vendor=$2
5004shift; shift
5005# Remember, the first character of IFS is used to create $*,
5006# except with old shells:
5007build_os=$*
5008IFS=$ac_save_IFS
5009case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
5010
5011
5012{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
5013$as_echo_n "checking host system type... " >&6; }
5014if test "${ac_cv_host+set}" = set; then :
5015 $as_echo_n "(cached) " >&6
5016else
5017 if test "x$host_alias" = x; then
5018 ac_cv_host=$ac_cv_build
5019else
5020 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
5021 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
5022fi
5023
5024fi
5025{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
5026$as_echo "$ac_cv_host" >&6; }
5027case $ac_cv_host in
5028*-*-*) ;;
5029*) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
5030esac
5031host=$ac_cv_host
5032ac_save_IFS=$IFS; IFS='-'
5033set x $ac_cv_host
5034shift
5035host_cpu=$1
5036host_vendor=$2
5037shift; shift
5038# Remember, the first character of IFS is used to create $*,
5039# except with old shells:
5040host_os=$*
5041IFS=$ac_save_IFS
5042case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
5043
5044
c971b7fa
PA
5045
5046
88b48903
WN
5047
5048 # IEEE behaviour is the default on all CPUs except Alpha and SH
5049 # (according to the test results of Bruno Haible's ieeefp/fenv_default.m4
5050 # and the GCC 4.1.2 manual).
5051 case "$host_cpu" in
5052 alpha*)
5053 # On Alpha systems, a compiler option provides the behaviour.
5054 # See the ieee(3) manual page, also available at
5055 # <http://h30097.www3.hp.com/docs/base_doc/DOCUMENTATION/V51B_HTML/MAN/MAN3/0600____.HTM>
5056 if test -n "$GCC"; then
5057 # GCC has the option -mieee.
5058 # For full IEEE compliance (rarely needed), use option -mieee-with-inexact.
5059 CPPFLAGS="$CPPFLAGS -mieee"
5060 else
5061 # Compaq (ex-DEC) C has the option -ieee, equivalent to -ieee_with_no_inexact.
5062 # For full IEEE compliance (rarely needed), use option -ieee_with_inexact.
5063 CPPFLAGS="$CPPFLAGS -ieee"
5064 fi
5065 ;;
5066 sh*)
5067 if test -n "$GCC"; then
5068 # GCC has the option -mieee.
5069 CPPFLAGS="$CPPFLAGS -mieee"
5070 fi
5071 ;;
5072 esac
5073
2196f55f
YQ
5074# Check whether --enable-largefile was given.
5075if test "${enable_largefile+set}" = set; then :
5076 enableval=$enable_largefile;
5077fi
5078
5079if test "$enable_largefile" != no; then
5080
5081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
5082$as_echo_n "checking for special C compiler options needed for large files... " >&6; }
5083if test "${ac_cv_sys_largefile_CC+set}" = set; then :
5084 $as_echo_n "(cached) " >&6
5085else
5086 ac_cv_sys_largefile_CC=no
5087 if test "$GCC" != yes; then
5088 ac_save_CC=$CC
5089 while :; do
5090 # IRIX 6.2 and later do not support large files by default,
5091 # so use the C compiler's -n32 option if that helps.
5092 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5093/* end confdefs.h. */
5094#include <sys/types.h>
5095 /* Check that off_t can represent 2**63 - 1 correctly.
5096 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5097 since some C++ compilers masquerading as C compilers
5098 incorrectly reject 9223372036854775807. */
5099#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5100 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5101 && LARGE_OFF_T % 2147483647 == 1)
5102 ? 1 : -1];
5103int
5104main ()
5105{
5106
5107 ;
5108 return 0;
5109}
5110_ACEOF
5111 if ac_fn_c_try_compile "$LINENO"; then :
5112 break
5113fi
5114rm -f core conftest.err conftest.$ac_objext
5115 CC="$CC -n32"
5116 if ac_fn_c_try_compile "$LINENO"; then :
5117 ac_cv_sys_largefile_CC=' -n32'; break
5118fi
5119rm -f core conftest.err conftest.$ac_objext
5120 break
5121 done
5122 CC=$ac_save_CC
5123 rm -f conftest.$ac_ext
5124 fi
5125fi
5126{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
5127$as_echo "$ac_cv_sys_largefile_CC" >&6; }
5128 if test "$ac_cv_sys_largefile_CC" != no; then
5129 CC=$CC$ac_cv_sys_largefile_CC
5130 fi
5131
5132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
5133$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
5134if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
5135 $as_echo_n "(cached) " >&6
5136else
5137 while :; do
5138 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5139/* end confdefs.h. */
5140#include <sys/types.h>
5141 /* Check that off_t can represent 2**63 - 1 correctly.
5142 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5143 since some C++ compilers masquerading as C compilers
5144 incorrectly reject 9223372036854775807. */
5145#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5146 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5147 && LARGE_OFF_T % 2147483647 == 1)
5148 ? 1 : -1];
5149int
5150main ()
5151{
5152
5153 ;
5154 return 0;
5155}
5156_ACEOF
5157if ac_fn_c_try_compile "$LINENO"; then :
5158 ac_cv_sys_file_offset_bits=no; break
5159fi
5160rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5161 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5162/* end confdefs.h. */
5163#define _FILE_OFFSET_BITS 64
5164#include <sys/types.h>
5165 /* Check that off_t can represent 2**63 - 1 correctly.
5166 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5167 since some C++ compilers masquerading as C compilers
5168 incorrectly reject 9223372036854775807. */
5169#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5170 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5171 && LARGE_OFF_T % 2147483647 == 1)
5172 ? 1 : -1];
5173int
5174main ()
5175{
5176
5177 ;
5178 return 0;
5179}
5180_ACEOF
5181if ac_fn_c_try_compile "$LINENO"; then :
5182 ac_cv_sys_file_offset_bits=64; break
5183fi
5184rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5185 ac_cv_sys_file_offset_bits=unknown
5186 break
5187done
5188fi
5189{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
5190$as_echo "$ac_cv_sys_file_offset_bits" >&6; }
5191case $ac_cv_sys_file_offset_bits in #(
5192 no | unknown) ;;
5193 *)
5194cat >>confdefs.h <<_ACEOF
5195#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
5196_ACEOF
5197;;
5198esac
5199rm -rf conftest*
5200 if test $ac_cv_sys_file_offset_bits = unknown; then
5201 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
5202$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
5203if test "${ac_cv_sys_large_files+set}" = set; then :
5204 $as_echo_n "(cached) " >&6
5205else
5206 while :; do
5207 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5208/* end confdefs.h. */
5209#include <sys/types.h>
5210 /* Check that off_t can represent 2**63 - 1 correctly.
5211 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5212 since some C++ compilers masquerading as C compilers
5213 incorrectly reject 9223372036854775807. */
5214#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5215 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5216 && LARGE_OFF_T % 2147483647 == 1)
5217 ? 1 : -1];
5218int
5219main ()
5220{
5221
5222 ;
5223 return 0;
5224}
5225_ACEOF
5226if ac_fn_c_try_compile "$LINENO"; then :
5227 ac_cv_sys_large_files=no; break
5228fi
5229rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5230 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5231/* end confdefs.h. */
5232#define _LARGE_FILES 1
5233#include <sys/types.h>
5234 /* Check that off_t can represent 2**63 - 1 correctly.
5235 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5236 since some C++ compilers masquerading as C compilers
5237 incorrectly reject 9223372036854775807. */
5238#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5239 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5240 && LARGE_OFF_T % 2147483647 == 1)
5241 ? 1 : -1];
5242int
5243main ()
5244{
5245
5246 ;
5247 return 0;
5248}
5249_ACEOF
5250if ac_fn_c_try_compile "$LINENO"; then :
5251 ac_cv_sys_large_files=1; break
5252fi
5253rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5254 ac_cv_sys_large_files=unknown
5255 break
5256done
5257fi
5258{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
5259$as_echo "$ac_cv_sys_large_files" >&6; }
5260case $ac_cv_sys_large_files in #(
5261 no | unknown) ;;
5262 *)
5263cat >>confdefs.h <<_ACEOF
5264#define _LARGE_FILES $ac_cv_sys_large_files
5265_ACEOF
5266;;
5267esac
5268rm -rf conftest*
5269 fi
5270
5271
4a626d0a
PA
5272$as_echo "#define _DARWIN_USE_64_BIT_INODE 1" >>confdefs.h
5273
2196f55f
YQ
5274fi
5275
88b48903
WN
5276
5277
4a626d0a 5278 # Code from module absolute-header:
8690e634
JK
5279 # Code from module alloca:
5280 # Code from module alloca-opt:
98399780 5281 # Code from module canonicalize-lgpl:
6a29c58e 5282 # Code from module chdir:
8690e634 5283 # Code from module configmake:
e26b6bb0 5284 # Code from module dirent:
18848e28 5285 # Code from module dirfd:
6a29c58e 5286 # Code from module dirname-lgpl:
2196f55f 5287 # Code from module dosname:
6a29c58e 5288 # Code from module double-slash-root:
18848e28 5289 # Code from module errno:
c971b7fa
PA
5290 # Code from module extensions:
5291
a512b375 5292 # Code from module extern-inline:
88b48903 5293 # Code from module float:
8690e634
JK
5294 # Code from module fnmatch:
5295 # Code from module fnmatch-gnu:
88b48903
WN
5296 # Code from module fpieee:
5297
5298 # Code from module fpucw:
5299 # Code from module frexp:
5300 # Code from module frexpl:
4a626d0a 5301 # Code from module gettimeofday:
c971b7fa
PA
5302 # Code from module include_next:
5303 # Code from module inttypes:
5304 # Code from module inttypes-incomplete:
88b48903
WN
5305 # Code from module isnand-nolibm:
5306 # Code from module isnanl-nolibm:
2196f55f
YQ
5307 # Code from module largefile:
5308
8690e634 5309 # Code from module localcharset:
f45c62c4 5310 # Code from module lstat:
6a29c58e 5311 # Code from module malloc-posix:
98399780 5312 # Code from module malloca:
88b48903 5313 # Code from module math:
8690e634
JK
5314 # Code from module mbrtowc:
5315 # Code from module mbsinit:
5316 # Code from module mbsrtowcs:
c971b7fa
PA
5317 # Code from module memchr:
5318 # Code from module memmem:
5319 # Code from module memmem-simple:
5320 # Code from module multiarch:
98399780 5321 # Code from module nocrash:
38ec2207 5322 # Code from module pathmax:
8424cc97 5323 # Code from module rawmemchr:
2196f55f 5324 # Code from module readlink:
6a29c58e
YQ
5325 # Code from module rename:
5326 # Code from module rmdir:
5327 # Code from module same-inode:
0750520d 5328 # Code from module signal-h:
98399780 5329 # Code from module snippet/_Noreturn:
c971b7fa
PA
5330 # Code from module snippet/arg-nonnull:
5331 # Code from module snippet/c++defs:
5332 # Code from module snippet/warn-on-use:
8839a007 5333 # Code from module ssize_t:
2196f55f 5334 # Code from module stat:
8690e634 5335 # Code from module stdbool:
c971b7fa
PA
5336 # Code from module stddef:
5337 # Code from module stdint:
6a29c58e 5338 # Code from module stdio:
98399780 5339 # Code from module stdlib:
8424cc97 5340 # Code from module strchrnul:
8690e634 5341 # Code from module streq:
c971b7fa 5342 # Code from module string:
8690e634 5343 # Code from module strnlen1:
63ce7108
TT
5344 # Code from module strstr:
5345 # Code from module strstr-simple:
421693b0 5346 # Code from module strtok_r:
09607c9e 5347 # Code from module sys_stat:
4a626d0a 5348 # Code from module sys_time:
8839a007 5349 # Code from module sys_types:
09607c9e 5350 # Code from module time:
8839a007 5351 # Code from module unistd:
c971b7fa 5352 # Code from module update-copyright:
8690e634
JK
5353 # Code from module verify:
5354 # Code from module wchar:
5355 # Code from module wctype-h:
c971b7fa
PA
5356
5357ac_ext=c
5358ac_cpp='$CPP $CPPFLAGS'
5359ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5360ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5361ac_compiler_gnu=$ac_cv_c_compiler_gnu
5362if test -n "$ac_tool_prefix"; then
5363 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
5364set dummy ${ac_tool_prefix}gcc; ac_word=$2
5365{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5366$as_echo_n "checking for $ac_word... " >&6; }
5367if test "${ac_cv_prog_CC+set}" = set; then :
5368 $as_echo_n "(cached) " >&6
5369else
5370 if test -n "$CC"; then
5371 ac_cv_prog_CC="$CC" # Let the user override the test.
5372else
5373as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5374for as_dir in $PATH
5375do
5376 IFS=$as_save_IFS
5377 test -z "$as_dir" && as_dir=.
5378 for ac_exec_ext in '' $ac_executable_extensions; do
5379 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5380 ac_cv_prog_CC="${ac_tool_prefix}gcc"
5381 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5382 break 2
5383 fi
5384done
5385 done
5386IFS=$as_save_IFS
5387
5388fi
5389fi
5390CC=$ac_cv_prog_CC
5391if test -n "$CC"; then
5392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5393$as_echo "$CC" >&6; }
5394else
5395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5396$as_echo "no" >&6; }
5397fi
5398
5399
5400fi
5401if test -z "$ac_cv_prog_CC"; then
5402 ac_ct_CC=$CC
5403 # Extract the first word of "gcc", so it can be a program name with args.
5404set dummy gcc; ac_word=$2
5405{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5406$as_echo_n "checking for $ac_word... " >&6; }
5407if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
5408 $as_echo_n "(cached) " >&6
5409else
5410 if test -n "$ac_ct_CC"; then
5411 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
5412else
5413as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5414for as_dir in $PATH
5415do
5416 IFS=$as_save_IFS
5417 test -z "$as_dir" && as_dir=.
5418 for ac_exec_ext in '' $ac_executable_extensions; do
5419 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5420 ac_cv_prog_ac_ct_CC="gcc"
5421 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5422 break 2
5423 fi
5424done
5425 done
5426IFS=$as_save_IFS
5427
5428fi
5429fi
5430ac_ct_CC=$ac_cv_prog_ac_ct_CC
5431if test -n "$ac_ct_CC"; then
5432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5433$as_echo "$ac_ct_CC" >&6; }
5434else
5435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5436$as_echo "no" >&6; }
5437fi
5438
5439 if test "x$ac_ct_CC" = x; then
5440 CC=""
5441 else
5442 case $cross_compiling:$ac_tool_warned in
5443yes:)
5444{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5445$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5446ac_tool_warned=yes ;;
5447esac
5448 CC=$ac_ct_CC
5449 fi
5450else
5451 CC="$ac_cv_prog_CC"
5452fi
5453
5454if test -z "$CC"; then
5455 if test -n "$ac_tool_prefix"; then
5456 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
5457set dummy ${ac_tool_prefix}cc; ac_word=$2
5458{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5459$as_echo_n "checking for $ac_word... " >&6; }
5460if test "${ac_cv_prog_CC+set}" = set; then :
5461 $as_echo_n "(cached) " >&6
5462else
5463 if test -n "$CC"; then
5464 ac_cv_prog_CC="$CC" # Let the user override the test.
5465else
5466as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5467for as_dir in $PATH
5468do
5469 IFS=$as_save_IFS
5470 test -z "$as_dir" && as_dir=.
5471 for ac_exec_ext in '' $ac_executable_extensions; do
5472 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5473 ac_cv_prog_CC="${ac_tool_prefix}cc"
5474 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5475 break 2
5476 fi
5477done
5478 done
5479IFS=$as_save_IFS
5480
5481fi
5482fi
5483CC=$ac_cv_prog_CC
5484if test -n "$CC"; then
5485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5486$as_echo "$CC" >&6; }
5487else
5488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5489$as_echo "no" >&6; }
5490fi
5491
5492
5493 fi
5494fi
5495if test -z "$CC"; then
5496 # Extract the first word of "cc", so it can be a program name with args.
5497set dummy cc; ac_word=$2
5498{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5499$as_echo_n "checking for $ac_word... " >&6; }
5500if test "${ac_cv_prog_CC+set}" = set; then :
5501 $as_echo_n "(cached) " >&6
5502else
5503 if test -n "$CC"; then
5504 ac_cv_prog_CC="$CC" # Let the user override the test.
5505else
5506 ac_prog_rejected=no
5507as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5508for as_dir in $PATH
5509do
5510 IFS=$as_save_IFS
5511 test -z "$as_dir" && as_dir=.
5512 for ac_exec_ext in '' $ac_executable_extensions; do
5513 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5514 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
5515 ac_prog_rejected=yes
5516 continue
5517 fi
5518 ac_cv_prog_CC="cc"
5519 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5520 break 2
5521 fi
5522done
5523 done
5524IFS=$as_save_IFS
5525
5526if test $ac_prog_rejected = yes; then
5527 # We found a bogon in the path, so make sure we never use it.
5528 set dummy $ac_cv_prog_CC
5529 shift
5530 if test $# != 0; then
5531 # We chose a different compiler from the bogus one.
5532 # However, it has the same basename, so the bogon will be chosen
5533 # first if we set CC to just the basename; use the full file name.
5534 shift
5535 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
5536 fi
5537fi
5538fi
5539fi
5540CC=$ac_cv_prog_CC
5541if test -n "$CC"; then
5542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5543$as_echo "$CC" >&6; }
5544else
5545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5546$as_echo "no" >&6; }
5547fi
5548
5549
5550fi
5551if test -z "$CC"; then
5552 if test -n "$ac_tool_prefix"; then
5553 for ac_prog in cl.exe
5554 do
5555 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5556set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5557{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5558$as_echo_n "checking for $ac_word... " >&6; }
5559if test "${ac_cv_prog_CC+set}" = set; then :
5560 $as_echo_n "(cached) " >&6
5561else
5562 if test -n "$CC"; then
5563 ac_cv_prog_CC="$CC" # Let the user override the test.
5564else
5565as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5566for as_dir in $PATH
5567do
5568 IFS=$as_save_IFS
5569 test -z "$as_dir" && as_dir=.
5570 for ac_exec_ext in '' $ac_executable_extensions; do
5571 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5572 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
5573 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5574 break 2
5575 fi
5576done
5577 done
5578IFS=$as_save_IFS
5579
5580fi
5581fi
5582CC=$ac_cv_prog_CC
5583if test -n "$CC"; then
5584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5585$as_echo "$CC" >&6; }
5586else
5587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5588$as_echo "no" >&6; }
5589fi
5590
5591
5592 test -n "$CC" && break
5593 done
5594fi
5595if test -z "$CC"; then
5596 ac_ct_CC=$CC
5597 for ac_prog in cl.exe
5598do
5599 # Extract the first word of "$ac_prog", so it can be a program name with args.
5600set dummy $ac_prog; ac_word=$2
5601{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5602$as_echo_n "checking for $ac_word... " >&6; }
5603if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
5604 $as_echo_n "(cached) " >&6
5605else
5606 if test -n "$ac_ct_CC"; then
5607 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
5608else
5609as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5610for as_dir in $PATH
5611do
5612 IFS=$as_save_IFS
5613 test -z "$as_dir" && as_dir=.
5614 for ac_exec_ext in '' $ac_executable_extensions; do
5615 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5616 ac_cv_prog_ac_ct_CC="$ac_prog"
5617 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5618 break 2
5619 fi
5620done
5621 done
5622IFS=$as_save_IFS
5623
5624fi
5625fi
5626ac_ct_CC=$ac_cv_prog_ac_ct_CC
5627if test -n "$ac_ct_CC"; then
5628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5629$as_echo "$ac_ct_CC" >&6; }
5630else
5631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5632$as_echo "no" >&6; }
5633fi
5634
5635
5636 test -n "$ac_ct_CC" && break
5637done
5638
5639 if test "x$ac_ct_CC" = x; then
5640 CC=""
5641 else
5642 case $cross_compiling:$ac_tool_warned in
5643yes:)
5644{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5645$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5646ac_tool_warned=yes ;;
5647esac
5648 CC=$ac_ct_CC
5649 fi
5650fi
5651
5652fi
5653
5654
5655test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5656$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5657as_fn_error "no acceptable C compiler found in \$PATH
5658See \`config.log' for more details." "$LINENO" 5; }
5659
5660# Provide some information about the compiler.
5661$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
5662set X $ac_compile
5663ac_compiler=$2
5664for ac_option in --version -v -V -qversion; do
5665 { { ac_try="$ac_compiler $ac_option >&5"
5666case "(($ac_try" in
5667 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5668 *) ac_try_echo=$ac_try;;
5669esac
5670eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5671$as_echo "$ac_try_echo"; } >&5
5672 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
5673 ac_status=$?
5674 if test -s conftest.err; then
5675 sed '10a\
5676... rest of stderr output deleted ...
5677 10q' conftest.err >conftest.er1
5678 cat conftest.er1 >&5
5679 rm -f conftest.er1 conftest.err
5680 fi
5681 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5682 test $ac_status = 0; }
5683done
5684
5685{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5686$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5687if test "${ac_cv_c_compiler_gnu+set}" = set; then :
5688 $as_echo_n "(cached) " >&6
5689else
5690 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5691/* end confdefs.h. */
5692
5693int
5694main ()
5695{
5696#ifndef __GNUC__
5697 choke me
5698#endif
5699
5700 ;
5701 return 0;
5702}
5703_ACEOF
5704if ac_fn_c_try_compile "$LINENO"; then :
5705 ac_compiler_gnu=yes
5706else
5707 ac_compiler_gnu=no
5708fi
5709rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5710ac_cv_c_compiler_gnu=$ac_compiler_gnu
5711
5712fi
5713{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5714$as_echo "$ac_cv_c_compiler_gnu" >&6; }
5715if test $ac_compiler_gnu = yes; then
5716 GCC=yes
5717else
5718 GCC=
5719fi
5720ac_test_CFLAGS=${CFLAGS+set}
5721ac_save_CFLAGS=$CFLAGS
5722{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5723$as_echo_n "checking whether $CC accepts -g... " >&6; }
5724if test "${ac_cv_prog_cc_g+set}" = set; then :
5725 $as_echo_n "(cached) " >&6
5726else
5727 ac_save_c_werror_flag=$ac_c_werror_flag
5728 ac_c_werror_flag=yes
5729 ac_cv_prog_cc_g=no
5730 CFLAGS="-g"
5731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5732/* end confdefs.h. */
5733
5734int
5735main ()
5736{
5737
5738 ;
5739 return 0;
5740}
5741_ACEOF
5742if ac_fn_c_try_compile "$LINENO"; then :
5743 ac_cv_prog_cc_g=yes
5744else
5745 CFLAGS=""
5746 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5747/* end confdefs.h. */
5748
5749int
5750main ()
5751{
5752
5753 ;
5754 return 0;
5755}
5756_ACEOF
5757if ac_fn_c_try_compile "$LINENO"; then :
5758
5759else
5760 ac_c_werror_flag=$ac_save_c_werror_flag
5761 CFLAGS="-g"
5762 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5763/* end confdefs.h. */
5764
5765int
5766main ()
5767{
5768
5769 ;
5770 return 0;
5771}
5772_ACEOF
5773if ac_fn_c_try_compile "$LINENO"; then :
5774 ac_cv_prog_cc_g=yes
5775fi
5776rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5777fi
5778rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5779fi
5780rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5781 ac_c_werror_flag=$ac_save_c_werror_flag
5782fi
5783{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5784$as_echo "$ac_cv_prog_cc_g" >&6; }
5785if test "$ac_test_CFLAGS" = set; then
5786 CFLAGS=$ac_save_CFLAGS
5787elif test $ac_cv_prog_cc_g = yes; then
5788 if test "$GCC" = yes; then
5789 CFLAGS="-g -O2"
5790 else
5791 CFLAGS="-g"
5792 fi
5793else
5794 if test "$GCC" = yes; then
5795 CFLAGS="-O2"
5796 else
5797 CFLAGS=
5798 fi
5799fi
5800{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5801$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5802if test "${ac_cv_prog_cc_c89+set}" = set; then :
5803 $as_echo_n "(cached) " >&6
5804else
5805 ac_cv_prog_cc_c89=no
5806ac_save_CC=$CC
5807cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5808/* end confdefs.h. */
5809#include <stdarg.h>
5810#include <stdio.h>
5811#include <sys/types.h>
5812#include <sys/stat.h>
5813/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5814struct buf { int x; };
5815FILE * (*rcsopen) (struct buf *, struct stat *, int);
5816static char *e (p, i)
5817 char **p;
5818 int i;
5819{
5820 return p[i];
5821}
5822static char *f (char * (*g) (char **, int), char **p, ...)
5823{
5824 char *s;
5825 va_list v;
5826 va_start (v,p);
5827 s = g (p, va_arg (v,int));
5828 va_end (v);
5829 return s;
5830}
5831
5832/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5833 function prototypes and stuff, but not '\xHH' hex character constants.
5834 These don't provoke an error unfortunately, instead are silently treated
5835 as 'x'. The following induces an error, until -std is added to get
5836 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5837 array size at least. It's necessary to write '\x00'==0 to get something
5838 that's true only with -std. */
5839int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5840
5841/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5842 inside strings and character constants. */
5843#define FOO(x) 'x'
5844int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5845
5846int test (int i, double x);
5847struct s1 {int (*f) (int a);};
5848struct s2 {int (*f) (double a);};
5849int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5850int argc;
5851char **argv;
5852int
5853main ()
5854{
5855return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5856 ;
5857 return 0;
5858}
5859_ACEOF
5860for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5861 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5862do
5863 CC="$ac_save_CC $ac_arg"
5864 if ac_fn_c_try_compile "$LINENO"; then :
5865 ac_cv_prog_cc_c89=$ac_arg
5866fi
5867rm -f core conftest.err conftest.$ac_objext
5868 test "x$ac_cv_prog_cc_c89" != "xno" && break
5869done
5870rm -f conftest.$ac_ext
5871CC=$ac_save_CC
5872
5873fi
5874# AC_CACHE_VAL
5875case "x$ac_cv_prog_cc_c89" in
5876 x)
5877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5878$as_echo "none needed" >&6; } ;;
5879 xno)
5880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5881$as_echo "unsupported" >&6; } ;;
5882 *)
5883 CC="$CC $ac_cv_prog_cc_c89"
5884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5885$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5886esac
5887if test "x$ac_cv_prog_cc_c89" != xno; then :
5888
5889fi
5890
5891ac_ext=c
5892ac_cpp='$CPP $CPPFLAGS'
5893ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5894ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5895ac_compiler_gnu=$ac_cv_c_compiler_gnu
5896
5897
5898am_cv_prog_cc_stdc=$ac_cv_prog_cc_stdc
5899
5900
5901ac_aux_dir=
5902for ac_dir in ../.. "$srcdir"/../..; do
5903 for ac_t in install-sh install.sh shtool; do
5904 if test -f "$ac_dir/$ac_t"; then
5905 ac_aux_dir=$ac_dir
5906 ac_install_sh="$ac_aux_dir/$ac_t -c"
5907 break 2
5908 fi
5909 done
5910done
5911if test -z "$ac_aux_dir"; then
5912 as_fn_error "cannot find install-sh, install.sh, or shtool in ../.. \"$srcdir\"/../.." "$LINENO" 5
5913fi
5914
5915# These three variables are undocumented and unsupported,
5916# and are intended to be withdrawn in a future Autoconf release.
5917# They can cause serious problems if a builder's source tree is in a directory
5918# whose full name contains unusual characters.
5919ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
5920ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
5921ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
5922
5923
5924{ $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
5925$as_echo_n "checking target system type... " >&6; }
5926if test "${ac_cv_target+set}" = set; then :
5927 $as_echo_n "(cached) " >&6
5928else
5929 if test "x$target_alias" = x; then
5930 ac_cv_target=$ac_cv_host
5931else
5932 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
5933 as_fn_error "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
5934fi
5935
5936fi
5937{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
5938$as_echo "$ac_cv_target" >&6; }
5939case $ac_cv_target in
5940*-*-*) ;;
5941*) as_fn_error "invalid value of canonical target" "$LINENO" 5;;
5942esac
5943target=$ac_cv_target
5944ac_save_IFS=$IFS; IFS='-'
5945set x $ac_cv_target
5946shift
5947target_cpu=$1
5948target_vendor=$2
5949shift; shift
5950# Remember, the first character of IFS is used to create $*,
5951# except with old shells:
5952target_os=$*
5953IFS=$ac_save_IFS
5954case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
5955
5956
5957# The aliases save the names the user supplied, while $host etc.
5958# will get canonicalized.
5959test -n "$target_alias" &&
5960 test "$program_prefix$program_suffix$program_transform_name" = \
5961 NONENONEs,x,x, &&
5962 program_prefix=${target_alias}-
5963
5964
5965
5966
5967
5968
5969
5970 LIBC_FATAL_STDERR_=1
5971 export LIBC_FATAL_STDERR_
5972
8690e634
JK
5973# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
5974# for constant arguments. Useless!
5975{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
5976$as_echo_n "checking for working alloca.h... " >&6; }
5977if test "${ac_cv_working_alloca_h+set}" = set; then :
c971b7fa
PA
5978 $as_echo_n "(cached) " >&6
5979else
8690e634 5980 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
c971b7fa 5981/* end confdefs.h. */
8690e634 5982#include <alloca.h>
c971b7fa
PA
5983int
5984main ()
5985{
8690e634
JK
5986char *p = (char *) alloca (2 * sizeof (int));
5987 if (p) return 0;
c971b7fa
PA
5988 ;
5989 return 0;
5990}
c971b7fa
PA
5991_ACEOF
5992if ac_fn_c_try_link "$LINENO"; then :
8690e634 5993 ac_cv_working_alloca_h=yes
c971b7fa 5994else
8690e634 5995 ac_cv_working_alloca_h=no
c971b7fa
PA
5996fi
5997rm -f core conftest.err conftest.$ac_objext \
5998 conftest$ac_exeext conftest.$ac_ext
c971b7fa 5999fi
8690e634
JK
6000{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
6001$as_echo "$ac_cv_working_alloca_h" >&6; }
6002if test $ac_cv_working_alloca_h = yes; then
c971b7fa 6003
8690e634 6004$as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
c971b7fa 6005
8690e634 6006fi
c971b7fa 6007
8690e634
JK
6008{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
6009$as_echo_n "checking for alloca... " >&6; }
6010if test "${ac_cv_func_alloca_works+set}" = set; then :
c971b7fa 6011 $as_echo_n "(cached) " >&6
c971b7fa
PA
6012else
6013 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6014/* end confdefs.h. */
8690e634
JK
6015#ifdef __GNUC__
6016# define alloca __builtin_alloca
6017#else
6018# ifdef _MSC_VER
6019# include <malloc.h>
6020# define alloca _alloca
6021# else
6022# ifdef HAVE_ALLOCA_H
6023# include <alloca.h>
6024# else
6025# ifdef _AIX
6026 #pragma alloca
6027# else
6028# ifndef alloca /* predefined by HP cc +Olibcalls */
6029char *alloca ();
6030# endif
6031# endif
6032# endif
6033# endif
6034#endif
6035
c971b7fa
PA
6036int
6037main ()
6038{
8690e634
JK
6039char *p = (char *) alloca (1);
6040 if (p) return 0;
c971b7fa
PA
6041 ;
6042 return 0;
6043}
6044_ACEOF
8690e634
JK
6045if ac_fn_c_try_link "$LINENO"; then :
6046 ac_cv_func_alloca_works=yes
c971b7fa 6047else
8690e634 6048 ac_cv_func_alloca_works=no
c971b7fa 6049fi
8690e634
JK
6050rm -f core conftest.err conftest.$ac_objext \
6051 conftest$ac_exeext conftest.$ac_ext
c971b7fa 6052fi
a143c6de
JB
6053{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
6054$as_echo "$ac_cv_func_alloca_works" >&6; }
c971b7fa 6055
a143c6de 6056if test $ac_cv_func_alloca_works = yes; then
c971b7fa 6057
a143c6de 6058$as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
c971b7fa 6059
a143c6de
JB
6060else
6061 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
6062# that cause trouble. Some versions do not even contain alloca or
6063# contain a buggy version. If you still want to use their alloca,
6064# use ar to extract alloca.o from them instead of compiling alloca.c.
c971b7fa
PA
6065
6066
6067
6068
6069
a143c6de 6070ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
c971b7fa 6071
a143c6de 6072$as_echo "#define C_ALLOCA 1" >>confdefs.h
c971b7fa 6073
c971b7fa 6074
a143c6de
JB
6075{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether 'alloca.c' needs Cray hooks" >&5
6076$as_echo_n "checking whether 'alloca.c' needs Cray hooks... " >&6; }
6077if test "${ac_cv_os_cray+set}" = set; then :
8690e634
JK
6078 $as_echo_n "(cached) " >&6
6079else
a143c6de 6080 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8690e634 6081/* end confdefs.h. */
a143c6de
JB
6082#if defined CRAY && ! defined CRAY2
6083webecray
6084#else
6085wenotbecray
8690e634 6086#endif
c971b7fa 6087
8690e634
JK
6088_ACEOF
6089if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
a143c6de
JB
6090 $EGREP "webecray" >/dev/null 2>&1; then :
6091 ac_cv_os_cray=yes
8690e634 6092else
a143c6de 6093 ac_cv_os_cray=no
8690e634
JK
6094fi
6095rm -f conftest*
c971b7fa 6096
c0fc7f8b 6097fi
a143c6de
JB
6098{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
6099$as_echo "$ac_cv_os_cray" >&6; }
6100if test $ac_cv_os_cray = yes; then
6101 for ac_func in _getb67 GETB67 getb67; do
6102 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
6103ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
6104eval as_val=\$$as_ac_var
6105 if test "x$as_val" = x""yes; then :
c0fc7f8b 6106
a143c6de
JB
6107cat >>confdefs.h <<_ACEOF
6108#define CRAY_STACKSEG_END $ac_func
6109_ACEOF
c971b7fa 6110
a143c6de 6111 break
8690e634 6112fi
c971b7fa 6113
a143c6de 6114 done
8690e634 6115fi
c0fc7f8b 6116
a143c6de
JB
6117{ $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
6118$as_echo_n "checking stack direction for C alloca... " >&6; }
6119if test "${ac_cv_c_stack_direction+set}" = set; then :
c971b7fa
PA
6120 $as_echo_n "(cached) " >&6
6121else
a143c6de
JB
6122 if test "$cross_compiling" = yes; then :
6123 ac_cv_c_stack_direction=0
6124else
6125 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
c971b7fa 6126/* end confdefs.h. */
a143c6de
JB
6127$ac_includes_default
6128int
6129find_stack_direction (int *addr, int depth)
6130{
6131 int dir, dummy = 0;
6132 if (! addr)
6133 addr = &dummy;
6134 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
6135 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
6136 return dir + dummy;
6137}
8690e634 6138
a143c6de
JB
6139int
6140main (int argc, char **argv)
6141{
6142 return find_stack_direction (0, argc + !argv + 20) < 0;
6143}
c971b7fa 6144_ACEOF
a143c6de
JB
6145if ac_fn_c_try_run "$LINENO"; then :
6146 ac_cv_c_stack_direction=1
c971b7fa 6147else
a143c6de 6148 ac_cv_c_stack_direction=-1
8690e634 6149fi
a143c6de
JB
6150rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6151 conftest.$ac_objext conftest.beam conftest.$ac_ext
c971b7fa 6152fi
c971b7fa
PA
6153
6154fi
a143c6de
JB
6155{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
6156$as_echo "$ac_cv_c_stack_direction" >&6; }
6157cat >>confdefs.h <<_ACEOF
6158#define STACK_DIRECTION $ac_cv_c_stack_direction
6159_ACEOF
8690e634 6160
c971b7fa
PA
6161
6162fi
c971b7fa
PA
6163
6164
98399780
YQ
6165 GNULIB__EXIT=0;
6166 GNULIB_ATOLL=0;
6167 GNULIB_CALLOC_POSIX=0;
6168 GNULIB_CANONICALIZE_FILE_NAME=0;
6169 GNULIB_GETLOADAVG=0;
6170 GNULIB_GETSUBOPT=0;
6171 GNULIB_GRANTPT=0;
6172 GNULIB_MALLOC_POSIX=0;
6173 GNULIB_MBTOWC=0;
6174 GNULIB_MKDTEMP=0;
6175 GNULIB_MKOSTEMP=0;
6176 GNULIB_MKOSTEMPS=0;
6177 GNULIB_MKSTEMP=0;
6178 GNULIB_MKSTEMPS=0;
6179 GNULIB_POSIX_OPENPT=0;
6180 GNULIB_PTSNAME=0;
6181 GNULIB_PTSNAME_R=0;
6182 GNULIB_PUTENV=0;
4a626d0a 6183 GNULIB_QSORT_R=0;
98399780
YQ
6184 GNULIB_RANDOM=0;
6185 GNULIB_RANDOM_R=0;
6186 GNULIB_REALLOC_POSIX=0;
6187 GNULIB_REALPATH=0;
6188 GNULIB_RPMATCH=0;
4a626d0a 6189 GNULIB_SECURE_GETENV=0;
98399780
YQ
6190 GNULIB_SETENV=0;
6191 GNULIB_STRTOD=0;
6192 GNULIB_STRTOLL=0;
6193 GNULIB_STRTOULL=0;
6194 GNULIB_SYSTEM_POSIX=0;
6195 GNULIB_UNLOCKPT=0;
6196 GNULIB_UNSETENV=0;
6197 GNULIB_WCTOMB=0;
6198 HAVE__EXIT=1;
6199 HAVE_ATOLL=1;
6200 HAVE_CANONICALIZE_FILE_NAME=1;
6201 HAVE_DECL_GETLOADAVG=1;
6202 HAVE_GETSUBOPT=1;
6203 HAVE_GRANTPT=1;
6204 HAVE_MKDTEMP=1;
6205 HAVE_MKOSTEMP=1;
6206 HAVE_MKOSTEMPS=1;
6207 HAVE_MKSTEMP=1;
6208 HAVE_MKSTEMPS=1;
6209 HAVE_POSIX_OPENPT=1;
6210 HAVE_PTSNAME=1;
6211 HAVE_PTSNAME_R=1;
6212 HAVE_RANDOM=1;
6213 HAVE_RANDOM_H=1;
6214 HAVE_RANDOM_R=1;
6215 HAVE_REALPATH=1;
6216 HAVE_RPMATCH=1;
4a626d0a 6217 HAVE_SECURE_GETENV=1;
98399780
YQ
6218 HAVE_SETENV=1;
6219 HAVE_DECL_SETENV=1;
6220 HAVE_STRTOD=1;
6221 HAVE_STRTOLL=1;
6222 HAVE_STRTOULL=1;
6223 HAVE_STRUCT_RANDOM_DATA=1;
6224 HAVE_SYS_LOADAVG_H=0;
6225 HAVE_UNLOCKPT=1;
6226 HAVE_DECL_UNSETENV=1;
6227 REPLACE_CALLOC=0;
6228 REPLACE_CANONICALIZE_FILE_NAME=0;
6229 REPLACE_MALLOC=0;
6230 REPLACE_MBTOWC=0;
6231 REPLACE_MKSTEMP=0;
6232 REPLACE_PTSNAME=0;
6233 REPLACE_PTSNAME_R=0;
6234 REPLACE_PUTENV=0;
4a626d0a 6235 REPLACE_QSORT_R=0;
98399780
YQ
6236 REPLACE_RANDOM_R=0;
6237 REPLACE_REALLOC=0;
6238 REPLACE_REALPATH=0;
6239 REPLACE_SETENV=0;
6240 REPLACE_STRTOD=0;
6241 REPLACE_UNSETENV=0;
6242 REPLACE_WCTOMB=0;
6243
6244
6245
6246
6247 for ac_func in $ac_func_list
6248do :
6249 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
6250ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
6251eval as_val=\$$as_ac_var
6252 if test "x$as_val" = x""yes; then :
6253 cat >>confdefs.h <<_ACEOF
6254#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
6255_ACEOF
6256
6257fi
6258done
6259
6260
6261
6262
6263
6264
6265
6266
6267
6268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether // is distinct from /" >&5
6269$as_echo_n "checking whether // is distinct from /... " >&6; }
6270if test "${gl_cv_double_slash_root+set}" = set; then :
6271 $as_echo_n "(cached) " >&6
6272else
6273 if test x"$cross_compiling" = xyes ; then
6274 # When cross-compiling, there is no way to tell whether // is special
6275 # short of a list of hosts. However, the only known hosts to date
6276 # that have a distinct // are Apollo DomainOS (too old to port to),
6277 # Cygwin, and z/OS. If anyone knows of another system for which // has
6278 # special semantics and is distinct from /, please report it to
6279 # <bug-gnulib@gnu.org>.
6280 case $host in
6281 *-cygwin | i370-ibm-openedition)
6282 gl_cv_double_slash_root=yes ;;
6283 *)
6284 # Be optimistic and assume that / and // are the same when we
6285 # don't know.
6286 gl_cv_double_slash_root='unknown, assuming no' ;;
6287 esac
6288 else
6289 set x `ls -di / // 2>/dev/null`
6290 if test "$2" = "$4" && wc //dev/null >/dev/null 2>&1; then
6291 gl_cv_double_slash_root=no
6292 else
6293 gl_cv_double_slash_root=yes
6294 fi
6295 fi
6296fi
6297{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_double_slash_root" >&5
6298$as_echo "$gl_cv_double_slash_root" >&6; }
6299 if test "$gl_cv_double_slash_root" = yes; then
6300
6301$as_echo "#define DOUBLE_SLASH_IS_DISTINCT_ROOT 1" >>confdefs.h
6302
6303 fi
6304
6305
6306
6307
6308
6309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether realpath works" >&5
6310$as_echo_n "checking whether realpath works... " >&6; }
6311if test "${gl_cv_func_realpath_works+set}" = set; then :
6312 $as_echo_n "(cached) " >&6
6313else
6314
6315 touch conftest.a
6316 mkdir conftest.d
6317 if test "$cross_compiling" = yes; then :
6318 case "$host_os" in
6319 # Guess yes on glibc systems.
6320 *-gnu* | gnu*) gl_cv_func_realpath_works="guessing yes" ;;
6321 # If we don't know, assume the worst.
6322 *) gl_cv_func_realpath_works="guessing no" ;;
6323 esac
6324
6325else
6326 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6327/* end confdefs.h. */
6328
6329
6330
6331#include <stdlib.h>
6332#if defined __MACH__ && defined __APPLE__
6333/* Avoid a crash on Mac OS X. */
6334#include <mach/mach.h>
6335#include <mach/mach_error.h>
6336#include <mach/thread_status.h>
6337#include <mach/exception.h>
6338#include <mach/task.h>
6339#include <pthread.h>
6340/* The exception port on which our thread listens. */
6341static mach_port_t our_exception_port;
6342/* The main function of the thread listening for exceptions of type
6343 EXC_BAD_ACCESS. */
6344static void *
6345mach_exception_thread (void *arg)
6346{
6347 /* Buffer for a message to be received. */
6348 struct {
6349 mach_msg_header_t head;
6350 mach_msg_body_t msgh_body;
6351 char data[1024];
6352 } msg;
6353 mach_msg_return_t retval;
6354 /* Wait for a message on the exception port. */
6355 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
6356 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
6357 if (retval != MACH_MSG_SUCCESS)
6358 abort ();
6359 exit (1);
6360}
6361static void
6362nocrash_init (void)
6363{
6364 mach_port_t self = mach_task_self ();
6365 /* Allocate a port on which the thread shall listen for exceptions. */
6366 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
6367 == KERN_SUCCESS) {
6368 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
6369 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
6370 MACH_MSG_TYPE_MAKE_SEND)
6371 == KERN_SUCCESS) {
6372 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
6373 for us. */
6374 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
6375 /* Create the thread listening on the exception port. */
6376 pthread_attr_t attr;
6377 pthread_t thread;
6378 if (pthread_attr_init (&attr) == 0
6379 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
6380 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
6381 pthread_attr_destroy (&attr);
6382 /* Replace the exception port info for these exceptions with our own.
6383 Note that we replace the exception port for the entire task, not only
6384 for a particular thread. This has the effect that when our exception
6385 port gets the message, the thread specific exception port has already
6386 been asked, and we don't need to bother about it.
6387 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
6388 task_set_exception_ports (self, mask, our_exception_port,
6389 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
6390 }
6391 }
6392 }
6393}
6394#elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
6395/* Avoid a crash on native Windows. */
6396#define WIN32_LEAN_AND_MEAN
6397#include <windows.h>
6398#include <winerror.h>
6399static LONG WINAPI
6400exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
6401{
6402 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
6403 {
6404 case EXCEPTION_ACCESS_VIOLATION:
6405 case EXCEPTION_IN_PAGE_ERROR:
6406 case EXCEPTION_STACK_OVERFLOW:
6407 case EXCEPTION_GUARD_PAGE:
6408 case EXCEPTION_PRIV_INSTRUCTION:
6409 case EXCEPTION_ILLEGAL_INSTRUCTION:
6410 case EXCEPTION_DATATYPE_MISALIGNMENT:
6411 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
6412 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
6413 exit (1);
6414 }
6415 return EXCEPTION_CONTINUE_SEARCH;
6416}
6417static void
6418nocrash_init (void)
6419{
6420 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
6421}
6422#else
6423/* Avoid a crash on POSIX systems. */
6424#include <signal.h>
6425/* A POSIX signal handler. */
6426static void
6427exception_handler (int sig)
6428{
6429 exit (1);
6430}
6431static void
6432nocrash_init (void)
6433{
6434#ifdef SIGSEGV
6435 signal (SIGSEGV, exception_handler);
6436#endif
6437#ifdef SIGBUS
6438 signal (SIGBUS, exception_handler);
6439#endif
6440}
6441#endif
6442
6443 #include <stdlib.h>
6444 #include <string.h>
6445
6446int
6447main ()
6448{
6449
6450 int result = 0;
6451 {
6452 char *name = realpath ("conftest.a", NULL);
6453 if (!(name && *name == '/'))
6454 result |= 1;
6455 }
6456 {
6457 char *name = realpath ("conftest.b/../conftest.a", NULL);
6458 if (name != NULL)
6459 result |= 2;
6460 }
6461 {
6462 char *name = realpath ("conftest.a/", NULL);
6463 if (name != NULL)
6464 result |= 4;
6465 }
6466 {
6467 char *name1 = realpath (".", NULL);
6468 char *name2 = realpath ("conftest.d//./..", NULL);
6469 if (strcmp (name1, name2) != 0)
6470 result |= 8;
6471 }
6472 return result;
6473
6474 ;
6475 return 0;
6476}
6477
6478_ACEOF
6479if ac_fn_c_try_run "$LINENO"; then :
6480 gl_cv_func_realpath_works=yes
6481else
6482 gl_cv_func_realpath_works=no
6483fi
6484rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6485 conftest.$ac_objext conftest.beam conftest.$ac_ext
6486fi
6487
6488 rm -rf conftest.a conftest.d
6489
6490fi
6491{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_realpath_works" >&5
6492$as_echo "$gl_cv_func_realpath_works" >&6; }
6493 case "$gl_cv_func_realpath_works" in
6494 *yes)
6495
6496$as_echo "#define FUNC_REALPATH_WORKS 1" >>confdefs.h
6497
6498 ;;
6499 esac
6500
6501
6502
6503
6504 for ac_header in $ac_header_list
6505do :
6506 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6507ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6508"
6509eval as_val=\$$as_ac_Header
6510 if test "x$as_val" = x""yes; then :
6511 cat >>confdefs.h <<_ACEOF
6512#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6513_ACEOF
6514
6515fi
6516
6517done
6518
6519
6520
6521
6522
6523
6524
6525
6526
6527
6528
e26b6bb0
TT
6529 GNULIB_CHDIR=0;
6530 GNULIB_CHOWN=0;
6531 GNULIB_CLOSE=0;
6532 GNULIB_DUP=0;
6533 GNULIB_DUP2=0;
6534 GNULIB_DUP3=0;
6535 GNULIB_ENVIRON=0;
6536 GNULIB_EUIDACCESS=0;
6537 GNULIB_FACCESSAT=0;
6538 GNULIB_FCHDIR=0;
6539 GNULIB_FCHOWNAT=0;
6540 GNULIB_FDATASYNC=0;
6541 GNULIB_FSYNC=0;
6542 GNULIB_FTRUNCATE=0;
6543 GNULIB_GETCWD=0;
6544 GNULIB_GETDOMAINNAME=0;
6545 GNULIB_GETDTABLESIZE=0;
6546 GNULIB_GETGROUPS=0;
6547 GNULIB_GETHOSTNAME=0;
6548 GNULIB_GETLOGIN=0;
6549 GNULIB_GETLOGIN_R=0;
6550 GNULIB_GETPAGESIZE=0;
6551 GNULIB_GETUSERSHELL=0;
6552 GNULIB_GROUP_MEMBER=0;
6553 GNULIB_ISATTY=0;
6554 GNULIB_LCHOWN=0;
6555 GNULIB_LINK=0;
6556 GNULIB_LINKAT=0;
6557 GNULIB_LSEEK=0;
6558 GNULIB_PIPE=0;
6559 GNULIB_PIPE2=0;
6560 GNULIB_PREAD=0;
6561 GNULIB_PWRITE=0;
6562 GNULIB_READ=0;
6563 GNULIB_READLINK=0;
6564 GNULIB_READLINKAT=0;
6565 GNULIB_RMDIR=0;
6566 GNULIB_SETHOSTNAME=0;
6567 GNULIB_SLEEP=0;
6568 GNULIB_SYMLINK=0;
6569 GNULIB_SYMLINKAT=0;
6570 GNULIB_TTYNAME_R=0;
6571 GNULIB_UNISTD_H_NONBLOCKING=0;
6572 GNULIB_UNISTD_H_SIGPIPE=0;
6573 GNULIB_UNLINK=0;
6574 GNULIB_UNLINKAT=0;
6575 GNULIB_USLEEP=0;
6576 GNULIB_WRITE=0;
6577 HAVE_CHOWN=1;
6578 HAVE_DUP2=1;
6579 HAVE_DUP3=1;
6580 HAVE_EUIDACCESS=1;
6581 HAVE_FACCESSAT=1;
6582 HAVE_FCHDIR=1;
6583 HAVE_FCHOWNAT=1;
6584 HAVE_FDATASYNC=1;
6585 HAVE_FSYNC=1;
6586 HAVE_FTRUNCATE=1;
6587 HAVE_GETDTABLESIZE=1;
6588 HAVE_GETGROUPS=1;
6589 HAVE_GETHOSTNAME=1;
6590 HAVE_GETLOGIN=1;
6591 HAVE_GETPAGESIZE=1;
6592 HAVE_GROUP_MEMBER=1;
6593 HAVE_LCHOWN=1;
6594 HAVE_LINK=1;
6595 HAVE_LINKAT=1;
6596 HAVE_PIPE=1;
6597 HAVE_PIPE2=1;
6598 HAVE_PREAD=1;
6599 HAVE_PWRITE=1;
6600 HAVE_READLINK=1;
6601 HAVE_READLINKAT=1;
6602 HAVE_SETHOSTNAME=1;
6603 HAVE_SLEEP=1;
6604 HAVE_SYMLINK=1;
6605 HAVE_SYMLINKAT=1;
6606 HAVE_UNLINKAT=1;
6607 HAVE_USLEEP=1;
6608 HAVE_DECL_ENVIRON=1;
6609 HAVE_DECL_FCHDIR=1;
6610 HAVE_DECL_FDATASYNC=1;
6611 HAVE_DECL_GETDOMAINNAME=1;
6612 HAVE_DECL_GETLOGIN_R=1;
6613 HAVE_DECL_GETPAGESIZE=1;
6614 HAVE_DECL_GETUSERSHELL=1;
6615 HAVE_DECL_SETHOSTNAME=1;
6616 HAVE_DECL_TTYNAME_R=1;
6617 HAVE_OS_H=0;
6618 HAVE_SYS_PARAM_H=0;
6619 REPLACE_CHOWN=0;
6620 REPLACE_CLOSE=0;
6621 REPLACE_DUP=0;
6622 REPLACE_DUP2=0;
6623 REPLACE_FCHOWNAT=0;
6624 REPLACE_FTRUNCATE=0;
6625 REPLACE_GETCWD=0;
6626 REPLACE_GETDOMAINNAME=0;
4a626d0a 6627 REPLACE_GETDTABLESIZE=0;
e26b6bb0
TT
6628 REPLACE_GETLOGIN_R=0;
6629 REPLACE_GETGROUPS=0;
6630 REPLACE_GETPAGESIZE=0;
6631 REPLACE_ISATTY=0;
6632 REPLACE_LCHOWN=0;
6633 REPLACE_LINK=0;
6634 REPLACE_LINKAT=0;
6635 REPLACE_LSEEK=0;
6636 REPLACE_PREAD=0;
6637 REPLACE_PWRITE=0;
6638 REPLACE_READ=0;
6639 REPLACE_READLINK=0;
4a626d0a 6640 REPLACE_READLINKAT=0;
e26b6bb0
TT
6641 REPLACE_RMDIR=0;
6642 REPLACE_SLEEP=0;
6643 REPLACE_SYMLINK=0;
4a626d0a 6644 REPLACE_SYMLINKAT=0;
e26b6bb0
TT
6645 REPLACE_TTYNAME_R=0;
6646 REPLACE_UNLINK=0;
6647 REPLACE_UNLINKAT=0;
6648 REPLACE_USLEEP=0;
6649 REPLACE_WRITE=0;
6650 UNISTD_H_HAVE_WINSOCK2_H=0;
6651 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
6652
6653
6654
6655 GNULIB_OPENDIR=0;
6656 GNULIB_READDIR=0;
6657 GNULIB_REWINDDIR=0;
6658 GNULIB_CLOSEDIR=0;
6659 GNULIB_DIRFD=0;
6660 GNULIB_FDOPENDIR=0;
6661 GNULIB_SCANDIR=0;
6662 GNULIB_ALPHASORT=0;
6663 HAVE_OPENDIR=1;
6664 HAVE_READDIR=1;
6665 HAVE_REWINDDIR=1;
6666 HAVE_CLOSEDIR=1;
6667 HAVE_DECL_DIRFD=1;
6668 HAVE_DECL_FDOPENDIR=1;
6669 HAVE_FDOPENDIR=1;
6670 HAVE_SCANDIR=1;
6671 HAVE_ALPHASORT=1;
6672 REPLACE_OPENDIR=0;
6673 REPLACE_CLOSEDIR=0;
6674 REPLACE_DIRFD=0;
6675 REPLACE_FDOPENDIR=0;
6676
6677
6678
6679 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
6680$as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
6681if test "${gl_cv_have_include_next+set}" = set; then :
6682 $as_echo_n "(cached) " >&6
6683else
6684 rm -rf conftestd1a conftestd1b conftestd2
6685 mkdir conftestd1a conftestd1b conftestd2
6686 cat <<EOF > conftestd1a/conftest.h
6687#define DEFINED_IN_CONFTESTD1
6688#include_next <conftest.h>
6689#ifdef DEFINED_IN_CONFTESTD2
6690int foo;
6691#else
88b48903
WN
6692#error "include_next doesn't work"
6693#endif
6694EOF
6695 cat <<EOF > conftestd1b/conftest.h
6696#define DEFINED_IN_CONFTESTD1
6697#include <stdio.h>
6698#include_next <conftest.h>
6699#ifdef DEFINED_IN_CONFTESTD2
6700int foo;
6701#else
6702#error "include_next doesn't work"
6703#endif
6704EOF
6705 cat <<EOF > conftestd2/conftest.h
6706#ifndef DEFINED_IN_CONFTESTD1
6707#error "include_next test doesn't work"
6708#endif
6709#define DEFINED_IN_CONFTESTD2
6710EOF
6711 gl_save_CPPFLAGS="$CPPFLAGS"
6712 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
6713 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6714/* end confdefs.h. */
6715#include <conftest.h>
6716_ACEOF
6717if ac_fn_c_try_compile "$LINENO"; then :
6718 gl_cv_have_include_next=yes
6719else
6720 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
6721 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6722/* end confdefs.h. */
6723#include <conftest.h>
6724_ACEOF
6725if ac_fn_c_try_compile "$LINENO"; then :
6726 gl_cv_have_include_next=buggy
6727else
6728 gl_cv_have_include_next=no
6729fi
6730rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6731
6732fi
6733rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6734 CPPFLAGS="$gl_save_CPPFLAGS"
6735 rm -rf conftestd1a conftestd1b conftestd2
6736
6737fi
6738{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
6739$as_echo "$gl_cv_have_include_next" >&6; }
6740 PRAGMA_SYSTEM_HEADER=
6741 if test $gl_cv_have_include_next = yes; then
6742 INCLUDE_NEXT=include_next
6743 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
6744 if test -n "$GCC"; then
6745 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
6746 fi
6747 else
6748 if test $gl_cv_have_include_next = buggy; then
6749 INCLUDE_NEXT=include
6750 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
6751 else
6752 INCLUDE_NEXT=include
6753 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
6754 fi
6755 fi
6756
6757
6758
6759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
6760$as_echo_n "checking whether system header files limit the line length... " >&6; }
6761if test "${gl_cv_pragma_columns+set}" = set; then :
6762 $as_echo_n "(cached) " >&6
6763else
6764 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6765/* end confdefs.h. */
6766
6767#ifdef __TANDEM
6768choke me
6769#endif
6770
6771_ACEOF
6772if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6773 $EGREP "choke me" >/dev/null 2>&1; then :
6774 gl_cv_pragma_columns=yes
6775else
6776 gl_cv_pragma_columns=no
6777fi
6778rm -f conftest*
6779
6780
6781fi
6782{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
6783$as_echo "$gl_cv_pragma_columns" >&6; }
6784 if test $gl_cv_pragma_columns = yes; then
6785 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
6786 else
6787 PRAGMA_COLUMNS=
6788 fi
6789
6790
6791
6792
e26b6bb0 6793
e26b6bb0 6794
18848e28
GF
6795 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for complete errno.h" >&5
6796$as_echo_n "checking for complete errno.h... " >&6; }
6797if test "${gl_cv_header_errno_h_complete+set}" = set; then :
6798 $as_echo_n "(cached) " >&6
6799else
6800
6801 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6802/* end confdefs.h. */
6803
6804#include <errno.h>
6805#if !defined ETXTBSY
6806booboo
6807#endif
6808#if !defined ENOMSG
6809booboo
6810#endif
6811#if !defined EIDRM
6812booboo
6813#endif
6814#if !defined ENOLINK
6815booboo
6816#endif
6817#if !defined EPROTO
6818booboo
6819#endif
6820#if !defined EMULTIHOP
6821booboo
6822#endif
6823#if !defined EBADMSG
6824booboo
6825#endif
6826#if !defined EOVERFLOW
6827booboo
6828#endif
6829#if !defined ENOTSUP
6830booboo
6831#endif
6832#if !defined ENETRESET
6833booboo
6834#endif
6835#if !defined ECONNABORTED
6836booboo
6837#endif
6838#if !defined ESTALE
6839booboo
6840#endif
6841#if !defined EDQUOT
6842booboo
6843#endif
6844#if !defined ECANCELED
6845booboo
6846#endif
6847#if !defined EOWNERDEAD
6848booboo
6849#endif
6850#if !defined ENOTRECOVERABLE
6851booboo
6852#endif
6853#if !defined EILSEQ
6854booboo
6855#endif
6856
6857_ACEOF
6858if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6859 $EGREP "booboo" >/dev/null 2>&1; then :
6860 gl_cv_header_errno_h_complete=no
6861else
6862 gl_cv_header_errno_h_complete=yes
6863fi
6864rm -f conftest*
6865
6866
6867fi
6868{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_complete" >&5
6869$as_echo "$gl_cv_header_errno_h_complete" >&6; }
6870 if test $gl_cv_header_errno_h_complete = yes; then
6871 ERRNO_H=''
6872 else
6873
6874
6875
6876
6877
6878
6879
6880
6881 if test $gl_cv_have_include_next = yes; then
6882 gl_cv_next_errno_h='<'errno.h'>'
6883 else
6884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <errno.h>" >&5
6885$as_echo_n "checking absolute name of <errno.h>... " >&6; }
6886if test "${gl_cv_next_errno_h+set}" = set; then :
6887 $as_echo_n "(cached) " >&6
6888else
6889
4a626d0a
PA
6890
6891
6892 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18848e28
GF
6893/* end confdefs.h. */
6894#include <errno.h>
18848e28 6895_ACEOF
4a626d0a
PA
6896 case "$host_os" in
6897 aix*) gl_absname_cpp="$ac_cpp -C" ;;
6898 *) gl_absname_cpp="$ac_cpp" ;;
6899 esac
18848e28 6900
4a626d0a
PA
6901 case "$host_os" in
6902 mingw*)
6903 gl_dirsep_regex='[/\\]'
6904 ;;
6905 *)
6906 gl_dirsep_regex='\/'
6907 ;;
6908 esac
6909 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
6910 gl_header_literal_regex=`echo 'errno.h' \
6911 | sed -e "$gl_make_literal_regex_sed"`
6912 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
6913 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
6914 s|^/[^/]|//&|
6915 p
6916 q
6917 }'
6918
6919 gl_cv_absolute_errno_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
6920 sed -n "$gl_absolute_header_sed"`
6921
6922 gl_header=$gl_cv_absolute_errno_h
6923 gl_cv_next_errno_h='"'$gl_header'"'
6924
6925
6926fi
6927{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_errno_h" >&5
18848e28
GF
6928$as_echo "$gl_cv_next_errno_h" >&6; }
6929 fi
6930 NEXT_ERRNO_H=$gl_cv_next_errno_h
6931
6932 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
6933 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
6934 gl_next_as_first_directive='<'errno.h'>'
6935 else
6936 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
6937 gl_next_as_first_directive=$gl_cv_next_errno_h
6938 fi
6939 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H=$gl_next_as_first_directive
6940
6941
6942
6943
6944 ERRNO_H='errno.h'
6945 fi
6946
6947 if test -n "$ERRNO_H"; then
6948 GL_GENERATE_ERRNO_H_TRUE=
6949 GL_GENERATE_ERRNO_H_FALSE='#'
6950else
6951 GL_GENERATE_ERRNO_H_TRUE='#'
6952 GL_GENERATE_ERRNO_H_FALSE=
6953fi
6954
6955
6956 if test -n "$ERRNO_H"; then
6957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EMULTIHOP value" >&5
6958$as_echo_n "checking for EMULTIHOP value... " >&6; }
6959if test "${gl_cv_header_errno_h_EMULTIHOP+set}" = set; then :
6960 $as_echo_n "(cached) " >&6
6961else
6962
6963 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6964/* end confdefs.h. */
6965
6966#include <errno.h>
6967#ifdef EMULTIHOP
6968yes
6969#endif
6970
6971_ACEOF
6972if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6973 $EGREP "yes" >/dev/null 2>&1; then :
6974 gl_cv_header_errno_h_EMULTIHOP=yes
6975else
6976 gl_cv_header_errno_h_EMULTIHOP=no
6977fi
6978rm -f conftest*
6979
6980 if test $gl_cv_header_errno_h_EMULTIHOP = no; then
6981 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6982/* end confdefs.h. */
6983
6984#define _XOPEN_SOURCE_EXTENDED 1
6985#include <errno.h>
6986#ifdef EMULTIHOP
6987yes
6988#endif
6989
6990_ACEOF
6991if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6992 $EGREP "yes" >/dev/null 2>&1; then :
6993 gl_cv_header_errno_h_EMULTIHOP=hidden
6994fi
6995rm -f conftest*
6996
6997 if test $gl_cv_header_errno_h_EMULTIHOP = hidden; then
6998 if ac_fn_c_compute_int "$LINENO" "EMULTIHOP" "gl_cv_header_errno_h_EMULTIHOP" "
6999#define _XOPEN_SOURCE_EXTENDED 1
7000#include <errno.h>
7001/* The following two lines are a workaround against an autoconf-2.52 bug. */
7002#include <stdio.h>
7003#include <stdlib.h>
7004"; then :
7005
7006fi
7007
7008 fi
7009 fi
7010
7011fi
7012{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EMULTIHOP" >&5
7013$as_echo "$gl_cv_header_errno_h_EMULTIHOP" >&6; }
7014 case $gl_cv_header_errno_h_EMULTIHOP in
7015 yes | no)
7016 EMULTIHOP_HIDDEN=0; EMULTIHOP_VALUE=
7017 ;;
7018 *)
7019 EMULTIHOP_HIDDEN=1; EMULTIHOP_VALUE="$gl_cv_header_errno_h_EMULTIHOP"
7020 ;;
7021 esac
7022
7023
7024 fi
7025
7026
7027 if test -n "$ERRNO_H"; then
7028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ENOLINK value" >&5
7029$as_echo_n "checking for ENOLINK value... " >&6; }
7030if test "${gl_cv_header_errno_h_ENOLINK+set}" = set; then :
7031 $as_echo_n "(cached) " >&6
7032else
7033
7034 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7035/* end confdefs.h. */
7036
7037#include <errno.h>
7038#ifdef ENOLINK
7039yes
7040#endif
7041
7042_ACEOF
7043if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7044 $EGREP "yes" >/dev/null 2>&1; then :
7045 gl_cv_header_errno_h_ENOLINK=yes
7046else
7047 gl_cv_header_errno_h_ENOLINK=no
7048fi
7049rm -f conftest*
7050
7051 if test $gl_cv_header_errno_h_ENOLINK = no; then
7052 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7053/* end confdefs.h. */
7054
7055#define _XOPEN_SOURCE_EXTENDED 1
7056#include <errno.h>
7057#ifdef ENOLINK
7058yes
7059#endif
7060
7061_ACEOF
7062if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7063 $EGREP "yes" >/dev/null 2>&1; then :
7064 gl_cv_header_errno_h_ENOLINK=hidden
7065fi
7066rm -f conftest*
7067
7068 if test $gl_cv_header_errno_h_ENOLINK = hidden; then
7069 if ac_fn_c_compute_int "$LINENO" "ENOLINK" "gl_cv_header_errno_h_ENOLINK" "
7070#define _XOPEN_SOURCE_EXTENDED 1
7071#include <errno.h>
7072/* The following two lines are a workaround against an autoconf-2.52 bug. */
7073#include <stdio.h>
7074#include <stdlib.h>
7075"; then :
7076
7077fi
7078
7079 fi
7080 fi
7081
7082fi
7083{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_ENOLINK" >&5
7084$as_echo "$gl_cv_header_errno_h_ENOLINK" >&6; }
7085 case $gl_cv_header_errno_h_ENOLINK in
7086 yes | no)
7087 ENOLINK_HIDDEN=0; ENOLINK_VALUE=
7088 ;;
7089 *)
7090 ENOLINK_HIDDEN=1; ENOLINK_VALUE="$gl_cv_header_errno_h_ENOLINK"
7091 ;;
7092 esac
7093
7094
7095 fi
7096
7097
7098 if test -n "$ERRNO_H"; then
7099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EOVERFLOW value" >&5
7100$as_echo_n "checking for EOVERFLOW value... " >&6; }
7101if test "${gl_cv_header_errno_h_EOVERFLOW+set}" = set; then :
7102 $as_echo_n "(cached) " >&6
7103else
7104
7105 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7106/* end confdefs.h. */
7107
7108#include <errno.h>
7109#ifdef EOVERFLOW
7110yes
7111#endif
7112
7113_ACEOF
7114if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7115 $EGREP "yes" >/dev/null 2>&1; then :
7116 gl_cv_header_errno_h_EOVERFLOW=yes
7117else
7118 gl_cv_header_errno_h_EOVERFLOW=no
7119fi
7120rm -f conftest*
7121
7122 if test $gl_cv_header_errno_h_EOVERFLOW = no; then
7123 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7124/* end confdefs.h. */
7125
7126#define _XOPEN_SOURCE_EXTENDED 1
7127#include <errno.h>
7128#ifdef EOVERFLOW
7129yes
7130#endif
7131
7132_ACEOF
7133if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7134 $EGREP "yes" >/dev/null 2>&1; then :
7135 gl_cv_header_errno_h_EOVERFLOW=hidden
7136fi
7137rm -f conftest*
7138
7139 if test $gl_cv_header_errno_h_EOVERFLOW = hidden; then
7140 if ac_fn_c_compute_int "$LINENO" "EOVERFLOW" "gl_cv_header_errno_h_EOVERFLOW" "
7141#define _XOPEN_SOURCE_EXTENDED 1
7142#include <errno.h>
7143/* The following two lines are a workaround against an autoconf-2.52 bug. */
7144#include <stdio.h>
7145#include <stdlib.h>
7146"; then :
7147
7148fi
7149
7150 fi
7151 fi
7152
7153fi
7154{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EOVERFLOW" >&5
7155$as_echo "$gl_cv_header_errno_h_EOVERFLOW" >&6; }
7156 case $gl_cv_header_errno_h_EOVERFLOW in
7157 yes | no)
7158 EOVERFLOW_HIDDEN=0; EOVERFLOW_VALUE=
7159 ;;
7160 *)
7161 EOVERFLOW_HIDDEN=1; EOVERFLOW_VALUE="$gl_cv_header_errno_h_EOVERFLOW"
7162 ;;
7163 esac
7164
7165
7166 fi
7167
7168
7169
7170
63ce7108
TT
7171
7172
7173
7174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
7175$as_echo_n "checking for mbstate_t... " >&6; }
7176if test "${ac_cv_type_mbstate_t+set}" = set; then :
7177 $as_echo_n "(cached) " >&6
7178else
7179 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7180/* end confdefs.h. */
7181$ac_includes_default
7182/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
7183 <wchar.h>.
7184 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
7185 included before <wchar.h>. */
7186#include <stddef.h>
7187#include <stdio.h>
7188#include <time.h>
7189#include <wchar.h>
7190int
7191main ()
7192{
7193mbstate_t x; return sizeof x;
7194 ;
7195 return 0;
7196}
7197_ACEOF
7198if ac_fn_c_try_compile "$LINENO"; then :
7199 ac_cv_type_mbstate_t=yes
7200else
7201 ac_cv_type_mbstate_t=no
7202fi
7203rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7204fi
7205{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
7206$as_echo "$ac_cv_type_mbstate_t" >&6; }
7207 if test $ac_cv_type_mbstate_t = yes; then
7208
7209$as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
7210
7211 else
7212
7213$as_echo "#define mbstate_t int" >>confdefs.h
7214
7215 fi
7216
7217
7218
7219
63ce7108
TT
7220
7221
7222
7223
7224
7225
7226
7227
7228
7229
7230
7231
7232
7233
7234
7235
63ce7108
TT
7236 GNULIB_ACOSF=0;
7237 GNULIB_ACOSL=0;
7238 GNULIB_ASINF=0;
7239 GNULIB_ASINL=0;
7240 GNULIB_ATANF=0;
7241 GNULIB_ATANL=0;
7242 GNULIB_ATAN2F=0;
7243 GNULIB_CBRT=0;
7244 GNULIB_CBRTF=0;
7245 GNULIB_CBRTL=0;
7246 GNULIB_CEIL=0;
7247 GNULIB_CEILF=0;
7248 GNULIB_CEILL=0;
7249 GNULIB_COPYSIGN=0;
7250 GNULIB_COPYSIGNF=0;
88b48903
WN
7251 GNULIB_COPYSIGNL=0;
7252 GNULIB_COSF=0;
7253 GNULIB_COSL=0;
7254 GNULIB_COSHF=0;
7255 GNULIB_EXPF=0;
7256 GNULIB_EXPL=0;
7257 GNULIB_EXP2=0;
7258 GNULIB_EXP2F=0;
7259 GNULIB_EXP2L=0;
7260 GNULIB_EXPM1=0;
7261 GNULIB_EXPM1F=0;
7262 GNULIB_EXPM1L=0;
7263 GNULIB_FABSF=0;
7264 GNULIB_FABSL=0;
7265 GNULIB_FLOOR=0;
7266 GNULIB_FLOORF=0;
7267 GNULIB_FLOORL=0;
7268 GNULIB_FMA=0;
7269 GNULIB_FMAF=0;
7270 GNULIB_FMAL=0;
7271 GNULIB_FMOD=0;
7272 GNULIB_FMODF=0;
7273 GNULIB_FMODL=0;
7274 GNULIB_FREXPF=0;
7275 GNULIB_FREXP=0;
7276 GNULIB_FREXPL=0;
7277 GNULIB_HYPOT=0;
7278 GNULIB_HYPOTF=0;
7279 GNULIB_HYPOTL=0;
7280 GNULIB_ILOGB=0;
7281 GNULIB_ILOGBF=0;
7282 GNULIB_ILOGBL=0;
7283 GNULIB_ISFINITE=0;
7284 GNULIB_ISINF=0;
7285 GNULIB_ISNAN=0;
7286 GNULIB_ISNANF=0;
7287 GNULIB_ISNAND=0;
7288 GNULIB_ISNANL=0;
7289 GNULIB_LDEXPF=0;
7290 GNULIB_LDEXPL=0;
7291 GNULIB_LOG=0;
7292 GNULIB_LOGF=0;
7293 GNULIB_LOGL=0;
7294 GNULIB_LOG10=0;
7295 GNULIB_LOG10F=0;
7296 GNULIB_LOG10L=0;
7297 GNULIB_LOG1P=0;
7298 GNULIB_LOG1PF=0;
7299 GNULIB_LOG1PL=0;
7300 GNULIB_LOG2=0;
7301 GNULIB_LOG2F=0;
7302 GNULIB_LOG2L=0;
7303 GNULIB_LOGB=0;
7304 GNULIB_LOGBF=0;
7305 GNULIB_LOGBL=0;
7306 GNULIB_MODF=0;
7307 GNULIB_MODFF=0;
7308 GNULIB_MODFL=0;
7309 GNULIB_POWF=0;
7310 GNULIB_REMAINDER=0;
7311 GNULIB_REMAINDERF=0;
7312 GNULIB_REMAINDERL=0;
7313 GNULIB_RINT=0;
7314 GNULIB_RINTF=0;
7315 GNULIB_RINTL=0;
7316 GNULIB_ROUND=0;
7317 GNULIB_ROUNDF=0;
7318 GNULIB_ROUNDL=0;
7319 GNULIB_SIGNBIT=0;
7320 GNULIB_SINF=0;
7321 GNULIB_SINL=0;
7322 GNULIB_SINHF=0;
7323 GNULIB_SQRTF=0;
7324 GNULIB_SQRTL=0;
7325 GNULIB_TANF=0;
7326 GNULIB_TANL=0;
7327 GNULIB_TANHF=0;
7328 GNULIB_TRUNC=0;
7329 GNULIB_TRUNCF=0;
7330 GNULIB_TRUNCL=0;
7331 HAVE_ACOSF=1;
7332 HAVE_ACOSL=1;
7333 HAVE_ASINF=1;
7334 HAVE_ASINL=1;
7335 HAVE_ATANF=1;
7336 HAVE_ATANL=1;
7337 HAVE_ATAN2F=1;
7338 HAVE_CBRT=1;
7339 HAVE_CBRTF=1;
7340 HAVE_CBRTL=1;
7341 HAVE_COPYSIGN=1;
7342 HAVE_COPYSIGNL=1;
7343 HAVE_COSF=1;
7344 HAVE_COSL=1;
7345 HAVE_COSHF=1;
7346 HAVE_EXPF=1;
7347 HAVE_EXPL=1;
7348 HAVE_EXPM1=1;
7349 HAVE_EXPM1F=1;
7350 HAVE_FABSF=1;
7351 HAVE_FABSL=1;
7352 HAVE_FMA=1;
7353 HAVE_FMAF=1;
7354 HAVE_FMAL=1;
7355 HAVE_FMODF=1;
7356 HAVE_FMODL=1;
7357 HAVE_FREXPF=1;
7358 HAVE_HYPOTF=1;
7359 HAVE_HYPOTL=1;
7360 HAVE_ILOGB=1;
7361 HAVE_ILOGBF=1;
7362 HAVE_ILOGBL=1;
7363 HAVE_ISNANF=1;
7364 HAVE_ISNAND=1;
7365 HAVE_ISNANL=1;
7366 HAVE_LDEXPF=1;
7367 HAVE_LOGF=1;
7368 HAVE_LOGL=1;
7369 HAVE_LOG10F=1;
7370 HAVE_LOG10L=1;
7371 HAVE_LOG1P=1;
7372 HAVE_LOG1PF=1;
7373 HAVE_LOG1PL=1;
7374 HAVE_LOGBF=1;
7375 HAVE_LOGBL=1;
7376 HAVE_MODFF=1;
7377 HAVE_MODFL=1;
7378 HAVE_POWF=1;
7379 HAVE_REMAINDER=1;
7380 HAVE_REMAINDERF=1;
7381 HAVE_RINT=1;
7382 HAVE_RINTL=1;
7383 HAVE_SINF=1;
7384 HAVE_SINL=1;
7385 HAVE_SINHF=1;
7386 HAVE_SQRTF=1;
7387 HAVE_SQRTL=1;
7388 HAVE_TANF=1;
7389 HAVE_TANL=1;
7390 HAVE_TANHF=1;
7391 HAVE_DECL_ACOSL=1;
7392 HAVE_DECL_ASINL=1;
7393 HAVE_DECL_ATANL=1;
7394 HAVE_DECL_CBRTF=1;
7395 HAVE_DECL_CBRTL=1;
7396 HAVE_DECL_CEILF=1;
7397 HAVE_DECL_CEILL=1;
7398 HAVE_DECL_COPYSIGNF=1;
7399 HAVE_DECL_COSL=1;
7400 HAVE_DECL_EXPL=1;
7401 HAVE_DECL_EXP2=1;
7402 HAVE_DECL_EXP2F=1;
7403 HAVE_DECL_EXP2L=1;
7404 HAVE_DECL_EXPM1L=1;
7405 HAVE_DECL_FLOORF=1;
7406 HAVE_DECL_FLOORL=1;
7407 HAVE_DECL_FREXPL=1;
7408 HAVE_DECL_LDEXPL=1;
7409 HAVE_DECL_LOGL=1;
7410 HAVE_DECL_LOG10L=1;
7411 HAVE_DECL_LOG2=1;
7412 HAVE_DECL_LOG2F=1;
7413 HAVE_DECL_LOG2L=1;
7414 HAVE_DECL_LOGB=1;
7415 HAVE_DECL_REMAINDER=1;
7416 HAVE_DECL_REMAINDERL=1;
7417 HAVE_DECL_RINTF=1;
7418 HAVE_DECL_ROUND=1;
7419 HAVE_DECL_ROUNDF=1;
7420 HAVE_DECL_ROUNDL=1;
7421 HAVE_DECL_SINL=1;
7422 HAVE_DECL_SQRTL=1;
7423 HAVE_DECL_TANL=1;
7424 HAVE_DECL_TRUNC=1;
7425 HAVE_DECL_TRUNCF=1;
7426 HAVE_DECL_TRUNCL=1;
7427 REPLACE_CBRTF=0;
7428 REPLACE_CBRTL=0;
7429 REPLACE_CEIL=0;
7430 REPLACE_CEILF=0;
7431 REPLACE_CEILL=0;
7432 REPLACE_EXPM1=0;
7433 REPLACE_EXPM1F=0;
7434 REPLACE_EXP2=0;
7435 REPLACE_EXP2L=0;
7436 REPLACE_FABSL=0;
7437 REPLACE_FLOOR=0;
7438 REPLACE_FLOORF=0;
7439 REPLACE_FLOORL=0;
7440 REPLACE_FMA=0;
7441 REPLACE_FMAF=0;
7442 REPLACE_FMAL=0;
7443 REPLACE_FMOD=0;
7444 REPLACE_FMODF=0;
7445 REPLACE_FMODL=0;
7446 REPLACE_FREXPF=0;
7447 REPLACE_FREXP=0;
7448 REPLACE_FREXPL=0;
7449 REPLACE_HUGE_VAL=0;
7450 REPLACE_HYPOT=0;
7451 REPLACE_HYPOTF=0;
7452 REPLACE_HYPOTL=0;
7453 REPLACE_ILOGB=0;
7454 REPLACE_ILOGBF=0;
7455 REPLACE_ISFINITE=0;
7456 REPLACE_ISINF=0;
7457 REPLACE_ISNAN=0;
7458 REPLACE_LDEXPL=0;
7459 REPLACE_LOG=0;
7460 REPLACE_LOGF=0;
7461 REPLACE_LOGL=0;
7462 REPLACE_LOG10=0;
7463 REPLACE_LOG10F=0;
7464 REPLACE_LOG10L=0;
7465 REPLACE_LOG1P=0;
7466 REPLACE_LOG1PF=0;
7467 REPLACE_LOG1PL=0;
7468 REPLACE_LOG2=0;
7469 REPLACE_LOG2F=0;
7470 REPLACE_LOG2L=0;
7471 REPLACE_LOGB=0;
7472 REPLACE_LOGBF=0;
7473 REPLACE_LOGBL=0;
7474 REPLACE_MODF=0;
7475 REPLACE_MODFF=0;
7476 REPLACE_MODFL=0;
7477 REPLACE_NAN=0;
7478 REPLACE_REMAINDER=0;
7479 REPLACE_REMAINDERF=0;
7480 REPLACE_REMAINDERL=0;
7481 REPLACE_ROUND=0;
7482 REPLACE_ROUNDF=0;
7483 REPLACE_ROUNDL=0;
7484 REPLACE_SIGNBIT=0;
7485 REPLACE_SIGNBIT_USING_GCC=0;
7486 REPLACE_SQRTL=0;
7487 REPLACE_TRUNC=0;
7488 REPLACE_TRUNCF=0;
7489 REPLACE_TRUNCL=0;
7490
7491
7492 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexp() can be used without linking with libm" >&5
7493$as_echo_n "checking whether frexp() can be used without linking with libm... " >&6; }
7494if test "${gl_cv_func_frexp_no_libm+set}" = set; then :
7495 $as_echo_n "(cached) " >&6
7496else
7497
7498 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7499/* end confdefs.h. */
7500#include <math.h>
7501 double x;
7502int
7503main ()
7504{
7505int e; return frexp (x, &e) > 0;
7506 ;
7507 return 0;
7508}
7509_ACEOF
7510if ac_fn_c_try_link "$LINENO"; then :
7511 gl_cv_func_frexp_no_libm=yes
7512else
7513 gl_cv_func_frexp_no_libm=no
7514fi
7515rm -f core conftest.err conftest.$ac_objext \
7516 conftest$ac_exeext conftest.$ac_ext
7517
7518fi
7519{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexp_no_libm" >&5
7520$as_echo "$gl_cv_func_frexp_no_libm" >&6; }
7521
4a626d0a
PA
7522ac_fn_c_check_decl "$LINENO" "alarm" "ac_cv_have_decl_alarm" "$ac_includes_default"
7523if test "x$ac_cv_have_decl_alarm" = x""yes; then :
7524 ac_have_decl=1
7525else
7526 ac_have_decl=0
7527fi
88b48903 7528
4a626d0a
PA
7529cat >>confdefs.h <<_ACEOF
7530#define HAVE_DECL_ALARM $ac_have_decl
7531_ACEOF
88b48903
WN
7532
7533
88b48903
WN
7534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether long double and double are the same" >&5
7535$as_echo_n "checking whether long double and double are the same... " >&6; }
7536if test "${gl_cv_long_double_equals_double+set}" = set; then :
7537 $as_echo_n "(cached) " >&6
7538else
7539 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7540/* end confdefs.h. */
7541#include <float.h>
7542int
7543main ()
7544{
7545typedef int check[sizeof (long double) == sizeof (double)
7546 && LDBL_MANT_DIG == DBL_MANT_DIG
7547 && LDBL_MAX_EXP == DBL_MAX_EXP
7548 && LDBL_MIN_EXP == DBL_MIN_EXP
7549 ? 1 : -1];
7550
7551 ;
7552 return 0;
7553}
7554_ACEOF
7555if ac_fn_c_try_compile "$LINENO"; then :
7556 gl_cv_long_double_equals_double=yes
7557else
7558 gl_cv_long_double_equals_double=no
7559fi
7560rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7561
7562fi
7563{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_long_double_equals_double" >&5
7564$as_echo "$gl_cv_long_double_equals_double" >&6; }
7565 if test $gl_cv_long_double_equals_double = yes; then
7566
7567$as_echo "#define HAVE_SAME_LONG_DOUBLE_AS_DOUBLE 1" >>confdefs.h
7568
7569 HAVE_SAME_LONG_DOUBLE_AS_DOUBLE=1
7570 else
7571 HAVE_SAME_LONG_DOUBLE_AS_DOUBLE=0
7572 fi
7573
7574
4a626d0a
PA
7575{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
7576$as_echo_n "checking for C/C++ restrict keyword... " >&6; }
7577if test "${ac_cv_c_restrict+set}" = set; then :
7578 $as_echo_n "(cached) " >&6
7579else
7580 ac_cv_c_restrict=no
7581 # The order here caters to the fact that C++ does not require restrict.
7582 for ac_kw in __restrict __restrict__ _Restrict restrict; do
7583 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7584/* end confdefs.h. */
7585typedef int *int_ptr;
7586 int foo (int_ptr $ac_kw ip) { return ip[0]; }
7587 int bar (int [$ac_kw]); /* Catch GCC bug 14050. */
7588 int bar (int ip[$ac_kw]) { return ip[0]; }
7589
7590int
7591main ()
7592{
7593int s[1];
7594 int *$ac_kw t = s;
7595 t[0] = 0;
7596 return foo (t) + bar (t);
7597
7598 ;
7599 return 0;
7600}
7601_ACEOF
7602if ac_fn_c_try_compile "$LINENO"; then :
7603 ac_cv_c_restrict=$ac_kw
7604fi
7605rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7606 test "$ac_cv_c_restrict" != no && break
7607 done
7608
7609fi
7610{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
7611$as_echo "$ac_cv_c_restrict" >&6; }
7612
7613 case $ac_cv_c_restrict in
7614 restrict) ;;
7615 no) $as_echo "#define restrict /**/" >>confdefs.h
7616 ;;
7617 *) cat >>confdefs.h <<_ACEOF
7618#define restrict $ac_cv_c_restrict
7619_ACEOF
7620 ;;
7621 esac
7622
7623
7624 GNULIB_GETTIMEOFDAY=0;
7625 HAVE_GETTIMEOFDAY=1;
7626 HAVE_STRUCT_TIMEVAL=1;
7627 HAVE_SYS_TIME_H=1;
7628 HAVE_TIMEZONE_T=0;
7629 REPLACE_GETTIMEOFDAY=0;
7630 REPLACE_STRUCT_TIMEVAL=0;
7631
7632
7633
7634
7635
7636
7637
7638
7639
7640
7641
7642
7643
7644
7645
7646
7647
7648
7649 if test $gl_cv_have_include_next = yes; then
7650 gl_cv_next_sys_time_h='<'sys/time.h'>'
7651 else
7652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
7653$as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
7654if test "${gl_cv_next_sys_time_h+set}" = set; then :
7655 $as_echo_n "(cached) " >&6
7656else
7657
7658 if test $ac_cv_header_sys_time_h = yes; then
7659
7660
7661
7662
7663 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7664/* end confdefs.h. */
7665#include <sys/time.h>
7666_ACEOF
7667 case "$host_os" in
7668 aix*) gl_absname_cpp="$ac_cpp -C" ;;
7669 *) gl_absname_cpp="$ac_cpp" ;;
7670 esac
7671
7672 case "$host_os" in
7673 mingw*)
7674 gl_dirsep_regex='[/\\]'
7675 ;;
7676 *)
7677 gl_dirsep_regex='\/'
7678 ;;
7679 esac
7680 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
7681 gl_header_literal_regex=`echo 'sys/time.h' \
7682 | sed -e "$gl_make_literal_regex_sed"`
7683 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
7684 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
7685 s|^/[^/]|//&|
7686 p
7687 q
7688 }'
7689
7690 gl_cv_absolute_sys_time_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
7691 sed -n "$gl_absolute_header_sed"`
7692
7693 gl_header=$gl_cv_absolute_sys_time_h
7694 gl_cv_next_sys_time_h='"'$gl_header'"'
7695 else
7696 gl_cv_next_sys_time_h='<'sys/time.h'>'
7697 fi
7698
7699
7700fi
7701{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
7702$as_echo "$gl_cv_next_sys_time_h" >&6; }
7703 fi
7704 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
7705
7706 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
7707 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
7708 gl_next_as_first_directive='<'sys/time.h'>'
7709 else
7710 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
7711 gl_next_as_first_directive=$gl_cv_next_sys_time_h
7712 fi
7713 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
7714
7715
7716
7717
7718
7719 if test $ac_cv_header_sys_time_h != yes; then
7720 HAVE_SYS_TIME_H=0
7721 fi
7722
7723
7724
7725
7726
7727 if test $ac_cv_header_sys_socket_h != yes; then
7728 for ac_header in winsock2.h
7729do :
7730 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
7731if test "x$ac_cv_header_winsock2_h" = x""yes; then :
7732 cat >>confdefs.h <<_ACEOF
7733#define HAVE_WINSOCK2_H 1
7734_ACEOF
7735
7736fi
7737
7738done
7739
7740 fi
7741 if test "$ac_cv_header_winsock2_h" = yes; then
7742 HAVE_WINSOCK2_H=1
7743 UNISTD_H_HAVE_WINSOCK2_H=1
7744 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
7745 else
7746 HAVE_WINSOCK2_H=0
7747 fi
7748
7749
7750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
7751$as_echo_n "checking for struct timeval... " >&6; }
7752if test "${gl_cv_sys_struct_timeval+set}" = set; then :
7753 $as_echo_n "(cached) " >&6
7754else
7755 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7756/* end confdefs.h. */
7757#if HAVE_SYS_TIME_H
7758 #include <sys/time.h>
7759 #endif
7760 #include <time.h>
7761 #if HAVE_WINSOCK2_H
7762 # include <winsock2.h>
7763 #endif
7764
7765int
7766main ()
7767{
7768static struct timeval x; x.tv_sec = x.tv_usec;
7769 ;
7770 return 0;
7771}
7772_ACEOF
7773if ac_fn_c_try_compile "$LINENO"; then :
7774 gl_cv_sys_struct_timeval=yes
7775else
7776 gl_cv_sys_struct_timeval=no
7777fi
7778rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7779
7780fi
7781{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
7782$as_echo "$gl_cv_sys_struct_timeval" >&6; }
7783 if test $gl_cv_sys_struct_timeval != yes; then
7784 HAVE_STRUCT_TIMEVAL=0
7785 else
7786 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
7787$as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
7788if test "${gl_cv_sys_struct_timeval_tv_sec+set}" = set; then :
7789 $as_echo_n "(cached) " >&6
7790else
7791 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7792/* end confdefs.h. */
7793#if HAVE_SYS_TIME_H
7794 #include <sys/time.h>
7795 #endif
7796 #include <time.h>
7797 #if HAVE_WINSOCK2_H
7798 # include <winsock2.h>
7799 #endif
7800
7801int
7802main ()
7803{
7804static struct timeval x;
7805 typedef int verify_tv_sec_type[
7806 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
7807 ];
7808
7809 ;
7810 return 0;
7811}
7812_ACEOF
7813if ac_fn_c_try_compile "$LINENO"; then :
7814 gl_cv_sys_struct_timeval_tv_sec=yes
7815else
7816 gl_cv_sys_struct_timeval_tv_sec=no
7817fi
7818rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7819
7820fi
7821{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
7822$as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
7823 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
7824 REPLACE_STRUCT_TIMEVAL=1
7825 fi
7826 fi
7827
7828
7829 for gl_func in gettimeofday; do
7830 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
7831 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
7832$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
7833if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
7834 $as_echo_n "(cached) " >&6
7835else
7836 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7837/* end confdefs.h. */
7838
7839#if HAVE_SYS_TIME_H
7840# include <sys/time.h>
7841#endif
7842#include <time.h>
7843
7844int
7845main ()
7846{
7847#undef $gl_func
7848 (void) $gl_func;
7849 ;
7850 return 0;
7851}
7852_ACEOF
7853if ac_fn_c_try_compile "$LINENO"; then :
7854 eval "$as_gl_Symbol=yes"
7855else
7856 eval "$as_gl_Symbol=no"
7857fi
7858rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7859fi
7860eval ac_res=\$$as_gl_Symbol
7861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7862$as_echo "$ac_res" >&6; }
7863 eval as_val=\$$as_gl_Symbol
7864 if test "x$as_val" = x""yes; then :
7865 cat >>confdefs.h <<_ACEOF
7866#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
7867_ACEOF
7868
7869 eval ac_cv_have_decl_$gl_func=yes
7870fi
7871 done
7872
7873
7874
7875
7876
7877
7878
88b48903 7879
8690e634
JK
7880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
7881$as_echo_n "checking for unsigned long long int... " >&6; }
7882if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
7883 $as_echo_n "(cached) " >&6
7884else
7885 ac_cv_type_unsigned_long_long_int=yes
7886 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
7887 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7888/* end confdefs.h. */
7889
7890 /* For now, do not test the preprocessor; as of 2007 there are too many
7891 implementations with broken preprocessors. Perhaps this can
7892 be revisited in 2012. In the meantime, code should not expect
7893 #if to work with literals wider than 32 bits. */
7894 /* Test literals. */
7895 long long int ll = 9223372036854775807ll;
7896 long long int nll = -9223372036854775807LL;
7897 unsigned long long int ull = 18446744073709551615ULL;
7898 /* Test constant expressions. */
7899 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
7900 ? 1 : -1)];
7901 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
7902 ? 1 : -1)];
7903 int i = 63;
7904int
7905main ()
7906{
7907/* Test availability of runtime routines for shift and division. */
7908 long long int llmax = 9223372036854775807ll;
7909 unsigned long long int ullmax = 18446744073709551615ull;
7910 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
7911 | (llmax / ll) | (llmax % ll)
7912 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
7913 | (ullmax / ull) | (ullmax % ull));
7914 ;
7915 return 0;
7916}
7917
7918_ACEOF
7919if ac_fn_c_try_link "$LINENO"; then :
7920
7921else
7922 ac_cv_type_unsigned_long_long_int=no
7923fi
7924rm -f core conftest.err conftest.$ac_objext \
7925 conftest$ac_exeext conftest.$ac_ext
7926 fi
7927fi
7928{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
7929$as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
7930 if test $ac_cv_type_unsigned_long_long_int = yes; then
7931
7932$as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
7933
7934 fi
7935
7936
7937
7938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
7939$as_echo_n "checking for long long int... " >&6; }
7940if test "${ac_cv_type_long_long_int+set}" = set; then :
7941 $as_echo_n "(cached) " >&6
7942else
7943 ac_cv_type_long_long_int=yes
7944 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
7945 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
7946 if test $ac_cv_type_long_long_int = yes; then
7947 if test "$cross_compiling" = yes; then :
7948 :
7949else
7950 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7951/* end confdefs.h. */
7952#include <limits.h>
7953 #ifndef LLONG_MAX
7954 # define HALF \
7955 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
7956 # define LLONG_MAX (HALF - 1 + HALF)
7957 #endif
7958int
7959main ()
7960{
7961long long int n = 1;
7962 int i;
7963 for (i = 0; ; i++)
7964 {
7965 long long int m = n << i;
7966 if (m >> i != n)
7967 return 1;
7968 if (LLONG_MAX / 2 < m)
7969 break;
7970 }
7971 return 0;
7972 ;
7973 return 0;
7974}
7975_ACEOF
7976if ac_fn_c_try_run "$LINENO"; then :
7977
7978else
7979 ac_cv_type_long_long_int=no
7980fi
7981rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7982 conftest.$ac_objext conftest.beam conftest.$ac_ext
7983fi
7984
7985 fi
7986 fi
7987fi
7988{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
7989$as_echo "$ac_cv_type_long_long_int" >&6; }
7990 if test $ac_cv_type_long_long_int = yes; then
7991
7992$as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
7993
7994 fi
7995
7996
7997
7998
7999
8000
88b48903
WN
8001 gl_cv_c_multiarch=no
8002 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
a143c6de 8003/* end confdefs.h. */
88b48903
WN
8004#ifndef __APPLE_CC__
8005 not a universal capable compiler
8006 #endif
8007 typedef int dummy;
8008
8690e634
JK
8009_ACEOF
8010if ac_fn_c_try_compile "$LINENO"; then :
8011
8012 arch=
8013 prev=
8014 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
8015 if test -n "$prev"; then
8016 case $word in
8017 i?86 | x86_64 | ppc | ppc64)
8018 if test -z "$arch" || test "$arch" = "$word"; then
8019 arch="$word"
8020 else
8021 gl_cv_c_multiarch=yes
8022 fi
8023 ;;
8024 esac
8025 prev=
8026 else
8027 if test "x$word" = "x-arch"; then
8028 prev=arch
8029 fi
8030 fi
8031 done
8032
8033fi
8034rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8035 if test $gl_cv_c_multiarch = yes; then
8036 APPLE_UNIVERSAL_BUILD=1
8037 else
8038 APPLE_UNIVERSAL_BUILD=0
8039 fi
8040
8041
8042
8043
8044
8045 if test $ac_cv_type_long_long_int = yes; then
8046 HAVE_LONG_LONG_INT=1
8047 else
8048 HAVE_LONG_LONG_INT=0
8049 fi
8050
8051
8052 if test $ac_cv_type_unsigned_long_long_int = yes; then
8053 HAVE_UNSIGNED_LONG_LONG_INT=1
8054 else
8055 HAVE_UNSIGNED_LONG_LONG_INT=0
8056 fi
8057
8058
8059
8690e634
JK
8060 if test $ac_cv_header_wchar_h = yes; then
8061 HAVE_WCHAR_H=1
8062 else
8063 HAVE_WCHAR_H=0
8064 fi
8065
8066
8067 if test $ac_cv_header_inttypes_h = yes; then
8068 HAVE_INTTYPES_H=1
8069 else
8070 HAVE_INTTYPES_H=0
8071 fi
8072
8073
8074 if test $ac_cv_header_sys_types_h = yes; then
8075 HAVE_SYS_TYPES_H=1
8076 else
8077 HAVE_SYS_TYPES_H=0
8078 fi
8079
8080
8081
8082
8083
8084
8085
8086
8690e634
JK
8087
8088
8089
8090 if test $gl_cv_have_include_next = yes; then
8091 gl_cv_next_stdint_h='<'stdint.h'>'
8092 else
8093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
8094$as_echo_n "checking absolute name of <stdint.h>... " >&6; }
8095if test "${gl_cv_next_stdint_h+set}" = set; then :
8096 $as_echo_n "(cached) " >&6
8097else
8098
8099 if test $ac_cv_header_stdint_h = yes; then
8100
8101
4a626d0a
PA
8102
8103
8104 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8690e634
JK
8105/* end confdefs.h. */
8106#include <stdint.h>
8690e634 8107_ACEOF
4a626d0a
PA
8108 case "$host_os" in
8109 aix*) gl_absname_cpp="$ac_cpp -C" ;;
8110 *) gl_absname_cpp="$ac_cpp" ;;
8111 esac
8112
8113 case "$host_os" in
8114 mingw*)
8115 gl_dirsep_regex='[/\\]'
8116 ;;
8117 *)
8118 gl_dirsep_regex='\/'
8119 ;;
8120 esac
8121 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
8122 gl_header_literal_regex=`echo 'stdint.h' \
8123 | sed -e "$gl_make_literal_regex_sed"`
8124 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
8125 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
8126 s|^/[^/]|//&|
8127 p
8128 q
8129 }'
8130
8131 gl_cv_absolute_stdint_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
8132 sed -n "$gl_absolute_header_sed"`
8133
8134 gl_header=$gl_cv_absolute_stdint_h
8135 gl_cv_next_stdint_h='"'$gl_header'"'
8690e634
JK
8136 else
8137 gl_cv_next_stdint_h='<'stdint.h'>'
8138 fi
8139
8140
8141fi
8142{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
8143$as_echo "$gl_cv_next_stdint_h" >&6; }
8144 fi
8145 NEXT_STDINT_H=$gl_cv_next_stdint_h
8146
8147 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
8148 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
8149 gl_next_as_first_directive='<'stdint.h'>'
8150 else
8151 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
8152 gl_next_as_first_directive=$gl_cv_next_stdint_h
8153 fi
8154 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
8155
8156
8157
8158
8159 if test $ac_cv_header_stdint_h = yes; then
8160 HAVE_STDINT_H=1
8161 else
8162 HAVE_STDINT_H=0
8163 fi
8164
8165
8166 if test $ac_cv_header_stdint_h = yes; then
8167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
8168$as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
8169if test "${gl_cv_header_working_stdint_h+set}" = set; then :
8170 $as_echo_n "(cached) " >&6
8171else
8172 gl_cv_header_working_stdint_h=no
8173 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8174/* end confdefs.h. */
8175
8176
8177#define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
8178#include <stdint.h>
8179/* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
8180#if !(defined WCHAR_MIN && defined WCHAR_MAX)
8181#error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
8182#endif
8183
8184
8185 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
8186 included before <wchar.h>. */
8187 #include <stddef.h>
8188 #include <signal.h>
8189 #if HAVE_WCHAR_H
8190 # include <stdio.h>
8191 # include <time.h>
8192 # include <wchar.h>
8193 #endif
8194
8195
8196#ifdef INT8_MAX
8197int8_t a1 = INT8_MAX;
8198int8_t a1min = INT8_MIN;
8199#endif
8200#ifdef INT16_MAX
8201int16_t a2 = INT16_MAX;
8202int16_t a2min = INT16_MIN;
8203#endif
8204#ifdef INT32_MAX
8205int32_t a3 = INT32_MAX;
8206int32_t a3min = INT32_MIN;
8207#endif
8208#ifdef INT64_MAX
8209int64_t a4 = INT64_MAX;
8210int64_t a4min = INT64_MIN;
8211#endif
8212#ifdef UINT8_MAX
8213uint8_t b1 = UINT8_MAX;
8214#else
8215typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
8216#endif
8217#ifdef UINT16_MAX
8218uint16_t b2 = UINT16_MAX;
8219#endif
8220#ifdef UINT32_MAX
8221uint32_t b3 = UINT32_MAX;
8222#endif
8223#ifdef UINT64_MAX
8224uint64_t b4 = UINT64_MAX;
8225#endif
8226int_least8_t c1 = INT8_C (0x7f);
8227int_least8_t c1max = INT_LEAST8_MAX;
8228int_least8_t c1min = INT_LEAST8_MIN;
8229int_least16_t c2 = INT16_C (0x7fff);
8230int_least16_t c2max = INT_LEAST16_MAX;
8231int_least16_t c2min = INT_LEAST16_MIN;
8232int_least32_t c3 = INT32_C (0x7fffffff);
8233int_least32_t c3max = INT_LEAST32_MAX;
8234int_least32_t c3min = INT_LEAST32_MIN;
8235int_least64_t c4 = INT64_C (0x7fffffffffffffff);
8236int_least64_t c4max = INT_LEAST64_MAX;
8237int_least64_t c4min = INT_LEAST64_MIN;
8238uint_least8_t d1 = UINT8_C (0xff);
8239uint_least8_t d1max = UINT_LEAST8_MAX;
8240uint_least16_t d2 = UINT16_C (0xffff);
8241uint_least16_t d2max = UINT_LEAST16_MAX;
8242uint_least32_t d3 = UINT32_C (0xffffffff);
8243uint_least32_t d3max = UINT_LEAST32_MAX;
8244uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
8245uint_least64_t d4max = UINT_LEAST64_MAX;
8246int_fast8_t e1 = INT_FAST8_MAX;
8247int_fast8_t e1min = INT_FAST8_MIN;
8248int_fast16_t e2 = INT_FAST16_MAX;
8249int_fast16_t e2min = INT_FAST16_MIN;
8250int_fast32_t e3 = INT_FAST32_MAX;
8251int_fast32_t e3min = INT_FAST32_MIN;
8252int_fast64_t e4 = INT_FAST64_MAX;
8253int_fast64_t e4min = INT_FAST64_MIN;
8254uint_fast8_t f1 = UINT_FAST8_MAX;
8255uint_fast16_t f2 = UINT_FAST16_MAX;
8256uint_fast32_t f3 = UINT_FAST32_MAX;
8257uint_fast64_t f4 = UINT_FAST64_MAX;
8258#ifdef INTPTR_MAX
8259intptr_t g = INTPTR_MAX;
8260intptr_t gmin = INTPTR_MIN;
8261#endif
8262#ifdef UINTPTR_MAX
8263uintptr_t h = UINTPTR_MAX;
8264#endif
8265intmax_t i = INTMAX_MAX;
8266uintmax_t j = UINTMAX_MAX;
8267
8268#include <limits.h> /* for CHAR_BIT */
8269#define TYPE_MINIMUM(t) \
8270 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
8271#define TYPE_MAXIMUM(t) \
8272 ((t) ((t) 0 < (t) -1 \
8273 ? (t) -1 \
8274 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
8275struct s {
8276 int check_PTRDIFF:
8277 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
8278 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
8279 ? 1 : -1;
8280 /* Detect bug in FreeBSD 6.0 / ia64. */
8281 int check_SIG_ATOMIC:
8282 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
8283 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
8284 ? 1 : -1;
8285 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
8286 int check_WCHAR:
8287 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
8288 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
8289 ? 1 : -1;
8290 /* Detect bug in mingw. */
8291 int check_WINT:
8292 WINT_MIN == TYPE_MINIMUM (wint_t)
8293 && WINT_MAX == TYPE_MAXIMUM (wint_t)
8294 ? 1 : -1;
8295
8296 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
8297 int check_UINT8_C:
8298 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
8299 int check_UINT16_C:
8300 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
8301
8302 /* Detect bugs in OpenBSD 3.9 stdint.h. */
8303#ifdef UINT8_MAX
8304 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
8305#endif
8306#ifdef UINT16_MAX
8307 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
8308#endif
8309#ifdef UINT32_MAX
8310 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
8311#endif
8312#ifdef UINT64_MAX
8313 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
8314#endif
8315 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
8316 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
8317 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
8318 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
8319 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
8320 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
8321 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
8322 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
8323 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
8324 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
8325 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
8326};
8327
8328int
8329main ()
8330{
8331
8332 ;
8333 return 0;
8334}
8335_ACEOF
8336if ac_fn_c_try_compile "$LINENO"; then :
8337 if test "$cross_compiling" = yes; then :
8338 gl_cv_header_working_stdint_h=yes
8339
8340else
8341 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8342/* end confdefs.h. */
8343
8344
8345#define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
8346#include <stdint.h>
8347
8348
8349 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
8350 included before <wchar.h>. */
8351 #include <stddef.h>
8352 #include <signal.h>
8353 #if HAVE_WCHAR_H
8354 # include <stdio.h>
8355 # include <time.h>
8356 # include <wchar.h>
8357 #endif
8358
8359
8360#include <stdio.h>
8361#include <string.h>
8362#define MVAL(macro) MVAL1(macro)
8363#define MVAL1(expression) #expression
8364static const char *macro_values[] =
8365 {
8366#ifdef INT8_MAX
8367 MVAL (INT8_MAX),
8368#endif
8369#ifdef INT16_MAX
8370 MVAL (INT16_MAX),
8371#endif
8372#ifdef INT32_MAX
8373 MVAL (INT32_MAX),
8374#endif
8375#ifdef INT64_MAX
8376 MVAL (INT64_MAX),
8377#endif
8378#ifdef UINT8_MAX
8379 MVAL (UINT8_MAX),
8380#endif
8381#ifdef UINT16_MAX
8382 MVAL (UINT16_MAX),
8383#endif
8384#ifdef UINT32_MAX
8385 MVAL (UINT32_MAX),
8386#endif
8387#ifdef UINT64_MAX
8388 MVAL (UINT64_MAX),
8389#endif
8390 NULL
8391 };
8392
8393int
8394main ()
8395{
8396
8397 const char **mv;
8398 for (mv = macro_values; *mv != NULL; mv++)
8399 {
8400 const char *value = *mv;
8401 /* Test whether it looks like a cast expression. */
8402 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
8403 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
8404 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
8405 || strncmp (value, "((int)"/*)*/, 6) == 0
8406 || strncmp (value, "((signed short)"/*)*/, 15) == 0
8407 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
8408 return mv - macro_values + 1;
8409 }
8410 return 0;
8411
8412 ;
8413 return 0;
8414}
8415_ACEOF
8416if ac_fn_c_try_run "$LINENO"; then :
8417 gl_cv_header_working_stdint_h=yes
8418fi
8419rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8420 conftest.$ac_objext conftest.beam conftest.$ac_ext
8421fi
8422
8423
8424fi
8425rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8426
8427fi
8428{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
8429$as_echo "$gl_cv_header_working_stdint_h" >&6; }
8430 fi
8431 if test "$gl_cv_header_working_stdint_h" = yes; then
8432 STDINT_H=
8433 else
8434 for ac_header in sys/inttypes.h sys/bitypes.h
8435do :
8436 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8437ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8438eval as_val=\$$as_ac_Header
8439 if test "x$as_val" = x""yes; then :
8440 cat >>confdefs.h <<_ACEOF
8441#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8442_ACEOF
8443
8444fi
8445
8446done
8447
8448 if test $ac_cv_header_sys_inttypes_h = yes; then
8449 HAVE_SYS_INTTYPES_H=1
8450 else
8451 HAVE_SYS_INTTYPES_H=0
8452 fi
8453
8454 if test $ac_cv_header_sys_bitypes_h = yes; then
8455 HAVE_SYS_BITYPES_H=1
8456 else
8457 HAVE_SYS_BITYPES_H=0
8458 fi
8459
8460
8461
8462
8463 if test $APPLE_UNIVERSAL_BUILD = 0; then
8464
8465
8466 for gltype in ptrdiff_t size_t ; do
8467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
8468$as_echo_n "checking for bit size of $gltype... " >&6; }
8469if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
8470 $as_echo_n "(cached) " >&6
8471else
8472 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
8473 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
8474 included before <wchar.h>. */
8475 #include <stddef.h>
8476 #include <signal.h>
8477 #if HAVE_WCHAR_H
8478 # include <stdio.h>
8479 # include <time.h>
8480 # include <wchar.h>
8481 #endif
8482
8483#include <limits.h>"; then :
8484
8485else
8486 result=unknown
8487fi
8488
8489 eval gl_cv_bitsizeof_${gltype}=\$result
8490
8491fi
8492eval ac_res=\$gl_cv_bitsizeof_${gltype}
8493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
8494$as_echo "$ac_res" >&6; }
8495 eval result=\$gl_cv_bitsizeof_${gltype}
8496 if test $result = unknown; then
8497 result=0
8498 fi
8499 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
8500 cat >>confdefs.h <<_ACEOF
8501#define BITSIZEOF_${GLTYPE} $result
8502_ACEOF
8503
8504 eval BITSIZEOF_${GLTYPE}=\$result
8505 done
8506
8507
8508 fi
8509
8510
8511 for gltype in sig_atomic_t wchar_t wint_t ; do
8512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
8513$as_echo_n "checking for bit size of $gltype... " >&6; }
8514if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
8515 $as_echo_n "(cached) " >&6
8516else
8517 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
8518 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
8519 included before <wchar.h>. */
8520 #include <stddef.h>
8521 #include <signal.h>
8522 #if HAVE_WCHAR_H
8523 # include <stdio.h>
8524 # include <time.h>
8525 # include <wchar.h>
8526 #endif
8527
8528#include <limits.h>"; then :
8529
8530else
8531 result=unknown
8532fi
8533
8534 eval gl_cv_bitsizeof_${gltype}=\$result
8535
8536fi
8537eval ac_res=\$gl_cv_bitsizeof_${gltype}
8538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
8539$as_echo "$ac_res" >&6; }
8540 eval result=\$gl_cv_bitsizeof_${gltype}
8541 if test $result = unknown; then
8542 result=0
8543 fi
8544 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
8545 cat >>confdefs.h <<_ACEOF
8546#define BITSIZEOF_${GLTYPE} $result
8547_ACEOF
8548
8549 eval BITSIZEOF_${GLTYPE}=\$result
8550 done
8551
8552
8553
8554
8555 for gltype in sig_atomic_t wchar_t wint_t ; do
8556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
8557$as_echo_n "checking whether $gltype is signed... " >&6; }
8558if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
8559 $as_echo_n "(cached) " >&6
8560else
8561 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8562/* end confdefs.h. */
8563
8564 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
8565 included before <wchar.h>. */
8566 #include <stddef.h>
8567 #include <signal.h>
8568 #if HAVE_WCHAR_H
8569 # include <stdio.h>
8570 # include <time.h>
8571 # include <wchar.h>
8572 #endif
8573
8574 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
8575int
8576main ()
8577{
8578
8579 ;
8580 return 0;
8581}
8582_ACEOF
8583if ac_fn_c_try_compile "$LINENO"; then :
8584 result=yes
8585else
8586 result=no
8587fi
8588rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8589 eval gl_cv_type_${gltype}_signed=\$result
8590
8591fi
8592eval ac_res=\$gl_cv_type_${gltype}_signed
8593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
8594$as_echo "$ac_res" >&6; }
8595 eval result=\$gl_cv_type_${gltype}_signed
8596 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
8597 if test "$result" = yes; then
8598 cat >>confdefs.h <<_ACEOF
8599#define HAVE_SIGNED_${GLTYPE} 1
8600_ACEOF
8601
8602 eval HAVE_SIGNED_${GLTYPE}=1
8603 else
8604 eval HAVE_SIGNED_${GLTYPE}=0
8605 fi
8606 done
8607
8608
8609 gl_cv_type_ptrdiff_t_signed=yes
8610 gl_cv_type_size_t_signed=no
8611 if test $APPLE_UNIVERSAL_BUILD = 0; then
8612
8613
8614 for gltype in ptrdiff_t size_t ; do
8615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
8616$as_echo_n "checking for $gltype integer literal suffix... " >&6; }
8617if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
8618 $as_echo_n "(cached) " >&6
8619else
8620 eval gl_cv_type_${gltype}_suffix=no
8621 eval result=\$gl_cv_type_${gltype}_signed
8622 if test "$result" = yes; then
8623 glsufu=
8624 else
8625 glsufu=u
8626 fi
8627 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
8628 case $glsuf in
8629 '') gltype1='int';;
8630 l) gltype1='long int';;
8631 ll) gltype1='long long int';;
8632 i64) gltype1='__int64';;
8633 u) gltype1='unsigned int';;
8634 ul) gltype1='unsigned long int';;
8635 ull) gltype1='unsigned long long int';;
8636 ui64)gltype1='unsigned __int64';;
8637 esac
8638 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8639/* end confdefs.h. */
8640
8641 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
8642 included before <wchar.h>. */
8643 #include <stddef.h>
8644 #include <signal.h>
8645 #if HAVE_WCHAR_H
8646 # include <stdio.h>
8647 # include <time.h>
8648 # include <wchar.h>
8649 #endif
8650
8651 extern $gltype foo;
8652 extern $gltype1 foo;
8653int
8654main ()
8655{
8656
8657 ;
8658 return 0;
8659}
8660_ACEOF
8661if ac_fn_c_try_compile "$LINENO"; then :
8662 eval gl_cv_type_${gltype}_suffix=\$glsuf
8663fi
8664rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8665 eval result=\$gl_cv_type_${gltype}_suffix
8666 test "$result" != no && break
8667 done
8668fi
8669eval ac_res=\$gl_cv_type_${gltype}_suffix
8670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
8671$as_echo "$ac_res" >&6; }
8672 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
8673 eval result=\$gl_cv_type_${gltype}_suffix
8674 test "$result" = no && result=
8675 eval ${GLTYPE}_SUFFIX=\$result
8676 cat >>confdefs.h <<_ACEOF
8677#define ${GLTYPE}_SUFFIX $result
8678_ACEOF
8679
8680 done
8681
8682
8683 fi
8684
8685
8686 for gltype in sig_atomic_t wchar_t wint_t ; do
8687 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
8688$as_echo_n "checking for $gltype integer literal suffix... " >&6; }
8689if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
8690 $as_echo_n "(cached) " >&6
8691else
8692 eval gl_cv_type_${gltype}_suffix=no
8693 eval result=\$gl_cv_type_${gltype}_signed
8694 if test "$result" = yes; then
8695 glsufu=
8696 else
8697 glsufu=u
8698 fi
8699 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
8700 case $glsuf in
8701 '') gltype1='int';;
8702 l) gltype1='long int';;
8703 ll) gltype1='long long int';;
8704 i64) gltype1='__int64';;
8705 u) gltype1='unsigned int';;
8706 ul) gltype1='unsigned long int';;
8707 ull) gltype1='unsigned long long int';;
8708 ui64)gltype1='unsigned __int64';;
8709 esac
8710 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8711/* end confdefs.h. */
8712
8713 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
8714 included before <wchar.h>. */
8715 #include <stddef.h>
8716 #include <signal.h>
8717 #if HAVE_WCHAR_H
8718 # include <stdio.h>
8719 # include <time.h>
8720 # include <wchar.h>
8721 #endif
8722
8723 extern $gltype foo;
8724 extern $gltype1 foo;
8725int
8726main ()
8727{
8728
8729 ;
8730 return 0;
8731}
8732_ACEOF
8733if ac_fn_c_try_compile "$LINENO"; then :
8734 eval gl_cv_type_${gltype}_suffix=\$glsuf
8735fi
8736rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8737 eval result=\$gl_cv_type_${gltype}_suffix
8738 test "$result" != no && break
8739 done
8740fi
8741eval ac_res=\$gl_cv_type_${gltype}_suffix
8742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
8743$as_echo "$ac_res" >&6; }
8744 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
8745 eval result=\$gl_cv_type_${gltype}_suffix
8746 test "$result" = no && result=
8747 eval ${GLTYPE}_SUFFIX=\$result
8748 cat >>confdefs.h <<_ACEOF
8749#define ${GLTYPE}_SUFFIX $result
8750_ACEOF
8751
8752 done
8753
8754
8755
8756 if test $BITSIZEOF_WINT_T -lt 32; then
8757 BITSIZEOF_WINT_T=32
8758 fi
8759
8760 STDINT_H=stdint.h
8761 fi
8762
8763 if test -n "$STDINT_H"; then
8764 GL_GENERATE_STDINT_H_TRUE=
8765 GL_GENERATE_STDINT_H_FALSE='#'
8766else
8767 GL_GENERATE_STDINT_H_TRUE='#'
8768 GL_GENERATE_STDINT_H_FALSE=
8769fi
8770
8771
8772
8773
8774
8690e634
JK
8775 GNULIB_IMAXABS=0;
8776 GNULIB_IMAXDIV=0;
8777 GNULIB_STRTOIMAX=0;
8778 GNULIB_STRTOUMAX=0;
8779 HAVE_DECL_IMAXABS=1;
8780 HAVE_DECL_IMAXDIV=1;
8781 HAVE_DECL_STRTOIMAX=1;
8782 HAVE_DECL_STRTOUMAX=1;
8783 REPLACE_STRTOIMAX=0;
4a626d0a 8784 REPLACE_STRTOUMAX=0;
8690e634
JK
8785 INT32_MAX_LT_INTMAX_MAX=1;
8786 INT64_MAX_EQ_LONG_MAX='defined _LP64';
8787 PRI_MACROS_BROKEN=0;
8788 PRIPTR_PREFIX=__PRIPTR_PREFIX;
8789 UINT32_MAX_LT_UINTMAX_MAX=1;
8790 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
8791
8792
8793
8794
8690e634
JK
8795
8796
8797
8798
8799
8800
8801
8802
8803
8804
8805
8690e634
JK
8806 if test $gl_cv_have_include_next = yes; then
8807 gl_cv_next_inttypes_h='<'inttypes.h'>'
8808 else
8809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
8810$as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
8811if test "${gl_cv_next_inttypes_h+set}" = set; then :
8812 $as_echo_n "(cached) " >&6
8813else
8814
8815 if test $ac_cv_header_inttypes_h = yes; then
8816
8817
4a626d0a
PA
8818
8819
8820 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8690e634
JK
8821/* end confdefs.h. */
8822#include <inttypes.h>
8690e634 8823_ACEOF
4a626d0a
PA
8824 case "$host_os" in
8825 aix*) gl_absname_cpp="$ac_cpp -C" ;;
8826 *) gl_absname_cpp="$ac_cpp" ;;
8827 esac
8828
8829 case "$host_os" in
8830 mingw*)
8831 gl_dirsep_regex='[/\\]'
8832 ;;
8833 *)
8834 gl_dirsep_regex='\/'
8835 ;;
8836 esac
8837 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
8838 gl_header_literal_regex=`echo 'inttypes.h' \
8839 | sed -e "$gl_make_literal_regex_sed"`
8840 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
8841 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
8842 s|^/[^/]|//&|
8843 p
8844 q
8845 }'
8846
8847 gl_cv_absolute_inttypes_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
8848 sed -n "$gl_absolute_header_sed"`
8849
8850 gl_header=$gl_cv_absolute_inttypes_h
8851 gl_cv_next_inttypes_h='"'$gl_header'"'
8690e634
JK
8852 else
8853 gl_cv_next_inttypes_h='<'inttypes.h'>'
8854 fi
8855
8856
8857fi
8858{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
8859$as_echo "$gl_cv_next_inttypes_h" >&6; }
8860 fi
8861 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
8862
8863 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
8864 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
8865 gl_next_as_first_directive='<'inttypes.h'>'
8866 else
8867 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
8868 gl_next_as_first_directive=$gl_cv_next_inttypes_h
8869 fi
8870 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
8871
8872
8873
8874
8875
8876
8877
8878
8879 for gl_func in imaxabs imaxdiv strtoimax strtoumax; do
8880 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
8881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
8882$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
8883if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
8884 $as_echo_n "(cached) " >&6
8885else
8886 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8887/* end confdefs.h. */
8888#include <inttypes.h>
8889
8890int
8891main ()
8892{
8893#undef $gl_func
8894 (void) $gl_func;
8895 ;
8896 return 0;
8897}
8898_ACEOF
8899if ac_fn_c_try_compile "$LINENO"; then :
8900 eval "$as_gl_Symbol=yes"
8901else
8902 eval "$as_gl_Symbol=no"
8903fi
8904rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8905fi
8906eval ac_res=\$$as_gl_Symbol
8907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
8908$as_echo "$ac_res" >&6; }
8909 eval as_val=\$$as_gl_Symbol
8910 if test "x$as_val" = x""yes; then :
8911 cat >>confdefs.h <<_ACEOF
8912#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
8913_ACEOF
8914
8915 eval ac_cv_have_decl_$gl_func=yes
8916fi
8917 done
8918
8919
8920
8921 for ac_header in inttypes.h
8922do :
8923 ac_fn_c_check_header_mongrel "$LINENO" "inttypes.h" "ac_cv_header_inttypes_h" "$ac_includes_default"
8924if test "x$ac_cv_header_inttypes_h" = x""yes; then :
8925 cat >>confdefs.h <<_ACEOF
8926#define HAVE_INTTYPES_H 1
8927_ACEOF
8928
8929fi
8930
8931done
8932
8933 if test $ac_cv_header_inttypes_h = yes; then
8934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the inttypes.h PRIxNN macros are broken" >&5
8935$as_echo_n "checking whether the inttypes.h PRIxNN macros are broken... " >&6; }
8936if test "${gt_cv_inttypes_pri_broken+set}" = set; then :
8937 $as_echo_n "(cached) " >&6
8938else
8939
8940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8941/* end confdefs.h. */
8942
8943#include <inttypes.h>
8944#ifdef PRId32
8945char *p = PRId32;
8946#endif
8947
8948int
8949main ()
8950{
8951
8952 ;
8953 return 0;
8954}
8955_ACEOF
8956if ac_fn_c_try_compile "$LINENO"; then :
8957 gt_cv_inttypes_pri_broken=no
8958else
8959 gt_cv_inttypes_pri_broken=yes
8960fi
8961rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8962
8963fi
8964{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_inttypes_pri_broken" >&5
8965$as_echo "$gt_cv_inttypes_pri_broken" >&6; }
8966 fi
8967 if test "$gt_cv_inttypes_pri_broken" = yes; then
8968
8969cat >>confdefs.h <<_ACEOF
8970#define PRI_MACROS_BROKEN 1
8971_ACEOF
8972
8973 PRI_MACROS_BROKEN=1
8974 else
8975 PRI_MACROS_BROKEN=0
8976 fi
8977
8978
8979
88b48903
WN
8980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'double'" >&5
8981$as_echo_n "checking where to find the exponent in a 'double'... " >&6; }
8982if test "${gl_cv_cc_double_expbit0+set}" = set; then :
8690e634
JK
8983 $as_echo_n "(cached) " >&6
8984else
88b48903
WN
8985
8986 if test "$cross_compiling" = yes; then :
8987
8988 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8690e634 8989/* end confdefs.h. */
88b48903
WN
8990
8991#if defined arm || defined __arm || defined __arm__
8992 mixed_endianness
8993#endif
8994
8995_ACEOF
8996if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8997 $EGREP "mixed_endianness" >/dev/null 2>&1; then :
8998 gl_cv_cc_double_expbit0="unknown"
8999else
9000
9001 :
9002if test "${ac_cv_c_bigendian+set}" = set; then :
9003 $as_echo_n "(cached) " >&6
9004else
9005 ac_cv_c_bigendian=unknown
9006 # See if we're dealing with a universal compiler.
9007 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9008/* end confdefs.h. */
9009#ifndef __APPLE_CC__
9010 not a universal capable compiler
9011 #endif
9012 typedef int dummy;
9013
9014_ACEOF
9015if ac_fn_c_try_compile "$LINENO"; then :
9016
9017 # Check for potential -arch flags. It is not universal unless
9018 # there are at least two -arch flags with different values.
9019 ac_arch=
9020 ac_prev=
9021 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
9022 if test -n "$ac_prev"; then
9023 case $ac_word in
9024 i?86 | x86_64 | ppc | ppc64)
9025 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
9026 ac_arch=$ac_word
9027 else
9028 ac_cv_c_bigendian=universal
9029 break
9030 fi
9031 ;;
9032 esac
9033 ac_prev=
9034 elif test "x$ac_word" = "x-arch"; then
9035 ac_prev=arch
9036 fi
9037 done
9038fi
9039rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9040 if test $ac_cv_c_bigendian = unknown; then
9041 # See if sys/param.h defines the BYTE_ORDER macro.
9042 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9043/* end confdefs.h. */
9044#include <sys/types.h>
9045 #include <sys/param.h>
9046
8690e634
JK
9047int
9048main ()
9049{
88b48903
WN
9050#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
9051 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
9052 && LITTLE_ENDIAN)
9053 bogus endian macros
9054 #endif
9055
8690e634
JK
9056 ;
9057 return 0;
9058}
9059_ACEOF
88b48903
WN
9060if ac_fn_c_try_compile "$LINENO"; then :
9061 # It does; now see whether it defined to BIG_ENDIAN or not.
9062 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9063/* end confdefs.h. */
9064#include <sys/types.h>
9065 #include <sys/param.h>
9066
9067int
9068main ()
9069{
9070#if BYTE_ORDER != BIG_ENDIAN
9071 not big endian
9072 #endif
9073
9074 ;
9075 return 0;
9076}
9077_ACEOF
9078if ac_fn_c_try_compile "$LINENO"; then :
9079 ac_cv_c_bigendian=yes
8690e634 9080else
88b48903 9081 ac_cv_c_bigendian=no
8690e634 9082fi
88b48903 9083rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8690e634 9084fi
88b48903
WN
9085rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9086 fi
9087 if test $ac_cv_c_bigendian = unknown; then
9088 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
9089 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9090/* end confdefs.h. */
9091#include <limits.h>
8690e634 9092
88b48903
WN
9093int
9094main ()
9095{
9096#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
9097 bogus endian macros
9098 #endif
8690e634 9099
88b48903
WN
9100 ;
9101 return 0;
9102}
9103_ACEOF
9104if ac_fn_c_try_compile "$LINENO"; then :
9105 # It does; now see whether it defined to _BIG_ENDIAN or not.
9106 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9107/* end confdefs.h. */
9108#include <limits.h>
8690e634 9109
88b48903
WN
9110int
9111main ()
9112{
9113#ifndef _BIG_ENDIAN
9114 not big endian
9115 #endif
8690e634 9116
88b48903
WN
9117 ;
9118 return 0;
9119}
9120_ACEOF
9121if ac_fn_c_try_compile "$LINENO"; then :
9122 ac_cv_c_bigendian=yes
9123else
9124 ac_cv_c_bigendian=no
9125fi
9126rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9127fi
9128rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9129 fi
9130 if test $ac_cv_c_bigendian = unknown; then
9131 # Compile a test program.
9132 if test "$cross_compiling" = yes; then :
9133 # Try to guess by grepping values from an object file.
9134 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9135/* end confdefs.h. */
9136short int ascii_mm[] =
9137 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
9138 short int ascii_ii[] =
9139 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
9140 int use_ascii (int i) {
9141 return ascii_mm[i] + ascii_ii[i];
9142 }
9143 short int ebcdic_ii[] =
9144 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
9145 short int ebcdic_mm[] =
9146 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
9147 int use_ebcdic (int i) {
9148 return ebcdic_mm[i] + ebcdic_ii[i];
9149 }
9150 extern int foo;
8690e634 9151
88b48903
WN
9152int
9153main ()
9154{
9155return use_ascii (foo) == use_ebcdic (foo);
9156 ;
9157 return 0;
9158}
9159_ACEOF
9160if ac_fn_c_try_compile "$LINENO"; then :
9161 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
9162 ac_cv_c_bigendian=yes
9163 fi
9164 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
9165 if test "$ac_cv_c_bigendian" = unknown; then
9166 ac_cv_c_bigendian=no
9167 else
9168 # finding both strings is unlikely to happen, but who knows?
9169 ac_cv_c_bigendian=unknown
9170 fi
9171 fi
9172fi
9173rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9174else
9175 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9176/* end confdefs.h. */
9177$ac_includes_default
9178int
9179main ()
9180{
8690e634 9181
88b48903
WN
9182 /* Are we little or big endian? From Harbison&Steele. */
9183 union
9184 {
9185 long int l;
9186 char c[sizeof (long int)];
9187 } u;
9188 u.l = 1;
9189 return u.c[sizeof (long int) - 1] == 1;
8690e634 9190
88b48903
WN
9191 ;
9192 return 0;
9193}
9194_ACEOF
9195if ac_fn_c_try_run "$LINENO"; then :
9196 ac_cv_c_bigendian=no
9197else
9198 ac_cv_c_bigendian=yes
9199fi
9200rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9201 conftest.$ac_objext conftest.beam conftest.$ac_ext
9202fi
8690e634 9203
88b48903
WN
9204 fi
9205fi
9206:
9207 case $ac_cv_c_bigendian in #(
9208 yes)
9209 gl_cv_cc_double_expbit0="word 0 bit 20";; #(
9210 no)
9211 gl_cv_cc_double_expbit0="word 1 bit 20" ;; #(
9212 universal)
8690e634 9213
88b48903 9214$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
8690e634 9215
88b48903
WN
9216 ;; #(
9217 *)
9218 gl_cv_cc_double_expbit0="unknown" ;;
9219 esac
8690e634
JK
9220
9221
88b48903
WN
9222fi
9223rm -f conftest*
8690e634 9224
8690e634 9225
88b48903
WN
9226else
9227 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9228/* end confdefs.h. */
8690e634 9229
88b48903
WN
9230#include <float.h>
9231#include <stddef.h>
9232#include <stdio.h>
9233#include <string.h>
9234#define NWORDS \
9235 ((sizeof (double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
9236typedef union { double value; unsigned int word[NWORDS]; } memory_double;
9237static unsigned int ored_words[NWORDS];
9238static unsigned int anded_words[NWORDS];
9239static void add_to_ored_words (double x)
9240{
9241 memory_double m;
9242 size_t i;
9243 /* Clear it first, in case sizeof (double) < sizeof (memory_double). */
9244 memset (&m, 0, sizeof (memory_double));
9245 m.value = x;
9246 for (i = 0; i < NWORDS; i++)
9247 {
9248 ored_words[i] |= m.word[i];
9249 anded_words[i] &= m.word[i];
9250 }
9251}
9252int main ()
9253{
9254 size_t j;
9255 FILE *fp = fopen ("conftest.out", "w");
9256 if (fp == NULL)
9257 return 1;
9258 for (j = 0; j < NWORDS; j++)
9259 anded_words[j] = ~ (unsigned int) 0;
9260 add_to_ored_words (0.25);
9261 add_to_ored_words (0.5);
9262 add_to_ored_words (1.0);
9263 add_to_ored_words (2.0);
9264 add_to_ored_words (4.0);
9265 /* Remove bits that are common (e.g. if representation of the first mantissa
9266 bit is explicit). */
9267 for (j = 0; j < NWORDS; j++)
9268 ored_words[j] &= ~anded_words[j];
9269 /* Now find the nonzero word. */
9270 for (j = 0; j < NWORDS; j++)
9271 if (ored_words[j] != 0)
9272 break;
9273 if (j < NWORDS)
9274 {
9275 size_t i;
9276 for (i = j + 1; i < NWORDS; i++)
9277 if (ored_words[i] != 0)
9278 {
9279 fprintf (fp, "unknown");
9280 return (fclose (fp) != 0);
9281 }
9282 for (i = 0; ; i++)
9283 if ((ored_words[j] >> i) & 1)
9284 {
9285 fprintf (fp, "word %d bit %d", (int) j, (int) i);
9286 return (fclose (fp) != 0);
9287 }
9288 }
9289 fprintf (fp, "unknown");
9290 return (fclose (fp) != 0);
9291}
8690e634 9292
88b48903
WN
9293_ACEOF
9294if ac_fn_c_try_run "$LINENO"; then :
9295 gl_cv_cc_double_expbit0=`cat conftest.out`
9296else
9297 gl_cv_cc_double_expbit0="unknown"
9298fi
9299rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9300 conftest.$ac_objext conftest.beam conftest.$ac_ext
9301fi
8690e634 9302
88b48903 9303 rm -f conftest.out
8690e634 9304
88b48903
WN
9305fi
9306{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_double_expbit0" >&5
9307$as_echo "$gl_cv_cc_double_expbit0" >&6; }
9308 case "$gl_cv_cc_double_expbit0" in
9309 word*bit*)
9310 word=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
9311 bit=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word.*bit //'`
8690e634 9312
88b48903
WN
9313cat >>confdefs.h <<_ACEOF
9314#define DBL_EXPBIT0_WORD $word
9315_ACEOF
8690e634
JK
9316
9317
88b48903
WN
9318cat >>confdefs.h <<_ACEOF
9319#define DBL_EXPBIT0_BIT $bit
9320_ACEOF
8690e634 9321
88b48903
WN
9322 ;;
9323 esac
8690e634
JK
9324
9325
88b48903
WN
9326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
9327$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
9328if test "${ac_cv_c_bigendian+set}" = set; then :
8690e634
JK
9329 $as_echo_n "(cached) " >&6
9330else
88b48903
WN
9331 ac_cv_c_bigendian=unknown
9332 # See if we're dealing with a universal compiler.
9333 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9334/* end confdefs.h. */
9335#ifndef __APPLE_CC__
9336 not a universal capable compiler
9337 #endif
9338 typedef int dummy;
9339
9340_ACEOF
9341if ac_fn_c_try_compile "$LINENO"; then :
9342
9343 # Check for potential -arch flags. It is not universal unless
9344 # there are at least two -arch flags with different values.
9345 ac_arch=
9346 ac_prev=
9347 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
9348 if test -n "$ac_prev"; then
9349 case $ac_word in
9350 i?86 | x86_64 | ppc | ppc64)
9351 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
9352 ac_arch=$ac_word
9353 else
9354 ac_cv_c_bigendian=universal
9355 break
9356 fi
9357 ;;
9358 esac
9359 ac_prev=
9360 elif test "x$ac_word" = "x-arch"; then
9361 ac_prev=arch
9362 fi
9363 done
9364fi
9365rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9366 if test $ac_cv_c_bigendian = unknown; then
9367 # See if sys/param.h defines the BYTE_ORDER macro.
9368 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8690e634
JK
9369/* end confdefs.h. */
9370#include <sys/types.h>
88b48903
WN
9371 #include <sys/param.h>
9372
9373int
9374main ()
9375{
9376#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
9377 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
9378 && LITTLE_ENDIAN)
9379 bogus endian macros
9380 #endif
9381
9382 ;
9383 return 0;
9384}
9385_ACEOF
9386if ac_fn_c_try_compile "$LINENO"; then :
9387 # It does; now see whether it defined to BIG_ENDIAN or not.
9388 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9389/* end confdefs.h. */
9390#include <sys/types.h>
9391 #include <sys/param.h>
9392
9393int
9394main ()
9395{
9396#if BYTE_ORDER != BIG_ENDIAN
9397 not big endian
9398 #endif
9399
9400 ;
9401 return 0;
9402}
9403_ACEOF
9404if ac_fn_c_try_compile "$LINENO"; then :
9405 ac_cv_c_bigendian=yes
9406else
9407 ac_cv_c_bigendian=no
9408fi
9409rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9410fi
9411rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9412 fi
9413 if test $ac_cv_c_bigendian = unknown; then
9414 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
9415 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9416/* end confdefs.h. */
9417#include <limits.h>
9418
9419int
9420main ()
9421{
9422#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
9423 bogus endian macros
9424 #endif
9425
9426 ;
9427 return 0;
9428}
9429_ACEOF
9430if ac_fn_c_try_compile "$LINENO"; then :
9431 # It does; now see whether it defined to _BIG_ENDIAN or not.
9432 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9433/* end confdefs.h. */
9434#include <limits.h>
9435
9436int
9437main ()
9438{
9439#ifndef _BIG_ENDIAN
9440 not big endian
9441 #endif
9442
9443 ;
9444 return 0;
9445}
9446_ACEOF
9447if ac_fn_c_try_compile "$LINENO"; then :
9448 ac_cv_c_bigendian=yes
9449else
9450 ac_cv_c_bigendian=no
9451fi
9452rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9453fi
9454rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9455 fi
9456 if test $ac_cv_c_bigendian = unknown; then
9457 # Compile a test program.
9458 if test "$cross_compiling" = yes; then :
9459 # Try to guess by grepping values from an object file.
9460 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9461/* end confdefs.h. */
9462short int ascii_mm[] =
9463 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
9464 short int ascii_ii[] =
9465 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
9466 int use_ascii (int i) {
9467 return ascii_mm[i] + ascii_ii[i];
9468 }
9469 short int ebcdic_ii[] =
9470 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
9471 short int ebcdic_mm[] =
9472 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
9473 int use_ebcdic (int i) {
9474 return ebcdic_mm[i] + ebcdic_ii[i];
9475 }
9476 extern int foo;
9477
9478int
9479main ()
9480{
9481return use_ascii (foo) == use_ebcdic (foo);
9482 ;
9483 return 0;
9484}
9485_ACEOF
9486if ac_fn_c_try_compile "$LINENO"; then :
9487 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
9488 ac_cv_c_bigendian=yes
9489 fi
9490 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
9491 if test "$ac_cv_c_bigendian" = unknown; then
9492 ac_cv_c_bigendian=no
9493 else
9494 # finding both strings is unlikely to happen, but who knows?
9495 ac_cv_c_bigendian=unknown
9496 fi
9497 fi
9498fi
9499rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9500else
9501 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9502/* end confdefs.h. */
9503$ac_includes_default
9504int
9505main ()
9506{
9507
9508 /* Are we little or big endian? From Harbison&Steele. */
9509 union
9510 {
9511 long int l;
9512 char c[sizeof (long int)];
9513 } u;
9514 u.l = 1;
9515 return u.c[sizeof (long int) - 1] == 1;
9516
9517 ;
9518 return 0;
9519}
9520_ACEOF
9521if ac_fn_c_try_run "$LINENO"; then :
9522 ac_cv_c_bigendian=no
9523else
9524 ac_cv_c_bigendian=yes
9525fi
9526rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9527 conftest.$ac_objext conftest.beam conftest.$ac_ext
9528fi
9529
9530 fi
9531fi
9532{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
9533$as_echo "$ac_cv_c_bigendian" >&6; }
9534 case $ac_cv_c_bigendian in #(
9535 yes)
9536 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
9537;; #(
9538 no)
9539 ;; #(
9540 universal)
9541
9542$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
9543
9544 ;; #(
9545 *)
9546 as_fn_error "unknown endianness
9547 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
9548 esac
9549
9550
9551
2196f55f
YQ
9552
9553 case "$host_os" in
9554 mingw*)
9555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
9556$as_echo_n "checking for 64-bit off_t... " >&6; }
9557if test "${gl_cv_type_off_t_64+set}" = set; then :
9558 $as_echo_n "(cached) " >&6
9559else
9560 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9561/* end confdefs.h. */
9562#include <sys/types.h>
9563 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
9564
9565int
9566main ()
9567{
9568
9569 ;
9570 return 0;
9571}
9572_ACEOF
9573if ac_fn_c_try_compile "$LINENO"; then :
9574 gl_cv_type_off_t_64=yes
9575else
9576 gl_cv_type_off_t_64=no
9577fi
9578rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9579
9580fi
9581{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
9582$as_echo "$gl_cv_type_off_t_64" >&6; }
9583 if test $gl_cv_type_off_t_64 = no; then
9584 WINDOWS_64_BIT_OFF_T=1
9585 else
9586 WINDOWS_64_BIT_OFF_T=0
9587 fi
9588 WINDOWS_64_BIT_ST_SIZE=1
9589 ;;
9590 *)
9591 WINDOWS_64_BIT_OFF_T=0
9592 WINDOWS_64_BIT_ST_SIZE=0
9593 ;;
9594 esac
9595
9596
88b48903
WN
9597 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
9598$as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
9599if test "${am_cv_langinfo_codeset+set}" = set; then :
9600 $as_echo_n "(cached) " >&6
9601else
9602 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9603/* end confdefs.h. */
9604#include <langinfo.h>
9605int
9606main ()
9607{
9608char* cs = nl_langinfo(CODESET); return !cs;
9609 ;
9610 return 0;
9611}
9612_ACEOF
9613if ac_fn_c_try_link "$LINENO"; then :
9614 am_cv_langinfo_codeset=yes
9615else
9616 am_cv_langinfo_codeset=no
9617fi
9618rm -f core conftest.err conftest.$ac_objext \
9619 conftest$ac_exeext conftest.$ac_ext
9620
9621fi
9622{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
9623$as_echo "$am_cv_langinfo_codeset" >&6; }
9624 if test $am_cv_langinfo_codeset = yes; then
9625
9626$as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
9627
9628 fi
9629
9630
9631
9632
9633
9634
9635
9636
9637
9638
88b48903
WN
9639 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fcntl.h" >&5
9640$as_echo_n "checking for working fcntl.h... " >&6; }
9641if test "${gl_cv_header_working_fcntl_h+set}" = set; then :
9642 $as_echo_n "(cached) " >&6
9643else
9644 if test "$cross_compiling" = yes; then :
9645 gl_cv_header_working_fcntl_h=cross-compiling
9646else
9647 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9648/* end confdefs.h. */
9649#include <sys/types.h>
9650 #include <sys/stat.h>
9651 #if HAVE_UNISTD_H
9652 # include <unistd.h>
9653 #else /* on Windows with MSVC */
9654 # include <io.h>
9655 # include <stdlib.h>
8690e634
JK
9656 # defined sleep(n) _sleep ((n) * 1000)
9657 #endif
9658 #include <fcntl.h>
9659 #ifndef O_NOATIME
9660 #define O_NOATIME 0
9661 #endif
9662 #ifndef O_NOFOLLOW
9663 #define O_NOFOLLOW 0
9664 #endif
9665 static int const constants[] =
9666 {
9667 O_CREAT, O_EXCL, O_NOCTTY, O_TRUNC, O_APPEND,
9668 O_NONBLOCK, O_SYNC, O_ACCMODE, O_RDONLY, O_RDWR, O_WRONLY
9669 };
9670
9671int
9672main ()
9673{
9674
9675 int result = !constants;
9676 #if HAVE_SYMLINK
9677 {
9678 static char const sym[] = "conftest.sym";
a512b375
JB
9679 if (symlink ("/dev/null", sym) != 0)
9680 result |= 2;
9681 else
9682 {
9683 int fd = open (sym, O_WRONLY | O_NOFOLLOW | O_CREAT, 0);
9684 if (fd >= 0)
9685 {
9686 close (fd);
9687 result |= 4;
9688 }
9689 }
9690 if (unlink (sym) != 0 || symlink (".", sym) != 0)
8690e634
JK
9691 result |= 2;
9692 else
9693 {
9694 int fd = open (sym, O_RDONLY | O_NOFOLLOW);
9695 if (fd >= 0)
9696 {
9697 close (fd);
9698 result |= 4;
9699 }
9700 }
9701 unlink (sym);
9702 }
9703 #endif
9704 {
9705 static char const file[] = "confdefs.h";
9706 int fd = open (file, O_RDONLY | O_NOATIME);
9707 if (fd < 0)
9708 result |= 8;
9709 else
9710 {
9711 struct stat st0;
9712 if (fstat (fd, &st0) != 0)
9713 result |= 16;
9714 else
9715 {
9716 char c;
9717 sleep (1);
9718 if (read (fd, &c, 1) != 1)
9719 result |= 24;
9720 else
9721 {
9722 if (close (fd) != 0)
9723 result |= 32;
9724 else
9725 {
9726 struct stat st1;
9727 if (stat (file, &st1) != 0)
9728 result |= 40;
9729 else
9730 if (st0.st_atime != st1.st_atime)
9731 result |= 64;
9732 }
9733 }
9734 }
9735 }
9736 }
9737 return result;
9738 ;
9739 return 0;
9740}
9741_ACEOF
9742if ac_fn_c_try_run "$LINENO"; then :
9743 gl_cv_header_working_fcntl_h=yes
9744else
9745 case $? in #(
9746 4) gl_cv_header_working_fcntl_h='no (bad O_NOFOLLOW)';; #(
9747 64) gl_cv_header_working_fcntl_h='no (bad O_NOATIME)';; #(
9748 68) gl_cv_header_working_fcntl_h='no (bad O_NOATIME, O_NOFOLLOW)';; #(
9749 *) gl_cv_header_working_fcntl_h='no';;
9750 esac
9751fi
9752rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9753 conftest.$ac_objext conftest.beam conftest.$ac_ext
9754fi
9755
9756fi
9757{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_fcntl_h" >&5
9758$as_echo "$gl_cv_header_working_fcntl_h" >&6; }
9759
9760 case $gl_cv_header_working_fcntl_h in #(
9761 *O_NOATIME* | no | cross-compiling) ac_val=0;; #(
9762 *) ac_val=1;;
9763 esac
9764
9765cat >>confdefs.h <<_ACEOF
9766#define HAVE_WORKING_O_NOATIME $ac_val
9767_ACEOF
9768
9769
9770 case $gl_cv_header_working_fcntl_h in #(
9771 *O_NOFOLLOW* | no | cross-compiling) ac_val=0;; #(
9772 *) ac_val=1;;
9773 esac
9774
9775cat >>confdefs.h <<_ACEOF
9776#define HAVE_WORKING_O_NOFOLLOW $ac_val
9777_ACEOF
9778
9779
3574124b 9780ac_fn_c_check_decl "$LINENO" "getc_unlocked" "ac_cv_have_decl_getc_unlocked" "$ac_includes_default"
8690e634
JK
9781if test "x$ac_cv_have_decl_getc_unlocked" = x""yes; then :
9782 ac_have_decl=1
9783else
9784 ac_have_decl=0
9785fi
9786
9787cat >>confdefs.h <<_ACEOF
9788#define HAVE_DECL_GETC_UNLOCKED $ac_have_decl
9789_ACEOF
9790
9791
8690e634
JK
9792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C Library >= 2.1 or uClibc" >&5
9793$as_echo_n "checking whether we are using the GNU C Library >= 2.1 or uClibc... " >&6; }
9794if test "${ac_cv_gnu_library_2_1+set}" = set; then :
9795 $as_echo_n "(cached) " >&6
9796else
9797 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9798/* end confdefs.h. */
9799
9800#include <features.h>
9801#ifdef __GNU_LIBRARY__
9802 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)
9803 Lucky GNU user
9804 #endif
9805#endif
9806#ifdef __UCLIBC__
9807 Lucky user
9808#endif
9809
9810_ACEOF
9811if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9812 $EGREP "Lucky" >/dev/null 2>&1; then :
9813 ac_cv_gnu_library_2_1=yes
9814else
9815 ac_cv_gnu_library_2_1=no
9816fi
9817rm -f conftest*
9818
9819
9820
9821fi
9822{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gnu_library_2_1" >&5
9823$as_echo "$ac_cv_gnu_library_2_1" >&6; }
9824
9825 GLIBC21="$ac_cv_gnu_library_2_1"
9826
9827
9828
f45c62c4
YQ
9829 GNULIB_FCHMODAT=0;
9830 GNULIB_FSTAT=0;
9831 GNULIB_FSTATAT=0;
9832 GNULIB_FUTIMENS=0;
9833 GNULIB_LCHMOD=0;
9834 GNULIB_LSTAT=0;
9835 GNULIB_MKDIRAT=0;
9836 GNULIB_MKFIFO=0;
9837 GNULIB_MKFIFOAT=0;
9838 GNULIB_MKNOD=0;
9839 GNULIB_MKNODAT=0;
9840 GNULIB_STAT=0;
9841 GNULIB_UTIMENSAT=0;
9842 HAVE_FCHMODAT=1;
9843 HAVE_FSTATAT=1;
9844 HAVE_FUTIMENS=1;
9845 HAVE_LCHMOD=1;
9846 HAVE_LSTAT=1;
9847 HAVE_MKDIRAT=1;
9848 HAVE_MKFIFO=1;
9849 HAVE_MKFIFOAT=1;
9850 HAVE_MKNOD=1;
9851 HAVE_MKNODAT=1;
9852 HAVE_UTIMENSAT=1;
9853 REPLACE_FSTAT=0;
9854 REPLACE_FSTATAT=0;
9855 REPLACE_FUTIMENS=0;
9856 REPLACE_LSTAT=0;
9857 REPLACE_MKDIR=0;
9858 REPLACE_MKFIFO=0;
9859 REPLACE_MKNOD=0;
9860 REPLACE_STAT=0;
9861 REPLACE_UTIMENSAT=0;
9862
9863
9864
9865
9866 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
9867$as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
9868if test "${gl_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
9869 $as_echo_n "(cached) " >&6
9870else
9871 rm -f conftest.sym conftest.file
9872 echo >conftest.file
4a626d0a 9873 if test "$cross_compiling" = yes; then :
f45c62c4 9874 case "$host_os" in
4a626d0a
PA
9875 *-gnu*)
9876 # Guess yes on glibc systems.
9877 gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
9878 *)
9879 # If we don't know, assume the worst.
9880 gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
9881 esac
f45c62c4
YQ
9882
9883else
9884 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9885/* end confdefs.h. */
9886$ac_includes_default
9887int
9888main ()
9889{
9890struct stat sbuf;
4a626d0a
PA
9891 if (symlink ("conftest.file", "conftest.sym") != 0)
9892 return 1;
9893 /* Linux will dereference the symlink and fail, as required by
9894 POSIX. That is better in the sense that it means we will not
9895 have to compile and use the lstat wrapper. */
9896 return lstat ("conftest.sym/", &sbuf) == 0;
f45c62c4
YQ
9897
9898 ;
9899 return 0;
9900}
9901_ACEOF
9902if ac_fn_c_try_run "$LINENO"; then :
9903 gl_cv_func_lstat_dereferences_slashed_symlink=yes
9904else
9905 gl_cv_func_lstat_dereferences_slashed_symlink=no
9906fi
9907rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9908 conftest.$ac_objext conftest.beam conftest.$ac_ext
9909fi
9910
f45c62c4
YQ
9911 rm -f conftest.sym conftest.file
9912
9913fi
9914{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
9915$as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
9916 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
9917 *yes)
9918
9919cat >>confdefs.h <<_ACEOF
9920#define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
9921_ACEOF
9922
9923 ;;
9924 esac
9925
9926
6a29c58e
YQ
9927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc, realloc, calloc are POSIX compliant" >&5
9928$as_echo_n "checking whether malloc, realloc, calloc are POSIX compliant... " >&6; }
9929if test "${gl_cv_func_malloc_posix+set}" = set; then :
9930 $as_echo_n "(cached) " >&6
9931else
9932
9933 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9934/* end confdefs.h. */
9935
9936int
9937main ()
9938{
9939#if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
9940 choke me
9941 #endif
9942
9943 ;
9944 return 0;
9945}
9946_ACEOF
9947if ac_fn_c_try_compile "$LINENO"; then :
9948 gl_cv_func_malloc_posix=yes
9949else
9950 gl_cv_func_malloc_posix=no
9951fi
9952rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9953
9954fi
9955{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_malloc_posix" >&5
9956$as_echo "$gl_cv_func_malloc_posix" >&6; }
9957
9958
9959
9960 for ac_header in stdlib.h
98399780
YQ
9961do :
9962 ac_fn_c_check_header_mongrel "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default"
9963if test "x$ac_cv_header_stdlib_h" = x""yes; then :
9964 cat >>confdefs.h <<_ACEOF
9965#define HAVE_STDLIB_H 1
9966_ACEOF
9967
9968fi
9969
9970done
9971
6a29c58e 9972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5
98399780
YQ
9973$as_echo_n "checking for GNU libc compatible malloc... " >&6; }
9974if test "${ac_cv_func_malloc_0_nonnull+set}" = set; then :
9975 $as_echo_n "(cached) " >&6
9976else
9977 if test "$cross_compiling" = yes; then :
6a29c58e
YQ
9978 case "$host_os" in
9979 # Guess yes on platforms where we know the result.
9980 *-gnu* | freebsd* | netbsd* | openbsd* \
9981 | hpux* | solaris* | cygwin* | mingw*)
9982 ac_cv_func_malloc_0_nonnull=yes ;;
9983 # If we don't know, assume the worst.
9984 *) ac_cv_func_malloc_0_nonnull=no ;;
9985 esac
9986
98399780
YQ
9987else
9988 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9989/* end confdefs.h. */
9990#if defined STDC_HEADERS || defined HAVE_STDLIB_H
6a29c58e
YQ
9991 # include <stdlib.h>
9992 #else
9993 char *malloc ();
9994 #endif
98399780
YQ
9995
9996int
9997main ()
9998{
9999return ! malloc (0);
10000 ;
10001 return 0;
10002}
6a29c58e 10003
98399780
YQ
10004_ACEOF
10005if ac_fn_c_try_run "$LINENO"; then :
10006 ac_cv_func_malloc_0_nonnull=yes
10007else
10008 ac_cv_func_malloc_0_nonnull=no
10009fi
10010rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10011 conftest.$ac_objext conftest.beam conftest.$ac_ext
10012fi
10013
6a29c58e 10014
98399780
YQ
10015fi
10016{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_malloc_0_nonnull" >&5
10017$as_echo "$ac_cv_func_malloc_0_nonnull" >&6; }
6a29c58e 10018 if test $ac_cv_func_malloc_0_nonnull = yes; then :
98399780
YQ
10019 gl_cv_func_malloc_0_nonnull=1
10020else
10021 gl_cv_func_malloc_0_nonnull=0
10022fi
10023
10024
10025cat >>confdefs.h <<_ACEOF
10026#define MALLOC_0_IS_NONNULL $gl_cv_func_malloc_0_nonnull
10027_ACEOF
10028
10029
10030
88b48903
WN
10031
10032
8690e634
JK
10033 GNULIB_BTOWC=0;
10034 GNULIB_WCTOB=0;
10035 GNULIB_MBSINIT=0;
10036 GNULIB_MBRTOWC=0;
10037 GNULIB_MBRLEN=0;
10038 GNULIB_MBSRTOWCS=0;
10039 GNULIB_MBSNRTOWCS=0;
10040 GNULIB_WCRTOMB=0;
10041 GNULIB_WCSRTOMBS=0;
10042 GNULIB_WCSNRTOMBS=0;
10043 GNULIB_WCWIDTH=0;
10044 GNULIB_WMEMCHR=0;
10045 GNULIB_WMEMCMP=0;
10046 GNULIB_WMEMCPY=0;
10047 GNULIB_WMEMMOVE=0;
10048 GNULIB_WMEMSET=0;
10049 GNULIB_WCSLEN=0;
10050 GNULIB_WCSNLEN=0;
10051 GNULIB_WCSCPY=0;
10052 GNULIB_WCPCPY=0;
10053 GNULIB_WCSNCPY=0;
10054 GNULIB_WCPNCPY=0;
10055 GNULIB_WCSCAT=0;
10056 GNULIB_WCSNCAT=0;
10057 GNULIB_WCSCMP=0;
10058 GNULIB_WCSNCMP=0;
10059 GNULIB_WCSCASECMP=0;
10060 GNULIB_WCSNCASECMP=0;
10061 GNULIB_WCSCOLL=0;
10062 GNULIB_WCSXFRM=0;
10063 GNULIB_WCSDUP=0;
10064 GNULIB_WCSCHR=0;
10065 GNULIB_WCSRCHR=0;
10066 GNULIB_WCSCSPN=0;
10067 GNULIB_WCSSPN=0;
10068 GNULIB_WCSPBRK=0;
10069 GNULIB_WCSSTR=0;
10070 GNULIB_WCSTOK=0;
10071 GNULIB_WCSWIDTH=0;
10072 HAVE_BTOWC=1;
10073 HAVE_MBSINIT=1;
10074 HAVE_MBRTOWC=1;
10075 HAVE_MBRLEN=1;
10076 HAVE_MBSRTOWCS=1;
10077 HAVE_MBSNRTOWCS=1;
10078 HAVE_WCRTOMB=1;
10079 HAVE_WCSRTOMBS=1;
10080 HAVE_WCSNRTOMBS=1;
10081 HAVE_WMEMCHR=1;
10082 HAVE_WMEMCMP=1;
10083 HAVE_WMEMCPY=1;
10084 HAVE_WMEMMOVE=1;
10085 HAVE_WMEMSET=1;
10086 HAVE_WCSLEN=1;
10087 HAVE_WCSNLEN=1;
10088 HAVE_WCSCPY=1;
10089 HAVE_WCPCPY=1;
10090 HAVE_WCSNCPY=1;
10091 HAVE_WCPNCPY=1;
10092 HAVE_WCSCAT=1;
10093 HAVE_WCSNCAT=1;
10094 HAVE_WCSCMP=1;
10095 HAVE_WCSNCMP=1;
10096 HAVE_WCSCASECMP=1;
10097 HAVE_WCSNCASECMP=1;
10098 HAVE_WCSCOLL=1;
10099 HAVE_WCSXFRM=1;
10100 HAVE_WCSDUP=1;
10101 HAVE_WCSCHR=1;
10102 HAVE_WCSRCHR=1;
10103 HAVE_WCSCSPN=1;
10104 HAVE_WCSSPN=1;
10105 HAVE_WCSPBRK=1;
10106 HAVE_WCSSTR=1;
10107 HAVE_WCSTOK=1;
10108 HAVE_WCSWIDTH=1;
10109 HAVE_DECL_WCTOB=1;
10110 HAVE_DECL_WCWIDTH=1;
10111 REPLACE_MBSTATE_T=0;
10112 REPLACE_BTOWC=0;
10113 REPLACE_WCTOB=0;
10114 REPLACE_MBSINIT=0;
10115 REPLACE_MBRTOWC=0;
10116 REPLACE_MBRLEN=0;
10117 REPLACE_MBSRTOWCS=0;
10118 REPLACE_MBSNRTOWCS=0;
10119 REPLACE_WCRTOMB=0;
10120 REPLACE_WCSRTOMBS=0;
10121 REPLACE_WCSNRTOMBS=0;
10122 REPLACE_WCWIDTH=0;
10123 REPLACE_WCSWIDTH=0;
10124
10125
10126
10127
10128
10129
10130
10131
8690e634
JK
10132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional japanese locale" >&5
10133$as_echo_n "checking for a traditional japanese locale... " >&6; }
10134if test "${gt_cv_locale_ja+set}" = set; then :
10135 $as_echo_n "(cached) " >&6
10136else
10137
10138 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10139/* end confdefs.h. */
10140
10141#include <locale.h>
10142#include <time.h>
10143#if HAVE_LANGINFO_CODESET
10144# include <langinfo.h>
10145#endif
10146#include <stdlib.h>
10147#include <string.h>
10148struct tm t;
10149char buf[16];
10150int main ()
10151{
10152 const char *p;
10153 /* Check whether the given locale name is recognized by the system. */
10154#if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
10155 /* On native Windows, setlocale(category, "") looks at the system settings,
10156 not at the environment variables. Also, when an encoding suffix such
10157 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
10158 category of the locale to "C". */
10159 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
10160 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
10161 return 1;
10162#else
10163 if (setlocale (LC_ALL, "") == NULL) return 1;
10164#endif
10165 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
10166 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
10167 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
10168 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
10169 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
10170 some unit tests fail.
10171 On MirBSD 10, when an unsupported locale is specified, setlocale()
10172 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
10173#if HAVE_LANGINFO_CODESET
10174 {
10175 const char *cs = nl_langinfo (CODESET);
10176 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
10177 || strcmp (cs, "UTF-8") == 0)
10178 return 1;
10179 }
10180#endif
10181#ifdef __CYGWIN__
10182 /* On Cygwin, avoid locale names without encoding suffix, because the
10183 locale_charset() function relies on the encoding suffix. Note that
10184 LC_ALL is set on the command line. */
10185 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
10186#endif
10187 /* Check whether MB_CUR_MAX is > 1. This excludes the dysfunctional locales
10188 on Cygwin 1.5.x. */
10189 if (MB_CUR_MAX == 1)
10190 return 1;
10191 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
10192 This excludes the UTF-8 encoding (except on MirBSD). */
10193 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
10194 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
10195 for (p = buf; *p != '\0'; p++)
10196 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
10197 return 1;
10198 return 0;
10199}
10200
10201_ACEOF
10202 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
10203 (eval $ac_link) 2>&5
10204 ac_status=$?
10205 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
10206 test $ac_status = 0; } && test -s conftest$ac_exeext; then
10207 case "$host_os" in
10208 # Handle native Windows specially, because there setlocale() interprets
10209 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
10210 # "fr" or "fra" as "French" or "French_France.1252",
10211 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
10212 # "ja" as "Japanese" or "Japanese_Japan.932",
10213 # and similar.
10214 mingw*)
10215 # Note that on native Windows, the Japanese locale is
10216 # Japanese_Japan.932, and CP932 is very different from EUC-JP, so we
10217 # cannot use it here.
10218 gt_cv_locale_ja=none
10219 ;;
10220 *)
10221 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
10222 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
10223 # configure script would override the LC_ALL setting. Likewise for
10224 # LC_CTYPE, which is also set at the beginning of the configure script.
10225 # Test for the AIX locale name.
10226 if (LC_ALL=ja_JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10227 gt_cv_locale_ja=ja_JP
10228 else
10229 # Test for the locale name with explicit encoding suffix.
10230 if (LC_ALL=ja_JP.EUC-JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10231 gt_cv_locale_ja=ja_JP.EUC-JP
10232 else
10233 # Test for the HP-UX, OSF/1, NetBSD locale name.
10234 if (LC_ALL=ja_JP.eucJP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10235 gt_cv_locale_ja=ja_JP.eucJP
10236 else
10237 # Test for the IRIX, FreeBSD locale name.
10238 if (LC_ALL=ja_JP.EUC LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10239 gt_cv_locale_ja=ja_JP.EUC
10240 else
10241 # Test for the Solaris 7 locale name.
10242 if (LC_ALL=ja LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10243 gt_cv_locale_ja=ja
10244 else
10245 # Special test for NetBSD 1.6.
10246 if test -f /usr/share/locale/ja_JP.eucJP/LC_CTYPE; then
10247 gt_cv_locale_ja=ja_JP.eucJP
10248 else
10249 # None found.
10250 gt_cv_locale_ja=none
10251 fi
10252 fi
10253 fi
10254 fi
10255 fi
10256 fi
10257 ;;
10258 esac
10259 fi
10260 rm -fr conftest*
10261
10262fi
10263{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_ja" >&5
10264$as_echo "$gt_cv_locale_ja" >&6; }
10265 LOCALE_JA=$gt_cv_locale_ja
10266
10267
10268
10269
10270
10271 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a transitional chinese locale" >&5
10272$as_echo_n "checking for a transitional chinese locale... " >&6; }
10273if test "${gt_cv_locale_zh_CN+set}" = set; then :
10274 $as_echo_n "(cached) " >&6
10275else
10276
10277 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10278/* end confdefs.h. */
10279
10280#include <locale.h>
10281#include <stdlib.h>
10282#include <time.h>
10283#if HAVE_LANGINFO_CODESET
10284# include <langinfo.h>
10285#endif
10286#include <stdlib.h>
10287#include <string.h>
10288struct tm t;
10289char buf[16];
10290int main ()
10291{
10292 const char *p;
10293 /* Check whether the given locale name is recognized by the system. */
10294#if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
10295 /* On native Windows, setlocale(category, "") looks at the system settings,
10296 not at the environment variables. Also, when an encoding suffix such
10297 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
10298 category of the locale to "C". */
10299 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
10300 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
10301 return 1;
10302#else
10303 if (setlocale (LC_ALL, "") == NULL) return 1;
10304#endif
10305 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
10306 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
10307 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
10308 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
10309 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
10310 some unit tests fail.
10311 On MirBSD 10, when an unsupported locale is specified, setlocale()
10312 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
10313#if HAVE_LANGINFO_CODESET
10314 {
10315 const char *cs = nl_langinfo (CODESET);
10316 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
10317 || strcmp (cs, "UTF-8") == 0)
10318 return 1;
10319 }
10320#endif
10321#ifdef __CYGWIN__
10322 /* On Cygwin, avoid locale names without encoding suffix, because the
10323 locale_charset() function relies on the encoding suffix. Note that
10324 LC_ALL is set on the command line. */
10325 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
10326#endif
10327 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
10328 This excludes the UTF-8 encoding (except on MirBSD). */
10329 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
10330 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
10331 for (p = buf; *p != '\0'; p++)
10332 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
10333 return 1;
10334 /* Check whether a typical GB18030 multibyte sequence is recognized as a
10335 single wide character. This excludes the GB2312 and GBK encodings. */
10336 if (mblen ("\203\062\332\066", 5) != 4)
10337 return 1;
10338 return 0;
10339}
10340
10341_ACEOF
10342 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
10343 (eval $ac_link) 2>&5
10344 ac_status=$?
10345 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
10346 test $ac_status = 0; } && test -s conftest$ac_exeext; then
10347 case "$host_os" in
10348 # Handle native Windows specially, because there setlocale() interprets
10349 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
10350 # "fr" or "fra" as "French" or "French_France.1252",
10351 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
10352 # "ja" as "Japanese" or "Japanese_Japan.932",
10353 # and similar.
10354 mingw*)
10355 # Test for the hypothetical native Windows locale name.
10356 if (LC_ALL=Chinese_China.54936 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10357 gt_cv_locale_zh_CN=Chinese_China.54936
10358 else
10359 # None found.
10360 gt_cv_locale_zh_CN=none
10361 fi
10362 ;;
10363 solaris2.8)
10364 # On Solaris 8, the locales zh_CN.GB18030, zh_CN.GBK, zh.GBK are
10365 # broken. One witness is the test case in gl_MBRTOWC_SANITYCHECK.
10366 # Another witness is that "LC_ALL=zh_CN.GB18030 bash -c true" dumps core.
10367 gt_cv_locale_zh_CN=none
10368 ;;
10369 *)
10370 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
10371 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
10372 # configure script would override the LC_ALL setting. Likewise for
10373 # LC_CTYPE, which is also set at the beginning of the configure script.
10374 # Test for the locale name without encoding suffix.
10375 if (LC_ALL=zh_CN LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10376 gt_cv_locale_zh_CN=zh_CN
10377 else
10378 # Test for the locale name with explicit encoding suffix.
10379 if (LC_ALL=zh_CN.GB18030 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10380 gt_cv_locale_zh_CN=zh_CN.GB18030
10381 else
10382 # None found.
10383 gt_cv_locale_zh_CN=none
10384 fi
10385 fi
10386 ;;
10387 esac
10388 else
10389 # If there was a link error, due to mblen(), the system is so old that
10390 # it certainly doesn't have a chinese locale.
10391 gt_cv_locale_zh_CN=none
10392 fi
10393 rm -fr conftest*
10394
10395fi
10396{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_zh_CN" >&5
10397$as_echo "$gt_cv_locale_zh_CN" >&6; }
10398 LOCALE_ZH_CN=$gt_cv_locale_zh_CN
10399
10400
10401
10402
10403 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
10404$as_echo_n "checking for a french Unicode locale... " >&6; }
10405if test "${gt_cv_locale_fr_utf8+set}" = set; then :
10406 $as_echo_n "(cached) " >&6
10407else
10408
10409 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10410/* end confdefs.h. */
10411
10412#include <locale.h>
10413#include <time.h>
10414#if HAVE_LANGINFO_CODESET
10415# include <langinfo.h>
10416#endif
10417#include <stdlib.h>
10418#include <string.h>
10419struct tm t;
10420char buf[16];
10421int main () {
10422 /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
10423 imitates locale dependent behaviour by looking at the environment
10424 variables, and all locales use the UTF-8 encoding. */
10425#if !(defined __BEOS__ || defined __HAIKU__)
10426 /* Check whether the given locale name is recognized by the system. */
10427# if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
10428 /* On native Windows, setlocale(category, "") looks at the system settings,
10429 not at the environment variables. Also, when an encoding suffix such
10430 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
10431 category of the locale to "C". */
10432 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
10433 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
10434 return 1;
10435# else
10436 if (setlocale (LC_ALL, "") == NULL) return 1;
10437# endif
10438 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
10439 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
10440 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
10441 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
10442 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
10443 some unit tests fail. */
10444# if HAVE_LANGINFO_CODESET
10445 {
10446 const char *cs = nl_langinfo (CODESET);
10447 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
10448 return 1;
10449 }
10450# endif
10451# ifdef __CYGWIN__
10452 /* On Cygwin, avoid locale names without encoding suffix, because the
10453 locale_charset() function relies on the encoding suffix. Note that
10454 LC_ALL is set on the command line. */
10455 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
10456# endif
10457 /* Check whether in the abbreviation of the second month, the second
10458 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
10459 two bytes long, with UTF-8 encoding. */
10460 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
10461 if (strftime (buf, sizeof (buf), "%b", &t) < 4
10462 || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
10463 return 1;
10464#endif
10465#if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
10466 /* Check whether the decimal separator is a comma.
10467 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
10468 are nl_langinfo(RADIXCHAR) are both ".". */
10469 if (localeconv () ->decimal_point[0] != ',') return 1;
10470#endif
10471 return 0;
10472}
10473
10474_ACEOF
10475 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
10476 (eval $ac_link) 2>&5
10477 ac_status=$?
10478 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
10479 test $ac_status = 0; } && test -s conftest$ac_exeext; then
10480 case "$host_os" in
10481 # Handle native Windows specially, because there setlocale() interprets
10482 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
10483 # "fr" or "fra" as "French" or "French_France.1252",
10484 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
10485 # "ja" as "Japanese" or "Japanese_Japan.932",
10486 # and similar.
10487 mingw*)
10488 # Test for the hypothetical native Windows locale name.
10489 if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10490 gt_cv_locale_fr_utf8=French_France.65001
10491 else
10492 # None found.
10493 gt_cv_locale_fr_utf8=none
10494 fi
10495 ;;
10496 *)
10497 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
10498 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
10499 # configure script would override the LC_ALL setting. Likewise for
10500 # LC_CTYPE, which is also set at the beginning of the configure script.
10501 # Test for the usual locale name.
10502 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10503 gt_cv_locale_fr_utf8=fr_FR
10504 else
10505 # Test for the locale name with explicit encoding suffix.
10506 if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10507 gt_cv_locale_fr_utf8=fr_FR.UTF-8
10508 else
10509 # Test for the Solaris 7 locale name.
10510 if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10511 gt_cv_locale_fr_utf8=fr.UTF-8
10512 else
10513 # None found.
10514 gt_cv_locale_fr_utf8=none
10515 fi
10516 fi
10517 fi
10518 ;;
10519 esac
10520 fi
10521 rm -fr conftest*
10522
10523fi
10524{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
10525$as_echo "$gt_cv_locale_fr_utf8" >&6; }
10526 LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
10527
10528
10529
10530
10531
10532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
10533$as_echo_n "checking for a traditional french locale... " >&6; }
10534if test "${gt_cv_locale_fr+set}" = set; then :
10535 $as_echo_n "(cached) " >&6
10536else
10537
10538 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10539/* end confdefs.h. */
10540
10541#include <locale.h>
10542#include <time.h>
10543#if HAVE_LANGINFO_CODESET
10544# include <langinfo.h>
10545#endif
10546#include <stdlib.h>
10547#include <string.h>
10548struct tm t;
10549char buf[16];
10550int main () {
10551 /* Check whether the given locale name is recognized by the system. */
10552#if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
10553 /* On native Windows, setlocale(category, "") looks at the system settings,
10554 not at the environment variables. Also, when an encoding suffix such
10555 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
10556 category of the locale to "C". */
10557 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
10558 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
10559 return 1;
10560#else
10561 if (setlocale (LC_ALL, "") == NULL) return 1;
10562#endif
10563 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
10564 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
10565 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
10566 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
10567 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
10568 some unit tests fail.
10569 On MirBSD 10, when an unsupported locale is specified, setlocale()
10570 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
10571#if HAVE_LANGINFO_CODESET
10572 {
10573 const char *cs = nl_langinfo (CODESET);
10574 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
10575 || strcmp (cs, "UTF-8") == 0)
10576 return 1;
10577 }
10578#endif
10579#ifdef __CYGWIN__
10580 /* On Cygwin, avoid locale names without encoding suffix, because the
10581 locale_charset() function relies on the encoding suffix. Note that
10582 LC_ALL is set on the command line. */
10583 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
10584#endif
10585 /* Check whether in the abbreviation of the second month, the second
10586 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
10587 one byte long. This excludes the UTF-8 encoding. */
10588 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
10589 if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
10590#if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
10591 /* Check whether the decimal separator is a comma.
10592 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
10593 are nl_langinfo(RADIXCHAR) are both ".". */
10594 if (localeconv () ->decimal_point[0] != ',') return 1;
10595#endif
10596 return 0;
10597}
10598
10599_ACEOF
10600 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
10601 (eval $ac_link) 2>&5
10602 ac_status=$?
10603 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
10604 test $ac_status = 0; } && test -s conftest$ac_exeext; then
10605 case "$host_os" in
10606 # Handle native Windows specially, because there setlocale() interprets
10607 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
10608 # "fr" or "fra" as "French" or "French_France.1252",
10609 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
10610 # "ja" as "Japanese" or "Japanese_Japan.932",
10611 # and similar.
10612 mingw*)
10613 # Test for the native Windows locale name.
10614 if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10615 gt_cv_locale_fr=French_France.1252
10616 else
10617 # None found.
10618 gt_cv_locale_fr=none
10619 fi
10620 ;;
10621 *)
10622 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
10623 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
10624 # configure script would override the LC_ALL setting. Likewise for
10625 # LC_CTYPE, which is also set at the beginning of the configure script.
10626 # Test for the usual locale name.
10627 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10628 gt_cv_locale_fr=fr_FR
10629 else
10630 # Test for the locale name with explicit encoding suffix.
10631 if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10632 gt_cv_locale_fr=fr_FR.ISO-8859-1
10633 else
10634 # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
10635 if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10636 gt_cv_locale_fr=fr_FR.ISO8859-1
10637 else
10638 # Test for the HP-UX locale name.
10639 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10640 gt_cv_locale_fr=fr_FR.iso88591
10641 else
10642 # Test for the Solaris 7 locale name.
10643 if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
10644 gt_cv_locale_fr=fr
10645 else
10646 # None found.
10647 gt_cv_locale_fr=none
10648 fi
10649 fi
10650 fi
10651 fi
10652 fi
10653 ;;
10654 esac
10655 fi
10656 rm -fr conftest*
10657
10658fi
10659{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
10660$as_echo "$gt_cv_locale_fr" >&6; }
10661 LOCALE_FR=$gt_cv_locale_fr
10662
10663
10664
10665
10666
10667
10668
8690e634
JK
10669 GNULIB_FFSL=0;
10670 GNULIB_FFSLL=0;
10671 GNULIB_MEMCHR=0;
10672 GNULIB_MEMMEM=0;
10673 GNULIB_MEMPCPY=0;
10674 GNULIB_MEMRCHR=0;
10675 GNULIB_RAWMEMCHR=0;
10676 GNULIB_STPCPY=0;
10677 GNULIB_STPNCPY=0;
10678 GNULIB_STRCHRNUL=0;
10679 GNULIB_STRDUP=0;
10680 GNULIB_STRNCAT=0;
10681 GNULIB_STRNDUP=0;
10682 GNULIB_STRNLEN=0;
10683 GNULIB_STRPBRK=0;
10684 GNULIB_STRSEP=0;
10685 GNULIB_STRSTR=0;
10686 GNULIB_STRCASESTR=0;
10687 GNULIB_STRTOK_R=0;
10688 GNULIB_MBSLEN=0;
10689 GNULIB_MBSNLEN=0;
10690 GNULIB_MBSCHR=0;
10691 GNULIB_MBSRCHR=0;
10692 GNULIB_MBSSTR=0;
10693 GNULIB_MBSCASECMP=0;
10694 GNULIB_MBSNCASECMP=0;
10695 GNULIB_MBSPCASECMP=0;
10696 GNULIB_MBSCASESTR=0;
10697 GNULIB_MBSCSPN=0;
10698 GNULIB_MBSPBRK=0;
10699 GNULIB_MBSSPN=0;
10700 GNULIB_MBSSEP=0;
10701 GNULIB_MBSTOK_R=0;
10702 GNULIB_STRERROR=0;
10703 GNULIB_STRERROR_R=0;
10704 GNULIB_STRSIGNAL=0;
10705 GNULIB_STRVERSCMP=0;
10706 HAVE_MBSLEN=0;
10707 HAVE_FFSL=1;
10708 HAVE_FFSLL=1;
10709 HAVE_MEMCHR=1;
10710 HAVE_DECL_MEMMEM=1;
10711 HAVE_MEMPCPY=1;
10712 HAVE_DECL_MEMRCHR=1;
10713 HAVE_RAWMEMCHR=1;
10714 HAVE_STPCPY=1;
10715 HAVE_STPNCPY=1;
10716 HAVE_STRCHRNUL=1;
10717 HAVE_DECL_STRDUP=1;
10718 HAVE_DECL_STRNDUP=1;
10719 HAVE_DECL_STRNLEN=1;
10720 HAVE_STRPBRK=1;
10721 HAVE_STRSEP=1;
10722 HAVE_STRCASESTR=1;
10723 HAVE_DECL_STRTOK_R=1;
10724 HAVE_DECL_STRERROR_R=1;
10725 HAVE_DECL_STRSIGNAL=1;
10726 HAVE_STRVERSCMP=1;
10727 REPLACE_MEMCHR=0;
10728 REPLACE_MEMMEM=0;
10729 REPLACE_STPNCPY=0;
10730 REPLACE_STRDUP=0;
10731 REPLACE_STRSTR=0;
10732 REPLACE_STRCASESTR=0;
10733 REPLACE_STRCHRNUL=0;
10734 REPLACE_STRERROR=0;
10735 REPLACE_STRERROR_R=0;
10736 REPLACE_STRNCAT=0;
10737 REPLACE_STRNDUP=0;
10738 REPLACE_STRNLEN=0;
10739 REPLACE_STRSIGNAL=0;
10740 REPLACE_STRTOK_R=0;
10741 UNDEFINE_STRTOK_R=0;
10742
10743
10744
10745
10746
10747 # Check for mmap(). Don't use AC_FUNC_MMAP, because it checks too much: it
10748 # fails on HP-UX 11, because MAP_FIXED mappings do not work. But this is
10749 # irrelevant for anonymous mappings.
10750 ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap"
10751if test "x$ac_cv_func_mmap" = x""yes; then :
10752 gl_have_mmap=yes
10753else
10754 gl_have_mmap=no
10755fi
10756
10757
10758 # Try to allow MAP_ANONYMOUS.
10759 gl_have_mmap_anonymous=no
10760 if test $gl_have_mmap = yes; then
10761 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAP_ANONYMOUS" >&5
10762$as_echo_n "checking for MAP_ANONYMOUS... " >&6; }
10763 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10764/* end confdefs.h. */
10765
10766#include <sys/mman.h>
10767#ifdef MAP_ANONYMOUS
10768 I cannot identify this map
10769#endif
10770
10771_ACEOF
10772if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10773 $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
10774 gl_have_mmap_anonymous=yes
10775fi
10776rm -f conftest*
10777
10778 if test $gl_have_mmap_anonymous != yes; then
10779 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10780/* end confdefs.h. */
10781
10782#include <sys/mman.h>
10783#ifdef MAP_ANON
10784 I cannot identify this map
10785#endif
10786
10787_ACEOF
10788if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10789 $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
10790
10791$as_echo "#define MAP_ANONYMOUS MAP_ANON" >>confdefs.h
10792
10793 gl_have_mmap_anonymous=yes
10794fi
10795rm -f conftest*
10796
10797 fi
10798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_have_mmap_anonymous" >&5
10799$as_echo "$gl_have_mmap_anonymous" >&6; }
10800 if test $gl_have_mmap_anonymous = yes; then
10801
10802$as_echo "#define HAVE_MAP_ANONYMOUS 1" >>confdefs.h
10803
10804 fi
10805 fi
10806
10807
8690e634
JK
10808
10809
10810
10811
10812 if test $HAVE_MEMCHR = 1; then
10813 # Detect platform-specific bugs in some versions of glibc:
10814 # memchr should not dereference anything with length 0
10815 # http://bugzilla.redhat.com/499689
10816 # memchr should not dereference overestimated length after a match
10817 # http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=521737
10818 # http://sourceware.org/bugzilla/show_bug.cgi?id=10162
10819 # Assume that memchr works on platforms that lack mprotect.
10820 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memchr works" >&5
10821$as_echo_n "checking whether memchr works... " >&6; }
10822if test "${gl_cv_func_memchr_works+set}" = set; then :
10823 $as_echo_n "(cached) " >&6
10824else
10825 if test "$cross_compiling" = yes; then :
10826 gl_cv_func_memchr_works="guessing no"
10827else
10828 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10829/* end confdefs.h. */
10830
10831#include <string.h>
10832#if HAVE_SYS_MMAN_H
10833# include <fcntl.h>
10834# include <unistd.h>
10835# include <sys/types.h>
10836# include <sys/mman.h>
10837# ifndef MAP_FILE
10838# define MAP_FILE 0
10839# endif
10840#endif
10841
10842int
10843main ()
10844{
10845
10846 int result = 0;
10847 char *fence = NULL;
10848#if HAVE_SYS_MMAN_H && HAVE_MPROTECT
10849# if HAVE_MAP_ANONYMOUS
10850 const int flags = MAP_ANONYMOUS | MAP_PRIVATE;
10851 const int fd = -1;
10852# else /* !HAVE_MAP_ANONYMOUS */
10853 const int flags = MAP_FILE | MAP_PRIVATE;
10854 int fd = open ("/dev/zero", O_RDONLY, 0666);
10855 if (fd >= 0)
10856# endif
10857 {
10858 int pagesize = getpagesize ();
10859 char *two_pages =
10860 (char *) mmap (NULL, 2 * pagesize, PROT_READ | PROT_WRITE,
10861 flags, fd, 0);
10862 if (two_pages != (char *)(-1)
10863 && mprotect (two_pages + pagesize, pagesize, PROT_NONE) == 0)
10864 fence = two_pages + pagesize;
10865 }
10866#endif
10867 if (fence)
10868 {
10869 if (memchr (fence, 0, 0))
10870 result |= 1;
10871 strcpy (fence - 9, "12345678");
10872 if (memchr (fence - 9, 0, 79) != fence - 1)
10873 result |= 2;
10874 if (memchr (fence - 1, 0, 3) != fence - 1)
10875 result |= 4;
10876 }
10877 return result;
10878
10879 ;
10880 return 0;
10881}
10882_ACEOF
10883if ac_fn_c_try_run "$LINENO"; then :
10884 gl_cv_func_memchr_works=yes
10885else
10886 gl_cv_func_memchr_works=no
10887fi
10888rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10889 conftest.$ac_objext conftest.beam conftest.$ac_ext
10890fi
10891
10892fi
10893{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memchr_works" >&5
10894$as_echo "$gl_cv_func_memchr_works" >&6; }
10895 if test "$gl_cv_func_memchr_works" != yes; then
10896 REPLACE_MEMCHR=1
10897 fi
10898 fi
10899
3574124b 10900ac_fn_c_check_decl "$LINENO" "memmem" "ac_cv_have_decl_memmem" "$ac_includes_default"
8690e634
JK
10901if test "x$ac_cv_have_decl_memmem" = x""yes; then :
10902 ac_have_decl=1
10903else
10904 ac_have_decl=0
10905fi
10906
10907cat >>confdefs.h <<_ACEOF
10908#define HAVE_DECL_MEMMEM $ac_have_decl
10909_ACEOF
10910
10911
10912
10913
10914
8690e634
JK
10915 for ac_func in memmem
10916do :
10917 ac_fn_c_check_func "$LINENO" "memmem" "ac_cv_func_memmem"
10918if test "x$ac_cv_func_memmem" = x""yes; then :
10919 cat >>confdefs.h <<_ACEOF
10920#define HAVE_MEMMEM 1
10921_ACEOF
10922
10923fi
10924done
10925
10926 if test $ac_cv_func_memmem = yes; then
10927 HAVE_MEMMEM=1
10928 else
10929 HAVE_MEMMEM=0
10930 fi
10931
8690e634
JK
10932 if test $ac_cv_have_decl_memmem = no; then
10933 HAVE_DECL_MEMMEM=0
10934 else
10935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memmem works" >&5
10936$as_echo_n "checking whether memmem works... " >&6; }
10937if test "${gl_cv_func_memmem_works_always+set}" = set; then :
10938 $as_echo_n "(cached) " >&6
10939else
10940 if test "$cross_compiling" = yes; then :
10941 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10942/* end confdefs.h. */
10943
10944#ifdef __GNU_LIBRARY__
10945 #include <features.h>
10946 #if ((__GLIBC__ == 2 && ((__GLIBC_MINOR > 0 && __GLIBC_MINOR__ < 9) \
10947 || __GLIBC_MINOR__ > 12)) \
10948 || (__GLIBC__ > 2)) \
10949 || defined __UCLIBC__
10950 Lucky user
10951 #endif
10952#elif defined __CYGWIN__
10953 #include <cygwin/version.h>
10954 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
10955 Lucky user
10956 #endif
10957#else
10958 Lucky user
10959#endif
10960
10961_ACEOF
10962if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10963 $EGREP "Lucky user" >/dev/null 2>&1; then :
10964 gl_cv_func_memmem_works_always="guessing yes"
10965else
10966 gl_cv_func_memmem_works_always="guessing no"
10967fi
10968rm -f conftest*
10969
10970
10971else
10972 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10973/* end confdefs.h. */
10974
10975#include <string.h> /* for memmem */
10976#define P "_EF_BF_BD"
10977#define HAYSTACK "F_BD_CE_BD" P P P P "_C3_88_20" P P P "_C3_A7_20" P
10978#define NEEDLE P P P P P
10979
10980int
10981main ()
10982{
10983
10984 int result = 0;
10985 if (memmem (HAYSTACK, strlen (HAYSTACK), NEEDLE, strlen (NEEDLE)))
10986 result |= 1;
10987 /* Check for empty needle behavior. */
10988 {
10989 const char *haystack = "AAA";
10990 if (memmem (haystack, 3, NULL, 0) != haystack)
10991 result |= 2;
10992 }
10993 return result;
10994
10995 ;
10996 return 0;
10997}
10998_ACEOF
10999if ac_fn_c_try_run "$LINENO"; then :
11000 gl_cv_func_memmem_works_always=yes
11001else
11002 gl_cv_func_memmem_works_always=no
11003fi
11004rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11005 conftest.$ac_objext conftest.beam conftest.$ac_ext
11006fi
11007
11008
11009fi
11010{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memmem_works_always" >&5
11011$as_echo "$gl_cv_func_memmem_works_always" >&6; }
11012 case "$gl_cv_func_memmem_works_always" in
11013 *yes) ;;
11014 *)
11015 REPLACE_MEMMEM=1
11016 ;;
11017 esac
11018 fi
11019 :
11020
6a29c58e
YQ
11021
11022 GNULIB_DPRINTF=0;
11023 GNULIB_FCLOSE=0;
11024 GNULIB_FDOPEN=0;
11025 GNULIB_FFLUSH=0;
11026 GNULIB_FGETC=0;
11027 GNULIB_FGETS=0;
11028 GNULIB_FOPEN=0;
11029 GNULIB_FPRINTF=0;
11030 GNULIB_FPRINTF_POSIX=0;
11031 GNULIB_FPURGE=0;
11032 GNULIB_FPUTC=0;
11033 GNULIB_FPUTS=0;
11034 GNULIB_FREAD=0;
11035 GNULIB_FREOPEN=0;
11036 GNULIB_FSCANF=0;
11037 GNULIB_FSEEK=0;
11038 GNULIB_FSEEKO=0;
11039 GNULIB_FTELL=0;
11040 GNULIB_FTELLO=0;
11041 GNULIB_FWRITE=0;
11042 GNULIB_GETC=0;
11043 GNULIB_GETCHAR=0;
11044 GNULIB_GETDELIM=0;
11045 GNULIB_GETLINE=0;
11046 GNULIB_OBSTACK_PRINTF=0;
11047 GNULIB_OBSTACK_PRINTF_POSIX=0;
11048 GNULIB_PCLOSE=0;
11049 GNULIB_PERROR=0;
11050 GNULIB_POPEN=0;
11051 GNULIB_PRINTF=0;
11052 GNULIB_PRINTF_POSIX=0;
11053 GNULIB_PUTC=0;
11054 GNULIB_PUTCHAR=0;
11055 GNULIB_PUTS=0;
11056 GNULIB_REMOVE=0;
11057 GNULIB_RENAME=0;
11058 GNULIB_RENAMEAT=0;
11059 GNULIB_SCANF=0;
11060 GNULIB_SNPRINTF=0;
11061 GNULIB_SPRINTF_POSIX=0;
11062 GNULIB_STDIO_H_NONBLOCKING=0;
11063 GNULIB_STDIO_H_SIGPIPE=0;
11064 GNULIB_TMPFILE=0;
11065 GNULIB_VASPRINTF=0;
11066 GNULIB_VFSCANF=0;
11067 GNULIB_VSCANF=0;
11068 GNULIB_VDPRINTF=0;
11069 GNULIB_VFPRINTF=0;
11070 GNULIB_VFPRINTF_POSIX=0;
11071 GNULIB_VPRINTF=0;
11072 GNULIB_VPRINTF_POSIX=0;
11073 GNULIB_VSNPRINTF=0;
11074 GNULIB_VSPRINTF_POSIX=0;
11075 HAVE_DECL_FPURGE=1;
11076 HAVE_DECL_FSEEKO=1;
11077 HAVE_DECL_FTELLO=1;
11078 HAVE_DECL_GETDELIM=1;
11079 HAVE_DECL_GETLINE=1;
11080 HAVE_DECL_OBSTACK_PRINTF=1;
11081 HAVE_DECL_SNPRINTF=1;
11082 HAVE_DECL_VSNPRINTF=1;
11083 HAVE_DPRINTF=1;
11084 HAVE_FSEEKO=1;
11085 HAVE_FTELLO=1;
11086 HAVE_PCLOSE=1;
11087 HAVE_POPEN=1;
11088 HAVE_RENAMEAT=1;
11089 HAVE_VASPRINTF=1;
11090 HAVE_VDPRINTF=1;
11091 REPLACE_DPRINTF=0;
11092 REPLACE_FCLOSE=0;
11093 REPLACE_FDOPEN=0;
11094 REPLACE_FFLUSH=0;
11095 REPLACE_FOPEN=0;
11096 REPLACE_FPRINTF=0;
11097 REPLACE_FPURGE=0;
11098 REPLACE_FREOPEN=0;
11099 REPLACE_FSEEK=0;
11100 REPLACE_FSEEKO=0;
11101 REPLACE_FTELL=0;
11102 REPLACE_FTELLO=0;
11103 REPLACE_GETDELIM=0;
11104 REPLACE_GETLINE=0;
11105 REPLACE_OBSTACK_PRINTF=0;
11106 REPLACE_PERROR=0;
11107 REPLACE_POPEN=0;
11108 REPLACE_PRINTF=0;
11109 REPLACE_REMOVE=0;
11110 REPLACE_RENAME=0;
11111 REPLACE_RENAMEAT=0;
11112 REPLACE_SNPRINTF=0;
11113 REPLACE_SPRINTF=0;
11114 REPLACE_STDIO_READ_FUNCS=0;
11115 REPLACE_STDIO_WRITE_FUNCS=0;
11116 REPLACE_TMPFILE=0;
11117 REPLACE_VASPRINTF=0;
11118 REPLACE_VDPRINTF=0;
11119 REPLACE_VFPRINTF=0;
11120 REPLACE_VPRINTF=0;
11121 REPLACE_VSNPRINTF=0;
11122 REPLACE_VSPRINTF=0;
11123
11124
11125
0750520d
PA
11126
11127 GNULIB_PTHREAD_SIGMASK=0;
11128 GNULIB_RAISE=0;
11129 GNULIB_SIGNAL_H_SIGPIPE=0;
11130 GNULIB_SIGPROCMASK=0;
11131 GNULIB_SIGACTION=0;
11132 HAVE_POSIX_SIGNALBLOCKING=1;
11133 HAVE_PTHREAD_SIGMASK=1;
11134 HAVE_RAISE=1;
11135 HAVE_SIGSET_T=1;
11136 HAVE_SIGINFO_T=1;
11137 HAVE_SIGACTION=1;
11138 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
11139
11140 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
11141
11142 HAVE_SIGHANDLER_T=1;
11143 REPLACE_PTHREAD_SIGMASK=0;
11144 REPLACE_RAISE=0;
11145
11146
11147 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
11148 #include <signal.h>
11149 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
11150 #include <sys/types.h>
11151
11152"
11153if test "x$ac_cv_type_sigset_t" = x""yes; then :
11154
11155cat >>confdefs.h <<_ACEOF
11156#define HAVE_SIGSET_T 1
11157_ACEOF
11158
11159gl_cv_type_sigset_t=yes
11160else
11161 gl_cv_type_sigset_t=no
11162fi
11163
11164 if test $gl_cv_type_sigset_t != yes; then
11165 HAVE_SIGSET_T=0
11166 fi
11167
11168ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
11169if test "x$ac_cv_type_pid_t" = x""yes; then :
11170
11171else
11172
11173cat >>confdefs.h <<_ACEOF
11174#define pid_t int
11175_ACEOF
11176
11177fi
11178
11179{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
11180$as_echo_n "checking for uid_t in sys/types.h... " >&6; }
11181if test "${ac_cv_type_uid_t+set}" = set; then :
11182 $as_echo_n "(cached) " >&6
11183else
11184 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11185/* end confdefs.h. */
11186#include <sys/types.h>
11187
11188_ACEOF
11189if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11190 $EGREP "uid_t" >/dev/null 2>&1; then :
11191 ac_cv_type_uid_t=yes
11192else
11193 ac_cv_type_uid_t=no
11194fi
11195rm -f conftest*
11196
11197fi
11198{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
11199$as_echo "$ac_cv_type_uid_t" >&6; }
11200if test $ac_cv_type_uid_t = no; then
11201
11202$as_echo "#define uid_t int" >>confdefs.h
11203
11204
11205$as_echo "#define gid_t int" >>confdefs.h
11206
11207fi
11208
8690e634
JK
11209{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
11210$as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
11211if test "${ac_cv_header_stdbool_h+set}" = set; then :
11212 $as_echo_n "(cached) " >&6
11213else
11214 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11215/* end confdefs.h. */
11216
11217 #include <stdbool.h>
11218 #ifndef bool
11219 "error: bool is not defined"
11220 #endif
11221 #ifndef false
11222 "error: false is not defined"
11223 #endif
11224 #if false
11225 "error: false is not 0"
11226 #endif
11227 #ifndef true
11228 "error: true is not defined"
11229 #endif
11230 #if true != 1
11231 "error: true is not 1"
11232 #endif
11233 #ifndef __bool_true_false_are_defined
11234 "error: __bool_true_false_are_defined is not defined"
11235 #endif
11236
11237 struct s { _Bool s: 1; _Bool t; } s;
11238
11239 char a[true == 1 ? 1 : -1];
11240 char b[false == 0 ? 1 : -1];
11241 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
11242 char d[(bool) 0.5 == true ? 1 : -1];
11243 /* See body of main program for 'e'. */
11244 char f[(_Bool) 0.0 == false ? 1 : -1];
11245 char g[true];
11246 char h[sizeof (_Bool)];
11247 char i[sizeof s.t];
11248 enum { j = false, k = true, l = false * true, m = true * 256 };
11249 /* The following fails for
11250 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
11251 _Bool n[m];
11252 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
11253 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
11254 /* Catch a bug in an HP-UX C compiler. See
11255 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
11256 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
11257 */
11258 _Bool q = true;
11259 _Bool *pq = &q;
11260
11261int
11262main ()
11263{
11264
11265 bool e = &s;
11266 *pq |= q;
11267 *pq |= ! q;
11268 /* Refer to every declared value, to avoid compiler optimizations. */
11269 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
11270 + !m + !n + !o + !p + !q + !pq);
11271
11272 ;
11273 return 0;
11274}
11275_ACEOF
11276if ac_fn_c_try_compile "$LINENO"; then :
11277 ac_cv_header_stdbool_h=yes
11278else
11279 ac_cv_header_stdbool_h=no
11280fi
11281rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11282fi
11283{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
11284$as_echo "$ac_cv_header_stdbool_h" >&6; }
11285 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
11286if test "x$ac_cv_type__Bool" = x""yes; then :
11287
11288cat >>confdefs.h <<_ACEOF
11289#define HAVE__BOOL 1
11290_ACEOF
11291
11292
11293fi
11294
11295
11296
11297 REPLACE_NULL=0;
4a626d0a 11298 HAVE_MAX_ALIGN_T=1;
8690e634
JK
11299 HAVE_WCHAR_T=1;
11300
11301
11302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
11303$as_echo_n "checking for wchar_t... " >&6; }
11304if test "${gt_cv_c_wchar_t+set}" = set; then :
11305 $as_echo_n "(cached) " >&6
11306else
11307 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11308/* end confdefs.h. */
11309#include <stddef.h>
11310 wchar_t foo = (wchar_t)'\0';
11311int
11312main ()
11313{
11314
11315 ;
11316 return 0;
11317}
11318_ACEOF
11319if ac_fn_c_try_compile "$LINENO"; then :
11320 gt_cv_c_wchar_t=yes
11321else
11322 gt_cv_c_wchar_t=no
11323fi
11324rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11325fi
11326{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
11327$as_echo "$gt_cv_c_wchar_t" >&6; }
11328 if test $gt_cv_c_wchar_t = yes; then
11329
11330$as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
11331
11332 fi
11333
63ce7108
TT
11334
11335
11336
11337
8690e634
JK
11338
11339
11340
11341
11342
11343
11344
11345 if test $gl_cv_have_include_next = yes; then
11346 gl_cv_next_string_h='<'string.h'>'
11347 else
11348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <string.h>" >&5
11349$as_echo_n "checking absolute name of <string.h>... " >&6; }
11350if test "${gl_cv_next_string_h+set}" = set; then :
11351 $as_echo_n "(cached) " >&6
11352else
11353
4a626d0a
PA
11354
11355
11356 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8690e634
JK
11357/* end confdefs.h. */
11358#include <string.h>
8690e634 11359_ACEOF
4a626d0a
PA
11360 case "$host_os" in
11361 aix*) gl_absname_cpp="$ac_cpp -C" ;;
11362 *) gl_absname_cpp="$ac_cpp" ;;
11363 esac
11364
11365 case "$host_os" in
11366 mingw*)
11367 gl_dirsep_regex='[/\\]'
11368 ;;
11369 *)
11370 gl_dirsep_regex='\/'
11371 ;;
11372 esac
11373 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
11374 gl_header_literal_regex=`echo 'string.h' \
11375 | sed -e "$gl_make_literal_regex_sed"`
11376 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
11377 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
11378 s|^/[^/]|//&|
11379 p
11380 q
11381 }'
8690e634 11382
4a626d0a
PA
11383 gl_cv_absolute_string_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
11384 sed -n "$gl_absolute_header_sed"`
c971b7fa 11385
4a626d0a
PA
11386 gl_header=$gl_cv_absolute_string_h
11387 gl_cv_next_string_h='"'$gl_header'"'
8690e634
JK
11388
11389
11390fi
11391{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_string_h" >&5
11392$as_echo "$gl_cv_next_string_h" >&6; }
11393 fi
11394 NEXT_STRING_H=$gl_cv_next_string_h
11395
11396 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
11397 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
11398 gl_next_as_first_directive='<'string.h'>'
11399 else
11400 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
11401 gl_next_as_first_directive=$gl_cv_next_string_h
11402 fi
11403 NEXT_AS_FIRST_DIRECTIVE_STRING_H=$gl_next_as_first_directive
11404
11405
11406
11407
11408
11409
11410 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
11411 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
11412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
11413$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
11414if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
11415 $as_echo_n "(cached) " >&6
11416else
11417 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11418/* end confdefs.h. */
11419#include <string.h>
11420
11421int
11422main ()
11423{
11424#undef $gl_func
11425 (void) $gl_func;
11426 ;
11427 return 0;
11428}
11429_ACEOF
11430if ac_fn_c_try_compile "$LINENO"; then :
11431 eval "$as_gl_Symbol=yes"
11432else
11433 eval "$as_gl_Symbol=no"
11434fi
11435rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11436fi
11437eval ac_res=\$$as_gl_Symbol
11438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
11439$as_echo "$ac_res" >&6; }
11440 eval as_val=\$$as_gl_Symbol
11441 if test "x$as_val" = x""yes; then :
11442 cat >>confdefs.h <<_ACEOF
11443#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
11444_ACEOF
11445
11446 eval ac_cv_have_decl_$gl_func=yes
11447fi
11448 done
11449
11450
11451
8839a007 11452
63ce7108
TT
11453
11454 if test "$gl_cv_func_memchr_works" != yes; then
11455 REPLACE_STRSTR=1
11456 else
11457 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strstr works" >&5
11458$as_echo_n "checking whether strstr works... " >&6; }
11459if test "${gl_cv_func_strstr_works_always+set}" = set; then :
11460 $as_echo_n "(cached) " >&6
11461else
11462 if test "$cross_compiling" = yes; then :
11463 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11464/* end confdefs.h. */
11465
11466#ifdef __GNU_LIBRARY__
11467 #include <features.h>
11468 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ > 12) || (__GLIBC__ > 2)) \
11469 || defined __UCLIBC__
11470 Lucky user
11471 #endif
11472#elif defined __CYGWIN__
11473 #include <cygwin/version.h>
11474 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
11475 Lucky user
11476 #endif
11477#else
11478 Lucky user
11479#endif
11480
11481_ACEOF
11482if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11483 $EGREP "Lucky user" >/dev/null 2>&1; then :
11484 gl_cv_func_strstr_works_always="guessing yes"
11485else
11486 gl_cv_func_strstr_works_always="guessing no"
11487fi
11488rm -f conftest*
11489
11490
11491else
11492 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11493/* end confdefs.h. */
11494
11495#include <string.h> /* for strstr */
11496#define P "_EF_BF_BD"
11497#define HAYSTACK "F_BD_CE_BD" P P P P "_C3_88_20" P P P "_C3_A7_20" P
11498#define NEEDLE P P P P P
11499
11500int
11501main ()
11502{
11503return !!strstr (HAYSTACK, NEEDLE);
11504
11505 ;
11506 return 0;
11507}
11508_ACEOF
11509if ac_fn_c_try_run "$LINENO"; then :
11510 gl_cv_func_strstr_works_always=yes
11511else
11512 gl_cv_func_strstr_works_always=no
11513fi
11514rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11515 conftest.$ac_objext conftest.beam conftest.$ac_ext
11516fi
11517
11518
11519fi
11520{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strstr_works_always" >&5
11521$as_echo "$gl_cv_func_strstr_works_always" >&6; }
11522 case "$gl_cv_func_strstr_works_always" in
11523 *yes) ;;
11524 *)
11525 REPLACE_STRSTR=1
11526 ;;
11527 esac
11528 fi
11529
421693b0
PA
11530ac_fn_c_check_decl "$LINENO" "strtok_r" "ac_cv_have_decl_strtok_r" "$ac_includes_default"
11531if test "x$ac_cv_have_decl_strtok_r" = x""yes; then :
11532 ac_have_decl=1
11533else
11534 ac_have_decl=0
11535fi
11536
11537cat >>confdefs.h <<_ACEOF
11538#define HAVE_DECL_STRTOK_R $ac_have_decl
11539_ACEOF
11540
09607c9e
TT
11541{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
11542$as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
11543if test "${ac_cv_header_stat_broken+set}" = set; then :
11544 $as_echo_n "(cached) " >&6
11545else
11546 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11547/* end confdefs.h. */
11548#include <sys/types.h>
11549#include <sys/stat.h>
63ce7108 11550
09607c9e
TT
11551#if defined S_ISBLK && defined S_IFDIR
11552extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
11553#endif
8839a007 11554
09607c9e
TT
11555#if defined S_ISBLK && defined S_IFCHR
11556extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
11557#endif
11558
11559#if defined S_ISLNK && defined S_IFREG
11560extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
11561#endif
11562
11563#if defined S_ISSOCK && defined S_IFREG
11564extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
11565#endif
8839a007 11566
8839a007 11567_ACEOF
09607c9e
TT
11568if ac_fn_c_try_compile "$LINENO"; then :
11569 ac_cv_header_stat_broken=no
11570else
11571 ac_cv_header_stat_broken=yes
11572fi
11573rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11574fi
11575{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
11576$as_echo "$ac_cv_header_stat_broken" >&6; }
11577if test $ac_cv_header_stat_broken = yes; then
11578
11579$as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
8839a007
PA
11580
11581fi
11582
09607c9e
TT
11583
11584
8839a007
PA
11585ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
11586if test "x$ac_cv_type_mode_t" = x""yes; then :
11587
11588else
11589
11590cat >>confdefs.h <<_ACEOF
11591#define mode_t int
11592_ACEOF
11593
11594fi
11595
8839a007
PA
11596{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
11597$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
11598if test -z "$MKDIR_P"; then
11599 if test "${ac_cv_path_mkdir+set}" = set; then :
11600 $as_echo_n "(cached) " >&6
11601else
11602 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11603for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
11604do
11605 IFS=$as_save_IFS
11606 test -z "$as_dir" && as_dir=.
11607 for ac_prog in mkdir gmkdir; do
11608 for ac_exec_ext in '' $ac_executable_extensions; do
11609 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
11610 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
11611 'mkdir (GNU coreutils) '* | \
11612 'mkdir (coreutils) '* | \
11613 'mkdir (fileutils) '4.1*)
11614 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
11615 break 3;;
11616 esac
11617 done
11618 done
11619 done
11620IFS=$as_save_IFS
11621
11622fi
11623
11624 if test "${ac_cv_path_mkdir+set}" = set; then
11625 MKDIR_P="$ac_cv_path_mkdir -p"
11626 else
11627 # As a last resort, use the slow shell script. Don't cache a
11628 # value for MKDIR_P within a source directory, because that will
11629 # break other packages using the cache if that directory is
11630 # removed, or if the value is a relative name.
11631 test -d ./--version && rmdir ./--version
11632 MKDIR_P="$ac_install_sh -d"
11633 fi
11634fi
11635{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
11636$as_echo "$MKDIR_P" >&6; }
11637
11638
09607c9e 11639
09607c9e
TT
11640
11641
2196f55f 11642
09607c9e
TT
11643
11644
11645
11646
4a626d0a
PA
11647
11648
11649
11650
11651
11652
11653
11654
11655
11656 if test $gl_cv_have_include_next = yes; then
11657 gl_cv_next_sys_types_h='<'sys/types.h'>'
11658 else
11659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/types.h>" >&5
11660$as_echo_n "checking absolute name of <sys/types.h>... " >&6; }
11661if test "${gl_cv_next_sys_types_h+set}" = set; then :
11662 $as_echo_n "(cached) " >&6
11663else
11664
11665
11666
11667 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11668/* end confdefs.h. */
11669#include <sys/types.h>
11670_ACEOF
11671 case "$host_os" in
11672 aix*) gl_absname_cpp="$ac_cpp -C" ;;
11673 *) gl_absname_cpp="$ac_cpp" ;;
11674 esac
11675
11676 case "$host_os" in
11677 mingw*)
11678 gl_dirsep_regex='[/\\]'
11679 ;;
11680 *)
11681 gl_dirsep_regex='\/'
11682 ;;
11683 esac
11684 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
11685 gl_header_literal_regex=`echo 'sys/types.h' \
11686 | sed -e "$gl_make_literal_regex_sed"`
11687 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
11688 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
11689 s|^/[^/]|//&|
11690 p
11691 q
11692 }'
11693
11694 gl_cv_absolute_sys_types_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
11695 sed -n "$gl_absolute_header_sed"`
11696
11697 gl_header=$gl_cv_absolute_sys_types_h
11698 gl_cv_next_sys_types_h='"'$gl_header'"'
11699
11700
11701fi
11702{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_types_h" >&5
11703$as_echo "$gl_cv_next_sys_types_h" >&6; }
11704 fi
11705 NEXT_SYS_TYPES_H=$gl_cv_next_sys_types_h
11706
11707 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
11708 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
11709 gl_next_as_first_directive='<'sys/types.h'>'
11710 else
11711 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
11712 gl_next_as_first_directive=$gl_cv_next_sys_types_h
11713 fi
11714 NEXT_AS_FIRST_DIRECTIVE_SYS_TYPES_H=$gl_next_as_first_directive
11715
11716
11717
11718
11719
11720
11721
11722
11723
11724
11725
11726
09607c9e
TT
11727 GNULIB_MKTIME=0;
11728 GNULIB_NANOSLEEP=0;
11729 GNULIB_STRPTIME=0;
11730 GNULIB_TIMEGM=0;
11731 GNULIB_TIME_R=0;
4a626d0a 11732 GNULIB_TIME_RZ=0;
09607c9e
TT
11733 HAVE_DECL_LOCALTIME_R=1;
11734 HAVE_NANOSLEEP=1;
11735 HAVE_STRPTIME=1;
11736 HAVE_TIMEGM=1;
11737 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
11738 REPLACE_MKTIME=GNULIB_PORTCHECK;
11739 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
11740 REPLACE_TIMEGM=GNULIB_PORTCHECK;
11741
4a626d0a
PA
11742 : ${GNULIB_GETTIMEOFDAY=0};
11743 REPLACE_GMTIME=0;
11744 REPLACE_LOCALTIME=0;
09607c9e
TT
11745
11746
11747
11748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
11749$as_echo_n "checking for struct timespec in <time.h>... " >&6; }
11750if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
11751 $as_echo_n "(cached) " >&6
11752else
11753 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11754/* end confdefs.h. */
11755#include <time.h>
11756
11757int
11758main ()
11759{
11760static struct timespec x; x.tv_sec = x.tv_nsec;
11761 ;
11762 return 0;
11763}
11764_ACEOF
11765if ac_fn_c_try_compile "$LINENO"; then :
11766 gl_cv_sys_struct_timespec_in_time_h=yes
11767else
11768 gl_cv_sys_struct_timespec_in_time_h=no
11769fi
11770rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11771fi
11772{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
11773$as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
11774
11775 TIME_H_DEFINES_STRUCT_TIMESPEC=0
11776 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
11777 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
4a626d0a 11778 UNISTD_H_DEFINES_STRUCT_TIMESPEC=0
09607c9e
TT
11779 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
11780 TIME_H_DEFINES_STRUCT_TIMESPEC=1
11781 else
11782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
11783$as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
11784if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
11785 $as_echo_n "(cached) " >&6
11786else
11787 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11788/* end confdefs.h. */
11789#include <sys/time.h>
11790
11791int
11792main ()
11793{
11794static struct timespec x; x.tv_sec = x.tv_nsec;
11795 ;
11796 return 0;
11797}
11798_ACEOF
11799if ac_fn_c_try_compile "$LINENO"; then :
11800 gl_cv_sys_struct_timespec_in_sys_time_h=yes
11801else
11802 gl_cv_sys_struct_timespec_in_sys_time_h=no
11803fi
11804rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11805fi
11806{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
11807$as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
11808 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
11809 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
11810 else
11811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
11812$as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
11813if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then :
11814 $as_echo_n "(cached) " >&6
11815else
11816 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11817/* end confdefs.h. */
11818#include <pthread.h>
11819
11820int
11821main ()
11822{
11823static struct timespec x; x.tv_sec = x.tv_nsec;
11824 ;
11825 return 0;
11826}
11827_ACEOF
11828if ac_fn_c_try_compile "$LINENO"; then :
11829 gl_cv_sys_struct_timespec_in_pthread_h=yes
11830else
11831 gl_cv_sys_struct_timespec_in_pthread_h=no
11832fi
11833rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11834fi
11835{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
11836$as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
11837 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
11838 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
4a626d0a
PA
11839 else
11840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <unistd.h>" >&5
11841$as_echo_n "checking for struct timespec in <unistd.h>... " >&6; }
11842if test "${gl_cv_sys_struct_timespec_in_unistd_h+set}" = set; then :
11843 $as_echo_n "(cached) " >&6
11844else
11845 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11846/* end confdefs.h. */
11847#include <unistd.h>
11848
11849int
11850main ()
11851{
11852static struct timespec x; x.tv_sec = x.tv_nsec;
11853 ;
11854 return 0;
11855}
11856_ACEOF
11857if ac_fn_c_try_compile "$LINENO"; then :
11858 gl_cv_sys_struct_timespec_in_unistd_h=yes
11859else
11860 gl_cv_sys_struct_timespec_in_unistd_h=no
11861fi
11862rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11863fi
11864{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_unistd_h" >&5
11865$as_echo "$gl_cv_sys_struct_timespec_in_unistd_h" >&6; }
11866 if test $gl_cv_sys_struct_timespec_in_unistd_h = yes; then
11867 UNISTD_H_DEFINES_STRUCT_TIMESPEC=1
11868 fi
09607c9e
TT
11869 fi
11870 fi
11871 fi
11872
11873
11874
11875
11876
11877
11878
11879
11880
11881
11882
11883
11884
11885
11886
4a626d0a 11887
09607c9e
TT
11888 if test $gl_cv_have_include_next = yes; then
11889 gl_cv_next_time_h='<'time.h'>'
11890 else
11891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
11892$as_echo_n "checking absolute name of <time.h>... " >&6; }
11893if test "${gl_cv_next_time_h+set}" = set; then :
11894 $as_echo_n "(cached) " >&6
11895else
11896
4a626d0a
PA
11897
11898
11899 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
09607c9e
TT
11900/* end confdefs.h. */
11901#include <time.h>
09607c9e 11902_ACEOF
4a626d0a
PA
11903 case "$host_os" in
11904 aix*) gl_absname_cpp="$ac_cpp -C" ;;
11905 *) gl_absname_cpp="$ac_cpp" ;;
11906 esac
11907
11908 case "$host_os" in
11909 mingw*)
11910 gl_dirsep_regex='[/\\]'
11911 ;;
11912 *)
11913 gl_dirsep_regex='\/'
11914 ;;
11915 esac
11916 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
11917 gl_header_literal_regex=`echo 'time.h' \
11918 | sed -e "$gl_make_literal_regex_sed"`
11919 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
11920 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
11921 s|^/[^/]|//&|
11922 p
11923 q
11924 }'
09607c9e 11925
4a626d0a
PA
11926 gl_cv_absolute_time_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
11927 sed -n "$gl_absolute_header_sed"`
09607c9e 11928
4a626d0a
PA
11929 gl_header=$gl_cv_absolute_time_h
11930 gl_cv_next_time_h='"'$gl_header'"'
09607c9e
TT
11931
11932
11933fi
11934{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
11935$as_echo "$gl_cv_next_time_h" >&6; }
11936 fi
11937 NEXT_TIME_H=$gl_cv_next_time_h
11938
11939 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
11940 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
11941 gl_next_as_first_directive='<'time.h'>'
11942 else
11943 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
11944 gl_next_as_first_directive=$gl_cv_next_time_h
11945 fi
11946 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
11947
11948
11949
11950
11951
11952
11953
8690e634
JK
11954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <wchar.h> uses 'inline' correctly" >&5
11955$as_echo_n "checking whether <wchar.h> uses 'inline' correctly... " >&6; }
11956if test "${gl_cv_header_wchar_h_correct_inline+set}" = set; then :
11957 $as_echo_n "(cached) " >&6
11958else
11959 gl_cv_header_wchar_h_correct_inline=yes
11960 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11961/* end confdefs.h. */
11962
11963 #define wcstod renamed_wcstod
11964/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
11965 <wchar.h>.
11966 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
11967 included before <wchar.h>. */
11968#include <stddef.h>
11969#include <stdio.h>
11970#include <time.h>
11971#include <wchar.h>
11972extern int zero (void);
11973int main () { return zero(); }
11974
11975_ACEOF
11976 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
11977 (eval $ac_compile) 2>&5
11978 ac_status=$?
11979 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
11980 test $ac_status = 0; }; then
11981 mv conftest.$ac_objext conftest1.$ac_objext
11982 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11983/* end confdefs.h. */
11984
11985 #define wcstod renamed_wcstod
11986/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
11987 <wchar.h>.
11988 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
11989 included before <wchar.h>. */
11990#include <stddef.h>
11991#include <stdio.h>
11992#include <time.h>
11993#include <wchar.h>
11994int zero (void) { return 0; }
11995
11996_ACEOF
11997 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
11998 (eval $ac_compile) 2>&5
11999 ac_status=$?
12000 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
12001 test $ac_status = 0; }; then
12002 mv conftest.$ac_objext conftest2.$ac_objext
12003 if $CC -o conftest$ac_exeext $CFLAGS $LDFLAGS conftest1.$ac_objext conftest2.$ac_objext $LIBS >&5 2>&1; then
12004 :
12005 else
12006 gl_cv_header_wchar_h_correct_inline=no
12007 fi
12008 fi
12009 fi
12010 rm -f conftest1.$ac_objext conftest2.$ac_objext conftest$ac_exeext
12011
12012fi
12013{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_wchar_h_correct_inline" >&5
12014$as_echo "$gl_cv_header_wchar_h_correct_inline" >&6; }
12015 if test $gl_cv_header_wchar_h_correct_inline = no; then
12016 as_fn_error "<wchar.h> cannot be used with this compiler ($CC $CFLAGS $CPPFLAGS).
12017This is a known interoperability problem of glibc <= 2.5 with gcc >= 4.3 in
12018C99 mode. You have four options:
12019 - Add the flag -fgnu89-inline to CC and reconfigure, or
12020 - Fix your include files, using parts of
12021 <http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=b037a293a48718af30d706c2e18c929d0e69a621>, or
12022 - Use a gcc version older than 4.3, or
12023 - Don't use the flags -std=c99 or -std=gnu99.
12024Configuration aborted." "$LINENO" 5
12025 fi
12026
12027
12028
12029
12030
8690e634
JK
12031 if test $ac_cv_header_features_h = yes; then
12032 HAVE_FEATURES_H=1
12033 else
12034 HAVE_FEATURES_H=0
12035 fi
12036
12037
12038
12039 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wint_t" >&5
12040$as_echo_n "checking for wint_t... " >&6; }
12041if test "${gt_cv_c_wint_t+set}" = set; then :
12042 $as_echo_n "(cached) " >&6
12043else
12044 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12045/* end confdefs.h. */
12046
12047/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
12048 <wchar.h>.
12049 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
12050 before <wchar.h>. */
12051#include <stddef.h>
12052#include <stdio.h>
12053#include <time.h>
12054#include <wchar.h>
12055 wint_t foo = (wchar_t)'\0';
12056int
12057main ()
12058{
12059
12060 ;
12061 return 0;
12062}
12063_ACEOF
12064if ac_fn_c_try_compile "$LINENO"; then :
12065 gt_cv_c_wint_t=yes
12066else
12067 gt_cv_c_wint_t=no
12068fi
12069rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12070fi
12071{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wint_t" >&5
12072$as_echo "$gt_cv_c_wint_t" >&6; }
12073 if test $gt_cv_c_wint_t = yes; then
12074
12075$as_echo "#define HAVE_WINT_T 1" >>confdefs.h
12076
12077 fi
12078
12079
12080 GNULIB_ISWBLANK=0;
12081 GNULIB_WCTYPE=0;
12082 GNULIB_ISWCTYPE=0;
12083 GNULIB_WCTRANS=0;
12084 GNULIB_TOWCTRANS=0;
12085 HAVE_ISWBLANK=1;
12086 HAVE_WCTYPE_T=1;
12087 HAVE_WCTRANS_T=1;
12088 REPLACE_ISWBLANK=0;
12089
12090
12091
12092
8690e634
JK
12093 if false; then
12094 GL_COND_LIBTOOL_TRUE=
12095 GL_COND_LIBTOOL_FALSE='#'
12096else
12097 GL_COND_LIBTOOL_TRUE='#'
12098 GL_COND_LIBTOOL_FALSE=
12099fi
12100
12101 gl_cond_libtool=false
12102 gl_libdeps=
12103 gl_ltlibdeps=
12104 gl_m4_base='import/m4'
12105
12106
12107
12108
12109
12110
12111
12112
12113
12114 gl_source_base='import'
12115
12116
12117 if test $ac_cv_func_alloca_works = no; then
12118 :
12119 fi
12120
12121 # Define an additional variable used in the Makefile substitution.
12122 if test $ac_cv_working_alloca_h = yes; then
12123 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
12124$as_echo_n "checking for alloca as a compiler built-in... " >&6; }
12125if test "${gl_cv_rpl_alloca+set}" = set; then :
12126 $as_echo_n "(cached) " >&6
12127else
12128
12129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12130/* end confdefs.h. */
12131
12132#if defined __GNUC__ || defined _AIX || defined _MSC_VER
12133 Need own alloca
12134#endif
12135
12136_ACEOF
12137if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12138 $EGREP "Need own alloca" >/dev/null 2>&1; then :
12139 gl_cv_rpl_alloca=yes
12140else
12141 gl_cv_rpl_alloca=no
12142fi
12143rm -f conftest*
12144
12145
12146fi
12147{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
12148$as_echo "$gl_cv_rpl_alloca" >&6; }
12149 if test $gl_cv_rpl_alloca = yes; then
12150
12151$as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
12152
12153 ALLOCA_H=alloca.h
12154 else
12155 ALLOCA_H=
12156 fi
12157 else
12158 ALLOCA_H=alloca.h
12159 fi
12160
12161 if test -n "$ALLOCA_H"; then
12162 GL_GENERATE_ALLOCA_H_TRUE=
12163 GL_GENERATE_ALLOCA_H_FALSE='#'
12164else
12165 GL_GENERATE_ALLOCA_H_TRUE='#'
12166 GL_GENERATE_ALLOCA_H_FALSE=
12167fi
12168
12169
12170
98399780
YQ
12171
12172
12173 if test $ac_cv_func_canonicalize_file_name = no; then
12174 HAVE_CANONICALIZE_FILE_NAME=0
12175 if test $ac_cv_func_realpath = no; then
12176 HAVE_REALPATH=0
12177 else
12178 case "$gl_cv_func_realpath_works" in
12179 *yes) ;;
12180 *) REPLACE_REALPATH=1 ;;
12181 esac
12182 fi
12183 else
12184 case "$gl_cv_func_realpath_works" in
12185 *yes)
12186 ;;
12187 *)
12188 REPLACE_CANONICALIZE_FILE_NAME=1
12189 REPLACE_REALPATH=1
12190 ;;
12191 esac
12192 fi
12193
12194 if test $HAVE_CANONICALIZE_FILE_NAME = 0 || test $REPLACE_CANONICALIZE_FILE_NAME = 1; then
12195
12196
12197
12198
12199
12200
12201
12202
12203 gl_LIBOBJS="$gl_LIBOBJS canonicalize-lgpl.$ac_objext"
12204
12205 fi
12206
12207
12208cat >>confdefs.h <<_ACEOF
12209#define GNULIB_CANONICALIZE_LGPL 1
12210_ACEOF
12211
12212
12213
12214
12215
12216
12217
12218 GNULIB_CANONICALIZE_FILE_NAME=1
12219
12220
12221
12222
12223
12224$as_echo "#define GNULIB_TEST_CANONICALIZE_FILE_NAME 1" >>confdefs.h
12225
12226
12227
12228
12229
12230
12231
12232
12233 GNULIB_REALPATH=1
12234
12235
12236
12237
12238
12239$as_echo "#define GNULIB_TEST_REALPATH 1" >>confdefs.h
12240
12241
12242
12243
6a29c58e
YQ
12244
12245
12246
12247
12248 GNULIB_CHDIR=1
12249
12250
12251
12252
12253
12254$as_echo "#define GNULIB_TEST_CHDIR 1" >>confdefs.h
12255
12256
12257
12258
8690e634
JK
12259 if test "x$datarootdir" = x; then
12260 datarootdir='${datadir}'
12261
12262 fi
12263 if test "x$docdir" = x; then
12264 docdir='${datarootdir}/doc/${PACKAGE}'
12265
12266 fi
12267 if test "x$htmldir" = x; then
12268 htmldir='${docdir}'
12269
12270 fi
12271 if test "x$dvidir" = x; then
12272 dvidir='${docdir}'
12273
12274 fi
12275 if test "x$pdfdir" = x; then
12276 pdfdir='${docdir}'
12277
12278 fi
12279 if test "x$psdir" = x; then
12280 psdir='${docdir}'
12281
12282 fi
12283 if test "x$lispdir" = x; then
12284 lispdir='${datarootdir}/emacs/site-lisp'
12285
12286 fi
12287 if test "x$localedir" = x; then
12288 localedir='${datarootdir}/locale'
12289
4a626d0a
PA
12290 fi
12291 if test "x$runstatedir" = x; then
12292 runstatedir='${localstatedir}/run'
12293
8690e634
JK
12294 fi
12295
12296 pkglibexecdir='${libexecdir}/${PACKAGE}'
12297
12298
12299
12300
12301
12302
63ce7108 12303
e26b6bb0
TT
12304
12305
12306
12307
12308
12309
12310
12311 if test $gl_cv_have_include_next = yes; then
12312 gl_cv_next_dirent_h='<'dirent.h'>'
12313 else
12314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <dirent.h>" >&5
12315$as_echo_n "checking absolute name of <dirent.h>... " >&6; }
12316if test "${gl_cv_next_dirent_h+set}" = set; then :
12317 $as_echo_n "(cached) " >&6
12318else
12319
12320 if test $ac_cv_header_dirent_h = yes; then
12321
12322
4a626d0a
PA
12323
12324
12325 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
e26b6bb0
TT
12326/* end confdefs.h. */
12327#include <dirent.h>
e26b6bb0 12328_ACEOF
4a626d0a
PA
12329 case "$host_os" in
12330 aix*) gl_absname_cpp="$ac_cpp -C" ;;
12331 *) gl_absname_cpp="$ac_cpp" ;;
12332 esac
12333
12334 case "$host_os" in
12335 mingw*)
12336 gl_dirsep_regex='[/\\]'
12337 ;;
12338 *)
12339 gl_dirsep_regex='\/'
12340 ;;
12341 esac
12342 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
12343 gl_header_literal_regex=`echo 'dirent.h' \
12344 | sed -e "$gl_make_literal_regex_sed"`
12345 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
12346 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
12347 s|^/[^/]|//&|
12348 p
12349 q
12350 }'
12351
12352 gl_cv_absolute_dirent_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
12353 sed -n "$gl_absolute_header_sed"`
12354
12355 gl_header=$gl_cv_absolute_dirent_h
12356 gl_cv_next_dirent_h='"'$gl_header'"'
e26b6bb0
TT
12357 else
12358 gl_cv_next_dirent_h='<'dirent.h'>'
12359 fi
12360
12361
12362fi
12363{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_dirent_h" >&5
12364$as_echo "$gl_cv_next_dirent_h" >&6; }
12365 fi
12366 NEXT_DIRENT_H=$gl_cv_next_dirent_h
12367
12368 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
12369 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
12370 gl_next_as_first_directive='<'dirent.h'>'
12371 else
12372 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
12373 gl_next_as_first_directive=$gl_cv_next_dirent_h
12374 fi
12375 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H=$gl_next_as_first_directive
12376
12377
12378
12379
12380 if test $ac_cv_header_dirent_h = yes; then
12381 HAVE_DIRENT_H=1
12382 else
12383 HAVE_DIRENT_H=0
12384 fi
12385
12386
12387
12388 for gl_func in alphasort closedir dirfd fdopendir opendir readdir rewinddir scandir; do
12389 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
12390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
12391$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
12392if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
12393 $as_echo_n "(cached) " >&6
12394else
12395 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12396/* end confdefs.h. */
12397#include <dirent.h>
12398
12399int
12400main ()
12401{
12402#undef $gl_func
12403 (void) $gl_func;
12404 ;
12405 return 0;
12406}
12407_ACEOF
12408if ac_fn_c_try_compile "$LINENO"; then :
12409 eval "$as_gl_Symbol=yes"
12410else
12411 eval "$as_gl_Symbol=no"
12412fi
12413rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12414fi
12415eval ac_res=\$$as_gl_Symbol
12416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
12417$as_echo "$ac_res" >&6; }
12418 eval as_val=\$$as_gl_Symbol
12419 if test "x$as_val" = x""yes; then :
12420 cat >>confdefs.h <<_ACEOF
12421#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
12422_ACEOF
12423
12424 eval ac_cv_have_decl_$gl_func=yes
12425fi
12426 done
12427
12428
12429
12430
12431
12432
18848e28
GF
12433
12434 for ac_func in dirfd
12435do :
12436 ac_fn_c_check_func "$LINENO" "dirfd" "ac_cv_func_dirfd"
12437if test "x$ac_cv_func_dirfd" = x""yes; then :
12438 cat >>confdefs.h <<_ACEOF
12439#define HAVE_DIRFD 1
12440_ACEOF
12441
12442fi
12443done
12444
12445 ac_fn_c_check_decl "$LINENO" "dirfd" "ac_cv_have_decl_dirfd" "#include <sys/types.h>
12446 #include <dirent.h>
12447"
12448if test "x$ac_cv_have_decl_dirfd" = x""yes; then :
12449 ac_have_decl=1
12450else
12451 ac_have_decl=0
12452fi
12453
12454cat >>confdefs.h <<_ACEOF
12455#define HAVE_DECL_DIRFD $ac_have_decl
12456_ACEOF
12457
12458 if test $ac_cv_have_decl_dirfd = no; then
12459 HAVE_DECL_DIRFD=0
12460 fi
12461
12462 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dirfd is a macro" >&5
12463$as_echo_n "checking whether dirfd is a macro... " >&6; }
12464if test "${gl_cv_func_dirfd_macro+set}" = set; then :
12465 $as_echo_n "(cached) " >&6
12466else
12467 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12468/* end confdefs.h. */
12469
12470#include <sys/types.h>
12471#include <dirent.h>
12472#ifdef dirfd
12473 dirent_header_defines_dirfd
12474#endif
12475_ACEOF
12476if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12477 $EGREP "dirent_header_defines_dirfd" >/dev/null 2>&1; then :
12478 gl_cv_func_dirfd_macro=yes
12479else
12480 gl_cv_func_dirfd_macro=no
12481fi
12482rm -f conftest*
12483
12484fi
12485{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dirfd_macro" >&5
12486$as_echo "$gl_cv_func_dirfd_macro" >&6; }
12487
12488 # Use the replacement only if we have no function or macro with that name.
12489 if test $ac_cv_func_dirfd = no && test $gl_cv_func_dirfd_macro = no; then
12490 if test $ac_cv_have_decl_dirfd = yes; then
12491 # If the system declares dirfd already, let's declare rpl_dirfd instead.
12492 REPLACE_DIRFD=1
12493 fi
12494 fi
12495
12496 if test $ac_cv_func_dirfd = no && test $gl_cv_func_dirfd_macro = no; then
12497
12498
12499
12500
12501
12502
12503
12504
12505 gl_LIBOBJS="$gl_LIBOBJS dirfd.$ac_objext"
12506
12507
12508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to get the file descriptor associated with an open DIR*" >&5
12509$as_echo_n "checking how to get the file descriptor associated with an open DIR*... " >&6; }
12510if test "${gl_cv_sys_dir_fd_member_name+set}" = set; then :
12511 $as_echo_n "(cached) " >&6
12512else
12513
12514 dirfd_save_CFLAGS=$CFLAGS
12515 for ac_expr in d_fd dd_fd; do
12516
12517 CFLAGS="$CFLAGS -DDIR_FD_MEMBER_NAME=$ac_expr"
12518 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12519/* end confdefs.h. */
12520
12521 #include <sys/types.h>
12522 #include <dirent.h>
12523int
12524main ()
12525{
12526DIR *dir_p = opendir("."); (void) dir_p->DIR_FD_MEMBER_NAME;
12527 ;
12528 return 0;
12529}
12530_ACEOF
12531if ac_fn_c_try_compile "$LINENO"; then :
12532 dir_fd_found=yes
12533
12534fi
12535rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12536 CFLAGS=$dirfd_save_CFLAGS
12537 test "$dir_fd_found" = yes && break
12538 done
12539 test "$dir_fd_found" = yes || ac_expr=no_such_member
12540
12541 gl_cv_sys_dir_fd_member_name=$ac_expr
12542
12543
12544fi
12545{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_dir_fd_member_name" >&5
12546$as_echo "$gl_cv_sys_dir_fd_member_name" >&6; }
12547 if test $gl_cv_sys_dir_fd_member_name != no_such_member; then
12548
12549cat >>confdefs.h <<_ACEOF
12550#define DIR_FD_MEMBER_NAME $gl_cv_sys_dir_fd_member_name
12551_ACEOF
12552
12553 fi
12554
12555
12556 fi
12557
12558
12559
12560
12561
12562 GNULIB_DIRFD=1
12563
12564
12565
12566
12567
12568$as_echo "#define GNULIB_TEST_DIRFD 1" >>confdefs.h
12569
12570
12571
12572
12573
12574
12575
12576
6a29c58e
YQ
12577
12578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether // is distinct from /" >&5
12579$as_echo_n "checking whether // is distinct from /... " >&6; }
12580if test "${gl_cv_double_slash_root+set}" = set; then :
12581 $as_echo_n "(cached) " >&6
12582else
12583 if test x"$cross_compiling" = xyes ; then
12584 # When cross-compiling, there is no way to tell whether // is special
12585 # short of a list of hosts. However, the only known hosts to date
12586 # that have a distinct // are Apollo DomainOS (too old to port to),
12587 # Cygwin, and z/OS. If anyone knows of another system for which // has
12588 # special semantics and is distinct from /, please report it to
12589 # <bug-gnulib@gnu.org>.
12590 case $host in
12591 *-cygwin | i370-ibm-openedition)
12592 gl_cv_double_slash_root=yes ;;
12593 *)
12594 # Be optimistic and assume that / and // are the same when we
12595 # don't know.
12596 gl_cv_double_slash_root='unknown, assuming no' ;;
12597 esac
12598 else
12599 set x `ls -di / // 2>/dev/null`
12600 if test "$2" = "$4" && wc //dev/null >/dev/null 2>&1; then
12601 gl_cv_double_slash_root=no
12602 else
12603 gl_cv_double_slash_root=yes
12604 fi
12605 fi
12606fi
12607{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_double_slash_root" >&5
12608$as_echo "$gl_cv_double_slash_root" >&6; }
12609 if test "$gl_cv_double_slash_root" = yes; then
12610
12611$as_echo "#define DOUBLE_SLASH_IS_DISTINCT_ROOT 1" >>confdefs.h
12612
12613 fi
12614
12615
12616
12617
12618
12619
88b48903
WN
12620 FLOAT_H=
12621 REPLACE_FLOAT_LDBL=0
12622 case "$host_os" in
12623 aix* | beos* | openbsd* | mirbsd* | irix*)
12624 FLOAT_H=float.h
12625 ;;
12626 freebsd*)
12627 case "$host_cpu" in
12628 i[34567]86 )
12629 FLOAT_H=float.h
12630 ;;
12631 x86_64 )
12632 # On x86_64 systems, the C compiler may still be generating
12633 # 32-bit code.
12634 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12635/* end confdefs.h. */
12636#if defined __LP64__ || defined __x86_64__ || defined __amd64__
12637 yes
12638 #endif
12639_ACEOF
12640if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12641 $EGREP "yes" >/dev/null 2>&1; then :
12642
12643else
12644 FLOAT_H=float.h
12645fi
12646rm -f conftest*
8690e634 12647
88b48903
WN
12648 ;;
12649 esac
12650 ;;
12651 linux*)
12652 case "$host_cpu" in
12653 powerpc*)
12654 FLOAT_H=float.h
12655 ;;
12656 esac
12657 ;;
12658 esac
12659 case "$host_os" in
12660 aix* | freebsd* | linux*)
12661 if test -n "$FLOAT_H"; then
12662 REPLACE_FLOAT_LDBL=1
12663 fi
12664 ;;
12665 esac
a512b375 12666
88b48903
WN
12667 REPLACE_ITOLD=0
12668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether conversion from 'int' to 'long double' works" >&5
12669$as_echo_n "checking whether conversion from 'int' to 'long double' works... " >&6; }
12670if test "${gl_cv_func_itold_works+set}" = set; then :
8690e634
JK
12671 $as_echo_n "(cached) " >&6
12672else
88b48903
WN
12673
12674 if test "$cross_compiling" = yes; then :
12675 case "$host" in
12676 sparc*-*-linux*)
12677 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12678/* end confdefs.h. */
12679#if defined __LP64__ || defined __arch64__
12680 yes
12681 #endif
12682_ACEOF
12683if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12684 $EGREP "yes" >/dev/null 2>&1; then :
12685 gl_cv_func_itold_works="guessing no"
12686else
12687 gl_cv_func_itold_works="guessing yes"
12688fi
12689rm -f conftest*
12690
12691 ;;
12692 *) gl_cv_func_itold_works="guessing yes" ;;
12693 esac
12694
8690e634
JK
12695else
12696 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12697/* end confdefs.h. */
8690e634 12698
88b48903
WN
12699int i = -1;
12700volatile long double ld;
12701int main ()
8690e634 12702{
88b48903
WN
12703 ld += i * 1.0L;
12704 if (ld > 0)
12705 return 1;
12706 return 0;
12707}
12708_ACEOF
12709if ac_fn_c_try_run "$LINENO"; then :
12710 gl_cv_func_itold_works=yes
12711else
12712 gl_cv_func_itold_works=no
12713fi
12714rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12715 conftest.$ac_objext conftest.beam conftest.$ac_ext
12716fi
12717
12718
12719fi
12720{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_itold_works" >&5
12721$as_echo "$gl_cv_func_itold_works" >&6; }
12722 case "$gl_cv_func_itold_works" in
12723 *no)
12724 REPLACE_ITOLD=1
12725 FLOAT_H=float.h
12726 ;;
12727 esac
12728
12729 if test -n "$FLOAT_H"; then
12730
12731
12732
12733
12734
12735
12736
12737
12738 if test $gl_cv_have_include_next = yes; then
12739 gl_cv_next_float_h='<'float.h'>'
12740 else
12741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <float.h>" >&5
12742$as_echo_n "checking absolute name of <float.h>... " >&6; }
12743if test "${gl_cv_next_float_h+set}" = set; then :
12744 $as_echo_n "(cached) " >&6
12745else
12746
4a626d0a
PA
12747
12748
12749 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
88b48903
WN
12750/* end confdefs.h. */
12751#include <float.h>
88b48903 12752_ACEOF
4a626d0a
PA
12753 case "$host_os" in
12754 aix*) gl_absname_cpp="$ac_cpp -C" ;;
12755 *) gl_absname_cpp="$ac_cpp" ;;
12756 esac
12757
12758 case "$host_os" in
12759 mingw*)
12760 gl_dirsep_regex='[/\\]'
12761 ;;
12762 *)
12763 gl_dirsep_regex='\/'
12764 ;;
12765 esac
12766 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
12767 gl_header_literal_regex=`echo 'float.h' \
12768 | sed -e "$gl_make_literal_regex_sed"`
12769 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
12770 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
12771 s|^/[^/]|//&|
12772 p
12773 q
12774 }'
88b48903 12775
4a626d0a
PA
12776 gl_cv_absolute_float_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
12777 sed -n "$gl_absolute_header_sed"`
88b48903 12778
4a626d0a
PA
12779 gl_header=$gl_cv_absolute_float_h
12780 gl_cv_next_float_h='"'$gl_header'"'
88b48903
WN
12781
12782
12783fi
12784{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_float_h" >&5
12785$as_echo "$gl_cv_next_float_h" >&6; }
12786 fi
12787 NEXT_FLOAT_H=$gl_cv_next_float_h
12788
12789 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
12790 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
12791 gl_next_as_first_directive='<'float.h'>'
12792 else
12793 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
12794 gl_next_as_first_directive=$gl_cv_next_float_h
12795 fi
12796 NEXT_AS_FIRST_DIRECTIVE_FLOAT_H=$gl_next_as_first_directive
12797
12798
12799
12800
12801 fi
12802
12803 if test -n "$FLOAT_H"; then
12804 GL_GENERATE_FLOAT_H_TRUE=
12805 GL_GENERATE_FLOAT_H_FALSE='#'
12806else
12807 GL_GENERATE_FLOAT_H_TRUE='#'
12808 GL_GENERATE_FLOAT_H_FALSE=
12809fi
12810
12811
12812
12813 if test $REPLACE_FLOAT_LDBL = 1; then
12814
12815
12816
12817
12818
12819
12820
12821
12822 gl_LIBOBJS="$gl_LIBOBJS float.$ac_objext"
12823
12824 fi
12825 if test $REPLACE_ITOLD = 1; then
12826
12827
12828
12829
12830
12831
12832
12833
12834 gl_LIBOBJS="$gl_LIBOBJS itold.$ac_objext"
12835
12836 fi
12837
12838
12839
12840
12841
12842 FNMATCH_H=
12843 gl_fnmatch_required_lowercase=`
12844 echo $gl_fnmatch_required | LC_ALL=C tr '[A-Z]' '[a-z]'
12845 `
12846 gl_fnmatch_cache_var="gl_cv_func_fnmatch_${gl_fnmatch_required_lowercase}"
12847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working $gl_fnmatch_required fnmatch" >&5
12848$as_echo_n "checking for working $gl_fnmatch_required fnmatch... " >&6; }
12849if { as_var=$gl_fnmatch_cache_var; eval "test \"\${$as_var+set}\" = set"; }; then :
12850 $as_echo_n "(cached) " >&6
12851else
12852 if test $gl_fnmatch_required = GNU; then
12853 gl_fnmatch_gnu_start=
12854 gl_fnmatch_gnu_end=
12855 else
12856 gl_fnmatch_gnu_start='#if 0'
12857 gl_fnmatch_gnu_end='#endif'
12858 fi
12859 if test "$cross_compiling" = yes; then :
12860 eval "$gl_fnmatch_cache_var=\"guessing no\""
12861else
12862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12863/* end confdefs.h. */
12864#include <fnmatch.h>
12865 static int
12866 y (char const *pattern, char const *string, int flags)
12867 {
12868 return fnmatch (pattern, string, flags) == 0;
12869 }
12870 static int
12871 n (char const *pattern, char const *string, int flags)
12872 {
12873 return fnmatch (pattern, string, flags) == FNM_NOMATCH;
12874 }
12875
12876int
12877main ()
12878{
12879char const *Apat = 'A' < '\\\\' ? "[A-\\\\\\\\]" : "[\\\\\\\\-A]";
12880 char const *apat = 'a' < '\\\\' ? "[a-\\\\\\\\]" : "[\\\\\\\\-a]";
12881 static char const A_1[] = { 'A' - 1, 0 };
12882 static char const A01[] = { 'A' + 1, 0 };
12883 static char const a_1[] = { 'a' - 1, 0 };
12884 static char const a01[] = { 'a' + 1, 0 };
12885 static char const bs_1[] = { '\\\\' - 1, 0 };
8690e634
JK
12886 static char const bs01[] = { '\\\\' + 1, 0 };
12887 int result = 0;
12888 if (!n ("a*", "", 0))
12889 return 1;
12890 if (!y ("a*", "abc", 0))
12891 return 1;
12892 if (!y ("[/b", "[/b", 0)) /*"]]"*/ /* glibc Bugzilla bug 12378 */
12893 return 1;
12894 if (!n ("d*/*1", "d/s/1", FNM_PATHNAME))
12895 return 2;
12896 if (!y ("a\\\\bc", "abc", 0))
12897 return 3;
12898 if (!n ("a\\\\bc", "abc", FNM_NOESCAPE))
12899 return 3;
12900 if (!y ("*x", ".x", 0))
12901 return 4;
12902 if (!n ("*x", ".x", FNM_PERIOD))
12903 return 4;
12904 if (!y (Apat, "\\\\", 0))
12905 return 5;
12906 if (!y (Apat, "A", 0))
12907 return 5;
12908 if (!y (apat, "\\\\", 0))
12909 return 5;
12910 if (!y (apat, "a", 0))
12911 return 5;
12912 if (!(n (Apat, A_1, 0) == ('A' < '\\\\')))
12913 return 5;
12914 if (!(n (apat, a_1, 0) == ('a' < '\\\\')))
12915 return 5;
12916 if (!(y (Apat, A01, 0) == ('A' < '\\\\')))
12917 return 5;
12918 if (!(y (apat, a01, 0) == ('a' < '\\\\')))
12919 return 5;
12920 if (!(y (Apat, bs_1, 0) == ('A' < '\\\\')))
12921 return 5;
12922 if (!(y (apat, bs_1, 0) == ('a' < '\\\\')))
12923 return 5;
12924 if (!(n (Apat, bs01, 0) == ('A' < '\\\\')))
12925 return 5;
12926 if (!(n (apat, bs01, 0) == ('a' < '\\\\')))
12927 return 5;
12928 $gl_fnmatch_gnu_start
12929 if (!y ("xxXX", "xXxX", FNM_CASEFOLD))
12930 result |= 8;
12931 if (!y ("a++(x|yy)b", "a+xyyyyxb", FNM_EXTMATCH))
12932 result |= 16;
12933 if (!n ("d*/*1", "d/s/1", FNM_FILE_NAME))
12934 result |= 32;
12935 if (!y ("*", "x", FNM_FILE_NAME | FNM_LEADING_DIR))
12936 result |= 64;
12937 if (!y ("x*", "x/y/z", FNM_FILE_NAME | FNM_LEADING_DIR))
12938 result |= 64;
12939 if (!y ("*c*", "c/x", FNM_FILE_NAME | FNM_LEADING_DIR))
12940 result |= 64;
12941 $gl_fnmatch_gnu_end
12942 return result;
12943
12944 ;
12945 return 0;
12946}
12947_ACEOF
12948if ac_fn_c_try_run "$LINENO"; then :
12949 eval "$gl_fnmatch_cache_var=yes"
12950else
12951 eval "$gl_fnmatch_cache_var=no"
12952fi
12953rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12954 conftest.$ac_objext conftest.beam conftest.$ac_ext
12955fi
12956
12957
12958fi
12959eval ac_res=\$$gl_fnmatch_cache_var
12960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
12961$as_echo "$ac_res" >&6; }
12962 eval "gl_fnmatch_result=\"\$$gl_fnmatch_cache_var\""
12963 if test "$gl_fnmatch_result" = yes; then
12964 rm -f "$gl_source_base/fnmatch.h"
12965 else
12966 FNMATCH_H=fnmatch.h
12967 fi
12968
12969 if test -n "$FNMATCH_H"; then
12970 GL_GENERATE_FNMATCH_H_TRUE=
12971 GL_GENERATE_FNMATCH_H_FALSE='#'
12972else
12973 GL_GENERATE_FNMATCH_H_TRUE='#'
12974 GL_GENERATE_FNMATCH_H_FALSE=
12975fi
12976
12977
a512b375 12978 if test -n "$FNMATCH_H"; then
8690e634
JK
12979
12980
12981
12982
12983
12984
12985
12986
12987 gl_LIBOBJS="$gl_LIBOBJS fnmatch.$ac_objext"
12988
12989
12990
12991cat >>confdefs.h <<_ACEOF
12992#define fnmatch ${gl_fnmatch_required_lowercase}_fnmatch
12993_ACEOF
12994
12995
12996 ac_fn_c_check_decl "$LINENO" "isblank" "ac_cv_have_decl_isblank" "#include <ctype.h>
12997"
12998if test "x$ac_cv_have_decl_isblank" = x""yes; then :
12999 ac_have_decl=1
13000else
13001 ac_have_decl=0
13002fi
13003
13004cat >>confdefs.h <<_ACEOF
13005#define HAVE_DECL_ISBLANK $ac_have_decl
13006_ACEOF
13007
13008
c971b7fa 13009
c971b7fa 13010
a512b375 13011 fi
c971b7fa 13012
c971b7fa 13013
c971b7fa 13014
c971b7fa 13015
c971b7fa 13016
a512b375 13017 if test -n "$FNMATCH_H"; then
c971b7fa 13018
c971b7fa 13019
c971b7fa
PA
13020
13021
c971b7fa
PA
13022
13023
c971b7fa
PA
13024
13025
8690e634 13026 gl_LIBOBJS="$gl_LIBOBJS fnmatch.$ac_objext"
c971b7fa 13027
c971b7fa 13028
c971b7fa 13029
8690e634
JK
13030cat >>confdefs.h <<_ACEOF
13031#define fnmatch ${gl_fnmatch_required_lowercase}_fnmatch
13032_ACEOF
c971b7fa
PA
13033
13034
8690e634
JK
13035 ac_fn_c_check_decl "$LINENO" "isblank" "ac_cv_have_decl_isblank" "#include <ctype.h>
13036"
13037if test "x$ac_cv_have_decl_isblank" = x""yes; then :
13038 ac_have_decl=1
13039else
13040 ac_have_decl=0
c971b7fa 13041fi
c971b7fa 13042
8690e634
JK
13043cat >>confdefs.h <<_ACEOF
13044#define HAVE_DECL_ISBLANK $ac_have_decl
c971b7fa
PA
13045_ACEOF
13046
c971b7fa 13047
8690e634 13048
c971b7fa 13049
88b48903
WN
13050 fi
13051
13052
13053
13054 FREXP_LIBM=
13055 if test $gl_cv_func_frexp_no_libm = no; then
13056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexp() can be used with libm" >&5
13057$as_echo_n "checking whether frexp() can be used with libm... " >&6; }
13058if test "${gl_cv_func_frexp_in_libm+set}" = set; then :
13059 $as_echo_n "(cached) " >&6
13060else
13061
13062 save_LIBS="$LIBS"
13063 LIBS="$LIBS -lm"
13064 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13065/* end confdefs.h. */
13066#include <math.h>
13067 double x;
13068int
13069main ()
13070{
13071int e; return frexp (x, &e) > 0;
13072 ;
13073 return 0;
13074}
13075_ACEOF
13076if ac_fn_c_try_link "$LINENO"; then :
13077 gl_cv_func_frexp_in_libm=yes
13078else
13079 gl_cv_func_frexp_in_libm=no
13080fi
13081rm -f core conftest.err conftest.$ac_objext \
13082 conftest$ac_exeext conftest.$ac_ext
13083 LIBS="$save_LIBS"
13084
13085fi
13086{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexp_in_libm" >&5
13087$as_echo "$gl_cv_func_frexp_in_libm" >&6; }
13088 if test $gl_cv_func_frexp_in_libm = yes; then
13089 FREXP_LIBM=-lm
13090 fi
13091 fi
13092 if test $gl_cv_func_frexp_no_libm = yes \
13093 || test $gl_cv_func_frexp_in_libm = yes; then
13094 save_LIBS="$LIBS"
13095 LIBS="$LIBS $FREXP_LIBM"
13096
13097
13098
88b48903
WN
13099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexp works" >&5
13100$as_echo_n "checking whether frexp works... " >&6; }
13101if test "${gl_cv_func_frexp_works+set}" = set; then :
13102 $as_echo_n "(cached) " >&6
13103else
13104
13105 if test "$cross_compiling" = yes; then :
13106 case "$host_os" in
13107 netbsd* | irix* | mingw*) gl_cv_func_frexp_works="guessing no";;
13108 *) gl_cv_func_frexp_works="guessing yes";;
13109 esac
13110
13111else
13112 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13113/* end confdefs.h. */
13114
13115#include <float.h>
13116#include <math.h>
13117#include <string.h>
4a626d0a
PA
13118#if HAVE_DECL_ALARM
13119# include <signal.h>
88b48903
WN
13120# include <unistd.h>
13121#endif
13122/* HP cc on HP-UX 10.20 has a bug with the constant expression -0.0.
13123 ICC 10.0 has a bug when optimizing the expression -zero.
13124 The expression -DBL_MIN * DBL_MIN does not work when cross-compiling
13125 to PowerPC on Mac OS X 10.5. */
13126#if defined __hpux || defined __sgi || defined __ICC
13127static double
13128compute_minus_zero (void)
13129{
13130 return -DBL_MIN * DBL_MIN;
13131}
13132# define minus_zero compute_minus_zero ()
13133#else
13134double minus_zero = -0.0;
13135#endif
13136int main()
13137{
13138 int result = 0;
13139 int i;
13140 volatile double x;
13141 double zero = 0.0;
4a626d0a 13142#if HAVE_DECL_ALARM
88b48903
WN
13143 /* NeXTstep 3.3 frexp() runs into an endless loop when called on an infinite
13144 number. Let the test fail in this case. */
4a626d0a 13145 signal (SIGALRM, SIG_DFL);
88b48903
WN
13146 alarm (5);
13147#endif
13148 /* Test on denormalized numbers. */
13149 for (i = 1, x = 1.0; i >= DBL_MIN_EXP; i--, x *= 0.5)
13150 ;
13151 if (x > 0.0)
13152 {
13153 int exp;
13154 double y = frexp (x, &exp);
13155 /* On machines with IEEE754 arithmetic: x = 1.11254e-308, exp = -1022.
13156 On NetBSD: y = 0.75. Correct: y = 0.5. */
13157 if (y != 0.5)
13158 result |= 1;
13159 }
13160 /* Test on infinite numbers. */
13161 x = 1.0 / zero;
13162 {
13163 int exp;
13164 double y = frexp (x, &exp);
13165 if (y != x)
13166 result |= 2;
13167 }
13168 /* Test on negative zero. */
13169 x = minus_zero;
13170 {
13171 int exp;
13172 double y = frexp (x, &exp);
13173 if (memcmp (&y, &x, sizeof x))
13174 result |= 4;
13175 }
13176 return result;
13177}
13178_ACEOF
13179if ac_fn_c_try_run "$LINENO"; then :
13180 gl_cv_func_frexp_works=yes
13181else
13182 gl_cv_func_frexp_works=no
13183fi
13184rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13185 conftest.$ac_objext conftest.beam conftest.$ac_ext
13186fi
13187
13188
13189fi
13190{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexp_works" >&5
13191$as_echo "$gl_cv_func_frexp_works" >&6; }
13192
13193 LIBS="$save_LIBS"
13194 case "$gl_cv_func_frexp_works" in
13195 *yes) gl_func_frexp=yes ;;
13196 *) gl_func_frexp=no; REPLACE_FREXP=1; FREXP_LIBM= ;;
13197 esac
13198 else
13199 gl_func_frexp=no
13200 fi
13201 if test $gl_func_frexp = yes; then
13202
13203$as_echo "#define HAVE_FREXP 1" >>confdefs.h
13204
13205 fi
13206
13207
13208 if test $gl_func_frexp != yes; then
13209
13210
13211
13212
13213
13214
13215
13216
13217 gl_LIBOBJS="$gl_LIBOBJS frexp.$ac_objext"
13218
13219 fi
13220
13221
13222
13223
13224
13225 GNULIB_FREXP=1
13226
13227
13228
13229
13230
13231$as_echo "#define GNULIB_TEST_FREXP 1" >>confdefs.h
13232
13233
13234
13235
13236
13237
13238
13239
13240
13241 ac_fn_c_check_decl "$LINENO" "frexpl" "ac_cv_have_decl_frexpl" "#include <math.h>
13242"
13243if test "x$ac_cv_have_decl_frexpl" = x""yes; then :
13244
13245else
13246 HAVE_DECL_FREXPL=0
13247fi
13248
13249
13250 FREXPL_LIBM=
13251 if test $HAVE_DECL_FREXPL = 1; then
13252
13253 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexpl() can be used without linking with libm" >&5
13254$as_echo_n "checking whether frexpl() can be used without linking with libm... " >&6; }
13255if test "${gl_cv_func_frexpl_no_libm+set}" = set; then :
13256 $as_echo_n "(cached) " >&6
13257else
13258
13259 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13260/* end confdefs.h. */
13261#include <math.h>
13262 long double x;
13263int
13264main ()
13265{
13266int e; return frexpl (x, &e) > 0;
13267 ;
13268 return 0;
13269}
13270_ACEOF
13271if ac_fn_c_try_link "$LINENO"; then :
13272 gl_cv_func_frexpl_no_libm=yes
13273else
13274 gl_cv_func_frexpl_no_libm=no
13275fi
13276rm -f core conftest.err conftest.$ac_objext \
13277 conftest$ac_exeext conftest.$ac_ext
13278
13279fi
13280{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexpl_no_libm" >&5
13281$as_echo "$gl_cv_func_frexpl_no_libm" >&6; }
13282
13283 if test $gl_cv_func_frexpl_no_libm = no; then
13284 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexpl() can be used with libm" >&5
13285$as_echo_n "checking whether frexpl() can be used with libm... " >&6; }
13286if test "${gl_cv_func_frexpl_in_libm+set}" = set; then :
13287 $as_echo_n "(cached) " >&6
13288else
13289
13290 save_LIBS="$LIBS"
13291 LIBS="$LIBS -lm"
13292 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13293/* end confdefs.h. */
13294#include <math.h>
13295 long double x;
13296int
13297main ()
13298{
13299int e; return frexpl (x, &e) > 0;
13300 ;
13301 return 0;
13302}
13303_ACEOF
13304if ac_fn_c_try_link "$LINENO"; then :
13305 gl_cv_func_frexpl_in_libm=yes
13306else
13307 gl_cv_func_frexpl_in_libm=no
13308fi
13309rm -f core conftest.err conftest.$ac_objext \
13310 conftest$ac_exeext conftest.$ac_ext
13311 LIBS="$save_LIBS"
13312
13313fi
13314{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexpl_in_libm" >&5
13315$as_echo "$gl_cv_func_frexpl_in_libm" >&6; }
13316 if test $gl_cv_func_frexpl_in_libm = yes; then
13317 FREXPL_LIBM=-lm
13318 fi
13319 fi
13320 if test $gl_cv_func_frexpl_no_libm = yes \
13321 || test $gl_cv_func_frexpl_in_libm = yes; then
13322 save_LIBS="$LIBS"
13323 LIBS="$LIBS $FREXPL_LIBM"
13324
13325
13326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexpl works" >&5
13327$as_echo_n "checking whether frexpl works... " >&6; }
13328if test "${gl_cv_func_frexpl_works+set}" = set; then :
13329 $as_echo_n "(cached) " >&6
13330else
13331
13332 if test "$cross_compiling" = yes; then :
13333
13334 case "$host_os" in
13335 aix | aix[3-6]* | beos* | darwin* | irix* | mingw* | pw*)
13336 gl_cv_func_frexpl_works="guessing no";;
13337 *) gl_cv_func_frexpl_works="guessing yes";;
13338 esac
13339
13340else
13341 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13342/* end confdefs.h. */
13343
13344#include <float.h>
13345#include <math.h>
13346/* Override the values of <float.h>, like done in float.in.h. */
13347#if defined __i386__ && (defined __BEOS__ || defined __OpenBSD__)
13348# undef LDBL_MIN_EXP
13349# define LDBL_MIN_EXP (-16381)
13350#endif
13351#if defined __i386__ && defined __FreeBSD__
13352# undef LDBL_MIN_EXP
13353# define LDBL_MIN_EXP (-16381)
13354#endif
13355#if (defined _ARCH_PPC || defined _POWER) && defined _AIX && (LDBL_MANT_DIG == 106) && defined __GNUC__
13356# undef LDBL_MIN_EXP
13357# define LDBL_MIN_EXP DBL_MIN_EXP
13358#endif
13359#if defined __sgi && (LDBL_MANT_DIG >= 106)
13360# if defined __GNUC__
13361# undef LDBL_MIN_EXP
13362# define LDBL_MIN_EXP DBL_MIN_EXP
13363# endif
13364#endif
13365extern
13366#ifdef __cplusplus
13367"C"
13368#endif
13369long double frexpl (long double, int *);
13370int main()
13371{
13372 int result = 0;
13373 volatile long double x;
13374 /* Test on finite numbers that fails on AIX 5.1. */
13375 x = 16.0L;
13376 {
13377 int exp = -9999;
13378 frexpl (x, &exp);
13379 if (exp != 5)
13380 result |= 1;
13381 }
13382 /* Test on finite numbers that fails on Mac OS X 10.4, because its frexpl
13383 function returns an invalid (incorrectly normalized) value: it returns
13384 y = { 0x3fe028f5, 0xc28f5c28, 0x3c9eb851, 0xeb851eb8 }
13385 but the correct result is
13386 0.505L = { 0x3fe028f5, 0xc28f5c29, 0xbc547ae1, 0x47ae1480 } */
13387 x = 1.01L;
13388 {
13389 int exp = -9999;
13390 long double y = frexpl (x, &exp);
13391 if (!(exp == 1 && y == 0.505L))
13392 result |= 2;
13393 }
13394 /* Test on large finite numbers. This fails on BeOS at i = 16322, while
13395 LDBL_MAX_EXP = 16384.
13396 In the loop end test, we test x against Infinity, rather than comparing
13397 i with LDBL_MAX_EXP, because BeOS <float.h> has a wrong LDBL_MAX_EXP. */
13398 {
13399 int i;
13400 for (i = 1, x = 1.0L; x != x + x; i++, x *= 2.0L)
13401 {
13402 int exp = -9999;
13403 frexpl (x, &exp);
13404 if (exp != i)
13405 {
13406 result |= 4;
13407 break;
13408 }
13409 }
13410 }
13411 /* Test on denormalized numbers. */
13412 {
13413 int i;
13414 for (i = 1, x = 1.0L; i >= LDBL_MIN_EXP; i--, x *= 0.5L)
13415 ;
13416 if (x > 0.0L)
13417 {
13418 int exp;
13419 long double y = frexpl (x, &exp);
13420 /* On machines with IEEE854 arithmetic: x = 1.68105e-4932,
13421 exp = -16382, y = 0.5. On Mac OS X 10.5: exp = -16384, y = 0.5. */
13422 if (exp != LDBL_MIN_EXP - 1)
13423 result |= 8;
13424 }
13425 }
13426 /* Test on infinite numbers. */
13427 x = 1.0L / 0.0L;
13428 {
13429 int exp;
13430 long double y = frexpl (x, &exp);
13431 if (y != x)
13432 result |= 16;
13433 }
13434 return result;
13435}
13436_ACEOF
13437if ac_fn_c_try_run "$LINENO"; then :
13438 gl_cv_func_frexpl_works=yes
13439else
13440 gl_cv_func_frexpl_works=no
13441fi
13442rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13443 conftest.$ac_objext conftest.beam conftest.$ac_ext
13444fi
13445
13446
4a626d0a
PA
13447fi
13448{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexpl_works" >&5
13449$as_echo "$gl_cv_func_frexpl_works" >&6; }
13450
13451 LIBS="$save_LIBS"
13452 case "$gl_cv_func_frexpl_works" in
13453 *yes) gl_func_frexpl=yes ;;
13454 *) gl_func_frexpl=no; REPLACE_FREXPL=1 ;;
13455 esac
13456 else
13457 gl_func_frexpl=no
13458 fi
13459 if test $gl_func_frexpl = yes; then
13460
13461$as_echo "#define HAVE_FREXPL 1" >>confdefs.h
13462
13463 fi
13464 fi
13465 if test $HAVE_DECL_FREXPL = 0 || test $gl_func_frexpl = no; then
13466 if test $HAVE_SAME_LONG_DOUBLE_AS_DOUBLE = 1; then
13467
13468 FREXPL_LIBM="$FREXP_LIBM"
13469 else
13470 FREXPL_LIBM=
13471 fi
13472 fi
13473
13474
13475 if test $HAVE_DECL_FREXPL = 0 || test $gl_func_frexpl = no; then
13476
13477
13478
13479
13480
13481
13482
13483
13484 gl_LIBOBJS="$gl_LIBOBJS frexpl.$ac_objext"
13485
13486 fi
13487
13488
13489
13490
13491
13492 GNULIB_FREXPL=1
13493
13494
13495
13496
13497
13498$as_echo "#define GNULIB_TEST_FREXPL 1" >>confdefs.h
13499
13500
13501
13502
13503
13504
13505
13506
13507
13508 gl_gettimeofday_timezone=void
13509 if test $ac_cv_func_gettimeofday != yes; then
13510 HAVE_GETTIMEOFDAY=0
13511 else
13512
13513
13514
13515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
13516$as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
13517if test "${gl_cv_func_gettimeofday_clobber+set}" = set; then :
13518 $as_echo_n "(cached) " >&6
13519else
13520 if test "$cross_compiling" = yes; then :
13521 # When cross-compiling:
13522 case "$host_os" in
13523 # Guess all is fine on glibc systems.
13524 *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
13525 # If we don't know, assume the worst.
13526 *) gl_cv_func_gettimeofday_clobber="guessing yes" ;;
13527 esac
13528
13529else
13530 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13531/* end confdefs.h. */
13532#include <string.h>
13533 #include <sys/time.h>
13534 #include <time.h>
13535 #include <stdlib.h>
13536
13537int
13538main ()
13539{
13540
13541 time_t t = 0;
13542 struct tm *lt;
13543 struct tm saved_lt;
13544 struct timeval tv;
13545 lt = localtime (&t);
13546 saved_lt = *lt;
13547 gettimeofday (&tv, NULL);
13548 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
13549
13550 ;
13551 return 0;
13552}
13553_ACEOF
13554if ac_fn_c_try_run "$LINENO"; then :
13555 gl_cv_func_gettimeofday_clobber=no
13556else
13557 gl_cv_func_gettimeofday_clobber=yes
13558fi
13559rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13560 conftest.$ac_objext conftest.beam conftest.$ac_ext
13561fi
13562
13563fi
13564{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
13565$as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
13566
13567 case "$gl_cv_func_gettimeofday_clobber" in
13568 *yes)
13569 REPLACE_GETTIMEOFDAY=1
13570
13571 REPLACE_GMTIME=1
13572 REPLACE_LOCALTIME=1
13573
13574
13575$as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
13576
13577 ;;
13578 esac
13579
13580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
13581$as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
13582if test "${gl_cv_func_gettimeofday_posix_signature+set}" = set; then :
13583 $as_echo_n "(cached) " >&6
13584else
13585 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13586/* end confdefs.h. */
13587#include <sys/time.h>
13588 struct timeval c;
13589 int gettimeofday (struct timeval *restrict, void *restrict);
13590
13591int
13592main ()
13593{
13594/* glibc uses struct timezone * rather than the POSIX void *
13595 if _GNU_SOURCE is defined. However, since the only portable
13596 use of gettimeofday uses NULL as the second parameter, and
13597 since the glibc definition is actually more typesafe, it is
13598 not worth wrapping this to get a compliant signature. */
13599 int (*f) (struct timeval *restrict, void *restrict)
13600 = gettimeofday;
13601 int x = f (&c, 0);
13602 return !(x | c.tv_sec | c.tv_usec);
13603
13604 ;
13605 return 0;
13606}
13607_ACEOF
13608if ac_fn_c_try_compile "$LINENO"; then :
13609 gl_cv_func_gettimeofday_posix_signature=yes
13610else
13611 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13612/* end confdefs.h. */
13613#include <sys/time.h>
13614int gettimeofday (struct timeval *restrict, struct timezone *restrict);
13615
13616int
13617main ()
13618{
13619
13620 ;
13621 return 0;
13622}
13623_ACEOF
13624if ac_fn_c_try_compile "$LINENO"; then :
13625 gl_cv_func_gettimeofday_posix_signature=almost
13626else
13627 gl_cv_func_gettimeofday_posix_signature=no
13628fi
13629rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13630fi
13631rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13632fi
13633{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
13634$as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
13635 if test $gl_cv_func_gettimeofday_posix_signature = almost; then
13636 gl_gettimeofday_timezone='struct timezone'
13637 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
13638 REPLACE_GETTIMEOFDAY=1
13639 fi
13640 if test $REPLACE_STRUCT_TIMEVAL = 1; then
13641 REPLACE_GETTIMEOFDAY=1
13642 fi
13643
13644 fi
13645
13646cat >>confdefs.h <<_ACEOF
13647#define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
13648_ACEOF
13649
88b48903 13650
4a626d0a 13651 if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
88b48903 13652
88b48903 13653
88b48903 13654
88b48903
WN
13655
13656
88b48903
WN
13657
13658
13659
4a626d0a 13660 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
88b48903
WN
13661
13662
4a626d0a
PA
13663 for ac_header in sys/timeb.h
13664do :
13665 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
13666if test "x$ac_cv_header_sys_timeb_h" = x""yes; then :
13667 cat >>confdefs.h <<_ACEOF
13668#define HAVE_SYS_TIMEB_H 1
13669_ACEOF
88b48903 13670
4a626d0a 13671fi
88b48903 13672
4a626d0a
PA
13673done
13674
13675 for ac_func in _ftime
13676do :
13677 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
13678if test "x$ac_cv_func__ftime" = x""yes; then :
13679 cat >>confdefs.h <<_ACEOF
13680#define HAVE__FTIME 1
13681_ACEOF
13682
13683fi
13684done
88b48903 13685
88b48903
WN
13686
13687 fi
13688
13689
13690
13691
13692
4a626d0a 13693 GNULIB_GETTIMEOFDAY=1
88b48903
WN
13694
13695
13696
13697
13698
4a626d0a 13699$as_echo "#define GNULIB_TEST_GETTIMEOFDAY 1" >>confdefs.h
88b48903
WN
13700
13701
13702
13703
13704
13705
13706
13707
13708 PRIPTR_PREFIX=
13709 if test -n "$STDINT_H"; then
13710 PRIPTR_PREFIX='"l"'
13711 else
13712 for glpfx in '' l ll I64; do
13713 case $glpfx in
13714 '') gltype1='int';;
13715 l) gltype1='long int';;
13716 ll) gltype1='long long int';;
13717 I64) gltype1='__int64';;
13718 esac
13719 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13720/* end confdefs.h. */
13721#include <stdint.h>
13722 extern intptr_t foo;
13723 extern $gltype1 foo;
13724int
13725main ()
13726{
13727
13728 ;
13729 return 0;
13730}
13731_ACEOF
13732if ac_fn_c_try_compile "$LINENO"; then :
13733 PRIPTR_PREFIX='"'$glpfx'"'
13734fi
13735rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13736 test -n "$PRIPTR_PREFIX" && break
13737 done
13738 fi
13739
13740
13741
13742 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether INT32_MAX < INTMAX_MAX" >&5
13743$as_echo_n "checking whether INT32_MAX < INTMAX_MAX... " >&6; }
13744if test "${gl_cv_test_INT32_MAX_LT_INTMAX_MAX+set}" = set; then :
13745 $as_echo_n "(cached) " >&6
13746else
13747 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13748/* end confdefs.h. */
13749/* Work also in C++ mode. */
13750 #define __STDC_LIMIT_MACROS 1
13751
13752 /* Work if build is not clean. */
13753 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
13754
13755 #include <limits.h>
13756 #if HAVE_STDINT_H
13757 #include <stdint.h>
13758 #endif
13759
13760 #if defined INT32_MAX && defined INTMAX_MAX
13761 #define CONDITION (INT32_MAX < INTMAX_MAX)
13762 #elif HAVE_LONG_LONG_INT
13763 #define CONDITION (sizeof (int) < sizeof (long long int))
13764 #else
13765 #define CONDITION 0
13766 #endif
13767 int test[CONDITION ? 1 : -1];
13768int
13769main ()
13770{
13771
13772 ;
13773 return 0;
13774}
13775_ACEOF
13776if ac_fn_c_try_compile "$LINENO"; then :
13777 gl_cv_test_INT32_MAX_LT_INTMAX_MAX=yes
13778else
13779 gl_cv_test_INT32_MAX_LT_INTMAX_MAX=no
13780fi
13781rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13782fi
13783{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_INT32_MAX_LT_INTMAX_MAX" >&5
13784$as_echo "$gl_cv_test_INT32_MAX_LT_INTMAX_MAX" >&6; }
13785 if test $gl_cv_test_INT32_MAX_LT_INTMAX_MAX = yes; then
13786 INT32_MAX_LT_INTMAX_MAX=1;
13787 else
13788 INT32_MAX_LT_INTMAX_MAX=0;
13789 fi
13790
13791
13792 if test $APPLE_UNIVERSAL_BUILD = 0; then
13793
13794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether INT64_MAX == LONG_MAX" >&5
13795$as_echo_n "checking whether INT64_MAX == LONG_MAX... " >&6; }
13796if test "${gl_cv_test_INT64_MAX_EQ_LONG_MAX+set}" = set; then :
13797 $as_echo_n "(cached) " >&6
13798else
13799 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13800/* end confdefs.h. */
13801/* Work also in C++ mode. */
13802 #define __STDC_LIMIT_MACROS 1
13803
13804 /* Work if build is not clean. */
13805 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
13806
13807 #include <limits.h>
13808 #if HAVE_STDINT_H
13809 #include <stdint.h>
13810 #endif
13811
13812 #if defined INT64_MAX
13813 #define CONDITION (INT64_MAX == LONG_MAX)
13814 #elif HAVE_LONG_LONG_INT
13815 #define CONDITION (sizeof (long long int) == sizeof (long int))
13816 #else
13817 #define CONDITION 0
13818 #endif
13819 int test[CONDITION ? 1 : -1];
13820int
13821main ()
13822{
13823
13824 ;
13825 return 0;
13826}
13827_ACEOF
13828if ac_fn_c_try_compile "$LINENO"; then :
13829 gl_cv_test_INT64_MAX_EQ_LONG_MAX=yes
13830else
13831 gl_cv_test_INT64_MAX_EQ_LONG_MAX=no
13832fi
13833rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13834fi
13835{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_INT64_MAX_EQ_LONG_MAX" >&5
13836$as_echo "$gl_cv_test_INT64_MAX_EQ_LONG_MAX" >&6; }
13837 if test $gl_cv_test_INT64_MAX_EQ_LONG_MAX = yes; then
13838 INT64_MAX_EQ_LONG_MAX=1;
13839 else
13840 INT64_MAX_EQ_LONG_MAX=0;
13841 fi
13842
13843
13844 else
13845 INT64_MAX_EQ_LONG_MAX=-1
13846 fi
13847
13848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether UINT32_MAX < UINTMAX_MAX" >&5
13849$as_echo_n "checking whether UINT32_MAX < UINTMAX_MAX... " >&6; }
13850if test "${gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX+set}" = set; then :
13851 $as_echo_n "(cached) " >&6
13852else
13853 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13854/* end confdefs.h. */
13855/* Work also in C++ mode. */
13856 #define __STDC_LIMIT_MACROS 1
13857
13858 /* Work if build is not clean. */
13859 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
13860
13861 #include <limits.h>
13862 #if HAVE_STDINT_H
13863 #include <stdint.h>
13864 #endif
13865
13866 #if defined UINT32_MAX && defined UINTMAX_MAX
13867 #define CONDITION (UINT32_MAX < UINTMAX_MAX)
13868 #elif HAVE_LONG_LONG_INT
13869 #define CONDITION (sizeof (unsigned int) < sizeof (unsigned long long int))
13870 #else
13871 #define CONDITION 0
13872 #endif
13873 int test[CONDITION ? 1 : -1];
13874int
13875main ()
13876{
13877
13878 ;
13879 return 0;
13880}
13881_ACEOF
13882if ac_fn_c_try_compile "$LINENO"; then :
13883 gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX=yes
13884else
13885 gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX=no
13886fi
13887rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13888fi
13889{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX" >&5
13890$as_echo "$gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX" >&6; }
13891 if test $gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX = yes; then
13892 UINT32_MAX_LT_UINTMAX_MAX=1;
13893 else
13894 UINT32_MAX_LT_UINTMAX_MAX=0;
13895 fi
13896
13897
13898 if test $APPLE_UNIVERSAL_BUILD = 0; then
13899
13900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether UINT64_MAX == ULONG_MAX" >&5
13901$as_echo_n "checking whether UINT64_MAX == ULONG_MAX... " >&6; }
13902if test "${gl_cv_test_UINT64_MAX_EQ_ULONG_MAX+set}" = set; then :
13903 $as_echo_n "(cached) " >&6
13904else
13905 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13906/* end confdefs.h. */
13907/* Work also in C++ mode. */
13908 #define __STDC_LIMIT_MACROS 1
13909
13910 /* Work if build is not clean. */
13911 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
13912
13913 #include <limits.h>
13914 #if HAVE_STDINT_H
13915 #include <stdint.h>
13916 #endif
13917
13918 #if defined UINT64_MAX
13919 #define CONDITION (UINT64_MAX == ULONG_MAX)
13920 #elif HAVE_LONG_LONG_INT
13921 #define CONDITION (sizeof (unsigned long long int) == sizeof (unsigned long int))
13922 #else
13923 #define CONDITION 0
13924 #endif
13925 int test[CONDITION ? 1 : -1];
13926int
13927main ()
13928{
13929
13930 ;
13931 return 0;
13932}
13933_ACEOF
13934if ac_fn_c_try_compile "$LINENO"; then :
13935 gl_cv_test_UINT64_MAX_EQ_ULONG_MAX=yes
13936else
13937 gl_cv_test_UINT64_MAX_EQ_ULONG_MAX=no
13938fi
13939rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13940fi
13941{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_UINT64_MAX_EQ_ULONG_MAX" >&5
13942$as_echo "$gl_cv_test_UINT64_MAX_EQ_ULONG_MAX" >&6; }
13943 if test $gl_cv_test_UINT64_MAX_EQ_ULONG_MAX = yes; then
13944 UINT64_MAX_EQ_ULONG_MAX=1;
13945 else
13946 UINT64_MAX_EQ_ULONG_MAX=0;
13947 fi
13948
13949
13950 else
13951 UINT64_MAX_EQ_ULONG_MAX=-1
13952 fi
13953
13954
13955
13956
13957
13958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnan(double) can be used without linking with libm" >&5
13959$as_echo_n "checking whether isnan(double) can be used without linking with libm... " >&6; }
13960if test "${gl_cv_func_isnand_no_libm+set}" = set; then :
13961 $as_echo_n "(cached) " >&6
13962else
13963
13964 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13965/* end confdefs.h. */
13966#include <math.h>
13967 #if __GNUC__ >= 4
13968 # undef isnand
13969 # define isnand(x) __builtin_isnan ((double)(x))
13970 #else
13971 # undef isnand
13972 # define isnand(x) isnan ((double)(x))
13973 #endif
13974 double x;
13975int
13976main ()
13977{
13978return isnand (x);
13979 ;
13980 return 0;
13981}
13982_ACEOF
13983if ac_fn_c_try_link "$LINENO"; then :
13984 gl_cv_func_isnand_no_libm=yes
13985else
13986 gl_cv_func_isnand_no_libm=no
13987fi
13988rm -f core conftest.err conftest.$ac_objext \
13989 conftest$ac_exeext conftest.$ac_ext
13990
13991fi
13992{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnand_no_libm" >&5
13993$as_echo "$gl_cv_func_isnand_no_libm" >&6; }
13994
13995 gl_func_isnand_no_libm=$gl_cv_func_isnand_no_libm
13996 if test $gl_cv_func_isnand_no_libm = yes; then
13997
13998$as_echo "#define HAVE_ISNAND_IN_LIBC 1" >>confdefs.h
13999
14000 fi
14001
14002 if test $gl_func_isnand_no_libm != yes; then
14003
14004
14005
14006
14007
14008
14009
14010
14011 gl_LIBOBJS="$gl_LIBOBJS isnand.$ac_objext"
14012
14013
14014
14015
14016 fi
14017
14018
14019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnan(long double) can be used without linking with libm" >&5
14020$as_echo_n "checking whether isnan(long double) can be used without linking with libm... " >&6; }
14021if test "${gl_cv_func_isnanl_no_libm+set}" = set; then :
14022 $as_echo_n "(cached) " >&6
14023else
14024
14025 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14026/* end confdefs.h. */
14027#include <math.h>
14028 #if __GNUC__ >= 4
14029 # undef isnanl
14030 # define isnanl(x) __builtin_isnanl ((long double)(x))
14031 #elif defined isnan
14032 # undef isnanl
14033 # define isnanl(x) isnan ((long double)(x))
14034 #endif
14035 long double x;
14036int
14037main ()
14038{
14039return isnanl (x);
14040 ;
14041 return 0;
14042}
14043_ACEOF
14044if ac_fn_c_try_link "$LINENO"; then :
14045 gl_cv_func_isnanl_no_libm=yes
14046else
14047 gl_cv_func_isnanl_no_libm=no
14048fi
14049rm -f core conftest.err conftest.$ac_objext \
14050 conftest$ac_exeext conftest.$ac_ext
14051
14052fi
14053{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnanl_no_libm" >&5
14054$as_echo "$gl_cv_func_isnanl_no_libm" >&6; }
14055
14056 gl_func_isnanl_no_libm=$gl_cv_func_isnanl_no_libm
14057 if test $gl_func_isnanl_no_libm = yes; then
14058
14059
14060
14061
14062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnanl works" >&5
14063$as_echo_n "checking whether isnanl works... " >&6; }
14064if test "${gl_cv_func_isnanl_works+set}" = set; then :
14065 $as_echo_n "(cached) " >&6
14066else
14067
14068 if test "$cross_compiling" = yes; then :
4a626d0a 14069 gl_cv_func_isnanl_works="guessing yes"
88b48903
WN
14070else
14071 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14072/* end confdefs.h. */
14073
14074#include <float.h>
14075#include <limits.h>
14076#include <math.h>
14077#if __GNUC__ >= 4
14078# undef isnanl
14079# define isnanl(x) __builtin_isnanl ((long double)(x))
14080#elif defined isnan
14081# undef isnanl
14082# define isnanl(x) isnan ((long double)(x))
14083#endif
14084#define NWORDS \
14085 ((sizeof (long double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
14086typedef union { unsigned int word[NWORDS]; long double value; }
14087 memory_long_double;
14088/* On Irix 6.5, gcc 3.4.3 can't compute compile-time NaN, and needs the
14089 runtime type conversion. */
14090#ifdef __sgi
14091static long double NaNl ()
14092{
14093 double zero = 0.0;
14094 return zero / zero;
14095}
14096#else
14097# define NaNl() (0.0L / 0.0L)
14098#endif
14099int main ()
14100{
14101 int result = 0;
14102
14103 if (!isnanl (NaNl ()))
14104 result |= 1;
14105
14106 {
14107 memory_long_double m;
14108 unsigned int i;
14109
14110 /* The isnanl function should be immune against changes in the sign bit and
14111 in the mantissa bits. The xor operation twiddles a bit that can only be
14112 a sign bit or a mantissa bit (since the exponent never extends to
14113 bit 31). */
14114 m.value = NaNl ();
14115 m.word[NWORDS / 2] ^= (unsigned int) 1 << (sizeof (unsigned int) * CHAR_BIT - 1);
14116 for (i = 0; i < NWORDS; i++)
14117 m.word[i] |= 1;
14118 if (!isnanl (m.value))
14119 result |= 1;
14120 }
14121
14122#if ((defined __ia64 && LDBL_MANT_DIG == 64) || (defined __x86_64__ || defined __amd64__) || (defined __i386 || defined __i386__ || defined _I386 || defined _M_IX86 || defined _X86_)) && !HAVE_SAME_LONG_DOUBLE_AS_DOUBLE
14123/* Representation of an 80-bit 'long double' as an initializer for a sequence
14124 of 'unsigned int' words. */
14125# ifdef WORDS_BIGENDIAN
14126# define LDBL80_WORDS(exponent,manthi,mantlo) \
14127 { ((unsigned int) (exponent) << 16) | ((unsigned int) (manthi) >> 16), \
4a626d0a 14128 ((unsigned int) (manthi) << 16) | ((unsigned int) (mantlo) >> 16), \
88b48903
WN
14129 (unsigned int) (mantlo) << 16 \
14130 }
14131# else
14132# define LDBL80_WORDS(exponent,manthi,mantlo) \
14133 { mantlo, manthi, exponent }
14134# endif
14135 { /* Quiet NaN. */
14136 static memory_long_double x =
14137 { LDBL80_WORDS (0xFFFF, 0xC3333333, 0x00000000) };
14138 if (!isnanl (x.value))
14139 result |= 2;
14140 }
14141 {
14142 /* Signalling NaN. */
14143 static memory_long_double x =
14144 { LDBL80_WORDS (0xFFFF, 0x83333333, 0x00000000) };
14145 if (!isnanl (x.value))
14146 result |= 2;
14147 }
4a626d0a 14148 /* isnanl should return something even for noncanonical values. */
88b48903
WN
14149 { /* Pseudo-NaN. */
14150 static memory_long_double x =
14151 { LDBL80_WORDS (0xFFFF, 0x40000001, 0x00000000) };
4a626d0a 14152 if (isnanl (x.value) && !isnanl (x.value))
88b48903
WN
14153 result |= 4;
14154 }
14155 { /* Pseudo-Infinity. */
14156 static memory_long_double x =
14157 { LDBL80_WORDS (0xFFFF, 0x00000000, 0x00000000) };
4a626d0a 14158 if (isnanl (x.value) && !isnanl (x.value))
88b48903
WN
14159 result |= 8;
14160 }
14161 { /* Pseudo-Zero. */
14162 static memory_long_double x =
14163 { LDBL80_WORDS (0x4004, 0x00000000, 0x00000000) };
4a626d0a 14164 if (isnanl (x.value) && !isnanl (x.value))
88b48903
WN
14165 result |= 16;
14166 }
14167 { /* Unnormalized number. */
14168 static memory_long_double x =
14169 { LDBL80_WORDS (0x4000, 0x63333333, 0x00000000) };
4a626d0a 14170 if (isnanl (x.value) && !isnanl (x.value))
88b48903
WN
14171 result |= 32;
14172 }
14173 { /* Pseudo-Denormal. */
14174 static memory_long_double x =
14175 { LDBL80_WORDS (0x0000, 0x83333333, 0x00000000) };
4a626d0a 14176 if (isnanl (x.value) && !isnanl (x.value))
88b48903
WN
14177 result |= 64;
14178 }
14179#endif
14180
14181 return result;
14182}
14183_ACEOF
14184if ac_fn_c_try_run "$LINENO"; then :
14185 gl_cv_func_isnanl_works=yes
14186else
14187 gl_cv_func_isnanl_works=no
14188fi
14189rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14190 conftest.$ac_objext conftest.beam conftest.$ac_ext
14191fi
14192
14193
14194fi
14195{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnanl_works" >&5
14196$as_echo "$gl_cv_func_isnanl_works" >&6; }
14197
14198 case "$gl_cv_func_isnanl_works" in
14199 *yes) ;;
14200 *) gl_func_isnanl_no_libm=no ;;
14201 esac
14202 fi
14203 if test $gl_func_isnanl_no_libm = yes; then
14204
14205$as_echo "#define HAVE_ISNANL_IN_LIBC 1" >>confdefs.h
14206
14207 fi
14208
14209 if test $gl_func_isnanl_no_libm != yes; then
14210
14211
14212
14213
14214
14215
14216
14217
14218 gl_LIBOBJS="$gl_LIBOBJS isnanl.$ac_objext"
14219
14220
14221
14222
14223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'long double'" >&5
14224$as_echo_n "checking where to find the exponent in a 'long double'... " >&6; }
14225if test "${gl_cv_cc_long_double_expbit0+set}" = set; then :
14226 $as_echo_n "(cached) " >&6
14227else
14228
14229 if test "$cross_compiling" = yes; then :
14230
14231 gl_cv_cc_long_double_expbit0="unknown"
14232
14233else
14234 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14235/* end confdefs.h. */
14236
14237#include <float.h>
14238#include <stddef.h>
14239#include <stdio.h>
14240#include <string.h>
14241#define NWORDS \
14242 ((sizeof (long double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
14243typedef union { long double value; unsigned int word[NWORDS]; }
14244 memory_long_double;
14245static unsigned int ored_words[NWORDS];
14246static unsigned int anded_words[NWORDS];
14247static void add_to_ored_words (long double x)
14248{
14249 memory_long_double m;
14250 size_t i;
14251 /* Clear it first, in case
14252 sizeof (long double) < sizeof (memory_long_double). */
14253 memset (&m, 0, sizeof (memory_long_double));
14254 m.value = x;
14255 for (i = 0; i < NWORDS; i++)
14256 {
14257 ored_words[i] |= m.word[i];
14258 anded_words[i] &= m.word[i];
14259 }
14260}
14261int main ()
14262{
14263 size_t j;
14264 FILE *fp = fopen ("conftest.out", "w");
14265 if (fp == NULL)
14266 return 1;
14267 for (j = 0; j < NWORDS; j++)
14268 anded_words[j] = ~ (unsigned int) 0;
14269 add_to_ored_words (0.25L);
14270 add_to_ored_words (0.5L);
14271 add_to_ored_words (1.0L);
14272 add_to_ored_words (2.0L);
14273 add_to_ored_words (4.0L);
14274 /* Remove bits that are common (e.g. if representation of the first mantissa
14275 bit is explicit). */
14276 for (j = 0; j < NWORDS; j++)
14277 ored_words[j] &= ~anded_words[j];
14278 /* Now find the nonzero word. */
14279 for (j = 0; j < NWORDS; j++)
14280 if (ored_words[j] != 0)
14281 break;
14282 if (j < NWORDS)
14283 {
14284 size_t i;
14285 for (i = j + 1; i < NWORDS; i++)
14286 if (ored_words[i] != 0)
14287 {
14288 fprintf (fp, "unknown");
14289 return (fclose (fp) != 0);
14290 }
14291 for (i = 0; ; i++)
14292 if ((ored_words[j] >> i) & 1)
14293 {
14294 fprintf (fp, "word %d bit %d", (int) j, (int) i);
14295 return (fclose (fp) != 0);
14296 }
14297 }
14298 fprintf (fp, "unknown");
14299 return (fclose (fp) != 0);
14300}
14301
14302_ACEOF
14303if ac_fn_c_try_run "$LINENO"; then :
14304 gl_cv_cc_long_double_expbit0=`cat conftest.out`
14305else
14306 gl_cv_cc_long_double_expbit0="unknown"
14307fi
14308rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14309 conftest.$ac_objext conftest.beam conftest.$ac_ext
14310fi
14311
14312 rm -f conftest.out
14313
14314fi
14315{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_long_double_expbit0" >&5
14316$as_echo "$gl_cv_cc_long_double_expbit0" >&6; }
14317 case "$gl_cv_cc_long_double_expbit0" in
14318 word*bit*)
14319 word=`echo "$gl_cv_cc_long_double_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
14320 bit=`echo "$gl_cv_cc_long_double_expbit0" | sed -e 's/word.*bit //'`
14321
14322cat >>confdefs.h <<_ACEOF
14323#define LDBL_EXPBIT0_WORD $word
14324_ACEOF
14325
14326
14327cat >>confdefs.h <<_ACEOF
14328#define LDBL_EXPBIT0_BIT $bit
14329_ACEOF
14330
14331 ;;
14332 esac
14333
14334
14335
14336 fi
14337
14338
14339
14340
88b48903
WN
14341
14342
14343
14344
2196f55f 14345
88b48903
WN
14346 LOCALCHARSET_TESTS_ENVIRONMENT="CHARSETALIASDIR=\"\$(abs_top_builddir)/$gl_source_base\""
14347
14348
14349
14350
f45c62c4
YQ
14351 if test $ac_cv_func_lstat = yes; then
14352
14353 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
14354 *no)
14355 REPLACE_LSTAT=1
14356 ;;
14357 esac
14358 else
14359 HAVE_LSTAT=0
14360 fi
14361
14362 if test $REPLACE_LSTAT = 1; then
14363
14364
14365
14366
14367
14368
14369
14370
14371 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
14372
14373 :
14374 fi
14375
14376
14377
14378
14379
14380 GNULIB_LSTAT=1
14381
14382
14383
14384
14385
14386$as_echo "#define GNULIB_TEST_LSTAT 1" >>confdefs.h
14387
14388
14389
14390
14391
14392
6a29c58e
YQ
14393 if test $gl_cv_func_malloc_posix = yes; then
14394
14395$as_echo "#define HAVE_MALLOC_POSIX 1" >>confdefs.h
14396
14397 else
14398 REPLACE_MALLOC=1
14399 fi
14400
14401 if test $REPLACE_MALLOC = 1; then
14402
14403
14404
14405
14406
14407
14408
14409
14410 gl_LIBOBJS="$gl_LIBOBJS malloc.$ac_objext"
14411
14412 fi
14413
14414
14415
14416
14417
14418 GNULIB_MALLOC_POSIX=1
14419
14420
14421
14422
14423
14424$as_echo "#define GNULIB_TEST_MALLOC_POSIX 1" >>confdefs.h
14425
14426
14427
14428
14429
14430
88b48903
WN
14431
14432
14433
14434
14435
88b48903 14436
c971b7fa 14437
c971b7fa 14438
98399780
YQ
14439
14440
14441
14442
88b48903
WN
14443 if test $gl_cv_have_include_next = yes; then
14444 gl_cv_next_math_h='<'math.h'>'
14445 else
14446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <math.h>" >&5
14447$as_echo_n "checking absolute name of <math.h>... " >&6; }
14448if test "${gl_cv_next_math_h+set}" = set; then :
14449 $as_echo_n "(cached) " >&6
14450else
c971b7fa 14451
88b48903 14452 if test $ac_cv_header_math_h = yes; then
c971b7fa
PA
14453
14454
4a626d0a
PA
14455
14456
14457 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8690e634 14458/* end confdefs.h. */
88b48903 14459#include <math.h>
8690e634 14460_ACEOF
4a626d0a
PA
14461 case "$host_os" in
14462 aix*) gl_absname_cpp="$ac_cpp -C" ;;
14463 *) gl_absname_cpp="$ac_cpp" ;;
14464 esac
14465
14466 case "$host_os" in
14467 mingw*)
14468 gl_dirsep_regex='[/\\]'
14469 ;;
14470 *)
14471 gl_dirsep_regex='\/'
14472 ;;
14473 esac
14474 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
14475 gl_header_literal_regex=`echo 'math.h' \
14476 | sed -e "$gl_make_literal_regex_sed"`
14477 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
14478 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
14479 s|^/[^/]|//&|
14480 p
14481 q
14482 }'
14483
14484 gl_cv_absolute_math_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
14485 sed -n "$gl_absolute_header_sed"`
14486
14487 gl_header=$gl_cv_absolute_math_h
14488 gl_cv_next_math_h='"'$gl_header'"'
88b48903
WN
14489 else
14490 gl_cv_next_math_h='<'math.h'>'
14491 fi
8690e634 14492
c971b7fa 14493
88b48903
WN
14494fi
14495{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_math_h" >&5
14496$as_echo "$gl_cv_next_math_h" >&6; }
14497 fi
14498 NEXT_MATH_H=$gl_cv_next_math_h
c971b7fa 14499
88b48903
WN
14500 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
14501 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
14502 gl_next_as_first_directive='<'math.h'>'
14503 else
14504 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
14505 gl_next_as_first_directive=$gl_cv_next_math_h
14506 fi
14507 NEXT_AS_FIRST_DIRECTIVE_MATH_H=$gl_next_as_first_directive
8690e634 14508
c971b7fa 14509
c971b7fa
PA
14510
14511
c971b7fa 14512
88b48903
WN
14513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NAN macro works" >&5
14514$as_echo_n "checking whether NAN macro works... " >&6; }
14515if test "${gl_cv_header_math_nan_works+set}" = set; then :
c971b7fa
PA
14516 $as_echo_n "(cached) " >&6
14517else
8690e634
JK
14518 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14519/* end confdefs.h. */
88b48903 14520#include <math.h>
c971b7fa
PA
14521int
14522main ()
14523{
88b48903
WN
14524/* Solaris 10 has a broken definition of NAN. Other platforms
14525 fail to provide NAN, or provide it only in C99 mode; this
14526 test only needs to fail when NAN is provided but wrong. */
14527 float f = 1.0f;
14528#ifdef NAN
14529 f = NAN;
14530#endif
14531 return f == 0;
c971b7fa
PA
14532 ;
14533 return 0;
14534}
14535_ACEOF
14536if ac_fn_c_try_compile "$LINENO"; then :
88b48903 14537 gl_cv_header_math_nan_works=yes
8690e634 14538else
88b48903 14539 gl_cv_header_math_nan_works=no
c971b7fa
PA
14540fi
14541rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c971b7fa 14542fi
88b48903
WN
14543{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_math_nan_works" >&5
14544$as_echo "$gl_cv_header_math_nan_works" >&6; }
14545 if test $gl_cv_header_math_nan_works = no; then
14546 REPLACE_NAN=1
c971b7fa 14547 fi
88b48903
WN
14548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether HUGE_VAL works" >&5
14549$as_echo_n "checking whether HUGE_VAL works... " >&6; }
14550if test "${gl_cv_header_math_huge_val_works+set}" = set; then :
c971b7fa
PA
14551 $as_echo_n "(cached) " >&6
14552else
8690e634 14553 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
c971b7fa 14554/* end confdefs.h. */
88b48903 14555#include <math.h>
c971b7fa
PA
14556int
14557main ()
14558{
88b48903
WN
14559/* Solaris 10 has a broken definition of HUGE_VAL. */
14560 double d = HUGE_VAL;
14561 return d == 0;
c971b7fa
PA
14562 ;
14563 return 0;
14564}
14565_ACEOF
14566if ac_fn_c_try_compile "$LINENO"; then :
88b48903 14567 gl_cv_header_math_huge_val_works=yes
8690e634 14568else
88b48903 14569 gl_cv_header_math_huge_val_works=no
c971b7fa
PA
14570fi
14571rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c971b7fa 14572fi
88b48903
WN
14573{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_math_huge_val_works" >&5
14574$as_echo "$gl_cv_header_math_huge_val_works" >&6; }
14575 if test $gl_cv_header_math_huge_val_works = no; then
14576 REPLACE_HUGE_VAL=1
8690e634 14577 fi
c971b7fa 14578
c971b7fa 14579
88b48903
WN
14580 for gl_func in acosf acosl asinf asinl atanf atanl cbrt cbrtf cbrtl ceilf ceill copysign copysignf copysignl cosf cosl coshf expf expl exp2 exp2f exp2l expm1 expm1f expm1l fabsf fabsl floorf floorl fma fmaf fmal fmod fmodf fmodl frexpf frexpl hypotf hypotl ilogb ilogbf ilogbl ldexpf ldexpl log logf logl log10 log10f log10l log1p log1pf log1pl log2 log2f log2l logb logbf logbl modf modff modfl powf remainder remainderf remainderl rint rintf rintl round roundf roundl sinf sinl sinhf sqrtf sqrtl tanf tanl tanhf trunc truncf truncl; do
14581 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
14582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
14583$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
14584if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
8690e634
JK
14585 $as_echo_n "(cached) " >&6
14586else
14587 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14588/* end confdefs.h. */
88b48903 14589#include <math.h>
8690e634
JK
14590int
14591main ()
14592{
88b48903
WN
14593#undef $gl_func
14594 (void) $gl_func;
8690e634
JK
14595 ;
14596 return 0;
14597}
14598_ACEOF
14599if ac_fn_c_try_compile "$LINENO"; then :
88b48903 14600 eval "$as_gl_Symbol=yes"
c971b7fa 14601else
88b48903 14602 eval "$as_gl_Symbol=no"
c971b7fa 14603fi
8690e634
JK
14604rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14605fi
88b48903
WN
14606eval ac_res=\$$as_gl_Symbol
14607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
14608$as_echo "$ac_res" >&6; }
14609 eval as_val=\$$as_gl_Symbol
14610 if test "x$as_val" = x""yes; then :
14611 cat >>confdefs.h <<_ACEOF
14612#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
14613_ACEOF
c971b7fa 14614
88b48903
WN
14615 eval ac_cv_have_decl_$gl_func=yes
14616fi
14617 done
c971b7fa
PA
14618
14619
14620
14621
14622
c971b7fa 14623
c971b7fa 14624
c971b7fa 14625
c971b7fa
PA
14626
14627
c971b7fa 14628
8690e634
JK
14629
14630 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
14631
14632
14633
14634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
14635$as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
14636if test "${gl_cv_func_mbrtowc_incomplete_state+set}" = set; then :
c971b7fa
PA
14637 $as_echo_n "(cached) " >&6
14638else
8690e634
JK
14639
14640 case "$host_os" in
14641 # Guess no on AIX and OSF/1.
14642 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
14643 # Guess yes otherwise.
14644 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
14645 esac
14646 if test $LOCALE_JA != none; then
14647 if test "$cross_compiling" = yes; then :
14648 :
14649else
c971b7fa
PA
14650 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14651/* end confdefs.h. */
c971b7fa 14652
8690e634
JK
14653#include <locale.h>
14654#include <string.h>
14655/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
14656 <wchar.h>.
14657 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
14658 included before <wchar.h>. */
14659#include <stddef.h>
14660#include <stdio.h>
14661#include <time.h>
14662#include <wchar.h>
14663int main ()
c971b7fa 14664{
8690e634
JK
14665 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
14666 {
14667 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
14668 mbstate_t state;
14669 wchar_t wc;
14670
14671 memset (&state, '\0', sizeof (mbstate_t));
14672 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
14673 if (mbsinit (&state))
14674 return 1;
14675 }
c971b7fa
PA
14676 return 0;
14677}
14678_ACEOF
8690e634
JK
14679if ac_fn_c_try_run "$LINENO"; then :
14680 gl_cv_func_mbrtowc_incomplete_state=yes
c971b7fa 14681else
8690e634 14682 gl_cv_func_mbrtowc_incomplete_state=no
c971b7fa 14683fi
8690e634
JK
14684rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14685 conftest.$ac_objext conftest.beam conftest.$ac_ext
c971b7fa 14686fi
c971b7fa 14687
8690e634 14688 fi
c971b7fa 14689
8690e634
JK
14690fi
14691{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
14692$as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
c971b7fa 14693
c971b7fa 14694
c971b7fa 14695
c971b7fa 14696
8690e634
JK
14697 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
14698$as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
14699if test "${gl_cv_func_mbrtowc_sanitycheck+set}" = set; then :
c971b7fa
PA
14700 $as_echo_n "(cached) " >&6
14701else
14702
8690e634
JK
14703 case "$host_os" in
14704 # Guess no on Solaris 8.
14705 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
14706 # Guess yes otherwise.
14707 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
14708 esac
14709 if test $LOCALE_ZH_CN != none; then
14710 if test "$cross_compiling" = yes; then :
14711 :
14712else
14713 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
c971b7fa
PA
14714/* end confdefs.h. */
14715
8690e634
JK
14716#include <locale.h>
14717#include <stdlib.h>
14718#include <string.h>
14719/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
14720 <wchar.h>.
14721 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
14722 included before <wchar.h>. */
14723#include <stddef.h>
14724#include <stdio.h>
14725#include <time.h>
14726#include <wchar.h>
14727int main ()
c971b7fa 14728{
8690e634
JK
14729 /* This fails on Solaris 8:
14730 mbrtowc returns 2, and sets wc to 0x00F0.
14731 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
14732 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
14733 {
14734 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
14735 mbstate_t state;
14736 wchar_t wc;
14737
14738 memset (&state, '\0', sizeof (mbstate_t));
14739 if (mbrtowc (&wc, input + 3, 6, &state) != 4
14740 && mbtowc (&wc, input + 3, 6) == 4)
14741 return 1;
14742 }
c971b7fa
PA
14743 return 0;
14744}
14745_ACEOF
8690e634
JK
14746if ac_fn_c_try_run "$LINENO"; then :
14747 gl_cv_func_mbrtowc_sanitycheck=yes
c971b7fa 14748else
8690e634 14749 gl_cv_func_mbrtowc_sanitycheck=no
c971b7fa 14750fi
8690e634
JK
14751rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14752 conftest.$ac_objext conftest.beam conftest.$ac_ext
c971b7fa 14753fi
c971b7fa 14754
8690e634 14755 fi
c971b7fa 14756
8690e634
JK
14757fi
14758{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
14759$as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
14760
14761 REPLACE_MBSTATE_T=0
14762 case "$gl_cv_func_mbrtowc_incomplete_state" in
14763 *yes) ;;
14764 *) REPLACE_MBSTATE_T=1 ;;
14765 esac
14766 case "$gl_cv_func_mbrtowc_sanitycheck" in
14767 *yes) ;;
14768 *) REPLACE_MBSTATE_T=1 ;;
14769 esac
c971b7fa 14770 else
8690e634 14771 REPLACE_MBSTATE_T=1
c971b7fa
PA
14772 fi
14773
14774
14775
8690e634
JK
14776 if test $ac_cv_func_mbrtowc = no; then
14777 HAVE_MBRTOWC=0
14778 ac_fn_c_check_decl "$LINENO" "mbrtowc" "ac_cv_have_decl_mbrtowc" "
14779/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
14780 <wchar.h>.
14781 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
14782 included before <wchar.h>. */
14783#include <stddef.h>
14784#include <stdio.h>
14785#include <time.h>
14786#include <wchar.h>
c971b7fa 14787
8690e634
JK
14788"
14789if test "x$ac_cv_have_decl_mbrtowc" = x""yes; then :
14790 ac_have_decl=1
14791else
14792 ac_have_decl=0
c971b7fa 14793fi
c971b7fa 14794
8690e634
JK
14795cat >>confdefs.h <<_ACEOF
14796#define HAVE_DECL_MBRTOWC $ac_have_decl
14797_ACEOF
c971b7fa 14798
8690e634
JK
14799 if test $ac_cv_have_decl_mbrtowc = yes; then
14800 REPLACE_MBRTOWC=1
14801 fi
14802 else
14803 if test $REPLACE_MBSTATE_T = 1; then
14804 REPLACE_MBRTOWC=1
14805 else
c971b7fa
PA
14806
14807
14808
8690e634
JK
14809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles a NULL pwc argument" >&5
14810$as_echo_n "checking whether mbrtowc handles a NULL pwc argument... " >&6; }
14811if test "${gl_cv_func_mbrtowc_null_arg1+set}" = set; then :
14812 $as_echo_n "(cached) " >&6
c971b7fa 14813else
c971b7fa 14814
8690e634
JK
14815 case "$host_os" in
14816 # Guess no on Solaris.
14817 solaris*) gl_cv_func_mbrtowc_null_arg1="guessing no" ;;
14818 # Guess yes otherwise.
14819 *) gl_cv_func_mbrtowc_null_arg1="guessing yes" ;;
14820 esac
14821 if test $LOCALE_FR_UTF8 != none; then
14822 if test "$cross_compiling" = yes; then :
14823 :
14824else
14825 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
c971b7fa
PA
14826/* end confdefs.h. */
14827
8690e634
JK
14828#include <locale.h>
14829#include <stdlib.h>
14830#include <string.h>
14831/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
14832 <wchar.h>.
14833 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
14834 included before <wchar.h>. */
14835#include <stddef.h>
14836#include <stdio.h>
14837#include <time.h>
14838#include <wchar.h>
14839int main ()
14840{
14841 int result = 0;
14842
14843 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
14844 {
14845 char input[] = "\303\237er";
14846 mbstate_t state;
14847 wchar_t wc;
14848 size_t ret;
14849
14850 memset (&state, '\0', sizeof (mbstate_t));
14851 wc = (wchar_t) 0xBADFACE;
14852 ret = mbrtowc (&wc, input, 5, &state);
14853 if (ret != 2)
14854 result |= 1;
14855 if (!mbsinit (&state))
14856 result |= 2;
c971b7fa 14857
8690e634
JK
14858 memset (&state, '\0', sizeof (mbstate_t));
14859 ret = mbrtowc (NULL, input, 5, &state);
14860 if (ret != 2) /* Solaris 7 fails here: ret is -1. */
14861 result |= 4;
14862 if (!mbsinit (&state))
14863 result |= 8;
14864 }
14865 return result;
14866}
c971b7fa 14867_ACEOF
8690e634
JK
14868if ac_fn_c_try_run "$LINENO"; then :
14869 gl_cv_func_mbrtowc_null_arg1=yes
14870else
14871 gl_cv_func_mbrtowc_null_arg1=no
14872fi
14873rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14874 conftest.$ac_objext conftest.beam conftest.$ac_ext
14875fi
c971b7fa 14876
8690e634 14877 fi
c971b7fa 14878
c971b7fa 14879fi
8690e634
JK
14880{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_null_arg1" >&5
14881$as_echo "$gl_cv_func_mbrtowc_null_arg1" >&6; }
c971b7fa 14882
c971b7fa 14883
c971b7fa 14884
c971b7fa 14885
8690e634
JK
14886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles a NULL string argument" >&5
14887$as_echo_n "checking whether mbrtowc handles a NULL string argument... " >&6; }
14888if test "${gl_cv_func_mbrtowc_null_arg2+set}" = set; then :
14889 $as_echo_n "(cached) " >&6
14890else
c971b7fa 14891
8690e634
JK
14892 case "$host_os" in
14893 # Guess no on OSF/1.
14894 osf*) gl_cv_func_mbrtowc_null_arg2="guessing no" ;;
14895 # Guess yes otherwise.
14896 *) gl_cv_func_mbrtowc_null_arg2="guessing yes" ;;
14897 esac
14898 if test $LOCALE_FR_UTF8 != none; then
14899 if test "$cross_compiling" = yes; then :
c971b7fa 14900 :
8690e634
JK
14901else
14902 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14903/* end confdefs.h. */
14904
14905#include <locale.h>
14906#include <string.h>
14907/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
14908 <wchar.h>.
14909 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
14910 included before <wchar.h>. */
14911#include <stddef.h>
14912#include <stdio.h>
14913#include <time.h>
14914#include <wchar.h>
14915int main ()
14916{
14917 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
14918 {
14919 mbstate_t state;
14920 wchar_t wc;
14921 int ret;
14922
14923 memset (&state, '\0', sizeof (mbstate_t));
14924 wc = (wchar_t) 0xBADFACE;
14925 mbrtowc (&wc, NULL, 5, &state);
14926 /* Check that wc was not modified. */
14927 if (wc != (wchar_t) 0xBADFACE)
14928 return 1;
14929 }
14930 return 0;
14931}
14932_ACEOF
14933if ac_fn_c_try_run "$LINENO"; then :
14934 gl_cv_func_mbrtowc_null_arg2=yes
14935else
14936 gl_cv_func_mbrtowc_null_arg2=no
14937fi
14938rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14939 conftest.$ac_objext conftest.beam conftest.$ac_ext
14940fi
14941
14942 fi
14943
14944fi
14945{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_null_arg2" >&5
14946$as_echo "$gl_cv_func_mbrtowc_null_arg2" >&6; }
c971b7fa
PA
14947
14948
14949
14950
14951
14952
8690e634
JK
14953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc has a correct return value" >&5
14954$as_echo_n "checking whether mbrtowc has a correct return value... " >&6; }
14955if test "${gl_cv_func_mbrtowc_retval+set}" = set; then :
14956 $as_echo_n "(cached) " >&6
14957else
14958
14959 case "$host_os" in
14960 # Guess no on HP-UX, Solaris, native Windows.
14961 hpux* | solaris* | mingw*) gl_cv_func_mbrtowc_retval="guessing no" ;;
14962 # Guess yes otherwise.
14963 *) gl_cv_func_mbrtowc_retval="guessing yes" ;;
14964 esac
14965 if test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none \
14966 || { case "$host_os" in mingw*) true;; *) false;; esac; }; then
14967 if test "$cross_compiling" = yes; then :
c971b7fa 14968 :
8690e634
JK
14969else
14970 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14971/* end confdefs.h. */
c971b7fa 14972
8690e634
JK
14973#include <locale.h>
14974#include <string.h>
14975/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
14976 <wchar.h>.
14977 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
14978 included before <wchar.h>. */
14979#include <stddef.h>
14980#include <stdio.h>
14981#include <time.h>
14982#include <wchar.h>
14983int main ()
14984{
14985 int result = 0;
14986 int found_some_locale = 0;
14987 /* This fails on Solaris. */
14988 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
14989 {
14990 char input[] = "B\303\274\303\237er"; /* "Büßer" */
14991 mbstate_t state;
14992 wchar_t wc;
14993
14994 memset (&state, '\0', sizeof (mbstate_t));
14995 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
14996 {
14997 input[1] = '\0';
14998 if (mbrtowc (&wc, input + 2, 5, &state) != 1)
14999 result |= 1;
15000 }
15001 found_some_locale = 1;
15002 }
15003 /* This fails on HP-UX 11.11. */
15004 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
15005 {
15006 char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
15007 mbstate_t state;
15008 wchar_t wc;
15009
15010 memset (&state, '\0', sizeof (mbstate_t));
15011 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
15012 {
15013 input[1] = '\0';
15014 if (mbrtowc (&wc, input + 2, 5, &state) != 2)
15015 result |= 2;
15016 }
15017 found_some_locale = 1;
15018 }
15019 /* This fails on native Windows. */
15020 if (setlocale (LC_ALL, "Japanese_Japan.932") != NULL)
15021 {
15022 char input[] = "<\223\372\226\173\214\352>"; /* "<日本語>" */
15023 mbstate_t state;
15024 wchar_t wc;
15025
15026 memset (&state, '\0', sizeof (mbstate_t));
15027 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
15028 {
15029 input[3] = '\0';
15030 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
15031 result |= 4;
15032 }
15033 found_some_locale = 1;
15034 }
15035 if (setlocale (LC_ALL, "Chinese_Taiwan.950") != NULL)
15036 {
15037 char input[] = "<\244\351\245\273\273\171>"; /* "<日本語>" */
15038 mbstate_t state;
15039 wchar_t wc;
15040
15041 memset (&state, '\0', sizeof (mbstate_t));
15042 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
15043 {
15044 input[3] = '\0';
15045 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
15046 result |= 8;
15047 }
15048 found_some_locale = 1;
15049 }
15050 if (setlocale (LC_ALL, "Chinese_China.936") != NULL)
15051 {
15052 char input[] = "<\310\325\261\276\325\132>"; /* "<日本語>" */
15053 mbstate_t state;
15054 wchar_t wc;
15055
15056 memset (&state, '\0', sizeof (mbstate_t));
15057 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
15058 {
15059 input[3] = '\0';
15060 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
15061 result |= 16;
15062 }
15063 found_some_locale = 1;
15064 }
15065 return (found_some_locale ? result : 77);
15066}
15067_ACEOF
15068if ac_fn_c_try_run "$LINENO"; then :
15069 gl_cv_func_mbrtowc_retval=yes
15070else
15071 if test $? != 77; then
15072 gl_cv_func_mbrtowc_retval=no
15073 fi
c971b7fa 15074
8690e634
JK
15075fi
15076rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15077 conftest.$ac_objext conftest.beam conftest.$ac_ext
15078fi
c971b7fa 15079
8690e634 15080 fi
c971b7fa 15081
8690e634
JK
15082fi
15083{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_retval" >&5
15084$as_echo "$gl_cv_func_mbrtowc_retval" >&6; }
c971b7fa
PA
15085
15086
15087
15088
8690e634
JK
15089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc returns 0 when parsing a NUL character" >&5
15090$as_echo_n "checking whether mbrtowc returns 0 when parsing a NUL character... " >&6; }
15091if test "${gl_cv_func_mbrtowc_nul_retval+set}" = set; then :
c971b7fa
PA
15092 $as_echo_n "(cached) " >&6
15093else
8690e634
JK
15094
15095 case "$host_os" in
15096 # Guess no on Solaris 8 and 9.
15097 solaris2.[89]) gl_cv_func_mbrtowc_nul_retval="guessing no" ;;
15098 # Guess yes otherwise.
15099 *) gl_cv_func_mbrtowc_nul_retval="guessing yes" ;;
15100 esac
15101 if test $LOCALE_ZH_CN != none; then
15102 if test "$cross_compiling" = yes; then :
15103 :
c971b7fa
PA
15104else
15105 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15106/* end confdefs.h. */
15107
8690e634 15108#include <locale.h>
c971b7fa 15109#include <string.h>
8690e634
JK
15110/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
15111 <wchar.h>.
15112 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15113 included before <wchar.h>. */
15114#include <stddef.h>
15115#include <stdio.h>
15116#include <time.h>
15117#include <wchar.h>
15118int main ()
c971b7fa 15119{
8690e634
JK
15120 /* This fails on Solaris 8 and 9. */
15121 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
c971b7fa 15122 {
8690e634
JK
15123 mbstate_t state;
15124 wchar_t wc;
c971b7fa 15125
8690e634
JK
15126 memset (&state, '\0', sizeof (mbstate_t));
15127 if (mbrtowc (&wc, "", 1, &state) != 0)
15128 return 1;
15129 }
c971b7fa
PA
15130 return 0;
15131}
15132_ACEOF
15133if ac_fn_c_try_run "$LINENO"; then :
8690e634 15134 gl_cv_func_mbrtowc_nul_retval=yes
c971b7fa 15135else
8690e634 15136 gl_cv_func_mbrtowc_nul_retval=no
c971b7fa
PA
15137fi
15138rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15139 conftest.$ac_objext conftest.beam conftest.$ac_ext
15140fi
15141
8690e634
JK
15142 fi
15143
c971b7fa 15144fi
8690e634
JK
15145{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_nul_retval" >&5
15146$as_echo "$gl_cv_func_mbrtowc_nul_retval" >&6; }
15147
4a626d0a
PA
15148
15149
15150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works on empty input" >&5
15151$as_echo_n "checking whether mbrtowc works on empty input... " >&6; }
15152if test "${gl_cv_func_mbrtowc_empty_input+set}" = set; then :
15153 $as_echo_n "(cached) " >&6
15154else
15155
15156 case "$host_os" in
15157 # Guess no on AIX and glibc systems.
15158 aix* | *-gnu*)
15159 gl_cv_func_mbrtowc_empty_input="guessing no" ;;
15160 *) gl_cv_func_mbrtowc_empty_input="guessing yes" ;;
15161 esac
15162 if test "$cross_compiling" = yes; then :
15163 :
15164else
15165 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15166/* end confdefs.h. */
15167
15168 #include <wchar.h>
15169 static wchar_t wc;
15170 static mbstate_t mbs;
15171 int
15172 main (void)
15173 {
15174 return mbrtowc (&wc, "", 0, &mbs) == (size_t) -2;
15175 }
15176_ACEOF
15177if ac_fn_c_try_run "$LINENO"; then :
15178 gl_cv_func_mbrtowc_empty_input=no
15179else
15180 gl_cv_func_mbrtowc_empty_input=yes
15181fi
15182rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15183 conftest.$ac_objext conftest.beam conftest.$ac_ext
15184fi
15185
15186
15187fi
15188{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_empty_input" >&5
15189$as_echo "$gl_cv_func_mbrtowc_empty_input" >&6; }
15190
8690e634
JK
15191 case "$gl_cv_func_mbrtowc_null_arg1" in
15192 *yes) ;;
15193 *)
15194$as_echo "#define MBRTOWC_NULL_ARG1_BUG 1" >>confdefs.h
15195
15196 REPLACE_MBRTOWC=1
15197 ;;
15198 esac
15199 case "$gl_cv_func_mbrtowc_null_arg2" in
15200 *yes) ;;
15201 *)
15202$as_echo "#define MBRTOWC_NULL_ARG2_BUG 1" >>confdefs.h
15203
15204 REPLACE_MBRTOWC=1
15205 ;;
15206 esac
15207 case "$gl_cv_func_mbrtowc_retval" in
15208 *yes) ;;
15209 *)
15210$as_echo "#define MBRTOWC_RETVAL_BUG 1" >>confdefs.h
15211
15212 REPLACE_MBRTOWC=1
15213 ;;
15214 esac
15215 case "$gl_cv_func_mbrtowc_nul_retval" in
15216 *yes) ;;
15217 *)
15218$as_echo "#define MBRTOWC_NUL_RETVAL_BUG 1" >>confdefs.h
15219
4a626d0a
PA
15220 REPLACE_MBRTOWC=1
15221 ;;
15222 esac
15223 case "$gl_cv_func_mbrtowc_empty_input" in
15224 *yes) ;;
15225 *)
15226$as_echo "#define MBRTOWC_EMPTY_INPUT_BUG 1" >>confdefs.h
15227
8690e634
JK
15228 REPLACE_MBRTOWC=1
15229 ;;
15230 esac
c971b7fa
PA
15231 fi
15232 fi
15233
a512b375 15234 if test $HAVE_MBRTOWC = 0 || test $REPLACE_MBRTOWC = 1; then
c971b7fa 15235
c971b7fa 15236
c971b7fa
PA
15237
15238
15239
15240
15241
15242
8690e634
JK
15243 gl_LIBOBJS="$gl_LIBOBJS mbrtowc.$ac_objext"
15244
15245
15246 :
c971b7fa 15247
a512b375 15248 fi
c971b7fa 15249
8690e634
JK
15250
15251
15252
15253
15254 GNULIB_MBRTOWC=1
15255
15256
15257
15258
15259
15260$as_echo "#define GNULIB_TEST_MBRTOWC 1" >>confdefs.h
15261
15262
15263
15264
15265
15266
15267
15268
15269
15270
15271
15272
c971b7fa 15273
c971b7fa 15274
8690e634 15275 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
c971b7fa 15276
8690e634
JK
15277
15278
15279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
15280$as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
15281if test "${gl_cv_func_mbrtowc_incomplete_state+set}" = set; then :
15282 $as_echo_n "(cached) " >&6
15283else
15284
15285 case "$host_os" in
15286 # Guess no on AIX and OSF/1.
15287 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
15288 # Guess yes otherwise.
15289 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
15290 esac
15291 if test $LOCALE_JA != none; then
15292 if test "$cross_compiling" = yes; then :
15293 :
c971b7fa
PA
15294else
15295 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15296/* end confdefs.h. */
15297
8690e634
JK
15298#include <locale.h>
15299#include <string.h>
15300/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
15301 <wchar.h>.
15302 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15303 included before <wchar.h>. */
15304#include <stddef.h>
15305#include <stdio.h>
15306#include <time.h>
15307#include <wchar.h>
15308int main ()
c971b7fa 15309{
8690e634 15310 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
c971b7fa 15311 {
8690e634
JK
15312 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
15313 mbstate_t state;
15314 wchar_t wc;
15315
15316 memset (&state, '\0', sizeof (mbstate_t));
15317 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
15318 if (mbsinit (&state))
15319 return 1;
c971b7fa 15320 }
c971b7fa
PA
15321 return 0;
15322}
15323_ACEOF
15324if ac_fn_c_try_run "$LINENO"; then :
8690e634 15325 gl_cv_func_mbrtowc_incomplete_state=yes
c971b7fa 15326else
8690e634 15327 gl_cv_func_mbrtowc_incomplete_state=no
c971b7fa
PA
15328fi
15329rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15330 conftest.$ac_objext conftest.beam conftest.$ac_ext
15331fi
15332
8690e634 15333 fi
c971b7fa
PA
15334
15335fi
8690e634
JK
15336{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
15337$as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
c971b7fa
PA
15338
15339
c971b7fa
PA
15340
15341
8690e634
JK
15342 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
15343$as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
15344if test "${gl_cv_func_mbrtowc_sanitycheck+set}" = set; then :
c971b7fa
PA
15345 $as_echo_n "(cached) " >&6
15346else
8690e634
JK
15347
15348 case "$host_os" in
15349 # Guess no on Solaris 8.
15350 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
15351 # Guess yes otherwise.
15352 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
15353 esac
15354 if test $LOCALE_ZH_CN != none; then
15355 if test "$cross_compiling" = yes; then :
15356 :
15357else
c971b7fa
PA
15358 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15359/* end confdefs.h. */
8690e634
JK
15360
15361#include <locale.h>
15362#include <stdlib.h>
15363#include <string.h>
15364/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
15365 <wchar.h>.
15366 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15367 included before <wchar.h>. */
c971b7fa 15368#include <stddef.h>
8690e634
JK
15369#include <stdio.h>
15370#include <time.h>
15371#include <wchar.h>
15372int main ()
c971b7fa 15373{
8690e634
JK
15374 /* This fails on Solaris 8:
15375 mbrtowc returns 2, and sets wc to 0x00F0.
15376 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
15377 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
15378 {
15379 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
15380 mbstate_t state;
15381 wchar_t wc;
15382
15383 memset (&state, '\0', sizeof (mbstate_t));
15384 if (mbrtowc (&wc, input + 3, 6, &state) != 4
15385 && mbtowc (&wc, input + 3, 6) == 4)
15386 return 1;
15387 }
c971b7fa
PA
15388 return 0;
15389}
15390_ACEOF
8690e634
JK
15391if ac_fn_c_try_run "$LINENO"; then :
15392 gl_cv_func_mbrtowc_sanitycheck=yes
c971b7fa 15393else
8690e634 15394 gl_cv_func_mbrtowc_sanitycheck=no
c971b7fa 15395fi
8690e634
JK
15396rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15397 conftest.$ac_objext conftest.beam conftest.$ac_ext
c971b7fa 15398fi
c971b7fa 15399
8690e634
JK
15400 fi
15401
15402fi
15403{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
15404$as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
c971b7fa 15405
8690e634
JK
15406 REPLACE_MBSTATE_T=0
15407 case "$gl_cv_func_mbrtowc_incomplete_state" in
15408 *yes) ;;
15409 *) REPLACE_MBSTATE_T=1 ;;
15410 esac
15411 case "$gl_cv_func_mbrtowc_sanitycheck" in
15412 *yes) ;;
15413 *) REPLACE_MBSTATE_T=1 ;;
15414 esac
15415 else
15416 REPLACE_MBSTATE_T=1
c971b7fa
PA
15417 fi
15418
c971b7fa 15419
8690e634 15420
8690e634
JK
15421 if test $ac_cv_func_mbsinit = no; then
15422 HAVE_MBSINIT=0
15423 ac_fn_c_check_decl "$LINENO" "mbsinit" "ac_cv_have_decl_mbsinit" "
15424/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
15425 <wchar.h>.
15426 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15427 included before <wchar.h>. */
15428#include <stddef.h>
15429#include <stdio.h>
15430#include <time.h>
15431#include <wchar.h>
15432
15433"
15434if test "x$ac_cv_have_decl_mbsinit" = x""yes; then :
15435 ac_have_decl=1
15436else
15437 ac_have_decl=0
c971b7fa 15438fi
c971b7fa 15439
8690e634
JK
15440cat >>confdefs.h <<_ACEOF
15441#define HAVE_DECL_MBSINIT $ac_have_decl
c971b7fa 15442_ACEOF
c971b7fa 15443
8690e634
JK
15444 if test $ac_cv_have_decl_mbsinit = yes; then
15445 REPLACE_MBSINIT=1
15446 fi
15447 else
15448 if test $REPLACE_MBSTATE_T = 1; then
15449 REPLACE_MBSINIT=1
15450 else
15451 case "$host_os" in
15452 mingw*) REPLACE_MBSINIT=1 ;;
15453 esac
15454 fi
15455 fi
c971b7fa 15456
a512b375 15457 if test $HAVE_MBSINIT = 0 || test $REPLACE_MBSINIT = 1; then
c971b7fa
PA
15458
15459
15460
15461
15462
15463
15464
15465
8690e634 15466 gl_LIBOBJS="$gl_LIBOBJS mbsinit.$ac_objext"
c971b7fa
PA
15467
15468
8690e634 15469 :
c971b7fa 15470
a512b375 15471 fi
c971b7fa 15472
c971b7fa 15473
c971b7fa 15474
c971b7fa
PA
15475
15476
8690e634 15477 GNULIB_MBSINIT=1
c971b7fa 15478
c971b7fa
PA
15479
15480
15481
15482
8690e634 15483$as_echo "#define GNULIB_TEST_MBSINIT 1" >>confdefs.h
c971b7fa
PA
15484
15485
c971b7fa 15486
c971b7fa 15487
c971b7fa
PA
15488
15489
15490
c971b7fa 15491
c971b7fa
PA
15492
15493
15494
15495
8690e634
JK
15496
15497 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
c971b7fa
PA
15498
15499
15500
8690e634
JK
15501 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
15502$as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
15503if test "${gl_cv_func_mbrtowc_incomplete_state+set}" = set; then :
15504 $as_echo_n "(cached) " >&6
15505else
c971b7fa 15506
8690e634
JK
15507 case "$host_os" in
15508 # Guess no on AIX and OSF/1.
15509 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
15510 # Guess yes otherwise.
15511 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
c971b7fa 15512 esac
8690e634
JK
15513 if test $LOCALE_JA != none; then
15514 if test "$cross_compiling" = yes; then :
15515 :
15516else
15517 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
c971b7fa 15518/* end confdefs.h. */
c971b7fa 15519
8690e634
JK
15520#include <locale.h>
15521#include <string.h>
15522/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
15523 <wchar.h>.
15524 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15525 included before <wchar.h>. */
15526#include <stddef.h>
15527#include <stdio.h>
15528#include <time.h>
15529#include <wchar.h>
15530int main ()
15531{
15532 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
15533 {
15534 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
15535 mbstate_t state;
15536 wchar_t wc;
15537
15538 memset (&state, '\0', sizeof (mbstate_t));
15539 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
15540 if (mbsinit (&state))
15541 return 1;
15542 }
c971b7fa
PA
15543 return 0;
15544}
15545_ACEOF
8690e634
JK
15546if ac_fn_c_try_run "$LINENO"; then :
15547 gl_cv_func_mbrtowc_incomplete_state=yes
15548else
15549 gl_cv_func_mbrtowc_incomplete_state=no
15550fi
15551rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15552 conftest.$ac_objext conftest.beam conftest.$ac_ext
c971b7fa 15553fi
c971b7fa 15554
8690e634 15555 fi
c971b7fa 15556
8690e634
JK
15557fi
15558{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
15559$as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
c971b7fa 15560
8690e634
JK
15561
15562
15563
15564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
15565$as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
15566if test "${gl_cv_func_mbrtowc_sanitycheck+set}" = set; then :
c971b7fa
PA
15567 $as_echo_n "(cached) " >&6
15568else
8690e634
JK
15569
15570 case "$host_os" in
15571 # Guess no on Solaris 8.
15572 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
15573 # Guess yes otherwise.
15574 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
15575 esac
15576 if test $LOCALE_ZH_CN != none; then
15577 if test "$cross_compiling" = yes; then :
15578 :
15579else
c971b7fa
PA
15580 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15581/* end confdefs.h. */
c971b7fa 15582
8690e634
JK
15583#include <locale.h>
15584#include <stdlib.h>
15585#include <string.h>
15586/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
15587 <wchar.h>.
15588 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15589 included before <wchar.h>. */
15590#include <stddef.h>
15591#include <stdio.h>
15592#include <time.h>
15593#include <wchar.h>
15594int main ()
c971b7fa 15595{
8690e634
JK
15596 /* This fails on Solaris 8:
15597 mbrtowc returns 2, and sets wc to 0x00F0.
15598 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
15599 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
15600 {
15601 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
15602 mbstate_t state;
15603 wchar_t wc;
15604
15605 memset (&state, '\0', sizeof (mbstate_t));
15606 if (mbrtowc (&wc, input + 3, 6, &state) != 4
15607 && mbtowc (&wc, input + 3, 6) == 4)
15608 return 1;
15609 }
c971b7fa
PA
15610 return 0;
15611}
15612_ACEOF
8690e634
JK
15613if ac_fn_c_try_run "$LINENO"; then :
15614 gl_cv_func_mbrtowc_sanitycheck=yes
c971b7fa 15615else
8690e634 15616 gl_cv_func_mbrtowc_sanitycheck=no
c971b7fa 15617fi
8690e634
JK
15618rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15619 conftest.$ac_objext conftest.beam conftest.$ac_ext
c971b7fa 15620fi
8690e634
JK
15621
15622 fi
15623
15624fi
15625{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
15626$as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
15627
15628 REPLACE_MBSTATE_T=0
15629 case "$gl_cv_func_mbrtowc_incomplete_state" in
15630 *yes) ;;
15631 *) REPLACE_MBSTATE_T=1 ;;
15632 esac
15633 case "$gl_cv_func_mbrtowc_sanitycheck" in
15634 *yes) ;;
15635 *) REPLACE_MBSTATE_T=1 ;;
15636 esac
c971b7fa 15637 else
8690e634 15638 REPLACE_MBSTATE_T=1
c971b7fa
PA
15639 fi
15640
15641
c971b7fa 15642
8690e634
JK
15643 if test $ac_cv_func_mbsrtowcs = no; then
15644 HAVE_MBSRTOWCS=0
15645 ac_fn_c_check_decl "$LINENO" "mbsrtowcs" "ac_cv_have_decl_mbsrtowcs" "
15646/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
15647 <wchar.h>.
15648 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15649 included before <wchar.h>. */
15650#include <stddef.h>
15651#include <stdio.h>
15652#include <time.h>
15653#include <wchar.h>
15654
15655"
15656if test "x$ac_cv_have_decl_mbsrtowcs" = x""yes; then :
15657 ac_have_decl=1
c971b7fa 15658else
8690e634 15659 ac_have_decl=0
c971b7fa 15660fi
c971b7fa 15661
8690e634
JK
15662cat >>confdefs.h <<_ACEOF
15663#define HAVE_DECL_MBSRTOWCS $ac_have_decl
15664_ACEOF
c971b7fa 15665
8690e634
JK
15666 if test $ac_cv_have_decl_mbsrtowcs = yes; then
15667 REPLACE_MBSRTOWCS=1
15668 fi
c971b7fa 15669 else
8690e634
JK
15670 if test $REPLACE_MBSTATE_T = 1; then
15671 REPLACE_MBSRTOWCS=1
15672 else
c971b7fa 15673
8690e634
JK
15674
15675
15676
15677
15678
15679 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbsrtowcs works" >&5
15680$as_echo_n "checking whether mbsrtowcs works... " >&6; }
15681if test "${gl_cv_func_mbsrtowcs_works+set}" = set; then :
c971b7fa
PA
15682 $as_echo_n "(cached) " >&6
15683else
8690e634
JK
15684
15685 case "$host_os" in
15686 # Guess no on HP-UX, Solaris, mingw.
15687 hpux* | solaris* | mingw*) gl_cv_func_mbsrtowcs_works="guessing no" ;;
15688 # Guess yes otherwise.
15689 *) gl_cv_func_mbsrtowcs_works="guessing yes" ;;
15690 esac
15691 if test $LOCALE_FR != none || test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none || test $LOCALE_ZH_CN != none; then
15692 if test "$cross_compiling" = yes; then :
15693 :
15694else
c971b7fa
PA
15695 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15696/* end confdefs.h. */
c971b7fa 15697
8690e634
JK
15698#include <locale.h>
15699#include <string.h>
15700/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
15701 <wchar.h>.
15702 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15703 included before <wchar.h>. */
15704#include <stddef.h>
15705#include <stdio.h>
15706#include <time.h>
15707#include <wchar.h>
15708int main ()
c971b7fa 15709{
8690e634
JK
15710 int result = 0;
15711 /* Test whether the function supports a NULL destination argument.
15712 This fails on native Windows. */
15713 if (setlocale (LC_ALL, "$LOCALE_FR") != NULL)
15714 {
15715 const char input[] = "\337er";
15716 const char *src = input;
15717 mbstate_t state;
c971b7fa 15718
8690e634
JK
15719 memset (&state, '\0', sizeof (mbstate_t));
15720 if (mbsrtowcs (NULL, &src, 1, &state) != 3
15721 || src != input)
15722 result |= 1;
15723 }
15724 /* Test whether the function works when started with a conversion state
15725 in non-initial state. This fails on HP-UX 11.11 and Solaris 10. */
15726 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
15727 {
15728 const char input[] = "B\303\274\303\237er";
15729 mbstate_t state;
15730
15731 memset (&state, '\0', sizeof (mbstate_t));
15732 if (mbrtowc (NULL, input + 1, 1, &state) == (size_t)(-2))
15733 if (!mbsinit (&state))
15734 {
15735 const char *src = input + 2;
15736 if (mbsrtowcs (NULL, &src, 10, &state) != 4)
15737 result |= 2;
15738 }
15739 }
15740 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
15741 {
15742 const char input[] = "<\306\374\313\334\270\354>";
15743 mbstate_t state;
15744
15745 memset (&state, '\0', sizeof (mbstate_t));
15746 if (mbrtowc (NULL, input + 3, 1, &state) == (size_t)(-2))
15747 if (!mbsinit (&state))
15748 {
15749 const char *src = input + 4;
15750 if (mbsrtowcs (NULL, &src, 10, &state) != 3)
15751 result |= 4;
15752 }
15753 }
15754 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
15755 {
15756 const char input[] = "B\250\271\201\060\211\070er";
15757 mbstate_t state;
15758
15759 memset (&state, '\0', sizeof (mbstate_t));
15760 if (mbrtowc (NULL, input + 1, 1, &state) == (size_t)(-2))
15761 if (!mbsinit (&state))
15762 {
15763 const char *src = input + 2;
15764 if (mbsrtowcs (NULL, &src, 10, &state) != 4)
15765 result |= 8;
15766 }
15767 }
15768 return result;
c971b7fa
PA
15769}
15770_ACEOF
8690e634
JK
15771if ac_fn_c_try_run "$LINENO"; then :
15772 gl_cv_func_mbsrtowcs_works=yes
c971b7fa 15773else
8690e634 15774 gl_cv_func_mbsrtowcs_works=no
c971b7fa 15775fi
8690e634
JK
15776rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15777 conftest.$ac_objext conftest.beam conftest.$ac_ext
c971b7fa 15778fi
8690e634
JK
15779
15780 fi
15781
15782fi
15783{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbsrtowcs_works" >&5
15784$as_echo "$gl_cv_func_mbsrtowcs_works" >&6; }
15785
15786 case "$gl_cv_func_mbsrtowcs_works" in
15787 *yes) ;;
15788 *) REPLACE_MBSRTOWCS=1 ;;
15789 esac
15790 fi
c971b7fa
PA
15791 fi
15792
a512b375 15793 if test $HAVE_MBSRTOWCS = 0 || test $REPLACE_MBSRTOWCS = 1; then
c971b7fa 15794
c971b7fa 15795
c971b7fa 15796
c971b7fa 15797
c971b7fa 15798
c971b7fa 15799
c971b7fa
PA
15800
15801
8690e634
JK
15802 gl_LIBOBJS="$gl_LIBOBJS mbsrtowcs.$ac_objext"
15803
15804
15805
15806
15807
15808
15809
15810
15811
15812 gl_LIBOBJS="$gl_LIBOBJS mbsrtowcs-state.$ac_objext"
15813
15814
15815 :
15816
a512b375 15817 fi
8690e634
JK
15818
15819
15820
15821
15822
15823 GNULIB_MBSRTOWCS=1
15824
15825
15826
15827
15828
15829$as_echo "#define GNULIB_TEST_MBSRTOWCS 1" >>confdefs.h
c971b7fa
PA
15830
15831
15832
15833
a512b375 15834 if test $HAVE_MEMCHR = 0 || test $REPLACE_MEMCHR = 1; then
c971b7fa
PA
15835
15836
15837
15838
15839
15840
15841
15842
15843 gl_LIBOBJS="$gl_LIBOBJS memchr.$ac_objext"
15844
15845
15846 for ac_header in bp-sym.h
15847do :
15848 ac_fn_c_check_header_mongrel "$LINENO" "bp-sym.h" "ac_cv_header_bp_sym_h" "$ac_includes_default"
15849if test "x$ac_cv_header_bp_sym_h" = x""yes; then :
15850 cat >>confdefs.h <<_ACEOF
15851#define HAVE_BP_SYM_H 1
15852_ACEOF
15853
15854fi
15855
15856done
15857
15858
a512b375 15859 fi
c971b7fa
PA
15860
15861
15862
15863
15864
15865 GNULIB_MEMCHR=1
15866
15867
15868
15869
15870
15871$as_echo "#define GNULIB_TEST_MEMCHR 1" >>confdefs.h
15872
15873
15874
15875
15876
15877 if test $HAVE_DECL_MEMMEM = 1 && test $REPLACE_MEMMEM = 0; then
15878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memmem works in linear time" >&5
15879$as_echo_n "checking whether memmem works in linear time... " >&6; }
15880if test "${gl_cv_func_memmem_works_fast+set}" = set; then :
15881 $as_echo_n "(cached) " >&6
15882else
15883 if test "$cross_compiling" = yes; then :
15884 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15885/* end confdefs.h. */
15886
15887#include <features.h>
15888#ifdef __GNU_LIBRARY__
15889 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 9) || (__GLIBC__ > 2)) \
15890 && !defined __UCLIBC__
15891 Lucky user
15892 #endif
15893#endif
15894#ifdef __CYGWIN__
15895 #include <cygwin/version.h>
15896 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 0)
15897 Lucky user
15898 #endif
15899#endif
15900
15901_ACEOF
15902if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15903 $EGREP "Lucky user" >/dev/null 2>&1; then :
63ce7108
TT
15904 gl_cv_func_memmem_works_fast="guessing yes"
15905else
15906 gl_cv_func_memmem_works_fast="guessing no"
15907fi
15908rm -f conftest*
15909
15910
15911else
15912 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15913/* end confdefs.h. */
15914
15915#include <signal.h> /* for signal */
15916#include <string.h> /* for memmem */
15917#include <stdlib.h> /* for malloc */
15918#include <unistd.h> /* for alarm */
15919static void quit (int sig) { exit (sig + 128); }
15920
15921int
15922main ()
15923{
15924
15925 int result = 0;
15926 size_t m = 1000000;
15927 char *haystack = (char *) malloc (2 * m + 1);
15928 char *needle = (char *) malloc (m + 1);
15929 /* Failure to compile this test due to missing alarm is okay,
15930 since all such platforms (mingw) also lack memmem. */
15931 signal (SIGALRM, quit);
15932 alarm (5);
15933 /* Check for quadratic performance. */
15934 if (haystack && needle)
15935 {
15936 memset (haystack, 'A', 2 * m);
15937 haystack[2 * m] = 'B';
15938 memset (needle, 'A', m);
15939 needle[m] = 'B';
15940 if (!memmem (haystack, 2 * m + 1, needle, m + 1))
15941 result |= 1;
15942 }
15943 return result;
15944
15945 ;
15946 return 0;
15947}
15948_ACEOF
15949if ac_fn_c_try_run "$LINENO"; then :
15950 gl_cv_func_memmem_works_fast=yes
15951else
15952 gl_cv_func_memmem_works_fast=no
15953fi
15954rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15955 conftest.$ac_objext conftest.beam conftest.$ac_ext
15956fi
15957
15958
15959fi
15960{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memmem_works_fast" >&5
15961$as_echo "$gl_cv_func_memmem_works_fast" >&6; }
15962 case "$gl_cv_func_memmem_works_fast" in
15963 *yes) ;;
15964 *)
15965 REPLACE_MEMMEM=1
15966 ;;
15967 esac
15968 fi
15969
15970 if test $HAVE_MEMMEM = 0 || test $REPLACE_MEMMEM = 1; then
15971
15972
15973
15974
15975
15976
15977
15978
15979 gl_LIBOBJS="$gl_LIBOBJS memmem.$ac_objext"
15980
15981 fi
15982
15983
15984
15985
15986 for ac_func in memmem
15987do :
15988 ac_fn_c_check_func "$LINENO" "memmem" "ac_cv_func_memmem"
15989if test "x$ac_cv_func_memmem" = x""yes; then :
15990 cat >>confdefs.h <<_ACEOF
15991#define HAVE_MEMMEM 1
15992_ACEOF
15993
15994fi
15995done
15996
15997 if test $ac_cv_func_memmem = yes; then
15998 HAVE_MEMMEM=1
15999 else
16000 HAVE_MEMMEM=0
16001 fi
16002
16003 if test $ac_cv_have_decl_memmem = no; then
16004 HAVE_DECL_MEMMEM=0
16005 else
16006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memmem works" >&5
16007$as_echo_n "checking whether memmem works... " >&6; }
16008if test "${gl_cv_func_memmem_works_always+set}" = set; then :
16009 $as_echo_n "(cached) " >&6
16010else
16011 if test "$cross_compiling" = yes; then :
16012 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16013/* end confdefs.h. */
16014
16015#ifdef __GNU_LIBRARY__
16016 #include <features.h>
16017 #if ((__GLIBC__ == 2 && ((__GLIBC_MINOR > 0 && __GLIBC_MINOR__ < 9) \
16018 || __GLIBC_MINOR__ > 12)) \
16019 || (__GLIBC__ > 2)) \
16020 || defined __UCLIBC__
16021 Lucky user
16022 #endif
16023#elif defined __CYGWIN__
16024 #include <cygwin/version.h>
16025 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
16026 Lucky user
16027 #endif
16028#else
16029 Lucky user
16030#endif
16031
16032_ACEOF
16033if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16034 $EGREP "Lucky user" >/dev/null 2>&1; then :
16035 gl_cv_func_memmem_works_always="guessing yes"
16036else
16037 gl_cv_func_memmem_works_always="guessing no"
16038fi
16039rm -f conftest*
16040
16041
16042else
16043 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16044/* end confdefs.h. */
16045
16046#include <string.h> /* for memmem */
16047#define P "_EF_BF_BD"
16048#define HAYSTACK "F_BD_CE_BD" P P P P "_C3_88_20" P P P "_C3_A7_20" P
16049#define NEEDLE P P P P P
16050
16051int
16052main ()
16053{
16054
16055 int result = 0;
16056 if (memmem (HAYSTACK, strlen (HAYSTACK), NEEDLE, strlen (NEEDLE)))
16057 result |= 1;
16058 /* Check for empty needle behavior. */
16059 {
16060 const char *haystack = "AAA";
16061 if (memmem (haystack, 3, NULL, 0) != haystack)
16062 result |= 2;
16063 }
16064 return result;
16065
16066 ;
16067 return 0;
16068}
16069_ACEOF
16070if ac_fn_c_try_run "$LINENO"; then :
16071 gl_cv_func_memmem_works_always=yes
16072else
16073 gl_cv_func_memmem_works_always=no
16074fi
16075rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16076 conftest.$ac_objext conftest.beam conftest.$ac_ext
16077fi
16078
16079
16080fi
16081{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memmem_works_always" >&5
16082$as_echo "$gl_cv_func_memmem_works_always" >&6; }
16083 case "$gl_cv_func_memmem_works_always" in
16084 *yes) ;;
16085 *)
16086 REPLACE_MEMMEM=1
16087 ;;
16088 esac
16089 fi
16090 :
16091
16092 if test $HAVE_MEMMEM = 0 || test $REPLACE_MEMMEM = 1; then
16093
16094
16095
16096
16097
16098
16099
16100
16101 gl_LIBOBJS="$gl_LIBOBJS memmem.$ac_objext"
16102
16103 fi
16104
16105
16106
16107
16108
16109 GNULIB_MEMMEM=1
16110
16111
16112
16113
16114
16115$as_echo "#define GNULIB_TEST_MEMMEM 1" >>confdefs.h
16116
16117
16118
16119
16120
16121
16122
16123
2196f55f
YQ
16124
16125
8424cc97
SM
16126
16127 for ac_func in rawmemchr
16128do :
16129 ac_fn_c_check_func "$LINENO" "rawmemchr" "ac_cv_func_rawmemchr"
16130if test "x$ac_cv_func_rawmemchr" = x""yes; then :
16131 cat >>confdefs.h <<_ACEOF
16132#define HAVE_RAWMEMCHR 1
16133_ACEOF
16134
16135fi
16136done
16137
16138 if test $ac_cv_func_rawmemchr = no; then
16139 HAVE_RAWMEMCHR=0
16140 fi
16141
16142 if test $HAVE_RAWMEMCHR = 0; then
16143
16144
16145
16146
16147
16148
16149
16150
16151 gl_LIBOBJS="$gl_LIBOBJS rawmemchr.$ac_objext"
16152
16153 :
16154 fi
16155
16156
16157
16158
16159
16160 GNULIB_RAWMEMCHR=1
16161
16162
16163
16164
16165
16166$as_echo "#define GNULIB_TEST_RAWMEMCHR 1" >>confdefs.h
16167
16168
16169
16170
16171
16172
2196f55f
YQ
16173 if test $ac_cv_func_readlink = no; then
16174 HAVE_READLINK=0
16175 else
16176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
16177$as_echo_n "checking whether readlink signature is correct... " >&6; }
16178if test "${gl_cv_decl_readlink_works+set}" = set; then :
16179 $as_echo_n "(cached) " >&6
16180else
16181 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16182/* end confdefs.h. */
16183#include <unistd.h>
16184 /* Cause compilation failure if original declaration has wrong type. */
16185 ssize_t readlink (const char *, char *, size_t);
16186int
16187main ()
16188{
16189
16190 ;
16191 return 0;
16192}
16193_ACEOF
16194if ac_fn_c_try_compile "$LINENO"; then :
16195 gl_cv_decl_readlink_works=yes
16196else
16197 gl_cv_decl_readlink_works=no
16198fi
16199rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16200fi
16201{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
16202$as_echo "$gl_cv_decl_readlink_works" >&6; }
16203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
16204$as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
16205if test "${gl_cv_func_readlink_works+set}" = set; then :
16206 $as_echo_n "(cached) " >&6
16207else
16208 # We have readlink, so assume ln -s works.
16209 ln -s conftest.no-such conftest.link
16210 ln -s conftest.link conftest.lnk2
16211 if test "$cross_compiling" = yes; then :
16212 case "$host_os" in
16213 # Guess yes on glibc systems.
16214 *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
16215 # If we don't know, assume the worst.
16216 *) gl_cv_func_readlink_works="guessing no" ;;
16217 esac
16218
16219else
16220 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16221/* end confdefs.h. */
16222#include <unistd.h>
16223
16224int
16225main ()
16226{
16227char buf[20];
16228 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
16229 ;
16230 return 0;
16231}
16232_ACEOF
16233if ac_fn_c_try_run "$LINENO"; then :
16234 gl_cv_func_readlink_works=yes
16235else
16236 gl_cv_func_readlink_works=no
16237fi
16238rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16239 conftest.$ac_objext conftest.beam conftest.$ac_ext
16240fi
16241
16242 rm -f conftest.link conftest.lnk2
16243fi
16244{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
16245$as_echo "$gl_cv_func_readlink_works" >&6; }
16246 case "$gl_cv_func_readlink_works" in
16247 *yes)
16248 if test "$gl_cv_decl_readlink_works" != yes; then
16249 REPLACE_READLINK=1
16250 fi
16251 ;;
16252 *)
16253
16254$as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
16255
16256 REPLACE_READLINK=1
16257 ;;
16258 esac
16259 fi
16260
16261 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
16262
16263
16264
16265
16266
16267
16268
16269
16270 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
16271
16272
16273 :
16274
16275 fi
16276
16277
16278
16279
16280
16281 GNULIB_READLINK=1
16282
16283
16284
16285
16286
16287$as_echo "#define GNULIB_TEST_READLINK 1" >>confdefs.h
16288
16289
16290
16291
6a29c58e
YQ
16292
16293
16294
16295
16296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename honors trailing slash on destination" >&5
16297$as_echo_n "checking whether rename honors trailing slash on destination... " >&6; }
16298if test "${gl_cv_func_rename_slash_dst_works+set}" = set; then :
16299 $as_echo_n "(cached) " >&6
16300else
16301 rm -rf conftest.f conftest.f1 conftest.f2 conftest.d1 conftest.d2 conftest.lnk
16302 touch conftest.f && touch conftest.f1 && mkdir conftest.d1 ||
16303 as_fn_error "cannot create temporary files" "$LINENO" 5
16304 # Assume that if we have lstat, we can also check symlinks.
16305 if test $ac_cv_func_lstat = yes; then
16306 ln -s conftest.f conftest.lnk
16307 fi
16308 if test "$cross_compiling" = yes; then :
16309 case "$host_os" in
16310 # Guess yes on glibc systems.
16311 *-gnu*) gl_cv_func_rename_slash_dst_works="guessing yes" ;;
16312 # If we don't know, assume the worst.
16313 *) gl_cv_func_rename_slash_dst_works="guessing no" ;;
16314 esac
16315
16316else
16317 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16318/* end confdefs.h. */
16319
16320# include <stdio.h>
16321# include <stdlib.h>
16322
16323int
16324main ()
16325{
16326int result = 0;
16327 if (rename ("conftest.f1", "conftest.f2/") == 0)
16328 result |= 1;
16329 if (rename ("conftest.d1", "conftest.d2/") != 0)
16330 result |= 2;
16331#if HAVE_LSTAT
16332 if (rename ("conftest.f", "conftest.lnk/") == 0)
16333 result |= 4;
16334#endif
16335 return result;
16336
16337 ;
16338 return 0;
16339}
16340_ACEOF
16341if ac_fn_c_try_run "$LINENO"; then :
16342 gl_cv_func_rename_slash_dst_works=yes
16343else
16344 gl_cv_func_rename_slash_dst_works=no
16345fi
16346rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16347 conftest.$ac_objext conftest.beam conftest.$ac_ext
16348fi
16349
16350 rm -rf conftest.f conftest.f1 conftest.f2 conftest.d1 conftest.d2 conftest.lnk
16351
16352fi
16353{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_slash_dst_works" >&5
16354$as_echo "$gl_cv_func_rename_slash_dst_works" >&6; }
16355 case "$gl_cv_func_rename_slash_dst_works" in
16356 *yes) ;;
16357 *)
16358 REPLACE_RENAME=1
16359
16360$as_echo "#define RENAME_TRAILING_SLASH_DEST_BUG 1" >>confdefs.h
16361
16362 ;;
16363 esac
16364
16365 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename honors trailing slash on source" >&5
16366$as_echo_n "checking whether rename honors trailing slash on source... " >&6; }
16367if test "${gl_cv_func_rename_slash_src_works+set}" = set; then :
16368 $as_echo_n "(cached) " >&6
16369else
16370 rm -rf conftest.f conftest.f1 conftest.d1 conftest.d2 conftest.d3 conftest.lnk
16371 touch conftest.f && touch conftest.f1 && mkdir conftest.d1 ||
16372 as_fn_error "cannot create temporary files" "$LINENO" 5
16373 # Assume that if we have lstat, we can also check symlinks.
16374 if test $ac_cv_func_lstat = yes; then
16375 ln -s conftest.f conftest.lnk
16376 fi
16377 if test "$cross_compiling" = yes; then :
16378 case "$host_os" in
16379 # Guess yes on glibc systems.
16380 *-gnu*) gl_cv_func_rename_slash_src_works="guessing yes" ;;
16381 # If we don't know, assume the worst.
16382 *) gl_cv_func_rename_slash_src_works="guessing no" ;;
16383 esac
16384
16385else
16386 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16387/* end confdefs.h. */
16388
16389# include <stdio.h>
16390# include <stdlib.h>
16391
16392int
16393main ()
16394{
16395int result = 0;
16396 if (rename ("conftest.f1/", "conftest.d3") == 0)
16397 result |= 1;
16398 if (rename ("conftest.d1/", "conftest.d2") != 0)
16399 result |= 2;
16400#if HAVE_LSTAT
16401 if (rename ("conftest.lnk/", "conftest.f") == 0)
16402 result |= 4;
16403#endif
16404 return result;
16405
16406 ;
16407 return 0;
16408}
16409_ACEOF
16410if ac_fn_c_try_run "$LINENO"; then :
16411 gl_cv_func_rename_slash_src_works=yes
16412else
16413 gl_cv_func_rename_slash_src_works=no
16414fi
16415rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16416 conftest.$ac_objext conftest.beam conftest.$ac_ext
16417fi
16418
16419 rm -rf conftest.f conftest.f1 conftest.d1 conftest.d2 conftest.d3 conftest.lnk
16420
16421fi
16422{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_slash_src_works" >&5
16423$as_echo "$gl_cv_func_rename_slash_src_works" >&6; }
16424 case "$gl_cv_func_rename_slash_src_works" in
16425 *yes) ;;
16426 *)
16427 REPLACE_RENAME=1
16428
16429$as_echo "#define RENAME_TRAILING_SLASH_SOURCE_BUG 1" >>confdefs.h
16430
16431 ;;
16432 esac
16433
16434
16435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename manages hard links correctly" >&5
16436$as_echo_n "checking whether rename manages hard links correctly... " >&6; }
16437if test "${gl_cv_func_rename_link_works+set}" = set; then :
16438 $as_echo_n "(cached) " >&6
16439else
16440 if test $ac_cv_func_link = yes; then
16441 rm -rf conftest.f conftest.f1
16442 if touch conftest.f && ln conftest.f conftest.f1 &&
16443 set x `ls -i conftest.f conftest.f1` && test "" = ""; then
16444 if test "$cross_compiling" = yes; then :
16445 case "$host_os" in
16446 # Guess yes on glibc systems.
16447 *-gnu*) gl_cv_func_rename_link_works="guessing yes" ;;
16448 # If we don't know, assume the worst.
16449 *) gl_cv_func_rename_link_works="guessing no" ;;
16450 esac
16451
16452else
16453 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16454/* end confdefs.h. */
16455
16456# include <stdio.h>
16457# include <stdlib.h>
16458# include <unistd.h>
16459
16460int
16461main ()
16462{
16463int result = 0;
16464 if (rename ("conftest.f", "conftest.f1"))
16465 result |= 1;
16466 if (unlink ("conftest.f1"))
16467 result |= 2;
16468 if (rename ("conftest.f", "conftest.f"))
16469 result |= 4;
16470 if (rename ("conftest.f1", "conftest.f1") == 0)
16471 result |= 8;
16472 return result;
16473
16474 ;
16475 return 0;
16476}
16477_ACEOF
16478if ac_fn_c_try_run "$LINENO"; then :
16479 gl_cv_func_rename_link_works=yes
16480else
16481 gl_cv_func_rename_link_works=no
16482fi
16483rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16484 conftest.$ac_objext conftest.beam conftest.$ac_ext
16485fi
16486
16487 else
16488 gl_cv_func_rename_link_works="guessing no"
16489 fi
16490 rm -rf conftest.f conftest.f1
16491 else
16492 gl_cv_func_rename_link_works=yes
16493 fi
16494
16495fi
16496{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_link_works" >&5
16497$as_echo "$gl_cv_func_rename_link_works" >&6; }
16498 case "$gl_cv_func_rename_link_works" in
16499 *yes) ;;
16500 *)
16501 REPLACE_RENAME=1
16502
16503$as_echo "#define RENAME_HARD_LINK_BUG 1" >>confdefs.h
16504
16505 ;;
16506 esac
16507
16508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename manages existing destinations correctly" >&5
16509$as_echo_n "checking whether rename manages existing destinations correctly... " >&6; }
16510if test "${gl_cv_func_rename_dest_works+set}" = set; then :
16511 $as_echo_n "(cached) " >&6
16512else
16513 rm -rf conftest.f conftest.d1 conftest.d2
16514 touch conftest.f && mkdir conftest.d1 conftest.d2 ||
16515 as_fn_error "cannot create temporary files" "$LINENO" 5
16516 if test "$cross_compiling" = yes; then :
16517 case "$host_os" in
16518 # Guess yes on glibc systems.
16519 *-gnu*) gl_cv_func_rename_dest_works="guessing yes" ;;
16520 # If we don't know, assume the worst.
16521 *) gl_cv_func_rename_dest_works="guessing no" ;;
16522 esac
16523
16524else
16525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16526/* end confdefs.h. */
16527
16528# include <stdio.h>
16529# include <stdlib.h>
16530
16531int
16532main ()
16533{
16534int result = 0;
16535 if (rename ("conftest.d1", "conftest.d2") != 0)
16536 result |= 1;
16537 if (rename ("conftest.d2", "conftest.f") == 0)
16538 result |= 2;
16539 return result;
16540
16541 ;
16542 return 0;
16543}
16544_ACEOF
16545if ac_fn_c_try_run "$LINENO"; then :
16546 gl_cv_func_rename_dest_works=yes
16547else
16548 gl_cv_func_rename_dest_works=no
16549fi
16550rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16551 conftest.$ac_objext conftest.beam conftest.$ac_ext
16552fi
16553
16554 rm -rf conftest.f conftest.d1 conftest.d2
16555
16556fi
16557{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_dest_works" >&5
16558$as_echo "$gl_cv_func_rename_dest_works" >&6; }
16559 case "$gl_cv_func_rename_dest_works" in
16560 *yes) ;;
16561 *)
16562 REPLACE_RENAME=1
16563
16564$as_echo "#define RENAME_DEST_EXISTS_BUG 1" >>confdefs.h
16565
16566 ;;
16567 esac
16568
16569 if test $REPLACE_RENAME = 1; then
16570
16571
16572
16573
16574
16575
16576
16577
16578 gl_LIBOBJS="$gl_LIBOBJS rename.$ac_objext"
16579
16580 fi
16581
16582
16583
16584
16585
16586 GNULIB_RENAME=1
16587
16588
16589
16590
16591
16592$as_echo "#define GNULIB_TEST_RENAME 1" >>confdefs.h
16593
16594
16595
16596
16597
16598
16599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rmdir works" >&5
16600$as_echo_n "checking whether rmdir works... " >&6; }
16601if test "${gl_cv_func_rmdir_works+set}" = set; then :
16602 $as_echo_n "(cached) " >&6
16603else
16604 mkdir conftest.dir
16605 touch conftest.file
16606 if test "$cross_compiling" = yes; then :
16607 case "$host_os" in
16608 # Guess yes on glibc systems.
16609 *-gnu*) gl_cv_func_rmdir_works="guessing yes" ;;
16610 # If we don't know, assume the worst.
16611 *) gl_cv_func_rmdir_works="guessing no" ;;
16612 esac
16613
16614else
16615 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16616/* end confdefs.h. */
16617#include <stdio.h>
16618 #include <errno.h>
16619 #if HAVE_UNISTD_H
16620 # include <unistd.h>
16621 #else /* on Windows with MSVC */
16622 # include <direct.h>
16623 #endif
16624
16625int
16626main ()
16627{
16628int result = 0;
16629 if (!rmdir ("conftest.file/"))
16630 result |= 1;
16631 else if (errno != ENOTDIR)
16632 result |= 2;
16633 if (!rmdir ("conftest.dir/./"))
16634 result |= 4;
16635 return result;
16636
16637 ;
16638 return 0;
16639}
16640_ACEOF
16641if ac_fn_c_try_run "$LINENO"; then :
16642 gl_cv_func_rmdir_works=yes
16643else
16644 gl_cv_func_rmdir_works=no
16645fi
16646rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16647 conftest.$ac_objext conftest.beam conftest.$ac_ext
16648fi
16649
16650 rm -rf conftest.dir conftest.file
16651fi
16652{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rmdir_works" >&5
16653$as_echo "$gl_cv_func_rmdir_works" >&6; }
16654 case "$gl_cv_func_rmdir_works" in
16655 *yes) ;;
16656 *)
16657 REPLACE_RMDIR=1
16658 ;;
16659 esac
16660
16661 if test $REPLACE_RMDIR = 1; then
16662
16663
16664
16665
16666
16667
16668
16669
16670 gl_LIBOBJS="$gl_LIBOBJS rmdir.$ac_objext"
16671
16672 fi
16673
16674
16675
16676
16677
16678 GNULIB_RMDIR=1
16679
16680
16681
16682
16683
16684$as_echo "#define GNULIB_TEST_RMDIR 1" >>confdefs.h
16685
16686
16687
16688
0750520d
PA
16689
16690
16691
16692
16693
16694
16695
16696
16697
16698
16699 if test $gl_cv_have_include_next = yes; then
16700 gl_cv_next_signal_h='<'signal.h'>'
16701 else
16702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
16703$as_echo_n "checking absolute name of <signal.h>... " >&6; }
16704if test "${gl_cv_next_signal_h+set}" = set; then :
16705 $as_echo_n "(cached) " >&6
16706else
16707
16708
16709
16710 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16711/* end confdefs.h. */
16712#include <signal.h>
16713_ACEOF
16714 case "$host_os" in
16715 aix*) gl_absname_cpp="$ac_cpp -C" ;;
16716 *) gl_absname_cpp="$ac_cpp" ;;
16717 esac
16718
16719 case "$host_os" in
16720 mingw*)
16721 gl_dirsep_regex='[/\\]'
16722 ;;
16723 *)
16724 gl_dirsep_regex='\/'
16725 ;;
16726 esac
16727 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
16728 gl_header_literal_regex=`echo 'signal.h' \
16729 | sed -e "$gl_make_literal_regex_sed"`
16730 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
16731 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
16732 s|^/[^/]|//&|
16733 p
16734 q
16735 }'
16736
16737 gl_cv_absolute_signal_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
16738 sed -n "$gl_absolute_header_sed"`
16739
16740 gl_header=$gl_cv_absolute_signal_h
16741 gl_cv_next_signal_h='"'$gl_header'"'
16742
16743
16744fi
16745{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
16746$as_echo "$gl_cv_next_signal_h" >&6; }
16747 fi
16748 NEXT_SIGNAL_H=$gl_cv_next_signal_h
16749
16750 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
16751 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
16752 gl_next_as_first_directive='<'signal.h'>'
16753 else
16754 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
16755 gl_next_as_first_directive=$gl_cv_next_signal_h
16756 fi
16757 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
16758
16759
16760
16761
16762
16763# AIX declares sig_atomic_t to already include volatile, and C89 compilers
16764# then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
16765 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
16766#include <signal.h>
16767
16768"
16769if test "x$ac_cv_type_volatile_sig_atomic_t" = x""yes; then :
16770
16771else
16772 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
16773fi
16774
16775
16776
16777
16778
16779
16780
16781 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
16782#include <signal.h>
16783
16784"
16785if test "x$ac_cv_type_sighandler_t" = x""yes; then :
16786
16787else
16788 HAVE_SIGHANDLER_T=0
16789fi
16790
16791
16792
16793 for gl_func in pthread_sigmask sigaction sigaddset sigdelset sigemptyset sigfillset sigismember sigpending sigprocmask; do
16794 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
16795 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
16796$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
16797if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
16798 $as_echo_n "(cached) " >&6
16799else
16800 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16801/* end confdefs.h. */
16802#include <signal.h>
16803
16804int
16805main ()
16806{
16807#undef $gl_func
16808 (void) $gl_func;
16809 ;
16810 return 0;
16811}
16812_ACEOF
16813if ac_fn_c_try_compile "$LINENO"; then :
16814 eval "$as_gl_Symbol=yes"
16815else
16816 eval "$as_gl_Symbol=no"
16817fi
16818rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16819fi
16820eval ac_res=\$$as_gl_Symbol
16821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
16822$as_echo "$ac_res" >&6; }
16823 eval as_val=\$$as_gl_Symbol
16824 if test "x$as_val" = x""yes; then :
16825 cat >>confdefs.h <<_ACEOF
16826#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
16827_ACEOF
16828
16829 eval ac_cv_have_decl_$gl_func=yes
16830fi
16831 done
16832
16833
16834
63ce7108
TT
16835 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
16836$as_echo_n "checking for ssize_t... " >&6; }
16837if test "${gt_cv_ssize_t+set}" = set; then :
16838 $as_echo_n "(cached) " >&6
16839else
16840 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16841/* end confdefs.h. */
16842#include <sys/types.h>
16843int
16844main ()
16845{
16846int x = sizeof (ssize_t *) + sizeof (ssize_t);
16847 return !x;
16848 ;
16849 return 0;
16850}
16851_ACEOF
16852if ac_fn_c_try_compile "$LINENO"; then :
16853 gt_cv_ssize_t=yes
16854else
16855 gt_cv_ssize_t=no
16856fi
16857rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16858fi
16859{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
16860$as_echo "$gt_cv_ssize_t" >&6; }
16861 if test $gt_cv_ssize_t = no; then
16862
16863$as_echo "#define ssize_t int" >>confdefs.h
16864
16865 fi
16866
16867
16868
16869
2196f55f
YQ
16870 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
16871$as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
16872if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
16873 $as_echo_n "(cached) " >&6
16874else
16875 if test "$cross_compiling" = yes; then :
16876 case $host_os in
16877 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
16878 *) gl_cv_func_stat_dir_slash="guessing yes";;
16879 esac
16880else
16881 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16882/* end confdefs.h. */
16883#include <sys/stat.h>
16884
16885int
16886main ()
16887{
16888struct stat st; return stat (".", &st) != stat ("./", &st);
16889 ;
16890 return 0;
16891}
16892_ACEOF
16893if ac_fn_c_try_run "$LINENO"; then :
16894 gl_cv_func_stat_dir_slash=yes
16895else
16896 gl_cv_func_stat_dir_slash=no
16897fi
16898rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16899 conftest.$ac_objext conftest.beam conftest.$ac_ext
16900fi
16901
16902fi
16903{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
16904$as_echo "$gl_cv_func_stat_dir_slash" >&6; }
16905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
16906$as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
16907if test "${gl_cv_func_stat_file_slash+set}" = set; then :
16908 $as_echo_n "(cached) " >&6
16909else
16910 touch conftest.tmp
16911 # Assume that if we have lstat, we can also check symlinks.
16912 if test $ac_cv_func_lstat = yes; then
16913 ln -s conftest.tmp conftest.lnk
16914 fi
16915 if test "$cross_compiling" = yes; then :
16916 case "$host_os" in
16917 # Guess yes on glibc systems.
16918 *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
16919 # If we don't know, assume the worst.
16920 *) gl_cv_func_stat_file_slash="guessing no" ;;
16921 esac
16922
16923else
16924 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16925/* end confdefs.h. */
16926#include <sys/stat.h>
16927
16928int
16929main ()
16930{
16931int result = 0;
16932 struct stat st;
16933 if (!stat ("conftest.tmp/", &st))
16934 result |= 1;
16935#if HAVE_LSTAT
16936 if (!stat ("conftest.lnk/", &st))
16937 result |= 2;
16938#endif
16939 return result;
16940
16941 ;
16942 return 0;
16943}
16944_ACEOF
16945if ac_fn_c_try_run "$LINENO"; then :
16946 gl_cv_func_stat_file_slash=yes
16947else
16948 gl_cv_func_stat_file_slash=no
16949fi
16950rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16951 conftest.$ac_objext conftest.beam conftest.$ac_ext
16952fi
16953
16954 rm -f conftest.tmp conftest.lnk
16955fi
16956{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
16957$as_echo "$gl_cv_func_stat_file_slash" >&6; }
16958 case $gl_cv_func_stat_dir_slash in
16959 *no) REPLACE_STAT=1
16960
16961$as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
16962;;
16963 esac
16964 case $gl_cv_func_stat_file_slash in
16965 *no) REPLACE_STAT=1
16966
16967$as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
16968;;
16969 esac
16970
16971 if test $REPLACE_STAT = 1; then
16972
16973
16974
16975
16976
16977
16978
16979
16980 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
16981
16982 :
16983 fi
16984
16985
16986
16987
16988
16989 GNULIB_STAT=1
16990
16991
16992
16993
16994
16995$as_echo "#define GNULIB_TEST_STAT 1" >>confdefs.h
16996
16997
16998
16999
17000
17001
63ce7108
TT
17002 # Define two additional variables used in the Makefile substitution.
17003
17004 if test "$ac_cv_header_stdbool_h" = yes; then
17005 STDBOOL_H=''
17006 else
17007 STDBOOL_H='stdbool.h'
17008 fi
17009
17010 if test -n "$STDBOOL_H"; then
17011 GL_GENERATE_STDBOOL_H_TRUE=
17012 GL_GENERATE_STDBOOL_H_FALSE='#'
17013else
17014 GL_GENERATE_STDBOOL_H_TRUE='#'
17015 GL_GENERATE_STDBOOL_H_FALSE=
17016fi
17017
17018
17019 if test "$ac_cv_type__Bool" = yes; then
17020 HAVE__BOOL=1
17021 else
17022 HAVE__BOOL=0
17023 fi
17024
17025
17026
17027
17028
17029 STDDEF_H=
4a626d0a
PA
17030 ac_fn_c_check_type "$LINENO" "max_align_t" "ac_cv_type_max_align_t" "#include <stddef.h>
17031
17032"
17033if test "x$ac_cv_type_max_align_t" = x""yes; then :
17034
17035else
17036 HAVE_MAX_ALIGN_T=0; STDDEF_H=stddef.h
17037fi
17038
63ce7108
TT
17039 if test $gt_cv_c_wchar_t = no; then
17040 HAVE_WCHAR_T=0
17041 STDDEF_H=stddef.h
17042 fi
17043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
17044$as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
17045if test "${gl_cv_decl_null_works+set}" = set; then :
17046 $as_echo_n "(cached) " >&6
17047else
17048 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17049/* end confdefs.h. */
17050#include <stddef.h>
17051 int test[2 * (sizeof NULL == sizeof (void *)) -1];
17052
17053int
17054main ()
17055{
17056
17057 ;
17058 return 0;
17059}
17060_ACEOF
17061if ac_fn_c_try_compile "$LINENO"; then :
17062 gl_cv_decl_null_works=yes
17063else
17064 gl_cv_decl_null_works=no
17065fi
17066rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17067fi
17068{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
17069$as_echo "$gl_cv_decl_null_works" >&6; }
17070 if test $gl_cv_decl_null_works = no; then
17071 REPLACE_NULL=1
17072 STDDEF_H=stddef.h
17073 fi
17074
17075 if test -n "$STDDEF_H"; then
17076 GL_GENERATE_STDDEF_H_TRUE=
17077 GL_GENERATE_STDDEF_H_FALSE='#'
17078else
17079 GL_GENERATE_STDDEF_H_TRUE='#'
17080 GL_GENERATE_STDDEF_H_FALSE=
17081fi
17082
17083 if test -n "$STDDEF_H"; then
17084
17085
17086
17087
17088
17089
17090
17091
17092 if test $gl_cv_have_include_next = yes; then
17093 gl_cv_next_stddef_h='<'stddef.h'>'
17094 else
17095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
17096$as_echo_n "checking absolute name of <stddef.h>... " >&6; }
17097if test "${gl_cv_next_stddef_h+set}" = set; then :
17098 $as_echo_n "(cached) " >&6
17099else
17100
4a626d0a
PA
17101
17102
17103 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
63ce7108
TT
17104/* end confdefs.h. */
17105#include <stddef.h>
63ce7108 17106_ACEOF
4a626d0a
PA
17107 case "$host_os" in
17108 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17109 *) gl_absname_cpp="$ac_cpp" ;;
17110 esac
63ce7108 17111
4a626d0a
PA
17112 case "$host_os" in
17113 mingw*)
17114 gl_dirsep_regex='[/\\]'
17115 ;;
17116 *)
17117 gl_dirsep_regex='\/'
17118 ;;
17119 esac
17120 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17121 gl_header_literal_regex=`echo 'stddef.h' \
17122 | sed -e "$gl_make_literal_regex_sed"`
17123 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17124 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17125 s|^/[^/]|//&|
17126 p
17127 q
17128 }'
63ce7108 17129
4a626d0a
PA
17130 gl_cv_absolute_stddef_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17131 sed -n "$gl_absolute_header_sed"`
17132
17133 gl_header=$gl_cv_absolute_stddef_h
17134 gl_cv_next_stddef_h='"'$gl_header'"'
63ce7108
TT
17135
17136
17137fi
17138{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
17139$as_echo "$gl_cv_next_stddef_h" >&6; }
17140 fi
17141 NEXT_STDDEF_H=$gl_cv_next_stddef_h
17142
17143 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17144 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17145 gl_next_as_first_directive='<'stddef.h'>'
17146 else
17147 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17148 gl_next_as_first_directive=$gl_cv_next_stddef_h
17149 fi
17150 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
17151
17152
17153
17154
17155 fi
17156
17157
17158
17159
17160
17161
17162
98399780
YQ
17163
17164
17165
17166
17167
4a626d0a
PA
17168
17169
6a29c58e
YQ
17170 if test $gl_cv_have_include_next = yes; then
17171 gl_cv_next_stdio_h='<'stdio.h'>'
17172 else
17173 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
17174$as_echo_n "checking absolute name of <stdio.h>... " >&6; }
17175if test "${gl_cv_next_stdio_h+set}" = set; then :
17176 $as_echo_n "(cached) " >&6
17177else
17178
4a626d0a
PA
17179
17180
17181 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6a29c58e
YQ
17182/* end confdefs.h. */
17183#include <stdio.h>
6a29c58e 17184_ACEOF
4a626d0a
PA
17185 case "$host_os" in
17186 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17187 *) gl_absname_cpp="$ac_cpp" ;;
17188 esac
17189
17190 case "$host_os" in
17191 mingw*)
17192 gl_dirsep_regex='[/\\]'
17193 ;;
17194 *)
17195 gl_dirsep_regex='\/'
17196 ;;
17197 esac
17198 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17199 gl_header_literal_regex=`echo 'stdio.h' \
17200 | sed -e "$gl_make_literal_regex_sed"`
17201 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17202 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17203 s|^/[^/]|//&|
17204 p
17205 q
17206 }'
6a29c58e 17207
4a626d0a
PA
17208 gl_cv_absolute_stdio_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17209 sed -n "$gl_absolute_header_sed"`
6a29c58e 17210
4a626d0a
PA
17211 gl_header=$gl_cv_absolute_stdio_h
17212 gl_cv_next_stdio_h='"'$gl_header'"'
6a29c58e
YQ
17213
17214
17215fi
17216{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
17217$as_echo "$gl_cv_next_stdio_h" >&6; }
17218 fi
17219 NEXT_STDIO_H=$gl_cv_next_stdio_h
17220
17221 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17222 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17223 gl_next_as_first_directive='<'stdio.h'>'
17224 else
17225 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17226 gl_next_as_first_directive=$gl_cv_next_stdio_h
17227 fi
17228 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
17229
17230
17231
17232
17233
4a626d0a
PA
17234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which flavor of printf attribute matches inttypes macros" >&5
17235$as_echo_n "checking which flavor of printf attribute matches inttypes macros... " >&6; }
17236if test "${gl_cv_func_printf_attribute_flavor+set}" = set; then :
17237 $as_echo_n "(cached) " >&6
17238else
17239 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17240/* end confdefs.h. */
17241
17242 #define __STDC_FORMAT_MACROS 1
17243 #include <stdio.h>
17244 #include <inttypes.h>
17245 /* For non-mingw systems, compilation will trivially succeed.
17246 For mingw, compilation will succeed for older mingw (system
17247 printf, "I64d") and fail for newer mingw (gnu printf, "lld"). */
17248 #if ((defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__) && \
17249 (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4))
17250 extern char PRIdMAX_probe[sizeof PRIdMAX == sizeof "I64d" ? 1 : -1];
17251 #endif
17252
17253int
17254main ()
17255{
17256
17257 ;
17258 return 0;
17259}
17260_ACEOF
17261if ac_fn_c_try_compile "$LINENO"; then :
17262 gl_cv_func_printf_attribute_flavor=system
17263else
17264 gl_cv_func_printf_attribute_flavor=gnu
17265fi
17266rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17267fi
17268{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_attribute_flavor" >&5
17269$as_echo "$gl_cv_func_printf_attribute_flavor" >&6; }
17270 if test "$gl_cv_func_printf_attribute_flavor" = gnu; then
17271
17272$as_echo "#define GNULIB_PRINTF_ATTRIBUTE_FLAVOR_GNU 1" >>confdefs.h
17273
17274 fi
17275
6a29c58e
YQ
17276 GNULIB_FSCANF=1
17277
17278
17279cat >>confdefs.h <<_ACEOF
17280#define GNULIB_FSCANF 1
17281_ACEOF
17282
17283
17284 GNULIB_SCANF=1
17285
17286
17287cat >>confdefs.h <<_ACEOF
17288#define GNULIB_SCANF 1
17289_ACEOF
17290
17291
17292 GNULIB_FGETC=1
17293 GNULIB_GETC=1
17294 GNULIB_GETCHAR=1
17295 GNULIB_FGETS=1
17296 GNULIB_FREAD=1
17297
17298
17299 GNULIB_FPRINTF=1
17300 GNULIB_PRINTF=1
17301 GNULIB_VFPRINTF=1
17302 GNULIB_VPRINTF=1
17303 GNULIB_FPUTC=1
17304 GNULIB_PUTC=1
17305 GNULIB_PUTCHAR=1
17306 GNULIB_FPUTS=1
17307 GNULIB_PUTS=1
17308 GNULIB_FWRITE=1
17309
17310
17311
17312
17313 for gl_func in dprintf fpurge fseeko ftello getdelim getline gets pclose popen renameat snprintf tmpfile vdprintf vsnprintf; do
17314 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
17315 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
17316$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
17317if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
17318 $as_echo_n "(cached) " >&6
17319else
17320 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17321/* end confdefs.h. */
17322#include <stdio.h>
17323
17324int
17325main ()
17326{
17327#undef $gl_func
17328 (void) $gl_func;
17329 ;
17330 return 0;
17331}
17332_ACEOF
17333if ac_fn_c_try_compile "$LINENO"; then :
17334 eval "$as_gl_Symbol=yes"
17335else
17336 eval "$as_gl_Symbol=no"
17337fi
17338rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17339fi
17340eval ac_res=\$$as_gl_Symbol
17341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
17342$as_echo "$ac_res" >&6; }
17343 eval as_val=\$$as_gl_Symbol
17344 if test "x$as_val" = x""yes; then :
17345 cat >>confdefs.h <<_ACEOF
17346#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
17347_ACEOF
17348
17349 eval ac_cv_have_decl_$gl_func=yes
17350fi
17351 done
17352
17353
17354
17355
17356
17357
17358
17359
17360
17361
17362
17363
98399780
YQ
17364 if test $gl_cv_have_include_next = yes; then
17365 gl_cv_next_stdlib_h='<'stdlib.h'>'
17366 else
17367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
17368$as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
17369if test "${gl_cv_next_stdlib_h+set}" = set; then :
17370 $as_echo_n "(cached) " >&6
17371else
17372
4a626d0a
PA
17373
17374
17375 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
98399780
YQ
17376/* end confdefs.h. */
17377#include <stdlib.h>
98399780 17378_ACEOF
4a626d0a
PA
17379 case "$host_os" in
17380 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17381 *) gl_absname_cpp="$ac_cpp" ;;
17382 esac
17383
17384 case "$host_os" in
17385 mingw*)
17386 gl_dirsep_regex='[/\\]'
17387 ;;
17388 *)
17389 gl_dirsep_regex='\/'
17390 ;;
17391 esac
17392 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17393 gl_header_literal_regex=`echo 'stdlib.h' \
17394 | sed -e "$gl_make_literal_regex_sed"`
17395 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17396 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17397 s|^/[^/]|//&|
17398 p
17399 q
17400 }'
98399780 17401
4a626d0a
PA
17402 gl_cv_absolute_stdlib_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17403 sed -n "$gl_absolute_header_sed"`
98399780 17404
4a626d0a
PA
17405 gl_header=$gl_cv_absolute_stdlib_h
17406 gl_cv_next_stdlib_h='"'$gl_header'"'
98399780
YQ
17407
17408
17409fi
17410{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
17411$as_echo "$gl_cv_next_stdlib_h" >&6; }
17412 fi
17413 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
17414
17415 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17416 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17417 gl_next_as_first_directive='<'stdlib.h'>'
17418 else
17419 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17420 gl_next_as_first_directive=$gl_cv_next_stdlib_h
17421 fi
17422 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
17423
17424
17425
17426
17427
17428
4a626d0a 17429 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
98399780
YQ
17430 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
17431 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
17432$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
17433if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
17434 $as_echo_n "(cached) " >&6
17435else
17436 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17437/* end confdefs.h. */
17438#include <stdlib.h>
17439#if HAVE_SYS_LOADAVG_H
17440# include <sys/loadavg.h>
17441#endif
17442#if HAVE_RANDOM_H
17443# include <random.h>
17444#endif
17445
17446int
17447main ()
17448{
17449#undef $gl_func
17450 (void) $gl_func;
17451 ;
17452 return 0;
17453}
17454_ACEOF
17455if ac_fn_c_try_compile "$LINENO"; then :
17456 eval "$as_gl_Symbol=yes"
17457else
17458 eval "$as_gl_Symbol=no"
17459fi
17460rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17461fi
17462eval ac_res=\$$as_gl_Symbol
17463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
17464$as_echo "$ac_res" >&6; }
17465 eval as_val=\$$as_gl_Symbol
17466 if test "x$as_val" = x""yes; then :
17467 cat >>confdefs.h <<_ACEOF
17468#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
17469_ACEOF
17470
17471 eval ac_cv_have_decl_$gl_func=yes
17472fi
17473 done
17474
17475
17476
17477
17478
17479
8424cc97
SM
17480 for ac_func in strchrnul
17481do :
17482 ac_fn_c_check_func "$LINENO" "strchrnul" "ac_cv_func_strchrnul"
17483if test "x$ac_cv_func_strchrnul" = x""yes; then :
17484 cat >>confdefs.h <<_ACEOF
17485#define HAVE_STRCHRNUL 1
17486_ACEOF
17487
17488fi
17489done
17490
17491 if test $ac_cv_func_strchrnul = no; then
17492 HAVE_STRCHRNUL=0
17493 else
17494 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strchrnul works" >&5
17495$as_echo_n "checking whether strchrnul works... " >&6; }
17496if test "${gl_cv_func_strchrnul_works+set}" = set; then :
17497 $as_echo_n "(cached) " >&6
17498else
17499 if test "$cross_compiling" = yes; then :
17500 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17501/* end confdefs.h. */
17502
17503#if defined __CYGWIN__
17504 #include <cygwin/version.h>
17505 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 9)
17506 Lucky user
17507 #endif
17508#else
17509 Lucky user
17510#endif
17511
17512_ACEOF
17513if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17514 $EGREP "Lucky user" >/dev/null 2>&1; then :
17515 gl_cv_func_strchrnul_works="guessing yes"
17516else
17517 gl_cv_func_strchrnul_works="guessing no"
17518fi
17519rm -f conftest*
17520
17521
17522else
17523 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17524/* end confdefs.h. */
17525
17526#include <string.h> /* for strchrnul */
17527
17528int
17529main ()
17530{
17531const char *buf = "a";
17532 return strchrnul (buf, 'b') != buf + 1;
17533
17534 ;
17535 return 0;
17536}
17537_ACEOF
17538if ac_fn_c_try_run "$LINENO"; then :
17539 gl_cv_func_strchrnul_works=yes
17540else
17541 gl_cv_func_strchrnul_works=no
17542fi
17543rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17544 conftest.$ac_objext conftest.beam conftest.$ac_ext
17545fi
17546
17547
17548fi
17549{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strchrnul_works" >&5
17550$as_echo "$gl_cv_func_strchrnul_works" >&6; }
17551 case "$gl_cv_func_strchrnul_works" in
17552 *yes) ;;
17553 *) REPLACE_STRCHRNUL=1 ;;
17554 esac
17555 fi
17556
17557 if test $HAVE_STRCHRNUL = 0 || test $REPLACE_STRCHRNUL = 1; then
17558
17559
17560
17561
17562
17563
17564
17565
17566 gl_LIBOBJS="$gl_LIBOBJS strchrnul.$ac_objext"
17567
17568 :
17569 fi
17570
17571
17572
17573
17574
17575 GNULIB_STRCHRNUL=1
17576
17577
17578
17579
17580
17581$as_echo "#define GNULIB_TEST_STRCHRNUL 1" >>confdefs.h
17582
17583
17584
17585
17586
17587
17588
98399780 17589
63ce7108
TT
17590 if test $REPLACE_STRSTR = 0; then
17591 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strstr works in linear time" >&5
17592$as_echo_n "checking whether strstr works in linear time... " >&6; }
17593if test "${gl_cv_func_strstr_linear+set}" = set; then :
17594 $as_echo_n "(cached) " >&6
17595else
17596 if test "$cross_compiling" = yes; then :
17597 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17598/* end confdefs.h. */
17599
17600#include <features.h>
17601#ifdef __GNU_LIBRARY__
17602 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ > 12) || (__GLIBC__ > 2)) \
17603 && !(defined __i386__ || defined __x86_64__) \
17604 && !defined __UCLIBC__
17605 Lucky user
17606 #endif
17607#endif
17608#ifdef __CYGWIN__
17609 #include <cygwin/version.h>
17610 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
17611 Lucky user
17612 #endif
17613#endif
17614
17615_ACEOF
17616if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17617 $EGREP "Lucky user" >/dev/null 2>&1; then :
17618 gl_cv_func_strstr_linear="guessing yes"
c971b7fa 17619else
63ce7108 17620 gl_cv_func_strstr_linear="guessing no"
c971b7fa
PA
17621fi
17622rm -f conftest*
17623
17624
17625else
17626 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17627/* end confdefs.h. */
17628
17629#include <signal.h> /* for signal */
63ce7108 17630#include <string.h> /* for strstr */
c971b7fa
PA
17631#include <stdlib.h> /* for malloc */
17632#include <unistd.h> /* for alarm */
17633static void quit (int sig) { exit (sig + 128); }
17634
17635int
17636main ()
17637{
17638
17639 int result = 0;
17640 size_t m = 1000000;
63ce7108
TT
17641 char *haystack = (char *) malloc (2 * m + 2);
17642 char *needle = (char *) malloc (m + 2);
c971b7fa 17643 /* Failure to compile this test due to missing alarm is okay,
63ce7108 17644 since all such platforms (mingw) also have quadratic strstr. */
c971b7fa
PA
17645 signal (SIGALRM, quit);
17646 alarm (5);
17647 /* Check for quadratic performance. */
17648 if (haystack && needle)
17649 {
17650 memset (haystack, 'A', 2 * m);
17651 haystack[2 * m] = 'B';
63ce7108 17652 haystack[2 * m + 1] = 0;
c971b7fa
PA
17653 memset (needle, 'A', m);
17654 needle[m] = 'B';
63ce7108
TT
17655 needle[m + 1] = 0;
17656 if (!strstr (haystack, needle))
c971b7fa
PA
17657 result |= 1;
17658 }
17659 return result;
17660
17661 ;
17662 return 0;
17663}
17664_ACEOF
17665if ac_fn_c_try_run "$LINENO"; then :
63ce7108 17666 gl_cv_func_strstr_linear=yes
c971b7fa 17667else
63ce7108 17668 gl_cv_func_strstr_linear=no
c971b7fa
PA
17669fi
17670rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17671 conftest.$ac_objext conftest.beam conftest.$ac_ext
17672fi
17673
17674
17675fi
63ce7108
TT
17676{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strstr_linear" >&5
17677$as_echo "$gl_cv_func_strstr_linear" >&6; }
17678 case "$gl_cv_func_strstr_linear" in
40a73391
JK
17679 *yes) ;;
17680 *)
63ce7108 17681 REPLACE_STRSTR=1
40a73391
JK
17682 ;;
17683 esac
c971b7fa
PA
17684 fi
17685
63ce7108 17686 if test $REPLACE_STRSTR = 1; then
c971b7fa
PA
17687
17688
17689
17690
17691
17692
17693
17694
63ce7108 17695 gl_LIBOBJS="$gl_LIBOBJS strstr.$ac_objext"
c971b7fa 17696
a512b375 17697 fi
c971b7fa
PA
17698
17699
17700
63ce7108
TT
17701 if test "$gl_cv_func_memchr_works" != yes; then
17702 REPLACE_STRSTR=1
c971b7fa 17703 else
63ce7108
TT
17704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strstr works" >&5
17705$as_echo_n "checking whether strstr works... " >&6; }
17706if test "${gl_cv_func_strstr_works_always+set}" = set; then :
c971b7fa
PA
17707 $as_echo_n "(cached) " >&6
17708else
17709 if test "$cross_compiling" = yes; then :
63ce7108 17710 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
c971b7fa
PA
17711/* end confdefs.h. */
17712
17713#ifdef __GNU_LIBRARY__
17714 #include <features.h>
63ce7108 17715 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ > 12) || (__GLIBC__ > 2)) \
c971b7fa
PA
17716 || defined __UCLIBC__
17717 Lucky user
17718 #endif
17719#elif defined __CYGWIN__
17720 #include <cygwin/version.h>
17721 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
17722 Lucky user
17723 #endif
17724#else
17725 Lucky user
17726#endif
17727
17728_ACEOF
17729if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17730 $EGREP "Lucky user" >/dev/null 2>&1; then :
63ce7108 17731 gl_cv_func_strstr_works_always="guessing yes"
c971b7fa 17732else
63ce7108 17733 gl_cv_func_strstr_works_always="guessing no"
c971b7fa
PA
17734fi
17735rm -f conftest*
17736
17737
17738else
17739 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17740/* end confdefs.h. */
17741
63ce7108 17742#include <string.h> /* for strstr */
c971b7fa
PA
17743#define P "_EF_BF_BD"
17744#define HAYSTACK "F_BD_CE_BD" P P P P "_C3_88_20" P P P "_C3_A7_20" P
17745#define NEEDLE P P P P P
17746
17747int
17748main ()
17749{
63ce7108 17750return !!strstr (HAYSTACK, NEEDLE);
c971b7fa
PA
17751
17752 ;
17753 return 0;
17754}
17755_ACEOF
17756if ac_fn_c_try_run "$LINENO"; then :
63ce7108 17757 gl_cv_func_strstr_works_always=yes
c971b7fa 17758else
63ce7108 17759 gl_cv_func_strstr_works_always=no
c971b7fa
PA
17760fi
17761rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17762 conftest.$ac_objext conftest.beam conftest.$ac_ext
17763fi
17764
17765
17766fi
63ce7108
TT
17767{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strstr_works_always" >&5
17768$as_echo "$gl_cv_func_strstr_works_always" >&6; }
17769 case "$gl_cv_func_strstr_works_always" in
40a73391
JK
17770 *yes) ;;
17771 *)
63ce7108 17772 REPLACE_STRSTR=1
40a73391
JK
17773 ;;
17774 esac
c971b7fa 17775 fi
8839a007 17776
63ce7108 17777 if test $REPLACE_STRSTR = 1; then
8839a007 17778
8690e634
JK
17779
17780
8690e634
JK
17781
17782
17783
17784
17785
63ce7108 17786 gl_LIBOBJS="$gl_LIBOBJS strstr.$ac_objext"
8690e634 17787
8690e634
JK
17788 fi
17789
8690e634
JK
17790
17791
8690e634 17792
8690e634 17793
63ce7108 17794 GNULIB_STRSTR=1
8690e634
JK
17795
17796
17797
8690e634
JK
17798
17799
63ce7108 17800$as_echo "#define GNULIB_TEST_STRSTR 1" >>confdefs.h
8690e634
JK
17801
17802
17803
17804
17805
17806
17807
421693b0
PA
17808 for ac_func in strtok_r
17809do :
17810 ac_fn_c_check_func "$LINENO" "strtok_r" "ac_cv_func_strtok_r"
17811if test "x$ac_cv_func_strtok_r" = x""yes; then :
17812 cat >>confdefs.h <<_ACEOF
17813#define HAVE_STRTOK_R 1
17814_ACEOF
17815
17816fi
17817done
17818
17819 if test $ac_cv_func_strtok_r = yes; then
17820 HAVE_STRTOK_R=1
17821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtok_r works" >&5
17822$as_echo_n "checking whether strtok_r works... " >&6; }
17823if test "${gl_cv_func_strtok_r_works+set}" = set; then :
17824 $as_echo_n "(cached) " >&6
17825else
17826 if test "$cross_compiling" = yes; then :
17827
17828 case "$host_os" in
17829 # Guess no on glibc systems.
17830 *-gnu*) gl_cv_func_strtok_r_works="guessing no";;
17831 *) gl_cv_func_strtok_r_works="guessing yes";;
17832 esac
17833
17834else
17835 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17836/* end confdefs.h. */
17837
17838 #ifndef __OPTIMIZE__
17839 # define __OPTIMIZE__ 1
17840 #endif
17841 #undef __OPTIMIZE_SIZE__
17842 #undef __NO_INLINE__
17843 #include <stdlib.h>
17844 #include <string.h>
17845
17846int
17847main ()
17848{
17849static const char dummy[] = "\177\01a";
17850 char delimiters[] = "xxxxxxxx";
17851 char *save_ptr = (char *) dummy;
17852 strtok_r (delimiters, "x", &save_ptr);
17853 strtok_r (NULL, "x", &save_ptr);
17854 return 0;
17855
17856 ;
17857 return 0;
17858}
17859
17860_ACEOF
17861if ac_fn_c_try_run "$LINENO"; then :
17862 gl_cv_func_strtok_r_works=yes
17863else
17864 gl_cv_func_strtok_r_works=no
17865fi
17866rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17867 conftest.$ac_objext conftest.beam conftest.$ac_ext
17868fi
17869
17870
17871fi
17872{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strtok_r_works" >&5
17873$as_echo "$gl_cv_func_strtok_r_works" >&6; }
17874 case "$gl_cv_func_strtok_r_works" in
17875 *no)
17876 UNDEFINE_STRTOK_R=1
17877 ;;
17878 esac
17879 else
17880 HAVE_STRTOK_R=0
17881 fi
17882
17883 if test $ac_cv_have_decl_strtok_r = no; then
17884 HAVE_DECL_STRTOK_R=0
17885 fi
17886
17887 if test $HAVE_STRTOK_R = 0 || test $REPLACE_STRTOK_R = 1; then
17888
17889
17890
17891
17892
17893
17894
17895
17896 gl_LIBOBJS="$gl_LIBOBJS strtok_r.$ac_objext"
17897
17898
17899 :
17900
17901 fi
17902
17903
17904
17905
17906
17907 GNULIB_STRTOK_R=1
17908
17909
17910
17911
17912
17913$as_echo "#define GNULIB_TEST_STRTOK_R 1" >>confdefs.h
17914
17915
17916
17917
17918
17919
17920
8690e634
JK
17921
17922
17923
17924
17925
8690e634 17926
09607c9e
TT
17927
17928
17929
17930
17931 if test $gl_cv_have_include_next = yes; then
17932 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
17933 else
17934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
17935$as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
17936if test "${gl_cv_next_sys_stat_h+set}" = set; then :
17937 $as_echo_n "(cached) " >&6
17938else
17939
17940 if test $ac_cv_header_sys_stat_h = yes; then
17941
17942
4a626d0a
PA
17943
17944
17945 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
09607c9e
TT
17946/* end confdefs.h. */
17947#include <sys/stat.h>
09607c9e 17948_ACEOF
4a626d0a
PA
17949 case "$host_os" in
17950 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17951 *) gl_absname_cpp="$ac_cpp" ;;
17952 esac
17953
17954 case "$host_os" in
17955 mingw*)
17956 gl_dirsep_regex='[/\\]'
17957 ;;
17958 *)
17959 gl_dirsep_regex='\/'
17960 ;;
17961 esac
17962 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17963 gl_header_literal_regex=`echo 'sys/stat.h' \
17964 | sed -e "$gl_make_literal_regex_sed"`
17965 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17966 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17967 s|^/[^/]|//&|
17968 p
17969 q
17970 }'
17971
17972 gl_cv_absolute_sys_stat_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17973 sed -n "$gl_absolute_header_sed"`
17974
17975 gl_header=$gl_cv_absolute_sys_stat_h
17976 gl_cv_next_sys_stat_h='"'$gl_header'"'
09607c9e
TT
17977 else
17978 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
17979 fi
17980
17981
17982fi
17983{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
17984$as_echo "$gl_cv_next_sys_stat_h" >&6; }
17985 fi
17986 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
17987
17988 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17989 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17990 gl_next_as_first_directive='<'sys/stat.h'>'
17991 else
17992 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17993 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
17994 fi
17995 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
17996
17997
17998
17999
18000
18001
18002
18003
2196f55f 18004
09607c9e
TT
18005
18006
18007 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
18008
18009$as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
18010
18011 fi
18012
18013 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
18014 #include <sys/stat.h>
18015"
18016if test "x$ac_cv_type_nlink_t" = x""yes; then :
18017
18018else
18019
18020$as_echo "#define nlink_t int" >>confdefs.h
18021
18022fi
18023
18024
18025
18026 for gl_func in fchmodat fstat fstatat futimens lchmod lstat mkdirat mkfifo mkfifoat mknod mknodat stat utimensat; do
18027 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
18028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
18029$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
18030if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
18031 $as_echo_n "(cached) " >&6
18032else
18033 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18034/* end confdefs.h. */
18035#include <sys/stat.h>
18036
18037int
18038main ()
18039{
18040#undef $gl_func
18041 (void) $gl_func;
18042 ;
18043 return 0;
18044}
18045_ACEOF
18046if ac_fn_c_try_compile "$LINENO"; then :
18047 eval "$as_gl_Symbol=yes"
18048else
18049 eval "$as_gl_Symbol=no"
18050fi
18051rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18052fi
18053eval ac_res=\$$as_gl_Symbol
18054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18055$as_echo "$ac_res" >&6; }
18056 eval as_val=\$$as_gl_Symbol
18057 if test "x$as_val" = x""yes; then :
18058 cat >>confdefs.h <<_ACEOF
18059#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
18060_ACEOF
18061
18062 eval ac_cv_have_decl_$gl_func=yes
18063fi
18064 done
18065
18066
18067
18068
18069
18070
18071
18072
18073
18074
18075
18076
18077
18078
8839a007
PA
18079
18080
18081
18082
09607c9e
TT
18083
18084
8839a007
PA
18085
18086
18087
18088
18089 if test $gl_cv_have_include_next = yes; then
18090 gl_cv_next_unistd_h='<'unistd.h'>'
18091 else
18092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
18093$as_echo_n "checking absolute name of <unistd.h>... " >&6; }
18094if test "${gl_cv_next_unistd_h+set}" = set; then :
18095 $as_echo_n "(cached) " >&6
18096else
18097
18098 if test $ac_cv_header_unistd_h = yes; then
18099
18100
4a626d0a
PA
18101
18102
18103 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8839a007
PA
18104/* end confdefs.h. */
18105#include <unistd.h>
8839a007 18106_ACEOF
4a626d0a
PA
18107 case "$host_os" in
18108 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18109 *) gl_absname_cpp="$ac_cpp" ;;
18110 esac
18111
18112 case "$host_os" in
18113 mingw*)
18114 gl_dirsep_regex='[/\\]'
18115 ;;
18116 *)
18117 gl_dirsep_regex='\/'
18118 ;;
18119 esac
18120 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18121 gl_header_literal_regex=`echo 'unistd.h' \
18122 | sed -e "$gl_make_literal_regex_sed"`
18123 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18124 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18125 s|^/[^/]|//&|
18126 p
18127 q
18128 }'
18129
18130 gl_cv_absolute_unistd_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18131 sed -n "$gl_absolute_header_sed"`
18132
18133 gl_header=$gl_cv_absolute_unistd_h
18134 gl_cv_next_unistd_h='"'$gl_header'"'
8839a007
PA
18135 else
18136 gl_cv_next_unistd_h='<'unistd.h'>'
18137 fi
18138
18139
18140fi
18141{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
18142$as_echo "$gl_cv_next_unistd_h" >&6; }
18143 fi
18144 NEXT_UNISTD_H=$gl_cv_next_unistd_h
18145
18146 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18147 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18148 gl_next_as_first_directive='<'unistd.h'>'
18149 else
18150 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18151 gl_next_as_first_directive=$gl_cv_next_unistd_h
18152 fi
18153 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
18154
18155
18156
18157
18158 if test $ac_cv_header_unistd_h = yes; then
18159 HAVE_UNISTD_H=1
18160 else
18161 HAVE_UNISTD_H=0
18162 fi
18163
18164
18165
18166
18167
18168
18169
18170 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
18171 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
18172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
18173$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
18174if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
18175 $as_echo_n "(cached) " >&6
18176else
18177 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18178/* end confdefs.h. */
18179
18180#if HAVE_UNISTD_H
18181# include <unistd.h>
18182#endif
18183/* Some systems declare various items in the wrong headers. */
18184#if !(defined __GLIBC__ && !defined __UCLIBC__)
18185# include <fcntl.h>
18186# include <stdio.h>
18187# include <stdlib.h>
18188# if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
18189# include <io.h>
18190# endif
18191#endif
18192
18193int
18194main ()
18195{
18196#undef $gl_func
18197 (void) $gl_func;
18198 ;
18199 return 0;
18200}
18201_ACEOF
18202if ac_fn_c_try_compile "$LINENO"; then :
18203 eval "$as_gl_Symbol=yes"
18204else
18205 eval "$as_gl_Symbol=no"
18206fi
18207rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18208fi
18209eval ac_res=\$$as_gl_Symbol
18210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18211$as_echo "$ac_res" >&6; }
18212 eval as_val=\$$as_gl_Symbol
18213 if test "x$as_val" = x""yes; then :
18214 cat >>confdefs.h <<_ACEOF
18215#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
18216_ACEOF
18217
18218 eval ac_cv_have_decl_$gl_func=yes
18219fi
18220 done
18221
18222
18223
18224
18225
18226
18227
18228
18229
18230
18231
18232
8690e634
JK
18233
18234
18235 if test $gl_cv_have_include_next = yes; then
18236 gl_cv_next_wchar_h='<'wchar.h'>'
18237 else
18238 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <wchar.h>" >&5
18239$as_echo_n "checking absolute name of <wchar.h>... " >&6; }
18240if test "${gl_cv_next_wchar_h+set}" = set; then :
18241 $as_echo_n "(cached) " >&6
18242else
18243
18244 if test $ac_cv_header_wchar_h = yes; then
18245
18246
4a626d0a
PA
18247
18248
18249 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8690e634
JK
18250/* end confdefs.h. */
18251#include <wchar.h>
8690e634 18252_ACEOF
4a626d0a
PA
18253 case "$host_os" in
18254 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18255 *) gl_absname_cpp="$ac_cpp" ;;
18256 esac
18257
18258 case "$host_os" in
18259 mingw*)
18260 gl_dirsep_regex='[/\\]'
18261 ;;
18262 *)
18263 gl_dirsep_regex='\/'
18264 ;;
18265 esac
18266 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18267 gl_header_literal_regex=`echo 'wchar.h' \
18268 | sed -e "$gl_make_literal_regex_sed"`
18269 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18270 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18271 s|^/[^/]|//&|
18272 p
18273 q
18274 }'
18275
18276 gl_cv_absolute_wchar_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18277 sed -n "$gl_absolute_header_sed"`
18278
18279 gl_header=$gl_cv_absolute_wchar_h
18280 gl_cv_next_wchar_h='"'$gl_header'"'
8690e634
JK
18281 else
18282 gl_cv_next_wchar_h='<'wchar.h'>'
18283 fi
18284
18285
18286fi
18287{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wchar_h" >&5
18288$as_echo "$gl_cv_next_wchar_h" >&6; }
18289 fi
18290 NEXT_WCHAR_H=$gl_cv_next_wchar_h
18291
18292 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18293 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18294 gl_next_as_first_directive='<'wchar.h'>'
18295 else
18296 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18297 gl_next_as_first_directive=$gl_cv_next_wchar_h
18298 fi
18299 NEXT_AS_FIRST_DIRECTIVE_WCHAR_H=$gl_next_as_first_directive
18300
18301
18302
18303
18304 if test $ac_cv_header_wchar_h = yes; then
18305 HAVE_WCHAR_H=1
18306 else
18307 HAVE_WCHAR_H=0
18308 fi
18309
c971b7fa
PA
18310
18311
18312
18313
8690e634
JK
18314 if test $gt_cv_c_wint_t = yes; then
18315 HAVE_WINT_T=1
18316 else
18317 HAVE_WINT_T=0
18318 fi
c971b7fa
PA
18319
18320
18321
8690e634
JK
18322 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
18323 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
18324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
18325$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
18326if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
c971b7fa
PA
18327 $as_echo_n "(cached) " >&6
18328else
18329 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18330/* end confdefs.h. */
8690e634
JK
18331
18332/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
18333 <wchar.h>.
18334 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18335 included before <wchar.h>. */
18336#if !(defined __GLIBC__ && !defined __UCLIBC__)
18337# include <stddef.h>
18338# include <stdio.h>
18339# include <time.h>
18340#endif
18341#include <wchar.h>
c971b7fa
PA
18342
18343int
18344main ()
18345{
8690e634
JK
18346#undef $gl_func
18347 (void) $gl_func;
c971b7fa
PA
18348 ;
18349 return 0;
18350}
18351_ACEOF
18352if ac_fn_c_try_compile "$LINENO"; then :
8690e634 18353 eval "$as_gl_Symbol=yes"
c971b7fa 18354else
8690e634 18355 eval "$as_gl_Symbol=no"
c971b7fa
PA
18356fi
18357rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18358fi
8690e634
JK
18359eval ac_res=\$$as_gl_Symbol
18360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18361$as_echo "$ac_res" >&6; }
18362 eval as_val=\$$as_gl_Symbol
18363 if test "x$as_val" = x""yes; then :
18364 cat >>confdefs.h <<_ACEOF
18365#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
18366_ACEOF
c971b7fa 18367
8690e634 18368 eval ac_cv_have_decl_$gl_func=yes
c971b7fa 18369fi
8690e634
JK
18370 done
18371
18372
18373
18374
18375
18376
18377
8690e634
JK
18378 if test $ac_cv_func_iswcntrl = yes; then
18379 HAVE_ISWCNTRL=1
18380 else
18381 HAVE_ISWCNTRL=0
18382 fi
18383
18384
18385
8690e634
JK
18386 if test $gt_cv_c_wint_t = yes; then
18387 HAVE_WINT_T=1
18388 else
18389 HAVE_WINT_T=0
18390 fi
18391
18392
18393
18394
18395
18396
c971b7fa 18397
8690e634 18398
c971b7fa
PA
18399
18400
18401
18402 if test $gl_cv_have_include_next = yes; then
8690e634 18403 gl_cv_next_wctype_h='<'wctype.h'>'
c971b7fa 18404 else
8690e634
JK
18405 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <wctype.h>" >&5
18406$as_echo_n "checking absolute name of <wctype.h>... " >&6; }
18407if test "${gl_cv_next_wctype_h+set}" = set; then :
c971b7fa
PA
18408 $as_echo_n "(cached) " >&6
18409else
18410
8690e634
JK
18411 if test $ac_cv_header_wctype_h = yes; then
18412
18413
4a626d0a
PA
18414
18415
18416 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
c971b7fa 18417/* end confdefs.h. */
8690e634 18418#include <wctype.h>
c971b7fa 18419_ACEOF
4a626d0a
PA
18420 case "$host_os" in
18421 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18422 *) gl_absname_cpp="$ac_cpp" ;;
18423 esac
18424
18425 case "$host_os" in
18426 mingw*)
18427 gl_dirsep_regex='[/\\]'
18428 ;;
18429 *)
18430 gl_dirsep_regex='\/'
18431 ;;
18432 esac
18433 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18434 gl_header_literal_regex=`echo 'wctype.h' \
18435 | sed -e "$gl_make_literal_regex_sed"`
18436 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18437 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18438 s|^/[^/]|//&|
18439 p
18440 q
18441 }'
18442
18443 gl_cv_absolute_wctype_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18444 sed -n "$gl_absolute_header_sed"`
18445
18446 gl_header=$gl_cv_absolute_wctype_h
18447 gl_cv_next_wctype_h='"'$gl_header'"'
8690e634
JK
18448 else
18449 gl_cv_next_wctype_h='<'wctype.h'>'
18450 fi
c971b7fa
PA
18451
18452
18453fi
8690e634
JK
18454{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wctype_h" >&5
18455$as_echo "$gl_cv_next_wctype_h" >&6; }
c971b7fa 18456 fi
8690e634 18457 NEXT_WCTYPE_H=$gl_cv_next_wctype_h
c971b7fa
PA
18458
18459 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18460 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
8690e634 18461 gl_next_as_first_directive='<'wctype.h'>'
c971b7fa
PA
18462 else
18463 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
8690e634 18464 gl_next_as_first_directive=$gl_cv_next_wctype_h
c971b7fa 18465 fi
8690e634
JK
18466 NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H=$gl_next_as_first_directive
18467
18468
18469
18470
18471 if test $ac_cv_header_wctype_h = yes; then
18472 if test $ac_cv_func_iswcntrl = yes; then
18473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether iswcntrl works" >&5
18474$as_echo_n "checking whether iswcntrl works... " >&6; }
18475if test "${gl_cv_func_iswcntrl_works+set}" = set; then :
18476 $as_echo_n "(cached) " >&6
18477else
18478
18479 if test "$cross_compiling" = yes; then :
18480 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18481/* end confdefs.h. */
18482#include <stdlib.h>
18483 #if __GNU_LIBRARY__ == 1
18484 Linux libc5 i18n is broken.
18485 #endif
18486int
18487main ()
18488{
18489
18490 ;
18491 return 0;
18492}
18493_ACEOF
18494if ac_fn_c_try_compile "$LINENO"; then :
18495 gl_cv_func_iswcntrl_works="guessing yes"
18496else
18497 gl_cv_func_iswcntrl_works="guessing no"
18498fi
18499rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18500
18501else
18502 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18503/* end confdefs.h. */
18504
18505 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
18506 included before <wchar.h>.
18507 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
18508 must be included before <wchar.h>. */
18509 #include <stddef.h>
18510 #include <stdio.h>
18511 #include <time.h>
18512 #include <wchar.h>
18513 #include <wctype.h>
18514 int main () { return iswprint ('x') == 0; }
18515
18516_ACEOF
18517if ac_fn_c_try_run "$LINENO"; then :
18518 gl_cv_func_iswcntrl_works=yes
18519else
18520 gl_cv_func_iswcntrl_works=no
18521fi
18522rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18523 conftest.$ac_objext conftest.beam conftest.$ac_ext
18524fi
18525
18526
18527fi
18528{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_iswcntrl_works" >&5
18529$as_echo "$gl_cv_func_iswcntrl_works" >&6; }
18530 fi
18531 HAVE_WCTYPE_H=1
18532 else
18533 HAVE_WCTYPE_H=0
18534 fi
18535
18536
18537 case "$gl_cv_func_iswcntrl_works" in
18538 *yes) REPLACE_ISWCNTRL=0 ;;
18539 *) REPLACE_ISWCNTRL=1 ;;
18540 esac
18541
18542
18543 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_ISWCNTRL = 1; then
18544 :
18545 fi
18546
18547 if test $REPLACE_ISWCNTRL = 1; then
18548 REPLACE_TOWLOWER=1
18549 else
18550 for ac_func in towlower
18551do :
18552 ac_fn_c_check_func "$LINENO" "towlower" "ac_cv_func_towlower"
18553if test "x$ac_cv_func_towlower" = x""yes; then :
18554 cat >>confdefs.h <<_ACEOF
18555#define HAVE_TOWLOWER 1
18556_ACEOF
18557
18558fi
18559done
18560
18561 if test $ac_cv_func_towlower = yes; then
18562 REPLACE_TOWLOWER=0
18563 else
18564 ac_fn_c_check_decl "$LINENO" "towlower" "ac_cv_have_decl_towlower" "/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
18565 included before <wchar.h>.
18566 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
18567 must be included before <wchar.h>. */
18568 #include <stddef.h>
18569 #include <stdio.h>
18570 #include <time.h>
18571 #include <wchar.h>
18572 #if HAVE_WCTYPE_H
18573 # include <wctype.h>
18574 #endif
18575
18576"
18577if test "x$ac_cv_have_decl_towlower" = x""yes; then :
18578 ac_have_decl=1
18579else
18580 ac_have_decl=0
18581fi
18582
18583cat >>confdefs.h <<_ACEOF
18584#define HAVE_DECL_TOWLOWER $ac_have_decl
18585_ACEOF
18586
18587 if test $ac_cv_have_decl_towlower = yes; then
18588 REPLACE_TOWLOWER=1
18589 else
18590 REPLACE_TOWLOWER=0
18591 fi
18592 fi
18593 fi
18594
18595
18596 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_TOWLOWER = 1; then
18597 :
18598 fi
18599
18600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctype_t" >&5
18601$as_echo_n "checking for wctype_t... " >&6; }
18602if test "${gl_cv_type_wctype_t+set}" = set; then :
18603 $as_echo_n "(cached) " >&6
18604else
18605 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18606/* end confdefs.h. */
18607/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
18608 included before <wchar.h>.
18609 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
18610 must be included before <wchar.h>. */
18611 #include <stddef.h>
18612 #include <stdio.h>
18613 #include <time.h>
18614 #include <wchar.h>
18615 #if HAVE_WCTYPE_H
18616 # include <wctype.h>
18617 #endif
18618 wctype_t a;
18619
18620int
18621main ()
18622{
18623
18624 ;
18625 return 0;
18626}
18627_ACEOF
18628if ac_fn_c_try_compile "$LINENO"; then :
18629 gl_cv_type_wctype_t=yes
18630else
18631 gl_cv_type_wctype_t=no
18632fi
18633rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c971b7fa 18634
8690e634
JK
18635fi
18636{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctype_t" >&5
18637$as_echo "$gl_cv_type_wctype_t" >&6; }
18638 if test $gl_cv_type_wctype_t = no; then
18639 HAVE_WCTYPE_T=0
18640 fi
18641
18642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctrans_t" >&5
18643$as_echo_n "checking for wctrans_t... " >&6; }
18644if test "${gl_cv_type_wctrans_t+set}" = set; then :
18645 $as_echo_n "(cached) " >&6
18646else
18647 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18648/* end confdefs.h. */
18649/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
18650 included before <wchar.h>.
18651 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
18652 must be included before <wchar.h>. */
18653 #include <stddef.h>
18654 #include <stdio.h>
18655 #include <time.h>
18656 #include <wchar.h>
18657 #include <wctype.h>
18658 wctrans_t a;
c971b7fa 18659
8690e634
JK
18660int
18661main ()
18662{
c971b7fa 18663
8690e634
JK
18664 ;
18665 return 0;
18666}
18667_ACEOF
18668if ac_fn_c_try_compile "$LINENO"; then :
18669 gl_cv_type_wctrans_t=yes
18670else
18671 gl_cv_type_wctrans_t=no
18672fi
18673rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c971b7fa 18674
8690e634
JK
18675fi
18676{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctrans_t" >&5
18677$as_echo "$gl_cv_type_wctrans_t" >&6; }
18678 if test $gl_cv_type_wctrans_t = no; then
18679 HAVE_WCTRANS_T=0
c971b7fa
PA
18680 fi
18681
18682
8690e634
JK
18683 for gl_func in wctype iswctype wctrans towctrans ; do
18684 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
18685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
18686$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
18687if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
18688 $as_echo_n "(cached) " >&6
18689else
18690 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18691/* end confdefs.h. */
18692
18693/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
18694 <wchar.h>.
18695 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18696 included before <wchar.h>. */
18697#if !(defined __GLIBC__ && !defined __UCLIBC__)
18698# include <stddef.h>
18699# include <stdio.h>
18700# include <time.h>
18701# include <wchar.h>
18702#endif
18703#include <wctype.h>
18704
18705int
18706main ()
18707{
18708#undef $gl_func
18709 (void) $gl_func;
18710 ;
18711 return 0;
18712}
18713_ACEOF
18714if ac_fn_c_try_compile "$LINENO"; then :
18715 eval "$as_gl_Symbol=yes"
18716else
18717 eval "$as_gl_Symbol=no"
18718fi
18719rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18720fi
18721eval ac_res=\$$as_gl_Symbol
18722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18723$as_echo "$ac_res" >&6; }
18724 eval as_val=\$$as_gl_Symbol
18725 if test "x$as_val" = x""yes; then :
18726 cat >>confdefs.h <<_ACEOF
18727#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
18728_ACEOF
c971b7fa 18729
8690e634
JK
18730 eval ac_cv_have_decl_$gl_func=yes
18731fi
18732 done
c971b7fa
PA
18733
18734
18735 # End of code from modules
18736
18737
18738
18739
18740
18741
18742
18743
18744
18745 gltests_libdeps=
18746 gltests_ltlibdeps=
18747
18748
18749
18750
18751
18752
18753
18754
18755
18756 gl_source_base='tests'
18757 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
18758
18759 gl_module_indicator_condition=$gltests_WITNESS
18760
18761
18762
18763
18764
18765
18766
18767
18768
18769 LIBGNU_LIBDEPS="$gl_libdeps"
18770
18771 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
18772
18773
18774
18775# We don't use automake, but gnulib does. This line lets us generate
18776# its Makefile.in.
18777am__api_version='1.11'
18778
18779# Find a good install program. We prefer a C program (faster),
18780# so one script is as good as another. But avoid the broken or
18781# incompatible versions:
18782# SysV /etc/install, /usr/sbin/install
18783# SunOS /usr/etc/install
18784# IRIX /sbin/install
18785# AIX /bin/install
18786# AmigaOS /C/install, which installs bootblocks on floppy discs
18787# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
18788# AFS /usr/afsws/bin/install, which mishandles nonexistent args
18789# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
18790# OS/2's system install, which has a completely different semantic
18791# ./install, which can be erroneously created by make from ./install.sh.
18792# Reject install programs that cannot install multiple files.
18793{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
18794$as_echo_n "checking for a BSD-compatible install... " >&6; }
18795if test -z "$INSTALL"; then
18796if test "${ac_cv_path_install+set}" = set; then :
18797 $as_echo_n "(cached) " >&6
18798else
18799 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18800for as_dir in $PATH
18801do
18802 IFS=$as_save_IFS
18803 test -z "$as_dir" && as_dir=.
18804 # Account for people who put trailing slashes in PATH elements.
18805case $as_dir/ in #((
18806 ./ | .// | /[cC]/* | \
18807 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
18808 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
18809 /usr/ucb/* ) ;;
18810 *)
18811 # OSF1 and SCO ODT 3.0 have their own names for install.
18812 # Don't use installbsd from OSF since it installs stuff as root
18813 # by default.
18814 for ac_prog in ginstall scoinst install; do
18815 for ac_exec_ext in '' $ac_executable_extensions; do
18816 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
18817 if test $ac_prog = install &&
18818 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
18819 # AIX install. It has an incompatible calling convention.
18820 :
18821 elif test $ac_prog = install &&
18822 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
18823 # program-specific install script used by HP pwplus--don't use.
18824 :
18825 else
18826 rm -rf conftest.one conftest.two conftest.dir
18827 echo one > conftest.one
18828 echo two > conftest.two
18829 mkdir conftest.dir
18830 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
18831 test -s conftest.one && test -s conftest.two &&
18832 test -s conftest.dir/conftest.one &&
18833 test -s conftest.dir/conftest.two
18834 then
18835 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
18836 break 3
18837 fi
18838 fi
18839 fi
18840 done
18841 done
18842 ;;
18843esac
18844
18845 done
18846IFS=$as_save_IFS
18847
18848rm -rf conftest.one conftest.two conftest.dir
18849
18850fi
18851 if test "${ac_cv_path_install+set}" = set; then
18852 INSTALL=$ac_cv_path_install
18853 else
18854 # As a last resort, use the slow shell script. Don't cache a
18855 # value for INSTALL within a source directory, because that will
18856 # break other packages using the cache if that directory is
18857 # removed, or if the value is a relative name.
18858 INSTALL=$ac_install_sh
18859 fi
18860fi
18861{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
18862$as_echo "$INSTALL" >&6; }
18863
18864# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
18865# It thinks the first close brace ends the variable substitution.
18866test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
18867
18868test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
18869
18870test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
18871
18872{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
18873$as_echo_n "checking whether build environment is sane... " >&6; }
18874# Just in case
18875sleep 1
18876echo timestamp > conftest.file
18877# Reject unsafe characters in $srcdir or the absolute working directory
18878# name. Accept space and tab only in the latter.
18879am_lf='
18880'
18881case `pwd` in
18882 *[\\\"\#\$\&\'\`$am_lf]*)
18883 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
18884esac
18885case $srcdir in
18886 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
18887 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
18888esac
18889
18890# Do `set' in a subshell so we don't clobber the current shell's
18891# arguments. Must try -L first in case configure is actually a
18892# symlink; some systems play weird games with the mod time of symlinks
18893# (eg FreeBSD returns the mod time of the symlink's containing
18894# directory).
18895if (
18896 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
18897 if test "$*" = "X"; then
18898 # -L didn't work.
18899 set X `ls -t "$srcdir/configure" conftest.file`
18900 fi
18901 rm -f conftest.file
18902 if test "$*" != "X $srcdir/configure conftest.file" \
18903 && test "$*" != "X conftest.file $srcdir/configure"; then
18904
18905 # If neither matched, then we have a broken ls. This can happen
18906 # if, for instance, CONFIG_SHELL is bash and it inherits a
18907 # broken ls alias from the environment. This has actually
18908 # happened. Such a system could not be considered "sane".
18909 as_fn_error "ls -t appears to fail. Make sure there is not a broken
18910alias in your environment" "$LINENO" 5
18911 fi
18912
18913 test "$2" = conftest.file
18914 )
18915then
18916 # Ok.
18917 :
18918else
18919 as_fn_error "newly created file is older than distributed files!
18920Check your system clock" "$LINENO" 5
18921fi
18922{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18923$as_echo "yes" >&6; }
18924test "$program_prefix" != NONE &&
18925 program_transform_name="s&^&$program_prefix&;$program_transform_name"
18926# Use a double $ so make ignores it.
18927test "$program_suffix" != NONE &&
18928 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
18929# Double any \ or $.
18930# By default was `s,x,x', remove it if useless.
18931ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
18932program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
18933
18934# expand $ac_aux_dir to an absolute path
18935am_aux_dir=`cd $ac_aux_dir && pwd`
18936
18937if test x"${MISSING+set}" != xset; then
18938 case $am_aux_dir in
18939 *\ * | *\ *)
18940 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
18941 *)
18942 MISSING="\${SHELL} $am_aux_dir/missing" ;;
18943 esac
18944fi
18945# Use eval to expand $SHELL
18946if eval "$MISSING --run true"; then
18947 am_missing_run="$MISSING --run "
18948else
18949 am_missing_run=
18950 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
18951$as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
18952fi
18953
18954if test x"${install_sh}" != xset; then
18955 case $am_aux_dir in
18956 *\ * | *\ *)
18957 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
18958 *)
18959 install_sh="\${SHELL} $am_aux_dir/install-sh"
18960 esac
18961fi
18962
18963# Installed binaries are usually stripped using `strip' when the user
18964# run `make install-strip'. However `strip' might not be the right
18965# tool to use in cross-compilation environments, therefore Automake
18966# will honor the `STRIP' environment variable to overrule this program.
18967if test "$cross_compiling" != no; then
18968 if test -n "$ac_tool_prefix"; then
18969 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
18970set dummy ${ac_tool_prefix}strip; ac_word=$2
18971{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18972$as_echo_n "checking for $ac_word... " >&6; }
18973if test "${ac_cv_prog_STRIP+set}" = set; then :
18974 $as_echo_n "(cached) " >&6
18975else
18976 if test -n "$STRIP"; then
18977 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
18978else
18979as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18980for as_dir in $PATH
18981do
18982 IFS=$as_save_IFS
18983 test -z "$as_dir" && as_dir=.
18984 for ac_exec_ext in '' $ac_executable_extensions; do
18985 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
18986 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
18987 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18988 break 2
18989 fi
18990done
18991 done
18992IFS=$as_save_IFS
18993
18994fi
18995fi
18996STRIP=$ac_cv_prog_STRIP
18997if test -n "$STRIP"; then
18998 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
18999$as_echo "$STRIP" >&6; }
19000else
19001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19002$as_echo "no" >&6; }
19003fi
19004
19005
19006fi
19007if test -z "$ac_cv_prog_STRIP"; then
19008 ac_ct_STRIP=$STRIP
19009 # Extract the first word of "strip", so it can be a program name with args.
19010set dummy strip; ac_word=$2
19011{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19012$as_echo_n "checking for $ac_word... " >&6; }
19013if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
19014 $as_echo_n "(cached) " >&6
19015else
19016 if test -n "$ac_ct_STRIP"; then
19017 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
19018else
19019as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19020for as_dir in $PATH
19021do
19022 IFS=$as_save_IFS
19023 test -z "$as_dir" && as_dir=.
19024 for ac_exec_ext in '' $ac_executable_extensions; do
19025 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
19026 ac_cv_prog_ac_ct_STRIP="strip"
19027 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19028 break 2
19029 fi
19030done
19031 done
19032IFS=$as_save_IFS
19033
19034fi
19035fi
19036ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
19037if test -n "$ac_ct_STRIP"; then
19038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
19039$as_echo "$ac_ct_STRIP" >&6; }
19040else
19041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19042$as_echo "no" >&6; }
19043fi
19044
19045 if test "x$ac_ct_STRIP" = x; then
19046 STRIP=":"
19047 else
19048 case $cross_compiling:$ac_tool_warned in
19049yes:)
19050{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
19051$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
19052ac_tool_warned=yes ;;
19053esac
19054 STRIP=$ac_ct_STRIP
19055 fi
19056else
19057 STRIP="$ac_cv_prog_STRIP"
19058fi
19059
19060fi
19061INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
19062
c971b7fa
PA
19063mkdir_p="$MKDIR_P"
19064case $mkdir_p in
19065 [\\/$]* | ?:[\\/]*) ;;
19066 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
19067esac
19068
19069for ac_prog in gawk mawk nawk awk
19070do
19071 # Extract the first word of "$ac_prog", so it can be a program name with args.
19072set dummy $ac_prog; ac_word=$2
19073{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19074$as_echo_n "checking for $ac_word... " >&6; }
19075if test "${ac_cv_prog_AWK+set}" = set; then :
19076 $as_echo_n "(cached) " >&6
19077else
19078 if test -n "$AWK"; then
19079 ac_cv_prog_AWK="$AWK" # Let the user override the test.
19080else
19081as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19082for as_dir in $PATH
19083do
19084 IFS=$as_save_IFS
19085 test -z "$as_dir" && as_dir=.
19086 for ac_exec_ext in '' $ac_executable_extensions; do
19087 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
19088 ac_cv_prog_AWK="$ac_prog"
19089 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19090 break 2
19091 fi
19092done
19093 done
19094IFS=$as_save_IFS
19095
19096fi
19097fi
19098AWK=$ac_cv_prog_AWK
19099if test -n "$AWK"; then
19100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
19101$as_echo "$AWK" >&6; }
19102else
19103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19104$as_echo "no" >&6; }
19105fi
19106
19107
19108 test -n "$AWK" && break
19109done
19110
19111{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
19112$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
19113set x ${MAKE-make}
19114ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
19115if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
19116 $as_echo_n "(cached) " >&6
19117else
19118 cat >conftest.make <<\_ACEOF
19119SHELL = /bin/sh
19120all:
19121 @echo '@@@%%%=$(MAKE)=@@@%%%'
19122_ACEOF
19123# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
19124case `${MAKE-make} -f conftest.make 2>/dev/null` in
19125 *@@@%%%=?*=@@@%%%*)
19126 eval ac_cv_prog_make_${ac_make}_set=yes;;
19127 *)
19128 eval ac_cv_prog_make_${ac_make}_set=no;;
19129esac
19130rm -f conftest.make
19131fi
19132if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
19133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19134$as_echo "yes" >&6; }
19135 SET_MAKE=
19136else
19137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19138$as_echo "no" >&6; }
19139 SET_MAKE="MAKE=${MAKE-make}"
19140fi
19141
19142rm -rf .tst 2>/dev/null
19143mkdir .tst 2>/dev/null
19144if test -d .tst; then
19145 am__leading_dot=.
19146else
19147 am__leading_dot=_
19148fi
19149rmdir .tst 2>/dev/null
19150
19151DEPDIR="${am__leading_dot}deps"
19152
19153ac_config_commands="$ac_config_commands depfiles"
19154
19155
19156am_make=${MAKE-make}
19157cat > confinc << 'END'
19158am__doit:
19159 @echo this is the am__doit target
19160.PHONY: am__doit
19161END
19162# If we don't find an include directive, just comment out the code.
19163{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
19164$as_echo_n "checking for style of include used by $am_make... " >&6; }
19165am__include="#"
19166am__quote=
19167_am_result=none
19168# First try GNU make style include.
19169echo "include confinc" > confmf
19170# Ignore all kinds of additional output from `make'.
19171case `$am_make -s -f confmf 2> /dev/null` in #(
19172*the\ am__doit\ target*)
19173 am__include=include
19174 am__quote=
19175 _am_result=GNU
19176 ;;
19177esac
19178# Now try BSD make style include.
19179if test "$am__include" = "#"; then
19180 echo '.include "confinc"' > confmf
19181 case `$am_make -s -f confmf 2> /dev/null` in #(
19182 *the\ am__doit\ target*)
19183 am__include=.include
19184 am__quote="\""
19185 _am_result=BSD
19186 ;;
19187 esac
19188fi
19189
19190
19191{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
19192$as_echo "$_am_result" >&6; }
19193rm -f confinc confmf
19194
19195# Check whether --enable-dependency-tracking was given.
19196if test "${enable_dependency_tracking+set}" = set; then :
19197 enableval=$enable_dependency_tracking;
19198fi
19199
19200if test "x$enable_dependency_tracking" != xno; then
19201 am_depcomp="$ac_aux_dir/depcomp"
19202 AMDEPBACKSLASH='\'
19203fi
19204 if test "x$enable_dependency_tracking" != xno; then
19205 AMDEP_TRUE=
19206 AMDEP_FALSE='#'
19207else
19208 AMDEP_TRUE='#'
19209 AMDEP_FALSE=
19210fi
19211
19212
19213if test "`cd $srcdir && pwd`" != "`pwd`"; then
19214 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
19215 # is not polluted with repeated "-I."
19216 am__isrc=' -I$(srcdir)'
19217 # test to see if srcdir already configured
19218 if test -f $srcdir/config.status; then
19219 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
19220 fi
19221fi
19222
19223# test whether we have cygpath
19224if test -z "$CYGPATH_W"; then
19225 if (cygpath --version) >/dev/null 2>/dev/null; then
19226 CYGPATH_W='cygpath -w'
19227 else
19228 CYGPATH_W=echo
19229 fi
19230fi
19231
19232
19233# Define the identity of the package.
19234 PACKAGE=libgnu
19235 VERSION=UNUSED-VERSION
19236
19237
19238# Some tools Automake needs.
19239
19240ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
19241
19242
19243AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
19244
19245
19246AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
19247
19248
19249AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
19250
19251
19252MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
19253
19254# We need awk for the "check" target. The system "awk" is bad on
19255# some platforms.
19256# Always define AMTAR for backward compatibility.
19257
19258AMTAR=${AMTAR-"${am_missing_run}tar"}
19259
19260am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
19261
19262
19263
19264
19265depcc="$CC" am_compiler_list=
19266
19267{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
19268$as_echo_n "checking dependency style of $depcc... " >&6; }
19269if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
19270 $as_echo_n "(cached) " >&6
19271else
19272 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
19273 # We make a subdir and do the tests there. Otherwise we can end up
19274 # making bogus files that we don't know about and never remove. For
19275 # instance it was reported that on HP-UX the gcc test will end up
19276 # making a dummy file named `D' -- because `-MD' means `put the output
19277 # in D'.
19278 mkdir conftest.dir
19279 # Copy depcomp to subdir because otherwise we won't find it if we're
19280 # using a relative directory.
19281 cp "$am_depcomp" conftest.dir
19282 cd conftest.dir
19283 # We will build objects and dependencies in a subdirectory because
19284 # it helps to detect inapplicable dependency modes. For instance
19285 # both Tru64's cc and ICC support -MD to output dependencies as a
19286 # side effect of compilation, but ICC will put the dependencies in
19287 # the current directory while Tru64 will put them in the object
19288 # directory.
19289 mkdir sub
19290
19291 am_cv_CC_dependencies_compiler_type=none
19292 if test "$am_compiler_list" = ""; then
19293 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
19294 fi
19295 am__universal=false
19296 case " $depcc " in #(
19297 *\ -arch\ *\ -arch\ *) am__universal=true ;;
19298 esac
19299
19300 for depmode in $am_compiler_list; do
19301 # Setup a source with many dependencies, because some compilers
19302 # like to wrap large dependency lists on column 80 (with \), and
19303 # we should not choose a depcomp mode which is confused by this.
19304 #
19305 # We need to recreate these files for each test, as the compiler may
19306 # overwrite some of them when testing with obscure command lines.
19307 # This happens at least with the AIX C compiler.
19308 : > sub/conftest.c
19309 for i in 1 2 3 4 5 6; do
19310 echo '#include "conftst'$i'.h"' >> sub/conftest.c
19311 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
19312 # Solaris 8's {/usr,}/bin/sh.
19313 touch sub/conftst$i.h
19314 done
19315 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
19316
19317 # We check with `-c' and `-o' for the sake of the "dashmstdout"
19318 # mode. It turns out that the SunPro C++ compiler does not properly
19319 # handle `-M -o', and we need to detect this. Also, some Intel
19320 # versions had trouble with output in subdirs
19321 am__obj=sub/conftest.${OBJEXT-o}
19322 am__minus_obj="-o $am__obj"
19323 case $depmode in
19324 gcc)
19325 # This depmode causes a compiler race in universal mode.
19326 test "$am__universal" = false || continue
19327 ;;
19328 nosideeffect)
19329 # after this tag, mechanisms are not by side-effect, so they'll
19330 # only be used when explicitly requested
19331 if test "x$enable_dependency_tracking" = xyes; then
19332 continue
19333 else
19334 break
19335 fi
19336 ;;
19337 msvisualcpp | msvcmsys)
19338 # This compiler won't grok `-c -o', but also, the minuso test has
19339 # not run yet. These depmodes are late enough in the game, and
19340 # so weak that their functioning should not be impacted.
19341 am__obj=conftest.${OBJEXT-o}
19342 am__minus_obj=
19343 ;;
19344 none) break ;;
19345 esac
19346 if depmode=$depmode \
19347 source=sub/conftest.c object=$am__obj \
19348 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
19349 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
19350 >/dev/null 2>conftest.err &&
19351 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
19352 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
19353 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
19354 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
19355 # icc doesn't choke on unknown options, it will just issue warnings
19356 # or remarks (even with -Werror). So we grep stderr for any message
19357 # that says an option was ignored or not supported.
19358 # When given -MP, icc 7.0 and 7.1 complain thusly:
19359 # icc: Command line warning: ignoring option '-M'; no argument required
19360 # The diagnosis changed in icc 8.0:
19361 # icc: Command line remark: option '-MP' not supported
19362 if (grep 'ignoring option' conftest.err ||
19363 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
19364 am_cv_CC_dependencies_compiler_type=$depmode
19365 break
19366 fi
19367 fi
19368 done
19369
19370 cd ..
19371 rm -rf conftest.dir
19372else
19373 am_cv_CC_dependencies_compiler_type=none
19374fi
19375
19376fi
19377{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
19378$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
19379CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
19380
19381 if
19382 test "x$enable_dependency_tracking" != xno \
19383 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
19384 am__fastdepCC_TRUE=
19385 am__fastdepCC_FALSE='#'
19386else
19387 am__fastdepCC_TRUE='#'
19388 am__fastdepCC_FALSE=
19389fi
19390
19391
19392
19393
19394# --------------------- #
19395# Checks for programs. #
19396# --------------------- #
19397
19398
19399{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
19400$as_echo_n "checking whether ln -s works... " >&6; }
19401LN_S=$as_ln_s
19402if test "$LN_S" = "ln -s"; then
19403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19404$as_echo "yes" >&6; }
19405else
19406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
19407$as_echo "no, using $LN_S" >&6; }
19408fi
19409
19410if test -n "$ac_tool_prefix"; then
19411 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
19412set dummy ${ac_tool_prefix}ranlib; ac_word=$2
19413{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19414$as_echo_n "checking for $ac_word... " >&6; }
19415if test "${ac_cv_prog_RANLIB+set}" = set; then :
19416 $as_echo_n "(cached) " >&6
19417else
19418 if test -n "$RANLIB"; then
19419 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
19420else
19421as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19422for as_dir in $PATH
19423do
19424 IFS=$as_save_IFS
19425 test -z "$as_dir" && as_dir=.
19426 for ac_exec_ext in '' $ac_executable_extensions; do
19427 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
19428 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
19429 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19430 break 2
19431 fi
19432done
19433 done
19434IFS=$as_save_IFS
19435
19436fi
19437fi
19438RANLIB=$ac_cv_prog_RANLIB
19439if test -n "$RANLIB"; then
19440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
19441$as_echo "$RANLIB" >&6; }
19442else
19443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19444$as_echo "no" >&6; }
19445fi
19446
19447
19448fi
19449if test -z "$ac_cv_prog_RANLIB"; then
19450 ac_ct_RANLIB=$RANLIB
19451 # Extract the first word of "ranlib", so it can be a program name with args.
19452set dummy ranlib; ac_word=$2
19453{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19454$as_echo_n "checking for $ac_word... " >&6; }
19455if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
19456 $as_echo_n "(cached) " >&6
19457else
19458 if test -n "$ac_ct_RANLIB"; then
19459 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
19460else
19461as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19462for as_dir in $PATH
19463do
19464 IFS=$as_save_IFS
19465 test -z "$as_dir" && as_dir=.
19466 for ac_exec_ext in '' $ac_executable_extensions; do
19467 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
19468 ac_cv_prog_ac_ct_RANLIB="ranlib"
19469 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19470 break 2
19471 fi
19472done
19473 done
19474IFS=$as_save_IFS
19475
19476fi
19477fi
19478ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
19479if test -n "$ac_ct_RANLIB"; then
19480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
19481$as_echo "$ac_ct_RANLIB" >&6; }
19482else
19483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19484$as_echo "no" >&6; }
19485fi
19486
19487 if test "x$ac_ct_RANLIB" = x; then
19488 RANLIB=":"
19489 else
19490 case $cross_compiling:$ac_tool_warned in
19491yes:)
19492{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
19493$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
19494ac_tool_warned=yes ;;
19495esac
19496 RANLIB=$ac_ct_RANLIB
19497 fi
19498else
19499 RANLIB="$ac_cv_prog_RANLIB"
19500fi
19501
19502
19503if test -n "$ac_tool_prefix"; then
19504 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
19505set dummy ${ac_tool_prefix}ar; ac_word=$2
19506{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19507$as_echo_n "checking for $ac_word... " >&6; }
19508if test "${ac_cv_prog_AR+set}" = set; then :
19509 $as_echo_n "(cached) " >&6
19510else
19511 if test -n "$AR"; then
19512 ac_cv_prog_AR="$AR" # Let the user override the test.
19513else
19514as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19515for as_dir in $PATH
19516do
19517 IFS=$as_save_IFS
19518 test -z "$as_dir" && as_dir=.
19519 for ac_exec_ext in '' $ac_executable_extensions; do
19520 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
19521 ac_cv_prog_AR="${ac_tool_prefix}ar"
19522 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19523 break 2
19524 fi
19525done
19526 done
19527IFS=$as_save_IFS
19528
19529fi
19530fi
19531AR=$ac_cv_prog_AR
19532if test -n "$AR"; then
19533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
19534$as_echo "$AR" >&6; }
19535else
19536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19537$as_echo "no" >&6; }
19538fi
19539
19540
19541fi
19542if test -z "$ac_cv_prog_AR"; then
19543 ac_ct_AR=$AR
19544 # Extract the first word of "ar", so it can be a program name with args.
19545set dummy ar; ac_word=$2
19546{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19547$as_echo_n "checking for $ac_word... " >&6; }
19548if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
19549 $as_echo_n "(cached) " >&6
19550else
19551 if test -n "$ac_ct_AR"; then
19552 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
19553else
19554as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19555for as_dir in $PATH
19556do
19557 IFS=$as_save_IFS
19558 test -z "$as_dir" && as_dir=.
19559 for ac_exec_ext in '' $ac_executable_extensions; do
19560 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
19561 ac_cv_prog_ac_ct_AR="ar"
19562 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19563 break 2
19564 fi
19565done
19566 done
19567IFS=$as_save_IFS
19568
19569fi
19570fi
19571ac_ct_AR=$ac_cv_prog_ac_ct_AR
19572if test -n "$ac_ct_AR"; then
19573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
19574$as_echo "$ac_ct_AR" >&6; }
19575else
19576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19577$as_echo "no" >&6; }
19578fi
19579
19580 if test "x$ac_ct_AR" = x; then
19581 AR=""
19582 else
19583 case $cross_compiling:$ac_tool_warned in
19584yes:)
19585{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
19586$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
19587ac_tool_warned=yes ;;
19588esac
19589 AR=$ac_ct_AR
19590 fi
19591else
19592 AR="$ac_cv_prog_AR"
19593fi
19594
19595
19596# ---------------------- #
19597# Checks for libraries. #
19598# ---------------------- #
19599
19600ac_config_files="$ac_config_files Makefile import/Makefile"
19601
19602ac_config_commands="$ac_config_commands default"
19603
19604cat >confcache <<\_ACEOF
19605# This file is a shell script that caches the results of configure
19606# tests run on this system so they can be shared between configure
19607# scripts and configure runs, see configure's option --config-cache.
19608# It is not useful on other systems. If it contains results you don't
19609# want to keep, you may remove or edit it.
19610#
19611# config.status only pays attention to the cache file if you give it
19612# the --recheck option to rerun configure.
19613#
19614# `ac_cv_env_foo' variables (set or unset) will be overridden when
19615# loading this file, other *unset* `ac_cv_foo' will be assigned the
19616# following values.
19617
19618_ACEOF
19619
19620# The following way of writing the cache mishandles newlines in values,
19621# but we know of no workaround that is simple, portable, and efficient.
19622# So, we kill variables containing newlines.
19623# Ultrix sh set writes to stderr and can't be redirected directly,
19624# and sets the high bit in the cache file unless we assign to the vars.
19625(
19626 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
19627 eval ac_val=\$$ac_var
19628 case $ac_val in #(
19629 *${as_nl}*)
19630 case $ac_var in #(
19631 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
19632$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
19633 esac
19634 case $ac_var in #(
19635 _ | IFS | as_nl) ;; #(
19636 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
19637 *) { eval $ac_var=; unset $ac_var;} ;;
19638 esac ;;
19639 esac
19640 done
19641
19642 (set) 2>&1 |
19643 case $as_nl`(ac_space=' '; set) 2>&1` in #(
19644 *${as_nl}ac_space=\ *)
19645 # `set' does not quote correctly, so add quotes: double-quote
19646 # substitution turns \\\\ into \\, and sed turns \\ into \.
19647 sed -n \
19648 "s/'/'\\\\''/g;
19649 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
19650 ;; #(
19651 *)
19652 # `set' quotes correctly as required by POSIX, so do not add quotes.
19653 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
19654 ;;
19655 esac |
19656 sort
19657) |
19658 sed '
19659 /^ac_cv_env_/b end
19660 t clear
19661 :clear
19662 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
19663 t end
19664 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
19665 :end' >>confcache
19666if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
19667 if test -w "$cache_file"; then
19668 test "x$cache_file" != "x/dev/null" &&
19669 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
19670$as_echo "$as_me: updating cache $cache_file" >&6;}
19671 cat confcache >$cache_file
19672 else
19673 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
19674$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
19675 fi
19676fi
19677rm -f confcache
19678
19679test "x$prefix" = xNONE && prefix=$ac_default_prefix
19680# Let make expand exec_prefix.
19681test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
19682
19683DEFS=-DHAVE_CONFIG_H
19684
19685ac_libobjs=
19686ac_ltlibobjs=
19687for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
19688 # 1. Remove the extension, and $U if already installed.
19689 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
19690 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
19691 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
19692 # will be set to the directory where LIBOBJS objects are built.
19693 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
19694 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
19695done
19696LIBOBJS=$ac_libobjs
19697
19698LTLIBOBJS=$ac_ltlibobjs
19699
19700
19701if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
19702 as_fn_error "conditional \"MAINTAINER_MODE\" was never defined.
19703Usually this means the macro was only invoked conditionally." "$LINENO" 5
19704fi
19705if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
19706 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
19707Usually this means the macro was only invoked conditionally." "$LINENO" 5
19708fi
8690e634
JK
19709if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
19710 as_fn_error "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
19711Usually this means the macro was only invoked conditionally." "$LINENO" 5
19712fi
18848e28
GF
19713if test -z "${GL_GENERATE_ERRNO_H_TRUE}" && test -z "${GL_GENERATE_ERRNO_H_FALSE}"; then
19714 as_fn_error "conditional \"GL_GENERATE_ERRNO_H\" was never defined.
19715Usually this means the macro was only invoked conditionally." "$LINENO" 5
19716fi
88b48903
WN
19717if test -z "${GL_GENERATE_FLOAT_H_TRUE}" && test -z "${GL_GENERATE_FLOAT_H_FALSE}"; then
19718 as_fn_error "conditional \"GL_GENERATE_FLOAT_H\" was never defined.
19719Usually this means the macro was only invoked conditionally." "$LINENO" 5
19720fi
8690e634
JK
19721if test -z "${GL_GENERATE_FNMATCH_H_TRUE}" && test -z "${GL_GENERATE_FNMATCH_H_FALSE}"; then
19722 as_fn_error "conditional \"GL_GENERATE_FNMATCH_H\" was never defined.
19723Usually this means the macro was only invoked conditionally." "$LINENO" 5
19724fi
c971b7fa
PA
19725if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
19726 as_fn_error "conditional \"GL_GENERATE_STDINT_H\" was never defined.
19727Usually this means the macro was only invoked conditionally." "$LINENO" 5
19728fi
88b48903
WN
19729
19730
8690e634
JK
19731if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
19732 as_fn_error "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
19733Usually this means the macro was only invoked conditionally." "$LINENO" 5
19734fi
c971b7fa
PA
19735if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
19736 as_fn_error "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
19737Usually this means the macro was only invoked conditionally." "$LINENO" 5
19738fi
19739
19740 gl_libobjs=
19741 gl_ltlibobjs=
19742 if test -n "$gl_LIBOBJS"; then
19743 # Remove the extension.
19744 sed_drop_objext='s/\.o$//;s/\.obj$//'
19745 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
19746 gl_libobjs="$gl_libobjs $i.$ac_objext"
19747 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
19748 done
19749 fi
19750 gl_LIBOBJS=$gl_libobjs
19751
19752 gl_LTLIBOBJS=$gl_ltlibobjs
19753
19754
19755
19756 gltests_libobjs=
19757 gltests_ltlibobjs=
19758 if test -n "$gltests_LIBOBJS"; then
19759 # Remove the extension.
19760 sed_drop_objext='s/\.o$//;s/\.obj$//'
19761 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
19762 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
19763 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
19764 done
19765 fi
19766 gltests_LIBOBJS=$gltests_libobjs
19767
19768 gltests_LTLIBOBJS=$gltests_ltlibobjs
19769
19770
19771if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
19772 as_fn_error "conditional \"AMDEP\" was never defined.
19773Usually this means the macro was only invoked conditionally." "$LINENO" 5
19774fi
19775if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
19776 as_fn_error "conditional \"am__fastdepCC\" was never defined.
19777Usually this means the macro was only invoked conditionally." "$LINENO" 5
19778fi
19779 if test -n "$EXEEXT"; then
19780 am__EXEEXT_TRUE=
19781 am__EXEEXT_FALSE='#'
19782else
19783 am__EXEEXT_TRUE='#'
19784 am__EXEEXT_FALSE=
19785fi
19786
19787
19788: ${CONFIG_STATUS=./config.status}
19789ac_write_fail=0
19790ac_clean_files_save=$ac_clean_files
19791ac_clean_files="$ac_clean_files $CONFIG_STATUS"
19792{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
19793$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
19794as_write_fail=0
19795cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
19796#! $SHELL
19797# Generated by $as_me.
19798# Run this file to recreate the current configuration.
19799# Compiler output produced by configure, useful for debugging
19800# configure, is in config.log if it exists.
19801
19802debug=false
19803ac_cs_recheck=false
19804ac_cs_silent=false
19805
19806SHELL=\${CONFIG_SHELL-$SHELL}
19807export SHELL
19808_ASEOF
19809cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
19810## -------------------- ##
19811## M4sh Initialization. ##
19812## -------------------- ##
19813
19814# Be more Bourne compatible
19815DUALCASE=1; export DUALCASE # for MKS sh
19816if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
19817 emulate sh
19818 NULLCMD=:
19819 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
19820 # is contrary to our usage. Disable this feature.
19821 alias -g '${1+"$@"}'='"$@"'
19822 setopt NO_GLOB_SUBST
19823else
19824 case `(set -o) 2>/dev/null` in #(
19825 *posix*) :
19826 set -o posix ;; #(
19827 *) :
19828 ;;
19829esac
19830fi
19831
19832
19833as_nl='
19834'
19835export as_nl
19836# Printing a long string crashes Solaris 7 /usr/bin/printf.
19837as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
19838as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
19839as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
19840# Prefer a ksh shell builtin over an external printf program on Solaris,
19841# but without wasting forks for bash or zsh.
19842if test -z "$BASH_VERSION$ZSH_VERSION" \
19843 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
19844 as_echo='print -r --'
19845 as_echo_n='print -rn --'
19846elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
19847 as_echo='printf %s\n'
19848 as_echo_n='printf %s'
19849else
19850 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
19851 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
19852 as_echo_n='/usr/ucb/echo -n'
19853 else
19854 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
19855 as_echo_n_body='eval
19856 arg=$1;
19857 case $arg in #(
19858 *"$as_nl"*)
19859 expr "X$arg" : "X\\(.*\\)$as_nl";
19860 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
19861 esac;
19862 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
19863 '
19864 export as_echo_n_body
19865 as_echo_n='sh -c $as_echo_n_body as_echo'
19866 fi
19867 export as_echo_body
19868 as_echo='sh -c $as_echo_body as_echo'
19869fi
19870
19871# The user is always right.
19872if test "${PATH_SEPARATOR+set}" != set; then
19873 PATH_SEPARATOR=:
19874 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
19875 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
19876 PATH_SEPARATOR=';'
19877 }
19878fi
19879
19880
19881# IFS
19882# We need space, tab and new line, in precisely that order. Quoting is
19883# there to prevent editors from complaining about space-tab.
19884# (If _AS_PATH_WALK were called with IFS unset, it would disable word
19885# splitting by setting IFS to empty value.)
19886IFS=" "" $as_nl"
19887
19888# Find who we are. Look in the path if we contain no directory separator.
19889case $0 in #((
19890 *[\\/]* ) as_myself=$0 ;;
19891 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19892for as_dir in $PATH
19893do
19894 IFS=$as_save_IFS
19895 test -z "$as_dir" && as_dir=.
19896 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
19897 done
19898IFS=$as_save_IFS
19899
19900 ;;
19901esac
19902# We did not find ourselves, most probably we were run as `sh COMMAND'
19903# in which case we are not to be found in the path.
19904if test "x$as_myself" = x; then
19905 as_myself=$0
19906fi
19907if test ! -f "$as_myself"; then
19908 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
19909 exit 1
19910fi
19911
19912# Unset variables that we do not need and which cause bugs (e.g. in
19913# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
19914# suppresses any "Segmentation fault" message there. '((' could
19915# trigger a bug in pdksh 5.2.14.
19916for as_var in BASH_ENV ENV MAIL MAILPATH
19917do eval test x\${$as_var+set} = xset \
19918 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
19919done
19920PS1='$ '
19921PS2='> '
19922PS4='+ '
19923
19924# NLS nuisances.
19925LC_ALL=C
19926export LC_ALL
19927LANGUAGE=C
19928export LANGUAGE
19929
19930# CDPATH.
19931(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
19932
19933
19934# as_fn_error ERROR [LINENO LOG_FD]
19935# ---------------------------------
19936# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
19937# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
19938# script with status $?, using 1 if that was 0.
19939as_fn_error ()
19940{
19941 as_status=$?; test $as_status -eq 0 && as_status=1
19942 if test "$3"; then
19943 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
19944 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
19945 fi
19946 $as_echo "$as_me: error: $1" >&2
19947 as_fn_exit $as_status
19948} # as_fn_error
19949
19950
19951# as_fn_set_status STATUS
19952# -----------------------
19953# Set $? to STATUS, without forking.
19954as_fn_set_status ()
19955{
19956 return $1
19957} # as_fn_set_status
19958
19959# as_fn_exit STATUS
19960# -----------------
19961# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
19962as_fn_exit ()
19963{
19964 set +e
19965 as_fn_set_status $1
19966 exit $1
19967} # as_fn_exit
19968
19969# as_fn_unset VAR
19970# ---------------
19971# Portably unset VAR.
19972as_fn_unset ()
19973{
19974 { eval $1=; unset $1;}
19975}
19976as_unset=as_fn_unset
19977# as_fn_append VAR VALUE
19978# ----------------------
19979# Append the text in VALUE to the end of the definition contained in VAR. Take
19980# advantage of any shell optimizations that allow amortized linear growth over
19981# repeated appends, instead of the typical quadratic growth present in naive
19982# implementations.
19983if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
19984 eval 'as_fn_append ()
19985 {
19986 eval $1+=\$2
19987 }'
19988else
19989 as_fn_append ()
19990 {
19991 eval $1=\$$1\$2
19992 }
19993fi # as_fn_append
19994
19995# as_fn_arith ARG...
19996# ------------------
19997# Perform arithmetic evaluation on the ARGs, and store the result in the
19998# global $as_val. Take advantage of shells that can avoid forks. The arguments
19999# must be portable across $(()) and expr.
20000if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
20001 eval 'as_fn_arith ()
20002 {
20003 as_val=$(( $* ))
20004 }'
20005else
20006 as_fn_arith ()
20007 {
20008 as_val=`expr "$@" || test $? -eq 1`
20009 }
20010fi # as_fn_arith
20011
20012
20013if expr a : '\(a\)' >/dev/null 2>&1 &&
20014 test "X`expr 00001 : '.*\(...\)'`" = X001; then
20015 as_expr=expr
20016else
20017 as_expr=false
20018fi
20019
20020if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
20021 as_basename=basename
20022else
20023 as_basename=false
20024fi
20025
20026if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
20027 as_dirname=dirname
20028else
20029 as_dirname=false
20030fi
20031
20032as_me=`$as_basename -- "$0" ||
20033$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
20034 X"$0" : 'X\(//\)$' \| \
20035 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
20036$as_echo X/"$0" |
20037 sed '/^.*\/\([^/][^/]*\)\/*$/{
20038 s//\1/
20039 q
20040 }
20041 /^X\/\(\/\/\)$/{
20042 s//\1/
20043 q
20044 }
20045 /^X\/\(\/\).*/{
20046 s//\1/
20047 q
20048 }
20049 s/.*/./; q'`
20050
20051# Avoid depending upon Character Ranges.
20052as_cr_letters='abcdefghijklmnopqrstuvwxyz'
20053as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
20054as_cr_Letters=$as_cr_letters$as_cr_LETTERS
20055as_cr_digits='0123456789'
20056as_cr_alnum=$as_cr_Letters$as_cr_digits
20057
20058ECHO_C= ECHO_N= ECHO_T=
20059case `echo -n x` in #(((((
20060-n*)
20061 case `echo 'xy\c'` in
20062 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
20063 xy) ECHO_C='\c';;
20064 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
20065 ECHO_T=' ';;
20066 esac;;
20067*)
20068 ECHO_N='-n';;
20069esac
20070
20071rm -f conf$$ conf$$.exe conf$$.file
20072if test -d conf$$.dir; then
20073 rm -f conf$$.dir/conf$$.file
20074else
20075 rm -f conf$$.dir
20076 mkdir conf$$.dir 2>/dev/null
20077fi
20078if (echo >conf$$.file) 2>/dev/null; then
20079 if ln -s conf$$.file conf$$ 2>/dev/null; then
20080 as_ln_s='ln -s'
20081 # ... but there are two gotchas:
20082 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
20083 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
20084 # In both cases, we have to default to `cp -p'.
20085 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
20086 as_ln_s='cp -p'
20087 elif ln conf$$.file conf$$ 2>/dev/null; then
20088 as_ln_s=ln
20089 else
20090 as_ln_s='cp -p'
20091 fi
20092else
20093 as_ln_s='cp -p'
20094fi
20095rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
20096rmdir conf$$.dir 2>/dev/null
20097
20098
20099# as_fn_mkdir_p
20100# -------------
20101# Create "$as_dir" as a directory, including parents if necessary.
20102as_fn_mkdir_p ()
20103{
20104
20105 case $as_dir in #(
20106 -*) as_dir=./$as_dir;;
20107 esac
20108 test -d "$as_dir" || eval $as_mkdir_p || {
20109 as_dirs=
20110 while :; do
20111 case $as_dir in #(
20112 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
20113 *) as_qdir=$as_dir;;
20114 esac
20115 as_dirs="'$as_qdir' $as_dirs"
20116 as_dir=`$as_dirname -- "$as_dir" ||
20117$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20118 X"$as_dir" : 'X\(//\)[^/]' \| \
20119 X"$as_dir" : 'X\(//\)$' \| \
20120 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
20121$as_echo X"$as_dir" |
20122 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
20123 s//\1/
20124 q
20125 }
20126 /^X\(\/\/\)[^/].*/{
20127 s//\1/
20128 q
20129 }
20130 /^X\(\/\/\)$/{
20131 s//\1/
20132 q
20133 }
20134 /^X\(\/\).*/{
20135 s//\1/
20136 q
20137 }
20138 s/.*/./; q'`
20139 test -d "$as_dir" && break
20140 done
20141 test -z "$as_dirs" || eval "mkdir $as_dirs"
20142 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
20143
20144
20145} # as_fn_mkdir_p
20146if mkdir -p . 2>/dev/null; then
20147 as_mkdir_p='mkdir -p "$as_dir"'
20148else
20149 test -d ./-p && rmdir ./-p
20150 as_mkdir_p=false
20151fi
20152
20153if test -x / >/dev/null 2>&1; then
20154 as_test_x='test -x'
20155else
20156 if ls -dL / >/dev/null 2>&1; then
20157 as_ls_L_option=L
20158 else
20159 as_ls_L_option=
20160 fi
20161 as_test_x='
20162 eval sh -c '\''
20163 if test -d "$1"; then
20164 test -d "$1/.";
20165 else
20166 case $1 in #(
20167 -*)set "./$1";;
20168 esac;
20169 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
20170 ???[sx]*):;;*)false;;esac;fi
20171 '\'' sh
20172 '
20173fi
20174as_executable_p=$as_test_x
20175
20176# Sed expression to map a string onto a valid CPP name.
20177as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
20178
20179# Sed expression to map a string onto a valid variable name.
20180as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
20181
20182
20183exec 6>&1
20184## ----------------------------------- ##
20185## Main body of $CONFIG_STATUS script. ##
20186## ----------------------------------- ##
20187_ASEOF
20188test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
20189
20190cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20191# Save the log message, to keep $0 and so on meaningful, and to
20192# report actual input values of CONFIG_FILES etc. instead of their
20193# values after options handling.
20194ac_log="
20195This file was extended by $as_me, which was
20196generated by GNU Autoconf 2.64. Invocation command line was
20197
20198 CONFIG_FILES = $CONFIG_FILES
20199 CONFIG_HEADERS = $CONFIG_HEADERS
20200 CONFIG_LINKS = $CONFIG_LINKS
20201 CONFIG_COMMANDS = $CONFIG_COMMANDS
20202 $ $0 $@
20203
20204on `(hostname || uname -n) 2>/dev/null | sed 1q`
20205"
20206
20207_ACEOF
20208
20209case $ac_config_files in *"
20210"*) set x $ac_config_files; shift; ac_config_files=$*;;
20211esac
20212
20213case $ac_config_headers in *"
20214"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
20215esac
20216
20217
20218cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20219# Files that config.status was made for.
20220config_files="$ac_config_files"
20221config_headers="$ac_config_headers"
20222config_commands="$ac_config_commands"
20223
20224_ACEOF
20225
20226cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20227ac_cs_usage="\
20228\`$as_me' instantiates files and other configuration actions
20229from templates according to the current configuration. Unless the files
20230and actions are specified as TAGs, all are instantiated by default.
20231
20232Usage: $0 [OPTION]... [TAG]...
20233
20234 -h, --help print this help, then exit
20235 -V, --version print version number and configuration settings, then exit
20236 -q, --quiet, --silent
20237 do not print progress messages
20238 -d, --debug don't remove temporary files
20239 --recheck update $as_me by reconfiguring in the same conditions
20240 --file=FILE[:TEMPLATE]
20241 instantiate the configuration file FILE
20242 --header=FILE[:TEMPLATE]
20243 instantiate the configuration header FILE
20244
20245Configuration files:
20246$config_files
20247
20248Configuration headers:
20249$config_headers
20250
20251Configuration commands:
20252$config_commands
20253
20254Report bugs to the package provider."
20255
20256_ACEOF
20257cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20258ac_cs_version="\\
20259config.status
20260configured by $0, generated by GNU Autoconf 2.64,
20261 with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
20262
20263Copyright (C) 2009 Free Software Foundation, Inc.
20264This config.status script is free software; the Free Software Foundation
20265gives unlimited permission to copy, distribute and modify it."
20266
20267ac_pwd='$ac_pwd'
20268srcdir='$srcdir'
20269INSTALL='$INSTALL'
20270MKDIR_P='$MKDIR_P'
20271AWK='$AWK'
20272test -n "\$AWK" || AWK=awk
20273_ACEOF
20274
20275cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20276# The default lists apply if the user does not specify any file.
20277ac_need_defaults=:
20278while test $# != 0
20279do
20280 case $1 in
20281 --*=*)
20282 ac_option=`expr "X$1" : 'X\([^=]*\)='`
20283 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
20284 ac_shift=:
20285 ;;
20286 *)
20287 ac_option=$1
20288 ac_optarg=$2
20289 ac_shift=shift
20290 ;;
20291 esac
20292
20293 case $ac_option in
20294 # Handling of the options.
20295 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
20296 ac_cs_recheck=: ;;
20297 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
20298 $as_echo "$ac_cs_version"; exit ;;
20299 --debug | --debu | --deb | --de | --d | -d )
20300 debug=: ;;
20301 --file | --fil | --fi | --f )
20302 $ac_shift
20303 case $ac_optarg in
20304 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
20305 esac
20306 as_fn_append CONFIG_FILES " '$ac_optarg'"
20307 ac_need_defaults=false;;
20308 --header | --heade | --head | --hea )
20309 $ac_shift
20310 case $ac_optarg in
20311 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
20312 esac
20313 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
20314 ac_need_defaults=false;;
20315 --he | --h)
20316 # Conflict between --help and --header
20317 as_fn_error "ambiguous option: \`$1'
20318Try \`$0 --help' for more information.";;
20319 --help | --hel | -h )
20320 $as_echo "$ac_cs_usage"; exit ;;
20321 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
20322 | -silent | --silent | --silen | --sile | --sil | --si | --s)
20323 ac_cs_silent=: ;;
20324
20325 # This is an error.
20326 -*) as_fn_error "unrecognized option: \`$1'
20327Try \`$0 --help' for more information." ;;
20328
20329 *) as_fn_append ac_config_targets " $1"
20330 ac_need_defaults=false ;;
20331
20332 esac
20333 shift
20334done
20335
20336ac_configure_extra_args=
20337
20338if $ac_cs_silent; then
20339 exec 6>/dev/null
20340 ac_configure_extra_args="$ac_configure_extra_args --silent"
20341fi
20342
20343_ACEOF
20344cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20345if \$ac_cs_recheck; then
20346 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
20347 shift
20348 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
20349 CONFIG_SHELL='$SHELL'
20350 export CONFIG_SHELL
20351 exec "\$@"
20352fi
20353
20354_ACEOF
20355cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20356exec 5>>config.log
20357{
20358 echo
20359 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
20360## Running $as_me. ##
20361_ASBOX
20362 $as_echo "$ac_log"
20363} >&5
20364
20365_ACEOF
20366cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20367#
20368# INIT-COMMANDS
20369#
20370AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
20371
20372_ACEOF
20373
20374cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20375
20376# Handling of arguments.
20377for ac_config_target in $ac_config_targets
20378do
20379 case $ac_config_target in
20380 "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
20381 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
20382 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
20383 "import/Makefile") CONFIG_FILES="$CONFIG_FILES import/Makefile" ;;
20384 "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
20385
20386 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
20387 esac
20388done
20389
20390
20391# If the user did not use the arguments to specify the items to instantiate,
20392# then the envvar interface is used. Set only those that are not.
20393# We use the long form for the default assignment because of an extremely
20394# bizarre bug on SunOS 4.1.3.
20395if $ac_need_defaults; then
20396 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
20397 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
20398 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
20399fi
20400
20401# Have a temporary directory for convenience. Make it in the build tree
20402# simply because there is no reason against having it here, and in addition,
20403# creating and moving files from /tmp can sometimes cause problems.
20404# Hook for its removal unless debugging.
20405# Note that there is a small window in which the directory will not be cleaned:
20406# after its creation but before its name has been assigned to `$tmp'.
20407$debug ||
20408{
20409 tmp=
20410 trap 'exit_status=$?
20411 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
20412' 0
20413 trap 'as_fn_exit 1' 1 2 13 15
20414}
20415# Create a (secure) tmp directory for tmp files.
20416
20417{
20418 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
20419 test -n "$tmp" && test -d "$tmp"
20420} ||
20421{
20422 tmp=./conf$$-$RANDOM
20423 (umask 077 && mkdir "$tmp")
20424} || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
20425
20426# Set up the scripts for CONFIG_FILES section.
20427# No need to generate them if there are no CONFIG_FILES.
20428# This happens for instance with `./config.status config.h'.
20429if test -n "$CONFIG_FILES"; then
20430
20431
20432ac_cr=`echo X | tr X '\015'`
20433# On cygwin, bash can eat \r inside `` if the user requested igncr.
20434# But we know of no other shell where ac_cr would be empty at this
20435# point, so we can use a bashism as a fallback.
20436if test "x$ac_cr" = x; then
20437 eval ac_cr=\$\'\\r\'
20438fi
20439ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
20440if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
20441 ac_cs_awk_cr='\r'
20442else
20443 ac_cs_awk_cr=$ac_cr
20444fi
20445
20446echo 'BEGIN {' >"$tmp/subs1.awk" &&
20447_ACEOF
20448
20449
20450{
20451 echo "cat >conf$$subs.awk <<_ACEOF" &&
20452 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
20453 echo "_ACEOF"
20454} >conf$$subs.sh ||
20455 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
20456ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
20457ac_delim='%!_!# '
20458for ac_last_try in false false false false false :; do
20459 . ./conf$$subs.sh ||
20460 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
20461
20462 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
20463 if test $ac_delim_n = $ac_delim_num; then
20464 break
20465 elif $ac_last_try; then
20466 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
20467 else
20468 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
20469 fi
20470done
20471rm -f conf$$subs.sh
20472
20473cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20474cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
20475_ACEOF
20476sed -n '
20477h
20478s/^/S["/; s/!.*/"]=/
20479p
20480g
20481s/^[^!]*!//
20482:repl
20483t repl
20484s/'"$ac_delim"'$//
20485t delim
20486:nl
20487h
20488s/\(.\{148\}\).*/\1/
20489t more1
20490s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
20491p
20492n
20493b repl
20494:more1
20495s/["\\]/\\&/g; s/^/"/; s/$/"\\/
20496p
20497g
20498s/.\{148\}//
20499t nl
20500:delim
20501h
20502s/\(.\{148\}\).*/\1/
20503t more2
20504s/["\\]/\\&/g; s/^/"/; s/$/"/
20505p
20506b
20507:more2
20508s/["\\]/\\&/g; s/^/"/; s/$/"\\/
20509p
20510g
20511s/.\{148\}//
20512t delim
20513' <conf$$subs.awk | sed '
20514/^[^""]/{
20515 N
20516 s/\n//
20517}
20518' >>$CONFIG_STATUS || ac_write_fail=1
20519rm -f conf$$subs.awk
20520cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20521_ACAWK
20522cat >>"\$tmp/subs1.awk" <<_ACAWK &&
20523 for (key in S) S_is_set[key] = 1
20524 FS = "\a"
20525
20526}
20527{
20528 line = $ 0
20529 nfields = split(line, field, "@")
20530 substed = 0
20531 len = length(field[1])
20532 for (i = 2; i < nfields; i++) {
20533 key = field[i]
20534 keylen = length(key)
20535 if (S_is_set[key]) {
20536 value = S[key]
20537 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
20538 len += length(value) + length(field[++i])
20539 substed = 1
20540 } else
20541 len += 1 + keylen
20542 }
20543
20544 print line
20545}
20546
20547_ACAWK
20548_ACEOF
20549cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20550if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
20551 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
20552else
20553 cat
20554fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
20555 || as_fn_error "could not setup config files machinery" "$LINENO" 5
20556_ACEOF
20557
20558# VPATH may cause trouble with some makes, so we remove $(srcdir),
20559# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
20560# trailing colons and then remove the whole line if VPATH becomes empty
20561# (actually we leave an empty line to preserve line numbers).
20562if test "x$srcdir" = x.; then
20563 ac_vpsub='/^[ ]*VPATH[ ]*=/{
20564s/:*\$(srcdir):*/:/
20565s/:*\${srcdir}:*/:/
20566s/:*@srcdir@:*/:/
20567s/^\([^=]*=[ ]*\):*/\1/
20568s/:*$//
20569s/^[^=]*=[ ]*$//
20570}'
20571fi
20572
20573cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20574fi # test -n "$CONFIG_FILES"
20575
20576# Set up the scripts for CONFIG_HEADERS section.
20577# No need to generate them if there are no CONFIG_HEADERS.
20578# This happens for instance with `./config.status Makefile'.
20579if test -n "$CONFIG_HEADERS"; then
20580cat >"$tmp/defines.awk" <<\_ACAWK ||
20581BEGIN {
20582_ACEOF
20583
20584# Transform confdefs.h into an awk script `defines.awk', embedded as
20585# here-document in config.status, that substitutes the proper values into
20586# config.h.in to produce config.h.
20587
20588# Create a delimiter string that does not exist in confdefs.h, to ease
20589# handling of long lines.
20590ac_delim='%!_!# '
20591for ac_last_try in false false :; do
20592 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
20593 if test -z "$ac_t"; then
20594 break
20595 elif $ac_last_try; then
20596 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
20597 else
20598 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
20599 fi
20600done
20601
20602# For the awk script, D is an array of macro values keyed by name,
20603# likewise P contains macro parameters if any. Preserve backslash
20604# newline sequences.
20605
20606ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
20607sed -n '
20608s/.\{148\}/&'"$ac_delim"'/g
20609t rset
20610:rset
20611s/^[ ]*#[ ]*define[ ][ ]*/ /
20612t def
20613d
20614:def
20615s/\\$//
20616t bsnl
20617s/["\\]/\\&/g
20618s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
20619D["\1"]=" \3"/p
20620s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
20621d
20622:bsnl
20623s/["\\]/\\&/g
20624s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
20625D["\1"]=" \3\\\\\\n"\\/p
20626t cont
20627s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
20628t cont
20629d
20630:cont
20631n
20632s/.\{148\}/&'"$ac_delim"'/g
20633t clear
20634:clear
20635s/\\$//
20636t bsnlc
20637s/["\\]/\\&/g; s/^/"/; s/$/"/p
20638d
20639:bsnlc
20640s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
20641b cont
20642' <confdefs.h | sed '
20643s/'"$ac_delim"'/"\\\
20644"/g' >>$CONFIG_STATUS || ac_write_fail=1
20645
20646cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20647 for (key in D) D_is_set[key] = 1
20648 FS = "\a"
20649}
20650/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
20651 line = \$ 0
20652 split(line, arg, " ")
20653 if (arg[1] == "#") {
20654 defundef = arg[2]
20655 mac1 = arg[3]
20656 } else {
20657 defundef = substr(arg[1], 2)
20658 mac1 = arg[2]
20659 }
20660 split(mac1, mac2, "(") #)
20661 macro = mac2[1]
20662 prefix = substr(line, 1, index(line, defundef) - 1)
20663 if (D_is_set[macro]) {
20664 # Preserve the white space surrounding the "#".
20665 print prefix "define", macro P[macro] D[macro]
20666 next
20667 } else {
20668 # Replace #undef with comments. This is necessary, for example,
20669 # in the case of _POSIX_SOURCE, which is predefined and required
20670 # on some systems where configure will not decide to define it.
20671 if (defundef == "undef") {
20672 print "/*", prefix defundef, macro, "*/"
20673 next
20674 }
20675 }
20676}
20677{ print }
20678_ACAWK
20679_ACEOF
20680cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20681 as_fn_error "could not setup config headers machinery" "$LINENO" 5
20682fi # test -n "$CONFIG_HEADERS"
20683
20684
20685eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
20686shift
20687for ac_tag
20688do
20689 case $ac_tag in
20690 :[FHLC]) ac_mode=$ac_tag; continue;;
20691 esac
20692 case $ac_mode$ac_tag in
20693 :[FHL]*:*);;
20694 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
20695 :[FH]-) ac_tag=-:-;;
20696 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
20697 esac
20698 ac_save_IFS=$IFS
20699 IFS=:
20700 set x $ac_tag
20701 IFS=$ac_save_IFS
20702 shift
20703 ac_file=$1
20704 shift
20705
20706 case $ac_mode in
20707 :L) ac_source=$1;;
20708 :[FH])
20709 ac_file_inputs=
20710 for ac_f
20711 do
20712 case $ac_f in
20713 -) ac_f="$tmp/stdin";;
20714 *) # Look for the file first in the build tree, then in the source tree
20715 # (if the path is not absolute). The absolute path cannot be DOS-style,
20716 # because $ac_f cannot contain `:'.
20717 test -f "$ac_f" ||
20718 case $ac_f in
20719 [\\/$]*) false;;
20720 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
20721 esac ||
20722 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
20723 esac
20724 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
20725 as_fn_append ac_file_inputs " '$ac_f'"
20726 done
20727
20728 # Let's still pretend it is `configure' which instantiates (i.e., don't
20729 # use $as_me), people would be surprised to read:
20730 # /* config.h. Generated by config.status. */
20731 configure_input='Generated from '`
20732 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
20733 `' by configure.'
20734 if test x"$ac_file" != x-; then
20735 configure_input="$ac_file. $configure_input"
20736 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
20737$as_echo "$as_me: creating $ac_file" >&6;}
20738 fi
20739 # Neutralize special characters interpreted by sed in replacement strings.
20740 case $configure_input in #(
20741 *\&* | *\|* | *\\* )
20742 ac_sed_conf_input=`$as_echo "$configure_input" |
20743 sed 's/[\\\\&|]/\\\\&/g'`;; #(
20744 *) ac_sed_conf_input=$configure_input;;
20745 esac
20746
20747 case $ac_tag in
20748 *:-:* | *:-) cat >"$tmp/stdin" \
20749 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
20750 esac
20751 ;;
20752 esac
20753
20754 ac_dir=`$as_dirname -- "$ac_file" ||
20755$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20756 X"$ac_file" : 'X\(//\)[^/]' \| \
20757 X"$ac_file" : 'X\(//\)$' \| \
20758 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
20759$as_echo X"$ac_file" |
20760 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
20761 s//\1/
20762 q
20763 }
20764 /^X\(\/\/\)[^/].*/{
20765 s//\1/
20766 q
20767 }
20768 /^X\(\/\/\)$/{
20769 s//\1/
20770 q
20771 }
20772 /^X\(\/\).*/{
20773 s//\1/
20774 q
20775 }
20776 s/.*/./; q'`
20777 as_dir="$ac_dir"; as_fn_mkdir_p
20778 ac_builddir=.
20779
20780case "$ac_dir" in
20781.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
20782*)
20783 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
20784 # A ".." for each directory in $ac_dir_suffix.
20785 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
20786 case $ac_top_builddir_sub in
20787 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
20788 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
20789 esac ;;
20790esac
20791ac_abs_top_builddir=$ac_pwd
20792ac_abs_builddir=$ac_pwd$ac_dir_suffix
20793# for backward compatibility:
20794ac_top_builddir=$ac_top_build_prefix
20795
20796case $srcdir in
20797 .) # We are building in place.
20798 ac_srcdir=.
20799 ac_top_srcdir=$ac_top_builddir_sub
20800 ac_abs_top_srcdir=$ac_pwd ;;
20801 [\\/]* | ?:[\\/]* ) # Absolute name.
20802 ac_srcdir=$srcdir$ac_dir_suffix;
20803 ac_top_srcdir=$srcdir
20804 ac_abs_top_srcdir=$srcdir ;;
20805 *) # Relative name.
20806 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
20807 ac_top_srcdir=$ac_top_build_prefix$srcdir
20808 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
20809esac
20810ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
20811
20812
20813 case $ac_mode in
20814 :F)
20815 #
20816 # CONFIG_FILE
20817 #
20818
20819 case $INSTALL in
20820 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
20821 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
20822 esac
20823 ac_MKDIR_P=$MKDIR_P
20824 case $MKDIR_P in
20825 [\\/$]* | ?:[\\/]* ) ;;
20826 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
20827 esac
20828_ACEOF
20829
20830cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20831# If the template does not know about datarootdir, expand it.
20832# FIXME: This hack should be removed a few years after 2.60.
20833ac_datarootdir_hack=; ac_datarootdir_seen=
20834ac_sed_dataroot='
20835/datarootdir/ {
20836 p
20837 q
20838}
20839/@datadir@/p
20840/@docdir@/p
20841/@infodir@/p
20842/@localedir@/p
20843/@mandir@/p'
20844case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
20845*datarootdir*) ac_datarootdir_seen=yes;;
20846*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
20847 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
20848$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
20849_ACEOF
20850cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20851 ac_datarootdir_hack='
20852 s&@datadir@&$datadir&g
20853 s&@docdir@&$docdir&g
20854 s&@infodir@&$infodir&g
20855 s&@localedir@&$localedir&g
20856 s&@mandir@&$mandir&g
20857 s&\\\${datarootdir}&$datarootdir&g' ;;
20858esac
20859_ACEOF
20860
20861# Neutralize VPATH when `$srcdir' = `.'.
20862# Shell code in configure.ac might set extrasub.
20863# FIXME: do we really want to maintain this feature?
20864cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20865ac_sed_extra="$ac_vpsub
20866$extrasub
20867_ACEOF
20868cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20869:t
20870/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
20871s|@configure_input@|$ac_sed_conf_input|;t t
20872s&@top_builddir@&$ac_top_builddir_sub&;t t
20873s&@top_build_prefix@&$ac_top_build_prefix&;t t
20874s&@srcdir@&$ac_srcdir&;t t
20875s&@abs_srcdir@&$ac_abs_srcdir&;t t
20876s&@top_srcdir@&$ac_top_srcdir&;t t
20877s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
20878s&@builddir@&$ac_builddir&;t t
20879s&@abs_builddir@&$ac_abs_builddir&;t t
20880s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
20881s&@INSTALL@&$ac_INSTALL&;t t
20882s&@MKDIR_P@&$ac_MKDIR_P&;t t
20883$ac_datarootdir_hack
20884"
20885eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
20886 || as_fn_error "could not create $ac_file" "$LINENO" 5
20887
20888test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
20889 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
20890 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
20891 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
20892which seems to be undefined. Please make sure it is defined." >&5
20893$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
20894which seems to be undefined. Please make sure it is defined." >&2;}
20895
20896 rm -f "$tmp/stdin"
20897 case $ac_file in
20898 -) cat "$tmp/out" && rm -f "$tmp/out";;
20899 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
20900 esac \
20901 || as_fn_error "could not create $ac_file" "$LINENO" 5
20902 ;;
20903 :H)
20904 #
20905 # CONFIG_HEADER
20906 #
20907 if test x"$ac_file" != x-; then
20908 {
20909 $as_echo "/* $configure_input */" \
20910 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
20911 } >"$tmp/config.h" \
20912 || as_fn_error "could not create $ac_file" "$LINENO" 5
20913 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
20914 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
20915$as_echo "$as_me: $ac_file is unchanged" >&6;}
20916 else
20917 rm -f "$ac_file"
20918 mv "$tmp/config.h" "$ac_file" \
20919 || as_fn_error "could not create $ac_file" "$LINENO" 5
20920 fi
20921 else
20922 $as_echo "/* $configure_input */" \
20923 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
20924 || as_fn_error "could not create -" "$LINENO" 5
20925 fi
20926# Compute "$ac_file"'s index in $config_headers.
20927_am_arg="$ac_file"
20928_am_stamp_count=1
20929for _am_header in $config_headers :; do
20930 case $_am_header in
20931 $_am_arg | $_am_arg:* )
20932 break ;;
20933 * )
20934 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
20935 esac
20936done
20937echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
20938$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20939 X"$_am_arg" : 'X\(//\)[^/]' \| \
20940 X"$_am_arg" : 'X\(//\)$' \| \
20941 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
20942$as_echo X"$_am_arg" |
20943 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
20944 s//\1/
20945 q
20946 }
20947 /^X\(\/\/\)[^/].*/{
20948 s//\1/
20949 q
20950 }
20951 /^X\(\/\/\)$/{
20952 s//\1/
20953 q
20954 }
20955 /^X\(\/\).*/{
20956 s//\1/
20957 q
20958 }
20959 s/.*/./; q'`/stamp-h$_am_stamp_count
20960 ;;
20961
20962 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
20963$as_echo "$as_me: executing $ac_file commands" >&6;}
20964 ;;
20965 esac
20966
20967
20968 case $ac_file$ac_mode in
20969 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
20970 # Autoconf 2.62 quotes --file arguments for eval, but not when files
20971 # are listed without --file. Let's play safe and only enable the eval
20972 # if we detect the quoting.
20973 case $CONFIG_FILES in
20974 *\'*) eval set x "$CONFIG_FILES" ;;
20975 *) set x $CONFIG_FILES ;;
20976 esac
20977 shift
20978 for mf
20979 do
20980 # Strip MF so we end up with the name of the file.
20981 mf=`echo "$mf" | sed -e 's/:.*$//'`
20982 # Check whether this is an Automake generated Makefile or not.
20983 # We used to match only the files named `Makefile.in', but
20984 # some people rename them; so instead we look at the file content.
20985 # Grep'ing the first line is not enough: some people post-process
20986 # each Makefile.in and add a new line on top of each file to say so.
20987 # Grep'ing the whole file is not good either: AIX grep has a line
20988 # limit of 2048, but all sed's we know have understand at least 4000.
20989 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
20990 dirpart=`$as_dirname -- "$mf" ||
20991$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20992 X"$mf" : 'X\(//\)[^/]' \| \
20993 X"$mf" : 'X\(//\)$' \| \
20994 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
20995$as_echo X"$mf" |
20996 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
20997 s//\1/
20998 q
20999 }
21000 /^X\(\/\/\)[^/].*/{
21001 s//\1/
21002 q
21003 }
21004 /^X\(\/\/\)$/{
21005 s//\1/
21006 q
21007 }
21008 /^X\(\/\).*/{
21009 s//\1/
21010 q
21011 }
21012 s/.*/./; q'`
21013 else
21014 continue
21015 fi
21016 # Extract the definition of DEPDIR, am__include, and am__quote
21017 # from the Makefile without running `make'.
21018 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
21019 test -z "$DEPDIR" && continue
21020 am__include=`sed -n 's/^am__include = //p' < "$mf"`
21021 test -z "am__include" && continue
21022 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
21023 # When using ansi2knr, U may be empty or an underscore; expand it
21024 U=`sed -n 's/^U = //p' < "$mf"`
21025 # Find all dependency output files, they are included files with
21026 # $(DEPDIR) in their names. We invoke sed twice because it is the
21027 # simplest approach to changing $(DEPDIR) to its actual value in the
21028 # expansion.
21029 for file in `sed -n "
21030 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
21031 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
21032 # Make sure the directory exists.
21033 test -f "$dirpart/$file" && continue
21034 fdir=`$as_dirname -- "$file" ||
21035$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
21036 X"$file" : 'X\(//\)[^/]' \| \
21037 X"$file" : 'X\(//\)$' \| \
21038 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
21039$as_echo X"$file" |
21040 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
21041 s//\1/
21042 q
21043 }
21044 /^X\(\/\/\)[^/].*/{
21045 s//\1/
21046 q
21047 }
21048 /^X\(\/\/\)$/{
21049 s//\1/
21050 q
21051 }
21052 /^X\(\/\).*/{
21053 s//\1/
21054 q
21055 }
21056 s/.*/./; q'`
21057 as_dir=$dirpart/$fdir; as_fn_mkdir_p
21058 # echo "creating $dirpart/$file"
21059 echo '# dummy' > "$dirpart/$file"
21060 done
21061 done
21062}
21063 ;;
21064 "default":C)
21065case x$CONFIG_HEADERS in
21066xconfig.h:config.in)
21067echo > stamp-h ;;
21068esac
21069 ;;
21070
21071 esac
21072done # for ac_tag
21073
21074
21075as_fn_exit 0
21076_ACEOF
21077ac_clean_files=$ac_clean_files_save
21078
21079test $ac_write_fail = 0 ||
21080 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
21081
21082
21083# configure is writing to config.log, and then calls config.status.
21084# config.status does its own redirection, appending to config.log.
21085# Unfortunately, on DOS this fails, as config.log is still kept open
21086# by configure, so config.status won't be able to write to it; its
21087# output is simply discarded. So we exec the FD to /dev/null,
21088# effectively closing config.log, so it can be properly (re)opened and
21089# appended to by config.status. When coming back to configure, we
21090# need to make the FD available again.
21091if test "$no_create" != yes; then
21092 ac_cs_success=:
21093 ac_config_status_args=
21094 test "$silent" = yes &&
21095 ac_config_status_args="$ac_config_status_args --quiet"
21096 exec 5>/dev/null
21097 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
21098 exec 5>>config.log
21099 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
21100 # would make configure fail if this is the last instruction.
21101 $ac_cs_success || as_fn_exit $?
21102fi
21103if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
21104 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
21105$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
21106fi
21107
21108
21109exit 0
This page took 1.612498 seconds and 4 git commands to generate.