Add silent Makefile rules
[deliverable/binutils-gdb.git] / gdb / gnulib / configure
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
16 DUALCASE=1; export DUALCASE # for MKS sh
17 if 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
24 else
25 case `(set -o) 2>/dev/null` in #(
26 *posix*) :
27 set -o posix ;; #(
28 *) :
29 ;;
30 esac
31 fi
32
33
34 as_nl='
35 '
36 export as_nl
37 # Printing a long string crashes Solaris 7 /usr/bin/printf.
38 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
39 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
40 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
41 # Prefer a ksh shell builtin over an external printf program on Solaris,
42 # but without wasting forks for bash or zsh.
43 if test -z "$BASH_VERSION$ZSH_VERSION" \
44 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
45 as_echo='print -r --'
46 as_echo_n='print -rn --'
47 elif (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'
50 else
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'
70 fi
71
72 # The user is always right.
73 if 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 }
79 fi
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.)
87 IFS=" "" $as_nl"
88
89 # Find who we are. Look in the path if we contain no directory separator.
90 case $0 in #((
91 *[\\/]* ) as_myself=$0 ;;
92 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
93 for as_dir in $PATH
94 do
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
99 IFS=$as_save_IFS
100
101 ;;
102 esac
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.
105 if test "x$as_myself" = x; then
106 as_myself=$0
107 fi
108 if test ! -f "$as_myself"; then
109 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
110 exit 1
111 fi
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.
117 for as_var in BASH_ENV ENV MAIL MAILPATH
118 do eval test x\${$as_var+set} = xset \
119 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
120 done
121 PS1='$ '
122 PS2='> '
123 PS4='+ '
124
125 # NLS nuisances.
126 LC_ALL=C
127 export LC_ALL
128 LANGUAGE=C
129 export LANGUAGE
130
131 # CDPATH.
132 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
133
134 if 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
142 else
143 case \`(set -o) 2>/dev/null\` in #(
144 *posix*) :
145 set -o posix ;; #(
146 *) :
147 ;;
148 esac
149 fi
150 "
151 as_required="as_fn_return () { (exit \$1); }
152 as_fn_success () { as_fn_return 0; }
153 as_fn_failure () { as_fn_return 1; }
154 as_fn_ret_success () { return 0; }
155 as_fn_ret_failure () { return 1; }
156
157 exitcode=0
158 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
159 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
160 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
161 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
162 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
163
164 else
165 exitcode=1; echo positional parameters were not saved.
166 fi
167 test 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
172 test \$(( 1 + 1 )) = 2 || exit 1"
173 if (eval "$as_required") 2>/dev/null; then :
174 as_have_required=yes
175 else
176 as_have_required=no
177 fi
178 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
179
180 else
181 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
182 as_found=false
183 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
184 do
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
198 fi
199 fi
200 done;;
201 esac
202 as_found=false
203 done
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
207 fi; }
208 IFS=$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+"$@"}
220 fi
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
235 fi
236 fi
237 fi
238 SHELL=${CONFIG_SHELL-/bin/sh}
239 export SHELL
240 # Unset more variables known to interfere with behavior of common tools.
241 CLICOLOR_FORCE= GREP_OPTIONS=
242 unset CLICOLOR_FORCE GREP_OPTIONS
243
244 ## --------------------- ##
245 ## M4sh Shell Functions. ##
246 ## --------------------- ##
247 # as_fn_unset VAR
248 # ---------------
249 # Portably unset VAR.
250 as_fn_unset ()
251 {
252 { eval $1=; unset $1;}
253 }
254 as_unset=as_fn_unset
255
256 # as_fn_set_status STATUS
257 # -----------------------
258 # Set $? to STATUS, without forking.
259 as_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.
267 as_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.
277 as_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.
327 if (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 }'
332 else
333 as_fn_append ()
334 {
335 eval $1=\$$1\$2
336 }
337 fi # 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.
344 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
345 eval 'as_fn_arith ()
346 {
347 as_val=$(( $* ))
348 }'
349 else
350 as_fn_arith ()
351 {
352 as_val=`expr "$@" || test $? -eq 1`
353 }
354 fi # 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.
362 as_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
373 if expr a : '\(a\)' >/dev/null 2>&1 &&
374 test "X`expr 00001 : '.*\(...\)'`" = X001; then
375 as_expr=expr
376 else
377 as_expr=false
378 fi
379
380 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
381 as_basename=basename
382 else
383 as_basename=false
384 fi
385
386 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
387 as_dirname=dirname
388 else
389 as_dirname=false
390 fi
391
392 as_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.
412 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
413 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
414 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
415 as_cr_digits='0123456789'
416 as_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
450 ECHO_C= ECHO_N= ECHO_T=
451 case `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';;
461 esac
462
463 rm -f conf$$ conf$$.exe conf$$.file
464 if test -d conf$$.dir; then
465 rm -f conf$$.dir/conf$$.file
466 else
467 rm -f conf$$.dir
468 mkdir conf$$.dir 2>/dev/null
469 fi
470 if (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
484 else
485 as_ln_s='cp -p'
486 fi
487 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
488 rmdir conf$$.dir 2>/dev/null
489
490 if mkdir -p . 2>/dev/null; then
491 as_mkdir_p='mkdir -p "$as_dir"'
492 else
493 test -d ./-p && rmdir ./-p
494 as_mkdir_p=false
495 fi
496
497 if test -x / >/dev/null 2>&1; then
498 as_test_x='test -x'
499 else
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 '
517 fi
518 as_executable_p=$as_test_x
519
520 # Sed expression to map a string onto a valid CPP name.
521 as_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.
524 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
525
526
527 exec 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.
532 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
533
534 #
535 # Initializations.
536 #
537 ac_default_prefix=/usr/local
538 ac_clean_files=
539 ac_config_libobj_dir=.
540 LIBOBJS=
541 cross_compiling=no
542 subdirs=
543 MFLAGS=
544 MAKEFLAGS=
545
546 # Identity of this package.
547 PACKAGE_NAME=
548 PACKAGE_TARNAME=
549 PACKAGE_VERSION=
550 PACKAGE_STRING=
551 PACKAGE_BUGREPORT=
552 PACKAGE_URL=
553
554 ac_unique_file="import/memmem.c"
555 # Factoring default headers for most tests.
556 ac_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
591 ac_func_list=
592 ac_header_list=
593 gl_fnmatch_required=POSIX
594 ac_subst_vars='am__EXEEXT_FALSE
595 am__EXEEXT_TRUE
596 gltests_LTLIBOBJS
597 gltests_LIBOBJS
598 gl_LTLIBOBJS
599 gl_LIBOBJS
600 LTLIBOBJS
601 LIBOBJS
602 LN_S
603 AM_BACKSLASH
604 AM_DEFAULT_VERBOSITY
605 am__fastdepCC_FALSE
606 am__fastdepCC_TRUE
607 CCDEPMODE
608 AMDEPBACKSLASH
609 AMDEP_FALSE
610 AMDEP_TRUE
611 am__quote
612 am__include
613 DEPDIR
614 am__untar
615 am__tar
616 AMTAR
617 am__leading_dot
618 SET_MAKE
619 AWK
620 mkdir_p
621 INSTALL_STRIP_PROGRAM
622 STRIP
623 install_sh
624 MAKEINFO
625 AUTOHEADER
626 AUTOMAKE
627 AUTOCONF
628 ACLOCAL
629 VERSION
630 PACKAGE
631 CYGPATH_W
632 am__isrc
633 INSTALL_DATA
634 INSTALL_SCRIPT
635 INSTALL_PROGRAM
636 LIBGNU_LTLIBDEPS
637 LIBGNU_LIBDEPS
638 gltests_WITNESS
639 REPLACE_TOWLOWER
640 REPLACE_ISWCNTRL
641 HAVE_WCTYPE_H
642 NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H
643 NEXT_WCTYPE_H
644 HAVE_ISWCNTRL
645 REPLACE_ISWBLANK
646 HAVE_WCTRANS_T
647 HAVE_WCTYPE_T
648 HAVE_ISWBLANK
649 GNULIB_TOWCTRANS
650 GNULIB_WCTRANS
651 GNULIB_ISWCTYPE
652 GNULIB_WCTYPE
653 GNULIB_ISWBLANK
654 HAVE_WINT_T
655 HAVE_FEATURES_H
656 NEXT_AS_FIRST_DIRECTIVE_WCHAR_H
657 NEXT_WCHAR_H
658 HAVE_UNISTD_H
659 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
660 NEXT_UNISTD_H
661 UNISTD_H_DEFINES_STRUCT_TIMESPEC
662 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
663 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
664 TIME_H_DEFINES_STRUCT_TIMESPEC
665 NEXT_AS_FIRST_DIRECTIVE_TIME_H
666 NEXT_TIME_H
667 REPLACE_LOCALTIME
668 REPLACE_GMTIME
669 REPLACE_TIMEGM
670 REPLACE_NANOSLEEP
671 REPLACE_MKTIME
672 REPLACE_LOCALTIME_R
673 HAVE_TIMEGM
674 HAVE_STRPTIME
675 HAVE_NANOSLEEP
676 HAVE_DECL_LOCALTIME_R
677 GNULIB_TIME_RZ
678 GNULIB_TIME_R
679 GNULIB_TIMEGM
680 GNULIB_STRPTIME
681 GNULIB_NANOSLEEP
682 GNULIB_MKTIME
683 WINDOWS_64_BIT_OFF_T
684 NEXT_AS_FIRST_DIRECTIVE_SYS_TYPES_H
685 NEXT_SYS_TYPES_H
686 MKDIR_P
687 NEXT_AS_FIRST_DIRECTIVE_STRING_H
688 NEXT_STRING_H
689 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
690 NEXT_STDLIB_H
691 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
692 NEXT_STDIO_H
693 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
694 NEXT_STDDEF_H
695 GL_GENERATE_STDDEF_H_FALSE
696 GL_GENERATE_STDDEF_H_TRUE
697 STDDEF_H
698 HAVE_WCHAR_T
699 HAVE_MAX_ALIGN_T
700 REPLACE_NULL
701 HAVE__BOOL
702 GL_GENERATE_STDBOOL_H_FALSE
703 GL_GENERATE_STDBOOL_H_TRUE
704 STDBOOL_H
705 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
706 NEXT_SIGNAL_H
707 REPLACE_RAISE
708 REPLACE_PTHREAD_SIGMASK
709 HAVE_SIGHANDLER_T
710 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
711 HAVE_STRUCT_SIGACTION_SA_SIGACTION
712 HAVE_SIGACTION
713 HAVE_SIGINFO_T
714 HAVE_SIGSET_T
715 HAVE_RAISE
716 HAVE_PTHREAD_SIGMASK
717 HAVE_POSIX_SIGNALBLOCKING
718 GNULIB_SIGACTION
719 GNULIB_SIGPROCMASK
720 GNULIB_SIGNAL_H_SIGPIPE
721 GNULIB_RAISE
722 GNULIB_PTHREAD_SIGMASK
723 REPLACE_VSPRINTF
724 REPLACE_VSNPRINTF
725 REPLACE_VPRINTF
726 REPLACE_VFPRINTF
727 REPLACE_VDPRINTF
728 REPLACE_VASPRINTF
729 REPLACE_TMPFILE
730 REPLACE_STDIO_WRITE_FUNCS
731 REPLACE_STDIO_READ_FUNCS
732 REPLACE_SPRINTF
733 REPLACE_SNPRINTF
734 REPLACE_RENAMEAT
735 REPLACE_RENAME
736 REPLACE_REMOVE
737 REPLACE_PRINTF
738 REPLACE_POPEN
739 REPLACE_PERROR
740 REPLACE_OBSTACK_PRINTF
741 REPLACE_GETLINE
742 REPLACE_GETDELIM
743 REPLACE_FTELLO
744 REPLACE_FTELL
745 REPLACE_FSEEKO
746 REPLACE_FSEEK
747 REPLACE_FREOPEN
748 REPLACE_FPURGE
749 REPLACE_FPRINTF
750 REPLACE_FOPEN
751 REPLACE_FFLUSH
752 REPLACE_FDOPEN
753 REPLACE_FCLOSE
754 REPLACE_DPRINTF
755 HAVE_VDPRINTF
756 HAVE_VASPRINTF
757 HAVE_RENAMEAT
758 HAVE_POPEN
759 HAVE_PCLOSE
760 HAVE_FTELLO
761 HAVE_FSEEKO
762 HAVE_DPRINTF
763 HAVE_DECL_VSNPRINTF
764 HAVE_DECL_SNPRINTF
765 HAVE_DECL_OBSTACK_PRINTF
766 HAVE_DECL_GETLINE
767 HAVE_DECL_GETDELIM
768 HAVE_DECL_FTELLO
769 HAVE_DECL_FSEEKO
770 HAVE_DECL_FPURGE
771 GNULIB_VSPRINTF_POSIX
772 GNULIB_VSNPRINTF
773 GNULIB_VPRINTF_POSIX
774 GNULIB_VPRINTF
775 GNULIB_VFPRINTF_POSIX
776 GNULIB_VFPRINTF
777 GNULIB_VDPRINTF
778 GNULIB_VSCANF
779 GNULIB_VFSCANF
780 GNULIB_VASPRINTF
781 GNULIB_TMPFILE
782 GNULIB_STDIO_H_SIGPIPE
783 GNULIB_STDIO_H_NONBLOCKING
784 GNULIB_SPRINTF_POSIX
785 GNULIB_SNPRINTF
786 GNULIB_SCANF
787 GNULIB_RENAMEAT
788 GNULIB_RENAME
789 GNULIB_REMOVE
790 GNULIB_PUTS
791 GNULIB_PUTCHAR
792 GNULIB_PUTC
793 GNULIB_PRINTF_POSIX
794 GNULIB_PRINTF
795 GNULIB_POPEN
796 GNULIB_PERROR
797 GNULIB_PCLOSE
798 GNULIB_OBSTACK_PRINTF_POSIX
799 GNULIB_OBSTACK_PRINTF
800 GNULIB_GETLINE
801 GNULIB_GETDELIM
802 GNULIB_GETCHAR
803 GNULIB_GETC
804 GNULIB_FWRITE
805 GNULIB_FTELLO
806 GNULIB_FTELL
807 GNULIB_FSEEKO
808 GNULIB_FSEEK
809 GNULIB_FSCANF
810 GNULIB_FREOPEN
811 GNULIB_FREAD
812 GNULIB_FPUTS
813 GNULIB_FPUTC
814 GNULIB_FPURGE
815 GNULIB_FPRINTF_POSIX
816 GNULIB_FPRINTF
817 GNULIB_FOPEN
818 GNULIB_FGETS
819 GNULIB_FGETC
820 GNULIB_FFLUSH
821 GNULIB_FDOPEN
822 GNULIB_FCLOSE
823 GNULIB_DPRINTF
824 UNDEFINE_STRTOK_R
825 REPLACE_STRTOK_R
826 REPLACE_STRSIGNAL
827 REPLACE_STRNLEN
828 REPLACE_STRNDUP
829 REPLACE_STRNCAT
830 REPLACE_STRERROR_R
831 REPLACE_STRERROR
832 REPLACE_STRCHRNUL
833 REPLACE_STRCASESTR
834 REPLACE_STRSTR
835 REPLACE_STRDUP
836 REPLACE_STPNCPY
837 REPLACE_MEMMEM
838 REPLACE_MEMCHR
839 HAVE_STRVERSCMP
840 HAVE_DECL_STRSIGNAL
841 HAVE_DECL_STRERROR_R
842 HAVE_DECL_STRTOK_R
843 HAVE_STRCASESTR
844 HAVE_STRSEP
845 HAVE_STRPBRK
846 HAVE_DECL_STRNLEN
847 HAVE_DECL_STRNDUP
848 HAVE_DECL_STRDUP
849 HAVE_STRCHRNUL
850 HAVE_STPNCPY
851 HAVE_STPCPY
852 HAVE_RAWMEMCHR
853 HAVE_DECL_MEMRCHR
854 HAVE_MEMPCPY
855 HAVE_DECL_MEMMEM
856 HAVE_MEMCHR
857 HAVE_FFSLL
858 HAVE_FFSL
859 HAVE_MBSLEN
860 GNULIB_STRVERSCMP
861 GNULIB_STRSIGNAL
862 GNULIB_STRERROR_R
863 GNULIB_STRERROR
864 GNULIB_MBSTOK_R
865 GNULIB_MBSSEP
866 GNULIB_MBSSPN
867 GNULIB_MBSPBRK
868 GNULIB_MBSCSPN
869 GNULIB_MBSCASESTR
870 GNULIB_MBSPCASECMP
871 GNULIB_MBSNCASECMP
872 GNULIB_MBSCASECMP
873 GNULIB_MBSSTR
874 GNULIB_MBSRCHR
875 GNULIB_MBSCHR
876 GNULIB_MBSNLEN
877 GNULIB_MBSLEN
878 GNULIB_STRTOK_R
879 GNULIB_STRCASESTR
880 GNULIB_STRSTR
881 GNULIB_STRSEP
882 GNULIB_STRPBRK
883 GNULIB_STRNLEN
884 GNULIB_STRNDUP
885 GNULIB_STRNCAT
886 GNULIB_STRDUP
887 GNULIB_STRCHRNUL
888 GNULIB_STPNCPY
889 GNULIB_STPCPY
890 GNULIB_RAWMEMCHR
891 GNULIB_MEMRCHR
892 GNULIB_MEMPCPY
893 GNULIB_MEMMEM
894 GNULIB_MEMCHR
895 GNULIB_FFSLL
896 GNULIB_FFSL
897 LOCALE_FR
898 LOCALE_FR_UTF8
899 LOCALE_ZH_CN
900 LOCALE_JA
901 REPLACE_WCSWIDTH
902 REPLACE_WCWIDTH
903 REPLACE_WCSNRTOMBS
904 REPLACE_WCSRTOMBS
905 REPLACE_WCRTOMB
906 REPLACE_MBSNRTOWCS
907 REPLACE_MBSRTOWCS
908 REPLACE_MBRLEN
909 REPLACE_MBRTOWC
910 REPLACE_MBSINIT
911 REPLACE_WCTOB
912 REPLACE_BTOWC
913 REPLACE_MBSTATE_T
914 HAVE_DECL_WCWIDTH
915 HAVE_DECL_WCTOB
916 HAVE_WCSWIDTH
917 HAVE_WCSTOK
918 HAVE_WCSSTR
919 HAVE_WCSPBRK
920 HAVE_WCSSPN
921 HAVE_WCSCSPN
922 HAVE_WCSRCHR
923 HAVE_WCSCHR
924 HAVE_WCSDUP
925 HAVE_WCSXFRM
926 HAVE_WCSCOLL
927 HAVE_WCSNCASECMP
928 HAVE_WCSCASECMP
929 HAVE_WCSNCMP
930 HAVE_WCSCMP
931 HAVE_WCSNCAT
932 HAVE_WCSCAT
933 HAVE_WCPNCPY
934 HAVE_WCSNCPY
935 HAVE_WCPCPY
936 HAVE_WCSCPY
937 HAVE_WCSNLEN
938 HAVE_WCSLEN
939 HAVE_WMEMSET
940 HAVE_WMEMMOVE
941 HAVE_WMEMCPY
942 HAVE_WMEMCMP
943 HAVE_WMEMCHR
944 HAVE_WCSNRTOMBS
945 HAVE_WCSRTOMBS
946 HAVE_WCRTOMB
947 HAVE_MBSNRTOWCS
948 HAVE_MBSRTOWCS
949 HAVE_MBRLEN
950 HAVE_MBRTOWC
951 HAVE_MBSINIT
952 HAVE_BTOWC
953 GNULIB_WCSWIDTH
954 GNULIB_WCSTOK
955 GNULIB_WCSSTR
956 GNULIB_WCSPBRK
957 GNULIB_WCSSPN
958 GNULIB_WCSCSPN
959 GNULIB_WCSRCHR
960 GNULIB_WCSCHR
961 GNULIB_WCSDUP
962 GNULIB_WCSXFRM
963 GNULIB_WCSCOLL
964 GNULIB_WCSNCASECMP
965 GNULIB_WCSCASECMP
966 GNULIB_WCSNCMP
967 GNULIB_WCSCMP
968 GNULIB_WCSNCAT
969 GNULIB_WCSCAT
970 GNULIB_WCPNCPY
971 GNULIB_WCSNCPY
972 GNULIB_WCPCPY
973 GNULIB_WCSCPY
974 GNULIB_WCSNLEN
975 GNULIB_WCSLEN
976 GNULIB_WMEMSET
977 GNULIB_WMEMMOVE
978 GNULIB_WMEMCPY
979 GNULIB_WMEMCMP
980 GNULIB_WMEMCHR
981 GNULIB_WCWIDTH
982 GNULIB_WCSNRTOMBS
983 GNULIB_WCSRTOMBS
984 GNULIB_WCRTOMB
985 GNULIB_MBSNRTOWCS
986 GNULIB_MBSRTOWCS
987 GNULIB_MBRLEN
988 GNULIB_MBRTOWC
989 GNULIB_MBSINIT
990 GNULIB_WCTOB
991 GNULIB_BTOWC
992 NEXT_AS_FIRST_DIRECTIVE_MATH_H
993 NEXT_MATH_H
994 LOCALCHARSET_TESTS_ENVIRONMENT
995 GLIBC21
996 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
997 NEXT_INTTYPES_H
998 UINT64_MAX_EQ_ULONG_MAX
999 UINT32_MAX_LT_UINTMAX_MAX
1000 PRIPTR_PREFIX
1001 PRI_MACROS_BROKEN
1002 INT64_MAX_EQ_LONG_MAX
1003 INT32_MAX_LT_INTMAX_MAX
1004 REPLACE_STRTOUMAX
1005 REPLACE_STRTOIMAX
1006 HAVE_DECL_STRTOUMAX
1007 HAVE_DECL_STRTOIMAX
1008 HAVE_DECL_IMAXDIV
1009 HAVE_DECL_IMAXABS
1010 GNULIB_STRTOUMAX
1011 GNULIB_STRTOIMAX
1012 GNULIB_IMAXDIV
1013 GNULIB_IMAXABS
1014 GL_GENERATE_STDINT_H_FALSE
1015 GL_GENERATE_STDINT_H_TRUE
1016 STDINT_H
1017 HAVE_SYS_INTTYPES_H
1018 HAVE_SYS_BITYPES_H
1019 HAVE_C99_STDINT_H
1020 WINT_T_SUFFIX
1021 WCHAR_T_SUFFIX
1022 SIG_ATOMIC_T_SUFFIX
1023 SIZE_T_SUFFIX
1024 PTRDIFF_T_SUFFIX
1025 HAVE_SIGNED_WINT_T
1026 HAVE_SIGNED_WCHAR_T
1027 HAVE_SIGNED_SIG_ATOMIC_T
1028 BITSIZEOF_WINT_T
1029 BITSIZEOF_WCHAR_T
1030 BITSIZEOF_SIG_ATOMIC_T
1031 BITSIZEOF_SIZE_T
1032 BITSIZEOF_PTRDIFF_T
1033 APPLE_UNIVERSAL_BUILD
1034 HAVE_STDINT_H
1035 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
1036 NEXT_STDINT_H
1037 HAVE_SYS_TYPES_H
1038 HAVE_INTTYPES_H
1039 HAVE_WCHAR_H
1040 HAVE_UNSIGNED_LONG_LONG_INT
1041 HAVE_LONG_LONG_INT
1042 GL_GENERATE_LIMITS_H_FALSE
1043 GL_GENERATE_LIMITS_H_TRUE
1044 LIMITS_H
1045 NEXT_AS_FIRST_DIRECTIVE_LIMITS_H
1046 NEXT_LIMITS_H
1047 HAVE_SYS_CDEFS_H
1048 GL_GENERATE_GLOB_H_FALSE
1049 GL_GENERATE_GLOB_H_TRUE
1050 GLOB_H
1051 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
1052 NEXT_SYS_TIME_H
1053 REPLACE_STRUCT_TIMEVAL
1054 REPLACE_GETTIMEOFDAY
1055 HAVE_TIMEZONE_T
1056 HAVE_SYS_TIME_H
1057 HAVE_STRUCT_TIMEVAL
1058 HAVE_GETTIMEOFDAY
1059 GNULIB_GETTIMEOFDAY
1060 LTLIBINTL
1061 LIBINTL
1062 WINDOWS_64_BIT_ST_SIZE
1063 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
1064 NEXT_SYS_STAT_H
1065 REPLACE_UTIMENSAT
1066 REPLACE_STAT
1067 REPLACE_MKNOD
1068 REPLACE_MKFIFO
1069 REPLACE_MKDIR
1070 REPLACE_LSTAT
1071 REPLACE_FUTIMENS
1072 REPLACE_FSTATAT
1073 REPLACE_FSTAT
1074 HAVE_UTIMENSAT
1075 HAVE_MKNODAT
1076 HAVE_MKNOD
1077 HAVE_MKFIFOAT
1078 HAVE_MKFIFO
1079 HAVE_MKDIRAT
1080 HAVE_LSTAT
1081 HAVE_LCHMOD
1082 HAVE_FUTIMENS
1083 HAVE_FSTATAT
1084 HAVE_FCHMODAT
1085 GNULIB_UTIMENSAT
1086 GNULIB_STAT
1087 GNULIB_MKNODAT
1088 GNULIB_MKNOD
1089 GNULIB_MKFIFOAT
1090 GNULIB_MKFIFO
1091 GNULIB_MKDIRAT
1092 GNULIB_LSTAT
1093 GNULIB_LCHMOD
1094 GNULIB_FUTIMENS
1095 GNULIB_FSTATAT
1096 GNULIB_FSTAT
1097 GNULIB_FCHMODAT
1098 FREXPL_LIBM
1099 HAVE_SAME_LONG_DOUBLE_AS_DOUBLE
1100 FREXP_LIBM
1101 REPLACE_TRUNCL
1102 REPLACE_TRUNCF
1103 REPLACE_TRUNC
1104 REPLACE_SQRTL
1105 REPLACE_SIGNBIT_USING_GCC
1106 REPLACE_SIGNBIT
1107 REPLACE_ROUNDL
1108 REPLACE_ROUNDF
1109 REPLACE_ROUND
1110 REPLACE_REMAINDERL
1111 REPLACE_REMAINDERF
1112 REPLACE_REMAINDER
1113 REPLACE_NAN
1114 REPLACE_MODFL
1115 REPLACE_MODFF
1116 REPLACE_MODF
1117 REPLACE_LOGBL
1118 REPLACE_LOGBF
1119 REPLACE_LOGB
1120 REPLACE_LOG2L
1121 REPLACE_LOG2F
1122 REPLACE_LOG2
1123 REPLACE_LOG1PL
1124 REPLACE_LOG1PF
1125 REPLACE_LOG1P
1126 REPLACE_LOG10L
1127 REPLACE_LOG10F
1128 REPLACE_LOG10
1129 REPLACE_LOGL
1130 REPLACE_LOGF
1131 REPLACE_LOG
1132 REPLACE_LDEXPL
1133 REPLACE_ISNAN
1134 REPLACE_ISINF
1135 REPLACE_ISFINITE
1136 REPLACE_ILOGBF
1137 REPLACE_ILOGB
1138 REPLACE_HYPOTL
1139 REPLACE_HYPOTF
1140 REPLACE_HYPOT
1141 REPLACE_HUGE_VAL
1142 REPLACE_FREXPL
1143 REPLACE_FREXP
1144 REPLACE_FREXPF
1145 REPLACE_FMODL
1146 REPLACE_FMODF
1147 REPLACE_FMOD
1148 REPLACE_FMAL
1149 REPLACE_FMAF
1150 REPLACE_FMA
1151 REPLACE_FLOORL
1152 REPLACE_FLOORF
1153 REPLACE_FLOOR
1154 REPLACE_FABSL
1155 REPLACE_EXP2L
1156 REPLACE_EXP2
1157 REPLACE_EXPM1F
1158 REPLACE_EXPM1
1159 REPLACE_CEILL
1160 REPLACE_CEILF
1161 REPLACE_CEIL
1162 REPLACE_CBRTL
1163 REPLACE_CBRTF
1164 HAVE_DECL_TRUNCL
1165 HAVE_DECL_TRUNCF
1166 HAVE_DECL_TRUNC
1167 HAVE_DECL_TANL
1168 HAVE_DECL_SQRTL
1169 HAVE_DECL_SINL
1170 HAVE_DECL_ROUNDL
1171 HAVE_DECL_ROUNDF
1172 HAVE_DECL_ROUND
1173 HAVE_DECL_RINTF
1174 HAVE_DECL_REMAINDERL
1175 HAVE_DECL_REMAINDER
1176 HAVE_DECL_LOGB
1177 HAVE_DECL_LOG2L
1178 HAVE_DECL_LOG2F
1179 HAVE_DECL_LOG2
1180 HAVE_DECL_LOG10L
1181 HAVE_DECL_LOGL
1182 HAVE_DECL_LDEXPL
1183 HAVE_DECL_FREXPL
1184 HAVE_DECL_FLOORL
1185 HAVE_DECL_FLOORF
1186 HAVE_DECL_EXPM1L
1187 HAVE_DECL_EXP2L
1188 HAVE_DECL_EXP2F
1189 HAVE_DECL_EXP2
1190 HAVE_DECL_EXPL
1191 HAVE_DECL_COSL
1192 HAVE_DECL_COPYSIGNF
1193 HAVE_DECL_CEILL
1194 HAVE_DECL_CEILF
1195 HAVE_DECL_CBRTL
1196 HAVE_DECL_CBRTF
1197 HAVE_DECL_ATANL
1198 HAVE_DECL_ASINL
1199 HAVE_DECL_ACOSL
1200 HAVE_TANHF
1201 HAVE_TANL
1202 HAVE_TANF
1203 HAVE_SQRTL
1204 HAVE_SQRTF
1205 HAVE_SINHF
1206 HAVE_SINL
1207 HAVE_SINF
1208 HAVE_RINTL
1209 HAVE_RINT
1210 HAVE_REMAINDERF
1211 HAVE_REMAINDER
1212 HAVE_POWF
1213 HAVE_MODFL
1214 HAVE_MODFF
1215 HAVE_LOGBL
1216 HAVE_LOGBF
1217 HAVE_LOG1PL
1218 HAVE_LOG1PF
1219 HAVE_LOG1P
1220 HAVE_LOG10L
1221 HAVE_LOG10F
1222 HAVE_LOGL
1223 HAVE_LOGF
1224 HAVE_LDEXPF
1225 HAVE_ISNANL
1226 HAVE_ISNAND
1227 HAVE_ISNANF
1228 HAVE_ILOGBL
1229 HAVE_ILOGBF
1230 HAVE_ILOGB
1231 HAVE_HYPOTL
1232 HAVE_HYPOTF
1233 HAVE_FREXPF
1234 HAVE_FMODL
1235 HAVE_FMODF
1236 HAVE_FMAL
1237 HAVE_FMAF
1238 HAVE_FMA
1239 HAVE_FABSL
1240 HAVE_FABSF
1241 HAVE_EXPM1F
1242 HAVE_EXPM1
1243 HAVE_EXPL
1244 HAVE_EXPF
1245 HAVE_COSHF
1246 HAVE_COSL
1247 HAVE_COSF
1248 HAVE_COPYSIGNL
1249 HAVE_COPYSIGN
1250 HAVE_CBRTL
1251 HAVE_CBRTF
1252 HAVE_CBRT
1253 HAVE_ATAN2F
1254 HAVE_ATANL
1255 HAVE_ATANF
1256 HAVE_ASINL
1257 HAVE_ASINF
1258 HAVE_ACOSL
1259 HAVE_ACOSF
1260 GNULIB_TRUNCL
1261 GNULIB_TRUNCF
1262 GNULIB_TRUNC
1263 GNULIB_TANHF
1264 GNULIB_TANL
1265 GNULIB_TANF
1266 GNULIB_SQRTL
1267 GNULIB_SQRTF
1268 GNULIB_SINHF
1269 GNULIB_SINL
1270 GNULIB_SINF
1271 GNULIB_SIGNBIT
1272 GNULIB_ROUNDL
1273 GNULIB_ROUNDF
1274 GNULIB_ROUND
1275 GNULIB_RINTL
1276 GNULIB_RINTF
1277 GNULIB_RINT
1278 GNULIB_REMAINDERL
1279 GNULIB_REMAINDERF
1280 GNULIB_REMAINDER
1281 GNULIB_POWF
1282 GNULIB_MODFL
1283 GNULIB_MODFF
1284 GNULIB_MODF
1285 GNULIB_LOGBL
1286 GNULIB_LOGBF
1287 GNULIB_LOGB
1288 GNULIB_LOG2L
1289 GNULIB_LOG2F
1290 GNULIB_LOG2
1291 GNULIB_LOG1PL
1292 GNULIB_LOG1PF
1293 GNULIB_LOG1P
1294 GNULIB_LOG10L
1295 GNULIB_LOG10F
1296 GNULIB_LOG10
1297 GNULIB_LOGL
1298 GNULIB_LOGF
1299 GNULIB_LOG
1300 GNULIB_LDEXPL
1301 GNULIB_LDEXPF
1302 GNULIB_ISNANL
1303 GNULIB_ISNAND
1304 GNULIB_ISNANF
1305 GNULIB_ISNAN
1306 GNULIB_ISINF
1307 GNULIB_ISFINITE
1308 GNULIB_ILOGBL
1309 GNULIB_ILOGBF
1310 GNULIB_ILOGB
1311 GNULIB_HYPOTL
1312 GNULIB_HYPOTF
1313 GNULIB_HYPOT
1314 GNULIB_FREXPL
1315 GNULIB_FREXP
1316 GNULIB_FREXPF
1317 GNULIB_FMODL
1318 GNULIB_FMODF
1319 GNULIB_FMOD
1320 GNULIB_FMAL
1321 GNULIB_FMAF
1322 GNULIB_FMA
1323 GNULIB_FLOORL
1324 GNULIB_FLOORF
1325 GNULIB_FLOOR
1326 GNULIB_FABSL
1327 GNULIB_FABSF
1328 GNULIB_EXPM1L
1329 GNULIB_EXPM1F
1330 GNULIB_EXPM1
1331 GNULIB_EXP2L
1332 GNULIB_EXP2F
1333 GNULIB_EXP2
1334 GNULIB_EXPL
1335 GNULIB_EXPF
1336 GNULIB_COSHF
1337 GNULIB_COSL
1338 GNULIB_COSF
1339 GNULIB_COPYSIGNL
1340 GNULIB_COPYSIGNF
1341 GNULIB_COPYSIGN
1342 GNULIB_CEILL
1343 GNULIB_CEILF
1344 GNULIB_CEIL
1345 GNULIB_CBRTL
1346 GNULIB_CBRTF
1347 GNULIB_CBRT
1348 GNULIB_ATAN2F
1349 GNULIB_ATANL
1350 GNULIB_ATANF
1351 GNULIB_ASINL
1352 GNULIB_ASINF
1353 GNULIB_ACOSL
1354 GNULIB_ACOSF
1355 GL_GENERATE_FNMATCH_H_FALSE
1356 GL_GENERATE_FNMATCH_H_TRUE
1357 FNMATCH_H
1358 REPLACE_ITOLD
1359 GL_GENERATE_FLOAT_H_FALSE
1360 GL_GENERATE_FLOAT_H_TRUE
1361 FLOAT_H
1362 NEXT_AS_FIRST_DIRECTIVE_FLOAT_H
1363 NEXT_FLOAT_H
1364 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H
1365 NEXT_FCNTL_H
1366 REPLACE_OPENAT
1367 REPLACE_OPEN
1368 REPLACE_FCNTL
1369 HAVE_OPENAT
1370 HAVE_FCNTL
1371 GNULIB_OPENAT
1372 GNULIB_OPEN
1373 GNULIB_NONBLOCKING
1374 GNULIB_FCNTL
1375 EOVERFLOW_VALUE
1376 EOVERFLOW_HIDDEN
1377 ENOLINK_VALUE
1378 ENOLINK_HIDDEN
1379 EMULTIHOP_VALUE
1380 EMULTIHOP_HIDDEN
1381 GL_GENERATE_ERRNO_H_FALSE
1382 GL_GENERATE_ERRNO_H_TRUE
1383 ERRNO_H
1384 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H
1385 NEXT_ERRNO_H
1386 HAVE_DIRENT_H
1387 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H
1388 NEXT_DIRENT_H
1389 PRAGMA_COLUMNS
1390 PRAGMA_SYSTEM_HEADER
1391 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
1392 INCLUDE_NEXT
1393 pkglibexecdir
1394 runstatedir
1395 lispdir
1396 REPLACE_FDOPENDIR
1397 REPLACE_DIRFD
1398 REPLACE_CLOSEDIR
1399 REPLACE_OPENDIR
1400 HAVE_ALPHASORT
1401 HAVE_SCANDIR
1402 HAVE_FDOPENDIR
1403 HAVE_DECL_FDOPENDIR
1404 HAVE_DECL_DIRFD
1405 HAVE_CLOSEDIR
1406 HAVE_REWINDDIR
1407 HAVE_READDIR
1408 HAVE_OPENDIR
1409 GNULIB_ALPHASORT
1410 GNULIB_SCANDIR
1411 GNULIB_FDOPENDIR
1412 GNULIB_DIRFD
1413 GNULIB_CLOSEDIR
1414 GNULIB_REWINDDIR
1415 GNULIB_READDIR
1416 GNULIB_OPENDIR
1417 HAVE_WINSOCK2_H
1418 HAVE_MSVC_INVALID_PARAMETER_HANDLER
1419 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
1420 UNISTD_H_HAVE_WINSOCK2_H
1421 REPLACE_WRITE
1422 REPLACE_USLEEP
1423 REPLACE_UNLINKAT
1424 REPLACE_UNLINK
1425 REPLACE_TTYNAME_R
1426 REPLACE_SYMLINKAT
1427 REPLACE_SYMLINK
1428 REPLACE_SLEEP
1429 REPLACE_RMDIR
1430 REPLACE_READLINKAT
1431 REPLACE_READLINK
1432 REPLACE_READ
1433 REPLACE_PWRITE
1434 REPLACE_PREAD
1435 REPLACE_LSEEK
1436 REPLACE_LINKAT
1437 REPLACE_LINK
1438 REPLACE_LCHOWN
1439 REPLACE_ISATTY
1440 REPLACE_GETPAGESIZE
1441 REPLACE_GETGROUPS
1442 REPLACE_GETLOGIN_R
1443 REPLACE_GETDTABLESIZE
1444 REPLACE_GETDOMAINNAME
1445 REPLACE_GETCWD
1446 REPLACE_FTRUNCATE
1447 REPLACE_FCHOWNAT
1448 REPLACE_DUP2
1449 REPLACE_DUP
1450 REPLACE_CLOSE
1451 REPLACE_CHOWN
1452 HAVE_SYS_PARAM_H
1453 HAVE_OS_H
1454 HAVE_DECL_TTYNAME_R
1455 HAVE_DECL_SETHOSTNAME
1456 HAVE_DECL_GETUSERSHELL
1457 HAVE_DECL_GETPAGESIZE
1458 HAVE_DECL_GETLOGIN_R
1459 HAVE_DECL_GETDOMAINNAME
1460 HAVE_DECL_FDATASYNC
1461 HAVE_DECL_FCHDIR
1462 HAVE_DECL_ENVIRON
1463 HAVE_USLEEP
1464 HAVE_UNLINKAT
1465 HAVE_SYMLINKAT
1466 HAVE_SYMLINK
1467 HAVE_SLEEP
1468 HAVE_SETHOSTNAME
1469 HAVE_READLINKAT
1470 HAVE_READLINK
1471 HAVE_PWRITE
1472 HAVE_PREAD
1473 HAVE_PIPE2
1474 HAVE_PIPE
1475 HAVE_LINKAT
1476 HAVE_LINK
1477 HAVE_LCHOWN
1478 HAVE_GROUP_MEMBER
1479 HAVE_GETPAGESIZE
1480 HAVE_GETLOGIN
1481 HAVE_GETHOSTNAME
1482 HAVE_GETGROUPS
1483 HAVE_GETDTABLESIZE
1484 HAVE_FTRUNCATE
1485 HAVE_FSYNC
1486 HAVE_FDATASYNC
1487 HAVE_FCHOWNAT
1488 HAVE_FCHDIR
1489 HAVE_FACCESSAT
1490 HAVE_EUIDACCESS
1491 HAVE_DUP3
1492 HAVE_DUP2
1493 HAVE_CHOWN
1494 GNULIB_WRITE
1495 GNULIB_USLEEP
1496 GNULIB_UNLINKAT
1497 GNULIB_UNLINK
1498 GNULIB_UNISTD_H_SIGPIPE
1499 GNULIB_UNISTD_H_NONBLOCKING
1500 GNULIB_TTYNAME_R
1501 GNULIB_SYMLINKAT
1502 GNULIB_SYMLINK
1503 GNULIB_SLEEP
1504 GNULIB_SETHOSTNAME
1505 GNULIB_RMDIR
1506 GNULIB_READLINKAT
1507 GNULIB_READLINK
1508 GNULIB_READ
1509 GNULIB_PWRITE
1510 GNULIB_PREAD
1511 GNULIB_PIPE2
1512 GNULIB_PIPE
1513 GNULIB_LSEEK
1514 GNULIB_LINKAT
1515 GNULIB_LINK
1516 GNULIB_LCHOWN
1517 GNULIB_ISATTY
1518 GNULIB_GROUP_MEMBER
1519 GNULIB_GETUSERSHELL
1520 GNULIB_GETPAGESIZE
1521 GNULIB_GETLOGIN_R
1522 GNULIB_GETLOGIN
1523 GNULIB_GETHOSTNAME
1524 GNULIB_GETGROUPS
1525 GNULIB_GETDTABLESIZE
1526 GNULIB_GETDOMAINNAME
1527 GNULIB_GETCWD
1528 GNULIB_FTRUNCATE
1529 GNULIB_FSYNC
1530 GNULIB_FDATASYNC
1531 GNULIB_FCHOWNAT
1532 GNULIB_FCHDIR
1533 GNULIB_FACCESSAT
1534 GNULIB_EUIDACCESS
1535 GNULIB_ENVIRON
1536 GNULIB_DUP3
1537 GNULIB_DUP2
1538 GNULIB_DUP
1539 GNULIB_CLOSE
1540 GNULIB_CHOWN
1541 GNULIB_CHDIR
1542 REPLACE_WCTOMB
1543 REPLACE_UNSETENV
1544 REPLACE_STRTOD
1545 REPLACE_SETENV
1546 REPLACE_REALPATH
1547 REPLACE_REALLOC
1548 REPLACE_RANDOM_R
1549 REPLACE_QSORT_R
1550 REPLACE_PUTENV
1551 REPLACE_PTSNAME_R
1552 REPLACE_PTSNAME
1553 REPLACE_MKSTEMP
1554 REPLACE_MBTOWC
1555 REPLACE_MALLOC
1556 REPLACE_CANONICALIZE_FILE_NAME
1557 REPLACE_CALLOC
1558 HAVE_DECL_UNSETENV
1559 HAVE_UNLOCKPT
1560 HAVE_SYS_LOADAVG_H
1561 HAVE_STRUCT_RANDOM_DATA
1562 HAVE_STRTOULL
1563 HAVE_STRTOLL
1564 HAVE_STRTOD
1565 HAVE_DECL_SETENV
1566 HAVE_SETENV
1567 HAVE_SECURE_GETENV
1568 HAVE_RPMATCH
1569 HAVE_REALPATH
1570 HAVE_RANDOM_R
1571 HAVE_RANDOM_H
1572 HAVE_RANDOM
1573 HAVE_QSORT_R
1574 HAVE_PTSNAME_R
1575 HAVE_PTSNAME
1576 HAVE_POSIX_OPENPT
1577 HAVE_MKSTEMPS
1578 HAVE_MKSTEMP
1579 HAVE_MKOSTEMPS
1580 HAVE_MKOSTEMP
1581 HAVE_MKDTEMP
1582 HAVE_GRANTPT
1583 HAVE_GETSUBOPT
1584 HAVE_DECL_GETLOADAVG
1585 HAVE_CANONICALIZE_FILE_NAME
1586 HAVE_ATOLL
1587 HAVE__EXIT
1588 GNULIB_WCTOMB
1589 GNULIB_UNSETENV
1590 GNULIB_UNLOCKPT
1591 GNULIB_SYSTEM_POSIX
1592 GNULIB_STRTOULL
1593 GNULIB_STRTOLL
1594 GNULIB_STRTOD
1595 GNULIB_SETENV
1596 GNULIB_SECURE_GETENV
1597 GNULIB_RPMATCH
1598 GNULIB_REALPATH
1599 GNULIB_REALLOC_POSIX
1600 GNULIB_RANDOM_R
1601 GNULIB_RANDOM
1602 GNULIB_QSORT_R
1603 GNULIB_PUTENV
1604 GNULIB_PTSNAME_R
1605 GNULIB_PTSNAME
1606 GNULIB_POSIX_OPENPT
1607 GNULIB_MKSTEMPS
1608 GNULIB_MKSTEMP
1609 GNULIB_MKOSTEMPS
1610 GNULIB_MKOSTEMP
1611 GNULIB_MKDTEMP
1612 GNULIB_MBTOWC
1613 GNULIB_MALLOC_POSIX
1614 GNULIB_GRANTPT
1615 GNULIB_GETSUBOPT
1616 GNULIB_GETLOADAVG
1617 GNULIB_CANONICALIZE_FILE_NAME
1618 GNULIB_CALLOC_POSIX
1619 GNULIB_ATOLL
1620 GNULIB__EXIT
1621 GL_GENERATE_ALLOCA_H_FALSE
1622 GL_GENERATE_ALLOCA_H_TRUE
1623 ALLOCA_H
1624 ALLOCA
1625 GL_COND_LIBTOOL_FALSE
1626 GL_COND_LIBTOOL_TRUE
1627 target_os
1628 target_vendor
1629 target_cpu
1630 target
1631 host_os
1632 host_vendor
1633 host_cpu
1634 host
1635 build_os
1636 build_vendor
1637 build_cpu
1638 build
1639 RANLIB
1640 ARFLAGS
1641 AR
1642 EGREP
1643 GREP
1644 CPP
1645 OBJEXT
1646 EXEEXT
1647 ac_ct_CC
1648 CPPFLAGS
1649 LDFLAGS
1650 CFLAGS
1651 CC
1652 MAINT
1653 MAINTAINER_MODE_FALSE
1654 MAINTAINER_MODE_TRUE
1655 target_alias
1656 host_alias
1657 build_alias
1658 LIBS
1659 ECHO_T
1660 ECHO_N
1661 ECHO_C
1662 DEFS
1663 mandir
1664 localedir
1665 libdir
1666 psdir
1667 pdfdir
1668 dvidir
1669 htmldir
1670 infodir
1671 docdir
1672 oldincludedir
1673 includedir
1674 localstatedir
1675 sharedstatedir
1676 sysconfdir
1677 datadir
1678 datarootdir
1679 libexecdir
1680 sbindir
1681 bindir
1682 program_transform_name
1683 prefix
1684 exec_prefix
1685 PACKAGE_URL
1686 PACKAGE_BUGREPORT
1687 PACKAGE_STRING
1688 PACKAGE_VERSION
1689 PACKAGE_TARNAME
1690 PACKAGE_NAME
1691 PATH_SEPARATOR
1692 SHELL'
1693 ac_subst_files=''
1694 ac_user_opts='
1695 enable_option_checking
1696 enable_maintainer_mode
1697 enable_largefile
1698 enable_dependency_tracking
1699 enable_silent_rules
1700 '
1701 ac_precious_vars='build_alias
1702 host_alias
1703 target_alias
1704 CC
1705 CFLAGS
1706 LDFLAGS
1707 LIBS
1708 CPPFLAGS
1709 CPP'
1710
1711
1712 # Initialize some variables set by options.
1713 ac_init_help=
1714 ac_init_version=false
1715 ac_unrecognized_opts=
1716 ac_unrecognized_sep=
1717 # The variables have the same names as the options, with
1718 # dashes changed to underlines.
1719 cache_file=/dev/null
1720 exec_prefix=NONE
1721 no_create=
1722 no_recursion=
1723 prefix=NONE
1724 program_prefix=NONE
1725 program_suffix=NONE
1726 program_transform_name=s,x,x,
1727 silent=
1728 site=
1729 srcdir=
1730 verbose=
1731 x_includes=NONE
1732 x_libraries=NONE
1733
1734 # Installation directory options.
1735 # These are left unexpanded so users can "make install exec_prefix=/foo"
1736 # and all the variables that are supposed to be based on exec_prefix
1737 # by default will actually change.
1738 # Use braces instead of parens because sh, perl, etc. also accept them.
1739 # (The list follows the same order as the GNU Coding Standards.)
1740 bindir='${exec_prefix}/bin'
1741 sbindir='${exec_prefix}/sbin'
1742 libexecdir='${exec_prefix}/libexec'
1743 datarootdir='${prefix}/share'
1744 datadir='${datarootdir}'
1745 sysconfdir='${prefix}/etc'
1746 sharedstatedir='${prefix}/com'
1747 localstatedir='${prefix}/var'
1748 includedir='${prefix}/include'
1749 oldincludedir='/usr/include'
1750 docdir='${datarootdir}/doc/${PACKAGE}'
1751 infodir='${datarootdir}/info'
1752 htmldir='${docdir}'
1753 dvidir='${docdir}'
1754 pdfdir='${docdir}'
1755 psdir='${docdir}'
1756 libdir='${exec_prefix}/lib'
1757 localedir='${datarootdir}/locale'
1758 mandir='${datarootdir}/man'
1759
1760 ac_prev=
1761 ac_dashdash=
1762 for ac_option
1763 do
1764 # If the previous option needs an argument, assign it.
1765 if test -n "$ac_prev"; then
1766 eval $ac_prev=\$ac_option
1767 ac_prev=
1768 continue
1769 fi
1770
1771 case $ac_option in
1772 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1773 *) ac_optarg=yes ;;
1774 esac
1775
1776 # Accept the important Cygnus configure options, so we can diagnose typos.
1777
1778 case $ac_dashdash$ac_option in
1779 --)
1780 ac_dashdash=yes ;;
1781
1782 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1783 ac_prev=bindir ;;
1784 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1785 bindir=$ac_optarg ;;
1786
1787 -build | --build | --buil | --bui | --bu)
1788 ac_prev=build_alias ;;
1789 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1790 build_alias=$ac_optarg ;;
1791
1792 -cache-file | --cache-file | --cache-fil | --cache-fi \
1793 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1794 ac_prev=cache_file ;;
1795 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1796 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1797 cache_file=$ac_optarg ;;
1798
1799 --config-cache | -C)
1800 cache_file=config.cache ;;
1801
1802 -datadir | --datadir | --datadi | --datad)
1803 ac_prev=datadir ;;
1804 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1805 datadir=$ac_optarg ;;
1806
1807 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1808 | --dataroo | --dataro | --datar)
1809 ac_prev=datarootdir ;;
1810 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1811 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1812 datarootdir=$ac_optarg ;;
1813
1814 -disable-* | --disable-*)
1815 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1816 # Reject names that are not valid shell variable names.
1817 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1818 as_fn_error "invalid feature name: $ac_useropt"
1819 ac_useropt_orig=$ac_useropt
1820 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1821 case $ac_user_opts in
1822 *"
1823 "enable_$ac_useropt"
1824 "*) ;;
1825 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1826 ac_unrecognized_sep=', ';;
1827 esac
1828 eval enable_$ac_useropt=no ;;
1829
1830 -docdir | --docdir | --docdi | --doc | --do)
1831 ac_prev=docdir ;;
1832 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1833 docdir=$ac_optarg ;;
1834
1835 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1836 ac_prev=dvidir ;;
1837 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1838 dvidir=$ac_optarg ;;
1839
1840 -enable-* | --enable-*)
1841 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1842 # Reject names that are not valid shell variable names.
1843 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1844 as_fn_error "invalid feature name: $ac_useropt"
1845 ac_useropt_orig=$ac_useropt
1846 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1847 case $ac_user_opts in
1848 *"
1849 "enable_$ac_useropt"
1850 "*) ;;
1851 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1852 ac_unrecognized_sep=', ';;
1853 esac
1854 eval enable_$ac_useropt=\$ac_optarg ;;
1855
1856 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1857 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1858 | --exec | --exe | --ex)
1859 ac_prev=exec_prefix ;;
1860 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1861 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1862 | --exec=* | --exe=* | --ex=*)
1863 exec_prefix=$ac_optarg ;;
1864
1865 -gas | --gas | --ga | --g)
1866 # Obsolete; use --with-gas.
1867 with_gas=yes ;;
1868
1869 -help | --help | --hel | --he | -h)
1870 ac_init_help=long ;;
1871 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1872 ac_init_help=recursive ;;
1873 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1874 ac_init_help=short ;;
1875
1876 -host | --host | --hos | --ho)
1877 ac_prev=host_alias ;;
1878 -host=* | --host=* | --hos=* | --ho=*)
1879 host_alias=$ac_optarg ;;
1880
1881 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1882 ac_prev=htmldir ;;
1883 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1884 | --ht=*)
1885 htmldir=$ac_optarg ;;
1886
1887 -includedir | --includedir | --includedi | --included | --include \
1888 | --includ | --inclu | --incl | --inc)
1889 ac_prev=includedir ;;
1890 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1891 | --includ=* | --inclu=* | --incl=* | --inc=*)
1892 includedir=$ac_optarg ;;
1893
1894 -infodir | --infodir | --infodi | --infod | --info | --inf)
1895 ac_prev=infodir ;;
1896 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1897 infodir=$ac_optarg ;;
1898
1899 -libdir | --libdir | --libdi | --libd)
1900 ac_prev=libdir ;;
1901 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1902 libdir=$ac_optarg ;;
1903
1904 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1905 | --libexe | --libex | --libe)
1906 ac_prev=libexecdir ;;
1907 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1908 | --libexe=* | --libex=* | --libe=*)
1909 libexecdir=$ac_optarg ;;
1910
1911 -localedir | --localedir | --localedi | --localed | --locale)
1912 ac_prev=localedir ;;
1913 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1914 localedir=$ac_optarg ;;
1915
1916 -localstatedir | --localstatedir | --localstatedi | --localstated \
1917 | --localstate | --localstat | --localsta | --localst | --locals)
1918 ac_prev=localstatedir ;;
1919 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1920 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1921 localstatedir=$ac_optarg ;;
1922
1923 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1924 ac_prev=mandir ;;
1925 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1926 mandir=$ac_optarg ;;
1927
1928 -nfp | --nfp | --nf)
1929 # Obsolete; use --without-fp.
1930 with_fp=no ;;
1931
1932 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1933 | --no-cr | --no-c | -n)
1934 no_create=yes ;;
1935
1936 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1937 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1938 no_recursion=yes ;;
1939
1940 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1941 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1942 | --oldin | --oldi | --old | --ol | --o)
1943 ac_prev=oldincludedir ;;
1944 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1945 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1946 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1947 oldincludedir=$ac_optarg ;;
1948
1949 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1950 ac_prev=prefix ;;
1951 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1952 prefix=$ac_optarg ;;
1953
1954 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1955 | --program-pre | --program-pr | --program-p)
1956 ac_prev=program_prefix ;;
1957 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1958 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1959 program_prefix=$ac_optarg ;;
1960
1961 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1962 | --program-suf | --program-su | --program-s)
1963 ac_prev=program_suffix ;;
1964 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1965 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1966 program_suffix=$ac_optarg ;;
1967
1968 -program-transform-name | --program-transform-name \
1969 | --program-transform-nam | --program-transform-na \
1970 | --program-transform-n | --program-transform- \
1971 | --program-transform | --program-transfor \
1972 | --program-transfo | --program-transf \
1973 | --program-trans | --program-tran \
1974 | --progr-tra | --program-tr | --program-t)
1975 ac_prev=program_transform_name ;;
1976 -program-transform-name=* | --program-transform-name=* \
1977 | --program-transform-nam=* | --program-transform-na=* \
1978 | --program-transform-n=* | --program-transform-=* \
1979 | --program-transform=* | --program-transfor=* \
1980 | --program-transfo=* | --program-transf=* \
1981 | --program-trans=* | --program-tran=* \
1982 | --progr-tra=* | --program-tr=* | --program-t=*)
1983 program_transform_name=$ac_optarg ;;
1984
1985 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1986 ac_prev=pdfdir ;;
1987 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1988 pdfdir=$ac_optarg ;;
1989
1990 -psdir | --psdir | --psdi | --psd | --ps)
1991 ac_prev=psdir ;;
1992 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1993 psdir=$ac_optarg ;;
1994
1995 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1996 | -silent | --silent | --silen | --sile | --sil)
1997 silent=yes ;;
1998
1999 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
2000 ac_prev=sbindir ;;
2001 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
2002 | --sbi=* | --sb=*)
2003 sbindir=$ac_optarg ;;
2004
2005 -sharedstatedir | --sharedstatedir | --sharedstatedi \
2006 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
2007 | --sharedst | --shareds | --shared | --share | --shar \
2008 | --sha | --sh)
2009 ac_prev=sharedstatedir ;;
2010 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
2011 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
2012 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
2013 | --sha=* | --sh=*)
2014 sharedstatedir=$ac_optarg ;;
2015
2016 -site | --site | --sit)
2017 ac_prev=site ;;
2018 -site=* | --site=* | --sit=*)
2019 site=$ac_optarg ;;
2020
2021 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
2022 ac_prev=srcdir ;;
2023 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
2024 srcdir=$ac_optarg ;;
2025
2026 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
2027 | --syscon | --sysco | --sysc | --sys | --sy)
2028 ac_prev=sysconfdir ;;
2029 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
2030 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
2031 sysconfdir=$ac_optarg ;;
2032
2033 -target | --target | --targe | --targ | --tar | --ta | --t)
2034 ac_prev=target_alias ;;
2035 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
2036 target_alias=$ac_optarg ;;
2037
2038 -v | -verbose | --verbose | --verbos | --verbo | --verb)
2039 verbose=yes ;;
2040
2041 -version | --version | --versio | --versi | --vers | -V)
2042 ac_init_version=: ;;
2043
2044 -with-* | --with-*)
2045 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
2046 # Reject names that are not valid shell variable names.
2047 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
2048 as_fn_error "invalid package name: $ac_useropt"
2049 ac_useropt_orig=$ac_useropt
2050 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
2051 case $ac_user_opts in
2052 *"
2053 "with_$ac_useropt"
2054 "*) ;;
2055 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
2056 ac_unrecognized_sep=', ';;
2057 esac
2058 eval with_$ac_useropt=\$ac_optarg ;;
2059
2060 -without-* | --without-*)
2061 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
2062 # Reject names that are not valid shell variable names.
2063 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
2064 as_fn_error "invalid package name: $ac_useropt"
2065 ac_useropt_orig=$ac_useropt
2066 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
2067 case $ac_user_opts in
2068 *"
2069 "with_$ac_useropt"
2070 "*) ;;
2071 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
2072 ac_unrecognized_sep=', ';;
2073 esac
2074 eval with_$ac_useropt=no ;;
2075
2076 --x)
2077 # Obsolete; use --with-x.
2078 with_x=yes ;;
2079
2080 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
2081 | --x-incl | --x-inc | --x-in | --x-i)
2082 ac_prev=x_includes ;;
2083 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
2084 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
2085 x_includes=$ac_optarg ;;
2086
2087 -x-libraries | --x-libraries | --x-librarie | --x-librari \
2088 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
2089 ac_prev=x_libraries ;;
2090 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
2091 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
2092 x_libraries=$ac_optarg ;;
2093
2094 -*) as_fn_error "unrecognized option: \`$ac_option'
2095 Try \`$0 --help' for more information."
2096 ;;
2097
2098 *=*)
2099 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
2100 # Reject names that are not valid shell variable names.
2101 case $ac_envvar in #(
2102 '' | [0-9]* | *[!_$as_cr_alnum]* )
2103 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
2104 esac
2105 eval $ac_envvar=\$ac_optarg
2106 export $ac_envvar ;;
2107
2108 *)
2109 # FIXME: should be removed in autoconf 3.0.
2110 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
2111 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
2112 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
2113 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
2114 ;;
2115
2116 esac
2117 done
2118
2119 if test -n "$ac_prev"; then
2120 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
2121 as_fn_error "missing argument to $ac_option"
2122 fi
2123
2124 if test -n "$ac_unrecognized_opts"; then
2125 case $enable_option_checking in
2126 no) ;;
2127 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
2128 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
2129 esac
2130 fi
2131
2132 # Check all directory arguments for consistency.
2133 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
2134 datadir sysconfdir sharedstatedir localstatedir includedir \
2135 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
2136 libdir localedir mandir
2137 do
2138 eval ac_val=\$$ac_var
2139 # Remove trailing slashes.
2140 case $ac_val in
2141 */ )
2142 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
2143 eval $ac_var=\$ac_val;;
2144 esac
2145 # Be sure to have absolute directory names.
2146 case $ac_val in
2147 [\\/$]* | ?:[\\/]* ) continue;;
2148 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
2149 esac
2150 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
2151 done
2152
2153 # There might be people who depend on the old broken behavior: `$host'
2154 # used to hold the argument of --host etc.
2155 # FIXME: To remove some day.
2156 build=$build_alias
2157 host=$host_alias
2158 target=$target_alias
2159
2160 # FIXME: To remove some day.
2161 if test "x$host_alias" != x; then
2162 if test "x$build_alias" = x; then
2163 cross_compiling=maybe
2164 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
2165 If a cross compiler is detected then cross compile mode will be used." >&2
2166 elif test "x$build_alias" != "x$host_alias"; then
2167 cross_compiling=yes
2168 fi
2169 fi
2170
2171 ac_tool_prefix=
2172 test -n "$host_alias" && ac_tool_prefix=$host_alias-
2173
2174 test "$silent" = yes && exec 6>/dev/null
2175
2176
2177 ac_pwd=`pwd` && test -n "$ac_pwd" &&
2178 ac_ls_di=`ls -di .` &&
2179 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
2180 as_fn_error "working directory cannot be determined"
2181 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
2182 as_fn_error "pwd does not report name of working directory"
2183
2184
2185 # Find the source files, if location was not specified.
2186 if test -z "$srcdir"; then
2187 ac_srcdir_defaulted=yes
2188 # Try the directory containing this script, then the parent directory.
2189 ac_confdir=`$as_dirname -- "$as_myself" ||
2190 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
2191 X"$as_myself" : 'X\(//\)[^/]' \| \
2192 X"$as_myself" : 'X\(//\)$' \| \
2193 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
2194 $as_echo X"$as_myself" |
2195 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
2196 s//\1/
2197 q
2198 }
2199 /^X\(\/\/\)[^/].*/{
2200 s//\1/
2201 q
2202 }
2203 /^X\(\/\/\)$/{
2204 s//\1/
2205 q
2206 }
2207 /^X\(\/\).*/{
2208 s//\1/
2209 q
2210 }
2211 s/.*/./; q'`
2212 srcdir=$ac_confdir
2213 if test ! -r "$srcdir/$ac_unique_file"; then
2214 srcdir=..
2215 fi
2216 else
2217 ac_srcdir_defaulted=no
2218 fi
2219 if test ! -r "$srcdir/$ac_unique_file"; then
2220 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
2221 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
2222 fi
2223 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
2224 ac_abs_confdir=`(
2225 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
2226 pwd)`
2227 # When building in place, set srcdir=.
2228 if test "$ac_abs_confdir" = "$ac_pwd"; then
2229 srcdir=.
2230 fi
2231 # Remove unnecessary trailing slashes from srcdir.
2232 # Double slashes in file names in object file debugging info
2233 # mess up M-x gdb in Emacs.
2234 case $srcdir in
2235 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
2236 esac
2237 for ac_var in $ac_precious_vars; do
2238 eval ac_env_${ac_var}_set=\${${ac_var}+set}
2239 eval ac_env_${ac_var}_value=\$${ac_var}
2240 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
2241 eval ac_cv_env_${ac_var}_value=\$${ac_var}
2242 done
2243
2244 #
2245 # Report the --help message.
2246 #
2247 if test "$ac_init_help" = "long"; then
2248 # Omit some internal or obsolete options to make the list less imposing.
2249 # This message is too long to be a string in the A/UX 3.1 sh.
2250 cat <<_ACEOF
2251 \`configure' configures this package to adapt to many kinds of systems.
2252
2253 Usage: $0 [OPTION]... [VAR=VALUE]...
2254
2255 To assign environment variables (e.g., CC, CFLAGS...), specify them as
2256 VAR=VALUE. See below for descriptions of some of the useful variables.
2257
2258 Defaults for the options are specified in brackets.
2259
2260 Configuration:
2261 -h, --help display this help and exit
2262 --help=short display options specific to this package
2263 --help=recursive display the short help of all the included packages
2264 -V, --version display version information and exit
2265 -q, --quiet, --silent do not print \`checking...' messages
2266 --cache-file=FILE cache test results in FILE [disabled]
2267 -C, --config-cache alias for \`--cache-file=config.cache'
2268 -n, --no-create do not create output files
2269 --srcdir=DIR find the sources in DIR [configure dir or \`..']
2270
2271 Installation directories:
2272 --prefix=PREFIX install architecture-independent files in PREFIX
2273 [$ac_default_prefix]
2274 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
2275 [PREFIX]
2276
2277 By default, \`make install' will install all the files in
2278 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
2279 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
2280 for instance \`--prefix=\$HOME'.
2281
2282 For better control, use the options below.
2283
2284 Fine tuning of the installation directories:
2285 --bindir=DIR user executables [EPREFIX/bin]
2286 --sbindir=DIR system admin executables [EPREFIX/sbin]
2287 --libexecdir=DIR program executables [EPREFIX/libexec]
2288 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
2289 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
2290 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
2291 --libdir=DIR object code libraries [EPREFIX/lib]
2292 --includedir=DIR C header files [PREFIX/include]
2293 --oldincludedir=DIR C header files for non-gcc [/usr/include]
2294 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
2295 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
2296 --infodir=DIR info documentation [DATAROOTDIR/info]
2297 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
2298 --mandir=DIR man documentation [DATAROOTDIR/man]
2299 --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE]
2300 --htmldir=DIR html documentation [DOCDIR]
2301 --dvidir=DIR dvi documentation [DOCDIR]
2302 --pdfdir=DIR pdf documentation [DOCDIR]
2303 --psdir=DIR ps documentation [DOCDIR]
2304 _ACEOF
2305
2306 cat <<\_ACEOF
2307
2308 Program names:
2309 --program-prefix=PREFIX prepend PREFIX to installed program names
2310 --program-suffix=SUFFIX append SUFFIX to installed program names
2311 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
2312
2313 System types:
2314 --build=BUILD configure for building on BUILD [guessed]
2315 --host=HOST cross-compile to build programs to run on HOST [BUILD]
2316 --target=TARGET configure for building compilers for TARGET [HOST]
2317 _ACEOF
2318 fi
2319
2320 if test -n "$ac_init_help"; then
2321
2322 cat <<\_ACEOF
2323
2324 Optional Features:
2325 --disable-option-checking ignore unrecognized --enable/--with options
2326 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
2327 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
2328 --enable-maintainer-mode enable make rules and dependencies not useful
2329 (and sometimes confusing) to the casual installer
2330 --disable-largefile omit support for large files
2331 --disable-dependency-tracking speeds up one-time build
2332 --enable-dependency-tracking do not reject slow dependency extractors
2333 --enable-silent-rules less verbose build output (undo: `make V=1')
2334 --disable-silent-rules verbose build output (undo: `make V=0')
2335
2336 Some influential environment variables:
2337 CC C compiler command
2338 CFLAGS C compiler flags
2339 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2340 nonstandard directory <lib dir>
2341 LIBS libraries to pass to the linker, e.g. -l<library>
2342 CPPFLAGS C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
2343 you have headers in a nonstandard directory <include dir>
2344 CPP C preprocessor
2345
2346 Use these variables to override the choices made by `configure' or to help
2347 it to find libraries and programs with nonstandard names/locations.
2348
2349 Report bugs to the package provider.
2350 _ACEOF
2351 ac_status=$?
2352 fi
2353
2354 if test "$ac_init_help" = "recursive"; then
2355 # If there are subdirs, report their specific --help.
2356 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2357 test -d "$ac_dir" ||
2358 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2359 continue
2360 ac_builddir=.
2361
2362 case "$ac_dir" in
2363 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2364 *)
2365 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2366 # A ".." for each directory in $ac_dir_suffix.
2367 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2368 case $ac_top_builddir_sub in
2369 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2370 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2371 esac ;;
2372 esac
2373 ac_abs_top_builddir=$ac_pwd
2374 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2375 # for backward compatibility:
2376 ac_top_builddir=$ac_top_build_prefix
2377
2378 case $srcdir in
2379 .) # We are building in place.
2380 ac_srcdir=.
2381 ac_top_srcdir=$ac_top_builddir_sub
2382 ac_abs_top_srcdir=$ac_pwd ;;
2383 [\\/]* | ?:[\\/]* ) # Absolute name.
2384 ac_srcdir=$srcdir$ac_dir_suffix;
2385 ac_top_srcdir=$srcdir
2386 ac_abs_top_srcdir=$srcdir ;;
2387 *) # Relative name.
2388 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2389 ac_top_srcdir=$ac_top_build_prefix$srcdir
2390 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2391 esac
2392 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2393
2394 cd "$ac_dir" || { ac_status=$?; continue; }
2395 # Check for guested configure.
2396 if test -f "$ac_srcdir/configure.gnu"; then
2397 echo &&
2398 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2399 elif test -f "$ac_srcdir/configure"; then
2400 echo &&
2401 $SHELL "$ac_srcdir/configure" --help=recursive
2402 else
2403 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2404 fi || ac_status=$?
2405 cd "$ac_pwd" || { ac_status=$?; break; }
2406 done
2407 fi
2408
2409 test -n "$ac_init_help" && exit $ac_status
2410 if $ac_init_version; then
2411 cat <<\_ACEOF
2412 configure
2413 generated by GNU Autoconf 2.64
2414
2415 Copyright (C) 2009 Free Software Foundation, Inc.
2416 This configure script is free software; the Free Software Foundation
2417 gives unlimited permission to copy, distribute and modify it.
2418 _ACEOF
2419 exit
2420 fi
2421
2422 ## ------------------------ ##
2423 ## Autoconf initialization. ##
2424 ## ------------------------ ##
2425
2426 # ac_fn_c_try_compile LINENO
2427 # --------------------------
2428 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2429 ac_fn_c_try_compile ()
2430 {
2431 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2432 rm -f conftest.$ac_objext
2433 if { { ac_try="$ac_compile"
2434 case "(($ac_try" in
2435 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2436 *) ac_try_echo=$ac_try;;
2437 esac
2438 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2439 $as_echo "$ac_try_echo"; } >&5
2440 (eval "$ac_compile") 2>conftest.err
2441 ac_status=$?
2442 if test -s conftest.err; then
2443 grep -v '^ *+' conftest.err >conftest.er1
2444 cat conftest.er1 >&5
2445 mv -f conftest.er1 conftest.err
2446 fi
2447 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2448 test $ac_status = 0; } && {
2449 test -z "$ac_c_werror_flag" ||
2450 test ! -s conftest.err
2451 } && test -s conftest.$ac_objext; then :
2452 ac_retval=0
2453 else
2454 $as_echo "$as_me: failed program was:" >&5
2455 sed 's/^/| /' conftest.$ac_ext >&5
2456
2457 ac_retval=1
2458 fi
2459 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2460 return $ac_retval
2461
2462 } # ac_fn_c_try_compile
2463
2464 # ac_fn_c_try_cpp LINENO
2465 # ----------------------
2466 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2467 ac_fn_c_try_cpp ()
2468 {
2469 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2470 if { { ac_try="$ac_cpp conftest.$ac_ext"
2471 case "(($ac_try" in
2472 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2473 *) ac_try_echo=$ac_try;;
2474 esac
2475 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2476 $as_echo "$ac_try_echo"; } >&5
2477 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2478 ac_status=$?
2479 if test -s conftest.err; then
2480 grep -v '^ *+' conftest.err >conftest.er1
2481 cat conftest.er1 >&5
2482 mv -f conftest.er1 conftest.err
2483 fi
2484 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2485 test $ac_status = 0; } >/dev/null && {
2486 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2487 test ! -s conftest.err
2488 }; then :
2489 ac_retval=0
2490 else
2491 $as_echo "$as_me: failed program was:" >&5
2492 sed 's/^/| /' conftest.$ac_ext >&5
2493
2494 ac_retval=1
2495 fi
2496 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2497 return $ac_retval
2498
2499 } # ac_fn_c_try_cpp
2500
2501 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2502 # -------------------------------------------------------
2503 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2504 # the include files in INCLUDES and setting the cache variable VAR
2505 # accordingly.
2506 ac_fn_c_check_header_mongrel ()
2507 {
2508 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2509 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2511 $as_echo_n "checking for $2... " >&6; }
2512 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2513 $as_echo_n "(cached) " >&6
2514 fi
2515 eval ac_res=\$$3
2516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2517 $as_echo "$ac_res" >&6; }
2518 else
2519 # Is the header compilable?
2520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2521 $as_echo_n "checking $2 usability... " >&6; }
2522 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2523 /* end confdefs.h. */
2524 $4
2525 #include <$2>
2526 _ACEOF
2527 if ac_fn_c_try_compile "$LINENO"; then :
2528 ac_header_compiler=yes
2529 else
2530 ac_header_compiler=no
2531 fi
2532 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2534 $as_echo "$ac_header_compiler" >&6; }
2535
2536 # Is the header present?
2537 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2538 $as_echo_n "checking $2 presence... " >&6; }
2539 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2540 /* end confdefs.h. */
2541 #include <$2>
2542 _ACEOF
2543 if ac_fn_c_try_cpp "$LINENO"; then :
2544 ac_header_preproc=yes
2545 else
2546 ac_header_preproc=no
2547 fi
2548 rm -f conftest.err conftest.$ac_ext
2549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2550 $as_echo "$ac_header_preproc" >&6; }
2551
2552 # So? What about this header?
2553 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2554 yes:no: )
2555 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2556 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2557 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2558 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2559 ;;
2560 no:yes:* )
2561 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2562 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2563 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2564 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2565 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2566 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2567 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2568 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2569 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2570 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2571 ;;
2572 esac
2573 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2574 $as_echo_n "checking for $2... " >&6; }
2575 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2576 $as_echo_n "(cached) " >&6
2577 else
2578 eval "$3=\$ac_header_compiler"
2579 fi
2580 eval ac_res=\$$3
2581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2582 $as_echo "$ac_res" >&6; }
2583 fi
2584 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2585
2586 } # ac_fn_c_check_header_mongrel
2587
2588 # ac_fn_c_try_run LINENO
2589 # ----------------------
2590 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2591 # that executables *can* be run.
2592 ac_fn_c_try_run ()
2593 {
2594 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2595 if { { ac_try="$ac_link"
2596 case "(($ac_try" in
2597 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2598 *) ac_try_echo=$ac_try;;
2599 esac
2600 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2601 $as_echo "$ac_try_echo"; } >&5
2602 (eval "$ac_link") 2>&5
2603 ac_status=$?
2604 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2605 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2606 { { case "(($ac_try" in
2607 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2608 *) ac_try_echo=$ac_try;;
2609 esac
2610 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2611 $as_echo "$ac_try_echo"; } >&5
2612 (eval "$ac_try") 2>&5
2613 ac_status=$?
2614 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2615 test $ac_status = 0; }; }; then :
2616 ac_retval=0
2617 else
2618 $as_echo "$as_me: program exited with status $ac_status" >&5
2619 $as_echo "$as_me: failed program was:" >&5
2620 sed 's/^/| /' conftest.$ac_ext >&5
2621
2622 ac_retval=$ac_status
2623 fi
2624 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2625 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2626 return $ac_retval
2627
2628 } # ac_fn_c_try_run
2629
2630 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2631 # -------------------------------------------------------
2632 # Tests whether HEADER exists and can be compiled using the include files in
2633 # INCLUDES, setting the cache variable VAR accordingly.
2634 ac_fn_c_check_header_compile ()
2635 {
2636 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2638 $as_echo_n "checking for $2... " >&6; }
2639 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2640 $as_echo_n "(cached) " >&6
2641 else
2642 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2643 /* end confdefs.h. */
2644 $4
2645 #include <$2>
2646 _ACEOF
2647 if ac_fn_c_try_compile "$LINENO"; then :
2648 eval "$3=yes"
2649 else
2650 eval "$3=no"
2651 fi
2652 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2653 fi
2654 eval ac_res=\$$3
2655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2656 $as_echo "$ac_res" >&6; }
2657 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2658
2659 } # ac_fn_c_check_header_compile
2660
2661 # ac_fn_c_try_link LINENO
2662 # -----------------------
2663 # Try to link conftest.$ac_ext, and return whether this succeeded.
2664 ac_fn_c_try_link ()
2665 {
2666 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2667 rm -f conftest.$ac_objext conftest$ac_exeext
2668 if { { ac_try="$ac_link"
2669 case "(($ac_try" in
2670 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2671 *) ac_try_echo=$ac_try;;
2672 esac
2673 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2674 $as_echo "$ac_try_echo"; } >&5
2675 (eval "$ac_link") 2>conftest.err
2676 ac_status=$?
2677 if test -s conftest.err; then
2678 grep -v '^ *+' conftest.err >conftest.er1
2679 cat conftest.er1 >&5
2680 mv -f conftest.er1 conftest.err
2681 fi
2682 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2683 test $ac_status = 0; } && {
2684 test -z "$ac_c_werror_flag" ||
2685 test ! -s conftest.err
2686 } && test -s conftest$ac_exeext && {
2687 test "$cross_compiling" = yes ||
2688 $as_test_x conftest$ac_exeext
2689 }; then :
2690 ac_retval=0
2691 else
2692 $as_echo "$as_me: failed program was:" >&5
2693 sed 's/^/| /' conftest.$ac_ext >&5
2694
2695 ac_retval=1
2696 fi
2697 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2698 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2699 # interfere with the next link command; also delete a directory that is
2700 # left behind by Apple's compiler. We do this before executing the actions.
2701 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2702 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2703 return $ac_retval
2704
2705 } # ac_fn_c_try_link
2706
2707 # ac_fn_c_check_func LINENO FUNC VAR
2708 # ----------------------------------
2709 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2710 ac_fn_c_check_func ()
2711 {
2712 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2714 $as_echo_n "checking for $2... " >&6; }
2715 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2716 $as_echo_n "(cached) " >&6
2717 else
2718 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2719 /* end confdefs.h. */
2720 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2721 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2722 #define $2 innocuous_$2
2723
2724 /* System header to define __stub macros and hopefully few prototypes,
2725 which can conflict with char $2 (); below.
2726 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2727 <limits.h> exists even on freestanding compilers. */
2728
2729 #ifdef __STDC__
2730 # include <limits.h>
2731 #else
2732 # include <assert.h>
2733 #endif
2734
2735 #undef $2
2736
2737 /* Override any GCC internal prototype to avoid an error.
2738 Use char because int might match the return type of a GCC
2739 builtin and then its argument prototype would still apply. */
2740 #ifdef __cplusplus
2741 extern "C"
2742 #endif
2743 char $2 ();
2744 /* The GNU C library defines this for functions which it implements
2745 to always fail with ENOSYS. Some functions are actually named
2746 something starting with __ and the normal name is an alias. */
2747 #if defined __stub_$2 || defined __stub___$2
2748 choke me
2749 #endif
2750
2751 int
2752 main ()
2753 {
2754 return $2 ();
2755 ;
2756 return 0;
2757 }
2758 _ACEOF
2759 if ac_fn_c_try_link "$LINENO"; then :
2760 eval "$3=yes"
2761 else
2762 eval "$3=no"
2763 fi
2764 rm -f core conftest.err conftest.$ac_objext \
2765 conftest$ac_exeext conftest.$ac_ext
2766 fi
2767 eval ac_res=\$$3
2768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2769 $as_echo "$ac_res" >&6; }
2770 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2771
2772 } # ac_fn_c_check_func
2773
2774 # ac_fn_c_check_decl LINENO SYMBOL VAR
2775 # ------------------------------------
2776 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2777 ac_fn_c_check_decl ()
2778 {
2779 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
2781 $as_echo_n "checking whether $2 is declared... " >&6; }
2782 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2783 $as_echo_n "(cached) " >&6
2784 else
2785 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2786 /* end confdefs.h. */
2787 $4
2788 int
2789 main ()
2790 {
2791 #ifndef $2
2792 (void) $2;
2793 #endif
2794
2795 ;
2796 return 0;
2797 }
2798 _ACEOF
2799 if ac_fn_c_try_compile "$LINENO"; then :
2800 eval "$3=yes"
2801 else
2802 eval "$3=no"
2803 fi
2804 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2805 fi
2806 eval ac_res=\$$3
2807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2808 $as_echo "$ac_res" >&6; }
2809 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2810
2811 } # ac_fn_c_check_decl
2812
2813 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2814 # --------------------------------------------
2815 # Tries to find the compile-time value of EXPR in a program that includes
2816 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2817 # computed
2818 ac_fn_c_compute_int ()
2819 {
2820 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2821 if test "$cross_compiling" = yes; then
2822 # Depending upon the size, compute the lo and hi bounds.
2823 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2824 /* end confdefs.h. */
2825 $4
2826 int
2827 main ()
2828 {
2829 static int test_array [1 - 2 * !(($2) >= 0)];
2830 test_array [0] = 0
2831
2832 ;
2833 return 0;
2834 }
2835 _ACEOF
2836 if ac_fn_c_try_compile "$LINENO"; then :
2837 ac_lo=0 ac_mid=0
2838 while :; do
2839 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2840 /* end confdefs.h. */
2841 $4
2842 int
2843 main ()
2844 {
2845 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2846 test_array [0] = 0
2847
2848 ;
2849 return 0;
2850 }
2851 _ACEOF
2852 if ac_fn_c_try_compile "$LINENO"; then :
2853 ac_hi=$ac_mid; break
2854 else
2855 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2856 if test $ac_lo -le $ac_mid; then
2857 ac_lo= ac_hi=
2858 break
2859 fi
2860 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2861 fi
2862 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2863 done
2864 else
2865 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2866 /* end confdefs.h. */
2867 $4
2868 int
2869 main ()
2870 {
2871 static int test_array [1 - 2 * !(($2) < 0)];
2872 test_array [0] = 0
2873
2874 ;
2875 return 0;
2876 }
2877 _ACEOF
2878 if ac_fn_c_try_compile "$LINENO"; then :
2879 ac_hi=-1 ac_mid=-1
2880 while :; do
2881 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2882 /* end confdefs.h. */
2883 $4
2884 int
2885 main ()
2886 {
2887 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2888 test_array [0] = 0
2889
2890 ;
2891 return 0;
2892 }
2893 _ACEOF
2894 if ac_fn_c_try_compile "$LINENO"; then :
2895 ac_lo=$ac_mid; break
2896 else
2897 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2898 if test $ac_mid -le $ac_hi; then
2899 ac_lo= ac_hi=
2900 break
2901 fi
2902 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2903 fi
2904 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2905 done
2906 else
2907 ac_lo= ac_hi=
2908 fi
2909 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2910 fi
2911 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2912 # Binary search between lo and hi bounds.
2913 while test "x$ac_lo" != "x$ac_hi"; do
2914 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2915 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2916 /* end confdefs.h. */
2917 $4
2918 int
2919 main ()
2920 {
2921 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2922 test_array [0] = 0
2923
2924 ;
2925 return 0;
2926 }
2927 _ACEOF
2928 if ac_fn_c_try_compile "$LINENO"; then :
2929 ac_hi=$ac_mid
2930 else
2931 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2932 fi
2933 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2934 done
2935 case $ac_lo in #((
2936 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2937 '') ac_retval=1 ;;
2938 esac
2939 else
2940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2941 /* end confdefs.h. */
2942 $4
2943 static long int longval () { return $2; }
2944 static unsigned long int ulongval () { return $2; }
2945 #include <stdio.h>
2946 #include <stdlib.h>
2947 int
2948 main ()
2949 {
2950
2951 FILE *f = fopen ("conftest.val", "w");
2952 if (! f)
2953 return 1;
2954 if (($2) < 0)
2955 {
2956 long int i = longval ();
2957 if (i != ($2))
2958 return 1;
2959 fprintf (f, "%ld", i);
2960 }
2961 else
2962 {
2963 unsigned long int i = ulongval ();
2964 if (i != ($2))
2965 return 1;
2966 fprintf (f, "%lu", i);
2967 }
2968 /* Do not output a trailing newline, as this causes \r\n confusion
2969 on some platforms. */
2970 return ferror (f) || fclose (f) != 0;
2971
2972 ;
2973 return 0;
2974 }
2975 _ACEOF
2976 if ac_fn_c_try_run "$LINENO"; then :
2977 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2978 else
2979 ac_retval=1
2980 fi
2981 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2982 conftest.$ac_objext conftest.beam conftest.$ac_ext
2983 rm -f conftest.val
2984
2985 fi
2986 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2987 return $ac_retval
2988
2989 } # ac_fn_c_compute_int
2990
2991 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2992 # -------------------------------------------
2993 # Tests whether TYPE exists after having included INCLUDES, setting cache
2994 # variable VAR accordingly.
2995 ac_fn_c_check_type ()
2996 {
2997 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2999 $as_echo_n "checking for $2... " >&6; }
3000 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
3001 $as_echo_n "(cached) " >&6
3002 else
3003 eval "$3=no"
3004 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3005 /* end confdefs.h. */
3006 $4
3007 int
3008 main ()
3009 {
3010 if (sizeof ($2))
3011 return 0;
3012 ;
3013 return 0;
3014 }
3015 _ACEOF
3016 if ac_fn_c_try_compile "$LINENO"; then :
3017 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3018 /* end confdefs.h. */
3019 $4
3020 int
3021 main ()
3022 {
3023 if (sizeof (($2)))
3024 return 0;
3025 ;
3026 return 0;
3027 }
3028 _ACEOF
3029 if ac_fn_c_try_compile "$LINENO"; then :
3030
3031 else
3032 eval "$3=yes"
3033 fi
3034 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3035 fi
3036 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3037 fi
3038 eval ac_res=\$$3
3039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
3040 $as_echo "$ac_res" >&6; }
3041 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
3042
3043 } # ac_fn_c_check_type
3044 cat >config.log <<_ACEOF
3045 This file contains any messages produced by compilers while
3046 running configure, to aid debugging if configure makes a mistake.
3047
3048 It was created by $as_me, which was
3049 generated by GNU Autoconf 2.64. Invocation command line was
3050
3051 $ $0 $@
3052
3053 _ACEOF
3054 exec 5>>config.log
3055 {
3056 cat <<_ASUNAME
3057 ## --------- ##
3058 ## Platform. ##
3059 ## --------- ##
3060
3061 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
3062 uname -m = `(uname -m) 2>/dev/null || echo unknown`
3063 uname -r = `(uname -r) 2>/dev/null || echo unknown`
3064 uname -s = `(uname -s) 2>/dev/null || echo unknown`
3065 uname -v = `(uname -v) 2>/dev/null || echo unknown`
3066
3067 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
3068 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
3069
3070 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
3071 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
3072 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
3073 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
3074 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
3075 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
3076 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
3077
3078 _ASUNAME
3079
3080 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3081 for as_dir in $PATH
3082 do
3083 IFS=$as_save_IFS
3084 test -z "$as_dir" && as_dir=.
3085 $as_echo "PATH: $as_dir"
3086 done
3087 IFS=$as_save_IFS
3088
3089 } >&5
3090
3091 cat >&5 <<_ACEOF
3092
3093
3094 ## ----------- ##
3095 ## Core tests. ##
3096 ## ----------- ##
3097
3098 _ACEOF
3099
3100
3101 # Keep a trace of the command line.
3102 # Strip out --no-create and --no-recursion so they do not pile up.
3103 # Strip out --silent because we don't want to record it for future runs.
3104 # Also quote any args containing shell meta-characters.
3105 # Make two passes to allow for proper duplicate-argument suppression.
3106 ac_configure_args=
3107 ac_configure_args0=
3108 ac_configure_args1=
3109 ac_must_keep_next=false
3110 for ac_pass in 1 2
3111 do
3112 for ac_arg
3113 do
3114 case $ac_arg in
3115 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
3116 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
3117 | -silent | --silent | --silen | --sile | --sil)
3118 continue ;;
3119 *\'*)
3120 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
3121 esac
3122 case $ac_pass in
3123 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
3124 2)
3125 as_fn_append ac_configure_args1 " '$ac_arg'"
3126 if test $ac_must_keep_next = true; then
3127 ac_must_keep_next=false # Got value, back to normal.
3128 else
3129 case $ac_arg in
3130 *=* | --config-cache | -C | -disable-* | --disable-* \
3131 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
3132 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
3133 | -with-* | --with-* | -without-* | --without-* | --x)
3134 case "$ac_configure_args0 " in
3135 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
3136 esac
3137 ;;
3138 -* ) ac_must_keep_next=true ;;
3139 esac
3140 fi
3141 as_fn_append ac_configure_args " '$ac_arg'"
3142 ;;
3143 esac
3144 done
3145 done
3146 { ac_configure_args0=; unset ac_configure_args0;}
3147 { ac_configure_args1=; unset ac_configure_args1;}
3148
3149 # When interrupted or exit'd, cleanup temporary files, and complete
3150 # config.log. We remove comments because anyway the quotes in there
3151 # would cause problems or look ugly.
3152 # WARNING: Use '\'' to represent an apostrophe within the trap.
3153 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3154 trap 'exit_status=$?
3155 # Save into config.log some information that might help in debugging.
3156 {
3157 echo
3158
3159 cat <<\_ASBOX
3160 ## ---------------- ##
3161 ## Cache variables. ##
3162 ## ---------------- ##
3163 _ASBOX
3164 echo
3165 # The following way of writing the cache mishandles newlines in values,
3166 (
3167 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3168 eval ac_val=\$$ac_var
3169 case $ac_val in #(
3170 *${as_nl}*)
3171 case $ac_var in #(
3172 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3173 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3174 esac
3175 case $ac_var in #(
3176 _ | IFS | as_nl) ;; #(
3177 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3178 *) { eval $ac_var=; unset $ac_var;} ;;
3179 esac ;;
3180 esac
3181 done
3182 (set) 2>&1 |
3183 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3184 *${as_nl}ac_space=\ *)
3185 sed -n \
3186 "s/'\''/'\''\\\\'\'''\''/g;
3187 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3188 ;; #(
3189 *)
3190 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3191 ;;
3192 esac |
3193 sort
3194 )
3195 echo
3196
3197 cat <<\_ASBOX
3198 ## ----------------- ##
3199 ## Output variables. ##
3200 ## ----------------- ##
3201 _ASBOX
3202 echo
3203 for ac_var in $ac_subst_vars
3204 do
3205 eval ac_val=\$$ac_var
3206 case $ac_val in
3207 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3208 esac
3209 $as_echo "$ac_var='\''$ac_val'\''"
3210 done | sort
3211 echo
3212
3213 if test -n "$ac_subst_files"; then
3214 cat <<\_ASBOX
3215 ## ------------------- ##
3216 ## File substitutions. ##
3217 ## ------------------- ##
3218 _ASBOX
3219 echo
3220 for ac_var in $ac_subst_files
3221 do
3222 eval ac_val=\$$ac_var
3223 case $ac_val in
3224 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3225 esac
3226 $as_echo "$ac_var='\''$ac_val'\''"
3227 done | sort
3228 echo
3229 fi
3230
3231 if test -s confdefs.h; then
3232 cat <<\_ASBOX
3233 ## ----------- ##
3234 ## confdefs.h. ##
3235 ## ----------- ##
3236 _ASBOX
3237 echo
3238 cat confdefs.h
3239 echo
3240 fi
3241 test "$ac_signal" != 0 &&
3242 $as_echo "$as_me: caught signal $ac_signal"
3243 $as_echo "$as_me: exit $exit_status"
3244 } >&5
3245 rm -f core *.core core.conftest.* &&
3246 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3247 exit $exit_status
3248 ' 0
3249 for ac_signal in 1 2 13 15; do
3250 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3251 done
3252 ac_signal=0
3253
3254 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3255 rm -f -r conftest* confdefs.h
3256
3257 $as_echo "/* confdefs.h */" > confdefs.h
3258
3259 # Predefined preprocessor variables.
3260
3261 cat >>confdefs.h <<_ACEOF
3262 #define PACKAGE_NAME "$PACKAGE_NAME"
3263 _ACEOF
3264
3265 cat >>confdefs.h <<_ACEOF
3266 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3267 _ACEOF
3268
3269 cat >>confdefs.h <<_ACEOF
3270 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3271 _ACEOF
3272
3273 cat >>confdefs.h <<_ACEOF
3274 #define PACKAGE_STRING "$PACKAGE_STRING"
3275 _ACEOF
3276
3277 cat >>confdefs.h <<_ACEOF
3278 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3279 _ACEOF
3280
3281 cat >>confdefs.h <<_ACEOF
3282 #define PACKAGE_URL "$PACKAGE_URL"
3283 _ACEOF
3284
3285
3286 # Let the site file select an alternate cache file if it wants to.
3287 # Prefer an explicitly selected file to automatically selected ones.
3288 ac_site_file1=NONE
3289 ac_site_file2=NONE
3290 if test -n "$CONFIG_SITE"; then
3291 ac_site_file1=$CONFIG_SITE
3292 elif test "x$prefix" != xNONE; then
3293 ac_site_file1=$prefix/share/config.site
3294 ac_site_file2=$prefix/etc/config.site
3295 else
3296 ac_site_file1=$ac_default_prefix/share/config.site
3297 ac_site_file2=$ac_default_prefix/etc/config.site
3298 fi
3299 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3300 do
3301 test "x$ac_site_file" = xNONE && continue
3302 if test -r "$ac_site_file"; then
3303 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3304 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3305 sed 's/^/| /' "$ac_site_file" >&5
3306 . "$ac_site_file"
3307 fi
3308 done
3309
3310 if test -r "$cache_file"; then
3311 # Some versions of bash will fail to source /dev/null (special
3312 # files actually), so we avoid doing that.
3313 if test -f "$cache_file"; then
3314 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3315 $as_echo "$as_me: loading cache $cache_file" >&6;}
3316 case $cache_file in
3317 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3318 *) . "./$cache_file";;
3319 esac
3320 fi
3321 else
3322 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3323 $as_echo "$as_me: creating cache $cache_file" >&6;}
3324 >$cache_file
3325 fi
3326
3327 as_fn_append ac_func_list " canonicalize_file_name"
3328 as_fn_append ac_func_list " getcwd"
3329 as_fn_append ac_func_list " readlink"
3330 as_fn_append ac_func_list " realpath"
3331 as_fn_append ac_header_list " sys/param.h"
3332 as_fn_append ac_header_list " unistd.h"
3333 as_fn_append ac_func_list " _set_invalid_parameter_handler"
3334 as_fn_append ac_header_list " sys/socket.h"
3335 as_fn_append ac_func_list " fchdir"
3336 as_fn_append ac_header_list " dirent.h"
3337 as_fn_append ac_func_list " fcntl"
3338 as_fn_append ac_func_list " symlink"
3339 as_fn_append ac_func_list " fdopendir"
3340 as_fn_append ac_func_list " mempcpy"
3341 as_fn_append ac_func_list " btowc"
3342 as_fn_append ac_func_list " isblank"
3343 as_fn_append ac_func_list " iswctype"
3344 as_fn_append ac_func_list " mbsrtowcs"
3345 as_fn_append ac_func_list " wmemchr"
3346 as_fn_append ac_func_list " wmemcpy"
3347 as_fn_append ac_func_list " wmempcpy"
3348 as_fn_append ac_header_list " wctype.h"
3349 gl_fnmatch_required=GNU
3350 as_fn_append ac_header_list " sys/stat.h"
3351 as_fn_append ac_func_list " fstatat"
3352 as_fn_append ac_func_list " getdtablesize"
3353 as_fn_append ac_func_list " getlogin_r"
3354 as_fn_append ac_func_list " getprogname"
3355 as_fn_append ac_func_list " getexecname"
3356 as_fn_append ac_header_list " sys/time.h"
3357 as_fn_append ac_func_list " gettimeofday"
3358 as_fn_append ac_header_list " sys/cdefs.h"
3359 as_fn_append ac_func_list " getpwnam_r"
3360 as_fn_append ac_header_list " limits.h"
3361 as_fn_append ac_header_list " wchar.h"
3362 as_fn_append ac_header_list " stdint.h"
3363 as_fn_append ac_header_list " inttypes.h"
3364 as_fn_append ac_func_list " lstat"
3365 as_fn_append ac_header_list " math.h"
3366 as_fn_append ac_func_list " mbsinit"
3367 as_fn_append ac_func_list " mbrtowc"
3368 as_fn_append ac_header_list " sys/mman.h"
3369 as_fn_append ac_func_list " mprotect"
3370 as_fn_append ac_func_list " mkstemp"
3371 as_fn_append ac_func_list " openat"
3372 as_fn_append ac_func_list " link"
3373 as_fn_append ac_func_list " secure_getenv"
3374 as_fn_append ac_func_list " getuid"
3375 as_fn_append ac_func_list " geteuid"
3376 as_fn_append ac_func_list " getgid"
3377 as_fn_append ac_func_list " getegid"
3378 as_fn_append ac_func_list " setenv"
3379 as_fn_append ac_func_list " strdup"
3380 as_fn_append ac_func_list " pipe"
3381 as_fn_append ac_header_list " features.h"
3382 as_fn_append ac_func_list " iswcntrl"
3383 # Check that the precious variables saved in the cache have kept the same
3384 # value.
3385 ac_cache_corrupted=false
3386 for ac_var in $ac_precious_vars; do
3387 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3388 eval ac_new_set=\$ac_env_${ac_var}_set
3389 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3390 eval ac_new_val=\$ac_env_${ac_var}_value
3391 case $ac_old_set,$ac_new_set in
3392 set,)
3393 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3394 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3395 ac_cache_corrupted=: ;;
3396 ,set)
3397 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3398 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3399 ac_cache_corrupted=: ;;
3400 ,);;
3401 *)
3402 if test "x$ac_old_val" != "x$ac_new_val"; then
3403 # differences in whitespace do not lead to failure.
3404 ac_old_val_w=`echo x $ac_old_val`
3405 ac_new_val_w=`echo x $ac_new_val`
3406 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3407 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3408 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3409 ac_cache_corrupted=:
3410 else
3411 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3412 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3413 eval $ac_var=\$ac_old_val
3414 fi
3415 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3416 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3417 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3418 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3419 fi;;
3420 esac
3421 # Pass precious variables to config.status.
3422 if test "$ac_new_set" = set; then
3423 case $ac_new_val in
3424 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3425 *) ac_arg=$ac_var=$ac_new_val ;;
3426 esac
3427 case " $ac_configure_args " in
3428 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3429 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3430 esac
3431 fi
3432 done
3433 if $ac_cache_corrupted; then
3434 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3435 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3436 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3437 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3438 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3439 fi
3440 ## -------------------- ##
3441 ## Main body of script. ##
3442 ## -------------------- ##
3443
3444 ac_ext=c
3445 ac_cpp='$CPP $CPPFLAGS'
3446 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3447 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3448 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3449
3450
3451 ac_config_headers="$ac_config_headers config.h:config.in"
3452
3453
3454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
3455 $as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
3456 # Check whether --enable-maintainer-mode was given.
3457 if test "${enable_maintainer_mode+set}" = set; then :
3458 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
3459 else
3460 USE_MAINTAINER_MODE=no
3461 fi
3462
3463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
3464 $as_echo "$USE_MAINTAINER_MODE" >&6; }
3465 if test $USE_MAINTAINER_MODE = yes; then
3466 MAINTAINER_MODE_TRUE=
3467 MAINTAINER_MODE_FALSE='#'
3468 else
3469 MAINTAINER_MODE_TRUE='#'
3470 MAINTAINER_MODE_FALSE=
3471 fi
3472
3473 MAINT=$MAINTAINER_MODE_TRUE
3474
3475
3476
3477 ac_ext=c
3478 ac_cpp='$CPP $CPPFLAGS'
3479 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3480 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3481 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3482 if test -n "$ac_tool_prefix"; then
3483 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3484 set dummy ${ac_tool_prefix}gcc; ac_word=$2
3485 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3486 $as_echo_n "checking for $ac_word... " >&6; }
3487 if test "${ac_cv_prog_CC+set}" = set; then :
3488 $as_echo_n "(cached) " >&6
3489 else
3490 if test -n "$CC"; then
3491 ac_cv_prog_CC="$CC" # Let the user override the test.
3492 else
3493 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3494 for as_dir in $PATH
3495 do
3496 IFS=$as_save_IFS
3497 test -z "$as_dir" && as_dir=.
3498 for ac_exec_ext in '' $ac_executable_extensions; do
3499 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3500 ac_cv_prog_CC="${ac_tool_prefix}gcc"
3501 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3502 break 2
3503 fi
3504 done
3505 done
3506 IFS=$as_save_IFS
3507
3508 fi
3509 fi
3510 CC=$ac_cv_prog_CC
3511 if test -n "$CC"; then
3512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3513 $as_echo "$CC" >&6; }
3514 else
3515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3516 $as_echo "no" >&6; }
3517 fi
3518
3519
3520 fi
3521 if test -z "$ac_cv_prog_CC"; then
3522 ac_ct_CC=$CC
3523 # Extract the first word of "gcc", so it can be a program name with args.
3524 set dummy gcc; ac_word=$2
3525 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3526 $as_echo_n "checking for $ac_word... " >&6; }
3527 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
3528 $as_echo_n "(cached) " >&6
3529 else
3530 if test -n "$ac_ct_CC"; then
3531 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3532 else
3533 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3534 for as_dir in $PATH
3535 do
3536 IFS=$as_save_IFS
3537 test -z "$as_dir" && as_dir=.
3538 for ac_exec_ext in '' $ac_executable_extensions; do
3539 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3540 ac_cv_prog_ac_ct_CC="gcc"
3541 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3542 break 2
3543 fi
3544 done
3545 done
3546 IFS=$as_save_IFS
3547
3548 fi
3549 fi
3550 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3551 if test -n "$ac_ct_CC"; then
3552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3553 $as_echo "$ac_ct_CC" >&6; }
3554 else
3555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3556 $as_echo "no" >&6; }
3557 fi
3558
3559 if test "x$ac_ct_CC" = x; then
3560 CC=""
3561 else
3562 case $cross_compiling:$ac_tool_warned in
3563 yes:)
3564 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3565 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3566 ac_tool_warned=yes ;;
3567 esac
3568 CC=$ac_ct_CC
3569 fi
3570 else
3571 CC="$ac_cv_prog_CC"
3572 fi
3573
3574 if test -z "$CC"; then
3575 if test -n "$ac_tool_prefix"; then
3576 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3577 set dummy ${ac_tool_prefix}cc; ac_word=$2
3578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3579 $as_echo_n "checking for $ac_word... " >&6; }
3580 if test "${ac_cv_prog_CC+set}" = set; then :
3581 $as_echo_n "(cached) " >&6
3582 else
3583 if test -n "$CC"; then
3584 ac_cv_prog_CC="$CC" # Let the user override the test.
3585 else
3586 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3587 for as_dir in $PATH
3588 do
3589 IFS=$as_save_IFS
3590 test -z "$as_dir" && as_dir=.
3591 for ac_exec_ext in '' $ac_executable_extensions; do
3592 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3593 ac_cv_prog_CC="${ac_tool_prefix}cc"
3594 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3595 break 2
3596 fi
3597 done
3598 done
3599 IFS=$as_save_IFS
3600
3601 fi
3602 fi
3603 CC=$ac_cv_prog_CC
3604 if test -n "$CC"; then
3605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3606 $as_echo "$CC" >&6; }
3607 else
3608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3609 $as_echo "no" >&6; }
3610 fi
3611
3612
3613 fi
3614 fi
3615 if test -z "$CC"; then
3616 # Extract the first word of "cc", so it can be a program name with args.
3617 set dummy cc; ac_word=$2
3618 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3619 $as_echo_n "checking for $ac_word... " >&6; }
3620 if test "${ac_cv_prog_CC+set}" = set; then :
3621 $as_echo_n "(cached) " >&6
3622 else
3623 if test -n "$CC"; then
3624 ac_cv_prog_CC="$CC" # Let the user override the test.
3625 else
3626 ac_prog_rejected=no
3627 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3628 for as_dir in $PATH
3629 do
3630 IFS=$as_save_IFS
3631 test -z "$as_dir" && as_dir=.
3632 for ac_exec_ext in '' $ac_executable_extensions; do
3633 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3634 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3635 ac_prog_rejected=yes
3636 continue
3637 fi
3638 ac_cv_prog_CC="cc"
3639 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3640 break 2
3641 fi
3642 done
3643 done
3644 IFS=$as_save_IFS
3645
3646 if test $ac_prog_rejected = yes; then
3647 # We found a bogon in the path, so make sure we never use it.
3648 set dummy $ac_cv_prog_CC
3649 shift
3650 if test $# != 0; then
3651 # We chose a different compiler from the bogus one.
3652 # However, it has the same basename, so the bogon will be chosen
3653 # first if we set CC to just the basename; use the full file name.
3654 shift
3655 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3656 fi
3657 fi
3658 fi
3659 fi
3660 CC=$ac_cv_prog_CC
3661 if test -n "$CC"; then
3662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3663 $as_echo "$CC" >&6; }
3664 else
3665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3666 $as_echo "no" >&6; }
3667 fi
3668
3669
3670 fi
3671 if test -z "$CC"; then
3672 if test -n "$ac_tool_prefix"; then
3673 for ac_prog in cl.exe
3674 do
3675 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3676 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3678 $as_echo_n "checking for $ac_word... " >&6; }
3679 if test "${ac_cv_prog_CC+set}" = set; then :
3680 $as_echo_n "(cached) " >&6
3681 else
3682 if test -n "$CC"; then
3683 ac_cv_prog_CC="$CC" # Let the user override the test.
3684 else
3685 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3686 for as_dir in $PATH
3687 do
3688 IFS=$as_save_IFS
3689 test -z "$as_dir" && as_dir=.
3690 for ac_exec_ext in '' $ac_executable_extensions; do
3691 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3692 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3693 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3694 break 2
3695 fi
3696 done
3697 done
3698 IFS=$as_save_IFS
3699
3700 fi
3701 fi
3702 CC=$ac_cv_prog_CC
3703 if test -n "$CC"; then
3704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3705 $as_echo "$CC" >&6; }
3706 else
3707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3708 $as_echo "no" >&6; }
3709 fi
3710
3711
3712 test -n "$CC" && break
3713 done
3714 fi
3715 if test -z "$CC"; then
3716 ac_ct_CC=$CC
3717 for ac_prog in cl.exe
3718 do
3719 # Extract the first word of "$ac_prog", so it can be a program name with args.
3720 set dummy $ac_prog; ac_word=$2
3721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3722 $as_echo_n "checking for $ac_word... " >&6; }
3723 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
3724 $as_echo_n "(cached) " >&6
3725 else
3726 if test -n "$ac_ct_CC"; then
3727 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3728 else
3729 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3730 for as_dir in $PATH
3731 do
3732 IFS=$as_save_IFS
3733 test -z "$as_dir" && as_dir=.
3734 for ac_exec_ext in '' $ac_executable_extensions; do
3735 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3736 ac_cv_prog_ac_ct_CC="$ac_prog"
3737 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3738 break 2
3739 fi
3740 done
3741 done
3742 IFS=$as_save_IFS
3743
3744 fi
3745 fi
3746 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3747 if test -n "$ac_ct_CC"; then
3748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3749 $as_echo "$ac_ct_CC" >&6; }
3750 else
3751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3752 $as_echo "no" >&6; }
3753 fi
3754
3755
3756 test -n "$ac_ct_CC" && break
3757 done
3758
3759 if test "x$ac_ct_CC" = x; then
3760 CC=""
3761 else
3762 case $cross_compiling:$ac_tool_warned in
3763 yes:)
3764 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3765 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3766 ac_tool_warned=yes ;;
3767 esac
3768 CC=$ac_ct_CC
3769 fi
3770 fi
3771
3772 fi
3773
3774
3775 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3776 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3777 as_fn_error "no acceptable C compiler found in \$PATH
3778 See \`config.log' for more details." "$LINENO" 5; }
3779
3780 # Provide some information about the compiler.
3781 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3782 set X $ac_compile
3783 ac_compiler=$2
3784 for ac_option in --version -v -V -qversion; do
3785 { { ac_try="$ac_compiler $ac_option >&5"
3786 case "(($ac_try" in
3787 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3788 *) ac_try_echo=$ac_try;;
3789 esac
3790 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3791 $as_echo "$ac_try_echo"; } >&5
3792 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3793 ac_status=$?
3794 if test -s conftest.err; then
3795 sed '10a\
3796 ... rest of stderr output deleted ...
3797 10q' conftest.err >conftest.er1
3798 cat conftest.er1 >&5
3799 rm -f conftest.er1 conftest.err
3800 fi
3801 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3802 test $ac_status = 0; }
3803 done
3804
3805 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3806 /* end confdefs.h. */
3807 #include <stdio.h>
3808 int
3809 main ()
3810 {
3811 FILE *f = fopen ("conftest.out", "w");
3812 return ferror (f) || fclose (f) != 0;
3813
3814 ;
3815 return 0;
3816 }
3817 _ACEOF
3818 ac_clean_files_save=$ac_clean_files
3819 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out conftest.out"
3820 # Try to create an executable without -o first, disregard a.out.
3821 # It will help us diagnose broken compilers, and finding out an intuition
3822 # of exeext.
3823 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3824 $as_echo_n "checking for C compiler default output file name... " >&6; }
3825 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3826
3827 # The possible output files:
3828 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3829
3830 ac_rmfiles=
3831 for ac_file in $ac_files
3832 do
3833 case $ac_file in
3834 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3835 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3836 esac
3837 done
3838 rm -f $ac_rmfiles
3839
3840 if { { ac_try="$ac_link_default"
3841 case "(($ac_try" in
3842 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3843 *) ac_try_echo=$ac_try;;
3844 esac
3845 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3846 $as_echo "$ac_try_echo"; } >&5
3847 (eval "$ac_link_default") 2>&5
3848 ac_status=$?
3849 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3850 test $ac_status = 0; }; then :
3851 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3852 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3853 # in a Makefile. We should not override ac_cv_exeext if it was cached,
3854 # so that the user can short-circuit this test for compilers unknown to
3855 # Autoconf.
3856 for ac_file in $ac_files ''
3857 do
3858 test -f "$ac_file" || continue
3859 case $ac_file in
3860 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3861 ;;
3862 [ab].out )
3863 # We found the default executable, but exeext='' is most
3864 # certainly right.
3865 break;;
3866 *.* )
3867 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3868 then :; else
3869 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3870 fi
3871 # We set ac_cv_exeext here because the later test for it is not
3872 # safe: cross compilers may not add the suffix if given an `-o'
3873 # argument, so we may need to know it at that point already.
3874 # Even if this section looks crufty: it has the advantage of
3875 # actually working.
3876 break;;
3877 * )
3878 break;;
3879 esac
3880 done
3881 test "$ac_cv_exeext" = no && ac_cv_exeext=
3882
3883 else
3884 ac_file=''
3885 fi
3886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3887 $as_echo "$ac_file" >&6; }
3888 if test -z "$ac_file"; then :
3889 $as_echo "$as_me: failed program was:" >&5
3890 sed 's/^/| /' conftest.$ac_ext >&5
3891
3892 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3893 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3894 { as_fn_set_status 77
3895 as_fn_error "C compiler cannot create executables
3896 See \`config.log' for more details." "$LINENO" 5; }; }
3897 fi
3898 ac_exeext=$ac_cv_exeext
3899
3900 # Check that the compiler produces executables we can run. If not, either
3901 # the compiler is broken, or we cross compile.
3902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3903 $as_echo_n "checking whether the C compiler works... " >&6; }
3904 # If not cross compiling, check that we can run a simple program.
3905 if test "$cross_compiling" != yes; then
3906 if { ac_try='./$ac_file'
3907 { { case "(($ac_try" in
3908 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3909 *) ac_try_echo=$ac_try;;
3910 esac
3911 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3912 $as_echo "$ac_try_echo"; } >&5
3913 (eval "$ac_try") 2>&5
3914 ac_status=$?
3915 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3916 test $ac_status = 0; }; }; then
3917 cross_compiling=no
3918 else
3919 if test "$cross_compiling" = maybe; then
3920 cross_compiling=yes
3921 else
3922 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3923 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3924 as_fn_error "cannot run C compiled programs.
3925 If you meant to cross compile, use \`--host'.
3926 See \`config.log' for more details." "$LINENO" 5; }
3927 fi
3928 fi
3929 fi
3930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3931 $as_echo "yes" >&6; }
3932
3933 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out conftest.out
3934 ac_clean_files=$ac_clean_files_save
3935 # Check that the compiler produces executables we can run. If not, either
3936 # the compiler is broken, or we cross compile.
3937 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3938 $as_echo_n "checking whether we are cross compiling... " >&6; }
3939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3940 $as_echo "$cross_compiling" >&6; }
3941
3942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3943 $as_echo_n "checking for suffix of executables... " >&6; }
3944 if { { ac_try="$ac_link"
3945 case "(($ac_try" in
3946 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3947 *) ac_try_echo=$ac_try;;
3948 esac
3949 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3950 $as_echo "$ac_try_echo"; } >&5
3951 (eval "$ac_link") 2>&5
3952 ac_status=$?
3953 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3954 test $ac_status = 0; }; then :
3955 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3956 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3957 # work properly (i.e., refer to `conftest.exe'), while it won't with
3958 # `rm'.
3959 for ac_file in conftest.exe conftest conftest.*; do
3960 test -f "$ac_file" || continue
3961 case $ac_file in
3962 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3963 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3964 break;;
3965 * ) break;;
3966 esac
3967 done
3968 else
3969 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3970 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3971 as_fn_error "cannot compute suffix of executables: cannot compile and link
3972 See \`config.log' for more details." "$LINENO" 5; }
3973 fi
3974 rm -f conftest$ac_cv_exeext
3975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3976 $as_echo "$ac_cv_exeext" >&6; }
3977
3978 rm -f conftest.$ac_ext
3979 EXEEXT=$ac_cv_exeext
3980 ac_exeext=$EXEEXT
3981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3982 $as_echo_n "checking for suffix of object files... " >&6; }
3983 if test "${ac_cv_objext+set}" = set; then :
3984 $as_echo_n "(cached) " >&6
3985 else
3986 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3987 /* end confdefs.h. */
3988
3989 int
3990 main ()
3991 {
3992
3993 ;
3994 return 0;
3995 }
3996 _ACEOF
3997 rm -f conftest.o conftest.obj
3998 if { { ac_try="$ac_compile"
3999 case "(($ac_try" in
4000 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4001 *) ac_try_echo=$ac_try;;
4002 esac
4003 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4004 $as_echo "$ac_try_echo"; } >&5
4005 (eval "$ac_compile") 2>&5
4006 ac_status=$?
4007 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4008 test $ac_status = 0; }; then :
4009 for ac_file in conftest.o conftest.obj conftest.*; do
4010 test -f "$ac_file" || continue;
4011 case $ac_file in
4012 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
4013 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4014 break;;
4015 esac
4016 done
4017 else
4018 $as_echo "$as_me: failed program was:" >&5
4019 sed 's/^/| /' conftest.$ac_ext >&5
4020
4021 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4022 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4023 as_fn_error "cannot compute suffix of object files: cannot compile
4024 See \`config.log' for more details." "$LINENO" 5; }
4025 fi
4026 rm -f conftest.$ac_cv_objext conftest.$ac_ext
4027 fi
4028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4029 $as_echo "$ac_cv_objext" >&6; }
4030 OBJEXT=$ac_cv_objext
4031 ac_objext=$OBJEXT
4032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4033 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4034 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
4035 $as_echo_n "(cached) " >&6
4036 else
4037 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4038 /* end confdefs.h. */
4039
4040 int
4041 main ()
4042 {
4043 #ifndef __GNUC__
4044 choke me
4045 #endif
4046
4047 ;
4048 return 0;
4049 }
4050 _ACEOF
4051 if ac_fn_c_try_compile "$LINENO"; then :
4052 ac_compiler_gnu=yes
4053 else
4054 ac_compiler_gnu=no
4055 fi
4056 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4057 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4058
4059 fi
4060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4061 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
4062 if test $ac_compiler_gnu = yes; then
4063 GCC=yes
4064 else
4065 GCC=
4066 fi
4067 ac_test_CFLAGS=${CFLAGS+set}
4068 ac_save_CFLAGS=$CFLAGS
4069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4070 $as_echo_n "checking whether $CC accepts -g... " >&6; }
4071 if test "${ac_cv_prog_cc_g+set}" = set; then :
4072 $as_echo_n "(cached) " >&6
4073 else
4074 ac_save_c_werror_flag=$ac_c_werror_flag
4075 ac_c_werror_flag=yes
4076 ac_cv_prog_cc_g=no
4077 CFLAGS="-g"
4078 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4079 /* end confdefs.h. */
4080
4081 int
4082 main ()
4083 {
4084
4085 ;
4086 return 0;
4087 }
4088 _ACEOF
4089 if ac_fn_c_try_compile "$LINENO"; then :
4090 ac_cv_prog_cc_g=yes
4091 else
4092 CFLAGS=""
4093 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4094 /* end confdefs.h. */
4095
4096 int
4097 main ()
4098 {
4099
4100 ;
4101 return 0;
4102 }
4103 _ACEOF
4104 if ac_fn_c_try_compile "$LINENO"; then :
4105
4106 else
4107 ac_c_werror_flag=$ac_save_c_werror_flag
4108 CFLAGS="-g"
4109 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4110 /* end confdefs.h. */
4111
4112 int
4113 main ()
4114 {
4115
4116 ;
4117 return 0;
4118 }
4119 _ACEOF
4120 if ac_fn_c_try_compile "$LINENO"; then :
4121 ac_cv_prog_cc_g=yes
4122 fi
4123 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4124 fi
4125 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4126 fi
4127 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4128 ac_c_werror_flag=$ac_save_c_werror_flag
4129 fi
4130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4131 $as_echo "$ac_cv_prog_cc_g" >&6; }
4132 if test "$ac_test_CFLAGS" = set; then
4133 CFLAGS=$ac_save_CFLAGS
4134 elif test $ac_cv_prog_cc_g = yes; then
4135 if test "$GCC" = yes; then
4136 CFLAGS="-g -O2"
4137 else
4138 CFLAGS="-g"
4139 fi
4140 else
4141 if test "$GCC" = yes; then
4142 CFLAGS="-O2"
4143 else
4144 CFLAGS=
4145 fi
4146 fi
4147 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4148 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4149 if test "${ac_cv_prog_cc_c89+set}" = set; then :
4150 $as_echo_n "(cached) " >&6
4151 else
4152 ac_cv_prog_cc_c89=no
4153 ac_save_CC=$CC
4154 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4155 /* end confdefs.h. */
4156 #include <stdarg.h>
4157 #include <stdio.h>
4158 #include <sys/types.h>
4159 #include <sys/stat.h>
4160 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4161 struct buf { int x; };
4162 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4163 static char *e (p, i)
4164 char **p;
4165 int i;
4166 {
4167 return p[i];
4168 }
4169 static char *f (char * (*g) (char **, int), char **p, ...)
4170 {
4171 char *s;
4172 va_list v;
4173 va_start (v,p);
4174 s = g (p, va_arg (v,int));
4175 va_end (v);
4176 return s;
4177 }
4178
4179 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
4180 function prototypes and stuff, but not '\xHH' hex character constants.
4181 These don't provoke an error unfortunately, instead are silently treated
4182 as 'x'. The following induces an error, until -std is added to get
4183 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
4184 array size at least. It's necessary to write '\x00'==0 to get something
4185 that's true only with -std. */
4186 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4187
4188 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4189 inside strings and character constants. */
4190 #define FOO(x) 'x'
4191 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4192
4193 int test (int i, double x);
4194 struct s1 {int (*f) (int a);};
4195 struct s2 {int (*f) (double a);};
4196 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4197 int argc;
4198 char **argv;
4199 int
4200 main ()
4201 {
4202 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4203 ;
4204 return 0;
4205 }
4206 _ACEOF
4207 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4208 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4209 do
4210 CC="$ac_save_CC $ac_arg"
4211 if ac_fn_c_try_compile "$LINENO"; then :
4212 ac_cv_prog_cc_c89=$ac_arg
4213 fi
4214 rm -f core conftest.err conftest.$ac_objext
4215 test "x$ac_cv_prog_cc_c89" != "xno" && break
4216 done
4217 rm -f conftest.$ac_ext
4218 CC=$ac_save_CC
4219
4220 fi
4221 # AC_CACHE_VAL
4222 case "x$ac_cv_prog_cc_c89" in
4223 x)
4224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4225 $as_echo "none needed" >&6; } ;;
4226 xno)
4227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4228 $as_echo "unsupported" >&6; } ;;
4229 *)
4230 CC="$CC $ac_cv_prog_cc_c89"
4231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4232 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
4233 esac
4234 if test "x$ac_cv_prog_cc_c89" != xno; then :
4235
4236 fi
4237
4238 ac_ext=c
4239 ac_cpp='$CPP $CPPFLAGS'
4240 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4241 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4242 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4243
4244
4245 ac_ext=c
4246 ac_cpp='$CPP $CPPFLAGS'
4247 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4248 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4249 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4250 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
4251 $as_echo_n "checking how to run the C preprocessor... " >&6; }
4252 # On Suns, sometimes $CPP names a directory.
4253 if test -n "$CPP" && test -d "$CPP"; then
4254 CPP=
4255 fi
4256 if test -z "$CPP"; then
4257 if test "${ac_cv_prog_CPP+set}" = set; then :
4258 $as_echo_n "(cached) " >&6
4259 else
4260 # Double quotes because CPP needs to be expanded
4261 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4262 do
4263 ac_preproc_ok=false
4264 for ac_c_preproc_warn_flag in '' yes
4265 do
4266 # Use a header file that comes with gcc, so configuring glibc
4267 # with a fresh cross-compiler works.
4268 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4269 # <limits.h> exists even on freestanding compilers.
4270 # On the NeXT, cc -E runs the code through the compiler's parser,
4271 # not just through cpp. "Syntax error" is here to catch this case.
4272 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4273 /* end confdefs.h. */
4274 #ifdef __STDC__
4275 # include <limits.h>
4276 #else
4277 # include <assert.h>
4278 #endif
4279 Syntax error
4280 _ACEOF
4281 if ac_fn_c_try_cpp "$LINENO"; then :
4282
4283 else
4284 # Broken: fails on valid input.
4285 continue
4286 fi
4287 rm -f conftest.err conftest.$ac_ext
4288
4289 # OK, works on sane cases. Now check whether nonexistent headers
4290 # can be detected and how.
4291 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4292 /* end confdefs.h. */
4293 #include <ac_nonexistent.h>
4294 _ACEOF
4295 if ac_fn_c_try_cpp "$LINENO"; then :
4296 # Broken: success on invalid input.
4297 continue
4298 else
4299 # Passes both tests.
4300 ac_preproc_ok=:
4301 break
4302 fi
4303 rm -f conftest.err conftest.$ac_ext
4304
4305 done
4306 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4307 rm -f conftest.err conftest.$ac_ext
4308 if $ac_preproc_ok; then :
4309 break
4310 fi
4311
4312 done
4313 ac_cv_prog_CPP=$CPP
4314
4315 fi
4316 CPP=$ac_cv_prog_CPP
4317 else
4318 ac_cv_prog_CPP=$CPP
4319 fi
4320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
4321 $as_echo "$CPP" >&6; }
4322 ac_preproc_ok=false
4323 for ac_c_preproc_warn_flag in '' yes
4324 do
4325 # Use a header file that comes with gcc, so configuring glibc
4326 # with a fresh cross-compiler works.
4327 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4328 # <limits.h> exists even on freestanding compilers.
4329 # On the NeXT, cc -E runs the code through the compiler's parser,
4330 # not just through cpp. "Syntax error" is here to catch this case.
4331 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4332 /* end confdefs.h. */
4333 #ifdef __STDC__
4334 # include <limits.h>
4335 #else
4336 # include <assert.h>
4337 #endif
4338 Syntax error
4339 _ACEOF
4340 if ac_fn_c_try_cpp "$LINENO"; then :
4341
4342 else
4343 # Broken: fails on valid input.
4344 continue
4345 fi
4346 rm -f conftest.err conftest.$ac_ext
4347
4348 # OK, works on sane cases. Now check whether nonexistent headers
4349 # can be detected and how.
4350 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4351 /* end confdefs.h. */
4352 #include <ac_nonexistent.h>
4353 _ACEOF
4354 if ac_fn_c_try_cpp "$LINENO"; then :
4355 # Broken: success on invalid input.
4356 continue
4357 else
4358 # Passes both tests.
4359 ac_preproc_ok=:
4360 break
4361 fi
4362 rm -f conftest.err conftest.$ac_ext
4363
4364 done
4365 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4366 rm -f conftest.err conftest.$ac_ext
4367 if $ac_preproc_ok; then :
4368
4369 else
4370 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4371 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4372 as_fn_error "C preprocessor \"$CPP\" fails sanity check
4373 See \`config.log' for more details." "$LINENO" 5; }
4374 fi
4375
4376 ac_ext=c
4377 ac_cpp='$CPP $CPPFLAGS'
4378 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4379 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4380 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4381
4382
4383 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
4384 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
4385 if test "${ac_cv_path_GREP+set}" = set; then :
4386 $as_echo_n "(cached) " >&6
4387 else
4388 if test -z "$GREP"; then
4389 ac_path_GREP_found=false
4390 # Loop through the user's path and test for each of PROGNAME-LIST
4391 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4392 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4393 do
4394 IFS=$as_save_IFS
4395 test -z "$as_dir" && as_dir=.
4396 for ac_prog in grep ggrep; do
4397 for ac_exec_ext in '' $ac_executable_extensions; do
4398 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
4399 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
4400 # Check for GNU ac_path_GREP and select it if it is found.
4401 # Check for GNU $ac_path_GREP
4402 case `"$ac_path_GREP" --version 2>&1` in
4403 *GNU*)
4404 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4405 *)
4406 ac_count=0
4407 $as_echo_n 0123456789 >"conftest.in"
4408 while :
4409 do
4410 cat "conftest.in" "conftest.in" >"conftest.tmp"
4411 mv "conftest.tmp" "conftest.in"
4412 cp "conftest.in" "conftest.nl"
4413 $as_echo 'GREP' >> "conftest.nl"
4414 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4415 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4416 as_fn_arith $ac_count + 1 && ac_count=$as_val
4417 if test $ac_count -gt ${ac_path_GREP_max-0}; then
4418 # Best one so far, save it but keep looking for a better one
4419 ac_cv_path_GREP="$ac_path_GREP"
4420 ac_path_GREP_max=$ac_count
4421 fi
4422 # 10*(2^10) chars as input seems more than enough
4423 test $ac_count -gt 10 && break
4424 done
4425 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4426 esac
4427
4428 $ac_path_GREP_found && break 3
4429 done
4430 done
4431 done
4432 IFS=$as_save_IFS
4433 if test -z "$ac_cv_path_GREP"; then
4434 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4435 fi
4436 else
4437 ac_cv_path_GREP=$GREP
4438 fi
4439
4440 fi
4441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4442 $as_echo "$ac_cv_path_GREP" >&6; }
4443 GREP="$ac_cv_path_GREP"
4444
4445
4446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4447 $as_echo_n "checking for egrep... " >&6; }
4448 if test "${ac_cv_path_EGREP+set}" = set; then :
4449 $as_echo_n "(cached) " >&6
4450 else
4451 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4452 then ac_cv_path_EGREP="$GREP -E"
4453 else
4454 if test -z "$EGREP"; then
4455 ac_path_EGREP_found=false
4456 # Loop through the user's path and test for each of PROGNAME-LIST
4457 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4458 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4459 do
4460 IFS=$as_save_IFS
4461 test -z "$as_dir" && as_dir=.
4462 for ac_prog in egrep; do
4463 for ac_exec_ext in '' $ac_executable_extensions; do
4464 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4465 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
4466 # Check for GNU ac_path_EGREP and select it if it is found.
4467 # Check for GNU $ac_path_EGREP
4468 case `"$ac_path_EGREP" --version 2>&1` in
4469 *GNU*)
4470 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4471 *)
4472 ac_count=0
4473 $as_echo_n 0123456789 >"conftest.in"
4474 while :
4475 do
4476 cat "conftest.in" "conftest.in" >"conftest.tmp"
4477 mv "conftest.tmp" "conftest.in"
4478 cp "conftest.in" "conftest.nl"
4479 $as_echo 'EGREP' >> "conftest.nl"
4480 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4481 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4482 as_fn_arith $ac_count + 1 && ac_count=$as_val
4483 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4484 # Best one so far, save it but keep looking for a better one
4485 ac_cv_path_EGREP="$ac_path_EGREP"
4486 ac_path_EGREP_max=$ac_count
4487 fi
4488 # 10*(2^10) chars as input seems more than enough
4489 test $ac_count -gt 10 && break
4490 done
4491 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4492 esac
4493
4494 $ac_path_EGREP_found && break 3
4495 done
4496 done
4497 done
4498 IFS=$as_save_IFS
4499 if test -z "$ac_cv_path_EGREP"; then
4500 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4501 fi
4502 else
4503 ac_cv_path_EGREP=$EGREP
4504 fi
4505
4506 fi
4507 fi
4508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4509 $as_echo "$ac_cv_path_EGREP" >&6; }
4510 EGREP="$ac_cv_path_EGREP"
4511
4512
4513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4514 $as_echo_n "checking for ANSI C header files... " >&6; }
4515 if test "${ac_cv_header_stdc+set}" = set; then :
4516 $as_echo_n "(cached) " >&6
4517 else
4518 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4519 /* end confdefs.h. */
4520 #include <stdlib.h>
4521 #include <stdarg.h>
4522 #include <string.h>
4523 #include <float.h>
4524
4525 int
4526 main ()
4527 {
4528
4529 ;
4530 return 0;
4531 }
4532 _ACEOF
4533 if ac_fn_c_try_compile "$LINENO"; then :
4534 ac_cv_header_stdc=yes
4535 else
4536 ac_cv_header_stdc=no
4537 fi
4538 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4539
4540 if test $ac_cv_header_stdc = yes; then
4541 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4542 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4543 /* end confdefs.h. */
4544 #include <string.h>
4545
4546 _ACEOF
4547 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4548 $EGREP "memchr" >/dev/null 2>&1; then :
4549
4550 else
4551 ac_cv_header_stdc=no
4552 fi
4553 rm -f conftest*
4554
4555 fi
4556
4557 if test $ac_cv_header_stdc = yes; then
4558 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4559 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4560 /* end confdefs.h. */
4561 #include <stdlib.h>
4562
4563 _ACEOF
4564 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4565 $EGREP "free" >/dev/null 2>&1; then :
4566
4567 else
4568 ac_cv_header_stdc=no
4569 fi
4570 rm -f conftest*
4571
4572 fi
4573
4574 if test $ac_cv_header_stdc = yes; then
4575 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4576 if test "$cross_compiling" = yes; then :
4577 :
4578 else
4579 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4580 /* end confdefs.h. */
4581 #include <ctype.h>
4582 #include <stdlib.h>
4583 #if ((' ' & 0x0FF) == 0x020)
4584 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4585 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4586 #else
4587 # define ISLOWER(c) \
4588 (('a' <= (c) && (c) <= 'i') \
4589 || ('j' <= (c) && (c) <= 'r') \
4590 || ('s' <= (c) && (c) <= 'z'))
4591 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4592 #endif
4593
4594 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4595 int
4596 main ()
4597 {
4598 int i;
4599 for (i = 0; i < 256; i++)
4600 if (XOR (islower (i), ISLOWER (i))
4601 || toupper (i) != TOUPPER (i))
4602 return 2;
4603 return 0;
4604 }
4605 _ACEOF
4606 if ac_fn_c_try_run "$LINENO"; then :
4607
4608 else
4609 ac_cv_header_stdc=no
4610 fi
4611 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4612 conftest.$ac_objext conftest.beam conftest.$ac_ext
4613 fi
4614
4615 fi
4616 fi
4617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4618 $as_echo "$ac_cv_header_stdc" >&6; }
4619 if test $ac_cv_header_stdc = yes; then
4620
4621 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
4622
4623 fi
4624
4625 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
4626 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4627 inttypes.h stdint.h unistd.h
4628 do :
4629 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4630 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4631 "
4632 eval as_val=\$$as_ac_Header
4633 if test "x$as_val" = x""yes; then :
4634 cat >>confdefs.h <<_ACEOF
4635 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4636 _ACEOF
4637
4638 fi
4639
4640 done
4641
4642
4643
4644 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4645 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
4646 MINIX=yes
4647 else
4648 MINIX=
4649 fi
4650
4651
4652 if test "$MINIX" = yes; then
4653
4654 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
4655
4656
4657 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
4658
4659
4660 $as_echo "#define _MINIX 1" >>confdefs.h
4661
4662
4663 $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h
4664
4665 fi
4666
4667
4668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4669 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4670 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
4671 $as_echo_n "(cached) " >&6
4672 else
4673 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4674 /* end confdefs.h. */
4675
4676 # define __EXTENSIONS__ 1
4677 $ac_includes_default
4678 int
4679 main ()
4680 {
4681
4682 ;
4683 return 0;
4684 }
4685 _ACEOF
4686 if ac_fn_c_try_compile "$LINENO"; then :
4687 ac_cv_safe_to_define___extensions__=yes
4688 else
4689 ac_cv_safe_to_define___extensions__=no
4690 fi
4691 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4692 fi
4693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4694 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
4695 test $ac_cv_safe_to_define___extensions__ = yes &&
4696 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
4697
4698 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
4699
4700 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
4701
4702 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
4703
4704 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
4705
4706 $as_echo "#define __STDC_WANT_IEC_60559_ATTRIBS_EXT__ 1" >>confdefs.h
4707
4708 $as_echo "#define __STDC_WANT_IEC_60559_BFP_EXT__ 1" >>confdefs.h
4709
4710 $as_echo "#define __STDC_WANT_IEC_60559_DFP_EXT__ 1" >>confdefs.h
4711
4712 $as_echo "#define __STDC_WANT_IEC_60559_FUNCS_EXT__ 1" >>confdefs.h
4713
4714 $as_echo "#define __STDC_WANT_IEC_60559_TYPES_EXT__ 1" >>confdefs.h
4715
4716 $as_echo "#define __STDC_WANT_LIB_EXT2__ 1" >>confdefs.h
4717
4718 $as_echo "#define __STDC_WANT_MATH_SPEC_FUNCS__ 1" >>confdefs.h
4719
4720 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
4721
4722 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5
4723 $as_echo_n "checking whether _XOPEN_SOURCE should be defined... " >&6; }
4724 if test "${ac_cv_should_define__xopen_source+set}" = set; then :
4725 $as_echo_n "(cached) " >&6
4726 else
4727 ac_cv_should_define__xopen_source=no
4728 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4729 /* end confdefs.h. */
4730
4731 #include <wchar.h>
4732 mbstate_t x;
4733 int
4734 main ()
4735 {
4736
4737 ;
4738 return 0;
4739 }
4740 _ACEOF
4741 if ac_fn_c_try_compile "$LINENO"; then :
4742
4743 else
4744 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4745 /* end confdefs.h. */
4746
4747 #define _XOPEN_SOURCE 500
4748 #include <wchar.h>
4749 mbstate_t x;
4750 int
4751 main ()
4752 {
4753
4754 ;
4755 return 0;
4756 }
4757 _ACEOF
4758 if ac_fn_c_try_compile "$LINENO"; then :
4759 ac_cv_should_define__xopen_source=yes
4760 fi
4761 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4762 fi
4763 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4764 fi
4765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5
4766 $as_echo "$ac_cv_should_define__xopen_source" >&6; }
4767 test $ac_cv_should_define__xopen_source = yes &&
4768 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
4769
4770
4771
4772
4773
4774
4775
4776
4777
4778
4779
4780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
4781 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
4782 if test "${gl_cv_c_amsterdam_compiler+set}" = set; then :
4783 $as_echo_n "(cached) " >&6
4784 else
4785
4786 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4787 /* end confdefs.h. */
4788
4789 #ifdef __ACK__
4790 Amsterdam
4791 #endif
4792
4793 _ACEOF
4794 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4795 $EGREP "Amsterdam" >/dev/null 2>&1; then :
4796 gl_cv_c_amsterdam_compiler=yes
4797 else
4798 gl_cv_c_amsterdam_compiler=no
4799 fi
4800 rm -f conftest*
4801
4802
4803 fi
4804 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
4805 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
4806
4807 if test $gl_cv_c_amsterdam_compiler = yes; then
4808 if test -z "$AR"; then
4809 AR='cc -c.a'
4810 fi
4811 if test -z "$ARFLAGS"; then
4812 ARFLAGS='-o'
4813 fi
4814 else
4815 :
4816 fi
4817
4818 if test -n "$ac_tool_prefix"; then
4819 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
4820 set dummy ${ac_tool_prefix}ar; ac_word=$2
4821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4822 $as_echo_n "checking for $ac_word... " >&6; }
4823 if test "${ac_cv_prog_AR+set}" = set; then :
4824 $as_echo_n "(cached) " >&6
4825 else
4826 if test -n "$AR"; then
4827 ac_cv_prog_AR="$AR" # Let the user override the test.
4828 else
4829 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4830 for as_dir in $PATH
4831 do
4832 IFS=$as_save_IFS
4833 test -z "$as_dir" && as_dir=.
4834 for ac_exec_ext in '' $ac_executable_extensions; do
4835 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4836 ac_cv_prog_AR="${ac_tool_prefix}ar"
4837 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4838 break 2
4839 fi
4840 done
4841 done
4842 IFS=$as_save_IFS
4843
4844 fi
4845 fi
4846 AR=$ac_cv_prog_AR
4847 if test -n "$AR"; then
4848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
4849 $as_echo "$AR" >&6; }
4850 else
4851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4852 $as_echo "no" >&6; }
4853 fi
4854
4855
4856 fi
4857 if test -z "$ac_cv_prog_AR"; then
4858 ac_ct_AR=$AR
4859 # Extract the first word of "ar", so it can be a program name with args.
4860 set dummy ar; ac_word=$2
4861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4862 $as_echo_n "checking for $ac_word... " >&6; }
4863 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
4864 $as_echo_n "(cached) " >&6
4865 else
4866 if test -n "$ac_ct_AR"; then
4867 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
4868 else
4869 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4870 for as_dir in $PATH
4871 do
4872 IFS=$as_save_IFS
4873 test -z "$as_dir" && as_dir=.
4874 for ac_exec_ext in '' $ac_executable_extensions; do
4875 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4876 ac_cv_prog_ac_ct_AR="ar"
4877 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4878 break 2
4879 fi
4880 done
4881 done
4882 IFS=$as_save_IFS
4883
4884 fi
4885 fi
4886 ac_ct_AR=$ac_cv_prog_ac_ct_AR
4887 if test -n "$ac_ct_AR"; then
4888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
4889 $as_echo "$ac_ct_AR" >&6; }
4890 else
4891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4892 $as_echo "no" >&6; }
4893 fi
4894
4895 if test "x$ac_ct_AR" = x; then
4896 AR="ar"
4897 else
4898 case $cross_compiling:$ac_tool_warned in
4899 yes:)
4900 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4901 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4902 ac_tool_warned=yes ;;
4903 esac
4904 AR=$ac_ct_AR
4905 fi
4906 else
4907 AR="$ac_cv_prog_AR"
4908 fi
4909
4910 if test -z "$ARFLAGS"; then
4911 ARFLAGS='cr'
4912 fi
4913
4914
4915
4916 if test -z "$RANLIB"; then
4917 if test $gl_cv_c_amsterdam_compiler = yes; then
4918 RANLIB=':'
4919 else
4920 if test -n "$ac_tool_prefix"; then
4921 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
4922 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
4923 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4924 $as_echo_n "checking for $ac_word... " >&6; }
4925 if test "${ac_cv_prog_RANLIB+set}" = set; then :
4926 $as_echo_n "(cached) " >&6
4927 else
4928 if test -n "$RANLIB"; then
4929 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4930 else
4931 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4932 for as_dir in $PATH
4933 do
4934 IFS=$as_save_IFS
4935 test -z "$as_dir" && as_dir=.
4936 for ac_exec_ext in '' $ac_executable_extensions; do
4937 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4938 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
4939 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4940 break 2
4941 fi
4942 done
4943 done
4944 IFS=$as_save_IFS
4945
4946 fi
4947 fi
4948 RANLIB=$ac_cv_prog_RANLIB
4949 if test -n "$RANLIB"; then
4950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
4951 $as_echo "$RANLIB" >&6; }
4952 else
4953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4954 $as_echo "no" >&6; }
4955 fi
4956
4957
4958 fi
4959 if test -z "$ac_cv_prog_RANLIB"; then
4960 ac_ct_RANLIB=$RANLIB
4961 # Extract the first word of "ranlib", so it can be a program name with args.
4962 set dummy ranlib; ac_word=$2
4963 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4964 $as_echo_n "checking for $ac_word... " >&6; }
4965 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
4966 $as_echo_n "(cached) " >&6
4967 else
4968 if test -n "$ac_ct_RANLIB"; then
4969 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4970 else
4971 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4972 for as_dir in $PATH
4973 do
4974 IFS=$as_save_IFS
4975 test -z "$as_dir" && as_dir=.
4976 for ac_exec_ext in '' $ac_executable_extensions; do
4977 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4978 ac_cv_prog_ac_ct_RANLIB="ranlib"
4979 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4980 break 2
4981 fi
4982 done
4983 done
4984 IFS=$as_save_IFS
4985
4986 fi
4987 fi
4988 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4989 if test -n "$ac_ct_RANLIB"; then
4990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
4991 $as_echo "$ac_ct_RANLIB" >&6; }
4992 else
4993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4994 $as_echo "no" >&6; }
4995 fi
4996
4997 if test "x$ac_ct_RANLIB" = x; then
4998 RANLIB=":"
4999 else
5000 case $cross_compiling:$ac_tool_warned in
5001 yes:)
5002 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5003 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5004 ac_tool_warned=yes ;;
5005 esac
5006 RANLIB=$ac_ct_RANLIB
5007 fi
5008 else
5009 RANLIB="$ac_cv_prog_RANLIB"
5010 fi
5011
5012 fi
5013 fi
5014
5015
5016 ac_aux_dir=
5017 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
5018 for ac_t in install-sh install.sh shtool; do
5019 if test -f "$ac_dir/$ac_t"; then
5020 ac_aux_dir=$ac_dir
5021 ac_install_sh="$ac_aux_dir/$ac_t -c"
5022 break 2
5023 fi
5024 done
5025 done
5026 if test -z "$ac_aux_dir"; then
5027 as_fn_error "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
5028 fi
5029
5030 # These three variables are undocumented and unsupported,
5031 # and are intended to be withdrawn in a future Autoconf release.
5032 # They can cause serious problems if a builder's source tree is in a directory
5033 # whose full name contains unusual characters.
5034 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
5035 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
5036 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
5037
5038
5039 # Make sure we can run config.sub.
5040 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
5041 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
5042
5043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
5044 $as_echo_n "checking build system type... " >&6; }
5045 if test "${ac_cv_build+set}" = set; then :
5046 $as_echo_n "(cached) " >&6
5047 else
5048 ac_build_alias=$build_alias
5049 test "x$ac_build_alias" = x &&
5050 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
5051 test "x$ac_build_alias" = x &&
5052 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
5053 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
5054 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
5055
5056 fi
5057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
5058 $as_echo "$ac_cv_build" >&6; }
5059 case $ac_cv_build in
5060 *-*-*) ;;
5061 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
5062 esac
5063 build=$ac_cv_build
5064 ac_save_IFS=$IFS; IFS='-'
5065 set x $ac_cv_build
5066 shift
5067 build_cpu=$1
5068 build_vendor=$2
5069 shift; shift
5070 # Remember, the first character of IFS is used to create $*,
5071 # except with old shells:
5072 build_os=$*
5073 IFS=$ac_save_IFS
5074 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
5075
5076
5077 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
5078 $as_echo_n "checking host system type... " >&6; }
5079 if test "${ac_cv_host+set}" = set; then :
5080 $as_echo_n "(cached) " >&6
5081 else
5082 if test "x$host_alias" = x; then
5083 ac_cv_host=$ac_cv_build
5084 else
5085 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
5086 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
5087 fi
5088
5089 fi
5090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
5091 $as_echo "$ac_cv_host" >&6; }
5092 case $ac_cv_host in
5093 *-*-*) ;;
5094 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
5095 esac
5096 host=$ac_cv_host
5097 ac_save_IFS=$IFS; IFS='-'
5098 set x $ac_cv_host
5099 shift
5100 host_cpu=$1
5101 host_vendor=$2
5102 shift; shift
5103 # Remember, the first character of IFS is used to create $*,
5104 # except with old shells:
5105 host_os=$*
5106 IFS=$ac_save_IFS
5107 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
5108
5109
5110
5111
5112
5113 # IEEE behaviour is the default on all CPUs except Alpha and SH
5114 # (according to the test results of Bruno Haible's ieeefp/fenv_default.m4
5115 # and the GCC 4.1.2 manual).
5116 case "$host_cpu" in
5117 alpha*)
5118 # On Alpha systems, a compiler option provides the behaviour.
5119 # See the ieee(3) manual page, also available at
5120 # <http://h30097.www3.hp.com/docs/base_doc/DOCUMENTATION/V51B_HTML/MAN/MAN3/0600____.HTM>
5121 if test -n "$GCC"; then
5122 # GCC has the option -mieee.
5123 # For full IEEE compliance (rarely needed), use option -mieee-with-inexact.
5124 CPPFLAGS="$CPPFLAGS -mieee"
5125 else
5126 # Compaq (ex-DEC) C has the option -ieee, equivalent to -ieee_with_no_inexact.
5127 # For full IEEE compliance (rarely needed), use option -ieee_with_inexact.
5128 CPPFLAGS="$CPPFLAGS -ieee"
5129 fi
5130 ;;
5131 sh*)
5132 if test -n "$GCC"; then
5133 # GCC has the option -mieee.
5134 CPPFLAGS="$CPPFLAGS -mieee"
5135 fi
5136 ;;
5137 esac
5138
5139 # Check whether --enable-largefile was given.
5140 if test "${enable_largefile+set}" = set; then :
5141 enableval=$enable_largefile;
5142 fi
5143
5144 if test "$enable_largefile" != no; then
5145
5146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
5147 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
5148 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
5149 $as_echo_n "(cached) " >&6
5150 else
5151 ac_cv_sys_largefile_CC=no
5152 if test "$GCC" != yes; then
5153 ac_save_CC=$CC
5154 while :; do
5155 # IRIX 6.2 and later do not support large files by default,
5156 # so use the C compiler's -n32 option if that helps.
5157 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5158 /* end confdefs.h. */
5159 #include <sys/types.h>
5160 /* Check that off_t can represent 2**63 - 1 correctly.
5161 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5162 since some C++ compilers masquerading as C compilers
5163 incorrectly reject 9223372036854775807. */
5164 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5165 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5166 && LARGE_OFF_T % 2147483647 == 1)
5167 ? 1 : -1];
5168 int
5169 main ()
5170 {
5171
5172 ;
5173 return 0;
5174 }
5175 _ACEOF
5176 if ac_fn_c_try_compile "$LINENO"; then :
5177 break
5178 fi
5179 rm -f core conftest.err conftest.$ac_objext
5180 CC="$CC -n32"
5181 if ac_fn_c_try_compile "$LINENO"; then :
5182 ac_cv_sys_largefile_CC=' -n32'; break
5183 fi
5184 rm -f core conftest.err conftest.$ac_objext
5185 break
5186 done
5187 CC=$ac_save_CC
5188 rm -f conftest.$ac_ext
5189 fi
5190 fi
5191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
5192 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
5193 if test "$ac_cv_sys_largefile_CC" != no; then
5194 CC=$CC$ac_cv_sys_largefile_CC
5195 fi
5196
5197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
5198 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
5199 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
5200 $as_echo_n "(cached) " >&6
5201 else
5202 while :; do
5203 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5204 /* end confdefs.h. */
5205 #include <sys/types.h>
5206 /* Check that off_t can represent 2**63 - 1 correctly.
5207 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5208 since some C++ compilers masquerading as C compilers
5209 incorrectly reject 9223372036854775807. */
5210 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5211 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5212 && LARGE_OFF_T % 2147483647 == 1)
5213 ? 1 : -1];
5214 int
5215 main ()
5216 {
5217
5218 ;
5219 return 0;
5220 }
5221 _ACEOF
5222 if ac_fn_c_try_compile "$LINENO"; then :
5223 ac_cv_sys_file_offset_bits=no; break
5224 fi
5225 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5226 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5227 /* end confdefs.h. */
5228 #define _FILE_OFFSET_BITS 64
5229 #include <sys/types.h>
5230 /* Check that off_t can represent 2**63 - 1 correctly.
5231 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5232 since some C++ compilers masquerading as C compilers
5233 incorrectly reject 9223372036854775807. */
5234 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5235 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5236 && LARGE_OFF_T % 2147483647 == 1)
5237 ? 1 : -1];
5238 int
5239 main ()
5240 {
5241
5242 ;
5243 return 0;
5244 }
5245 _ACEOF
5246 if ac_fn_c_try_compile "$LINENO"; then :
5247 ac_cv_sys_file_offset_bits=64; break
5248 fi
5249 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5250 ac_cv_sys_file_offset_bits=unknown
5251 break
5252 done
5253 fi
5254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
5255 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
5256 case $ac_cv_sys_file_offset_bits in #(
5257 no | unknown) ;;
5258 *)
5259 cat >>confdefs.h <<_ACEOF
5260 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
5261 _ACEOF
5262 ;;
5263 esac
5264 rm -rf conftest*
5265 if test $ac_cv_sys_file_offset_bits = unknown; then
5266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
5267 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
5268 if test "${ac_cv_sys_large_files+set}" = set; then :
5269 $as_echo_n "(cached) " >&6
5270 else
5271 while :; do
5272 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5273 /* end confdefs.h. */
5274 #include <sys/types.h>
5275 /* Check that off_t can represent 2**63 - 1 correctly.
5276 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5277 since some C++ compilers masquerading as C compilers
5278 incorrectly reject 9223372036854775807. */
5279 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5280 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5281 && LARGE_OFF_T % 2147483647 == 1)
5282 ? 1 : -1];
5283 int
5284 main ()
5285 {
5286
5287 ;
5288 return 0;
5289 }
5290 _ACEOF
5291 if ac_fn_c_try_compile "$LINENO"; then :
5292 ac_cv_sys_large_files=no; break
5293 fi
5294 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5295 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5296 /* end confdefs.h. */
5297 #define _LARGE_FILES 1
5298 #include <sys/types.h>
5299 /* Check that off_t can represent 2**63 - 1 correctly.
5300 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5301 since some C++ compilers masquerading as C compilers
5302 incorrectly reject 9223372036854775807. */
5303 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5304 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5305 && LARGE_OFF_T % 2147483647 == 1)
5306 ? 1 : -1];
5307 int
5308 main ()
5309 {
5310
5311 ;
5312 return 0;
5313 }
5314 _ACEOF
5315 if ac_fn_c_try_compile "$LINENO"; then :
5316 ac_cv_sys_large_files=1; break
5317 fi
5318 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5319 ac_cv_sys_large_files=unknown
5320 break
5321 done
5322 fi
5323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
5324 $as_echo "$ac_cv_sys_large_files" >&6; }
5325 case $ac_cv_sys_large_files in #(
5326 no | unknown) ;;
5327 *)
5328 cat >>confdefs.h <<_ACEOF
5329 #define _LARGE_FILES $ac_cv_sys_large_files
5330 _ACEOF
5331 ;;
5332 esac
5333 rm -rf conftest*
5334 fi
5335
5336
5337 $as_echo "#define _DARWIN_USE_64_BIT_INODE 1" >>confdefs.h
5338
5339 fi
5340
5341
5342
5343 # Pre-early section.
5344
5345
5346
5347 # Code from module absolute-header:
5348 # Code from module alloca:
5349 # Code from module alloca-opt:
5350 # Code from module assure:
5351 # Code from module at-internal:
5352 # Code from module canonicalize-lgpl:
5353 # Code from module chdir:
5354 # Code from module chdir-long:
5355 # Code from module cloexec:
5356 # Code from module close:
5357 # Code from module closedir:
5358 # Code from module configmake:
5359 # Code from module d-ino:
5360 # Code from module d-type:
5361 # Code from module dirent:
5362 # Code from module dirfd:
5363 # Code from module dirname-lgpl:
5364 # Code from module dosname:
5365 # Code from module double-slash-root:
5366 # Code from module dup:
5367 # Code from module dup2:
5368 # Code from module environ:
5369 # Code from module errno:
5370 # Code from module error:
5371 # Code from module exitfail:
5372 # Code from module extensions:
5373 # Code from module extern-inline:
5374 # Code from module fchdir:
5375 # Code from module fcntl:
5376 # Code from module fcntl-h:
5377 # Code from module fd-hook:
5378 # Code from module fdopendir:
5379 # Code from module filename:
5380 # Code from module filenamecat-lgpl:
5381 # Code from module flexmember:
5382 # Code from module float:
5383 # Code from module fnmatch:
5384 # Code from module fnmatch-gnu:
5385 # Code from module fpieee:
5386
5387 # Code from module fpucw:
5388 # Code from module frexp:
5389 # Code from module frexpl:
5390 # Code from module fstat:
5391 # Code from module fstatat:
5392 # Code from module getcwd:
5393 # Code from module getcwd-lgpl:
5394 # Code from module getdtablesize:
5395 # Code from module getlogin_r:
5396 # Code from module getprogname:
5397 # Code from module gettext-h:
5398 # Code from module gettimeofday:
5399 # Code from module glob:
5400 # Code from module hard-locale:
5401 # Code from module include_next:
5402 # Code from module intprops:
5403 # Code from module inttypes:
5404 # Code from module inttypes-incomplete:
5405 # Code from module isnand-nolibm:
5406 # Code from module isnanl-nolibm:
5407 # Code from module largefile:
5408
5409 # Code from module limits-h:
5410 # Code from module localcharset:
5411 # Code from module lstat:
5412 # Code from module malloc-posix:
5413 # Code from module malloca:
5414 # Code from module math:
5415 # Code from module mbrtowc:
5416 # Code from module mbsinit:
5417 # Code from module mbsrtowcs:
5418 # Code from module memchr:
5419 # Code from module memmem:
5420 # Code from module memmem-simple:
5421 # Code from module mempcpy:
5422 # Code from module memrchr:
5423 # Code from module mkstemp:
5424 # Code from module msvc-inval:
5425 # Code from module msvc-nothrow:
5426 # Code from module multiarch:
5427 # Code from module nocrash:
5428 # Code from module open:
5429 # Code from module openat:
5430 # Code from module openat-die:
5431 # Code from module openat-h:
5432 # Code from module opendir:
5433 # Code from module pathmax:
5434 # Code from module rawmemchr:
5435 # Code from module readdir:
5436 # Code from module readlink:
5437 # Code from module realloc-posix:
5438 # Code from module rename:
5439 # Code from module rewinddir:
5440 # Code from module rmdir:
5441 # Code from module same-inode:
5442 # Code from module save-cwd:
5443 # Code from module secure_getenv:
5444 # Code from module setenv:
5445 # Code from module signal-h:
5446 # Code from module snippet/_Noreturn:
5447 # Code from module snippet/arg-nonnull:
5448 # Code from module snippet/c++defs:
5449 # Code from module snippet/warn-on-use:
5450 # Code from module ssize_t:
5451 # Code from module stat:
5452 # Code from module stdbool:
5453 # Code from module stddef:
5454 # Code from module stdint:
5455 # Code from module stdio:
5456 # Code from module stdlib:
5457 # Code from module strchrnul:
5458 # Code from module strdup-posix:
5459 # Code from module streq:
5460 # Code from module strerror:
5461 # Code from module strerror-override:
5462 # Code from module string:
5463 # Code from module strnlen1:
5464 # Code from module strstr:
5465 # Code from module strstr-simple:
5466 # Code from module strtok_r:
5467 # Code from module sys_stat:
5468 # Code from module sys_time:
5469 # Code from module sys_types:
5470 # Code from module tempname:
5471 # Code from module time:
5472 # Code from module unistd:
5473 # Code from module unistd-safer:
5474 # Code from module unsetenv:
5475 # Code from module update-copyright:
5476 # Code from module verify:
5477 # Code from module wchar:
5478 # Code from module wctype-h:
5479
5480 ac_ext=c
5481 ac_cpp='$CPP $CPPFLAGS'
5482 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5483 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5484 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5485 if test -n "$ac_tool_prefix"; then
5486 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
5487 set dummy ${ac_tool_prefix}gcc; ac_word=$2
5488 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5489 $as_echo_n "checking for $ac_word... " >&6; }
5490 if test "${ac_cv_prog_CC+set}" = set; then :
5491 $as_echo_n "(cached) " >&6
5492 else
5493 if test -n "$CC"; then
5494 ac_cv_prog_CC="$CC" # Let the user override the test.
5495 else
5496 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5497 for as_dir in $PATH
5498 do
5499 IFS=$as_save_IFS
5500 test -z "$as_dir" && as_dir=.
5501 for ac_exec_ext in '' $ac_executable_extensions; do
5502 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5503 ac_cv_prog_CC="${ac_tool_prefix}gcc"
5504 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5505 break 2
5506 fi
5507 done
5508 done
5509 IFS=$as_save_IFS
5510
5511 fi
5512 fi
5513 CC=$ac_cv_prog_CC
5514 if test -n "$CC"; then
5515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5516 $as_echo "$CC" >&6; }
5517 else
5518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5519 $as_echo "no" >&6; }
5520 fi
5521
5522
5523 fi
5524 if test -z "$ac_cv_prog_CC"; then
5525 ac_ct_CC=$CC
5526 # Extract the first word of "gcc", so it can be a program name with args.
5527 set dummy gcc; ac_word=$2
5528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5529 $as_echo_n "checking for $ac_word... " >&6; }
5530 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
5531 $as_echo_n "(cached) " >&6
5532 else
5533 if test -n "$ac_ct_CC"; then
5534 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
5535 else
5536 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5537 for as_dir in $PATH
5538 do
5539 IFS=$as_save_IFS
5540 test -z "$as_dir" && as_dir=.
5541 for ac_exec_ext in '' $ac_executable_extensions; do
5542 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5543 ac_cv_prog_ac_ct_CC="gcc"
5544 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5545 break 2
5546 fi
5547 done
5548 done
5549 IFS=$as_save_IFS
5550
5551 fi
5552 fi
5553 ac_ct_CC=$ac_cv_prog_ac_ct_CC
5554 if test -n "$ac_ct_CC"; then
5555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5556 $as_echo "$ac_ct_CC" >&6; }
5557 else
5558 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5559 $as_echo "no" >&6; }
5560 fi
5561
5562 if test "x$ac_ct_CC" = x; then
5563 CC=""
5564 else
5565 case $cross_compiling:$ac_tool_warned in
5566 yes:)
5567 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5568 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5569 ac_tool_warned=yes ;;
5570 esac
5571 CC=$ac_ct_CC
5572 fi
5573 else
5574 CC="$ac_cv_prog_CC"
5575 fi
5576
5577 if test -z "$CC"; then
5578 if test -n "$ac_tool_prefix"; then
5579 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
5580 set dummy ${ac_tool_prefix}cc; ac_word=$2
5581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5582 $as_echo_n "checking for $ac_word... " >&6; }
5583 if test "${ac_cv_prog_CC+set}" = set; then :
5584 $as_echo_n "(cached) " >&6
5585 else
5586 if test -n "$CC"; then
5587 ac_cv_prog_CC="$CC" # Let the user override the test.
5588 else
5589 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5590 for as_dir in $PATH
5591 do
5592 IFS=$as_save_IFS
5593 test -z "$as_dir" && as_dir=.
5594 for ac_exec_ext in '' $ac_executable_extensions; do
5595 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5596 ac_cv_prog_CC="${ac_tool_prefix}cc"
5597 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5598 break 2
5599 fi
5600 done
5601 done
5602 IFS=$as_save_IFS
5603
5604 fi
5605 fi
5606 CC=$ac_cv_prog_CC
5607 if test -n "$CC"; then
5608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5609 $as_echo "$CC" >&6; }
5610 else
5611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5612 $as_echo "no" >&6; }
5613 fi
5614
5615
5616 fi
5617 fi
5618 if test -z "$CC"; then
5619 # Extract the first word of "cc", so it can be a program name with args.
5620 set dummy cc; ac_word=$2
5621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5622 $as_echo_n "checking for $ac_word... " >&6; }
5623 if test "${ac_cv_prog_CC+set}" = set; then :
5624 $as_echo_n "(cached) " >&6
5625 else
5626 if test -n "$CC"; then
5627 ac_cv_prog_CC="$CC" # Let the user override the test.
5628 else
5629 ac_prog_rejected=no
5630 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5631 for as_dir in $PATH
5632 do
5633 IFS=$as_save_IFS
5634 test -z "$as_dir" && as_dir=.
5635 for ac_exec_ext in '' $ac_executable_extensions; do
5636 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5637 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
5638 ac_prog_rejected=yes
5639 continue
5640 fi
5641 ac_cv_prog_CC="cc"
5642 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5643 break 2
5644 fi
5645 done
5646 done
5647 IFS=$as_save_IFS
5648
5649 if test $ac_prog_rejected = yes; then
5650 # We found a bogon in the path, so make sure we never use it.
5651 set dummy $ac_cv_prog_CC
5652 shift
5653 if test $# != 0; then
5654 # We chose a different compiler from the bogus one.
5655 # However, it has the same basename, so the bogon will be chosen
5656 # first if we set CC to just the basename; use the full file name.
5657 shift
5658 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
5659 fi
5660 fi
5661 fi
5662 fi
5663 CC=$ac_cv_prog_CC
5664 if test -n "$CC"; then
5665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5666 $as_echo "$CC" >&6; }
5667 else
5668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5669 $as_echo "no" >&6; }
5670 fi
5671
5672
5673 fi
5674 if test -z "$CC"; then
5675 if test -n "$ac_tool_prefix"; then
5676 for ac_prog in cl.exe
5677 do
5678 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5679 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5681 $as_echo_n "checking for $ac_word... " >&6; }
5682 if test "${ac_cv_prog_CC+set}" = set; then :
5683 $as_echo_n "(cached) " >&6
5684 else
5685 if test -n "$CC"; then
5686 ac_cv_prog_CC="$CC" # Let the user override the test.
5687 else
5688 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5689 for as_dir in $PATH
5690 do
5691 IFS=$as_save_IFS
5692 test -z "$as_dir" && as_dir=.
5693 for ac_exec_ext in '' $ac_executable_extensions; do
5694 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5695 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
5696 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5697 break 2
5698 fi
5699 done
5700 done
5701 IFS=$as_save_IFS
5702
5703 fi
5704 fi
5705 CC=$ac_cv_prog_CC
5706 if test -n "$CC"; then
5707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5708 $as_echo "$CC" >&6; }
5709 else
5710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5711 $as_echo "no" >&6; }
5712 fi
5713
5714
5715 test -n "$CC" && break
5716 done
5717 fi
5718 if test -z "$CC"; then
5719 ac_ct_CC=$CC
5720 for ac_prog in cl.exe
5721 do
5722 # Extract the first word of "$ac_prog", so it can be a program name with args.
5723 set dummy $ac_prog; ac_word=$2
5724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5725 $as_echo_n "checking for $ac_word... " >&6; }
5726 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
5727 $as_echo_n "(cached) " >&6
5728 else
5729 if test -n "$ac_ct_CC"; then
5730 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
5731 else
5732 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5733 for as_dir in $PATH
5734 do
5735 IFS=$as_save_IFS
5736 test -z "$as_dir" && as_dir=.
5737 for ac_exec_ext in '' $ac_executable_extensions; do
5738 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5739 ac_cv_prog_ac_ct_CC="$ac_prog"
5740 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5741 break 2
5742 fi
5743 done
5744 done
5745 IFS=$as_save_IFS
5746
5747 fi
5748 fi
5749 ac_ct_CC=$ac_cv_prog_ac_ct_CC
5750 if test -n "$ac_ct_CC"; then
5751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5752 $as_echo "$ac_ct_CC" >&6; }
5753 else
5754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5755 $as_echo "no" >&6; }
5756 fi
5757
5758
5759 test -n "$ac_ct_CC" && break
5760 done
5761
5762 if test "x$ac_ct_CC" = x; then
5763 CC=""
5764 else
5765 case $cross_compiling:$ac_tool_warned in
5766 yes:)
5767 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5768 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5769 ac_tool_warned=yes ;;
5770 esac
5771 CC=$ac_ct_CC
5772 fi
5773 fi
5774
5775 fi
5776
5777
5778 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5779 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5780 as_fn_error "no acceptable C compiler found in \$PATH
5781 See \`config.log' for more details." "$LINENO" 5; }
5782
5783 # Provide some information about the compiler.
5784 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
5785 set X $ac_compile
5786 ac_compiler=$2
5787 for ac_option in --version -v -V -qversion; do
5788 { { ac_try="$ac_compiler $ac_option >&5"
5789 case "(($ac_try" in
5790 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5791 *) ac_try_echo=$ac_try;;
5792 esac
5793 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5794 $as_echo "$ac_try_echo"; } >&5
5795 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
5796 ac_status=$?
5797 if test -s conftest.err; then
5798 sed '10a\
5799 ... rest of stderr output deleted ...
5800 10q' conftest.err >conftest.er1
5801 cat conftest.er1 >&5
5802 rm -f conftest.er1 conftest.err
5803 fi
5804 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5805 test $ac_status = 0; }
5806 done
5807
5808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5809 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5810 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
5811 $as_echo_n "(cached) " >&6
5812 else
5813 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5814 /* end confdefs.h. */
5815
5816 int
5817 main ()
5818 {
5819 #ifndef __GNUC__
5820 choke me
5821 #endif
5822
5823 ;
5824 return 0;
5825 }
5826 _ACEOF
5827 if ac_fn_c_try_compile "$LINENO"; then :
5828 ac_compiler_gnu=yes
5829 else
5830 ac_compiler_gnu=no
5831 fi
5832 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5833 ac_cv_c_compiler_gnu=$ac_compiler_gnu
5834
5835 fi
5836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5837 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
5838 if test $ac_compiler_gnu = yes; then
5839 GCC=yes
5840 else
5841 GCC=
5842 fi
5843 ac_test_CFLAGS=${CFLAGS+set}
5844 ac_save_CFLAGS=$CFLAGS
5845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5846 $as_echo_n "checking whether $CC accepts -g... " >&6; }
5847 if test "${ac_cv_prog_cc_g+set}" = set; then :
5848 $as_echo_n "(cached) " >&6
5849 else
5850 ac_save_c_werror_flag=$ac_c_werror_flag
5851 ac_c_werror_flag=yes
5852 ac_cv_prog_cc_g=no
5853 CFLAGS="-g"
5854 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5855 /* end confdefs.h. */
5856
5857 int
5858 main ()
5859 {
5860
5861 ;
5862 return 0;
5863 }
5864 _ACEOF
5865 if ac_fn_c_try_compile "$LINENO"; then :
5866 ac_cv_prog_cc_g=yes
5867 else
5868 CFLAGS=""
5869 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5870 /* end confdefs.h. */
5871
5872 int
5873 main ()
5874 {
5875
5876 ;
5877 return 0;
5878 }
5879 _ACEOF
5880 if ac_fn_c_try_compile "$LINENO"; then :
5881
5882 else
5883 ac_c_werror_flag=$ac_save_c_werror_flag
5884 CFLAGS="-g"
5885 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5886 /* end confdefs.h. */
5887
5888 int
5889 main ()
5890 {
5891
5892 ;
5893 return 0;
5894 }
5895 _ACEOF
5896 if ac_fn_c_try_compile "$LINENO"; then :
5897 ac_cv_prog_cc_g=yes
5898 fi
5899 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5900 fi
5901 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5902 fi
5903 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5904 ac_c_werror_flag=$ac_save_c_werror_flag
5905 fi
5906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5907 $as_echo "$ac_cv_prog_cc_g" >&6; }
5908 if test "$ac_test_CFLAGS" = set; then
5909 CFLAGS=$ac_save_CFLAGS
5910 elif test $ac_cv_prog_cc_g = yes; then
5911 if test "$GCC" = yes; then
5912 CFLAGS="-g -O2"
5913 else
5914 CFLAGS="-g"
5915 fi
5916 else
5917 if test "$GCC" = yes; then
5918 CFLAGS="-O2"
5919 else
5920 CFLAGS=
5921 fi
5922 fi
5923 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5924 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5925 if test "${ac_cv_prog_cc_c89+set}" = set; then :
5926 $as_echo_n "(cached) " >&6
5927 else
5928 ac_cv_prog_cc_c89=no
5929 ac_save_CC=$CC
5930 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5931 /* end confdefs.h. */
5932 #include <stdarg.h>
5933 #include <stdio.h>
5934 #include <sys/types.h>
5935 #include <sys/stat.h>
5936 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5937 struct buf { int x; };
5938 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5939 static char *e (p, i)
5940 char **p;
5941 int i;
5942 {
5943 return p[i];
5944 }
5945 static char *f (char * (*g) (char **, int), char **p, ...)
5946 {
5947 char *s;
5948 va_list v;
5949 va_start (v,p);
5950 s = g (p, va_arg (v,int));
5951 va_end (v);
5952 return s;
5953 }
5954
5955 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5956 function prototypes and stuff, but not '\xHH' hex character constants.
5957 These don't provoke an error unfortunately, instead are silently treated
5958 as 'x'. The following induces an error, until -std is added to get
5959 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5960 array size at least. It's necessary to write '\x00'==0 to get something
5961 that's true only with -std. */
5962 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5963
5964 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5965 inside strings and character constants. */
5966 #define FOO(x) 'x'
5967 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5968
5969 int test (int i, double x);
5970 struct s1 {int (*f) (int a);};
5971 struct s2 {int (*f) (double a);};
5972 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5973 int argc;
5974 char **argv;
5975 int
5976 main ()
5977 {
5978 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5979 ;
5980 return 0;
5981 }
5982 _ACEOF
5983 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5984 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5985 do
5986 CC="$ac_save_CC $ac_arg"
5987 if ac_fn_c_try_compile "$LINENO"; then :
5988 ac_cv_prog_cc_c89=$ac_arg
5989 fi
5990 rm -f core conftest.err conftest.$ac_objext
5991 test "x$ac_cv_prog_cc_c89" != "xno" && break
5992 done
5993 rm -f conftest.$ac_ext
5994 CC=$ac_save_CC
5995
5996 fi
5997 # AC_CACHE_VAL
5998 case "x$ac_cv_prog_cc_c89" in
5999 x)
6000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6001 $as_echo "none needed" >&6; } ;;
6002 xno)
6003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6004 $as_echo "unsupported" >&6; } ;;
6005 *)
6006 CC="$CC $ac_cv_prog_cc_c89"
6007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
6008 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
6009 esac
6010 if test "x$ac_cv_prog_cc_c89" != xno; then :
6011
6012 fi
6013
6014 ac_ext=c
6015 ac_cpp='$CPP $CPPFLAGS'
6016 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6017 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6018 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6019
6020
6021 am_cv_prog_cc_stdc=$ac_cv_prog_cc_stdc
6022
6023
6024 ac_aux_dir=
6025 for ac_dir in ../.. "$srcdir"/../..; do
6026 for ac_t in install-sh install.sh shtool; do
6027 if test -f "$ac_dir/$ac_t"; then
6028 ac_aux_dir=$ac_dir
6029 ac_install_sh="$ac_aux_dir/$ac_t -c"
6030 break 2
6031 fi
6032 done
6033 done
6034 if test -z "$ac_aux_dir"; then
6035 as_fn_error "cannot find install-sh, install.sh, or shtool in ../.. \"$srcdir\"/../.." "$LINENO" 5
6036 fi
6037
6038 # These three variables are undocumented and unsupported,
6039 # and are intended to be withdrawn in a future Autoconf release.
6040 # They can cause serious problems if a builder's source tree is in a directory
6041 # whose full name contains unusual characters.
6042 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
6043 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
6044 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
6045
6046
6047 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
6048 $as_echo_n "checking target system type... " >&6; }
6049 if test "${ac_cv_target+set}" = set; then :
6050 $as_echo_n "(cached) " >&6
6051 else
6052 if test "x$target_alias" = x; then
6053 ac_cv_target=$ac_cv_host
6054 else
6055 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
6056 as_fn_error "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
6057 fi
6058
6059 fi
6060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
6061 $as_echo "$ac_cv_target" >&6; }
6062 case $ac_cv_target in
6063 *-*-*) ;;
6064 *) as_fn_error "invalid value of canonical target" "$LINENO" 5;;
6065 esac
6066 target=$ac_cv_target
6067 ac_save_IFS=$IFS; IFS='-'
6068 set x $ac_cv_target
6069 shift
6070 target_cpu=$1
6071 target_vendor=$2
6072 shift; shift
6073 # Remember, the first character of IFS is used to create $*,
6074 # except with old shells:
6075 target_os=$*
6076 IFS=$ac_save_IFS
6077 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
6078
6079
6080 # The aliases save the names the user supplied, while $host etc.
6081 # will get canonicalized.
6082 test -n "$target_alias" &&
6083 test "$program_prefix$program_suffix$program_transform_name" = \
6084 NONENONEs,x,x, &&
6085 program_prefix=${target_alias}-
6086
6087
6088
6089
6090
6091
6092
6093 LIBC_FATAL_STDERR_=1
6094 export LIBC_FATAL_STDERR_
6095
6096 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
6097 # for constant arguments. Useless!
6098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
6099 $as_echo_n "checking for working alloca.h... " >&6; }
6100 if test "${ac_cv_working_alloca_h+set}" = set; then :
6101 $as_echo_n "(cached) " >&6
6102 else
6103 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6104 /* end confdefs.h. */
6105 #include <alloca.h>
6106 int
6107 main ()
6108 {
6109 char *p = (char *) alloca (2 * sizeof (int));
6110 if (p) return 0;
6111 ;
6112 return 0;
6113 }
6114 _ACEOF
6115 if ac_fn_c_try_link "$LINENO"; then :
6116 ac_cv_working_alloca_h=yes
6117 else
6118 ac_cv_working_alloca_h=no
6119 fi
6120 rm -f core conftest.err conftest.$ac_objext \
6121 conftest$ac_exeext conftest.$ac_ext
6122 fi
6123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
6124 $as_echo "$ac_cv_working_alloca_h" >&6; }
6125 if test $ac_cv_working_alloca_h = yes; then
6126
6127 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
6128
6129 fi
6130
6131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
6132 $as_echo_n "checking for alloca... " >&6; }
6133 if test "${ac_cv_func_alloca_works+set}" = set; then :
6134 $as_echo_n "(cached) " >&6
6135 else
6136 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6137 /* end confdefs.h. */
6138 #ifdef __GNUC__
6139 # define alloca __builtin_alloca
6140 #else
6141 # ifdef _MSC_VER
6142 # include <malloc.h>
6143 # define alloca _alloca
6144 # else
6145 # ifdef HAVE_ALLOCA_H
6146 # include <alloca.h>
6147 # else
6148 # ifdef _AIX
6149 #pragma alloca
6150 # else
6151 # ifndef alloca /* predefined by HP cc +Olibcalls */
6152 char *alloca ();
6153 # endif
6154 # endif
6155 # endif
6156 # endif
6157 #endif
6158
6159 int
6160 main ()
6161 {
6162 char *p = (char *) alloca (1);
6163 if (p) return 0;
6164 ;
6165 return 0;
6166 }
6167 _ACEOF
6168 if ac_fn_c_try_link "$LINENO"; then :
6169 ac_cv_func_alloca_works=yes
6170 else
6171 ac_cv_func_alloca_works=no
6172 fi
6173 rm -f core conftest.err conftest.$ac_objext \
6174 conftest$ac_exeext conftest.$ac_ext
6175 fi
6176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
6177 $as_echo "$ac_cv_func_alloca_works" >&6; }
6178
6179 if test $ac_cv_func_alloca_works = yes; then
6180
6181 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
6182
6183 else
6184 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
6185 # that cause trouble. Some versions do not even contain alloca or
6186 # contain a buggy version. If you still want to use their alloca,
6187 # use ar to extract alloca.o from them instead of compiling alloca.c.
6188
6189
6190
6191
6192
6193 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
6194
6195 $as_echo "#define C_ALLOCA 1" >>confdefs.h
6196
6197
6198 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether 'alloca.c' needs Cray hooks" >&5
6199 $as_echo_n "checking whether 'alloca.c' needs Cray hooks... " >&6; }
6200 if test "${ac_cv_os_cray+set}" = set; then :
6201 $as_echo_n "(cached) " >&6
6202 else
6203 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6204 /* end confdefs.h. */
6205 #if defined CRAY && ! defined CRAY2
6206 webecray
6207 #else
6208 wenotbecray
6209 #endif
6210
6211 _ACEOF
6212 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6213 $EGREP "webecray" >/dev/null 2>&1; then :
6214 ac_cv_os_cray=yes
6215 else
6216 ac_cv_os_cray=no
6217 fi
6218 rm -f conftest*
6219
6220 fi
6221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
6222 $as_echo "$ac_cv_os_cray" >&6; }
6223 if test $ac_cv_os_cray = yes; then
6224 for ac_func in _getb67 GETB67 getb67; do
6225 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
6226 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
6227 eval as_val=\$$as_ac_var
6228 if test "x$as_val" = x""yes; then :
6229
6230 cat >>confdefs.h <<_ACEOF
6231 #define CRAY_STACKSEG_END $ac_func
6232 _ACEOF
6233
6234 break
6235 fi
6236
6237 done
6238 fi
6239
6240 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
6241 $as_echo_n "checking stack direction for C alloca... " >&6; }
6242 if test "${ac_cv_c_stack_direction+set}" = set; then :
6243 $as_echo_n "(cached) " >&6
6244 else
6245 if test "$cross_compiling" = yes; then :
6246 ac_cv_c_stack_direction=0
6247 else
6248 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6249 /* end confdefs.h. */
6250 $ac_includes_default
6251 int
6252 find_stack_direction (int *addr, int depth)
6253 {
6254 int dir, dummy = 0;
6255 if (! addr)
6256 addr = &dummy;
6257 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
6258 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
6259 return dir + dummy;
6260 }
6261
6262 int
6263 main (int argc, char **argv)
6264 {
6265 return find_stack_direction (0, argc + !argv + 20) < 0;
6266 }
6267 _ACEOF
6268 if ac_fn_c_try_run "$LINENO"; then :
6269 ac_cv_c_stack_direction=1
6270 else
6271 ac_cv_c_stack_direction=-1
6272 fi
6273 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6274 conftest.$ac_objext conftest.beam conftest.$ac_ext
6275 fi
6276
6277 fi
6278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
6279 $as_echo "$ac_cv_c_stack_direction" >&6; }
6280 cat >>confdefs.h <<_ACEOF
6281 #define STACK_DIRECTION $ac_cv_c_stack_direction
6282 _ACEOF
6283
6284
6285 fi
6286
6287
6288 GNULIB__EXIT=0;
6289 GNULIB_ATOLL=0;
6290 GNULIB_CALLOC_POSIX=0;
6291 GNULIB_CANONICALIZE_FILE_NAME=0;
6292 GNULIB_GETLOADAVG=0;
6293 GNULIB_GETSUBOPT=0;
6294 GNULIB_GRANTPT=0;
6295 GNULIB_MALLOC_POSIX=0;
6296 GNULIB_MBTOWC=0;
6297 GNULIB_MKDTEMP=0;
6298 GNULIB_MKOSTEMP=0;
6299 GNULIB_MKOSTEMPS=0;
6300 GNULIB_MKSTEMP=0;
6301 GNULIB_MKSTEMPS=0;
6302 GNULIB_POSIX_OPENPT=0;
6303 GNULIB_PTSNAME=0;
6304 GNULIB_PTSNAME_R=0;
6305 GNULIB_PUTENV=0;
6306 GNULIB_QSORT_R=0;
6307 GNULIB_RANDOM=0;
6308 GNULIB_RANDOM_R=0;
6309 GNULIB_REALLOC_POSIX=0;
6310 GNULIB_REALPATH=0;
6311 GNULIB_RPMATCH=0;
6312 GNULIB_SECURE_GETENV=0;
6313 GNULIB_SETENV=0;
6314 GNULIB_STRTOD=0;
6315 GNULIB_STRTOLL=0;
6316 GNULIB_STRTOULL=0;
6317 GNULIB_SYSTEM_POSIX=0;
6318 GNULIB_UNLOCKPT=0;
6319 GNULIB_UNSETENV=0;
6320 GNULIB_WCTOMB=0;
6321 HAVE__EXIT=1;
6322 HAVE_ATOLL=1;
6323 HAVE_CANONICALIZE_FILE_NAME=1;
6324 HAVE_DECL_GETLOADAVG=1;
6325 HAVE_GETSUBOPT=1;
6326 HAVE_GRANTPT=1;
6327 HAVE_MKDTEMP=1;
6328 HAVE_MKOSTEMP=1;
6329 HAVE_MKOSTEMPS=1;
6330 HAVE_MKSTEMP=1;
6331 HAVE_MKSTEMPS=1;
6332 HAVE_POSIX_OPENPT=1;
6333 HAVE_PTSNAME=1;
6334 HAVE_PTSNAME_R=1;
6335 HAVE_QSORT_R=1;
6336 HAVE_RANDOM=1;
6337 HAVE_RANDOM_H=1;
6338 HAVE_RANDOM_R=1;
6339 HAVE_REALPATH=1;
6340 HAVE_RPMATCH=1;
6341 HAVE_SECURE_GETENV=1;
6342 HAVE_SETENV=1;
6343 HAVE_DECL_SETENV=1;
6344 HAVE_STRTOD=1;
6345 HAVE_STRTOLL=1;
6346 HAVE_STRTOULL=1;
6347 HAVE_STRUCT_RANDOM_DATA=1;
6348 HAVE_SYS_LOADAVG_H=0;
6349 HAVE_UNLOCKPT=1;
6350 HAVE_DECL_UNSETENV=1;
6351 REPLACE_CALLOC=0;
6352 REPLACE_CANONICALIZE_FILE_NAME=0;
6353 REPLACE_MALLOC=0;
6354 REPLACE_MBTOWC=0;
6355 REPLACE_MKSTEMP=0;
6356 REPLACE_PTSNAME=0;
6357 REPLACE_PTSNAME_R=0;
6358 REPLACE_PUTENV=0;
6359 REPLACE_QSORT_R=0;
6360 REPLACE_RANDOM_R=0;
6361 REPLACE_REALLOC=0;
6362 REPLACE_REALPATH=0;
6363 REPLACE_SETENV=0;
6364 REPLACE_STRTOD=0;
6365 REPLACE_UNSETENV=0;
6366 REPLACE_WCTOMB=0;
6367
6368
6369
6370
6371 for ac_func in $ac_func_list
6372 do :
6373 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
6374 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
6375 eval as_val=\$$as_ac_var
6376 if test "x$as_val" = x""yes; then :
6377 cat >>confdefs.h <<_ACEOF
6378 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
6379 _ACEOF
6380
6381 fi
6382 done
6383
6384
6385
6386
6387
6388
6389
6390
6391
6392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether // is distinct from /" >&5
6393 $as_echo_n "checking whether // is distinct from /... " >&6; }
6394 if test "${gl_cv_double_slash_root+set}" = set; then :
6395 $as_echo_n "(cached) " >&6
6396 else
6397 if test x"$cross_compiling" = xyes ; then
6398 # When cross-compiling, there is no way to tell whether // is special
6399 # short of a list of hosts. However, the only known hosts to date
6400 # that have a distinct // are Apollo DomainOS (too old to port to),
6401 # Cygwin, and z/OS. If anyone knows of another system for which // has
6402 # special semantics and is distinct from /, please report it to
6403 # <bug-gnulib@gnu.org>.
6404 case $host in
6405 *-cygwin | i370-ibm-openedition)
6406 gl_cv_double_slash_root=yes ;;
6407 *)
6408 # Be optimistic and assume that / and // are the same when we
6409 # don't know.
6410 gl_cv_double_slash_root='unknown, assuming no' ;;
6411 esac
6412 else
6413 set x `ls -di / // 2>/dev/null`
6414 if test "$2" = "$4" && wc //dev/null >/dev/null 2>&1; then
6415 gl_cv_double_slash_root=no
6416 else
6417 gl_cv_double_slash_root=yes
6418 fi
6419 fi
6420 fi
6421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_double_slash_root" >&5
6422 $as_echo "$gl_cv_double_slash_root" >&6; }
6423 if test "$gl_cv_double_slash_root" = yes; then
6424
6425 $as_echo "#define DOUBLE_SLASH_IS_DISTINCT_ROOT 1" >>confdefs.h
6426
6427 fi
6428
6429
6430
6431
6432
6433 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether realpath works" >&5
6434 $as_echo_n "checking whether realpath works... " >&6; }
6435 if test "${gl_cv_func_realpath_works+set}" = set; then :
6436 $as_echo_n "(cached) " >&6
6437 else
6438
6439 touch conftest.a
6440 mkdir conftest.d
6441 if test "$cross_compiling" = yes; then :
6442 case "$host_os" in
6443 # Guess yes on glibc systems.
6444 *-gnu* | gnu*) gl_cv_func_realpath_works="guessing yes" ;;
6445 # If we don't know, assume the worst.
6446 *) gl_cv_func_realpath_works="guessing no" ;;
6447 esac
6448
6449 else
6450 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6451 /* end confdefs.h. */
6452
6453
6454
6455 #include <stdlib.h>
6456 #if defined __MACH__ && defined __APPLE__
6457 /* Avoid a crash on Mac OS X. */
6458 #include <mach/mach.h>
6459 #include <mach/mach_error.h>
6460 #include <mach/thread_status.h>
6461 #include <mach/exception.h>
6462 #include <mach/task.h>
6463 #include <pthread.h>
6464 /* The exception port on which our thread listens. */
6465 static mach_port_t our_exception_port;
6466 /* The main function of the thread listening for exceptions of type
6467 EXC_BAD_ACCESS. */
6468 static void *
6469 mach_exception_thread (void *arg)
6470 {
6471 /* Buffer for a message to be received. */
6472 struct {
6473 mach_msg_header_t head;
6474 mach_msg_body_t msgh_body;
6475 char data[1024];
6476 } msg;
6477 mach_msg_return_t retval;
6478 /* Wait for a message on the exception port. */
6479 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
6480 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
6481 if (retval != MACH_MSG_SUCCESS)
6482 abort ();
6483 exit (1);
6484 }
6485 static void
6486 nocrash_init (void)
6487 {
6488 mach_port_t self = mach_task_self ();
6489 /* Allocate a port on which the thread shall listen for exceptions. */
6490 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
6491 == KERN_SUCCESS) {
6492 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
6493 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
6494 MACH_MSG_TYPE_MAKE_SEND)
6495 == KERN_SUCCESS) {
6496 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
6497 for us. */
6498 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
6499 /* Create the thread listening on the exception port. */
6500 pthread_attr_t attr;
6501 pthread_t thread;
6502 if (pthread_attr_init (&attr) == 0
6503 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
6504 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
6505 pthread_attr_destroy (&attr);
6506 /* Replace the exception port info for these exceptions with our own.
6507 Note that we replace the exception port for the entire task, not only
6508 for a particular thread. This has the effect that when our exception
6509 port gets the message, the thread specific exception port has already
6510 been asked, and we don't need to bother about it.
6511 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
6512 task_set_exception_ports (self, mask, our_exception_port,
6513 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
6514 }
6515 }
6516 }
6517 }
6518 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
6519 /* Avoid a crash on native Windows. */
6520 #define WIN32_LEAN_AND_MEAN
6521 #include <windows.h>
6522 #include <winerror.h>
6523 static LONG WINAPI
6524 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
6525 {
6526 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
6527 {
6528 case EXCEPTION_ACCESS_VIOLATION:
6529 case EXCEPTION_IN_PAGE_ERROR:
6530 case EXCEPTION_STACK_OVERFLOW:
6531 case EXCEPTION_GUARD_PAGE:
6532 case EXCEPTION_PRIV_INSTRUCTION:
6533 case EXCEPTION_ILLEGAL_INSTRUCTION:
6534 case EXCEPTION_DATATYPE_MISALIGNMENT:
6535 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
6536 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
6537 exit (1);
6538 }
6539 return EXCEPTION_CONTINUE_SEARCH;
6540 }
6541 static void
6542 nocrash_init (void)
6543 {
6544 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
6545 }
6546 #else
6547 /* Avoid a crash on POSIX systems. */
6548 #include <signal.h>
6549 #include <unistd.h>
6550 /* A POSIX signal handler. */
6551 static void
6552 exception_handler (int sig)
6553 {
6554 _exit (1);
6555 }
6556 static void
6557 nocrash_init (void)
6558 {
6559 #ifdef SIGSEGV
6560 signal (SIGSEGV, exception_handler);
6561 #endif
6562 #ifdef SIGBUS
6563 signal (SIGBUS, exception_handler);
6564 #endif
6565 }
6566 #endif
6567
6568 #include <stdlib.h>
6569 #include <string.h>
6570
6571 int
6572 main ()
6573 {
6574
6575 int result = 0;
6576 {
6577 char *name = realpath ("conftest.a", NULL);
6578 if (!(name && *name == '/'))
6579 result |= 1;
6580 free (name);
6581 }
6582 {
6583 char *name = realpath ("conftest.b/../conftest.a", NULL);
6584 if (name != NULL)
6585 result |= 2;
6586 free (name);
6587 }
6588 {
6589 char *name = realpath ("conftest.a/", NULL);
6590 if (name != NULL)
6591 result |= 4;
6592 free (name);
6593 }
6594 {
6595 char *name1 = realpath (".", NULL);
6596 char *name2 = realpath ("conftest.d//./..", NULL);
6597 if (! name1 || ! name2 || strcmp (name1, name2))
6598 result |= 8;
6599 free (name1);
6600 free (name2);
6601 }
6602 return result;
6603
6604 ;
6605 return 0;
6606 }
6607
6608 _ACEOF
6609 if ac_fn_c_try_run "$LINENO"; then :
6610 gl_cv_func_realpath_works=yes
6611 else
6612 gl_cv_func_realpath_works=no
6613 fi
6614 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6615 conftest.$ac_objext conftest.beam conftest.$ac_ext
6616 fi
6617
6618 rm -rf conftest.a conftest.d
6619
6620 fi
6621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_realpath_works" >&5
6622 $as_echo "$gl_cv_func_realpath_works" >&6; }
6623 case "$gl_cv_func_realpath_works" in
6624 *yes)
6625
6626 $as_echo "#define FUNC_REALPATH_WORKS 1" >>confdefs.h
6627
6628 ;;
6629 esac
6630
6631
6632
6633
6634 for ac_header in $ac_header_list
6635 do :
6636 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6637 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6638 "
6639 eval as_val=\$$as_ac_Header
6640 if test "x$as_val" = x""yes; then :
6641 cat >>confdefs.h <<_ACEOF
6642 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6643 _ACEOF
6644
6645 fi
6646
6647 done
6648
6649
6650
6651
6652
6653
6654
6655
6656
6657
6658
6659 GNULIB_CHDIR=0;
6660 GNULIB_CHOWN=0;
6661 GNULIB_CLOSE=0;
6662 GNULIB_DUP=0;
6663 GNULIB_DUP2=0;
6664 GNULIB_DUP3=0;
6665 GNULIB_ENVIRON=0;
6666 GNULIB_EUIDACCESS=0;
6667 GNULIB_FACCESSAT=0;
6668 GNULIB_FCHDIR=0;
6669 GNULIB_FCHOWNAT=0;
6670 GNULIB_FDATASYNC=0;
6671 GNULIB_FSYNC=0;
6672 GNULIB_FTRUNCATE=0;
6673 GNULIB_GETCWD=0;
6674 GNULIB_GETDOMAINNAME=0;
6675 GNULIB_GETDTABLESIZE=0;
6676 GNULIB_GETGROUPS=0;
6677 GNULIB_GETHOSTNAME=0;
6678 GNULIB_GETLOGIN=0;
6679 GNULIB_GETLOGIN_R=0;
6680 GNULIB_GETPAGESIZE=0;
6681 GNULIB_GETUSERSHELL=0;
6682 GNULIB_GROUP_MEMBER=0;
6683 GNULIB_ISATTY=0;
6684 GNULIB_LCHOWN=0;
6685 GNULIB_LINK=0;
6686 GNULIB_LINKAT=0;
6687 GNULIB_LSEEK=0;
6688 GNULIB_PIPE=0;
6689 GNULIB_PIPE2=0;
6690 GNULIB_PREAD=0;
6691 GNULIB_PWRITE=0;
6692 GNULIB_READ=0;
6693 GNULIB_READLINK=0;
6694 GNULIB_READLINKAT=0;
6695 GNULIB_RMDIR=0;
6696 GNULIB_SETHOSTNAME=0;
6697 GNULIB_SLEEP=0;
6698 GNULIB_SYMLINK=0;
6699 GNULIB_SYMLINKAT=0;
6700 GNULIB_TTYNAME_R=0;
6701 GNULIB_UNISTD_H_NONBLOCKING=0;
6702 GNULIB_UNISTD_H_SIGPIPE=0;
6703 GNULIB_UNLINK=0;
6704 GNULIB_UNLINKAT=0;
6705 GNULIB_USLEEP=0;
6706 GNULIB_WRITE=0;
6707 HAVE_CHOWN=1;
6708 HAVE_DUP2=1;
6709 HAVE_DUP3=1;
6710 HAVE_EUIDACCESS=1;
6711 HAVE_FACCESSAT=1;
6712 HAVE_FCHDIR=1;
6713 HAVE_FCHOWNAT=1;
6714 HAVE_FDATASYNC=1;
6715 HAVE_FSYNC=1;
6716 HAVE_FTRUNCATE=1;
6717 HAVE_GETDTABLESIZE=1;
6718 HAVE_GETGROUPS=1;
6719 HAVE_GETHOSTNAME=1;
6720 HAVE_GETLOGIN=1;
6721 HAVE_GETPAGESIZE=1;
6722 HAVE_GROUP_MEMBER=1;
6723 HAVE_LCHOWN=1;
6724 HAVE_LINK=1;
6725 HAVE_LINKAT=1;
6726 HAVE_PIPE=1;
6727 HAVE_PIPE2=1;
6728 HAVE_PREAD=1;
6729 HAVE_PWRITE=1;
6730 HAVE_READLINK=1;
6731 HAVE_READLINKAT=1;
6732 HAVE_SETHOSTNAME=1;
6733 HAVE_SLEEP=1;
6734 HAVE_SYMLINK=1;
6735 HAVE_SYMLINKAT=1;
6736 HAVE_UNLINKAT=1;
6737 HAVE_USLEEP=1;
6738 HAVE_DECL_ENVIRON=1;
6739 HAVE_DECL_FCHDIR=1;
6740 HAVE_DECL_FDATASYNC=1;
6741 HAVE_DECL_GETDOMAINNAME=1;
6742 HAVE_DECL_GETLOGIN_R=1;
6743 HAVE_DECL_GETPAGESIZE=1;
6744 HAVE_DECL_GETUSERSHELL=1;
6745 HAVE_DECL_SETHOSTNAME=1;
6746 HAVE_DECL_TTYNAME_R=1;
6747 HAVE_OS_H=0;
6748 HAVE_SYS_PARAM_H=0;
6749 REPLACE_CHOWN=0;
6750 REPLACE_CLOSE=0;
6751 REPLACE_DUP=0;
6752 REPLACE_DUP2=0;
6753 REPLACE_FCHOWNAT=0;
6754 REPLACE_FTRUNCATE=0;
6755 REPLACE_GETCWD=0;
6756 REPLACE_GETDOMAINNAME=0;
6757 REPLACE_GETDTABLESIZE=0;
6758 REPLACE_GETLOGIN_R=0;
6759 REPLACE_GETGROUPS=0;
6760 REPLACE_GETPAGESIZE=0;
6761 REPLACE_ISATTY=0;
6762 REPLACE_LCHOWN=0;
6763 REPLACE_LINK=0;
6764 REPLACE_LINKAT=0;
6765 REPLACE_LSEEK=0;
6766 REPLACE_PREAD=0;
6767 REPLACE_PWRITE=0;
6768 REPLACE_READ=0;
6769 REPLACE_READLINK=0;
6770 REPLACE_READLINKAT=0;
6771 REPLACE_RMDIR=0;
6772 REPLACE_SLEEP=0;
6773 REPLACE_SYMLINK=0;
6774 REPLACE_SYMLINKAT=0;
6775 REPLACE_TTYNAME_R=0;
6776 REPLACE_UNLINK=0;
6777 REPLACE_UNLINKAT=0;
6778 REPLACE_USLEEP=0;
6779 REPLACE_WRITE=0;
6780 UNISTD_H_HAVE_WINSOCK2_H=0;
6781 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
6782
6783
6784
6785
6786
6787
6788
6789
6790
6791
6792
6793 if test $ac_cv_func__set_invalid_parameter_handler = yes; then
6794 HAVE_MSVC_INVALID_PARAMETER_HANDLER=1
6795
6796 $as_echo "#define HAVE_MSVC_INVALID_PARAMETER_HANDLER 1" >>confdefs.h
6797
6798 else
6799 HAVE_MSVC_INVALID_PARAMETER_HANDLER=0
6800 fi
6801
6802
6803
6804
6805
6806
6807
6808 GNULIB_OPENDIR=0;
6809 GNULIB_READDIR=0;
6810 GNULIB_REWINDDIR=0;
6811 GNULIB_CLOSEDIR=0;
6812 GNULIB_DIRFD=0;
6813 GNULIB_FDOPENDIR=0;
6814 GNULIB_SCANDIR=0;
6815 GNULIB_ALPHASORT=0;
6816 HAVE_OPENDIR=1;
6817 HAVE_READDIR=1;
6818 HAVE_REWINDDIR=1;
6819 HAVE_CLOSEDIR=1;
6820 HAVE_DECL_DIRFD=1;
6821 HAVE_DECL_FDOPENDIR=1;
6822 HAVE_FDOPENDIR=1;
6823 HAVE_SCANDIR=1;
6824 HAVE_ALPHASORT=1;
6825 REPLACE_OPENDIR=0;
6826 REPLACE_CLOSEDIR=0;
6827 REPLACE_DIRFD=0;
6828 REPLACE_FDOPENDIR=0;
6829
6830
6831
6832 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
6833 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
6834 if test "${gl_cv_have_include_next+set}" = set; then :
6835 $as_echo_n "(cached) " >&6
6836 else
6837 rm -rf conftestd1a conftestd1b conftestd2
6838 mkdir conftestd1a conftestd1b conftestd2
6839 cat <<EOF > conftestd1a/conftest.h
6840 #define DEFINED_IN_CONFTESTD1
6841 #include_next <conftest.h>
6842 #ifdef DEFINED_IN_CONFTESTD2
6843 int foo;
6844 #else
6845 #error "include_next doesn't work"
6846 #endif
6847 EOF
6848 cat <<EOF > conftestd1b/conftest.h
6849 #define DEFINED_IN_CONFTESTD1
6850 #include <stdio.h>
6851 #include_next <conftest.h>
6852 #ifdef DEFINED_IN_CONFTESTD2
6853 int foo;
6854 #else
6855 #error "include_next doesn't work"
6856 #endif
6857 EOF
6858 cat <<EOF > conftestd2/conftest.h
6859 #ifndef DEFINED_IN_CONFTESTD1
6860 #error "include_next test doesn't work"
6861 #endif
6862 #define DEFINED_IN_CONFTESTD2
6863 EOF
6864 gl_save_CPPFLAGS="$CPPFLAGS"
6865 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
6866 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6867 /* end confdefs.h. */
6868 #include <conftest.h>
6869 _ACEOF
6870 if ac_fn_c_try_compile "$LINENO"; then :
6871 gl_cv_have_include_next=yes
6872 else
6873 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
6874 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6875 /* end confdefs.h. */
6876 #include <conftest.h>
6877 _ACEOF
6878 if ac_fn_c_try_compile "$LINENO"; then :
6879 gl_cv_have_include_next=buggy
6880 else
6881 gl_cv_have_include_next=no
6882 fi
6883 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6884
6885 fi
6886 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6887 CPPFLAGS="$gl_save_CPPFLAGS"
6888 rm -rf conftestd1a conftestd1b conftestd2
6889
6890 fi
6891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
6892 $as_echo "$gl_cv_have_include_next" >&6; }
6893 PRAGMA_SYSTEM_HEADER=
6894 if test $gl_cv_have_include_next = yes; then
6895 INCLUDE_NEXT=include_next
6896 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
6897 if test -n "$GCC"; then
6898 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
6899 fi
6900 else
6901 if test $gl_cv_have_include_next = buggy; then
6902 INCLUDE_NEXT=include
6903 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
6904 else
6905 INCLUDE_NEXT=include
6906 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
6907 fi
6908 fi
6909
6910
6911
6912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
6913 $as_echo_n "checking whether system header files limit the line length... " >&6; }
6914 if test "${gl_cv_pragma_columns+set}" = set; then :
6915 $as_echo_n "(cached) " >&6
6916 else
6917 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6918 /* end confdefs.h. */
6919
6920 #ifdef __TANDEM
6921 choke me
6922 #endif
6923
6924 _ACEOF
6925 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6926 $EGREP "choke me" >/dev/null 2>&1; then :
6927 gl_cv_pragma_columns=yes
6928 else
6929 gl_cv_pragma_columns=no
6930 fi
6931 rm -f conftest*
6932
6933
6934 fi
6935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
6936 $as_echo "$gl_cv_pragma_columns" >&6; }
6937 if test $gl_cv_pragma_columns = yes; then
6938 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
6939 else
6940 PRAGMA_COLUMNS=
6941 fi
6942
6943
6944
6945
6946
6947
6948
6949
6950
6951
6952
6953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
6954 $as_echo_n "checking if environ is properly declared... " >&6; }
6955 if test "${gt_cv_var_environ_declaration+set}" = set; then :
6956 $as_echo_n "(cached) " >&6
6957 else
6958
6959 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6960 /* end confdefs.h. */
6961 #if HAVE_UNISTD_H
6962 #include <unistd.h>
6963 #endif
6964 /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
6965 #include <stdlib.h>
6966
6967 extern struct { int foo; } environ;
6968 int
6969 main ()
6970 {
6971 environ.foo = 1;
6972 ;
6973 return 0;
6974 }
6975 _ACEOF
6976 if ac_fn_c_try_compile "$LINENO"; then :
6977 gt_cv_var_environ_declaration=no
6978 else
6979 gt_cv_var_environ_declaration=yes
6980 fi
6981 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6982 fi
6983
6984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
6985 $as_echo "$gt_cv_var_environ_declaration" >&6; }
6986 if test $gt_cv_var_environ_declaration = yes; then
6987
6988 $as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
6989
6990 fi
6991
6992
6993 if test $gt_cv_var_environ_declaration != yes; then
6994 HAVE_DECL_ENVIRON=0
6995 fi
6996
6997
6998
6999 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for complete errno.h" >&5
7000 $as_echo_n "checking for complete errno.h... " >&6; }
7001 if test "${gl_cv_header_errno_h_complete+set}" = set; then :
7002 $as_echo_n "(cached) " >&6
7003 else
7004
7005 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7006 /* end confdefs.h. */
7007
7008 #include <errno.h>
7009 #if !defined ETXTBSY
7010 booboo
7011 #endif
7012 #if !defined ENOMSG
7013 booboo
7014 #endif
7015 #if !defined EIDRM
7016 booboo
7017 #endif
7018 #if !defined ENOLINK
7019 booboo
7020 #endif
7021 #if !defined EPROTO
7022 booboo
7023 #endif
7024 #if !defined EMULTIHOP
7025 booboo
7026 #endif
7027 #if !defined EBADMSG
7028 booboo
7029 #endif
7030 #if !defined EOVERFLOW
7031 booboo
7032 #endif
7033 #if !defined ENOTSUP
7034 booboo
7035 #endif
7036 #if !defined ENETRESET
7037 booboo
7038 #endif
7039 #if !defined ECONNABORTED
7040 booboo
7041 #endif
7042 #if !defined ESTALE
7043 booboo
7044 #endif
7045 #if !defined EDQUOT
7046 booboo
7047 #endif
7048 #if !defined ECANCELED
7049 booboo
7050 #endif
7051 #if !defined EOWNERDEAD
7052 booboo
7053 #endif
7054 #if !defined ENOTRECOVERABLE
7055 booboo
7056 #endif
7057 #if !defined EILSEQ
7058 booboo
7059 #endif
7060
7061 _ACEOF
7062 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7063 $EGREP "booboo" >/dev/null 2>&1; then :
7064 gl_cv_header_errno_h_complete=no
7065 else
7066 gl_cv_header_errno_h_complete=yes
7067 fi
7068 rm -f conftest*
7069
7070
7071 fi
7072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_complete" >&5
7073 $as_echo "$gl_cv_header_errno_h_complete" >&6; }
7074 if test $gl_cv_header_errno_h_complete = yes; then
7075 ERRNO_H=''
7076 else
7077
7078
7079
7080
7081
7082
7083
7084
7085 if test $gl_cv_have_include_next = yes; then
7086 gl_cv_next_errno_h='<'errno.h'>'
7087 else
7088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <errno.h>" >&5
7089 $as_echo_n "checking absolute name of <errno.h>... " >&6; }
7090 if test "${gl_cv_next_errno_h+set}" = set; then :
7091 $as_echo_n "(cached) " >&6
7092 else
7093
7094
7095
7096 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7097 /* end confdefs.h. */
7098 #include <errno.h>
7099 _ACEOF
7100 case "$host_os" in
7101 aix*) gl_absname_cpp="$ac_cpp -C" ;;
7102 *) gl_absname_cpp="$ac_cpp" ;;
7103 esac
7104
7105 case "$host_os" in
7106 mingw*)
7107 gl_dirsep_regex='[/\\]'
7108 ;;
7109 *)
7110 gl_dirsep_regex='\/'
7111 ;;
7112 esac
7113 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
7114 gl_header_literal_regex=`echo 'errno.h' \
7115 | sed -e "$gl_make_literal_regex_sed"`
7116 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
7117 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
7118 s|^/[^/]|//&|
7119 p
7120 q
7121 }'
7122
7123 gl_cv_absolute_errno_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
7124 sed -n "$gl_absolute_header_sed"`
7125
7126 gl_header=$gl_cv_absolute_errno_h
7127 gl_cv_next_errno_h='"'$gl_header'"'
7128
7129
7130 fi
7131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_errno_h" >&5
7132 $as_echo "$gl_cv_next_errno_h" >&6; }
7133 fi
7134 NEXT_ERRNO_H=$gl_cv_next_errno_h
7135
7136 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
7137 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
7138 gl_next_as_first_directive='<'errno.h'>'
7139 else
7140 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
7141 gl_next_as_first_directive=$gl_cv_next_errno_h
7142 fi
7143 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H=$gl_next_as_first_directive
7144
7145
7146
7147
7148 ERRNO_H='errno.h'
7149 fi
7150
7151 if test -n "$ERRNO_H"; then
7152 GL_GENERATE_ERRNO_H_TRUE=
7153 GL_GENERATE_ERRNO_H_FALSE='#'
7154 else
7155 GL_GENERATE_ERRNO_H_TRUE='#'
7156 GL_GENERATE_ERRNO_H_FALSE=
7157 fi
7158
7159
7160 if test -n "$ERRNO_H"; then
7161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EMULTIHOP value" >&5
7162 $as_echo_n "checking for EMULTIHOP value... " >&6; }
7163 if test "${gl_cv_header_errno_h_EMULTIHOP+set}" = set; then :
7164 $as_echo_n "(cached) " >&6
7165 else
7166
7167 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7168 /* end confdefs.h. */
7169
7170 #include <errno.h>
7171 #ifdef EMULTIHOP
7172 yes
7173 #endif
7174
7175 _ACEOF
7176 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7177 $EGREP "yes" >/dev/null 2>&1; then :
7178 gl_cv_header_errno_h_EMULTIHOP=yes
7179 else
7180 gl_cv_header_errno_h_EMULTIHOP=no
7181 fi
7182 rm -f conftest*
7183
7184 if test $gl_cv_header_errno_h_EMULTIHOP = no; then
7185 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7186 /* end confdefs.h. */
7187
7188 #define _XOPEN_SOURCE_EXTENDED 1
7189 #include <errno.h>
7190 #ifdef EMULTIHOP
7191 yes
7192 #endif
7193
7194 _ACEOF
7195 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7196 $EGREP "yes" >/dev/null 2>&1; then :
7197 gl_cv_header_errno_h_EMULTIHOP=hidden
7198 fi
7199 rm -f conftest*
7200
7201 if test $gl_cv_header_errno_h_EMULTIHOP = hidden; then
7202 if ac_fn_c_compute_int "$LINENO" "EMULTIHOP" "gl_cv_header_errno_h_EMULTIHOP" "
7203 #define _XOPEN_SOURCE_EXTENDED 1
7204 #include <errno.h>
7205 /* The following two lines are a workaround against an autoconf-2.52 bug. */
7206 #include <stdio.h>
7207 #include <stdlib.h>
7208 "; then :
7209
7210 fi
7211
7212 fi
7213 fi
7214
7215 fi
7216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EMULTIHOP" >&5
7217 $as_echo "$gl_cv_header_errno_h_EMULTIHOP" >&6; }
7218 case $gl_cv_header_errno_h_EMULTIHOP in
7219 yes | no)
7220 EMULTIHOP_HIDDEN=0; EMULTIHOP_VALUE=
7221 ;;
7222 *)
7223 EMULTIHOP_HIDDEN=1; EMULTIHOP_VALUE="$gl_cv_header_errno_h_EMULTIHOP"
7224 ;;
7225 esac
7226
7227
7228 fi
7229
7230
7231 if test -n "$ERRNO_H"; then
7232 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ENOLINK value" >&5
7233 $as_echo_n "checking for ENOLINK value... " >&6; }
7234 if test "${gl_cv_header_errno_h_ENOLINK+set}" = set; then :
7235 $as_echo_n "(cached) " >&6
7236 else
7237
7238 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7239 /* end confdefs.h. */
7240
7241 #include <errno.h>
7242 #ifdef ENOLINK
7243 yes
7244 #endif
7245
7246 _ACEOF
7247 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7248 $EGREP "yes" >/dev/null 2>&1; then :
7249 gl_cv_header_errno_h_ENOLINK=yes
7250 else
7251 gl_cv_header_errno_h_ENOLINK=no
7252 fi
7253 rm -f conftest*
7254
7255 if test $gl_cv_header_errno_h_ENOLINK = no; then
7256 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7257 /* end confdefs.h. */
7258
7259 #define _XOPEN_SOURCE_EXTENDED 1
7260 #include <errno.h>
7261 #ifdef ENOLINK
7262 yes
7263 #endif
7264
7265 _ACEOF
7266 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7267 $EGREP "yes" >/dev/null 2>&1; then :
7268 gl_cv_header_errno_h_ENOLINK=hidden
7269 fi
7270 rm -f conftest*
7271
7272 if test $gl_cv_header_errno_h_ENOLINK = hidden; then
7273 if ac_fn_c_compute_int "$LINENO" "ENOLINK" "gl_cv_header_errno_h_ENOLINK" "
7274 #define _XOPEN_SOURCE_EXTENDED 1
7275 #include <errno.h>
7276 /* The following two lines are a workaround against an autoconf-2.52 bug. */
7277 #include <stdio.h>
7278 #include <stdlib.h>
7279 "; then :
7280
7281 fi
7282
7283 fi
7284 fi
7285
7286 fi
7287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_ENOLINK" >&5
7288 $as_echo "$gl_cv_header_errno_h_ENOLINK" >&6; }
7289 case $gl_cv_header_errno_h_ENOLINK in
7290 yes | no)
7291 ENOLINK_HIDDEN=0; ENOLINK_VALUE=
7292 ;;
7293 *)
7294 ENOLINK_HIDDEN=1; ENOLINK_VALUE="$gl_cv_header_errno_h_ENOLINK"
7295 ;;
7296 esac
7297
7298
7299 fi
7300
7301
7302 if test -n "$ERRNO_H"; then
7303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EOVERFLOW value" >&5
7304 $as_echo_n "checking for EOVERFLOW value... " >&6; }
7305 if test "${gl_cv_header_errno_h_EOVERFLOW+set}" = set; then :
7306 $as_echo_n "(cached) " >&6
7307 else
7308
7309 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7310 /* end confdefs.h. */
7311
7312 #include <errno.h>
7313 #ifdef EOVERFLOW
7314 yes
7315 #endif
7316
7317 _ACEOF
7318 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7319 $EGREP "yes" >/dev/null 2>&1; then :
7320 gl_cv_header_errno_h_EOVERFLOW=yes
7321 else
7322 gl_cv_header_errno_h_EOVERFLOW=no
7323 fi
7324 rm -f conftest*
7325
7326 if test $gl_cv_header_errno_h_EOVERFLOW = no; then
7327 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7328 /* end confdefs.h. */
7329
7330 #define _XOPEN_SOURCE_EXTENDED 1
7331 #include <errno.h>
7332 #ifdef EOVERFLOW
7333 yes
7334 #endif
7335
7336 _ACEOF
7337 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7338 $EGREP "yes" >/dev/null 2>&1; then :
7339 gl_cv_header_errno_h_EOVERFLOW=hidden
7340 fi
7341 rm -f conftest*
7342
7343 if test $gl_cv_header_errno_h_EOVERFLOW = hidden; then
7344 if ac_fn_c_compute_int "$LINENO" "EOVERFLOW" "gl_cv_header_errno_h_EOVERFLOW" "
7345 #define _XOPEN_SOURCE_EXTENDED 1
7346 #include <errno.h>
7347 /* The following two lines are a workaround against an autoconf-2.52 bug. */
7348 #include <stdio.h>
7349 #include <stdlib.h>
7350 "; then :
7351
7352 fi
7353
7354 fi
7355 fi
7356
7357 fi
7358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EOVERFLOW" >&5
7359 $as_echo "$gl_cv_header_errno_h_EOVERFLOW" >&6; }
7360 case $gl_cv_header_errno_h_EOVERFLOW in
7361 yes | no)
7362 EOVERFLOW_HIDDEN=0; EOVERFLOW_VALUE=
7363 ;;
7364 *)
7365 EOVERFLOW_HIDDEN=1; EOVERFLOW_VALUE="$gl_cv_header_errno_h_EOVERFLOW"
7366 ;;
7367 esac
7368
7369
7370 fi
7371
7372
7373 ac_fn_c_check_decl "$LINENO" "strerror_r" "ac_cv_have_decl_strerror_r" "$ac_includes_default"
7374 if test "x$ac_cv_have_decl_strerror_r" = x""yes; then :
7375 ac_have_decl=1
7376 else
7377 ac_have_decl=0
7378 fi
7379
7380 cat >>confdefs.h <<_ACEOF
7381 #define HAVE_DECL_STRERROR_R $ac_have_decl
7382 _ACEOF
7383
7384 for ac_func in strerror_r
7385 do :
7386 ac_fn_c_check_func "$LINENO" "strerror_r" "ac_cv_func_strerror_r"
7387 if test "x$ac_cv_func_strerror_r" = x""yes; then :
7388 cat >>confdefs.h <<_ACEOF
7389 #define HAVE_STRERROR_R 1
7390 _ACEOF
7391
7392 fi
7393 done
7394
7395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror_r returns char *" >&5
7396 $as_echo_n "checking whether strerror_r returns char *... " >&6; }
7397 if test "${ac_cv_func_strerror_r_char_p+set}" = set; then :
7398 $as_echo_n "(cached) " >&6
7399 else
7400
7401 ac_cv_func_strerror_r_char_p=no
7402 if test $ac_cv_have_decl_strerror_r = yes; then
7403 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7404 /* end confdefs.h. */
7405 $ac_includes_default
7406 int
7407 main ()
7408 {
7409
7410 char buf[100];
7411 char x = *strerror_r (0, buf, sizeof buf);
7412 char *p = strerror_r (0, buf, sizeof buf);
7413 return !p || x;
7414
7415 ;
7416 return 0;
7417 }
7418 _ACEOF
7419 if ac_fn_c_try_compile "$LINENO"; then :
7420 ac_cv_func_strerror_r_char_p=yes
7421 fi
7422 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7423 else
7424 # strerror_r is not declared. Choose between
7425 # systems that have relatively inaccessible declarations for the
7426 # function. BeOS and DEC UNIX 4.0 fall in this category, but the
7427 # former has a strerror_r that returns char*, while the latter
7428 # has a strerror_r that returns `int'.
7429 # This test should segfault on the DEC system.
7430 if test "$cross_compiling" = yes; then :
7431 :
7432 else
7433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7434 /* end confdefs.h. */
7435 $ac_includes_default
7436 extern char *strerror_r ();
7437 int
7438 main ()
7439 {
7440 char buf[100];
7441 char x = *strerror_r (0, buf, sizeof buf);
7442 return ! isalpha (x);
7443 ;
7444 return 0;
7445 }
7446 _ACEOF
7447 if ac_fn_c_try_run "$LINENO"; then :
7448 ac_cv_func_strerror_r_char_p=yes
7449 fi
7450 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7451 conftest.$ac_objext conftest.beam conftest.$ac_ext
7452 fi
7453
7454 fi
7455
7456 fi
7457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strerror_r_char_p" >&5
7458 $as_echo "$ac_cv_func_strerror_r_char_p" >&6; }
7459 if test $ac_cv_func_strerror_r_char_p = yes; then
7460
7461 $as_echo "#define STRERROR_R_CHAR_P 1" >>confdefs.h
7462
7463 fi
7464
7465
7466
7467
7468 ac_fn_c_check_decl "$LINENO" "fchdir" "ac_cv_have_decl_fchdir" "$ac_includes_default"
7469 if test "x$ac_cv_have_decl_fchdir" = x""yes; then :
7470 ac_have_decl=1
7471 else
7472 ac_have_decl=0
7473 fi
7474
7475 cat >>confdefs.h <<_ACEOF
7476 #define HAVE_DECL_FCHDIR $ac_have_decl
7477 _ACEOF
7478
7479
7480 GNULIB_FCNTL=0;
7481 GNULIB_NONBLOCKING=0;
7482 GNULIB_OPEN=0;
7483 GNULIB_OPENAT=0;
7484 HAVE_FCNTL=1;
7485 HAVE_OPENAT=1;
7486 REPLACE_FCNTL=0;
7487 REPLACE_OPEN=0;
7488 REPLACE_OPENAT=0;
7489
7490
7491
7492
7493
7494
7495
7496
7497
7498
7499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fcntl.h" >&5
7500 $as_echo_n "checking for working fcntl.h... " >&6; }
7501 if test "${gl_cv_header_working_fcntl_h+set}" = set; then :
7502 $as_echo_n "(cached) " >&6
7503 else
7504 if test "$cross_compiling" = yes; then :
7505 gl_cv_header_working_fcntl_h=cross-compiling
7506 else
7507 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7508 /* end confdefs.h. */
7509 #include <sys/types.h>
7510 #include <sys/stat.h>
7511 #if HAVE_UNISTD_H
7512 # include <unistd.h>
7513 #else /* on Windows with MSVC */
7514 # include <io.h>
7515 # include <stdlib.h>
7516 # defined sleep(n) _sleep ((n) * 1000)
7517 #endif
7518 #include <fcntl.h>
7519 #ifndef O_NOATIME
7520 #define O_NOATIME 0
7521 #endif
7522 #ifndef O_NOFOLLOW
7523 #define O_NOFOLLOW 0
7524 #endif
7525 static int const constants[] =
7526 {
7527 O_CREAT, O_EXCL, O_NOCTTY, O_TRUNC, O_APPEND,
7528 O_NONBLOCK, O_SYNC, O_ACCMODE, O_RDONLY, O_RDWR, O_WRONLY
7529 };
7530
7531 int
7532 main ()
7533 {
7534
7535 int result = !constants;
7536 #if HAVE_SYMLINK
7537 {
7538 static char const sym[] = "conftest.sym";
7539 if (symlink ("/dev/null", sym) != 0)
7540 result |= 2;
7541 else
7542 {
7543 int fd = open (sym, O_WRONLY | O_NOFOLLOW | O_CREAT, 0);
7544 if (fd >= 0)
7545 {
7546 close (fd);
7547 result |= 4;
7548 }
7549 }
7550 if (unlink (sym) != 0 || symlink (".", sym) != 0)
7551 result |= 2;
7552 else
7553 {
7554 int fd = open (sym, O_RDONLY | O_NOFOLLOW);
7555 if (fd >= 0)
7556 {
7557 close (fd);
7558 result |= 4;
7559 }
7560 }
7561 unlink (sym);
7562 }
7563 #endif
7564 {
7565 static char const file[] = "confdefs.h";
7566 int fd = open (file, O_RDONLY | O_NOATIME);
7567 if (fd < 0)
7568 result |= 8;
7569 else
7570 {
7571 struct stat st0;
7572 if (fstat (fd, &st0) != 0)
7573 result |= 16;
7574 else
7575 {
7576 char c;
7577 sleep (1);
7578 if (read (fd, &c, 1) != 1)
7579 result |= 24;
7580 else
7581 {
7582 if (close (fd) != 0)
7583 result |= 32;
7584 else
7585 {
7586 struct stat st1;
7587 if (stat (file, &st1) != 0)
7588 result |= 40;
7589 else
7590 if (st0.st_atime != st1.st_atime)
7591 result |= 64;
7592 }
7593 }
7594 }
7595 }
7596 }
7597 return result;
7598 ;
7599 return 0;
7600 }
7601 _ACEOF
7602 if ac_fn_c_try_run "$LINENO"; then :
7603 gl_cv_header_working_fcntl_h=yes
7604 else
7605 case $? in #(
7606 4) gl_cv_header_working_fcntl_h='no (bad O_NOFOLLOW)';; #(
7607 64) gl_cv_header_working_fcntl_h='no (bad O_NOATIME)';; #(
7608 68) gl_cv_header_working_fcntl_h='no (bad O_NOATIME, O_NOFOLLOW)';; #(
7609 *) gl_cv_header_working_fcntl_h='no';;
7610 esac
7611 fi
7612 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7613 conftest.$ac_objext conftest.beam conftest.$ac_ext
7614 fi
7615
7616 fi
7617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_fcntl_h" >&5
7618 $as_echo "$gl_cv_header_working_fcntl_h" >&6; }
7619
7620 case $gl_cv_header_working_fcntl_h in #(
7621 *O_NOATIME* | no | cross-compiling) ac_val=0;; #(
7622 *) ac_val=1;;
7623 esac
7624
7625 cat >>confdefs.h <<_ACEOF
7626 #define HAVE_WORKING_O_NOATIME $ac_val
7627 _ACEOF
7628
7629
7630 case $gl_cv_header_working_fcntl_h in #(
7631 *O_NOFOLLOW* | no | cross-compiling) ac_val=0;; #(
7632 *) ac_val=1;;
7633 esac
7634
7635 cat >>confdefs.h <<_ACEOF
7636 #define HAVE_WORKING_O_NOFOLLOW $ac_val
7637 _ACEOF
7638
7639
7640 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
7641 if test "x$ac_cv_type_pid_t" = x""yes; then :
7642
7643 else
7644
7645 cat >>confdefs.h <<_ACEOF
7646 #define pid_t int
7647 _ACEOF
7648
7649 fi
7650
7651 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
7652 if test "x$ac_cv_type_mode_t" = x""yes; then :
7653
7654 else
7655
7656 cat >>confdefs.h <<_ACEOF
7657 #define mode_t int
7658 _ACEOF
7659
7660 fi
7661
7662
7663
7664
7665
7666
7667
7668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
7669 $as_echo_n "checking for mbstate_t... " >&6; }
7670 if test "${ac_cv_type_mbstate_t+set}" = set; then :
7671 $as_echo_n "(cached) " >&6
7672 else
7673 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7674 /* end confdefs.h. */
7675 $ac_includes_default
7676 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
7677 <wchar.h>.
7678 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
7679 included before <wchar.h>. */
7680 #include <stddef.h>
7681 #include <stdio.h>
7682 #include <time.h>
7683 #include <wchar.h>
7684 int
7685 main ()
7686 {
7687 mbstate_t x; return sizeof x;
7688 ;
7689 return 0;
7690 }
7691 _ACEOF
7692 if ac_fn_c_try_compile "$LINENO"; then :
7693 ac_cv_type_mbstate_t=yes
7694 else
7695 ac_cv_type_mbstate_t=no
7696 fi
7697 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7698 fi
7699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
7700 $as_echo "$ac_cv_type_mbstate_t" >&6; }
7701 if test $ac_cv_type_mbstate_t = yes; then
7702
7703 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
7704
7705 else
7706
7707 $as_echo "#define mbstate_t int" >>confdefs.h
7708
7709 fi
7710
7711
7712
7713
7714
7715
7716
7717
7718
7719
7720
7721
7722
7723
7724
7725
7726
7727
7728 GNULIB_ACOSF=0;
7729 GNULIB_ACOSL=0;
7730 GNULIB_ASINF=0;
7731 GNULIB_ASINL=0;
7732 GNULIB_ATANF=0;
7733 GNULIB_ATANL=0;
7734 GNULIB_ATAN2F=0;
7735 GNULIB_CBRT=0;
7736 GNULIB_CBRTF=0;
7737 GNULIB_CBRTL=0;
7738 GNULIB_CEIL=0;
7739 GNULIB_CEILF=0;
7740 GNULIB_CEILL=0;
7741 GNULIB_COPYSIGN=0;
7742 GNULIB_COPYSIGNF=0;
7743 GNULIB_COPYSIGNL=0;
7744 GNULIB_COSF=0;
7745 GNULIB_COSL=0;
7746 GNULIB_COSHF=0;
7747 GNULIB_EXPF=0;
7748 GNULIB_EXPL=0;
7749 GNULIB_EXP2=0;
7750 GNULIB_EXP2F=0;
7751 GNULIB_EXP2L=0;
7752 GNULIB_EXPM1=0;
7753 GNULIB_EXPM1F=0;
7754 GNULIB_EXPM1L=0;
7755 GNULIB_FABSF=0;
7756 GNULIB_FABSL=0;
7757 GNULIB_FLOOR=0;
7758 GNULIB_FLOORF=0;
7759 GNULIB_FLOORL=0;
7760 GNULIB_FMA=0;
7761 GNULIB_FMAF=0;
7762 GNULIB_FMAL=0;
7763 GNULIB_FMOD=0;
7764 GNULIB_FMODF=0;
7765 GNULIB_FMODL=0;
7766 GNULIB_FREXPF=0;
7767 GNULIB_FREXP=0;
7768 GNULIB_FREXPL=0;
7769 GNULIB_HYPOT=0;
7770 GNULIB_HYPOTF=0;
7771 GNULIB_HYPOTL=0;
7772 GNULIB_ILOGB=0;
7773 GNULIB_ILOGBF=0;
7774 GNULIB_ILOGBL=0;
7775 GNULIB_ISFINITE=0;
7776 GNULIB_ISINF=0;
7777 GNULIB_ISNAN=0;
7778 GNULIB_ISNANF=0;
7779 GNULIB_ISNAND=0;
7780 GNULIB_ISNANL=0;
7781 GNULIB_LDEXPF=0;
7782 GNULIB_LDEXPL=0;
7783 GNULIB_LOG=0;
7784 GNULIB_LOGF=0;
7785 GNULIB_LOGL=0;
7786 GNULIB_LOG10=0;
7787 GNULIB_LOG10F=0;
7788 GNULIB_LOG10L=0;
7789 GNULIB_LOG1P=0;
7790 GNULIB_LOG1PF=0;
7791 GNULIB_LOG1PL=0;
7792 GNULIB_LOG2=0;
7793 GNULIB_LOG2F=0;
7794 GNULIB_LOG2L=0;
7795 GNULIB_LOGB=0;
7796 GNULIB_LOGBF=0;
7797 GNULIB_LOGBL=0;
7798 GNULIB_MODF=0;
7799 GNULIB_MODFF=0;
7800 GNULIB_MODFL=0;
7801 GNULIB_POWF=0;
7802 GNULIB_REMAINDER=0;
7803 GNULIB_REMAINDERF=0;
7804 GNULIB_REMAINDERL=0;
7805 GNULIB_RINT=0;
7806 GNULIB_RINTF=0;
7807 GNULIB_RINTL=0;
7808 GNULIB_ROUND=0;
7809 GNULIB_ROUNDF=0;
7810 GNULIB_ROUNDL=0;
7811 GNULIB_SIGNBIT=0;
7812 GNULIB_SINF=0;
7813 GNULIB_SINL=0;
7814 GNULIB_SINHF=0;
7815 GNULIB_SQRTF=0;
7816 GNULIB_SQRTL=0;
7817 GNULIB_TANF=0;
7818 GNULIB_TANL=0;
7819 GNULIB_TANHF=0;
7820 GNULIB_TRUNC=0;
7821 GNULIB_TRUNCF=0;
7822 GNULIB_TRUNCL=0;
7823 HAVE_ACOSF=1;
7824 HAVE_ACOSL=1;
7825 HAVE_ASINF=1;
7826 HAVE_ASINL=1;
7827 HAVE_ATANF=1;
7828 HAVE_ATANL=1;
7829 HAVE_ATAN2F=1;
7830 HAVE_CBRT=1;
7831 HAVE_CBRTF=1;
7832 HAVE_CBRTL=1;
7833 HAVE_COPYSIGN=1;
7834 HAVE_COPYSIGNL=1;
7835 HAVE_COSF=1;
7836 HAVE_COSL=1;
7837 HAVE_COSHF=1;
7838 HAVE_EXPF=1;
7839 HAVE_EXPL=1;
7840 HAVE_EXPM1=1;
7841 HAVE_EXPM1F=1;
7842 HAVE_FABSF=1;
7843 HAVE_FABSL=1;
7844 HAVE_FMA=1;
7845 HAVE_FMAF=1;
7846 HAVE_FMAL=1;
7847 HAVE_FMODF=1;
7848 HAVE_FMODL=1;
7849 HAVE_FREXPF=1;
7850 HAVE_HYPOTF=1;
7851 HAVE_HYPOTL=1;
7852 HAVE_ILOGB=1;
7853 HAVE_ILOGBF=1;
7854 HAVE_ILOGBL=1;
7855 HAVE_ISNANF=1;
7856 HAVE_ISNAND=1;
7857 HAVE_ISNANL=1;
7858 HAVE_LDEXPF=1;
7859 HAVE_LOGF=1;
7860 HAVE_LOGL=1;
7861 HAVE_LOG10F=1;
7862 HAVE_LOG10L=1;
7863 HAVE_LOG1P=1;
7864 HAVE_LOG1PF=1;
7865 HAVE_LOG1PL=1;
7866 HAVE_LOGBF=1;
7867 HAVE_LOGBL=1;
7868 HAVE_MODFF=1;
7869 HAVE_MODFL=1;
7870 HAVE_POWF=1;
7871 HAVE_REMAINDER=1;
7872 HAVE_REMAINDERF=1;
7873 HAVE_RINT=1;
7874 HAVE_RINTL=1;
7875 HAVE_SINF=1;
7876 HAVE_SINL=1;
7877 HAVE_SINHF=1;
7878 HAVE_SQRTF=1;
7879 HAVE_SQRTL=1;
7880 HAVE_TANF=1;
7881 HAVE_TANL=1;
7882 HAVE_TANHF=1;
7883 HAVE_DECL_ACOSL=1;
7884 HAVE_DECL_ASINL=1;
7885 HAVE_DECL_ATANL=1;
7886 HAVE_DECL_CBRTF=1;
7887 HAVE_DECL_CBRTL=1;
7888 HAVE_DECL_CEILF=1;
7889 HAVE_DECL_CEILL=1;
7890 HAVE_DECL_COPYSIGNF=1;
7891 HAVE_DECL_COSL=1;
7892 HAVE_DECL_EXPL=1;
7893 HAVE_DECL_EXP2=1;
7894 HAVE_DECL_EXP2F=1;
7895 HAVE_DECL_EXP2L=1;
7896 HAVE_DECL_EXPM1L=1;
7897 HAVE_DECL_FLOORF=1;
7898 HAVE_DECL_FLOORL=1;
7899 HAVE_DECL_FREXPL=1;
7900 HAVE_DECL_LDEXPL=1;
7901 HAVE_DECL_LOGL=1;
7902 HAVE_DECL_LOG10L=1;
7903 HAVE_DECL_LOG2=1;
7904 HAVE_DECL_LOG2F=1;
7905 HAVE_DECL_LOG2L=1;
7906 HAVE_DECL_LOGB=1;
7907 HAVE_DECL_REMAINDER=1;
7908 HAVE_DECL_REMAINDERL=1;
7909 HAVE_DECL_RINTF=1;
7910 HAVE_DECL_ROUND=1;
7911 HAVE_DECL_ROUNDF=1;
7912 HAVE_DECL_ROUNDL=1;
7913 HAVE_DECL_SINL=1;
7914 HAVE_DECL_SQRTL=1;
7915 HAVE_DECL_TANL=1;
7916 HAVE_DECL_TRUNC=1;
7917 HAVE_DECL_TRUNCF=1;
7918 HAVE_DECL_TRUNCL=1;
7919 REPLACE_CBRTF=0;
7920 REPLACE_CBRTL=0;
7921 REPLACE_CEIL=0;
7922 REPLACE_CEILF=0;
7923 REPLACE_CEILL=0;
7924 REPLACE_EXPM1=0;
7925 REPLACE_EXPM1F=0;
7926 REPLACE_EXP2=0;
7927 REPLACE_EXP2L=0;
7928 REPLACE_FABSL=0;
7929 REPLACE_FLOOR=0;
7930 REPLACE_FLOORF=0;
7931 REPLACE_FLOORL=0;
7932 REPLACE_FMA=0;
7933 REPLACE_FMAF=0;
7934 REPLACE_FMAL=0;
7935 REPLACE_FMOD=0;
7936 REPLACE_FMODF=0;
7937 REPLACE_FMODL=0;
7938 REPLACE_FREXPF=0;
7939 REPLACE_FREXP=0;
7940 REPLACE_FREXPL=0;
7941 REPLACE_HUGE_VAL=0;
7942 REPLACE_HYPOT=0;
7943 REPLACE_HYPOTF=0;
7944 REPLACE_HYPOTL=0;
7945 REPLACE_ILOGB=0;
7946 REPLACE_ILOGBF=0;
7947 REPLACE_ISFINITE=0;
7948 REPLACE_ISINF=0;
7949 REPLACE_ISNAN=0;
7950 REPLACE_LDEXPL=0;
7951 REPLACE_LOG=0;
7952 REPLACE_LOGF=0;
7953 REPLACE_LOGL=0;
7954 REPLACE_LOG10=0;
7955 REPLACE_LOG10F=0;
7956 REPLACE_LOG10L=0;
7957 REPLACE_LOG1P=0;
7958 REPLACE_LOG1PF=0;
7959 REPLACE_LOG1PL=0;
7960 REPLACE_LOG2=0;
7961 REPLACE_LOG2F=0;
7962 REPLACE_LOG2L=0;
7963 REPLACE_LOGB=0;
7964 REPLACE_LOGBF=0;
7965 REPLACE_LOGBL=0;
7966 REPLACE_MODF=0;
7967 REPLACE_MODFF=0;
7968 REPLACE_MODFL=0;
7969 REPLACE_NAN=0;
7970 REPLACE_REMAINDER=0;
7971 REPLACE_REMAINDERF=0;
7972 REPLACE_REMAINDERL=0;
7973 REPLACE_ROUND=0;
7974 REPLACE_ROUNDF=0;
7975 REPLACE_ROUNDL=0;
7976 REPLACE_SIGNBIT=0;
7977 REPLACE_SIGNBIT_USING_GCC=0;
7978 REPLACE_SQRTL=0;
7979 REPLACE_TRUNC=0;
7980 REPLACE_TRUNCF=0;
7981 REPLACE_TRUNCL=0;
7982
7983
7984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexp() can be used without linking with libm" >&5
7985 $as_echo_n "checking whether frexp() can be used without linking with libm... " >&6; }
7986 if test "${gl_cv_func_frexp_no_libm+set}" = set; then :
7987 $as_echo_n "(cached) " >&6
7988 else
7989
7990 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7991 /* end confdefs.h. */
7992 #include <math.h>
7993 double x;
7994 int
7995 main ()
7996 {
7997 int e; return frexp (x, &e) > 0;
7998 ;
7999 return 0;
8000 }
8001 _ACEOF
8002 if ac_fn_c_try_link "$LINENO"; then :
8003 gl_cv_func_frexp_no_libm=yes
8004 else
8005 gl_cv_func_frexp_no_libm=no
8006 fi
8007 rm -f core conftest.err conftest.$ac_objext \
8008 conftest$ac_exeext conftest.$ac_ext
8009
8010 fi
8011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexp_no_libm" >&5
8012 $as_echo "$gl_cv_func_frexp_no_libm" >&6; }
8013
8014 ac_fn_c_check_decl "$LINENO" "alarm" "ac_cv_have_decl_alarm" "$ac_includes_default"
8015 if test "x$ac_cv_have_decl_alarm" = x""yes; then :
8016 ac_have_decl=1
8017 else
8018 ac_have_decl=0
8019 fi
8020
8021 cat >>confdefs.h <<_ACEOF
8022 #define HAVE_DECL_ALARM $ac_have_decl
8023 _ACEOF
8024
8025
8026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether long double and double are the same" >&5
8027 $as_echo_n "checking whether long double and double are the same... " >&6; }
8028 if test "${gl_cv_long_double_equals_double+set}" = set; then :
8029 $as_echo_n "(cached) " >&6
8030 else
8031 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8032 /* end confdefs.h. */
8033 #include <float.h>
8034 int
8035 main ()
8036 {
8037 typedef int check[sizeof (long double) == sizeof (double)
8038 && LDBL_MANT_DIG == DBL_MANT_DIG
8039 && LDBL_MAX_EXP == DBL_MAX_EXP
8040 && LDBL_MIN_EXP == DBL_MIN_EXP
8041 ? 1 : -1];
8042
8043 ;
8044 return 0;
8045 }
8046 _ACEOF
8047 if ac_fn_c_try_compile "$LINENO"; then :
8048 gl_cv_long_double_equals_double=yes
8049 else
8050 gl_cv_long_double_equals_double=no
8051 fi
8052 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8053
8054 fi
8055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_long_double_equals_double" >&5
8056 $as_echo "$gl_cv_long_double_equals_double" >&6; }
8057 if test $gl_cv_long_double_equals_double = yes; then
8058
8059 $as_echo "#define HAVE_SAME_LONG_DOUBLE_AS_DOUBLE 1" >>confdefs.h
8060
8061 HAVE_SAME_LONG_DOUBLE_AS_DOUBLE=1
8062 else
8063 HAVE_SAME_LONG_DOUBLE_AS_DOUBLE=0
8064 fi
8065
8066
8067
8068 GNULIB_FCHMODAT=0;
8069 GNULIB_FSTAT=0;
8070 GNULIB_FSTATAT=0;
8071 GNULIB_FUTIMENS=0;
8072 GNULIB_LCHMOD=0;
8073 GNULIB_LSTAT=0;
8074 GNULIB_MKDIRAT=0;
8075 GNULIB_MKFIFO=0;
8076 GNULIB_MKFIFOAT=0;
8077 GNULIB_MKNOD=0;
8078 GNULIB_MKNODAT=0;
8079 GNULIB_STAT=0;
8080 GNULIB_UTIMENSAT=0;
8081 HAVE_FCHMODAT=1;
8082 HAVE_FSTATAT=1;
8083 HAVE_FUTIMENS=1;
8084 HAVE_LCHMOD=1;
8085 HAVE_LSTAT=1;
8086 HAVE_MKDIRAT=1;
8087 HAVE_MKFIFO=1;
8088 HAVE_MKFIFOAT=1;
8089 HAVE_MKNOD=1;
8090 HAVE_MKNODAT=1;
8091 HAVE_UTIMENSAT=1;
8092 REPLACE_FSTAT=0;
8093 REPLACE_FSTATAT=0;
8094 REPLACE_FUTIMENS=0;
8095 REPLACE_LSTAT=0;
8096 REPLACE_MKDIR=0;
8097 REPLACE_MKFIFO=0;
8098 REPLACE_MKNOD=0;
8099 REPLACE_STAT=0;
8100 REPLACE_UTIMENSAT=0;
8101
8102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
8103 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
8104 if test "${ac_cv_header_stat_broken+set}" = set; then :
8105 $as_echo_n "(cached) " >&6
8106 else
8107 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8108 /* end confdefs.h. */
8109 #include <sys/types.h>
8110 #include <sys/stat.h>
8111
8112 #if defined S_ISBLK && defined S_IFDIR
8113 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
8114 #endif
8115
8116 #if defined S_ISBLK && defined S_IFCHR
8117 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
8118 #endif
8119
8120 #if defined S_ISLNK && defined S_IFREG
8121 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
8122 #endif
8123
8124 #if defined S_ISSOCK && defined S_IFREG
8125 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
8126 #endif
8127
8128 _ACEOF
8129 if ac_fn_c_try_compile "$LINENO"; then :
8130 ac_cv_header_stat_broken=no
8131 else
8132 ac_cv_header_stat_broken=yes
8133 fi
8134 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8135 fi
8136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
8137 $as_echo "$ac_cv_header_stat_broken" >&6; }
8138 if test $ac_cv_header_stat_broken = yes; then
8139
8140 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
8141
8142 fi
8143
8144
8145
8146
8147
8148 case "$host_os" in
8149 mingw*)
8150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
8151 $as_echo_n "checking for 64-bit off_t... " >&6; }
8152 if test "${gl_cv_type_off_t_64+set}" = set; then :
8153 $as_echo_n "(cached) " >&6
8154 else
8155 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8156 /* end confdefs.h. */
8157 #include <sys/types.h>
8158 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
8159
8160 int
8161 main ()
8162 {
8163
8164 ;
8165 return 0;
8166 }
8167 _ACEOF
8168 if ac_fn_c_try_compile "$LINENO"; then :
8169 gl_cv_type_off_t_64=yes
8170 else
8171 gl_cv_type_off_t_64=no
8172 fi
8173 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8174
8175 fi
8176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
8177 $as_echo "$gl_cv_type_off_t_64" >&6; }
8178 if test $gl_cv_type_off_t_64 = no; then
8179 WINDOWS_64_BIT_OFF_T=1
8180 else
8181 WINDOWS_64_BIT_OFF_T=0
8182 fi
8183 WINDOWS_64_BIT_ST_SIZE=1
8184 ;;
8185 *)
8186 WINDOWS_64_BIT_OFF_T=0
8187 WINDOWS_64_BIT_ST_SIZE=0
8188 ;;
8189 esac
8190
8191
8192
8193
8194
8195
8196
8197
8198
8199
8200
8201
8202
8203
8204
8205 if test $gl_cv_have_include_next = yes; then
8206 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
8207 else
8208 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
8209 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
8210 if test "${gl_cv_next_sys_stat_h+set}" = set; then :
8211 $as_echo_n "(cached) " >&6
8212 else
8213
8214 if test $ac_cv_header_sys_stat_h = yes; then
8215
8216
8217
8218
8219 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8220 /* end confdefs.h. */
8221 #include <sys/stat.h>
8222 _ACEOF
8223 case "$host_os" in
8224 aix*) gl_absname_cpp="$ac_cpp -C" ;;
8225 *) gl_absname_cpp="$ac_cpp" ;;
8226 esac
8227
8228 case "$host_os" in
8229 mingw*)
8230 gl_dirsep_regex='[/\\]'
8231 ;;
8232 *)
8233 gl_dirsep_regex='\/'
8234 ;;
8235 esac
8236 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
8237 gl_header_literal_regex=`echo 'sys/stat.h' \
8238 | sed -e "$gl_make_literal_regex_sed"`
8239 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
8240 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
8241 s|^/[^/]|//&|
8242 p
8243 q
8244 }'
8245
8246 gl_cv_absolute_sys_stat_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
8247 sed -n "$gl_absolute_header_sed"`
8248
8249 gl_header=$gl_cv_absolute_sys_stat_h
8250 gl_cv_next_sys_stat_h='"'$gl_header'"'
8251 else
8252 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
8253 fi
8254
8255
8256 fi
8257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
8258 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
8259 fi
8260 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
8261
8262 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
8263 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
8264 gl_next_as_first_directive='<'sys/stat.h'>'
8265 else
8266 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
8267 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
8268 fi
8269 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
8270
8271
8272
8273
8274
8275
8276
8277
8278
8279
8280
8281 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
8282
8283 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
8284
8285 fi
8286
8287 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
8288 #include <sys/stat.h>
8289 "
8290 if test "x$ac_cv_type_nlink_t" = x""yes; then :
8291
8292 else
8293
8294 $as_echo "#define nlink_t int" >>confdefs.h
8295
8296 fi
8297
8298
8299
8300 for gl_func in fchmodat fstat fstatat futimens lchmod lstat mkdirat mkfifo mkfifoat mknod mknodat stat utimensat; do
8301 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
8302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
8303 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
8304 if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
8305 $as_echo_n "(cached) " >&6
8306 else
8307 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8308 /* end confdefs.h. */
8309 #include <sys/stat.h>
8310
8311 int
8312 main ()
8313 {
8314 #undef $gl_func
8315 (void) $gl_func;
8316 ;
8317 return 0;
8318 }
8319 _ACEOF
8320 if ac_fn_c_try_compile "$LINENO"; then :
8321 eval "$as_gl_Symbol=yes"
8322 else
8323 eval "$as_gl_Symbol=no"
8324 fi
8325 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8326 fi
8327 eval ac_res=\$$as_gl_Symbol
8328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
8329 $as_echo "$ac_res" >&6; }
8330 eval as_val=\$$as_gl_Symbol
8331 if test "x$as_val" = x""yes; then :
8332 cat >>confdefs.h <<_ACEOF
8333 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
8334 _ACEOF
8335
8336 eval ac_cv_have_decl_$gl_func=yes
8337 fi
8338 done
8339
8340
8341
8342 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
8343 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
8344 if test "${gl_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
8345 $as_echo_n "(cached) " >&6
8346 else
8347 rm -f conftest.sym conftest.file
8348 echo >conftest.file
8349 if test "$cross_compiling" = yes; then :
8350 case "$host_os" in
8351 *-gnu*)
8352 # Guess yes on glibc systems.
8353 gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
8354 *)
8355 # If we don't know, assume the worst.
8356 gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
8357 esac
8358
8359 else
8360 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8361 /* end confdefs.h. */
8362 $ac_includes_default
8363 int
8364 main ()
8365 {
8366 struct stat sbuf;
8367 if (symlink ("conftest.file", "conftest.sym") != 0)
8368 return 1;
8369 /* Linux will dereference the symlink and fail, as required by
8370 POSIX. That is better in the sense that it means we will not
8371 have to compile and use the lstat wrapper. */
8372 return lstat ("conftest.sym/", &sbuf) == 0;
8373
8374 ;
8375 return 0;
8376 }
8377 _ACEOF
8378 if ac_fn_c_try_run "$LINENO"; then :
8379 gl_cv_func_lstat_dereferences_slashed_symlink=yes
8380 else
8381 gl_cv_func_lstat_dereferences_slashed_symlink=no
8382 fi
8383 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8384 conftest.$ac_objext conftest.beam conftest.$ac_ext
8385 fi
8386
8387 rm -f conftest.sym conftest.file
8388
8389 fi
8390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
8391 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
8392 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
8393 *yes)
8394
8395 cat >>confdefs.h <<_ACEOF
8396 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
8397 _ACEOF
8398
8399 ;;
8400 esac
8401
8402
8403
8404
8405
8406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getcwd (NULL, 0) allocates memory for result" >&5
8407 $as_echo_n "checking whether getcwd (NULL, 0) allocates memory for result... " >&6; }
8408 if test "${gl_cv_func_getcwd_null+set}" = set; then :
8409 $as_echo_n "(cached) " >&6
8410 else
8411 if test "$cross_compiling" = yes; then :
8412 case "$host_os" in
8413 # Guess yes on glibc systems.
8414 *-gnu*) gl_cv_func_getcwd_null="guessing yes";;
8415 # Guess yes on Cygwin.
8416 cygwin*) gl_cv_func_getcwd_null="guessing yes";;
8417 # If we don't know, assume the worst.
8418 *) gl_cv_func_getcwd_null="guessing no";;
8419 esac
8420
8421 else
8422 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8423 /* end confdefs.h. */
8424
8425 # include <stdlib.h>
8426 # if HAVE_UNISTD_H
8427 # include <unistd.h>
8428 # else /* on Windows with MSVC */
8429 # include <direct.h>
8430 # endif
8431 # ifndef getcwd
8432 char *getcwd ();
8433 # endif
8434
8435 int
8436 main ()
8437 {
8438
8439 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
8440 /* mingw cwd does not start with '/', but getcwd does allocate.
8441 However, mingw fails to honor non-zero size. */
8442 #else
8443 if (chdir ("/") != 0)
8444 return 1;
8445 else
8446 {
8447 char *f = getcwd (NULL, 0);
8448 if (! f)
8449 return 2;
8450 if (f[0] != '/')
8451 return 3;
8452 if (f[1] != '\0')
8453 return 4;
8454 free (f);
8455 return 0;
8456 }
8457 #endif
8458
8459 ;
8460 return 0;
8461 }
8462 _ACEOF
8463 if ac_fn_c_try_run "$LINENO"; then :
8464 gl_cv_func_getcwd_null=yes
8465 else
8466 gl_cv_func_getcwd_null=no
8467 fi
8468 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8469 conftest.$ac_objext conftest.beam conftest.$ac_ext
8470 fi
8471
8472 fi
8473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_null" >&5
8474 $as_echo "$gl_cv_func_getcwd_null" >&6; }
8475
8476
8477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getcwd with POSIX signature" >&5
8478 $as_echo_n "checking for getcwd with POSIX signature... " >&6; }
8479 if test "${gl_cv_func_getcwd_posix_signature+set}" = set; then :
8480 $as_echo_n "(cached) " >&6
8481 else
8482 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8483 /* end confdefs.h. */
8484 #include <unistd.h>
8485 int
8486 main ()
8487 {
8488 extern
8489 #ifdef __cplusplus
8490 "C"
8491 #endif
8492 char *getcwd (char *, size_t);
8493
8494 ;
8495 return 0;
8496 }
8497
8498 _ACEOF
8499 if ac_fn_c_try_compile "$LINENO"; then :
8500 gl_cv_func_getcwd_posix_signature=yes
8501 else
8502 gl_cv_func_getcwd_posix_signature=no
8503 fi
8504 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8505
8506 fi
8507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_posix_signature" >&5
8508 $as_echo "$gl_cv_func_getcwd_posix_signature" >&6; }
8509
8510 ac_fn_c_check_decl "$LINENO" "getcwd" "ac_cv_have_decl_getcwd" "$ac_includes_default"
8511 if test "x$ac_cv_have_decl_getcwd" = x""yes; then :
8512 ac_have_decl=1
8513 else
8514 ac_have_decl=0
8515 fi
8516
8517 cat >>confdefs.h <<_ACEOF
8518 #define HAVE_DECL_GETCWD $ac_have_decl
8519 _ACEOF
8520
8521
8522
8523 ac_fn_c_check_decl "$LINENO" "getdtablesize" "ac_cv_have_decl_getdtablesize" "$ac_includes_default"
8524 if test "x$ac_cv_have_decl_getdtablesize" = x""yes; then :
8525 ac_have_decl=1
8526 else
8527 ac_have_decl=0
8528 fi
8529
8530 cat >>confdefs.h <<_ACEOF
8531 #define HAVE_DECL_GETDTABLESIZE $ac_have_decl
8532 _ACEOF
8533
8534 ac_fn_c_check_decl "$LINENO" "getlogin_r" "ac_cv_have_decl_getlogin_r" "$ac_includes_default"
8535 if test "x$ac_cv_have_decl_getlogin_r" = x""yes; then :
8536 ac_have_decl=1
8537 else
8538 ac_have_decl=0
8539 fi
8540
8541 cat >>confdefs.h <<_ACEOF
8542 #define HAVE_DECL_GETLOGIN_R $ac_have_decl
8543 _ACEOF
8544
8545
8546
8547 ac_fn_c_check_decl "$LINENO" "getlogin" "ac_cv_have_decl_getlogin" "$ac_includes_default"
8548 if test "x$ac_cv_have_decl_getlogin" = x""yes; then :
8549 ac_have_decl=1
8550 else
8551 ac_have_decl=0
8552 fi
8553
8554 cat >>confdefs.h <<_ACEOF
8555 #define HAVE_DECL_GETLOGIN $ac_have_decl
8556 _ACEOF
8557
8558
8559
8560
8561
8562 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
8563 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
8564 if test "${ac_cv_c_restrict+set}" = set; then :
8565 $as_echo_n "(cached) " >&6
8566 else
8567 ac_cv_c_restrict=no
8568 # The order here caters to the fact that C++ does not require restrict.
8569 for ac_kw in __restrict __restrict__ _Restrict restrict; do
8570 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8571 /* end confdefs.h. */
8572 typedef int *int_ptr;
8573 int foo (int_ptr $ac_kw ip) { return ip[0]; }
8574 int bar (int [$ac_kw]); /* Catch GCC bug 14050. */
8575 int bar (int ip[$ac_kw]) { return ip[0]; }
8576
8577 int
8578 main ()
8579 {
8580 int s[1];
8581 int *$ac_kw t = s;
8582 t[0] = 0;
8583 return foo (t) + bar (t);
8584
8585 ;
8586 return 0;
8587 }
8588 _ACEOF
8589 if ac_fn_c_try_compile "$LINENO"; then :
8590 ac_cv_c_restrict=$ac_kw
8591 fi
8592 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8593 test "$ac_cv_c_restrict" != no && break
8594 done
8595
8596 fi
8597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
8598 $as_echo "$ac_cv_c_restrict" >&6; }
8599
8600 case $ac_cv_c_restrict in
8601 restrict) ;;
8602 no) $as_echo "#define restrict /**/" >>confdefs.h
8603 ;;
8604 *) cat >>confdefs.h <<_ACEOF
8605 #define restrict $ac_cv_c_restrict
8606 _ACEOF
8607 ;;
8608 esac
8609
8610
8611 GNULIB_GETTIMEOFDAY=0;
8612 HAVE_GETTIMEOFDAY=1;
8613 HAVE_STRUCT_TIMEVAL=1;
8614 HAVE_SYS_TIME_H=1;
8615 HAVE_TIMEZONE_T=0;
8616 REPLACE_GETTIMEOFDAY=0;
8617 REPLACE_STRUCT_TIMEVAL=0;
8618
8619
8620
8621
8622
8623
8624
8625
8626
8627
8628
8629
8630
8631
8632
8633
8634 if test $gl_cv_have_include_next = yes; then
8635 gl_cv_next_sys_time_h='<'sys/time.h'>'
8636 else
8637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
8638 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
8639 if test "${gl_cv_next_sys_time_h+set}" = set; then :
8640 $as_echo_n "(cached) " >&6
8641 else
8642
8643 if test $ac_cv_header_sys_time_h = yes; then
8644
8645
8646
8647
8648 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8649 /* end confdefs.h. */
8650 #include <sys/time.h>
8651 _ACEOF
8652 case "$host_os" in
8653 aix*) gl_absname_cpp="$ac_cpp -C" ;;
8654 *) gl_absname_cpp="$ac_cpp" ;;
8655 esac
8656
8657 case "$host_os" in
8658 mingw*)
8659 gl_dirsep_regex='[/\\]'
8660 ;;
8661 *)
8662 gl_dirsep_regex='\/'
8663 ;;
8664 esac
8665 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
8666 gl_header_literal_regex=`echo 'sys/time.h' \
8667 | sed -e "$gl_make_literal_regex_sed"`
8668 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
8669 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
8670 s|^/[^/]|//&|
8671 p
8672 q
8673 }'
8674
8675 gl_cv_absolute_sys_time_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
8676 sed -n "$gl_absolute_header_sed"`
8677
8678 gl_header=$gl_cv_absolute_sys_time_h
8679 gl_cv_next_sys_time_h='"'$gl_header'"'
8680 else
8681 gl_cv_next_sys_time_h='<'sys/time.h'>'
8682 fi
8683
8684
8685 fi
8686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
8687 $as_echo "$gl_cv_next_sys_time_h" >&6; }
8688 fi
8689 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
8690
8691 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
8692 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
8693 gl_next_as_first_directive='<'sys/time.h'>'
8694 else
8695 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
8696 gl_next_as_first_directive=$gl_cv_next_sys_time_h
8697 fi
8698 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
8699
8700
8701
8702
8703
8704 if test $ac_cv_header_sys_time_h != yes; then
8705 HAVE_SYS_TIME_H=0
8706 fi
8707
8708
8709
8710
8711
8712 if test $ac_cv_header_sys_socket_h != yes; then
8713 for ac_header in winsock2.h
8714 do :
8715 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
8716 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
8717 cat >>confdefs.h <<_ACEOF
8718 #define HAVE_WINSOCK2_H 1
8719 _ACEOF
8720
8721 fi
8722
8723 done
8724
8725 fi
8726 if test "$ac_cv_header_winsock2_h" = yes; then
8727 HAVE_WINSOCK2_H=1
8728 UNISTD_H_HAVE_WINSOCK2_H=1
8729 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
8730 else
8731 HAVE_WINSOCK2_H=0
8732 fi
8733
8734
8735 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
8736 $as_echo_n "checking for struct timeval... " >&6; }
8737 if test "${gl_cv_sys_struct_timeval+set}" = set; then :
8738 $as_echo_n "(cached) " >&6
8739 else
8740 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8741 /* end confdefs.h. */
8742 #if HAVE_SYS_TIME_H
8743 #include <sys/time.h>
8744 #endif
8745 #include <time.h>
8746 #if HAVE_WINSOCK2_H
8747 # include <winsock2.h>
8748 #endif
8749
8750 int
8751 main ()
8752 {
8753 static struct timeval x; x.tv_sec = x.tv_usec;
8754 ;
8755 return 0;
8756 }
8757 _ACEOF
8758 if ac_fn_c_try_compile "$LINENO"; then :
8759 gl_cv_sys_struct_timeval=yes
8760 else
8761 gl_cv_sys_struct_timeval=no
8762 fi
8763 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8764
8765 fi
8766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
8767 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
8768 if test $gl_cv_sys_struct_timeval != yes; then
8769 HAVE_STRUCT_TIMEVAL=0
8770 else
8771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
8772 $as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
8773 if test "${gl_cv_sys_struct_timeval_tv_sec+set}" = set; then :
8774 $as_echo_n "(cached) " >&6
8775 else
8776 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8777 /* end confdefs.h. */
8778 #if HAVE_SYS_TIME_H
8779 #include <sys/time.h>
8780 #endif
8781 #include <time.h>
8782 #if HAVE_WINSOCK2_H
8783 # include <winsock2.h>
8784 #endif
8785
8786 int
8787 main ()
8788 {
8789 static struct timeval x;
8790 typedef int verify_tv_sec_type[
8791 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
8792 ];
8793
8794 ;
8795 return 0;
8796 }
8797 _ACEOF
8798 if ac_fn_c_try_compile "$LINENO"; then :
8799 gl_cv_sys_struct_timeval_tv_sec=yes
8800 else
8801 gl_cv_sys_struct_timeval_tv_sec=no
8802 fi
8803 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8804
8805 fi
8806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
8807 $as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
8808 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
8809 REPLACE_STRUCT_TIMEVAL=1
8810 fi
8811 fi
8812
8813
8814 for gl_func in gettimeofday; do
8815 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
8816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
8817 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
8818 if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
8819 $as_echo_n "(cached) " >&6
8820 else
8821 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8822 /* end confdefs.h. */
8823
8824 #if HAVE_SYS_TIME_H
8825 # include <sys/time.h>
8826 #endif
8827 #include <time.h>
8828
8829 int
8830 main ()
8831 {
8832 #undef $gl_func
8833 (void) $gl_func;
8834 ;
8835 return 0;
8836 }
8837 _ACEOF
8838 if ac_fn_c_try_compile "$LINENO"; then :
8839 eval "$as_gl_Symbol=yes"
8840 else
8841 eval "$as_gl_Symbol=no"
8842 fi
8843 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8844 fi
8845 eval ac_res=\$$as_gl_Symbol
8846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
8847 $as_echo "$ac_res" >&6; }
8848 eval as_val=\$$as_gl_Symbol
8849 if test "x$as_val" = x""yes; then :
8850 cat >>confdefs.h <<_ACEOF
8851 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
8852 _ACEOF
8853
8854 eval ac_cv_have_decl_$gl_func=yes
8855 fi
8856 done
8857
8858
8859
8860
8861
8862
8863
8864
8865
8866
8867
8868
8869
8870
8871
8872
8873
8874
8875
8876
8877
8878
8879
8880 if test $gl_cv_have_include_next = yes; then
8881 gl_cv_next_limits_h='<'limits.h'>'
8882 else
8883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <limits.h>" >&5
8884 $as_echo_n "checking absolute name of <limits.h>... " >&6; }
8885 if test "${gl_cv_next_limits_h+set}" = set; then :
8886 $as_echo_n "(cached) " >&6
8887 else
8888
8889 if test $ac_cv_header_limits_h = yes; then
8890
8891
8892
8893
8894 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8895 /* end confdefs.h. */
8896 #include <limits.h>
8897 _ACEOF
8898 case "$host_os" in
8899 aix*) gl_absname_cpp="$ac_cpp -C" ;;
8900 *) gl_absname_cpp="$ac_cpp" ;;
8901 esac
8902
8903 case "$host_os" in
8904 mingw*)
8905 gl_dirsep_regex='[/\\]'
8906 ;;
8907 *)
8908 gl_dirsep_regex='\/'
8909 ;;
8910 esac
8911 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
8912 gl_header_literal_regex=`echo 'limits.h' \
8913 | sed -e "$gl_make_literal_regex_sed"`
8914 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
8915 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
8916 s|^/[^/]|//&|
8917 p
8918 q
8919 }'
8920
8921 gl_cv_absolute_limits_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
8922 sed -n "$gl_absolute_header_sed"`
8923
8924 gl_header=$gl_cv_absolute_limits_h
8925 gl_cv_next_limits_h='"'$gl_header'"'
8926 else
8927 gl_cv_next_limits_h='<'limits.h'>'
8928 fi
8929
8930
8931 fi
8932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_limits_h" >&5
8933 $as_echo "$gl_cv_next_limits_h" >&6; }
8934 fi
8935 NEXT_LIMITS_H=$gl_cv_next_limits_h
8936
8937 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
8938 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
8939 gl_next_as_first_directive='<'limits.h'>'
8940 else
8941 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
8942 gl_next_as_first_directive=$gl_cv_next_limits_h
8943 fi
8944 NEXT_AS_FIRST_DIRECTIVE_LIMITS_H=$gl_next_as_first_directive
8945
8946
8947
8948
8949
8950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether limits.h has ULLONG_WIDTH etc." >&5
8951 $as_echo_n "checking whether limits.h has ULLONG_WIDTH etc.... " >&6; }
8952 if test "${gl_cv_header_limits_width+set}" = set; then :
8953 $as_echo_n "(cached) " >&6
8954 else
8955 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8956 /* end confdefs.h. */
8957 #ifndef __STDC_WANT_IEC_60559_BFP_EXT__
8958 #define __STDC_WANT_IEC_60559_BFP_EXT__ 1
8959 #endif
8960 #include <limits.h>
8961 int ullw = ULLONG_WIDTH;
8962 int
8963 main ()
8964 {
8965
8966 ;
8967 return 0;
8968 }
8969 _ACEOF
8970 if ac_fn_c_try_compile "$LINENO"; then :
8971 gl_cv_header_limits_width=yes
8972 else
8973 gl_cv_header_limits_width=no
8974 fi
8975 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8976 fi
8977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_limits_width" >&5
8978 $as_echo "$gl_cv_header_limits_width" >&6; }
8979 if test "$gl_cv_header_limits_width" = yes; then
8980 LIMITS_H=
8981 else
8982 LIMITS_H=limits.h
8983 fi
8984
8985 if test -n "$LIMITS_H"; then
8986 GL_GENERATE_LIMITS_H_TRUE=
8987 GL_GENERATE_LIMITS_H_FALSE='#'
8988 else
8989 GL_GENERATE_LIMITS_H_TRUE='#'
8990 GL_GENERATE_LIMITS_H_FALSE=
8991 fi
8992
8993
8994
8995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
8996 $as_echo_n "checking for unsigned long long int... " >&6; }
8997 if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
8998 $as_echo_n "(cached) " >&6
8999 else
9000 ac_cv_type_unsigned_long_long_int=yes
9001 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
9002 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9003 /* end confdefs.h. */
9004
9005 /* For now, do not test the preprocessor; as of 2007 there are too many
9006 implementations with broken preprocessors. Perhaps this can
9007 be revisited in 2012. In the meantime, code should not expect
9008 #if to work with literals wider than 32 bits. */
9009 /* Test literals. */
9010 long long int ll = 9223372036854775807ll;
9011 long long int nll = -9223372036854775807LL;
9012 unsigned long long int ull = 18446744073709551615ULL;
9013 /* Test constant expressions. */
9014 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
9015 ? 1 : -1)];
9016 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
9017 ? 1 : -1)];
9018 int i = 63;
9019 int
9020 main ()
9021 {
9022 /* Test availability of runtime routines for shift and division. */
9023 long long int llmax = 9223372036854775807ll;
9024 unsigned long long int ullmax = 18446744073709551615ull;
9025 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
9026 | (llmax / ll) | (llmax % ll)
9027 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
9028 | (ullmax / ull) | (ullmax % ull));
9029 ;
9030 return 0;
9031 }
9032
9033 _ACEOF
9034 if ac_fn_c_try_link "$LINENO"; then :
9035
9036 else
9037 ac_cv_type_unsigned_long_long_int=no
9038 fi
9039 rm -f core conftest.err conftest.$ac_objext \
9040 conftest$ac_exeext conftest.$ac_ext
9041 fi
9042 fi
9043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
9044 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
9045 if test $ac_cv_type_unsigned_long_long_int = yes; then
9046
9047 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
9048
9049 fi
9050
9051
9052
9053 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
9054 $as_echo_n "checking for long long int... " >&6; }
9055 if test "${ac_cv_type_long_long_int+set}" = set; then :
9056 $as_echo_n "(cached) " >&6
9057 else
9058 ac_cv_type_long_long_int=yes
9059 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
9060 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
9061 if test $ac_cv_type_long_long_int = yes; then
9062 if test "$cross_compiling" = yes; then :
9063 :
9064 else
9065 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9066 /* end confdefs.h. */
9067 #include <limits.h>
9068 #ifndef LLONG_MAX
9069 # define HALF \
9070 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
9071 # define LLONG_MAX (HALF - 1 + HALF)
9072 #endif
9073 int
9074 main ()
9075 {
9076 long long int n = 1;
9077 int i;
9078 for (i = 0; ; i++)
9079 {
9080 long long int m = n << i;
9081 if (m >> i != n)
9082 return 1;
9083 if (LLONG_MAX / 2 < m)
9084 break;
9085 }
9086 return 0;
9087 ;
9088 return 0;
9089 }
9090 _ACEOF
9091 if ac_fn_c_try_run "$LINENO"; then :
9092
9093 else
9094 ac_cv_type_long_long_int=no
9095 fi
9096 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9097 conftest.$ac_objext conftest.beam conftest.$ac_ext
9098 fi
9099
9100 fi
9101 fi
9102 fi
9103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
9104 $as_echo "$ac_cv_type_long_long_int" >&6; }
9105 if test $ac_cv_type_long_long_int = yes; then
9106
9107 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
9108
9109 fi
9110
9111
9112
9113
9114
9115
9116 gl_cv_c_multiarch=no
9117 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9118 /* end confdefs.h. */
9119 #ifndef __APPLE_CC__
9120 not a universal capable compiler
9121 #endif
9122 typedef int dummy;
9123
9124 _ACEOF
9125 if ac_fn_c_try_compile "$LINENO"; then :
9126
9127 arch=
9128 prev=
9129 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
9130 if test -n "$prev"; then
9131 case $word in
9132 i?86 | x86_64 | ppc | ppc64)
9133 if test -z "$arch" || test "$arch" = "$word"; then
9134 arch="$word"
9135 else
9136 gl_cv_c_multiarch=yes
9137 fi
9138 ;;
9139 esac
9140 prev=
9141 else
9142 if test "x$word" = "x-arch"; then
9143 prev=arch
9144 fi
9145 fi
9146 done
9147
9148 fi
9149 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9150 if test $gl_cv_c_multiarch = yes; then
9151 APPLE_UNIVERSAL_BUILD=1
9152 else
9153 APPLE_UNIVERSAL_BUILD=0
9154 fi
9155
9156
9157
9158
9159
9160
9161
9162 if test $ac_cv_type_long_long_int = yes; then
9163 HAVE_LONG_LONG_INT=1
9164 else
9165 HAVE_LONG_LONG_INT=0
9166 fi
9167
9168
9169 if test $ac_cv_type_unsigned_long_long_int = yes; then
9170 HAVE_UNSIGNED_LONG_LONG_INT=1
9171 else
9172 HAVE_UNSIGNED_LONG_LONG_INT=0
9173 fi
9174
9175
9176
9177 if test $ac_cv_header_wchar_h = yes; then
9178 HAVE_WCHAR_H=1
9179 else
9180 HAVE_WCHAR_H=0
9181 fi
9182
9183
9184 if test $ac_cv_header_inttypes_h = yes; then
9185 HAVE_INTTYPES_H=1
9186 else
9187 HAVE_INTTYPES_H=0
9188 fi
9189
9190
9191 if test $ac_cv_header_sys_types_h = yes; then
9192 HAVE_SYS_TYPES_H=1
9193 else
9194 HAVE_SYS_TYPES_H=0
9195 fi
9196
9197
9198
9199
9200
9201
9202
9203
9204
9205
9206
9207 if test $gl_cv_have_include_next = yes; then
9208 gl_cv_next_stdint_h='<'stdint.h'>'
9209 else
9210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
9211 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
9212 if test "${gl_cv_next_stdint_h+set}" = set; then :
9213 $as_echo_n "(cached) " >&6
9214 else
9215
9216 if test $ac_cv_header_stdint_h = yes; then
9217
9218
9219
9220
9221 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9222 /* end confdefs.h. */
9223 #include <stdint.h>
9224 _ACEOF
9225 case "$host_os" in
9226 aix*) gl_absname_cpp="$ac_cpp -C" ;;
9227 *) gl_absname_cpp="$ac_cpp" ;;
9228 esac
9229
9230 case "$host_os" in
9231 mingw*)
9232 gl_dirsep_regex='[/\\]'
9233 ;;
9234 *)
9235 gl_dirsep_regex='\/'
9236 ;;
9237 esac
9238 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
9239 gl_header_literal_regex=`echo 'stdint.h' \
9240 | sed -e "$gl_make_literal_regex_sed"`
9241 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
9242 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
9243 s|^/[^/]|//&|
9244 p
9245 q
9246 }'
9247
9248 gl_cv_absolute_stdint_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
9249 sed -n "$gl_absolute_header_sed"`
9250
9251 gl_header=$gl_cv_absolute_stdint_h
9252 gl_cv_next_stdint_h='"'$gl_header'"'
9253 else
9254 gl_cv_next_stdint_h='<'stdint.h'>'
9255 fi
9256
9257
9258 fi
9259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
9260 $as_echo "$gl_cv_next_stdint_h" >&6; }
9261 fi
9262 NEXT_STDINT_H=$gl_cv_next_stdint_h
9263
9264 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
9265 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
9266 gl_next_as_first_directive='<'stdint.h'>'
9267 else
9268 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
9269 gl_next_as_first_directive=$gl_cv_next_stdint_h
9270 fi
9271 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
9272
9273
9274
9275
9276 if test $ac_cv_header_stdint_h = yes; then
9277 HAVE_STDINT_H=1
9278 else
9279 HAVE_STDINT_H=0
9280 fi
9281
9282
9283 if test $ac_cv_header_stdint_h = yes; then
9284 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
9285 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
9286 if test "${gl_cv_header_working_stdint_h+set}" = set; then :
9287 $as_echo_n "(cached) " >&6
9288 else
9289 gl_cv_header_working_stdint_h=no
9290 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9291 /* end confdefs.h. */
9292
9293
9294 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
9295 #define __STDC_CONSTANT_MACROS 1
9296 #define __STDC_LIMIT_MACROS 1
9297 #include <stdint.h>
9298 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
9299 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
9300 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
9301 #endif
9302
9303
9304 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
9305 included before <wchar.h>. */
9306 #include <stddef.h>
9307 #include <signal.h>
9308 #if HAVE_WCHAR_H
9309 # include <stdio.h>
9310 # include <time.h>
9311 # include <wchar.h>
9312 #endif
9313
9314
9315 #ifdef INT8_MAX
9316 int8_t a1 = INT8_MAX;
9317 int8_t a1min = INT8_MIN;
9318 #endif
9319 #ifdef INT16_MAX
9320 int16_t a2 = INT16_MAX;
9321 int16_t a2min = INT16_MIN;
9322 #endif
9323 #ifdef INT32_MAX
9324 int32_t a3 = INT32_MAX;
9325 int32_t a3min = INT32_MIN;
9326 #endif
9327 #ifdef INT64_MAX
9328 int64_t a4 = INT64_MAX;
9329 int64_t a4min = INT64_MIN;
9330 #endif
9331 #ifdef UINT8_MAX
9332 uint8_t b1 = UINT8_MAX;
9333 #else
9334 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
9335 #endif
9336 #ifdef UINT16_MAX
9337 uint16_t b2 = UINT16_MAX;
9338 #endif
9339 #ifdef UINT32_MAX
9340 uint32_t b3 = UINT32_MAX;
9341 #endif
9342 #ifdef UINT64_MAX
9343 uint64_t b4 = UINT64_MAX;
9344 #endif
9345 int_least8_t c1 = INT8_C (0x7f);
9346 int_least8_t c1max = INT_LEAST8_MAX;
9347 int_least8_t c1min = INT_LEAST8_MIN;
9348 int_least16_t c2 = INT16_C (0x7fff);
9349 int_least16_t c2max = INT_LEAST16_MAX;
9350 int_least16_t c2min = INT_LEAST16_MIN;
9351 int_least32_t c3 = INT32_C (0x7fffffff);
9352 int_least32_t c3max = INT_LEAST32_MAX;
9353 int_least32_t c3min = INT_LEAST32_MIN;
9354 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
9355 int_least64_t c4max = INT_LEAST64_MAX;
9356 int_least64_t c4min = INT_LEAST64_MIN;
9357 uint_least8_t d1 = UINT8_C (0xff);
9358 uint_least8_t d1max = UINT_LEAST8_MAX;
9359 uint_least16_t d2 = UINT16_C (0xffff);
9360 uint_least16_t d2max = UINT_LEAST16_MAX;
9361 uint_least32_t d3 = UINT32_C (0xffffffff);
9362 uint_least32_t d3max = UINT_LEAST32_MAX;
9363 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
9364 uint_least64_t d4max = UINT_LEAST64_MAX;
9365 int_fast8_t e1 = INT_FAST8_MAX;
9366 int_fast8_t e1min = INT_FAST8_MIN;
9367 int_fast16_t e2 = INT_FAST16_MAX;
9368 int_fast16_t e2min = INT_FAST16_MIN;
9369 int_fast32_t e3 = INT_FAST32_MAX;
9370 int_fast32_t e3min = INT_FAST32_MIN;
9371 int_fast64_t e4 = INT_FAST64_MAX;
9372 int_fast64_t e4min = INT_FAST64_MIN;
9373 uint_fast8_t f1 = UINT_FAST8_MAX;
9374 uint_fast16_t f2 = UINT_FAST16_MAX;
9375 uint_fast32_t f3 = UINT_FAST32_MAX;
9376 uint_fast64_t f4 = UINT_FAST64_MAX;
9377 #ifdef INTPTR_MAX
9378 intptr_t g = INTPTR_MAX;
9379 intptr_t gmin = INTPTR_MIN;
9380 #endif
9381 #ifdef UINTPTR_MAX
9382 uintptr_t h = UINTPTR_MAX;
9383 #endif
9384 intmax_t i = INTMAX_MAX;
9385 uintmax_t j = UINTMAX_MAX;
9386
9387 /* Check that SIZE_MAX has the correct type, if possible. */
9388 #if 201112 <= __STDC_VERSION__
9389 int k = _Generic (SIZE_MAX, size_t: 0);
9390 #elif (2 <= __GNUC__ || defined __IBM__TYPEOF__ \
9391 || (0x5110 <= __SUNPRO_C && !__STDC__))
9392 extern size_t k;
9393 extern __typeof__ (SIZE_MAX) k;
9394 #endif
9395
9396 #include <limits.h> /* for CHAR_BIT */
9397 #define TYPE_MINIMUM(t) \
9398 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
9399 #define TYPE_MAXIMUM(t) \
9400 ((t) ((t) 0 < (t) -1 \
9401 ? (t) -1 \
9402 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
9403 struct s {
9404 int check_PTRDIFF:
9405 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
9406 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
9407 ? 1 : -1;
9408 /* Detect bug in FreeBSD 6.0 / ia64. */
9409 int check_SIG_ATOMIC:
9410 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
9411 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
9412 ? 1 : -1;
9413 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
9414 int check_WCHAR:
9415 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
9416 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
9417 ? 1 : -1;
9418 /* Detect bug in mingw. */
9419 int check_WINT:
9420 WINT_MIN == TYPE_MINIMUM (wint_t)
9421 && WINT_MAX == TYPE_MAXIMUM (wint_t)
9422 ? 1 : -1;
9423
9424 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
9425 int check_UINT8_C:
9426 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
9427 int check_UINT16_C:
9428 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
9429
9430 /* Detect bugs in OpenBSD 3.9 stdint.h. */
9431 #ifdef UINT8_MAX
9432 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
9433 #endif
9434 #ifdef UINT16_MAX
9435 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
9436 #endif
9437 #ifdef UINT32_MAX
9438 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
9439 #endif
9440 #ifdef UINT64_MAX
9441 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
9442 #endif
9443 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
9444 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
9445 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
9446 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
9447 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
9448 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
9449 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
9450 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
9451 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
9452 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
9453 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
9454 };
9455
9456 int
9457 main ()
9458 {
9459
9460 ;
9461 return 0;
9462 }
9463 _ACEOF
9464 if ac_fn_c_try_compile "$LINENO"; then :
9465 if test "$cross_compiling" = yes; then :
9466 gl_cv_header_working_stdint_h=yes
9467
9468 else
9469 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9470 /* end confdefs.h. */
9471
9472
9473 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
9474 #define __STDC_CONSTANT_MACROS 1
9475 #define __STDC_LIMIT_MACROS 1
9476 #include <stdint.h>
9477
9478
9479 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
9480 included before <wchar.h>. */
9481 #include <stddef.h>
9482 #include <signal.h>
9483 #if HAVE_WCHAR_H
9484 # include <stdio.h>
9485 # include <time.h>
9486 # include <wchar.h>
9487 #endif
9488
9489
9490 #include <stdio.h>
9491 #include <string.h>
9492 #define MVAL(macro) MVAL1(macro)
9493 #define MVAL1(expression) #expression
9494 static const char *macro_values[] =
9495 {
9496 #ifdef INT8_MAX
9497 MVAL (INT8_MAX),
9498 #endif
9499 #ifdef INT16_MAX
9500 MVAL (INT16_MAX),
9501 #endif
9502 #ifdef INT32_MAX
9503 MVAL (INT32_MAX),
9504 #endif
9505 #ifdef INT64_MAX
9506 MVAL (INT64_MAX),
9507 #endif
9508 #ifdef UINT8_MAX
9509 MVAL (UINT8_MAX),
9510 #endif
9511 #ifdef UINT16_MAX
9512 MVAL (UINT16_MAX),
9513 #endif
9514 #ifdef UINT32_MAX
9515 MVAL (UINT32_MAX),
9516 #endif
9517 #ifdef UINT64_MAX
9518 MVAL (UINT64_MAX),
9519 #endif
9520 NULL
9521 };
9522
9523 int
9524 main ()
9525 {
9526
9527 const char **mv;
9528 for (mv = macro_values; *mv != NULL; mv++)
9529 {
9530 const char *value = *mv;
9531 /* Test whether it looks like a cast expression. */
9532 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
9533 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
9534 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
9535 || strncmp (value, "((int)"/*)*/, 6) == 0
9536 || strncmp (value, "((signed short)"/*)*/, 15) == 0
9537 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
9538 return mv - macro_values + 1;
9539 }
9540 return 0;
9541
9542 ;
9543 return 0;
9544 }
9545 _ACEOF
9546 if ac_fn_c_try_run "$LINENO"; then :
9547 gl_cv_header_working_stdint_h=yes
9548 fi
9549 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9550 conftest.$ac_objext conftest.beam conftest.$ac_ext
9551 fi
9552
9553
9554 fi
9555 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9556
9557 fi
9558 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
9559 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
9560 fi
9561
9562 HAVE_C99_STDINT_H=0
9563 HAVE_SYS_BITYPES_H=0
9564 HAVE_SYS_INTTYPES_H=0
9565 STDINT_H=stdint.h
9566 if test "$gl_cv_header_working_stdint_h" = yes; then
9567 HAVE_C99_STDINT_H=1
9568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h predates C++11" >&5
9569 $as_echo_n "checking whether stdint.h predates C++11... " >&6; }
9570 if test "${gl_cv_header_stdint_predates_cxx11_h+set}" = set; then :
9571 $as_echo_n "(cached) " >&6
9572 else
9573 gl_cv_header_stdint_predates_cxx11_h=yes
9574 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9575 /* end confdefs.h. */
9576
9577
9578 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
9579 #include <stdint.h>
9580
9581
9582 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
9583 included before <wchar.h>. */
9584 #include <stddef.h>
9585 #include <signal.h>
9586 #if HAVE_WCHAR_H
9587 # include <stdio.h>
9588 # include <time.h>
9589 # include <wchar.h>
9590 #endif
9591
9592
9593 intmax_t im = INTMAX_MAX;
9594 int32_t i32 = INT32_C (0x7fffffff);
9595
9596 int
9597 main ()
9598 {
9599
9600 ;
9601 return 0;
9602 }
9603 _ACEOF
9604 if ac_fn_c_try_compile "$LINENO"; then :
9605 gl_cv_header_stdint_predates_cxx11_h=no
9606 fi
9607 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9608 fi
9609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_stdint_predates_cxx11_h" >&5
9610 $as_echo "$gl_cv_header_stdint_predates_cxx11_h" >&6; }
9611
9612 if test "$gl_cv_header_stdint_predates_cxx11_h" = yes; then
9613
9614 $as_echo "#define __STDC_CONSTANT_MACROS 1" >>confdefs.h
9615
9616
9617 $as_echo "#define __STDC_LIMIT_MACROS 1" >>confdefs.h
9618
9619 fi
9620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h has UINTMAX_WIDTH etc." >&5
9621 $as_echo_n "checking whether stdint.h has UINTMAX_WIDTH etc.... " >&6; }
9622 if test "${gl_cv_header_stdint_width+set}" = set; then :
9623 $as_echo_n "(cached) " >&6
9624 else
9625 gl_cv_header_stdint_width=no
9626 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9627 /* end confdefs.h. */
9628
9629 /* Work if build is not clean. */
9630 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1
9631 #ifndef __STDC_WANT_IEC_60559_BFP_EXT__
9632 #define __STDC_WANT_IEC_60559_BFP_EXT__ 1
9633 #endif
9634 #include <stdint.h>
9635
9636 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
9637 included before <wchar.h>. */
9638 #include <stddef.h>
9639 #include <signal.h>
9640 #if HAVE_WCHAR_H
9641 # include <stdio.h>
9642 # include <time.h>
9643 # include <wchar.h>
9644 #endif
9645
9646 int iw = UINTMAX_WIDTH;
9647
9648 int
9649 main ()
9650 {
9651
9652 ;
9653 return 0;
9654 }
9655 _ACEOF
9656 if ac_fn_c_try_compile "$LINENO"; then :
9657 gl_cv_header_stdint_width=yes
9658 fi
9659 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9660 fi
9661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_stdint_width" >&5
9662 $as_echo "$gl_cv_header_stdint_width" >&6; }
9663 if test "$gl_cv_header_stdint_width" = yes; then
9664 STDINT_H=
9665 fi
9666 else
9667 for ac_header in sys/inttypes.h sys/bitypes.h
9668 do :
9669 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9670 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
9671 eval as_val=\$$as_ac_Header
9672 if test "x$as_val" = x""yes; then :
9673 cat >>confdefs.h <<_ACEOF
9674 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9675 _ACEOF
9676
9677 fi
9678
9679 done
9680
9681 if test $ac_cv_header_sys_inttypes_h = yes; then
9682 HAVE_SYS_INTTYPES_H=1
9683 fi
9684 if test $ac_cv_header_sys_bitypes_h = yes; then
9685 HAVE_SYS_BITYPES_H=1
9686 fi
9687
9688
9689 if test $APPLE_UNIVERSAL_BUILD = 0; then
9690
9691
9692 for gltype in ptrdiff_t size_t ; do
9693 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
9694 $as_echo_n "checking for bit size of $gltype... " >&6; }
9695 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
9696 $as_echo_n "(cached) " >&6
9697 else
9698 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
9699 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
9700 included before <wchar.h>. */
9701 #include <stddef.h>
9702 #include <signal.h>
9703 #if HAVE_WCHAR_H
9704 # include <stdio.h>
9705 # include <time.h>
9706 # include <wchar.h>
9707 #endif
9708
9709 #include <limits.h>"; then :
9710
9711 else
9712 result=unknown
9713 fi
9714
9715 eval gl_cv_bitsizeof_${gltype}=\$result
9716
9717 fi
9718 eval ac_res=\$gl_cv_bitsizeof_${gltype}
9719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
9720 $as_echo "$ac_res" >&6; }
9721 eval result=\$gl_cv_bitsizeof_${gltype}
9722 if test $result = unknown; then
9723 result=0
9724 fi
9725 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
9726 cat >>confdefs.h <<_ACEOF
9727 #define BITSIZEOF_${GLTYPE} $result
9728 _ACEOF
9729
9730 eval BITSIZEOF_${GLTYPE}=\$result
9731 done
9732
9733
9734 fi
9735
9736
9737 for gltype in sig_atomic_t wchar_t wint_t ; do
9738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
9739 $as_echo_n "checking for bit size of $gltype... " >&6; }
9740 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
9741 $as_echo_n "(cached) " >&6
9742 else
9743 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
9744 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
9745 included before <wchar.h>. */
9746 #include <stddef.h>
9747 #include <signal.h>
9748 #if HAVE_WCHAR_H
9749 # include <stdio.h>
9750 # include <time.h>
9751 # include <wchar.h>
9752 #endif
9753
9754 #include <limits.h>"; then :
9755
9756 else
9757 result=unknown
9758 fi
9759
9760 eval gl_cv_bitsizeof_${gltype}=\$result
9761
9762 fi
9763 eval ac_res=\$gl_cv_bitsizeof_${gltype}
9764 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
9765 $as_echo "$ac_res" >&6; }
9766 eval result=\$gl_cv_bitsizeof_${gltype}
9767 if test $result = unknown; then
9768 result=0
9769 fi
9770 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
9771 cat >>confdefs.h <<_ACEOF
9772 #define BITSIZEOF_${GLTYPE} $result
9773 _ACEOF
9774
9775 eval BITSIZEOF_${GLTYPE}=\$result
9776 done
9777
9778
9779
9780
9781 for gltype in sig_atomic_t wchar_t wint_t ; do
9782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
9783 $as_echo_n "checking whether $gltype is signed... " >&6; }
9784 if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
9785 $as_echo_n "(cached) " >&6
9786 else
9787 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9788 /* end confdefs.h. */
9789
9790 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
9791 included before <wchar.h>. */
9792 #include <stddef.h>
9793 #include <signal.h>
9794 #if HAVE_WCHAR_H
9795 # include <stdio.h>
9796 # include <time.h>
9797 # include <wchar.h>
9798 #endif
9799
9800 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
9801 int
9802 main ()
9803 {
9804
9805 ;
9806 return 0;
9807 }
9808 _ACEOF
9809 if ac_fn_c_try_compile "$LINENO"; then :
9810 result=yes
9811 else
9812 result=no
9813 fi
9814 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9815 eval gl_cv_type_${gltype}_signed=\$result
9816
9817 fi
9818 eval ac_res=\$gl_cv_type_${gltype}_signed
9819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
9820 $as_echo "$ac_res" >&6; }
9821 eval result=\$gl_cv_type_${gltype}_signed
9822 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
9823 if test "$result" = yes; then
9824 cat >>confdefs.h <<_ACEOF
9825 #define HAVE_SIGNED_${GLTYPE} 1
9826 _ACEOF
9827
9828 eval HAVE_SIGNED_${GLTYPE}=1
9829 else
9830 eval HAVE_SIGNED_${GLTYPE}=0
9831 fi
9832 done
9833
9834
9835 gl_cv_type_ptrdiff_t_signed=yes
9836 gl_cv_type_size_t_signed=no
9837 if test $APPLE_UNIVERSAL_BUILD = 0; then
9838
9839
9840 for gltype in ptrdiff_t size_t ; do
9841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
9842 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
9843 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
9844 $as_echo_n "(cached) " >&6
9845 else
9846 eval gl_cv_type_${gltype}_suffix=no
9847 eval result=\$gl_cv_type_${gltype}_signed
9848 if test "$result" = yes; then
9849 glsufu=
9850 else
9851 glsufu=u
9852 fi
9853 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
9854 case $glsuf in
9855 '') gltype1='int';;
9856 l) gltype1='long int';;
9857 ll) gltype1='long long int';;
9858 i64) gltype1='__int64';;
9859 u) gltype1='unsigned int';;
9860 ul) gltype1='unsigned long int';;
9861 ull) gltype1='unsigned long long int';;
9862 ui64)gltype1='unsigned __int64';;
9863 esac
9864 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9865 /* end confdefs.h. */
9866
9867 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
9868 included before <wchar.h>. */
9869 #include <stddef.h>
9870 #include <signal.h>
9871 #if HAVE_WCHAR_H
9872 # include <stdio.h>
9873 # include <time.h>
9874 # include <wchar.h>
9875 #endif
9876
9877 extern $gltype foo;
9878 extern $gltype1 foo;
9879 int
9880 main ()
9881 {
9882
9883 ;
9884 return 0;
9885 }
9886 _ACEOF
9887 if ac_fn_c_try_compile "$LINENO"; then :
9888 eval gl_cv_type_${gltype}_suffix=\$glsuf
9889 fi
9890 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9891 eval result=\$gl_cv_type_${gltype}_suffix
9892 test "$result" != no && break
9893 done
9894 fi
9895 eval ac_res=\$gl_cv_type_${gltype}_suffix
9896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
9897 $as_echo "$ac_res" >&6; }
9898 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
9899 eval result=\$gl_cv_type_${gltype}_suffix
9900 test "$result" = no && result=
9901 eval ${GLTYPE}_SUFFIX=\$result
9902 cat >>confdefs.h <<_ACEOF
9903 #define ${GLTYPE}_SUFFIX $result
9904 _ACEOF
9905
9906 done
9907
9908
9909 fi
9910
9911
9912 for gltype in sig_atomic_t wchar_t wint_t ; do
9913 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
9914 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
9915 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
9916 $as_echo_n "(cached) " >&6
9917 else
9918 eval gl_cv_type_${gltype}_suffix=no
9919 eval result=\$gl_cv_type_${gltype}_signed
9920 if test "$result" = yes; then
9921 glsufu=
9922 else
9923 glsufu=u
9924 fi
9925 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
9926 case $glsuf in
9927 '') gltype1='int';;
9928 l) gltype1='long int';;
9929 ll) gltype1='long long int';;
9930 i64) gltype1='__int64';;
9931 u) gltype1='unsigned int';;
9932 ul) gltype1='unsigned long int';;
9933 ull) gltype1='unsigned long long int';;
9934 ui64)gltype1='unsigned __int64';;
9935 esac
9936 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9937 /* end confdefs.h. */
9938
9939 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
9940 included before <wchar.h>. */
9941 #include <stddef.h>
9942 #include <signal.h>
9943 #if HAVE_WCHAR_H
9944 # include <stdio.h>
9945 # include <time.h>
9946 # include <wchar.h>
9947 #endif
9948
9949 extern $gltype foo;
9950 extern $gltype1 foo;
9951 int
9952 main ()
9953 {
9954
9955 ;
9956 return 0;
9957 }
9958 _ACEOF
9959 if ac_fn_c_try_compile "$LINENO"; then :
9960 eval gl_cv_type_${gltype}_suffix=\$glsuf
9961 fi
9962 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9963 eval result=\$gl_cv_type_${gltype}_suffix
9964 test "$result" != no && break
9965 done
9966 fi
9967 eval ac_res=\$gl_cv_type_${gltype}_suffix
9968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
9969 $as_echo "$ac_res" >&6; }
9970 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
9971 eval result=\$gl_cv_type_${gltype}_suffix
9972 test "$result" = no && result=
9973 eval ${GLTYPE}_SUFFIX=\$result
9974 cat >>confdefs.h <<_ACEOF
9975 #define ${GLTYPE}_SUFFIX $result
9976 _ACEOF
9977
9978 done
9979
9980
9981
9982 if test $BITSIZEOF_WINT_T -lt 32; then
9983 BITSIZEOF_WINT_T=32
9984 fi
9985
9986 fi
9987
9988 # The substitute stdint.h needs the substitute limit.h's _GL_INTEGER_WIDTH.
9989 LIMITS_H=limits.h
9990 if test -n "$LIMITS_H"; then
9991 GL_GENERATE_LIMITS_H_TRUE=
9992 GL_GENERATE_LIMITS_H_FALSE='#'
9993 else
9994 GL_GENERATE_LIMITS_H_TRUE='#'
9995 GL_GENERATE_LIMITS_H_FALSE=
9996 fi
9997
9998
9999
10000
10001
10002
10003 if test -n "$STDINT_H"; then
10004 GL_GENERATE_STDINT_H_TRUE=
10005 GL_GENERATE_STDINT_H_FALSE='#'
10006 else
10007 GL_GENERATE_STDINT_H_TRUE='#'
10008 GL_GENERATE_STDINT_H_FALSE=
10009 fi
10010
10011
10012
10013
10014
10015 GNULIB_IMAXABS=0;
10016 GNULIB_IMAXDIV=0;
10017 GNULIB_STRTOIMAX=0;
10018 GNULIB_STRTOUMAX=0;
10019 HAVE_DECL_IMAXABS=1;
10020 HAVE_DECL_IMAXDIV=1;
10021 HAVE_DECL_STRTOIMAX=1;
10022 HAVE_DECL_STRTOUMAX=1;
10023 REPLACE_STRTOIMAX=0;
10024 REPLACE_STRTOUMAX=0;
10025 INT32_MAX_LT_INTMAX_MAX=1;
10026 INT64_MAX_EQ_LONG_MAX='defined _LP64';
10027 PRI_MACROS_BROKEN=0;
10028 PRIPTR_PREFIX=__PRIPTR_PREFIX;
10029 UINT32_MAX_LT_UINTMAX_MAX=1;
10030 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
10031
10032
10033
10034
10035
10036
10037
10038
10039
10040
10041
10042
10043
10044
10045
10046 if test $gl_cv_have_include_next = yes; then
10047 gl_cv_next_inttypes_h='<'inttypes.h'>'
10048 else
10049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
10050 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
10051 if test "${gl_cv_next_inttypes_h+set}" = set; then :
10052 $as_echo_n "(cached) " >&6
10053 else
10054
10055 if test $ac_cv_header_inttypes_h = yes; then
10056
10057
10058
10059
10060 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10061 /* end confdefs.h. */
10062 #include <inttypes.h>
10063 _ACEOF
10064 case "$host_os" in
10065 aix*) gl_absname_cpp="$ac_cpp -C" ;;
10066 *) gl_absname_cpp="$ac_cpp" ;;
10067 esac
10068
10069 case "$host_os" in
10070 mingw*)
10071 gl_dirsep_regex='[/\\]'
10072 ;;
10073 *)
10074 gl_dirsep_regex='\/'
10075 ;;
10076 esac
10077 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
10078 gl_header_literal_regex=`echo 'inttypes.h' \
10079 | sed -e "$gl_make_literal_regex_sed"`
10080 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
10081 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
10082 s|^/[^/]|//&|
10083 p
10084 q
10085 }'
10086
10087 gl_cv_absolute_inttypes_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
10088 sed -n "$gl_absolute_header_sed"`
10089
10090 gl_header=$gl_cv_absolute_inttypes_h
10091 gl_cv_next_inttypes_h='"'$gl_header'"'
10092 else
10093 gl_cv_next_inttypes_h='<'inttypes.h'>'
10094 fi
10095
10096
10097 fi
10098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
10099 $as_echo "$gl_cv_next_inttypes_h" >&6; }
10100 fi
10101 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
10102
10103 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
10104 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
10105 gl_next_as_first_directive='<'inttypes.h'>'
10106 else
10107 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
10108 gl_next_as_first_directive=$gl_cv_next_inttypes_h
10109 fi
10110 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
10111
10112
10113
10114
10115
10116
10117
10118
10119 for gl_func in imaxabs imaxdiv strtoimax strtoumax; do
10120 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
10121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
10122 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
10123 if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
10124 $as_echo_n "(cached) " >&6
10125 else
10126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10127 /* end confdefs.h. */
10128 #include <inttypes.h>
10129
10130 int
10131 main ()
10132 {
10133 #undef $gl_func
10134 (void) $gl_func;
10135 ;
10136 return 0;
10137 }
10138 _ACEOF
10139 if ac_fn_c_try_compile "$LINENO"; then :
10140 eval "$as_gl_Symbol=yes"
10141 else
10142 eval "$as_gl_Symbol=no"
10143 fi
10144 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10145 fi
10146 eval ac_res=\$$as_gl_Symbol
10147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10148 $as_echo "$ac_res" >&6; }
10149 eval as_val=\$$as_gl_Symbol
10150 if test "x$as_val" = x""yes; then :
10151 cat >>confdefs.h <<_ACEOF
10152 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
10153 _ACEOF
10154
10155 eval ac_cv_have_decl_$gl_func=yes
10156 fi
10157 done
10158
10159
10160
10161 for ac_header in inttypes.h
10162 do :
10163 ac_fn_c_check_header_mongrel "$LINENO" "inttypes.h" "ac_cv_header_inttypes_h" "$ac_includes_default"
10164 if test "x$ac_cv_header_inttypes_h" = x""yes; then :
10165 cat >>confdefs.h <<_ACEOF
10166 #define HAVE_INTTYPES_H 1
10167 _ACEOF
10168
10169 fi
10170
10171 done
10172
10173 if test $ac_cv_header_inttypes_h = yes; then
10174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the inttypes.h PRIxNN macros are broken" >&5
10175 $as_echo_n "checking whether the inttypes.h PRIxNN macros are broken... " >&6; }
10176 if test "${gt_cv_inttypes_pri_broken+set}" = set; then :
10177 $as_echo_n "(cached) " >&6
10178 else
10179
10180 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10181 /* end confdefs.h. */
10182
10183 #include <inttypes.h>
10184 #ifdef PRId32
10185 char *p = PRId32;
10186 #endif
10187
10188 int
10189 main ()
10190 {
10191
10192 ;
10193 return 0;
10194 }
10195 _ACEOF
10196 if ac_fn_c_try_compile "$LINENO"; then :
10197 gt_cv_inttypes_pri_broken=no
10198 else
10199 gt_cv_inttypes_pri_broken=yes
10200 fi
10201 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10202
10203 fi
10204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_inttypes_pri_broken" >&5
10205 $as_echo "$gt_cv_inttypes_pri_broken" >&6; }
10206 fi
10207 if test "$gt_cv_inttypes_pri_broken" = yes; then
10208
10209 cat >>confdefs.h <<_ACEOF
10210 #define PRI_MACROS_BROKEN 1
10211 _ACEOF
10212
10213 PRI_MACROS_BROKEN=1
10214 else
10215 PRI_MACROS_BROKEN=0
10216 fi
10217
10218
10219
10220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'double'" >&5
10221 $as_echo_n "checking where to find the exponent in a 'double'... " >&6; }
10222 if test "${gl_cv_cc_double_expbit0+set}" = set; then :
10223 $as_echo_n "(cached) " >&6
10224 else
10225
10226 if test "$cross_compiling" = yes; then :
10227
10228 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10229 /* end confdefs.h. */
10230
10231 #if defined arm || defined __arm || defined __arm__
10232 mixed_endianness
10233 #endif
10234
10235 _ACEOF
10236 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10237 $EGREP "mixed_endianness" >/dev/null 2>&1; then :
10238 gl_cv_cc_double_expbit0="unknown"
10239 else
10240
10241 :
10242 if test "${ac_cv_c_bigendian+set}" = set; then :
10243 $as_echo_n "(cached) " >&6
10244 else
10245 ac_cv_c_bigendian=unknown
10246 # See if we're dealing with a universal compiler.
10247 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10248 /* end confdefs.h. */
10249 #ifndef __APPLE_CC__
10250 not a universal capable compiler
10251 #endif
10252 typedef int dummy;
10253
10254 _ACEOF
10255 if ac_fn_c_try_compile "$LINENO"; then :
10256
10257 # Check for potential -arch flags. It is not universal unless
10258 # there are at least two -arch flags with different values.
10259 ac_arch=
10260 ac_prev=
10261 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
10262 if test -n "$ac_prev"; then
10263 case $ac_word in
10264 i?86 | x86_64 | ppc | ppc64)
10265 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
10266 ac_arch=$ac_word
10267 else
10268 ac_cv_c_bigendian=universal
10269 break
10270 fi
10271 ;;
10272 esac
10273 ac_prev=
10274 elif test "x$ac_word" = "x-arch"; then
10275 ac_prev=arch
10276 fi
10277 done
10278 fi
10279 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10280 if test $ac_cv_c_bigendian = unknown; then
10281 # See if sys/param.h defines the BYTE_ORDER macro.
10282 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10283 /* end confdefs.h. */
10284 #include <sys/types.h>
10285 #include <sys/param.h>
10286
10287 int
10288 main ()
10289 {
10290 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
10291 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
10292 && LITTLE_ENDIAN)
10293 bogus endian macros
10294 #endif
10295
10296 ;
10297 return 0;
10298 }
10299 _ACEOF
10300 if ac_fn_c_try_compile "$LINENO"; then :
10301 # It does; now see whether it defined to BIG_ENDIAN or not.
10302 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10303 /* end confdefs.h. */
10304 #include <sys/types.h>
10305 #include <sys/param.h>
10306
10307 int
10308 main ()
10309 {
10310 #if BYTE_ORDER != BIG_ENDIAN
10311 not big endian
10312 #endif
10313
10314 ;
10315 return 0;
10316 }
10317 _ACEOF
10318 if ac_fn_c_try_compile "$LINENO"; then :
10319 ac_cv_c_bigendian=yes
10320 else
10321 ac_cv_c_bigendian=no
10322 fi
10323 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10324 fi
10325 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10326 fi
10327 if test $ac_cv_c_bigendian = unknown; then
10328 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
10329 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10330 /* end confdefs.h. */
10331 #include <limits.h>
10332
10333 int
10334 main ()
10335 {
10336 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
10337 bogus endian macros
10338 #endif
10339
10340 ;
10341 return 0;
10342 }
10343 _ACEOF
10344 if ac_fn_c_try_compile "$LINENO"; then :
10345 # It does; now see whether it defined to _BIG_ENDIAN or not.
10346 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10347 /* end confdefs.h. */
10348 #include <limits.h>
10349
10350 int
10351 main ()
10352 {
10353 #ifndef _BIG_ENDIAN
10354 not big endian
10355 #endif
10356
10357 ;
10358 return 0;
10359 }
10360 _ACEOF
10361 if ac_fn_c_try_compile "$LINENO"; then :
10362 ac_cv_c_bigendian=yes
10363 else
10364 ac_cv_c_bigendian=no
10365 fi
10366 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10367 fi
10368 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10369 fi
10370 if test $ac_cv_c_bigendian = unknown; then
10371 # Compile a test program.
10372 if test "$cross_compiling" = yes; then :
10373 # Try to guess by grepping values from an object file.
10374 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10375 /* end confdefs.h. */
10376 short int ascii_mm[] =
10377 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
10378 short int ascii_ii[] =
10379 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
10380 int use_ascii (int i) {
10381 return ascii_mm[i] + ascii_ii[i];
10382 }
10383 short int ebcdic_ii[] =
10384 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
10385 short int ebcdic_mm[] =
10386 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
10387 int use_ebcdic (int i) {
10388 return ebcdic_mm[i] + ebcdic_ii[i];
10389 }
10390 extern int foo;
10391
10392 int
10393 main ()
10394 {
10395 return use_ascii (foo) == use_ebcdic (foo);
10396 ;
10397 return 0;
10398 }
10399 _ACEOF
10400 if ac_fn_c_try_compile "$LINENO"; then :
10401 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
10402 ac_cv_c_bigendian=yes
10403 fi
10404 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
10405 if test "$ac_cv_c_bigendian" = unknown; then
10406 ac_cv_c_bigendian=no
10407 else
10408 # finding both strings is unlikely to happen, but who knows?
10409 ac_cv_c_bigendian=unknown
10410 fi
10411 fi
10412 fi
10413 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10414 else
10415 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10416 /* end confdefs.h. */
10417 $ac_includes_default
10418 int
10419 main ()
10420 {
10421
10422 /* Are we little or big endian? From Harbison&Steele. */
10423 union
10424 {
10425 long int l;
10426 char c[sizeof (long int)];
10427 } u;
10428 u.l = 1;
10429 return u.c[sizeof (long int) - 1] == 1;
10430
10431 ;
10432 return 0;
10433 }
10434 _ACEOF
10435 if ac_fn_c_try_run "$LINENO"; then :
10436 ac_cv_c_bigendian=no
10437 else
10438 ac_cv_c_bigendian=yes
10439 fi
10440 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10441 conftest.$ac_objext conftest.beam conftest.$ac_ext
10442 fi
10443
10444 fi
10445 fi
10446 :
10447 case $ac_cv_c_bigendian in #(
10448 yes)
10449 gl_cv_cc_double_expbit0="word 0 bit 20";; #(
10450 no)
10451 gl_cv_cc_double_expbit0="word 1 bit 20" ;; #(
10452 universal)
10453
10454 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
10455
10456 ;; #(
10457 *)
10458 gl_cv_cc_double_expbit0="unknown" ;;
10459 esac
10460
10461
10462 fi
10463 rm -f conftest*
10464
10465
10466 else
10467 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10468 /* end confdefs.h. */
10469
10470 #include <float.h>
10471 #include <stddef.h>
10472 #include <stdio.h>
10473 #include <string.h>
10474 #define NWORDS \
10475 ((sizeof (double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
10476 typedef union { double value; unsigned int word[NWORDS]; } memory_double;
10477 static unsigned int ored_words[NWORDS];
10478 static unsigned int anded_words[NWORDS];
10479 static void add_to_ored_words (double x)
10480 {
10481 memory_double m;
10482 size_t i;
10483 /* Clear it first, in case sizeof (double) < sizeof (memory_double). */
10484 memset (&m, 0, sizeof (memory_double));
10485 m.value = x;
10486 for (i = 0; i < NWORDS; i++)
10487 {
10488 ored_words[i] |= m.word[i];
10489 anded_words[i] &= m.word[i];
10490 }
10491 }
10492 int main ()
10493 {
10494 size_t j;
10495 FILE *fp = fopen ("conftest.out", "w");
10496 if (fp == NULL)
10497 return 1;
10498 for (j = 0; j < NWORDS; j++)
10499 anded_words[j] = ~ (unsigned int) 0;
10500 add_to_ored_words (0.25);
10501 add_to_ored_words (0.5);
10502 add_to_ored_words (1.0);
10503 add_to_ored_words (2.0);
10504 add_to_ored_words (4.0);
10505 /* Remove bits that are common (e.g. if representation of the first mantissa
10506 bit is explicit). */
10507 for (j = 0; j < NWORDS; j++)
10508 ored_words[j] &= ~anded_words[j];
10509 /* Now find the nonzero word. */
10510 for (j = 0; j < NWORDS; j++)
10511 if (ored_words[j] != 0)
10512 break;
10513 if (j < NWORDS)
10514 {
10515 size_t i;
10516 for (i = j + 1; i < NWORDS; i++)
10517 if (ored_words[i] != 0)
10518 {
10519 fprintf (fp, "unknown");
10520 return (fclose (fp) != 0);
10521 }
10522 for (i = 0; ; i++)
10523 if ((ored_words[j] >> i) & 1)
10524 {
10525 fprintf (fp, "word %d bit %d", (int) j, (int) i);
10526 return (fclose (fp) != 0);
10527 }
10528 }
10529 fprintf (fp, "unknown");
10530 return (fclose (fp) != 0);
10531 }
10532
10533 _ACEOF
10534 if ac_fn_c_try_run "$LINENO"; then :
10535 gl_cv_cc_double_expbit0=`cat conftest.out`
10536 else
10537 gl_cv_cc_double_expbit0="unknown"
10538 fi
10539 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10540 conftest.$ac_objext conftest.beam conftest.$ac_ext
10541 fi
10542
10543 rm -f conftest.out
10544
10545 fi
10546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_double_expbit0" >&5
10547 $as_echo "$gl_cv_cc_double_expbit0" >&6; }
10548 case "$gl_cv_cc_double_expbit0" in
10549 word*bit*)
10550 word=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
10551 bit=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word.*bit //'`
10552
10553 cat >>confdefs.h <<_ACEOF
10554 #define DBL_EXPBIT0_WORD $word
10555 _ACEOF
10556
10557
10558 cat >>confdefs.h <<_ACEOF
10559 #define DBL_EXPBIT0_BIT $bit
10560 _ACEOF
10561
10562 ;;
10563 esac
10564
10565
10566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
10567 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
10568 if test "${ac_cv_c_bigendian+set}" = set; then :
10569 $as_echo_n "(cached) " >&6
10570 else
10571 ac_cv_c_bigendian=unknown
10572 # See if we're dealing with a universal compiler.
10573 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10574 /* end confdefs.h. */
10575 #ifndef __APPLE_CC__
10576 not a universal capable compiler
10577 #endif
10578 typedef int dummy;
10579
10580 _ACEOF
10581 if ac_fn_c_try_compile "$LINENO"; then :
10582
10583 # Check for potential -arch flags. It is not universal unless
10584 # there are at least two -arch flags with different values.
10585 ac_arch=
10586 ac_prev=
10587 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
10588 if test -n "$ac_prev"; then
10589 case $ac_word in
10590 i?86 | x86_64 | ppc | ppc64)
10591 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
10592 ac_arch=$ac_word
10593 else
10594 ac_cv_c_bigendian=universal
10595 break
10596 fi
10597 ;;
10598 esac
10599 ac_prev=
10600 elif test "x$ac_word" = "x-arch"; then
10601 ac_prev=arch
10602 fi
10603 done
10604 fi
10605 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10606 if test $ac_cv_c_bigendian = unknown; then
10607 # See if sys/param.h defines the BYTE_ORDER macro.
10608 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10609 /* end confdefs.h. */
10610 #include <sys/types.h>
10611 #include <sys/param.h>
10612
10613 int
10614 main ()
10615 {
10616 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
10617 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
10618 && LITTLE_ENDIAN)
10619 bogus endian macros
10620 #endif
10621
10622 ;
10623 return 0;
10624 }
10625 _ACEOF
10626 if ac_fn_c_try_compile "$LINENO"; then :
10627 # It does; now see whether it defined to BIG_ENDIAN or not.
10628 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10629 /* end confdefs.h. */
10630 #include <sys/types.h>
10631 #include <sys/param.h>
10632
10633 int
10634 main ()
10635 {
10636 #if BYTE_ORDER != BIG_ENDIAN
10637 not big endian
10638 #endif
10639
10640 ;
10641 return 0;
10642 }
10643 _ACEOF
10644 if ac_fn_c_try_compile "$LINENO"; then :
10645 ac_cv_c_bigendian=yes
10646 else
10647 ac_cv_c_bigendian=no
10648 fi
10649 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10650 fi
10651 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10652 fi
10653 if test $ac_cv_c_bigendian = unknown; then
10654 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
10655 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10656 /* end confdefs.h. */
10657 #include <limits.h>
10658
10659 int
10660 main ()
10661 {
10662 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
10663 bogus endian macros
10664 #endif
10665
10666 ;
10667 return 0;
10668 }
10669 _ACEOF
10670 if ac_fn_c_try_compile "$LINENO"; then :
10671 # It does; now see whether it defined to _BIG_ENDIAN or not.
10672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10673 /* end confdefs.h. */
10674 #include <limits.h>
10675
10676 int
10677 main ()
10678 {
10679 #ifndef _BIG_ENDIAN
10680 not big endian
10681 #endif
10682
10683 ;
10684 return 0;
10685 }
10686 _ACEOF
10687 if ac_fn_c_try_compile "$LINENO"; then :
10688 ac_cv_c_bigendian=yes
10689 else
10690 ac_cv_c_bigendian=no
10691 fi
10692 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10693 fi
10694 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10695 fi
10696 if test $ac_cv_c_bigendian = unknown; then
10697 # Compile a test program.
10698 if test "$cross_compiling" = yes; then :
10699 # Try to guess by grepping values from an object file.
10700 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10701 /* end confdefs.h. */
10702 short int ascii_mm[] =
10703 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
10704 short int ascii_ii[] =
10705 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
10706 int use_ascii (int i) {
10707 return ascii_mm[i] + ascii_ii[i];
10708 }
10709 short int ebcdic_ii[] =
10710 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
10711 short int ebcdic_mm[] =
10712 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
10713 int use_ebcdic (int i) {
10714 return ebcdic_mm[i] + ebcdic_ii[i];
10715 }
10716 extern int foo;
10717
10718 int
10719 main ()
10720 {
10721 return use_ascii (foo) == use_ebcdic (foo);
10722 ;
10723 return 0;
10724 }
10725 _ACEOF
10726 if ac_fn_c_try_compile "$LINENO"; then :
10727 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
10728 ac_cv_c_bigendian=yes
10729 fi
10730 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
10731 if test "$ac_cv_c_bigendian" = unknown; then
10732 ac_cv_c_bigendian=no
10733 else
10734 # finding both strings is unlikely to happen, but who knows?
10735 ac_cv_c_bigendian=unknown
10736 fi
10737 fi
10738 fi
10739 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10740 else
10741 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10742 /* end confdefs.h. */
10743 $ac_includes_default
10744 int
10745 main ()
10746 {
10747
10748 /* Are we little or big endian? From Harbison&Steele. */
10749 union
10750 {
10751 long int l;
10752 char c[sizeof (long int)];
10753 } u;
10754 u.l = 1;
10755 return u.c[sizeof (long int) - 1] == 1;
10756
10757 ;
10758 return 0;
10759 }
10760 _ACEOF
10761 if ac_fn_c_try_run "$LINENO"; then :
10762 ac_cv_c_bigendian=no
10763 else
10764 ac_cv_c_bigendian=yes
10765 fi
10766 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10767 conftest.$ac_objext conftest.beam conftest.$ac_ext
10768 fi
10769
10770 fi
10771 fi
10772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
10773 $as_echo "$ac_cv_c_bigendian" >&6; }
10774 case $ac_cv_c_bigendian in #(
10775 yes)
10776 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
10777 ;; #(
10778 no)
10779 ;; #(
10780 universal)
10781
10782 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
10783
10784 ;; #(
10785 *)
10786 as_fn_error "unknown endianness
10787 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
10788 esac
10789
10790
10791
10792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
10793 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
10794 if test "${am_cv_langinfo_codeset+set}" = set; then :
10795 $as_echo_n "(cached) " >&6
10796 else
10797 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10798 /* end confdefs.h. */
10799 #include <langinfo.h>
10800 int
10801 main ()
10802 {
10803 char* cs = nl_langinfo(CODESET); return !cs;
10804 ;
10805 return 0;
10806 }
10807 _ACEOF
10808 if ac_fn_c_try_link "$LINENO"; then :
10809 am_cv_langinfo_codeset=yes
10810 else
10811 am_cv_langinfo_codeset=no
10812 fi
10813 rm -f core conftest.err conftest.$ac_objext \
10814 conftest$ac_exeext conftest.$ac_ext
10815
10816 fi
10817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
10818 $as_echo "$am_cv_langinfo_codeset" >&6; }
10819 if test $am_cv_langinfo_codeset = yes; then
10820
10821 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
10822
10823 fi
10824
10825 ac_fn_c_check_decl "$LINENO" "getc_unlocked" "ac_cv_have_decl_getc_unlocked" "$ac_includes_default"
10826 if test "x$ac_cv_have_decl_getc_unlocked" = x""yes; then :
10827 ac_have_decl=1
10828 else
10829 ac_have_decl=0
10830 fi
10831
10832 cat >>confdefs.h <<_ACEOF
10833 #define HAVE_DECL_GETC_UNLOCKED $ac_have_decl
10834 _ACEOF
10835
10836
10837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C Library >= 2.1 or uClibc" >&5
10838 $as_echo_n "checking whether we are using the GNU C Library >= 2.1 or uClibc... " >&6; }
10839 if test "${ac_cv_gnu_library_2_1+set}" = set; then :
10840 $as_echo_n "(cached) " >&6
10841 else
10842 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10843 /* end confdefs.h. */
10844
10845 #include <features.h>
10846 #ifdef __GNU_LIBRARY__
10847 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)
10848 Lucky GNU user
10849 #endif
10850 #endif
10851 #ifdef __UCLIBC__
10852 Lucky user
10853 #endif
10854
10855 _ACEOF
10856 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10857 $EGREP "Lucky" >/dev/null 2>&1; then :
10858 ac_cv_gnu_library_2_1=yes
10859 else
10860 ac_cv_gnu_library_2_1=no
10861 fi
10862 rm -f conftest*
10863
10864
10865
10866 fi
10867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gnu_library_2_1" >&5
10868 $as_echo "$ac_cv_gnu_library_2_1" >&6; }
10869
10870 GLIBC21="$ac_cv_gnu_library_2_1"
10871
10872
10873
10874
10875
10876 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc, realloc, calloc are POSIX compliant" >&5
10877 $as_echo_n "checking whether malloc, realloc, calloc are POSIX compliant... " >&6; }
10878 if test "${gl_cv_func_malloc_posix+set}" = set; then :
10879 $as_echo_n "(cached) " >&6
10880 else
10881
10882 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10883 /* end confdefs.h. */
10884
10885 int
10886 main ()
10887 {
10888 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
10889 choke me
10890 #endif
10891
10892 ;
10893 return 0;
10894 }
10895 _ACEOF
10896 if ac_fn_c_try_compile "$LINENO"; then :
10897 gl_cv_func_malloc_posix=yes
10898 else
10899 gl_cv_func_malloc_posix=no
10900 fi
10901 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10902
10903 fi
10904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_malloc_posix" >&5
10905 $as_echo "$gl_cv_func_malloc_posix" >&6; }
10906
10907
10908
10909 for ac_header in stdlib.h
10910 do :
10911 ac_fn_c_check_header_mongrel "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default"
10912 if test "x$ac_cv_header_stdlib_h" = x""yes; then :
10913 cat >>confdefs.h <<_ACEOF
10914 #define HAVE_STDLIB_H 1
10915 _ACEOF
10916
10917 fi
10918
10919 done
10920
10921 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5
10922 $as_echo_n "checking for GNU libc compatible malloc... " >&6; }
10923 if test "${ac_cv_func_malloc_0_nonnull+set}" = set; then :
10924 $as_echo_n "(cached) " >&6
10925 else
10926 if test "$cross_compiling" = yes; then :
10927 case "$host_os" in
10928 # Guess yes on platforms where we know the result.
10929 *-gnu* | freebsd* | netbsd* | openbsd* \
10930 | hpux* | solaris* | cygwin* | mingw*)
10931 ac_cv_func_malloc_0_nonnull=yes ;;
10932 # If we don't know, assume the worst.
10933 *) ac_cv_func_malloc_0_nonnull=no ;;
10934 esac
10935
10936 else
10937 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10938 /* end confdefs.h. */
10939 #if defined STDC_HEADERS || defined HAVE_STDLIB_H
10940 # include <stdlib.h>
10941 #else
10942 char *malloc ();
10943 #endif
10944
10945 int
10946 main ()
10947 {
10948 char *p = malloc (0);
10949 int result = !p;
10950 free (p);
10951 return result;
10952 ;
10953 return 0;
10954 }
10955
10956 _ACEOF
10957 if ac_fn_c_try_run "$LINENO"; then :
10958 ac_cv_func_malloc_0_nonnull=yes
10959 else
10960 ac_cv_func_malloc_0_nonnull=no
10961 fi
10962 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10963 conftest.$ac_objext conftest.beam conftest.$ac_ext
10964 fi
10965
10966
10967 fi
10968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_malloc_0_nonnull" >&5
10969 $as_echo "$ac_cv_func_malloc_0_nonnull" >&6; }
10970 if test $ac_cv_func_malloc_0_nonnull = yes; then :
10971 gl_cv_func_malloc_0_nonnull=1
10972 else
10973 gl_cv_func_malloc_0_nonnull=0
10974 fi
10975
10976
10977 cat >>confdefs.h <<_ACEOF
10978 #define MALLOC_0_IS_NONNULL $gl_cv_func_malloc_0_nonnull
10979 _ACEOF
10980
10981
10982
10983
10984
10985 GNULIB_BTOWC=0;
10986 GNULIB_WCTOB=0;
10987 GNULIB_MBSINIT=0;
10988 GNULIB_MBRTOWC=0;
10989 GNULIB_MBRLEN=0;
10990 GNULIB_MBSRTOWCS=0;
10991 GNULIB_MBSNRTOWCS=0;
10992 GNULIB_WCRTOMB=0;
10993 GNULIB_WCSRTOMBS=0;
10994 GNULIB_WCSNRTOMBS=0;
10995 GNULIB_WCWIDTH=0;
10996 GNULIB_WMEMCHR=0;
10997 GNULIB_WMEMCMP=0;
10998 GNULIB_WMEMCPY=0;
10999 GNULIB_WMEMMOVE=0;
11000 GNULIB_WMEMSET=0;
11001 GNULIB_WCSLEN=0;
11002 GNULIB_WCSNLEN=0;
11003 GNULIB_WCSCPY=0;
11004 GNULIB_WCPCPY=0;
11005 GNULIB_WCSNCPY=0;
11006 GNULIB_WCPNCPY=0;
11007 GNULIB_WCSCAT=0;
11008 GNULIB_WCSNCAT=0;
11009 GNULIB_WCSCMP=0;
11010 GNULIB_WCSNCMP=0;
11011 GNULIB_WCSCASECMP=0;
11012 GNULIB_WCSNCASECMP=0;
11013 GNULIB_WCSCOLL=0;
11014 GNULIB_WCSXFRM=0;
11015 GNULIB_WCSDUP=0;
11016 GNULIB_WCSCHR=0;
11017 GNULIB_WCSRCHR=0;
11018 GNULIB_WCSCSPN=0;
11019 GNULIB_WCSSPN=0;
11020 GNULIB_WCSPBRK=0;
11021 GNULIB_WCSSTR=0;
11022 GNULIB_WCSTOK=0;
11023 GNULIB_WCSWIDTH=0;
11024 HAVE_BTOWC=1;
11025 HAVE_MBSINIT=1;
11026 HAVE_MBRTOWC=1;
11027 HAVE_MBRLEN=1;
11028 HAVE_MBSRTOWCS=1;
11029 HAVE_MBSNRTOWCS=1;
11030 HAVE_WCRTOMB=1;
11031 HAVE_WCSRTOMBS=1;
11032 HAVE_WCSNRTOMBS=1;
11033 HAVE_WMEMCHR=1;
11034 HAVE_WMEMCMP=1;
11035 HAVE_WMEMCPY=1;
11036 HAVE_WMEMMOVE=1;
11037 HAVE_WMEMSET=1;
11038 HAVE_WCSLEN=1;
11039 HAVE_WCSNLEN=1;
11040 HAVE_WCSCPY=1;
11041 HAVE_WCPCPY=1;
11042 HAVE_WCSNCPY=1;
11043 HAVE_WCPNCPY=1;
11044 HAVE_WCSCAT=1;
11045 HAVE_WCSNCAT=1;
11046 HAVE_WCSCMP=1;
11047 HAVE_WCSNCMP=1;
11048 HAVE_WCSCASECMP=1;
11049 HAVE_WCSNCASECMP=1;
11050 HAVE_WCSCOLL=1;
11051 HAVE_WCSXFRM=1;
11052 HAVE_WCSDUP=1;
11053 HAVE_WCSCHR=1;
11054 HAVE_WCSRCHR=1;
11055 HAVE_WCSCSPN=1;
11056 HAVE_WCSSPN=1;
11057 HAVE_WCSPBRK=1;
11058 HAVE_WCSSTR=1;
11059 HAVE_WCSTOK=1;
11060 HAVE_WCSWIDTH=1;
11061 HAVE_DECL_WCTOB=1;
11062 HAVE_DECL_WCWIDTH=1;
11063 REPLACE_MBSTATE_T=0;
11064 REPLACE_BTOWC=0;
11065 REPLACE_WCTOB=0;
11066 REPLACE_MBSINIT=0;
11067 REPLACE_MBRTOWC=0;
11068 REPLACE_MBRLEN=0;
11069 REPLACE_MBSRTOWCS=0;
11070 REPLACE_MBSNRTOWCS=0;
11071 REPLACE_WCRTOMB=0;
11072 REPLACE_WCSRTOMBS=0;
11073 REPLACE_WCSNRTOMBS=0;
11074 REPLACE_WCWIDTH=0;
11075 REPLACE_WCSWIDTH=0;
11076
11077
11078
11079
11080
11081
11082
11083
11084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional japanese locale" >&5
11085 $as_echo_n "checking for a traditional japanese locale... " >&6; }
11086 if test "${gt_cv_locale_ja+set}" = set; then :
11087 $as_echo_n "(cached) " >&6
11088 else
11089
11090 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11091 /* end confdefs.h. */
11092
11093 #include <locale.h>
11094 #include <time.h>
11095 #if HAVE_LANGINFO_CODESET
11096 # include <langinfo.h>
11097 #endif
11098 #include <stdlib.h>
11099 #include <string.h>
11100 struct tm t;
11101 char buf[16];
11102 int main ()
11103 {
11104 const char *p;
11105 /* Check whether the given locale name is recognized by the system. */
11106 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
11107 /* On native Windows, setlocale(category, "") looks at the system settings,
11108 not at the environment variables. Also, when an encoding suffix such
11109 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
11110 category of the locale to "C". */
11111 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
11112 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
11113 return 1;
11114 #else
11115 if (setlocale (LC_ALL, "") == NULL) return 1;
11116 #endif
11117 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
11118 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
11119 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
11120 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
11121 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
11122 some unit tests fail.
11123 On MirBSD 10, when an unsupported locale is specified, setlocale()
11124 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
11125 #if HAVE_LANGINFO_CODESET
11126 {
11127 const char *cs = nl_langinfo (CODESET);
11128 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
11129 || strcmp (cs, "UTF-8") == 0)
11130 return 1;
11131 }
11132 #endif
11133 #ifdef __CYGWIN__
11134 /* On Cygwin, avoid locale names without encoding suffix, because the
11135 locale_charset() function relies on the encoding suffix. Note that
11136 LC_ALL is set on the command line. */
11137 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
11138 #endif
11139 /* Check whether MB_CUR_MAX is > 1. This excludes the dysfunctional locales
11140 on Cygwin 1.5.x. */
11141 if (MB_CUR_MAX == 1)
11142 return 1;
11143 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
11144 This excludes the UTF-8 encoding (except on MirBSD). */
11145 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
11146 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
11147 for (p = buf; *p != '\0'; p++)
11148 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
11149 return 1;
11150 return 0;
11151 }
11152
11153 _ACEOF
11154 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
11155 (eval $ac_link) 2>&5
11156 ac_status=$?
11157 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
11158 test $ac_status = 0; } && test -s conftest$ac_exeext; then
11159 case "$host_os" in
11160 # Handle native Windows specially, because there setlocale() interprets
11161 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
11162 # "fr" or "fra" as "French" or "French_France.1252",
11163 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
11164 # "ja" as "Japanese" or "Japanese_Japan.932",
11165 # and similar.
11166 mingw*)
11167 # Note that on native Windows, the Japanese locale is
11168 # Japanese_Japan.932, and CP932 is very different from EUC-JP, so we
11169 # cannot use it here.
11170 gt_cv_locale_ja=none
11171 ;;
11172 *)
11173 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
11174 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
11175 # configure script would override the LC_ALL setting. Likewise for
11176 # LC_CTYPE, which is also set at the beginning of the configure script.
11177 # Test for the AIX locale name.
11178 if (LC_ALL=ja_JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11179 gt_cv_locale_ja=ja_JP
11180 else
11181 # Test for the locale name with explicit encoding suffix.
11182 if (LC_ALL=ja_JP.EUC-JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11183 gt_cv_locale_ja=ja_JP.EUC-JP
11184 else
11185 # Test for the HP-UX, OSF/1, NetBSD locale name.
11186 if (LC_ALL=ja_JP.eucJP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11187 gt_cv_locale_ja=ja_JP.eucJP
11188 else
11189 # Test for the IRIX, FreeBSD locale name.
11190 if (LC_ALL=ja_JP.EUC LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11191 gt_cv_locale_ja=ja_JP.EUC
11192 else
11193 # Test for the Solaris 7 locale name.
11194 if (LC_ALL=ja LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11195 gt_cv_locale_ja=ja
11196 else
11197 # Special test for NetBSD 1.6.
11198 if test -f /usr/share/locale/ja_JP.eucJP/LC_CTYPE; then
11199 gt_cv_locale_ja=ja_JP.eucJP
11200 else
11201 # None found.
11202 gt_cv_locale_ja=none
11203 fi
11204 fi
11205 fi
11206 fi
11207 fi
11208 fi
11209 ;;
11210 esac
11211 fi
11212 rm -fr conftest*
11213
11214 fi
11215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_ja" >&5
11216 $as_echo "$gt_cv_locale_ja" >&6; }
11217 LOCALE_JA=$gt_cv_locale_ja
11218
11219
11220
11221
11222
11223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a transitional chinese locale" >&5
11224 $as_echo_n "checking for a transitional chinese locale... " >&6; }
11225 if test "${gt_cv_locale_zh_CN+set}" = set; then :
11226 $as_echo_n "(cached) " >&6
11227 else
11228
11229 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11230 /* end confdefs.h. */
11231
11232 #include <locale.h>
11233 #include <stdlib.h>
11234 #include <time.h>
11235 #if HAVE_LANGINFO_CODESET
11236 # include <langinfo.h>
11237 #endif
11238 #include <stdlib.h>
11239 #include <string.h>
11240 struct tm t;
11241 char buf[16];
11242 int main ()
11243 {
11244 const char *p;
11245 /* Check whether the given locale name is recognized by the system. */
11246 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
11247 /* On native Windows, setlocale(category, "") looks at the system settings,
11248 not at the environment variables. Also, when an encoding suffix such
11249 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
11250 category of the locale to "C". */
11251 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
11252 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
11253 return 1;
11254 #else
11255 if (setlocale (LC_ALL, "") == NULL) return 1;
11256 #endif
11257 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
11258 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
11259 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
11260 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
11261 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
11262 some unit tests fail.
11263 On MirBSD 10, when an unsupported locale is specified, setlocale()
11264 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
11265 #if HAVE_LANGINFO_CODESET
11266 {
11267 const char *cs = nl_langinfo (CODESET);
11268 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
11269 || strcmp (cs, "UTF-8") == 0)
11270 return 1;
11271 }
11272 #endif
11273 #ifdef __CYGWIN__
11274 /* On Cygwin, avoid locale names without encoding suffix, because the
11275 locale_charset() function relies on the encoding suffix. Note that
11276 LC_ALL is set on the command line. */
11277 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
11278 #endif
11279 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
11280 This excludes the UTF-8 encoding (except on MirBSD). */
11281 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
11282 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
11283 for (p = buf; *p != '\0'; p++)
11284 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
11285 return 1;
11286 /* Check whether a typical GB18030 multibyte sequence is recognized as a
11287 single wide character. This excludes the GB2312 and GBK encodings. */
11288 if (mblen ("\203\062\332\066", 5) != 4)
11289 return 1;
11290 return 0;
11291 }
11292
11293 _ACEOF
11294 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
11295 (eval $ac_link) 2>&5
11296 ac_status=$?
11297 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
11298 test $ac_status = 0; } && test -s conftest$ac_exeext; then
11299 case "$host_os" in
11300 # Handle native Windows specially, because there setlocale() interprets
11301 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
11302 # "fr" or "fra" as "French" or "French_France.1252",
11303 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
11304 # "ja" as "Japanese" or "Japanese_Japan.932",
11305 # and similar.
11306 mingw*)
11307 # Test for the hypothetical native Windows locale name.
11308 if (LC_ALL=Chinese_China.54936 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11309 gt_cv_locale_zh_CN=Chinese_China.54936
11310 else
11311 # None found.
11312 gt_cv_locale_zh_CN=none
11313 fi
11314 ;;
11315 solaris2.8)
11316 # On Solaris 8, the locales zh_CN.GB18030, zh_CN.GBK, zh.GBK are
11317 # broken. One witness is the test case in gl_MBRTOWC_SANITYCHECK.
11318 # Another witness is that "LC_ALL=zh_CN.GB18030 bash -c true" dumps core.
11319 gt_cv_locale_zh_CN=none
11320 ;;
11321 *)
11322 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
11323 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
11324 # configure script would override the LC_ALL setting. Likewise for
11325 # LC_CTYPE, which is also set at the beginning of the configure script.
11326 # Test for the locale name without encoding suffix.
11327 if (LC_ALL=zh_CN LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11328 gt_cv_locale_zh_CN=zh_CN
11329 else
11330 # Test for the locale name with explicit encoding suffix.
11331 if (LC_ALL=zh_CN.GB18030 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11332 gt_cv_locale_zh_CN=zh_CN.GB18030
11333 else
11334 # None found.
11335 gt_cv_locale_zh_CN=none
11336 fi
11337 fi
11338 ;;
11339 esac
11340 else
11341 # If there was a link error, due to mblen(), the system is so old that
11342 # it certainly doesn't have a chinese locale.
11343 gt_cv_locale_zh_CN=none
11344 fi
11345 rm -fr conftest*
11346
11347 fi
11348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_zh_CN" >&5
11349 $as_echo "$gt_cv_locale_zh_CN" >&6; }
11350 LOCALE_ZH_CN=$gt_cv_locale_zh_CN
11351
11352
11353
11354
11355 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
11356 $as_echo_n "checking for a french Unicode locale... " >&6; }
11357 if test "${gt_cv_locale_fr_utf8+set}" = set; then :
11358 $as_echo_n "(cached) " >&6
11359 else
11360
11361 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11362 /* end confdefs.h. */
11363
11364 #include <locale.h>
11365 #include <time.h>
11366 #if HAVE_LANGINFO_CODESET
11367 # include <langinfo.h>
11368 #endif
11369 #include <stdlib.h>
11370 #include <string.h>
11371 struct tm t;
11372 char buf[16];
11373 int main () {
11374 /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
11375 imitates locale dependent behaviour by looking at the environment
11376 variables, and all locales use the UTF-8 encoding. */
11377 #if !(defined __BEOS__ || defined __HAIKU__)
11378 /* Check whether the given locale name is recognized by the system. */
11379 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
11380 /* On native Windows, setlocale(category, "") looks at the system settings,
11381 not at the environment variables. Also, when an encoding suffix such
11382 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
11383 category of the locale to "C". */
11384 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
11385 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
11386 return 1;
11387 # else
11388 if (setlocale (LC_ALL, "") == NULL) return 1;
11389 # endif
11390 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
11391 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
11392 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
11393 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
11394 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
11395 some unit tests fail. */
11396 # if HAVE_LANGINFO_CODESET
11397 {
11398 const char *cs = nl_langinfo (CODESET);
11399 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
11400 return 1;
11401 }
11402 # endif
11403 # ifdef __CYGWIN__
11404 /* On Cygwin, avoid locale names without encoding suffix, because the
11405 locale_charset() function relies on the encoding suffix. Note that
11406 LC_ALL is set on the command line. */
11407 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
11408 # endif
11409 /* Check whether in the abbreviation of the second month, the second
11410 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
11411 two bytes long, with UTF-8 encoding. */
11412 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
11413 if (strftime (buf, sizeof (buf), "%b", &t) < 4
11414 || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
11415 return 1;
11416 #endif
11417 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
11418 /* Check whether the decimal separator is a comma.
11419 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
11420 are nl_langinfo(RADIXCHAR) are both ".". */
11421 if (localeconv () ->decimal_point[0] != ',') return 1;
11422 #endif
11423 return 0;
11424 }
11425
11426 _ACEOF
11427 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
11428 (eval $ac_link) 2>&5
11429 ac_status=$?
11430 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
11431 test $ac_status = 0; } && test -s conftest$ac_exeext; then
11432 case "$host_os" in
11433 # Handle native Windows specially, because there setlocale() interprets
11434 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
11435 # "fr" or "fra" as "French" or "French_France.1252",
11436 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
11437 # "ja" as "Japanese" or "Japanese_Japan.932",
11438 # and similar.
11439 mingw*)
11440 # Test for the hypothetical native Windows locale name.
11441 if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11442 gt_cv_locale_fr_utf8=French_France.65001
11443 else
11444 # None found.
11445 gt_cv_locale_fr_utf8=none
11446 fi
11447 ;;
11448 *)
11449 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
11450 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
11451 # configure script would override the LC_ALL setting. Likewise for
11452 # LC_CTYPE, which is also set at the beginning of the configure script.
11453 # Test for the usual locale name.
11454 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11455 gt_cv_locale_fr_utf8=fr_FR
11456 else
11457 # Test for the locale name with explicit encoding suffix.
11458 if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11459 gt_cv_locale_fr_utf8=fr_FR.UTF-8
11460 else
11461 # Test for the Solaris 7 locale name.
11462 if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11463 gt_cv_locale_fr_utf8=fr.UTF-8
11464 else
11465 # None found.
11466 gt_cv_locale_fr_utf8=none
11467 fi
11468 fi
11469 fi
11470 ;;
11471 esac
11472 fi
11473 rm -fr conftest*
11474
11475 fi
11476 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
11477 $as_echo "$gt_cv_locale_fr_utf8" >&6; }
11478 LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
11479
11480
11481
11482
11483
11484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
11485 $as_echo_n "checking for a traditional french locale... " >&6; }
11486 if test "${gt_cv_locale_fr+set}" = set; then :
11487 $as_echo_n "(cached) " >&6
11488 else
11489
11490 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11491 /* end confdefs.h. */
11492
11493 #include <locale.h>
11494 #include <time.h>
11495 #if HAVE_LANGINFO_CODESET
11496 # include <langinfo.h>
11497 #endif
11498 #include <stdlib.h>
11499 #include <string.h>
11500 struct tm t;
11501 char buf[16];
11502 int main () {
11503 /* Check whether the given locale name is recognized by the system. */
11504 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
11505 /* On native Windows, setlocale(category, "") looks at the system settings,
11506 not at the environment variables. Also, when an encoding suffix such
11507 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
11508 category of the locale to "C". */
11509 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
11510 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
11511 return 1;
11512 #else
11513 if (setlocale (LC_ALL, "") == NULL) return 1;
11514 #endif
11515 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
11516 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
11517 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
11518 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
11519 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
11520 some unit tests fail.
11521 On MirBSD 10, when an unsupported locale is specified, setlocale()
11522 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
11523 #if HAVE_LANGINFO_CODESET
11524 {
11525 const char *cs = nl_langinfo (CODESET);
11526 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
11527 || strcmp (cs, "UTF-8") == 0)
11528 return 1;
11529 }
11530 #endif
11531 #ifdef __CYGWIN__
11532 /* On Cygwin, avoid locale names without encoding suffix, because the
11533 locale_charset() function relies on the encoding suffix. Note that
11534 LC_ALL is set on the command line. */
11535 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
11536 #endif
11537 /* Check whether in the abbreviation of the second month, the second
11538 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
11539 one byte long. This excludes the UTF-8 encoding. */
11540 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
11541 if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
11542 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
11543 /* Check whether the decimal separator is a comma.
11544 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
11545 are nl_langinfo(RADIXCHAR) are both ".". */
11546 if (localeconv () ->decimal_point[0] != ',') return 1;
11547 #endif
11548 return 0;
11549 }
11550
11551 _ACEOF
11552 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
11553 (eval $ac_link) 2>&5
11554 ac_status=$?
11555 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
11556 test $ac_status = 0; } && test -s conftest$ac_exeext; then
11557 case "$host_os" in
11558 # Handle native Windows specially, because there setlocale() interprets
11559 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
11560 # "fr" or "fra" as "French" or "French_France.1252",
11561 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
11562 # "ja" as "Japanese" or "Japanese_Japan.932",
11563 # and similar.
11564 mingw*)
11565 # Test for the native Windows locale name.
11566 if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11567 gt_cv_locale_fr=French_France.1252
11568 else
11569 # None found.
11570 gt_cv_locale_fr=none
11571 fi
11572 ;;
11573 *)
11574 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
11575 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
11576 # configure script would override the LC_ALL setting. Likewise for
11577 # LC_CTYPE, which is also set at the beginning of the configure script.
11578 # Test for the usual locale name.
11579 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11580 gt_cv_locale_fr=fr_FR
11581 else
11582 # Test for the locale name with explicit encoding suffix.
11583 if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11584 gt_cv_locale_fr=fr_FR.ISO-8859-1
11585 else
11586 # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
11587 if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11588 gt_cv_locale_fr=fr_FR.ISO8859-1
11589 else
11590 # Test for the HP-UX locale name.
11591 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11592 gt_cv_locale_fr=fr_FR.iso88591
11593 else
11594 # Test for the Solaris 7 locale name.
11595 if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11596 gt_cv_locale_fr=fr
11597 else
11598 # None found.
11599 gt_cv_locale_fr=none
11600 fi
11601 fi
11602 fi
11603 fi
11604 fi
11605 ;;
11606 esac
11607 fi
11608 rm -fr conftest*
11609
11610 fi
11611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
11612 $as_echo "$gt_cv_locale_fr" >&6; }
11613 LOCALE_FR=$gt_cv_locale_fr
11614
11615
11616
11617
11618
11619
11620
11621 GNULIB_FFSL=0;
11622 GNULIB_FFSLL=0;
11623 GNULIB_MEMCHR=0;
11624 GNULIB_MEMMEM=0;
11625 GNULIB_MEMPCPY=0;
11626 GNULIB_MEMRCHR=0;
11627 GNULIB_RAWMEMCHR=0;
11628 GNULIB_STPCPY=0;
11629 GNULIB_STPNCPY=0;
11630 GNULIB_STRCHRNUL=0;
11631 GNULIB_STRDUP=0;
11632 GNULIB_STRNCAT=0;
11633 GNULIB_STRNDUP=0;
11634 GNULIB_STRNLEN=0;
11635 GNULIB_STRPBRK=0;
11636 GNULIB_STRSEP=0;
11637 GNULIB_STRSTR=0;
11638 GNULIB_STRCASESTR=0;
11639 GNULIB_STRTOK_R=0;
11640 GNULIB_MBSLEN=0;
11641 GNULIB_MBSNLEN=0;
11642 GNULIB_MBSCHR=0;
11643 GNULIB_MBSRCHR=0;
11644 GNULIB_MBSSTR=0;
11645 GNULIB_MBSCASECMP=0;
11646 GNULIB_MBSNCASECMP=0;
11647 GNULIB_MBSPCASECMP=0;
11648 GNULIB_MBSCASESTR=0;
11649 GNULIB_MBSCSPN=0;
11650 GNULIB_MBSPBRK=0;
11651 GNULIB_MBSSPN=0;
11652 GNULIB_MBSSEP=0;
11653 GNULIB_MBSTOK_R=0;
11654 GNULIB_STRERROR=0;
11655 GNULIB_STRERROR_R=0;
11656 GNULIB_STRSIGNAL=0;
11657 GNULIB_STRVERSCMP=0;
11658 HAVE_MBSLEN=0;
11659 HAVE_FFSL=1;
11660 HAVE_FFSLL=1;
11661 HAVE_MEMCHR=1;
11662 HAVE_DECL_MEMMEM=1;
11663 HAVE_MEMPCPY=1;
11664 HAVE_DECL_MEMRCHR=1;
11665 HAVE_RAWMEMCHR=1;
11666 HAVE_STPCPY=1;
11667 HAVE_STPNCPY=1;
11668 HAVE_STRCHRNUL=1;
11669 HAVE_DECL_STRDUP=1;
11670 HAVE_DECL_STRNDUP=1;
11671 HAVE_DECL_STRNLEN=1;
11672 HAVE_STRPBRK=1;
11673 HAVE_STRSEP=1;
11674 HAVE_STRCASESTR=1;
11675 HAVE_DECL_STRTOK_R=1;
11676 HAVE_DECL_STRERROR_R=1;
11677 HAVE_DECL_STRSIGNAL=1;
11678 HAVE_STRVERSCMP=1;
11679 REPLACE_MEMCHR=0;
11680 REPLACE_MEMMEM=0;
11681 REPLACE_STPNCPY=0;
11682 REPLACE_STRDUP=0;
11683 REPLACE_STRSTR=0;
11684 REPLACE_STRCASESTR=0;
11685 REPLACE_STRCHRNUL=0;
11686 REPLACE_STRERROR=0;
11687 REPLACE_STRERROR_R=0;
11688 REPLACE_STRNCAT=0;
11689 REPLACE_STRNDUP=0;
11690 REPLACE_STRNLEN=0;
11691 REPLACE_STRSIGNAL=0;
11692 REPLACE_STRTOK_R=0;
11693 UNDEFINE_STRTOK_R=0;
11694
11695
11696
11697
11698
11699 # Check for mmap(). Don't use AC_FUNC_MMAP, because it checks too much: it
11700 # fails on HP-UX 11, because MAP_FIXED mappings do not work. But this is
11701 # irrelevant for anonymous mappings.
11702 ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap"
11703 if test "x$ac_cv_func_mmap" = x""yes; then :
11704 gl_have_mmap=yes
11705 else
11706 gl_have_mmap=no
11707 fi
11708
11709
11710 # Try to allow MAP_ANONYMOUS.
11711 gl_have_mmap_anonymous=no
11712 if test $gl_have_mmap = yes; then
11713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAP_ANONYMOUS" >&5
11714 $as_echo_n "checking for MAP_ANONYMOUS... " >&6; }
11715 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11716 /* end confdefs.h. */
11717
11718 #include <sys/mman.h>
11719 #ifdef MAP_ANONYMOUS
11720 I cannot identify this map
11721 #endif
11722
11723 _ACEOF
11724 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11725 $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
11726 gl_have_mmap_anonymous=yes
11727 fi
11728 rm -f conftest*
11729
11730 if test $gl_have_mmap_anonymous != yes; then
11731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11732 /* end confdefs.h. */
11733
11734 #include <sys/mman.h>
11735 #ifdef MAP_ANON
11736 I cannot identify this map
11737 #endif
11738
11739 _ACEOF
11740 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11741 $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
11742
11743 $as_echo "#define MAP_ANONYMOUS MAP_ANON" >>confdefs.h
11744
11745 gl_have_mmap_anonymous=yes
11746 fi
11747 rm -f conftest*
11748
11749 fi
11750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_have_mmap_anonymous" >&5
11751 $as_echo "$gl_have_mmap_anonymous" >&6; }
11752 if test $gl_have_mmap_anonymous = yes; then
11753
11754 $as_echo "#define HAVE_MAP_ANONYMOUS 1" >>confdefs.h
11755
11756 fi
11757 fi
11758
11759
11760
11761
11762
11763
11764 if test $HAVE_MEMCHR = 1; then
11765 # Detect platform-specific bugs in some versions of glibc:
11766 # memchr should not dereference anything with length 0
11767 # http://bugzilla.redhat.com/499689
11768 # memchr should not dereference overestimated length after a match
11769 # http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=521737
11770 # http://sourceware.org/bugzilla/show_bug.cgi?id=10162
11771 # Assume that memchr works on platforms that lack mprotect.
11772 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memchr works" >&5
11773 $as_echo_n "checking whether memchr works... " >&6; }
11774 if test "${gl_cv_func_memchr_works+set}" = set; then :
11775 $as_echo_n "(cached) " >&6
11776 else
11777 if test "$cross_compiling" = yes; then :
11778 gl_cv_func_memchr_works="guessing no"
11779 else
11780 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11781 /* end confdefs.h. */
11782
11783 #include <string.h>
11784 #if HAVE_SYS_MMAN_H
11785 # include <fcntl.h>
11786 # include <unistd.h>
11787 # include <sys/types.h>
11788 # include <sys/mman.h>
11789 # ifndef MAP_FILE
11790 # define MAP_FILE 0
11791 # endif
11792 #endif
11793
11794 int
11795 main ()
11796 {
11797
11798 int result = 0;
11799 char *fence = NULL;
11800 #if HAVE_SYS_MMAN_H && HAVE_MPROTECT
11801 # if HAVE_MAP_ANONYMOUS
11802 const int flags = MAP_ANONYMOUS | MAP_PRIVATE;
11803 const int fd = -1;
11804 # else /* !HAVE_MAP_ANONYMOUS */
11805 const int flags = MAP_FILE | MAP_PRIVATE;
11806 int fd = open ("/dev/zero", O_RDONLY, 0666);
11807 if (fd >= 0)
11808 # endif
11809 {
11810 int pagesize = getpagesize ();
11811 char *two_pages =
11812 (char *) mmap (NULL, 2 * pagesize, PROT_READ | PROT_WRITE,
11813 flags, fd, 0);
11814 if (two_pages != (char *)(-1)
11815 && mprotect (two_pages + pagesize, pagesize, PROT_NONE) == 0)
11816 fence = two_pages + pagesize;
11817 }
11818 #endif
11819 if (fence)
11820 {
11821 if (memchr (fence, 0, 0))
11822 result |= 1;
11823 strcpy (fence - 9, "12345678");
11824 if (memchr (fence - 9, 0, 79) != fence - 1)
11825 result |= 2;
11826 if (memchr (fence - 1, 0, 3) != fence - 1)
11827 result |= 4;
11828 }
11829 return result;
11830
11831 ;
11832 return 0;
11833 }
11834 _ACEOF
11835 if ac_fn_c_try_run "$LINENO"; then :
11836 gl_cv_func_memchr_works=yes
11837 else
11838 gl_cv_func_memchr_works=no
11839 fi
11840 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11841 conftest.$ac_objext conftest.beam conftest.$ac_ext
11842 fi
11843
11844 fi
11845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memchr_works" >&5
11846 $as_echo "$gl_cv_func_memchr_works" >&6; }
11847 if test "$gl_cv_func_memchr_works" != yes; then
11848 REPLACE_MEMCHR=1
11849 fi
11850 fi
11851
11852 ac_fn_c_check_decl "$LINENO" "memmem" "ac_cv_have_decl_memmem" "$ac_includes_default"
11853 if test "x$ac_cv_have_decl_memmem" = x""yes; then :
11854 ac_have_decl=1
11855 else
11856 ac_have_decl=0
11857 fi
11858
11859 cat >>confdefs.h <<_ACEOF
11860 #define HAVE_DECL_MEMMEM $ac_have_decl
11861 _ACEOF
11862
11863
11864
11865
11866
11867 for ac_func in memmem
11868 do :
11869 ac_fn_c_check_func "$LINENO" "memmem" "ac_cv_func_memmem"
11870 if test "x$ac_cv_func_memmem" = x""yes; then :
11871 cat >>confdefs.h <<_ACEOF
11872 #define HAVE_MEMMEM 1
11873 _ACEOF
11874
11875 fi
11876 done
11877
11878 if test $ac_cv_func_memmem = yes; then
11879 HAVE_MEMMEM=1
11880 else
11881 HAVE_MEMMEM=0
11882 fi
11883
11884 if test $ac_cv_have_decl_memmem = no; then
11885 HAVE_DECL_MEMMEM=0
11886 else
11887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memmem works" >&5
11888 $as_echo_n "checking whether memmem works... " >&6; }
11889 if test "${gl_cv_func_memmem_works_always+set}" = set; then :
11890 $as_echo_n "(cached) " >&6
11891 else
11892 if test "$cross_compiling" = yes; then :
11893 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11894 /* end confdefs.h. */
11895
11896 #ifdef __GNU_LIBRARY__
11897 #include <features.h>
11898 #if ((__GLIBC__ == 2 && ((__GLIBC_MINOR > 0 && __GLIBC_MINOR__ < 9) \
11899 || __GLIBC_MINOR__ > 12)) \
11900 || (__GLIBC__ > 2)) \
11901 || defined __UCLIBC__
11902 Lucky user
11903 #endif
11904 #elif defined __CYGWIN__
11905 #include <cygwin/version.h>
11906 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
11907 Lucky user
11908 #endif
11909 #else
11910 Lucky user
11911 #endif
11912
11913 _ACEOF
11914 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11915 $EGREP "Lucky user" >/dev/null 2>&1; then :
11916 gl_cv_func_memmem_works_always="guessing yes"
11917 else
11918 gl_cv_func_memmem_works_always="guessing no"
11919 fi
11920 rm -f conftest*
11921
11922
11923 else
11924 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11925 /* end confdefs.h. */
11926
11927 #include <string.h> /* for memmem */
11928 #define P "_EF_BF_BD"
11929 #define HAYSTACK "F_BD_CE_BD" P P P P "_C3_88_20" P P P "_C3_A7_20" P
11930 #define NEEDLE P P P P P
11931
11932 int
11933 main ()
11934 {
11935
11936 int result = 0;
11937 if (memmem (HAYSTACK, strlen (HAYSTACK), NEEDLE, strlen (NEEDLE)))
11938 result |= 1;
11939 /* Check for empty needle behavior. */
11940 {
11941 const char *haystack = "AAA";
11942 if (memmem (haystack, 3, NULL, 0) != haystack)
11943 result |= 2;
11944 }
11945 return result;
11946
11947 ;
11948 return 0;
11949 }
11950 _ACEOF
11951 if ac_fn_c_try_run "$LINENO"; then :
11952 gl_cv_func_memmem_works_always=yes
11953 else
11954 gl_cv_func_memmem_works_always=no
11955 fi
11956 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11957 conftest.$ac_objext conftest.beam conftest.$ac_ext
11958 fi
11959
11960
11961 fi
11962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memmem_works_always" >&5
11963 $as_echo "$gl_cv_func_memmem_works_always" >&6; }
11964 case "$gl_cv_func_memmem_works_always" in
11965 *yes) ;;
11966 *)
11967 REPLACE_MEMMEM=1
11968 ;;
11969 esac
11970 fi
11971 :
11972
11973 ac_fn_c_check_decl "$LINENO" "memrchr" "ac_cv_have_decl_memrchr" "$ac_includes_default"
11974 if test "x$ac_cv_have_decl_memrchr" = x""yes; then :
11975 ac_have_decl=1
11976 else
11977 ac_have_decl=0
11978 fi
11979
11980 cat >>confdefs.h <<_ACEOF
11981 #define HAVE_DECL_MEMRCHR $ac_have_decl
11982 _ACEOF
11983
11984
11985
11986
11987
11988
11989
11990
11991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for promoted mode_t type" >&5
11992 $as_echo_n "checking for promoted mode_t type... " >&6; }
11993 if test "${gl_cv_promoted_mode_t+set}" = set; then :
11994 $as_echo_n "(cached) " >&6
11995 else
11996
11997 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11998 /* end confdefs.h. */
11999 #include <sys/types.h>
12000 int
12001 main ()
12002 {
12003 typedef int array[2 * (sizeof (mode_t) < sizeof (int)) - 1];
12004 ;
12005 return 0;
12006 }
12007 _ACEOF
12008 if ac_fn_c_try_compile "$LINENO"; then :
12009 gl_cv_promoted_mode_t='int'
12010 else
12011 gl_cv_promoted_mode_t='mode_t'
12012 fi
12013 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12014
12015 fi
12016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_promoted_mode_t" >&5
12017 $as_echo "$gl_cv_promoted_mode_t" >&6; }
12018
12019 cat >>confdefs.h <<_ACEOF
12020 #define PROMOTED_MODE_T $gl_cv_promoted_mode_t
12021 _ACEOF
12022
12023
12024
12025
12026
12027 GNULIB_DPRINTF=0;
12028 GNULIB_FCLOSE=0;
12029 GNULIB_FDOPEN=0;
12030 GNULIB_FFLUSH=0;
12031 GNULIB_FGETC=0;
12032 GNULIB_FGETS=0;
12033 GNULIB_FOPEN=0;
12034 GNULIB_FPRINTF=0;
12035 GNULIB_FPRINTF_POSIX=0;
12036 GNULIB_FPURGE=0;
12037 GNULIB_FPUTC=0;
12038 GNULIB_FPUTS=0;
12039 GNULIB_FREAD=0;
12040 GNULIB_FREOPEN=0;
12041 GNULIB_FSCANF=0;
12042 GNULIB_FSEEK=0;
12043 GNULIB_FSEEKO=0;
12044 GNULIB_FTELL=0;
12045 GNULIB_FTELLO=0;
12046 GNULIB_FWRITE=0;
12047 GNULIB_GETC=0;
12048 GNULIB_GETCHAR=0;
12049 GNULIB_GETDELIM=0;
12050 GNULIB_GETLINE=0;
12051 GNULIB_OBSTACK_PRINTF=0;
12052 GNULIB_OBSTACK_PRINTF_POSIX=0;
12053 GNULIB_PCLOSE=0;
12054 GNULIB_PERROR=0;
12055 GNULIB_POPEN=0;
12056 GNULIB_PRINTF=0;
12057 GNULIB_PRINTF_POSIX=0;
12058 GNULIB_PUTC=0;
12059 GNULIB_PUTCHAR=0;
12060 GNULIB_PUTS=0;
12061 GNULIB_REMOVE=0;
12062 GNULIB_RENAME=0;
12063 GNULIB_RENAMEAT=0;
12064 GNULIB_SCANF=0;
12065 GNULIB_SNPRINTF=0;
12066 GNULIB_SPRINTF_POSIX=0;
12067 GNULIB_STDIO_H_NONBLOCKING=0;
12068 GNULIB_STDIO_H_SIGPIPE=0;
12069 GNULIB_TMPFILE=0;
12070 GNULIB_VASPRINTF=0;
12071 GNULIB_VFSCANF=0;
12072 GNULIB_VSCANF=0;
12073 GNULIB_VDPRINTF=0;
12074 GNULIB_VFPRINTF=0;
12075 GNULIB_VFPRINTF_POSIX=0;
12076 GNULIB_VPRINTF=0;
12077 GNULIB_VPRINTF_POSIX=0;
12078 GNULIB_VSNPRINTF=0;
12079 GNULIB_VSPRINTF_POSIX=0;
12080 HAVE_DECL_FPURGE=1;
12081 HAVE_DECL_FSEEKO=1;
12082 HAVE_DECL_FTELLO=1;
12083 HAVE_DECL_GETDELIM=1;
12084 HAVE_DECL_GETLINE=1;
12085 HAVE_DECL_OBSTACK_PRINTF=1;
12086 HAVE_DECL_SNPRINTF=1;
12087 HAVE_DECL_VSNPRINTF=1;
12088 HAVE_DPRINTF=1;
12089 HAVE_FSEEKO=1;
12090 HAVE_FTELLO=1;
12091 HAVE_PCLOSE=1;
12092 HAVE_POPEN=1;
12093 HAVE_RENAMEAT=1;
12094 HAVE_VASPRINTF=1;
12095 HAVE_VDPRINTF=1;
12096 REPLACE_DPRINTF=0;
12097 REPLACE_FCLOSE=0;
12098 REPLACE_FDOPEN=0;
12099 REPLACE_FFLUSH=0;
12100 REPLACE_FOPEN=0;
12101 REPLACE_FPRINTF=0;
12102 REPLACE_FPURGE=0;
12103 REPLACE_FREOPEN=0;
12104 REPLACE_FSEEK=0;
12105 REPLACE_FSEEKO=0;
12106 REPLACE_FTELL=0;
12107 REPLACE_FTELLO=0;
12108 REPLACE_GETDELIM=0;
12109 REPLACE_GETLINE=0;
12110 REPLACE_OBSTACK_PRINTF=0;
12111 REPLACE_PERROR=0;
12112 REPLACE_POPEN=0;
12113 REPLACE_PRINTF=0;
12114 REPLACE_REMOVE=0;
12115 REPLACE_RENAME=0;
12116 REPLACE_RENAMEAT=0;
12117 REPLACE_SNPRINTF=0;
12118 REPLACE_SPRINTF=0;
12119 REPLACE_STDIO_READ_FUNCS=0;
12120 REPLACE_STDIO_WRITE_FUNCS=0;
12121 REPLACE_TMPFILE=0;
12122 REPLACE_VASPRINTF=0;
12123 REPLACE_VDPRINTF=0;
12124 REPLACE_VFPRINTF=0;
12125 REPLACE_VPRINTF=0;
12126 REPLACE_VSNPRINTF=0;
12127 REPLACE_VSPRINTF=0;
12128
12129
12130
12131
12132
12133
12134
12135
12136
12137
12138
12139
12140
12141 ac_fn_c_check_decl "$LINENO" "setenv" "ac_cv_have_decl_setenv" "$ac_includes_default"
12142 if test "x$ac_cv_have_decl_setenv" = x""yes; then :
12143 ac_have_decl=1
12144 else
12145 ac_have_decl=0
12146 fi
12147
12148 cat >>confdefs.h <<_ACEOF
12149 #define HAVE_DECL_SETENV $ac_have_decl
12150 _ACEOF
12151
12152
12153
12154
12155
12156
12157 if test $ac_cv_have_decl_setenv = no; then
12158 HAVE_DECL_SETENV=0
12159 fi
12160
12161
12162
12163
12164
12165 for ac_header in search.h
12166 do :
12167 ac_fn_c_check_header_mongrel "$LINENO" "search.h" "ac_cv_header_search_h" "$ac_includes_default"
12168 if test "x$ac_cv_header_search_h" = x""yes; then :
12169 cat >>confdefs.h <<_ACEOF
12170 #define HAVE_SEARCH_H 1
12171 _ACEOF
12172
12173 fi
12174
12175 done
12176
12177 for ac_func in tsearch
12178 do :
12179 ac_fn_c_check_func "$LINENO" "tsearch" "ac_cv_func_tsearch"
12180 if test "x$ac_cv_func_tsearch" = x""yes; then :
12181 cat >>confdefs.h <<_ACEOF
12182 #define HAVE_TSEARCH 1
12183 _ACEOF
12184
12185 fi
12186 done
12187
12188
12189
12190
12191 GNULIB_PTHREAD_SIGMASK=0;
12192 GNULIB_RAISE=0;
12193 GNULIB_SIGNAL_H_SIGPIPE=0;
12194 GNULIB_SIGPROCMASK=0;
12195 GNULIB_SIGACTION=0;
12196 HAVE_POSIX_SIGNALBLOCKING=1;
12197 HAVE_PTHREAD_SIGMASK=1;
12198 HAVE_RAISE=1;
12199 HAVE_SIGSET_T=1;
12200 HAVE_SIGINFO_T=1;
12201 HAVE_SIGACTION=1;
12202 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
12203
12204 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
12205
12206 HAVE_SIGHANDLER_T=1;
12207 REPLACE_PTHREAD_SIGMASK=0;
12208 REPLACE_RAISE=0;
12209
12210
12211 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
12212 #include <signal.h>
12213 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
12214 #include <sys/types.h>
12215
12216 "
12217 if test "x$ac_cv_type_sigset_t" = x""yes; then :
12218
12219 cat >>confdefs.h <<_ACEOF
12220 #define HAVE_SIGSET_T 1
12221 _ACEOF
12222
12223 gl_cv_type_sigset_t=yes
12224 else
12225 gl_cv_type_sigset_t=no
12226 fi
12227
12228 if test $gl_cv_type_sigset_t != yes; then
12229 HAVE_SIGSET_T=0
12230 fi
12231
12232 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
12233 $as_echo_n "checking for uid_t in sys/types.h... " >&6; }
12234 if test "${ac_cv_type_uid_t+set}" = set; then :
12235 $as_echo_n "(cached) " >&6
12236 else
12237 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12238 /* end confdefs.h. */
12239 #include <sys/types.h>
12240
12241 _ACEOF
12242 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12243 $EGREP "uid_t" >/dev/null 2>&1; then :
12244 ac_cv_type_uid_t=yes
12245 else
12246 ac_cv_type_uid_t=no
12247 fi
12248 rm -f conftest*
12249
12250 fi
12251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
12252 $as_echo "$ac_cv_type_uid_t" >&6; }
12253 if test $ac_cv_type_uid_t = no; then
12254
12255 $as_echo "#define uid_t int" >>confdefs.h
12256
12257
12258 $as_echo "#define gid_t int" >>confdefs.h
12259
12260 fi
12261
12262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
12263 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
12264 if test "${ac_cv_header_stdbool_h+set}" = set; then :
12265 $as_echo_n "(cached) " >&6
12266 else
12267 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12268 /* end confdefs.h. */
12269
12270 #include <stdbool.h>
12271
12272 #ifdef __cplusplus
12273 typedef bool Bool;
12274 #else
12275 typedef _Bool Bool;
12276 #ifndef bool
12277 "error: bool is not defined"
12278 #endif
12279 #ifndef false
12280 "error: false is not defined"
12281 #endif
12282 #if false
12283 "error: false is not 0"
12284 #endif
12285 #ifndef true
12286 "error: true is not defined"
12287 #endif
12288 #if true != 1
12289 "error: true is not 1"
12290 #endif
12291 #endif
12292
12293 #ifndef __bool_true_false_are_defined
12294 "error: __bool_true_false_are_defined is not defined"
12295 #endif
12296
12297 struct s { Bool s: 1; Bool t; bool u: 1; bool v; } s;
12298
12299 char a[true == 1 ? 1 : -1];
12300 char b[false == 0 ? 1 : -1];
12301 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
12302 char d[(bool) 0.5 == true ? 1 : -1];
12303 /* See body of main program for 'e'. */
12304 char f[(Bool) 0.0 == false ? 1 : -1];
12305 char g[true];
12306 char h[sizeof (Bool)];
12307 char i[sizeof s.t];
12308 enum { j = false, k = true, l = false * true, m = true * 256 };
12309 /* The following fails for
12310 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
12311 Bool n[m];
12312 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
12313 char p[-1 - (Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
12314 /* Catch a bug in an HP-UX C compiler. See
12315 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
12316 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
12317 */
12318 Bool q = true;
12319 Bool *pq = &q;
12320 bool *qq = &q;
12321
12322 int
12323 main ()
12324 {
12325
12326 bool e = &s;
12327 *pq |= q; *pq |= ! q;
12328 *qq |= q; *qq |= ! q;
12329 /* Refer to every declared value, to avoid compiler optimizations. */
12330 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
12331 + !m + !n + !o + !p + !q + !pq + !qq);
12332
12333 ;
12334 return 0;
12335 }
12336 _ACEOF
12337 if ac_fn_c_try_compile "$LINENO"; then :
12338 ac_cv_header_stdbool_h=yes
12339 else
12340 ac_cv_header_stdbool_h=no
12341 fi
12342 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12343 fi
12344 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
12345 $as_echo "$ac_cv_header_stdbool_h" >&6; }
12346 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
12347 if test "x$ac_cv_type__Bool" = x""yes; then :
12348
12349 cat >>confdefs.h <<_ACEOF
12350 #define HAVE__BOOL 1
12351 _ACEOF
12352
12353
12354 fi
12355
12356
12357
12358 REPLACE_NULL=0;
12359 HAVE_MAX_ALIGN_T=1;
12360 HAVE_WCHAR_T=1;
12361
12362
12363 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
12364 $as_echo_n "checking for wchar_t... " >&6; }
12365 if test "${gt_cv_c_wchar_t+set}" = set; then :
12366 $as_echo_n "(cached) " >&6
12367 else
12368 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12369 /* end confdefs.h. */
12370 #include <stddef.h>
12371 wchar_t foo = (wchar_t)'\0';
12372 int
12373 main ()
12374 {
12375
12376 ;
12377 return 0;
12378 }
12379 _ACEOF
12380 if ac_fn_c_try_compile "$LINENO"; then :
12381 gt_cv_c_wchar_t=yes
12382 else
12383 gt_cv_c_wchar_t=no
12384 fi
12385 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12386 fi
12387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
12388 $as_echo "$gt_cv_c_wchar_t" >&6; }
12389 if test $gt_cv_c_wchar_t = yes; then
12390
12391 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
12392
12393 fi
12394
12395
12396
12397 ac_fn_c_check_decl "$LINENO" "strdup" "ac_cv_have_decl_strdup" "$ac_includes_default"
12398 if test "x$ac_cv_have_decl_strdup" = x""yes; then :
12399 ac_have_decl=1
12400 else
12401 ac_have_decl=0
12402 fi
12403
12404 cat >>confdefs.h <<_ACEOF
12405 #define HAVE_DECL_STRDUP $ac_have_decl
12406 _ACEOF
12407
12408
12409 REPLACE_STRERROR_0=0
12410 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror(0) succeeds" >&5
12411 $as_echo_n "checking whether strerror(0) succeeds... " >&6; }
12412 if test "${gl_cv_func_strerror_0_works+set}" = set; then :
12413 $as_echo_n "(cached) " >&6
12414 else
12415 if test "$cross_compiling" = yes; then :
12416 case "$host_os" in
12417 # Guess yes on glibc systems.
12418 *-gnu*) gl_cv_func_strerror_0_works="guessing yes" ;;
12419 # If we don't know, assume the worst.
12420 *) gl_cv_func_strerror_0_works="guessing no" ;;
12421 esac
12422
12423 else
12424 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12425 /* end confdefs.h. */
12426 #include <string.h>
12427 #include <errno.h>
12428
12429 int
12430 main ()
12431 {
12432 int result = 0;
12433 char *str;
12434 errno = 0;
12435 str = strerror (0);
12436 if (!*str) result |= 1;
12437 if (errno) result |= 2;
12438 if (strstr (str, "nknown") || strstr (str, "ndefined"))
12439 result |= 4;
12440 return result;
12441 ;
12442 return 0;
12443 }
12444 _ACEOF
12445 if ac_fn_c_try_run "$LINENO"; then :
12446 gl_cv_func_strerror_0_works=yes
12447 else
12448 gl_cv_func_strerror_0_works=no
12449 fi
12450 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12451 conftest.$ac_objext conftest.beam conftest.$ac_ext
12452 fi
12453
12454
12455 fi
12456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strerror_0_works" >&5
12457 $as_echo "$gl_cv_func_strerror_0_works" >&6; }
12458 case "$gl_cv_func_strerror_0_works" in
12459 *yes) ;;
12460 *)
12461 REPLACE_STRERROR_0=1
12462
12463 $as_echo "#define REPLACE_STRERROR_0 1" >>confdefs.h
12464
12465 ;;
12466 esac
12467
12468
12469
12470
12471
12472
12473
12474
12475
12476
12477
12478
12479 if test $gl_cv_have_include_next = yes; then
12480 gl_cv_next_string_h='<'string.h'>'
12481 else
12482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <string.h>" >&5
12483 $as_echo_n "checking absolute name of <string.h>... " >&6; }
12484 if test "${gl_cv_next_string_h+set}" = set; then :
12485 $as_echo_n "(cached) " >&6
12486 else
12487
12488
12489
12490 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12491 /* end confdefs.h. */
12492 #include <string.h>
12493 _ACEOF
12494 case "$host_os" in
12495 aix*) gl_absname_cpp="$ac_cpp -C" ;;
12496 *) gl_absname_cpp="$ac_cpp" ;;
12497 esac
12498
12499 case "$host_os" in
12500 mingw*)
12501 gl_dirsep_regex='[/\\]'
12502 ;;
12503 *)
12504 gl_dirsep_regex='\/'
12505 ;;
12506 esac
12507 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
12508 gl_header_literal_regex=`echo 'string.h' \
12509 | sed -e "$gl_make_literal_regex_sed"`
12510 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
12511 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
12512 s|^/[^/]|//&|
12513 p
12514 q
12515 }'
12516
12517 gl_cv_absolute_string_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
12518 sed -n "$gl_absolute_header_sed"`
12519
12520 gl_header=$gl_cv_absolute_string_h
12521 gl_cv_next_string_h='"'$gl_header'"'
12522
12523
12524 fi
12525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_string_h" >&5
12526 $as_echo "$gl_cv_next_string_h" >&6; }
12527 fi
12528 NEXT_STRING_H=$gl_cv_next_string_h
12529
12530 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
12531 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
12532 gl_next_as_first_directive='<'string.h'>'
12533 else
12534 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
12535 gl_next_as_first_directive=$gl_cv_next_string_h
12536 fi
12537 NEXT_AS_FIRST_DIRECTIVE_STRING_H=$gl_next_as_first_directive
12538
12539
12540
12541
12542
12543
12544 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
12545 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
12546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
12547 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
12548 if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
12549 $as_echo_n "(cached) " >&6
12550 else
12551 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12552 /* end confdefs.h. */
12553 #include <string.h>
12554
12555 int
12556 main ()
12557 {
12558 #undef $gl_func
12559 (void) $gl_func;
12560 ;
12561 return 0;
12562 }
12563 _ACEOF
12564 if ac_fn_c_try_compile "$LINENO"; then :
12565 eval "$as_gl_Symbol=yes"
12566 else
12567 eval "$as_gl_Symbol=no"
12568 fi
12569 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12570 fi
12571 eval ac_res=\$$as_gl_Symbol
12572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
12573 $as_echo "$ac_res" >&6; }
12574 eval as_val=\$$as_gl_Symbol
12575 if test "x$as_val" = x""yes; then :
12576 cat >>confdefs.h <<_ACEOF
12577 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
12578 _ACEOF
12579
12580 eval ac_cv_have_decl_$gl_func=yes
12581 fi
12582 done
12583
12584
12585
12586
12587
12588 if test "$gl_cv_func_memchr_works" != yes; then
12589 REPLACE_STRSTR=1
12590 else
12591 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strstr works" >&5
12592 $as_echo_n "checking whether strstr works... " >&6; }
12593 if test "${gl_cv_func_strstr_works_always+set}" = set; then :
12594 $as_echo_n "(cached) " >&6
12595 else
12596 if test "$cross_compiling" = yes; then :
12597 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12598 /* end confdefs.h. */
12599
12600 #ifdef __GNU_LIBRARY__
12601 #include <features.h>
12602 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ > 12) || (__GLIBC__ > 2)) \
12603 || defined __UCLIBC__
12604 Lucky user
12605 #endif
12606 #elif defined __CYGWIN__
12607 #include <cygwin/version.h>
12608 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
12609 Lucky user
12610 #endif
12611 #else
12612 Lucky user
12613 #endif
12614
12615 _ACEOF
12616 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12617 $EGREP "Lucky user" >/dev/null 2>&1; then :
12618 gl_cv_func_strstr_works_always="guessing yes"
12619 else
12620 gl_cv_func_strstr_works_always="guessing no"
12621 fi
12622 rm -f conftest*
12623
12624
12625 else
12626 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12627 /* end confdefs.h. */
12628
12629 #include <string.h> /* for strstr */
12630 #define P "_EF_BF_BD"
12631 #define HAYSTACK "F_BD_CE_BD" P P P P "_C3_88_20" P P P "_C3_A7_20" P
12632 #define NEEDLE P P P P P
12633
12634 int
12635 main ()
12636 {
12637 return !!strstr (HAYSTACK, NEEDLE);
12638
12639 ;
12640 return 0;
12641 }
12642 _ACEOF
12643 if ac_fn_c_try_run "$LINENO"; then :
12644 gl_cv_func_strstr_works_always=yes
12645 else
12646 gl_cv_func_strstr_works_always=no
12647 fi
12648 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12649 conftest.$ac_objext conftest.beam conftest.$ac_ext
12650 fi
12651
12652
12653 fi
12654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strstr_works_always" >&5
12655 $as_echo "$gl_cv_func_strstr_works_always" >&6; }
12656 case "$gl_cv_func_strstr_works_always" in
12657 *yes) ;;
12658 *)
12659 REPLACE_STRSTR=1
12660 ;;
12661 esac
12662 fi
12663
12664 ac_fn_c_check_decl "$LINENO" "strtok_r" "ac_cv_have_decl_strtok_r" "$ac_includes_default"
12665 if test "x$ac_cv_have_decl_strtok_r" = x""yes; then :
12666 ac_have_decl=1
12667 else
12668 ac_have_decl=0
12669 fi
12670
12671 cat >>confdefs.h <<_ACEOF
12672 #define HAVE_DECL_STRTOK_R $ac_have_decl
12673 _ACEOF
12674
12675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
12676 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
12677 if test -z "$MKDIR_P"; then
12678 if test "${ac_cv_path_mkdir+set}" = set; then :
12679 $as_echo_n "(cached) " >&6
12680 else
12681 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12682 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
12683 do
12684 IFS=$as_save_IFS
12685 test -z "$as_dir" && as_dir=.
12686 for ac_prog in mkdir gmkdir; do
12687 for ac_exec_ext in '' $ac_executable_extensions; do
12688 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
12689 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
12690 'mkdir (GNU coreutils) '* | \
12691 'mkdir (coreutils) '* | \
12692 'mkdir (fileutils) '4.1*)
12693 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
12694 break 3;;
12695 esac
12696 done
12697 done
12698 done
12699 IFS=$as_save_IFS
12700
12701 fi
12702
12703 if test "${ac_cv_path_mkdir+set}" = set; then
12704 MKDIR_P="$ac_cv_path_mkdir -p"
12705 else
12706 # As a last resort, use the slow shell script. Don't cache a
12707 # value for MKDIR_P within a source directory, because that will
12708 # break other packages using the cache if that directory is
12709 # removed, or if the value is a relative name.
12710 test -d ./--version && rmdir ./--version
12711 MKDIR_P="$ac_install_sh -d"
12712 fi
12713 fi
12714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
12715 $as_echo "$MKDIR_P" >&6; }
12716
12717
12718
12719
12720
12721
12722
12723
12724
12725
12726
12727
12728
12729
12730
12731
12732
12733
12734
12735 if test $gl_cv_have_include_next = yes; then
12736 gl_cv_next_sys_types_h='<'sys/types.h'>'
12737 else
12738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/types.h>" >&5
12739 $as_echo_n "checking absolute name of <sys/types.h>... " >&6; }
12740 if test "${gl_cv_next_sys_types_h+set}" = set; then :
12741 $as_echo_n "(cached) " >&6
12742 else
12743
12744
12745
12746 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12747 /* end confdefs.h. */
12748 #include <sys/types.h>
12749 _ACEOF
12750 case "$host_os" in
12751 aix*) gl_absname_cpp="$ac_cpp -C" ;;
12752 *) gl_absname_cpp="$ac_cpp" ;;
12753 esac
12754
12755 case "$host_os" in
12756 mingw*)
12757 gl_dirsep_regex='[/\\]'
12758 ;;
12759 *)
12760 gl_dirsep_regex='\/'
12761 ;;
12762 esac
12763 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
12764 gl_header_literal_regex=`echo 'sys/types.h' \
12765 | sed -e "$gl_make_literal_regex_sed"`
12766 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
12767 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
12768 s|^/[^/]|//&|
12769 p
12770 q
12771 }'
12772
12773 gl_cv_absolute_sys_types_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
12774 sed -n "$gl_absolute_header_sed"`
12775
12776 gl_header=$gl_cv_absolute_sys_types_h
12777 gl_cv_next_sys_types_h='"'$gl_header'"'
12778
12779
12780 fi
12781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_types_h" >&5
12782 $as_echo "$gl_cv_next_sys_types_h" >&6; }
12783 fi
12784 NEXT_SYS_TYPES_H=$gl_cv_next_sys_types_h
12785
12786 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
12787 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
12788 gl_next_as_first_directive='<'sys/types.h'>'
12789 else
12790 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
12791 gl_next_as_first_directive=$gl_cv_next_sys_types_h
12792 fi
12793 NEXT_AS_FIRST_DIRECTIVE_SYS_TYPES_H=$gl_next_as_first_directive
12794
12795
12796
12797
12798
12799
12800
12801
12802
12803
12804
12805
12806 GNULIB_MKTIME=0;
12807 GNULIB_NANOSLEEP=0;
12808 GNULIB_STRPTIME=0;
12809 GNULIB_TIMEGM=0;
12810 GNULIB_TIME_R=0;
12811 GNULIB_TIME_RZ=0;
12812 HAVE_DECL_LOCALTIME_R=1;
12813 HAVE_NANOSLEEP=1;
12814 HAVE_STRPTIME=1;
12815 HAVE_TIMEGM=1;
12816 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
12817 REPLACE_MKTIME=GNULIB_PORTCHECK;
12818 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
12819 REPLACE_TIMEGM=GNULIB_PORTCHECK;
12820
12821 : ${GNULIB_GETTIMEOFDAY=0};
12822 REPLACE_GMTIME=0;
12823 REPLACE_LOCALTIME=0;
12824
12825
12826
12827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
12828 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
12829 if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
12830 $as_echo_n "(cached) " >&6
12831 else
12832 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12833 /* end confdefs.h. */
12834 #include <time.h>
12835
12836 int
12837 main ()
12838 {
12839 static struct timespec x; x.tv_sec = x.tv_nsec;
12840 ;
12841 return 0;
12842 }
12843 _ACEOF
12844 if ac_fn_c_try_compile "$LINENO"; then :
12845 gl_cv_sys_struct_timespec_in_time_h=yes
12846 else
12847 gl_cv_sys_struct_timespec_in_time_h=no
12848 fi
12849 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12850 fi
12851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
12852 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
12853
12854 TIME_H_DEFINES_STRUCT_TIMESPEC=0
12855 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
12856 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
12857 UNISTD_H_DEFINES_STRUCT_TIMESPEC=0
12858 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
12859 TIME_H_DEFINES_STRUCT_TIMESPEC=1
12860 else
12861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
12862 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
12863 if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
12864 $as_echo_n "(cached) " >&6
12865 else
12866 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12867 /* end confdefs.h. */
12868 #include <sys/time.h>
12869
12870 int
12871 main ()
12872 {
12873 static struct timespec x; x.tv_sec = x.tv_nsec;
12874 ;
12875 return 0;
12876 }
12877 _ACEOF
12878 if ac_fn_c_try_compile "$LINENO"; then :
12879 gl_cv_sys_struct_timespec_in_sys_time_h=yes
12880 else
12881 gl_cv_sys_struct_timespec_in_sys_time_h=no
12882 fi
12883 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12884 fi
12885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
12886 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
12887 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
12888 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
12889 else
12890 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
12891 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
12892 if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then :
12893 $as_echo_n "(cached) " >&6
12894 else
12895 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12896 /* end confdefs.h. */
12897 #include <pthread.h>
12898
12899 int
12900 main ()
12901 {
12902 static struct timespec x; x.tv_sec = x.tv_nsec;
12903 ;
12904 return 0;
12905 }
12906 _ACEOF
12907 if ac_fn_c_try_compile "$LINENO"; then :
12908 gl_cv_sys_struct_timespec_in_pthread_h=yes
12909 else
12910 gl_cv_sys_struct_timespec_in_pthread_h=no
12911 fi
12912 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12913 fi
12914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
12915 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
12916 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
12917 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
12918 else
12919 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <unistd.h>" >&5
12920 $as_echo_n "checking for struct timespec in <unistd.h>... " >&6; }
12921 if test "${gl_cv_sys_struct_timespec_in_unistd_h+set}" = set; then :
12922 $as_echo_n "(cached) " >&6
12923 else
12924 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12925 /* end confdefs.h. */
12926 #include <unistd.h>
12927
12928 int
12929 main ()
12930 {
12931 static struct timespec x; x.tv_sec = x.tv_nsec;
12932 ;
12933 return 0;
12934 }
12935 _ACEOF
12936 if ac_fn_c_try_compile "$LINENO"; then :
12937 gl_cv_sys_struct_timespec_in_unistd_h=yes
12938 else
12939 gl_cv_sys_struct_timespec_in_unistd_h=no
12940 fi
12941 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12942 fi
12943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_unistd_h" >&5
12944 $as_echo "$gl_cv_sys_struct_timespec_in_unistd_h" >&6; }
12945 if test $gl_cv_sys_struct_timespec_in_unistd_h = yes; then
12946 UNISTD_H_DEFINES_STRUCT_TIMESPEC=1
12947 fi
12948 fi
12949 fi
12950 fi
12951
12952
12953
12954
12955
12956
12957
12958
12959
12960
12961
12962
12963
12964
12965
12966
12967 if test $gl_cv_have_include_next = yes; then
12968 gl_cv_next_time_h='<'time.h'>'
12969 else
12970 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
12971 $as_echo_n "checking absolute name of <time.h>... " >&6; }
12972 if test "${gl_cv_next_time_h+set}" = set; then :
12973 $as_echo_n "(cached) " >&6
12974 else
12975
12976
12977
12978 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12979 /* end confdefs.h. */
12980 #include <time.h>
12981 _ACEOF
12982 case "$host_os" in
12983 aix*) gl_absname_cpp="$ac_cpp -C" ;;
12984 *) gl_absname_cpp="$ac_cpp" ;;
12985 esac
12986
12987 case "$host_os" in
12988 mingw*)
12989 gl_dirsep_regex='[/\\]'
12990 ;;
12991 *)
12992 gl_dirsep_regex='\/'
12993 ;;
12994 esac
12995 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
12996 gl_header_literal_regex=`echo 'time.h' \
12997 | sed -e "$gl_make_literal_regex_sed"`
12998 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
12999 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
13000 s|^/[^/]|//&|
13001 p
13002 q
13003 }'
13004
13005 gl_cv_absolute_time_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
13006 sed -n "$gl_absolute_header_sed"`
13007
13008 gl_header=$gl_cv_absolute_time_h
13009 gl_cv_next_time_h='"'$gl_header'"'
13010
13011
13012 fi
13013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
13014 $as_echo "$gl_cv_next_time_h" >&6; }
13015 fi
13016 NEXT_TIME_H=$gl_cv_next_time_h
13017
13018 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
13019 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
13020 gl_next_as_first_directive='<'time.h'>'
13021 else
13022 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
13023 gl_next_as_first_directive=$gl_cv_next_time_h
13024 fi
13025 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
13026
13027
13028
13029
13030
13031
13032
13033
13034 ac_fn_c_check_decl "$LINENO" "unsetenv" "ac_cv_have_decl_unsetenv" "$ac_includes_default"
13035 if test "x$ac_cv_have_decl_unsetenv" = x""yes; then :
13036 ac_have_decl=1
13037 else
13038 ac_have_decl=0
13039 fi
13040
13041 cat >>confdefs.h <<_ACEOF
13042 #define HAVE_DECL_UNSETENV $ac_have_decl
13043 _ACEOF
13044
13045
13046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <wchar.h> uses 'inline' correctly" >&5
13047 $as_echo_n "checking whether <wchar.h> uses 'inline' correctly... " >&6; }
13048 if test "${gl_cv_header_wchar_h_correct_inline+set}" = set; then :
13049 $as_echo_n "(cached) " >&6
13050 else
13051 gl_cv_header_wchar_h_correct_inline=yes
13052 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13053 /* end confdefs.h. */
13054
13055 #define wcstod renamed_wcstod
13056 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
13057 <wchar.h>.
13058 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
13059 included before <wchar.h>. */
13060 #include <stddef.h>
13061 #include <stdio.h>
13062 #include <time.h>
13063 #include <wchar.h>
13064 extern int zero (void);
13065 int main () { return zero(); }
13066
13067 _ACEOF
13068 save_ac_compile="$ac_compile"
13069 ac_compile=`echo "$save_ac_compile" | sed s/conftest/conftest1/`
13070 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
13071 (eval $ac_compile) 2>&5
13072 ac_status=$?
13073 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
13074 test $ac_status = 0; }; then
13075 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13076 /* end confdefs.h. */
13077
13078 #define wcstod renamed_wcstod
13079 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
13080 <wchar.h>.
13081 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
13082 included before <wchar.h>. */
13083 #include <stddef.h>
13084 #include <stdio.h>
13085 #include <time.h>
13086 #include <wchar.h>
13087 int zero (void) { return 0; }
13088
13089 _ACEOF
13090 ac_compile=`echo "$save_ac_compile" | sed s/conftest/conftest2/`
13091 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
13092 (eval $ac_compile) 2>&5
13093 ac_status=$?
13094 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
13095 test $ac_status = 0; }; then
13096 if $CC -o conftest$ac_exeext $CFLAGS $LDFLAGS conftest1.$ac_objext conftest2.$ac_objext $LIBS >&5 2>&1; then
13097 :
13098 else
13099 gl_cv_header_wchar_h_correct_inline=no
13100 fi
13101 fi
13102 fi
13103 ac_compile="$save_ac_compile"
13104 rm -f conftest1.$ac_objext conftest2.$ac_objext conftest$ac_exeext
13105
13106 fi
13107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_wchar_h_correct_inline" >&5
13108 $as_echo "$gl_cv_header_wchar_h_correct_inline" >&6; }
13109 if test $gl_cv_header_wchar_h_correct_inline = no; then
13110 as_fn_error "<wchar.h> cannot be used with this compiler ($CC $CFLAGS $CPPFLAGS).
13111 This is a known interoperability problem of glibc <= 2.5 with gcc >= 4.3 in
13112 C99 mode. You have four options:
13113 - Add the flag -fgnu89-inline to CC and reconfigure, or
13114 - Fix your include files, using parts of
13115 <http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=b037a293a48718af30d706c2e18c929d0e69a621>, or
13116 - Use a gcc version older than 4.3, or
13117 - Don't use the flags -std=c99 or -std=gnu99.
13118 Configuration aborted." "$LINENO" 5
13119 fi
13120
13121
13122
13123
13124
13125 if test $ac_cv_header_features_h = yes; then
13126 HAVE_FEATURES_H=1
13127 else
13128 HAVE_FEATURES_H=0
13129 fi
13130
13131
13132
13133 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wint_t" >&5
13134 $as_echo_n "checking for wint_t... " >&6; }
13135 if test "${gt_cv_c_wint_t+set}" = set; then :
13136 $as_echo_n "(cached) " >&6
13137 else
13138 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13139 /* end confdefs.h. */
13140
13141 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
13142 <wchar.h>.
13143 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
13144 before <wchar.h>. */
13145 #include <stddef.h>
13146 #include <stdio.h>
13147 #include <time.h>
13148 #include <wchar.h>
13149 wint_t foo = (wchar_t)'\0';
13150 int
13151 main ()
13152 {
13153
13154 ;
13155 return 0;
13156 }
13157 _ACEOF
13158 if ac_fn_c_try_compile "$LINENO"; then :
13159 gt_cv_c_wint_t=yes
13160 else
13161 gt_cv_c_wint_t=no
13162 fi
13163 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13164 fi
13165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wint_t" >&5
13166 $as_echo "$gt_cv_c_wint_t" >&6; }
13167 if test $gt_cv_c_wint_t = yes; then
13168
13169 $as_echo "#define HAVE_WINT_T 1" >>confdefs.h
13170
13171 fi
13172
13173
13174 GNULIB_ISWBLANK=0;
13175 GNULIB_WCTYPE=0;
13176 GNULIB_ISWCTYPE=0;
13177 GNULIB_WCTRANS=0;
13178 GNULIB_TOWCTRANS=0;
13179 HAVE_ISWBLANK=1;
13180 HAVE_WCTYPE_T=1;
13181 HAVE_WCTRANS_T=1;
13182 REPLACE_ISWBLANK=0;
13183
13184
13185
13186
13187 if false; then
13188 GL_COND_LIBTOOL_TRUE=
13189 GL_COND_LIBTOOL_FALSE='#'
13190 else
13191 GL_COND_LIBTOOL_TRUE='#'
13192 GL_COND_LIBTOOL_FALSE=
13193 fi
13194
13195 gl_cond_libtool=false
13196 gl_libdeps=
13197 gl_ltlibdeps=
13198 gl_m4_base='import/m4'
13199
13200
13201
13202
13203
13204
13205
13206
13207
13208 gl_source_base='import'
13209
13210
13211 if test $ac_cv_func_alloca_works = no; then
13212 :
13213 fi
13214
13215 # Define an additional variable used in the Makefile substitution.
13216 if test $ac_cv_working_alloca_h = yes; then
13217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
13218 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
13219 if test "${gl_cv_rpl_alloca+set}" = set; then :
13220 $as_echo_n "(cached) " >&6
13221 else
13222
13223 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13224 /* end confdefs.h. */
13225
13226 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
13227 Need own alloca
13228 #endif
13229
13230 _ACEOF
13231 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13232 $EGREP "Need own alloca" >/dev/null 2>&1; then :
13233 gl_cv_rpl_alloca=yes
13234 else
13235 gl_cv_rpl_alloca=no
13236 fi
13237 rm -f conftest*
13238
13239
13240 fi
13241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
13242 $as_echo "$gl_cv_rpl_alloca" >&6; }
13243 if test $gl_cv_rpl_alloca = yes; then
13244
13245 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
13246
13247 ALLOCA_H=alloca.h
13248 else
13249 ALLOCA_H=
13250 fi
13251 else
13252 ALLOCA_H=alloca.h
13253 fi
13254
13255 if test -n "$ALLOCA_H"; then
13256 GL_GENERATE_ALLOCA_H_TRUE=
13257 GL_GENERATE_ALLOCA_H_FALSE='#'
13258 else
13259 GL_GENERATE_ALLOCA_H_TRUE='#'
13260 GL_GENERATE_ALLOCA_H_FALSE=
13261 fi
13262
13263
13264
13265
13266
13267
13268
13269
13270
13271
13272 gl_LIBOBJS="$gl_LIBOBJS openat-proc.$ac_objext"
13273
13274
13275
13276
13277 if test $ac_cv_func_canonicalize_file_name = no; then
13278 HAVE_CANONICALIZE_FILE_NAME=0
13279 if test $ac_cv_func_realpath = no; then
13280 HAVE_REALPATH=0
13281 else
13282 case "$gl_cv_func_realpath_works" in
13283 *yes) ;;
13284 *) REPLACE_REALPATH=1 ;;
13285 esac
13286 fi
13287 else
13288 case "$gl_cv_func_realpath_works" in
13289 *yes)
13290 ;;
13291 *)
13292 REPLACE_CANONICALIZE_FILE_NAME=1
13293 REPLACE_REALPATH=1
13294 ;;
13295 esac
13296 fi
13297
13298 if test $HAVE_CANONICALIZE_FILE_NAME = 0 || test $REPLACE_CANONICALIZE_FILE_NAME = 1; then
13299
13300
13301
13302
13303
13304
13305
13306
13307 gl_LIBOBJS="$gl_LIBOBJS canonicalize-lgpl.$ac_objext"
13308
13309 fi
13310
13311
13312 cat >>confdefs.h <<_ACEOF
13313 #define GNULIB_CANONICALIZE_LGPL 1
13314 _ACEOF
13315
13316
13317
13318
13319
13320
13321
13322 GNULIB_CANONICALIZE_FILE_NAME=1
13323
13324
13325
13326
13327
13328 $as_echo "#define GNULIB_TEST_CANONICALIZE_FILE_NAME 1" >>confdefs.h
13329
13330
13331
13332
13333
13334
13335
13336
13337 GNULIB_REALPATH=1
13338
13339
13340
13341
13342
13343 $as_echo "#define GNULIB_TEST_REALPATH 1" >>confdefs.h
13344
13345
13346
13347
13348
13349
13350
13351
13352 GNULIB_CHDIR=1
13353
13354
13355
13356
13357
13358 $as_echo "#define GNULIB_TEST_CHDIR 1" >>confdefs.h
13359
13360
13361
13362
13363
13364 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether this system has an arbitrary file name length limit" >&5
13365 $as_echo_n "checking whether this system has an arbitrary file name length limit... " >&6; }
13366 if test "${gl_cv_have_arbitrary_file_name_length_limit+set}" = set; then :
13367 $as_echo_n "(cached) " >&6
13368 else
13369 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13370 /* end confdefs.h. */
13371
13372 /* Arrange to define PATH_MAX, like "pathmax.h" does. */
13373 #if HAVE_UNISTD_H
13374 # include <unistd.h>
13375 #endif
13376 #include <limits.h>
13377 #if defined HAVE_SYS_PARAM_H && !defined PATH_MAX && !defined MAXPATHLEN
13378 # include <sys/param.h>
13379 #endif
13380 #if !defined PATH_MAX && defined MAXPATHLEN
13381 # define PATH_MAX MAXPATHLEN
13382 #endif
13383 #ifdef __hpux
13384 # undef PATH_MAX
13385 # define PATH_MAX 1024
13386 #endif
13387 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
13388 # undef PATH_MAX
13389 # define PATH_MAX 260
13390 #endif
13391
13392 #ifdef PATH_MAX
13393 have_arbitrary_file_name_length_limit
13394 #endif
13395 _ACEOF
13396 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13397 $EGREP "have_arbitrary_file_name_length_limit" >/dev/null 2>&1; then :
13398 gl_cv_have_arbitrary_file_name_length_limit=yes
13399 else
13400 gl_cv_have_arbitrary_file_name_length_limit=no
13401 fi
13402 rm -f conftest*
13403
13404 fi
13405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_arbitrary_file_name_length_limit" >&5
13406 $as_echo "$gl_cv_have_arbitrary_file_name_length_limit" >&6; }
13407
13408 if test $gl_cv_have_arbitrary_file_name_length_limit = yes; then
13409
13410
13411
13412
13413
13414
13415
13416
13417 gl_LIBOBJS="$gl_LIBOBJS chdir-long.$ac_objext"
13418
13419 :
13420 fi
13421
13422
13423 $as_echo "#define GNULIB_TEST_CLOEXEC 1" >>confdefs.h
13424
13425
13426
13427
13428
13429 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
13430 REPLACE_CLOSE=1
13431 fi
13432
13433
13434
13435
13436
13437 if test $ac_cv_header_sys_socket_h != yes; then
13438 for ac_header in winsock2.h
13439 do :
13440 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
13441 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
13442 cat >>confdefs.h <<_ACEOF
13443 #define HAVE_WINSOCK2_H 1
13444 _ACEOF
13445
13446 fi
13447
13448 done
13449
13450 fi
13451 if test "$ac_cv_header_winsock2_h" = yes; then
13452 HAVE_WINSOCK2_H=1
13453 UNISTD_H_HAVE_WINSOCK2_H=1
13454 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
13455 else
13456 HAVE_WINSOCK2_H=0
13457 fi
13458
13459
13460 if test $UNISTD_H_HAVE_WINSOCK2_H = 1; then
13461 REPLACE_CLOSE=1
13462 fi
13463
13464
13465 if test $REPLACE_CLOSE = 0; then
13466
13467
13468
13469 if test $ac_cv_func_fchdir = no; then
13470 HAVE_FCHDIR=0
13471 fi
13472
13473 if test $HAVE_FCHDIR = 0; then
13474 REPLACE_CLOSE=1
13475 fi
13476 fi
13477
13478
13479 if test $REPLACE_CLOSE = 1; then
13480
13481
13482
13483
13484
13485
13486
13487
13488 gl_LIBOBJS="$gl_LIBOBJS close.$ac_objext"
13489
13490 fi
13491
13492
13493
13494
13495
13496 GNULIB_CLOSE=1
13497
13498
13499
13500
13501
13502 $as_echo "#define GNULIB_TEST_CLOSE 1" >>confdefs.h
13503
13504
13505
13506
13507
13508
13509 for ac_func in closedir
13510 do :
13511 ac_fn_c_check_func "$LINENO" "closedir" "ac_cv_func_closedir"
13512 if test "x$ac_cv_func_closedir" = x""yes; then :
13513 cat >>confdefs.h <<_ACEOF
13514 #define HAVE_CLOSEDIR 1
13515 _ACEOF
13516
13517 fi
13518 done
13519
13520 if test $ac_cv_func_closedir = no; then
13521 HAVE_CLOSEDIR=0
13522 fi
13523
13524
13525
13526
13527 if test $ac_cv_func_fchdir = no; then
13528 HAVE_FCHDIR=0
13529 fi
13530
13531 if test $HAVE_FCHDIR = 0; then
13532 if test $HAVE_CLOSEDIR = 1; then
13533 REPLACE_CLOSEDIR=1
13534 fi
13535 fi
13536
13537 case $host_os,$HAVE_CLOSEDIR in
13538 os2*,1)
13539 REPLACE_CLOSEDIR=1;;
13540 esac
13541
13542 if test $HAVE_CLOSEDIR = 0 || test $REPLACE_CLOSEDIR = 1; then
13543
13544
13545
13546
13547
13548
13549
13550
13551 gl_LIBOBJS="$gl_LIBOBJS closedir.$ac_objext"
13552
13553 fi
13554
13555
13556
13557
13558
13559 GNULIB_CLOSEDIR=1
13560
13561
13562
13563
13564
13565 $as_echo "#define GNULIB_TEST_CLOSEDIR 1" >>confdefs.h
13566
13567
13568
13569
13570 if test "x$datarootdir" = x; then
13571 datarootdir='${datadir}'
13572
13573 fi
13574 if test "x$docdir" = x; then
13575 docdir='${datarootdir}/doc/${PACKAGE}'
13576
13577 fi
13578 if test "x$htmldir" = x; then
13579 htmldir='${docdir}'
13580
13581 fi
13582 if test "x$dvidir" = x; then
13583 dvidir='${docdir}'
13584
13585 fi
13586 if test "x$pdfdir" = x; then
13587 pdfdir='${docdir}'
13588
13589 fi
13590 if test "x$psdir" = x; then
13591 psdir='${docdir}'
13592
13593 fi
13594 if test "x$lispdir" = x; then
13595 lispdir='${datarootdir}/emacs/site-lisp'
13596
13597 fi
13598 if test "x$localedir" = x; then
13599 localedir='${datarootdir}/locale'
13600
13601 fi
13602 if test "x$runstatedir" = x; then
13603 runstatedir='${localstatedir}/run'
13604
13605 fi
13606
13607 pkglibexecdir='${libexecdir}/${PACKAGE}'
13608
13609
13610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for d_ino member in directory struct" >&5
13611 $as_echo_n "checking for d_ino member in directory struct... " >&6; }
13612 if test "${gl_cv_struct_dirent_d_ino+set}" = set; then :
13613 $as_echo_n "(cached) " >&6
13614 else
13615 if test "$cross_compiling" = yes; then :
13616 case "$host_os" in
13617 # Guess yes on glibc systems with Linux kernel.
13618 linux*-gnu*) gl_cv_struct_dirent_d_ino="guessing yes" ;;
13619 # If we don't know, assume the worst.
13620 *) gl_cv_struct_dirent_d_ino="guessing no" ;;
13621 esac
13622
13623 else
13624 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13625 /* end confdefs.h. */
13626 #include <sys/types.h>
13627 #include <sys/stat.h>
13628 #include <dirent.h>
13629
13630 int
13631 main ()
13632 {
13633 DIR *dp = opendir (".");
13634 struct dirent *e;
13635 struct stat st;
13636 if (! dp)
13637 return 1;
13638 e = readdir (dp);
13639 if (! e)
13640 return 2;
13641 if (lstat (e->d_name, &st) != 0)
13642 return 3;
13643 if (e->d_ino != st.st_ino)
13644 return 4;
13645 closedir (dp);
13646 return 0;
13647
13648 ;
13649 return 0;
13650 }
13651 _ACEOF
13652 if ac_fn_c_try_run "$LINENO"; then :
13653 gl_cv_struct_dirent_d_ino=yes
13654 else
13655 gl_cv_struct_dirent_d_ino=no
13656 fi
13657 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13658 conftest.$ac_objext conftest.beam conftest.$ac_ext
13659 fi
13660
13661 fi
13662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_struct_dirent_d_ino" >&5
13663 $as_echo "$gl_cv_struct_dirent_d_ino" >&6; }
13664 case "$gl_cv_struct_dirent_d_ino" in
13665 *yes)
13666
13667 $as_echo "#define D_INO_IN_DIRENT 1" >>confdefs.h
13668
13669 ;;
13670 esac
13671
13672
13673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for d_type member in directory struct" >&5
13674 $as_echo_n "checking for d_type member in directory struct... " >&6; }
13675 if test "${gl_cv_struct_dirent_d_type+set}" = set; then :
13676 $as_echo_n "(cached) " >&6
13677 else
13678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13679 /* end confdefs.h. */
13680
13681 #include <sys/types.h>
13682 #include <dirent.h>
13683
13684 int
13685 main ()
13686 {
13687 struct dirent dp; dp.d_type = 0;
13688 ;
13689 return 0;
13690 }
13691 _ACEOF
13692 if ac_fn_c_try_link "$LINENO"; then :
13693 gl_cv_struct_dirent_d_type=yes
13694 else
13695 gl_cv_struct_dirent_d_type=no
13696 fi
13697 rm -f core conftest.err conftest.$ac_objext \
13698 conftest$ac_exeext conftest.$ac_ext
13699
13700
13701 fi
13702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_struct_dirent_d_type" >&5
13703 $as_echo "$gl_cv_struct_dirent_d_type" >&6; }
13704 if test $gl_cv_struct_dirent_d_type = yes; then
13705
13706 $as_echo "#define HAVE_STRUCT_DIRENT_D_TYPE 1" >>confdefs.h
13707
13708 fi
13709
13710
13711
13712
13713
13714
13715
13716
13717
13718
13719
13720
13721
13722
13723 if test $gl_cv_have_include_next = yes; then
13724 gl_cv_next_dirent_h='<'dirent.h'>'
13725 else
13726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <dirent.h>" >&5
13727 $as_echo_n "checking absolute name of <dirent.h>... " >&6; }
13728 if test "${gl_cv_next_dirent_h+set}" = set; then :
13729 $as_echo_n "(cached) " >&6
13730 else
13731
13732 if test $ac_cv_header_dirent_h = yes; then
13733
13734
13735
13736
13737 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13738 /* end confdefs.h. */
13739 #include <dirent.h>
13740 _ACEOF
13741 case "$host_os" in
13742 aix*) gl_absname_cpp="$ac_cpp -C" ;;
13743 *) gl_absname_cpp="$ac_cpp" ;;
13744 esac
13745
13746 case "$host_os" in
13747 mingw*)
13748 gl_dirsep_regex='[/\\]'
13749 ;;
13750 *)
13751 gl_dirsep_regex='\/'
13752 ;;
13753 esac
13754 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
13755 gl_header_literal_regex=`echo 'dirent.h' \
13756 | sed -e "$gl_make_literal_regex_sed"`
13757 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
13758 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
13759 s|^/[^/]|//&|
13760 p
13761 q
13762 }'
13763
13764 gl_cv_absolute_dirent_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
13765 sed -n "$gl_absolute_header_sed"`
13766
13767 gl_header=$gl_cv_absolute_dirent_h
13768 gl_cv_next_dirent_h='"'$gl_header'"'
13769 else
13770 gl_cv_next_dirent_h='<'dirent.h'>'
13771 fi
13772
13773
13774 fi
13775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_dirent_h" >&5
13776 $as_echo "$gl_cv_next_dirent_h" >&6; }
13777 fi
13778 NEXT_DIRENT_H=$gl_cv_next_dirent_h
13779
13780 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
13781 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
13782 gl_next_as_first_directive='<'dirent.h'>'
13783 else
13784 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
13785 gl_next_as_first_directive=$gl_cv_next_dirent_h
13786 fi
13787 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H=$gl_next_as_first_directive
13788
13789
13790
13791
13792 if test $ac_cv_header_dirent_h = yes; then
13793 HAVE_DIRENT_H=1
13794 else
13795 HAVE_DIRENT_H=0
13796 fi
13797
13798
13799
13800 for gl_func in alphasort closedir dirfd fdopendir opendir readdir rewinddir scandir; do
13801 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
13802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
13803 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
13804 if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
13805 $as_echo_n "(cached) " >&6
13806 else
13807 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13808 /* end confdefs.h. */
13809 #include <dirent.h>
13810
13811 int
13812 main ()
13813 {
13814 #undef $gl_func
13815 (void) $gl_func;
13816 ;
13817 return 0;
13818 }
13819 _ACEOF
13820 if ac_fn_c_try_compile "$LINENO"; then :
13821 eval "$as_gl_Symbol=yes"
13822 else
13823 eval "$as_gl_Symbol=no"
13824 fi
13825 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13826 fi
13827 eval ac_res=\$$as_gl_Symbol
13828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
13829 $as_echo "$ac_res" >&6; }
13830 eval as_val=\$$as_gl_Symbol
13831 if test "x$as_val" = x""yes; then :
13832 cat >>confdefs.h <<_ACEOF
13833 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
13834 _ACEOF
13835
13836 eval ac_cv_have_decl_$gl_func=yes
13837 fi
13838 done
13839
13840
13841
13842
13843
13844
13845
13846 for ac_func in dirfd
13847 do :
13848 ac_fn_c_check_func "$LINENO" "dirfd" "ac_cv_func_dirfd"
13849 if test "x$ac_cv_func_dirfd" = x""yes; then :
13850 cat >>confdefs.h <<_ACEOF
13851 #define HAVE_DIRFD 1
13852 _ACEOF
13853
13854 fi
13855 done
13856
13857 ac_fn_c_check_decl "$LINENO" "dirfd" "ac_cv_have_decl_dirfd" "#include <sys/types.h>
13858 #include <dirent.h>
13859 "
13860 if test "x$ac_cv_have_decl_dirfd" = x""yes; then :
13861 ac_have_decl=1
13862 else
13863 ac_have_decl=0
13864 fi
13865
13866 cat >>confdefs.h <<_ACEOF
13867 #define HAVE_DECL_DIRFD $ac_have_decl
13868 _ACEOF
13869
13870 if test $ac_cv_have_decl_dirfd = no; then
13871 HAVE_DECL_DIRFD=0
13872 fi
13873
13874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dirfd is a macro" >&5
13875 $as_echo_n "checking whether dirfd is a macro... " >&6; }
13876 if test "${gl_cv_func_dirfd_macro+set}" = set; then :
13877 $as_echo_n "(cached) " >&6
13878 else
13879 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13880 /* end confdefs.h. */
13881
13882 #include <sys/types.h>
13883 #include <dirent.h>
13884 #ifdef dirfd
13885 dirent_header_defines_dirfd
13886 #endif
13887 _ACEOF
13888 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13889 $EGREP "dirent_header_defines_dirfd" >/dev/null 2>&1; then :
13890 gl_cv_func_dirfd_macro=yes
13891 else
13892 gl_cv_func_dirfd_macro=no
13893 fi
13894 rm -f conftest*
13895
13896 fi
13897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dirfd_macro" >&5
13898 $as_echo "$gl_cv_func_dirfd_macro" >&6; }
13899
13900 # Use the replacement if we have no function or macro with that name,
13901 # or if OS/2 kLIBC whose dirfd() does not work.
13902 # Replace only if the system declares dirfd already.
13903 case $ac_cv_func_dirfd,$gl_cv_func_dirfd_macro,$host_os,$ac_cv_have_decl_dirfd in
13904 no,no,*,yes | *,*,os2*,yes)
13905 REPLACE_DIRFD=1
13906
13907 $as_echo "#define REPLACE_DIRFD 1" >>confdefs.h
13908 ;;
13909 esac
13910
13911 if test $ac_cv_func_dirfd = no && test $gl_cv_func_dirfd_macro = no \
13912 || test $REPLACE_DIRFD = 1; then
13913
13914
13915
13916
13917
13918
13919
13920
13921 gl_LIBOBJS="$gl_LIBOBJS dirfd.$ac_objext"
13922
13923
13924 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to get the file descriptor associated with an open DIR*" >&5
13925 $as_echo_n "checking how to get the file descriptor associated with an open DIR*... " >&6; }
13926 if test "${gl_cv_sys_dir_fd_member_name+set}" = set; then :
13927 $as_echo_n "(cached) " >&6
13928 else
13929
13930 dirfd_save_CFLAGS=$CFLAGS
13931 for ac_expr in d_fd dd_fd; do
13932
13933 CFLAGS="$CFLAGS -DDIR_FD_MEMBER_NAME=$ac_expr"
13934 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13935 /* end confdefs.h. */
13936
13937 #include <sys/types.h>
13938 #include <dirent.h>
13939 int
13940 main ()
13941 {
13942 DIR *dir_p = opendir("."); (void) dir_p->DIR_FD_MEMBER_NAME;
13943 ;
13944 return 0;
13945 }
13946 _ACEOF
13947 if ac_fn_c_try_compile "$LINENO"; then :
13948 dir_fd_found=yes
13949
13950 fi
13951 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13952 CFLAGS=$dirfd_save_CFLAGS
13953 test "$dir_fd_found" = yes && break
13954 done
13955 test "$dir_fd_found" = yes || ac_expr=no_such_member
13956
13957 gl_cv_sys_dir_fd_member_name=$ac_expr
13958
13959
13960 fi
13961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_dir_fd_member_name" >&5
13962 $as_echo "$gl_cv_sys_dir_fd_member_name" >&6; }
13963 if test $gl_cv_sys_dir_fd_member_name != no_such_member; then
13964
13965 cat >>confdefs.h <<_ACEOF
13966 #define DIR_FD_MEMBER_NAME $gl_cv_sys_dir_fd_member_name
13967 _ACEOF
13968
13969 fi
13970
13971
13972 fi
13973
13974
13975
13976
13977
13978 GNULIB_DIRFD=1
13979
13980
13981
13982
13983
13984 $as_echo "#define GNULIB_TEST_DIRFD 1" >>confdefs.h
13985
13986
13987
13988
13989
13990
13991
13992
13993
13994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether // is distinct from /" >&5
13995 $as_echo_n "checking whether // is distinct from /... " >&6; }
13996 if test "${gl_cv_double_slash_root+set}" = set; then :
13997 $as_echo_n "(cached) " >&6
13998 else
13999 if test x"$cross_compiling" = xyes ; then
14000 # When cross-compiling, there is no way to tell whether // is special
14001 # short of a list of hosts. However, the only known hosts to date
14002 # that have a distinct // are Apollo DomainOS (too old to port to),
14003 # Cygwin, and z/OS. If anyone knows of another system for which // has
14004 # special semantics and is distinct from /, please report it to
14005 # <bug-gnulib@gnu.org>.
14006 case $host in
14007 *-cygwin | i370-ibm-openedition)
14008 gl_cv_double_slash_root=yes ;;
14009 *)
14010 # Be optimistic and assume that / and // are the same when we
14011 # don't know.
14012 gl_cv_double_slash_root='unknown, assuming no' ;;
14013 esac
14014 else
14015 set x `ls -di / // 2>/dev/null`
14016 if test "$2" = "$4" && wc //dev/null >/dev/null 2>&1; then
14017 gl_cv_double_slash_root=no
14018 else
14019 gl_cv_double_slash_root=yes
14020 fi
14021 fi
14022 fi
14023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_double_slash_root" >&5
14024 $as_echo "$gl_cv_double_slash_root" >&6; }
14025 if test "$gl_cv_double_slash_root" = yes; then
14026
14027 $as_echo "#define DOUBLE_SLASH_IS_DISTINCT_ROOT 1" >>confdefs.h
14028
14029 fi
14030
14031
14032
14033
14034 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
14035 REPLACE_DUP=1
14036 fi
14037
14038
14039
14040
14041 if test $ac_cv_func_fchdir = no; then
14042 HAVE_FCHDIR=0
14043 fi
14044
14045 if test $HAVE_FCHDIR = 0; then
14046 REPLACE_DUP=1
14047 fi
14048
14049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup works" >&5
14050 $as_echo_n "checking whether dup works... " >&6; }
14051 if test "${gl_cv_func_dup_works+set}" = set; then :
14052 $as_echo_n "(cached) " >&6
14053 else
14054 if test "$cross_compiling" = yes; then :
14055 gl_cv_func_dup_works='guessing yes'
14056 else
14057 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14058 /* end confdefs.h. */
14059 #include <unistd.h>
14060 #include <fcntl.h>
14061 #include <errno.h>
14062 int
14063 main ()
14064 {
14065 /* On OS/2 kLIBC, dup does not work on a directory fd. */
14066 int fd = open (".", O_RDONLY);
14067 return fd < 0 ? 1 : dup (fd) < 0 ? 2 : 0;
14068
14069 ;
14070 return 0;
14071 }
14072
14073 _ACEOF
14074 if ac_fn_c_try_run "$LINENO"; then :
14075 gl_cv_func_dup_works=yes
14076 else
14077 gl_cv_func_dup_works=no
14078 fi
14079 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14080 conftest.$ac_objext conftest.beam conftest.$ac_ext
14081 fi
14082
14083
14084 fi
14085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup_works" >&5
14086 $as_echo "$gl_cv_func_dup_works" >&6; }
14087 case "$gl_cv_func_dup_works" in
14088 *yes) ;;
14089 *)
14090 REPLACE_DUP=1
14091 ;;
14092 esac
14093
14094 if test $REPLACE_DUP = 1; then
14095
14096
14097
14098
14099
14100
14101
14102
14103 gl_LIBOBJS="$gl_LIBOBJS dup.$ac_objext"
14104
14105 :
14106 fi
14107
14108
14109
14110
14111
14112 GNULIB_DUP=1
14113
14114
14115
14116
14117
14118 $as_echo "#define GNULIB_TEST_DUP 1" >>confdefs.h
14119
14120
14121
14122
14123
14124
14125
14126
14127 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
14128
14129
14130 if test $HAVE_DUP2 = 1; then
14131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
14132 $as_echo_n "checking whether dup2 works... " >&6; }
14133 if test "${gl_cv_func_dup2_works+set}" = set; then :
14134 $as_echo_n "(cached) " >&6
14135 else
14136 if test "$cross_compiling" = yes; then :
14137 case "$host_os" in
14138 mingw*) # on this platform, dup2 always returns 0 for success
14139 gl_cv_func_dup2_works="guessing no" ;;
14140 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
14141 gl_cv_func_dup2_works="guessing no" ;;
14142 aix* | freebsd*)
14143 # on AIX 7.1 and FreeBSD 6.1, dup2 (1,toobig) gives EMFILE,
14144 # not EBADF.
14145 gl_cv_func_dup2_works="guessing no" ;;
14146 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
14147 gl_cv_func_dup2_works="guessing no" ;;
14148 *-android*) # implemented using dup3(), which fails if oldfd == newfd
14149 gl_cv_func_dup2_works="guessing no" ;;
14150 os2*) # on OS/2 kLIBC, dup2() does not work on a directory fd.
14151 gl_cv_func_dup2_works="guessing no" ;;
14152 *) gl_cv_func_dup2_works="guessing yes" ;;
14153 esac
14154 else
14155 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14156 /* end confdefs.h. */
14157
14158 #include <errno.h>
14159 #include <fcntl.h>
14160 #include <limits.h>
14161 #include <sys/resource.h>
14162 #include <unistd.h>
14163 #ifndef RLIM_SAVED_CUR
14164 # define RLIM_SAVED_CUR RLIM_INFINITY
14165 #endif
14166 #ifndef RLIM_SAVED_MAX
14167 # define RLIM_SAVED_MAX RLIM_INFINITY
14168 #endif
14169
14170 int
14171 main ()
14172 {
14173 int result = 0;
14174 int bad_fd = INT_MAX;
14175 struct rlimit rlim;
14176 if (getrlimit (RLIMIT_NOFILE, &rlim) == 0
14177 && 0 <= rlim.rlim_cur && rlim.rlim_cur <= INT_MAX
14178 && rlim.rlim_cur != RLIM_INFINITY
14179 && rlim.rlim_cur != RLIM_SAVED_MAX
14180 && rlim.rlim_cur != RLIM_SAVED_CUR)
14181 bad_fd = rlim.rlim_cur;
14182 #ifdef FD_CLOEXEC
14183 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
14184 result |= 1;
14185 #endif
14186 if (dup2 (1, 1) != 1)
14187 result |= 2;
14188 #ifdef FD_CLOEXEC
14189 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
14190 result |= 4;
14191 #endif
14192 close (0);
14193 if (dup2 (0, 0) != -1)
14194 result |= 8;
14195 /* Many gnulib modules require POSIX conformance of EBADF. */
14196 if (dup2 (2, bad_fd) == -1 && errno != EBADF)
14197 result |= 16;
14198 /* Flush out some cygwin core dumps. */
14199 if (dup2 (2, -1) != -1 || errno != EBADF)
14200 result |= 32;
14201 dup2 (2, 255);
14202 dup2 (2, 256);
14203 /* On OS/2 kLIBC, dup2() does not work on a directory fd. */
14204 {
14205 int fd = open (".", O_RDONLY);
14206 if (fd == -1)
14207 result |= 64;
14208 else if (dup2 (fd, fd + 1) == -1)
14209 result |= 128;
14210
14211 close (fd);
14212 }
14213 return result;
14214 ;
14215 return 0;
14216 }
14217
14218 _ACEOF
14219 if ac_fn_c_try_run "$LINENO"; then :
14220 gl_cv_func_dup2_works=yes
14221 else
14222 gl_cv_func_dup2_works=no
14223 fi
14224 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14225 conftest.$ac_objext conftest.beam conftest.$ac_ext
14226 fi
14227
14228
14229 fi
14230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
14231 $as_echo "$gl_cv_func_dup2_works" >&6; }
14232 case "$gl_cv_func_dup2_works" in
14233 *yes) ;;
14234 *)
14235 REPLACE_DUP2=1
14236 for ac_func in setdtablesize
14237 do :
14238 ac_fn_c_check_func "$LINENO" "setdtablesize" "ac_cv_func_setdtablesize"
14239 if test "x$ac_cv_func_setdtablesize" = x""yes; then :
14240 cat >>confdefs.h <<_ACEOF
14241 #define HAVE_SETDTABLESIZE 1
14242 _ACEOF
14243
14244 fi
14245 done
14246
14247 ;;
14248 esac
14249 fi
14250
14251
14252
14253
14254 if test $ac_cv_func_fchdir = no; then
14255 HAVE_FCHDIR=0
14256 fi
14257
14258 if test $HAVE_FCHDIR = 0; then
14259 if test $HAVE_DUP2 = 1; then
14260 REPLACE_DUP2=1
14261 fi
14262 fi
14263
14264
14265 if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
14266
14267
14268
14269
14270
14271
14272
14273
14274 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
14275
14276
14277 fi
14278
14279
14280
14281
14282
14283 GNULIB_DUP2=1
14284
14285
14286
14287
14288
14289 $as_echo "#define GNULIB_TEST_DUP2 1" >>confdefs.h
14290
14291
14292
14293
14294
14295
14296
14297
14298
14299 GNULIB_ENVIRON=1
14300
14301
14302
14303
14304
14305 $as_echo "#define GNULIB_TEST_ENVIRON 1" >>confdefs.h
14306
14307
14308
14309
14310
14311 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for error_at_line" >&5
14312 $as_echo_n "checking for error_at_line... " >&6; }
14313 if test "${ac_cv_lib_error_at_line+set}" = set; then :
14314 $as_echo_n "(cached) " >&6
14315 else
14316 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14317 /* end confdefs.h. */
14318 #include <error.h>
14319 int
14320 main ()
14321 {
14322 error_at_line (0, 0, "", 0, "an error occurred");
14323 ;
14324 return 0;
14325 }
14326 _ACEOF
14327 if ac_fn_c_try_link "$LINENO"; then :
14328 ac_cv_lib_error_at_line=yes
14329 else
14330 ac_cv_lib_error_at_line=no
14331 fi
14332 rm -f core conftest.err conftest.$ac_objext \
14333 conftest$ac_exeext conftest.$ac_ext
14334 fi
14335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_error_at_line" >&5
14336 $as_echo "$ac_cv_lib_error_at_line" >&6; }
14337
14338 if test $ac_cv_lib_error_at_line = no; then
14339
14340
14341
14342
14343
14344
14345
14346
14347 gl_LIBOBJS="$gl_LIBOBJS error.$ac_objext"
14348
14349
14350
14351 :
14352
14353 fi
14354
14355
14356
14357
14358
14359
14360
14361 if test $ac_cv_have_decl_fchdir = no; then
14362 HAVE_DECL_FCHDIR=0
14363 fi
14364
14365
14366 if test $HAVE_FCHDIR = 0; then
14367
14368
14369
14370
14371
14372
14373
14374
14375 gl_LIBOBJS="$gl_LIBOBJS fchdir.$ac_objext"
14376
14377 :
14378
14379 $as_echo "#define REPLACE_FCHDIR 1" >>confdefs.h
14380
14381 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether open can visit directories" >&5
14382 $as_echo_n "checking whether open can visit directories... " >&6; }
14383 if test "${gl_cv_func_open_directory_works+set}" = set; then :
14384 $as_echo_n "(cached) " >&6
14385 else
14386 if test "$cross_compiling" = yes; then :
14387 case "$host_os" in
14388 # Guess yes on glibc systems.
14389 *-gnu*) gl_cv_func_open_directory_works="guessing yes" ;;
14390 # If we don't know, assume the worst.
14391 *) gl_cv_func_open_directory_works="guessing no" ;;
14392 esac
14393
14394 else
14395 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14396 /* end confdefs.h. */
14397 #include <fcntl.h>
14398
14399 int
14400 main ()
14401 {
14402 return open(".", O_RDONLY) < 0;
14403 ;
14404 return 0;
14405 }
14406 _ACEOF
14407 if ac_fn_c_try_run "$LINENO"; then :
14408 gl_cv_func_open_directory_works=yes
14409 else
14410 gl_cv_func_open_directory_works=no
14411 fi
14412 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14413 conftest.$ac_objext conftest.beam conftest.$ac_ext
14414 fi
14415
14416 fi
14417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_open_directory_works" >&5
14418 $as_echo "$gl_cv_func_open_directory_works" >&6; }
14419 case "$gl_cv_func_open_directory_works" in
14420 *yes) ;;
14421 *)
14422
14423 $as_echo "#define REPLACE_OPEN_DIRECTORY 1" >>confdefs.h
14424
14425 ;;
14426 esac
14427 fi
14428
14429
14430
14431
14432
14433
14434 GNULIB_FCHDIR=1
14435
14436
14437
14438
14439
14440 $as_echo "#define GNULIB_TEST_FCHDIR 1" >>confdefs.h
14441
14442
14443
14444
14445
14446
14447
14448
14449 if test $ac_cv_func_fcntl = no; then
14450
14451
14452
14453 if test $ac_cv_func_fcntl = no; then
14454 HAVE_FCNTL=0
14455 else
14456 REPLACE_FCNTL=1
14457 fi
14458
14459 else
14460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl handles F_DUPFD correctly" >&5
14461 $as_echo_n "checking whether fcntl handles F_DUPFD correctly... " >&6; }
14462 if test "${gl_cv_func_fcntl_f_dupfd_works+set}" = set; then :
14463 $as_echo_n "(cached) " >&6
14464 else
14465 if test "$cross_compiling" = yes; then :
14466 case $host_os in
14467 aix* | cygwin* | haiku*)
14468 gl_cv_func_fcntl_f_dupfd_works="guessing no" ;;
14469 *) gl_cv_func_fcntl_f_dupfd_works="guessing yes" ;;
14470 esac
14471 else
14472 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14473 /* end confdefs.h. */
14474 #include <errno.h>
14475 #include <fcntl.h>
14476 #include <limits.h>
14477 #include <sys/resource.h>
14478 #include <unistd.h>
14479 #ifndef RLIM_SAVED_CUR
14480 # define RLIM_SAVED_CUR RLIM_INFINITY
14481 #endif
14482 #ifndef RLIM_SAVED_MAX
14483 # define RLIM_SAVED_MAX RLIM_INFINITY
14484 #endif
14485
14486 int
14487 main ()
14488 {
14489 int result = 0;
14490 int bad_fd = INT_MAX;
14491 struct rlimit rlim;
14492 if (getrlimit (RLIMIT_NOFILE, &rlim) == 0
14493 && 0 <= rlim.rlim_cur && rlim.rlim_cur <= INT_MAX
14494 && rlim.rlim_cur != RLIM_INFINITY
14495 && rlim.rlim_cur != RLIM_SAVED_MAX
14496 && rlim.rlim_cur != RLIM_SAVED_CUR)
14497 bad_fd = rlim.rlim_cur;
14498 if (fcntl (0, F_DUPFD, -1) != -1) result |= 1;
14499 if (errno != EINVAL) result |= 2;
14500 if (fcntl (0, F_DUPFD, bad_fd) != -1) result |= 4;
14501 if (errno != EINVAL) result |= 8;
14502 /* On OS/2 kLIBC, F_DUPFD does not work on a directory fd */
14503 {
14504 int fd;
14505 fd = open (".", O_RDONLY);
14506 if (fd == -1)
14507 result |= 16;
14508 else if (fcntl (fd, F_DUPFD, STDERR_FILENO + 1) == -1)
14509 result |= 32;
14510
14511 close (fd);
14512 }
14513 return result;
14514 ;
14515 return 0;
14516 }
14517 _ACEOF
14518 if ac_fn_c_try_run "$LINENO"; then :
14519 gl_cv_func_fcntl_f_dupfd_works=yes
14520 else
14521 gl_cv_func_fcntl_f_dupfd_works=no
14522 fi
14523 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14524 conftest.$ac_objext conftest.beam conftest.$ac_ext
14525 fi
14526
14527 fi
14528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_works" >&5
14529 $as_echo "$gl_cv_func_fcntl_f_dupfd_works" >&6; }
14530 case $gl_cv_func_fcntl_f_dupfd_works in
14531 *yes) ;;
14532 *)
14533
14534
14535 if test $ac_cv_func_fcntl = no; then
14536 HAVE_FCNTL=0
14537 else
14538 REPLACE_FCNTL=1
14539 fi
14540
14541
14542 $as_echo "#define FCNTL_DUPFD_BUGGY 1" >>confdefs.h
14543 ;;
14544 esac
14545
14546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl understands F_DUPFD_CLOEXEC" >&5
14547 $as_echo_n "checking whether fcntl understands F_DUPFD_CLOEXEC... " >&6; }
14548 if test "${gl_cv_func_fcntl_f_dupfd_cloexec+set}" = set; then :
14549 $as_echo_n "(cached) " >&6
14550 else
14551 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14552 /* end confdefs.h. */
14553
14554 #include <fcntl.h>
14555 #ifndef F_DUPFD_CLOEXEC
14556 choke me
14557 #endif
14558
14559 int
14560 main ()
14561 {
14562
14563 ;
14564 return 0;
14565 }
14566 _ACEOF
14567 if ac_fn_c_try_compile "$LINENO"; then :
14568 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14569 /* end confdefs.h. */
14570
14571 #ifdef __linux__
14572 /* The Linux kernel only added F_DUPFD_CLOEXEC in 2.6.24, so we always replace
14573 it to support the semantics on older kernels that failed with EINVAL. */
14574 choke me
14575 #endif
14576
14577 int
14578 main ()
14579 {
14580
14581 ;
14582 return 0;
14583 }
14584 _ACEOF
14585 if ac_fn_c_try_compile "$LINENO"; then :
14586 gl_cv_func_fcntl_f_dupfd_cloexec=yes
14587 else
14588 gl_cv_func_fcntl_f_dupfd_cloexec="needs runtime check"
14589 fi
14590 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14591 else
14592 gl_cv_func_fcntl_f_dupfd_cloexec=no
14593 fi
14594 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14595 fi
14596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_cloexec" >&5
14597 $as_echo "$gl_cv_func_fcntl_f_dupfd_cloexec" >&6; }
14598 if test "$gl_cv_func_fcntl_f_dupfd_cloexec" != yes; then
14599
14600
14601
14602 if test $ac_cv_func_fcntl = no; then
14603 HAVE_FCNTL=0
14604 else
14605 REPLACE_FCNTL=1
14606 fi
14607
14608 fi
14609 fi
14610
14611
14612
14613
14614 if test $ac_cv_func_fchdir = no; then
14615 HAVE_FCHDIR=0
14616 fi
14617
14618 if test $HAVE_FCHDIR = 0; then
14619
14620
14621
14622 if test $ac_cv_func_fcntl = no; then
14623 HAVE_FCNTL=0
14624 else
14625 REPLACE_FCNTL=1
14626 fi
14627
14628 fi
14629
14630
14631 if test $HAVE_FCNTL = 0 || test $REPLACE_FCNTL = 1; then
14632
14633
14634
14635
14636
14637
14638
14639
14640 gl_LIBOBJS="$gl_LIBOBJS fcntl.$ac_objext"
14641
14642 fi
14643
14644
14645
14646
14647
14648 GNULIB_FCNTL=1
14649
14650
14651
14652
14653
14654 $as_echo "#define GNULIB_TEST_FCNTL 1" >>confdefs.h
14655
14656
14657
14658
14659
14660
14661
14662
14663
14664
14665
14666
14667
14668
14669 if test $gl_cv_have_include_next = yes; then
14670 gl_cv_next_fcntl_h='<'fcntl.h'>'
14671 else
14672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <fcntl.h>" >&5
14673 $as_echo_n "checking absolute name of <fcntl.h>... " >&6; }
14674 if test "${gl_cv_next_fcntl_h+set}" = set; then :
14675 $as_echo_n "(cached) " >&6
14676 else
14677
14678
14679
14680 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14681 /* end confdefs.h. */
14682 #include <fcntl.h>
14683 _ACEOF
14684 case "$host_os" in
14685 aix*) gl_absname_cpp="$ac_cpp -C" ;;
14686 *) gl_absname_cpp="$ac_cpp" ;;
14687 esac
14688
14689 case "$host_os" in
14690 mingw*)
14691 gl_dirsep_regex='[/\\]'
14692 ;;
14693 *)
14694 gl_dirsep_regex='\/'
14695 ;;
14696 esac
14697 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
14698 gl_header_literal_regex=`echo 'fcntl.h' \
14699 | sed -e "$gl_make_literal_regex_sed"`
14700 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
14701 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
14702 s|^/[^/]|//&|
14703 p
14704 q
14705 }'
14706
14707 gl_cv_absolute_fcntl_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
14708 sed -n "$gl_absolute_header_sed"`
14709
14710 gl_header=$gl_cv_absolute_fcntl_h
14711 gl_cv_next_fcntl_h='"'$gl_header'"'
14712
14713
14714 fi
14715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_fcntl_h" >&5
14716 $as_echo "$gl_cv_next_fcntl_h" >&6; }
14717 fi
14718 NEXT_FCNTL_H=$gl_cv_next_fcntl_h
14719
14720 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
14721 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
14722 gl_next_as_first_directive='<'fcntl.h'>'
14723 else
14724 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
14725 gl_next_as_first_directive=$gl_cv_next_fcntl_h
14726 fi
14727 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H=$gl_next_as_first_directive
14728
14729
14730
14731
14732
14733
14734
14735
14736
14737
14738 for gl_func in fcntl openat; do
14739 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
14740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
14741 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
14742 if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
14743 $as_echo_n "(cached) " >&6
14744 else
14745 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14746 /* end confdefs.h. */
14747 #include <fcntl.h>
14748
14749 int
14750 main ()
14751 {
14752 #undef $gl_func
14753 (void) $gl_func;
14754 ;
14755 return 0;
14756 }
14757 _ACEOF
14758 if ac_fn_c_try_compile "$LINENO"; then :
14759 eval "$as_gl_Symbol=yes"
14760 else
14761 eval "$as_gl_Symbol=no"
14762 fi
14763 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14764 fi
14765 eval ac_res=\$$as_gl_Symbol
14766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
14767 $as_echo "$ac_res" >&6; }
14768 eval as_val=\$$as_gl_Symbol
14769 if test "x$as_val" = x""yes; then :
14770 cat >>confdefs.h <<_ACEOF
14771 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
14772 _ACEOF
14773
14774 eval ac_cv_have_decl_$gl_func=yes
14775 fi
14776 done
14777
14778
14779
14780
14781
14782
14783
14784 ac_fn_c_check_decl "$LINENO" "fdopendir" "ac_cv_have_decl_fdopendir" "
14785 #include <dirent.h>
14786
14787 "
14788 if test "x$ac_cv_have_decl_fdopendir" = x""yes; then :
14789 ac_have_decl=1
14790 else
14791 ac_have_decl=0
14792 fi
14793
14794 cat >>confdefs.h <<_ACEOF
14795 #define HAVE_DECL_FDOPENDIR $ac_have_decl
14796 _ACEOF
14797 if test $ac_have_decl = 1; then :
14798
14799 else
14800 HAVE_DECL_FDOPENDIR=0
14801 fi
14802
14803
14804 if test $ac_cv_func_fdopendir = no; then
14805 HAVE_FDOPENDIR=0
14806 else
14807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fdopendir works" >&5
14808 $as_echo_n "checking whether fdopendir works... " >&6; }
14809 if test "${gl_cv_func_fdopendir_works+set}" = set; then :
14810 $as_echo_n "(cached) " >&6
14811 else
14812 if test "$cross_compiling" = yes; then :
14813 case "$host_os" in
14814 # Guess yes on glibc systems.
14815 *-gnu*) gl_cv_func_fdopendir_works="guessing yes" ;;
14816 # If we don't know, assume the worst.
14817 *) gl_cv_func_fdopendir_works="guessing no" ;;
14818 esac
14819
14820 else
14821 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14822 /* end confdefs.h. */
14823
14824 #include <dirent.h>
14825 #include <fcntl.h>
14826 #include <unistd.h>
14827 #if !HAVE_DECL_FDOPENDIR
14828 extern
14829 # ifdef __cplusplus
14830 "C"
14831 # endif
14832 DIR *fdopendir (int);
14833 #endif
14834
14835 int
14836 main ()
14837 {
14838 int result = 0;
14839 int fd = open ("conftest.c", O_RDONLY);
14840 if (fd < 0) result |= 1;
14841 if (fdopendir (fd)) result |= 2;
14842 if (close (fd)) result |= 4;
14843 return result;
14844 ;
14845 return 0;
14846 }
14847 _ACEOF
14848 if ac_fn_c_try_run "$LINENO"; then :
14849 gl_cv_func_fdopendir_works=yes
14850 else
14851 gl_cv_func_fdopendir_works=no
14852 fi
14853 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14854 conftest.$ac_objext conftest.beam conftest.$ac_ext
14855 fi
14856
14857 fi
14858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fdopendir_works" >&5
14859 $as_echo "$gl_cv_func_fdopendir_works" >&6; }
14860 case "$gl_cv_func_fdopendir_works" in
14861 *yes) ;;
14862 *)
14863 REPLACE_FDOPENDIR=1
14864 ;;
14865 esac
14866 fi
14867
14868 if test $HAVE_FDOPENDIR = 0 || test $REPLACE_FDOPENDIR = 1; then
14869
14870
14871
14872
14873
14874
14875
14876
14877 gl_LIBOBJS="$gl_LIBOBJS fdopendir.$ac_objext"
14878
14879 fi
14880
14881
14882
14883
14884
14885 GNULIB_FDOPENDIR=1
14886
14887
14888
14889
14890
14891 $as_echo "#define GNULIB_TEST_FDOPENDIR 1" >>confdefs.h
14892
14893
14894
14895
14896
14897 cat >>confdefs.h <<_ACEOF
14898 #define GNULIB_FDOPENDIR 1
14899 _ACEOF
14900
14901
14902
14903
14904
14905
14906 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flexible array member" >&5
14907 $as_echo_n "checking for flexible array member... " >&6; }
14908 if test "${ac_cv_c_flexmember+set}" = set; then :
14909 $as_echo_n "(cached) " >&6
14910 else
14911 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14912 /* end confdefs.h. */
14913 #include <stdlib.h>
14914 #include <stdio.h>
14915 #include <stddef.h>
14916 struct s { int n; double d[]; };
14917 int
14918 main ()
14919 {
14920 int m = getchar ();
14921 size_t nbytes = offsetof (struct s, d) + m * sizeof (double);
14922 nbytes += sizeof (struct s) - 1;
14923 nbytes -= nbytes % sizeof (struct s);
14924 struct s *p = malloc (nbytes);
14925 p->d[0] = 0.0;
14926 return p->d != (double *) NULL;
14927 ;
14928 return 0;
14929 }
14930 _ACEOF
14931 if ac_fn_c_try_compile "$LINENO"; then :
14932 ac_cv_c_flexmember=yes
14933 else
14934 ac_cv_c_flexmember=no
14935 fi
14936 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14937 fi
14938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_flexmember" >&5
14939 $as_echo "$ac_cv_c_flexmember" >&6; }
14940 if test $ac_cv_c_flexmember = yes; then
14941
14942 $as_echo "#define FLEXIBLE_ARRAY_MEMBER /**/" >>confdefs.h
14943
14944 else
14945 $as_echo "#define FLEXIBLE_ARRAY_MEMBER 1" >>confdefs.h
14946
14947 fi
14948
14949
14950
14951
14952 FLOAT_H=
14953 REPLACE_FLOAT_LDBL=0
14954 case "$host_os" in
14955 aix* | beos* | openbsd* | mirbsd* | irix*)
14956 FLOAT_H=float.h
14957 ;;
14958 freebsd*)
14959 case "$host_cpu" in
14960 i[34567]86 )
14961 FLOAT_H=float.h
14962 ;;
14963 x86_64 )
14964 # On x86_64 systems, the C compiler may still be generating
14965 # 32-bit code.
14966 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14967 /* end confdefs.h. */
14968 #if defined __LP64__ || defined __x86_64__ || defined __amd64__
14969 yes
14970 #endif
14971 _ACEOF
14972 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14973 $EGREP "yes" >/dev/null 2>&1; then :
14974
14975 else
14976 FLOAT_H=float.h
14977 fi
14978 rm -f conftest*
14979
14980 ;;
14981 esac
14982 ;;
14983 linux*)
14984 case "$host_cpu" in
14985 powerpc*)
14986 FLOAT_H=float.h
14987 ;;
14988 esac
14989 ;;
14990 esac
14991 case "$host_os" in
14992 aix* | freebsd* | linux*)
14993 if test -n "$FLOAT_H"; then
14994 REPLACE_FLOAT_LDBL=1
14995 fi
14996 ;;
14997 esac
14998
14999 REPLACE_ITOLD=0
15000 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether conversion from 'int' to 'long double' works" >&5
15001 $as_echo_n "checking whether conversion from 'int' to 'long double' works... " >&6; }
15002 if test "${gl_cv_func_itold_works+set}" = set; then :
15003 $as_echo_n "(cached) " >&6
15004 else
15005
15006 if test "$cross_compiling" = yes; then :
15007 case "$host" in
15008 sparc*-*-linux*)
15009 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15010 /* end confdefs.h. */
15011 #if defined __LP64__ || defined __arch64__
15012 yes
15013 #endif
15014 _ACEOF
15015 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15016 $EGREP "yes" >/dev/null 2>&1; then :
15017 gl_cv_func_itold_works="guessing no"
15018 else
15019 gl_cv_func_itold_works="guessing yes"
15020 fi
15021 rm -f conftest*
15022
15023 ;;
15024 *) gl_cv_func_itold_works="guessing yes" ;;
15025 esac
15026
15027 else
15028 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15029 /* end confdefs.h. */
15030
15031 int i = -1;
15032 volatile long double ld;
15033 int main ()
15034 {
15035 ld += i * 1.0L;
15036 if (ld > 0)
15037 return 1;
15038 return 0;
15039 }
15040 _ACEOF
15041 if ac_fn_c_try_run "$LINENO"; then :
15042 gl_cv_func_itold_works=yes
15043 else
15044 gl_cv_func_itold_works=no
15045 fi
15046 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15047 conftest.$ac_objext conftest.beam conftest.$ac_ext
15048 fi
15049
15050
15051 fi
15052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_itold_works" >&5
15053 $as_echo "$gl_cv_func_itold_works" >&6; }
15054 case "$gl_cv_func_itold_works" in
15055 *no)
15056 REPLACE_ITOLD=1
15057 FLOAT_H=float.h
15058 ;;
15059 esac
15060
15061 if test -n "$FLOAT_H"; then
15062
15063
15064
15065
15066
15067
15068
15069
15070 if test $gl_cv_have_include_next = yes; then
15071 gl_cv_next_float_h='<'float.h'>'
15072 else
15073 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <float.h>" >&5
15074 $as_echo_n "checking absolute name of <float.h>... " >&6; }
15075 if test "${gl_cv_next_float_h+set}" = set; then :
15076 $as_echo_n "(cached) " >&6
15077 else
15078
15079
15080
15081 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15082 /* end confdefs.h. */
15083 #include <float.h>
15084 _ACEOF
15085 case "$host_os" in
15086 aix*) gl_absname_cpp="$ac_cpp -C" ;;
15087 *) gl_absname_cpp="$ac_cpp" ;;
15088 esac
15089
15090 case "$host_os" in
15091 mingw*)
15092 gl_dirsep_regex='[/\\]'
15093 ;;
15094 *)
15095 gl_dirsep_regex='\/'
15096 ;;
15097 esac
15098 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
15099 gl_header_literal_regex=`echo 'float.h' \
15100 | sed -e "$gl_make_literal_regex_sed"`
15101 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
15102 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
15103 s|^/[^/]|//&|
15104 p
15105 q
15106 }'
15107
15108 gl_cv_absolute_float_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
15109 sed -n "$gl_absolute_header_sed"`
15110
15111 gl_header=$gl_cv_absolute_float_h
15112 gl_cv_next_float_h='"'$gl_header'"'
15113
15114
15115 fi
15116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_float_h" >&5
15117 $as_echo "$gl_cv_next_float_h" >&6; }
15118 fi
15119 NEXT_FLOAT_H=$gl_cv_next_float_h
15120
15121 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
15122 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
15123 gl_next_as_first_directive='<'float.h'>'
15124 else
15125 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
15126 gl_next_as_first_directive=$gl_cv_next_float_h
15127 fi
15128 NEXT_AS_FIRST_DIRECTIVE_FLOAT_H=$gl_next_as_first_directive
15129
15130
15131
15132
15133 fi
15134
15135 if test -n "$FLOAT_H"; then
15136 GL_GENERATE_FLOAT_H_TRUE=
15137 GL_GENERATE_FLOAT_H_FALSE='#'
15138 else
15139 GL_GENERATE_FLOAT_H_TRUE='#'
15140 GL_GENERATE_FLOAT_H_FALSE=
15141 fi
15142
15143
15144
15145 if test $REPLACE_FLOAT_LDBL = 1; then
15146
15147
15148
15149
15150
15151
15152
15153
15154 gl_LIBOBJS="$gl_LIBOBJS float.$ac_objext"
15155
15156 fi
15157 if test $REPLACE_ITOLD = 1; then
15158
15159
15160
15161
15162
15163
15164
15165
15166 gl_LIBOBJS="$gl_LIBOBJS itold.$ac_objext"
15167
15168 fi
15169
15170
15171
15172
15173
15174 FNMATCH_H=
15175 gl_fnmatch_required_lowercase=`
15176 echo $gl_fnmatch_required | LC_ALL=C tr '[A-Z]' '[a-z]'
15177 `
15178 gl_fnmatch_cache_var="gl_cv_func_fnmatch_${gl_fnmatch_required_lowercase}"
15179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working $gl_fnmatch_required fnmatch" >&5
15180 $as_echo_n "checking for working $gl_fnmatch_required fnmatch... " >&6; }
15181 if { as_var=$gl_fnmatch_cache_var; eval "test \"\${$as_var+set}\" = set"; }; then :
15182 $as_echo_n "(cached) " >&6
15183 else
15184 if test $gl_fnmatch_required = GNU; then
15185 gl_fnmatch_gnu_start=
15186 gl_fnmatch_gnu_end=
15187 else
15188 gl_fnmatch_gnu_start='#if 0'
15189 gl_fnmatch_gnu_end='#endif'
15190 fi
15191 if test "$cross_compiling" = yes; then :
15192 eval "$gl_fnmatch_cache_var=\"guessing no\""
15193 else
15194 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15195 /* end confdefs.h. */
15196 #include <fnmatch.h>
15197 static int
15198 y (char const *pattern, char const *string, int flags)
15199 {
15200 return fnmatch (pattern, string, flags) == 0;
15201 }
15202 static int
15203 n (char const *pattern, char const *string, int flags)
15204 {
15205 return fnmatch (pattern, string, flags) == FNM_NOMATCH;
15206 }
15207
15208 int
15209 main ()
15210 {
15211 char const *Apat = 'A' < '\\\\' ? "[A-\\\\\\\\]" : "[\\\\\\\\-A]";
15212 char const *apat = 'a' < '\\\\' ? "[a-\\\\\\\\]" : "[\\\\\\\\-a]";
15213 static char const A_1[] = { 'A' - 1, 0 };
15214 static char const A01[] = { 'A' + 1, 0 };
15215 static char const a_1[] = { 'a' - 1, 0 };
15216 static char const a01[] = { 'a' + 1, 0 };
15217 static char const bs_1[] = { '\\\\' - 1, 0 };
15218 static char const bs01[] = { '\\\\' + 1, 0 };
15219 int result = 0;
15220 if (!n ("a*", "", 0))
15221 return 1;
15222 if (!y ("a*", "abc", 0))
15223 return 1;
15224 if (!y ("[/b", "[/b", 0)) /*"]]"*/ /* glibc Bugzilla bug 12378 */
15225 return 1;
15226 if (!n ("d*/*1", "d/s/1", FNM_PATHNAME))
15227 return 2;
15228 if (!y ("a\\\\bc", "abc", 0))
15229 return 3;
15230 if (!n ("a\\\\bc", "abc", FNM_NOESCAPE))
15231 return 3;
15232 if (!y ("*x", ".x", 0))
15233 return 4;
15234 if (!n ("*x", ".x", FNM_PERIOD))
15235 return 4;
15236 if (!y (Apat, "\\\\", 0))
15237 return 5;
15238 if (!y (Apat, "A", 0))
15239 return 5;
15240 if (!y (apat, "\\\\", 0))
15241 return 5;
15242 if (!y (apat, "a", 0))
15243 return 5;
15244 if (!(n (Apat, A_1, 0) == ('A' < '\\\\')))
15245 return 5;
15246 if (!(n (apat, a_1, 0) == ('a' < '\\\\')))
15247 return 5;
15248 if (!(y (Apat, A01, 0) == ('A' < '\\\\')))
15249 return 5;
15250 if (!(y (apat, a01, 0) == ('a' < '\\\\')))
15251 return 5;
15252 if (!(y (Apat, bs_1, 0) == ('A' < '\\\\')))
15253 return 5;
15254 if (!(y (apat, bs_1, 0) == ('a' < '\\\\')))
15255 return 5;
15256 if (!(n (Apat, bs01, 0) == ('A' < '\\\\')))
15257 return 5;
15258 if (!(n (apat, bs01, 0) == ('a' < '\\\\')))
15259 return 5;
15260 $gl_fnmatch_gnu_start
15261 if (!y ("xxXX", "xXxX", FNM_CASEFOLD))
15262 result |= 8;
15263 if (!y ("a++(x|yy)b", "a+xyyyyxb", FNM_EXTMATCH))
15264 result |= 16;
15265 if (!n ("d*/*1", "d/s/1", FNM_FILE_NAME))
15266 result |= 32;
15267 if (!y ("*", "x", FNM_FILE_NAME | FNM_LEADING_DIR))
15268 result |= 64;
15269 if (!y ("x*", "x/y/z", FNM_FILE_NAME | FNM_LEADING_DIR))
15270 result |= 64;
15271 if (!y ("*c*", "c/x", FNM_FILE_NAME | FNM_LEADING_DIR))
15272 result |= 64;
15273 $gl_fnmatch_gnu_end
15274 return result;
15275
15276 ;
15277 return 0;
15278 }
15279 _ACEOF
15280 if ac_fn_c_try_run "$LINENO"; then :
15281 eval "$gl_fnmatch_cache_var=yes"
15282 else
15283 eval "$gl_fnmatch_cache_var=no"
15284 fi
15285 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15286 conftest.$ac_objext conftest.beam conftest.$ac_ext
15287 fi
15288
15289
15290 fi
15291 eval ac_res=\$$gl_fnmatch_cache_var
15292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15293 $as_echo "$ac_res" >&6; }
15294 eval "gl_fnmatch_result=\"\$$gl_fnmatch_cache_var\""
15295 if test "$gl_fnmatch_result" = yes; then
15296 rm -f "$gl_source_base/fnmatch.h"
15297 else
15298 FNMATCH_H=fnmatch.h
15299 fi
15300
15301 if test -n "$FNMATCH_H"; then
15302 GL_GENERATE_FNMATCH_H_TRUE=
15303 GL_GENERATE_FNMATCH_H_FALSE='#'
15304 else
15305 GL_GENERATE_FNMATCH_H_TRUE='#'
15306 GL_GENERATE_FNMATCH_H_FALSE=
15307 fi
15308
15309
15310 if test -n "$FNMATCH_H"; then
15311
15312
15313
15314
15315
15316
15317
15318
15319 gl_LIBOBJS="$gl_LIBOBJS fnmatch.$ac_objext"
15320
15321
15322
15323 cat >>confdefs.h <<_ACEOF
15324 #define fnmatch ${gl_fnmatch_required_lowercase}_fnmatch
15325 _ACEOF
15326
15327
15328 ac_fn_c_check_decl "$LINENO" "isblank" "ac_cv_have_decl_isblank" "#include <ctype.h>
15329 "
15330 if test "x$ac_cv_have_decl_isblank" = x""yes; then :
15331 ac_have_decl=1
15332 else
15333 ac_have_decl=0
15334 fi
15335
15336 cat >>confdefs.h <<_ACEOF
15337 #define HAVE_DECL_ISBLANK $ac_have_decl
15338 _ACEOF
15339
15340
15341
15342
15343 fi
15344
15345
15346
15347
15348
15349 if test -n "$FNMATCH_H"; then
15350
15351
15352
15353
15354
15355
15356
15357
15358 gl_LIBOBJS="$gl_LIBOBJS fnmatch.$ac_objext"
15359
15360
15361
15362 cat >>confdefs.h <<_ACEOF
15363 #define fnmatch ${gl_fnmatch_required_lowercase}_fnmatch
15364 _ACEOF
15365
15366
15367 ac_fn_c_check_decl "$LINENO" "isblank" "ac_cv_have_decl_isblank" "#include <ctype.h>
15368 "
15369 if test "x$ac_cv_have_decl_isblank" = x""yes; then :
15370 ac_have_decl=1
15371 else
15372 ac_have_decl=0
15373 fi
15374
15375 cat >>confdefs.h <<_ACEOF
15376 #define HAVE_DECL_ISBLANK $ac_have_decl
15377 _ACEOF
15378
15379
15380
15381
15382 fi
15383
15384
15385
15386 FREXP_LIBM=
15387 if test $gl_cv_func_frexp_no_libm = no; then
15388 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexp() can be used with libm" >&5
15389 $as_echo_n "checking whether frexp() can be used with libm... " >&6; }
15390 if test "${gl_cv_func_frexp_in_libm+set}" = set; then :
15391 $as_echo_n "(cached) " >&6
15392 else
15393
15394 save_LIBS="$LIBS"
15395 LIBS="$LIBS -lm"
15396 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15397 /* end confdefs.h. */
15398 #include <math.h>
15399 double x;
15400 int
15401 main ()
15402 {
15403 int e; return frexp (x, &e) > 0;
15404 ;
15405 return 0;
15406 }
15407 _ACEOF
15408 if ac_fn_c_try_link "$LINENO"; then :
15409 gl_cv_func_frexp_in_libm=yes
15410 else
15411 gl_cv_func_frexp_in_libm=no
15412 fi
15413 rm -f core conftest.err conftest.$ac_objext \
15414 conftest$ac_exeext conftest.$ac_ext
15415 LIBS="$save_LIBS"
15416
15417 fi
15418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexp_in_libm" >&5
15419 $as_echo "$gl_cv_func_frexp_in_libm" >&6; }
15420 if test $gl_cv_func_frexp_in_libm = yes; then
15421 FREXP_LIBM=-lm
15422 fi
15423 fi
15424 if test $gl_cv_func_frexp_no_libm = yes \
15425 || test $gl_cv_func_frexp_in_libm = yes; then
15426 save_LIBS="$LIBS"
15427 LIBS="$LIBS $FREXP_LIBM"
15428
15429
15430
15431 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexp works" >&5
15432 $as_echo_n "checking whether frexp works... " >&6; }
15433 if test "${gl_cv_func_frexp_works+set}" = set; then :
15434 $as_echo_n "(cached) " >&6
15435 else
15436
15437 if test "$cross_compiling" = yes; then :
15438 case "$host_os" in
15439 netbsd* | irix* | mingw*) gl_cv_func_frexp_works="guessing no";;
15440 *) gl_cv_func_frexp_works="guessing yes";;
15441 esac
15442
15443 else
15444 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15445 /* end confdefs.h. */
15446
15447 #include <float.h>
15448 #include <math.h>
15449 #include <string.h>
15450 #if HAVE_DECL_ALARM
15451 # include <signal.h>
15452 # include <unistd.h>
15453 #endif
15454 /* HP cc on HP-UX 10.20 has a bug with the constant expression -0.0.
15455 ICC 10.0 has a bug when optimizing the expression -zero.
15456 The expression -DBL_MIN * DBL_MIN does not work when cross-compiling
15457 to PowerPC on Mac OS X 10.5. */
15458 #if defined __hpux || defined __sgi || defined __ICC
15459 static double
15460 compute_minus_zero (void)
15461 {
15462 return -DBL_MIN * DBL_MIN;
15463 }
15464 # define minus_zero compute_minus_zero ()
15465 #else
15466 double minus_zero = -0.0;
15467 #endif
15468 int main()
15469 {
15470 int result = 0;
15471 int i;
15472 volatile double x;
15473 double zero = 0.0;
15474 #if HAVE_DECL_ALARM
15475 /* NeXTstep 3.3 frexp() runs into an endless loop when called on an infinite
15476 number. Let the test fail in this case. */
15477 signal (SIGALRM, SIG_DFL);
15478 alarm (5);
15479 #endif
15480 /* Test on denormalized numbers. */
15481 for (i = 1, x = 1.0; i >= DBL_MIN_EXP; i--, x *= 0.5)
15482 ;
15483 if (x > 0.0)
15484 {
15485 int exp;
15486 double y = frexp (x, &exp);
15487 /* On machines with IEEE754 arithmetic: x = 1.11254e-308, exp = -1022.
15488 On NetBSD: y = 0.75. Correct: y = 0.5. */
15489 if (y != 0.5)
15490 result |= 1;
15491 }
15492 /* Test on infinite numbers. */
15493 x = 1.0 / zero;
15494 {
15495 int exp;
15496 double y = frexp (x, &exp);
15497 if (y != x)
15498 result |= 2;
15499 }
15500 /* Test on negative zero. */
15501 x = minus_zero;
15502 {
15503 int exp;
15504 double y = frexp (x, &exp);
15505 if (memcmp (&y, &x, sizeof x))
15506 result |= 4;
15507 }
15508 return result;
15509 }
15510 _ACEOF
15511 if ac_fn_c_try_run "$LINENO"; then :
15512 gl_cv_func_frexp_works=yes
15513 else
15514 gl_cv_func_frexp_works=no
15515 fi
15516 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15517 conftest.$ac_objext conftest.beam conftest.$ac_ext
15518 fi
15519
15520
15521 fi
15522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexp_works" >&5
15523 $as_echo "$gl_cv_func_frexp_works" >&6; }
15524
15525 LIBS="$save_LIBS"
15526 case "$gl_cv_func_frexp_works" in
15527 *yes) gl_func_frexp=yes ;;
15528 *) gl_func_frexp=no; REPLACE_FREXP=1; FREXP_LIBM= ;;
15529 esac
15530 else
15531 gl_func_frexp=no
15532 fi
15533 if test $gl_func_frexp = yes; then
15534
15535 $as_echo "#define HAVE_FREXP 1" >>confdefs.h
15536
15537 fi
15538
15539
15540 if test $gl_func_frexp != yes; then
15541
15542
15543
15544
15545
15546
15547
15548
15549 gl_LIBOBJS="$gl_LIBOBJS frexp.$ac_objext"
15550
15551 fi
15552
15553
15554
15555
15556
15557 GNULIB_FREXP=1
15558
15559
15560
15561
15562
15563 $as_echo "#define GNULIB_TEST_FREXP 1" >>confdefs.h
15564
15565
15566
15567
15568
15569
15570
15571
15572
15573 ac_fn_c_check_decl "$LINENO" "frexpl" "ac_cv_have_decl_frexpl" "#include <math.h>
15574 "
15575 if test "x$ac_cv_have_decl_frexpl" = x""yes; then :
15576
15577 else
15578 HAVE_DECL_FREXPL=0
15579 fi
15580
15581
15582 FREXPL_LIBM=
15583 if test $HAVE_DECL_FREXPL = 1; then
15584
15585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexpl() can be used without linking with libm" >&5
15586 $as_echo_n "checking whether frexpl() can be used without linking with libm... " >&6; }
15587 if test "${gl_cv_func_frexpl_no_libm+set}" = set; then :
15588 $as_echo_n "(cached) " >&6
15589 else
15590
15591 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15592 /* end confdefs.h. */
15593 #include <math.h>
15594 long double x;
15595 int
15596 main ()
15597 {
15598 int e; return frexpl (x, &e) > 0;
15599 ;
15600 return 0;
15601 }
15602 _ACEOF
15603 if ac_fn_c_try_link "$LINENO"; then :
15604 gl_cv_func_frexpl_no_libm=yes
15605 else
15606 gl_cv_func_frexpl_no_libm=no
15607 fi
15608 rm -f core conftest.err conftest.$ac_objext \
15609 conftest$ac_exeext conftest.$ac_ext
15610
15611 fi
15612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexpl_no_libm" >&5
15613 $as_echo "$gl_cv_func_frexpl_no_libm" >&6; }
15614
15615 if test $gl_cv_func_frexpl_no_libm = no; then
15616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexpl() can be used with libm" >&5
15617 $as_echo_n "checking whether frexpl() can be used with libm... " >&6; }
15618 if test "${gl_cv_func_frexpl_in_libm+set}" = set; then :
15619 $as_echo_n "(cached) " >&6
15620 else
15621
15622 save_LIBS="$LIBS"
15623 LIBS="$LIBS -lm"
15624 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15625 /* end confdefs.h. */
15626 #include <math.h>
15627 long double x;
15628 int
15629 main ()
15630 {
15631 int e; return frexpl (x, &e) > 0;
15632 ;
15633 return 0;
15634 }
15635 _ACEOF
15636 if ac_fn_c_try_link "$LINENO"; then :
15637 gl_cv_func_frexpl_in_libm=yes
15638 else
15639 gl_cv_func_frexpl_in_libm=no
15640 fi
15641 rm -f core conftest.err conftest.$ac_objext \
15642 conftest$ac_exeext conftest.$ac_ext
15643 LIBS="$save_LIBS"
15644
15645 fi
15646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexpl_in_libm" >&5
15647 $as_echo "$gl_cv_func_frexpl_in_libm" >&6; }
15648 if test $gl_cv_func_frexpl_in_libm = yes; then
15649 FREXPL_LIBM=-lm
15650 fi
15651 fi
15652 if test $gl_cv_func_frexpl_no_libm = yes \
15653 || test $gl_cv_func_frexpl_in_libm = yes; then
15654 save_LIBS="$LIBS"
15655 LIBS="$LIBS $FREXPL_LIBM"
15656
15657
15658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexpl works" >&5
15659 $as_echo_n "checking whether frexpl works... " >&6; }
15660 if test "${gl_cv_func_frexpl_works+set}" = set; then :
15661 $as_echo_n "(cached) " >&6
15662 else
15663
15664 if test "$cross_compiling" = yes; then :
15665
15666 case "$host_os" in
15667 aix | aix[3-6]* | beos* | darwin* | irix* | mingw* | pw*)
15668 gl_cv_func_frexpl_works="guessing no";;
15669 *) gl_cv_func_frexpl_works="guessing yes";;
15670 esac
15671
15672 else
15673 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15674 /* end confdefs.h. */
15675
15676 #include <float.h>
15677 #include <math.h>
15678 /* Override the values of <float.h>, like done in float.in.h. */
15679 #if defined __i386__ && (defined __BEOS__ || defined __OpenBSD__)
15680 # undef LDBL_MIN_EXP
15681 # define LDBL_MIN_EXP (-16381)
15682 #endif
15683 #if defined __i386__ && defined __FreeBSD__
15684 # undef LDBL_MIN_EXP
15685 # define LDBL_MIN_EXP (-16381)
15686 #endif
15687 #if (defined _ARCH_PPC || defined _POWER) && defined _AIX && (LDBL_MANT_DIG == 106) && defined __GNUC__
15688 # undef LDBL_MIN_EXP
15689 # define LDBL_MIN_EXP DBL_MIN_EXP
15690 #endif
15691 #if defined __sgi && (LDBL_MANT_DIG >= 106)
15692 # if defined __GNUC__
15693 # undef LDBL_MIN_EXP
15694 # define LDBL_MIN_EXP DBL_MIN_EXP
15695 # endif
15696 #endif
15697 extern
15698 #ifdef __cplusplus
15699 "C"
15700 #endif
15701 long double frexpl (long double, int *);
15702 int main()
15703 {
15704 int result = 0;
15705 volatile long double x;
15706 /* Test on finite numbers that fails on AIX 5.1. */
15707 x = 16.0L;
15708 {
15709 int exp = -9999;
15710 frexpl (x, &exp);
15711 if (exp != 5)
15712 result |= 1;
15713 }
15714 /* Test on finite numbers that fails on Mac OS X 10.4, because its frexpl
15715 function returns an invalid (incorrectly normalized) value: it returns
15716 y = { 0x3fe028f5, 0xc28f5c28, 0x3c9eb851, 0xeb851eb8 }
15717 but the correct result is
15718 0.505L = { 0x3fe028f5, 0xc28f5c29, 0xbc547ae1, 0x47ae1480 } */
15719 x = 1.01L;
15720 {
15721 int exp = -9999;
15722 long double y = frexpl (x, &exp);
15723 if (!(exp == 1 && y == 0.505L))
15724 result |= 2;
15725 }
15726 /* Test on large finite numbers. This fails on BeOS at i = 16322, while
15727 LDBL_MAX_EXP = 16384.
15728 In the loop end test, we test x against Infinity, rather than comparing
15729 i with LDBL_MAX_EXP, because BeOS <float.h> has a wrong LDBL_MAX_EXP. */
15730 {
15731 int i;
15732 for (i = 1, x = 1.0L; x != x + x; i++, x *= 2.0L)
15733 {
15734 int exp = -9999;
15735 frexpl (x, &exp);
15736 if (exp != i)
15737 {
15738 result |= 4;
15739 break;
15740 }
15741 }
15742 }
15743 /* Test on denormalized numbers. */
15744 {
15745 int i;
15746 for (i = 1, x = 1.0L; i >= LDBL_MIN_EXP; i--, x *= 0.5L)
15747 ;
15748 if (x > 0.0L)
15749 {
15750 int exp;
15751 long double y = frexpl (x, &exp);
15752 /* On machines with IEEE854 arithmetic: x = 1.68105e-4932,
15753 exp = -16382, y = 0.5. On Mac OS X 10.5: exp = -16384, y = 0.5. */
15754 if (exp != LDBL_MIN_EXP - 1)
15755 result |= 8;
15756 }
15757 }
15758 /* Test on infinite numbers. */
15759 x = 1.0L / 0.0L;
15760 {
15761 int exp;
15762 long double y = frexpl (x, &exp);
15763 if (y != x)
15764 result |= 16;
15765 }
15766 return result;
15767 }
15768 _ACEOF
15769 if ac_fn_c_try_run "$LINENO"; then :
15770 gl_cv_func_frexpl_works=yes
15771 else
15772 gl_cv_func_frexpl_works=no
15773 fi
15774 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15775 conftest.$ac_objext conftest.beam conftest.$ac_ext
15776 fi
15777
15778
15779 fi
15780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexpl_works" >&5
15781 $as_echo "$gl_cv_func_frexpl_works" >&6; }
15782
15783 LIBS="$save_LIBS"
15784 case "$gl_cv_func_frexpl_works" in
15785 *yes) gl_func_frexpl=yes ;;
15786 *) gl_func_frexpl=no; REPLACE_FREXPL=1 ;;
15787 esac
15788 else
15789 gl_func_frexpl=no
15790 fi
15791 if test $gl_func_frexpl = yes; then
15792
15793 $as_echo "#define HAVE_FREXPL 1" >>confdefs.h
15794
15795 fi
15796 fi
15797 if test $HAVE_DECL_FREXPL = 0 || test $gl_func_frexpl = no; then
15798 if test $HAVE_SAME_LONG_DOUBLE_AS_DOUBLE = 1; then
15799
15800 FREXPL_LIBM="$FREXP_LIBM"
15801 else
15802 FREXPL_LIBM=
15803 fi
15804 fi
15805
15806
15807 if test $HAVE_DECL_FREXPL = 0 || test $gl_func_frexpl = no; then
15808
15809
15810
15811
15812
15813
15814
15815
15816 gl_LIBOBJS="$gl_LIBOBJS frexpl.$ac_objext"
15817
15818 fi
15819
15820
15821
15822
15823
15824 GNULIB_FREXPL=1
15825
15826
15827
15828
15829
15830 $as_echo "#define GNULIB_TEST_FREXPL 1" >>confdefs.h
15831
15832
15833
15834
15835
15836
15837
15838 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
15839 REPLACE_FSTAT=1
15840 fi
15841
15842
15843 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
15844 REPLACE_FSTAT=1
15845 fi
15846
15847
15848
15849
15850
15851 if test $ac_cv_func_fchdir = no; then
15852 HAVE_FCHDIR=0
15853 fi
15854
15855 if test $HAVE_FCHDIR = 0; then
15856 case "$gl_cv_func_open_directory_works" in
15857 *yes) ;;
15858 *)
15859 REPLACE_FSTAT=1
15860 ;;
15861 esac
15862 fi
15863
15864
15865 if test $REPLACE_FSTAT = 1; then
15866
15867
15868
15869
15870
15871
15872
15873
15874 gl_LIBOBJS="$gl_LIBOBJS fstat.$ac_objext"
15875
15876 :
15877 fi
15878
15879
15880
15881
15882
15883 GNULIB_FSTAT=1
15884
15885
15886
15887
15888
15889 $as_echo "#define GNULIB_TEST_FSTAT 1" >>confdefs.h
15890
15891
15892
15893
15894
15895
15896
15897
15898
15899 if test $ac_cv_func_fstatat = no; then
15900 HAVE_FSTATAT=0
15901 else
15902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fstatat (..., 0) works" >&5
15903 $as_echo_n "checking whether fstatat (..., 0) works... " >&6; }
15904 if test "${gl_cv_func_fstatat_zero_flag+set}" = set; then :
15905 $as_echo_n "(cached) " >&6
15906 else
15907 if test "$cross_compiling" = yes; then :
15908 case "$host_os" in
15909 aix*) gl_cv_func_fstatat_zero_flag="guessing no";;
15910 *) gl_cv_func_fstatat_zero_flag="guessing yes";;
15911 esac
15912
15913 else
15914 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15915 /* end confdefs.h. */
15916
15917 #include <fcntl.h>
15918 #include <sys/stat.h>
15919 int
15920 main (void)
15921 {
15922 struct stat a;
15923 return fstatat (AT_FDCWD, ".", &a, 0) != 0;
15924 }
15925
15926 _ACEOF
15927 if ac_fn_c_try_run "$LINENO"; then :
15928 gl_cv_func_fstatat_zero_flag=yes
15929 else
15930 gl_cv_func_fstatat_zero_flag=no
15931 fi
15932 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15933 conftest.$ac_objext conftest.beam conftest.$ac_ext
15934 fi
15935
15936
15937 fi
15938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fstatat_zero_flag" >&5
15939 $as_echo "$gl_cv_func_fstatat_zero_flag" >&6; }
15940
15941 case $gl_cv_func_fstatat_zero_flag+$gl_cv_func_lstat_dereferences_slashed_symlink in
15942 *yes+*yes) ;;
15943 *) REPLACE_FSTATAT=1
15944 case $gl_cv_func_fstatat_zero_flag in
15945 *yes)
15946
15947 $as_echo "#define HAVE_WORKING_FSTATAT_ZERO_FLAG 1" >>confdefs.h
15948
15949 ;;
15950 esac
15951 ;;
15952 esac
15953 fi
15954
15955 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
15956
15957
15958
15959
15960
15961
15962
15963
15964 gl_LIBOBJS="$gl_LIBOBJS fstatat.$ac_objext"
15965
15966 fi
15967
15968
15969
15970
15971
15972 GNULIB_FSTATAT=1
15973
15974
15975
15976
15977
15978 $as_echo "#define GNULIB_TEST_FSTATAT 1" >>confdefs.h
15979
15980
15981
15982
15983
15984
15985
15986
15987 gl_abort_bug=no
15988 case "$host_os" in
15989 mingw*)
15990 gl_cv_func_getcwd_path_max=yes
15991 ;;
15992 *)
15993
15994
15995
15996
15997
15998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getcwd handles long file names properly" >&5
15999 $as_echo_n "checking whether getcwd handles long file names properly... " >&6; }
16000 if test "${gl_cv_func_getcwd_path_max+set}" = set; then :
16001 $as_echo_n "(cached) " >&6
16002 else
16003 # Arrange for deletion of the temporary directory this test creates.
16004 ac_clean_files="$ac_clean_files confdir3"
16005 if test "$cross_compiling" = yes; then :
16006 case "$host_os" in
16007 aix*) gl_cv_func_getcwd_path_max='no, it has the AIX bug';;
16008 *) gl_cv_func_getcwd_path_max=no;;
16009 esac
16010 else
16011 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16012 /* end confdefs.h. */
16013
16014 #include <errno.h>
16015 #include <stdlib.h>
16016 #if HAVE_UNISTD_H
16017 # include <unistd.h>
16018 #else
16019 # include <direct.h>
16020 #endif
16021 #include <string.h>
16022 #include <limits.h>
16023 #include <sys/stat.h>
16024 #include <sys/types.h>
16025 #include <fcntl.h>
16026
16027
16028 /* Arrange to define PATH_MAX, like "pathmax.h" does. */
16029 #if HAVE_UNISTD_H
16030 # include <unistd.h>
16031 #endif
16032 #include <limits.h>
16033 #if defined HAVE_SYS_PARAM_H && !defined PATH_MAX && !defined MAXPATHLEN
16034 # include <sys/param.h>
16035 #endif
16036 #if !defined PATH_MAX && defined MAXPATHLEN
16037 # define PATH_MAX MAXPATHLEN
16038 #endif
16039 #ifdef __hpux
16040 # undef PATH_MAX
16041 # define PATH_MAX 1024
16042 #endif
16043 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
16044 # undef PATH_MAX
16045 # define PATH_MAX 260
16046 #endif
16047
16048
16049 #ifndef AT_FDCWD
16050 # define AT_FDCWD 0
16051 #endif
16052 #ifdef ENAMETOOLONG
16053 # define is_ENAMETOOLONG(x) ((x) == ENAMETOOLONG)
16054 #else
16055 # define is_ENAMETOOLONG(x) 0
16056 #endif
16057
16058 /* Use the getcwd function, not any macro. */
16059 #undef getcwd
16060
16061 /* Don't get link errors because mkdir is redefined to rpl_mkdir. */
16062 #undef mkdir
16063
16064 #ifndef S_IRWXU
16065 # define S_IRWXU 0700
16066 #endif
16067
16068 /* The length of this name must be 8. */
16069 #define DIR_NAME "confdir3"
16070 #define DIR_NAME_LEN 8
16071 #define DIR_NAME_SIZE (DIR_NAME_LEN + 1)
16072
16073 /* The length of "../". */
16074 #define DOTDOTSLASH_LEN 3
16075
16076 /* Leftover bytes in the buffer, to work around library or OS bugs. */
16077 #define BUF_SLOP 20
16078
16079 int
16080 main ()
16081 {
16082 #ifndef PATH_MAX
16083 /* The Hurd doesn't define this, so getcwd can't exhibit the bug --
16084 at least not on a local file system. And if we were to start worrying
16085 about remote file systems, we'd have to enable the wrapper function
16086 all of the time, just to be safe. That's not worth the cost. */
16087 exit (0);
16088 #elif ((INT_MAX / (DIR_NAME_SIZE / DOTDOTSLASH_LEN + 1) \
16089 - DIR_NAME_SIZE - BUF_SLOP) \
16090 <= PATH_MAX)
16091 /* FIXME: Assuming there's a system for which this is true,
16092 this should be done in a compile test. */
16093 exit (0);
16094 #else
16095 char buf[PATH_MAX * (DIR_NAME_SIZE / DOTDOTSLASH_LEN + 1)
16096 + DIR_NAME_SIZE + BUF_SLOP];
16097 char *cwd = getcwd (buf, PATH_MAX);
16098 size_t initial_cwd_len;
16099 size_t cwd_len;
16100 int fail = 0;
16101 size_t n_chdirs = 0;
16102
16103 if (cwd == NULL)
16104 exit (10);
16105
16106 cwd_len = initial_cwd_len = strlen (cwd);
16107
16108 while (1)
16109 {
16110 size_t dotdot_max = PATH_MAX * (DIR_NAME_SIZE / DOTDOTSLASH_LEN);
16111 char *c = NULL;
16112
16113 cwd_len += DIR_NAME_SIZE;
16114 /* If mkdir or chdir fails, it could be that this system cannot create
16115 any file with an absolute name longer than PATH_MAX, such as cygwin.
16116 If so, leave fail as 0, because the current working directory can't
16117 be too long for getcwd if it can't even be created. For other
16118 errors, be pessimistic and consider that as a failure, too. */
16119 if (mkdir (DIR_NAME, S_IRWXU) < 0 || chdir (DIR_NAME) < 0)
16120 {
16121 if (! (errno == ERANGE || is_ENAMETOOLONG (errno)))
16122 fail = 20;
16123 break;
16124 }
16125
16126 if (PATH_MAX <= cwd_len && cwd_len < PATH_MAX + DIR_NAME_SIZE)
16127 {
16128 struct stat sb;
16129
16130 c = getcwd (buf, PATH_MAX);
16131 if (!c && errno == ENOENT)
16132 {
16133 fail = 11;
16134 break;
16135 }
16136 if (c)
16137 {
16138 fail = 31;
16139 break;
16140 }
16141 if (! (errno == ERANGE || is_ENAMETOOLONG (errno)))
16142 {
16143 fail = 21;
16144 break;
16145 }
16146
16147 /* Our replacement needs to be able to stat() long ../../paths,
16148 so generate a path larger than PATH_MAX to check,
16149 avoiding the replacement if we can't stat(). */
16150 c = getcwd (buf, cwd_len + 1);
16151 if (c && !AT_FDCWD && stat (c, &sb) != 0 && is_ENAMETOOLONG (errno))
16152 {
16153 fail = 32;
16154 break;
16155 }
16156 }
16157
16158 if (dotdot_max <= cwd_len - initial_cwd_len)
16159 {
16160 if (dotdot_max + DIR_NAME_SIZE < cwd_len - initial_cwd_len)
16161 break;
16162 c = getcwd (buf, cwd_len + 1);
16163 if (!c)
16164 {
16165 if (! (errno == ERANGE || errno == ENOENT
16166 || is_ENAMETOOLONG (errno)))
16167 {
16168 fail = 22;
16169 break;
16170 }
16171 if (AT_FDCWD || errno == ERANGE || errno == ENOENT)
16172 {
16173 fail = 12;
16174 break;
16175 }
16176 }
16177 }
16178
16179 if (c && strlen (c) != cwd_len)
16180 {
16181 fail = 23;
16182 break;
16183 }
16184 ++n_chdirs;
16185 }
16186
16187 /* Leaving behind such a deep directory is not polite.
16188 So clean up here, right away, even though the driving
16189 shell script would also clean up. */
16190 {
16191 size_t i;
16192
16193 /* Try rmdir first, in case the chdir failed. */
16194 rmdir (DIR_NAME);
16195 for (i = 0; i <= n_chdirs; i++)
16196 {
16197 if (chdir ("..") < 0)
16198 break;
16199 if (rmdir (DIR_NAME) != 0)
16200 break;
16201 }
16202 }
16203
16204 exit (fail);
16205 #endif
16206 }
16207
16208 _ACEOF
16209 if ac_fn_c_try_run "$LINENO"; then :
16210 gl_cv_func_getcwd_path_max=yes
16211 else
16212 case $? in
16213 10|11|12) gl_cv_func_getcwd_path_max='no, but it is partly working';;
16214 31) gl_cv_func_getcwd_path_max='no, it has the AIX bug';;
16215 32) gl_cv_func_getcwd_path_max='yes, but with shorter paths';;
16216 *) gl_cv_func_getcwd_path_max=no;;
16217 esac
16218 fi
16219 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16220 conftest.$ac_objext conftest.beam conftest.$ac_ext
16221 fi
16222
16223
16224 fi
16225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_path_max" >&5
16226 $as_echo "$gl_cv_func_getcwd_path_max" >&6; }
16227
16228 case "$gl_cv_func_getcwd_null" in
16229 *yes)
16230
16231
16232
16233
16234 for ac_func in getpagesize
16235 do :
16236 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
16237 if test "x$ac_cv_func_getpagesize" = x""yes; then :
16238 cat >>confdefs.h <<_ACEOF
16239 #define HAVE_GETPAGESIZE 1
16240 _ACEOF
16241
16242 fi
16243 done
16244
16245 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getcwd aborts when 4k < cwd_length < 16k" >&5
16246 $as_echo_n "checking whether getcwd aborts when 4k < cwd_length < 16k... " >&6; }
16247 if test "${gl_cv_func_getcwd_abort_bug+set}" = set; then :
16248 $as_echo_n "(cached) " >&6
16249 else
16250 # Remove any remnants of a previous test.
16251 rm -rf confdir-14B---
16252 # Arrange for deletion of the temporary directory this test creates.
16253 ac_clean_files="$ac_clean_files confdir-14B---"
16254 if test "$cross_compiling" = yes; then :
16255 gl_cv_func_getcwd_abort_bug=yes
16256 else
16257 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16258 /* end confdefs.h. */
16259
16260 #include <errno.h>
16261 #include <stdlib.h>
16262 #if HAVE_UNISTD_H
16263 # include <unistd.h>
16264 #else /* on Windows with MSVC */
16265 # include <direct.h>
16266 #endif
16267 #include <string.h>
16268 #include <sys/stat.h>
16269
16270
16271 /* Arrange to define PATH_MAX, like "pathmax.h" does. */
16272 #if HAVE_UNISTD_H
16273 # include <unistd.h>
16274 #endif
16275 #include <limits.h>
16276 #if defined HAVE_SYS_PARAM_H && !defined PATH_MAX && !defined MAXPATHLEN
16277 # include <sys/param.h>
16278 #endif
16279 #if !defined PATH_MAX && defined MAXPATHLEN
16280 # define PATH_MAX MAXPATHLEN
16281 #endif
16282 #ifdef __hpux
16283 # undef PATH_MAX
16284 # define PATH_MAX 1024
16285 #endif
16286 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
16287 # undef PATH_MAX
16288 # define PATH_MAX 260
16289 #endif
16290
16291
16292 /* Don't get link errors because mkdir is redefined to rpl_mkdir. */
16293 #undef mkdir
16294
16295 #ifndef S_IRWXU
16296 # define S_IRWXU 0700
16297 #endif
16298
16299 /* FIXME: skip the run-test altogether on systems without getpagesize. */
16300 #if ! HAVE_GETPAGESIZE
16301 # define getpagesize() 0
16302 #endif
16303
16304 /* This size is chosen to be larger than PATH_MAX (4k), yet smaller than
16305 the 16kB pagesize on ia64 linux. Those conditions make the code below
16306 trigger a bug in glibc's getcwd implementation before 2.4.90-10. */
16307 #define TARGET_LEN (5 * 1024)
16308
16309 int
16310 main ()
16311 {
16312 char *cwd;
16313 size_t initial_cwd_len;
16314 int fail = 0;
16315
16316 /* The bug is triggered when PATH_MAX < getpagesize (), so skip
16317 this relatively expensive and invasive test if that's not true. */
16318 #ifdef PATH_MAX
16319 int bug_possible = PATH_MAX < getpagesize ();
16320 #else
16321 int bug_possible = 0;
16322 #endif
16323 if (! bug_possible)
16324 return 0;
16325
16326 cwd = getcwd (NULL, 0);
16327 if (cwd == NULL)
16328 return 2;
16329
16330 initial_cwd_len = strlen (cwd);
16331 free (cwd);
16332
16333 if (1)
16334 {
16335 static char const dir_name[] = "confdir-14B---";
16336 size_t desired_depth = ((TARGET_LEN - 1 - initial_cwd_len)
16337 / sizeof dir_name);
16338 size_t d;
16339 for (d = 0; d < desired_depth; d++)
16340 {
16341 if (mkdir (dir_name, S_IRWXU) < 0 || chdir (dir_name) < 0)
16342 {
16343 if (! (errno == ERANGE || errno == ENAMETOOLONG
16344 || errno == ENOENT))
16345 fail = 3; /* Unable to construct deep hierarchy. */
16346 break;
16347 }
16348 }
16349
16350 /* If libc has the bug in question, this invocation of getcwd
16351 results in a failed assertion. */
16352 cwd = getcwd (NULL, 0);
16353 if (cwd == NULL)
16354 fail = 4; /* getcwd didn't assert, but it failed for a long name
16355 where the answer could have been learned. */
16356 free (cwd);
16357
16358 /* Call rmdir first, in case the above chdir failed. */
16359 rmdir (dir_name);
16360 while (0 < d--)
16361 {
16362 if (chdir ("..") < 0)
16363 {
16364 fail = 5;
16365 break;
16366 }
16367 rmdir (dir_name);
16368 }
16369 }
16370
16371 return fail;
16372 }
16373
16374 _ACEOF
16375 if ac_fn_c_try_run "$LINENO"; then :
16376 gl_cv_func_getcwd_abort_bug=no
16377 else
16378 ret=$?
16379 if test $ret -ge 128 || test $ret = 4; then
16380 gl_cv_func_getcwd_abort_bug=yes
16381 else
16382 gl_cv_func_getcwd_abort_bug=no
16383 fi
16384 fi
16385 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16386 conftest.$ac_objext conftest.beam conftest.$ac_ext
16387 fi
16388
16389
16390 fi
16391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_abort_bug" >&5
16392 $as_echo "$gl_cv_func_getcwd_abort_bug" >&6; }
16393 if test $gl_cv_func_getcwd_abort_bug = yes; then :
16394 gl_abort_bug=yes
16395 fi
16396
16397 ;;
16398 esac
16399 ;;
16400 esac
16401 case "$gl_cv_func_getcwd_path_max" in
16402 "no"|"no, it has the AIX bug") ;;
16403 *)
16404
16405 $as_echo "#define HAVE_MINIMALLY_WORKING_GETCWD 1" >>confdefs.h
16406
16407 ;;
16408 esac
16409 case "$gl_cv_func_getcwd_path_max" in
16410 "no, but it is partly working")
16411
16412 $as_echo "#define HAVE_PARTLY_WORKING_GETCWD 1" >>confdefs.h
16413
16414 ;;
16415 "yes, but with shorter paths")
16416
16417 $as_echo "#define HAVE_GETCWD_SHORTER 1" >>confdefs.h
16418
16419 ;;
16420 esac
16421
16422 if { case "$gl_cv_func_getcwd_null" in *yes) false;; *) true;; esac; } \
16423 || test $gl_cv_func_getcwd_posix_signature != yes \
16424 || { case "$gl_cv_func_getcwd_path_max" in *yes*) false;; *) true;; esac; } \
16425 || test $gl_abort_bug = yes; then
16426 REPLACE_GETCWD=1
16427 fi
16428
16429 if test $REPLACE_GETCWD = 1; then
16430
16431
16432
16433
16434
16435
16436
16437
16438 gl_LIBOBJS="$gl_LIBOBJS getcwd.$ac_objext"
16439
16440
16441
16442
16443 :
16444
16445 fi
16446
16447
16448 cat >>confdefs.h <<_ACEOF
16449 #define GNULIB_GETCWD 1
16450 _ACEOF
16451
16452
16453
16454
16455
16456
16457
16458 GNULIB_GETCWD=1
16459
16460
16461
16462
16463
16464 $as_echo "#define GNULIB_TEST_GETCWD 1" >>confdefs.h
16465
16466
16467
16468
16469
16470
16471
16472
16473 case $gl_cv_func_getcwd_null,$gl_cv_func_getcwd_posix_signature in
16474 *yes,yes) ;;
16475 *)
16476 REPLACE_GETCWD=1
16477 ;;
16478 esac
16479
16480 if test $REPLACE_GETCWD = 1; then
16481
16482
16483
16484
16485
16486
16487
16488
16489 gl_LIBOBJS="$gl_LIBOBJS getcwd-lgpl.$ac_objext"
16490
16491 fi
16492
16493
16494
16495
16496
16497 GNULIB_GETCWD=1
16498
16499
16500
16501
16502
16503 $as_echo "#define GNULIB_TEST_GETCWD 1" >>confdefs.h
16504
16505
16506
16507
16508
16509
16510
16511
16512 if test $ac_cv_func_getdtablesize = yes &&
16513 test $ac_cv_have_decl_getdtablesize = yes; then
16514 # Cygwin 1.7.25 automatically increases the RLIMIT_NOFILE soft limit
16515 # up to an unchangeable hard limit; all other platforms correctly
16516 # require setrlimit before getdtablesize() can report a larger value.
16517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getdtablesize works" >&5
16518 $as_echo_n "checking whether getdtablesize works... " >&6; }
16519 if test "${gl_cv_func_getdtablesize_works+set}" = set; then :
16520 $as_echo_n "(cached) " >&6
16521 else
16522 if test "$cross_compiling" = yes; then :
16523 case "$host_os" in
16524 cygwin*) # on cygwin 1.5.25, getdtablesize() automatically grows
16525 gl_cv_func_getdtablesize_works="guessing no" ;;
16526 *) gl_cv_func_getdtablesize_works="guessing yes" ;;
16527 esac
16528 else
16529 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16530 /* end confdefs.h. */
16531
16532 #include <unistd.h>
16533 int
16534 main ()
16535 {
16536 int size = getdtablesize();
16537 if (dup2 (0, getdtablesize()) != -1)
16538 return 1;
16539 if (size != getdtablesize())
16540 return 2;
16541
16542 ;
16543 return 0;
16544 }
16545 _ACEOF
16546 if ac_fn_c_try_run "$LINENO"; then :
16547 gl_cv_func_getdtablesize_works=yes
16548 else
16549 gl_cv_func_getdtablesize_works=no
16550 fi
16551 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16552 conftest.$ac_objext conftest.beam conftest.$ac_ext
16553 fi
16554
16555
16556 fi
16557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getdtablesize_works" >&5
16558 $as_echo "$gl_cv_func_getdtablesize_works" >&6; }
16559 case "$gl_cv_func_getdtablesize_works" in
16560 *yes) ;;
16561 *) REPLACE_GETDTABLESIZE=1 ;;
16562 esac
16563 else
16564 HAVE_GETDTABLESIZE=0
16565 fi
16566
16567 if test $HAVE_GETDTABLESIZE = 0 || test $REPLACE_GETDTABLESIZE = 1; then
16568
16569
16570
16571
16572
16573
16574
16575
16576 gl_LIBOBJS="$gl_LIBOBJS getdtablesize.$ac_objext"
16577
16578 :
16579 fi
16580
16581
16582
16583
16584
16585 GNULIB_GETDTABLESIZE=1
16586
16587
16588
16589
16590
16591 $as_echo "#define GNULIB_TEST_GETDTABLESIZE 1" >>confdefs.h
16592
16593
16594
16595
16596
16597
16598
16599
16600
16601 if test $ac_cv_have_decl_getlogin_r = no; then
16602 HAVE_DECL_GETLOGIN_R=0
16603 fi
16604
16605
16606 if test $ac_cv_func_getlogin_r = no; then
16607 HAVE_GETLOGIN_R=0
16608 else
16609 HAVE_GETLOGIN_R=1
16610
16611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getlogin_r works with small buffers" >&5
16612 $as_echo_n "checking whether getlogin_r works with small buffers... " >&6; }
16613 if test "${gl_cv_func_getlogin_r_works+set}" = set; then :
16614 $as_echo_n "(cached) " >&6
16615 else
16616
16617 case "$host_os" in
16618 # Guess no on OSF/1.
16619 osf*) gl_cv_func_getlogin_r_works="guessing no" ;;
16620 # Guess yes otherwise.
16621 *) gl_cv_func_getlogin_r_works="guessing yes" ;;
16622 esac
16623 if test "$cross_compiling" = yes; then :
16624 :
16625 else
16626 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16627 /* end confdefs.h. */
16628
16629 #include <stddef.h>
16630 #include <unistd.h>
16631 #if !HAVE_DECL_GETLOGIN_R
16632 extern
16633 # ifdef __cplusplus
16634 "C"
16635 # endif
16636 int getlogin_r (char *, size_t);
16637 #endif
16638 int
16639 main (void)
16640 {
16641 int result = 0;
16642 char buf[100];
16643
16644 if (getlogin_r (buf, 0) == 0)
16645 result |= 16;
16646 if (getlogin_r (buf, 1) == 0)
16647 result |= 17;
16648 return result;
16649 }
16650 _ACEOF
16651 if ac_fn_c_try_run "$LINENO"; then :
16652 gl_cv_func_getlogin_r_works=yes
16653 else
16654 case $? in
16655 16 | 17) gl_cv_func_getlogin_r_works=no ;;
16656 esac
16657
16658 fi
16659 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16660 conftest.$ac_objext conftest.beam conftest.$ac_ext
16661 fi
16662
16663
16664 fi
16665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getlogin_r_works" >&5
16666 $as_echo "$gl_cv_func_getlogin_r_works" >&6; }
16667 case "$gl_cv_func_getlogin_r_works" in
16668 *yes) ;;
16669 *) REPLACE_GETLOGIN_R=1 ;;
16670 esac
16671 fi
16672
16673 if test $HAVE_GETLOGIN_R = 0 || test $REPLACE_GETLOGIN_R = 1; then
16674
16675
16676
16677
16678
16679
16680
16681
16682 gl_LIBOBJS="$gl_LIBOBJS getlogin_r.$ac_objext"
16683
16684
16685
16686
16687 fi
16688
16689
16690
16691
16692
16693 GNULIB_GETLOGIN_R=1
16694
16695
16696
16697
16698
16699 $as_echo "#define GNULIB_TEST_GETLOGIN_R 1" >>confdefs.h
16700
16701
16702
16703
16704
16705
16706 ac_found=0
16707 ac_fn_c_check_decl "$LINENO" "program_invocation_name" "ac_cv_have_decl_program_invocation_name" "#include <errno.h>
16708 "
16709 if test "x$ac_cv_have_decl_program_invocation_name" = x""yes; then :
16710 ac_have_decl=1
16711 else
16712 ac_have_decl=0
16713 fi
16714
16715 cat >>confdefs.h <<_ACEOF
16716 #define HAVE_DECL_PROGRAM_INVOCATION_NAME $ac_have_decl
16717 _ACEOF
16718 if test $ac_have_decl = 1; then :
16719 ac_found=1
16720 fi
16721
16722 ac_fn_c_check_decl "$LINENO" "program_invocation_short_name" "ac_cv_have_decl_program_invocation_short_name" "#include <errno.h>
16723 "
16724 if test "x$ac_cv_have_decl_program_invocation_short_name" = x""yes; then :
16725 ac_have_decl=1
16726 else
16727 ac_have_decl=0
16728 fi
16729
16730 cat >>confdefs.h <<_ACEOF
16731 #define HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME $ac_have_decl
16732 _ACEOF
16733 if test $ac_have_decl = 1; then :
16734 ac_found=1
16735 fi
16736
16737 ac_fn_c_check_decl "$LINENO" "__argv" "ac_cv_have_decl___argv" "#include <stdlib.h>
16738 "
16739 if test "x$ac_cv_have_decl___argv" = x""yes; then :
16740 ac_have_decl=1
16741 else
16742 ac_have_decl=0
16743 fi
16744
16745 cat >>confdefs.h <<_ACEOF
16746 #define HAVE_DECL___ARGV $ac_have_decl
16747 _ACEOF
16748 if test $ac_have_decl = 1; then :
16749 ac_found=1
16750 fi
16751
16752
16753 # Incur the cost of this test only if none of the above worked.
16754 if test $ac_found = 0; then
16755 # On OpenBSD 5.1, using the global __progname variable appears to be
16756 # the only way to implement getprogname.
16757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __progname is defined in default libraries" >&5
16758 $as_echo_n "checking whether __progname is defined in default libraries... " >&6; }
16759 if test "${gl_cv_var___progname+set}" = set; then :
16760 $as_echo_n "(cached) " >&6
16761 else
16762
16763 gl_cv_var___progname=
16764 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16765 /* end confdefs.h. */
16766 extern char *__progname;
16767 int
16768 main ()
16769 {
16770 return *__progname;
16771
16772 ;
16773 return 0;
16774 }
16775 _ACEOF
16776 if ac_fn_c_try_link "$LINENO"; then :
16777 gl_cv_var___progname=yes
16778
16779 fi
16780 rm -f core conftest.err conftest.$ac_objext \
16781 conftest$ac_exeext conftest.$ac_ext
16782
16783
16784 fi
16785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_var___progname" >&5
16786 $as_echo "$gl_cv_var___progname" >&6; }
16787 if test "$gl_cv_var___progname" = yes; then
16788
16789 $as_echo "#define HAVE_VAR___PROGNAME 1" >>confdefs.h
16790
16791 fi
16792 fi
16793
16794
16795
16796
16797
16798
16799
16800
16801
16802 gl_gettimeofday_timezone=void
16803 if test $ac_cv_func_gettimeofday != yes; then
16804 HAVE_GETTIMEOFDAY=0
16805 else
16806
16807
16808
16809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
16810 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
16811 if test "${gl_cv_func_gettimeofday_clobber+set}" = set; then :
16812 $as_echo_n "(cached) " >&6
16813 else
16814 if test "$cross_compiling" = yes; then :
16815 # When cross-compiling:
16816 case "$host_os" in
16817 # Guess all is fine on glibc systems.
16818 *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
16819 # If we don't know, assume the worst.
16820 *) gl_cv_func_gettimeofday_clobber="guessing yes" ;;
16821 esac
16822
16823 else
16824 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16825 /* end confdefs.h. */
16826 #include <string.h>
16827 #include <sys/time.h>
16828 #include <time.h>
16829 #include <stdlib.h>
16830
16831 int
16832 main ()
16833 {
16834
16835 time_t t = 0;
16836 struct tm *lt;
16837 struct tm saved_lt;
16838 struct timeval tv;
16839 lt = localtime (&t);
16840 saved_lt = *lt;
16841 gettimeofday (&tv, NULL);
16842 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
16843
16844 ;
16845 return 0;
16846 }
16847 _ACEOF
16848 if ac_fn_c_try_run "$LINENO"; then :
16849 gl_cv_func_gettimeofday_clobber=no
16850 else
16851 gl_cv_func_gettimeofday_clobber=yes
16852 fi
16853 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16854 conftest.$ac_objext conftest.beam conftest.$ac_ext
16855 fi
16856
16857 fi
16858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
16859 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
16860
16861 case "$gl_cv_func_gettimeofday_clobber" in
16862 *yes)
16863 REPLACE_GETTIMEOFDAY=1
16864
16865 REPLACE_GMTIME=1
16866 REPLACE_LOCALTIME=1
16867
16868
16869 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
16870
16871 ;;
16872 esac
16873
16874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
16875 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
16876 if test "${gl_cv_func_gettimeofday_posix_signature+set}" = set; then :
16877 $as_echo_n "(cached) " >&6
16878 else
16879 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16880 /* end confdefs.h. */
16881 #include <sys/time.h>
16882 struct timeval c;
16883 int gettimeofday (struct timeval *restrict, void *restrict);
16884
16885 int
16886 main ()
16887 {
16888 /* glibc uses struct timezone * rather than the POSIX void *
16889 if _GNU_SOURCE is defined. However, since the only portable
16890 use of gettimeofday uses NULL as the second parameter, and
16891 since the glibc definition is actually more typesafe, it is
16892 not worth wrapping this to get a compliant signature. */
16893 int (*f) (struct timeval *restrict, void *restrict)
16894 = gettimeofday;
16895 int x = f (&c, 0);
16896 return !(x | c.tv_sec | c.tv_usec);
16897
16898 ;
16899 return 0;
16900 }
16901 _ACEOF
16902 if ac_fn_c_try_compile "$LINENO"; then :
16903 gl_cv_func_gettimeofday_posix_signature=yes
16904 else
16905 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16906 /* end confdefs.h. */
16907 #include <sys/time.h>
16908 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
16909
16910 int
16911 main ()
16912 {
16913
16914 ;
16915 return 0;
16916 }
16917 _ACEOF
16918 if ac_fn_c_try_compile "$LINENO"; then :
16919 gl_cv_func_gettimeofday_posix_signature=almost
16920 else
16921 gl_cv_func_gettimeofday_posix_signature=no
16922 fi
16923 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16924 fi
16925 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16926 fi
16927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
16928 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
16929 if test $gl_cv_func_gettimeofday_posix_signature = almost; then
16930 gl_gettimeofday_timezone='struct timezone'
16931 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
16932 REPLACE_GETTIMEOFDAY=1
16933 fi
16934 if test $REPLACE_STRUCT_TIMEVAL = 1; then
16935 REPLACE_GETTIMEOFDAY=1
16936 fi
16937
16938 fi
16939
16940 cat >>confdefs.h <<_ACEOF
16941 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
16942 _ACEOF
16943
16944
16945 if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
16946
16947
16948
16949
16950
16951
16952
16953
16954 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
16955
16956
16957 for ac_header in sys/timeb.h
16958 do :
16959 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
16960 if test "x$ac_cv_header_sys_timeb_h" = x""yes; then :
16961 cat >>confdefs.h <<_ACEOF
16962 #define HAVE_SYS_TIMEB_H 1
16963 _ACEOF
16964
16965 fi
16966
16967 done
16968
16969 for ac_func in _ftime
16970 do :
16971 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
16972 if test "x$ac_cv_func__ftime" = x""yes; then :
16973 cat >>confdefs.h <<_ACEOF
16974 #define HAVE__FTIME 1
16975 _ACEOF
16976
16977 fi
16978 done
16979
16980
16981 fi
16982
16983
16984
16985
16986
16987 GNULIB_GETTIMEOFDAY=1
16988
16989
16990
16991
16992
16993 $as_echo "#define GNULIB_TEST_GETTIMEOFDAY 1" >>confdefs.h
16994
16995
16996
16997 GLOB_H=
16998 for ac_header in glob.h
16999 do :
17000 ac_fn_c_check_header_mongrel "$LINENO" "glob.h" "ac_cv_header_glob_h" "$ac_includes_default"
17001 if test "x$ac_cv_header_glob_h" = x""yes; then :
17002 cat >>confdefs.h <<_ACEOF
17003 #define HAVE_GLOB_H 1
17004 _ACEOF
17005
17006 else
17007 GLOB_H=glob.h
17008 fi
17009
17010 done
17011
17012
17013 if test -z "$GLOB_H"; then
17014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU glob interface version 1" >&5
17015 $as_echo_n "checking for GNU glob interface version 1... " >&6; }
17016 if test "${gl_cv_gnu_glob_interface_version_1+set}" = set; then :
17017 $as_echo_n "(cached) " >&6
17018 else
17019 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17020 /* end confdefs.h. */
17021 #include <gnu-versions.h>
17022 char a[_GNU_GLOB_INTERFACE_VERSION == 1 ? 1 : -1];
17023 _ACEOF
17024 if ac_fn_c_try_compile "$LINENO"; then :
17025 gl_cv_gnu_glob_interface_version_1=yes
17026 else
17027 gl_cv_gnu_glob_interface_version_1=no
17028 fi
17029 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17030 fi
17031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_gnu_glob_interface_version_1" >&5
17032 $as_echo "$gl_cv_gnu_glob_interface_version_1" >&6; }
17033
17034 if test "$gl_cv_gnu_glob_interface_version_1" = "no"; then
17035 GLOB_H=glob.h
17036 fi
17037 fi
17038
17039 if test -z "$GLOB_H"; then
17040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether glob lists broken symlinks" >&5
17041 $as_echo_n "checking whether glob lists broken symlinks... " >&6; }
17042 if test "${gl_cv_glob_lists_symlinks+set}" = set; then :
17043 $as_echo_n "(cached) " >&6
17044 else
17045 if ln -s conf-doesntexist conf$$-globtest 2>/dev/null; then
17046 gl_cv_glob_lists_symlinks=maybe
17047 else
17048 # If we can't make a symlink, then we cannot test this issue. Be
17049 # pessimistic about this.
17050 gl_cv_glob_lists_symlinks=no
17051 fi
17052
17053 if test $gl_cv_glob_lists_symlinks = maybe; then
17054 if test "$cross_compiling" = yes; then :
17055 gl_cv_glob_lists_symlinks=no
17056 else
17057 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17058 /* end confdefs.h. */
17059
17060 #include <stddef.h>
17061 #include <glob.h>
17062 int
17063 main ()
17064 {
17065 glob_t found;
17066 if (glob ("conf*-globtest", 0, NULL, &found) == GLOB_NOMATCH) return 1;
17067 ;
17068 return 0;
17069 }
17070 _ACEOF
17071 if ac_fn_c_try_run "$LINENO"; then :
17072 gl_cv_glob_lists_symlinks=yes
17073 else
17074 gl_cv_glob_lists_symlinks=no
17075 fi
17076 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17077 conftest.$ac_objext conftest.beam conftest.$ac_ext
17078 fi
17079
17080 fi
17081 fi
17082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_glob_lists_symlinks" >&5
17083 $as_echo "$gl_cv_glob_lists_symlinks" >&6; }
17084
17085 if test $gl_cv_glob_lists_symlinks = no; then
17086 GLOB_H=glob.h
17087 fi
17088 fi
17089
17090 rm -f conf$$-globtest
17091
17092
17093 if test -n "$GLOB_H"; then
17094 GL_GENERATE_GLOB_H_TRUE=
17095 GL_GENERATE_GLOB_H_FALSE='#'
17096 else
17097 GL_GENERATE_GLOB_H_TRUE='#'
17098 GL_GENERATE_GLOB_H_FALSE=
17099 fi
17100
17101
17102 if test -n "$GLOB_H"; then
17103
17104
17105
17106
17107
17108
17109
17110
17111 gl_LIBOBJS="$gl_LIBOBJS glob.$ac_objext"
17112
17113
17114 if test $ac_cv_header_sys_cdefs_h = yes; then
17115 HAVE_SYS_CDEFS_H=1
17116 else
17117 HAVE_SYS_CDEFS_H=0
17118 fi
17119
17120
17121 fi
17122
17123 :
17124
17125
17126
17127
17128
17129
17130 PRIPTR_PREFIX=
17131 if test -n "$STDINT_H"; then
17132 PRIPTR_PREFIX='"l"'
17133 else
17134 for glpfx in '' l ll I64; do
17135 case $glpfx in
17136 '') gltype1='int';;
17137 l) gltype1='long int';;
17138 ll) gltype1='long long int';;
17139 I64) gltype1='__int64';;
17140 esac
17141 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17142 /* end confdefs.h. */
17143 #include <stdint.h>
17144 extern intptr_t foo;
17145 extern $gltype1 foo;
17146 int
17147 main ()
17148 {
17149
17150 ;
17151 return 0;
17152 }
17153 _ACEOF
17154 if ac_fn_c_try_compile "$LINENO"; then :
17155 PRIPTR_PREFIX='"'$glpfx'"'
17156 fi
17157 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17158 test -n "$PRIPTR_PREFIX" && break
17159 done
17160 fi
17161
17162
17163
17164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether INT32_MAX < INTMAX_MAX" >&5
17165 $as_echo_n "checking whether INT32_MAX < INTMAX_MAX... " >&6; }
17166 if test "${gl_cv_test_INT32_MAX_LT_INTMAX_MAX+set}" = set; then :
17167 $as_echo_n "(cached) " >&6
17168 else
17169 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17170 /* end confdefs.h. */
17171 /* Work also in C++ mode. */
17172 #define __STDC_LIMIT_MACROS 1
17173
17174 /* Work if build is not clean. */
17175 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
17176
17177 #include <limits.h>
17178 #if HAVE_STDINT_H
17179 #include <stdint.h>
17180 #endif
17181
17182 #if defined INT32_MAX && defined INTMAX_MAX
17183 #define CONDITION (INT32_MAX < INTMAX_MAX)
17184 #elif HAVE_LONG_LONG_INT
17185 #define CONDITION (sizeof (int) < sizeof (long long int))
17186 #else
17187 #define CONDITION 0
17188 #endif
17189 int test[CONDITION ? 1 : -1];
17190 int
17191 main ()
17192 {
17193
17194 ;
17195 return 0;
17196 }
17197 _ACEOF
17198 if ac_fn_c_try_compile "$LINENO"; then :
17199 gl_cv_test_INT32_MAX_LT_INTMAX_MAX=yes
17200 else
17201 gl_cv_test_INT32_MAX_LT_INTMAX_MAX=no
17202 fi
17203 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17204 fi
17205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_INT32_MAX_LT_INTMAX_MAX" >&5
17206 $as_echo "$gl_cv_test_INT32_MAX_LT_INTMAX_MAX" >&6; }
17207 if test $gl_cv_test_INT32_MAX_LT_INTMAX_MAX = yes; then
17208 INT32_MAX_LT_INTMAX_MAX=1;
17209 else
17210 INT32_MAX_LT_INTMAX_MAX=0;
17211 fi
17212
17213
17214 if test $APPLE_UNIVERSAL_BUILD = 0; then
17215
17216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether INT64_MAX == LONG_MAX" >&5
17217 $as_echo_n "checking whether INT64_MAX == LONG_MAX... " >&6; }
17218 if test "${gl_cv_test_INT64_MAX_EQ_LONG_MAX+set}" = set; then :
17219 $as_echo_n "(cached) " >&6
17220 else
17221 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17222 /* end confdefs.h. */
17223 /* Work also in C++ mode. */
17224 #define __STDC_LIMIT_MACROS 1
17225
17226 /* Work if build is not clean. */
17227 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
17228
17229 #include <limits.h>
17230 #if HAVE_STDINT_H
17231 #include <stdint.h>
17232 #endif
17233
17234 #if defined INT64_MAX
17235 #define CONDITION (INT64_MAX == LONG_MAX)
17236 #elif HAVE_LONG_LONG_INT
17237 #define CONDITION (sizeof (long long int) == sizeof (long int))
17238 #else
17239 #define CONDITION 0
17240 #endif
17241 int test[CONDITION ? 1 : -1];
17242 int
17243 main ()
17244 {
17245
17246 ;
17247 return 0;
17248 }
17249 _ACEOF
17250 if ac_fn_c_try_compile "$LINENO"; then :
17251 gl_cv_test_INT64_MAX_EQ_LONG_MAX=yes
17252 else
17253 gl_cv_test_INT64_MAX_EQ_LONG_MAX=no
17254 fi
17255 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17256 fi
17257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_INT64_MAX_EQ_LONG_MAX" >&5
17258 $as_echo "$gl_cv_test_INT64_MAX_EQ_LONG_MAX" >&6; }
17259 if test $gl_cv_test_INT64_MAX_EQ_LONG_MAX = yes; then
17260 INT64_MAX_EQ_LONG_MAX=1;
17261 else
17262 INT64_MAX_EQ_LONG_MAX=0;
17263 fi
17264
17265
17266 else
17267 INT64_MAX_EQ_LONG_MAX=-1
17268 fi
17269
17270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether UINT32_MAX < UINTMAX_MAX" >&5
17271 $as_echo_n "checking whether UINT32_MAX < UINTMAX_MAX... " >&6; }
17272 if test "${gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX+set}" = set; then :
17273 $as_echo_n "(cached) " >&6
17274 else
17275 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17276 /* end confdefs.h. */
17277 /* Work also in C++ mode. */
17278 #define __STDC_LIMIT_MACROS 1
17279
17280 /* Work if build is not clean. */
17281 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
17282
17283 #include <limits.h>
17284 #if HAVE_STDINT_H
17285 #include <stdint.h>
17286 #endif
17287
17288 #if defined UINT32_MAX && defined UINTMAX_MAX
17289 #define CONDITION (UINT32_MAX < UINTMAX_MAX)
17290 #elif HAVE_LONG_LONG_INT
17291 #define CONDITION (sizeof (unsigned int) < sizeof (unsigned long long int))
17292 #else
17293 #define CONDITION 0
17294 #endif
17295 int test[CONDITION ? 1 : -1];
17296 int
17297 main ()
17298 {
17299
17300 ;
17301 return 0;
17302 }
17303 _ACEOF
17304 if ac_fn_c_try_compile "$LINENO"; then :
17305 gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX=yes
17306 else
17307 gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX=no
17308 fi
17309 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17310 fi
17311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX" >&5
17312 $as_echo "$gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX" >&6; }
17313 if test $gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX = yes; then
17314 UINT32_MAX_LT_UINTMAX_MAX=1;
17315 else
17316 UINT32_MAX_LT_UINTMAX_MAX=0;
17317 fi
17318
17319
17320 if test $APPLE_UNIVERSAL_BUILD = 0; then
17321
17322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether UINT64_MAX == ULONG_MAX" >&5
17323 $as_echo_n "checking whether UINT64_MAX == ULONG_MAX... " >&6; }
17324 if test "${gl_cv_test_UINT64_MAX_EQ_ULONG_MAX+set}" = set; then :
17325 $as_echo_n "(cached) " >&6
17326 else
17327 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17328 /* end confdefs.h. */
17329 /* Work also in C++ mode. */
17330 #define __STDC_LIMIT_MACROS 1
17331
17332 /* Work if build is not clean. */
17333 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
17334
17335 #include <limits.h>
17336 #if HAVE_STDINT_H
17337 #include <stdint.h>
17338 #endif
17339
17340 #if defined UINT64_MAX
17341 #define CONDITION (UINT64_MAX == ULONG_MAX)
17342 #elif HAVE_LONG_LONG_INT
17343 #define CONDITION (sizeof (unsigned long long int) == sizeof (unsigned long int))
17344 #else
17345 #define CONDITION 0
17346 #endif
17347 int test[CONDITION ? 1 : -1];
17348 int
17349 main ()
17350 {
17351
17352 ;
17353 return 0;
17354 }
17355 _ACEOF
17356 if ac_fn_c_try_compile "$LINENO"; then :
17357 gl_cv_test_UINT64_MAX_EQ_ULONG_MAX=yes
17358 else
17359 gl_cv_test_UINT64_MAX_EQ_ULONG_MAX=no
17360 fi
17361 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17362 fi
17363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_UINT64_MAX_EQ_ULONG_MAX" >&5
17364 $as_echo "$gl_cv_test_UINT64_MAX_EQ_ULONG_MAX" >&6; }
17365 if test $gl_cv_test_UINT64_MAX_EQ_ULONG_MAX = yes; then
17366 UINT64_MAX_EQ_ULONG_MAX=1;
17367 else
17368 UINT64_MAX_EQ_ULONG_MAX=0;
17369 fi
17370
17371
17372 else
17373 UINT64_MAX_EQ_ULONG_MAX=-1
17374 fi
17375
17376
17377
17378
17379
17380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnan(double) can be used without linking with libm" >&5
17381 $as_echo_n "checking whether isnan(double) can be used without linking with libm... " >&6; }
17382 if test "${gl_cv_func_isnand_no_libm+set}" = set; then :
17383 $as_echo_n "(cached) " >&6
17384 else
17385
17386 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17387 /* end confdefs.h. */
17388 #include <math.h>
17389 #if __GNUC__ >= 4
17390 # undef isnand
17391 # define isnand(x) __builtin_isnan ((double)(x))
17392 #else
17393 # undef isnand
17394 # define isnand(x) isnan ((double)(x))
17395 #endif
17396 double x;
17397 int
17398 main ()
17399 {
17400 return isnand (x);
17401 ;
17402 return 0;
17403 }
17404 _ACEOF
17405 if ac_fn_c_try_link "$LINENO"; then :
17406 gl_cv_func_isnand_no_libm=yes
17407 else
17408 gl_cv_func_isnand_no_libm=no
17409 fi
17410 rm -f core conftest.err conftest.$ac_objext \
17411 conftest$ac_exeext conftest.$ac_ext
17412
17413 fi
17414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnand_no_libm" >&5
17415 $as_echo "$gl_cv_func_isnand_no_libm" >&6; }
17416
17417 gl_func_isnand_no_libm=$gl_cv_func_isnand_no_libm
17418 if test $gl_cv_func_isnand_no_libm = yes; then
17419
17420 $as_echo "#define HAVE_ISNAND_IN_LIBC 1" >>confdefs.h
17421
17422 fi
17423
17424 if test $gl_func_isnand_no_libm != yes; then
17425
17426
17427
17428
17429
17430
17431
17432
17433 gl_LIBOBJS="$gl_LIBOBJS isnand.$ac_objext"
17434
17435
17436
17437
17438 fi
17439
17440
17441 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnan(long double) can be used without linking with libm" >&5
17442 $as_echo_n "checking whether isnan(long double) can be used without linking with libm... " >&6; }
17443 if test "${gl_cv_func_isnanl_no_libm+set}" = set; then :
17444 $as_echo_n "(cached) " >&6
17445 else
17446
17447 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17448 /* end confdefs.h. */
17449 #include <math.h>
17450 #if __GNUC__ >= 4
17451 # undef isnanl
17452 # define isnanl(x) __builtin_isnanl ((long double)(x))
17453 #elif defined isnan
17454 # undef isnanl
17455 # define isnanl(x) isnan ((long double)(x))
17456 #endif
17457 long double x;
17458 int
17459 main ()
17460 {
17461 return isnanl (x);
17462 ;
17463 return 0;
17464 }
17465 _ACEOF
17466 if ac_fn_c_try_link "$LINENO"; then :
17467 gl_cv_func_isnanl_no_libm=yes
17468 else
17469 gl_cv_func_isnanl_no_libm=no
17470 fi
17471 rm -f core conftest.err conftest.$ac_objext \
17472 conftest$ac_exeext conftest.$ac_ext
17473
17474 fi
17475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnanl_no_libm" >&5
17476 $as_echo "$gl_cv_func_isnanl_no_libm" >&6; }
17477
17478 gl_func_isnanl_no_libm=$gl_cv_func_isnanl_no_libm
17479 if test $gl_func_isnanl_no_libm = yes; then
17480
17481
17482
17483
17484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnanl works" >&5
17485 $as_echo_n "checking whether isnanl works... " >&6; }
17486 if test "${gl_cv_func_isnanl_works+set}" = set; then :
17487 $as_echo_n "(cached) " >&6
17488 else
17489
17490 if test "$cross_compiling" = yes; then :
17491 gl_cv_func_isnanl_works="guessing yes"
17492 else
17493 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17494 /* end confdefs.h. */
17495
17496 #include <float.h>
17497 #include <limits.h>
17498 #include <math.h>
17499 #if __GNUC__ >= 4
17500 # undef isnanl
17501 # define isnanl(x) __builtin_isnanl ((long double)(x))
17502 #elif defined isnan
17503 # undef isnanl
17504 # define isnanl(x) isnan ((long double)(x))
17505 #endif
17506 #define NWORDS \
17507 ((sizeof (long double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
17508 typedef union { unsigned int word[NWORDS]; long double value; }
17509 memory_long_double;
17510 /* On Irix 6.5, gcc 3.4.3 can't compute compile-time NaN, and needs the
17511 runtime type conversion. */
17512 #ifdef __sgi
17513 static long double NaNl ()
17514 {
17515 double zero = 0.0;
17516 return zero / zero;
17517 }
17518 #else
17519 # define NaNl() (0.0L / 0.0L)
17520 #endif
17521 int main ()
17522 {
17523 int result = 0;
17524
17525 if (!isnanl (NaNl ()))
17526 result |= 1;
17527
17528 {
17529 memory_long_double m;
17530 unsigned int i;
17531
17532 /* The isnanl function should be immune against changes in the sign bit and
17533 in the mantissa bits. The xor operation twiddles a bit that can only be
17534 a sign bit or a mantissa bit (since the exponent never extends to
17535 bit 31). */
17536 m.value = NaNl ();
17537 m.word[NWORDS / 2] ^= (unsigned int) 1 << (sizeof (unsigned int) * CHAR_BIT - 1);
17538 for (i = 0; i < NWORDS; i++)
17539 m.word[i] |= 1;
17540 if (!isnanl (m.value))
17541 result |= 1;
17542 }
17543
17544 #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
17545 /* Representation of an 80-bit 'long double' as an initializer for a sequence
17546 of 'unsigned int' words. */
17547 # ifdef WORDS_BIGENDIAN
17548 # define LDBL80_WORDS(exponent,manthi,mantlo) \
17549 { ((unsigned int) (exponent) << 16) | ((unsigned int) (manthi) >> 16), \
17550 ((unsigned int) (manthi) << 16) | ((unsigned int) (mantlo) >> 16), \
17551 (unsigned int) (mantlo) << 16 \
17552 }
17553 # else
17554 # define LDBL80_WORDS(exponent,manthi,mantlo) \
17555 { mantlo, manthi, exponent }
17556 # endif
17557 { /* Quiet NaN. */
17558 static memory_long_double x =
17559 { LDBL80_WORDS (0xFFFF, 0xC3333333, 0x00000000) };
17560 if (!isnanl (x.value))
17561 result |= 2;
17562 }
17563 {
17564 /* Signalling NaN. */
17565 static memory_long_double x =
17566 { LDBL80_WORDS (0xFFFF, 0x83333333, 0x00000000) };
17567 if (!isnanl (x.value))
17568 result |= 2;
17569 }
17570 /* isnanl should return something even for noncanonical values. */
17571 { /* Pseudo-NaN. */
17572 static memory_long_double x =
17573 { LDBL80_WORDS (0xFFFF, 0x40000001, 0x00000000) };
17574 if (isnanl (x.value) && !isnanl (x.value))
17575 result |= 4;
17576 }
17577 { /* Pseudo-Infinity. */
17578 static memory_long_double x =
17579 { LDBL80_WORDS (0xFFFF, 0x00000000, 0x00000000) };
17580 if (isnanl (x.value) && !isnanl (x.value))
17581 result |= 8;
17582 }
17583 { /* Pseudo-Zero. */
17584 static memory_long_double x =
17585 { LDBL80_WORDS (0x4004, 0x00000000, 0x00000000) };
17586 if (isnanl (x.value) && !isnanl (x.value))
17587 result |= 16;
17588 }
17589 { /* Unnormalized number. */
17590 static memory_long_double x =
17591 { LDBL80_WORDS (0x4000, 0x63333333, 0x00000000) };
17592 if (isnanl (x.value) && !isnanl (x.value))
17593 result |= 32;
17594 }
17595 { /* Pseudo-Denormal. */
17596 static memory_long_double x =
17597 { LDBL80_WORDS (0x0000, 0x83333333, 0x00000000) };
17598 if (isnanl (x.value) && !isnanl (x.value))
17599 result |= 64;
17600 }
17601 #endif
17602
17603 return result;
17604 }
17605 _ACEOF
17606 if ac_fn_c_try_run "$LINENO"; then :
17607 gl_cv_func_isnanl_works=yes
17608 else
17609 gl_cv_func_isnanl_works=no
17610 fi
17611 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17612 conftest.$ac_objext conftest.beam conftest.$ac_ext
17613 fi
17614
17615
17616 fi
17617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnanl_works" >&5
17618 $as_echo "$gl_cv_func_isnanl_works" >&6; }
17619
17620 case "$gl_cv_func_isnanl_works" in
17621 *yes) ;;
17622 *) gl_func_isnanl_no_libm=no ;;
17623 esac
17624 fi
17625 if test $gl_func_isnanl_no_libm = yes; then
17626
17627 $as_echo "#define HAVE_ISNANL_IN_LIBC 1" >>confdefs.h
17628
17629 fi
17630
17631 if test $gl_func_isnanl_no_libm != yes; then
17632
17633
17634
17635
17636
17637
17638
17639
17640 gl_LIBOBJS="$gl_LIBOBJS isnanl.$ac_objext"
17641
17642
17643
17644
17645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'long double'" >&5
17646 $as_echo_n "checking where to find the exponent in a 'long double'... " >&6; }
17647 if test "${gl_cv_cc_long_double_expbit0+set}" = set; then :
17648 $as_echo_n "(cached) " >&6
17649 else
17650
17651 if test "$cross_compiling" = yes; then :
17652
17653 gl_cv_cc_long_double_expbit0="unknown"
17654
17655 else
17656 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17657 /* end confdefs.h. */
17658
17659 #include <float.h>
17660 #include <stddef.h>
17661 #include <stdio.h>
17662 #include <string.h>
17663 #define NWORDS \
17664 ((sizeof (long double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
17665 typedef union { long double value; unsigned int word[NWORDS]; }
17666 memory_long_double;
17667 static unsigned int ored_words[NWORDS];
17668 static unsigned int anded_words[NWORDS];
17669 static void add_to_ored_words (long double x)
17670 {
17671 memory_long_double m;
17672 size_t i;
17673 /* Clear it first, in case
17674 sizeof (long double) < sizeof (memory_long_double). */
17675 memset (&m, 0, sizeof (memory_long_double));
17676 m.value = x;
17677 for (i = 0; i < NWORDS; i++)
17678 {
17679 ored_words[i] |= m.word[i];
17680 anded_words[i] &= m.word[i];
17681 }
17682 }
17683 int main ()
17684 {
17685 size_t j;
17686 FILE *fp = fopen ("conftest.out", "w");
17687 if (fp == NULL)
17688 return 1;
17689 for (j = 0; j < NWORDS; j++)
17690 anded_words[j] = ~ (unsigned int) 0;
17691 add_to_ored_words (0.25L);
17692 add_to_ored_words (0.5L);
17693 add_to_ored_words (1.0L);
17694 add_to_ored_words (2.0L);
17695 add_to_ored_words (4.0L);
17696 /* Remove bits that are common (e.g. if representation of the first mantissa
17697 bit is explicit). */
17698 for (j = 0; j < NWORDS; j++)
17699 ored_words[j] &= ~anded_words[j];
17700 /* Now find the nonzero word. */
17701 for (j = 0; j < NWORDS; j++)
17702 if (ored_words[j] != 0)
17703 break;
17704 if (j < NWORDS)
17705 {
17706 size_t i;
17707 for (i = j + 1; i < NWORDS; i++)
17708 if (ored_words[i] != 0)
17709 {
17710 fprintf (fp, "unknown");
17711 return (fclose (fp) != 0);
17712 }
17713 for (i = 0; ; i++)
17714 if ((ored_words[j] >> i) & 1)
17715 {
17716 fprintf (fp, "word %d bit %d", (int) j, (int) i);
17717 return (fclose (fp) != 0);
17718 }
17719 }
17720 fprintf (fp, "unknown");
17721 return (fclose (fp) != 0);
17722 }
17723
17724 _ACEOF
17725 if ac_fn_c_try_run "$LINENO"; then :
17726 gl_cv_cc_long_double_expbit0=`cat conftest.out`
17727 else
17728 gl_cv_cc_long_double_expbit0="unknown"
17729 fi
17730 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17731 conftest.$ac_objext conftest.beam conftest.$ac_ext
17732 fi
17733
17734 rm -f conftest.out
17735
17736 fi
17737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_long_double_expbit0" >&5
17738 $as_echo "$gl_cv_cc_long_double_expbit0" >&6; }
17739 case "$gl_cv_cc_long_double_expbit0" in
17740 word*bit*)
17741 word=`echo "$gl_cv_cc_long_double_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
17742 bit=`echo "$gl_cv_cc_long_double_expbit0" | sed -e 's/word.*bit //'`
17743
17744 cat >>confdefs.h <<_ACEOF
17745 #define LDBL_EXPBIT0_WORD $word
17746 _ACEOF
17747
17748
17749 cat >>confdefs.h <<_ACEOF
17750 #define LDBL_EXPBIT0_BIT $bit
17751 _ACEOF
17752
17753 ;;
17754 esac
17755
17756
17757
17758 fi
17759
17760
17761
17762
17763
17764
17765
17766
17767
17768
17769 LOCALCHARSET_TESTS_ENVIRONMENT="CHARSETALIASDIR=\"\$(abs_top_builddir)/$gl_source_base\""
17770
17771
17772
17773
17774 if test $ac_cv_func_lstat = yes; then
17775
17776 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
17777 *no)
17778 REPLACE_LSTAT=1
17779 ;;
17780 esac
17781 else
17782 HAVE_LSTAT=0
17783 fi
17784
17785 if test $REPLACE_LSTAT = 1; then
17786
17787
17788
17789
17790
17791
17792
17793
17794 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
17795
17796 :
17797 fi
17798
17799
17800
17801
17802
17803 GNULIB_LSTAT=1
17804
17805
17806
17807
17808
17809 $as_echo "#define GNULIB_TEST_LSTAT 1" >>confdefs.h
17810
17811
17812
17813
17814
17815
17816 if test $gl_cv_func_malloc_posix = yes; then
17817
17818 $as_echo "#define HAVE_MALLOC_POSIX 1" >>confdefs.h
17819
17820 else
17821 REPLACE_MALLOC=1
17822 fi
17823
17824 if test $REPLACE_MALLOC = 1; then
17825
17826
17827
17828
17829
17830
17831
17832
17833 gl_LIBOBJS="$gl_LIBOBJS malloc.$ac_objext"
17834
17835 fi
17836
17837
17838
17839
17840
17841 GNULIB_MALLOC_POSIX=1
17842
17843
17844
17845
17846
17847 $as_echo "#define GNULIB_TEST_MALLOC_POSIX 1" >>confdefs.h
17848
17849
17850
17851
17852
17853
17854
17855
17856
17857
17858
17859
17860
17861
17862
17863
17864
17865
17866 if test $gl_cv_have_include_next = yes; then
17867 gl_cv_next_math_h='<'math.h'>'
17868 else
17869 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <math.h>" >&5
17870 $as_echo_n "checking absolute name of <math.h>... " >&6; }
17871 if test "${gl_cv_next_math_h+set}" = set; then :
17872 $as_echo_n "(cached) " >&6
17873 else
17874
17875 if test $ac_cv_header_math_h = yes; then
17876
17877
17878
17879
17880 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17881 /* end confdefs.h. */
17882 #include <math.h>
17883 _ACEOF
17884 case "$host_os" in
17885 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17886 *) gl_absname_cpp="$ac_cpp" ;;
17887 esac
17888
17889 case "$host_os" in
17890 mingw*)
17891 gl_dirsep_regex='[/\\]'
17892 ;;
17893 *)
17894 gl_dirsep_regex='\/'
17895 ;;
17896 esac
17897 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17898 gl_header_literal_regex=`echo 'math.h' \
17899 | sed -e "$gl_make_literal_regex_sed"`
17900 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17901 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17902 s|^/[^/]|//&|
17903 p
17904 q
17905 }'
17906
17907 gl_cv_absolute_math_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17908 sed -n "$gl_absolute_header_sed"`
17909
17910 gl_header=$gl_cv_absolute_math_h
17911 gl_cv_next_math_h='"'$gl_header'"'
17912 else
17913 gl_cv_next_math_h='<'math.h'>'
17914 fi
17915
17916
17917 fi
17918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_math_h" >&5
17919 $as_echo "$gl_cv_next_math_h" >&6; }
17920 fi
17921 NEXT_MATH_H=$gl_cv_next_math_h
17922
17923 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17924 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17925 gl_next_as_first_directive='<'math.h'>'
17926 else
17927 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17928 gl_next_as_first_directive=$gl_cv_next_math_h
17929 fi
17930 NEXT_AS_FIRST_DIRECTIVE_MATH_H=$gl_next_as_first_directive
17931
17932
17933
17934
17935
17936 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NAN macro works" >&5
17937 $as_echo_n "checking whether NAN macro works... " >&6; }
17938 if test "${gl_cv_header_math_nan_works+set}" = set; then :
17939 $as_echo_n "(cached) " >&6
17940 else
17941 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17942 /* end confdefs.h. */
17943 #include <math.h>
17944 int
17945 main ()
17946 {
17947 /* Solaris 10 has a broken definition of NAN. Other platforms
17948 fail to provide NAN, or provide it only in C99 mode; this
17949 test only needs to fail when NAN is provided but wrong. */
17950 float f = 1.0f;
17951 #ifdef NAN
17952 f = NAN;
17953 #endif
17954 return f == 0;
17955 ;
17956 return 0;
17957 }
17958 _ACEOF
17959 if ac_fn_c_try_compile "$LINENO"; then :
17960 gl_cv_header_math_nan_works=yes
17961 else
17962 gl_cv_header_math_nan_works=no
17963 fi
17964 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17965 fi
17966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_math_nan_works" >&5
17967 $as_echo "$gl_cv_header_math_nan_works" >&6; }
17968 if test $gl_cv_header_math_nan_works = no; then
17969 REPLACE_NAN=1
17970 fi
17971 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether HUGE_VAL works" >&5
17972 $as_echo_n "checking whether HUGE_VAL works... " >&6; }
17973 if test "${gl_cv_header_math_huge_val_works+set}" = set; then :
17974 $as_echo_n "(cached) " >&6
17975 else
17976 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17977 /* end confdefs.h. */
17978 #include <math.h>
17979 int
17980 main ()
17981 {
17982 /* Solaris 10 has a broken definition of HUGE_VAL. */
17983 double d = HUGE_VAL;
17984 return d == 0;
17985 ;
17986 return 0;
17987 }
17988 _ACEOF
17989 if ac_fn_c_try_compile "$LINENO"; then :
17990 gl_cv_header_math_huge_val_works=yes
17991 else
17992 gl_cv_header_math_huge_val_works=no
17993 fi
17994 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17995 fi
17996 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_math_huge_val_works" >&5
17997 $as_echo "$gl_cv_header_math_huge_val_works" >&6; }
17998 if test $gl_cv_header_math_huge_val_works = no; then
17999 REPLACE_HUGE_VAL=1
18000 fi
18001
18002
18003 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
18004 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
18005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
18006 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
18007 if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
18008 $as_echo_n "(cached) " >&6
18009 else
18010 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18011 /* end confdefs.h. */
18012 #include <math.h>
18013 int
18014 main ()
18015 {
18016 #undef $gl_func
18017 (void) $gl_func;
18018 ;
18019 return 0;
18020 }
18021 _ACEOF
18022 if ac_fn_c_try_compile "$LINENO"; then :
18023 eval "$as_gl_Symbol=yes"
18024 else
18025 eval "$as_gl_Symbol=no"
18026 fi
18027 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18028 fi
18029 eval ac_res=\$$as_gl_Symbol
18030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18031 $as_echo "$ac_res" >&6; }
18032 eval as_val=\$$as_gl_Symbol
18033 if test "x$as_val" = x""yes; then :
18034 cat >>confdefs.h <<_ACEOF
18035 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
18036 _ACEOF
18037
18038 eval ac_cv_have_decl_$gl_func=yes
18039 fi
18040 done
18041
18042
18043
18044
18045
18046
18047
18048
18049
18050
18051
18052
18053 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
18054
18055
18056
18057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
18058 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
18059 if test "${gl_cv_func_mbrtowc_incomplete_state+set}" = set; then :
18060 $as_echo_n "(cached) " >&6
18061 else
18062
18063 case "$host_os" in
18064 # Guess no on AIX and OSF/1.
18065 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
18066 # Guess yes otherwise.
18067 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
18068 esac
18069 if test $LOCALE_JA != none; then
18070 if test "$cross_compiling" = yes; then :
18071 :
18072 else
18073 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18074 /* end confdefs.h. */
18075
18076 #include <locale.h>
18077 #include <string.h>
18078 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
18079 <wchar.h>.
18080 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18081 included before <wchar.h>. */
18082 #include <stddef.h>
18083 #include <stdio.h>
18084 #include <time.h>
18085 #include <wchar.h>
18086 int main ()
18087 {
18088 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
18089 {
18090 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
18091 mbstate_t state;
18092 wchar_t wc;
18093
18094 memset (&state, '\0', sizeof (mbstate_t));
18095 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
18096 if (mbsinit (&state))
18097 return 1;
18098 }
18099 return 0;
18100 }
18101 _ACEOF
18102 if ac_fn_c_try_run "$LINENO"; then :
18103 gl_cv_func_mbrtowc_incomplete_state=yes
18104 else
18105 gl_cv_func_mbrtowc_incomplete_state=no
18106 fi
18107 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18108 conftest.$ac_objext conftest.beam conftest.$ac_ext
18109 fi
18110
18111 fi
18112
18113 fi
18114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
18115 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
18116
18117
18118
18119
18120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
18121 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
18122 if test "${gl_cv_func_mbrtowc_sanitycheck+set}" = set; then :
18123 $as_echo_n "(cached) " >&6
18124 else
18125
18126 case "$host_os" in
18127 # Guess no on Solaris 8.
18128 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
18129 # Guess yes otherwise.
18130 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
18131 esac
18132 if test $LOCALE_ZH_CN != none; then
18133 if test "$cross_compiling" = yes; then :
18134 :
18135 else
18136 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18137 /* end confdefs.h. */
18138
18139 #include <locale.h>
18140 #include <stdlib.h>
18141 #include <string.h>
18142 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
18143 <wchar.h>.
18144 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18145 included before <wchar.h>. */
18146 #include <stddef.h>
18147 #include <stdio.h>
18148 #include <time.h>
18149 #include <wchar.h>
18150 int main ()
18151 {
18152 /* This fails on Solaris 8:
18153 mbrtowc returns 2, and sets wc to 0x00F0.
18154 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
18155 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
18156 {
18157 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
18158 mbstate_t state;
18159 wchar_t wc;
18160
18161 memset (&state, '\0', sizeof (mbstate_t));
18162 if (mbrtowc (&wc, input + 3, 6, &state) != 4
18163 && mbtowc (&wc, input + 3, 6) == 4)
18164 return 1;
18165 }
18166 return 0;
18167 }
18168 _ACEOF
18169 if ac_fn_c_try_run "$LINENO"; then :
18170 gl_cv_func_mbrtowc_sanitycheck=yes
18171 else
18172 gl_cv_func_mbrtowc_sanitycheck=no
18173 fi
18174 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18175 conftest.$ac_objext conftest.beam conftest.$ac_ext
18176 fi
18177
18178 fi
18179
18180 fi
18181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
18182 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
18183
18184 REPLACE_MBSTATE_T=0
18185 case "$gl_cv_func_mbrtowc_incomplete_state" in
18186 *yes) ;;
18187 *) REPLACE_MBSTATE_T=1 ;;
18188 esac
18189 case "$gl_cv_func_mbrtowc_sanitycheck" in
18190 *yes) ;;
18191 *) REPLACE_MBSTATE_T=1 ;;
18192 esac
18193 else
18194 REPLACE_MBSTATE_T=1
18195 fi
18196
18197
18198
18199 if test $ac_cv_func_mbrtowc = no; then
18200 HAVE_MBRTOWC=0
18201 ac_fn_c_check_decl "$LINENO" "mbrtowc" "ac_cv_have_decl_mbrtowc" "
18202 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
18203 <wchar.h>.
18204 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18205 included before <wchar.h>. */
18206 #include <stddef.h>
18207 #include <stdio.h>
18208 #include <time.h>
18209 #include <wchar.h>
18210
18211 "
18212 if test "x$ac_cv_have_decl_mbrtowc" = x""yes; then :
18213 ac_have_decl=1
18214 else
18215 ac_have_decl=0
18216 fi
18217
18218 cat >>confdefs.h <<_ACEOF
18219 #define HAVE_DECL_MBRTOWC $ac_have_decl
18220 _ACEOF
18221
18222 if test $ac_cv_have_decl_mbrtowc = yes; then
18223 REPLACE_MBRTOWC=1
18224 fi
18225 else
18226 if test $REPLACE_MBSTATE_T = 1; then
18227 REPLACE_MBRTOWC=1
18228 else
18229
18230
18231
18232 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles a NULL pwc argument" >&5
18233 $as_echo_n "checking whether mbrtowc handles a NULL pwc argument... " >&6; }
18234 if test "${gl_cv_func_mbrtowc_null_arg1+set}" = set; then :
18235 $as_echo_n "(cached) " >&6
18236 else
18237
18238 case "$host_os" in
18239 # Guess no on Solaris.
18240 solaris*) gl_cv_func_mbrtowc_null_arg1="guessing no" ;;
18241 # Guess yes otherwise.
18242 *) gl_cv_func_mbrtowc_null_arg1="guessing yes" ;;
18243 esac
18244 if test $LOCALE_FR_UTF8 != none; then
18245 if test "$cross_compiling" = yes; then :
18246 :
18247 else
18248 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18249 /* end confdefs.h. */
18250
18251 #include <locale.h>
18252 #include <stdlib.h>
18253 #include <string.h>
18254 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
18255 <wchar.h>.
18256 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18257 included before <wchar.h>. */
18258 #include <stddef.h>
18259 #include <stdio.h>
18260 #include <time.h>
18261 #include <wchar.h>
18262 int main ()
18263 {
18264 int result = 0;
18265
18266 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
18267 {
18268 char input[] = "\303\237er";
18269 mbstate_t state;
18270 wchar_t wc;
18271 size_t ret;
18272
18273 memset (&state, '\0', sizeof (mbstate_t));
18274 wc = (wchar_t) 0xBADFACE;
18275 ret = mbrtowc (&wc, input, 5, &state);
18276 if (ret != 2)
18277 result |= 1;
18278 if (!mbsinit (&state))
18279 result |= 2;
18280
18281 memset (&state, '\0', sizeof (mbstate_t));
18282 ret = mbrtowc (NULL, input, 5, &state);
18283 if (ret != 2) /* Solaris 7 fails here: ret is -1. */
18284 result |= 4;
18285 if (!mbsinit (&state))
18286 result |= 8;
18287 }
18288 return result;
18289 }
18290 _ACEOF
18291 if ac_fn_c_try_run "$LINENO"; then :
18292 gl_cv_func_mbrtowc_null_arg1=yes
18293 else
18294 gl_cv_func_mbrtowc_null_arg1=no
18295 fi
18296 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18297 conftest.$ac_objext conftest.beam conftest.$ac_ext
18298 fi
18299
18300 fi
18301
18302 fi
18303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_null_arg1" >&5
18304 $as_echo "$gl_cv_func_mbrtowc_null_arg1" >&6; }
18305
18306
18307
18308
18309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles a NULL string argument" >&5
18310 $as_echo_n "checking whether mbrtowc handles a NULL string argument... " >&6; }
18311 if test "${gl_cv_func_mbrtowc_null_arg2+set}" = set; then :
18312 $as_echo_n "(cached) " >&6
18313 else
18314
18315 case "$host_os" in
18316 # Guess no on OSF/1.
18317 osf*) gl_cv_func_mbrtowc_null_arg2="guessing no" ;;
18318 # Guess yes otherwise.
18319 *) gl_cv_func_mbrtowc_null_arg2="guessing yes" ;;
18320 esac
18321 if test $LOCALE_FR_UTF8 != none; then
18322 if test "$cross_compiling" = yes; then :
18323 :
18324 else
18325 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18326 /* end confdefs.h. */
18327
18328 #include <locale.h>
18329 #include <string.h>
18330 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
18331 <wchar.h>.
18332 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18333 included before <wchar.h>. */
18334 #include <stddef.h>
18335 #include <stdio.h>
18336 #include <time.h>
18337 #include <wchar.h>
18338 int main ()
18339 {
18340 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
18341 {
18342 mbstate_t state;
18343 wchar_t wc;
18344 int ret;
18345
18346 memset (&state, '\0', sizeof (mbstate_t));
18347 wc = (wchar_t) 0xBADFACE;
18348 mbrtowc (&wc, NULL, 5, &state);
18349 /* Check that wc was not modified. */
18350 if (wc != (wchar_t) 0xBADFACE)
18351 return 1;
18352 }
18353 return 0;
18354 }
18355 _ACEOF
18356 if ac_fn_c_try_run "$LINENO"; then :
18357 gl_cv_func_mbrtowc_null_arg2=yes
18358 else
18359 gl_cv_func_mbrtowc_null_arg2=no
18360 fi
18361 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18362 conftest.$ac_objext conftest.beam conftest.$ac_ext
18363 fi
18364
18365 fi
18366
18367 fi
18368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_null_arg2" >&5
18369 $as_echo "$gl_cv_func_mbrtowc_null_arg2" >&6; }
18370
18371
18372
18373
18374
18375
18376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc has a correct return value" >&5
18377 $as_echo_n "checking whether mbrtowc has a correct return value... " >&6; }
18378 if test "${gl_cv_func_mbrtowc_retval+set}" = set; then :
18379 $as_echo_n "(cached) " >&6
18380 else
18381
18382 case "$host_os" in
18383 # Guess no on HP-UX, Solaris, native Windows.
18384 hpux* | solaris* | mingw*) gl_cv_func_mbrtowc_retval="guessing no" ;;
18385 # Guess yes otherwise.
18386 *) gl_cv_func_mbrtowc_retval="guessing yes" ;;
18387 esac
18388 if test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none \
18389 || { case "$host_os" in mingw*) true;; *) false;; esac; }; then
18390 if test "$cross_compiling" = yes; then :
18391 :
18392 else
18393 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18394 /* end confdefs.h. */
18395
18396 #include <locale.h>
18397 #include <string.h>
18398 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
18399 <wchar.h>.
18400 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18401 included before <wchar.h>. */
18402 #include <stddef.h>
18403 #include <stdio.h>
18404 #include <time.h>
18405 #include <wchar.h>
18406 int main ()
18407 {
18408 int result = 0;
18409 int found_some_locale = 0;
18410 /* This fails on Solaris. */
18411 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
18412 {
18413 char input[] = "B\303\274\303\237er"; /* "Büßer" */
18414 mbstate_t state;
18415 wchar_t wc;
18416
18417 memset (&state, '\0', sizeof (mbstate_t));
18418 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
18419 {
18420 input[1] = '\0';
18421 if (mbrtowc (&wc, input + 2, 5, &state) != 1)
18422 result |= 1;
18423 }
18424 found_some_locale = 1;
18425 }
18426 /* This fails on HP-UX 11.11. */
18427 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
18428 {
18429 char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
18430 mbstate_t state;
18431 wchar_t wc;
18432
18433 memset (&state, '\0', sizeof (mbstate_t));
18434 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
18435 {
18436 input[1] = '\0';
18437 if (mbrtowc (&wc, input + 2, 5, &state) != 2)
18438 result |= 2;
18439 }
18440 found_some_locale = 1;
18441 }
18442 /* This fails on native Windows. */
18443 if (setlocale (LC_ALL, "Japanese_Japan.932") != NULL)
18444 {
18445 char input[] = "<\223\372\226\173\214\352>"; /* "<日本語>" */
18446 mbstate_t state;
18447 wchar_t wc;
18448
18449 memset (&state, '\0', sizeof (mbstate_t));
18450 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
18451 {
18452 input[3] = '\0';
18453 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
18454 result |= 4;
18455 }
18456 found_some_locale = 1;
18457 }
18458 if (setlocale (LC_ALL, "Chinese_Taiwan.950") != NULL)
18459 {
18460 char input[] = "<\244\351\245\273\273\171>"; /* "<日本語>" */
18461 mbstate_t state;
18462 wchar_t wc;
18463
18464 memset (&state, '\0', sizeof (mbstate_t));
18465 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
18466 {
18467 input[3] = '\0';
18468 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
18469 result |= 8;
18470 }
18471 found_some_locale = 1;
18472 }
18473 if (setlocale (LC_ALL, "Chinese_China.936") != NULL)
18474 {
18475 char input[] = "<\310\325\261\276\325\132>"; /* "<日本語>" */
18476 mbstate_t state;
18477 wchar_t wc;
18478
18479 memset (&state, '\0', sizeof (mbstate_t));
18480 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
18481 {
18482 input[3] = '\0';
18483 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
18484 result |= 16;
18485 }
18486 found_some_locale = 1;
18487 }
18488 return (found_some_locale ? result : 77);
18489 }
18490 _ACEOF
18491 if ac_fn_c_try_run "$LINENO"; then :
18492 gl_cv_func_mbrtowc_retval=yes
18493 else
18494 if test $? != 77; then
18495 gl_cv_func_mbrtowc_retval=no
18496 fi
18497
18498 fi
18499 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18500 conftest.$ac_objext conftest.beam conftest.$ac_ext
18501 fi
18502
18503 fi
18504
18505 fi
18506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_retval" >&5
18507 $as_echo "$gl_cv_func_mbrtowc_retval" >&6; }
18508
18509
18510
18511
18512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc returns 0 when parsing a NUL character" >&5
18513 $as_echo_n "checking whether mbrtowc returns 0 when parsing a NUL character... " >&6; }
18514 if test "${gl_cv_func_mbrtowc_nul_retval+set}" = set; then :
18515 $as_echo_n "(cached) " >&6
18516 else
18517
18518 case "$host_os" in
18519 # Guess no on Solaris 8 and 9.
18520 solaris2.[89]) gl_cv_func_mbrtowc_nul_retval="guessing no" ;;
18521 # Guess yes otherwise.
18522 *) gl_cv_func_mbrtowc_nul_retval="guessing yes" ;;
18523 esac
18524 if test $LOCALE_ZH_CN != none; then
18525 if test "$cross_compiling" = yes; then :
18526 :
18527 else
18528 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18529 /* end confdefs.h. */
18530
18531 #include <locale.h>
18532 #include <string.h>
18533 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
18534 <wchar.h>.
18535 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18536 included before <wchar.h>. */
18537 #include <stddef.h>
18538 #include <stdio.h>
18539 #include <time.h>
18540 #include <wchar.h>
18541 int main ()
18542 {
18543 /* This fails on Solaris 8 and 9. */
18544 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
18545 {
18546 mbstate_t state;
18547 wchar_t wc;
18548
18549 memset (&state, '\0', sizeof (mbstate_t));
18550 if (mbrtowc (&wc, "", 1, &state) != 0)
18551 return 1;
18552 }
18553 return 0;
18554 }
18555 _ACEOF
18556 if ac_fn_c_try_run "$LINENO"; then :
18557 gl_cv_func_mbrtowc_nul_retval=yes
18558 else
18559 gl_cv_func_mbrtowc_nul_retval=no
18560 fi
18561 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18562 conftest.$ac_objext conftest.beam conftest.$ac_ext
18563 fi
18564
18565 fi
18566
18567 fi
18568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_nul_retval" >&5
18569 $as_echo "$gl_cv_func_mbrtowc_nul_retval" >&6; }
18570
18571
18572
18573 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works on empty input" >&5
18574 $as_echo_n "checking whether mbrtowc works on empty input... " >&6; }
18575 if test "${gl_cv_func_mbrtowc_empty_input+set}" = set; then :
18576 $as_echo_n "(cached) " >&6
18577 else
18578
18579 case "$host_os" in
18580 # Guess no on AIX and glibc systems.
18581 aix* | *-gnu*)
18582 gl_cv_func_mbrtowc_empty_input="guessing no" ;;
18583 *) gl_cv_func_mbrtowc_empty_input="guessing yes" ;;
18584 esac
18585 if test "$cross_compiling" = yes; then :
18586 :
18587 else
18588 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18589 /* end confdefs.h. */
18590
18591 #include <wchar.h>
18592 static wchar_t wc;
18593 static mbstate_t mbs;
18594 int
18595 main (void)
18596 {
18597 return mbrtowc (&wc, "", 0, &mbs) != (size_t) -2;
18598 }
18599 _ACEOF
18600 if ac_fn_c_try_run "$LINENO"; then :
18601 gl_cv_func_mbrtowc_empty_input=yes
18602 else
18603 gl_cv_func_mbrtowc_empty_input=no
18604 fi
18605 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18606 conftest.$ac_objext conftest.beam conftest.$ac_ext
18607 fi
18608
18609
18610 fi
18611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_empty_input" >&5
18612 $as_echo "$gl_cv_func_mbrtowc_empty_input" >&6; }
18613
18614
18615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C locale is free of encoding errors" >&5
18616 $as_echo_n "checking whether the C locale is free of encoding errors... " >&6; }
18617 if test "${gl_cv_C_locale_sans_EILSEQ+set}" = set; then :
18618 $as_echo_n "(cached) " >&6
18619 else
18620
18621 gl_cv_C_locale_sans_EILSEQ="guessing no"
18622
18623 if test "$cross_compiling" = yes; then :
18624 :
18625 else
18626 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18627 /* end confdefs.h. */
18628 #include <limits.h>
18629 #include <locale.h>
18630 #include <wchar.h>
18631
18632 int
18633 main ()
18634 {
18635
18636 int i;
18637 char *locale = setlocale (LC_ALL, "C");
18638 if (! locale)
18639 return 1;
18640 for (i = CHAR_MIN; i <= CHAR_MAX; i++)
18641 {
18642 char c = i;
18643 wchar_t wc;
18644 mbstate_t mbs = { 0, };
18645 size_t ss = mbrtowc (&wc, &c, 1, &mbs);
18646 if (1 < ss)
18647 return 1;
18648 }
18649 return 0;
18650
18651 ;
18652 return 0;
18653 }
18654 _ACEOF
18655 if ac_fn_c_try_run "$LINENO"; then :
18656 gl_cv_C_locale_sans_EILSEQ=yes
18657 else
18658 gl_cv_C_locale_sans_EILSEQ=no
18659 fi
18660 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18661 conftest.$ac_objext conftest.beam conftest.$ac_ext
18662 fi
18663
18664 fi
18665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_C_locale_sans_EILSEQ" >&5
18666 $as_echo "$gl_cv_C_locale_sans_EILSEQ" >&6; }
18667
18668 case "$gl_cv_func_mbrtowc_null_arg1" in
18669 *yes) ;;
18670 *)
18671 $as_echo "#define MBRTOWC_NULL_ARG1_BUG 1" >>confdefs.h
18672
18673 REPLACE_MBRTOWC=1
18674 ;;
18675 esac
18676 case "$gl_cv_func_mbrtowc_null_arg2" in
18677 *yes) ;;
18678 *)
18679 $as_echo "#define MBRTOWC_NULL_ARG2_BUG 1" >>confdefs.h
18680
18681 REPLACE_MBRTOWC=1
18682 ;;
18683 esac
18684 case "$gl_cv_func_mbrtowc_retval" in
18685 *yes) ;;
18686 *)
18687 $as_echo "#define MBRTOWC_RETVAL_BUG 1" >>confdefs.h
18688
18689 REPLACE_MBRTOWC=1
18690 ;;
18691 esac
18692 case "$gl_cv_func_mbrtowc_nul_retval" in
18693 *yes) ;;
18694 *)
18695 $as_echo "#define MBRTOWC_NUL_RETVAL_BUG 1" >>confdefs.h
18696
18697 REPLACE_MBRTOWC=1
18698 ;;
18699 esac
18700 case "$gl_cv_func_mbrtowc_empty_input" in
18701 *yes) ;;
18702 *)
18703 $as_echo "#define MBRTOWC_EMPTY_INPUT_BUG 1" >>confdefs.h
18704
18705 REPLACE_MBRTOWC=1
18706 ;;
18707 esac
18708 case $gl_cv_C_locale_sans_EILSEQ in
18709 *yes) ;;
18710 *)
18711 $as_echo "#define C_LOCALE_MAYBE_EILSEQ 1" >>confdefs.h
18712
18713 REPLACE_MBRTOWC=1
18714 ;;
18715 esac
18716 fi
18717 fi
18718
18719 if test $HAVE_MBRTOWC = 0 || test $REPLACE_MBRTOWC = 1; then
18720
18721
18722
18723
18724
18725
18726
18727
18728 gl_LIBOBJS="$gl_LIBOBJS mbrtowc.$ac_objext"
18729
18730
18731 :
18732
18733 fi
18734
18735
18736
18737
18738
18739 GNULIB_MBRTOWC=1
18740
18741
18742
18743
18744
18745 $as_echo "#define GNULIB_TEST_MBRTOWC 1" >>confdefs.h
18746
18747
18748
18749
18750
18751
18752
18753
18754
18755
18756
18757
18758
18759
18760 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
18761
18762
18763
18764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
18765 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
18766 if test "${gl_cv_func_mbrtowc_incomplete_state+set}" = set; then :
18767 $as_echo_n "(cached) " >&6
18768 else
18769
18770 case "$host_os" in
18771 # Guess no on AIX and OSF/1.
18772 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
18773 # Guess yes otherwise.
18774 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
18775 esac
18776 if test $LOCALE_JA != none; then
18777 if test "$cross_compiling" = yes; then :
18778 :
18779 else
18780 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18781 /* end confdefs.h. */
18782
18783 #include <locale.h>
18784 #include <string.h>
18785 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
18786 <wchar.h>.
18787 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18788 included before <wchar.h>. */
18789 #include <stddef.h>
18790 #include <stdio.h>
18791 #include <time.h>
18792 #include <wchar.h>
18793 int main ()
18794 {
18795 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
18796 {
18797 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
18798 mbstate_t state;
18799 wchar_t wc;
18800
18801 memset (&state, '\0', sizeof (mbstate_t));
18802 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
18803 if (mbsinit (&state))
18804 return 1;
18805 }
18806 return 0;
18807 }
18808 _ACEOF
18809 if ac_fn_c_try_run "$LINENO"; then :
18810 gl_cv_func_mbrtowc_incomplete_state=yes
18811 else
18812 gl_cv_func_mbrtowc_incomplete_state=no
18813 fi
18814 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18815 conftest.$ac_objext conftest.beam conftest.$ac_ext
18816 fi
18817
18818 fi
18819
18820 fi
18821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
18822 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
18823
18824
18825
18826
18827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
18828 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
18829 if test "${gl_cv_func_mbrtowc_sanitycheck+set}" = set; then :
18830 $as_echo_n "(cached) " >&6
18831 else
18832
18833 case "$host_os" in
18834 # Guess no on Solaris 8.
18835 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
18836 # Guess yes otherwise.
18837 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
18838 esac
18839 if test $LOCALE_ZH_CN != none; then
18840 if test "$cross_compiling" = yes; then :
18841 :
18842 else
18843 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18844 /* end confdefs.h. */
18845
18846 #include <locale.h>
18847 #include <stdlib.h>
18848 #include <string.h>
18849 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
18850 <wchar.h>.
18851 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18852 included before <wchar.h>. */
18853 #include <stddef.h>
18854 #include <stdio.h>
18855 #include <time.h>
18856 #include <wchar.h>
18857 int main ()
18858 {
18859 /* This fails on Solaris 8:
18860 mbrtowc returns 2, and sets wc to 0x00F0.
18861 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
18862 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
18863 {
18864 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
18865 mbstate_t state;
18866 wchar_t wc;
18867
18868 memset (&state, '\0', sizeof (mbstate_t));
18869 if (mbrtowc (&wc, input + 3, 6, &state) != 4
18870 && mbtowc (&wc, input + 3, 6) == 4)
18871 return 1;
18872 }
18873 return 0;
18874 }
18875 _ACEOF
18876 if ac_fn_c_try_run "$LINENO"; then :
18877 gl_cv_func_mbrtowc_sanitycheck=yes
18878 else
18879 gl_cv_func_mbrtowc_sanitycheck=no
18880 fi
18881 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18882 conftest.$ac_objext conftest.beam conftest.$ac_ext
18883 fi
18884
18885 fi
18886
18887 fi
18888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
18889 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
18890
18891 REPLACE_MBSTATE_T=0
18892 case "$gl_cv_func_mbrtowc_incomplete_state" in
18893 *yes) ;;
18894 *) REPLACE_MBSTATE_T=1 ;;
18895 esac
18896 case "$gl_cv_func_mbrtowc_sanitycheck" in
18897 *yes) ;;
18898 *) REPLACE_MBSTATE_T=1 ;;
18899 esac
18900 else
18901 REPLACE_MBSTATE_T=1
18902 fi
18903
18904
18905
18906 if test $ac_cv_func_mbsinit = no; then
18907 HAVE_MBSINIT=0
18908 ac_fn_c_check_decl "$LINENO" "mbsinit" "ac_cv_have_decl_mbsinit" "
18909 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
18910 <wchar.h>.
18911 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18912 included before <wchar.h>. */
18913 #include <stddef.h>
18914 #include <stdio.h>
18915 #include <time.h>
18916 #include <wchar.h>
18917
18918 "
18919 if test "x$ac_cv_have_decl_mbsinit" = x""yes; then :
18920 ac_have_decl=1
18921 else
18922 ac_have_decl=0
18923 fi
18924
18925 cat >>confdefs.h <<_ACEOF
18926 #define HAVE_DECL_MBSINIT $ac_have_decl
18927 _ACEOF
18928
18929 if test $ac_cv_have_decl_mbsinit = yes; then
18930 REPLACE_MBSINIT=1
18931 fi
18932 else
18933 if test $REPLACE_MBSTATE_T = 1; then
18934 REPLACE_MBSINIT=1
18935 else
18936 case "$host_os" in
18937 mingw*) REPLACE_MBSINIT=1 ;;
18938 esac
18939 fi
18940 fi
18941
18942 if test $HAVE_MBSINIT = 0 || test $REPLACE_MBSINIT = 1; then
18943
18944
18945
18946
18947
18948
18949
18950
18951 gl_LIBOBJS="$gl_LIBOBJS mbsinit.$ac_objext"
18952
18953
18954 :
18955
18956 fi
18957
18958
18959
18960
18961
18962 GNULIB_MBSINIT=1
18963
18964
18965
18966
18967
18968 $as_echo "#define GNULIB_TEST_MBSINIT 1" >>confdefs.h
18969
18970
18971
18972
18973
18974
18975
18976
18977
18978
18979
18980
18981
18982 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
18983
18984
18985
18986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
18987 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
18988 if test "${gl_cv_func_mbrtowc_incomplete_state+set}" = set; then :
18989 $as_echo_n "(cached) " >&6
18990 else
18991
18992 case "$host_os" in
18993 # Guess no on AIX and OSF/1.
18994 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
18995 # Guess yes otherwise.
18996 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
18997 esac
18998 if test $LOCALE_JA != none; then
18999 if test "$cross_compiling" = yes; then :
19000 :
19001 else
19002 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19003 /* end confdefs.h. */
19004
19005 #include <locale.h>
19006 #include <string.h>
19007 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19008 <wchar.h>.
19009 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19010 included before <wchar.h>. */
19011 #include <stddef.h>
19012 #include <stdio.h>
19013 #include <time.h>
19014 #include <wchar.h>
19015 int main ()
19016 {
19017 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
19018 {
19019 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
19020 mbstate_t state;
19021 wchar_t wc;
19022
19023 memset (&state, '\0', sizeof (mbstate_t));
19024 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
19025 if (mbsinit (&state))
19026 return 1;
19027 }
19028 return 0;
19029 }
19030 _ACEOF
19031 if ac_fn_c_try_run "$LINENO"; then :
19032 gl_cv_func_mbrtowc_incomplete_state=yes
19033 else
19034 gl_cv_func_mbrtowc_incomplete_state=no
19035 fi
19036 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19037 conftest.$ac_objext conftest.beam conftest.$ac_ext
19038 fi
19039
19040 fi
19041
19042 fi
19043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
19044 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
19045
19046
19047
19048
19049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
19050 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
19051 if test "${gl_cv_func_mbrtowc_sanitycheck+set}" = set; then :
19052 $as_echo_n "(cached) " >&6
19053 else
19054
19055 case "$host_os" in
19056 # Guess no on Solaris 8.
19057 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
19058 # Guess yes otherwise.
19059 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
19060 esac
19061 if test $LOCALE_ZH_CN != none; then
19062 if test "$cross_compiling" = yes; then :
19063 :
19064 else
19065 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19066 /* end confdefs.h. */
19067
19068 #include <locale.h>
19069 #include <stdlib.h>
19070 #include <string.h>
19071 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19072 <wchar.h>.
19073 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19074 included before <wchar.h>. */
19075 #include <stddef.h>
19076 #include <stdio.h>
19077 #include <time.h>
19078 #include <wchar.h>
19079 int main ()
19080 {
19081 /* This fails on Solaris 8:
19082 mbrtowc returns 2, and sets wc to 0x00F0.
19083 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
19084 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
19085 {
19086 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
19087 mbstate_t state;
19088 wchar_t wc;
19089
19090 memset (&state, '\0', sizeof (mbstate_t));
19091 if (mbrtowc (&wc, input + 3, 6, &state) != 4
19092 && mbtowc (&wc, input + 3, 6) == 4)
19093 return 1;
19094 }
19095 return 0;
19096 }
19097 _ACEOF
19098 if ac_fn_c_try_run "$LINENO"; then :
19099 gl_cv_func_mbrtowc_sanitycheck=yes
19100 else
19101 gl_cv_func_mbrtowc_sanitycheck=no
19102 fi
19103 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19104 conftest.$ac_objext conftest.beam conftest.$ac_ext
19105 fi
19106
19107 fi
19108
19109 fi
19110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
19111 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
19112
19113 REPLACE_MBSTATE_T=0
19114 case "$gl_cv_func_mbrtowc_incomplete_state" in
19115 *yes) ;;
19116 *) REPLACE_MBSTATE_T=1 ;;
19117 esac
19118 case "$gl_cv_func_mbrtowc_sanitycheck" in
19119 *yes) ;;
19120 *) REPLACE_MBSTATE_T=1 ;;
19121 esac
19122 else
19123 REPLACE_MBSTATE_T=1
19124 fi
19125
19126
19127
19128 if test $ac_cv_func_mbsrtowcs = no; then
19129 HAVE_MBSRTOWCS=0
19130 ac_fn_c_check_decl "$LINENO" "mbsrtowcs" "ac_cv_have_decl_mbsrtowcs" "
19131 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19132 <wchar.h>.
19133 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19134 included before <wchar.h>. */
19135 #include <stddef.h>
19136 #include <stdio.h>
19137 #include <time.h>
19138 #include <wchar.h>
19139
19140 "
19141 if test "x$ac_cv_have_decl_mbsrtowcs" = x""yes; then :
19142 ac_have_decl=1
19143 else
19144 ac_have_decl=0
19145 fi
19146
19147 cat >>confdefs.h <<_ACEOF
19148 #define HAVE_DECL_MBSRTOWCS $ac_have_decl
19149 _ACEOF
19150
19151 if test $ac_cv_have_decl_mbsrtowcs = yes; then
19152 REPLACE_MBSRTOWCS=1
19153 fi
19154 else
19155 if test $REPLACE_MBSTATE_T = 1; then
19156 REPLACE_MBSRTOWCS=1
19157 else
19158
19159
19160
19161
19162
19163
19164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbsrtowcs works" >&5
19165 $as_echo_n "checking whether mbsrtowcs works... " >&6; }
19166 if test "${gl_cv_func_mbsrtowcs_works+set}" = set; then :
19167 $as_echo_n "(cached) " >&6
19168 else
19169
19170 case "$host_os" in
19171 # Guess no on HP-UX, Solaris, mingw.
19172 hpux* | solaris* | mingw*) gl_cv_func_mbsrtowcs_works="guessing no" ;;
19173 # Guess yes otherwise.
19174 *) gl_cv_func_mbsrtowcs_works="guessing yes" ;;
19175 esac
19176 if test $LOCALE_FR != none || test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none || test $LOCALE_ZH_CN != none; then
19177 if test "$cross_compiling" = yes; then :
19178 :
19179 else
19180 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19181 /* end confdefs.h. */
19182
19183 #include <locale.h>
19184 #include <string.h>
19185 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19186 <wchar.h>.
19187 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19188 included before <wchar.h>. */
19189 #include <stddef.h>
19190 #include <stdio.h>
19191 #include <time.h>
19192 #include <wchar.h>
19193 int main ()
19194 {
19195 int result = 0;
19196 /* Test whether the function supports a NULL destination argument.
19197 This fails on native Windows. */
19198 if (setlocale (LC_ALL, "$LOCALE_FR") != NULL)
19199 {
19200 const char input[] = "\337er";
19201 const char *src = input;
19202 mbstate_t state;
19203
19204 memset (&state, '\0', sizeof (mbstate_t));
19205 if (mbsrtowcs (NULL, &src, 1, &state) != 3
19206 || src != input)
19207 result |= 1;
19208 }
19209 /* Test whether the function works when started with a conversion state
19210 in non-initial state. This fails on HP-UX 11.11 and Solaris 10. */
19211 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
19212 {
19213 const char input[] = "B\303\274\303\237er";
19214 mbstate_t state;
19215
19216 memset (&state, '\0', sizeof (mbstate_t));
19217 if (mbrtowc (NULL, input + 1, 1, &state) == (size_t)(-2))
19218 if (!mbsinit (&state))
19219 {
19220 const char *src = input + 2;
19221 if (mbsrtowcs (NULL, &src, 10, &state) != 4)
19222 result |= 2;
19223 }
19224 }
19225 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
19226 {
19227 const char input[] = "<\306\374\313\334\270\354>";
19228 mbstate_t state;
19229
19230 memset (&state, '\0', sizeof (mbstate_t));
19231 if (mbrtowc (NULL, input + 3, 1, &state) == (size_t)(-2))
19232 if (!mbsinit (&state))
19233 {
19234 const char *src = input + 4;
19235 if (mbsrtowcs (NULL, &src, 10, &state) != 3)
19236 result |= 4;
19237 }
19238 }
19239 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
19240 {
19241 const char input[] = "B\250\271\201\060\211\070er";
19242 mbstate_t state;
19243
19244 memset (&state, '\0', sizeof (mbstate_t));
19245 if (mbrtowc (NULL, input + 1, 1, &state) == (size_t)(-2))
19246 if (!mbsinit (&state))
19247 {
19248 const char *src = input + 2;
19249 if (mbsrtowcs (NULL, &src, 10, &state) != 4)
19250 result |= 8;
19251 }
19252 }
19253 return result;
19254 }
19255 _ACEOF
19256 if ac_fn_c_try_run "$LINENO"; then :
19257 gl_cv_func_mbsrtowcs_works=yes
19258 else
19259 gl_cv_func_mbsrtowcs_works=no
19260 fi
19261 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19262 conftest.$ac_objext conftest.beam conftest.$ac_ext
19263 fi
19264
19265 fi
19266
19267 fi
19268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbsrtowcs_works" >&5
19269 $as_echo "$gl_cv_func_mbsrtowcs_works" >&6; }
19270
19271 case "$gl_cv_func_mbsrtowcs_works" in
19272 *yes) ;;
19273 *) REPLACE_MBSRTOWCS=1 ;;
19274 esac
19275 fi
19276 fi
19277
19278 if test $HAVE_MBSRTOWCS = 0 || test $REPLACE_MBSRTOWCS = 1; then
19279
19280
19281
19282
19283
19284
19285
19286
19287 gl_LIBOBJS="$gl_LIBOBJS mbsrtowcs.$ac_objext"
19288
19289
19290
19291
19292
19293
19294
19295
19296
19297 gl_LIBOBJS="$gl_LIBOBJS mbsrtowcs-state.$ac_objext"
19298
19299
19300 :
19301
19302 fi
19303
19304
19305
19306
19307
19308 GNULIB_MBSRTOWCS=1
19309
19310
19311
19312
19313
19314 $as_echo "#define GNULIB_TEST_MBSRTOWCS 1" >>confdefs.h
19315
19316
19317
19318
19319 if test $HAVE_MEMCHR = 0 || test $REPLACE_MEMCHR = 1; then
19320
19321
19322
19323
19324
19325
19326
19327
19328 gl_LIBOBJS="$gl_LIBOBJS memchr.$ac_objext"
19329
19330
19331 for ac_header in bp-sym.h
19332 do :
19333 ac_fn_c_check_header_mongrel "$LINENO" "bp-sym.h" "ac_cv_header_bp_sym_h" "$ac_includes_default"
19334 if test "x$ac_cv_header_bp_sym_h" = x""yes; then :
19335 cat >>confdefs.h <<_ACEOF
19336 #define HAVE_BP_SYM_H 1
19337 _ACEOF
19338
19339 fi
19340
19341 done
19342
19343
19344 fi
19345
19346
19347
19348
19349
19350 GNULIB_MEMCHR=1
19351
19352
19353
19354
19355
19356 $as_echo "#define GNULIB_TEST_MEMCHR 1" >>confdefs.h
19357
19358
19359
19360
19361
19362 if test $HAVE_DECL_MEMMEM = 1 && test $REPLACE_MEMMEM = 0; then
19363 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memmem works in linear time" >&5
19364 $as_echo_n "checking whether memmem works in linear time... " >&6; }
19365 if test "${gl_cv_func_memmem_works_fast+set}" = set; then :
19366 $as_echo_n "(cached) " >&6
19367 else
19368 if test "$cross_compiling" = yes; then :
19369 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19370 /* end confdefs.h. */
19371
19372 #include <features.h>
19373 #ifdef __GNU_LIBRARY__
19374 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 9) || (__GLIBC__ > 2)) \
19375 && !defined __UCLIBC__
19376 Lucky user
19377 #endif
19378 #endif
19379 #ifdef __CYGWIN__
19380 #include <cygwin/version.h>
19381 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 0)
19382 Lucky user
19383 #endif
19384 #endif
19385
19386 _ACEOF
19387 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19388 $EGREP "Lucky user" >/dev/null 2>&1; then :
19389 gl_cv_func_memmem_works_fast="guessing yes"
19390 else
19391 gl_cv_func_memmem_works_fast="guessing no"
19392 fi
19393 rm -f conftest*
19394
19395
19396 else
19397 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19398 /* end confdefs.h. */
19399
19400 #include <signal.h> /* for signal */
19401 #include <string.h> /* for memmem */
19402 #include <stdlib.h> /* for malloc */
19403 #include <unistd.h> /* for alarm */
19404 static void quit (int sig) { _exit (sig + 128); }
19405
19406 int
19407 main ()
19408 {
19409
19410 int result = 0;
19411 size_t m = 1000000;
19412 char *haystack = (char *) malloc (2 * m + 1);
19413 char *needle = (char *) malloc (m + 1);
19414 /* Failure to compile this test due to missing alarm is okay,
19415 since all such platforms (mingw) also lack memmem. */
19416 signal (SIGALRM, quit);
19417 alarm (5);
19418 /* Check for quadratic performance. */
19419 if (haystack && needle)
19420 {
19421 memset (haystack, 'A', 2 * m);
19422 haystack[2 * m] = 'B';
19423 memset (needle, 'A', m);
19424 needle[m] = 'B';
19425 if (!memmem (haystack, 2 * m + 1, needle, m + 1))
19426 result |= 1;
19427 }
19428 return result;
19429
19430 ;
19431 return 0;
19432 }
19433 _ACEOF
19434 if ac_fn_c_try_run "$LINENO"; then :
19435 gl_cv_func_memmem_works_fast=yes
19436 else
19437 gl_cv_func_memmem_works_fast=no
19438 fi
19439 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19440 conftest.$ac_objext conftest.beam conftest.$ac_ext
19441 fi
19442
19443
19444 fi
19445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memmem_works_fast" >&5
19446 $as_echo "$gl_cv_func_memmem_works_fast" >&6; }
19447 case "$gl_cv_func_memmem_works_fast" in
19448 *yes) ;;
19449 *)
19450 REPLACE_MEMMEM=1
19451 ;;
19452 esac
19453 fi
19454
19455 if test $HAVE_MEMMEM = 0 || test $REPLACE_MEMMEM = 1; then
19456
19457
19458
19459
19460
19461
19462
19463
19464 gl_LIBOBJS="$gl_LIBOBJS memmem.$ac_objext"
19465
19466 fi
19467
19468
19469
19470
19471 for ac_func in memmem
19472 do :
19473 ac_fn_c_check_func "$LINENO" "memmem" "ac_cv_func_memmem"
19474 if test "x$ac_cv_func_memmem" = x""yes; then :
19475 cat >>confdefs.h <<_ACEOF
19476 #define HAVE_MEMMEM 1
19477 _ACEOF
19478
19479 fi
19480 done
19481
19482 if test $ac_cv_func_memmem = yes; then
19483 HAVE_MEMMEM=1
19484 else
19485 HAVE_MEMMEM=0
19486 fi
19487
19488 if test $ac_cv_have_decl_memmem = no; then
19489 HAVE_DECL_MEMMEM=0
19490 else
19491 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memmem works" >&5
19492 $as_echo_n "checking whether memmem works... " >&6; }
19493 if test "${gl_cv_func_memmem_works_always+set}" = set; then :
19494 $as_echo_n "(cached) " >&6
19495 else
19496 if test "$cross_compiling" = yes; then :
19497 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19498 /* end confdefs.h. */
19499
19500 #ifdef __GNU_LIBRARY__
19501 #include <features.h>
19502 #if ((__GLIBC__ == 2 && ((__GLIBC_MINOR > 0 && __GLIBC_MINOR__ < 9) \
19503 || __GLIBC_MINOR__ > 12)) \
19504 || (__GLIBC__ > 2)) \
19505 || defined __UCLIBC__
19506 Lucky user
19507 #endif
19508 #elif defined __CYGWIN__
19509 #include <cygwin/version.h>
19510 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
19511 Lucky user
19512 #endif
19513 #else
19514 Lucky user
19515 #endif
19516
19517 _ACEOF
19518 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19519 $EGREP "Lucky user" >/dev/null 2>&1; then :
19520 gl_cv_func_memmem_works_always="guessing yes"
19521 else
19522 gl_cv_func_memmem_works_always="guessing no"
19523 fi
19524 rm -f conftest*
19525
19526
19527 else
19528 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19529 /* end confdefs.h. */
19530
19531 #include <string.h> /* for memmem */
19532 #define P "_EF_BF_BD"
19533 #define HAYSTACK "F_BD_CE_BD" P P P P "_C3_88_20" P P P "_C3_A7_20" P
19534 #define NEEDLE P P P P P
19535
19536 int
19537 main ()
19538 {
19539
19540 int result = 0;
19541 if (memmem (HAYSTACK, strlen (HAYSTACK), NEEDLE, strlen (NEEDLE)))
19542 result |= 1;
19543 /* Check for empty needle behavior. */
19544 {
19545 const char *haystack = "AAA";
19546 if (memmem (haystack, 3, NULL, 0) != haystack)
19547 result |= 2;
19548 }
19549 return result;
19550
19551 ;
19552 return 0;
19553 }
19554 _ACEOF
19555 if ac_fn_c_try_run "$LINENO"; then :
19556 gl_cv_func_memmem_works_always=yes
19557 else
19558 gl_cv_func_memmem_works_always=no
19559 fi
19560 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19561 conftest.$ac_objext conftest.beam conftest.$ac_ext
19562 fi
19563
19564
19565 fi
19566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memmem_works_always" >&5
19567 $as_echo "$gl_cv_func_memmem_works_always" >&6; }
19568 case "$gl_cv_func_memmem_works_always" in
19569 *yes) ;;
19570 *)
19571 REPLACE_MEMMEM=1
19572 ;;
19573 esac
19574 fi
19575 :
19576
19577 if test $HAVE_MEMMEM = 0 || test $REPLACE_MEMMEM = 1; then
19578
19579
19580
19581
19582
19583
19584
19585
19586 gl_LIBOBJS="$gl_LIBOBJS memmem.$ac_objext"
19587
19588 fi
19589
19590
19591
19592
19593
19594 GNULIB_MEMMEM=1
19595
19596
19597
19598
19599
19600 $as_echo "#define GNULIB_TEST_MEMMEM 1" >>confdefs.h
19601
19602
19603
19604
19605
19606
19607
19608
19609
19610 for ac_func in mempcpy
19611 do :
19612 ac_fn_c_check_func "$LINENO" "mempcpy" "ac_cv_func_mempcpy"
19613 if test "x$ac_cv_func_mempcpy" = x""yes; then :
19614 cat >>confdefs.h <<_ACEOF
19615 #define HAVE_MEMPCPY 1
19616 _ACEOF
19617
19618 fi
19619 done
19620
19621 if test $ac_cv_func_mempcpy = no; then
19622 HAVE_MEMPCPY=0
19623 fi
19624
19625 if test $HAVE_MEMPCPY = 0; then
19626
19627
19628
19629
19630
19631
19632
19633
19634 gl_LIBOBJS="$gl_LIBOBJS mempcpy.$ac_objext"
19635
19636
19637 :
19638
19639 fi
19640
19641
19642
19643
19644
19645 GNULIB_MEMPCPY=1
19646
19647
19648
19649
19650
19651 $as_echo "#define GNULIB_TEST_MEMPCPY 1" >>confdefs.h
19652
19653
19654
19655
19656
19657
19658
19659
19660 if test $ac_cv_have_decl_memrchr = no; then
19661 HAVE_DECL_MEMRCHR=0
19662 fi
19663
19664 for ac_func in memrchr
19665 do :
19666 ac_fn_c_check_func "$LINENO" "memrchr" "ac_cv_func_memrchr"
19667 if test "x$ac_cv_func_memrchr" = x""yes; then :
19668 cat >>confdefs.h <<_ACEOF
19669 #define HAVE_MEMRCHR 1
19670 _ACEOF
19671
19672 fi
19673 done
19674
19675
19676 if test $ac_cv_func_memrchr = no; then
19677
19678
19679
19680
19681
19682
19683
19684
19685 gl_LIBOBJS="$gl_LIBOBJS memrchr.$ac_objext"
19686
19687 :
19688 fi
19689
19690
19691
19692
19693
19694 GNULIB_MEMRCHR=1
19695
19696
19697
19698
19699
19700 $as_echo "#define GNULIB_TEST_MEMRCHR 1" >>confdefs.h
19701
19702
19703
19704
19705
19706
19707
19708 if test $ac_cv_func_mkstemp = yes; then
19709 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mkstemp" >&5
19710 $as_echo_n "checking for working mkstemp... " >&6; }
19711 if test "${gl_cv_func_working_mkstemp+set}" = set; then :
19712 $as_echo_n "(cached) " >&6
19713 else
19714
19715 mkdir conftest.mkstemp
19716 if test "$cross_compiling" = yes; then :
19717 case "$host_os" in
19718 # Guess yes on glibc systems.
19719 *-gnu*) gl_cv_func_working_mkstemp="guessing yes" ;;
19720 # If we don't know, assume the worst.
19721 *) gl_cv_func_working_mkstemp="guessing no" ;;
19722 esac
19723
19724 else
19725 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19726 /* end confdefs.h. */
19727 $ac_includes_default
19728 int
19729 main ()
19730 {
19731 int result = 0;
19732 int i;
19733 off_t large = (off_t) 4294967295u;
19734 if (large < 0)
19735 large = 2147483647;
19736 umask (0);
19737 for (i = 0; i < 70; i++)
19738 {
19739 char templ[] = "conftest.mkstemp/coXXXXXX";
19740 int (*mkstemp_function) (char *) = mkstemp;
19741 int fd = mkstemp_function (templ);
19742 if (fd < 0)
19743 result |= 1;
19744 else
19745 {
19746 struct stat st;
19747 if (lseek (fd, large, SEEK_SET) != large)
19748 result |= 2;
19749 if (fstat (fd, &st) < 0)
19750 result |= 4;
19751 else if (st.st_mode & 0077)
19752 result |= 8;
19753 if (close (fd))
19754 result |= 16;
19755 }
19756 }
19757 return result;
19758 ;
19759 return 0;
19760 }
19761 _ACEOF
19762 if ac_fn_c_try_run "$LINENO"; then :
19763 gl_cv_func_working_mkstemp=yes
19764 else
19765 gl_cv_func_working_mkstemp=no
19766 fi
19767 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19768 conftest.$ac_objext conftest.beam conftest.$ac_ext
19769 fi
19770
19771 rm -rf conftest.mkstemp
19772
19773 fi
19774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mkstemp" >&5
19775 $as_echo "$gl_cv_func_working_mkstemp" >&6; }
19776 case "$gl_cv_func_working_mkstemp" in
19777 *yes) ;;
19778 *)
19779 REPLACE_MKSTEMP=1
19780 ;;
19781 esac
19782 else
19783 HAVE_MKSTEMP=0
19784 fi
19785
19786 if test $HAVE_MKSTEMP = 0 || test $REPLACE_MKSTEMP = 1; then
19787
19788
19789
19790
19791
19792
19793
19794
19795 gl_LIBOBJS="$gl_LIBOBJS mkstemp.$ac_objext"
19796
19797
19798
19799 fi
19800
19801
19802
19803
19804
19805 GNULIB_MKSTEMP=1
19806
19807
19808
19809
19810
19811 $as_echo "#define GNULIB_TEST_MKSTEMP 1" >>confdefs.h
19812
19813
19814
19815
19816 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
19817
19818
19819
19820
19821
19822
19823
19824
19825 gl_LIBOBJS="$gl_LIBOBJS msvc-inval.$ac_objext"
19826
19827 fi
19828
19829 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
19830
19831
19832
19833
19834
19835
19836
19837
19838 gl_LIBOBJS="$gl_LIBOBJS msvc-nothrow.$ac_objext"
19839
19840 fi
19841
19842
19843
19844 case "$host_os" in
19845 mingw* | pw*)
19846 REPLACE_OPEN=1
19847 ;;
19848 *)
19849
19850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether open recognizes a trailing slash" >&5
19851 $as_echo_n "checking whether open recognizes a trailing slash... " >&6; }
19852 if test "${gl_cv_func_open_slash+set}" = set; then :
19853 $as_echo_n "(cached) " >&6
19854 else
19855 # Assume that if we have lstat, we can also check symlinks.
19856 if test $ac_cv_func_lstat = yes; then
19857 touch conftest.tmp
19858 ln -s conftest.tmp conftest.lnk
19859 fi
19860 if test "$cross_compiling" = yes; then :
19861
19862 case "$host_os" in
19863 freebsd* | aix* | hpux* | solaris2.[0-9] | solaris2.[0-9].*)
19864 gl_cv_func_open_slash="guessing no" ;;
19865 *)
19866 gl_cv_func_open_slash="guessing yes" ;;
19867 esac
19868
19869 else
19870 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19871 /* end confdefs.h. */
19872
19873 #include <fcntl.h>
19874 #if HAVE_UNISTD_H
19875 # include <unistd.h>
19876 #endif
19877 int main ()
19878 {
19879 int result = 0;
19880 #if HAVE_LSTAT
19881 if (open ("conftest.lnk/", O_RDONLY) != -1)
19882 result |= 1;
19883 #endif
19884 if (open ("conftest.sl/", O_CREAT, 0600) >= 0)
19885 result |= 2;
19886 return result;
19887 }
19888 _ACEOF
19889 if ac_fn_c_try_run "$LINENO"; then :
19890 gl_cv_func_open_slash=yes
19891 else
19892 gl_cv_func_open_slash=no
19893 fi
19894 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19895 conftest.$ac_objext conftest.beam conftest.$ac_ext
19896 fi
19897
19898 rm -f conftest.sl conftest.tmp conftest.lnk
19899
19900 fi
19901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_open_slash" >&5
19902 $as_echo "$gl_cv_func_open_slash" >&6; }
19903 case "$gl_cv_func_open_slash" in
19904 *no)
19905
19906 $as_echo "#define OPEN_TRAILING_SLASH_BUG 1" >>confdefs.h
19907
19908 REPLACE_OPEN=1
19909 ;;
19910 esac
19911 ;;
19912 esac
19913
19914 if test $REPLACE_OPEN = 0; then
19915
19916
19917
19918 if test $ac_cv_func_fchdir = no; then
19919 HAVE_FCHDIR=0
19920 fi
19921
19922 if test $HAVE_FCHDIR = 0; then
19923 REPLACE_OPEN=1
19924 fi
19925 fi
19926
19927
19928
19929 if test $REPLACE_OPEN = 1; then
19930
19931
19932
19933
19934
19935
19936
19937
19938 gl_LIBOBJS="$gl_LIBOBJS open.$ac_objext"
19939
19940
19941
19942 :
19943
19944 fi
19945
19946
19947
19948
19949
19950 GNULIB_OPEN=1
19951
19952
19953
19954
19955
19956 $as_echo "#define GNULIB_TEST_OPEN 1" >>confdefs.h
19957
19958
19959
19960
19961
19962
19963
19964
19965 case $ac_cv_func_openat+$gl_cv_func_lstat_dereferences_slashed_symlink in
19966 yes+*yes)
19967 ;;
19968 yes+*)
19969 # Solaris 9 has *at functions, but uniformly mishandles trailing
19970 # slash in all of them.
19971 REPLACE_OPENAT=1
19972 ;;
19973 *)
19974 HAVE_OPENAT=0
19975 ;;
19976 esac
19977
19978 if test $HAVE_OPENAT = 0 || test $REPLACE_OPENAT = 1; then
19979
19980
19981
19982
19983
19984
19985
19986
19987 gl_LIBOBJS="$gl_LIBOBJS openat.$ac_objext"
19988
19989
19990
19991 :
19992
19993 fi
19994
19995
19996 cat >>confdefs.h <<_ACEOF
19997 #define GNULIB_OPENAT 1
19998 _ACEOF
19999
20000
20001
20002
20003
20004
20005 GNULIB_OPENAT=1
20006
20007
20008
20009
20010
20011 $as_echo "#define GNULIB_TEST_OPENAT 1" >>confdefs.h
20012
20013
20014
20015
20016
20017
20018 for ac_func in opendir
20019 do :
20020 ac_fn_c_check_func "$LINENO" "opendir" "ac_cv_func_opendir"
20021 if test "x$ac_cv_func_opendir" = x""yes; then :
20022 cat >>confdefs.h <<_ACEOF
20023 #define HAVE_OPENDIR 1
20024 _ACEOF
20025
20026 fi
20027 done
20028
20029 if test $ac_cv_func_opendir = no; then
20030 HAVE_OPENDIR=0
20031 fi
20032
20033
20034
20035
20036 if test $ac_cv_func_fchdir = no; then
20037 HAVE_FCHDIR=0
20038 fi
20039
20040 if test $HAVE_FCHDIR = 0; then
20041 if test $HAVE_OPENDIR = 1; then
20042 REPLACE_OPENDIR=1
20043 fi
20044 fi
20045
20046 case $host_os,$HAVE_OPENDIR in
20047 os2*,1)
20048 REPLACE_OPENDIR=1;;
20049 esac
20050
20051 if test $HAVE_OPENDIR = 0 || test $REPLACE_OPENDIR = 1; then
20052
20053
20054
20055
20056
20057
20058
20059
20060 gl_LIBOBJS="$gl_LIBOBJS opendir.$ac_objext"
20061
20062 fi
20063
20064
20065
20066
20067
20068 GNULIB_OPENDIR=1
20069
20070
20071
20072
20073
20074 $as_echo "#define GNULIB_TEST_OPENDIR 1" >>confdefs.h
20075
20076
20077
20078
20079
20080
20081
20082
20083
20084
20085 for ac_func in rawmemchr
20086 do :
20087 ac_fn_c_check_func "$LINENO" "rawmemchr" "ac_cv_func_rawmemchr"
20088 if test "x$ac_cv_func_rawmemchr" = x""yes; then :
20089 cat >>confdefs.h <<_ACEOF
20090 #define HAVE_RAWMEMCHR 1
20091 _ACEOF
20092
20093 fi
20094 done
20095
20096 if test $ac_cv_func_rawmemchr = no; then
20097 HAVE_RAWMEMCHR=0
20098 fi
20099
20100 if test $HAVE_RAWMEMCHR = 0; then
20101
20102
20103
20104
20105
20106
20107
20108
20109 gl_LIBOBJS="$gl_LIBOBJS rawmemchr.$ac_objext"
20110
20111 :
20112 fi
20113
20114
20115
20116
20117
20118 GNULIB_RAWMEMCHR=1
20119
20120
20121
20122
20123
20124 $as_echo "#define GNULIB_TEST_RAWMEMCHR 1" >>confdefs.h
20125
20126
20127
20128
20129
20130
20131 for ac_func in readdir
20132 do :
20133 ac_fn_c_check_func "$LINENO" "readdir" "ac_cv_func_readdir"
20134 if test "x$ac_cv_func_readdir" = x""yes; then :
20135 cat >>confdefs.h <<_ACEOF
20136 #define HAVE_READDIR 1
20137 _ACEOF
20138
20139 fi
20140 done
20141
20142 if test $ac_cv_func_readdir = no; then
20143 HAVE_READDIR=0
20144 fi
20145
20146 if test $HAVE_READDIR = 0; then
20147
20148
20149
20150
20151
20152
20153
20154
20155 gl_LIBOBJS="$gl_LIBOBJS readdir.$ac_objext"
20156
20157 fi
20158
20159
20160
20161
20162
20163 GNULIB_READDIR=1
20164
20165
20166
20167
20168
20169 $as_echo "#define GNULIB_TEST_READDIR 1" >>confdefs.h
20170
20171
20172
20173
20174
20175
20176 if test $ac_cv_func_readlink = no; then
20177 HAVE_READLINK=0
20178 else
20179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
20180 $as_echo_n "checking whether readlink signature is correct... " >&6; }
20181 if test "${gl_cv_decl_readlink_works+set}" = set; then :
20182 $as_echo_n "(cached) " >&6
20183 else
20184 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20185 /* end confdefs.h. */
20186 #include <unistd.h>
20187 /* Cause compilation failure if original declaration has wrong type. */
20188 ssize_t readlink (const char *, char *, size_t);
20189 int
20190 main ()
20191 {
20192
20193 ;
20194 return 0;
20195 }
20196 _ACEOF
20197 if ac_fn_c_try_compile "$LINENO"; then :
20198 gl_cv_decl_readlink_works=yes
20199 else
20200 gl_cv_decl_readlink_works=no
20201 fi
20202 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20203 fi
20204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
20205 $as_echo "$gl_cv_decl_readlink_works" >&6; }
20206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
20207 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
20208 if test "${gl_cv_func_readlink_works+set}" = set; then :
20209 $as_echo_n "(cached) " >&6
20210 else
20211 # We have readlink, so assume ln -s works.
20212 ln -s conftest.no-such conftest.link
20213 ln -s conftest.link conftest.lnk2
20214 if test "$cross_compiling" = yes; then :
20215 case "$host_os" in
20216 # Guess yes on glibc systems.
20217 *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
20218 # If we don't know, assume the worst.
20219 *) gl_cv_func_readlink_works="guessing no" ;;
20220 esac
20221
20222 else
20223 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20224 /* end confdefs.h. */
20225 #include <unistd.h>
20226
20227 int
20228 main ()
20229 {
20230 char buf[20];
20231 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
20232 ;
20233 return 0;
20234 }
20235 _ACEOF
20236 if ac_fn_c_try_run "$LINENO"; then :
20237 gl_cv_func_readlink_works=yes
20238 else
20239 gl_cv_func_readlink_works=no
20240 fi
20241 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20242 conftest.$ac_objext conftest.beam conftest.$ac_ext
20243 fi
20244
20245 rm -f conftest.link conftest.lnk2
20246 fi
20247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
20248 $as_echo "$gl_cv_func_readlink_works" >&6; }
20249 case "$gl_cv_func_readlink_works" in
20250 *yes)
20251 if test "$gl_cv_decl_readlink_works" != yes; then
20252 REPLACE_READLINK=1
20253 fi
20254 ;;
20255 *)
20256
20257 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
20258
20259 REPLACE_READLINK=1
20260 ;;
20261 esac
20262 fi
20263
20264 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
20265
20266
20267
20268
20269
20270
20271
20272
20273 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
20274
20275
20276 :
20277
20278 fi
20279
20280
20281
20282
20283
20284 GNULIB_READLINK=1
20285
20286
20287
20288
20289
20290 $as_echo "#define GNULIB_TEST_READLINK 1" >>confdefs.h
20291
20292
20293
20294
20295
20296
20297 if test $gl_cv_func_malloc_posix = yes; then
20298
20299 $as_echo "#define HAVE_REALLOC_POSIX 1" >>confdefs.h
20300
20301 else
20302 REPLACE_REALLOC=1
20303 fi
20304
20305 if test $REPLACE_REALLOC = 1; then
20306
20307
20308
20309
20310
20311
20312
20313
20314 gl_LIBOBJS="$gl_LIBOBJS realloc.$ac_objext"
20315
20316 fi
20317
20318
20319
20320
20321
20322 GNULIB_REALLOC_POSIX=1
20323
20324
20325
20326
20327
20328 $as_echo "#define GNULIB_TEST_REALLOC_POSIX 1" >>confdefs.h
20329
20330
20331
20332
20333
20334
20335
20336
20337 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename honors trailing slash on destination" >&5
20338 $as_echo_n "checking whether rename honors trailing slash on destination... " >&6; }
20339 if test "${gl_cv_func_rename_slash_dst_works+set}" = set; then :
20340 $as_echo_n "(cached) " >&6
20341 else
20342 rm -rf conftest.f conftest.f1 conftest.f2 conftest.d1 conftest.d2 conftest.lnk
20343 touch conftest.f && touch conftest.f1 && mkdir conftest.d1 ||
20344 as_fn_error "cannot create temporary files" "$LINENO" 5
20345 # Assume that if we have lstat, we can also check symlinks.
20346 if test $ac_cv_func_lstat = yes; then
20347 ln -s conftest.f conftest.lnk
20348 fi
20349 if test "$cross_compiling" = yes; then :
20350 case "$host_os" in
20351 # Guess yes on glibc systems.
20352 *-gnu*) gl_cv_func_rename_slash_dst_works="guessing yes" ;;
20353 # If we don't know, assume the worst.
20354 *) gl_cv_func_rename_slash_dst_works="guessing no" ;;
20355 esac
20356
20357 else
20358 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20359 /* end confdefs.h. */
20360
20361 # include <stdio.h>
20362 # include <stdlib.h>
20363
20364 int
20365 main ()
20366 {
20367 int result = 0;
20368 if (rename ("conftest.f1", "conftest.f2/") == 0)
20369 result |= 1;
20370 if (rename ("conftest.d1", "conftest.d2/") != 0)
20371 result |= 2;
20372 #if HAVE_LSTAT
20373 if (rename ("conftest.f", "conftest.lnk/") == 0)
20374 result |= 4;
20375 #endif
20376 return result;
20377
20378 ;
20379 return 0;
20380 }
20381 _ACEOF
20382 if ac_fn_c_try_run "$LINENO"; then :
20383 gl_cv_func_rename_slash_dst_works=yes
20384 else
20385 gl_cv_func_rename_slash_dst_works=no
20386 fi
20387 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20388 conftest.$ac_objext conftest.beam conftest.$ac_ext
20389 fi
20390
20391 rm -rf conftest.f conftest.f1 conftest.f2 conftest.d1 conftest.d2 conftest.lnk
20392
20393 fi
20394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_slash_dst_works" >&5
20395 $as_echo "$gl_cv_func_rename_slash_dst_works" >&6; }
20396 case "$gl_cv_func_rename_slash_dst_works" in
20397 *yes) ;;
20398 *)
20399 REPLACE_RENAME=1
20400
20401 $as_echo "#define RENAME_TRAILING_SLASH_DEST_BUG 1" >>confdefs.h
20402
20403 ;;
20404 esac
20405
20406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename honors trailing slash on source" >&5
20407 $as_echo_n "checking whether rename honors trailing slash on source... " >&6; }
20408 if test "${gl_cv_func_rename_slash_src_works+set}" = set; then :
20409 $as_echo_n "(cached) " >&6
20410 else
20411 rm -rf conftest.f conftest.f1 conftest.d1 conftest.d2 conftest.d3 conftest.lnk
20412 touch conftest.f && touch conftest.f1 && mkdir conftest.d1 ||
20413 as_fn_error "cannot create temporary files" "$LINENO" 5
20414 # Assume that if we have lstat, we can also check symlinks.
20415 if test $ac_cv_func_lstat = yes; then
20416 ln -s conftest.f conftest.lnk
20417 fi
20418 if test "$cross_compiling" = yes; then :
20419 case "$host_os" in
20420 # Guess yes on glibc systems.
20421 *-gnu*) gl_cv_func_rename_slash_src_works="guessing yes" ;;
20422 # If we don't know, assume the worst.
20423 *) gl_cv_func_rename_slash_src_works="guessing no" ;;
20424 esac
20425
20426 else
20427 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20428 /* end confdefs.h. */
20429
20430 # include <stdio.h>
20431 # include <stdlib.h>
20432
20433 int
20434 main ()
20435 {
20436 int result = 0;
20437 if (rename ("conftest.f1/", "conftest.d3") == 0)
20438 result |= 1;
20439 if (rename ("conftest.d1/", "conftest.d2") != 0)
20440 result |= 2;
20441 #if HAVE_LSTAT
20442 if (rename ("conftest.lnk/", "conftest.f") == 0)
20443 result |= 4;
20444 #endif
20445 return result;
20446
20447 ;
20448 return 0;
20449 }
20450 _ACEOF
20451 if ac_fn_c_try_run "$LINENO"; then :
20452 gl_cv_func_rename_slash_src_works=yes
20453 else
20454 gl_cv_func_rename_slash_src_works=no
20455 fi
20456 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20457 conftest.$ac_objext conftest.beam conftest.$ac_ext
20458 fi
20459
20460 rm -rf conftest.f conftest.f1 conftest.d1 conftest.d2 conftest.d3 conftest.lnk
20461
20462 fi
20463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_slash_src_works" >&5
20464 $as_echo "$gl_cv_func_rename_slash_src_works" >&6; }
20465 case "$gl_cv_func_rename_slash_src_works" in
20466 *yes) ;;
20467 *)
20468 REPLACE_RENAME=1
20469
20470 $as_echo "#define RENAME_TRAILING_SLASH_SOURCE_BUG 1" >>confdefs.h
20471
20472 ;;
20473 esac
20474
20475
20476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename manages hard links correctly" >&5
20477 $as_echo_n "checking whether rename manages hard links correctly... " >&6; }
20478 if test "${gl_cv_func_rename_link_works+set}" = set; then :
20479 $as_echo_n "(cached) " >&6
20480 else
20481 if test $ac_cv_func_link = yes; then
20482 rm -rf conftest.f conftest.f1
20483 if touch conftest.f && ln conftest.f conftest.f1 &&
20484 set x `ls -i conftest.f conftest.f1` && test "" = ""; then
20485 if test "$cross_compiling" = yes; then :
20486 case "$host_os" in
20487 # Guess yes on glibc systems.
20488 *-gnu*) gl_cv_func_rename_link_works="guessing yes" ;;
20489 # If we don't know, assume the worst.
20490 *) gl_cv_func_rename_link_works="guessing no" ;;
20491 esac
20492
20493 else
20494 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20495 /* end confdefs.h. */
20496
20497 # include <stdio.h>
20498 # include <stdlib.h>
20499 # include <unistd.h>
20500
20501 int
20502 main ()
20503 {
20504 int result = 0;
20505 if (rename ("conftest.f", "conftest.f1"))
20506 result |= 1;
20507 if (unlink ("conftest.f1"))
20508 result |= 2;
20509 if (rename ("conftest.f", "conftest.f"))
20510 result |= 4;
20511 if (rename ("conftest.f1", "conftest.f1") == 0)
20512 result |= 8;
20513 return result;
20514
20515 ;
20516 return 0;
20517 }
20518 _ACEOF
20519 if ac_fn_c_try_run "$LINENO"; then :
20520 gl_cv_func_rename_link_works=yes
20521 else
20522 gl_cv_func_rename_link_works=no
20523 fi
20524 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20525 conftest.$ac_objext conftest.beam conftest.$ac_ext
20526 fi
20527
20528 else
20529 gl_cv_func_rename_link_works="guessing no"
20530 fi
20531 rm -rf conftest.f conftest.f1
20532 else
20533 gl_cv_func_rename_link_works=yes
20534 fi
20535
20536 fi
20537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_link_works" >&5
20538 $as_echo "$gl_cv_func_rename_link_works" >&6; }
20539 case "$gl_cv_func_rename_link_works" in
20540 *yes) ;;
20541 *)
20542 REPLACE_RENAME=1
20543
20544 $as_echo "#define RENAME_HARD_LINK_BUG 1" >>confdefs.h
20545
20546 ;;
20547 esac
20548
20549 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename manages existing destinations correctly" >&5
20550 $as_echo_n "checking whether rename manages existing destinations correctly... " >&6; }
20551 if test "${gl_cv_func_rename_dest_works+set}" = set; then :
20552 $as_echo_n "(cached) " >&6
20553 else
20554 rm -rf conftest.f conftest.d1 conftest.d2
20555 touch conftest.f && mkdir conftest.d1 conftest.d2 ||
20556 as_fn_error "cannot create temporary files" "$LINENO" 5
20557 if test "$cross_compiling" = yes; then :
20558 case "$host_os" in
20559 # Guess yes on glibc systems.
20560 *-gnu*) gl_cv_func_rename_dest_works="guessing yes" ;;
20561 # If we don't know, assume the worst.
20562 *) gl_cv_func_rename_dest_works="guessing no" ;;
20563 esac
20564
20565 else
20566 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20567 /* end confdefs.h. */
20568
20569 # include <stdio.h>
20570 # include <stdlib.h>
20571
20572 int
20573 main ()
20574 {
20575 int result = 0;
20576 if (rename ("conftest.d1", "conftest.d2") != 0)
20577 result |= 1;
20578 if (rename ("conftest.d2", "conftest.f") == 0)
20579 result |= 2;
20580 return result;
20581
20582 ;
20583 return 0;
20584 }
20585 _ACEOF
20586 if ac_fn_c_try_run "$LINENO"; then :
20587 gl_cv_func_rename_dest_works=yes
20588 else
20589 gl_cv_func_rename_dest_works=no
20590 fi
20591 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20592 conftest.$ac_objext conftest.beam conftest.$ac_ext
20593 fi
20594
20595 rm -rf conftest.f conftest.d1 conftest.d2
20596
20597 fi
20598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_dest_works" >&5
20599 $as_echo "$gl_cv_func_rename_dest_works" >&6; }
20600 case "$gl_cv_func_rename_dest_works" in
20601 *yes) ;;
20602 *)
20603 REPLACE_RENAME=1
20604
20605 $as_echo "#define RENAME_DEST_EXISTS_BUG 1" >>confdefs.h
20606
20607 ;;
20608 esac
20609
20610 if test $REPLACE_RENAME = 1; then
20611
20612
20613
20614
20615
20616
20617
20618
20619 gl_LIBOBJS="$gl_LIBOBJS rename.$ac_objext"
20620
20621 fi
20622
20623
20624
20625
20626
20627 GNULIB_RENAME=1
20628
20629
20630
20631
20632
20633 $as_echo "#define GNULIB_TEST_RENAME 1" >>confdefs.h
20634
20635
20636
20637
20638
20639
20640 for ac_func in rewinddir
20641 do :
20642 ac_fn_c_check_func "$LINENO" "rewinddir" "ac_cv_func_rewinddir"
20643 if test "x$ac_cv_func_rewinddir" = x""yes; then :
20644 cat >>confdefs.h <<_ACEOF
20645 #define HAVE_REWINDDIR 1
20646 _ACEOF
20647
20648 fi
20649 done
20650
20651 if test $ac_cv_func_rewinddir = no; then
20652 HAVE_REWINDDIR=0
20653 fi
20654
20655 if test $HAVE_REWINDDIR = 0; then
20656
20657
20658
20659
20660
20661
20662
20663
20664 gl_LIBOBJS="$gl_LIBOBJS rewinddir.$ac_objext"
20665
20666 fi
20667
20668
20669
20670
20671
20672 GNULIB_REWINDDIR=1
20673
20674
20675
20676
20677
20678 $as_echo "#define GNULIB_TEST_REWINDDIR 1" >>confdefs.h
20679
20680
20681
20682
20683
20684
20685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rmdir works" >&5
20686 $as_echo_n "checking whether rmdir works... " >&6; }
20687 if test "${gl_cv_func_rmdir_works+set}" = set; then :
20688 $as_echo_n "(cached) " >&6
20689 else
20690 mkdir conftest.dir
20691 touch conftest.file
20692 if test "$cross_compiling" = yes; then :
20693 case "$host_os" in
20694 # Guess yes on glibc systems.
20695 *-gnu*) gl_cv_func_rmdir_works="guessing yes" ;;
20696 # If we don't know, assume the worst.
20697 *) gl_cv_func_rmdir_works="guessing no" ;;
20698 esac
20699
20700 else
20701 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20702 /* end confdefs.h. */
20703 #include <stdio.h>
20704 #include <errno.h>
20705 #if HAVE_UNISTD_H
20706 # include <unistd.h>
20707 #else /* on Windows with MSVC */
20708 # include <direct.h>
20709 #endif
20710
20711 int
20712 main ()
20713 {
20714 int result = 0;
20715 if (!rmdir ("conftest.file/"))
20716 result |= 1;
20717 else if (errno != ENOTDIR)
20718 result |= 2;
20719 if (!rmdir ("conftest.dir/./"))
20720 result |= 4;
20721 return result;
20722
20723 ;
20724 return 0;
20725 }
20726 _ACEOF
20727 if ac_fn_c_try_run "$LINENO"; then :
20728 gl_cv_func_rmdir_works=yes
20729 else
20730 gl_cv_func_rmdir_works=no
20731 fi
20732 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20733 conftest.$ac_objext conftest.beam conftest.$ac_ext
20734 fi
20735
20736 rm -rf conftest.dir conftest.file
20737 fi
20738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rmdir_works" >&5
20739 $as_echo "$gl_cv_func_rmdir_works" >&6; }
20740 case "$gl_cv_func_rmdir_works" in
20741 *yes) ;;
20742 *)
20743 REPLACE_RMDIR=1
20744 ;;
20745 esac
20746
20747 if test $REPLACE_RMDIR = 1; then
20748
20749
20750
20751
20752
20753
20754
20755
20756 gl_LIBOBJS="$gl_LIBOBJS rmdir.$ac_objext"
20757
20758 fi
20759
20760
20761
20762
20763
20764 GNULIB_RMDIR=1
20765
20766
20767
20768
20769
20770 $as_echo "#define GNULIB_TEST_RMDIR 1" >>confdefs.h
20771
20772
20773
20774
20775
20776
20777
20778
20779
20780
20781
20782 if test $ac_cv_func_secure_getenv = no; then
20783 HAVE_SECURE_GETENV=0
20784 fi
20785
20786 if test $HAVE_SECURE_GETENV = 0; then
20787
20788
20789
20790
20791
20792
20793
20794
20795 gl_LIBOBJS="$gl_LIBOBJS secure_getenv.$ac_objext"
20796
20797
20798 for ac_func in __secure_getenv
20799 do :
20800 ac_fn_c_check_func "$LINENO" "__secure_getenv" "ac_cv_func___secure_getenv"
20801 if test "x$ac_cv_func___secure_getenv" = x""yes; then :
20802 cat >>confdefs.h <<_ACEOF
20803 #define HAVE___SECURE_GETENV 1
20804 _ACEOF
20805
20806 fi
20807 done
20808
20809 if test $ac_cv_func___secure_getenv = no; then
20810 for ac_func in issetugid
20811 do :
20812 ac_fn_c_check_func "$LINENO" "issetugid" "ac_cv_func_issetugid"
20813 if test "x$ac_cv_func_issetugid" = x""yes; then :
20814 cat >>confdefs.h <<_ACEOF
20815 #define HAVE_ISSETUGID 1
20816 _ACEOF
20817
20818 fi
20819 done
20820
20821 fi
20822
20823
20824 fi
20825
20826
20827
20828
20829
20830 GNULIB_SECURE_GETENV=1
20831
20832
20833
20834
20835
20836 $as_echo "#define GNULIB_TEST_SECURE_GETENV 1" >>confdefs.h
20837
20838
20839
20840
20841
20842 if test $ac_cv_func_setenv = no; then
20843 HAVE_SETENV=0
20844 else
20845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setenv validates arguments" >&5
20846 $as_echo_n "checking whether setenv validates arguments... " >&6; }
20847 if test "${gl_cv_func_setenv_works+set}" = set; then :
20848 $as_echo_n "(cached) " >&6
20849 else
20850 if test "$cross_compiling" = yes; then :
20851 case "$host_os" in
20852 # Guess yes on glibc systems.
20853 *-gnu*) gl_cv_func_setenv_works="guessing yes" ;;
20854 # If we don't know, assume the worst.
20855 *) gl_cv_func_setenv_works="guessing no" ;;
20856 esac
20857
20858 else
20859 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20860 /* end confdefs.h. */
20861
20862 #include <stdlib.h>
20863 #include <errno.h>
20864 #include <string.h>
20865
20866 int
20867 main ()
20868 {
20869
20870 int result = 0;
20871 {
20872 if (setenv ("", "", 0) != -1)
20873 result |= 1;
20874 else if (errno != EINVAL)
20875 result |= 2;
20876 }
20877 {
20878 if (setenv ("a", "=", 1) != 0)
20879 result |= 4;
20880 else if (strcmp (getenv ("a"), "=") != 0)
20881 result |= 8;
20882 }
20883 return result;
20884
20885 ;
20886 return 0;
20887 }
20888 _ACEOF
20889 if ac_fn_c_try_run "$LINENO"; then :
20890 gl_cv_func_setenv_works=yes
20891 else
20892 gl_cv_func_setenv_works=no
20893 fi
20894 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20895 conftest.$ac_objext conftest.beam conftest.$ac_ext
20896 fi
20897
20898 fi
20899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_setenv_works" >&5
20900 $as_echo "$gl_cv_func_setenv_works" >&6; }
20901 case "$gl_cv_func_setenv_works" in
20902 *yes) ;;
20903 *)
20904 REPLACE_SETENV=1
20905 ;;
20906 esac
20907 fi
20908
20909 if test $HAVE_SETENV = 0 || test $REPLACE_SETENV = 1; then
20910
20911
20912
20913
20914
20915
20916
20917
20918 gl_LIBOBJS="$gl_LIBOBJS setenv.$ac_objext"
20919
20920 fi
20921
20922
20923
20924
20925
20926 GNULIB_SETENV=1
20927
20928
20929
20930
20931
20932 $as_echo "#define GNULIB_TEST_SETENV 1" >>confdefs.h
20933
20934
20935
20936
20937
20938
20939
20940
20941
20942
20943
20944
20945
20946
20947 if test $gl_cv_have_include_next = yes; then
20948 gl_cv_next_signal_h='<'signal.h'>'
20949 else
20950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
20951 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
20952 if test "${gl_cv_next_signal_h+set}" = set; then :
20953 $as_echo_n "(cached) " >&6
20954 else
20955
20956
20957
20958 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20959 /* end confdefs.h. */
20960 #include <signal.h>
20961 _ACEOF
20962 case "$host_os" in
20963 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20964 *) gl_absname_cpp="$ac_cpp" ;;
20965 esac
20966
20967 case "$host_os" in
20968 mingw*)
20969 gl_dirsep_regex='[/\\]'
20970 ;;
20971 *)
20972 gl_dirsep_regex='\/'
20973 ;;
20974 esac
20975 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
20976 gl_header_literal_regex=`echo 'signal.h' \
20977 | sed -e "$gl_make_literal_regex_sed"`
20978 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
20979 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
20980 s|^/[^/]|//&|
20981 p
20982 q
20983 }'
20984
20985 gl_cv_absolute_signal_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20986 sed -n "$gl_absolute_header_sed"`
20987
20988 gl_header=$gl_cv_absolute_signal_h
20989 gl_cv_next_signal_h='"'$gl_header'"'
20990
20991
20992 fi
20993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
20994 $as_echo "$gl_cv_next_signal_h" >&6; }
20995 fi
20996 NEXT_SIGNAL_H=$gl_cv_next_signal_h
20997
20998 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20999 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21000 gl_next_as_first_directive='<'signal.h'>'
21001 else
21002 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21003 gl_next_as_first_directive=$gl_cv_next_signal_h
21004 fi
21005 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
21006
21007
21008
21009
21010
21011 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
21012 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
21013 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
21014 #include <signal.h>
21015
21016 "
21017 if test "x$ac_cv_type_volatile_sig_atomic_t" = x""yes; then :
21018
21019 else
21020 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
21021 fi
21022
21023
21024
21025
21026
21027
21028
21029 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
21030 #include <signal.h>
21031
21032 "
21033 if test "x$ac_cv_type_sighandler_t" = x""yes; then :
21034
21035 else
21036 HAVE_SIGHANDLER_T=0
21037 fi
21038
21039
21040
21041 for gl_func in pthread_sigmask sigaction sigaddset sigdelset sigemptyset sigfillset sigismember sigpending sigprocmask; do
21042 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
21043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
21044 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
21045 if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
21046 $as_echo_n "(cached) " >&6
21047 else
21048 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21049 /* end confdefs.h. */
21050 #include <signal.h>
21051
21052 int
21053 main ()
21054 {
21055 #undef $gl_func
21056 (void) $gl_func;
21057 ;
21058 return 0;
21059 }
21060 _ACEOF
21061 if ac_fn_c_try_compile "$LINENO"; then :
21062 eval "$as_gl_Symbol=yes"
21063 else
21064 eval "$as_gl_Symbol=no"
21065 fi
21066 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21067 fi
21068 eval ac_res=\$$as_gl_Symbol
21069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
21070 $as_echo "$ac_res" >&6; }
21071 eval as_val=\$$as_gl_Symbol
21072 if test "x$as_val" = x""yes; then :
21073 cat >>confdefs.h <<_ACEOF
21074 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
21075 _ACEOF
21076
21077 eval ac_cv_have_decl_$gl_func=yes
21078 fi
21079 done
21080
21081
21082
21083 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
21084 $as_echo_n "checking for ssize_t... " >&6; }
21085 if test "${gt_cv_ssize_t+set}" = set; then :
21086 $as_echo_n "(cached) " >&6
21087 else
21088 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21089 /* end confdefs.h. */
21090 #include <sys/types.h>
21091 int
21092 main ()
21093 {
21094 int x = sizeof (ssize_t *) + sizeof (ssize_t);
21095 return !x;
21096 ;
21097 return 0;
21098 }
21099 _ACEOF
21100 if ac_fn_c_try_compile "$LINENO"; then :
21101 gt_cv_ssize_t=yes
21102 else
21103 gt_cv_ssize_t=no
21104 fi
21105 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21106 fi
21107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
21108 $as_echo "$gt_cv_ssize_t" >&6; }
21109 if test $gt_cv_ssize_t = no; then
21110
21111 $as_echo "#define ssize_t int" >>confdefs.h
21112
21113 fi
21114
21115
21116
21117
21118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
21119 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
21120 if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
21121 $as_echo_n "(cached) " >&6
21122 else
21123 if test "$cross_compiling" = yes; then :
21124 case $host_os in
21125 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
21126 *) gl_cv_func_stat_dir_slash="guessing yes";;
21127 esac
21128 else
21129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21130 /* end confdefs.h. */
21131 #include <sys/stat.h>
21132
21133 int
21134 main ()
21135 {
21136 struct stat st; return stat (".", &st) != stat ("./", &st);
21137 ;
21138 return 0;
21139 }
21140 _ACEOF
21141 if ac_fn_c_try_run "$LINENO"; then :
21142 gl_cv_func_stat_dir_slash=yes
21143 else
21144 gl_cv_func_stat_dir_slash=no
21145 fi
21146 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21147 conftest.$ac_objext conftest.beam conftest.$ac_ext
21148 fi
21149
21150 fi
21151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
21152 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
21153 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
21154 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
21155 if test "${gl_cv_func_stat_file_slash+set}" = set; then :
21156 $as_echo_n "(cached) " >&6
21157 else
21158 touch conftest.tmp
21159 # Assume that if we have lstat, we can also check symlinks.
21160 if test $ac_cv_func_lstat = yes; then
21161 ln -s conftest.tmp conftest.lnk
21162 fi
21163 if test "$cross_compiling" = yes; then :
21164 case "$host_os" in
21165 # Guess yes on glibc systems.
21166 *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
21167 # If we don't know, assume the worst.
21168 *) gl_cv_func_stat_file_slash="guessing no" ;;
21169 esac
21170
21171 else
21172 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21173 /* end confdefs.h. */
21174 #include <sys/stat.h>
21175
21176 int
21177 main ()
21178 {
21179 int result = 0;
21180 struct stat st;
21181 if (!stat ("conftest.tmp/", &st))
21182 result |= 1;
21183 #if HAVE_LSTAT
21184 if (!stat ("conftest.lnk/", &st))
21185 result |= 2;
21186 #endif
21187 return result;
21188
21189 ;
21190 return 0;
21191 }
21192 _ACEOF
21193 if ac_fn_c_try_run "$LINENO"; then :
21194 gl_cv_func_stat_file_slash=yes
21195 else
21196 gl_cv_func_stat_file_slash=no
21197 fi
21198 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21199 conftest.$ac_objext conftest.beam conftest.$ac_ext
21200 fi
21201
21202 rm -f conftest.tmp conftest.lnk
21203 fi
21204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
21205 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
21206 case $gl_cv_func_stat_dir_slash in
21207 *no) REPLACE_STAT=1
21208
21209 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
21210 ;;
21211 esac
21212 case $gl_cv_func_stat_file_slash in
21213 *no) REPLACE_STAT=1
21214
21215 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
21216 ;;
21217 esac
21218
21219 if test $REPLACE_STAT = 1; then
21220
21221
21222
21223
21224
21225
21226
21227
21228 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
21229
21230 :
21231 fi
21232
21233
21234
21235
21236
21237 GNULIB_STAT=1
21238
21239
21240
21241
21242
21243 $as_echo "#define GNULIB_TEST_STAT 1" >>confdefs.h
21244
21245
21246
21247
21248
21249
21250 # Define two additional variables used in the Makefile substitution.
21251
21252 if test "$ac_cv_header_stdbool_h" = yes; then
21253 STDBOOL_H=''
21254 else
21255 STDBOOL_H='stdbool.h'
21256 fi
21257
21258 if test -n "$STDBOOL_H"; then
21259 GL_GENERATE_STDBOOL_H_TRUE=
21260 GL_GENERATE_STDBOOL_H_FALSE='#'
21261 else
21262 GL_GENERATE_STDBOOL_H_TRUE='#'
21263 GL_GENERATE_STDBOOL_H_FALSE=
21264 fi
21265
21266
21267 if test "$ac_cv_type__Bool" = yes; then
21268 HAVE__BOOL=1
21269 else
21270 HAVE__BOOL=0
21271 fi
21272
21273
21274
21275
21276
21277 STDDEF_H=
21278 ac_fn_c_check_type "$LINENO" "max_align_t" "ac_cv_type_max_align_t" "#include <stddef.h>
21279
21280 "
21281 if test "x$ac_cv_type_max_align_t" = x""yes; then :
21282
21283 else
21284 HAVE_MAX_ALIGN_T=0; STDDEF_H=stddef.h
21285 fi
21286
21287 if test $gt_cv_c_wchar_t = no; then
21288 HAVE_WCHAR_T=0
21289 STDDEF_H=stddef.h
21290 fi
21291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
21292 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
21293 if test "${gl_cv_decl_null_works+set}" = set; then :
21294 $as_echo_n "(cached) " >&6
21295 else
21296 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21297 /* end confdefs.h. */
21298 #include <stddef.h>
21299 int test[2 * (sizeof NULL == sizeof (void *)) -1];
21300
21301 int
21302 main ()
21303 {
21304
21305 ;
21306 return 0;
21307 }
21308 _ACEOF
21309 if ac_fn_c_try_compile "$LINENO"; then :
21310 gl_cv_decl_null_works=yes
21311 else
21312 gl_cv_decl_null_works=no
21313 fi
21314 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21315 fi
21316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
21317 $as_echo "$gl_cv_decl_null_works" >&6; }
21318 if test $gl_cv_decl_null_works = no; then
21319 REPLACE_NULL=1
21320 STDDEF_H=stddef.h
21321 fi
21322
21323 if test -n "$STDDEF_H"; then
21324 GL_GENERATE_STDDEF_H_TRUE=
21325 GL_GENERATE_STDDEF_H_FALSE='#'
21326 else
21327 GL_GENERATE_STDDEF_H_TRUE='#'
21328 GL_GENERATE_STDDEF_H_FALSE=
21329 fi
21330
21331 if test -n "$STDDEF_H"; then
21332
21333
21334
21335
21336
21337
21338
21339
21340 if test $gl_cv_have_include_next = yes; then
21341 gl_cv_next_stddef_h='<'stddef.h'>'
21342 else
21343 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
21344 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
21345 if test "${gl_cv_next_stddef_h+set}" = set; then :
21346 $as_echo_n "(cached) " >&6
21347 else
21348
21349
21350
21351 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21352 /* end confdefs.h. */
21353 #include <stddef.h>
21354 _ACEOF
21355 case "$host_os" in
21356 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21357 *) gl_absname_cpp="$ac_cpp" ;;
21358 esac
21359
21360 case "$host_os" in
21361 mingw*)
21362 gl_dirsep_regex='[/\\]'
21363 ;;
21364 *)
21365 gl_dirsep_regex='\/'
21366 ;;
21367 esac
21368 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21369 gl_header_literal_regex=`echo 'stddef.h' \
21370 | sed -e "$gl_make_literal_regex_sed"`
21371 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21372 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21373 s|^/[^/]|//&|
21374 p
21375 q
21376 }'
21377
21378 gl_cv_absolute_stddef_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21379 sed -n "$gl_absolute_header_sed"`
21380
21381 gl_header=$gl_cv_absolute_stddef_h
21382 gl_cv_next_stddef_h='"'$gl_header'"'
21383
21384
21385 fi
21386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
21387 $as_echo "$gl_cv_next_stddef_h" >&6; }
21388 fi
21389 NEXT_STDDEF_H=$gl_cv_next_stddef_h
21390
21391 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21392 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21393 gl_next_as_first_directive='<'stddef.h'>'
21394 else
21395 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21396 gl_next_as_first_directive=$gl_cv_next_stddef_h
21397 fi
21398 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
21399
21400
21401
21402
21403 fi
21404
21405
21406
21407
21408 $as_echo "#define __USE_MINGW_ANSI_STDIO 1" >>confdefs.h
21409
21410
21411
21412
21413
21414
21415
21416
21417
21418
21419 if test $gl_cv_have_include_next = yes; then
21420 gl_cv_next_stdio_h='<'stdio.h'>'
21421 else
21422 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
21423 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
21424 if test "${gl_cv_next_stdio_h+set}" = set; then :
21425 $as_echo_n "(cached) " >&6
21426 else
21427
21428
21429
21430 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21431 /* end confdefs.h. */
21432 #include <stdio.h>
21433 _ACEOF
21434 case "$host_os" in
21435 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21436 *) gl_absname_cpp="$ac_cpp" ;;
21437 esac
21438
21439 case "$host_os" in
21440 mingw*)
21441 gl_dirsep_regex='[/\\]'
21442 ;;
21443 *)
21444 gl_dirsep_regex='\/'
21445 ;;
21446 esac
21447 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21448 gl_header_literal_regex=`echo 'stdio.h' \
21449 | sed -e "$gl_make_literal_regex_sed"`
21450 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21451 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21452 s|^/[^/]|//&|
21453 p
21454 q
21455 }'
21456
21457 gl_cv_absolute_stdio_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21458 sed -n "$gl_absolute_header_sed"`
21459
21460 gl_header=$gl_cv_absolute_stdio_h
21461 gl_cv_next_stdio_h='"'$gl_header'"'
21462
21463
21464 fi
21465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
21466 $as_echo "$gl_cv_next_stdio_h" >&6; }
21467 fi
21468 NEXT_STDIO_H=$gl_cv_next_stdio_h
21469
21470 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21471 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21472 gl_next_as_first_directive='<'stdio.h'>'
21473 else
21474 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21475 gl_next_as_first_directive=$gl_cv_next_stdio_h
21476 fi
21477 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
21478
21479
21480
21481
21482
21483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which flavor of printf attribute matches inttypes macros" >&5
21484 $as_echo_n "checking which flavor of printf attribute matches inttypes macros... " >&6; }
21485 if test "${gl_cv_func_printf_attribute_flavor+set}" = set; then :
21486 $as_echo_n "(cached) " >&6
21487 else
21488 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21489 /* end confdefs.h. */
21490
21491 #define __STDC_FORMAT_MACROS 1
21492 #include <stdio.h>
21493 #include <inttypes.h>
21494 /* For non-mingw systems, compilation will trivially succeed.
21495 For mingw, compilation will succeed for older mingw (system
21496 printf, "I64d") and fail for newer mingw (gnu printf, "lld"). */
21497 #if ((defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__) && \
21498 (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4))
21499 extern char PRIdMAX_probe[sizeof PRIdMAX == sizeof "I64d" ? 1 : -1];
21500 #endif
21501
21502 int
21503 main ()
21504 {
21505
21506 ;
21507 return 0;
21508 }
21509 _ACEOF
21510 if ac_fn_c_try_compile "$LINENO"; then :
21511 gl_cv_func_printf_attribute_flavor=system
21512 else
21513 gl_cv_func_printf_attribute_flavor=gnu
21514 fi
21515 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21516 fi
21517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_attribute_flavor" >&5
21518 $as_echo "$gl_cv_func_printf_attribute_flavor" >&6; }
21519 if test "$gl_cv_func_printf_attribute_flavor" = gnu; then
21520
21521 $as_echo "#define GNULIB_PRINTF_ATTRIBUTE_FLAVOR_GNU 1" >>confdefs.h
21522
21523 fi
21524
21525 GNULIB_FSCANF=1
21526
21527
21528 cat >>confdefs.h <<_ACEOF
21529 #define GNULIB_FSCANF 1
21530 _ACEOF
21531
21532
21533 GNULIB_SCANF=1
21534
21535
21536 cat >>confdefs.h <<_ACEOF
21537 #define GNULIB_SCANF 1
21538 _ACEOF
21539
21540
21541 GNULIB_FGETC=1
21542 GNULIB_GETC=1
21543 GNULIB_GETCHAR=1
21544 GNULIB_FGETS=1
21545 GNULIB_FREAD=1
21546
21547
21548 GNULIB_FPRINTF=1
21549 GNULIB_PRINTF=1
21550 GNULIB_VFPRINTF=1
21551 GNULIB_VPRINTF=1
21552 GNULIB_FPUTC=1
21553 GNULIB_PUTC=1
21554 GNULIB_PUTCHAR=1
21555 GNULIB_FPUTS=1
21556 GNULIB_PUTS=1
21557 GNULIB_FWRITE=1
21558
21559
21560
21561
21562 for gl_func in dprintf fpurge fseeko ftello getdelim getline gets pclose popen renameat snprintf tmpfile vdprintf vsnprintf; do
21563 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
21564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
21565 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
21566 if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
21567 $as_echo_n "(cached) " >&6
21568 else
21569 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21570 /* end confdefs.h. */
21571 #include <stdio.h>
21572
21573 int
21574 main ()
21575 {
21576 #undef $gl_func
21577 (void) $gl_func;
21578 ;
21579 return 0;
21580 }
21581 _ACEOF
21582 if ac_fn_c_try_compile "$LINENO"; then :
21583 eval "$as_gl_Symbol=yes"
21584 else
21585 eval "$as_gl_Symbol=no"
21586 fi
21587 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21588 fi
21589 eval ac_res=\$$as_gl_Symbol
21590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
21591 $as_echo "$ac_res" >&6; }
21592 eval as_val=\$$as_gl_Symbol
21593 if test "x$as_val" = x""yes; then :
21594 cat >>confdefs.h <<_ACEOF
21595 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
21596 _ACEOF
21597
21598 eval ac_cv_have_decl_$gl_func=yes
21599 fi
21600 done
21601
21602
21603
21604
21605
21606
21607
21608
21609
21610
21611
21612
21613 if test $gl_cv_have_include_next = yes; then
21614 gl_cv_next_stdlib_h='<'stdlib.h'>'
21615 else
21616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
21617 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
21618 if test "${gl_cv_next_stdlib_h+set}" = set; then :
21619 $as_echo_n "(cached) " >&6
21620 else
21621
21622
21623
21624 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21625 /* end confdefs.h. */
21626 #include <stdlib.h>
21627 _ACEOF
21628 case "$host_os" in
21629 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21630 *) gl_absname_cpp="$ac_cpp" ;;
21631 esac
21632
21633 case "$host_os" in
21634 mingw*)
21635 gl_dirsep_regex='[/\\]'
21636 ;;
21637 *)
21638 gl_dirsep_regex='\/'
21639 ;;
21640 esac
21641 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21642 gl_header_literal_regex=`echo 'stdlib.h' \
21643 | sed -e "$gl_make_literal_regex_sed"`
21644 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21645 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21646 s|^/[^/]|//&|
21647 p
21648 q
21649 }'
21650
21651 gl_cv_absolute_stdlib_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21652 sed -n "$gl_absolute_header_sed"`
21653
21654 gl_header=$gl_cv_absolute_stdlib_h
21655 gl_cv_next_stdlib_h='"'$gl_header'"'
21656
21657
21658 fi
21659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
21660 $as_echo "$gl_cv_next_stdlib_h" >&6; }
21661 fi
21662 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
21663
21664 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21665 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21666 gl_next_as_first_directive='<'stdlib.h'>'
21667 else
21668 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21669 gl_next_as_first_directive=$gl_cv_next_stdlib_h
21670 fi
21671 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
21672
21673
21674
21675
21676
21677
21678 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 qsort_r random random_r realpath rpmatch secure_getenv setenv setstate setstate_r srandom srandom_r strtod strtoll strtoull unlockpt unsetenv; do
21679 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
21680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
21681 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
21682 if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
21683 $as_echo_n "(cached) " >&6
21684 else
21685 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21686 /* end confdefs.h. */
21687 #include <stdlib.h>
21688 #if HAVE_SYS_LOADAVG_H
21689 # include <sys/loadavg.h>
21690 #endif
21691 #if HAVE_RANDOM_H
21692 # include <random.h>
21693 #endif
21694
21695 int
21696 main ()
21697 {
21698 #undef $gl_func
21699 (void) $gl_func;
21700 ;
21701 return 0;
21702 }
21703 _ACEOF
21704 if ac_fn_c_try_compile "$LINENO"; then :
21705 eval "$as_gl_Symbol=yes"
21706 else
21707 eval "$as_gl_Symbol=no"
21708 fi
21709 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21710 fi
21711 eval ac_res=\$$as_gl_Symbol
21712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
21713 $as_echo "$ac_res" >&6; }
21714 eval as_val=\$$as_gl_Symbol
21715 if test "x$as_val" = x""yes; then :
21716 cat >>confdefs.h <<_ACEOF
21717 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
21718 _ACEOF
21719
21720 eval ac_cv_have_decl_$gl_func=yes
21721 fi
21722 done
21723
21724
21725
21726
21727
21728
21729 for ac_func in strchrnul
21730 do :
21731 ac_fn_c_check_func "$LINENO" "strchrnul" "ac_cv_func_strchrnul"
21732 if test "x$ac_cv_func_strchrnul" = x""yes; then :
21733 cat >>confdefs.h <<_ACEOF
21734 #define HAVE_STRCHRNUL 1
21735 _ACEOF
21736
21737 fi
21738 done
21739
21740 if test $ac_cv_func_strchrnul = no; then
21741 HAVE_STRCHRNUL=0
21742 else
21743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strchrnul works" >&5
21744 $as_echo_n "checking whether strchrnul works... " >&6; }
21745 if test "${gl_cv_func_strchrnul_works+set}" = set; then :
21746 $as_echo_n "(cached) " >&6
21747 else
21748 if test "$cross_compiling" = yes; then :
21749 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21750 /* end confdefs.h. */
21751
21752 #if defined __CYGWIN__
21753 #include <cygwin/version.h>
21754 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 9)
21755 Lucky user
21756 #endif
21757 #else
21758 Lucky user
21759 #endif
21760
21761 _ACEOF
21762 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
21763 $EGREP "Lucky user" >/dev/null 2>&1; then :
21764 gl_cv_func_strchrnul_works="guessing yes"
21765 else
21766 gl_cv_func_strchrnul_works="guessing no"
21767 fi
21768 rm -f conftest*
21769
21770
21771 else
21772 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21773 /* end confdefs.h. */
21774
21775 #include <string.h> /* for strchrnul */
21776
21777 int
21778 main ()
21779 {
21780 const char *buf = "a";
21781 return strchrnul (buf, 'b') != buf + 1;
21782
21783 ;
21784 return 0;
21785 }
21786 _ACEOF
21787 if ac_fn_c_try_run "$LINENO"; then :
21788 gl_cv_func_strchrnul_works=yes
21789 else
21790 gl_cv_func_strchrnul_works=no
21791 fi
21792 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21793 conftest.$ac_objext conftest.beam conftest.$ac_ext
21794 fi
21795
21796
21797 fi
21798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strchrnul_works" >&5
21799 $as_echo "$gl_cv_func_strchrnul_works" >&6; }
21800 case "$gl_cv_func_strchrnul_works" in
21801 *yes) ;;
21802 *) REPLACE_STRCHRNUL=1 ;;
21803 esac
21804 fi
21805
21806 if test $HAVE_STRCHRNUL = 0 || test $REPLACE_STRCHRNUL = 1; then
21807
21808
21809
21810
21811
21812
21813
21814
21815 gl_LIBOBJS="$gl_LIBOBJS strchrnul.$ac_objext"
21816
21817 :
21818 fi
21819
21820
21821
21822
21823
21824 GNULIB_STRCHRNUL=1
21825
21826
21827
21828
21829
21830 $as_echo "#define GNULIB_TEST_STRCHRNUL 1" >>confdefs.h
21831
21832
21833
21834
21835
21836
21837
21838 if test $ac_cv_func_strdup = yes; then
21839 if test $gl_cv_func_malloc_posix != yes; then
21840 REPLACE_STRDUP=1
21841 fi
21842 fi
21843
21844 if test $ac_cv_have_decl_strdup = no; then
21845 HAVE_DECL_STRDUP=0
21846 fi
21847
21848 if test $ac_cv_func_strdup = no || test $REPLACE_STRDUP = 1; then
21849
21850
21851
21852
21853
21854
21855
21856
21857 gl_LIBOBJS="$gl_LIBOBJS strdup.$ac_objext"
21858
21859 :
21860 fi
21861
21862
21863
21864
21865
21866 GNULIB_STRDUP=1
21867
21868
21869
21870
21871
21872 $as_echo "#define GNULIB_TEST_STRDUP 1" >>confdefs.h
21873
21874
21875
21876
21877
21878
21879
21880
21881 if test "$ERRNO_H:$REPLACE_STRERROR_0" = :0; then
21882 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strerror function" >&5
21883 $as_echo_n "checking for working strerror function... " >&6; }
21884 if test "${gl_cv_func_working_strerror+set}" = set; then :
21885 $as_echo_n "(cached) " >&6
21886 else
21887 if test "$cross_compiling" = yes; then :
21888 case "$host_os" in
21889 # Guess yes on glibc systems.
21890 *-gnu*) gl_cv_func_working_strerror="guessing yes" ;;
21891 # If we don't know, assume the worst.
21892 *) gl_cv_func_working_strerror="guessing no" ;;
21893 esac
21894
21895 else
21896 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21897 /* end confdefs.h. */
21898 #include <string.h>
21899
21900 int
21901 main ()
21902 {
21903 if (!*strerror (-2)) return 1;
21904 ;
21905 return 0;
21906 }
21907 _ACEOF
21908 if ac_fn_c_try_run "$LINENO"; then :
21909 gl_cv_func_working_strerror=yes
21910 else
21911 gl_cv_func_working_strerror=no
21912 fi
21913 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21914 conftest.$ac_objext conftest.beam conftest.$ac_ext
21915 fi
21916
21917
21918 fi
21919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_strerror" >&5
21920 $as_echo "$gl_cv_func_working_strerror" >&6; }
21921 case "$gl_cv_func_working_strerror" in
21922 *yes) ;;
21923 *)
21924 REPLACE_STRERROR=1
21925 ;;
21926 esac
21927
21928 else
21929 REPLACE_STRERROR=1
21930 fi
21931
21932 if test $REPLACE_STRERROR = 1; then
21933
21934
21935
21936
21937
21938
21939
21940
21941 gl_LIBOBJS="$gl_LIBOBJS strerror.$ac_objext"
21942
21943 fi
21944
21945
21946 cat >>confdefs.h <<_ACEOF
21947 #define GNULIB_STRERROR 1
21948 _ACEOF
21949
21950
21951
21952
21953
21954
21955
21956 GNULIB_STRERROR=1
21957
21958
21959
21960
21961
21962 $as_echo "#define GNULIB_TEST_STRERROR 1" >>confdefs.h
21963
21964
21965
21966
21967
21968 if test -n "$ERRNO_H" || test $REPLACE_STRERROR_0 = 1; then
21969
21970
21971
21972
21973
21974
21975
21976
21977 gl_LIBOBJS="$gl_LIBOBJS strerror-override.$ac_objext"
21978
21979
21980
21981
21982
21983 if test $ac_cv_header_sys_socket_h != yes; then
21984 for ac_header in winsock2.h
21985 do :
21986 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
21987 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
21988 cat >>confdefs.h <<_ACEOF
21989 #define HAVE_WINSOCK2_H 1
21990 _ACEOF
21991
21992 fi
21993
21994 done
21995
21996 fi
21997 if test "$ac_cv_header_winsock2_h" = yes; then
21998 HAVE_WINSOCK2_H=1
21999 UNISTD_H_HAVE_WINSOCK2_H=1
22000 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
22001 else
22002 HAVE_WINSOCK2_H=0
22003 fi
22004
22005
22006 fi
22007
22008
22009
22010
22011
22012 if test $REPLACE_STRSTR = 0; then
22013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strstr works in linear time" >&5
22014 $as_echo_n "checking whether strstr works in linear time... " >&6; }
22015 if test "${gl_cv_func_strstr_linear+set}" = set; then :
22016 $as_echo_n "(cached) " >&6
22017 else
22018 if test "$cross_compiling" = yes; then :
22019 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22020 /* end confdefs.h. */
22021
22022 #include <features.h>
22023 #ifdef __GNU_LIBRARY__
22024 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ > 12) || (__GLIBC__ > 2)) \
22025 && !(defined __i386__ || defined __x86_64__) \
22026 && !defined __UCLIBC__
22027 Lucky user
22028 #endif
22029 #endif
22030 #ifdef __CYGWIN__
22031 #include <cygwin/version.h>
22032 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
22033 Lucky user
22034 #endif
22035 #endif
22036
22037 _ACEOF
22038 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22039 $EGREP "Lucky user" >/dev/null 2>&1; then :
22040 gl_cv_func_strstr_linear="guessing yes"
22041 else
22042 gl_cv_func_strstr_linear="guessing no"
22043 fi
22044 rm -f conftest*
22045
22046
22047 else
22048 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22049 /* end confdefs.h. */
22050
22051 #ifdef __MVS__
22052 /* z/OS does not deliver signals while strstr() is running (thanks to
22053 restrictions on its LE runtime), which prevents us from limiting the
22054 running time of this test. */
22055 # error "This test does not work properly on z/OS"
22056 #endif
22057 #include <signal.h> /* for signal */
22058 #include <string.h> /* for strstr */
22059 #include <stdlib.h> /* for malloc */
22060 #include <unistd.h> /* for alarm */
22061 static void quit (int sig) { _exit (sig + 128); }
22062
22063 int
22064 main ()
22065 {
22066
22067 int result = 0;
22068 size_t m = 1000000;
22069 char *haystack = (char *) malloc (2 * m + 2);
22070 char *needle = (char *) malloc (m + 2);
22071 /* Failure to compile this test due to missing alarm is okay,
22072 since all such platforms (mingw) also have quadratic strstr. */
22073 signal (SIGALRM, quit);
22074 alarm (5);
22075 /* Check for quadratic performance. */
22076 if (haystack && needle)
22077 {
22078 memset (haystack, 'A', 2 * m);
22079 haystack[2 * m] = 'B';
22080 haystack[2 * m + 1] = 0;
22081 memset (needle, 'A', m);
22082 needle[m] = 'B';
22083 needle[m + 1] = 0;
22084 if (!strstr (haystack, needle))
22085 result |= 1;
22086 }
22087 return result;
22088
22089 ;
22090 return 0;
22091 }
22092 _ACEOF
22093 if ac_fn_c_try_run "$LINENO"; then :
22094 gl_cv_func_strstr_linear=yes
22095 else
22096 gl_cv_func_strstr_linear=no
22097 fi
22098 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22099 conftest.$ac_objext conftest.beam conftest.$ac_ext
22100 fi
22101
22102
22103 fi
22104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strstr_linear" >&5
22105 $as_echo "$gl_cv_func_strstr_linear" >&6; }
22106 case "$gl_cv_func_strstr_linear" in
22107 *yes) ;;
22108 *)
22109 REPLACE_STRSTR=1
22110 ;;
22111 esac
22112 fi
22113
22114 if test $REPLACE_STRSTR = 1; then
22115
22116
22117
22118
22119
22120
22121
22122
22123 gl_LIBOBJS="$gl_LIBOBJS strstr.$ac_objext"
22124
22125 fi
22126
22127
22128
22129 if test "$gl_cv_func_memchr_works" != yes; then
22130 REPLACE_STRSTR=1
22131 else
22132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strstr works" >&5
22133 $as_echo_n "checking whether strstr works... " >&6; }
22134 if test "${gl_cv_func_strstr_works_always+set}" = set; then :
22135 $as_echo_n "(cached) " >&6
22136 else
22137 if test "$cross_compiling" = yes; then :
22138 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22139 /* end confdefs.h. */
22140
22141 #ifdef __GNU_LIBRARY__
22142 #include <features.h>
22143 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ > 12) || (__GLIBC__ > 2)) \
22144 || defined __UCLIBC__
22145 Lucky user
22146 #endif
22147 #elif defined __CYGWIN__
22148 #include <cygwin/version.h>
22149 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
22150 Lucky user
22151 #endif
22152 #else
22153 Lucky user
22154 #endif
22155
22156 _ACEOF
22157 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22158 $EGREP "Lucky user" >/dev/null 2>&1; then :
22159 gl_cv_func_strstr_works_always="guessing yes"
22160 else
22161 gl_cv_func_strstr_works_always="guessing no"
22162 fi
22163 rm -f conftest*
22164
22165
22166 else
22167 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22168 /* end confdefs.h. */
22169
22170 #include <string.h> /* for strstr */
22171 #define P "_EF_BF_BD"
22172 #define HAYSTACK "F_BD_CE_BD" P P P P "_C3_88_20" P P P "_C3_A7_20" P
22173 #define NEEDLE P P P P P
22174
22175 int
22176 main ()
22177 {
22178 return !!strstr (HAYSTACK, NEEDLE);
22179
22180 ;
22181 return 0;
22182 }
22183 _ACEOF
22184 if ac_fn_c_try_run "$LINENO"; then :
22185 gl_cv_func_strstr_works_always=yes
22186 else
22187 gl_cv_func_strstr_works_always=no
22188 fi
22189 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22190 conftest.$ac_objext conftest.beam conftest.$ac_ext
22191 fi
22192
22193
22194 fi
22195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strstr_works_always" >&5
22196 $as_echo "$gl_cv_func_strstr_works_always" >&6; }
22197 case "$gl_cv_func_strstr_works_always" in
22198 *yes) ;;
22199 *)
22200 REPLACE_STRSTR=1
22201 ;;
22202 esac
22203 fi
22204
22205 if test $REPLACE_STRSTR = 1; then
22206
22207
22208
22209
22210
22211
22212
22213
22214 gl_LIBOBJS="$gl_LIBOBJS strstr.$ac_objext"
22215
22216 fi
22217
22218
22219
22220
22221
22222 GNULIB_STRSTR=1
22223
22224
22225
22226
22227
22228 $as_echo "#define GNULIB_TEST_STRSTR 1" >>confdefs.h
22229
22230
22231
22232
22233
22234
22235
22236 for ac_func in strtok_r
22237 do :
22238 ac_fn_c_check_func "$LINENO" "strtok_r" "ac_cv_func_strtok_r"
22239 if test "x$ac_cv_func_strtok_r" = x""yes; then :
22240 cat >>confdefs.h <<_ACEOF
22241 #define HAVE_STRTOK_R 1
22242 _ACEOF
22243
22244 fi
22245 done
22246
22247 if test $ac_cv_func_strtok_r = yes; then
22248 HAVE_STRTOK_R=1
22249 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtok_r works" >&5
22250 $as_echo_n "checking whether strtok_r works... " >&6; }
22251 if test "${gl_cv_func_strtok_r_works+set}" = set; then :
22252 $as_echo_n "(cached) " >&6
22253 else
22254 if test "$cross_compiling" = yes; then :
22255
22256 case "$host_os" in
22257 # Guess no on glibc systems.
22258 *-gnu*) gl_cv_func_strtok_r_works="guessing no";;
22259 *) gl_cv_func_strtok_r_works="guessing yes";;
22260 esac
22261
22262 else
22263 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22264 /* end confdefs.h. */
22265
22266 #ifndef __OPTIMIZE__
22267 # define __OPTIMIZE__ 1
22268 #endif
22269 #undef __OPTIMIZE_SIZE__
22270 #undef __NO_INLINE__
22271 #include <stdlib.h>
22272 #include <string.h>
22273
22274 int
22275 main ()
22276 {
22277 static const char dummy[] = "\177\01a";
22278 char delimiters[] = "xxxxxxxx";
22279 char *save_ptr = (char *) dummy;
22280 strtok_r (delimiters, "x", &save_ptr);
22281 strtok_r (NULL, "x", &save_ptr);
22282 return 0;
22283
22284 ;
22285 return 0;
22286 }
22287
22288 _ACEOF
22289 if ac_fn_c_try_run "$LINENO"; then :
22290 gl_cv_func_strtok_r_works=yes
22291 else
22292 gl_cv_func_strtok_r_works=no
22293 fi
22294 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22295 conftest.$ac_objext conftest.beam conftest.$ac_ext
22296 fi
22297
22298
22299 fi
22300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strtok_r_works" >&5
22301 $as_echo "$gl_cv_func_strtok_r_works" >&6; }
22302 case "$gl_cv_func_strtok_r_works" in
22303 *no)
22304 UNDEFINE_STRTOK_R=1
22305 ;;
22306 esac
22307 else
22308 HAVE_STRTOK_R=0
22309 fi
22310
22311 if test $ac_cv_have_decl_strtok_r = no; then
22312 HAVE_DECL_STRTOK_R=0
22313 fi
22314
22315 if test $HAVE_STRTOK_R = 0 || test $REPLACE_STRTOK_R = 1; then
22316
22317
22318
22319
22320
22321
22322
22323
22324 gl_LIBOBJS="$gl_LIBOBJS strtok_r.$ac_objext"
22325
22326
22327 :
22328
22329 fi
22330
22331
22332
22333
22334
22335 GNULIB_STRTOK_R=1
22336
22337
22338
22339
22340
22341 $as_echo "#define GNULIB_TEST_STRTOK_R 1" >>confdefs.h
22342
22343
22344
22345
22346
22347
22348
22349
22350
22351
22352
22353
22354
22355
22356
22357
22358
22359 if test $gl_cv_have_include_next = yes; then
22360 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
22361 else
22362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
22363 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
22364 if test "${gl_cv_next_sys_stat_h+set}" = set; then :
22365 $as_echo_n "(cached) " >&6
22366 else
22367
22368 if test $ac_cv_header_sys_stat_h = yes; then
22369
22370
22371
22372
22373 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22374 /* end confdefs.h. */
22375 #include <sys/stat.h>
22376 _ACEOF
22377 case "$host_os" in
22378 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22379 *) gl_absname_cpp="$ac_cpp" ;;
22380 esac
22381
22382 case "$host_os" in
22383 mingw*)
22384 gl_dirsep_regex='[/\\]'
22385 ;;
22386 *)
22387 gl_dirsep_regex='\/'
22388 ;;
22389 esac
22390 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22391 gl_header_literal_regex=`echo 'sys/stat.h' \
22392 | sed -e "$gl_make_literal_regex_sed"`
22393 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22394 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22395 s|^/[^/]|//&|
22396 p
22397 q
22398 }'
22399
22400 gl_cv_absolute_sys_stat_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22401 sed -n "$gl_absolute_header_sed"`
22402
22403 gl_header=$gl_cv_absolute_sys_stat_h
22404 gl_cv_next_sys_stat_h='"'$gl_header'"'
22405 else
22406 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
22407 fi
22408
22409
22410 fi
22411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
22412 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
22413 fi
22414 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
22415
22416 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22417 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22418 gl_next_as_first_directive='<'sys/stat.h'>'
22419 else
22420 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22421 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
22422 fi
22423 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
22424
22425
22426
22427
22428
22429
22430
22431
22432
22433
22434
22435 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
22436
22437 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
22438
22439 fi
22440
22441 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
22442 #include <sys/stat.h>
22443 "
22444 if test "x$ac_cv_type_nlink_t" = x""yes; then :
22445
22446 else
22447
22448 $as_echo "#define nlink_t int" >>confdefs.h
22449
22450 fi
22451
22452
22453
22454 for gl_func in fchmodat fstat fstatat futimens lchmod lstat mkdirat mkfifo mkfifoat mknod mknodat stat utimensat; do
22455 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
22456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
22457 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
22458 if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
22459 $as_echo_n "(cached) " >&6
22460 else
22461 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22462 /* end confdefs.h. */
22463 #include <sys/stat.h>
22464
22465 int
22466 main ()
22467 {
22468 #undef $gl_func
22469 (void) $gl_func;
22470 ;
22471 return 0;
22472 }
22473 _ACEOF
22474 if ac_fn_c_try_compile "$LINENO"; then :
22475 eval "$as_gl_Symbol=yes"
22476 else
22477 eval "$as_gl_Symbol=no"
22478 fi
22479 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22480 fi
22481 eval ac_res=\$$as_gl_Symbol
22482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
22483 $as_echo "$ac_res" >&6; }
22484 eval as_val=\$$as_gl_Symbol
22485 if test "x$as_val" = x""yes; then :
22486 cat >>confdefs.h <<_ACEOF
22487 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
22488 _ACEOF
22489
22490 eval ac_cv_have_decl_$gl_func=yes
22491 fi
22492 done
22493
22494
22495
22496
22497
22498
22499
22500
22501
22502
22503
22504 :
22505
22506
22507
22508
22509
22510
22511
22512
22513
22514
22515
22516
22517
22518
22519
22520
22521
22522 if test $gl_cv_have_include_next = yes; then
22523 gl_cv_next_unistd_h='<'unistd.h'>'
22524 else
22525 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
22526 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
22527 if test "${gl_cv_next_unistd_h+set}" = set; then :
22528 $as_echo_n "(cached) " >&6
22529 else
22530
22531 if test $ac_cv_header_unistd_h = yes; then
22532
22533
22534
22535
22536 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22537 /* end confdefs.h. */
22538 #include <unistd.h>
22539 _ACEOF
22540 case "$host_os" in
22541 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22542 *) gl_absname_cpp="$ac_cpp" ;;
22543 esac
22544
22545 case "$host_os" in
22546 mingw*)
22547 gl_dirsep_regex='[/\\]'
22548 ;;
22549 *)
22550 gl_dirsep_regex='\/'
22551 ;;
22552 esac
22553 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22554 gl_header_literal_regex=`echo 'unistd.h' \
22555 | sed -e "$gl_make_literal_regex_sed"`
22556 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22557 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22558 s|^/[^/]|//&|
22559 p
22560 q
22561 }'
22562
22563 gl_cv_absolute_unistd_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22564 sed -n "$gl_absolute_header_sed"`
22565
22566 gl_header=$gl_cv_absolute_unistd_h
22567 gl_cv_next_unistd_h='"'$gl_header'"'
22568 else
22569 gl_cv_next_unistd_h='<'unistd.h'>'
22570 fi
22571
22572
22573 fi
22574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
22575 $as_echo "$gl_cv_next_unistd_h" >&6; }
22576 fi
22577 NEXT_UNISTD_H=$gl_cv_next_unistd_h
22578
22579 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22580 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22581 gl_next_as_first_directive='<'unistd.h'>'
22582 else
22583 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22584 gl_next_as_first_directive=$gl_cv_next_unistd_h
22585 fi
22586 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
22587
22588
22589
22590
22591 if test $ac_cv_header_unistd_h = yes; then
22592 HAVE_UNISTD_H=1
22593 else
22594 HAVE_UNISTD_H=0
22595 fi
22596
22597
22598
22599
22600
22601
22602
22603 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
22604 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
22605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
22606 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
22607 if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
22608 $as_echo_n "(cached) " >&6
22609 else
22610 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22611 /* end confdefs.h. */
22612
22613 #if HAVE_UNISTD_H
22614 # include <unistd.h>
22615 #endif
22616 /* Some systems declare various items in the wrong headers. */
22617 #if !(defined __GLIBC__ && !defined __UCLIBC__)
22618 # include <fcntl.h>
22619 # include <stdio.h>
22620 # include <stdlib.h>
22621 # if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
22622 # include <io.h>
22623 # endif
22624 #endif
22625
22626 int
22627 main ()
22628 {
22629 #undef $gl_func
22630 (void) $gl_func;
22631 ;
22632 return 0;
22633 }
22634 _ACEOF
22635 if ac_fn_c_try_compile "$LINENO"; then :
22636 eval "$as_gl_Symbol=yes"
22637 else
22638 eval "$as_gl_Symbol=no"
22639 fi
22640 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22641 fi
22642 eval ac_res=\$$as_gl_Symbol
22643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
22644 $as_echo "$ac_res" >&6; }
22645 eval as_val=\$$as_gl_Symbol
22646 if test "x$as_val" = x""yes; then :
22647 cat >>confdefs.h <<_ACEOF
22648 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
22649 _ACEOF
22650
22651 eval ac_cv_have_decl_$gl_func=yes
22652 fi
22653 done
22654
22655
22656
22657
22658
22659
22660
22661
22662 if test $ac_cv_have_decl_unsetenv = no; then
22663 HAVE_DECL_UNSETENV=0
22664 fi
22665 for ac_func in unsetenv
22666 do :
22667 ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv"
22668 if test "x$ac_cv_func_unsetenv" = x""yes; then :
22669 cat >>confdefs.h <<_ACEOF
22670 #define HAVE_UNSETENV 1
22671 _ACEOF
22672
22673 fi
22674 done
22675
22676 if test $ac_cv_func_unsetenv = no; then
22677 HAVE_UNSETENV=0
22678 else
22679 HAVE_UNSETENV=1
22680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsetenv() return type" >&5
22681 $as_echo_n "checking for unsetenv() return type... " >&6; }
22682 if test "${gt_cv_func_unsetenv_ret+set}" = set; then :
22683 $as_echo_n "(cached) " >&6
22684 else
22685 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22686 /* end confdefs.h. */
22687
22688 #undef _BSD
22689 #define _BSD 1 /* unhide unsetenv declaration in OSF/1 5.1 <stdlib.h> */
22690 #include <stdlib.h>
22691 extern
22692 #ifdef __cplusplus
22693 "C"
22694 #endif
22695 int unsetenv (const char *name);
22696
22697 int
22698 main ()
22699 {
22700
22701 ;
22702 return 0;
22703 }
22704 _ACEOF
22705 if ac_fn_c_try_compile "$LINENO"; then :
22706 gt_cv_func_unsetenv_ret='int'
22707 else
22708 gt_cv_func_unsetenv_ret='void'
22709 fi
22710 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22711 fi
22712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_unsetenv_ret" >&5
22713 $as_echo "$gt_cv_func_unsetenv_ret" >&6; }
22714 if test $gt_cv_func_unsetenv_ret = 'void'; then
22715
22716 $as_echo "#define VOID_UNSETENV 1" >>confdefs.h
22717
22718 REPLACE_UNSETENV=1
22719 fi
22720
22721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether unsetenv obeys POSIX" >&5
22722 $as_echo_n "checking whether unsetenv obeys POSIX... " >&6; }
22723 if test "${gl_cv_func_unsetenv_works+set}" = set; then :
22724 $as_echo_n "(cached) " >&6
22725 else
22726 if test "$cross_compiling" = yes; then :
22727 case "$host_os" in
22728 # Guess yes on glibc systems.
22729 *-gnu*) gl_cv_func_unsetenv_works="guessing yes" ;;
22730 # If we don't know, assume the worst.
22731 *) gl_cv_func_unsetenv_works="guessing no" ;;
22732 esac
22733
22734 else
22735 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22736 /* end confdefs.h. */
22737
22738 #include <stdlib.h>
22739 #include <errno.h>
22740 extern char **environ;
22741
22742 int
22743 main ()
22744 {
22745
22746 char entry1[] = "a=1";
22747 char entry2[] = "b=2";
22748 char *env[] = { entry1, entry2, NULL };
22749 if (putenv ((char *) "a=1")) return 1;
22750 if (putenv (entry2)) return 2;
22751 entry2[0] = 'a';
22752 unsetenv ("a");
22753 if (getenv ("a")) return 3;
22754 if (!unsetenv ("") || errno != EINVAL) return 4;
22755 entry2[0] = 'b';
22756 environ = env;
22757 if (!getenv ("a")) return 5;
22758 entry2[0] = 'a';
22759 unsetenv ("a");
22760 if (getenv ("a")) return 6;
22761
22762 ;
22763 return 0;
22764 }
22765 _ACEOF
22766 if ac_fn_c_try_run "$LINENO"; then :
22767 gl_cv_func_unsetenv_works=yes
22768 else
22769 gl_cv_func_unsetenv_works=no
22770 fi
22771 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22772 conftest.$ac_objext conftest.beam conftest.$ac_ext
22773 fi
22774
22775 fi
22776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_unsetenv_works" >&5
22777 $as_echo "$gl_cv_func_unsetenv_works" >&6; }
22778 case "$gl_cv_func_unsetenv_works" in
22779 *yes) ;;
22780 *)
22781 REPLACE_UNSETENV=1
22782 ;;
22783 esac
22784 fi
22785
22786 if test $HAVE_UNSETENV = 0 || test $REPLACE_UNSETENV = 1; then
22787
22788
22789
22790
22791
22792
22793
22794
22795 gl_LIBOBJS="$gl_LIBOBJS unsetenv.$ac_objext"
22796
22797
22798
22799
22800
22801 fi
22802
22803
22804
22805
22806
22807 GNULIB_UNSETENV=1
22808
22809
22810
22811
22812
22813 $as_echo "#define GNULIB_TEST_UNSETENV 1" >>confdefs.h
22814
22815
22816
22817
22818
22819
22820
22821
22822
22823
22824
22825
22826
22827
22828
22829 if test $gl_cv_have_include_next = yes; then
22830 gl_cv_next_wchar_h='<'wchar.h'>'
22831 else
22832 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <wchar.h>" >&5
22833 $as_echo_n "checking absolute name of <wchar.h>... " >&6; }
22834 if test "${gl_cv_next_wchar_h+set}" = set; then :
22835 $as_echo_n "(cached) " >&6
22836 else
22837
22838 if test $ac_cv_header_wchar_h = yes; then
22839
22840
22841
22842
22843 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22844 /* end confdefs.h. */
22845 #include <wchar.h>
22846 _ACEOF
22847 case "$host_os" in
22848 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22849 *) gl_absname_cpp="$ac_cpp" ;;
22850 esac
22851
22852 case "$host_os" in
22853 mingw*)
22854 gl_dirsep_regex='[/\\]'
22855 ;;
22856 *)
22857 gl_dirsep_regex='\/'
22858 ;;
22859 esac
22860 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22861 gl_header_literal_regex=`echo 'wchar.h' \
22862 | sed -e "$gl_make_literal_regex_sed"`
22863 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22864 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22865 s|^/[^/]|//&|
22866 p
22867 q
22868 }'
22869
22870 gl_cv_absolute_wchar_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22871 sed -n "$gl_absolute_header_sed"`
22872
22873 gl_header=$gl_cv_absolute_wchar_h
22874 gl_cv_next_wchar_h='"'$gl_header'"'
22875 else
22876 gl_cv_next_wchar_h='<'wchar.h'>'
22877 fi
22878
22879
22880 fi
22881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wchar_h" >&5
22882 $as_echo "$gl_cv_next_wchar_h" >&6; }
22883 fi
22884 NEXT_WCHAR_H=$gl_cv_next_wchar_h
22885
22886 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22887 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22888 gl_next_as_first_directive='<'wchar.h'>'
22889 else
22890 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22891 gl_next_as_first_directive=$gl_cv_next_wchar_h
22892 fi
22893 NEXT_AS_FIRST_DIRECTIVE_WCHAR_H=$gl_next_as_first_directive
22894
22895
22896
22897
22898 if test $ac_cv_header_wchar_h = yes; then
22899 HAVE_WCHAR_H=1
22900 else
22901 HAVE_WCHAR_H=0
22902 fi
22903
22904
22905
22906
22907
22908 if test $gt_cv_c_wint_t = yes; then
22909 HAVE_WINT_T=1
22910 else
22911 HAVE_WINT_T=0
22912 fi
22913
22914
22915
22916 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
22917 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
22918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
22919 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
22920 if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
22921 $as_echo_n "(cached) " >&6
22922 else
22923 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22924 /* end confdefs.h. */
22925
22926 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
22927 <wchar.h>.
22928 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
22929 included before <wchar.h>. */
22930 #if !(defined __GLIBC__ && !defined __UCLIBC__)
22931 # include <stddef.h>
22932 # include <stdio.h>
22933 # include <time.h>
22934 #endif
22935 #include <wchar.h>
22936
22937 int
22938 main ()
22939 {
22940 #undef $gl_func
22941 (void) $gl_func;
22942 ;
22943 return 0;
22944 }
22945 _ACEOF
22946 if ac_fn_c_try_compile "$LINENO"; then :
22947 eval "$as_gl_Symbol=yes"
22948 else
22949 eval "$as_gl_Symbol=no"
22950 fi
22951 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22952 fi
22953 eval ac_res=\$$as_gl_Symbol
22954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
22955 $as_echo "$ac_res" >&6; }
22956 eval as_val=\$$as_gl_Symbol
22957 if test "x$as_val" = x""yes; then :
22958 cat >>confdefs.h <<_ACEOF
22959 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
22960 _ACEOF
22961
22962 eval ac_cv_have_decl_$gl_func=yes
22963 fi
22964 done
22965
22966
22967
22968
22969
22970
22971
22972 if test $ac_cv_func_iswcntrl = yes; then
22973 HAVE_ISWCNTRL=1
22974 else
22975 HAVE_ISWCNTRL=0
22976 fi
22977
22978
22979
22980 if test $gt_cv_c_wint_t = yes; then
22981 HAVE_WINT_T=1
22982 else
22983 HAVE_WINT_T=0
22984 fi
22985
22986
22987
22988
22989
22990
22991
22992
22993
22994
22995
22996 if test $gl_cv_have_include_next = yes; then
22997 gl_cv_next_wctype_h='<'wctype.h'>'
22998 else
22999 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <wctype.h>" >&5
23000 $as_echo_n "checking absolute name of <wctype.h>... " >&6; }
23001 if test "${gl_cv_next_wctype_h+set}" = set; then :
23002 $as_echo_n "(cached) " >&6
23003 else
23004
23005 if test $ac_cv_header_wctype_h = yes; then
23006
23007
23008
23009
23010 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23011 /* end confdefs.h. */
23012 #include <wctype.h>
23013 _ACEOF
23014 case "$host_os" in
23015 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23016 *) gl_absname_cpp="$ac_cpp" ;;
23017 esac
23018
23019 case "$host_os" in
23020 mingw*)
23021 gl_dirsep_regex='[/\\]'
23022 ;;
23023 *)
23024 gl_dirsep_regex='\/'
23025 ;;
23026 esac
23027 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23028 gl_header_literal_regex=`echo 'wctype.h' \
23029 | sed -e "$gl_make_literal_regex_sed"`
23030 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23031 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23032 s|^/[^/]|//&|
23033 p
23034 q
23035 }'
23036
23037 gl_cv_absolute_wctype_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23038 sed -n "$gl_absolute_header_sed"`
23039
23040 gl_header=$gl_cv_absolute_wctype_h
23041 gl_cv_next_wctype_h='"'$gl_header'"'
23042 else
23043 gl_cv_next_wctype_h='<'wctype.h'>'
23044 fi
23045
23046
23047 fi
23048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wctype_h" >&5
23049 $as_echo "$gl_cv_next_wctype_h" >&6; }
23050 fi
23051 NEXT_WCTYPE_H=$gl_cv_next_wctype_h
23052
23053 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23054 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23055 gl_next_as_first_directive='<'wctype.h'>'
23056 else
23057 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23058 gl_next_as_first_directive=$gl_cv_next_wctype_h
23059 fi
23060 NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H=$gl_next_as_first_directive
23061
23062
23063
23064
23065 if test $ac_cv_header_wctype_h = yes; then
23066 if test $ac_cv_func_iswcntrl = yes; then
23067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether iswcntrl works" >&5
23068 $as_echo_n "checking whether iswcntrl works... " >&6; }
23069 if test "${gl_cv_func_iswcntrl_works+set}" = set; then :
23070 $as_echo_n "(cached) " >&6
23071 else
23072
23073 if test "$cross_compiling" = yes; then :
23074 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23075 /* end confdefs.h. */
23076 #include <stdlib.h>
23077 #if __GNU_LIBRARY__ == 1
23078 Linux libc5 i18n is broken.
23079 #endif
23080 int
23081 main ()
23082 {
23083
23084 ;
23085 return 0;
23086 }
23087 _ACEOF
23088 if ac_fn_c_try_compile "$LINENO"; then :
23089 gl_cv_func_iswcntrl_works="guessing yes"
23090 else
23091 gl_cv_func_iswcntrl_works="guessing no"
23092 fi
23093 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23094
23095 else
23096 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23097 /* end confdefs.h. */
23098
23099 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
23100 included before <wchar.h>.
23101 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
23102 must be included before <wchar.h>. */
23103 #include <stddef.h>
23104 #include <stdio.h>
23105 #include <time.h>
23106 #include <wchar.h>
23107 #include <wctype.h>
23108 int main () { return iswprint ('x') == 0; }
23109
23110 _ACEOF
23111 if ac_fn_c_try_run "$LINENO"; then :
23112 gl_cv_func_iswcntrl_works=yes
23113 else
23114 gl_cv_func_iswcntrl_works=no
23115 fi
23116 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23117 conftest.$ac_objext conftest.beam conftest.$ac_ext
23118 fi
23119
23120
23121 fi
23122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_iswcntrl_works" >&5
23123 $as_echo "$gl_cv_func_iswcntrl_works" >&6; }
23124 fi
23125 HAVE_WCTYPE_H=1
23126 else
23127 HAVE_WCTYPE_H=0
23128 fi
23129
23130
23131 case "$gl_cv_func_iswcntrl_works" in
23132 *yes) REPLACE_ISWCNTRL=0 ;;
23133 *) REPLACE_ISWCNTRL=1 ;;
23134 esac
23135
23136
23137 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_ISWCNTRL = 1; then
23138 :
23139 fi
23140
23141 if test $REPLACE_ISWCNTRL = 1; then
23142 REPLACE_TOWLOWER=1
23143 else
23144 for ac_func in towlower
23145 do :
23146 ac_fn_c_check_func "$LINENO" "towlower" "ac_cv_func_towlower"
23147 if test "x$ac_cv_func_towlower" = x""yes; then :
23148 cat >>confdefs.h <<_ACEOF
23149 #define HAVE_TOWLOWER 1
23150 _ACEOF
23151
23152 fi
23153 done
23154
23155 if test $ac_cv_func_towlower = yes; then
23156 REPLACE_TOWLOWER=0
23157 else
23158 ac_fn_c_check_decl "$LINENO" "towlower" "ac_cv_have_decl_towlower" "/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
23159 included before <wchar.h>.
23160 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
23161 must be included before <wchar.h>. */
23162 #include <stddef.h>
23163 #include <stdio.h>
23164 #include <time.h>
23165 #include <wchar.h>
23166 #if HAVE_WCTYPE_H
23167 # include <wctype.h>
23168 #endif
23169
23170 "
23171 if test "x$ac_cv_have_decl_towlower" = x""yes; then :
23172 ac_have_decl=1
23173 else
23174 ac_have_decl=0
23175 fi
23176
23177 cat >>confdefs.h <<_ACEOF
23178 #define HAVE_DECL_TOWLOWER $ac_have_decl
23179 _ACEOF
23180
23181 if test $ac_cv_have_decl_towlower = yes; then
23182 REPLACE_TOWLOWER=1
23183 else
23184 REPLACE_TOWLOWER=0
23185 fi
23186 fi
23187 fi
23188
23189
23190 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_TOWLOWER = 1; then
23191 :
23192 fi
23193
23194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctype_t" >&5
23195 $as_echo_n "checking for wctype_t... " >&6; }
23196 if test "${gl_cv_type_wctype_t+set}" = set; then :
23197 $as_echo_n "(cached) " >&6
23198 else
23199 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23200 /* end confdefs.h. */
23201 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
23202 included before <wchar.h>.
23203 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
23204 must be included before <wchar.h>. */
23205 #include <stddef.h>
23206 #include <stdio.h>
23207 #include <time.h>
23208 #include <wchar.h>
23209 #if HAVE_WCTYPE_H
23210 # include <wctype.h>
23211 #endif
23212 wctype_t a;
23213
23214 int
23215 main ()
23216 {
23217
23218 ;
23219 return 0;
23220 }
23221 _ACEOF
23222 if ac_fn_c_try_compile "$LINENO"; then :
23223 gl_cv_type_wctype_t=yes
23224 else
23225 gl_cv_type_wctype_t=no
23226 fi
23227 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23228
23229 fi
23230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctype_t" >&5
23231 $as_echo "$gl_cv_type_wctype_t" >&6; }
23232 if test $gl_cv_type_wctype_t = no; then
23233 HAVE_WCTYPE_T=0
23234 fi
23235
23236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctrans_t" >&5
23237 $as_echo_n "checking for wctrans_t... " >&6; }
23238 if test "${gl_cv_type_wctrans_t+set}" = set; then :
23239 $as_echo_n "(cached) " >&6
23240 else
23241 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23242 /* end confdefs.h. */
23243 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
23244 included before <wchar.h>.
23245 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
23246 must be included before <wchar.h>. */
23247 #include <stddef.h>
23248 #include <stdio.h>
23249 #include <time.h>
23250 #include <wchar.h>
23251 #include <wctype.h>
23252 wctrans_t a;
23253
23254 int
23255 main ()
23256 {
23257
23258 ;
23259 return 0;
23260 }
23261 _ACEOF
23262 if ac_fn_c_try_compile "$LINENO"; then :
23263 gl_cv_type_wctrans_t=yes
23264 else
23265 gl_cv_type_wctrans_t=no
23266 fi
23267 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23268
23269 fi
23270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctrans_t" >&5
23271 $as_echo "$gl_cv_type_wctrans_t" >&6; }
23272 if test $gl_cv_type_wctrans_t = no; then
23273 HAVE_WCTRANS_T=0
23274 fi
23275
23276
23277 for gl_func in wctype iswctype wctrans towctrans ; do
23278 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
23279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
23280 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
23281 if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
23282 $as_echo_n "(cached) " >&6
23283 else
23284 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23285 /* end confdefs.h. */
23286
23287 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
23288 <wchar.h>.
23289 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
23290 included before <wchar.h>. */
23291 #if !(defined __GLIBC__ && !defined __UCLIBC__)
23292 # include <stddef.h>
23293 # include <stdio.h>
23294 # include <time.h>
23295 # include <wchar.h>
23296 #endif
23297 #include <wctype.h>
23298
23299 int
23300 main ()
23301 {
23302 #undef $gl_func
23303 (void) $gl_func;
23304 ;
23305 return 0;
23306 }
23307 _ACEOF
23308 if ac_fn_c_try_compile "$LINENO"; then :
23309 eval "$as_gl_Symbol=yes"
23310 else
23311 eval "$as_gl_Symbol=no"
23312 fi
23313 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23314 fi
23315 eval ac_res=\$$as_gl_Symbol
23316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
23317 $as_echo "$ac_res" >&6; }
23318 eval as_val=\$$as_gl_Symbol
23319 if test "x$as_val" = x""yes; then :
23320 cat >>confdefs.h <<_ACEOF
23321 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
23322 _ACEOF
23323
23324 eval ac_cv_have_decl_$gl_func=yes
23325 fi
23326 done
23327
23328
23329 # End of code from modules
23330
23331
23332
23333
23334
23335
23336
23337
23338
23339 gltests_libdeps=
23340 gltests_ltlibdeps=
23341
23342
23343
23344
23345
23346
23347
23348
23349
23350 gl_source_base='tests'
23351 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
23352
23353 gl_module_indicator_condition=$gltests_WITNESS
23354
23355
23356
23357
23358
23359
23360
23361
23362
23363 LIBGNU_LIBDEPS="$gl_libdeps"
23364
23365 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
23366
23367
23368
23369 # We don't use automake, but gnulib does. This line lets us generate
23370 # its Makefile.in.
23371 am__api_version='1.11'
23372
23373 # Find a good install program. We prefer a C program (faster),
23374 # so one script is as good as another. But avoid the broken or
23375 # incompatible versions:
23376 # SysV /etc/install, /usr/sbin/install
23377 # SunOS /usr/etc/install
23378 # IRIX /sbin/install
23379 # AIX /bin/install
23380 # AmigaOS /C/install, which installs bootblocks on floppy discs
23381 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
23382 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
23383 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
23384 # OS/2's system install, which has a completely different semantic
23385 # ./install, which can be erroneously created by make from ./install.sh.
23386 # Reject install programs that cannot install multiple files.
23387 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
23388 $as_echo_n "checking for a BSD-compatible install... " >&6; }
23389 if test -z "$INSTALL"; then
23390 if test "${ac_cv_path_install+set}" = set; then :
23391 $as_echo_n "(cached) " >&6
23392 else
23393 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23394 for as_dir in $PATH
23395 do
23396 IFS=$as_save_IFS
23397 test -z "$as_dir" && as_dir=.
23398 # Account for people who put trailing slashes in PATH elements.
23399 case $as_dir/ in #((
23400 ./ | .// | /[cC]/* | \
23401 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
23402 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
23403 /usr/ucb/* ) ;;
23404 *)
23405 # OSF1 and SCO ODT 3.0 have their own names for install.
23406 # Don't use installbsd from OSF since it installs stuff as root
23407 # by default.
23408 for ac_prog in ginstall scoinst install; do
23409 for ac_exec_ext in '' $ac_executable_extensions; do
23410 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
23411 if test $ac_prog = install &&
23412 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
23413 # AIX install. It has an incompatible calling convention.
23414 :
23415 elif test $ac_prog = install &&
23416 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
23417 # program-specific install script used by HP pwplus--don't use.
23418 :
23419 else
23420 rm -rf conftest.one conftest.two conftest.dir
23421 echo one > conftest.one
23422 echo two > conftest.two
23423 mkdir conftest.dir
23424 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
23425 test -s conftest.one && test -s conftest.two &&
23426 test -s conftest.dir/conftest.one &&
23427 test -s conftest.dir/conftest.two
23428 then
23429 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
23430 break 3
23431 fi
23432 fi
23433 fi
23434 done
23435 done
23436 ;;
23437 esac
23438
23439 done
23440 IFS=$as_save_IFS
23441
23442 rm -rf conftest.one conftest.two conftest.dir
23443
23444 fi
23445 if test "${ac_cv_path_install+set}" = set; then
23446 INSTALL=$ac_cv_path_install
23447 else
23448 # As a last resort, use the slow shell script. Don't cache a
23449 # value for INSTALL within a source directory, because that will
23450 # break other packages using the cache if that directory is
23451 # removed, or if the value is a relative name.
23452 INSTALL=$ac_install_sh
23453 fi
23454 fi
23455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
23456 $as_echo "$INSTALL" >&6; }
23457
23458 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
23459 # It thinks the first close brace ends the variable substitution.
23460 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
23461
23462 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
23463
23464 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
23465
23466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
23467 $as_echo_n "checking whether build environment is sane... " >&6; }
23468 # Just in case
23469 sleep 1
23470 echo timestamp > conftest.file
23471 # Reject unsafe characters in $srcdir or the absolute working directory
23472 # name. Accept space and tab only in the latter.
23473 am_lf='
23474 '
23475 case `pwd` in
23476 *[\\\"\#\$\&\'\`$am_lf]*)
23477 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
23478 esac
23479 case $srcdir in
23480 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
23481 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
23482 esac
23483
23484 # Do `set' in a subshell so we don't clobber the current shell's
23485 # arguments. Must try -L first in case configure is actually a
23486 # symlink; some systems play weird games with the mod time of symlinks
23487 # (eg FreeBSD returns the mod time of the symlink's containing
23488 # directory).
23489 if (
23490 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
23491 if test "$*" = "X"; then
23492 # -L didn't work.
23493 set X `ls -t "$srcdir/configure" conftest.file`
23494 fi
23495 rm -f conftest.file
23496 if test "$*" != "X $srcdir/configure conftest.file" \
23497 && test "$*" != "X conftest.file $srcdir/configure"; then
23498
23499 # If neither matched, then we have a broken ls. This can happen
23500 # if, for instance, CONFIG_SHELL is bash and it inherits a
23501 # broken ls alias from the environment. This has actually
23502 # happened. Such a system could not be considered "sane".
23503 as_fn_error "ls -t appears to fail. Make sure there is not a broken
23504 alias in your environment" "$LINENO" 5
23505 fi
23506
23507 test "$2" = conftest.file
23508 )
23509 then
23510 # Ok.
23511 :
23512 else
23513 as_fn_error "newly created file is older than distributed files!
23514 Check your system clock" "$LINENO" 5
23515 fi
23516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
23517 $as_echo "yes" >&6; }
23518 test "$program_prefix" != NONE &&
23519 program_transform_name="s&^&$program_prefix&;$program_transform_name"
23520 # Use a double $ so make ignores it.
23521 test "$program_suffix" != NONE &&
23522 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
23523 # Double any \ or $.
23524 # By default was `s,x,x', remove it if useless.
23525 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
23526 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
23527
23528 # expand $ac_aux_dir to an absolute path
23529 am_aux_dir=`cd $ac_aux_dir && pwd`
23530
23531 if test x"${MISSING+set}" != xset; then
23532 case $am_aux_dir in
23533 *\ * | *\ *)
23534 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
23535 *)
23536 MISSING="\${SHELL} $am_aux_dir/missing" ;;
23537 esac
23538 fi
23539 # Use eval to expand $SHELL
23540 if eval "$MISSING --run true"; then
23541 am_missing_run="$MISSING --run "
23542 else
23543 am_missing_run=
23544 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
23545 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
23546 fi
23547
23548 if test x"${install_sh}" != xset; then
23549 case $am_aux_dir in
23550 *\ * | *\ *)
23551 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
23552 *)
23553 install_sh="\${SHELL} $am_aux_dir/install-sh"
23554 esac
23555 fi
23556
23557 # Installed binaries are usually stripped using `strip' when the user
23558 # run `make install-strip'. However `strip' might not be the right
23559 # tool to use in cross-compilation environments, therefore Automake
23560 # will honor the `STRIP' environment variable to overrule this program.
23561 if test "$cross_compiling" != no; then
23562 if test -n "$ac_tool_prefix"; then
23563 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
23564 set dummy ${ac_tool_prefix}strip; ac_word=$2
23565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
23566 $as_echo_n "checking for $ac_word... " >&6; }
23567 if test "${ac_cv_prog_STRIP+set}" = set; then :
23568 $as_echo_n "(cached) " >&6
23569 else
23570 if test -n "$STRIP"; then
23571 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
23572 else
23573 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23574 for as_dir in $PATH
23575 do
23576 IFS=$as_save_IFS
23577 test -z "$as_dir" && as_dir=.
23578 for ac_exec_ext in '' $ac_executable_extensions; do
23579 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
23580 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
23581 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
23582 break 2
23583 fi
23584 done
23585 done
23586 IFS=$as_save_IFS
23587
23588 fi
23589 fi
23590 STRIP=$ac_cv_prog_STRIP
23591 if test -n "$STRIP"; then
23592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
23593 $as_echo "$STRIP" >&6; }
23594 else
23595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23596 $as_echo "no" >&6; }
23597 fi
23598
23599
23600 fi
23601 if test -z "$ac_cv_prog_STRIP"; then
23602 ac_ct_STRIP=$STRIP
23603 # Extract the first word of "strip", so it can be a program name with args.
23604 set dummy strip; ac_word=$2
23605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
23606 $as_echo_n "checking for $ac_word... " >&6; }
23607 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
23608 $as_echo_n "(cached) " >&6
23609 else
23610 if test -n "$ac_ct_STRIP"; then
23611 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
23612 else
23613 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23614 for as_dir in $PATH
23615 do
23616 IFS=$as_save_IFS
23617 test -z "$as_dir" && as_dir=.
23618 for ac_exec_ext in '' $ac_executable_extensions; do
23619 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
23620 ac_cv_prog_ac_ct_STRIP="strip"
23621 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
23622 break 2
23623 fi
23624 done
23625 done
23626 IFS=$as_save_IFS
23627
23628 fi
23629 fi
23630 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
23631 if test -n "$ac_ct_STRIP"; then
23632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
23633 $as_echo "$ac_ct_STRIP" >&6; }
23634 else
23635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23636 $as_echo "no" >&6; }
23637 fi
23638
23639 if test "x$ac_ct_STRIP" = x; then
23640 STRIP=":"
23641 else
23642 case $cross_compiling:$ac_tool_warned in
23643 yes:)
23644 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
23645 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
23646 ac_tool_warned=yes ;;
23647 esac
23648 STRIP=$ac_ct_STRIP
23649 fi
23650 else
23651 STRIP="$ac_cv_prog_STRIP"
23652 fi
23653
23654 fi
23655 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
23656
23657 mkdir_p="$MKDIR_P"
23658 case $mkdir_p in
23659 [\\/$]* | ?:[\\/]*) ;;
23660 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
23661 esac
23662
23663 for ac_prog in gawk mawk nawk awk
23664 do
23665 # Extract the first word of "$ac_prog", so it can be a program name with args.
23666 set dummy $ac_prog; ac_word=$2
23667 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
23668 $as_echo_n "checking for $ac_word... " >&6; }
23669 if test "${ac_cv_prog_AWK+set}" = set; then :
23670 $as_echo_n "(cached) " >&6
23671 else
23672 if test -n "$AWK"; then
23673 ac_cv_prog_AWK="$AWK" # Let the user override the test.
23674 else
23675 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23676 for as_dir in $PATH
23677 do
23678 IFS=$as_save_IFS
23679 test -z "$as_dir" && as_dir=.
23680 for ac_exec_ext in '' $ac_executable_extensions; do
23681 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
23682 ac_cv_prog_AWK="$ac_prog"
23683 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
23684 break 2
23685 fi
23686 done
23687 done
23688 IFS=$as_save_IFS
23689
23690 fi
23691 fi
23692 AWK=$ac_cv_prog_AWK
23693 if test -n "$AWK"; then
23694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
23695 $as_echo "$AWK" >&6; }
23696 else
23697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23698 $as_echo "no" >&6; }
23699 fi
23700
23701
23702 test -n "$AWK" && break
23703 done
23704
23705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
23706 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
23707 set x ${MAKE-make}
23708 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
23709 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
23710 $as_echo_n "(cached) " >&6
23711 else
23712 cat >conftest.make <<\_ACEOF
23713 SHELL = /bin/sh
23714 all:
23715 @echo '@@@%%%=$(MAKE)=@@@%%%'
23716 _ACEOF
23717 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
23718 case `${MAKE-make} -f conftest.make 2>/dev/null` in
23719 *@@@%%%=?*=@@@%%%*)
23720 eval ac_cv_prog_make_${ac_make}_set=yes;;
23721 *)
23722 eval ac_cv_prog_make_${ac_make}_set=no;;
23723 esac
23724 rm -f conftest.make
23725 fi
23726 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
23727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
23728 $as_echo "yes" >&6; }
23729 SET_MAKE=
23730 else
23731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23732 $as_echo "no" >&6; }
23733 SET_MAKE="MAKE=${MAKE-make}"
23734 fi
23735
23736 rm -rf .tst 2>/dev/null
23737 mkdir .tst 2>/dev/null
23738 if test -d .tst; then
23739 am__leading_dot=.
23740 else
23741 am__leading_dot=_
23742 fi
23743 rmdir .tst 2>/dev/null
23744
23745 DEPDIR="${am__leading_dot}deps"
23746
23747 ac_config_commands="$ac_config_commands depfiles"
23748
23749
23750 am_make=${MAKE-make}
23751 cat > confinc << 'END'
23752 am__doit:
23753 @echo this is the am__doit target
23754 .PHONY: am__doit
23755 END
23756 # If we don't find an include directive, just comment out the code.
23757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
23758 $as_echo_n "checking for style of include used by $am_make... " >&6; }
23759 am__include="#"
23760 am__quote=
23761 _am_result=none
23762 # First try GNU make style include.
23763 echo "include confinc" > confmf
23764 # Ignore all kinds of additional output from `make'.
23765 case `$am_make -s -f confmf 2> /dev/null` in #(
23766 *the\ am__doit\ target*)
23767 am__include=include
23768 am__quote=
23769 _am_result=GNU
23770 ;;
23771 esac
23772 # Now try BSD make style include.
23773 if test "$am__include" = "#"; then
23774 echo '.include "confinc"' > confmf
23775 case `$am_make -s -f confmf 2> /dev/null` in #(
23776 *the\ am__doit\ target*)
23777 am__include=.include
23778 am__quote="\""
23779 _am_result=BSD
23780 ;;
23781 esac
23782 fi
23783
23784
23785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
23786 $as_echo "$_am_result" >&6; }
23787 rm -f confinc confmf
23788
23789 # Check whether --enable-dependency-tracking was given.
23790 if test "${enable_dependency_tracking+set}" = set; then :
23791 enableval=$enable_dependency_tracking;
23792 fi
23793
23794 if test "x$enable_dependency_tracking" != xno; then
23795 am_depcomp="$ac_aux_dir/depcomp"
23796 AMDEPBACKSLASH='\'
23797 fi
23798 if test "x$enable_dependency_tracking" != xno; then
23799 AMDEP_TRUE=
23800 AMDEP_FALSE='#'
23801 else
23802 AMDEP_TRUE='#'
23803 AMDEP_FALSE=
23804 fi
23805
23806
23807 if test "`cd $srcdir && pwd`" != "`pwd`"; then
23808 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
23809 # is not polluted with repeated "-I."
23810 am__isrc=' -I$(srcdir)'
23811 # test to see if srcdir already configured
23812 if test -f $srcdir/config.status; then
23813 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
23814 fi
23815 fi
23816
23817 # test whether we have cygpath
23818 if test -z "$CYGPATH_W"; then
23819 if (cygpath --version) >/dev/null 2>/dev/null; then
23820 CYGPATH_W='cygpath -w'
23821 else
23822 CYGPATH_W=echo
23823 fi
23824 fi
23825
23826
23827 # Define the identity of the package.
23828 PACKAGE=libgnu
23829 VERSION=UNUSED-VERSION
23830
23831
23832 # Some tools Automake needs.
23833
23834 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
23835
23836
23837 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
23838
23839
23840 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
23841
23842
23843 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
23844
23845
23846 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
23847
23848 # We need awk for the "check" target. The system "awk" is bad on
23849 # some platforms.
23850 # Always define AMTAR for backward compatibility.
23851
23852 AMTAR=${AMTAR-"${am_missing_run}tar"}
23853
23854 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
23855
23856
23857
23858
23859 depcc="$CC" am_compiler_list=
23860
23861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
23862 $as_echo_n "checking dependency style of $depcc... " >&6; }
23863 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
23864 $as_echo_n "(cached) " >&6
23865 else
23866 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
23867 # We make a subdir and do the tests there. Otherwise we can end up
23868 # making bogus files that we don't know about and never remove. For
23869 # instance it was reported that on HP-UX the gcc test will end up
23870 # making a dummy file named `D' -- because `-MD' means `put the output
23871 # in D'.
23872 mkdir conftest.dir
23873 # Copy depcomp to subdir because otherwise we won't find it if we're
23874 # using a relative directory.
23875 cp "$am_depcomp" conftest.dir
23876 cd conftest.dir
23877 # We will build objects and dependencies in a subdirectory because
23878 # it helps to detect inapplicable dependency modes. For instance
23879 # both Tru64's cc and ICC support -MD to output dependencies as a
23880 # side effect of compilation, but ICC will put the dependencies in
23881 # the current directory while Tru64 will put them in the object
23882 # directory.
23883 mkdir sub
23884
23885 am_cv_CC_dependencies_compiler_type=none
23886 if test "$am_compiler_list" = ""; then
23887 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
23888 fi
23889 am__universal=false
23890 case " $depcc " in #(
23891 *\ -arch\ *\ -arch\ *) am__universal=true ;;
23892 esac
23893
23894 for depmode in $am_compiler_list; do
23895 # Setup a source with many dependencies, because some compilers
23896 # like to wrap large dependency lists on column 80 (with \), and
23897 # we should not choose a depcomp mode which is confused by this.
23898 #
23899 # We need to recreate these files for each test, as the compiler may
23900 # overwrite some of them when testing with obscure command lines.
23901 # This happens at least with the AIX C compiler.
23902 : > sub/conftest.c
23903 for i in 1 2 3 4 5 6; do
23904 echo '#include "conftst'$i'.h"' >> sub/conftest.c
23905 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
23906 # Solaris 8's {/usr,}/bin/sh.
23907 touch sub/conftst$i.h
23908 done
23909 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
23910
23911 # We check with `-c' and `-o' for the sake of the "dashmstdout"
23912 # mode. It turns out that the SunPro C++ compiler does not properly
23913 # handle `-M -o', and we need to detect this. Also, some Intel
23914 # versions had trouble with output in subdirs
23915 am__obj=sub/conftest.${OBJEXT-o}
23916 am__minus_obj="-o $am__obj"
23917 case $depmode in
23918 gcc)
23919 # This depmode causes a compiler race in universal mode.
23920 test "$am__universal" = false || continue
23921 ;;
23922 nosideeffect)
23923 # after this tag, mechanisms are not by side-effect, so they'll
23924 # only be used when explicitly requested
23925 if test "x$enable_dependency_tracking" = xyes; then
23926 continue
23927 else
23928 break
23929 fi
23930 ;;
23931 msvisualcpp | msvcmsys)
23932 # This compiler won't grok `-c -o', but also, the minuso test has
23933 # not run yet. These depmodes are late enough in the game, and
23934 # so weak that their functioning should not be impacted.
23935 am__obj=conftest.${OBJEXT-o}
23936 am__minus_obj=
23937 ;;
23938 none) break ;;
23939 esac
23940 if depmode=$depmode \
23941 source=sub/conftest.c object=$am__obj \
23942 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
23943 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
23944 >/dev/null 2>conftest.err &&
23945 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
23946 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
23947 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
23948 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
23949 # icc doesn't choke on unknown options, it will just issue warnings
23950 # or remarks (even with -Werror). So we grep stderr for any message
23951 # that says an option was ignored or not supported.
23952 # When given -MP, icc 7.0 and 7.1 complain thusly:
23953 # icc: Command line warning: ignoring option '-M'; no argument required
23954 # The diagnosis changed in icc 8.0:
23955 # icc: Command line remark: option '-MP' not supported
23956 if (grep 'ignoring option' conftest.err ||
23957 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
23958 am_cv_CC_dependencies_compiler_type=$depmode
23959 break
23960 fi
23961 fi
23962 done
23963
23964 cd ..
23965 rm -rf conftest.dir
23966 else
23967 am_cv_CC_dependencies_compiler_type=none
23968 fi
23969
23970 fi
23971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
23972 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
23973 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
23974
23975 if
23976 test "x$enable_dependency_tracking" != xno \
23977 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
23978 am__fastdepCC_TRUE=
23979 am__fastdepCC_FALSE='#'
23980 else
23981 am__fastdepCC_TRUE='#'
23982 am__fastdepCC_FALSE=
23983 fi
23984
23985
23986
23987
23988 # Check whether --enable-silent-rules was given.
23989 if test "${enable_silent_rules+set}" = set; then :
23990 enableval=$enable_silent_rules;
23991 fi
23992
23993 case $enable_silent_rules in
23994 yes) AM_DEFAULT_VERBOSITY=0;;
23995 no) AM_DEFAULT_VERBOSITY=1;;
23996 *) AM_DEFAULT_VERBOSITY=0;;
23997 esac
23998 AM_BACKSLASH='\'
23999
24000
24001 # --------------------- #
24002 # Checks for programs. #
24003 # --------------------- #
24004
24005
24006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
24007 $as_echo_n "checking whether ln -s works... " >&6; }
24008 LN_S=$as_ln_s
24009 if test "$LN_S" = "ln -s"; then
24010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
24011 $as_echo "yes" >&6; }
24012 else
24013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
24014 $as_echo "no, using $LN_S" >&6; }
24015 fi
24016
24017 if test -n "$ac_tool_prefix"; then
24018 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
24019 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
24020 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24021 $as_echo_n "checking for $ac_word... " >&6; }
24022 if test "${ac_cv_prog_RANLIB+set}" = set; then :
24023 $as_echo_n "(cached) " >&6
24024 else
24025 if test -n "$RANLIB"; then
24026 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
24027 else
24028 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24029 for as_dir in $PATH
24030 do
24031 IFS=$as_save_IFS
24032 test -z "$as_dir" && as_dir=.
24033 for ac_exec_ext in '' $ac_executable_extensions; do
24034 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
24035 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
24036 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24037 break 2
24038 fi
24039 done
24040 done
24041 IFS=$as_save_IFS
24042
24043 fi
24044 fi
24045 RANLIB=$ac_cv_prog_RANLIB
24046 if test -n "$RANLIB"; then
24047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
24048 $as_echo "$RANLIB" >&6; }
24049 else
24050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24051 $as_echo "no" >&6; }
24052 fi
24053
24054
24055 fi
24056 if test -z "$ac_cv_prog_RANLIB"; then
24057 ac_ct_RANLIB=$RANLIB
24058 # Extract the first word of "ranlib", so it can be a program name with args.
24059 set dummy ranlib; ac_word=$2
24060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24061 $as_echo_n "checking for $ac_word... " >&6; }
24062 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
24063 $as_echo_n "(cached) " >&6
24064 else
24065 if test -n "$ac_ct_RANLIB"; then
24066 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
24067 else
24068 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24069 for as_dir in $PATH
24070 do
24071 IFS=$as_save_IFS
24072 test -z "$as_dir" && as_dir=.
24073 for ac_exec_ext in '' $ac_executable_extensions; do
24074 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
24075 ac_cv_prog_ac_ct_RANLIB="ranlib"
24076 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24077 break 2
24078 fi
24079 done
24080 done
24081 IFS=$as_save_IFS
24082
24083 fi
24084 fi
24085 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
24086 if test -n "$ac_ct_RANLIB"; then
24087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
24088 $as_echo "$ac_ct_RANLIB" >&6; }
24089 else
24090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24091 $as_echo "no" >&6; }
24092 fi
24093
24094 if test "x$ac_ct_RANLIB" = x; then
24095 RANLIB=":"
24096 else
24097 case $cross_compiling:$ac_tool_warned in
24098 yes:)
24099 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
24100 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
24101 ac_tool_warned=yes ;;
24102 esac
24103 RANLIB=$ac_ct_RANLIB
24104 fi
24105 else
24106 RANLIB="$ac_cv_prog_RANLIB"
24107 fi
24108
24109
24110 if test -n "$ac_tool_prefix"; then
24111 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
24112 set dummy ${ac_tool_prefix}ar; ac_word=$2
24113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24114 $as_echo_n "checking for $ac_word... " >&6; }
24115 if test "${ac_cv_prog_AR+set}" = set; then :
24116 $as_echo_n "(cached) " >&6
24117 else
24118 if test -n "$AR"; then
24119 ac_cv_prog_AR="$AR" # Let the user override the test.
24120 else
24121 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24122 for as_dir in $PATH
24123 do
24124 IFS=$as_save_IFS
24125 test -z "$as_dir" && as_dir=.
24126 for ac_exec_ext in '' $ac_executable_extensions; do
24127 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
24128 ac_cv_prog_AR="${ac_tool_prefix}ar"
24129 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24130 break 2
24131 fi
24132 done
24133 done
24134 IFS=$as_save_IFS
24135
24136 fi
24137 fi
24138 AR=$ac_cv_prog_AR
24139 if test -n "$AR"; then
24140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
24141 $as_echo "$AR" >&6; }
24142 else
24143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24144 $as_echo "no" >&6; }
24145 fi
24146
24147
24148 fi
24149 if test -z "$ac_cv_prog_AR"; then
24150 ac_ct_AR=$AR
24151 # Extract the first word of "ar", so it can be a program name with args.
24152 set dummy ar; ac_word=$2
24153 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24154 $as_echo_n "checking for $ac_word... " >&6; }
24155 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
24156 $as_echo_n "(cached) " >&6
24157 else
24158 if test -n "$ac_ct_AR"; then
24159 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
24160 else
24161 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24162 for as_dir in $PATH
24163 do
24164 IFS=$as_save_IFS
24165 test -z "$as_dir" && as_dir=.
24166 for ac_exec_ext in '' $ac_executable_extensions; do
24167 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
24168 ac_cv_prog_ac_ct_AR="ar"
24169 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24170 break 2
24171 fi
24172 done
24173 done
24174 IFS=$as_save_IFS
24175
24176 fi
24177 fi
24178 ac_ct_AR=$ac_cv_prog_ac_ct_AR
24179 if test -n "$ac_ct_AR"; then
24180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
24181 $as_echo "$ac_ct_AR" >&6; }
24182 else
24183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24184 $as_echo "no" >&6; }
24185 fi
24186
24187 if test "x$ac_ct_AR" = x; then
24188 AR=""
24189 else
24190 case $cross_compiling:$ac_tool_warned in
24191 yes:)
24192 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
24193 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
24194 ac_tool_warned=yes ;;
24195 esac
24196 AR=$ac_ct_AR
24197 fi
24198 else
24199 AR="$ac_cv_prog_AR"
24200 fi
24201
24202
24203 # ---------------------- #
24204 # Checks for libraries. #
24205 # ---------------------- #
24206
24207 ac_config_files="$ac_config_files Makefile import/Makefile"
24208
24209 ac_config_commands="$ac_config_commands default"
24210
24211 cat >confcache <<\_ACEOF
24212 # This file is a shell script that caches the results of configure
24213 # tests run on this system so they can be shared between configure
24214 # scripts and configure runs, see configure's option --config-cache.
24215 # It is not useful on other systems. If it contains results you don't
24216 # want to keep, you may remove or edit it.
24217 #
24218 # config.status only pays attention to the cache file if you give it
24219 # the --recheck option to rerun configure.
24220 #
24221 # `ac_cv_env_foo' variables (set or unset) will be overridden when
24222 # loading this file, other *unset* `ac_cv_foo' will be assigned the
24223 # following values.
24224
24225 _ACEOF
24226
24227 # The following way of writing the cache mishandles newlines in values,
24228 # but we know of no workaround that is simple, portable, and efficient.
24229 # So, we kill variables containing newlines.
24230 # Ultrix sh set writes to stderr and can't be redirected directly,
24231 # and sets the high bit in the cache file unless we assign to the vars.
24232 (
24233 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
24234 eval ac_val=\$$ac_var
24235 case $ac_val in #(
24236 *${as_nl}*)
24237 case $ac_var in #(
24238 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
24239 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
24240 esac
24241 case $ac_var in #(
24242 _ | IFS | as_nl) ;; #(
24243 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
24244 *) { eval $ac_var=; unset $ac_var;} ;;
24245 esac ;;
24246 esac
24247 done
24248
24249 (set) 2>&1 |
24250 case $as_nl`(ac_space=' '; set) 2>&1` in #(
24251 *${as_nl}ac_space=\ *)
24252 # `set' does not quote correctly, so add quotes: double-quote
24253 # substitution turns \\\\ into \\, and sed turns \\ into \.
24254 sed -n \
24255 "s/'/'\\\\''/g;
24256 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
24257 ;; #(
24258 *)
24259 # `set' quotes correctly as required by POSIX, so do not add quotes.
24260 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
24261 ;;
24262 esac |
24263 sort
24264 ) |
24265 sed '
24266 /^ac_cv_env_/b end
24267 t clear
24268 :clear
24269 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
24270 t end
24271 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
24272 :end' >>confcache
24273 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
24274 if test -w "$cache_file"; then
24275 test "x$cache_file" != "x/dev/null" &&
24276 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
24277 $as_echo "$as_me: updating cache $cache_file" >&6;}
24278 cat confcache >$cache_file
24279 else
24280 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
24281 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
24282 fi
24283 fi
24284 rm -f confcache
24285
24286 test "x$prefix" = xNONE && prefix=$ac_default_prefix
24287 # Let make expand exec_prefix.
24288 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
24289
24290 DEFS=-DHAVE_CONFIG_H
24291
24292 ac_libobjs=
24293 ac_ltlibobjs=
24294 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
24295 # 1. Remove the extension, and $U if already installed.
24296 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
24297 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
24298 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
24299 # will be set to the directory where LIBOBJS objects are built.
24300 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
24301 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
24302 done
24303 LIBOBJS=$ac_libobjs
24304
24305 LTLIBOBJS=$ac_ltlibobjs
24306
24307
24308 if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
24309 as_fn_error "conditional \"MAINTAINER_MODE\" was never defined.
24310 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24311 fi
24312 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
24313 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
24314 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24315 fi
24316 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
24317 as_fn_error "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
24318 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24319 fi
24320 if test -z "${GL_GENERATE_ERRNO_H_TRUE}" && test -z "${GL_GENERATE_ERRNO_H_FALSE}"; then
24321 as_fn_error "conditional \"GL_GENERATE_ERRNO_H\" was never defined.
24322 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24323 fi
24324 if test -z "${GL_GENERATE_FLOAT_H_TRUE}" && test -z "${GL_GENERATE_FLOAT_H_FALSE}"; then
24325 as_fn_error "conditional \"GL_GENERATE_FLOAT_H\" was never defined.
24326 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24327 fi
24328 if test -z "${GL_GENERATE_FNMATCH_H_TRUE}" && test -z "${GL_GENERATE_FNMATCH_H_FALSE}"; then
24329 as_fn_error "conditional \"GL_GENERATE_FNMATCH_H\" was never defined.
24330 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24331 fi
24332 if test -z "${GL_GENERATE_GLOB_H_TRUE}" && test -z "${GL_GENERATE_GLOB_H_FALSE}"; then
24333 as_fn_error "conditional \"GL_GENERATE_GLOB_H\" was never defined.
24334 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24335 fi
24336 if test -z "${GL_GENERATE_LIMITS_H_TRUE}" && test -z "${GL_GENERATE_LIMITS_H_FALSE}"; then
24337 as_fn_error "conditional \"GL_GENERATE_LIMITS_H\" was never defined.
24338 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24339 fi
24340 if test -z "${GL_GENERATE_LIMITS_H_TRUE}" && test -z "${GL_GENERATE_LIMITS_H_FALSE}"; then
24341 as_fn_error "conditional \"GL_GENERATE_LIMITS_H\" was never defined.
24342 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24343 fi
24344 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
24345 as_fn_error "conditional \"GL_GENERATE_STDINT_H\" was never defined.
24346 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24347 fi
24348
24349
24350 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
24351 as_fn_error "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
24352 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24353 fi
24354 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
24355 as_fn_error "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
24356 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24357 fi
24358
24359 gl_libobjs=
24360 gl_ltlibobjs=
24361 if test -n "$gl_LIBOBJS"; then
24362 # Remove the extension.
24363 sed_drop_objext='s/\.o$//;s/\.obj$//'
24364 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
24365 gl_libobjs="$gl_libobjs $i.$ac_objext"
24366 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
24367 done
24368 fi
24369 gl_LIBOBJS=$gl_libobjs
24370
24371 gl_LTLIBOBJS=$gl_ltlibobjs
24372
24373
24374
24375 gltests_libobjs=
24376 gltests_ltlibobjs=
24377 if test -n "$gltests_LIBOBJS"; then
24378 # Remove the extension.
24379 sed_drop_objext='s/\.o$//;s/\.obj$//'
24380 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
24381 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
24382 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
24383 done
24384 fi
24385 gltests_LIBOBJS=$gltests_libobjs
24386
24387 gltests_LTLIBOBJS=$gltests_ltlibobjs
24388
24389
24390 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
24391 as_fn_error "conditional \"AMDEP\" was never defined.
24392 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24393 fi
24394 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
24395 as_fn_error "conditional \"am__fastdepCC\" was never defined.
24396 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24397 fi
24398 if test -n "$EXEEXT"; then
24399 am__EXEEXT_TRUE=
24400 am__EXEEXT_FALSE='#'
24401 else
24402 am__EXEEXT_TRUE='#'
24403 am__EXEEXT_FALSE=
24404 fi
24405
24406
24407 : ${CONFIG_STATUS=./config.status}
24408 ac_write_fail=0
24409 ac_clean_files_save=$ac_clean_files
24410 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
24411 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
24412 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
24413 as_write_fail=0
24414 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
24415 #! $SHELL
24416 # Generated by $as_me.
24417 # Run this file to recreate the current configuration.
24418 # Compiler output produced by configure, useful for debugging
24419 # configure, is in config.log if it exists.
24420
24421 debug=false
24422 ac_cs_recheck=false
24423 ac_cs_silent=false
24424
24425 SHELL=\${CONFIG_SHELL-$SHELL}
24426 export SHELL
24427 _ASEOF
24428 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
24429 ## -------------------- ##
24430 ## M4sh Initialization. ##
24431 ## -------------------- ##
24432
24433 # Be more Bourne compatible
24434 DUALCASE=1; export DUALCASE # for MKS sh
24435 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
24436 emulate sh
24437 NULLCMD=:
24438 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
24439 # is contrary to our usage. Disable this feature.
24440 alias -g '${1+"$@"}'='"$@"'
24441 setopt NO_GLOB_SUBST
24442 else
24443 case `(set -o) 2>/dev/null` in #(
24444 *posix*) :
24445 set -o posix ;; #(
24446 *) :
24447 ;;
24448 esac
24449 fi
24450
24451
24452 as_nl='
24453 '
24454 export as_nl
24455 # Printing a long string crashes Solaris 7 /usr/bin/printf.
24456 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
24457 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
24458 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
24459 # Prefer a ksh shell builtin over an external printf program on Solaris,
24460 # but without wasting forks for bash or zsh.
24461 if test -z "$BASH_VERSION$ZSH_VERSION" \
24462 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
24463 as_echo='print -r --'
24464 as_echo_n='print -rn --'
24465 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
24466 as_echo='printf %s\n'
24467 as_echo_n='printf %s'
24468 else
24469 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
24470 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
24471 as_echo_n='/usr/ucb/echo -n'
24472 else
24473 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
24474 as_echo_n_body='eval
24475 arg=$1;
24476 case $arg in #(
24477 *"$as_nl"*)
24478 expr "X$arg" : "X\\(.*\\)$as_nl";
24479 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
24480 esac;
24481 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
24482 '
24483 export as_echo_n_body
24484 as_echo_n='sh -c $as_echo_n_body as_echo'
24485 fi
24486 export as_echo_body
24487 as_echo='sh -c $as_echo_body as_echo'
24488 fi
24489
24490 # The user is always right.
24491 if test "${PATH_SEPARATOR+set}" != set; then
24492 PATH_SEPARATOR=:
24493 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
24494 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
24495 PATH_SEPARATOR=';'
24496 }
24497 fi
24498
24499
24500 # IFS
24501 # We need space, tab and new line, in precisely that order. Quoting is
24502 # there to prevent editors from complaining about space-tab.
24503 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
24504 # splitting by setting IFS to empty value.)
24505 IFS=" "" $as_nl"
24506
24507 # Find who we are. Look in the path if we contain no directory separator.
24508 case $0 in #((
24509 *[\\/]* ) as_myself=$0 ;;
24510 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24511 for as_dir in $PATH
24512 do
24513 IFS=$as_save_IFS
24514 test -z "$as_dir" && as_dir=.
24515 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
24516 done
24517 IFS=$as_save_IFS
24518
24519 ;;
24520 esac
24521 # We did not find ourselves, most probably we were run as `sh COMMAND'
24522 # in which case we are not to be found in the path.
24523 if test "x$as_myself" = x; then
24524 as_myself=$0
24525 fi
24526 if test ! -f "$as_myself"; then
24527 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
24528 exit 1
24529 fi
24530
24531 # Unset variables that we do not need and which cause bugs (e.g. in
24532 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
24533 # suppresses any "Segmentation fault" message there. '((' could
24534 # trigger a bug in pdksh 5.2.14.
24535 for as_var in BASH_ENV ENV MAIL MAILPATH
24536 do eval test x\${$as_var+set} = xset \
24537 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
24538 done
24539 PS1='$ '
24540 PS2='> '
24541 PS4='+ '
24542
24543 # NLS nuisances.
24544 LC_ALL=C
24545 export LC_ALL
24546 LANGUAGE=C
24547 export LANGUAGE
24548
24549 # CDPATH.
24550 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
24551
24552
24553 # as_fn_error ERROR [LINENO LOG_FD]
24554 # ---------------------------------
24555 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
24556 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
24557 # script with status $?, using 1 if that was 0.
24558 as_fn_error ()
24559 {
24560 as_status=$?; test $as_status -eq 0 && as_status=1
24561 if test "$3"; then
24562 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
24563 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
24564 fi
24565 $as_echo "$as_me: error: $1" >&2
24566 as_fn_exit $as_status
24567 } # as_fn_error
24568
24569
24570 # as_fn_set_status STATUS
24571 # -----------------------
24572 # Set $? to STATUS, without forking.
24573 as_fn_set_status ()
24574 {
24575 return $1
24576 } # as_fn_set_status
24577
24578 # as_fn_exit STATUS
24579 # -----------------
24580 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
24581 as_fn_exit ()
24582 {
24583 set +e
24584 as_fn_set_status $1
24585 exit $1
24586 } # as_fn_exit
24587
24588 # as_fn_unset VAR
24589 # ---------------
24590 # Portably unset VAR.
24591 as_fn_unset ()
24592 {
24593 { eval $1=; unset $1;}
24594 }
24595 as_unset=as_fn_unset
24596 # as_fn_append VAR VALUE
24597 # ----------------------
24598 # Append the text in VALUE to the end of the definition contained in VAR. Take
24599 # advantage of any shell optimizations that allow amortized linear growth over
24600 # repeated appends, instead of the typical quadratic growth present in naive
24601 # implementations.
24602 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
24603 eval 'as_fn_append ()
24604 {
24605 eval $1+=\$2
24606 }'
24607 else
24608 as_fn_append ()
24609 {
24610 eval $1=\$$1\$2
24611 }
24612 fi # as_fn_append
24613
24614 # as_fn_arith ARG...
24615 # ------------------
24616 # Perform arithmetic evaluation on the ARGs, and store the result in the
24617 # global $as_val. Take advantage of shells that can avoid forks. The arguments
24618 # must be portable across $(()) and expr.
24619 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
24620 eval 'as_fn_arith ()
24621 {
24622 as_val=$(( $* ))
24623 }'
24624 else
24625 as_fn_arith ()
24626 {
24627 as_val=`expr "$@" || test $? -eq 1`
24628 }
24629 fi # as_fn_arith
24630
24631
24632 if expr a : '\(a\)' >/dev/null 2>&1 &&
24633 test "X`expr 00001 : '.*\(...\)'`" = X001; then
24634 as_expr=expr
24635 else
24636 as_expr=false
24637 fi
24638
24639 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
24640 as_basename=basename
24641 else
24642 as_basename=false
24643 fi
24644
24645 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
24646 as_dirname=dirname
24647 else
24648 as_dirname=false
24649 fi
24650
24651 as_me=`$as_basename -- "$0" ||
24652 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
24653 X"$0" : 'X\(//\)$' \| \
24654 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
24655 $as_echo X/"$0" |
24656 sed '/^.*\/\([^/][^/]*\)\/*$/{
24657 s//\1/
24658 q
24659 }
24660 /^X\/\(\/\/\)$/{
24661 s//\1/
24662 q
24663 }
24664 /^X\/\(\/\).*/{
24665 s//\1/
24666 q
24667 }
24668 s/.*/./; q'`
24669
24670 # Avoid depending upon Character Ranges.
24671 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
24672 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
24673 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
24674 as_cr_digits='0123456789'
24675 as_cr_alnum=$as_cr_Letters$as_cr_digits
24676
24677 ECHO_C= ECHO_N= ECHO_T=
24678 case `echo -n x` in #(((((
24679 -n*)
24680 case `echo 'xy\c'` in
24681 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
24682 xy) ECHO_C='\c';;
24683 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
24684 ECHO_T=' ';;
24685 esac;;
24686 *)
24687 ECHO_N='-n';;
24688 esac
24689
24690 rm -f conf$$ conf$$.exe conf$$.file
24691 if test -d conf$$.dir; then
24692 rm -f conf$$.dir/conf$$.file
24693 else
24694 rm -f conf$$.dir
24695 mkdir conf$$.dir 2>/dev/null
24696 fi
24697 if (echo >conf$$.file) 2>/dev/null; then
24698 if ln -s conf$$.file conf$$ 2>/dev/null; then
24699 as_ln_s='ln -s'
24700 # ... but there are two gotchas:
24701 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
24702 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
24703 # In both cases, we have to default to `cp -p'.
24704 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
24705 as_ln_s='cp -p'
24706 elif ln conf$$.file conf$$ 2>/dev/null; then
24707 as_ln_s=ln
24708 else
24709 as_ln_s='cp -p'
24710 fi
24711 else
24712 as_ln_s='cp -p'
24713 fi
24714 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
24715 rmdir conf$$.dir 2>/dev/null
24716
24717
24718 # as_fn_mkdir_p
24719 # -------------
24720 # Create "$as_dir" as a directory, including parents if necessary.
24721 as_fn_mkdir_p ()
24722 {
24723
24724 case $as_dir in #(
24725 -*) as_dir=./$as_dir;;
24726 esac
24727 test -d "$as_dir" || eval $as_mkdir_p || {
24728 as_dirs=
24729 while :; do
24730 case $as_dir in #(
24731 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
24732 *) as_qdir=$as_dir;;
24733 esac
24734 as_dirs="'$as_qdir' $as_dirs"
24735 as_dir=`$as_dirname -- "$as_dir" ||
24736 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24737 X"$as_dir" : 'X\(//\)[^/]' \| \
24738 X"$as_dir" : 'X\(//\)$' \| \
24739 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
24740 $as_echo X"$as_dir" |
24741 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
24742 s//\1/
24743 q
24744 }
24745 /^X\(\/\/\)[^/].*/{
24746 s//\1/
24747 q
24748 }
24749 /^X\(\/\/\)$/{
24750 s//\1/
24751 q
24752 }
24753 /^X\(\/\).*/{
24754 s//\1/
24755 q
24756 }
24757 s/.*/./; q'`
24758 test -d "$as_dir" && break
24759 done
24760 test -z "$as_dirs" || eval "mkdir $as_dirs"
24761 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
24762
24763
24764 } # as_fn_mkdir_p
24765 if mkdir -p . 2>/dev/null; then
24766 as_mkdir_p='mkdir -p "$as_dir"'
24767 else
24768 test -d ./-p && rmdir ./-p
24769 as_mkdir_p=false
24770 fi
24771
24772 if test -x / >/dev/null 2>&1; then
24773 as_test_x='test -x'
24774 else
24775 if ls -dL / >/dev/null 2>&1; then
24776 as_ls_L_option=L
24777 else
24778 as_ls_L_option=
24779 fi
24780 as_test_x='
24781 eval sh -c '\''
24782 if test -d "$1"; then
24783 test -d "$1/.";
24784 else
24785 case $1 in #(
24786 -*)set "./$1";;
24787 esac;
24788 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
24789 ???[sx]*):;;*)false;;esac;fi
24790 '\'' sh
24791 '
24792 fi
24793 as_executable_p=$as_test_x
24794
24795 # Sed expression to map a string onto a valid CPP name.
24796 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
24797
24798 # Sed expression to map a string onto a valid variable name.
24799 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
24800
24801
24802 exec 6>&1
24803 ## ----------------------------------- ##
24804 ## Main body of $CONFIG_STATUS script. ##
24805 ## ----------------------------------- ##
24806 _ASEOF
24807 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
24808
24809 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24810 # Save the log message, to keep $0 and so on meaningful, and to
24811 # report actual input values of CONFIG_FILES etc. instead of their
24812 # values after options handling.
24813 ac_log="
24814 This file was extended by $as_me, which was
24815 generated by GNU Autoconf 2.64. Invocation command line was
24816
24817 CONFIG_FILES = $CONFIG_FILES
24818 CONFIG_HEADERS = $CONFIG_HEADERS
24819 CONFIG_LINKS = $CONFIG_LINKS
24820 CONFIG_COMMANDS = $CONFIG_COMMANDS
24821 $ $0 $@
24822
24823 on `(hostname || uname -n) 2>/dev/null | sed 1q`
24824 "
24825
24826 _ACEOF
24827
24828 case $ac_config_files in *"
24829 "*) set x $ac_config_files; shift; ac_config_files=$*;;
24830 esac
24831
24832 case $ac_config_headers in *"
24833 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
24834 esac
24835
24836
24837 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24838 # Files that config.status was made for.
24839 config_files="$ac_config_files"
24840 config_headers="$ac_config_headers"
24841 config_commands="$ac_config_commands"
24842
24843 _ACEOF
24844
24845 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24846 ac_cs_usage="\
24847 \`$as_me' instantiates files and other configuration actions
24848 from templates according to the current configuration. Unless the files
24849 and actions are specified as TAGs, all are instantiated by default.
24850
24851 Usage: $0 [OPTION]... [TAG]...
24852
24853 -h, --help print this help, then exit
24854 -V, --version print version number and configuration settings, then exit
24855 -q, --quiet, --silent
24856 do not print progress messages
24857 -d, --debug don't remove temporary files
24858 --recheck update $as_me by reconfiguring in the same conditions
24859 --file=FILE[:TEMPLATE]
24860 instantiate the configuration file FILE
24861 --header=FILE[:TEMPLATE]
24862 instantiate the configuration header FILE
24863
24864 Configuration files:
24865 $config_files
24866
24867 Configuration headers:
24868 $config_headers
24869
24870 Configuration commands:
24871 $config_commands
24872
24873 Report bugs to the package provider."
24874
24875 _ACEOF
24876 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24877 ac_cs_version="\\
24878 config.status
24879 configured by $0, generated by GNU Autoconf 2.64,
24880 with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
24881
24882 Copyright (C) 2009 Free Software Foundation, Inc.
24883 This config.status script is free software; the Free Software Foundation
24884 gives unlimited permission to copy, distribute and modify it."
24885
24886 ac_pwd='$ac_pwd'
24887 srcdir='$srcdir'
24888 INSTALL='$INSTALL'
24889 MKDIR_P='$MKDIR_P'
24890 AWK='$AWK'
24891 test -n "\$AWK" || AWK=awk
24892 _ACEOF
24893
24894 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24895 # The default lists apply if the user does not specify any file.
24896 ac_need_defaults=:
24897 while test $# != 0
24898 do
24899 case $1 in
24900 --*=*)
24901 ac_option=`expr "X$1" : 'X\([^=]*\)='`
24902 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
24903 ac_shift=:
24904 ;;
24905 *)
24906 ac_option=$1
24907 ac_optarg=$2
24908 ac_shift=shift
24909 ;;
24910 esac
24911
24912 case $ac_option in
24913 # Handling of the options.
24914 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
24915 ac_cs_recheck=: ;;
24916 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
24917 $as_echo "$ac_cs_version"; exit ;;
24918 --debug | --debu | --deb | --de | --d | -d )
24919 debug=: ;;
24920 --file | --fil | --fi | --f )
24921 $ac_shift
24922 case $ac_optarg in
24923 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
24924 esac
24925 as_fn_append CONFIG_FILES " '$ac_optarg'"
24926 ac_need_defaults=false;;
24927 --header | --heade | --head | --hea )
24928 $ac_shift
24929 case $ac_optarg in
24930 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
24931 esac
24932 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
24933 ac_need_defaults=false;;
24934 --he | --h)
24935 # Conflict between --help and --header
24936 as_fn_error "ambiguous option: \`$1'
24937 Try \`$0 --help' for more information.";;
24938 --help | --hel | -h )
24939 $as_echo "$ac_cs_usage"; exit ;;
24940 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
24941 | -silent | --silent | --silen | --sile | --sil | --si | --s)
24942 ac_cs_silent=: ;;
24943
24944 # This is an error.
24945 -*) as_fn_error "unrecognized option: \`$1'
24946 Try \`$0 --help' for more information." ;;
24947
24948 *) as_fn_append ac_config_targets " $1"
24949 ac_need_defaults=false ;;
24950
24951 esac
24952 shift
24953 done
24954
24955 ac_configure_extra_args=
24956
24957 if $ac_cs_silent; then
24958 exec 6>/dev/null
24959 ac_configure_extra_args="$ac_configure_extra_args --silent"
24960 fi
24961
24962 _ACEOF
24963 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24964 if \$ac_cs_recheck; then
24965 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
24966 shift
24967 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
24968 CONFIG_SHELL='$SHELL'
24969 export CONFIG_SHELL
24970 exec "\$@"
24971 fi
24972
24973 _ACEOF
24974 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24975 exec 5>>config.log
24976 {
24977 echo
24978 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
24979 ## Running $as_me. ##
24980 _ASBOX
24981 $as_echo "$ac_log"
24982 } >&5
24983
24984 _ACEOF
24985 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24986 #
24987 # INIT-COMMANDS
24988 #
24989 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
24990
24991 _ACEOF
24992
24993 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24994
24995 # Handling of arguments.
24996 for ac_config_target in $ac_config_targets
24997 do
24998 case $ac_config_target in
24999 "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
25000 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
25001 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
25002 "import/Makefile") CONFIG_FILES="$CONFIG_FILES import/Makefile" ;;
25003 "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
25004
25005 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
25006 esac
25007 done
25008
25009
25010 # If the user did not use the arguments to specify the items to instantiate,
25011 # then the envvar interface is used. Set only those that are not.
25012 # We use the long form for the default assignment because of an extremely
25013 # bizarre bug on SunOS 4.1.3.
25014 if $ac_need_defaults; then
25015 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
25016 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
25017 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
25018 fi
25019
25020 # Have a temporary directory for convenience. Make it in the build tree
25021 # simply because there is no reason against having it here, and in addition,
25022 # creating and moving files from /tmp can sometimes cause problems.
25023 # Hook for its removal unless debugging.
25024 # Note that there is a small window in which the directory will not be cleaned:
25025 # after its creation but before its name has been assigned to `$tmp'.
25026 $debug ||
25027 {
25028 tmp=
25029 trap 'exit_status=$?
25030 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
25031 ' 0
25032 trap 'as_fn_exit 1' 1 2 13 15
25033 }
25034 # Create a (secure) tmp directory for tmp files.
25035
25036 {
25037 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
25038 test -n "$tmp" && test -d "$tmp"
25039 } ||
25040 {
25041 tmp=./conf$$-$RANDOM
25042 (umask 077 && mkdir "$tmp")
25043 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
25044
25045 # Set up the scripts for CONFIG_FILES section.
25046 # No need to generate them if there are no CONFIG_FILES.
25047 # This happens for instance with `./config.status config.h'.
25048 if test -n "$CONFIG_FILES"; then
25049
25050
25051 ac_cr=`echo X | tr X '\015'`
25052 # On cygwin, bash can eat \r inside `` if the user requested igncr.
25053 # But we know of no other shell where ac_cr would be empty at this
25054 # point, so we can use a bashism as a fallback.
25055 if test "x$ac_cr" = x; then
25056 eval ac_cr=\$\'\\r\'
25057 fi
25058 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
25059 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
25060 ac_cs_awk_cr='\r'
25061 else
25062 ac_cs_awk_cr=$ac_cr
25063 fi
25064
25065 echo 'BEGIN {' >"$tmp/subs1.awk" &&
25066 _ACEOF
25067
25068
25069 {
25070 echo "cat >conf$$subs.awk <<_ACEOF" &&
25071 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
25072 echo "_ACEOF"
25073 } >conf$$subs.sh ||
25074 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25075 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
25076 ac_delim='%!_!# '
25077 for ac_last_try in false false false false false :; do
25078 . ./conf$$subs.sh ||
25079 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25080
25081 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
25082 if test $ac_delim_n = $ac_delim_num; then
25083 break
25084 elif $ac_last_try; then
25085 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25086 else
25087 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
25088 fi
25089 done
25090 rm -f conf$$subs.sh
25091
25092 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25093 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
25094 _ACEOF
25095 sed -n '
25096 h
25097 s/^/S["/; s/!.*/"]=/
25098 p
25099 g
25100 s/^[^!]*!//
25101 :repl
25102 t repl
25103 s/'"$ac_delim"'$//
25104 t delim
25105 :nl
25106 h
25107 s/\(.\{148\}\).*/\1/
25108 t more1
25109 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
25110 p
25111 n
25112 b repl
25113 :more1
25114 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
25115 p
25116 g
25117 s/.\{148\}//
25118 t nl
25119 :delim
25120 h
25121 s/\(.\{148\}\).*/\1/
25122 t more2
25123 s/["\\]/\\&/g; s/^/"/; s/$/"/
25124 p
25125 b
25126 :more2
25127 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
25128 p
25129 g
25130 s/.\{148\}//
25131 t delim
25132 ' <conf$$subs.awk | sed '
25133 /^[^""]/{
25134 N
25135 s/\n//
25136 }
25137 ' >>$CONFIG_STATUS || ac_write_fail=1
25138 rm -f conf$$subs.awk
25139 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25140 _ACAWK
25141 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
25142 for (key in S) S_is_set[key] = 1
25143 FS = "\a"
25144
25145 }
25146 {
25147 line = $ 0
25148 nfields = split(line, field, "@")
25149 substed = 0
25150 len = length(field[1])
25151 for (i = 2; i < nfields; i++) {
25152 key = field[i]
25153 keylen = length(key)
25154 if (S_is_set[key]) {
25155 value = S[key]
25156 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
25157 len += length(value) + length(field[++i])
25158 substed = 1
25159 } else
25160 len += 1 + keylen
25161 }
25162
25163 print line
25164 }
25165
25166 _ACAWK
25167 _ACEOF
25168 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25169 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
25170 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
25171 else
25172 cat
25173 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
25174 || as_fn_error "could not setup config files machinery" "$LINENO" 5
25175 _ACEOF
25176
25177 # VPATH may cause trouble with some makes, so we remove $(srcdir),
25178 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
25179 # trailing colons and then remove the whole line if VPATH becomes empty
25180 # (actually we leave an empty line to preserve line numbers).
25181 if test "x$srcdir" = x.; then
25182 ac_vpsub='/^[ ]*VPATH[ ]*=/{
25183 s/:*\$(srcdir):*/:/
25184 s/:*\${srcdir}:*/:/
25185 s/:*@srcdir@:*/:/
25186 s/^\([^=]*=[ ]*\):*/\1/
25187 s/:*$//
25188 s/^[^=]*=[ ]*$//
25189 }'
25190 fi
25191
25192 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25193 fi # test -n "$CONFIG_FILES"
25194
25195 # Set up the scripts for CONFIG_HEADERS section.
25196 # No need to generate them if there are no CONFIG_HEADERS.
25197 # This happens for instance with `./config.status Makefile'.
25198 if test -n "$CONFIG_HEADERS"; then
25199 cat >"$tmp/defines.awk" <<\_ACAWK ||
25200 BEGIN {
25201 _ACEOF
25202
25203 # Transform confdefs.h into an awk script `defines.awk', embedded as
25204 # here-document in config.status, that substitutes the proper values into
25205 # config.h.in to produce config.h.
25206
25207 # Create a delimiter string that does not exist in confdefs.h, to ease
25208 # handling of long lines.
25209 ac_delim='%!_!# '
25210 for ac_last_try in false false :; do
25211 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
25212 if test -z "$ac_t"; then
25213 break
25214 elif $ac_last_try; then
25215 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
25216 else
25217 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
25218 fi
25219 done
25220
25221 # For the awk script, D is an array of macro values keyed by name,
25222 # likewise P contains macro parameters if any. Preserve backslash
25223 # newline sequences.
25224
25225 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
25226 sed -n '
25227 s/.\{148\}/&'"$ac_delim"'/g
25228 t rset
25229 :rset
25230 s/^[ ]*#[ ]*define[ ][ ]*/ /
25231 t def
25232 d
25233 :def
25234 s/\\$//
25235 t bsnl
25236 s/["\\]/\\&/g
25237 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
25238 D["\1"]=" \3"/p
25239 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
25240 d
25241 :bsnl
25242 s/["\\]/\\&/g
25243 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
25244 D["\1"]=" \3\\\\\\n"\\/p
25245 t cont
25246 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
25247 t cont
25248 d
25249 :cont
25250 n
25251 s/.\{148\}/&'"$ac_delim"'/g
25252 t clear
25253 :clear
25254 s/\\$//
25255 t bsnlc
25256 s/["\\]/\\&/g; s/^/"/; s/$/"/p
25257 d
25258 :bsnlc
25259 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
25260 b cont
25261 ' <confdefs.h | sed '
25262 s/'"$ac_delim"'/"\\\
25263 "/g' >>$CONFIG_STATUS || ac_write_fail=1
25264
25265 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25266 for (key in D) D_is_set[key] = 1
25267 FS = "\a"
25268 }
25269 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
25270 line = \$ 0
25271 split(line, arg, " ")
25272 if (arg[1] == "#") {
25273 defundef = arg[2]
25274 mac1 = arg[3]
25275 } else {
25276 defundef = substr(arg[1], 2)
25277 mac1 = arg[2]
25278 }
25279 split(mac1, mac2, "(") #)
25280 macro = mac2[1]
25281 prefix = substr(line, 1, index(line, defundef) - 1)
25282 if (D_is_set[macro]) {
25283 # Preserve the white space surrounding the "#".
25284 print prefix "define", macro P[macro] D[macro]
25285 next
25286 } else {
25287 # Replace #undef with comments. This is necessary, for example,
25288 # in the case of _POSIX_SOURCE, which is predefined and required
25289 # on some systems where configure will not decide to define it.
25290 if (defundef == "undef") {
25291 print "/*", prefix defundef, macro, "*/"
25292 next
25293 }
25294 }
25295 }
25296 { print }
25297 _ACAWK
25298 _ACEOF
25299 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25300 as_fn_error "could not setup config headers machinery" "$LINENO" 5
25301 fi # test -n "$CONFIG_HEADERS"
25302
25303
25304 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
25305 shift
25306 for ac_tag
25307 do
25308 case $ac_tag in
25309 :[FHLC]) ac_mode=$ac_tag; continue;;
25310 esac
25311 case $ac_mode$ac_tag in
25312 :[FHL]*:*);;
25313 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
25314 :[FH]-) ac_tag=-:-;;
25315 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
25316 esac
25317 ac_save_IFS=$IFS
25318 IFS=:
25319 set x $ac_tag
25320 IFS=$ac_save_IFS
25321 shift
25322 ac_file=$1
25323 shift
25324
25325 case $ac_mode in
25326 :L) ac_source=$1;;
25327 :[FH])
25328 ac_file_inputs=
25329 for ac_f
25330 do
25331 case $ac_f in
25332 -) ac_f="$tmp/stdin";;
25333 *) # Look for the file first in the build tree, then in the source tree
25334 # (if the path is not absolute). The absolute path cannot be DOS-style,
25335 # because $ac_f cannot contain `:'.
25336 test -f "$ac_f" ||
25337 case $ac_f in
25338 [\\/$]*) false;;
25339 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
25340 esac ||
25341 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
25342 esac
25343 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
25344 as_fn_append ac_file_inputs " '$ac_f'"
25345 done
25346
25347 # Let's still pretend it is `configure' which instantiates (i.e., don't
25348 # use $as_me), people would be surprised to read:
25349 # /* config.h. Generated by config.status. */
25350 configure_input='Generated from '`
25351 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
25352 `' by configure.'
25353 if test x"$ac_file" != x-; then
25354 configure_input="$ac_file. $configure_input"
25355 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
25356 $as_echo "$as_me: creating $ac_file" >&6;}
25357 fi
25358 # Neutralize special characters interpreted by sed in replacement strings.
25359 case $configure_input in #(
25360 *\&* | *\|* | *\\* )
25361 ac_sed_conf_input=`$as_echo "$configure_input" |
25362 sed 's/[\\\\&|]/\\\\&/g'`;; #(
25363 *) ac_sed_conf_input=$configure_input;;
25364 esac
25365
25366 case $ac_tag in
25367 *:-:* | *:-) cat >"$tmp/stdin" \
25368 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
25369 esac
25370 ;;
25371 esac
25372
25373 ac_dir=`$as_dirname -- "$ac_file" ||
25374 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25375 X"$ac_file" : 'X\(//\)[^/]' \| \
25376 X"$ac_file" : 'X\(//\)$' \| \
25377 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
25378 $as_echo X"$ac_file" |
25379 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25380 s//\1/
25381 q
25382 }
25383 /^X\(\/\/\)[^/].*/{
25384 s//\1/
25385 q
25386 }
25387 /^X\(\/\/\)$/{
25388 s//\1/
25389 q
25390 }
25391 /^X\(\/\).*/{
25392 s//\1/
25393 q
25394 }
25395 s/.*/./; q'`
25396 as_dir="$ac_dir"; as_fn_mkdir_p
25397 ac_builddir=.
25398
25399 case "$ac_dir" in
25400 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
25401 *)
25402 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
25403 # A ".." for each directory in $ac_dir_suffix.
25404 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
25405 case $ac_top_builddir_sub in
25406 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
25407 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
25408 esac ;;
25409 esac
25410 ac_abs_top_builddir=$ac_pwd
25411 ac_abs_builddir=$ac_pwd$ac_dir_suffix
25412 # for backward compatibility:
25413 ac_top_builddir=$ac_top_build_prefix
25414
25415 case $srcdir in
25416 .) # We are building in place.
25417 ac_srcdir=.
25418 ac_top_srcdir=$ac_top_builddir_sub
25419 ac_abs_top_srcdir=$ac_pwd ;;
25420 [\\/]* | ?:[\\/]* ) # Absolute name.
25421 ac_srcdir=$srcdir$ac_dir_suffix;
25422 ac_top_srcdir=$srcdir
25423 ac_abs_top_srcdir=$srcdir ;;
25424 *) # Relative name.
25425 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
25426 ac_top_srcdir=$ac_top_build_prefix$srcdir
25427 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
25428 esac
25429 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
25430
25431
25432 case $ac_mode in
25433 :F)
25434 #
25435 # CONFIG_FILE
25436 #
25437
25438 case $INSTALL in
25439 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
25440 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
25441 esac
25442 ac_MKDIR_P=$MKDIR_P
25443 case $MKDIR_P in
25444 [\\/$]* | ?:[\\/]* ) ;;
25445 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
25446 esac
25447 _ACEOF
25448
25449 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25450 # If the template does not know about datarootdir, expand it.
25451 # FIXME: This hack should be removed a few years after 2.60.
25452 ac_datarootdir_hack=; ac_datarootdir_seen=
25453 ac_sed_dataroot='
25454 /datarootdir/ {
25455 p
25456 q
25457 }
25458 /@datadir@/p
25459 /@docdir@/p
25460 /@infodir@/p
25461 /@localedir@/p
25462 /@mandir@/p'
25463 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
25464 *datarootdir*) ac_datarootdir_seen=yes;;
25465 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
25466 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
25467 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
25468 _ACEOF
25469 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25470 ac_datarootdir_hack='
25471 s&@datadir@&$datadir&g
25472 s&@docdir@&$docdir&g
25473 s&@infodir@&$infodir&g
25474 s&@localedir@&$localedir&g
25475 s&@mandir@&$mandir&g
25476 s&\\\${datarootdir}&$datarootdir&g' ;;
25477 esac
25478 _ACEOF
25479
25480 # Neutralize VPATH when `$srcdir' = `.'.
25481 # Shell code in configure.ac might set extrasub.
25482 # FIXME: do we really want to maintain this feature?
25483 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25484 ac_sed_extra="$ac_vpsub
25485 $extrasub
25486 _ACEOF
25487 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25488 :t
25489 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
25490 s|@configure_input@|$ac_sed_conf_input|;t t
25491 s&@top_builddir@&$ac_top_builddir_sub&;t t
25492 s&@top_build_prefix@&$ac_top_build_prefix&;t t
25493 s&@srcdir@&$ac_srcdir&;t t
25494 s&@abs_srcdir@&$ac_abs_srcdir&;t t
25495 s&@top_srcdir@&$ac_top_srcdir&;t t
25496 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
25497 s&@builddir@&$ac_builddir&;t t
25498 s&@abs_builddir@&$ac_abs_builddir&;t t
25499 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
25500 s&@INSTALL@&$ac_INSTALL&;t t
25501 s&@MKDIR_P@&$ac_MKDIR_P&;t t
25502 $ac_datarootdir_hack
25503 "
25504 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
25505 || as_fn_error "could not create $ac_file" "$LINENO" 5
25506
25507 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
25508 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
25509 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
25510 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
25511 which seems to be undefined. Please make sure it is defined." >&5
25512 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
25513 which seems to be undefined. Please make sure it is defined." >&2;}
25514
25515 rm -f "$tmp/stdin"
25516 case $ac_file in
25517 -) cat "$tmp/out" && rm -f "$tmp/out";;
25518 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
25519 esac \
25520 || as_fn_error "could not create $ac_file" "$LINENO" 5
25521 ;;
25522 :H)
25523 #
25524 # CONFIG_HEADER
25525 #
25526 if test x"$ac_file" != x-; then
25527 {
25528 $as_echo "/* $configure_input */" \
25529 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
25530 } >"$tmp/config.h" \
25531 || as_fn_error "could not create $ac_file" "$LINENO" 5
25532 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
25533 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
25534 $as_echo "$as_me: $ac_file is unchanged" >&6;}
25535 else
25536 rm -f "$ac_file"
25537 mv "$tmp/config.h" "$ac_file" \
25538 || as_fn_error "could not create $ac_file" "$LINENO" 5
25539 fi
25540 else
25541 $as_echo "/* $configure_input */" \
25542 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
25543 || as_fn_error "could not create -" "$LINENO" 5
25544 fi
25545 # Compute "$ac_file"'s index in $config_headers.
25546 _am_arg="$ac_file"
25547 _am_stamp_count=1
25548 for _am_header in $config_headers :; do
25549 case $_am_header in
25550 $_am_arg | $_am_arg:* )
25551 break ;;
25552 * )
25553 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
25554 esac
25555 done
25556 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
25557 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25558 X"$_am_arg" : 'X\(//\)[^/]' \| \
25559 X"$_am_arg" : 'X\(//\)$' \| \
25560 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
25561 $as_echo X"$_am_arg" |
25562 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25563 s//\1/
25564 q
25565 }
25566 /^X\(\/\/\)[^/].*/{
25567 s//\1/
25568 q
25569 }
25570 /^X\(\/\/\)$/{
25571 s//\1/
25572 q
25573 }
25574 /^X\(\/\).*/{
25575 s//\1/
25576 q
25577 }
25578 s/.*/./; q'`/stamp-h$_am_stamp_count
25579 ;;
25580
25581 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
25582 $as_echo "$as_me: executing $ac_file commands" >&6;}
25583 ;;
25584 esac
25585
25586
25587 case $ac_file$ac_mode in
25588 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
25589 # Autoconf 2.62 quotes --file arguments for eval, but not when files
25590 # are listed without --file. Let's play safe and only enable the eval
25591 # if we detect the quoting.
25592 case $CONFIG_FILES in
25593 *\'*) eval set x "$CONFIG_FILES" ;;
25594 *) set x $CONFIG_FILES ;;
25595 esac
25596 shift
25597 for mf
25598 do
25599 # Strip MF so we end up with the name of the file.
25600 mf=`echo "$mf" | sed -e 's/:.*$//'`
25601 # Check whether this is an Automake generated Makefile or not.
25602 # We used to match only the files named `Makefile.in', but
25603 # some people rename them; so instead we look at the file content.
25604 # Grep'ing the first line is not enough: some people post-process
25605 # each Makefile.in and add a new line on top of each file to say so.
25606 # Grep'ing the whole file is not good either: AIX grep has a line
25607 # limit of 2048, but all sed's we know have understand at least 4000.
25608 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
25609 dirpart=`$as_dirname -- "$mf" ||
25610 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25611 X"$mf" : 'X\(//\)[^/]' \| \
25612 X"$mf" : 'X\(//\)$' \| \
25613 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
25614 $as_echo X"$mf" |
25615 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25616 s//\1/
25617 q
25618 }
25619 /^X\(\/\/\)[^/].*/{
25620 s//\1/
25621 q
25622 }
25623 /^X\(\/\/\)$/{
25624 s//\1/
25625 q
25626 }
25627 /^X\(\/\).*/{
25628 s//\1/
25629 q
25630 }
25631 s/.*/./; q'`
25632 else
25633 continue
25634 fi
25635 # Extract the definition of DEPDIR, am__include, and am__quote
25636 # from the Makefile without running `make'.
25637 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
25638 test -z "$DEPDIR" && continue
25639 am__include=`sed -n 's/^am__include = //p' < "$mf"`
25640 test -z "am__include" && continue
25641 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
25642 # When using ansi2knr, U may be empty or an underscore; expand it
25643 U=`sed -n 's/^U = //p' < "$mf"`
25644 # Find all dependency output files, they are included files with
25645 # $(DEPDIR) in their names. We invoke sed twice because it is the
25646 # simplest approach to changing $(DEPDIR) to its actual value in the
25647 # expansion.
25648 for file in `sed -n "
25649 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
25650 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
25651 # Make sure the directory exists.
25652 test -f "$dirpart/$file" && continue
25653 fdir=`$as_dirname -- "$file" ||
25654 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25655 X"$file" : 'X\(//\)[^/]' \| \
25656 X"$file" : 'X\(//\)$' \| \
25657 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
25658 $as_echo X"$file" |
25659 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25660 s//\1/
25661 q
25662 }
25663 /^X\(\/\/\)[^/].*/{
25664 s//\1/
25665 q
25666 }
25667 /^X\(\/\/\)$/{
25668 s//\1/
25669 q
25670 }
25671 /^X\(\/\).*/{
25672 s//\1/
25673 q
25674 }
25675 s/.*/./; q'`
25676 as_dir=$dirpart/$fdir; as_fn_mkdir_p
25677 # echo "creating $dirpart/$file"
25678 echo '# dummy' > "$dirpart/$file"
25679 done
25680 done
25681 }
25682 ;;
25683 "default":C)
25684 case x$CONFIG_HEADERS in
25685 xconfig.h:config.in)
25686 echo > stamp-h ;;
25687 esac
25688 ;;
25689
25690 esac
25691 done # for ac_tag
25692
25693
25694 as_fn_exit 0
25695 _ACEOF
25696 ac_clean_files=$ac_clean_files_save
25697
25698 test $ac_write_fail = 0 ||
25699 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
25700
25701
25702 # configure is writing to config.log, and then calls config.status.
25703 # config.status does its own redirection, appending to config.log.
25704 # Unfortunately, on DOS this fails, as config.log is still kept open
25705 # by configure, so config.status won't be able to write to it; its
25706 # output is simply discarded. So we exec the FD to /dev/null,
25707 # effectively closing config.log, so it can be properly (re)opened and
25708 # appended to by config.status. When coming back to configure, we
25709 # need to make the FD available again.
25710 if test "$no_create" != yes; then
25711 ac_cs_success=:
25712 ac_config_status_args=
25713 test "$silent" = yes &&
25714 ac_config_status_args="$ac_config_status_args --quiet"
25715 exec 5>/dev/null
25716 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
25717 exec 5>>config.log
25718 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
25719 # would make configure fail if this is the last instruction.
25720 $ac_cs_success || as_fn_exit $?
25721 fi
25722 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
25723 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
25724 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
25725 fi
25726
25727
25728 exit 0
This page took 0.568973 seconds and 4 git commands to generate.