Import gnulib's mkdir module
[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.69 for libgnu UNUSED-VERSION.
4 #
5 #
6 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
7 #
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 as_myself=
91 case $0 in #((
92 *[\\/]* ) as_myself=$0 ;;
93 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
94 for as_dir in $PATH
95 do
96 IFS=$as_save_IFS
97 test -z "$as_dir" && as_dir=.
98 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
99 done
100 IFS=$as_save_IFS
101
102 ;;
103 esac
104 # We did not find ourselves, most probably we were run as `sh COMMAND'
105 # in which case we are not to be found in the path.
106 if test "x$as_myself" = x; then
107 as_myself=$0
108 fi
109 if test ! -f "$as_myself"; then
110 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
111 exit 1
112 fi
113
114 # Unset variables that we do not need and which cause bugs (e.g. in
115 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
116 # suppresses any "Segmentation fault" message there. '((' could
117 # trigger a bug in pdksh 5.2.14.
118 for as_var in BASH_ENV ENV MAIL MAILPATH
119 do eval test x\${$as_var+set} = xset \
120 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
121 done
122 PS1='$ '
123 PS2='> '
124 PS4='+ '
125
126 # NLS nuisances.
127 LC_ALL=C
128 export LC_ALL
129 LANGUAGE=C
130 export LANGUAGE
131
132 # CDPATH.
133 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
134
135 # Use a proper internal environment variable to ensure we don't fall
136 # into an infinite loop, continuously re-executing ourselves.
137 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
138 _as_can_reexec=no; export _as_can_reexec;
139 # We cannot yet assume a decent shell, so we have to provide a
140 # neutralization value for shells without unset; and this also
141 # works around shells that cannot unset nonexistent variables.
142 # Preserve -v and -x to the replacement shell.
143 BASH_ENV=/dev/null
144 ENV=/dev/null
145 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
146 case $- in # ((((
147 *v*x* | *x*v* ) as_opts=-vx ;;
148 *v* ) as_opts=-v ;;
149 *x* ) as_opts=-x ;;
150 * ) as_opts= ;;
151 esac
152 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
153 # Admittedly, this is quite paranoid, since all the known shells bail
154 # out after a failed `exec'.
155 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
156 as_fn_exit 255
157 fi
158 # We don't want this to propagate to other subprocesses.
159 { _as_can_reexec=; unset _as_can_reexec;}
160 if test "x$CONFIG_SHELL" = x; then
161 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
162 emulate sh
163 NULLCMD=:
164 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
165 # is contrary to our usage. Disable this feature.
166 alias -g '\${1+\"\$@\"}'='\"\$@\"'
167 setopt NO_GLOB_SUBST
168 else
169 case \`(set -o) 2>/dev/null\` in #(
170 *posix*) :
171 set -o posix ;; #(
172 *) :
173 ;;
174 esac
175 fi
176 "
177 as_required="as_fn_return () { (exit \$1); }
178 as_fn_success () { as_fn_return 0; }
179 as_fn_failure () { as_fn_return 1; }
180 as_fn_ret_success () { return 0; }
181 as_fn_ret_failure () { return 1; }
182
183 exitcode=0
184 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
185 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
186 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
187 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
188 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
189
190 else
191 exitcode=1; echo positional parameters were not saved.
192 fi
193 test x\$exitcode = x0 || exit 1
194 test -x / || exit 1"
195 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
196 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
197 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
198 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
199 test \$(( 1 + 1 )) = 2 || exit 1"
200 if (eval "$as_required") 2>/dev/null; then :
201 as_have_required=yes
202 else
203 as_have_required=no
204 fi
205 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
206
207 else
208 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
209 as_found=false
210 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
211 do
212 IFS=$as_save_IFS
213 test -z "$as_dir" && as_dir=.
214 as_found=:
215 case $as_dir in #(
216 /*)
217 for as_base in sh bash ksh sh5; do
218 # Try only shells that exist, to save several forks.
219 as_shell=$as_dir/$as_base
220 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
221 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
222 CONFIG_SHELL=$as_shell as_have_required=yes
223 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
224 break 2
225 fi
226 fi
227 done;;
228 esac
229 as_found=false
230 done
231 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
232 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
233 CONFIG_SHELL=$SHELL as_have_required=yes
234 fi; }
235 IFS=$as_save_IFS
236
237
238 if test "x$CONFIG_SHELL" != x; then :
239 export CONFIG_SHELL
240 # We cannot yet assume a decent shell, so we have to provide a
241 # neutralization value for shells without unset; and this also
242 # works around shells that cannot unset nonexistent variables.
243 # Preserve -v and -x to the replacement shell.
244 BASH_ENV=/dev/null
245 ENV=/dev/null
246 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
247 case $- in # ((((
248 *v*x* | *x*v* ) as_opts=-vx ;;
249 *v* ) as_opts=-v ;;
250 *x* ) as_opts=-x ;;
251 * ) as_opts= ;;
252 esac
253 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
254 # Admittedly, this is quite paranoid, since all the known shells bail
255 # out after a failed `exec'.
256 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
257 exit 255
258 fi
259
260 if test x$as_have_required = xno; then :
261 $as_echo "$0: This script requires a shell more modern than all"
262 $as_echo "$0: the shells that I found on your system."
263 if test x${ZSH_VERSION+set} = xset ; then
264 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
265 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
266 else
267 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
268 $0: including any error possibly output before this
269 $0: message. Then install a modern shell, or manually run
270 $0: the script under such a shell if you do have one."
271 fi
272 exit 1
273 fi
274 fi
275 fi
276 SHELL=${CONFIG_SHELL-/bin/sh}
277 export SHELL
278 # Unset more variables known to interfere with behavior of common tools.
279 CLICOLOR_FORCE= GREP_OPTIONS=
280 unset CLICOLOR_FORCE GREP_OPTIONS
281
282 ## --------------------- ##
283 ## M4sh Shell Functions. ##
284 ## --------------------- ##
285 # as_fn_unset VAR
286 # ---------------
287 # Portably unset VAR.
288 as_fn_unset ()
289 {
290 { eval $1=; unset $1;}
291 }
292 as_unset=as_fn_unset
293
294 # as_fn_set_status STATUS
295 # -----------------------
296 # Set $? to STATUS, without forking.
297 as_fn_set_status ()
298 {
299 return $1
300 } # as_fn_set_status
301
302 # as_fn_exit STATUS
303 # -----------------
304 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
305 as_fn_exit ()
306 {
307 set +e
308 as_fn_set_status $1
309 exit $1
310 } # as_fn_exit
311
312 # as_fn_mkdir_p
313 # -------------
314 # Create "$as_dir" as a directory, including parents if necessary.
315 as_fn_mkdir_p ()
316 {
317
318 case $as_dir in #(
319 -*) as_dir=./$as_dir;;
320 esac
321 test -d "$as_dir" || eval $as_mkdir_p || {
322 as_dirs=
323 while :; do
324 case $as_dir in #(
325 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
326 *) as_qdir=$as_dir;;
327 esac
328 as_dirs="'$as_qdir' $as_dirs"
329 as_dir=`$as_dirname -- "$as_dir" ||
330 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
331 X"$as_dir" : 'X\(//\)[^/]' \| \
332 X"$as_dir" : 'X\(//\)$' \| \
333 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
334 $as_echo X"$as_dir" |
335 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
336 s//\1/
337 q
338 }
339 /^X\(\/\/\)[^/].*/{
340 s//\1/
341 q
342 }
343 /^X\(\/\/\)$/{
344 s//\1/
345 q
346 }
347 /^X\(\/\).*/{
348 s//\1/
349 q
350 }
351 s/.*/./; q'`
352 test -d "$as_dir" && break
353 done
354 test -z "$as_dirs" || eval "mkdir $as_dirs"
355 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
356
357
358 } # as_fn_mkdir_p
359
360 # as_fn_executable_p FILE
361 # -----------------------
362 # Test if FILE is an executable regular file.
363 as_fn_executable_p ()
364 {
365 test -f "$1" && test -x "$1"
366 } # as_fn_executable_p
367 # as_fn_append VAR VALUE
368 # ----------------------
369 # Append the text in VALUE to the end of the definition contained in VAR. Take
370 # advantage of any shell optimizations that allow amortized linear growth over
371 # repeated appends, instead of the typical quadratic growth present in naive
372 # implementations.
373 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
374 eval 'as_fn_append ()
375 {
376 eval $1+=\$2
377 }'
378 else
379 as_fn_append ()
380 {
381 eval $1=\$$1\$2
382 }
383 fi # as_fn_append
384
385 # as_fn_arith ARG...
386 # ------------------
387 # Perform arithmetic evaluation on the ARGs, and store the result in the
388 # global $as_val. Take advantage of shells that can avoid forks. The arguments
389 # must be portable across $(()) and expr.
390 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
391 eval 'as_fn_arith ()
392 {
393 as_val=$(( $* ))
394 }'
395 else
396 as_fn_arith ()
397 {
398 as_val=`expr "$@" || test $? -eq 1`
399 }
400 fi # as_fn_arith
401
402
403 # as_fn_error STATUS ERROR [LINENO LOG_FD]
404 # ----------------------------------------
405 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
406 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
407 # script with STATUS, using 1 if that was 0.
408 as_fn_error ()
409 {
410 as_status=$1; test $as_status -eq 0 && as_status=1
411 if test "$4"; then
412 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
413 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
414 fi
415 $as_echo "$as_me: error: $2" >&2
416 as_fn_exit $as_status
417 } # as_fn_error
418
419 if expr a : '\(a\)' >/dev/null 2>&1 &&
420 test "X`expr 00001 : '.*\(...\)'`" = X001; then
421 as_expr=expr
422 else
423 as_expr=false
424 fi
425
426 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
427 as_basename=basename
428 else
429 as_basename=false
430 fi
431
432 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
433 as_dirname=dirname
434 else
435 as_dirname=false
436 fi
437
438 as_me=`$as_basename -- "$0" ||
439 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
440 X"$0" : 'X\(//\)$' \| \
441 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
442 $as_echo X/"$0" |
443 sed '/^.*\/\([^/][^/]*\)\/*$/{
444 s//\1/
445 q
446 }
447 /^X\/\(\/\/\)$/{
448 s//\1/
449 q
450 }
451 /^X\/\(\/\).*/{
452 s//\1/
453 q
454 }
455 s/.*/./; q'`
456
457 # Avoid depending upon Character Ranges.
458 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
459 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
460 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
461 as_cr_digits='0123456789'
462 as_cr_alnum=$as_cr_Letters$as_cr_digits
463
464
465 as_lineno_1=$LINENO as_lineno_1a=$LINENO
466 as_lineno_2=$LINENO as_lineno_2a=$LINENO
467 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
468 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
469 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
470 sed -n '
471 p
472 /[$]LINENO/=
473 ' <$as_myself |
474 sed '
475 s/[$]LINENO.*/&-/
476 t lineno
477 b
478 :lineno
479 N
480 :loop
481 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
482 t loop
483 s/-\n.*//
484 ' >$as_me.lineno &&
485 chmod +x "$as_me.lineno" ||
486 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
487
488 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
489 # already done that, so ensure we don't try to do so again and fall
490 # in an infinite loop. This has already happened in practice.
491 _as_can_reexec=no; export _as_can_reexec
492 # Don't try to exec as it changes $[0], causing all sort of problems
493 # (the dirname of $[0] is not the place where we might find the
494 # original and so on. Autoconf is especially sensitive to this).
495 . "./$as_me.lineno"
496 # Exit status is that of the last command.
497 exit
498 }
499
500 ECHO_C= ECHO_N= ECHO_T=
501 case `echo -n x` in #(((((
502 -n*)
503 case `echo 'xy\c'` in
504 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
505 xy) ECHO_C='\c';;
506 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
507 ECHO_T=' ';;
508 esac;;
509 *)
510 ECHO_N='-n';;
511 esac
512
513 rm -f conf$$ conf$$.exe conf$$.file
514 if test -d conf$$.dir; then
515 rm -f conf$$.dir/conf$$.file
516 else
517 rm -f conf$$.dir
518 mkdir conf$$.dir 2>/dev/null
519 fi
520 if (echo >conf$$.file) 2>/dev/null; then
521 if ln -s conf$$.file conf$$ 2>/dev/null; then
522 as_ln_s='ln -s'
523 # ... but there are two gotchas:
524 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
525 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
526 # In both cases, we have to default to `cp -pR'.
527 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
528 as_ln_s='cp -pR'
529 elif ln conf$$.file conf$$ 2>/dev/null; then
530 as_ln_s=ln
531 else
532 as_ln_s='cp -pR'
533 fi
534 else
535 as_ln_s='cp -pR'
536 fi
537 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
538 rmdir conf$$.dir 2>/dev/null
539
540 if mkdir -p . 2>/dev/null; then
541 as_mkdir_p='mkdir -p "$as_dir"'
542 else
543 test -d ./-p && rmdir ./-p
544 as_mkdir_p=false
545 fi
546
547 as_test_x='test -x'
548 as_executable_p=as_fn_executable_p
549
550 # Sed expression to map a string onto a valid CPP name.
551 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
552
553 # Sed expression to map a string onto a valid variable name.
554 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
555
556
557 test -n "$DJDIR" || exec 7<&0 </dev/null
558 exec 6>&1
559
560 # Name of the host.
561 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
562 # so uname gets run too.
563 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
564
565 #
566 # Initializations.
567 #
568 ac_default_prefix=/usr/local
569 ac_clean_files=
570 ac_config_libobj_dir=.
571 LIBOBJS=
572 cross_compiling=no
573 subdirs=
574 MFLAGS=
575 MAKEFLAGS=
576
577 # Identity of this package.
578 PACKAGE_NAME='libgnu'
579 PACKAGE_TARNAME='libgnu'
580 PACKAGE_VERSION='UNUSED-VERSION'
581 PACKAGE_STRING='libgnu UNUSED-VERSION'
582 PACKAGE_BUGREPORT=''
583 PACKAGE_URL=''
584
585 ac_unique_file="import/memmem.c"
586 # Factoring default headers for most tests.
587 ac_includes_default="\
588 #include <stdio.h>
589 #ifdef HAVE_SYS_TYPES_H
590 # include <sys/types.h>
591 #endif
592 #ifdef HAVE_SYS_STAT_H
593 # include <sys/stat.h>
594 #endif
595 #ifdef STDC_HEADERS
596 # include <stdlib.h>
597 # include <stddef.h>
598 #else
599 # ifdef HAVE_STDLIB_H
600 # include <stdlib.h>
601 # endif
602 #endif
603 #ifdef HAVE_STRING_H
604 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
605 # include <memory.h>
606 # endif
607 # include <string.h>
608 #endif
609 #ifdef HAVE_STRINGS_H
610 # include <strings.h>
611 #endif
612 #ifdef HAVE_INTTYPES_H
613 # include <inttypes.h>
614 #endif
615 #ifdef HAVE_STDINT_H
616 # include <stdint.h>
617 #endif
618 #ifdef HAVE_UNISTD_H
619 # include <unistd.h>
620 #endif"
621
622 gl_func_list=
623 gl_header_list=
624 gl_fnmatch_required=POSIX
625 ac_subst_vars='am__EXEEXT_FALSE
626 am__EXEEXT_TRUE
627 gltests_LTLIBOBJS
628 gltests_LIBOBJS
629 gl_LTLIBOBJS
630 gl_LIBOBJS
631 LTLIBOBJS
632 LIBOBJS
633 LN_S
634 AM_BACKSLASH
635 AM_DEFAULT_VERBOSITY
636 AM_DEFAULT_V
637 AM_V
638 am__fastdepCC_FALSE
639 am__fastdepCC_TRUE
640 CCDEPMODE
641 am__nodep
642 AMDEPBACKSLASH
643 AMDEP_FALSE
644 AMDEP_TRUE
645 am__quote
646 am__include
647 DEPDIR
648 am__untar
649 am__tar
650 AMTAR
651 am__leading_dot
652 SET_MAKE
653 AWK
654 mkdir_p
655 INSTALL_STRIP_PROGRAM
656 STRIP
657 install_sh
658 MAKEINFO
659 AUTOHEADER
660 AUTOMAKE
661 AUTOCONF
662 ACLOCAL
663 VERSION
664 PACKAGE
665 CYGPATH_W
666 am__isrc
667 INSTALL_DATA
668 INSTALL_SCRIPT
669 INSTALL_PROGRAM
670 LIBGNU_LTLIBDEPS
671 LIBGNU_LIBDEPS
672 gltests_WITNESS
673 REPLACE_TOWLOWER
674 REPLACE_ISWCNTRL
675 HAVE_WCTYPE_H
676 NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H
677 NEXT_WCTYPE_H
678 HAVE_ISWCNTRL
679 REPLACE_ISWBLANK
680 HAVE_WCTRANS_T
681 HAVE_WCTYPE_T
682 HAVE_ISWBLANK
683 GNULIB_TOWCTRANS
684 GNULIB_WCTRANS
685 GNULIB_ISWCTYPE
686 GNULIB_WCTYPE
687 GNULIB_ISWBLANK
688 HAVE_WINT_T
689 HAVE_FEATURES_H
690 NEXT_AS_FIRST_DIRECTIVE_WCHAR_H
691 NEXT_WCHAR_H
692 HAVE_UNISTD_H
693 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
694 NEXT_UNISTD_H
695 UNISTD_H_DEFINES_STRUCT_TIMESPEC
696 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
697 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
698 TIME_H_DEFINES_STRUCT_TIMESPEC
699 NEXT_AS_FIRST_DIRECTIVE_TIME_H
700 NEXT_TIME_H
701 REPLACE_LOCALTIME
702 REPLACE_GMTIME
703 REPLACE_TIMEGM
704 REPLACE_NANOSLEEP
705 REPLACE_MKTIME
706 REPLACE_LOCALTIME_R
707 HAVE_TIMEGM
708 HAVE_STRPTIME
709 HAVE_NANOSLEEP
710 HAVE_DECL_LOCALTIME_R
711 GNULIB_TIME_RZ
712 GNULIB_TIME_R
713 GNULIB_TIMEGM
714 GNULIB_STRPTIME
715 GNULIB_NANOSLEEP
716 GNULIB_MKTIME
717 WINDOWS_64_BIT_OFF_T
718 NEXT_AS_FIRST_DIRECTIVE_SYS_TYPES_H
719 NEXT_SYS_TYPES_H
720 MKDIR_P
721 NEXT_AS_FIRST_DIRECTIVE_STRING_H
722 NEXT_STRING_H
723 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
724 NEXT_STDLIB_H
725 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
726 NEXT_STDIO_H
727 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
728 NEXT_STDDEF_H
729 GL_GENERATE_STDDEF_H_FALSE
730 GL_GENERATE_STDDEF_H_TRUE
731 STDDEF_H
732 HAVE_WCHAR_T
733 HAVE_MAX_ALIGN_T
734 REPLACE_NULL
735 HAVE__BOOL
736 GL_GENERATE_STDBOOL_H_FALSE
737 GL_GENERATE_STDBOOL_H_TRUE
738 STDBOOL_H
739 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
740 NEXT_SIGNAL_H
741 REPLACE_RAISE
742 REPLACE_PTHREAD_SIGMASK
743 HAVE_SIGHANDLER_T
744 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
745 HAVE_STRUCT_SIGACTION_SA_SIGACTION
746 HAVE_SIGACTION
747 HAVE_SIGINFO_T
748 HAVE_SIGSET_T
749 HAVE_RAISE
750 HAVE_PTHREAD_SIGMASK
751 HAVE_POSIX_SIGNALBLOCKING
752 GNULIB_SIGACTION
753 GNULIB_SIGPROCMASK
754 GNULIB_SIGNAL_H_SIGPIPE
755 GNULIB_RAISE
756 GNULIB_PTHREAD_SIGMASK
757 REPLACE_VSPRINTF
758 REPLACE_VSNPRINTF
759 REPLACE_VPRINTF
760 REPLACE_VFPRINTF
761 REPLACE_VDPRINTF
762 REPLACE_VASPRINTF
763 REPLACE_TMPFILE
764 REPLACE_STDIO_WRITE_FUNCS
765 REPLACE_STDIO_READ_FUNCS
766 REPLACE_SPRINTF
767 REPLACE_SNPRINTF
768 REPLACE_RENAMEAT
769 REPLACE_RENAME
770 REPLACE_REMOVE
771 REPLACE_PRINTF
772 REPLACE_POPEN
773 REPLACE_PERROR
774 REPLACE_OBSTACK_PRINTF
775 REPLACE_GETLINE
776 REPLACE_GETDELIM
777 REPLACE_FTELLO
778 REPLACE_FTELL
779 REPLACE_FSEEKO
780 REPLACE_FSEEK
781 REPLACE_FREOPEN
782 REPLACE_FPURGE
783 REPLACE_FPRINTF
784 REPLACE_FOPEN
785 REPLACE_FFLUSH
786 REPLACE_FDOPEN
787 REPLACE_FCLOSE
788 REPLACE_DPRINTF
789 HAVE_VDPRINTF
790 HAVE_VASPRINTF
791 HAVE_RENAMEAT
792 HAVE_POPEN
793 HAVE_PCLOSE
794 HAVE_FTELLO
795 HAVE_FSEEKO
796 HAVE_DPRINTF
797 HAVE_DECL_VSNPRINTF
798 HAVE_DECL_SNPRINTF
799 HAVE_DECL_OBSTACK_PRINTF
800 HAVE_DECL_GETLINE
801 HAVE_DECL_GETDELIM
802 HAVE_DECL_FTELLO
803 HAVE_DECL_FSEEKO
804 HAVE_DECL_FPURGE
805 GNULIB_VSPRINTF_POSIX
806 GNULIB_VSNPRINTF
807 GNULIB_VPRINTF_POSIX
808 GNULIB_VPRINTF
809 GNULIB_VFPRINTF_POSIX
810 GNULIB_VFPRINTF
811 GNULIB_VDPRINTF
812 GNULIB_VSCANF
813 GNULIB_VFSCANF
814 GNULIB_VASPRINTF
815 GNULIB_TMPFILE
816 GNULIB_STDIO_H_SIGPIPE
817 GNULIB_STDIO_H_NONBLOCKING
818 GNULIB_SPRINTF_POSIX
819 GNULIB_SNPRINTF
820 GNULIB_SCANF
821 GNULIB_RENAMEAT
822 GNULIB_RENAME
823 GNULIB_REMOVE
824 GNULIB_PUTS
825 GNULIB_PUTCHAR
826 GNULIB_PUTC
827 GNULIB_PRINTF_POSIX
828 GNULIB_PRINTF
829 GNULIB_POPEN
830 GNULIB_PERROR
831 GNULIB_PCLOSE
832 GNULIB_OBSTACK_PRINTF_POSIX
833 GNULIB_OBSTACK_PRINTF
834 GNULIB_GETLINE
835 GNULIB_GETDELIM
836 GNULIB_GETCHAR
837 GNULIB_GETC
838 GNULIB_FWRITE
839 GNULIB_FTELLO
840 GNULIB_FTELL
841 GNULIB_FSEEKO
842 GNULIB_FSEEK
843 GNULIB_FSCANF
844 GNULIB_FREOPEN
845 GNULIB_FREAD
846 GNULIB_FPUTS
847 GNULIB_FPUTC
848 GNULIB_FPURGE
849 GNULIB_FPRINTF_POSIX
850 GNULIB_FPRINTF
851 GNULIB_FOPEN
852 GNULIB_FGETS
853 GNULIB_FGETC
854 GNULIB_FFLUSH
855 GNULIB_FDOPEN
856 GNULIB_FCLOSE
857 GNULIB_DPRINTF
858 UNDEFINE_STRTOK_R
859 REPLACE_STRTOK_R
860 REPLACE_STRSIGNAL
861 REPLACE_STRNLEN
862 REPLACE_STRNDUP
863 REPLACE_STRNCAT
864 REPLACE_STRERROR_R
865 REPLACE_STRERROR
866 REPLACE_STRCHRNUL
867 REPLACE_STRCASESTR
868 REPLACE_STRSTR
869 REPLACE_STRDUP
870 REPLACE_STPNCPY
871 REPLACE_MEMMEM
872 REPLACE_MEMCHR
873 HAVE_STRVERSCMP
874 HAVE_DECL_STRSIGNAL
875 HAVE_DECL_STRERROR_R
876 HAVE_DECL_STRTOK_R
877 HAVE_STRCASESTR
878 HAVE_STRSEP
879 HAVE_STRPBRK
880 HAVE_DECL_STRNLEN
881 HAVE_DECL_STRNDUP
882 HAVE_DECL_STRDUP
883 HAVE_STRCHRNUL
884 HAVE_STPNCPY
885 HAVE_STPCPY
886 HAVE_RAWMEMCHR
887 HAVE_DECL_MEMRCHR
888 HAVE_MEMPCPY
889 HAVE_DECL_MEMMEM
890 HAVE_MEMCHR
891 HAVE_FFSLL
892 HAVE_FFSL
893 HAVE_MBSLEN
894 GNULIB_STRVERSCMP
895 GNULIB_STRSIGNAL
896 GNULIB_STRERROR_R
897 GNULIB_STRERROR
898 GNULIB_MBSTOK_R
899 GNULIB_MBSSEP
900 GNULIB_MBSSPN
901 GNULIB_MBSPBRK
902 GNULIB_MBSCSPN
903 GNULIB_MBSCASESTR
904 GNULIB_MBSPCASECMP
905 GNULIB_MBSNCASECMP
906 GNULIB_MBSCASECMP
907 GNULIB_MBSSTR
908 GNULIB_MBSRCHR
909 GNULIB_MBSCHR
910 GNULIB_MBSNLEN
911 GNULIB_MBSLEN
912 GNULIB_STRTOK_R
913 GNULIB_STRCASESTR
914 GNULIB_STRSTR
915 GNULIB_STRSEP
916 GNULIB_STRPBRK
917 GNULIB_STRNLEN
918 GNULIB_STRNDUP
919 GNULIB_STRNCAT
920 GNULIB_STRDUP
921 GNULIB_STRCHRNUL
922 GNULIB_STPNCPY
923 GNULIB_STPCPY
924 GNULIB_RAWMEMCHR
925 GNULIB_MEMRCHR
926 GNULIB_MEMPCPY
927 GNULIB_MEMMEM
928 GNULIB_MEMCHR
929 GNULIB_FFSLL
930 GNULIB_FFSL
931 LOCALE_FR
932 LOCALE_FR_UTF8
933 LOCALE_ZH_CN
934 LOCALE_JA
935 REPLACE_WCSWIDTH
936 REPLACE_WCWIDTH
937 REPLACE_WCSNRTOMBS
938 REPLACE_WCSRTOMBS
939 REPLACE_WCRTOMB
940 REPLACE_MBSNRTOWCS
941 REPLACE_MBSRTOWCS
942 REPLACE_MBRLEN
943 REPLACE_MBRTOWC
944 REPLACE_MBSINIT
945 REPLACE_WCTOB
946 REPLACE_BTOWC
947 REPLACE_MBSTATE_T
948 HAVE_DECL_WCWIDTH
949 HAVE_DECL_WCTOB
950 HAVE_WCSWIDTH
951 HAVE_WCSTOK
952 HAVE_WCSSTR
953 HAVE_WCSPBRK
954 HAVE_WCSSPN
955 HAVE_WCSCSPN
956 HAVE_WCSRCHR
957 HAVE_WCSCHR
958 HAVE_WCSDUP
959 HAVE_WCSXFRM
960 HAVE_WCSCOLL
961 HAVE_WCSNCASECMP
962 HAVE_WCSCASECMP
963 HAVE_WCSNCMP
964 HAVE_WCSCMP
965 HAVE_WCSNCAT
966 HAVE_WCSCAT
967 HAVE_WCPNCPY
968 HAVE_WCSNCPY
969 HAVE_WCPCPY
970 HAVE_WCSCPY
971 HAVE_WCSNLEN
972 HAVE_WCSLEN
973 HAVE_WMEMSET
974 HAVE_WMEMMOVE
975 HAVE_WMEMCPY
976 HAVE_WMEMCMP
977 HAVE_WMEMCHR
978 HAVE_WCSNRTOMBS
979 HAVE_WCSRTOMBS
980 HAVE_WCRTOMB
981 HAVE_MBSNRTOWCS
982 HAVE_MBSRTOWCS
983 HAVE_MBRLEN
984 HAVE_MBRTOWC
985 HAVE_MBSINIT
986 HAVE_BTOWC
987 GNULIB_WCSWIDTH
988 GNULIB_WCSTOK
989 GNULIB_WCSSTR
990 GNULIB_WCSPBRK
991 GNULIB_WCSSPN
992 GNULIB_WCSCSPN
993 GNULIB_WCSRCHR
994 GNULIB_WCSCHR
995 GNULIB_WCSDUP
996 GNULIB_WCSXFRM
997 GNULIB_WCSCOLL
998 GNULIB_WCSNCASECMP
999 GNULIB_WCSCASECMP
1000 GNULIB_WCSNCMP
1001 GNULIB_WCSCMP
1002 GNULIB_WCSNCAT
1003 GNULIB_WCSCAT
1004 GNULIB_WCPNCPY
1005 GNULIB_WCSNCPY
1006 GNULIB_WCPCPY
1007 GNULIB_WCSCPY
1008 GNULIB_WCSNLEN
1009 GNULIB_WCSLEN
1010 GNULIB_WMEMSET
1011 GNULIB_WMEMMOVE
1012 GNULIB_WMEMCPY
1013 GNULIB_WMEMCMP
1014 GNULIB_WMEMCHR
1015 GNULIB_WCWIDTH
1016 GNULIB_WCSNRTOMBS
1017 GNULIB_WCSRTOMBS
1018 GNULIB_WCRTOMB
1019 GNULIB_MBSNRTOWCS
1020 GNULIB_MBSRTOWCS
1021 GNULIB_MBRLEN
1022 GNULIB_MBRTOWC
1023 GNULIB_MBSINIT
1024 GNULIB_WCTOB
1025 GNULIB_BTOWC
1026 NEXT_AS_FIRST_DIRECTIVE_MATH_H
1027 NEXT_MATH_H
1028 LOCALCHARSET_TESTS_ENVIRONMENT
1029 GLIBC21
1030 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
1031 NEXT_INTTYPES_H
1032 UINT64_MAX_EQ_ULONG_MAX
1033 UINT32_MAX_LT_UINTMAX_MAX
1034 PRIPTR_PREFIX
1035 PRI_MACROS_BROKEN
1036 INT64_MAX_EQ_LONG_MAX
1037 INT32_MAX_LT_INTMAX_MAX
1038 REPLACE_STRTOUMAX
1039 REPLACE_STRTOIMAX
1040 HAVE_DECL_STRTOUMAX
1041 HAVE_DECL_STRTOIMAX
1042 HAVE_DECL_IMAXDIV
1043 HAVE_DECL_IMAXABS
1044 GNULIB_STRTOUMAX
1045 GNULIB_STRTOIMAX
1046 GNULIB_IMAXDIV
1047 GNULIB_IMAXABS
1048 GL_GENERATE_STDINT_H_FALSE
1049 GL_GENERATE_STDINT_H_TRUE
1050 STDINT_H
1051 HAVE_SYS_INTTYPES_H
1052 HAVE_SYS_BITYPES_H
1053 HAVE_C99_STDINT_H
1054 WINT_T_SUFFIX
1055 WCHAR_T_SUFFIX
1056 SIG_ATOMIC_T_SUFFIX
1057 SIZE_T_SUFFIX
1058 PTRDIFF_T_SUFFIX
1059 HAVE_SIGNED_WINT_T
1060 HAVE_SIGNED_WCHAR_T
1061 HAVE_SIGNED_SIG_ATOMIC_T
1062 BITSIZEOF_WINT_T
1063 BITSIZEOF_WCHAR_T
1064 BITSIZEOF_SIG_ATOMIC_T
1065 BITSIZEOF_SIZE_T
1066 BITSIZEOF_PTRDIFF_T
1067 APPLE_UNIVERSAL_BUILD
1068 HAVE_STDINT_H
1069 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
1070 NEXT_STDINT_H
1071 HAVE_SYS_TYPES_H
1072 HAVE_INTTYPES_H
1073 HAVE_WCHAR_H
1074 HAVE_UNSIGNED_LONG_LONG_INT
1075 HAVE_LONG_LONG_INT
1076 GL_GENERATE_LIMITS_H_FALSE
1077 GL_GENERATE_LIMITS_H_TRUE
1078 LIMITS_H
1079 NEXT_AS_FIRST_DIRECTIVE_LIMITS_H
1080 NEXT_LIMITS_H
1081 HAVE_SYS_CDEFS_H
1082 GL_GENERATE_GLOB_H_FALSE
1083 GL_GENERATE_GLOB_H_TRUE
1084 GLOB_H
1085 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
1086 NEXT_SYS_TIME_H
1087 REPLACE_STRUCT_TIMEVAL
1088 REPLACE_GETTIMEOFDAY
1089 HAVE_TIMEZONE_T
1090 HAVE_SYS_TIME_H
1091 HAVE_STRUCT_TIMEVAL
1092 HAVE_GETTIMEOFDAY
1093 GNULIB_GETTIMEOFDAY
1094 LTLIBINTL
1095 LIBINTL
1096 WINDOWS_64_BIT_ST_SIZE
1097 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
1098 NEXT_SYS_STAT_H
1099 REPLACE_UTIMENSAT
1100 REPLACE_STAT
1101 REPLACE_MKNOD
1102 REPLACE_MKFIFO
1103 REPLACE_MKDIR
1104 REPLACE_LSTAT
1105 REPLACE_FUTIMENS
1106 REPLACE_FSTATAT
1107 REPLACE_FSTAT
1108 HAVE_UTIMENSAT
1109 HAVE_MKNODAT
1110 HAVE_MKNOD
1111 HAVE_MKFIFOAT
1112 HAVE_MKFIFO
1113 HAVE_MKDIRAT
1114 HAVE_LSTAT
1115 HAVE_LCHMOD
1116 HAVE_FUTIMENS
1117 HAVE_FSTATAT
1118 HAVE_FCHMODAT
1119 GNULIB_UTIMENSAT
1120 GNULIB_STAT
1121 GNULIB_MKNODAT
1122 GNULIB_MKNOD
1123 GNULIB_MKFIFOAT
1124 GNULIB_MKFIFO
1125 GNULIB_MKDIRAT
1126 GNULIB_LSTAT
1127 GNULIB_LCHMOD
1128 GNULIB_FUTIMENS
1129 GNULIB_FSTATAT
1130 GNULIB_FSTAT
1131 GNULIB_FCHMODAT
1132 FREXPL_LIBM
1133 HAVE_SAME_LONG_DOUBLE_AS_DOUBLE
1134 FREXP_LIBM
1135 REPLACE_TRUNCL
1136 REPLACE_TRUNCF
1137 REPLACE_TRUNC
1138 REPLACE_SQRTL
1139 REPLACE_SIGNBIT_USING_GCC
1140 REPLACE_SIGNBIT
1141 REPLACE_ROUNDL
1142 REPLACE_ROUNDF
1143 REPLACE_ROUND
1144 REPLACE_REMAINDERL
1145 REPLACE_REMAINDERF
1146 REPLACE_REMAINDER
1147 REPLACE_NAN
1148 REPLACE_MODFL
1149 REPLACE_MODFF
1150 REPLACE_MODF
1151 REPLACE_LOGBL
1152 REPLACE_LOGBF
1153 REPLACE_LOGB
1154 REPLACE_LOG2L
1155 REPLACE_LOG2F
1156 REPLACE_LOG2
1157 REPLACE_LOG1PL
1158 REPLACE_LOG1PF
1159 REPLACE_LOG1P
1160 REPLACE_LOG10L
1161 REPLACE_LOG10F
1162 REPLACE_LOG10
1163 REPLACE_LOGL
1164 REPLACE_LOGF
1165 REPLACE_LOG
1166 REPLACE_LDEXPL
1167 REPLACE_ISNAN
1168 REPLACE_ISINF
1169 REPLACE_ISFINITE
1170 REPLACE_ILOGBF
1171 REPLACE_ILOGB
1172 REPLACE_HYPOTL
1173 REPLACE_HYPOTF
1174 REPLACE_HYPOT
1175 REPLACE_HUGE_VAL
1176 REPLACE_FREXPL
1177 REPLACE_FREXP
1178 REPLACE_FREXPF
1179 REPLACE_FMODL
1180 REPLACE_FMODF
1181 REPLACE_FMOD
1182 REPLACE_FMAL
1183 REPLACE_FMAF
1184 REPLACE_FMA
1185 REPLACE_FLOORL
1186 REPLACE_FLOORF
1187 REPLACE_FLOOR
1188 REPLACE_FABSL
1189 REPLACE_EXP2L
1190 REPLACE_EXP2
1191 REPLACE_EXPM1F
1192 REPLACE_EXPM1
1193 REPLACE_CEILL
1194 REPLACE_CEILF
1195 REPLACE_CEIL
1196 REPLACE_CBRTL
1197 REPLACE_CBRTF
1198 HAVE_DECL_TRUNCL
1199 HAVE_DECL_TRUNCF
1200 HAVE_DECL_TRUNC
1201 HAVE_DECL_TANL
1202 HAVE_DECL_SQRTL
1203 HAVE_DECL_SINL
1204 HAVE_DECL_ROUNDL
1205 HAVE_DECL_ROUNDF
1206 HAVE_DECL_ROUND
1207 HAVE_DECL_RINTF
1208 HAVE_DECL_REMAINDERL
1209 HAVE_DECL_REMAINDER
1210 HAVE_DECL_LOGB
1211 HAVE_DECL_LOG2L
1212 HAVE_DECL_LOG2F
1213 HAVE_DECL_LOG2
1214 HAVE_DECL_LOG10L
1215 HAVE_DECL_LOGL
1216 HAVE_DECL_LDEXPL
1217 HAVE_DECL_FREXPL
1218 HAVE_DECL_FLOORL
1219 HAVE_DECL_FLOORF
1220 HAVE_DECL_EXPM1L
1221 HAVE_DECL_EXP2L
1222 HAVE_DECL_EXP2F
1223 HAVE_DECL_EXP2
1224 HAVE_DECL_EXPL
1225 HAVE_DECL_COSL
1226 HAVE_DECL_COPYSIGNF
1227 HAVE_DECL_CEILL
1228 HAVE_DECL_CEILF
1229 HAVE_DECL_CBRTL
1230 HAVE_DECL_CBRTF
1231 HAVE_DECL_ATANL
1232 HAVE_DECL_ASINL
1233 HAVE_DECL_ACOSL
1234 HAVE_TANHF
1235 HAVE_TANL
1236 HAVE_TANF
1237 HAVE_SQRTL
1238 HAVE_SQRTF
1239 HAVE_SINHF
1240 HAVE_SINL
1241 HAVE_SINF
1242 HAVE_RINTL
1243 HAVE_RINT
1244 HAVE_REMAINDERF
1245 HAVE_REMAINDER
1246 HAVE_POWF
1247 HAVE_MODFL
1248 HAVE_MODFF
1249 HAVE_LOGBL
1250 HAVE_LOGBF
1251 HAVE_LOG1PL
1252 HAVE_LOG1PF
1253 HAVE_LOG1P
1254 HAVE_LOG10L
1255 HAVE_LOG10F
1256 HAVE_LOGL
1257 HAVE_LOGF
1258 HAVE_LDEXPF
1259 HAVE_ISNANL
1260 HAVE_ISNAND
1261 HAVE_ISNANF
1262 HAVE_ILOGBL
1263 HAVE_ILOGBF
1264 HAVE_ILOGB
1265 HAVE_HYPOTL
1266 HAVE_HYPOTF
1267 HAVE_FREXPF
1268 HAVE_FMODL
1269 HAVE_FMODF
1270 HAVE_FMAL
1271 HAVE_FMAF
1272 HAVE_FMA
1273 HAVE_FABSL
1274 HAVE_FABSF
1275 HAVE_EXPM1F
1276 HAVE_EXPM1
1277 HAVE_EXPL
1278 HAVE_EXPF
1279 HAVE_COSHF
1280 HAVE_COSL
1281 HAVE_COSF
1282 HAVE_COPYSIGNL
1283 HAVE_COPYSIGN
1284 HAVE_CBRTL
1285 HAVE_CBRTF
1286 HAVE_CBRT
1287 HAVE_ATAN2F
1288 HAVE_ATANL
1289 HAVE_ATANF
1290 HAVE_ASINL
1291 HAVE_ASINF
1292 HAVE_ACOSL
1293 HAVE_ACOSF
1294 GNULIB_TRUNCL
1295 GNULIB_TRUNCF
1296 GNULIB_TRUNC
1297 GNULIB_TANHF
1298 GNULIB_TANL
1299 GNULIB_TANF
1300 GNULIB_SQRTL
1301 GNULIB_SQRTF
1302 GNULIB_SINHF
1303 GNULIB_SINL
1304 GNULIB_SINF
1305 GNULIB_SIGNBIT
1306 GNULIB_ROUNDL
1307 GNULIB_ROUNDF
1308 GNULIB_ROUND
1309 GNULIB_RINTL
1310 GNULIB_RINTF
1311 GNULIB_RINT
1312 GNULIB_REMAINDERL
1313 GNULIB_REMAINDERF
1314 GNULIB_REMAINDER
1315 GNULIB_POWF
1316 GNULIB_MODFL
1317 GNULIB_MODFF
1318 GNULIB_MODF
1319 GNULIB_LOGBL
1320 GNULIB_LOGBF
1321 GNULIB_LOGB
1322 GNULIB_LOG2L
1323 GNULIB_LOG2F
1324 GNULIB_LOG2
1325 GNULIB_LOG1PL
1326 GNULIB_LOG1PF
1327 GNULIB_LOG1P
1328 GNULIB_LOG10L
1329 GNULIB_LOG10F
1330 GNULIB_LOG10
1331 GNULIB_LOGL
1332 GNULIB_LOGF
1333 GNULIB_LOG
1334 GNULIB_LDEXPL
1335 GNULIB_LDEXPF
1336 GNULIB_ISNANL
1337 GNULIB_ISNAND
1338 GNULIB_ISNANF
1339 GNULIB_ISNAN
1340 GNULIB_ISINF
1341 GNULIB_ISFINITE
1342 GNULIB_ILOGBL
1343 GNULIB_ILOGBF
1344 GNULIB_ILOGB
1345 GNULIB_HYPOTL
1346 GNULIB_HYPOTF
1347 GNULIB_HYPOT
1348 GNULIB_FREXPL
1349 GNULIB_FREXP
1350 GNULIB_FREXPF
1351 GNULIB_FMODL
1352 GNULIB_FMODF
1353 GNULIB_FMOD
1354 GNULIB_FMAL
1355 GNULIB_FMAF
1356 GNULIB_FMA
1357 GNULIB_FLOORL
1358 GNULIB_FLOORF
1359 GNULIB_FLOOR
1360 GNULIB_FABSL
1361 GNULIB_FABSF
1362 GNULIB_EXPM1L
1363 GNULIB_EXPM1F
1364 GNULIB_EXPM1
1365 GNULIB_EXP2L
1366 GNULIB_EXP2F
1367 GNULIB_EXP2
1368 GNULIB_EXPL
1369 GNULIB_EXPF
1370 GNULIB_COSHF
1371 GNULIB_COSL
1372 GNULIB_COSF
1373 GNULIB_COPYSIGNL
1374 GNULIB_COPYSIGNF
1375 GNULIB_COPYSIGN
1376 GNULIB_CEILL
1377 GNULIB_CEILF
1378 GNULIB_CEIL
1379 GNULIB_CBRTL
1380 GNULIB_CBRTF
1381 GNULIB_CBRT
1382 GNULIB_ATAN2F
1383 GNULIB_ATANL
1384 GNULIB_ATANF
1385 GNULIB_ASINL
1386 GNULIB_ASINF
1387 GNULIB_ACOSL
1388 GNULIB_ACOSF
1389 GL_GENERATE_FNMATCH_H_FALSE
1390 GL_GENERATE_FNMATCH_H_TRUE
1391 FNMATCH_H
1392 REPLACE_ITOLD
1393 GL_GENERATE_FLOAT_H_FALSE
1394 GL_GENERATE_FLOAT_H_TRUE
1395 FLOAT_H
1396 NEXT_AS_FIRST_DIRECTIVE_FLOAT_H
1397 NEXT_FLOAT_H
1398 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H
1399 NEXT_FCNTL_H
1400 REPLACE_OPENAT
1401 REPLACE_OPEN
1402 REPLACE_FCNTL
1403 HAVE_OPENAT
1404 HAVE_FCNTL
1405 GNULIB_OPENAT
1406 GNULIB_OPEN
1407 GNULIB_NONBLOCKING
1408 GNULIB_FCNTL
1409 EOVERFLOW_VALUE
1410 EOVERFLOW_HIDDEN
1411 ENOLINK_VALUE
1412 ENOLINK_HIDDEN
1413 EMULTIHOP_VALUE
1414 EMULTIHOP_HIDDEN
1415 GL_GENERATE_ERRNO_H_FALSE
1416 GL_GENERATE_ERRNO_H_TRUE
1417 ERRNO_H
1418 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H
1419 NEXT_ERRNO_H
1420 HAVE_DIRENT_H
1421 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H
1422 NEXT_DIRENT_H
1423 PRAGMA_COLUMNS
1424 PRAGMA_SYSTEM_HEADER
1425 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
1426 INCLUDE_NEXT
1427 pkglibexecdir
1428 runstatedir
1429 lispdir
1430 REPLACE_FDOPENDIR
1431 REPLACE_DIRFD
1432 REPLACE_CLOSEDIR
1433 REPLACE_OPENDIR
1434 HAVE_ALPHASORT
1435 HAVE_SCANDIR
1436 HAVE_FDOPENDIR
1437 HAVE_DECL_FDOPENDIR
1438 HAVE_DECL_DIRFD
1439 HAVE_CLOSEDIR
1440 HAVE_REWINDDIR
1441 HAVE_READDIR
1442 HAVE_OPENDIR
1443 GNULIB_ALPHASORT
1444 GNULIB_SCANDIR
1445 GNULIB_FDOPENDIR
1446 GNULIB_DIRFD
1447 GNULIB_CLOSEDIR
1448 GNULIB_REWINDDIR
1449 GNULIB_READDIR
1450 GNULIB_OPENDIR
1451 HAVE_WINSOCK2_H
1452 HAVE_MSVC_INVALID_PARAMETER_HANDLER
1453 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
1454 UNISTD_H_HAVE_WINSOCK2_H
1455 REPLACE_WRITE
1456 REPLACE_USLEEP
1457 REPLACE_UNLINKAT
1458 REPLACE_UNLINK
1459 REPLACE_TTYNAME_R
1460 REPLACE_SYMLINKAT
1461 REPLACE_SYMLINK
1462 REPLACE_SLEEP
1463 REPLACE_RMDIR
1464 REPLACE_READLINKAT
1465 REPLACE_READLINK
1466 REPLACE_READ
1467 REPLACE_PWRITE
1468 REPLACE_PREAD
1469 REPLACE_LSEEK
1470 REPLACE_LINKAT
1471 REPLACE_LINK
1472 REPLACE_LCHOWN
1473 REPLACE_ISATTY
1474 REPLACE_GETPAGESIZE
1475 REPLACE_GETGROUPS
1476 REPLACE_GETLOGIN_R
1477 REPLACE_GETDTABLESIZE
1478 REPLACE_GETDOMAINNAME
1479 REPLACE_GETCWD
1480 REPLACE_FTRUNCATE
1481 REPLACE_FCHOWNAT
1482 REPLACE_DUP2
1483 REPLACE_DUP
1484 REPLACE_CLOSE
1485 REPLACE_CHOWN
1486 HAVE_SYS_PARAM_H
1487 HAVE_OS_H
1488 HAVE_DECL_TTYNAME_R
1489 HAVE_DECL_SETHOSTNAME
1490 HAVE_DECL_GETUSERSHELL
1491 HAVE_DECL_GETPAGESIZE
1492 HAVE_DECL_GETLOGIN_R
1493 HAVE_DECL_GETDOMAINNAME
1494 HAVE_DECL_FDATASYNC
1495 HAVE_DECL_FCHDIR
1496 HAVE_DECL_ENVIRON
1497 HAVE_USLEEP
1498 HAVE_UNLINKAT
1499 HAVE_SYMLINKAT
1500 HAVE_SYMLINK
1501 HAVE_SLEEP
1502 HAVE_SETHOSTNAME
1503 HAVE_READLINKAT
1504 HAVE_READLINK
1505 HAVE_PWRITE
1506 HAVE_PREAD
1507 HAVE_PIPE2
1508 HAVE_PIPE
1509 HAVE_LINKAT
1510 HAVE_LINK
1511 HAVE_LCHOWN
1512 HAVE_GROUP_MEMBER
1513 HAVE_GETPAGESIZE
1514 HAVE_GETLOGIN
1515 HAVE_GETHOSTNAME
1516 HAVE_GETGROUPS
1517 HAVE_GETDTABLESIZE
1518 HAVE_FTRUNCATE
1519 HAVE_FSYNC
1520 HAVE_FDATASYNC
1521 HAVE_FCHOWNAT
1522 HAVE_FCHDIR
1523 HAVE_FACCESSAT
1524 HAVE_EUIDACCESS
1525 HAVE_DUP3
1526 HAVE_DUP2
1527 HAVE_CHOWN
1528 GNULIB_WRITE
1529 GNULIB_USLEEP
1530 GNULIB_UNLINKAT
1531 GNULIB_UNLINK
1532 GNULIB_UNISTD_H_SIGPIPE
1533 GNULIB_UNISTD_H_NONBLOCKING
1534 GNULIB_TTYNAME_R
1535 GNULIB_SYMLINKAT
1536 GNULIB_SYMLINK
1537 GNULIB_SLEEP
1538 GNULIB_SETHOSTNAME
1539 GNULIB_RMDIR
1540 GNULIB_READLINKAT
1541 GNULIB_READLINK
1542 GNULIB_READ
1543 GNULIB_PWRITE
1544 GNULIB_PREAD
1545 GNULIB_PIPE2
1546 GNULIB_PIPE
1547 GNULIB_LSEEK
1548 GNULIB_LINKAT
1549 GNULIB_LINK
1550 GNULIB_LCHOWN
1551 GNULIB_ISATTY
1552 GNULIB_GROUP_MEMBER
1553 GNULIB_GETUSERSHELL
1554 GNULIB_GETPAGESIZE
1555 GNULIB_GETLOGIN_R
1556 GNULIB_GETLOGIN
1557 GNULIB_GETHOSTNAME
1558 GNULIB_GETGROUPS
1559 GNULIB_GETDTABLESIZE
1560 GNULIB_GETDOMAINNAME
1561 GNULIB_GETCWD
1562 GNULIB_FTRUNCATE
1563 GNULIB_FSYNC
1564 GNULIB_FDATASYNC
1565 GNULIB_FCHOWNAT
1566 GNULIB_FCHDIR
1567 GNULIB_FACCESSAT
1568 GNULIB_EUIDACCESS
1569 GNULIB_ENVIRON
1570 GNULIB_DUP3
1571 GNULIB_DUP2
1572 GNULIB_DUP
1573 GNULIB_CLOSE
1574 GNULIB_CHOWN
1575 GNULIB_CHDIR
1576 REPLACE_WCTOMB
1577 REPLACE_UNSETENV
1578 REPLACE_STRTOD
1579 REPLACE_SETENV
1580 REPLACE_REALPATH
1581 REPLACE_REALLOC
1582 REPLACE_RANDOM_R
1583 REPLACE_QSORT_R
1584 REPLACE_PUTENV
1585 REPLACE_PTSNAME_R
1586 REPLACE_PTSNAME
1587 REPLACE_MKSTEMP
1588 REPLACE_MBTOWC
1589 REPLACE_MALLOC
1590 REPLACE_CANONICALIZE_FILE_NAME
1591 REPLACE_CALLOC
1592 HAVE_DECL_UNSETENV
1593 HAVE_UNLOCKPT
1594 HAVE_SYS_LOADAVG_H
1595 HAVE_STRUCT_RANDOM_DATA
1596 HAVE_STRTOULL
1597 HAVE_STRTOLL
1598 HAVE_STRTOD
1599 HAVE_DECL_SETENV
1600 HAVE_SETENV
1601 HAVE_SECURE_GETENV
1602 HAVE_RPMATCH
1603 HAVE_REALPATH
1604 HAVE_RANDOM_R
1605 HAVE_RANDOM_H
1606 HAVE_RANDOM
1607 HAVE_QSORT_R
1608 HAVE_PTSNAME_R
1609 HAVE_PTSNAME
1610 HAVE_POSIX_OPENPT
1611 HAVE_MKSTEMPS
1612 HAVE_MKSTEMP
1613 HAVE_MKOSTEMPS
1614 HAVE_MKOSTEMP
1615 HAVE_MKDTEMP
1616 HAVE_GRANTPT
1617 HAVE_GETSUBOPT
1618 HAVE_DECL_GETLOADAVG
1619 HAVE_CANONICALIZE_FILE_NAME
1620 HAVE_ATOLL
1621 HAVE__EXIT
1622 GNULIB_WCTOMB
1623 GNULIB_UNSETENV
1624 GNULIB_UNLOCKPT
1625 GNULIB_SYSTEM_POSIX
1626 GNULIB_STRTOULL
1627 GNULIB_STRTOLL
1628 GNULIB_STRTOD
1629 GNULIB_SETENV
1630 GNULIB_SECURE_GETENV
1631 GNULIB_RPMATCH
1632 GNULIB_REALPATH
1633 GNULIB_REALLOC_POSIX
1634 GNULIB_RANDOM_R
1635 GNULIB_RANDOM
1636 GNULIB_QSORT_R
1637 GNULIB_PUTENV
1638 GNULIB_PTSNAME_R
1639 GNULIB_PTSNAME
1640 GNULIB_POSIX_OPENPT
1641 GNULIB_MKSTEMPS
1642 GNULIB_MKSTEMP
1643 GNULIB_MKOSTEMPS
1644 GNULIB_MKOSTEMP
1645 GNULIB_MKDTEMP
1646 GNULIB_MBTOWC
1647 GNULIB_MALLOC_POSIX
1648 GNULIB_GRANTPT
1649 GNULIB_GETSUBOPT
1650 GNULIB_GETLOADAVG
1651 GNULIB_CANONICALIZE_FILE_NAME
1652 GNULIB_CALLOC_POSIX
1653 GNULIB_ATOLL
1654 GNULIB__EXIT
1655 GL_GENERATE_ALLOCA_H_FALSE
1656 GL_GENERATE_ALLOCA_H_TRUE
1657 ALLOCA_H
1658 ALLOCA
1659 GL_COND_LIBTOOL_FALSE
1660 GL_COND_LIBTOOL_TRUE
1661 target_os
1662 target_vendor
1663 target_cpu
1664 target
1665 host_os
1666 host_vendor
1667 host_cpu
1668 host
1669 build_os
1670 build_vendor
1671 build_cpu
1672 build
1673 RANLIB
1674 ARFLAGS
1675 ac_ct_AR
1676 AR
1677 EGREP
1678 GREP
1679 CPP
1680 OBJEXT
1681 EXEEXT
1682 ac_ct_CC
1683 CPPFLAGS
1684 LDFLAGS
1685 CFLAGS
1686 CC
1687 MAINT
1688 MAINTAINER_MODE_FALSE
1689 MAINTAINER_MODE_TRUE
1690 target_alias
1691 host_alias
1692 build_alias
1693 LIBS
1694 ECHO_T
1695 ECHO_N
1696 ECHO_C
1697 DEFS
1698 mandir
1699 localedir
1700 libdir
1701 psdir
1702 pdfdir
1703 dvidir
1704 htmldir
1705 infodir
1706 docdir
1707 oldincludedir
1708 includedir
1709 localstatedir
1710 sharedstatedir
1711 sysconfdir
1712 datadir
1713 datarootdir
1714 libexecdir
1715 sbindir
1716 bindir
1717 program_transform_name
1718 prefix
1719 exec_prefix
1720 PACKAGE_URL
1721 PACKAGE_BUGREPORT
1722 PACKAGE_STRING
1723 PACKAGE_VERSION
1724 PACKAGE_TARNAME
1725 PACKAGE_NAME
1726 PATH_SEPARATOR
1727 SHELL'
1728 ac_subst_files=''
1729 ac_user_opts='
1730 enable_option_checking
1731 enable_maintainer_mode
1732 enable_largefile
1733 enable_dependency_tracking
1734 enable_silent_rules
1735 '
1736 ac_precious_vars='build_alias
1737 host_alias
1738 target_alias
1739 CC
1740 CFLAGS
1741 LDFLAGS
1742 LIBS
1743 CPPFLAGS
1744 CPP'
1745
1746
1747 # Initialize some variables set by options.
1748 ac_init_help=
1749 ac_init_version=false
1750 ac_unrecognized_opts=
1751 ac_unrecognized_sep=
1752 # The variables have the same names as the options, with
1753 # dashes changed to underlines.
1754 cache_file=/dev/null
1755 exec_prefix=NONE
1756 no_create=
1757 no_recursion=
1758 prefix=NONE
1759 program_prefix=NONE
1760 program_suffix=NONE
1761 program_transform_name=s,x,x,
1762 silent=
1763 site=
1764 srcdir=
1765 verbose=
1766 x_includes=NONE
1767 x_libraries=NONE
1768
1769 # Installation directory options.
1770 # These are left unexpanded so users can "make install exec_prefix=/foo"
1771 # and all the variables that are supposed to be based on exec_prefix
1772 # by default will actually change.
1773 # Use braces instead of parens because sh, perl, etc. also accept them.
1774 # (The list follows the same order as the GNU Coding Standards.)
1775 bindir='${exec_prefix}/bin'
1776 sbindir='${exec_prefix}/sbin'
1777 libexecdir='${exec_prefix}/libexec'
1778 datarootdir='${prefix}/share'
1779 datadir='${datarootdir}'
1780 sysconfdir='${prefix}/etc'
1781 sharedstatedir='${prefix}/com'
1782 localstatedir='${prefix}/var'
1783 includedir='${prefix}/include'
1784 oldincludedir='/usr/include'
1785 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1786 infodir='${datarootdir}/info'
1787 htmldir='${docdir}'
1788 dvidir='${docdir}'
1789 pdfdir='${docdir}'
1790 psdir='${docdir}'
1791 libdir='${exec_prefix}/lib'
1792 localedir='${datarootdir}/locale'
1793 mandir='${datarootdir}/man'
1794
1795 ac_prev=
1796 ac_dashdash=
1797 for ac_option
1798 do
1799 # If the previous option needs an argument, assign it.
1800 if test -n "$ac_prev"; then
1801 eval $ac_prev=\$ac_option
1802 ac_prev=
1803 continue
1804 fi
1805
1806 case $ac_option in
1807 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1808 *=) ac_optarg= ;;
1809 *) ac_optarg=yes ;;
1810 esac
1811
1812 # Accept the important Cygnus configure options, so we can diagnose typos.
1813
1814 case $ac_dashdash$ac_option in
1815 --)
1816 ac_dashdash=yes ;;
1817
1818 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1819 ac_prev=bindir ;;
1820 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1821 bindir=$ac_optarg ;;
1822
1823 -build | --build | --buil | --bui | --bu)
1824 ac_prev=build_alias ;;
1825 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1826 build_alias=$ac_optarg ;;
1827
1828 -cache-file | --cache-file | --cache-fil | --cache-fi \
1829 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1830 ac_prev=cache_file ;;
1831 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1832 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1833 cache_file=$ac_optarg ;;
1834
1835 --config-cache | -C)
1836 cache_file=config.cache ;;
1837
1838 -datadir | --datadir | --datadi | --datad)
1839 ac_prev=datadir ;;
1840 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1841 datadir=$ac_optarg ;;
1842
1843 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1844 | --dataroo | --dataro | --datar)
1845 ac_prev=datarootdir ;;
1846 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1847 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1848 datarootdir=$ac_optarg ;;
1849
1850 -disable-* | --disable-*)
1851 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1852 # Reject names that are not valid shell variable names.
1853 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1854 as_fn_error $? "invalid feature name: $ac_useropt"
1855 ac_useropt_orig=$ac_useropt
1856 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1857 case $ac_user_opts in
1858 *"
1859 "enable_$ac_useropt"
1860 "*) ;;
1861 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1862 ac_unrecognized_sep=', ';;
1863 esac
1864 eval enable_$ac_useropt=no ;;
1865
1866 -docdir | --docdir | --docdi | --doc | --do)
1867 ac_prev=docdir ;;
1868 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1869 docdir=$ac_optarg ;;
1870
1871 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1872 ac_prev=dvidir ;;
1873 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1874 dvidir=$ac_optarg ;;
1875
1876 -enable-* | --enable-*)
1877 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1878 # Reject names that are not valid shell variable names.
1879 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1880 as_fn_error $? "invalid feature name: $ac_useropt"
1881 ac_useropt_orig=$ac_useropt
1882 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1883 case $ac_user_opts in
1884 *"
1885 "enable_$ac_useropt"
1886 "*) ;;
1887 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1888 ac_unrecognized_sep=', ';;
1889 esac
1890 eval enable_$ac_useropt=\$ac_optarg ;;
1891
1892 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1893 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1894 | --exec | --exe | --ex)
1895 ac_prev=exec_prefix ;;
1896 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1897 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1898 | --exec=* | --exe=* | --ex=*)
1899 exec_prefix=$ac_optarg ;;
1900
1901 -gas | --gas | --ga | --g)
1902 # Obsolete; use --with-gas.
1903 with_gas=yes ;;
1904
1905 -help | --help | --hel | --he | -h)
1906 ac_init_help=long ;;
1907 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1908 ac_init_help=recursive ;;
1909 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1910 ac_init_help=short ;;
1911
1912 -host | --host | --hos | --ho)
1913 ac_prev=host_alias ;;
1914 -host=* | --host=* | --hos=* | --ho=*)
1915 host_alias=$ac_optarg ;;
1916
1917 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1918 ac_prev=htmldir ;;
1919 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1920 | --ht=*)
1921 htmldir=$ac_optarg ;;
1922
1923 -includedir | --includedir | --includedi | --included | --include \
1924 | --includ | --inclu | --incl | --inc)
1925 ac_prev=includedir ;;
1926 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1927 | --includ=* | --inclu=* | --incl=* | --inc=*)
1928 includedir=$ac_optarg ;;
1929
1930 -infodir | --infodir | --infodi | --infod | --info | --inf)
1931 ac_prev=infodir ;;
1932 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1933 infodir=$ac_optarg ;;
1934
1935 -libdir | --libdir | --libdi | --libd)
1936 ac_prev=libdir ;;
1937 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1938 libdir=$ac_optarg ;;
1939
1940 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1941 | --libexe | --libex | --libe)
1942 ac_prev=libexecdir ;;
1943 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1944 | --libexe=* | --libex=* | --libe=*)
1945 libexecdir=$ac_optarg ;;
1946
1947 -localedir | --localedir | --localedi | --localed | --locale)
1948 ac_prev=localedir ;;
1949 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1950 localedir=$ac_optarg ;;
1951
1952 -localstatedir | --localstatedir | --localstatedi | --localstated \
1953 | --localstate | --localstat | --localsta | --localst | --locals)
1954 ac_prev=localstatedir ;;
1955 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1956 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1957 localstatedir=$ac_optarg ;;
1958
1959 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1960 ac_prev=mandir ;;
1961 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1962 mandir=$ac_optarg ;;
1963
1964 -nfp | --nfp | --nf)
1965 # Obsolete; use --without-fp.
1966 with_fp=no ;;
1967
1968 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1969 | --no-cr | --no-c | -n)
1970 no_create=yes ;;
1971
1972 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1973 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1974 no_recursion=yes ;;
1975
1976 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1977 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1978 | --oldin | --oldi | --old | --ol | --o)
1979 ac_prev=oldincludedir ;;
1980 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1981 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1982 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1983 oldincludedir=$ac_optarg ;;
1984
1985 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1986 ac_prev=prefix ;;
1987 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1988 prefix=$ac_optarg ;;
1989
1990 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1991 | --program-pre | --program-pr | --program-p)
1992 ac_prev=program_prefix ;;
1993 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1994 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1995 program_prefix=$ac_optarg ;;
1996
1997 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1998 | --program-suf | --program-su | --program-s)
1999 ac_prev=program_suffix ;;
2000 -program-suffix=* | --program-suffix=* | --program-suffi=* \
2001 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
2002 program_suffix=$ac_optarg ;;
2003
2004 -program-transform-name | --program-transform-name \
2005 | --program-transform-nam | --program-transform-na \
2006 | --program-transform-n | --program-transform- \
2007 | --program-transform | --program-transfor \
2008 | --program-transfo | --program-transf \
2009 | --program-trans | --program-tran \
2010 | --progr-tra | --program-tr | --program-t)
2011 ac_prev=program_transform_name ;;
2012 -program-transform-name=* | --program-transform-name=* \
2013 | --program-transform-nam=* | --program-transform-na=* \
2014 | --program-transform-n=* | --program-transform-=* \
2015 | --program-transform=* | --program-transfor=* \
2016 | --program-transfo=* | --program-transf=* \
2017 | --program-trans=* | --program-tran=* \
2018 | --progr-tra=* | --program-tr=* | --program-t=*)
2019 program_transform_name=$ac_optarg ;;
2020
2021 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
2022 ac_prev=pdfdir ;;
2023 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
2024 pdfdir=$ac_optarg ;;
2025
2026 -psdir | --psdir | --psdi | --psd | --ps)
2027 ac_prev=psdir ;;
2028 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
2029 psdir=$ac_optarg ;;
2030
2031 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2032 | -silent | --silent | --silen | --sile | --sil)
2033 silent=yes ;;
2034
2035 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
2036 ac_prev=sbindir ;;
2037 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
2038 | --sbi=* | --sb=*)
2039 sbindir=$ac_optarg ;;
2040
2041 -sharedstatedir | --sharedstatedir | --sharedstatedi \
2042 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
2043 | --sharedst | --shareds | --shared | --share | --shar \
2044 | --sha | --sh)
2045 ac_prev=sharedstatedir ;;
2046 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
2047 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
2048 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
2049 | --sha=* | --sh=*)
2050 sharedstatedir=$ac_optarg ;;
2051
2052 -site | --site | --sit)
2053 ac_prev=site ;;
2054 -site=* | --site=* | --sit=*)
2055 site=$ac_optarg ;;
2056
2057 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
2058 ac_prev=srcdir ;;
2059 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
2060 srcdir=$ac_optarg ;;
2061
2062 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
2063 | --syscon | --sysco | --sysc | --sys | --sy)
2064 ac_prev=sysconfdir ;;
2065 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
2066 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
2067 sysconfdir=$ac_optarg ;;
2068
2069 -target | --target | --targe | --targ | --tar | --ta | --t)
2070 ac_prev=target_alias ;;
2071 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
2072 target_alias=$ac_optarg ;;
2073
2074 -v | -verbose | --verbose | --verbos | --verbo | --verb)
2075 verbose=yes ;;
2076
2077 -version | --version | --versio | --versi | --vers | -V)
2078 ac_init_version=: ;;
2079
2080 -with-* | --with-*)
2081 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
2082 # Reject names that are not valid shell variable names.
2083 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
2084 as_fn_error $? "invalid package name: $ac_useropt"
2085 ac_useropt_orig=$ac_useropt
2086 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
2087 case $ac_user_opts in
2088 *"
2089 "with_$ac_useropt"
2090 "*) ;;
2091 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
2092 ac_unrecognized_sep=', ';;
2093 esac
2094 eval with_$ac_useropt=\$ac_optarg ;;
2095
2096 -without-* | --without-*)
2097 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
2098 # Reject names that are not valid shell variable names.
2099 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
2100 as_fn_error $? "invalid package name: $ac_useropt"
2101 ac_useropt_orig=$ac_useropt
2102 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
2103 case $ac_user_opts in
2104 *"
2105 "with_$ac_useropt"
2106 "*) ;;
2107 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
2108 ac_unrecognized_sep=', ';;
2109 esac
2110 eval with_$ac_useropt=no ;;
2111
2112 --x)
2113 # Obsolete; use --with-x.
2114 with_x=yes ;;
2115
2116 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
2117 | --x-incl | --x-inc | --x-in | --x-i)
2118 ac_prev=x_includes ;;
2119 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
2120 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
2121 x_includes=$ac_optarg ;;
2122
2123 -x-libraries | --x-libraries | --x-librarie | --x-librari \
2124 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
2125 ac_prev=x_libraries ;;
2126 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
2127 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
2128 x_libraries=$ac_optarg ;;
2129
2130 -*) as_fn_error $? "unrecognized option: \`$ac_option'
2131 Try \`$0 --help' for more information"
2132 ;;
2133
2134 *=*)
2135 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
2136 # Reject names that are not valid shell variable names.
2137 case $ac_envvar in #(
2138 '' | [0-9]* | *[!_$as_cr_alnum]* )
2139 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
2140 esac
2141 eval $ac_envvar=\$ac_optarg
2142 export $ac_envvar ;;
2143
2144 *)
2145 # FIXME: should be removed in autoconf 3.0.
2146 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
2147 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
2148 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
2149 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
2150 ;;
2151
2152 esac
2153 done
2154
2155 if test -n "$ac_prev"; then
2156 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
2157 as_fn_error $? "missing argument to $ac_option"
2158 fi
2159
2160 if test -n "$ac_unrecognized_opts"; then
2161 case $enable_option_checking in
2162 no) ;;
2163 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
2164 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
2165 esac
2166 fi
2167
2168 # Check all directory arguments for consistency.
2169 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
2170 datadir sysconfdir sharedstatedir localstatedir includedir \
2171 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
2172 libdir localedir mandir
2173 do
2174 eval ac_val=\$$ac_var
2175 # Remove trailing slashes.
2176 case $ac_val in
2177 */ )
2178 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
2179 eval $ac_var=\$ac_val;;
2180 esac
2181 # Be sure to have absolute directory names.
2182 case $ac_val in
2183 [\\/$]* | ?:[\\/]* ) continue;;
2184 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
2185 esac
2186 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
2187 done
2188
2189 # There might be people who depend on the old broken behavior: `$host'
2190 # used to hold the argument of --host etc.
2191 # FIXME: To remove some day.
2192 build=$build_alias
2193 host=$host_alias
2194 target=$target_alias
2195
2196 # FIXME: To remove some day.
2197 if test "x$host_alias" != x; then
2198 if test "x$build_alias" = x; then
2199 cross_compiling=maybe
2200 elif test "x$build_alias" != "x$host_alias"; then
2201 cross_compiling=yes
2202 fi
2203 fi
2204
2205 ac_tool_prefix=
2206 test -n "$host_alias" && ac_tool_prefix=$host_alias-
2207
2208 test "$silent" = yes && exec 6>/dev/null
2209
2210
2211 ac_pwd=`pwd` && test -n "$ac_pwd" &&
2212 ac_ls_di=`ls -di .` &&
2213 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
2214 as_fn_error $? "working directory cannot be determined"
2215 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
2216 as_fn_error $? "pwd does not report name of working directory"
2217
2218
2219 # Find the source files, if location was not specified.
2220 if test -z "$srcdir"; then
2221 ac_srcdir_defaulted=yes
2222 # Try the directory containing this script, then the parent directory.
2223 ac_confdir=`$as_dirname -- "$as_myself" ||
2224 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
2225 X"$as_myself" : 'X\(//\)[^/]' \| \
2226 X"$as_myself" : 'X\(//\)$' \| \
2227 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
2228 $as_echo X"$as_myself" |
2229 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
2230 s//\1/
2231 q
2232 }
2233 /^X\(\/\/\)[^/].*/{
2234 s//\1/
2235 q
2236 }
2237 /^X\(\/\/\)$/{
2238 s//\1/
2239 q
2240 }
2241 /^X\(\/\).*/{
2242 s//\1/
2243 q
2244 }
2245 s/.*/./; q'`
2246 srcdir=$ac_confdir
2247 if test ! -r "$srcdir/$ac_unique_file"; then
2248 srcdir=..
2249 fi
2250 else
2251 ac_srcdir_defaulted=no
2252 fi
2253 if test ! -r "$srcdir/$ac_unique_file"; then
2254 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
2255 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
2256 fi
2257 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
2258 ac_abs_confdir=`(
2259 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
2260 pwd)`
2261 # When building in place, set srcdir=.
2262 if test "$ac_abs_confdir" = "$ac_pwd"; then
2263 srcdir=.
2264 fi
2265 # Remove unnecessary trailing slashes from srcdir.
2266 # Double slashes in file names in object file debugging info
2267 # mess up M-x gdb in Emacs.
2268 case $srcdir in
2269 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
2270 esac
2271 for ac_var in $ac_precious_vars; do
2272 eval ac_env_${ac_var}_set=\${${ac_var}+set}
2273 eval ac_env_${ac_var}_value=\$${ac_var}
2274 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
2275 eval ac_cv_env_${ac_var}_value=\$${ac_var}
2276 done
2277
2278 #
2279 # Report the --help message.
2280 #
2281 if test "$ac_init_help" = "long"; then
2282 # Omit some internal or obsolete options to make the list less imposing.
2283 # This message is too long to be a string in the A/UX 3.1 sh.
2284 cat <<_ACEOF
2285 \`configure' configures libgnu UNUSED-VERSION to adapt to many kinds of systems.
2286
2287 Usage: $0 [OPTION]... [VAR=VALUE]...
2288
2289 To assign environment variables (e.g., CC, CFLAGS...), specify them as
2290 VAR=VALUE. See below for descriptions of some of the useful variables.
2291
2292 Defaults for the options are specified in brackets.
2293
2294 Configuration:
2295 -h, --help display this help and exit
2296 --help=short display options specific to this package
2297 --help=recursive display the short help of all the included packages
2298 -V, --version display version information and exit
2299 -q, --quiet, --silent do not print \`checking ...' messages
2300 --cache-file=FILE cache test results in FILE [disabled]
2301 -C, --config-cache alias for \`--cache-file=config.cache'
2302 -n, --no-create do not create output files
2303 --srcdir=DIR find the sources in DIR [configure dir or \`..']
2304
2305 Installation directories:
2306 --prefix=PREFIX install architecture-independent files in PREFIX
2307 [$ac_default_prefix]
2308 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
2309 [PREFIX]
2310
2311 By default, \`make install' will install all the files in
2312 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
2313 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
2314 for instance \`--prefix=\$HOME'.
2315
2316 For better control, use the options below.
2317
2318 Fine tuning of the installation directories:
2319 --bindir=DIR user executables [EPREFIX/bin]
2320 --sbindir=DIR system admin executables [EPREFIX/sbin]
2321 --libexecdir=DIR program executables [EPREFIX/libexec]
2322 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
2323 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
2324 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
2325 --libdir=DIR object code libraries [EPREFIX/lib]
2326 --includedir=DIR C header files [PREFIX/include]
2327 --oldincludedir=DIR C header files for non-gcc [/usr/include]
2328 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
2329 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
2330 --infodir=DIR info documentation [DATAROOTDIR/info]
2331 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
2332 --mandir=DIR man documentation [DATAROOTDIR/man]
2333 --docdir=DIR documentation root [DATAROOTDIR/doc/libgnu]
2334 --htmldir=DIR html documentation [DOCDIR]
2335 --dvidir=DIR dvi documentation [DOCDIR]
2336 --pdfdir=DIR pdf documentation [DOCDIR]
2337 --psdir=DIR ps documentation [DOCDIR]
2338 _ACEOF
2339
2340 cat <<\_ACEOF
2341
2342 Program names:
2343 --program-prefix=PREFIX prepend PREFIX to installed program names
2344 --program-suffix=SUFFIX append SUFFIX to installed program names
2345 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
2346
2347 System types:
2348 --build=BUILD configure for building on BUILD [guessed]
2349 --host=HOST cross-compile to build programs to run on HOST [BUILD]
2350 --target=TARGET configure for building compilers for TARGET [HOST]
2351 _ACEOF
2352 fi
2353
2354 if test -n "$ac_init_help"; then
2355 case $ac_init_help in
2356 short | recursive ) echo "Configuration of libgnu UNUSED-VERSION:";;
2357 esac
2358 cat <<\_ACEOF
2359
2360 Optional Features:
2361 --disable-option-checking ignore unrecognized --enable/--with options
2362 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
2363 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
2364 --enable-maintainer-mode
2365 enable make rules and dependencies not useful (and
2366 sometimes confusing) to the casual installer
2367 --disable-largefile omit support for large files
2368 --enable-dependency-tracking
2369 do not reject slow dependency extractors
2370 --disable-dependency-tracking
2371 speeds up one-time build
2372 --enable-silent-rules less verbose build output (undo: "make V=1")
2373 --disable-silent-rules verbose build output (undo: "make V=0")
2374
2375 Some influential environment variables:
2376 CC C compiler command
2377 CFLAGS C compiler flags
2378 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2379 nonstandard directory <lib dir>
2380 LIBS libraries to pass to the linker, e.g. -l<library>
2381 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2382 you have headers in a nonstandard directory <include dir>
2383 CPP C preprocessor
2384
2385 Use these variables to override the choices made by `configure' or to help
2386 it to find libraries and programs with nonstandard names/locations.
2387
2388 Report bugs to the package provider.
2389 _ACEOF
2390 ac_status=$?
2391 fi
2392
2393 if test "$ac_init_help" = "recursive"; then
2394 # If there are subdirs, report their specific --help.
2395 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2396 test -d "$ac_dir" ||
2397 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2398 continue
2399 ac_builddir=.
2400
2401 case "$ac_dir" in
2402 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2403 *)
2404 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2405 # A ".." for each directory in $ac_dir_suffix.
2406 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2407 case $ac_top_builddir_sub in
2408 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2409 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2410 esac ;;
2411 esac
2412 ac_abs_top_builddir=$ac_pwd
2413 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2414 # for backward compatibility:
2415 ac_top_builddir=$ac_top_build_prefix
2416
2417 case $srcdir in
2418 .) # We are building in place.
2419 ac_srcdir=.
2420 ac_top_srcdir=$ac_top_builddir_sub
2421 ac_abs_top_srcdir=$ac_pwd ;;
2422 [\\/]* | ?:[\\/]* ) # Absolute name.
2423 ac_srcdir=$srcdir$ac_dir_suffix;
2424 ac_top_srcdir=$srcdir
2425 ac_abs_top_srcdir=$srcdir ;;
2426 *) # Relative name.
2427 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2428 ac_top_srcdir=$ac_top_build_prefix$srcdir
2429 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2430 esac
2431 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2432
2433 cd "$ac_dir" || { ac_status=$?; continue; }
2434 # Check for guested configure.
2435 if test -f "$ac_srcdir/configure.gnu"; then
2436 echo &&
2437 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2438 elif test -f "$ac_srcdir/configure"; then
2439 echo &&
2440 $SHELL "$ac_srcdir/configure" --help=recursive
2441 else
2442 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2443 fi || ac_status=$?
2444 cd "$ac_pwd" || { ac_status=$?; break; }
2445 done
2446 fi
2447
2448 test -n "$ac_init_help" && exit $ac_status
2449 if $ac_init_version; then
2450 cat <<\_ACEOF
2451 libgnu configure UNUSED-VERSION
2452 generated by GNU Autoconf 2.69
2453
2454 Copyright (C) 2012 Free Software Foundation, Inc.
2455 This configure script is free software; the Free Software Foundation
2456 gives unlimited permission to copy, distribute and modify it.
2457 _ACEOF
2458 exit
2459 fi
2460
2461 ## ------------------------ ##
2462 ## Autoconf initialization. ##
2463 ## ------------------------ ##
2464
2465 # ac_fn_c_try_compile LINENO
2466 # --------------------------
2467 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2468 ac_fn_c_try_compile ()
2469 {
2470 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2471 rm -f conftest.$ac_objext
2472 if { { ac_try="$ac_compile"
2473 case "(($ac_try" in
2474 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2475 *) ac_try_echo=$ac_try;;
2476 esac
2477 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2478 $as_echo "$ac_try_echo"; } >&5
2479 (eval "$ac_compile") 2>conftest.err
2480 ac_status=$?
2481 if test -s conftest.err; then
2482 grep -v '^ *+' conftest.err >conftest.er1
2483 cat conftest.er1 >&5
2484 mv -f conftest.er1 conftest.err
2485 fi
2486 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2487 test $ac_status = 0; } && {
2488 test -z "$ac_c_werror_flag" ||
2489 test ! -s conftest.err
2490 } && test -s conftest.$ac_objext; then :
2491 ac_retval=0
2492 else
2493 $as_echo "$as_me: failed program was:" >&5
2494 sed 's/^/| /' conftest.$ac_ext >&5
2495
2496 ac_retval=1
2497 fi
2498 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2499 as_fn_set_status $ac_retval
2500
2501 } # ac_fn_c_try_compile
2502
2503 # ac_fn_c_try_cpp LINENO
2504 # ----------------------
2505 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2506 ac_fn_c_try_cpp ()
2507 {
2508 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2509 if { { ac_try="$ac_cpp conftest.$ac_ext"
2510 case "(($ac_try" in
2511 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2512 *) ac_try_echo=$ac_try;;
2513 esac
2514 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2515 $as_echo "$ac_try_echo"; } >&5
2516 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2517 ac_status=$?
2518 if test -s conftest.err; then
2519 grep -v '^ *+' conftest.err >conftest.er1
2520 cat conftest.er1 >&5
2521 mv -f conftest.er1 conftest.err
2522 fi
2523 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2524 test $ac_status = 0; } > conftest.i && {
2525 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2526 test ! -s conftest.err
2527 }; then :
2528 ac_retval=0
2529 else
2530 $as_echo "$as_me: failed program was:" >&5
2531 sed 's/^/| /' conftest.$ac_ext >&5
2532
2533 ac_retval=1
2534 fi
2535 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2536 as_fn_set_status $ac_retval
2537
2538 } # ac_fn_c_try_cpp
2539
2540 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2541 # -------------------------------------------------------
2542 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2543 # the include files in INCLUDES and setting the cache variable VAR
2544 # accordingly.
2545 ac_fn_c_check_header_mongrel ()
2546 {
2547 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2548 if eval \${$3+:} false; then :
2549 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2550 $as_echo_n "checking for $2... " >&6; }
2551 if eval \${$3+:} false; then :
2552 $as_echo_n "(cached) " >&6
2553 fi
2554 eval ac_res=\$$3
2555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2556 $as_echo "$ac_res" >&6; }
2557 else
2558 # Is the header compilable?
2559 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2560 $as_echo_n "checking $2 usability... " >&6; }
2561 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2562 /* end confdefs.h. */
2563 $4
2564 #include <$2>
2565 _ACEOF
2566 if ac_fn_c_try_compile "$LINENO"; then :
2567 ac_header_compiler=yes
2568 else
2569 ac_header_compiler=no
2570 fi
2571 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2573 $as_echo "$ac_header_compiler" >&6; }
2574
2575 # Is the header present?
2576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2577 $as_echo_n "checking $2 presence... " >&6; }
2578 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2579 /* end confdefs.h. */
2580 #include <$2>
2581 _ACEOF
2582 if ac_fn_c_try_cpp "$LINENO"; then :
2583 ac_header_preproc=yes
2584 else
2585 ac_header_preproc=no
2586 fi
2587 rm -f conftest.err conftest.i conftest.$ac_ext
2588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2589 $as_echo "$ac_header_preproc" >&6; }
2590
2591 # So? What about this header?
2592 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2593 yes:no: )
2594 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2595 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2596 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2597 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2598 ;;
2599 no:yes:* )
2600 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2601 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2602 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2603 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2604 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2605 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2606 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2607 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2608 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2609 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2610 ;;
2611 esac
2612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2613 $as_echo_n "checking for $2... " >&6; }
2614 if eval \${$3+:} false; then :
2615 $as_echo_n "(cached) " >&6
2616 else
2617 eval "$3=\$ac_header_compiler"
2618 fi
2619 eval ac_res=\$$3
2620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2621 $as_echo "$ac_res" >&6; }
2622 fi
2623 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2624
2625 } # ac_fn_c_check_header_mongrel
2626
2627 # ac_fn_c_try_run LINENO
2628 # ----------------------
2629 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2630 # that executables *can* be run.
2631 ac_fn_c_try_run ()
2632 {
2633 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2634 if { { ac_try="$ac_link"
2635 case "(($ac_try" in
2636 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2637 *) ac_try_echo=$ac_try;;
2638 esac
2639 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2640 $as_echo "$ac_try_echo"; } >&5
2641 (eval "$ac_link") 2>&5
2642 ac_status=$?
2643 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2644 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2645 { { case "(($ac_try" in
2646 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2647 *) ac_try_echo=$ac_try;;
2648 esac
2649 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2650 $as_echo "$ac_try_echo"; } >&5
2651 (eval "$ac_try") 2>&5
2652 ac_status=$?
2653 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2654 test $ac_status = 0; }; }; then :
2655 ac_retval=0
2656 else
2657 $as_echo "$as_me: program exited with status $ac_status" >&5
2658 $as_echo "$as_me: failed program was:" >&5
2659 sed 's/^/| /' conftest.$ac_ext >&5
2660
2661 ac_retval=$ac_status
2662 fi
2663 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2664 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2665 as_fn_set_status $ac_retval
2666
2667 } # ac_fn_c_try_run
2668
2669 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2670 # -------------------------------------------------------
2671 # Tests whether HEADER exists and can be compiled using the include files in
2672 # INCLUDES, setting the cache variable VAR accordingly.
2673 ac_fn_c_check_header_compile ()
2674 {
2675 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2677 $as_echo_n "checking for $2... " >&6; }
2678 if eval \${$3+:} false; then :
2679 $as_echo_n "(cached) " >&6
2680 else
2681 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2682 /* end confdefs.h. */
2683 $4
2684 #include <$2>
2685 _ACEOF
2686 if ac_fn_c_try_compile "$LINENO"; then :
2687 eval "$3=yes"
2688 else
2689 eval "$3=no"
2690 fi
2691 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2692 fi
2693 eval ac_res=\$$3
2694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2695 $as_echo "$ac_res" >&6; }
2696 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2697
2698 } # ac_fn_c_check_header_compile
2699
2700 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2701 # -------------------------------------------
2702 # Tests whether TYPE exists after having included INCLUDES, setting cache
2703 # variable VAR accordingly.
2704 ac_fn_c_check_type ()
2705 {
2706 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2708 $as_echo_n "checking for $2... " >&6; }
2709 if eval \${$3+:} false; then :
2710 $as_echo_n "(cached) " >&6
2711 else
2712 eval "$3=no"
2713 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2714 /* end confdefs.h. */
2715 $4
2716 int
2717 main ()
2718 {
2719 if (sizeof ($2))
2720 return 0;
2721 ;
2722 return 0;
2723 }
2724 _ACEOF
2725 if ac_fn_c_try_compile "$LINENO"; then :
2726 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2727 /* end confdefs.h. */
2728 $4
2729 int
2730 main ()
2731 {
2732 if (sizeof (($2)))
2733 return 0;
2734 ;
2735 return 0;
2736 }
2737 _ACEOF
2738 if ac_fn_c_try_compile "$LINENO"; then :
2739
2740 else
2741 eval "$3=yes"
2742 fi
2743 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2744 fi
2745 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2746 fi
2747 eval ac_res=\$$3
2748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2749 $as_echo "$ac_res" >&6; }
2750 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2751
2752 } # ac_fn_c_check_type
2753
2754 # ac_fn_c_try_link LINENO
2755 # -----------------------
2756 # Try to link conftest.$ac_ext, and return whether this succeeded.
2757 ac_fn_c_try_link ()
2758 {
2759 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2760 rm -f conftest.$ac_objext conftest$ac_exeext
2761 if { { ac_try="$ac_link"
2762 case "(($ac_try" in
2763 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2764 *) ac_try_echo=$ac_try;;
2765 esac
2766 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2767 $as_echo "$ac_try_echo"; } >&5
2768 (eval "$ac_link") 2>conftest.err
2769 ac_status=$?
2770 if test -s conftest.err; then
2771 grep -v '^ *+' conftest.err >conftest.er1
2772 cat conftest.er1 >&5
2773 mv -f conftest.er1 conftest.err
2774 fi
2775 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2776 test $ac_status = 0; } && {
2777 test -z "$ac_c_werror_flag" ||
2778 test ! -s conftest.err
2779 } && test -s conftest$ac_exeext && {
2780 test "$cross_compiling" = yes ||
2781 test -x conftest$ac_exeext
2782 }; then :
2783 ac_retval=0
2784 else
2785 $as_echo "$as_me: failed program was:" >&5
2786 sed 's/^/| /' conftest.$ac_ext >&5
2787
2788 ac_retval=1
2789 fi
2790 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2791 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2792 # interfere with the next link command; also delete a directory that is
2793 # left behind by Apple's compiler. We do this before executing the actions.
2794 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2795 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2796 as_fn_set_status $ac_retval
2797
2798 } # ac_fn_c_try_link
2799
2800 # ac_fn_c_check_func LINENO FUNC VAR
2801 # ----------------------------------
2802 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2803 ac_fn_c_check_func ()
2804 {
2805 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2806 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2807 $as_echo_n "checking for $2... " >&6; }
2808 if eval \${$3+:} false; then :
2809 $as_echo_n "(cached) " >&6
2810 else
2811 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2812 /* end confdefs.h. */
2813 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2814 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2815 #define $2 innocuous_$2
2816
2817 /* System header to define __stub macros and hopefully few prototypes,
2818 which can conflict with char $2 (); below.
2819 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2820 <limits.h> exists even on freestanding compilers. */
2821
2822 #ifdef __STDC__
2823 # include <limits.h>
2824 #else
2825 # include <assert.h>
2826 #endif
2827
2828 #undef $2
2829
2830 /* Override any GCC internal prototype to avoid an error.
2831 Use char because int might match the return type of a GCC
2832 builtin and then its argument prototype would still apply. */
2833 #ifdef __cplusplus
2834 extern "C"
2835 #endif
2836 char $2 ();
2837 /* The GNU C library defines this for functions which it implements
2838 to always fail with ENOSYS. Some functions are actually named
2839 something starting with __ and the normal name is an alias. */
2840 #if defined __stub_$2 || defined __stub___$2
2841 choke me
2842 #endif
2843
2844 int
2845 main ()
2846 {
2847 return $2 ();
2848 ;
2849 return 0;
2850 }
2851 _ACEOF
2852 if ac_fn_c_try_link "$LINENO"; then :
2853 eval "$3=yes"
2854 else
2855 eval "$3=no"
2856 fi
2857 rm -f core conftest.err conftest.$ac_objext \
2858 conftest$ac_exeext conftest.$ac_ext
2859 fi
2860 eval ac_res=\$$3
2861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2862 $as_echo "$ac_res" >&6; }
2863 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2864
2865 } # ac_fn_c_check_func
2866
2867 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2868 # ---------------------------------------------
2869 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2870 # accordingly.
2871 ac_fn_c_check_decl ()
2872 {
2873 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2874 as_decl_name=`echo $2|sed 's/ *(.*//'`
2875 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2876 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2877 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2878 if eval \${$3+:} false; then :
2879 $as_echo_n "(cached) " >&6
2880 else
2881 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2882 /* end confdefs.h. */
2883 $4
2884 int
2885 main ()
2886 {
2887 #ifndef $as_decl_name
2888 #ifdef __cplusplus
2889 (void) $as_decl_use;
2890 #else
2891 (void) $as_decl_name;
2892 #endif
2893 #endif
2894
2895 ;
2896 return 0;
2897 }
2898 _ACEOF
2899 if ac_fn_c_try_compile "$LINENO"; then :
2900 eval "$3=yes"
2901 else
2902 eval "$3=no"
2903 fi
2904 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2905 fi
2906 eval ac_res=\$$3
2907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2908 $as_echo "$ac_res" >&6; }
2909 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2910
2911 } # ac_fn_c_check_decl
2912
2913 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2914 # --------------------------------------------
2915 # Tries to find the compile-time value of EXPR in a program that includes
2916 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2917 # computed
2918 ac_fn_c_compute_int ()
2919 {
2920 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2921 if test "$cross_compiling" = yes; then
2922 # Depending upon the size, compute the lo and hi bounds.
2923 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2924 /* end confdefs.h. */
2925 $4
2926 int
2927 main ()
2928 {
2929 static int test_array [1 - 2 * !(($2) >= 0)];
2930 test_array [0] = 0;
2931 return test_array [0];
2932
2933 ;
2934 return 0;
2935 }
2936 _ACEOF
2937 if ac_fn_c_try_compile "$LINENO"; then :
2938 ac_lo=0 ac_mid=0
2939 while :; do
2940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2941 /* end confdefs.h. */
2942 $4
2943 int
2944 main ()
2945 {
2946 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2947 test_array [0] = 0;
2948 return test_array [0];
2949
2950 ;
2951 return 0;
2952 }
2953 _ACEOF
2954 if ac_fn_c_try_compile "$LINENO"; then :
2955 ac_hi=$ac_mid; break
2956 else
2957 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2958 if test $ac_lo -le $ac_mid; then
2959 ac_lo= ac_hi=
2960 break
2961 fi
2962 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2963 fi
2964 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2965 done
2966 else
2967 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2968 /* end confdefs.h. */
2969 $4
2970 int
2971 main ()
2972 {
2973 static int test_array [1 - 2 * !(($2) < 0)];
2974 test_array [0] = 0;
2975 return test_array [0];
2976
2977 ;
2978 return 0;
2979 }
2980 _ACEOF
2981 if ac_fn_c_try_compile "$LINENO"; then :
2982 ac_hi=-1 ac_mid=-1
2983 while :; do
2984 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2985 /* end confdefs.h. */
2986 $4
2987 int
2988 main ()
2989 {
2990 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2991 test_array [0] = 0;
2992 return test_array [0];
2993
2994 ;
2995 return 0;
2996 }
2997 _ACEOF
2998 if ac_fn_c_try_compile "$LINENO"; then :
2999 ac_lo=$ac_mid; break
3000 else
3001 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
3002 if test $ac_mid -le $ac_hi; then
3003 ac_lo= ac_hi=
3004 break
3005 fi
3006 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
3007 fi
3008 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3009 done
3010 else
3011 ac_lo= ac_hi=
3012 fi
3013 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3014 fi
3015 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3016 # Binary search between lo and hi bounds.
3017 while test "x$ac_lo" != "x$ac_hi"; do
3018 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
3019 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3020 /* end confdefs.h. */
3021 $4
3022 int
3023 main ()
3024 {
3025 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
3026 test_array [0] = 0;
3027 return test_array [0];
3028
3029 ;
3030 return 0;
3031 }
3032 _ACEOF
3033 if ac_fn_c_try_compile "$LINENO"; then :
3034 ac_hi=$ac_mid
3035 else
3036 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
3037 fi
3038 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3039 done
3040 case $ac_lo in #((
3041 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
3042 '') ac_retval=1 ;;
3043 esac
3044 else
3045 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3046 /* end confdefs.h. */
3047 $4
3048 static long int longval () { return $2; }
3049 static unsigned long int ulongval () { return $2; }
3050 #include <stdio.h>
3051 #include <stdlib.h>
3052 int
3053 main ()
3054 {
3055
3056 FILE *f = fopen ("conftest.val", "w");
3057 if (! f)
3058 return 1;
3059 if (($2) < 0)
3060 {
3061 long int i = longval ();
3062 if (i != ($2))
3063 return 1;
3064 fprintf (f, "%ld", i);
3065 }
3066 else
3067 {
3068 unsigned long int i = ulongval ();
3069 if (i != ($2))
3070 return 1;
3071 fprintf (f, "%lu", i);
3072 }
3073 /* Do not output a trailing newline, as this causes \r\n confusion
3074 on some platforms. */
3075 return ferror (f) || fclose (f) != 0;
3076
3077 ;
3078 return 0;
3079 }
3080 _ACEOF
3081 if ac_fn_c_try_run "$LINENO"; then :
3082 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
3083 else
3084 ac_retval=1
3085 fi
3086 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
3087 conftest.$ac_objext conftest.beam conftest.$ac_ext
3088 rm -f conftest.val
3089
3090 fi
3091 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3092 as_fn_set_status $ac_retval
3093
3094 } # ac_fn_c_compute_int
3095 cat >config.log <<_ACEOF
3096 This file contains any messages produced by compilers while
3097 running configure, to aid debugging if configure makes a mistake.
3098
3099 It was created by libgnu $as_me UNUSED-VERSION, which was
3100 generated by GNU Autoconf 2.69. Invocation command line was
3101
3102 $ $0 $@
3103
3104 _ACEOF
3105 exec 5>>config.log
3106 {
3107 cat <<_ASUNAME
3108 ## --------- ##
3109 ## Platform. ##
3110 ## --------- ##
3111
3112 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
3113 uname -m = `(uname -m) 2>/dev/null || echo unknown`
3114 uname -r = `(uname -r) 2>/dev/null || echo unknown`
3115 uname -s = `(uname -s) 2>/dev/null || echo unknown`
3116 uname -v = `(uname -v) 2>/dev/null || echo unknown`
3117
3118 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
3119 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
3120
3121 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
3122 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
3123 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
3124 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
3125 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
3126 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
3127 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
3128
3129 _ASUNAME
3130
3131 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3132 for as_dir in $PATH
3133 do
3134 IFS=$as_save_IFS
3135 test -z "$as_dir" && as_dir=.
3136 $as_echo "PATH: $as_dir"
3137 done
3138 IFS=$as_save_IFS
3139
3140 } >&5
3141
3142 cat >&5 <<_ACEOF
3143
3144
3145 ## ----------- ##
3146 ## Core tests. ##
3147 ## ----------- ##
3148
3149 _ACEOF
3150
3151
3152 # Keep a trace of the command line.
3153 # Strip out --no-create and --no-recursion so they do not pile up.
3154 # Strip out --silent because we don't want to record it for future runs.
3155 # Also quote any args containing shell meta-characters.
3156 # Make two passes to allow for proper duplicate-argument suppression.
3157 ac_configure_args=
3158 ac_configure_args0=
3159 ac_configure_args1=
3160 ac_must_keep_next=false
3161 for ac_pass in 1 2
3162 do
3163 for ac_arg
3164 do
3165 case $ac_arg in
3166 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
3167 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
3168 | -silent | --silent | --silen | --sile | --sil)
3169 continue ;;
3170 *\'*)
3171 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
3172 esac
3173 case $ac_pass in
3174 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
3175 2)
3176 as_fn_append ac_configure_args1 " '$ac_arg'"
3177 if test $ac_must_keep_next = true; then
3178 ac_must_keep_next=false # Got value, back to normal.
3179 else
3180 case $ac_arg in
3181 *=* | --config-cache | -C | -disable-* | --disable-* \
3182 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
3183 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
3184 | -with-* | --with-* | -without-* | --without-* | --x)
3185 case "$ac_configure_args0 " in
3186 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
3187 esac
3188 ;;
3189 -* ) ac_must_keep_next=true ;;
3190 esac
3191 fi
3192 as_fn_append ac_configure_args " '$ac_arg'"
3193 ;;
3194 esac
3195 done
3196 done
3197 { ac_configure_args0=; unset ac_configure_args0;}
3198 { ac_configure_args1=; unset ac_configure_args1;}
3199
3200 # When interrupted or exit'd, cleanup temporary files, and complete
3201 # config.log. We remove comments because anyway the quotes in there
3202 # would cause problems or look ugly.
3203 # WARNING: Use '\'' to represent an apostrophe within the trap.
3204 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3205 trap 'exit_status=$?
3206 # Save into config.log some information that might help in debugging.
3207 {
3208 echo
3209
3210 $as_echo "## ---------------- ##
3211 ## Cache variables. ##
3212 ## ---------------- ##"
3213 echo
3214 # The following way of writing the cache mishandles newlines in values,
3215 (
3216 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3217 eval ac_val=\$$ac_var
3218 case $ac_val in #(
3219 *${as_nl}*)
3220 case $ac_var in #(
3221 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3222 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3223 esac
3224 case $ac_var in #(
3225 _ | IFS | as_nl) ;; #(
3226 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3227 *) { eval $ac_var=; unset $ac_var;} ;;
3228 esac ;;
3229 esac
3230 done
3231 (set) 2>&1 |
3232 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3233 *${as_nl}ac_space=\ *)
3234 sed -n \
3235 "s/'\''/'\''\\\\'\'''\''/g;
3236 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3237 ;; #(
3238 *)
3239 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3240 ;;
3241 esac |
3242 sort
3243 )
3244 echo
3245
3246 $as_echo "## ----------------- ##
3247 ## Output variables. ##
3248 ## ----------------- ##"
3249 echo
3250 for ac_var in $ac_subst_vars
3251 do
3252 eval ac_val=\$$ac_var
3253 case $ac_val in
3254 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3255 esac
3256 $as_echo "$ac_var='\''$ac_val'\''"
3257 done | sort
3258 echo
3259
3260 if test -n "$ac_subst_files"; then
3261 $as_echo "## ------------------- ##
3262 ## File substitutions. ##
3263 ## ------------------- ##"
3264 echo
3265 for ac_var in $ac_subst_files
3266 do
3267 eval ac_val=\$$ac_var
3268 case $ac_val in
3269 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3270 esac
3271 $as_echo "$ac_var='\''$ac_val'\''"
3272 done | sort
3273 echo
3274 fi
3275
3276 if test -s confdefs.h; then
3277 $as_echo "## ----------- ##
3278 ## confdefs.h. ##
3279 ## ----------- ##"
3280 echo
3281 cat confdefs.h
3282 echo
3283 fi
3284 test "$ac_signal" != 0 &&
3285 $as_echo "$as_me: caught signal $ac_signal"
3286 $as_echo "$as_me: exit $exit_status"
3287 } >&5
3288 rm -f core *.core core.conftest.* &&
3289 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3290 exit $exit_status
3291 ' 0
3292 for ac_signal in 1 2 13 15; do
3293 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3294 done
3295 ac_signal=0
3296
3297 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3298 rm -f -r conftest* confdefs.h
3299
3300 $as_echo "/* confdefs.h */" > confdefs.h
3301
3302 # Predefined preprocessor variables.
3303
3304 cat >>confdefs.h <<_ACEOF
3305 #define PACKAGE_NAME "$PACKAGE_NAME"
3306 _ACEOF
3307
3308 cat >>confdefs.h <<_ACEOF
3309 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3310 _ACEOF
3311
3312 cat >>confdefs.h <<_ACEOF
3313 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3314 _ACEOF
3315
3316 cat >>confdefs.h <<_ACEOF
3317 #define PACKAGE_STRING "$PACKAGE_STRING"
3318 _ACEOF
3319
3320 cat >>confdefs.h <<_ACEOF
3321 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3322 _ACEOF
3323
3324 cat >>confdefs.h <<_ACEOF
3325 #define PACKAGE_URL "$PACKAGE_URL"
3326 _ACEOF
3327
3328
3329 # Let the site file select an alternate cache file if it wants to.
3330 # Prefer an explicitly selected file to automatically selected ones.
3331 ac_site_file1=NONE
3332 ac_site_file2=NONE
3333 if test -n "$CONFIG_SITE"; then
3334 # We do not want a PATH search for config.site.
3335 case $CONFIG_SITE in #((
3336 -*) ac_site_file1=./$CONFIG_SITE;;
3337 */*) ac_site_file1=$CONFIG_SITE;;
3338 *) ac_site_file1=./$CONFIG_SITE;;
3339 esac
3340 elif test "x$prefix" != xNONE; then
3341 ac_site_file1=$prefix/share/config.site
3342 ac_site_file2=$prefix/etc/config.site
3343 else
3344 ac_site_file1=$ac_default_prefix/share/config.site
3345 ac_site_file2=$ac_default_prefix/etc/config.site
3346 fi
3347 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3348 do
3349 test "x$ac_site_file" = xNONE && continue
3350 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3351 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3352 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3353 sed 's/^/| /' "$ac_site_file" >&5
3354 . "$ac_site_file" \
3355 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3356 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3357 as_fn_error $? "failed to load site script $ac_site_file
3358 See \`config.log' for more details" "$LINENO" 5; }
3359 fi
3360 done
3361
3362 if test -r "$cache_file"; then
3363 # Some versions of bash will fail to source /dev/null (special files
3364 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3365 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3366 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3367 $as_echo "$as_me: loading cache $cache_file" >&6;}
3368 case $cache_file in
3369 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3370 *) . "./$cache_file";;
3371 esac
3372 fi
3373 else
3374 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3375 $as_echo "$as_me: creating cache $cache_file" >&6;}
3376 >$cache_file
3377 fi
3378
3379 gl_func_list="$gl_func_list canonicalize_file_name"
3380 gl_func_list="$gl_func_list getcwd"
3381 gl_func_list="$gl_func_list readlink"
3382 gl_func_list="$gl_func_list realpath"
3383 gl_header_list="$gl_header_list sys/param.h"
3384 gl_header_list="$gl_header_list unistd.h"
3385 gl_func_list="$gl_func_list _set_invalid_parameter_handler"
3386 gl_header_list="$gl_header_list sys/socket.h"
3387 gl_func_list="$gl_func_list fchdir"
3388 gl_header_list="$gl_header_list dirent.h"
3389 gl_func_list="$gl_func_list fcntl"
3390 gl_func_list="$gl_func_list symlink"
3391 gl_func_list="$gl_func_list fdopendir"
3392 gl_func_list="$gl_func_list mempcpy"
3393 gl_func_list="$gl_func_list btowc"
3394 gl_func_list="$gl_func_list isblank"
3395 gl_func_list="$gl_func_list iswctype"
3396 gl_func_list="$gl_func_list mbsrtowcs"
3397 gl_func_list="$gl_func_list wmemchr"
3398 gl_func_list="$gl_func_list wmemcpy"
3399 gl_func_list="$gl_func_list wmempcpy"
3400 gl_header_list="$gl_header_list wctype.h"
3401 gl_fnmatch_required=GNU
3402 gl_header_list="$gl_header_list sys/stat.h"
3403 gl_func_list="$gl_func_list fstatat"
3404 gl_func_list="$gl_func_list getdtablesize"
3405 gl_func_list="$gl_func_list getlogin_r"
3406 gl_func_list="$gl_func_list getprogname"
3407 gl_func_list="$gl_func_list getexecname"
3408 gl_header_list="$gl_header_list sys/time.h"
3409 gl_func_list="$gl_func_list gettimeofday"
3410 gl_header_list="$gl_header_list sys/cdefs.h"
3411 gl_func_list="$gl_func_list getpwnam_r"
3412 gl_header_list="$gl_header_list limits.h"
3413 gl_header_list="$gl_header_list wchar.h"
3414 gl_header_list="$gl_header_list stdint.h"
3415 gl_header_list="$gl_header_list inttypes.h"
3416 gl_func_list="$gl_func_list lstat"
3417 gl_header_list="$gl_header_list math.h"
3418 gl_func_list="$gl_func_list mbsinit"
3419 gl_func_list="$gl_func_list mbrtowc"
3420 gl_header_list="$gl_header_list sys/mman.h"
3421 gl_func_list="$gl_func_list mprotect"
3422 gl_func_list="$gl_func_list mkstemp"
3423 gl_func_list="$gl_func_list openat"
3424 gl_func_list="$gl_func_list link"
3425 gl_func_list="$gl_func_list secure_getenv"
3426 gl_func_list="$gl_func_list getuid"
3427 gl_func_list="$gl_func_list geteuid"
3428 gl_func_list="$gl_func_list getgid"
3429 gl_func_list="$gl_func_list getegid"
3430 gl_func_list="$gl_func_list setenv"
3431 gl_func_list="$gl_func_list strdup"
3432 gl_func_list="$gl_func_list pipe"
3433 gl_header_list="$gl_header_list features.h"
3434 gl_func_list="$gl_func_list iswcntrl"
3435 # Check that the precious variables saved in the cache have kept the same
3436 # value.
3437 ac_cache_corrupted=false
3438 for ac_var in $ac_precious_vars; do
3439 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3440 eval ac_new_set=\$ac_env_${ac_var}_set
3441 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3442 eval ac_new_val=\$ac_env_${ac_var}_value
3443 case $ac_old_set,$ac_new_set in
3444 set,)
3445 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3446 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3447 ac_cache_corrupted=: ;;
3448 ,set)
3449 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3450 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3451 ac_cache_corrupted=: ;;
3452 ,);;
3453 *)
3454 if test "x$ac_old_val" != "x$ac_new_val"; then
3455 # differences in whitespace do not lead to failure.
3456 ac_old_val_w=`echo x $ac_old_val`
3457 ac_new_val_w=`echo x $ac_new_val`
3458 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3459 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3460 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3461 ac_cache_corrupted=:
3462 else
3463 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3464 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3465 eval $ac_var=\$ac_old_val
3466 fi
3467 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3468 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3469 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3470 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3471 fi;;
3472 esac
3473 # Pass precious variables to config.status.
3474 if test "$ac_new_set" = set; then
3475 case $ac_new_val in
3476 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3477 *) ac_arg=$ac_var=$ac_new_val ;;
3478 esac
3479 case " $ac_configure_args " in
3480 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3481 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3482 esac
3483 fi
3484 done
3485 if $ac_cache_corrupted; then
3486 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3487 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3488 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3489 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3490 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3491 fi
3492 ## -------------------- ##
3493 ## Main body of script. ##
3494 ## -------------------- ##
3495
3496 ac_ext=c
3497 ac_cpp='$CPP $CPPFLAGS'
3498 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3499 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3500 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3501
3502
3503
3504 ac_config_headers="$ac_config_headers config.h:config.in"
3505
3506
3507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
3508 $as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
3509 # Check whether --enable-maintainer-mode was given.
3510 if test "${enable_maintainer_mode+set}" = set; then :
3511 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
3512 else
3513 USE_MAINTAINER_MODE=no
3514 fi
3515
3516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
3517 $as_echo "$USE_MAINTAINER_MODE" >&6; }
3518 if test $USE_MAINTAINER_MODE = yes; then
3519 MAINTAINER_MODE_TRUE=
3520 MAINTAINER_MODE_FALSE='#'
3521 else
3522 MAINTAINER_MODE_TRUE='#'
3523 MAINTAINER_MODE_FALSE=
3524 fi
3525
3526 MAINT=$MAINTAINER_MODE_TRUE
3527
3528
3529
3530 ac_ext=c
3531 ac_cpp='$CPP $CPPFLAGS'
3532 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3533 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3534 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3535 if test -n "$ac_tool_prefix"; then
3536 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3537 set dummy ${ac_tool_prefix}gcc; ac_word=$2
3538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3539 $as_echo_n "checking for $ac_word... " >&6; }
3540 if ${ac_cv_prog_CC+:} false; then :
3541 $as_echo_n "(cached) " >&6
3542 else
3543 if test -n "$CC"; then
3544 ac_cv_prog_CC="$CC" # Let the user override the test.
3545 else
3546 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3547 for as_dir in $PATH
3548 do
3549 IFS=$as_save_IFS
3550 test -z "$as_dir" && as_dir=.
3551 for ac_exec_ext in '' $ac_executable_extensions; do
3552 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3553 ac_cv_prog_CC="${ac_tool_prefix}gcc"
3554 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3555 break 2
3556 fi
3557 done
3558 done
3559 IFS=$as_save_IFS
3560
3561 fi
3562 fi
3563 CC=$ac_cv_prog_CC
3564 if test -n "$CC"; then
3565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3566 $as_echo "$CC" >&6; }
3567 else
3568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3569 $as_echo "no" >&6; }
3570 fi
3571
3572
3573 fi
3574 if test -z "$ac_cv_prog_CC"; then
3575 ac_ct_CC=$CC
3576 # Extract the first word of "gcc", so it can be a program name with args.
3577 set dummy gcc; 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 ${ac_cv_prog_ac_ct_CC+:} false; then :
3581 $as_echo_n "(cached) " >&6
3582 else
3583 if test -n "$ac_ct_CC"; then
3584 ac_cv_prog_ac_ct_CC="$ac_ct_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 as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3593 ac_cv_prog_ac_ct_CC="gcc"
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 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3604 if test -n "$ac_ct_CC"; then
3605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3606 $as_echo "$ac_ct_CC" >&6; }
3607 else
3608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3609 $as_echo "no" >&6; }
3610 fi
3611
3612 if test "x$ac_ct_CC" = x; then
3613 CC=""
3614 else
3615 case $cross_compiling:$ac_tool_warned in
3616 yes:)
3617 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3618 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3619 ac_tool_warned=yes ;;
3620 esac
3621 CC=$ac_ct_CC
3622 fi
3623 else
3624 CC="$ac_cv_prog_CC"
3625 fi
3626
3627 if test -z "$CC"; then
3628 if test -n "$ac_tool_prefix"; then
3629 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3630 set dummy ${ac_tool_prefix}cc; ac_word=$2
3631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3632 $as_echo_n "checking for $ac_word... " >&6; }
3633 if ${ac_cv_prog_CC+:} false; then :
3634 $as_echo_n "(cached) " >&6
3635 else
3636 if test -n "$CC"; then
3637 ac_cv_prog_CC="$CC" # Let the user override the test.
3638 else
3639 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3640 for as_dir in $PATH
3641 do
3642 IFS=$as_save_IFS
3643 test -z "$as_dir" && as_dir=.
3644 for ac_exec_ext in '' $ac_executable_extensions; do
3645 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3646 ac_cv_prog_CC="${ac_tool_prefix}cc"
3647 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3648 break 2
3649 fi
3650 done
3651 done
3652 IFS=$as_save_IFS
3653
3654 fi
3655 fi
3656 CC=$ac_cv_prog_CC
3657 if test -n "$CC"; then
3658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3659 $as_echo "$CC" >&6; }
3660 else
3661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3662 $as_echo "no" >&6; }
3663 fi
3664
3665
3666 fi
3667 fi
3668 if test -z "$CC"; then
3669 # Extract the first word of "cc", so it can be a program name with args.
3670 set dummy cc; ac_word=$2
3671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3672 $as_echo_n "checking for $ac_word... " >&6; }
3673 if ${ac_cv_prog_CC+:} false; then :
3674 $as_echo_n "(cached) " >&6
3675 else
3676 if test -n "$CC"; then
3677 ac_cv_prog_CC="$CC" # Let the user override the test.
3678 else
3679 ac_prog_rejected=no
3680 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3681 for as_dir in $PATH
3682 do
3683 IFS=$as_save_IFS
3684 test -z "$as_dir" && as_dir=.
3685 for ac_exec_ext in '' $ac_executable_extensions; do
3686 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3687 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3688 ac_prog_rejected=yes
3689 continue
3690 fi
3691 ac_cv_prog_CC="cc"
3692 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3693 break 2
3694 fi
3695 done
3696 done
3697 IFS=$as_save_IFS
3698
3699 if test $ac_prog_rejected = yes; then
3700 # We found a bogon in the path, so make sure we never use it.
3701 set dummy $ac_cv_prog_CC
3702 shift
3703 if test $# != 0; then
3704 # We chose a different compiler from the bogus one.
3705 # However, it has the same basename, so the bogon will be chosen
3706 # first if we set CC to just the basename; use the full file name.
3707 shift
3708 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3709 fi
3710 fi
3711 fi
3712 fi
3713 CC=$ac_cv_prog_CC
3714 if test -n "$CC"; then
3715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3716 $as_echo "$CC" >&6; }
3717 else
3718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3719 $as_echo "no" >&6; }
3720 fi
3721
3722
3723 fi
3724 if test -z "$CC"; then
3725 if test -n "$ac_tool_prefix"; then
3726 for ac_prog in cl.exe
3727 do
3728 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3729 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3730 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3731 $as_echo_n "checking for $ac_word... " >&6; }
3732 if ${ac_cv_prog_CC+:} false; then :
3733 $as_echo_n "(cached) " >&6
3734 else
3735 if test -n "$CC"; then
3736 ac_cv_prog_CC="$CC" # Let the user override the test.
3737 else
3738 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3739 for as_dir in $PATH
3740 do
3741 IFS=$as_save_IFS
3742 test -z "$as_dir" && as_dir=.
3743 for ac_exec_ext in '' $ac_executable_extensions; do
3744 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3745 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3746 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3747 break 2
3748 fi
3749 done
3750 done
3751 IFS=$as_save_IFS
3752
3753 fi
3754 fi
3755 CC=$ac_cv_prog_CC
3756 if test -n "$CC"; then
3757 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3758 $as_echo "$CC" >&6; }
3759 else
3760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3761 $as_echo "no" >&6; }
3762 fi
3763
3764
3765 test -n "$CC" && break
3766 done
3767 fi
3768 if test -z "$CC"; then
3769 ac_ct_CC=$CC
3770 for ac_prog in cl.exe
3771 do
3772 # Extract the first word of "$ac_prog", so it can be a program name with args.
3773 set dummy $ac_prog; ac_word=$2
3774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3775 $as_echo_n "checking for $ac_word... " >&6; }
3776 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3777 $as_echo_n "(cached) " >&6
3778 else
3779 if test -n "$ac_ct_CC"; then
3780 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3781 else
3782 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3783 for as_dir in $PATH
3784 do
3785 IFS=$as_save_IFS
3786 test -z "$as_dir" && as_dir=.
3787 for ac_exec_ext in '' $ac_executable_extensions; do
3788 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3789 ac_cv_prog_ac_ct_CC="$ac_prog"
3790 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3791 break 2
3792 fi
3793 done
3794 done
3795 IFS=$as_save_IFS
3796
3797 fi
3798 fi
3799 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3800 if test -n "$ac_ct_CC"; then
3801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3802 $as_echo "$ac_ct_CC" >&6; }
3803 else
3804 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3805 $as_echo "no" >&6; }
3806 fi
3807
3808
3809 test -n "$ac_ct_CC" && break
3810 done
3811
3812 if test "x$ac_ct_CC" = x; then
3813 CC=""
3814 else
3815 case $cross_compiling:$ac_tool_warned in
3816 yes:)
3817 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3818 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3819 ac_tool_warned=yes ;;
3820 esac
3821 CC=$ac_ct_CC
3822 fi
3823 fi
3824
3825 fi
3826
3827
3828 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3829 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3830 as_fn_error $? "no acceptable C compiler found in \$PATH
3831 See \`config.log' for more details" "$LINENO" 5; }
3832
3833 # Provide some information about the compiler.
3834 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3835 set X $ac_compile
3836 ac_compiler=$2
3837 for ac_option in --version -v -V -qversion; do
3838 { { ac_try="$ac_compiler $ac_option >&5"
3839 case "(($ac_try" in
3840 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3841 *) ac_try_echo=$ac_try;;
3842 esac
3843 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3844 $as_echo "$ac_try_echo"; } >&5
3845 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3846 ac_status=$?
3847 if test -s conftest.err; then
3848 sed '10a\
3849 ... rest of stderr output deleted ...
3850 10q' conftest.err >conftest.er1
3851 cat conftest.er1 >&5
3852 fi
3853 rm -f conftest.er1 conftest.err
3854 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3855 test $ac_status = 0; }
3856 done
3857
3858 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3859 /* end confdefs.h. */
3860
3861 int
3862 main ()
3863 {
3864
3865 ;
3866 return 0;
3867 }
3868 _ACEOF
3869 ac_clean_files_save=$ac_clean_files
3870 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3871 # Try to create an executable without -o first, disregard a.out.
3872 # It will help us diagnose broken compilers, and finding out an intuition
3873 # of exeext.
3874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3875 $as_echo_n "checking whether the C compiler works... " >&6; }
3876 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3877
3878 # The possible output files:
3879 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3880
3881 ac_rmfiles=
3882 for ac_file in $ac_files
3883 do
3884 case $ac_file in
3885 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3886 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3887 esac
3888 done
3889 rm -f $ac_rmfiles
3890
3891 if { { ac_try="$ac_link_default"
3892 case "(($ac_try" in
3893 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3894 *) ac_try_echo=$ac_try;;
3895 esac
3896 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3897 $as_echo "$ac_try_echo"; } >&5
3898 (eval "$ac_link_default") 2>&5
3899 ac_status=$?
3900 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3901 test $ac_status = 0; }; then :
3902 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3903 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3904 # in a Makefile. We should not override ac_cv_exeext if it was cached,
3905 # so that the user can short-circuit this test for compilers unknown to
3906 # Autoconf.
3907 for ac_file in $ac_files ''
3908 do
3909 test -f "$ac_file" || continue
3910 case $ac_file in
3911 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3912 ;;
3913 [ab].out )
3914 # We found the default executable, but exeext='' is most
3915 # certainly right.
3916 break;;
3917 *.* )
3918 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3919 then :; else
3920 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3921 fi
3922 # We set ac_cv_exeext here because the later test for it is not
3923 # safe: cross compilers may not add the suffix if given an `-o'
3924 # argument, so we may need to know it at that point already.
3925 # Even if this section looks crufty: it has the advantage of
3926 # actually working.
3927 break;;
3928 * )
3929 break;;
3930 esac
3931 done
3932 test "$ac_cv_exeext" = no && ac_cv_exeext=
3933
3934 else
3935 ac_file=''
3936 fi
3937 if test -z "$ac_file"; then :
3938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3939 $as_echo "no" >&6; }
3940 $as_echo "$as_me: failed program was:" >&5
3941 sed 's/^/| /' conftest.$ac_ext >&5
3942
3943 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3944 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3945 as_fn_error 77 "C compiler cannot create executables
3946 See \`config.log' for more details" "$LINENO" 5; }
3947 else
3948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3949 $as_echo "yes" >&6; }
3950 fi
3951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3952 $as_echo_n "checking for C compiler default output file name... " >&6; }
3953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3954 $as_echo "$ac_file" >&6; }
3955 ac_exeext=$ac_cv_exeext
3956
3957 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3958 ac_clean_files=$ac_clean_files_save
3959 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3960 $as_echo_n "checking for suffix of executables... " >&6; }
3961 if { { ac_try="$ac_link"
3962 case "(($ac_try" in
3963 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3964 *) ac_try_echo=$ac_try;;
3965 esac
3966 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3967 $as_echo "$ac_try_echo"; } >&5
3968 (eval "$ac_link") 2>&5
3969 ac_status=$?
3970 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3971 test $ac_status = 0; }; then :
3972 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3973 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3974 # work properly (i.e., refer to `conftest.exe'), while it won't with
3975 # `rm'.
3976 for ac_file in conftest.exe conftest conftest.*; do
3977 test -f "$ac_file" || continue
3978 case $ac_file in
3979 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3980 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3981 break;;
3982 * ) break;;
3983 esac
3984 done
3985 else
3986 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3987 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3988 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3989 See \`config.log' for more details" "$LINENO" 5; }
3990 fi
3991 rm -f conftest conftest$ac_cv_exeext
3992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3993 $as_echo "$ac_cv_exeext" >&6; }
3994
3995 rm -f conftest.$ac_ext
3996 EXEEXT=$ac_cv_exeext
3997 ac_exeext=$EXEEXT
3998 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3999 /* end confdefs.h. */
4000 #include <stdio.h>
4001 int
4002 main ()
4003 {
4004 FILE *f = fopen ("conftest.out", "w");
4005 return ferror (f) || fclose (f) != 0;
4006
4007 ;
4008 return 0;
4009 }
4010 _ACEOF
4011 ac_clean_files="$ac_clean_files conftest.out"
4012 # Check that the compiler produces executables we can run. If not, either
4013 # the compiler is broken, or we cross compile.
4014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4015 $as_echo_n "checking whether we are cross compiling... " >&6; }
4016 if test "$cross_compiling" != yes; then
4017 { { ac_try="$ac_link"
4018 case "(($ac_try" in
4019 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4020 *) ac_try_echo=$ac_try;;
4021 esac
4022 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4023 $as_echo "$ac_try_echo"; } >&5
4024 (eval "$ac_link") 2>&5
4025 ac_status=$?
4026 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4027 test $ac_status = 0; }
4028 if { ac_try='./conftest$ac_cv_exeext'
4029 { { case "(($ac_try" in
4030 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4031 *) ac_try_echo=$ac_try;;
4032 esac
4033 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4034 $as_echo "$ac_try_echo"; } >&5
4035 (eval "$ac_try") 2>&5
4036 ac_status=$?
4037 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4038 test $ac_status = 0; }; }; then
4039 cross_compiling=no
4040 else
4041 if test "$cross_compiling" = maybe; then
4042 cross_compiling=yes
4043 else
4044 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4045 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4046 as_fn_error $? "cannot run C compiled programs.
4047 If you meant to cross compile, use \`--host'.
4048 See \`config.log' for more details" "$LINENO" 5; }
4049 fi
4050 fi
4051 fi
4052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4053 $as_echo "$cross_compiling" >&6; }
4054
4055 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
4056 ac_clean_files=$ac_clean_files_save
4057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4058 $as_echo_n "checking for suffix of object files... " >&6; }
4059 if ${ac_cv_objext+:} false; then :
4060 $as_echo_n "(cached) " >&6
4061 else
4062 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4063 /* end confdefs.h. */
4064
4065 int
4066 main ()
4067 {
4068
4069 ;
4070 return 0;
4071 }
4072 _ACEOF
4073 rm -f conftest.o conftest.obj
4074 if { { ac_try="$ac_compile"
4075 case "(($ac_try" in
4076 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4077 *) ac_try_echo=$ac_try;;
4078 esac
4079 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4080 $as_echo "$ac_try_echo"; } >&5
4081 (eval "$ac_compile") 2>&5
4082 ac_status=$?
4083 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4084 test $ac_status = 0; }; then :
4085 for ac_file in conftest.o conftest.obj conftest.*; do
4086 test -f "$ac_file" || continue;
4087 case $ac_file in
4088 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
4089 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4090 break;;
4091 esac
4092 done
4093 else
4094 $as_echo "$as_me: failed program was:" >&5
4095 sed 's/^/| /' conftest.$ac_ext >&5
4096
4097 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4098 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4099 as_fn_error $? "cannot compute suffix of object files: cannot compile
4100 See \`config.log' for more details" "$LINENO" 5; }
4101 fi
4102 rm -f conftest.$ac_cv_objext conftest.$ac_ext
4103 fi
4104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4105 $as_echo "$ac_cv_objext" >&6; }
4106 OBJEXT=$ac_cv_objext
4107 ac_objext=$OBJEXT
4108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4109 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4110 if ${ac_cv_c_compiler_gnu+:} false; then :
4111 $as_echo_n "(cached) " >&6
4112 else
4113 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4114 /* end confdefs.h. */
4115
4116 int
4117 main ()
4118 {
4119 #ifndef __GNUC__
4120 choke me
4121 #endif
4122
4123 ;
4124 return 0;
4125 }
4126 _ACEOF
4127 if ac_fn_c_try_compile "$LINENO"; then :
4128 ac_compiler_gnu=yes
4129 else
4130 ac_compiler_gnu=no
4131 fi
4132 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4133 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4134
4135 fi
4136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4137 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
4138 if test $ac_compiler_gnu = yes; then
4139 GCC=yes
4140 else
4141 GCC=
4142 fi
4143 ac_test_CFLAGS=${CFLAGS+set}
4144 ac_save_CFLAGS=$CFLAGS
4145 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4146 $as_echo_n "checking whether $CC accepts -g... " >&6; }
4147 if ${ac_cv_prog_cc_g+:} false; then :
4148 $as_echo_n "(cached) " >&6
4149 else
4150 ac_save_c_werror_flag=$ac_c_werror_flag
4151 ac_c_werror_flag=yes
4152 ac_cv_prog_cc_g=no
4153 CFLAGS="-g"
4154 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4155 /* end confdefs.h. */
4156
4157 int
4158 main ()
4159 {
4160
4161 ;
4162 return 0;
4163 }
4164 _ACEOF
4165 if ac_fn_c_try_compile "$LINENO"; then :
4166 ac_cv_prog_cc_g=yes
4167 else
4168 CFLAGS=""
4169 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4170 /* end confdefs.h. */
4171
4172 int
4173 main ()
4174 {
4175
4176 ;
4177 return 0;
4178 }
4179 _ACEOF
4180 if ac_fn_c_try_compile "$LINENO"; then :
4181
4182 else
4183 ac_c_werror_flag=$ac_save_c_werror_flag
4184 CFLAGS="-g"
4185 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4186 /* end confdefs.h. */
4187
4188 int
4189 main ()
4190 {
4191
4192 ;
4193 return 0;
4194 }
4195 _ACEOF
4196 if ac_fn_c_try_compile "$LINENO"; then :
4197 ac_cv_prog_cc_g=yes
4198 fi
4199 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4200 fi
4201 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4202 fi
4203 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4204 ac_c_werror_flag=$ac_save_c_werror_flag
4205 fi
4206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4207 $as_echo "$ac_cv_prog_cc_g" >&6; }
4208 if test "$ac_test_CFLAGS" = set; then
4209 CFLAGS=$ac_save_CFLAGS
4210 elif test $ac_cv_prog_cc_g = yes; then
4211 if test "$GCC" = yes; then
4212 CFLAGS="-g -O2"
4213 else
4214 CFLAGS="-g"
4215 fi
4216 else
4217 if test "$GCC" = yes; then
4218 CFLAGS="-O2"
4219 else
4220 CFLAGS=
4221 fi
4222 fi
4223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4224 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4225 if ${ac_cv_prog_cc_c89+:} false; then :
4226 $as_echo_n "(cached) " >&6
4227 else
4228 ac_cv_prog_cc_c89=no
4229 ac_save_CC=$CC
4230 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4231 /* end confdefs.h. */
4232 #include <stdarg.h>
4233 #include <stdio.h>
4234 struct stat;
4235 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4236 struct buf { int x; };
4237 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4238 static char *e (p, i)
4239 char **p;
4240 int i;
4241 {
4242 return p[i];
4243 }
4244 static char *f (char * (*g) (char **, int), char **p, ...)
4245 {
4246 char *s;
4247 va_list v;
4248 va_start (v,p);
4249 s = g (p, va_arg (v,int));
4250 va_end (v);
4251 return s;
4252 }
4253
4254 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
4255 function prototypes and stuff, but not '\xHH' hex character constants.
4256 These don't provoke an error unfortunately, instead are silently treated
4257 as 'x'. The following induces an error, until -std is added to get
4258 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
4259 array size at least. It's necessary to write '\x00'==0 to get something
4260 that's true only with -std. */
4261 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4262
4263 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4264 inside strings and character constants. */
4265 #define FOO(x) 'x'
4266 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4267
4268 int test (int i, double x);
4269 struct s1 {int (*f) (int a);};
4270 struct s2 {int (*f) (double a);};
4271 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4272 int argc;
4273 char **argv;
4274 int
4275 main ()
4276 {
4277 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4278 ;
4279 return 0;
4280 }
4281 _ACEOF
4282 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4283 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4284 do
4285 CC="$ac_save_CC $ac_arg"
4286 if ac_fn_c_try_compile "$LINENO"; then :
4287 ac_cv_prog_cc_c89=$ac_arg
4288 fi
4289 rm -f core conftest.err conftest.$ac_objext
4290 test "x$ac_cv_prog_cc_c89" != "xno" && break
4291 done
4292 rm -f conftest.$ac_ext
4293 CC=$ac_save_CC
4294
4295 fi
4296 # AC_CACHE_VAL
4297 case "x$ac_cv_prog_cc_c89" in
4298 x)
4299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4300 $as_echo "none needed" >&6; } ;;
4301 xno)
4302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4303 $as_echo "unsupported" >&6; } ;;
4304 *)
4305 CC="$CC $ac_cv_prog_cc_c89"
4306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4307 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
4308 esac
4309 if test "x$ac_cv_prog_cc_c89" != xno; then :
4310
4311 fi
4312
4313 ac_ext=c
4314 ac_cpp='$CPP $CPPFLAGS'
4315 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4316 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4317 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4318
4319 ac_aux_dir=
4320 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
4321 if test -f "$ac_dir/install-sh"; then
4322 ac_aux_dir=$ac_dir
4323 ac_install_sh="$ac_aux_dir/install-sh -c"
4324 break
4325 elif test -f "$ac_dir/install.sh"; then
4326 ac_aux_dir=$ac_dir
4327 ac_install_sh="$ac_aux_dir/install.sh -c"
4328 break
4329 elif test -f "$ac_dir/shtool"; then
4330 ac_aux_dir=$ac_dir
4331 ac_install_sh="$ac_aux_dir/shtool install -c"
4332 break
4333 fi
4334 done
4335 if test -z "$ac_aux_dir"; then
4336 as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
4337 fi
4338
4339 # These three variables are undocumented and unsupported,
4340 # and are intended to be withdrawn in a future Autoconf release.
4341 # They can cause serious problems if a builder's source tree is in a directory
4342 # whose full name contains unusual characters.
4343 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
4344 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
4345 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
4346
4347
4348 # Expand $ac_aux_dir to an absolute path.
4349 am_aux_dir=`cd "$ac_aux_dir" && pwd`
4350
4351 ac_ext=c
4352 ac_cpp='$CPP $CPPFLAGS'
4353 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4354 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4355 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4356 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
4357 $as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
4358 if ${am_cv_prog_cc_c_o+:} false; then :
4359 $as_echo_n "(cached) " >&6
4360 else
4361 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4362 /* end confdefs.h. */
4363
4364 int
4365 main ()
4366 {
4367
4368 ;
4369 return 0;
4370 }
4371 _ACEOF
4372 # Make sure it works both with $CC and with simple cc.
4373 # Following AC_PROG_CC_C_O, we do the test twice because some
4374 # compilers refuse to overwrite an existing .o file with -o,
4375 # though they will create one.
4376 am_cv_prog_cc_c_o=yes
4377 for am_i in 1 2; do
4378 if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
4379 ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
4380 ac_status=$?
4381 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4382 (exit $ac_status); } \
4383 && test -f conftest2.$ac_objext; then
4384 : OK
4385 else
4386 am_cv_prog_cc_c_o=no
4387 break
4388 fi
4389 done
4390 rm -f core conftest*
4391 unset am_i
4392 fi
4393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
4394 $as_echo "$am_cv_prog_cc_c_o" >&6; }
4395 if test "$am_cv_prog_cc_c_o" != yes; then
4396 # Losing compiler, so override with the script.
4397 # FIXME: It is wrong to rewrite CC.
4398 # But if we don't then we get into trouble of one sort or another.
4399 # A longer-term fix would be to have automake use am__CC in this case,
4400 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
4401 CC="$am_aux_dir/compile $CC"
4402 fi
4403 ac_ext=c
4404 ac_cpp='$CPP $CPPFLAGS'
4405 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4406 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4407 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4408
4409
4410
4411 ac_ext=c
4412 ac_cpp='$CPP $CPPFLAGS'
4413 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4414 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4415 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4416 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
4417 $as_echo_n "checking how to run the C preprocessor... " >&6; }
4418 # On Suns, sometimes $CPP names a directory.
4419 if test -n "$CPP" && test -d "$CPP"; then
4420 CPP=
4421 fi
4422 if test -z "$CPP"; then
4423 if ${ac_cv_prog_CPP+:} false; then :
4424 $as_echo_n "(cached) " >&6
4425 else
4426 # Double quotes because CPP needs to be expanded
4427 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4428 do
4429 ac_preproc_ok=false
4430 for ac_c_preproc_warn_flag in '' yes
4431 do
4432 # Use a header file that comes with gcc, so configuring glibc
4433 # with a fresh cross-compiler works.
4434 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4435 # <limits.h> exists even on freestanding compilers.
4436 # On the NeXT, cc -E runs the code through the compiler's parser,
4437 # not just through cpp. "Syntax error" is here to catch this case.
4438 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4439 /* end confdefs.h. */
4440 #ifdef __STDC__
4441 # include <limits.h>
4442 #else
4443 # include <assert.h>
4444 #endif
4445 Syntax error
4446 _ACEOF
4447 if ac_fn_c_try_cpp "$LINENO"; then :
4448
4449 else
4450 # Broken: fails on valid input.
4451 continue
4452 fi
4453 rm -f conftest.err conftest.i conftest.$ac_ext
4454
4455 # OK, works on sane cases. Now check whether nonexistent headers
4456 # can be detected and how.
4457 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4458 /* end confdefs.h. */
4459 #include <ac_nonexistent.h>
4460 _ACEOF
4461 if ac_fn_c_try_cpp "$LINENO"; then :
4462 # Broken: success on invalid input.
4463 continue
4464 else
4465 # Passes both tests.
4466 ac_preproc_ok=:
4467 break
4468 fi
4469 rm -f conftest.err conftest.i conftest.$ac_ext
4470
4471 done
4472 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4473 rm -f conftest.i conftest.err conftest.$ac_ext
4474 if $ac_preproc_ok; then :
4475 break
4476 fi
4477
4478 done
4479 ac_cv_prog_CPP=$CPP
4480
4481 fi
4482 CPP=$ac_cv_prog_CPP
4483 else
4484 ac_cv_prog_CPP=$CPP
4485 fi
4486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
4487 $as_echo "$CPP" >&6; }
4488 ac_preproc_ok=false
4489 for ac_c_preproc_warn_flag in '' yes
4490 do
4491 # Use a header file that comes with gcc, so configuring glibc
4492 # with a fresh cross-compiler works.
4493 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4494 # <limits.h> exists even on freestanding compilers.
4495 # On the NeXT, cc -E runs the code through the compiler's parser,
4496 # not just through cpp. "Syntax error" is here to catch this case.
4497 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4498 /* end confdefs.h. */
4499 #ifdef __STDC__
4500 # include <limits.h>
4501 #else
4502 # include <assert.h>
4503 #endif
4504 Syntax error
4505 _ACEOF
4506 if ac_fn_c_try_cpp "$LINENO"; then :
4507
4508 else
4509 # Broken: fails on valid input.
4510 continue
4511 fi
4512 rm -f conftest.err conftest.i conftest.$ac_ext
4513
4514 # OK, works on sane cases. Now check whether nonexistent headers
4515 # can be detected and how.
4516 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4517 /* end confdefs.h. */
4518 #include <ac_nonexistent.h>
4519 _ACEOF
4520 if ac_fn_c_try_cpp "$LINENO"; then :
4521 # Broken: success on invalid input.
4522 continue
4523 else
4524 # Passes both tests.
4525 ac_preproc_ok=:
4526 break
4527 fi
4528 rm -f conftest.err conftest.i conftest.$ac_ext
4529
4530 done
4531 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4532 rm -f conftest.i conftest.err conftest.$ac_ext
4533 if $ac_preproc_ok; then :
4534
4535 else
4536 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4537 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4538 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
4539 See \`config.log' for more details" "$LINENO" 5; }
4540 fi
4541
4542 ac_ext=c
4543 ac_cpp='$CPP $CPPFLAGS'
4544 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4545 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4546 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4547
4548
4549 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
4550 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
4551 if ${ac_cv_path_GREP+:} false; then :
4552 $as_echo_n "(cached) " >&6
4553 else
4554 if test -z "$GREP"; then
4555 ac_path_GREP_found=false
4556 # Loop through the user's path and test for each of PROGNAME-LIST
4557 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4558 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4559 do
4560 IFS=$as_save_IFS
4561 test -z "$as_dir" && as_dir=.
4562 for ac_prog in grep ggrep; do
4563 for ac_exec_ext in '' $ac_executable_extensions; do
4564 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
4565 as_fn_executable_p "$ac_path_GREP" || continue
4566 # Check for GNU ac_path_GREP and select it if it is found.
4567 # Check for GNU $ac_path_GREP
4568 case `"$ac_path_GREP" --version 2>&1` in
4569 *GNU*)
4570 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4571 *)
4572 ac_count=0
4573 $as_echo_n 0123456789 >"conftest.in"
4574 while :
4575 do
4576 cat "conftest.in" "conftest.in" >"conftest.tmp"
4577 mv "conftest.tmp" "conftest.in"
4578 cp "conftest.in" "conftest.nl"
4579 $as_echo 'GREP' >> "conftest.nl"
4580 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4581 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4582 as_fn_arith $ac_count + 1 && ac_count=$as_val
4583 if test $ac_count -gt ${ac_path_GREP_max-0}; then
4584 # Best one so far, save it but keep looking for a better one
4585 ac_cv_path_GREP="$ac_path_GREP"
4586 ac_path_GREP_max=$ac_count
4587 fi
4588 # 10*(2^10) chars as input seems more than enough
4589 test $ac_count -gt 10 && break
4590 done
4591 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4592 esac
4593
4594 $ac_path_GREP_found && break 3
4595 done
4596 done
4597 done
4598 IFS=$as_save_IFS
4599 if test -z "$ac_cv_path_GREP"; then
4600 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4601 fi
4602 else
4603 ac_cv_path_GREP=$GREP
4604 fi
4605
4606 fi
4607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4608 $as_echo "$ac_cv_path_GREP" >&6; }
4609 GREP="$ac_cv_path_GREP"
4610
4611
4612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4613 $as_echo_n "checking for egrep... " >&6; }
4614 if ${ac_cv_path_EGREP+:} false; then :
4615 $as_echo_n "(cached) " >&6
4616 else
4617 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4618 then ac_cv_path_EGREP="$GREP -E"
4619 else
4620 if test -z "$EGREP"; then
4621 ac_path_EGREP_found=false
4622 # Loop through the user's path and test for each of PROGNAME-LIST
4623 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4624 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4625 do
4626 IFS=$as_save_IFS
4627 test -z "$as_dir" && as_dir=.
4628 for ac_prog in egrep; do
4629 for ac_exec_ext in '' $ac_executable_extensions; do
4630 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4631 as_fn_executable_p "$ac_path_EGREP" || continue
4632 # Check for GNU ac_path_EGREP and select it if it is found.
4633 # Check for GNU $ac_path_EGREP
4634 case `"$ac_path_EGREP" --version 2>&1` in
4635 *GNU*)
4636 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4637 *)
4638 ac_count=0
4639 $as_echo_n 0123456789 >"conftest.in"
4640 while :
4641 do
4642 cat "conftest.in" "conftest.in" >"conftest.tmp"
4643 mv "conftest.tmp" "conftest.in"
4644 cp "conftest.in" "conftest.nl"
4645 $as_echo 'EGREP' >> "conftest.nl"
4646 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4647 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4648 as_fn_arith $ac_count + 1 && ac_count=$as_val
4649 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4650 # Best one so far, save it but keep looking for a better one
4651 ac_cv_path_EGREP="$ac_path_EGREP"
4652 ac_path_EGREP_max=$ac_count
4653 fi
4654 # 10*(2^10) chars as input seems more than enough
4655 test $ac_count -gt 10 && break
4656 done
4657 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4658 esac
4659
4660 $ac_path_EGREP_found && break 3
4661 done
4662 done
4663 done
4664 IFS=$as_save_IFS
4665 if test -z "$ac_cv_path_EGREP"; then
4666 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4667 fi
4668 else
4669 ac_cv_path_EGREP=$EGREP
4670 fi
4671
4672 fi
4673 fi
4674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4675 $as_echo "$ac_cv_path_EGREP" >&6; }
4676 EGREP="$ac_cv_path_EGREP"
4677
4678
4679 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4680 $as_echo_n "checking for ANSI C header files... " >&6; }
4681 if ${ac_cv_header_stdc+:} false; then :
4682 $as_echo_n "(cached) " >&6
4683 else
4684 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4685 /* end confdefs.h. */
4686 #include <stdlib.h>
4687 #include <stdarg.h>
4688 #include <string.h>
4689 #include <float.h>
4690
4691 int
4692 main ()
4693 {
4694
4695 ;
4696 return 0;
4697 }
4698 _ACEOF
4699 if ac_fn_c_try_compile "$LINENO"; then :
4700 ac_cv_header_stdc=yes
4701 else
4702 ac_cv_header_stdc=no
4703 fi
4704 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4705
4706 if test $ac_cv_header_stdc = yes; then
4707 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4708 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4709 /* end confdefs.h. */
4710 #include <string.h>
4711
4712 _ACEOF
4713 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4714 $EGREP "memchr" >/dev/null 2>&1; then :
4715
4716 else
4717 ac_cv_header_stdc=no
4718 fi
4719 rm -f conftest*
4720
4721 fi
4722
4723 if test $ac_cv_header_stdc = yes; then
4724 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4725 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4726 /* end confdefs.h. */
4727 #include <stdlib.h>
4728
4729 _ACEOF
4730 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4731 $EGREP "free" >/dev/null 2>&1; then :
4732
4733 else
4734 ac_cv_header_stdc=no
4735 fi
4736 rm -f conftest*
4737
4738 fi
4739
4740 if test $ac_cv_header_stdc = yes; then
4741 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4742 if test "$cross_compiling" = yes; then :
4743 :
4744 else
4745 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4746 /* end confdefs.h. */
4747 #include <ctype.h>
4748 #include <stdlib.h>
4749 #if ((' ' & 0x0FF) == 0x020)
4750 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4751 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4752 #else
4753 # define ISLOWER(c) \
4754 (('a' <= (c) && (c) <= 'i') \
4755 || ('j' <= (c) && (c) <= 'r') \
4756 || ('s' <= (c) && (c) <= 'z'))
4757 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4758 #endif
4759
4760 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4761 int
4762 main ()
4763 {
4764 int i;
4765 for (i = 0; i < 256; i++)
4766 if (XOR (islower (i), ISLOWER (i))
4767 || toupper (i) != TOUPPER (i))
4768 return 2;
4769 return 0;
4770 }
4771 _ACEOF
4772 if ac_fn_c_try_run "$LINENO"; then :
4773
4774 else
4775 ac_cv_header_stdc=no
4776 fi
4777 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4778 conftest.$ac_objext conftest.beam conftest.$ac_ext
4779 fi
4780
4781 fi
4782 fi
4783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4784 $as_echo "$ac_cv_header_stdc" >&6; }
4785 if test $ac_cv_header_stdc = yes; then
4786
4787 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
4788
4789 fi
4790
4791 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
4792 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4793 inttypes.h stdint.h unistd.h
4794 do :
4795 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4796 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4797 "
4798 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4799 cat >>confdefs.h <<_ACEOF
4800 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4801 _ACEOF
4802
4803 fi
4804
4805 done
4806
4807
4808
4809 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4810 if test "x$ac_cv_header_minix_config_h" = xyes; then :
4811 MINIX=yes
4812 else
4813 MINIX=
4814 fi
4815
4816
4817 if test "$MINIX" = yes; then
4818
4819 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
4820
4821
4822 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
4823
4824
4825 $as_echo "#define _MINIX 1" >>confdefs.h
4826
4827
4828 $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h
4829
4830 fi
4831
4832
4833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4834 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4835 if ${ac_cv_safe_to_define___extensions__+:} false; then :
4836 $as_echo_n "(cached) " >&6
4837 else
4838 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4839 /* end confdefs.h. */
4840
4841 # define __EXTENSIONS__ 1
4842 $ac_includes_default
4843 int
4844 main ()
4845 {
4846
4847 ;
4848 return 0;
4849 }
4850 _ACEOF
4851 if ac_fn_c_try_compile "$LINENO"; then :
4852 ac_cv_safe_to_define___extensions__=yes
4853 else
4854 ac_cv_safe_to_define___extensions__=no
4855 fi
4856 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4857 fi
4858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4859 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
4860 test $ac_cv_safe_to_define___extensions__ = yes &&
4861 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
4862
4863 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
4864
4865 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
4866
4867 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
4868
4869 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
4870
4871 $as_echo "#define __STDC_WANT_IEC_60559_ATTRIBS_EXT__ 1" >>confdefs.h
4872
4873 $as_echo "#define __STDC_WANT_IEC_60559_BFP_EXT__ 1" >>confdefs.h
4874
4875 $as_echo "#define __STDC_WANT_IEC_60559_DFP_EXT__ 1" >>confdefs.h
4876
4877 $as_echo "#define __STDC_WANT_IEC_60559_FUNCS_EXT__ 1" >>confdefs.h
4878
4879 $as_echo "#define __STDC_WANT_IEC_60559_TYPES_EXT__ 1" >>confdefs.h
4880
4881 $as_echo "#define __STDC_WANT_LIB_EXT2__ 1" >>confdefs.h
4882
4883 $as_echo "#define __STDC_WANT_MATH_SPEC_FUNCS__ 1" >>confdefs.h
4884
4885 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
4886
4887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5
4888 $as_echo_n "checking whether _XOPEN_SOURCE should be defined... " >&6; }
4889 if ${ac_cv_should_define__xopen_source+:} false; then :
4890 $as_echo_n "(cached) " >&6
4891 else
4892 ac_cv_should_define__xopen_source=no
4893 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4894 /* end confdefs.h. */
4895
4896 #include <wchar.h>
4897 mbstate_t x;
4898 int
4899 main ()
4900 {
4901
4902 ;
4903 return 0;
4904 }
4905 _ACEOF
4906 if ac_fn_c_try_compile "$LINENO"; then :
4907
4908 else
4909 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4910 /* end confdefs.h. */
4911
4912 #define _XOPEN_SOURCE 500
4913 #include <wchar.h>
4914 mbstate_t x;
4915 int
4916 main ()
4917 {
4918
4919 ;
4920 return 0;
4921 }
4922 _ACEOF
4923 if ac_fn_c_try_compile "$LINENO"; then :
4924 ac_cv_should_define__xopen_source=yes
4925 fi
4926 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4927 fi
4928 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4929 fi
4930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5
4931 $as_echo "$ac_cv_should_define__xopen_source" >&6; }
4932 test $ac_cv_should_define__xopen_source = yes &&
4933 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
4934
4935
4936
4937
4938
4939
4940
4941
4942
4943
4944
4945 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
4946 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
4947 if ${gl_cv_c_amsterdam_compiler+:} false; then :
4948 $as_echo_n "(cached) " >&6
4949 else
4950
4951 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4952 /* end confdefs.h. */
4953
4954 #ifdef __ACK__
4955 Amsterdam
4956 #endif
4957
4958 _ACEOF
4959 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4960 $EGREP "Amsterdam" >/dev/null 2>&1; then :
4961 gl_cv_c_amsterdam_compiler=yes
4962 else
4963 gl_cv_c_amsterdam_compiler=no
4964 fi
4965 rm -f conftest*
4966
4967
4968 fi
4969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
4970 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
4971
4972 if test $gl_cv_c_amsterdam_compiler = yes; then
4973 if test -z "$AR"; then
4974 AR='cc -c.a'
4975 fi
4976 if test -z "$ARFLAGS"; then
4977 ARFLAGS='-o'
4978 fi
4979 else
4980 if test -n "$ac_tool_prefix"; then
4981 for ac_prog in ar lib "link -lib"
4982 do
4983 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4984 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4986 $as_echo_n "checking for $ac_word... " >&6; }
4987 if ${ac_cv_prog_AR+:} false; then :
4988 $as_echo_n "(cached) " >&6
4989 else
4990 if test -n "$AR"; then
4991 ac_cv_prog_AR="$AR" # Let the user override the test.
4992 else
4993 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4994 for as_dir in $PATH
4995 do
4996 IFS=$as_save_IFS
4997 test -z "$as_dir" && as_dir=.
4998 for ac_exec_ext in '' $ac_executable_extensions; do
4999 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5000 ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
5001 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5002 break 2
5003 fi
5004 done
5005 done
5006 IFS=$as_save_IFS
5007
5008 fi
5009 fi
5010 AR=$ac_cv_prog_AR
5011 if test -n "$AR"; then
5012 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
5013 $as_echo "$AR" >&6; }
5014 else
5015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5016 $as_echo "no" >&6; }
5017 fi
5018
5019
5020 test -n "$AR" && break
5021 done
5022 fi
5023 if test -z "$AR"; then
5024 ac_ct_AR=$AR
5025 for ac_prog in ar lib "link -lib"
5026 do
5027 # Extract the first word of "$ac_prog", so it can be a program name with args.
5028 set dummy $ac_prog; ac_word=$2
5029 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5030 $as_echo_n "checking for $ac_word... " >&6; }
5031 if ${ac_cv_prog_ac_ct_AR+:} false; then :
5032 $as_echo_n "(cached) " >&6
5033 else
5034 if test -n "$ac_ct_AR"; then
5035 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
5036 else
5037 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5038 for as_dir in $PATH
5039 do
5040 IFS=$as_save_IFS
5041 test -z "$as_dir" && as_dir=.
5042 for ac_exec_ext in '' $ac_executable_extensions; do
5043 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5044 ac_cv_prog_ac_ct_AR="$ac_prog"
5045 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5046 break 2
5047 fi
5048 done
5049 done
5050 IFS=$as_save_IFS
5051
5052 fi
5053 fi
5054 ac_ct_AR=$ac_cv_prog_ac_ct_AR
5055 if test -n "$ac_ct_AR"; then
5056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
5057 $as_echo "$ac_ct_AR" >&6; }
5058 else
5059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5060 $as_echo "no" >&6; }
5061 fi
5062
5063
5064 test -n "$ac_ct_AR" && break
5065 done
5066
5067 if test "x$ac_ct_AR" = x; then
5068 AR="false"
5069 else
5070 case $cross_compiling:$ac_tool_warned in
5071 yes:)
5072 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5073 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5074 ac_tool_warned=yes ;;
5075 esac
5076 AR=$ac_ct_AR
5077 fi
5078 fi
5079
5080 : ${AR=ar}
5081
5082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the archiver ($AR) interface" >&5
5083 $as_echo_n "checking the archiver ($AR) interface... " >&6; }
5084 if ${am_cv_ar_interface+:} false; then :
5085 $as_echo_n "(cached) " >&6
5086 else
5087 ac_ext=c
5088 ac_cpp='$CPP $CPPFLAGS'
5089 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5090 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5091 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5092
5093 am_cv_ar_interface=ar
5094 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5095 /* end confdefs.h. */
5096 int some_variable = 0;
5097 _ACEOF
5098 if ac_fn_c_try_compile "$LINENO"; then :
5099 am_ar_try='$AR cru libconftest.a conftest.$ac_objext >&5'
5100 { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$am_ar_try\""; } >&5
5101 (eval $am_ar_try) 2>&5
5102 ac_status=$?
5103 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5104 test $ac_status = 0; }
5105 if test "$ac_status" -eq 0; then
5106 am_cv_ar_interface=ar
5107 else
5108 am_ar_try='$AR -NOLOGO -OUT:conftest.lib conftest.$ac_objext >&5'
5109 { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$am_ar_try\""; } >&5
5110 (eval $am_ar_try) 2>&5
5111 ac_status=$?
5112 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5113 test $ac_status = 0; }
5114 if test "$ac_status" -eq 0; then
5115 am_cv_ar_interface=lib
5116 else
5117 am_cv_ar_interface=unknown
5118 fi
5119 fi
5120 rm -f conftest.lib libconftest.a
5121
5122 fi
5123 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5124 ac_ext=c
5125 ac_cpp='$CPP $CPPFLAGS'
5126 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5127 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5128 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5129
5130 fi
5131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_ar_interface" >&5
5132 $as_echo "$am_cv_ar_interface" >&6; }
5133
5134 case $am_cv_ar_interface in
5135 ar)
5136 ;;
5137 lib)
5138 # Microsoft lib, so override with the ar-lib wrapper script.
5139 # FIXME: It is wrong to rewrite AR.
5140 # But if we don't then we get into trouble of one sort or another.
5141 # A longer-term fix would be to have automake use am__AR in this case,
5142 # and then we could set am__AR="$am_aux_dir/ar-lib \$(AR)" or something
5143 # similar.
5144 AR="$am_aux_dir/ar-lib $AR"
5145 ;;
5146 unknown)
5147 as_fn_error $? "could not determine $AR interface" "$LINENO" 5
5148 ;;
5149 esac
5150
5151 fi
5152
5153 if test -n "$ac_tool_prefix"; then
5154 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
5155 set dummy ${ac_tool_prefix}ar; ac_word=$2
5156 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5157 $as_echo_n "checking for $ac_word... " >&6; }
5158 if ${ac_cv_prog_AR+:} false; then :
5159 $as_echo_n "(cached) " >&6
5160 else
5161 if test -n "$AR"; then
5162 ac_cv_prog_AR="$AR" # Let the user override the test.
5163 else
5164 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5165 for as_dir in $PATH
5166 do
5167 IFS=$as_save_IFS
5168 test -z "$as_dir" && as_dir=.
5169 for ac_exec_ext in '' $ac_executable_extensions; do
5170 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5171 ac_cv_prog_AR="${ac_tool_prefix}ar"
5172 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5173 break 2
5174 fi
5175 done
5176 done
5177 IFS=$as_save_IFS
5178
5179 fi
5180 fi
5181 AR=$ac_cv_prog_AR
5182 if test -n "$AR"; then
5183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
5184 $as_echo "$AR" >&6; }
5185 else
5186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5187 $as_echo "no" >&6; }
5188 fi
5189
5190
5191 fi
5192 if test -z "$ac_cv_prog_AR"; then
5193 ac_ct_AR=$AR
5194 # Extract the first word of "ar", so it can be a program name with args.
5195 set dummy ar; ac_word=$2
5196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5197 $as_echo_n "checking for $ac_word... " >&6; }
5198 if ${ac_cv_prog_ac_ct_AR+:} false; then :
5199 $as_echo_n "(cached) " >&6
5200 else
5201 if test -n "$ac_ct_AR"; then
5202 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
5203 else
5204 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5205 for as_dir in $PATH
5206 do
5207 IFS=$as_save_IFS
5208 test -z "$as_dir" && as_dir=.
5209 for ac_exec_ext in '' $ac_executable_extensions; do
5210 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5211 ac_cv_prog_ac_ct_AR="ar"
5212 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5213 break 2
5214 fi
5215 done
5216 done
5217 IFS=$as_save_IFS
5218
5219 fi
5220 fi
5221 ac_ct_AR=$ac_cv_prog_ac_ct_AR
5222 if test -n "$ac_ct_AR"; then
5223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
5224 $as_echo "$ac_ct_AR" >&6; }
5225 else
5226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5227 $as_echo "no" >&6; }
5228 fi
5229
5230 if test "x$ac_ct_AR" = x; then
5231 AR="ar"
5232 else
5233 case $cross_compiling:$ac_tool_warned in
5234 yes:)
5235 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5236 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5237 ac_tool_warned=yes ;;
5238 esac
5239 AR=$ac_ct_AR
5240 fi
5241 else
5242 AR="$ac_cv_prog_AR"
5243 fi
5244
5245 if test -z "$ARFLAGS"; then
5246 ARFLAGS='cr'
5247 fi
5248
5249
5250
5251 if test -z "$RANLIB"; then
5252 if test $gl_cv_c_amsterdam_compiler = yes; then
5253 RANLIB=':'
5254 else
5255 if test -n "$ac_tool_prefix"; then
5256 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5257 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5259 $as_echo_n "checking for $ac_word... " >&6; }
5260 if ${ac_cv_prog_RANLIB+:} false; then :
5261 $as_echo_n "(cached) " >&6
5262 else
5263 if test -n "$RANLIB"; then
5264 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5265 else
5266 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5267 for as_dir in $PATH
5268 do
5269 IFS=$as_save_IFS
5270 test -z "$as_dir" && as_dir=.
5271 for ac_exec_ext in '' $ac_executable_extensions; do
5272 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5273 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5274 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5275 break 2
5276 fi
5277 done
5278 done
5279 IFS=$as_save_IFS
5280
5281 fi
5282 fi
5283 RANLIB=$ac_cv_prog_RANLIB
5284 if test -n "$RANLIB"; then
5285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
5286 $as_echo "$RANLIB" >&6; }
5287 else
5288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5289 $as_echo "no" >&6; }
5290 fi
5291
5292
5293 fi
5294 if test -z "$ac_cv_prog_RANLIB"; then
5295 ac_ct_RANLIB=$RANLIB
5296 # Extract the first word of "ranlib", so it can be a program name with args.
5297 set dummy ranlib; ac_word=$2
5298 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5299 $as_echo_n "checking for $ac_word... " >&6; }
5300 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
5301 $as_echo_n "(cached) " >&6
5302 else
5303 if test -n "$ac_ct_RANLIB"; then
5304 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
5305 else
5306 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5307 for as_dir in $PATH
5308 do
5309 IFS=$as_save_IFS
5310 test -z "$as_dir" && as_dir=.
5311 for ac_exec_ext in '' $ac_executable_extensions; do
5312 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5313 ac_cv_prog_ac_ct_RANLIB="ranlib"
5314 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5315 break 2
5316 fi
5317 done
5318 done
5319 IFS=$as_save_IFS
5320
5321 fi
5322 fi
5323 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
5324 if test -n "$ac_ct_RANLIB"; then
5325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
5326 $as_echo "$ac_ct_RANLIB" >&6; }
5327 else
5328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5329 $as_echo "no" >&6; }
5330 fi
5331
5332 if test "x$ac_ct_RANLIB" = x; then
5333 RANLIB=":"
5334 else
5335 case $cross_compiling:$ac_tool_warned in
5336 yes:)
5337 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5338 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5339 ac_tool_warned=yes ;;
5340 esac
5341 RANLIB=$ac_ct_RANLIB
5342 fi
5343 else
5344 RANLIB="$ac_cv_prog_RANLIB"
5345 fi
5346
5347 fi
5348 fi
5349
5350
5351 # Make sure we can run config.sub.
5352 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
5353 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
5354
5355 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
5356 $as_echo_n "checking build system type... " >&6; }
5357 if ${ac_cv_build+:} false; then :
5358 $as_echo_n "(cached) " >&6
5359 else
5360 ac_build_alias=$build_alias
5361 test "x$ac_build_alias" = x &&
5362 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
5363 test "x$ac_build_alias" = x &&
5364 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
5365 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
5366 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
5367
5368 fi
5369 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
5370 $as_echo "$ac_cv_build" >&6; }
5371 case $ac_cv_build in
5372 *-*-*) ;;
5373 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
5374 esac
5375 build=$ac_cv_build
5376 ac_save_IFS=$IFS; IFS='-'
5377 set x $ac_cv_build
5378 shift
5379 build_cpu=$1
5380 build_vendor=$2
5381 shift; shift
5382 # Remember, the first character of IFS is used to create $*,
5383 # except with old shells:
5384 build_os=$*
5385 IFS=$ac_save_IFS
5386 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
5387
5388
5389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
5390 $as_echo_n "checking host system type... " >&6; }
5391 if ${ac_cv_host+:} false; then :
5392 $as_echo_n "(cached) " >&6
5393 else
5394 if test "x$host_alias" = x; then
5395 ac_cv_host=$ac_cv_build
5396 else
5397 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
5398 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
5399 fi
5400
5401 fi
5402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
5403 $as_echo "$ac_cv_host" >&6; }
5404 case $ac_cv_host in
5405 *-*-*) ;;
5406 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
5407 esac
5408 host=$ac_cv_host
5409 ac_save_IFS=$IFS; IFS='-'
5410 set x $ac_cv_host
5411 shift
5412 host_cpu=$1
5413 host_vendor=$2
5414 shift; shift
5415 # Remember, the first character of IFS is used to create $*,
5416 # except with old shells:
5417 host_os=$*
5418 IFS=$ac_save_IFS
5419 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
5420
5421
5422
5423
5424
5425 # IEEE behaviour is the default on all CPUs except Alpha and SH
5426 # (according to the test results of Bruno Haible's ieeefp/fenv_default.m4
5427 # and the GCC 4.1.2 manual).
5428 case "$host_cpu" in
5429 alpha*)
5430 # On Alpha systems, a compiler option provides the behaviour.
5431 # See the ieee(3) manual page, also available at
5432 # <http://h30097.www3.hp.com/docs/base_doc/DOCUMENTATION/V51B_HTML/MAN/MAN3/0600____.HTM>
5433 if test -n "$GCC"; then
5434 # GCC has the option -mieee.
5435 # For full IEEE compliance (rarely needed), use option -mieee-with-inexact.
5436 CPPFLAGS="$CPPFLAGS -mieee"
5437 else
5438 # Compaq (ex-DEC) C has the option -ieee, equivalent to -ieee_with_no_inexact.
5439 # For full IEEE compliance (rarely needed), use option -ieee_with_inexact.
5440 CPPFLAGS="$CPPFLAGS -ieee"
5441 fi
5442 ;;
5443 sh*)
5444 if test -n "$GCC"; then
5445 # GCC has the option -mieee.
5446 CPPFLAGS="$CPPFLAGS -mieee"
5447 fi
5448 ;;
5449 esac
5450
5451 # Check whether --enable-largefile was given.
5452 if test "${enable_largefile+set}" = set; then :
5453 enableval=$enable_largefile;
5454 fi
5455
5456 if test "$enable_largefile" != no; then
5457
5458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
5459 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
5460 if ${ac_cv_sys_largefile_CC+:} false; then :
5461 $as_echo_n "(cached) " >&6
5462 else
5463 ac_cv_sys_largefile_CC=no
5464 if test "$GCC" != yes; then
5465 ac_save_CC=$CC
5466 while :; do
5467 # IRIX 6.2 and later do not support large files by default,
5468 # so use the C compiler's -n32 option if that helps.
5469 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5470 /* end confdefs.h. */
5471 #include <sys/types.h>
5472 /* Check that off_t can represent 2**63 - 1 correctly.
5473 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5474 since some C++ compilers masquerading as C compilers
5475 incorrectly reject 9223372036854775807. */
5476 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5477 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5478 && LARGE_OFF_T % 2147483647 == 1)
5479 ? 1 : -1];
5480 int
5481 main ()
5482 {
5483
5484 ;
5485 return 0;
5486 }
5487 _ACEOF
5488 if ac_fn_c_try_compile "$LINENO"; then :
5489 break
5490 fi
5491 rm -f core conftest.err conftest.$ac_objext
5492 CC="$CC -n32"
5493 if ac_fn_c_try_compile "$LINENO"; then :
5494 ac_cv_sys_largefile_CC=' -n32'; break
5495 fi
5496 rm -f core conftest.err conftest.$ac_objext
5497 break
5498 done
5499 CC=$ac_save_CC
5500 rm -f conftest.$ac_ext
5501 fi
5502 fi
5503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
5504 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
5505 if test "$ac_cv_sys_largefile_CC" != no; then
5506 CC=$CC$ac_cv_sys_largefile_CC
5507 fi
5508
5509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
5510 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
5511 if ${ac_cv_sys_file_offset_bits+:} false; then :
5512 $as_echo_n "(cached) " >&6
5513 else
5514 while :; do
5515 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5516 /* end confdefs.h. */
5517 #include <sys/types.h>
5518 /* Check that off_t can represent 2**63 - 1 correctly.
5519 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5520 since some C++ compilers masquerading as C compilers
5521 incorrectly reject 9223372036854775807. */
5522 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5523 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5524 && LARGE_OFF_T % 2147483647 == 1)
5525 ? 1 : -1];
5526 int
5527 main ()
5528 {
5529
5530 ;
5531 return 0;
5532 }
5533 _ACEOF
5534 if ac_fn_c_try_compile "$LINENO"; then :
5535 ac_cv_sys_file_offset_bits=no; break
5536 fi
5537 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5538 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5539 /* end confdefs.h. */
5540 #define _FILE_OFFSET_BITS 64
5541 #include <sys/types.h>
5542 /* Check that off_t can represent 2**63 - 1 correctly.
5543 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5544 since some C++ compilers masquerading as C compilers
5545 incorrectly reject 9223372036854775807. */
5546 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5547 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5548 && LARGE_OFF_T % 2147483647 == 1)
5549 ? 1 : -1];
5550 int
5551 main ()
5552 {
5553
5554 ;
5555 return 0;
5556 }
5557 _ACEOF
5558 if ac_fn_c_try_compile "$LINENO"; then :
5559 ac_cv_sys_file_offset_bits=64; break
5560 fi
5561 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5562 ac_cv_sys_file_offset_bits=unknown
5563 break
5564 done
5565 fi
5566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
5567 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
5568 case $ac_cv_sys_file_offset_bits in #(
5569 no | unknown) ;;
5570 *)
5571 cat >>confdefs.h <<_ACEOF
5572 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
5573 _ACEOF
5574 ;;
5575 esac
5576 rm -rf conftest*
5577 if test $ac_cv_sys_file_offset_bits = unknown; then
5578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
5579 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
5580 if ${ac_cv_sys_large_files+:} false; then :
5581 $as_echo_n "(cached) " >&6
5582 else
5583 while :; do
5584 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5585 /* end confdefs.h. */
5586 #include <sys/types.h>
5587 /* Check that off_t can represent 2**63 - 1 correctly.
5588 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5589 since some C++ compilers masquerading as C compilers
5590 incorrectly reject 9223372036854775807. */
5591 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5592 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5593 && LARGE_OFF_T % 2147483647 == 1)
5594 ? 1 : -1];
5595 int
5596 main ()
5597 {
5598
5599 ;
5600 return 0;
5601 }
5602 _ACEOF
5603 if ac_fn_c_try_compile "$LINENO"; then :
5604 ac_cv_sys_large_files=no; break
5605 fi
5606 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5607 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5608 /* end confdefs.h. */
5609 #define _LARGE_FILES 1
5610 #include <sys/types.h>
5611 /* Check that off_t can represent 2**63 - 1 correctly.
5612 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5613 since some C++ compilers masquerading as C compilers
5614 incorrectly reject 9223372036854775807. */
5615 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5616 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5617 && LARGE_OFF_T % 2147483647 == 1)
5618 ? 1 : -1];
5619 int
5620 main ()
5621 {
5622
5623 ;
5624 return 0;
5625 }
5626 _ACEOF
5627 if ac_fn_c_try_compile "$LINENO"; then :
5628 ac_cv_sys_large_files=1; break
5629 fi
5630 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5631 ac_cv_sys_large_files=unknown
5632 break
5633 done
5634 fi
5635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
5636 $as_echo "$ac_cv_sys_large_files" >&6; }
5637 case $ac_cv_sys_large_files in #(
5638 no | unknown) ;;
5639 *)
5640 cat >>confdefs.h <<_ACEOF
5641 #define _LARGE_FILES $ac_cv_sys_large_files
5642 _ACEOF
5643 ;;
5644 esac
5645 rm -rf conftest*
5646 fi
5647
5648
5649 $as_echo "#define _DARWIN_USE_64_BIT_INODE 1" >>confdefs.h
5650
5651 fi
5652
5653
5654
5655 # Pre-early section.
5656
5657
5658
5659 # Code from module absolute-header:
5660 # Code from module alloca:
5661 # Code from module alloca-opt:
5662 # Code from module assure:
5663 # Code from module at-internal:
5664 # Code from module canonicalize-lgpl:
5665 # Code from module chdir:
5666 # Code from module chdir-long:
5667 # Code from module cloexec:
5668 # Code from module close:
5669 # Code from module closedir:
5670 # Code from module configmake:
5671 # Code from module d-ino:
5672 # Code from module d-type:
5673 # Code from module dirent:
5674 # Code from module dirfd:
5675 # Code from module dirname-lgpl:
5676 # Code from module dosname:
5677 # Code from module double-slash-root:
5678 # Code from module dup:
5679 # Code from module dup2:
5680 # Code from module environ:
5681 # Code from module errno:
5682 # Code from module error:
5683 # Code from module exitfail:
5684 # Code from module extensions:
5685 # Code from module extern-inline:
5686 # Code from module fchdir:
5687 # Code from module fcntl:
5688 # Code from module fcntl-h:
5689 # Code from module fd-hook:
5690 # Code from module fdopendir:
5691 # Code from module filename:
5692 # Code from module filenamecat-lgpl:
5693 # Code from module flexmember:
5694 # Code from module float:
5695 # Code from module fnmatch:
5696 # Code from module fnmatch-gnu:
5697 # Code from module fpieee:
5698
5699 # Code from module fpucw:
5700 # Code from module frexp:
5701 # Code from module frexpl:
5702 # Code from module fstat:
5703 # Code from module fstatat:
5704 # Code from module getcwd:
5705 # Code from module getcwd-lgpl:
5706 # Code from module getdtablesize:
5707 # Code from module getlogin_r:
5708 # Code from module getprogname:
5709 # Code from module gettext-h:
5710 # Code from module gettimeofday:
5711 # Code from module glob:
5712 # Code from module hard-locale:
5713 # Code from module include_next:
5714 # Code from module intprops:
5715 # Code from module inttypes:
5716 # Code from module inttypes-incomplete:
5717 # Code from module isnand-nolibm:
5718 # Code from module isnanl-nolibm:
5719 # Code from module largefile:
5720
5721 # Code from module limits-h:
5722 # Code from module localcharset:
5723 # Code from module lstat:
5724 # Code from module malloc-posix:
5725 # Code from module malloca:
5726 # Code from module math:
5727 # Code from module mbrtowc:
5728 # Code from module mbsinit:
5729 # Code from module mbsrtowcs:
5730 # Code from module memchr:
5731 # Code from module memmem:
5732 # Code from module memmem-simple:
5733 # Code from module mempcpy:
5734 # Code from module memrchr:
5735 # Code from module mkdir:
5736 # Code from module mkstemp:
5737 # Code from module msvc-inval:
5738 # Code from module msvc-nothrow:
5739 # Code from module multiarch:
5740 # Code from module nocrash:
5741 # Code from module open:
5742 # Code from module openat:
5743 # Code from module openat-die:
5744 # Code from module openat-h:
5745 # Code from module opendir:
5746 # Code from module pathmax:
5747 # Code from module rawmemchr:
5748 # Code from module readdir:
5749 # Code from module readlink:
5750 # Code from module realloc-posix:
5751 # Code from module rename:
5752 # Code from module rewinddir:
5753 # Code from module rmdir:
5754 # Code from module same-inode:
5755 # Code from module save-cwd:
5756 # Code from module secure_getenv:
5757 # Code from module setenv:
5758 # Code from module signal-h:
5759 # Code from module snippet/_Noreturn:
5760 # Code from module snippet/arg-nonnull:
5761 # Code from module snippet/c++defs:
5762 # Code from module snippet/warn-on-use:
5763 # Code from module ssize_t:
5764 # Code from module stat:
5765 # Code from module stdbool:
5766 # Code from module stddef:
5767 # Code from module stdint:
5768 # Code from module stdio:
5769 # Code from module stdlib:
5770 # Code from module strchrnul:
5771 # Code from module strdup-posix:
5772 # Code from module streq:
5773 # Code from module strerror:
5774 # Code from module strerror-override:
5775 # Code from module string:
5776 # Code from module strnlen1:
5777 # Code from module strstr:
5778 # Code from module strstr-simple:
5779 # Code from module strtok_r:
5780 # Code from module sys_stat:
5781 # Code from module sys_time:
5782 # Code from module sys_types:
5783 # Code from module tempname:
5784 # Code from module time:
5785 # Code from module unistd:
5786 # Code from module unistd-safer:
5787 # Code from module unsetenv:
5788 # Code from module update-copyright:
5789 # Code from module verify:
5790 # Code from module wchar:
5791 # Code from module wctype-h:
5792
5793 ac_ext=c
5794 ac_cpp='$CPP $CPPFLAGS'
5795 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5796 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5797 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5798 if test -n "$ac_tool_prefix"; then
5799 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
5800 set dummy ${ac_tool_prefix}gcc; ac_word=$2
5801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5802 $as_echo_n "checking for $ac_word... " >&6; }
5803 if ${ac_cv_prog_CC+:} false; then :
5804 $as_echo_n "(cached) " >&6
5805 else
5806 if test -n "$CC"; then
5807 ac_cv_prog_CC="$CC" # Let the user override the test.
5808 else
5809 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5810 for as_dir in $PATH
5811 do
5812 IFS=$as_save_IFS
5813 test -z "$as_dir" && as_dir=.
5814 for ac_exec_ext in '' $ac_executable_extensions; do
5815 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5816 ac_cv_prog_CC="${ac_tool_prefix}gcc"
5817 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5818 break 2
5819 fi
5820 done
5821 done
5822 IFS=$as_save_IFS
5823
5824 fi
5825 fi
5826 CC=$ac_cv_prog_CC
5827 if test -n "$CC"; then
5828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5829 $as_echo "$CC" >&6; }
5830 else
5831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5832 $as_echo "no" >&6; }
5833 fi
5834
5835
5836 fi
5837 if test -z "$ac_cv_prog_CC"; then
5838 ac_ct_CC=$CC
5839 # Extract the first word of "gcc", so it can be a program name with args.
5840 set dummy gcc; ac_word=$2
5841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5842 $as_echo_n "checking for $ac_word... " >&6; }
5843 if ${ac_cv_prog_ac_ct_CC+:} false; then :
5844 $as_echo_n "(cached) " >&6
5845 else
5846 if test -n "$ac_ct_CC"; then
5847 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
5848 else
5849 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5850 for as_dir in $PATH
5851 do
5852 IFS=$as_save_IFS
5853 test -z "$as_dir" && as_dir=.
5854 for ac_exec_ext in '' $ac_executable_extensions; do
5855 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5856 ac_cv_prog_ac_ct_CC="gcc"
5857 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5858 break 2
5859 fi
5860 done
5861 done
5862 IFS=$as_save_IFS
5863
5864 fi
5865 fi
5866 ac_ct_CC=$ac_cv_prog_ac_ct_CC
5867 if test -n "$ac_ct_CC"; then
5868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5869 $as_echo "$ac_ct_CC" >&6; }
5870 else
5871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5872 $as_echo "no" >&6; }
5873 fi
5874
5875 if test "x$ac_ct_CC" = x; then
5876 CC=""
5877 else
5878 case $cross_compiling:$ac_tool_warned in
5879 yes:)
5880 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5881 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5882 ac_tool_warned=yes ;;
5883 esac
5884 CC=$ac_ct_CC
5885 fi
5886 else
5887 CC="$ac_cv_prog_CC"
5888 fi
5889
5890 if test -z "$CC"; then
5891 if test -n "$ac_tool_prefix"; then
5892 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
5893 set dummy ${ac_tool_prefix}cc; ac_word=$2
5894 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5895 $as_echo_n "checking for $ac_word... " >&6; }
5896 if ${ac_cv_prog_CC+:} false; then :
5897 $as_echo_n "(cached) " >&6
5898 else
5899 if test -n "$CC"; then
5900 ac_cv_prog_CC="$CC" # Let the user override the test.
5901 else
5902 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5903 for as_dir in $PATH
5904 do
5905 IFS=$as_save_IFS
5906 test -z "$as_dir" && as_dir=.
5907 for ac_exec_ext in '' $ac_executable_extensions; do
5908 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5909 ac_cv_prog_CC="${ac_tool_prefix}cc"
5910 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5911 break 2
5912 fi
5913 done
5914 done
5915 IFS=$as_save_IFS
5916
5917 fi
5918 fi
5919 CC=$ac_cv_prog_CC
5920 if test -n "$CC"; then
5921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5922 $as_echo "$CC" >&6; }
5923 else
5924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5925 $as_echo "no" >&6; }
5926 fi
5927
5928
5929 fi
5930 fi
5931 if test -z "$CC"; then
5932 # Extract the first word of "cc", so it can be a program name with args.
5933 set dummy cc; ac_word=$2
5934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5935 $as_echo_n "checking for $ac_word... " >&6; }
5936 if ${ac_cv_prog_CC+:} false; then :
5937 $as_echo_n "(cached) " >&6
5938 else
5939 if test -n "$CC"; then
5940 ac_cv_prog_CC="$CC" # Let the user override the test.
5941 else
5942 ac_prog_rejected=no
5943 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5944 for as_dir in $PATH
5945 do
5946 IFS=$as_save_IFS
5947 test -z "$as_dir" && as_dir=.
5948 for ac_exec_ext in '' $ac_executable_extensions; do
5949 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5950 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
5951 ac_prog_rejected=yes
5952 continue
5953 fi
5954 ac_cv_prog_CC="cc"
5955 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5956 break 2
5957 fi
5958 done
5959 done
5960 IFS=$as_save_IFS
5961
5962 if test $ac_prog_rejected = yes; then
5963 # We found a bogon in the path, so make sure we never use it.
5964 set dummy $ac_cv_prog_CC
5965 shift
5966 if test $# != 0; then
5967 # We chose a different compiler from the bogus one.
5968 # However, it has the same basename, so the bogon will be chosen
5969 # first if we set CC to just the basename; use the full file name.
5970 shift
5971 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
5972 fi
5973 fi
5974 fi
5975 fi
5976 CC=$ac_cv_prog_CC
5977 if test -n "$CC"; then
5978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5979 $as_echo "$CC" >&6; }
5980 else
5981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5982 $as_echo "no" >&6; }
5983 fi
5984
5985
5986 fi
5987 if test -z "$CC"; then
5988 if test -n "$ac_tool_prefix"; then
5989 for ac_prog in cl.exe
5990 do
5991 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5992 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5993 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5994 $as_echo_n "checking for $ac_word... " >&6; }
5995 if ${ac_cv_prog_CC+:} false; then :
5996 $as_echo_n "(cached) " >&6
5997 else
5998 if test -n "$CC"; then
5999 ac_cv_prog_CC="$CC" # Let the user override the test.
6000 else
6001 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6002 for as_dir in $PATH
6003 do
6004 IFS=$as_save_IFS
6005 test -z "$as_dir" && as_dir=.
6006 for ac_exec_ext in '' $ac_executable_extensions; do
6007 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6008 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
6009 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6010 break 2
6011 fi
6012 done
6013 done
6014 IFS=$as_save_IFS
6015
6016 fi
6017 fi
6018 CC=$ac_cv_prog_CC
6019 if test -n "$CC"; then
6020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
6021 $as_echo "$CC" >&6; }
6022 else
6023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6024 $as_echo "no" >&6; }
6025 fi
6026
6027
6028 test -n "$CC" && break
6029 done
6030 fi
6031 if test -z "$CC"; then
6032 ac_ct_CC=$CC
6033 for ac_prog in cl.exe
6034 do
6035 # Extract the first word of "$ac_prog", so it can be a program name with args.
6036 set dummy $ac_prog; ac_word=$2
6037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6038 $as_echo_n "checking for $ac_word... " >&6; }
6039 if ${ac_cv_prog_ac_ct_CC+:} false; then :
6040 $as_echo_n "(cached) " >&6
6041 else
6042 if test -n "$ac_ct_CC"; then
6043 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
6044 else
6045 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6046 for as_dir in $PATH
6047 do
6048 IFS=$as_save_IFS
6049 test -z "$as_dir" && as_dir=.
6050 for ac_exec_ext in '' $ac_executable_extensions; do
6051 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6052 ac_cv_prog_ac_ct_CC="$ac_prog"
6053 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6054 break 2
6055 fi
6056 done
6057 done
6058 IFS=$as_save_IFS
6059
6060 fi
6061 fi
6062 ac_ct_CC=$ac_cv_prog_ac_ct_CC
6063 if test -n "$ac_ct_CC"; then
6064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
6065 $as_echo "$ac_ct_CC" >&6; }
6066 else
6067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6068 $as_echo "no" >&6; }
6069 fi
6070
6071
6072 test -n "$ac_ct_CC" && break
6073 done
6074
6075 if test "x$ac_ct_CC" = x; then
6076 CC=""
6077 else
6078 case $cross_compiling:$ac_tool_warned in
6079 yes:)
6080 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6081 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6082 ac_tool_warned=yes ;;
6083 esac
6084 CC=$ac_ct_CC
6085 fi
6086 fi
6087
6088 fi
6089
6090
6091 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6092 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6093 as_fn_error $? "no acceptable C compiler found in \$PATH
6094 See \`config.log' for more details" "$LINENO" 5; }
6095
6096 # Provide some information about the compiler.
6097 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
6098 set X $ac_compile
6099 ac_compiler=$2
6100 for ac_option in --version -v -V -qversion; do
6101 { { ac_try="$ac_compiler $ac_option >&5"
6102 case "(($ac_try" in
6103 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6104 *) ac_try_echo=$ac_try;;
6105 esac
6106 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
6107 $as_echo "$ac_try_echo"; } >&5
6108 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
6109 ac_status=$?
6110 if test -s conftest.err; then
6111 sed '10a\
6112 ... rest of stderr output deleted ...
6113 10q' conftest.err >conftest.er1
6114 cat conftest.er1 >&5
6115 fi
6116 rm -f conftest.er1 conftest.err
6117 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6118 test $ac_status = 0; }
6119 done
6120
6121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
6122 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
6123 if ${ac_cv_c_compiler_gnu+:} false; then :
6124 $as_echo_n "(cached) " >&6
6125 else
6126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6127 /* end confdefs.h. */
6128
6129 int
6130 main ()
6131 {
6132 #ifndef __GNUC__
6133 choke me
6134 #endif
6135
6136 ;
6137 return 0;
6138 }
6139 _ACEOF
6140 if ac_fn_c_try_compile "$LINENO"; then :
6141 ac_compiler_gnu=yes
6142 else
6143 ac_compiler_gnu=no
6144 fi
6145 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6146 ac_cv_c_compiler_gnu=$ac_compiler_gnu
6147
6148 fi
6149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
6150 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
6151 if test $ac_compiler_gnu = yes; then
6152 GCC=yes
6153 else
6154 GCC=
6155 fi
6156 ac_test_CFLAGS=${CFLAGS+set}
6157 ac_save_CFLAGS=$CFLAGS
6158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
6159 $as_echo_n "checking whether $CC accepts -g... " >&6; }
6160 if ${ac_cv_prog_cc_g+:} false; then :
6161 $as_echo_n "(cached) " >&6
6162 else
6163 ac_save_c_werror_flag=$ac_c_werror_flag
6164 ac_c_werror_flag=yes
6165 ac_cv_prog_cc_g=no
6166 CFLAGS="-g"
6167 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6168 /* end confdefs.h. */
6169
6170 int
6171 main ()
6172 {
6173
6174 ;
6175 return 0;
6176 }
6177 _ACEOF
6178 if ac_fn_c_try_compile "$LINENO"; then :
6179 ac_cv_prog_cc_g=yes
6180 else
6181 CFLAGS=""
6182 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6183 /* end confdefs.h. */
6184
6185 int
6186 main ()
6187 {
6188
6189 ;
6190 return 0;
6191 }
6192 _ACEOF
6193 if ac_fn_c_try_compile "$LINENO"; then :
6194
6195 else
6196 ac_c_werror_flag=$ac_save_c_werror_flag
6197 CFLAGS="-g"
6198 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6199 /* end confdefs.h. */
6200
6201 int
6202 main ()
6203 {
6204
6205 ;
6206 return 0;
6207 }
6208 _ACEOF
6209 if ac_fn_c_try_compile "$LINENO"; then :
6210 ac_cv_prog_cc_g=yes
6211 fi
6212 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6213 fi
6214 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6215 fi
6216 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6217 ac_c_werror_flag=$ac_save_c_werror_flag
6218 fi
6219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
6220 $as_echo "$ac_cv_prog_cc_g" >&6; }
6221 if test "$ac_test_CFLAGS" = set; then
6222 CFLAGS=$ac_save_CFLAGS
6223 elif test $ac_cv_prog_cc_g = yes; then
6224 if test "$GCC" = yes; then
6225 CFLAGS="-g -O2"
6226 else
6227 CFLAGS="-g"
6228 fi
6229 else
6230 if test "$GCC" = yes; then
6231 CFLAGS="-O2"
6232 else
6233 CFLAGS=
6234 fi
6235 fi
6236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
6237 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
6238 if ${ac_cv_prog_cc_c89+:} false; then :
6239 $as_echo_n "(cached) " >&6
6240 else
6241 ac_cv_prog_cc_c89=no
6242 ac_save_CC=$CC
6243 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6244 /* end confdefs.h. */
6245 #include <stdarg.h>
6246 #include <stdio.h>
6247 struct stat;
6248 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
6249 struct buf { int x; };
6250 FILE * (*rcsopen) (struct buf *, struct stat *, int);
6251 static char *e (p, i)
6252 char **p;
6253 int i;
6254 {
6255 return p[i];
6256 }
6257 static char *f (char * (*g) (char **, int), char **p, ...)
6258 {
6259 char *s;
6260 va_list v;
6261 va_start (v,p);
6262 s = g (p, va_arg (v,int));
6263 va_end (v);
6264 return s;
6265 }
6266
6267 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
6268 function prototypes and stuff, but not '\xHH' hex character constants.
6269 These don't provoke an error unfortunately, instead are silently treated
6270 as 'x'. The following induces an error, until -std is added to get
6271 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
6272 array size at least. It's necessary to write '\x00'==0 to get something
6273 that's true only with -std. */
6274 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
6275
6276 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
6277 inside strings and character constants. */
6278 #define FOO(x) 'x'
6279 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
6280
6281 int test (int i, double x);
6282 struct s1 {int (*f) (int a);};
6283 struct s2 {int (*f) (double a);};
6284 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
6285 int argc;
6286 char **argv;
6287 int
6288 main ()
6289 {
6290 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
6291 ;
6292 return 0;
6293 }
6294 _ACEOF
6295 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
6296 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
6297 do
6298 CC="$ac_save_CC $ac_arg"
6299 if ac_fn_c_try_compile "$LINENO"; then :
6300 ac_cv_prog_cc_c89=$ac_arg
6301 fi
6302 rm -f core conftest.err conftest.$ac_objext
6303 test "x$ac_cv_prog_cc_c89" != "xno" && break
6304 done
6305 rm -f conftest.$ac_ext
6306 CC=$ac_save_CC
6307
6308 fi
6309 # AC_CACHE_VAL
6310 case "x$ac_cv_prog_cc_c89" in
6311 x)
6312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6313 $as_echo "none needed" >&6; } ;;
6314 xno)
6315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6316 $as_echo "unsupported" >&6; } ;;
6317 *)
6318 CC="$CC $ac_cv_prog_cc_c89"
6319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
6320 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
6321 esac
6322 if test "x$ac_cv_prog_cc_c89" != xno; then :
6323
6324 fi
6325
6326 ac_ext=c
6327 ac_cpp='$CPP $CPPFLAGS'
6328 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6329 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6330 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6331
6332 ac_ext=c
6333 ac_cpp='$CPP $CPPFLAGS'
6334 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6335 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6336 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6337 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
6338 $as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
6339 if ${am_cv_prog_cc_c_o+:} false; then :
6340 $as_echo_n "(cached) " >&6
6341 else
6342 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6343 /* end confdefs.h. */
6344
6345 int
6346 main ()
6347 {
6348
6349 ;
6350 return 0;
6351 }
6352 _ACEOF
6353 # Make sure it works both with $CC and with simple cc.
6354 # Following AC_PROG_CC_C_O, we do the test twice because some
6355 # compilers refuse to overwrite an existing .o file with -o,
6356 # though they will create one.
6357 am_cv_prog_cc_c_o=yes
6358 for am_i in 1 2; do
6359 if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
6360 ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
6361 ac_status=$?
6362 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6363 (exit $ac_status); } \
6364 && test -f conftest2.$ac_objext; then
6365 : OK
6366 else
6367 am_cv_prog_cc_c_o=no
6368 break
6369 fi
6370 done
6371 rm -f core conftest*
6372 unset am_i
6373 fi
6374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
6375 $as_echo "$am_cv_prog_cc_c_o" >&6; }
6376 if test "$am_cv_prog_cc_c_o" != yes; then
6377 # Losing compiler, so override with the script.
6378 # FIXME: It is wrong to rewrite CC.
6379 # But if we don't then we get into trouble of one sort or another.
6380 # A longer-term fix would be to have automake use am__CC in this case,
6381 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
6382 CC="$am_aux_dir/compile $CC"
6383 fi
6384 ac_ext=c
6385 ac_cpp='$CPP $CPPFLAGS'
6386 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6387 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6388 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6389
6390
6391 am_cv_prog_cc_stdc=$ac_cv_prog_cc_stdc
6392
6393
6394 ac_aux_dir=
6395 for ac_dir in ../.. "$srcdir"/../..; do
6396 if test -f "$ac_dir/install-sh"; then
6397 ac_aux_dir=$ac_dir
6398 ac_install_sh="$ac_aux_dir/install-sh -c"
6399 break
6400 elif test -f "$ac_dir/install.sh"; then
6401 ac_aux_dir=$ac_dir
6402 ac_install_sh="$ac_aux_dir/install.sh -c"
6403 break
6404 elif test -f "$ac_dir/shtool"; then
6405 ac_aux_dir=$ac_dir
6406 ac_install_sh="$ac_aux_dir/shtool install -c"
6407 break
6408 fi
6409 done
6410 if test -z "$ac_aux_dir"; then
6411 as_fn_error $? "cannot find install-sh, install.sh, or shtool in ../.. \"$srcdir\"/../.." "$LINENO" 5
6412 fi
6413
6414 # These three variables are undocumented and unsupported,
6415 # and are intended to be withdrawn in a future Autoconf release.
6416 # They can cause serious problems if a builder's source tree is in a directory
6417 # whose full name contains unusual characters.
6418 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
6419 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
6420 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
6421
6422
6423 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
6424 $as_echo_n "checking target system type... " >&6; }
6425 if ${ac_cv_target+:} false; then :
6426 $as_echo_n "(cached) " >&6
6427 else
6428 if test "x$target_alias" = x; then
6429 ac_cv_target=$ac_cv_host
6430 else
6431 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
6432 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
6433 fi
6434
6435 fi
6436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
6437 $as_echo "$ac_cv_target" >&6; }
6438 case $ac_cv_target in
6439 *-*-*) ;;
6440 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
6441 esac
6442 target=$ac_cv_target
6443 ac_save_IFS=$IFS; IFS='-'
6444 set x $ac_cv_target
6445 shift
6446 target_cpu=$1
6447 target_vendor=$2
6448 shift; shift
6449 # Remember, the first character of IFS is used to create $*,
6450 # except with old shells:
6451 target_os=$*
6452 IFS=$ac_save_IFS
6453 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
6454
6455
6456 # The aliases save the names the user supplied, while $host etc.
6457 # will get canonicalized.
6458 test -n "$target_alias" &&
6459 test "$program_prefix$program_suffix$program_transform_name" = \
6460 NONENONEs,x,x, &&
6461 program_prefix=${target_alias}-
6462
6463
6464
6465
6466
6467
6468
6469 LIBC_FATAL_STDERR_=1
6470 export LIBC_FATAL_STDERR_
6471
6472 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
6473 if test "x$ac_cv_type_size_t" = xyes; then :
6474
6475 else
6476
6477 cat >>confdefs.h <<_ACEOF
6478 #define size_t unsigned int
6479 _ACEOF
6480
6481 fi
6482
6483 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
6484 # for constant arguments. Useless!
6485 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
6486 $as_echo_n "checking for working alloca.h... " >&6; }
6487 if ${ac_cv_working_alloca_h+:} false; then :
6488 $as_echo_n "(cached) " >&6
6489 else
6490 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6491 /* end confdefs.h. */
6492 #include <alloca.h>
6493 int
6494 main ()
6495 {
6496 char *p = (char *) alloca (2 * sizeof (int));
6497 if (p) return 0;
6498 ;
6499 return 0;
6500 }
6501 _ACEOF
6502 if ac_fn_c_try_link "$LINENO"; then :
6503 ac_cv_working_alloca_h=yes
6504 else
6505 ac_cv_working_alloca_h=no
6506 fi
6507 rm -f core conftest.err conftest.$ac_objext \
6508 conftest$ac_exeext conftest.$ac_ext
6509 fi
6510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
6511 $as_echo "$ac_cv_working_alloca_h" >&6; }
6512 if test $ac_cv_working_alloca_h = yes; then
6513
6514 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
6515
6516 fi
6517
6518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
6519 $as_echo_n "checking for alloca... " >&6; }
6520 if ${ac_cv_func_alloca_works+:} false; then :
6521 $as_echo_n "(cached) " >&6
6522 else
6523 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6524 /* end confdefs.h. */
6525 #ifdef __GNUC__
6526 # define alloca __builtin_alloca
6527 #else
6528 # ifdef _MSC_VER
6529 # include <malloc.h>
6530 # define alloca _alloca
6531 # else
6532 # ifdef HAVE_ALLOCA_H
6533 # include <alloca.h>
6534 # else
6535 # ifdef _AIX
6536 #pragma alloca
6537 # else
6538 # ifndef alloca /* predefined by HP cc +Olibcalls */
6539 void *alloca (size_t);
6540 # endif
6541 # endif
6542 # endif
6543 # endif
6544 #endif
6545
6546 int
6547 main ()
6548 {
6549 char *p = (char *) alloca (1);
6550 if (p) return 0;
6551 ;
6552 return 0;
6553 }
6554 _ACEOF
6555 if ac_fn_c_try_link "$LINENO"; then :
6556 ac_cv_func_alloca_works=yes
6557 else
6558 ac_cv_func_alloca_works=no
6559 fi
6560 rm -f core conftest.err conftest.$ac_objext \
6561 conftest$ac_exeext conftest.$ac_ext
6562 fi
6563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
6564 $as_echo "$ac_cv_func_alloca_works" >&6; }
6565
6566 if test $ac_cv_func_alloca_works = yes; then
6567
6568 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
6569
6570 else
6571 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
6572 # that cause trouble. Some versions do not even contain alloca or
6573 # contain a buggy version. If you still want to use their alloca,
6574 # use ar to extract alloca.o from them instead of compiling alloca.c.
6575
6576
6577
6578
6579
6580 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
6581
6582 $as_echo "#define C_ALLOCA 1" >>confdefs.h
6583
6584
6585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
6586 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
6587 if ${ac_cv_os_cray+:} false; then :
6588 $as_echo_n "(cached) " >&6
6589 else
6590 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6591 /* end confdefs.h. */
6592 #if defined CRAY && ! defined CRAY2
6593 webecray
6594 #else
6595 wenotbecray
6596 #endif
6597
6598 _ACEOF
6599 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6600 $EGREP "webecray" >/dev/null 2>&1; then :
6601 ac_cv_os_cray=yes
6602 else
6603 ac_cv_os_cray=no
6604 fi
6605 rm -f conftest*
6606
6607 fi
6608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
6609 $as_echo "$ac_cv_os_cray" >&6; }
6610 if test $ac_cv_os_cray = yes; then
6611 for ac_func in _getb67 GETB67 getb67; do
6612 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
6613 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
6614 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
6615
6616 cat >>confdefs.h <<_ACEOF
6617 #define CRAY_STACKSEG_END $ac_func
6618 _ACEOF
6619
6620 break
6621 fi
6622
6623 done
6624 fi
6625
6626 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
6627 $as_echo_n "checking stack direction for C alloca... " >&6; }
6628 if ${ac_cv_c_stack_direction+:} false; then :
6629 $as_echo_n "(cached) " >&6
6630 else
6631 if test "$cross_compiling" = yes; then :
6632 ac_cv_c_stack_direction=0
6633 else
6634 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6635 /* end confdefs.h. */
6636 $ac_includes_default
6637 int
6638 find_stack_direction (int *addr, int depth)
6639 {
6640 int dir, dummy = 0;
6641 if (! addr)
6642 addr = &dummy;
6643 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
6644 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
6645 return dir + dummy;
6646 }
6647
6648 int
6649 main (int argc, char **argv)
6650 {
6651 return find_stack_direction (0, argc + !argv + 20) < 0;
6652 }
6653 _ACEOF
6654 if ac_fn_c_try_run "$LINENO"; then :
6655 ac_cv_c_stack_direction=1
6656 else
6657 ac_cv_c_stack_direction=-1
6658 fi
6659 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6660 conftest.$ac_objext conftest.beam conftest.$ac_ext
6661 fi
6662
6663 fi
6664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
6665 $as_echo "$ac_cv_c_stack_direction" >&6; }
6666 cat >>confdefs.h <<_ACEOF
6667 #define STACK_DIRECTION $ac_cv_c_stack_direction
6668 _ACEOF
6669
6670
6671 fi
6672
6673
6674 GNULIB__EXIT=0;
6675 GNULIB_ATOLL=0;
6676 GNULIB_CALLOC_POSIX=0;
6677 GNULIB_CANONICALIZE_FILE_NAME=0;
6678 GNULIB_GETLOADAVG=0;
6679 GNULIB_GETSUBOPT=0;
6680 GNULIB_GRANTPT=0;
6681 GNULIB_MALLOC_POSIX=0;
6682 GNULIB_MBTOWC=0;
6683 GNULIB_MKDTEMP=0;
6684 GNULIB_MKOSTEMP=0;
6685 GNULIB_MKOSTEMPS=0;
6686 GNULIB_MKSTEMP=0;
6687 GNULIB_MKSTEMPS=0;
6688 GNULIB_POSIX_OPENPT=0;
6689 GNULIB_PTSNAME=0;
6690 GNULIB_PTSNAME_R=0;
6691 GNULIB_PUTENV=0;
6692 GNULIB_QSORT_R=0;
6693 GNULIB_RANDOM=0;
6694 GNULIB_RANDOM_R=0;
6695 GNULIB_REALLOC_POSIX=0;
6696 GNULIB_REALPATH=0;
6697 GNULIB_RPMATCH=0;
6698 GNULIB_SECURE_GETENV=0;
6699 GNULIB_SETENV=0;
6700 GNULIB_STRTOD=0;
6701 GNULIB_STRTOLL=0;
6702 GNULIB_STRTOULL=0;
6703 GNULIB_SYSTEM_POSIX=0;
6704 GNULIB_UNLOCKPT=0;
6705 GNULIB_UNSETENV=0;
6706 GNULIB_WCTOMB=0;
6707 HAVE__EXIT=1;
6708 HAVE_ATOLL=1;
6709 HAVE_CANONICALIZE_FILE_NAME=1;
6710 HAVE_DECL_GETLOADAVG=1;
6711 HAVE_GETSUBOPT=1;
6712 HAVE_GRANTPT=1;
6713 HAVE_MKDTEMP=1;
6714 HAVE_MKOSTEMP=1;
6715 HAVE_MKOSTEMPS=1;
6716 HAVE_MKSTEMP=1;
6717 HAVE_MKSTEMPS=1;
6718 HAVE_POSIX_OPENPT=1;
6719 HAVE_PTSNAME=1;
6720 HAVE_PTSNAME_R=1;
6721 HAVE_QSORT_R=1;
6722 HAVE_RANDOM=1;
6723 HAVE_RANDOM_H=1;
6724 HAVE_RANDOM_R=1;
6725 HAVE_REALPATH=1;
6726 HAVE_RPMATCH=1;
6727 HAVE_SECURE_GETENV=1;
6728 HAVE_SETENV=1;
6729 HAVE_DECL_SETENV=1;
6730 HAVE_STRTOD=1;
6731 HAVE_STRTOLL=1;
6732 HAVE_STRTOULL=1;
6733 HAVE_STRUCT_RANDOM_DATA=1;
6734 HAVE_SYS_LOADAVG_H=0;
6735 HAVE_UNLOCKPT=1;
6736 HAVE_DECL_UNSETENV=1;
6737 REPLACE_CALLOC=0;
6738 REPLACE_CANONICALIZE_FILE_NAME=0;
6739 REPLACE_MALLOC=0;
6740 REPLACE_MBTOWC=0;
6741 REPLACE_MKSTEMP=0;
6742 REPLACE_PTSNAME=0;
6743 REPLACE_PTSNAME_R=0;
6744 REPLACE_PUTENV=0;
6745 REPLACE_QSORT_R=0;
6746 REPLACE_RANDOM_R=0;
6747 REPLACE_REALLOC=0;
6748 REPLACE_REALPATH=0;
6749 REPLACE_SETENV=0;
6750 REPLACE_STRTOD=0;
6751 REPLACE_UNSETENV=0;
6752 REPLACE_WCTOMB=0;
6753
6754
6755
6756
6757
6758 for ac_func in $gl_func_list
6759 do :
6760 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
6761 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
6762 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
6763 cat >>confdefs.h <<_ACEOF
6764 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
6765 _ACEOF
6766
6767 fi
6768 done
6769
6770
6771
6772
6773
6774
6775
6776
6777
6778
6779
6780
6781
6782
6783
6784
6785
6786 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether // is distinct from /" >&5
6787 $as_echo_n "checking whether // is distinct from /... " >&6; }
6788 if ${gl_cv_double_slash_root+:} false; then :
6789 $as_echo_n "(cached) " >&6
6790 else
6791 if test x"$cross_compiling" = xyes ; then
6792 # When cross-compiling, there is no way to tell whether // is special
6793 # short of a list of hosts. However, the only known hosts to date
6794 # that have a distinct // are Apollo DomainOS (too old to port to),
6795 # Cygwin, and z/OS. If anyone knows of another system for which // has
6796 # special semantics and is distinct from /, please report it to
6797 # <bug-gnulib@gnu.org>.
6798 case $host in
6799 *-cygwin | i370-ibm-openedition)
6800 gl_cv_double_slash_root=yes ;;
6801 *)
6802 # Be optimistic and assume that / and // are the same when we
6803 # don't know.
6804 gl_cv_double_slash_root='unknown, assuming no' ;;
6805 esac
6806 else
6807 set x `ls -di / // 2>/dev/null`
6808 if test "$2" = "$4" && wc //dev/null >/dev/null 2>&1; then
6809 gl_cv_double_slash_root=no
6810 else
6811 gl_cv_double_slash_root=yes
6812 fi
6813 fi
6814 fi
6815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_double_slash_root" >&5
6816 $as_echo "$gl_cv_double_slash_root" >&6; }
6817 if test "$gl_cv_double_slash_root" = yes; then
6818
6819 $as_echo "#define DOUBLE_SLASH_IS_DISTINCT_ROOT 1" >>confdefs.h
6820
6821 fi
6822
6823
6824
6825
6826
6827
6828
6829
6830 :
6831
6832
6833
6834
6835
6836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether realpath works" >&5
6837 $as_echo_n "checking whether realpath works... " >&6; }
6838 if ${gl_cv_func_realpath_works+:} false; then :
6839 $as_echo_n "(cached) " >&6
6840 else
6841
6842 touch conftest.a
6843 mkdir conftest.d
6844 if test "$cross_compiling" = yes; then :
6845 case "$host_os" in
6846 # Guess yes on glibc systems.
6847 *-gnu* | gnu*) gl_cv_func_realpath_works="guessing yes" ;;
6848 # If we don't know, assume the worst.
6849 *) gl_cv_func_realpath_works="guessing no" ;;
6850 esac
6851
6852 else
6853 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6854 /* end confdefs.h. */
6855
6856
6857
6858 #include <stdlib.h>
6859 #if defined __MACH__ && defined __APPLE__
6860 /* Avoid a crash on Mac OS X. */
6861 #include <mach/mach.h>
6862 #include <mach/mach_error.h>
6863 #include <mach/thread_status.h>
6864 #include <mach/exception.h>
6865 #include <mach/task.h>
6866 #include <pthread.h>
6867 /* The exception port on which our thread listens. */
6868 static mach_port_t our_exception_port;
6869 /* The main function of the thread listening for exceptions of type
6870 EXC_BAD_ACCESS. */
6871 static void *
6872 mach_exception_thread (void *arg)
6873 {
6874 /* Buffer for a message to be received. */
6875 struct {
6876 mach_msg_header_t head;
6877 mach_msg_body_t msgh_body;
6878 char data[1024];
6879 } msg;
6880 mach_msg_return_t retval;
6881 /* Wait for a message on the exception port. */
6882 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
6883 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
6884 if (retval != MACH_MSG_SUCCESS)
6885 abort ();
6886 exit (1);
6887 }
6888 static void
6889 nocrash_init (void)
6890 {
6891 mach_port_t self = mach_task_self ();
6892 /* Allocate a port on which the thread shall listen for exceptions. */
6893 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
6894 == KERN_SUCCESS) {
6895 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
6896 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
6897 MACH_MSG_TYPE_MAKE_SEND)
6898 == KERN_SUCCESS) {
6899 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
6900 for us. */
6901 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
6902 /* Create the thread listening on the exception port. */
6903 pthread_attr_t attr;
6904 pthread_t thread;
6905 if (pthread_attr_init (&attr) == 0
6906 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
6907 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
6908 pthread_attr_destroy (&attr);
6909 /* Replace the exception port info for these exceptions with our own.
6910 Note that we replace the exception port for the entire task, not only
6911 for a particular thread. This has the effect that when our exception
6912 port gets the message, the thread specific exception port has already
6913 been asked, and we don't need to bother about it.
6914 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
6915 task_set_exception_ports (self, mask, our_exception_port,
6916 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
6917 }
6918 }
6919 }
6920 }
6921 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
6922 /* Avoid a crash on native Windows. */
6923 #define WIN32_LEAN_AND_MEAN
6924 #include <windows.h>
6925 #include <winerror.h>
6926 static LONG WINAPI
6927 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
6928 {
6929 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
6930 {
6931 case EXCEPTION_ACCESS_VIOLATION:
6932 case EXCEPTION_IN_PAGE_ERROR:
6933 case EXCEPTION_STACK_OVERFLOW:
6934 case EXCEPTION_GUARD_PAGE:
6935 case EXCEPTION_PRIV_INSTRUCTION:
6936 case EXCEPTION_ILLEGAL_INSTRUCTION:
6937 case EXCEPTION_DATATYPE_MISALIGNMENT:
6938 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
6939 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
6940 exit (1);
6941 }
6942 return EXCEPTION_CONTINUE_SEARCH;
6943 }
6944 static void
6945 nocrash_init (void)
6946 {
6947 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
6948 }
6949 #else
6950 /* Avoid a crash on POSIX systems. */
6951 #include <signal.h>
6952 #include <unistd.h>
6953 /* A POSIX signal handler. */
6954 static void
6955 exception_handler (int sig)
6956 {
6957 _exit (1);
6958 }
6959 static void
6960 nocrash_init (void)
6961 {
6962 #ifdef SIGSEGV
6963 signal (SIGSEGV, exception_handler);
6964 #endif
6965 #ifdef SIGBUS
6966 signal (SIGBUS, exception_handler);
6967 #endif
6968 }
6969 #endif
6970
6971 #include <stdlib.h>
6972 #include <string.h>
6973
6974 int
6975 main ()
6976 {
6977
6978 int result = 0;
6979 {
6980 char *name = realpath ("conftest.a", NULL);
6981 if (!(name && *name == '/'))
6982 result |= 1;
6983 free (name);
6984 }
6985 {
6986 char *name = realpath ("conftest.b/../conftest.a", NULL);
6987 if (name != NULL)
6988 result |= 2;
6989 free (name);
6990 }
6991 {
6992 char *name = realpath ("conftest.a/", NULL);
6993 if (name != NULL)
6994 result |= 4;
6995 free (name);
6996 }
6997 {
6998 char *name1 = realpath (".", NULL);
6999 char *name2 = realpath ("conftest.d//./..", NULL);
7000 if (! name1 || ! name2 || strcmp (name1, name2))
7001 result |= 8;
7002 free (name1);
7003 free (name2);
7004 }
7005 return result;
7006
7007 ;
7008 return 0;
7009 }
7010
7011 _ACEOF
7012 if ac_fn_c_try_run "$LINENO"; then :
7013 gl_cv_func_realpath_works=yes
7014 else
7015 gl_cv_func_realpath_works=no
7016 fi
7017 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7018 conftest.$ac_objext conftest.beam conftest.$ac_ext
7019 fi
7020
7021 rm -rf conftest.a conftest.d
7022
7023 fi
7024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_realpath_works" >&5
7025 $as_echo "$gl_cv_func_realpath_works" >&6; }
7026 case "$gl_cv_func_realpath_works" in
7027 *yes)
7028
7029 $as_echo "#define FUNC_REALPATH_WORKS 1" >>confdefs.h
7030
7031 ;;
7032 esac
7033
7034
7035
7036
7037
7038 for ac_header in $gl_header_list
7039 do :
7040 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7041 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
7042 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
7043 cat >>confdefs.h <<_ACEOF
7044 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7045 _ACEOF
7046
7047 fi
7048
7049 done
7050
7051
7052
7053
7054
7055
7056
7057
7058 :
7059
7060
7061
7062
7063
7064
7065
7066
7067
7068
7069
7070
7071
7072
7073 :
7074
7075
7076
7077
7078
7079
7080
7081 GNULIB_CHDIR=0;
7082 GNULIB_CHOWN=0;
7083 GNULIB_CLOSE=0;
7084 GNULIB_DUP=0;
7085 GNULIB_DUP2=0;
7086 GNULIB_DUP3=0;
7087 GNULIB_ENVIRON=0;
7088 GNULIB_EUIDACCESS=0;
7089 GNULIB_FACCESSAT=0;
7090 GNULIB_FCHDIR=0;
7091 GNULIB_FCHOWNAT=0;
7092 GNULIB_FDATASYNC=0;
7093 GNULIB_FSYNC=0;
7094 GNULIB_FTRUNCATE=0;
7095 GNULIB_GETCWD=0;
7096 GNULIB_GETDOMAINNAME=0;
7097 GNULIB_GETDTABLESIZE=0;
7098 GNULIB_GETGROUPS=0;
7099 GNULIB_GETHOSTNAME=0;
7100 GNULIB_GETLOGIN=0;
7101 GNULIB_GETLOGIN_R=0;
7102 GNULIB_GETPAGESIZE=0;
7103 GNULIB_GETUSERSHELL=0;
7104 GNULIB_GROUP_MEMBER=0;
7105 GNULIB_ISATTY=0;
7106 GNULIB_LCHOWN=0;
7107 GNULIB_LINK=0;
7108 GNULIB_LINKAT=0;
7109 GNULIB_LSEEK=0;
7110 GNULIB_PIPE=0;
7111 GNULIB_PIPE2=0;
7112 GNULIB_PREAD=0;
7113 GNULIB_PWRITE=0;
7114 GNULIB_READ=0;
7115 GNULIB_READLINK=0;
7116 GNULIB_READLINKAT=0;
7117 GNULIB_RMDIR=0;
7118 GNULIB_SETHOSTNAME=0;
7119 GNULIB_SLEEP=0;
7120 GNULIB_SYMLINK=0;
7121 GNULIB_SYMLINKAT=0;
7122 GNULIB_TTYNAME_R=0;
7123 GNULIB_UNISTD_H_NONBLOCKING=0;
7124 GNULIB_UNISTD_H_SIGPIPE=0;
7125 GNULIB_UNLINK=0;
7126 GNULIB_UNLINKAT=0;
7127 GNULIB_USLEEP=0;
7128 GNULIB_WRITE=0;
7129 HAVE_CHOWN=1;
7130 HAVE_DUP2=1;
7131 HAVE_DUP3=1;
7132 HAVE_EUIDACCESS=1;
7133 HAVE_FACCESSAT=1;
7134 HAVE_FCHDIR=1;
7135 HAVE_FCHOWNAT=1;
7136 HAVE_FDATASYNC=1;
7137 HAVE_FSYNC=1;
7138 HAVE_FTRUNCATE=1;
7139 HAVE_GETDTABLESIZE=1;
7140 HAVE_GETGROUPS=1;
7141 HAVE_GETHOSTNAME=1;
7142 HAVE_GETLOGIN=1;
7143 HAVE_GETPAGESIZE=1;
7144 HAVE_GROUP_MEMBER=1;
7145 HAVE_LCHOWN=1;
7146 HAVE_LINK=1;
7147 HAVE_LINKAT=1;
7148 HAVE_PIPE=1;
7149 HAVE_PIPE2=1;
7150 HAVE_PREAD=1;
7151 HAVE_PWRITE=1;
7152 HAVE_READLINK=1;
7153 HAVE_READLINKAT=1;
7154 HAVE_SETHOSTNAME=1;
7155 HAVE_SLEEP=1;
7156 HAVE_SYMLINK=1;
7157 HAVE_SYMLINKAT=1;
7158 HAVE_UNLINKAT=1;
7159 HAVE_USLEEP=1;
7160 HAVE_DECL_ENVIRON=1;
7161 HAVE_DECL_FCHDIR=1;
7162 HAVE_DECL_FDATASYNC=1;
7163 HAVE_DECL_GETDOMAINNAME=1;
7164 HAVE_DECL_GETLOGIN_R=1;
7165 HAVE_DECL_GETPAGESIZE=1;
7166 HAVE_DECL_GETUSERSHELL=1;
7167 HAVE_DECL_SETHOSTNAME=1;
7168 HAVE_DECL_TTYNAME_R=1;
7169 HAVE_OS_H=0;
7170 HAVE_SYS_PARAM_H=0;
7171 REPLACE_CHOWN=0;
7172 REPLACE_CLOSE=0;
7173 REPLACE_DUP=0;
7174 REPLACE_DUP2=0;
7175 REPLACE_FCHOWNAT=0;
7176 REPLACE_FTRUNCATE=0;
7177 REPLACE_GETCWD=0;
7178 REPLACE_GETDOMAINNAME=0;
7179 REPLACE_GETDTABLESIZE=0;
7180 REPLACE_GETLOGIN_R=0;
7181 REPLACE_GETGROUPS=0;
7182 REPLACE_GETPAGESIZE=0;
7183 REPLACE_ISATTY=0;
7184 REPLACE_LCHOWN=0;
7185 REPLACE_LINK=0;
7186 REPLACE_LINKAT=0;
7187 REPLACE_LSEEK=0;
7188 REPLACE_PREAD=0;
7189 REPLACE_PWRITE=0;
7190 REPLACE_READ=0;
7191 REPLACE_READLINK=0;
7192 REPLACE_READLINKAT=0;
7193 REPLACE_RMDIR=0;
7194 REPLACE_SLEEP=0;
7195 REPLACE_SYMLINK=0;
7196 REPLACE_SYMLINKAT=0;
7197 REPLACE_TTYNAME_R=0;
7198 REPLACE_UNLINK=0;
7199 REPLACE_UNLINKAT=0;
7200 REPLACE_USLEEP=0;
7201 REPLACE_WRITE=0;
7202 UNISTD_H_HAVE_WINSOCK2_H=0;
7203 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
7204
7205
7206
7207
7208
7209
7210
7211
7212
7213 :
7214
7215
7216
7217
7218
7219
7220
7221
7222
7223
7224
7225
7226
7227
7228
7229
7230 :
7231
7232
7233
7234
7235
7236 if test $ac_cv_func__set_invalid_parameter_handler = yes; then
7237 HAVE_MSVC_INVALID_PARAMETER_HANDLER=1
7238
7239 $as_echo "#define HAVE_MSVC_INVALID_PARAMETER_HANDLER 1" >>confdefs.h
7240
7241 else
7242 HAVE_MSVC_INVALID_PARAMETER_HANDLER=0
7243 fi
7244
7245
7246
7247
7248
7249
7250
7251
7252
7253
7254
7255
7256
7257 GNULIB_OPENDIR=0;
7258 GNULIB_READDIR=0;
7259 GNULIB_REWINDDIR=0;
7260 GNULIB_CLOSEDIR=0;
7261 GNULIB_DIRFD=0;
7262 GNULIB_FDOPENDIR=0;
7263 GNULIB_SCANDIR=0;
7264 GNULIB_ALPHASORT=0;
7265 HAVE_OPENDIR=1;
7266 HAVE_READDIR=1;
7267 HAVE_REWINDDIR=1;
7268 HAVE_CLOSEDIR=1;
7269 HAVE_DECL_DIRFD=1;
7270 HAVE_DECL_FDOPENDIR=1;
7271 HAVE_FDOPENDIR=1;
7272 HAVE_SCANDIR=1;
7273 HAVE_ALPHASORT=1;
7274 REPLACE_OPENDIR=0;
7275 REPLACE_CLOSEDIR=0;
7276 REPLACE_DIRFD=0;
7277 REPLACE_FDOPENDIR=0;
7278
7279
7280
7281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
7282 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
7283 if ${gl_cv_have_include_next+:} false; then :
7284 $as_echo_n "(cached) " >&6
7285 else
7286 rm -rf conftestd1a conftestd1b conftestd2
7287 mkdir conftestd1a conftestd1b conftestd2
7288 cat <<EOF > conftestd1a/conftest.h
7289 #define DEFINED_IN_CONFTESTD1
7290 #include_next <conftest.h>
7291 #ifdef DEFINED_IN_CONFTESTD2
7292 int foo;
7293 #else
7294 #error "include_next doesn't work"
7295 #endif
7296 EOF
7297 cat <<EOF > conftestd1b/conftest.h
7298 #define DEFINED_IN_CONFTESTD1
7299 #include <stdio.h>
7300 #include_next <conftest.h>
7301 #ifdef DEFINED_IN_CONFTESTD2
7302 int foo;
7303 #else
7304 #error "include_next doesn't work"
7305 #endif
7306 EOF
7307 cat <<EOF > conftestd2/conftest.h
7308 #ifndef DEFINED_IN_CONFTESTD1
7309 #error "include_next test doesn't work"
7310 #endif
7311 #define DEFINED_IN_CONFTESTD2
7312 EOF
7313 gl_save_CPPFLAGS="$CPPFLAGS"
7314 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
7315 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7316 /* end confdefs.h. */
7317 #include <conftest.h>
7318 _ACEOF
7319 if ac_fn_c_try_compile "$LINENO"; then :
7320 gl_cv_have_include_next=yes
7321 else
7322 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
7323 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7324 /* end confdefs.h. */
7325 #include <conftest.h>
7326 _ACEOF
7327 if ac_fn_c_try_compile "$LINENO"; then :
7328 gl_cv_have_include_next=buggy
7329 else
7330 gl_cv_have_include_next=no
7331 fi
7332 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7333
7334 fi
7335 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7336 CPPFLAGS="$gl_save_CPPFLAGS"
7337 rm -rf conftestd1a conftestd1b conftestd2
7338
7339 fi
7340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
7341 $as_echo "$gl_cv_have_include_next" >&6; }
7342 PRAGMA_SYSTEM_HEADER=
7343 if test $gl_cv_have_include_next = yes; then
7344 INCLUDE_NEXT=include_next
7345 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
7346 if test -n "$GCC"; then
7347 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
7348 fi
7349 else
7350 if test $gl_cv_have_include_next = buggy; then
7351 INCLUDE_NEXT=include
7352 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
7353 else
7354 INCLUDE_NEXT=include
7355 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
7356 fi
7357 fi
7358
7359
7360
7361 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
7362 $as_echo_n "checking whether system header files limit the line length... " >&6; }
7363 if ${gl_cv_pragma_columns+:} false; then :
7364 $as_echo_n "(cached) " >&6
7365 else
7366 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7367 /* end confdefs.h. */
7368
7369 #ifdef __TANDEM
7370 choke me
7371 #endif
7372
7373 _ACEOF
7374 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7375 $EGREP "choke me" >/dev/null 2>&1; then :
7376 gl_cv_pragma_columns=yes
7377 else
7378 gl_cv_pragma_columns=no
7379 fi
7380 rm -f conftest*
7381
7382
7383 fi
7384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
7385 $as_echo "$gl_cv_pragma_columns" >&6; }
7386 if test $gl_cv_pragma_columns = yes; then
7387 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
7388 else
7389 PRAGMA_COLUMNS=
7390 fi
7391
7392
7393
7394
7395
7396
7397
7398
7399
7400
7401
7402
7403 :
7404
7405
7406
7407
7408
7409
7410
7411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
7412 $as_echo_n "checking if environ is properly declared... " >&6; }
7413 if ${gt_cv_var_environ_declaration+:} false; then :
7414 $as_echo_n "(cached) " >&6
7415 else
7416
7417 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7418 /* end confdefs.h. */
7419 #if HAVE_UNISTD_H
7420 #include <unistd.h>
7421 #endif
7422 /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
7423 #include <stdlib.h>
7424
7425 extern struct { int foo; } environ;
7426 int
7427 main ()
7428 {
7429 environ.foo = 1;
7430 ;
7431 return 0;
7432 }
7433 _ACEOF
7434 if ac_fn_c_try_compile "$LINENO"; then :
7435 gt_cv_var_environ_declaration=no
7436 else
7437 gt_cv_var_environ_declaration=yes
7438 fi
7439 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7440 fi
7441
7442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
7443 $as_echo "$gt_cv_var_environ_declaration" >&6; }
7444 if test $gt_cv_var_environ_declaration = yes; then
7445
7446 $as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
7447
7448 fi
7449
7450
7451 if test $gt_cv_var_environ_declaration != yes; then
7452 HAVE_DECL_ENVIRON=0
7453 fi
7454
7455
7456
7457 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for complete errno.h" >&5
7458 $as_echo_n "checking for complete errno.h... " >&6; }
7459 if ${gl_cv_header_errno_h_complete+:} false; then :
7460 $as_echo_n "(cached) " >&6
7461 else
7462
7463 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7464 /* end confdefs.h. */
7465
7466 #include <errno.h>
7467 #if !defined ETXTBSY
7468 booboo
7469 #endif
7470 #if !defined ENOMSG
7471 booboo
7472 #endif
7473 #if !defined EIDRM
7474 booboo
7475 #endif
7476 #if !defined ENOLINK
7477 booboo
7478 #endif
7479 #if !defined EPROTO
7480 booboo
7481 #endif
7482 #if !defined EMULTIHOP
7483 booboo
7484 #endif
7485 #if !defined EBADMSG
7486 booboo
7487 #endif
7488 #if !defined EOVERFLOW
7489 booboo
7490 #endif
7491 #if !defined ENOTSUP
7492 booboo
7493 #endif
7494 #if !defined ENETRESET
7495 booboo
7496 #endif
7497 #if !defined ECONNABORTED
7498 booboo
7499 #endif
7500 #if !defined ESTALE
7501 booboo
7502 #endif
7503 #if !defined EDQUOT
7504 booboo
7505 #endif
7506 #if !defined ECANCELED
7507 booboo
7508 #endif
7509 #if !defined EOWNERDEAD
7510 booboo
7511 #endif
7512 #if !defined ENOTRECOVERABLE
7513 booboo
7514 #endif
7515 #if !defined EILSEQ
7516 booboo
7517 #endif
7518
7519 _ACEOF
7520 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7521 $EGREP "booboo" >/dev/null 2>&1; then :
7522 gl_cv_header_errno_h_complete=no
7523 else
7524 gl_cv_header_errno_h_complete=yes
7525 fi
7526 rm -f conftest*
7527
7528
7529 fi
7530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_complete" >&5
7531 $as_echo "$gl_cv_header_errno_h_complete" >&6; }
7532 if test $gl_cv_header_errno_h_complete = yes; then
7533 ERRNO_H=''
7534 else
7535
7536
7537
7538
7539
7540
7541
7542
7543 if test $gl_cv_have_include_next = yes; then
7544 gl_cv_next_errno_h='<'errno.h'>'
7545 else
7546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <errno.h>" >&5
7547 $as_echo_n "checking absolute name of <errno.h>... " >&6; }
7548 if ${gl_cv_next_errno_h+:} false; then :
7549 $as_echo_n "(cached) " >&6
7550 else
7551
7552
7553
7554 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7555 /* end confdefs.h. */
7556 #include <errno.h>
7557 _ACEOF
7558 case "$host_os" in
7559 aix*) gl_absname_cpp="$ac_cpp -C" ;;
7560 *) gl_absname_cpp="$ac_cpp" ;;
7561 esac
7562
7563 case "$host_os" in
7564 mingw*)
7565 gl_dirsep_regex='[/\\]'
7566 ;;
7567 *)
7568 gl_dirsep_regex='\/'
7569 ;;
7570 esac
7571 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
7572 gl_header_literal_regex=`echo 'errno.h' \
7573 | sed -e "$gl_make_literal_regex_sed"`
7574 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
7575 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
7576 s|^/[^/]|//&|
7577 p
7578 q
7579 }'
7580
7581 gl_cv_absolute_errno_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
7582 sed -n "$gl_absolute_header_sed"`
7583
7584 gl_header=$gl_cv_absolute_errno_h
7585 gl_cv_next_errno_h='"'$gl_header'"'
7586
7587
7588 fi
7589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_errno_h" >&5
7590 $as_echo "$gl_cv_next_errno_h" >&6; }
7591 fi
7592 NEXT_ERRNO_H=$gl_cv_next_errno_h
7593
7594 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
7595 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
7596 gl_next_as_first_directive='<'errno.h'>'
7597 else
7598 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
7599 gl_next_as_first_directive=$gl_cv_next_errno_h
7600 fi
7601 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H=$gl_next_as_first_directive
7602
7603
7604
7605
7606 ERRNO_H='errno.h'
7607 fi
7608
7609 if test -n "$ERRNO_H"; then
7610 GL_GENERATE_ERRNO_H_TRUE=
7611 GL_GENERATE_ERRNO_H_FALSE='#'
7612 else
7613 GL_GENERATE_ERRNO_H_TRUE='#'
7614 GL_GENERATE_ERRNO_H_FALSE=
7615 fi
7616
7617
7618 if test -n "$ERRNO_H"; then
7619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EMULTIHOP value" >&5
7620 $as_echo_n "checking for EMULTIHOP value... " >&6; }
7621 if ${gl_cv_header_errno_h_EMULTIHOP+:} false; then :
7622 $as_echo_n "(cached) " >&6
7623 else
7624
7625 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7626 /* end confdefs.h. */
7627
7628 #include <errno.h>
7629 #ifdef EMULTIHOP
7630 yes
7631 #endif
7632
7633 _ACEOF
7634 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7635 $EGREP "yes" >/dev/null 2>&1; then :
7636 gl_cv_header_errno_h_EMULTIHOP=yes
7637 else
7638 gl_cv_header_errno_h_EMULTIHOP=no
7639 fi
7640 rm -f conftest*
7641
7642 if test $gl_cv_header_errno_h_EMULTIHOP = no; then
7643 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7644 /* end confdefs.h. */
7645
7646 #define _XOPEN_SOURCE_EXTENDED 1
7647 #include <errno.h>
7648 #ifdef EMULTIHOP
7649 yes
7650 #endif
7651
7652 _ACEOF
7653 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7654 $EGREP "yes" >/dev/null 2>&1; then :
7655 gl_cv_header_errno_h_EMULTIHOP=hidden
7656 fi
7657 rm -f conftest*
7658
7659 if test $gl_cv_header_errno_h_EMULTIHOP = hidden; then
7660 if ac_fn_c_compute_int "$LINENO" "EMULTIHOP" "gl_cv_header_errno_h_EMULTIHOP" "
7661 #define _XOPEN_SOURCE_EXTENDED 1
7662 #include <errno.h>
7663 /* The following two lines are a workaround against an autoconf-2.52 bug. */
7664 #include <stdio.h>
7665 #include <stdlib.h>
7666 "; then :
7667
7668 fi
7669
7670 fi
7671 fi
7672
7673 fi
7674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EMULTIHOP" >&5
7675 $as_echo "$gl_cv_header_errno_h_EMULTIHOP" >&6; }
7676 case $gl_cv_header_errno_h_EMULTIHOP in
7677 yes | no)
7678 EMULTIHOP_HIDDEN=0; EMULTIHOP_VALUE=
7679 ;;
7680 *)
7681 EMULTIHOP_HIDDEN=1; EMULTIHOP_VALUE="$gl_cv_header_errno_h_EMULTIHOP"
7682 ;;
7683 esac
7684
7685
7686 fi
7687
7688
7689 if test -n "$ERRNO_H"; then
7690 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ENOLINK value" >&5
7691 $as_echo_n "checking for ENOLINK value... " >&6; }
7692 if ${gl_cv_header_errno_h_ENOLINK+:} false; then :
7693 $as_echo_n "(cached) " >&6
7694 else
7695
7696 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7697 /* end confdefs.h. */
7698
7699 #include <errno.h>
7700 #ifdef ENOLINK
7701 yes
7702 #endif
7703
7704 _ACEOF
7705 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7706 $EGREP "yes" >/dev/null 2>&1; then :
7707 gl_cv_header_errno_h_ENOLINK=yes
7708 else
7709 gl_cv_header_errno_h_ENOLINK=no
7710 fi
7711 rm -f conftest*
7712
7713 if test $gl_cv_header_errno_h_ENOLINK = no; then
7714 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7715 /* end confdefs.h. */
7716
7717 #define _XOPEN_SOURCE_EXTENDED 1
7718 #include <errno.h>
7719 #ifdef ENOLINK
7720 yes
7721 #endif
7722
7723 _ACEOF
7724 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7725 $EGREP "yes" >/dev/null 2>&1; then :
7726 gl_cv_header_errno_h_ENOLINK=hidden
7727 fi
7728 rm -f conftest*
7729
7730 if test $gl_cv_header_errno_h_ENOLINK = hidden; then
7731 if ac_fn_c_compute_int "$LINENO" "ENOLINK" "gl_cv_header_errno_h_ENOLINK" "
7732 #define _XOPEN_SOURCE_EXTENDED 1
7733 #include <errno.h>
7734 /* The following two lines are a workaround against an autoconf-2.52 bug. */
7735 #include <stdio.h>
7736 #include <stdlib.h>
7737 "; then :
7738
7739 fi
7740
7741 fi
7742 fi
7743
7744 fi
7745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_ENOLINK" >&5
7746 $as_echo "$gl_cv_header_errno_h_ENOLINK" >&6; }
7747 case $gl_cv_header_errno_h_ENOLINK in
7748 yes | no)
7749 ENOLINK_HIDDEN=0; ENOLINK_VALUE=
7750 ;;
7751 *)
7752 ENOLINK_HIDDEN=1; ENOLINK_VALUE="$gl_cv_header_errno_h_ENOLINK"
7753 ;;
7754 esac
7755
7756
7757 fi
7758
7759
7760 if test -n "$ERRNO_H"; then
7761 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EOVERFLOW value" >&5
7762 $as_echo_n "checking for EOVERFLOW value... " >&6; }
7763 if ${gl_cv_header_errno_h_EOVERFLOW+:} false; then :
7764 $as_echo_n "(cached) " >&6
7765 else
7766
7767 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7768 /* end confdefs.h. */
7769
7770 #include <errno.h>
7771 #ifdef EOVERFLOW
7772 yes
7773 #endif
7774
7775 _ACEOF
7776 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7777 $EGREP "yes" >/dev/null 2>&1; then :
7778 gl_cv_header_errno_h_EOVERFLOW=yes
7779 else
7780 gl_cv_header_errno_h_EOVERFLOW=no
7781 fi
7782 rm -f conftest*
7783
7784 if test $gl_cv_header_errno_h_EOVERFLOW = no; then
7785 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7786 /* end confdefs.h. */
7787
7788 #define _XOPEN_SOURCE_EXTENDED 1
7789 #include <errno.h>
7790 #ifdef EOVERFLOW
7791 yes
7792 #endif
7793
7794 _ACEOF
7795 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7796 $EGREP "yes" >/dev/null 2>&1; then :
7797 gl_cv_header_errno_h_EOVERFLOW=hidden
7798 fi
7799 rm -f conftest*
7800
7801 if test $gl_cv_header_errno_h_EOVERFLOW = hidden; then
7802 if ac_fn_c_compute_int "$LINENO" "EOVERFLOW" "gl_cv_header_errno_h_EOVERFLOW" "
7803 #define _XOPEN_SOURCE_EXTENDED 1
7804 #include <errno.h>
7805 /* The following two lines are a workaround against an autoconf-2.52 bug. */
7806 #include <stdio.h>
7807 #include <stdlib.h>
7808 "; then :
7809
7810 fi
7811
7812 fi
7813 fi
7814
7815 fi
7816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EOVERFLOW" >&5
7817 $as_echo "$gl_cv_header_errno_h_EOVERFLOW" >&6; }
7818 case $gl_cv_header_errno_h_EOVERFLOW in
7819 yes | no)
7820 EOVERFLOW_HIDDEN=0; EOVERFLOW_VALUE=
7821 ;;
7822 *)
7823 EOVERFLOW_HIDDEN=1; EOVERFLOW_VALUE="$gl_cv_header_errno_h_EOVERFLOW"
7824 ;;
7825 esac
7826
7827
7828 fi
7829
7830
7831 ac_fn_c_check_decl "$LINENO" "strerror_r" "ac_cv_have_decl_strerror_r" "$ac_includes_default"
7832 if test "x$ac_cv_have_decl_strerror_r" = xyes; then :
7833 ac_have_decl=1
7834 else
7835 ac_have_decl=0
7836 fi
7837
7838 cat >>confdefs.h <<_ACEOF
7839 #define HAVE_DECL_STRERROR_R $ac_have_decl
7840 _ACEOF
7841
7842 for ac_func in strerror_r
7843 do :
7844 ac_fn_c_check_func "$LINENO" "strerror_r" "ac_cv_func_strerror_r"
7845 if test "x$ac_cv_func_strerror_r" = xyes; then :
7846 cat >>confdefs.h <<_ACEOF
7847 #define HAVE_STRERROR_R 1
7848 _ACEOF
7849
7850 fi
7851 done
7852
7853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror_r returns char *" >&5
7854 $as_echo_n "checking whether strerror_r returns char *... " >&6; }
7855 if ${ac_cv_func_strerror_r_char_p+:} false; then :
7856 $as_echo_n "(cached) " >&6
7857 else
7858
7859 ac_cv_func_strerror_r_char_p=no
7860 if test $ac_cv_have_decl_strerror_r = yes; then
7861 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7862 /* end confdefs.h. */
7863 $ac_includes_default
7864 int
7865 main ()
7866 {
7867
7868 char buf[100];
7869 char x = *strerror_r (0, buf, sizeof buf);
7870 char *p = strerror_r (0, buf, sizeof buf);
7871 return !p || x;
7872
7873 ;
7874 return 0;
7875 }
7876 _ACEOF
7877 if ac_fn_c_try_compile "$LINENO"; then :
7878 ac_cv_func_strerror_r_char_p=yes
7879 fi
7880 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7881 else
7882 # strerror_r is not declared. Choose between
7883 # systems that have relatively inaccessible declarations for the
7884 # function. BeOS and DEC UNIX 4.0 fall in this category, but the
7885 # former has a strerror_r that returns char*, while the latter
7886 # has a strerror_r that returns `int'.
7887 # This test should segfault on the DEC system.
7888 if test "$cross_compiling" = yes; then :
7889 :
7890 else
7891 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7892 /* end confdefs.h. */
7893 $ac_includes_default
7894 extern char *strerror_r ();
7895 int
7896 main ()
7897 {
7898 char buf[100];
7899 char x = *strerror_r (0, buf, sizeof buf);
7900 return ! isalpha (x);
7901 ;
7902 return 0;
7903 }
7904 _ACEOF
7905 if ac_fn_c_try_run "$LINENO"; then :
7906 ac_cv_func_strerror_r_char_p=yes
7907 fi
7908 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7909 conftest.$ac_objext conftest.beam conftest.$ac_ext
7910 fi
7911
7912 fi
7913
7914 fi
7915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strerror_r_char_p" >&5
7916 $as_echo "$ac_cv_func_strerror_r_char_p" >&6; }
7917 if test $ac_cv_func_strerror_r_char_p = yes; then
7918
7919 $as_echo "#define STRERROR_R_CHAR_P 1" >>confdefs.h
7920
7921 fi
7922
7923
7924
7925
7926
7927 ac_fn_c_check_decl "$LINENO" "fchdir" "ac_cv_have_decl_fchdir" "$ac_includes_default"
7928 if test "x$ac_cv_have_decl_fchdir" = xyes; then :
7929 ac_have_decl=1
7930 else
7931 ac_have_decl=0
7932 fi
7933
7934 cat >>confdefs.h <<_ACEOF
7935 #define HAVE_DECL_FCHDIR $ac_have_decl
7936 _ACEOF
7937
7938
7939
7940 GNULIB_FCNTL=0;
7941 GNULIB_NONBLOCKING=0;
7942 GNULIB_OPEN=0;
7943 GNULIB_OPENAT=0;
7944 HAVE_FCNTL=1;
7945 HAVE_OPENAT=1;
7946 REPLACE_FCNTL=0;
7947 REPLACE_OPEN=0;
7948 REPLACE_OPENAT=0;
7949
7950
7951
7952
7953
7954
7955
7956
7957
7958
7959
7960
7961
7962
7963
7964 :
7965
7966
7967
7968
7969
7970
7971 :
7972
7973
7974
7975
7976
7977 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fcntl.h" >&5
7978 $as_echo_n "checking for working fcntl.h... " >&6; }
7979 if ${gl_cv_header_working_fcntl_h+:} false; then :
7980 $as_echo_n "(cached) " >&6
7981 else
7982 if test "$cross_compiling" = yes; then :
7983 gl_cv_header_working_fcntl_h=cross-compiling
7984 else
7985 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7986 /* end confdefs.h. */
7987 #include <sys/types.h>
7988 #include <sys/stat.h>
7989 #if HAVE_UNISTD_H
7990 # include <unistd.h>
7991 #else /* on Windows with MSVC */
7992 # include <io.h>
7993 # include <stdlib.h>
7994 # defined sleep(n) _sleep ((n) * 1000)
7995 #endif
7996 #include <fcntl.h>
7997 #ifndef O_NOATIME
7998 #define O_NOATIME 0
7999 #endif
8000 #ifndef O_NOFOLLOW
8001 #define O_NOFOLLOW 0
8002 #endif
8003 static int const constants[] =
8004 {
8005 O_CREAT, O_EXCL, O_NOCTTY, O_TRUNC, O_APPEND,
8006 O_NONBLOCK, O_SYNC, O_ACCMODE, O_RDONLY, O_RDWR, O_WRONLY
8007 };
8008
8009 int
8010 main ()
8011 {
8012
8013 int result = !constants;
8014 #if HAVE_SYMLINK
8015 {
8016 static char const sym[] = "conftest.sym";
8017 if (symlink ("/dev/null", sym) != 0)
8018 result |= 2;
8019 else
8020 {
8021 int fd = open (sym, O_WRONLY | O_NOFOLLOW | O_CREAT, 0);
8022 if (fd >= 0)
8023 {
8024 close (fd);
8025 result |= 4;
8026 }
8027 }
8028 if (unlink (sym) != 0 || symlink (".", sym) != 0)
8029 result |= 2;
8030 else
8031 {
8032 int fd = open (sym, O_RDONLY | O_NOFOLLOW);
8033 if (fd >= 0)
8034 {
8035 close (fd);
8036 result |= 4;
8037 }
8038 }
8039 unlink (sym);
8040 }
8041 #endif
8042 {
8043 static char const file[] = "confdefs.h";
8044 int fd = open (file, O_RDONLY | O_NOATIME);
8045 if (fd < 0)
8046 result |= 8;
8047 else
8048 {
8049 struct stat st0;
8050 if (fstat (fd, &st0) != 0)
8051 result |= 16;
8052 else
8053 {
8054 char c;
8055 sleep (1);
8056 if (read (fd, &c, 1) != 1)
8057 result |= 24;
8058 else
8059 {
8060 if (close (fd) != 0)
8061 result |= 32;
8062 else
8063 {
8064 struct stat st1;
8065 if (stat (file, &st1) != 0)
8066 result |= 40;
8067 else
8068 if (st0.st_atime != st1.st_atime)
8069 result |= 64;
8070 }
8071 }
8072 }
8073 }
8074 }
8075 return result;
8076 ;
8077 return 0;
8078 }
8079 _ACEOF
8080 if ac_fn_c_try_run "$LINENO"; then :
8081 gl_cv_header_working_fcntl_h=yes
8082 else
8083 case $? in #(
8084 4) gl_cv_header_working_fcntl_h='no (bad O_NOFOLLOW)';; #(
8085 64) gl_cv_header_working_fcntl_h='no (bad O_NOATIME)';; #(
8086 68) gl_cv_header_working_fcntl_h='no (bad O_NOATIME, O_NOFOLLOW)';; #(
8087 *) gl_cv_header_working_fcntl_h='no';;
8088 esac
8089 fi
8090 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8091 conftest.$ac_objext conftest.beam conftest.$ac_ext
8092 fi
8093
8094 fi
8095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_fcntl_h" >&5
8096 $as_echo "$gl_cv_header_working_fcntl_h" >&6; }
8097
8098 case $gl_cv_header_working_fcntl_h in #(
8099 *O_NOATIME* | no | cross-compiling) ac_val=0;; #(
8100 *) ac_val=1;;
8101 esac
8102
8103 cat >>confdefs.h <<_ACEOF
8104 #define HAVE_WORKING_O_NOATIME $ac_val
8105 _ACEOF
8106
8107
8108 case $gl_cv_header_working_fcntl_h in #(
8109 *O_NOFOLLOW* | no | cross-compiling) ac_val=0;; #(
8110 *) ac_val=1;;
8111 esac
8112
8113 cat >>confdefs.h <<_ACEOF
8114 #define HAVE_WORKING_O_NOFOLLOW $ac_val
8115 _ACEOF
8116
8117
8118 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
8119 if test "x$ac_cv_type_pid_t" = xyes; then :
8120
8121 else
8122
8123 cat >>confdefs.h <<_ACEOF
8124 #define pid_t int
8125 _ACEOF
8126
8127 fi
8128
8129 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
8130 if test "x$ac_cv_type_mode_t" = xyes; then :
8131
8132 else
8133
8134 cat >>confdefs.h <<_ACEOF
8135 #define mode_t int
8136 _ACEOF
8137
8138 fi
8139
8140
8141
8142
8143
8144
8145
8146
8147
8148
8149
8150
8151
8152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
8153 $as_echo_n "checking for mbstate_t... " >&6; }
8154 if ${ac_cv_type_mbstate_t+:} false; then :
8155 $as_echo_n "(cached) " >&6
8156 else
8157 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8158 /* end confdefs.h. */
8159 $ac_includes_default
8160 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
8161 <wchar.h>.
8162 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
8163 included before <wchar.h>. */
8164 #include <stddef.h>
8165 #include <stdio.h>
8166 #include <time.h>
8167 #include <wchar.h>
8168 int
8169 main ()
8170 {
8171 mbstate_t x; return sizeof x;
8172 ;
8173 return 0;
8174 }
8175 _ACEOF
8176 if ac_fn_c_try_compile "$LINENO"; then :
8177 ac_cv_type_mbstate_t=yes
8178 else
8179 ac_cv_type_mbstate_t=no
8180 fi
8181 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8182 fi
8183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
8184 $as_echo "$ac_cv_type_mbstate_t" >&6; }
8185 if test $ac_cv_type_mbstate_t = yes; then
8186
8187 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
8188
8189 else
8190
8191 $as_echo "#define mbstate_t int" >>confdefs.h
8192
8193 fi
8194
8195
8196
8197
8198
8199
8200
8201
8202
8203
8204
8205
8206
8207
8208
8209
8210
8211
8212
8213
8214
8215
8216
8217
8218
8219
8220
8221
8222
8223
8224
8225
8226
8227
8228
8229
8230
8231
8232
8233
8234
8235
8236 GNULIB_ACOSF=0;
8237 GNULIB_ACOSL=0;
8238 GNULIB_ASINF=0;
8239 GNULIB_ASINL=0;
8240 GNULIB_ATANF=0;
8241 GNULIB_ATANL=0;
8242 GNULIB_ATAN2F=0;
8243 GNULIB_CBRT=0;
8244 GNULIB_CBRTF=0;
8245 GNULIB_CBRTL=0;
8246 GNULIB_CEIL=0;
8247 GNULIB_CEILF=0;
8248 GNULIB_CEILL=0;
8249 GNULIB_COPYSIGN=0;
8250 GNULIB_COPYSIGNF=0;
8251 GNULIB_COPYSIGNL=0;
8252 GNULIB_COSF=0;
8253 GNULIB_COSL=0;
8254 GNULIB_COSHF=0;
8255 GNULIB_EXPF=0;
8256 GNULIB_EXPL=0;
8257 GNULIB_EXP2=0;
8258 GNULIB_EXP2F=0;
8259 GNULIB_EXP2L=0;
8260 GNULIB_EXPM1=0;
8261 GNULIB_EXPM1F=0;
8262 GNULIB_EXPM1L=0;
8263 GNULIB_FABSF=0;
8264 GNULIB_FABSL=0;
8265 GNULIB_FLOOR=0;
8266 GNULIB_FLOORF=0;
8267 GNULIB_FLOORL=0;
8268 GNULIB_FMA=0;
8269 GNULIB_FMAF=0;
8270 GNULIB_FMAL=0;
8271 GNULIB_FMOD=0;
8272 GNULIB_FMODF=0;
8273 GNULIB_FMODL=0;
8274 GNULIB_FREXPF=0;
8275 GNULIB_FREXP=0;
8276 GNULIB_FREXPL=0;
8277 GNULIB_HYPOT=0;
8278 GNULIB_HYPOTF=0;
8279 GNULIB_HYPOTL=0;
8280 GNULIB_ILOGB=0;
8281 GNULIB_ILOGBF=0;
8282 GNULIB_ILOGBL=0;
8283 GNULIB_ISFINITE=0;
8284 GNULIB_ISINF=0;
8285 GNULIB_ISNAN=0;
8286 GNULIB_ISNANF=0;
8287 GNULIB_ISNAND=0;
8288 GNULIB_ISNANL=0;
8289 GNULIB_LDEXPF=0;
8290 GNULIB_LDEXPL=0;
8291 GNULIB_LOG=0;
8292 GNULIB_LOGF=0;
8293 GNULIB_LOGL=0;
8294 GNULIB_LOG10=0;
8295 GNULIB_LOG10F=0;
8296 GNULIB_LOG10L=0;
8297 GNULIB_LOG1P=0;
8298 GNULIB_LOG1PF=0;
8299 GNULIB_LOG1PL=0;
8300 GNULIB_LOG2=0;
8301 GNULIB_LOG2F=0;
8302 GNULIB_LOG2L=0;
8303 GNULIB_LOGB=0;
8304 GNULIB_LOGBF=0;
8305 GNULIB_LOGBL=0;
8306 GNULIB_MODF=0;
8307 GNULIB_MODFF=0;
8308 GNULIB_MODFL=0;
8309 GNULIB_POWF=0;
8310 GNULIB_REMAINDER=0;
8311 GNULIB_REMAINDERF=0;
8312 GNULIB_REMAINDERL=0;
8313 GNULIB_RINT=0;
8314 GNULIB_RINTF=0;
8315 GNULIB_RINTL=0;
8316 GNULIB_ROUND=0;
8317 GNULIB_ROUNDF=0;
8318 GNULIB_ROUNDL=0;
8319 GNULIB_SIGNBIT=0;
8320 GNULIB_SINF=0;
8321 GNULIB_SINL=0;
8322 GNULIB_SINHF=0;
8323 GNULIB_SQRTF=0;
8324 GNULIB_SQRTL=0;
8325 GNULIB_TANF=0;
8326 GNULIB_TANL=0;
8327 GNULIB_TANHF=0;
8328 GNULIB_TRUNC=0;
8329 GNULIB_TRUNCF=0;
8330 GNULIB_TRUNCL=0;
8331 HAVE_ACOSF=1;
8332 HAVE_ACOSL=1;
8333 HAVE_ASINF=1;
8334 HAVE_ASINL=1;
8335 HAVE_ATANF=1;
8336 HAVE_ATANL=1;
8337 HAVE_ATAN2F=1;
8338 HAVE_CBRT=1;
8339 HAVE_CBRTF=1;
8340 HAVE_CBRTL=1;
8341 HAVE_COPYSIGN=1;
8342 HAVE_COPYSIGNL=1;
8343 HAVE_COSF=1;
8344 HAVE_COSL=1;
8345 HAVE_COSHF=1;
8346 HAVE_EXPF=1;
8347 HAVE_EXPL=1;
8348 HAVE_EXPM1=1;
8349 HAVE_EXPM1F=1;
8350 HAVE_FABSF=1;
8351 HAVE_FABSL=1;
8352 HAVE_FMA=1;
8353 HAVE_FMAF=1;
8354 HAVE_FMAL=1;
8355 HAVE_FMODF=1;
8356 HAVE_FMODL=1;
8357 HAVE_FREXPF=1;
8358 HAVE_HYPOTF=1;
8359 HAVE_HYPOTL=1;
8360 HAVE_ILOGB=1;
8361 HAVE_ILOGBF=1;
8362 HAVE_ILOGBL=1;
8363 HAVE_ISNANF=1;
8364 HAVE_ISNAND=1;
8365 HAVE_ISNANL=1;
8366 HAVE_LDEXPF=1;
8367 HAVE_LOGF=1;
8368 HAVE_LOGL=1;
8369 HAVE_LOG10F=1;
8370 HAVE_LOG10L=1;
8371 HAVE_LOG1P=1;
8372 HAVE_LOG1PF=1;
8373 HAVE_LOG1PL=1;
8374 HAVE_LOGBF=1;
8375 HAVE_LOGBL=1;
8376 HAVE_MODFF=1;
8377 HAVE_MODFL=1;
8378 HAVE_POWF=1;
8379 HAVE_REMAINDER=1;
8380 HAVE_REMAINDERF=1;
8381 HAVE_RINT=1;
8382 HAVE_RINTL=1;
8383 HAVE_SINF=1;
8384 HAVE_SINL=1;
8385 HAVE_SINHF=1;
8386 HAVE_SQRTF=1;
8387 HAVE_SQRTL=1;
8388 HAVE_TANF=1;
8389 HAVE_TANL=1;
8390 HAVE_TANHF=1;
8391 HAVE_DECL_ACOSL=1;
8392 HAVE_DECL_ASINL=1;
8393 HAVE_DECL_ATANL=1;
8394 HAVE_DECL_CBRTF=1;
8395 HAVE_DECL_CBRTL=1;
8396 HAVE_DECL_CEILF=1;
8397 HAVE_DECL_CEILL=1;
8398 HAVE_DECL_COPYSIGNF=1;
8399 HAVE_DECL_COSL=1;
8400 HAVE_DECL_EXPL=1;
8401 HAVE_DECL_EXP2=1;
8402 HAVE_DECL_EXP2F=1;
8403 HAVE_DECL_EXP2L=1;
8404 HAVE_DECL_EXPM1L=1;
8405 HAVE_DECL_FLOORF=1;
8406 HAVE_DECL_FLOORL=1;
8407 HAVE_DECL_FREXPL=1;
8408 HAVE_DECL_LDEXPL=1;
8409 HAVE_DECL_LOGL=1;
8410 HAVE_DECL_LOG10L=1;
8411 HAVE_DECL_LOG2=1;
8412 HAVE_DECL_LOG2F=1;
8413 HAVE_DECL_LOG2L=1;
8414 HAVE_DECL_LOGB=1;
8415 HAVE_DECL_REMAINDER=1;
8416 HAVE_DECL_REMAINDERL=1;
8417 HAVE_DECL_RINTF=1;
8418 HAVE_DECL_ROUND=1;
8419 HAVE_DECL_ROUNDF=1;
8420 HAVE_DECL_ROUNDL=1;
8421 HAVE_DECL_SINL=1;
8422 HAVE_DECL_SQRTL=1;
8423 HAVE_DECL_TANL=1;
8424 HAVE_DECL_TRUNC=1;
8425 HAVE_DECL_TRUNCF=1;
8426 HAVE_DECL_TRUNCL=1;
8427 REPLACE_CBRTF=0;
8428 REPLACE_CBRTL=0;
8429 REPLACE_CEIL=0;
8430 REPLACE_CEILF=0;
8431 REPLACE_CEILL=0;
8432 REPLACE_EXPM1=0;
8433 REPLACE_EXPM1F=0;
8434 REPLACE_EXP2=0;
8435 REPLACE_EXP2L=0;
8436 REPLACE_FABSL=0;
8437 REPLACE_FLOOR=0;
8438 REPLACE_FLOORF=0;
8439 REPLACE_FLOORL=0;
8440 REPLACE_FMA=0;
8441 REPLACE_FMAF=0;
8442 REPLACE_FMAL=0;
8443 REPLACE_FMOD=0;
8444 REPLACE_FMODF=0;
8445 REPLACE_FMODL=0;
8446 REPLACE_FREXPF=0;
8447 REPLACE_FREXP=0;
8448 REPLACE_FREXPL=0;
8449 REPLACE_HUGE_VAL=0;
8450 REPLACE_HYPOT=0;
8451 REPLACE_HYPOTF=0;
8452 REPLACE_HYPOTL=0;
8453 REPLACE_ILOGB=0;
8454 REPLACE_ILOGBF=0;
8455 REPLACE_ISFINITE=0;
8456 REPLACE_ISINF=0;
8457 REPLACE_ISNAN=0;
8458 REPLACE_LDEXPL=0;
8459 REPLACE_LOG=0;
8460 REPLACE_LOGF=0;
8461 REPLACE_LOGL=0;
8462 REPLACE_LOG10=0;
8463 REPLACE_LOG10F=0;
8464 REPLACE_LOG10L=0;
8465 REPLACE_LOG1P=0;
8466 REPLACE_LOG1PF=0;
8467 REPLACE_LOG1PL=0;
8468 REPLACE_LOG2=0;
8469 REPLACE_LOG2F=0;
8470 REPLACE_LOG2L=0;
8471 REPLACE_LOGB=0;
8472 REPLACE_LOGBF=0;
8473 REPLACE_LOGBL=0;
8474 REPLACE_MODF=0;
8475 REPLACE_MODFF=0;
8476 REPLACE_MODFL=0;
8477 REPLACE_NAN=0;
8478 REPLACE_REMAINDER=0;
8479 REPLACE_REMAINDERF=0;
8480 REPLACE_REMAINDERL=0;
8481 REPLACE_ROUND=0;
8482 REPLACE_ROUNDF=0;
8483 REPLACE_ROUNDL=0;
8484 REPLACE_SIGNBIT=0;
8485 REPLACE_SIGNBIT_USING_GCC=0;
8486 REPLACE_SQRTL=0;
8487 REPLACE_TRUNC=0;
8488 REPLACE_TRUNCF=0;
8489 REPLACE_TRUNCL=0;
8490
8491
8492 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexp() can be used without linking with libm" >&5
8493 $as_echo_n "checking whether frexp() can be used without linking with libm... " >&6; }
8494 if ${gl_cv_func_frexp_no_libm+:} false; then :
8495 $as_echo_n "(cached) " >&6
8496 else
8497
8498 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8499 /* end confdefs.h. */
8500 #include <math.h>
8501 double x;
8502 int
8503 main ()
8504 {
8505 int e; return frexp (x, &e) > 0;
8506 ;
8507 return 0;
8508 }
8509 _ACEOF
8510 if ac_fn_c_try_link "$LINENO"; then :
8511 gl_cv_func_frexp_no_libm=yes
8512 else
8513 gl_cv_func_frexp_no_libm=no
8514 fi
8515 rm -f core conftest.err conftest.$ac_objext \
8516 conftest$ac_exeext conftest.$ac_ext
8517
8518 fi
8519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexp_no_libm" >&5
8520 $as_echo "$gl_cv_func_frexp_no_libm" >&6; }
8521
8522
8523 ac_fn_c_check_decl "$LINENO" "alarm" "ac_cv_have_decl_alarm" "$ac_includes_default"
8524 if test "x$ac_cv_have_decl_alarm" = xyes; 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_ALARM $ac_have_decl
8532 _ACEOF
8533
8534
8535
8536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether long double and double are the same" >&5
8537 $as_echo_n "checking whether long double and double are the same... " >&6; }
8538 if ${gl_cv_long_double_equals_double+:} false; then :
8539 $as_echo_n "(cached) " >&6
8540 else
8541 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8542 /* end confdefs.h. */
8543 #include <float.h>
8544 int
8545 main ()
8546 {
8547 typedef int check[sizeof (long double) == sizeof (double)
8548 && LDBL_MANT_DIG == DBL_MANT_DIG
8549 && LDBL_MAX_EXP == DBL_MAX_EXP
8550 && LDBL_MIN_EXP == DBL_MIN_EXP
8551 ? 1 : -1];
8552
8553 ;
8554 return 0;
8555 }
8556 _ACEOF
8557 if ac_fn_c_try_compile "$LINENO"; then :
8558 gl_cv_long_double_equals_double=yes
8559 else
8560 gl_cv_long_double_equals_double=no
8561 fi
8562 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8563
8564 fi
8565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_long_double_equals_double" >&5
8566 $as_echo "$gl_cv_long_double_equals_double" >&6; }
8567 if test $gl_cv_long_double_equals_double = yes; then
8568
8569 $as_echo "#define HAVE_SAME_LONG_DOUBLE_AS_DOUBLE 1" >>confdefs.h
8570
8571 HAVE_SAME_LONG_DOUBLE_AS_DOUBLE=1
8572 else
8573 HAVE_SAME_LONG_DOUBLE_AS_DOUBLE=0
8574 fi
8575
8576
8577
8578 GNULIB_FCHMODAT=0;
8579 GNULIB_FSTAT=0;
8580 GNULIB_FSTATAT=0;
8581 GNULIB_FUTIMENS=0;
8582 GNULIB_LCHMOD=0;
8583 GNULIB_LSTAT=0;
8584 GNULIB_MKDIRAT=0;
8585 GNULIB_MKFIFO=0;
8586 GNULIB_MKFIFOAT=0;
8587 GNULIB_MKNOD=0;
8588 GNULIB_MKNODAT=0;
8589 GNULIB_STAT=0;
8590 GNULIB_UTIMENSAT=0;
8591 HAVE_FCHMODAT=1;
8592 HAVE_FSTATAT=1;
8593 HAVE_FUTIMENS=1;
8594 HAVE_LCHMOD=1;
8595 HAVE_LSTAT=1;
8596 HAVE_MKDIRAT=1;
8597 HAVE_MKFIFO=1;
8598 HAVE_MKFIFOAT=1;
8599 HAVE_MKNOD=1;
8600 HAVE_MKNODAT=1;
8601 HAVE_UTIMENSAT=1;
8602 REPLACE_FSTAT=0;
8603 REPLACE_FSTATAT=0;
8604 REPLACE_FUTIMENS=0;
8605 REPLACE_LSTAT=0;
8606 REPLACE_MKDIR=0;
8607 REPLACE_MKFIFO=0;
8608 REPLACE_MKNOD=0;
8609 REPLACE_STAT=0;
8610 REPLACE_UTIMENSAT=0;
8611
8612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
8613 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
8614 if ${ac_cv_header_stat_broken+:} false; then :
8615 $as_echo_n "(cached) " >&6
8616 else
8617 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8618 /* end confdefs.h. */
8619 #include <sys/types.h>
8620 #include <sys/stat.h>
8621
8622 #if defined S_ISBLK && defined S_IFDIR
8623 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
8624 #endif
8625
8626 #if defined S_ISBLK && defined S_IFCHR
8627 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
8628 #endif
8629
8630 #if defined S_ISLNK && defined S_IFREG
8631 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
8632 #endif
8633
8634 #if defined S_ISSOCK && defined S_IFREG
8635 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
8636 #endif
8637
8638 _ACEOF
8639 if ac_fn_c_try_compile "$LINENO"; then :
8640 ac_cv_header_stat_broken=no
8641 else
8642 ac_cv_header_stat_broken=yes
8643 fi
8644 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8645 fi
8646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
8647 $as_echo "$ac_cv_header_stat_broken" >&6; }
8648 if test $ac_cv_header_stat_broken = yes; then
8649
8650 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
8651
8652 fi
8653
8654
8655
8656
8657
8658
8659
8660
8661 case "$host_os" in
8662 mingw*)
8663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
8664 $as_echo_n "checking for 64-bit off_t... " >&6; }
8665 if ${gl_cv_type_off_t_64+:} false; then :
8666 $as_echo_n "(cached) " >&6
8667 else
8668 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8669 /* end confdefs.h. */
8670 #include <sys/types.h>
8671 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
8672
8673 int
8674 main ()
8675 {
8676
8677 ;
8678 return 0;
8679 }
8680 _ACEOF
8681 if ac_fn_c_try_compile "$LINENO"; then :
8682 gl_cv_type_off_t_64=yes
8683 else
8684 gl_cv_type_off_t_64=no
8685 fi
8686 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8687
8688 fi
8689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
8690 $as_echo "$gl_cv_type_off_t_64" >&6; }
8691 if test $gl_cv_type_off_t_64 = no; then
8692 WINDOWS_64_BIT_OFF_T=1
8693 else
8694 WINDOWS_64_BIT_OFF_T=0
8695 fi
8696 WINDOWS_64_BIT_ST_SIZE=1
8697 ;;
8698 *)
8699 WINDOWS_64_BIT_OFF_T=0
8700 WINDOWS_64_BIT_ST_SIZE=0
8701 ;;
8702 esac
8703
8704
8705
8706
8707
8708
8709
8710
8711
8712
8713
8714
8715 :
8716
8717
8718
8719
8720
8721
8722
8723
8724 if test $gl_cv_have_include_next = yes; then
8725 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
8726 else
8727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
8728 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
8729 if ${gl_cv_next_sys_stat_h+:} false; then :
8730 $as_echo_n "(cached) " >&6
8731 else
8732
8733 if test $ac_cv_header_sys_stat_h = yes; then
8734
8735
8736
8737
8738 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8739 /* end confdefs.h. */
8740 #include <sys/stat.h>
8741 _ACEOF
8742 case "$host_os" in
8743 aix*) gl_absname_cpp="$ac_cpp -C" ;;
8744 *) gl_absname_cpp="$ac_cpp" ;;
8745 esac
8746
8747 case "$host_os" in
8748 mingw*)
8749 gl_dirsep_regex='[/\\]'
8750 ;;
8751 *)
8752 gl_dirsep_regex='\/'
8753 ;;
8754 esac
8755 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
8756 gl_header_literal_regex=`echo 'sys/stat.h' \
8757 | sed -e "$gl_make_literal_regex_sed"`
8758 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
8759 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
8760 s|^/[^/]|//&|
8761 p
8762 q
8763 }'
8764
8765 gl_cv_absolute_sys_stat_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
8766 sed -n "$gl_absolute_header_sed"`
8767
8768 gl_header=$gl_cv_absolute_sys_stat_h
8769 gl_cv_next_sys_stat_h='"'$gl_header'"'
8770 else
8771 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
8772 fi
8773
8774
8775 fi
8776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
8777 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
8778 fi
8779 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
8780
8781 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
8782 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
8783 gl_next_as_first_directive='<'sys/stat.h'>'
8784 else
8785 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
8786 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
8787 fi
8788 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
8789
8790
8791
8792
8793
8794
8795
8796
8797
8798
8799
8800 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
8801
8802 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
8803
8804 fi
8805
8806 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
8807 #include <sys/stat.h>
8808 "
8809 if test "x$ac_cv_type_nlink_t" = xyes; then :
8810
8811 else
8812
8813 $as_echo "#define nlink_t int" >>confdefs.h
8814
8815 fi
8816
8817
8818
8819 for gl_func in fchmodat fstat fstatat futimens lchmod lstat mkdirat mkfifo mkfifoat mknod mknodat stat utimensat; do
8820 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
8821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
8822 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
8823 if eval \${$as_gl_Symbol+:} false; then :
8824 $as_echo_n "(cached) " >&6
8825 else
8826 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8827 /* end confdefs.h. */
8828 #include <sys/stat.h>
8829
8830 int
8831 main ()
8832 {
8833 #undef $gl_func
8834 (void) $gl_func;
8835 ;
8836 return 0;
8837 }
8838 _ACEOF
8839 if ac_fn_c_try_compile "$LINENO"; then :
8840 eval "$as_gl_Symbol=yes"
8841 else
8842 eval "$as_gl_Symbol=no"
8843 fi
8844 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8845 fi
8846 eval ac_res=\$$as_gl_Symbol
8847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
8848 $as_echo "$ac_res" >&6; }
8849 if eval test \"x\$"$as_gl_Symbol"\" = 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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
8861 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
8862 if ${gl_cv_func_lstat_dereferences_slashed_symlink+:} false; then :
8863 $as_echo_n "(cached) " >&6
8864 else
8865 rm -f conftest.sym conftest.file
8866 echo >conftest.file
8867 if test "$cross_compiling" = yes; then :
8868 case "$host_os" in
8869 *-gnu*)
8870 # Guess yes on glibc systems.
8871 gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
8872 *)
8873 # If we don't know, assume the worst.
8874 gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
8875 esac
8876
8877 else
8878 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8879 /* end confdefs.h. */
8880 $ac_includes_default
8881 int
8882 main ()
8883 {
8884 struct stat sbuf;
8885 if (symlink ("conftest.file", "conftest.sym") != 0)
8886 return 1;
8887 /* Linux will dereference the symlink and fail, as required by
8888 POSIX. That is better in the sense that it means we will not
8889 have to compile and use the lstat wrapper. */
8890 return lstat ("conftest.sym/", &sbuf) == 0;
8891
8892 ;
8893 return 0;
8894 }
8895 _ACEOF
8896 if ac_fn_c_try_run "$LINENO"; then :
8897 gl_cv_func_lstat_dereferences_slashed_symlink=yes
8898 else
8899 gl_cv_func_lstat_dereferences_slashed_symlink=no
8900 fi
8901 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8902 conftest.$ac_objext conftest.beam conftest.$ac_ext
8903 fi
8904
8905 rm -f conftest.sym conftest.file
8906
8907 fi
8908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
8909 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
8910 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
8911 *yes)
8912
8913 cat >>confdefs.h <<_ACEOF
8914 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
8915 _ACEOF
8916
8917 ;;
8918 esac
8919
8920
8921
8922
8923
8924
8925
8926
8927 :
8928
8929
8930
8931
8932
8933 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getcwd (NULL, 0) allocates memory for result" >&5
8934 $as_echo_n "checking whether getcwd (NULL, 0) allocates memory for result... " >&6; }
8935 if ${gl_cv_func_getcwd_null+:} false; then :
8936 $as_echo_n "(cached) " >&6
8937 else
8938 if test "$cross_compiling" = yes; then :
8939 case "$host_os" in
8940 # Guess yes on glibc systems.
8941 *-gnu*) gl_cv_func_getcwd_null="guessing yes";;
8942 # Guess yes on Cygwin.
8943 cygwin*) gl_cv_func_getcwd_null="guessing yes";;
8944 # If we don't know, assume the worst.
8945 *) gl_cv_func_getcwd_null="guessing no";;
8946 esac
8947
8948 else
8949 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8950 /* end confdefs.h. */
8951
8952 # include <stdlib.h>
8953 # if HAVE_UNISTD_H
8954 # include <unistd.h>
8955 # else /* on Windows with MSVC */
8956 # include <direct.h>
8957 # endif
8958 # ifndef getcwd
8959 char *getcwd ();
8960 # endif
8961
8962 int
8963 main ()
8964 {
8965
8966 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
8967 /* mingw cwd does not start with '/', but getcwd does allocate.
8968 However, mingw fails to honor non-zero size. */
8969 #else
8970 if (chdir ("/") != 0)
8971 return 1;
8972 else
8973 {
8974 char *f = getcwd (NULL, 0);
8975 if (! f)
8976 return 2;
8977 if (f[0] != '/')
8978 return 3;
8979 if (f[1] != '\0')
8980 return 4;
8981 free (f);
8982 return 0;
8983 }
8984 #endif
8985
8986 ;
8987 return 0;
8988 }
8989 _ACEOF
8990 if ac_fn_c_try_run "$LINENO"; then :
8991 gl_cv_func_getcwd_null=yes
8992 else
8993 gl_cv_func_getcwd_null=no
8994 fi
8995 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8996 conftest.$ac_objext conftest.beam conftest.$ac_ext
8997 fi
8998
8999 fi
9000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_null" >&5
9001 $as_echo "$gl_cv_func_getcwd_null" >&6; }
9002
9003
9004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getcwd with POSIX signature" >&5
9005 $as_echo_n "checking for getcwd with POSIX signature... " >&6; }
9006 if ${gl_cv_func_getcwd_posix_signature+:} false; then :
9007 $as_echo_n "(cached) " >&6
9008 else
9009 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9010 /* end confdefs.h. */
9011 #include <unistd.h>
9012 int
9013 main ()
9014 {
9015 extern
9016 #ifdef __cplusplus
9017 "C"
9018 #endif
9019 char *getcwd (char *, size_t);
9020
9021 ;
9022 return 0;
9023 }
9024
9025 _ACEOF
9026 if ac_fn_c_try_compile "$LINENO"; then :
9027 gl_cv_func_getcwd_posix_signature=yes
9028 else
9029 gl_cv_func_getcwd_posix_signature=no
9030 fi
9031 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9032
9033 fi
9034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_posix_signature" >&5
9035 $as_echo "$gl_cv_func_getcwd_posix_signature" >&6; }
9036
9037
9038 ac_fn_c_check_decl "$LINENO" "getcwd" "ac_cv_have_decl_getcwd" "$ac_includes_default"
9039 if test "x$ac_cv_have_decl_getcwd" = xyes; then :
9040 ac_have_decl=1
9041 else
9042 ac_have_decl=0
9043 fi
9044
9045 cat >>confdefs.h <<_ACEOF
9046 #define HAVE_DECL_GETCWD $ac_have_decl
9047 _ACEOF
9048
9049
9050
9051
9052
9053
9054
9055
9056 ac_fn_c_check_decl "$LINENO" "getdtablesize" "ac_cv_have_decl_getdtablesize" "$ac_includes_default"
9057 if test "x$ac_cv_have_decl_getdtablesize" = xyes; then :
9058 ac_have_decl=1
9059 else
9060 ac_have_decl=0
9061 fi
9062
9063 cat >>confdefs.h <<_ACEOF
9064 #define HAVE_DECL_GETDTABLESIZE $ac_have_decl
9065 _ACEOF
9066
9067
9068
9069 ac_fn_c_check_decl "$LINENO" "getlogin_r" "ac_cv_have_decl_getlogin_r" "$ac_includes_default"
9070 if test "x$ac_cv_have_decl_getlogin_r" = xyes; then :
9071 ac_have_decl=1
9072 else
9073 ac_have_decl=0
9074 fi
9075
9076 cat >>confdefs.h <<_ACEOF
9077 #define HAVE_DECL_GETLOGIN_R $ac_have_decl
9078 _ACEOF
9079
9080
9081
9082
9083
9084
9085
9086
9087 ac_fn_c_check_decl "$LINENO" "getlogin" "ac_cv_have_decl_getlogin" "$ac_includes_default"
9088 if test "x$ac_cv_have_decl_getlogin" = xyes; then :
9089 ac_have_decl=1
9090 else
9091 ac_have_decl=0
9092 fi
9093
9094 cat >>confdefs.h <<_ACEOF
9095 #define HAVE_DECL_GETLOGIN $ac_have_decl
9096 _ACEOF
9097
9098
9099
9100
9101
9102
9103
9104
9105
9106
9107
9108
9109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
9110 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
9111 if ${ac_cv_c_restrict+:} false; then :
9112 $as_echo_n "(cached) " >&6
9113 else
9114 ac_cv_c_restrict=no
9115 # The order here caters to the fact that C++ does not require restrict.
9116 for ac_kw in __restrict __restrict__ _Restrict restrict; do
9117 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9118 /* end confdefs.h. */
9119 typedef int *int_ptr;
9120 int foo (int_ptr $ac_kw ip) { return ip[0]; }
9121 int bar (int [$ac_kw]); /* Catch GCC bug 14050. */
9122 int bar (int ip[$ac_kw]) { return ip[0]; }
9123
9124 int
9125 main ()
9126 {
9127 int s[1];
9128 int *$ac_kw t = s;
9129 t[0] = 0;
9130 return foo (t) + bar (t);
9131
9132 ;
9133 return 0;
9134 }
9135 _ACEOF
9136 if ac_fn_c_try_compile "$LINENO"; then :
9137 ac_cv_c_restrict=$ac_kw
9138 fi
9139 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9140 test "$ac_cv_c_restrict" != no && break
9141 done
9142
9143 fi
9144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
9145 $as_echo "$ac_cv_c_restrict" >&6; }
9146
9147 case $ac_cv_c_restrict in
9148 restrict) ;;
9149 no) $as_echo "#define restrict /**/" >>confdefs.h
9150 ;;
9151 *) cat >>confdefs.h <<_ACEOF
9152 #define restrict $ac_cv_c_restrict
9153 _ACEOF
9154 ;;
9155 esac
9156
9157
9158 GNULIB_GETTIMEOFDAY=0;
9159 HAVE_GETTIMEOFDAY=1;
9160 HAVE_STRUCT_TIMEVAL=1;
9161 HAVE_SYS_TIME_H=1;
9162 HAVE_TIMEZONE_T=0;
9163 REPLACE_GETTIMEOFDAY=0;
9164 REPLACE_STRUCT_TIMEVAL=0;
9165
9166
9167
9168
9169
9170
9171
9172
9173
9174
9175 :
9176
9177
9178
9179
9180
9181
9182
9183
9184
9185
9186
9187 :
9188
9189
9190
9191
9192
9193
9194
9195
9196 if test $gl_cv_have_include_next = yes; then
9197 gl_cv_next_sys_time_h='<'sys/time.h'>'
9198 else
9199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
9200 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
9201 if ${gl_cv_next_sys_time_h+:} false; then :
9202 $as_echo_n "(cached) " >&6
9203 else
9204
9205 if test $ac_cv_header_sys_time_h = yes; then
9206
9207
9208
9209
9210 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9211 /* end confdefs.h. */
9212 #include <sys/time.h>
9213 _ACEOF
9214 case "$host_os" in
9215 aix*) gl_absname_cpp="$ac_cpp -C" ;;
9216 *) gl_absname_cpp="$ac_cpp" ;;
9217 esac
9218
9219 case "$host_os" in
9220 mingw*)
9221 gl_dirsep_regex='[/\\]'
9222 ;;
9223 *)
9224 gl_dirsep_regex='\/'
9225 ;;
9226 esac
9227 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
9228 gl_header_literal_regex=`echo 'sys/time.h' \
9229 | sed -e "$gl_make_literal_regex_sed"`
9230 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
9231 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
9232 s|^/[^/]|//&|
9233 p
9234 q
9235 }'
9236
9237 gl_cv_absolute_sys_time_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
9238 sed -n "$gl_absolute_header_sed"`
9239
9240 gl_header=$gl_cv_absolute_sys_time_h
9241 gl_cv_next_sys_time_h='"'$gl_header'"'
9242 else
9243 gl_cv_next_sys_time_h='<'sys/time.h'>'
9244 fi
9245
9246
9247 fi
9248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
9249 $as_echo "$gl_cv_next_sys_time_h" >&6; }
9250 fi
9251 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
9252
9253 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
9254 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
9255 gl_next_as_first_directive='<'sys/time.h'>'
9256 else
9257 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
9258 gl_next_as_first_directive=$gl_cv_next_sys_time_h
9259 fi
9260 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
9261
9262
9263
9264
9265
9266 if test $ac_cv_header_sys_time_h != yes; then
9267 HAVE_SYS_TIME_H=0
9268 fi
9269
9270
9271
9272
9273
9274 :
9275
9276
9277
9278
9279
9280 if test $ac_cv_header_sys_socket_h != yes; then
9281 for ac_header in winsock2.h
9282 do :
9283 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
9284 if test "x$ac_cv_header_winsock2_h" = xyes; then :
9285 cat >>confdefs.h <<_ACEOF
9286 #define HAVE_WINSOCK2_H 1
9287 _ACEOF
9288
9289 fi
9290
9291 done
9292
9293 fi
9294 if test "$ac_cv_header_winsock2_h" = yes; then
9295 HAVE_WINSOCK2_H=1
9296 UNISTD_H_HAVE_WINSOCK2_H=1
9297 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
9298 else
9299 HAVE_WINSOCK2_H=0
9300 fi
9301
9302
9303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
9304 $as_echo_n "checking for struct timeval... " >&6; }
9305 if ${gl_cv_sys_struct_timeval+:} false; then :
9306 $as_echo_n "(cached) " >&6
9307 else
9308 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9309 /* end confdefs.h. */
9310 #if HAVE_SYS_TIME_H
9311 #include <sys/time.h>
9312 #endif
9313 #include <time.h>
9314 #if HAVE_WINSOCK2_H
9315 # include <winsock2.h>
9316 #endif
9317
9318 int
9319 main ()
9320 {
9321 static struct timeval x; x.tv_sec = x.tv_usec;
9322 ;
9323 return 0;
9324 }
9325 _ACEOF
9326 if ac_fn_c_try_compile "$LINENO"; then :
9327 gl_cv_sys_struct_timeval=yes
9328 else
9329 gl_cv_sys_struct_timeval=no
9330 fi
9331 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9332
9333 fi
9334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
9335 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
9336 if test $gl_cv_sys_struct_timeval != yes; then
9337 HAVE_STRUCT_TIMEVAL=0
9338 else
9339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
9340 $as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
9341 if ${gl_cv_sys_struct_timeval_tv_sec+:} false; then :
9342 $as_echo_n "(cached) " >&6
9343 else
9344 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9345 /* end confdefs.h. */
9346 #if HAVE_SYS_TIME_H
9347 #include <sys/time.h>
9348 #endif
9349 #include <time.h>
9350 #if HAVE_WINSOCK2_H
9351 # include <winsock2.h>
9352 #endif
9353
9354 int
9355 main ()
9356 {
9357 static struct timeval x;
9358 typedef int verify_tv_sec_type[
9359 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
9360 ];
9361
9362 ;
9363 return 0;
9364 }
9365 _ACEOF
9366 if ac_fn_c_try_compile "$LINENO"; then :
9367 gl_cv_sys_struct_timeval_tv_sec=yes
9368 else
9369 gl_cv_sys_struct_timeval_tv_sec=no
9370 fi
9371 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9372
9373 fi
9374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
9375 $as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
9376 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
9377 REPLACE_STRUCT_TIMEVAL=1
9378 fi
9379 fi
9380
9381
9382 for gl_func in gettimeofday; do
9383 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
9384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
9385 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
9386 if eval \${$as_gl_Symbol+:} false; then :
9387 $as_echo_n "(cached) " >&6
9388 else
9389 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9390 /* end confdefs.h. */
9391
9392 #if HAVE_SYS_TIME_H
9393 # include <sys/time.h>
9394 #endif
9395 #include <time.h>
9396
9397 int
9398 main ()
9399 {
9400 #undef $gl_func
9401 (void) $gl_func;
9402 ;
9403 return 0;
9404 }
9405 _ACEOF
9406 if ac_fn_c_try_compile "$LINENO"; then :
9407 eval "$as_gl_Symbol=yes"
9408 else
9409 eval "$as_gl_Symbol=no"
9410 fi
9411 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9412 fi
9413 eval ac_res=\$$as_gl_Symbol
9414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
9415 $as_echo "$ac_res" >&6; }
9416 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
9417 cat >>confdefs.h <<_ACEOF
9418 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
9419 _ACEOF
9420
9421 eval ac_cv_have_decl_$gl_func=yes
9422 fi
9423 done
9424
9425
9426
9427
9428
9429
9430
9431
9432
9433
9434
9435
9436
9437
9438
9439
9440
9441
9442
9443
9444
9445
9446
9447
9448
9449
9450
9451
9452
9453
9454
9455
9456 :
9457
9458
9459
9460
9461
9462
9463
9464
9465 if test $gl_cv_have_include_next = yes; then
9466 gl_cv_next_limits_h='<'limits.h'>'
9467 else
9468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <limits.h>" >&5
9469 $as_echo_n "checking absolute name of <limits.h>... " >&6; }
9470 if ${gl_cv_next_limits_h+:} false; then :
9471 $as_echo_n "(cached) " >&6
9472 else
9473
9474 if test $ac_cv_header_limits_h = yes; then
9475
9476
9477
9478
9479 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9480 /* end confdefs.h. */
9481 #include <limits.h>
9482 _ACEOF
9483 case "$host_os" in
9484 aix*) gl_absname_cpp="$ac_cpp -C" ;;
9485 *) gl_absname_cpp="$ac_cpp" ;;
9486 esac
9487
9488 case "$host_os" in
9489 mingw*)
9490 gl_dirsep_regex='[/\\]'
9491 ;;
9492 *)
9493 gl_dirsep_regex='\/'
9494 ;;
9495 esac
9496 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
9497 gl_header_literal_regex=`echo 'limits.h' \
9498 | sed -e "$gl_make_literal_regex_sed"`
9499 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
9500 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
9501 s|^/[^/]|//&|
9502 p
9503 q
9504 }'
9505
9506 gl_cv_absolute_limits_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
9507 sed -n "$gl_absolute_header_sed"`
9508
9509 gl_header=$gl_cv_absolute_limits_h
9510 gl_cv_next_limits_h='"'$gl_header'"'
9511 else
9512 gl_cv_next_limits_h='<'limits.h'>'
9513 fi
9514
9515
9516 fi
9517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_limits_h" >&5
9518 $as_echo "$gl_cv_next_limits_h" >&6; }
9519 fi
9520 NEXT_LIMITS_H=$gl_cv_next_limits_h
9521
9522 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
9523 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
9524 gl_next_as_first_directive='<'limits.h'>'
9525 else
9526 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
9527 gl_next_as_first_directive=$gl_cv_next_limits_h
9528 fi
9529 NEXT_AS_FIRST_DIRECTIVE_LIMITS_H=$gl_next_as_first_directive
9530
9531
9532
9533
9534
9535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether limits.h has ULLONG_WIDTH etc." >&5
9536 $as_echo_n "checking whether limits.h has ULLONG_WIDTH etc.... " >&6; }
9537 if ${gl_cv_header_limits_width+:} false; then :
9538 $as_echo_n "(cached) " >&6
9539 else
9540 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9541 /* end confdefs.h. */
9542 #ifndef __STDC_WANT_IEC_60559_BFP_EXT__
9543 #define __STDC_WANT_IEC_60559_BFP_EXT__ 1
9544 #endif
9545 #include <limits.h>
9546 int ullw = ULLONG_WIDTH;
9547 int
9548 main ()
9549 {
9550
9551 ;
9552 return 0;
9553 }
9554 _ACEOF
9555 if ac_fn_c_try_compile "$LINENO"; then :
9556 gl_cv_header_limits_width=yes
9557 else
9558 gl_cv_header_limits_width=no
9559 fi
9560 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9561 fi
9562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_limits_width" >&5
9563 $as_echo "$gl_cv_header_limits_width" >&6; }
9564 if test "$gl_cv_header_limits_width" = yes; then
9565 LIMITS_H=
9566 else
9567 LIMITS_H=limits.h
9568 fi
9569
9570 if test -n "$LIMITS_H"; then
9571 GL_GENERATE_LIMITS_H_TRUE=
9572 GL_GENERATE_LIMITS_H_FALSE='#'
9573 else
9574 GL_GENERATE_LIMITS_H_TRUE='#'
9575 GL_GENERATE_LIMITS_H_FALSE=
9576 fi
9577
9578
9579
9580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
9581 $as_echo_n "checking for unsigned long long int... " >&6; }
9582 if ${ac_cv_type_unsigned_long_long_int+:} false; then :
9583 $as_echo_n "(cached) " >&6
9584 else
9585 ac_cv_type_unsigned_long_long_int=yes
9586 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
9587 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9588 /* end confdefs.h. */
9589
9590 /* For now, do not test the preprocessor; as of 2007 there are too many
9591 implementations with broken preprocessors. Perhaps this can
9592 be revisited in 2012. In the meantime, code should not expect
9593 #if to work with literals wider than 32 bits. */
9594 /* Test literals. */
9595 long long int ll = 9223372036854775807ll;
9596 long long int nll = -9223372036854775807LL;
9597 unsigned long long int ull = 18446744073709551615ULL;
9598 /* Test constant expressions. */
9599 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
9600 ? 1 : -1)];
9601 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
9602 ? 1 : -1)];
9603 int i = 63;
9604 int
9605 main ()
9606 {
9607 /* Test availability of runtime routines for shift and division. */
9608 long long int llmax = 9223372036854775807ll;
9609 unsigned long long int ullmax = 18446744073709551615ull;
9610 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
9611 | (llmax / ll) | (llmax % ll)
9612 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
9613 | (ullmax / ull) | (ullmax % ull));
9614 ;
9615 return 0;
9616 }
9617
9618 _ACEOF
9619 if ac_fn_c_try_link "$LINENO"; then :
9620
9621 else
9622 ac_cv_type_unsigned_long_long_int=no
9623 fi
9624 rm -f core conftest.err conftest.$ac_objext \
9625 conftest$ac_exeext conftest.$ac_ext
9626 fi
9627 fi
9628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
9629 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
9630 if test $ac_cv_type_unsigned_long_long_int = yes; then
9631
9632 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
9633
9634 fi
9635
9636
9637
9638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
9639 $as_echo_n "checking for long long int... " >&6; }
9640 if ${ac_cv_type_long_long_int+:} false; then :
9641 $as_echo_n "(cached) " >&6
9642 else
9643 ac_cv_type_long_long_int=yes
9644 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
9645 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
9646 if test $ac_cv_type_long_long_int = yes; then
9647 if test "$cross_compiling" = yes; then :
9648 :
9649 else
9650 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9651 /* end confdefs.h. */
9652 #include <limits.h>
9653 #ifndef LLONG_MAX
9654 # define HALF \
9655 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
9656 # define LLONG_MAX (HALF - 1 + HALF)
9657 #endif
9658 int
9659 main ()
9660 {
9661 long long int n = 1;
9662 int i;
9663 for (i = 0; ; i++)
9664 {
9665 long long int m = n << i;
9666 if (m >> i != n)
9667 return 1;
9668 if (LLONG_MAX / 2 < m)
9669 break;
9670 }
9671 return 0;
9672 ;
9673 return 0;
9674 }
9675 _ACEOF
9676 if ac_fn_c_try_run "$LINENO"; then :
9677
9678 else
9679 ac_cv_type_long_long_int=no
9680 fi
9681 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9682 conftest.$ac_objext conftest.beam conftest.$ac_ext
9683 fi
9684
9685 fi
9686 fi
9687 fi
9688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
9689 $as_echo "$ac_cv_type_long_long_int" >&6; }
9690 if test $ac_cv_type_long_long_int = yes; then
9691
9692 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
9693
9694 fi
9695
9696
9697
9698
9699
9700
9701
9702
9703
9704
9705
9706
9707 gl_cv_c_multiarch=no
9708 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9709 /* end confdefs.h. */
9710 #ifndef __APPLE_CC__
9711 not a universal capable compiler
9712 #endif
9713 typedef int dummy;
9714
9715 _ACEOF
9716 if ac_fn_c_try_compile "$LINENO"; then :
9717
9718 arch=
9719 prev=
9720 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
9721 if test -n "$prev"; then
9722 case $word in
9723 i?86 | x86_64 | ppc | ppc64)
9724 if test -z "$arch" || test "$arch" = "$word"; then
9725 arch="$word"
9726 else
9727 gl_cv_c_multiarch=yes
9728 fi
9729 ;;
9730 esac
9731 prev=
9732 else
9733 if test "x$word" = "x-arch"; then
9734 prev=arch
9735 fi
9736 fi
9737 done
9738
9739 fi
9740 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9741 if test $gl_cv_c_multiarch = yes; then
9742 APPLE_UNIVERSAL_BUILD=1
9743 else
9744 APPLE_UNIVERSAL_BUILD=0
9745 fi
9746
9747
9748
9749
9750
9751
9752
9753 if test $ac_cv_type_long_long_int = yes; then
9754 HAVE_LONG_LONG_INT=1
9755 else
9756 HAVE_LONG_LONG_INT=0
9757 fi
9758
9759
9760 if test $ac_cv_type_unsigned_long_long_int = yes; then
9761 HAVE_UNSIGNED_LONG_LONG_INT=1
9762 else
9763 HAVE_UNSIGNED_LONG_LONG_INT=0
9764 fi
9765
9766
9767
9768 :
9769
9770
9771
9772
9773
9774 if test $ac_cv_header_wchar_h = yes; then
9775 HAVE_WCHAR_H=1
9776 else
9777 HAVE_WCHAR_H=0
9778 fi
9779
9780
9781 if test $ac_cv_header_inttypes_h = yes; then
9782 HAVE_INTTYPES_H=1
9783 else
9784 HAVE_INTTYPES_H=0
9785 fi
9786
9787
9788 if test $ac_cv_header_sys_types_h = yes; then
9789 HAVE_SYS_TYPES_H=1
9790 else
9791 HAVE_SYS_TYPES_H=0
9792 fi
9793
9794
9795
9796
9797
9798
9799
9800
9801 :
9802
9803
9804
9805
9806
9807
9808
9809
9810 if test $gl_cv_have_include_next = yes; then
9811 gl_cv_next_stdint_h='<'stdint.h'>'
9812 else
9813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
9814 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
9815 if ${gl_cv_next_stdint_h+:} false; then :
9816 $as_echo_n "(cached) " >&6
9817 else
9818
9819 if test $ac_cv_header_stdint_h = yes; then
9820
9821
9822
9823
9824 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9825 /* end confdefs.h. */
9826 #include <stdint.h>
9827 _ACEOF
9828 case "$host_os" in
9829 aix*) gl_absname_cpp="$ac_cpp -C" ;;
9830 *) gl_absname_cpp="$ac_cpp" ;;
9831 esac
9832
9833 case "$host_os" in
9834 mingw*)
9835 gl_dirsep_regex='[/\\]'
9836 ;;
9837 *)
9838 gl_dirsep_regex='\/'
9839 ;;
9840 esac
9841 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
9842 gl_header_literal_regex=`echo 'stdint.h' \
9843 | sed -e "$gl_make_literal_regex_sed"`
9844 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
9845 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
9846 s|^/[^/]|//&|
9847 p
9848 q
9849 }'
9850
9851 gl_cv_absolute_stdint_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
9852 sed -n "$gl_absolute_header_sed"`
9853
9854 gl_header=$gl_cv_absolute_stdint_h
9855 gl_cv_next_stdint_h='"'$gl_header'"'
9856 else
9857 gl_cv_next_stdint_h='<'stdint.h'>'
9858 fi
9859
9860
9861 fi
9862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
9863 $as_echo "$gl_cv_next_stdint_h" >&6; }
9864 fi
9865 NEXT_STDINT_H=$gl_cv_next_stdint_h
9866
9867 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
9868 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
9869 gl_next_as_first_directive='<'stdint.h'>'
9870 else
9871 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
9872 gl_next_as_first_directive=$gl_cv_next_stdint_h
9873 fi
9874 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
9875
9876
9877
9878
9879 if test $ac_cv_header_stdint_h = yes; then
9880 HAVE_STDINT_H=1
9881 else
9882 HAVE_STDINT_H=0
9883 fi
9884
9885
9886 if test $ac_cv_header_stdint_h = yes; then
9887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
9888 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
9889 if ${gl_cv_header_working_stdint_h+:} false; then :
9890 $as_echo_n "(cached) " >&6
9891 else
9892 gl_cv_header_working_stdint_h=no
9893 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9894 /* end confdefs.h. */
9895
9896
9897 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
9898 #define __STDC_CONSTANT_MACROS 1
9899 #define __STDC_LIMIT_MACROS 1
9900 #include <stdint.h>
9901 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
9902 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
9903 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
9904 #endif
9905
9906
9907 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
9908 included before <wchar.h>. */
9909 #include <stddef.h>
9910 #include <signal.h>
9911 #if HAVE_WCHAR_H
9912 # include <stdio.h>
9913 # include <time.h>
9914 # include <wchar.h>
9915 #endif
9916
9917
9918 #ifdef INT8_MAX
9919 int8_t a1 = INT8_MAX;
9920 int8_t a1min = INT8_MIN;
9921 #endif
9922 #ifdef INT16_MAX
9923 int16_t a2 = INT16_MAX;
9924 int16_t a2min = INT16_MIN;
9925 #endif
9926 #ifdef INT32_MAX
9927 int32_t a3 = INT32_MAX;
9928 int32_t a3min = INT32_MIN;
9929 #endif
9930 #ifdef INT64_MAX
9931 int64_t a4 = INT64_MAX;
9932 int64_t a4min = INT64_MIN;
9933 #endif
9934 #ifdef UINT8_MAX
9935 uint8_t b1 = UINT8_MAX;
9936 #else
9937 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
9938 #endif
9939 #ifdef UINT16_MAX
9940 uint16_t b2 = UINT16_MAX;
9941 #endif
9942 #ifdef UINT32_MAX
9943 uint32_t b3 = UINT32_MAX;
9944 #endif
9945 #ifdef UINT64_MAX
9946 uint64_t b4 = UINT64_MAX;
9947 #endif
9948 int_least8_t c1 = INT8_C (0x7f);
9949 int_least8_t c1max = INT_LEAST8_MAX;
9950 int_least8_t c1min = INT_LEAST8_MIN;
9951 int_least16_t c2 = INT16_C (0x7fff);
9952 int_least16_t c2max = INT_LEAST16_MAX;
9953 int_least16_t c2min = INT_LEAST16_MIN;
9954 int_least32_t c3 = INT32_C (0x7fffffff);
9955 int_least32_t c3max = INT_LEAST32_MAX;
9956 int_least32_t c3min = INT_LEAST32_MIN;
9957 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
9958 int_least64_t c4max = INT_LEAST64_MAX;
9959 int_least64_t c4min = INT_LEAST64_MIN;
9960 uint_least8_t d1 = UINT8_C (0xff);
9961 uint_least8_t d1max = UINT_LEAST8_MAX;
9962 uint_least16_t d2 = UINT16_C (0xffff);
9963 uint_least16_t d2max = UINT_LEAST16_MAX;
9964 uint_least32_t d3 = UINT32_C (0xffffffff);
9965 uint_least32_t d3max = UINT_LEAST32_MAX;
9966 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
9967 uint_least64_t d4max = UINT_LEAST64_MAX;
9968 int_fast8_t e1 = INT_FAST8_MAX;
9969 int_fast8_t e1min = INT_FAST8_MIN;
9970 int_fast16_t e2 = INT_FAST16_MAX;
9971 int_fast16_t e2min = INT_FAST16_MIN;
9972 int_fast32_t e3 = INT_FAST32_MAX;
9973 int_fast32_t e3min = INT_FAST32_MIN;
9974 int_fast64_t e4 = INT_FAST64_MAX;
9975 int_fast64_t e4min = INT_FAST64_MIN;
9976 uint_fast8_t f1 = UINT_FAST8_MAX;
9977 uint_fast16_t f2 = UINT_FAST16_MAX;
9978 uint_fast32_t f3 = UINT_FAST32_MAX;
9979 uint_fast64_t f4 = UINT_FAST64_MAX;
9980 #ifdef INTPTR_MAX
9981 intptr_t g = INTPTR_MAX;
9982 intptr_t gmin = INTPTR_MIN;
9983 #endif
9984 #ifdef UINTPTR_MAX
9985 uintptr_t h = UINTPTR_MAX;
9986 #endif
9987 intmax_t i = INTMAX_MAX;
9988 uintmax_t j = UINTMAX_MAX;
9989
9990 /* Check that SIZE_MAX has the correct type, if possible. */
9991 #if 201112 <= __STDC_VERSION__
9992 int k = _Generic (SIZE_MAX, size_t: 0);
9993 #elif (2 <= __GNUC__ || defined __IBM__TYPEOF__ \
9994 || (0x5110 <= __SUNPRO_C && !__STDC__))
9995 extern size_t k;
9996 extern __typeof__ (SIZE_MAX) k;
9997 #endif
9998
9999 #include <limits.h> /* for CHAR_BIT */
10000 #define TYPE_MINIMUM(t) \
10001 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
10002 #define TYPE_MAXIMUM(t) \
10003 ((t) ((t) 0 < (t) -1 \
10004 ? (t) -1 \
10005 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
10006 struct s {
10007 int check_PTRDIFF:
10008 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
10009 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
10010 ? 1 : -1;
10011 /* Detect bug in FreeBSD 6.0 / ia64. */
10012 int check_SIG_ATOMIC:
10013 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
10014 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
10015 ? 1 : -1;
10016 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
10017 int check_WCHAR:
10018 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
10019 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
10020 ? 1 : -1;
10021 /* Detect bug in mingw. */
10022 int check_WINT:
10023 WINT_MIN == TYPE_MINIMUM (wint_t)
10024 && WINT_MAX == TYPE_MAXIMUM (wint_t)
10025 ? 1 : -1;
10026
10027 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
10028 int check_UINT8_C:
10029 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
10030 int check_UINT16_C:
10031 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
10032
10033 /* Detect bugs in OpenBSD 3.9 stdint.h. */
10034 #ifdef UINT8_MAX
10035 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
10036 #endif
10037 #ifdef UINT16_MAX
10038 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
10039 #endif
10040 #ifdef UINT32_MAX
10041 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
10042 #endif
10043 #ifdef UINT64_MAX
10044 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
10045 #endif
10046 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
10047 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
10048 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
10049 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
10050 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
10051 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
10052 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
10053 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
10054 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
10055 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
10056 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
10057 };
10058
10059 int
10060 main ()
10061 {
10062
10063 ;
10064 return 0;
10065 }
10066 _ACEOF
10067 if ac_fn_c_try_compile "$LINENO"; then :
10068 if test "$cross_compiling" = yes; then :
10069 gl_cv_header_working_stdint_h=yes
10070
10071 else
10072 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10073 /* end confdefs.h. */
10074
10075
10076 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
10077 #define __STDC_CONSTANT_MACROS 1
10078 #define __STDC_LIMIT_MACROS 1
10079 #include <stdint.h>
10080
10081
10082 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
10083 included before <wchar.h>. */
10084 #include <stddef.h>
10085 #include <signal.h>
10086 #if HAVE_WCHAR_H
10087 # include <stdio.h>
10088 # include <time.h>
10089 # include <wchar.h>
10090 #endif
10091
10092
10093 #include <stdio.h>
10094 #include <string.h>
10095 #define MVAL(macro) MVAL1(macro)
10096 #define MVAL1(expression) #expression
10097 static const char *macro_values[] =
10098 {
10099 #ifdef INT8_MAX
10100 MVAL (INT8_MAX),
10101 #endif
10102 #ifdef INT16_MAX
10103 MVAL (INT16_MAX),
10104 #endif
10105 #ifdef INT32_MAX
10106 MVAL (INT32_MAX),
10107 #endif
10108 #ifdef INT64_MAX
10109 MVAL (INT64_MAX),
10110 #endif
10111 #ifdef UINT8_MAX
10112 MVAL (UINT8_MAX),
10113 #endif
10114 #ifdef UINT16_MAX
10115 MVAL (UINT16_MAX),
10116 #endif
10117 #ifdef UINT32_MAX
10118 MVAL (UINT32_MAX),
10119 #endif
10120 #ifdef UINT64_MAX
10121 MVAL (UINT64_MAX),
10122 #endif
10123 NULL
10124 };
10125
10126 int
10127 main ()
10128 {
10129
10130 const char **mv;
10131 for (mv = macro_values; *mv != NULL; mv++)
10132 {
10133 const char *value = *mv;
10134 /* Test whether it looks like a cast expression. */
10135 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
10136 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
10137 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
10138 || strncmp (value, "((int)"/*)*/, 6) == 0
10139 || strncmp (value, "((signed short)"/*)*/, 15) == 0
10140 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
10141 return mv - macro_values + 1;
10142 }
10143 return 0;
10144
10145 ;
10146 return 0;
10147 }
10148 _ACEOF
10149 if ac_fn_c_try_run "$LINENO"; then :
10150 gl_cv_header_working_stdint_h=yes
10151 fi
10152 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10153 conftest.$ac_objext conftest.beam conftest.$ac_ext
10154 fi
10155
10156
10157 fi
10158 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10159
10160 fi
10161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
10162 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
10163 fi
10164
10165 HAVE_C99_STDINT_H=0
10166 HAVE_SYS_BITYPES_H=0
10167 HAVE_SYS_INTTYPES_H=0
10168 STDINT_H=stdint.h
10169 if test "$gl_cv_header_working_stdint_h" = yes; then
10170 HAVE_C99_STDINT_H=1
10171 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h predates C++11" >&5
10172 $as_echo_n "checking whether stdint.h predates C++11... " >&6; }
10173 if ${gl_cv_header_stdint_predates_cxx11_h+:} false; then :
10174 $as_echo_n "(cached) " >&6
10175 else
10176 gl_cv_header_stdint_predates_cxx11_h=yes
10177 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10178 /* end confdefs.h. */
10179
10180
10181 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
10182 #include <stdint.h>
10183
10184
10185 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
10186 included before <wchar.h>. */
10187 #include <stddef.h>
10188 #include <signal.h>
10189 #if HAVE_WCHAR_H
10190 # include <stdio.h>
10191 # include <time.h>
10192 # include <wchar.h>
10193 #endif
10194
10195
10196 intmax_t im = INTMAX_MAX;
10197 int32_t i32 = INT32_C (0x7fffffff);
10198
10199 int
10200 main ()
10201 {
10202
10203 ;
10204 return 0;
10205 }
10206 _ACEOF
10207 if ac_fn_c_try_compile "$LINENO"; then :
10208 gl_cv_header_stdint_predates_cxx11_h=no
10209 fi
10210 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10211 fi
10212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_stdint_predates_cxx11_h" >&5
10213 $as_echo "$gl_cv_header_stdint_predates_cxx11_h" >&6; }
10214
10215 if test "$gl_cv_header_stdint_predates_cxx11_h" = yes; then
10216
10217 $as_echo "#define __STDC_CONSTANT_MACROS 1" >>confdefs.h
10218
10219
10220 $as_echo "#define __STDC_LIMIT_MACROS 1" >>confdefs.h
10221
10222 fi
10223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h has UINTMAX_WIDTH etc." >&5
10224 $as_echo_n "checking whether stdint.h has UINTMAX_WIDTH etc.... " >&6; }
10225 if ${gl_cv_header_stdint_width+:} false; then :
10226 $as_echo_n "(cached) " >&6
10227 else
10228 gl_cv_header_stdint_width=no
10229 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10230 /* end confdefs.h. */
10231
10232 /* Work if build is not clean. */
10233 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1
10234 #ifndef __STDC_WANT_IEC_60559_BFP_EXT__
10235 #define __STDC_WANT_IEC_60559_BFP_EXT__ 1
10236 #endif
10237 #include <stdint.h>
10238
10239 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
10240 included before <wchar.h>. */
10241 #include <stddef.h>
10242 #include <signal.h>
10243 #if HAVE_WCHAR_H
10244 # include <stdio.h>
10245 # include <time.h>
10246 # include <wchar.h>
10247 #endif
10248
10249 int iw = UINTMAX_WIDTH;
10250
10251 int
10252 main ()
10253 {
10254
10255 ;
10256 return 0;
10257 }
10258 _ACEOF
10259 if ac_fn_c_try_compile "$LINENO"; then :
10260 gl_cv_header_stdint_width=yes
10261 fi
10262 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10263 fi
10264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_stdint_width" >&5
10265 $as_echo "$gl_cv_header_stdint_width" >&6; }
10266 if test "$gl_cv_header_stdint_width" = yes; then
10267 STDINT_H=
10268 fi
10269 else
10270 for ac_header in sys/inttypes.h sys/bitypes.h
10271 do :
10272 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10273 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
10274 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
10275 cat >>confdefs.h <<_ACEOF
10276 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10277 _ACEOF
10278
10279 fi
10280
10281 done
10282
10283 if test $ac_cv_header_sys_inttypes_h = yes; then
10284 HAVE_SYS_INTTYPES_H=1
10285 fi
10286 if test $ac_cv_header_sys_bitypes_h = yes; then
10287 HAVE_SYS_BITYPES_H=1
10288 fi
10289
10290
10291 if test $APPLE_UNIVERSAL_BUILD = 0; then
10292
10293
10294 for gltype in ptrdiff_t size_t ; do
10295 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
10296 $as_echo_n "checking for bit size of $gltype... " >&6; }
10297 if eval \${gl_cv_bitsizeof_${gltype}+:} false; then :
10298 $as_echo_n "(cached) " >&6
10299 else
10300 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
10301 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
10302 included before <wchar.h>. */
10303 #include <stddef.h>
10304 #include <signal.h>
10305 #if HAVE_WCHAR_H
10306 # include <stdio.h>
10307 # include <time.h>
10308 # include <wchar.h>
10309 #endif
10310
10311 #include <limits.h>"; then :
10312
10313 else
10314 result=unknown
10315 fi
10316
10317 eval gl_cv_bitsizeof_${gltype}=\$result
10318
10319 fi
10320 eval ac_res=\$gl_cv_bitsizeof_${gltype}
10321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10322 $as_echo "$ac_res" >&6; }
10323 eval result=\$gl_cv_bitsizeof_${gltype}
10324 if test $result = unknown; then
10325 result=0
10326 fi
10327 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
10328 cat >>confdefs.h <<_ACEOF
10329 #define BITSIZEOF_${GLTYPE} $result
10330 _ACEOF
10331
10332 eval BITSIZEOF_${GLTYPE}=\$result
10333 done
10334
10335
10336 fi
10337
10338
10339 for gltype in sig_atomic_t wchar_t wint_t ; do
10340 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
10341 $as_echo_n "checking for bit size of $gltype... " >&6; }
10342 if eval \${gl_cv_bitsizeof_${gltype}+:} false; then :
10343 $as_echo_n "(cached) " >&6
10344 else
10345 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
10346 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
10347 included before <wchar.h>. */
10348 #include <stddef.h>
10349 #include <signal.h>
10350 #if HAVE_WCHAR_H
10351 # include <stdio.h>
10352 # include <time.h>
10353 # include <wchar.h>
10354 #endif
10355
10356 #include <limits.h>"; then :
10357
10358 else
10359 result=unknown
10360 fi
10361
10362 eval gl_cv_bitsizeof_${gltype}=\$result
10363
10364 fi
10365 eval ac_res=\$gl_cv_bitsizeof_${gltype}
10366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10367 $as_echo "$ac_res" >&6; }
10368 eval result=\$gl_cv_bitsizeof_${gltype}
10369 if test $result = unknown; then
10370 result=0
10371 fi
10372 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
10373 cat >>confdefs.h <<_ACEOF
10374 #define BITSIZEOF_${GLTYPE} $result
10375 _ACEOF
10376
10377 eval BITSIZEOF_${GLTYPE}=\$result
10378 done
10379
10380
10381
10382
10383 for gltype in sig_atomic_t wchar_t wint_t ; do
10384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
10385 $as_echo_n "checking whether $gltype is signed... " >&6; }
10386 if eval \${gl_cv_type_${gltype}_signed+:} false; then :
10387 $as_echo_n "(cached) " >&6
10388 else
10389 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10390 /* end confdefs.h. */
10391
10392 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
10393 included before <wchar.h>. */
10394 #include <stddef.h>
10395 #include <signal.h>
10396 #if HAVE_WCHAR_H
10397 # include <stdio.h>
10398 # include <time.h>
10399 # include <wchar.h>
10400 #endif
10401
10402 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
10403 int
10404 main ()
10405 {
10406
10407 ;
10408 return 0;
10409 }
10410 _ACEOF
10411 if ac_fn_c_try_compile "$LINENO"; then :
10412 result=yes
10413 else
10414 result=no
10415 fi
10416 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10417 eval gl_cv_type_${gltype}_signed=\$result
10418
10419 fi
10420 eval ac_res=\$gl_cv_type_${gltype}_signed
10421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10422 $as_echo "$ac_res" >&6; }
10423 eval result=\$gl_cv_type_${gltype}_signed
10424 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
10425 if test "$result" = yes; then
10426 cat >>confdefs.h <<_ACEOF
10427 #define HAVE_SIGNED_${GLTYPE} 1
10428 _ACEOF
10429
10430 eval HAVE_SIGNED_${GLTYPE}=1
10431 else
10432 eval HAVE_SIGNED_${GLTYPE}=0
10433 fi
10434 done
10435
10436
10437 gl_cv_type_ptrdiff_t_signed=yes
10438 gl_cv_type_size_t_signed=no
10439 if test $APPLE_UNIVERSAL_BUILD = 0; then
10440
10441
10442 for gltype in ptrdiff_t size_t ; do
10443 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
10444 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
10445 if eval \${gl_cv_type_${gltype}_suffix+:} false; then :
10446 $as_echo_n "(cached) " >&6
10447 else
10448 eval gl_cv_type_${gltype}_suffix=no
10449 eval result=\$gl_cv_type_${gltype}_signed
10450 if test "$result" = yes; then
10451 glsufu=
10452 else
10453 glsufu=u
10454 fi
10455 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
10456 case $glsuf in
10457 '') gltype1='int';;
10458 l) gltype1='long int';;
10459 ll) gltype1='long long int';;
10460 i64) gltype1='__int64';;
10461 u) gltype1='unsigned int';;
10462 ul) gltype1='unsigned long int';;
10463 ull) gltype1='unsigned long long int';;
10464 ui64)gltype1='unsigned __int64';;
10465 esac
10466 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10467 /* end confdefs.h. */
10468
10469 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
10470 included before <wchar.h>. */
10471 #include <stddef.h>
10472 #include <signal.h>
10473 #if HAVE_WCHAR_H
10474 # include <stdio.h>
10475 # include <time.h>
10476 # include <wchar.h>
10477 #endif
10478
10479 extern $gltype foo;
10480 extern $gltype1 foo;
10481 int
10482 main ()
10483 {
10484
10485 ;
10486 return 0;
10487 }
10488 _ACEOF
10489 if ac_fn_c_try_compile "$LINENO"; then :
10490 eval gl_cv_type_${gltype}_suffix=\$glsuf
10491 fi
10492 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10493 eval result=\$gl_cv_type_${gltype}_suffix
10494 test "$result" != no && break
10495 done
10496 fi
10497 eval ac_res=\$gl_cv_type_${gltype}_suffix
10498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10499 $as_echo "$ac_res" >&6; }
10500 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
10501 eval result=\$gl_cv_type_${gltype}_suffix
10502 test "$result" = no && result=
10503 eval ${GLTYPE}_SUFFIX=\$result
10504 cat >>confdefs.h <<_ACEOF
10505 #define ${GLTYPE}_SUFFIX $result
10506 _ACEOF
10507
10508 done
10509
10510
10511 fi
10512
10513
10514 for gltype in sig_atomic_t wchar_t wint_t ; do
10515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
10516 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
10517 if eval \${gl_cv_type_${gltype}_suffix+:} false; then :
10518 $as_echo_n "(cached) " >&6
10519 else
10520 eval gl_cv_type_${gltype}_suffix=no
10521 eval result=\$gl_cv_type_${gltype}_signed
10522 if test "$result" = yes; then
10523 glsufu=
10524 else
10525 glsufu=u
10526 fi
10527 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
10528 case $glsuf in
10529 '') gltype1='int';;
10530 l) gltype1='long int';;
10531 ll) gltype1='long long int';;
10532 i64) gltype1='__int64';;
10533 u) gltype1='unsigned int';;
10534 ul) gltype1='unsigned long int';;
10535 ull) gltype1='unsigned long long int';;
10536 ui64)gltype1='unsigned __int64';;
10537 esac
10538 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10539 /* end confdefs.h. */
10540
10541 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
10542 included before <wchar.h>. */
10543 #include <stddef.h>
10544 #include <signal.h>
10545 #if HAVE_WCHAR_H
10546 # include <stdio.h>
10547 # include <time.h>
10548 # include <wchar.h>
10549 #endif
10550
10551 extern $gltype foo;
10552 extern $gltype1 foo;
10553 int
10554 main ()
10555 {
10556
10557 ;
10558 return 0;
10559 }
10560 _ACEOF
10561 if ac_fn_c_try_compile "$LINENO"; then :
10562 eval gl_cv_type_${gltype}_suffix=\$glsuf
10563 fi
10564 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10565 eval result=\$gl_cv_type_${gltype}_suffix
10566 test "$result" != no && break
10567 done
10568 fi
10569 eval ac_res=\$gl_cv_type_${gltype}_suffix
10570 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10571 $as_echo "$ac_res" >&6; }
10572 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
10573 eval result=\$gl_cv_type_${gltype}_suffix
10574 test "$result" = no && result=
10575 eval ${GLTYPE}_SUFFIX=\$result
10576 cat >>confdefs.h <<_ACEOF
10577 #define ${GLTYPE}_SUFFIX $result
10578 _ACEOF
10579
10580 done
10581
10582
10583
10584 if test $BITSIZEOF_WINT_T -lt 32; then
10585 BITSIZEOF_WINT_T=32
10586 fi
10587
10588 fi
10589
10590 # The substitute stdint.h needs the substitute limit.h's _GL_INTEGER_WIDTH.
10591 LIMITS_H=limits.h
10592 if test -n "$LIMITS_H"; then
10593 GL_GENERATE_LIMITS_H_TRUE=
10594 GL_GENERATE_LIMITS_H_FALSE='#'
10595 else
10596 GL_GENERATE_LIMITS_H_TRUE='#'
10597 GL_GENERATE_LIMITS_H_FALSE=
10598 fi
10599
10600
10601
10602
10603
10604
10605 if test -n "$STDINT_H"; then
10606 GL_GENERATE_STDINT_H_TRUE=
10607 GL_GENERATE_STDINT_H_FALSE='#'
10608 else
10609 GL_GENERATE_STDINT_H_TRUE='#'
10610 GL_GENERATE_STDINT_H_FALSE=
10611 fi
10612
10613
10614
10615
10616
10617
10618
10619
10620 GNULIB_IMAXABS=0;
10621 GNULIB_IMAXDIV=0;
10622 GNULIB_STRTOIMAX=0;
10623 GNULIB_STRTOUMAX=0;
10624 HAVE_DECL_IMAXABS=1;
10625 HAVE_DECL_IMAXDIV=1;
10626 HAVE_DECL_STRTOIMAX=1;
10627 HAVE_DECL_STRTOUMAX=1;
10628 REPLACE_STRTOIMAX=0;
10629 REPLACE_STRTOUMAX=0;
10630 INT32_MAX_LT_INTMAX_MAX=1;
10631 INT64_MAX_EQ_LONG_MAX='defined _LP64';
10632 PRI_MACROS_BROKEN=0;
10633 PRIPTR_PREFIX=__PRIPTR_PREFIX;
10634 UINT32_MAX_LT_UINTMAX_MAX=1;
10635 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
10636
10637
10638
10639
10640 :
10641
10642
10643
10644
10645
10646
10647
10648
10649
10650
10651
10652
10653
10654 :
10655
10656
10657
10658
10659
10660
10661
10662
10663 if test $gl_cv_have_include_next = yes; then
10664 gl_cv_next_inttypes_h='<'inttypes.h'>'
10665 else
10666 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
10667 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
10668 if ${gl_cv_next_inttypes_h+:} false; then :
10669 $as_echo_n "(cached) " >&6
10670 else
10671
10672 if test $ac_cv_header_inttypes_h = yes; then
10673
10674
10675
10676
10677 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10678 /* end confdefs.h. */
10679 #include <inttypes.h>
10680 _ACEOF
10681 case "$host_os" in
10682 aix*) gl_absname_cpp="$ac_cpp -C" ;;
10683 *) gl_absname_cpp="$ac_cpp" ;;
10684 esac
10685
10686 case "$host_os" in
10687 mingw*)
10688 gl_dirsep_regex='[/\\]'
10689 ;;
10690 *)
10691 gl_dirsep_regex='\/'
10692 ;;
10693 esac
10694 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
10695 gl_header_literal_regex=`echo 'inttypes.h' \
10696 | sed -e "$gl_make_literal_regex_sed"`
10697 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
10698 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
10699 s|^/[^/]|//&|
10700 p
10701 q
10702 }'
10703
10704 gl_cv_absolute_inttypes_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
10705 sed -n "$gl_absolute_header_sed"`
10706
10707 gl_header=$gl_cv_absolute_inttypes_h
10708 gl_cv_next_inttypes_h='"'$gl_header'"'
10709 else
10710 gl_cv_next_inttypes_h='<'inttypes.h'>'
10711 fi
10712
10713
10714 fi
10715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
10716 $as_echo "$gl_cv_next_inttypes_h" >&6; }
10717 fi
10718 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
10719
10720 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
10721 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
10722 gl_next_as_first_directive='<'inttypes.h'>'
10723 else
10724 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
10725 gl_next_as_first_directive=$gl_cv_next_inttypes_h
10726 fi
10727 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
10728
10729
10730
10731
10732
10733
10734
10735
10736 for gl_func in imaxabs imaxdiv strtoimax strtoumax; do
10737 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
10738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
10739 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
10740 if eval \${$as_gl_Symbol+:} false; then :
10741 $as_echo_n "(cached) " >&6
10742 else
10743 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10744 /* end confdefs.h. */
10745 #include <inttypes.h>
10746
10747 int
10748 main ()
10749 {
10750 #undef $gl_func
10751 (void) $gl_func;
10752 ;
10753 return 0;
10754 }
10755 _ACEOF
10756 if ac_fn_c_try_compile "$LINENO"; then :
10757 eval "$as_gl_Symbol=yes"
10758 else
10759 eval "$as_gl_Symbol=no"
10760 fi
10761 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10762 fi
10763 eval ac_res=\$$as_gl_Symbol
10764 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10765 $as_echo "$ac_res" >&6; }
10766 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
10767 cat >>confdefs.h <<_ACEOF
10768 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
10769 _ACEOF
10770
10771 eval ac_cv_have_decl_$gl_func=yes
10772 fi
10773 done
10774
10775
10776
10777 for ac_header in inttypes.h
10778 do :
10779 ac_fn_c_check_header_mongrel "$LINENO" "inttypes.h" "ac_cv_header_inttypes_h" "$ac_includes_default"
10780 if test "x$ac_cv_header_inttypes_h" = xyes; then :
10781 cat >>confdefs.h <<_ACEOF
10782 #define HAVE_INTTYPES_H 1
10783 _ACEOF
10784
10785 fi
10786
10787 done
10788
10789 if test $ac_cv_header_inttypes_h = yes; then
10790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the inttypes.h PRIxNN macros are broken" >&5
10791 $as_echo_n "checking whether the inttypes.h PRIxNN macros are broken... " >&6; }
10792 if ${gt_cv_inttypes_pri_broken+:} false; then :
10793 $as_echo_n "(cached) " >&6
10794 else
10795
10796 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10797 /* end confdefs.h. */
10798
10799 #include <inttypes.h>
10800 #ifdef PRId32
10801 char *p = PRId32;
10802 #endif
10803
10804 int
10805 main ()
10806 {
10807
10808 ;
10809 return 0;
10810 }
10811 _ACEOF
10812 if ac_fn_c_try_compile "$LINENO"; then :
10813 gt_cv_inttypes_pri_broken=no
10814 else
10815 gt_cv_inttypes_pri_broken=yes
10816 fi
10817 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10818
10819 fi
10820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_inttypes_pri_broken" >&5
10821 $as_echo "$gt_cv_inttypes_pri_broken" >&6; }
10822 fi
10823 if test "$gt_cv_inttypes_pri_broken" = yes; then
10824
10825 cat >>confdefs.h <<_ACEOF
10826 #define PRI_MACROS_BROKEN 1
10827 _ACEOF
10828
10829 PRI_MACROS_BROKEN=1
10830 else
10831 PRI_MACROS_BROKEN=0
10832 fi
10833
10834
10835
10836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'double'" >&5
10837 $as_echo_n "checking where to find the exponent in a 'double'... " >&6; }
10838 if ${gl_cv_cc_double_expbit0+:} false; then :
10839 $as_echo_n "(cached) " >&6
10840 else
10841
10842 if test "$cross_compiling" = yes; then :
10843
10844 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10845 /* end confdefs.h. */
10846
10847 #if defined arm || defined __arm || defined __arm__
10848 mixed_endianness
10849 #endif
10850
10851 _ACEOF
10852 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10853 $EGREP "mixed_endianness" >/dev/null 2>&1; then :
10854 gl_cv_cc_double_expbit0="unknown"
10855 else
10856
10857 :
10858 if ${ac_cv_c_bigendian+:} false; then :
10859 $as_echo_n "(cached) " >&6
10860 else
10861 ac_cv_c_bigendian=unknown
10862 # See if we're dealing with a universal compiler.
10863 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10864 /* end confdefs.h. */
10865 #ifndef __APPLE_CC__
10866 not a universal capable compiler
10867 #endif
10868 typedef int dummy;
10869
10870 _ACEOF
10871 if ac_fn_c_try_compile "$LINENO"; then :
10872
10873 # Check for potential -arch flags. It is not universal unless
10874 # there are at least two -arch flags with different values.
10875 ac_arch=
10876 ac_prev=
10877 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
10878 if test -n "$ac_prev"; then
10879 case $ac_word in
10880 i?86 | x86_64 | ppc | ppc64)
10881 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
10882 ac_arch=$ac_word
10883 else
10884 ac_cv_c_bigendian=universal
10885 break
10886 fi
10887 ;;
10888 esac
10889 ac_prev=
10890 elif test "x$ac_word" = "x-arch"; then
10891 ac_prev=arch
10892 fi
10893 done
10894 fi
10895 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10896 if test $ac_cv_c_bigendian = unknown; then
10897 # See if sys/param.h defines the BYTE_ORDER macro.
10898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10899 /* end confdefs.h. */
10900 #include <sys/types.h>
10901 #include <sys/param.h>
10902
10903 int
10904 main ()
10905 {
10906 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
10907 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
10908 && LITTLE_ENDIAN)
10909 bogus endian macros
10910 #endif
10911
10912 ;
10913 return 0;
10914 }
10915 _ACEOF
10916 if ac_fn_c_try_compile "$LINENO"; then :
10917 # It does; now see whether it defined to BIG_ENDIAN or not.
10918 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10919 /* end confdefs.h. */
10920 #include <sys/types.h>
10921 #include <sys/param.h>
10922
10923 int
10924 main ()
10925 {
10926 #if BYTE_ORDER != BIG_ENDIAN
10927 not big endian
10928 #endif
10929
10930 ;
10931 return 0;
10932 }
10933 _ACEOF
10934 if ac_fn_c_try_compile "$LINENO"; then :
10935 ac_cv_c_bigendian=yes
10936 else
10937 ac_cv_c_bigendian=no
10938 fi
10939 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10940 fi
10941 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10942 fi
10943 if test $ac_cv_c_bigendian = unknown; then
10944 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
10945 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10946 /* end confdefs.h. */
10947 #include <limits.h>
10948
10949 int
10950 main ()
10951 {
10952 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
10953 bogus endian macros
10954 #endif
10955
10956 ;
10957 return 0;
10958 }
10959 _ACEOF
10960 if ac_fn_c_try_compile "$LINENO"; then :
10961 # It does; now see whether it defined to _BIG_ENDIAN or not.
10962 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10963 /* end confdefs.h. */
10964 #include <limits.h>
10965
10966 int
10967 main ()
10968 {
10969 #ifndef _BIG_ENDIAN
10970 not big endian
10971 #endif
10972
10973 ;
10974 return 0;
10975 }
10976 _ACEOF
10977 if ac_fn_c_try_compile "$LINENO"; then :
10978 ac_cv_c_bigendian=yes
10979 else
10980 ac_cv_c_bigendian=no
10981 fi
10982 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10983 fi
10984 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10985 fi
10986 if test $ac_cv_c_bigendian = unknown; then
10987 # Compile a test program.
10988 if test "$cross_compiling" = yes; then :
10989 # Try to guess by grepping values from an object file.
10990 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10991 /* end confdefs.h. */
10992 short int ascii_mm[] =
10993 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
10994 short int ascii_ii[] =
10995 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
10996 int use_ascii (int i) {
10997 return ascii_mm[i] + ascii_ii[i];
10998 }
10999 short int ebcdic_ii[] =
11000 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
11001 short int ebcdic_mm[] =
11002 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
11003 int use_ebcdic (int i) {
11004 return ebcdic_mm[i] + ebcdic_ii[i];
11005 }
11006 extern int foo;
11007
11008 int
11009 main ()
11010 {
11011 return use_ascii (foo) == use_ebcdic (foo);
11012 ;
11013 return 0;
11014 }
11015 _ACEOF
11016 if ac_fn_c_try_compile "$LINENO"; then :
11017 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
11018 ac_cv_c_bigendian=yes
11019 fi
11020 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
11021 if test "$ac_cv_c_bigendian" = unknown; then
11022 ac_cv_c_bigendian=no
11023 else
11024 # finding both strings is unlikely to happen, but who knows?
11025 ac_cv_c_bigendian=unknown
11026 fi
11027 fi
11028 fi
11029 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11030 else
11031 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11032 /* end confdefs.h. */
11033 $ac_includes_default
11034 int
11035 main ()
11036 {
11037
11038 /* Are we little or big endian? From Harbison&Steele. */
11039 union
11040 {
11041 long int l;
11042 char c[sizeof (long int)];
11043 } u;
11044 u.l = 1;
11045 return u.c[sizeof (long int) - 1] == 1;
11046
11047 ;
11048 return 0;
11049 }
11050 _ACEOF
11051 if ac_fn_c_try_run "$LINENO"; then :
11052 ac_cv_c_bigendian=no
11053 else
11054 ac_cv_c_bigendian=yes
11055 fi
11056 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11057 conftest.$ac_objext conftest.beam conftest.$ac_ext
11058 fi
11059
11060 fi
11061 fi
11062 :
11063 case $ac_cv_c_bigendian in #(
11064 yes)
11065 gl_cv_cc_double_expbit0="word 0 bit 20";; #(
11066 no)
11067 gl_cv_cc_double_expbit0="word 1 bit 20" ;; #(
11068 universal)
11069
11070 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
11071
11072 ;; #(
11073 *)
11074 gl_cv_cc_double_expbit0="unknown" ;;
11075 esac
11076
11077
11078 fi
11079 rm -f conftest*
11080
11081
11082 else
11083 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11084 /* end confdefs.h. */
11085
11086 #include <float.h>
11087 #include <stddef.h>
11088 #include <stdio.h>
11089 #include <string.h>
11090 #define NWORDS \
11091 ((sizeof (double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
11092 typedef union { double value; unsigned int word[NWORDS]; } memory_double;
11093 static unsigned int ored_words[NWORDS];
11094 static unsigned int anded_words[NWORDS];
11095 static void add_to_ored_words (double x)
11096 {
11097 memory_double m;
11098 size_t i;
11099 /* Clear it first, in case sizeof (double) < sizeof (memory_double). */
11100 memset (&m, 0, sizeof (memory_double));
11101 m.value = x;
11102 for (i = 0; i < NWORDS; i++)
11103 {
11104 ored_words[i] |= m.word[i];
11105 anded_words[i] &= m.word[i];
11106 }
11107 }
11108 int main ()
11109 {
11110 size_t j;
11111 FILE *fp = fopen ("conftest.out", "w");
11112 if (fp == NULL)
11113 return 1;
11114 for (j = 0; j < NWORDS; j++)
11115 anded_words[j] = ~ (unsigned int) 0;
11116 add_to_ored_words (0.25);
11117 add_to_ored_words (0.5);
11118 add_to_ored_words (1.0);
11119 add_to_ored_words (2.0);
11120 add_to_ored_words (4.0);
11121 /* Remove bits that are common (e.g. if representation of the first mantissa
11122 bit is explicit). */
11123 for (j = 0; j < NWORDS; j++)
11124 ored_words[j] &= ~anded_words[j];
11125 /* Now find the nonzero word. */
11126 for (j = 0; j < NWORDS; j++)
11127 if (ored_words[j] != 0)
11128 break;
11129 if (j < NWORDS)
11130 {
11131 size_t i;
11132 for (i = j + 1; i < NWORDS; i++)
11133 if (ored_words[i] != 0)
11134 {
11135 fprintf (fp, "unknown");
11136 return (fclose (fp) != 0);
11137 }
11138 for (i = 0; ; i++)
11139 if ((ored_words[j] >> i) & 1)
11140 {
11141 fprintf (fp, "word %d bit %d", (int) j, (int) i);
11142 return (fclose (fp) != 0);
11143 }
11144 }
11145 fprintf (fp, "unknown");
11146 return (fclose (fp) != 0);
11147 }
11148
11149 _ACEOF
11150 if ac_fn_c_try_run "$LINENO"; then :
11151 gl_cv_cc_double_expbit0=`cat conftest.out`
11152 else
11153 gl_cv_cc_double_expbit0="unknown"
11154 fi
11155 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11156 conftest.$ac_objext conftest.beam conftest.$ac_ext
11157 fi
11158
11159 rm -f conftest.out
11160
11161 fi
11162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_double_expbit0" >&5
11163 $as_echo "$gl_cv_cc_double_expbit0" >&6; }
11164 case "$gl_cv_cc_double_expbit0" in
11165 word*bit*)
11166 word=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
11167 bit=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word.*bit //'`
11168
11169 cat >>confdefs.h <<_ACEOF
11170 #define DBL_EXPBIT0_WORD $word
11171 _ACEOF
11172
11173
11174 cat >>confdefs.h <<_ACEOF
11175 #define DBL_EXPBIT0_BIT $bit
11176 _ACEOF
11177
11178 ;;
11179 esac
11180
11181
11182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
11183 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
11184 if ${ac_cv_c_bigendian+:} false; then :
11185 $as_echo_n "(cached) " >&6
11186 else
11187 ac_cv_c_bigendian=unknown
11188 # See if we're dealing with a universal compiler.
11189 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11190 /* end confdefs.h. */
11191 #ifndef __APPLE_CC__
11192 not a universal capable compiler
11193 #endif
11194 typedef int dummy;
11195
11196 _ACEOF
11197 if ac_fn_c_try_compile "$LINENO"; then :
11198
11199 # Check for potential -arch flags. It is not universal unless
11200 # there are at least two -arch flags with different values.
11201 ac_arch=
11202 ac_prev=
11203 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
11204 if test -n "$ac_prev"; then
11205 case $ac_word in
11206 i?86 | x86_64 | ppc | ppc64)
11207 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
11208 ac_arch=$ac_word
11209 else
11210 ac_cv_c_bigendian=universal
11211 break
11212 fi
11213 ;;
11214 esac
11215 ac_prev=
11216 elif test "x$ac_word" = "x-arch"; then
11217 ac_prev=arch
11218 fi
11219 done
11220 fi
11221 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11222 if test $ac_cv_c_bigendian = unknown; then
11223 # See if sys/param.h defines the BYTE_ORDER macro.
11224 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11225 /* end confdefs.h. */
11226 #include <sys/types.h>
11227 #include <sys/param.h>
11228
11229 int
11230 main ()
11231 {
11232 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
11233 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
11234 && LITTLE_ENDIAN)
11235 bogus endian macros
11236 #endif
11237
11238 ;
11239 return 0;
11240 }
11241 _ACEOF
11242 if ac_fn_c_try_compile "$LINENO"; then :
11243 # It does; now see whether it defined to BIG_ENDIAN or not.
11244 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11245 /* end confdefs.h. */
11246 #include <sys/types.h>
11247 #include <sys/param.h>
11248
11249 int
11250 main ()
11251 {
11252 #if BYTE_ORDER != BIG_ENDIAN
11253 not big endian
11254 #endif
11255
11256 ;
11257 return 0;
11258 }
11259 _ACEOF
11260 if ac_fn_c_try_compile "$LINENO"; then :
11261 ac_cv_c_bigendian=yes
11262 else
11263 ac_cv_c_bigendian=no
11264 fi
11265 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11266 fi
11267 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11268 fi
11269 if test $ac_cv_c_bigendian = unknown; then
11270 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
11271 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11272 /* end confdefs.h. */
11273 #include <limits.h>
11274
11275 int
11276 main ()
11277 {
11278 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
11279 bogus endian macros
11280 #endif
11281
11282 ;
11283 return 0;
11284 }
11285 _ACEOF
11286 if ac_fn_c_try_compile "$LINENO"; then :
11287 # It does; now see whether it defined to _BIG_ENDIAN or not.
11288 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11289 /* end confdefs.h. */
11290 #include <limits.h>
11291
11292 int
11293 main ()
11294 {
11295 #ifndef _BIG_ENDIAN
11296 not big endian
11297 #endif
11298
11299 ;
11300 return 0;
11301 }
11302 _ACEOF
11303 if ac_fn_c_try_compile "$LINENO"; then :
11304 ac_cv_c_bigendian=yes
11305 else
11306 ac_cv_c_bigendian=no
11307 fi
11308 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11309 fi
11310 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11311 fi
11312 if test $ac_cv_c_bigendian = unknown; then
11313 # Compile a test program.
11314 if test "$cross_compiling" = yes; then :
11315 # Try to guess by grepping values from an object file.
11316 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11317 /* end confdefs.h. */
11318 short int ascii_mm[] =
11319 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
11320 short int ascii_ii[] =
11321 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
11322 int use_ascii (int i) {
11323 return ascii_mm[i] + ascii_ii[i];
11324 }
11325 short int ebcdic_ii[] =
11326 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
11327 short int ebcdic_mm[] =
11328 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
11329 int use_ebcdic (int i) {
11330 return ebcdic_mm[i] + ebcdic_ii[i];
11331 }
11332 extern int foo;
11333
11334 int
11335 main ()
11336 {
11337 return use_ascii (foo) == use_ebcdic (foo);
11338 ;
11339 return 0;
11340 }
11341 _ACEOF
11342 if ac_fn_c_try_compile "$LINENO"; then :
11343 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
11344 ac_cv_c_bigendian=yes
11345 fi
11346 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
11347 if test "$ac_cv_c_bigendian" = unknown; then
11348 ac_cv_c_bigendian=no
11349 else
11350 # finding both strings is unlikely to happen, but who knows?
11351 ac_cv_c_bigendian=unknown
11352 fi
11353 fi
11354 fi
11355 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11356 else
11357 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11358 /* end confdefs.h. */
11359 $ac_includes_default
11360 int
11361 main ()
11362 {
11363
11364 /* Are we little or big endian? From Harbison&Steele. */
11365 union
11366 {
11367 long int l;
11368 char c[sizeof (long int)];
11369 } u;
11370 u.l = 1;
11371 return u.c[sizeof (long int) - 1] == 1;
11372
11373 ;
11374 return 0;
11375 }
11376 _ACEOF
11377 if ac_fn_c_try_run "$LINENO"; then :
11378 ac_cv_c_bigendian=no
11379 else
11380 ac_cv_c_bigendian=yes
11381 fi
11382 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11383 conftest.$ac_objext conftest.beam conftest.$ac_ext
11384 fi
11385
11386 fi
11387 fi
11388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
11389 $as_echo "$ac_cv_c_bigendian" >&6; }
11390 case $ac_cv_c_bigendian in #(
11391 yes)
11392 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
11393 ;; #(
11394 no)
11395 ;; #(
11396 universal)
11397
11398 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
11399
11400 ;; #(
11401 *)
11402 as_fn_error $? "unknown endianness
11403 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
11404 esac
11405
11406
11407
11408 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
11409 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
11410 if ${am_cv_langinfo_codeset+:} false; then :
11411 $as_echo_n "(cached) " >&6
11412 else
11413 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11414 /* end confdefs.h. */
11415 #include <langinfo.h>
11416 int
11417 main ()
11418 {
11419 char* cs = nl_langinfo(CODESET); return !cs;
11420 ;
11421 return 0;
11422 }
11423 _ACEOF
11424 if ac_fn_c_try_link "$LINENO"; then :
11425 am_cv_langinfo_codeset=yes
11426 else
11427 am_cv_langinfo_codeset=no
11428 fi
11429 rm -f core conftest.err conftest.$ac_objext \
11430 conftest$ac_exeext conftest.$ac_ext
11431
11432 fi
11433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
11434 $as_echo "$am_cv_langinfo_codeset" >&6; }
11435 if test $am_cv_langinfo_codeset = yes; then
11436
11437 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
11438
11439 fi
11440
11441
11442 ac_fn_c_check_decl "$LINENO" "getc_unlocked" "ac_cv_have_decl_getc_unlocked" "$ac_includes_default"
11443 if test "x$ac_cv_have_decl_getc_unlocked" = xyes; then :
11444 ac_have_decl=1
11445 else
11446 ac_have_decl=0
11447 fi
11448
11449 cat >>confdefs.h <<_ACEOF
11450 #define HAVE_DECL_GETC_UNLOCKED $ac_have_decl
11451 _ACEOF
11452
11453
11454
11455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C Library >= 2.1 or uClibc" >&5
11456 $as_echo_n "checking whether we are using the GNU C Library >= 2.1 or uClibc... " >&6; }
11457 if ${ac_cv_gnu_library_2_1+:} false; then :
11458 $as_echo_n "(cached) " >&6
11459 else
11460 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11461 /* end confdefs.h. */
11462
11463 #include <features.h>
11464 #ifdef __GNU_LIBRARY__
11465 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)
11466 Lucky GNU user
11467 #endif
11468 #endif
11469 #ifdef __UCLIBC__
11470 Lucky user
11471 #endif
11472
11473 _ACEOF
11474 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11475 $EGREP "Lucky" >/dev/null 2>&1; then :
11476 ac_cv_gnu_library_2_1=yes
11477 else
11478 ac_cv_gnu_library_2_1=no
11479 fi
11480 rm -f conftest*
11481
11482
11483
11484 fi
11485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gnu_library_2_1" >&5
11486 $as_echo "$ac_cv_gnu_library_2_1" >&6; }
11487
11488 GLIBC21="$ac_cv_gnu_library_2_1"
11489
11490
11491
11492
11493
11494
11495
11496
11497 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc, realloc, calloc are POSIX compliant" >&5
11498 $as_echo_n "checking whether malloc, realloc, calloc are POSIX compliant... " >&6; }
11499 if ${gl_cv_func_malloc_posix+:} false; then :
11500 $as_echo_n "(cached) " >&6
11501 else
11502
11503 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11504 /* end confdefs.h. */
11505
11506 int
11507 main ()
11508 {
11509 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
11510 choke me
11511 #endif
11512
11513 ;
11514 return 0;
11515 }
11516 _ACEOF
11517 if ac_fn_c_try_compile "$LINENO"; then :
11518 gl_cv_func_malloc_posix=yes
11519 else
11520 gl_cv_func_malloc_posix=no
11521 fi
11522 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11523
11524 fi
11525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_malloc_posix" >&5
11526 $as_echo "$gl_cv_func_malloc_posix" >&6; }
11527
11528
11529
11530 for ac_header in stdlib.h
11531 do :
11532 ac_fn_c_check_header_mongrel "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default"
11533 if test "x$ac_cv_header_stdlib_h" = xyes; then :
11534 cat >>confdefs.h <<_ACEOF
11535 #define HAVE_STDLIB_H 1
11536 _ACEOF
11537
11538 fi
11539
11540 done
11541
11542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5
11543 $as_echo_n "checking for GNU libc compatible malloc... " >&6; }
11544 if ${ac_cv_func_malloc_0_nonnull+:} false; then :
11545 $as_echo_n "(cached) " >&6
11546 else
11547 if test "$cross_compiling" = yes; then :
11548 case "$host_os" in
11549 # Guess yes on platforms where we know the result.
11550 *-gnu* | freebsd* | netbsd* | openbsd* \
11551 | hpux* | solaris* | cygwin* | mingw*)
11552 ac_cv_func_malloc_0_nonnull=yes ;;
11553 # If we don't know, assume the worst.
11554 *) ac_cv_func_malloc_0_nonnull=no ;;
11555 esac
11556
11557 else
11558 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11559 /* end confdefs.h. */
11560 #if defined STDC_HEADERS || defined HAVE_STDLIB_H
11561 # include <stdlib.h>
11562 #else
11563 char *malloc ();
11564 #endif
11565
11566 int
11567 main ()
11568 {
11569 char *p = malloc (0);
11570 int result = !p;
11571 free (p);
11572 return result;
11573 ;
11574 return 0;
11575 }
11576
11577 _ACEOF
11578 if ac_fn_c_try_run "$LINENO"; then :
11579 ac_cv_func_malloc_0_nonnull=yes
11580 else
11581 ac_cv_func_malloc_0_nonnull=no
11582 fi
11583 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11584 conftest.$ac_objext conftest.beam conftest.$ac_ext
11585 fi
11586
11587
11588 fi
11589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_malloc_0_nonnull" >&5
11590 $as_echo "$ac_cv_func_malloc_0_nonnull" >&6; }
11591 if test $ac_cv_func_malloc_0_nonnull = yes; then :
11592 gl_cv_func_malloc_0_nonnull=1
11593 else
11594 gl_cv_func_malloc_0_nonnull=0
11595 fi
11596
11597
11598 cat >>confdefs.h <<_ACEOF
11599 #define MALLOC_0_IS_NONNULL $gl_cv_func_malloc_0_nonnull
11600 _ACEOF
11601
11602
11603
11604
11605
11606
11607
11608
11609 GNULIB_BTOWC=0;
11610 GNULIB_WCTOB=0;
11611 GNULIB_MBSINIT=0;
11612 GNULIB_MBRTOWC=0;
11613 GNULIB_MBRLEN=0;
11614 GNULIB_MBSRTOWCS=0;
11615 GNULIB_MBSNRTOWCS=0;
11616 GNULIB_WCRTOMB=0;
11617 GNULIB_WCSRTOMBS=0;
11618 GNULIB_WCSNRTOMBS=0;
11619 GNULIB_WCWIDTH=0;
11620 GNULIB_WMEMCHR=0;
11621 GNULIB_WMEMCMP=0;
11622 GNULIB_WMEMCPY=0;
11623 GNULIB_WMEMMOVE=0;
11624 GNULIB_WMEMSET=0;
11625 GNULIB_WCSLEN=0;
11626 GNULIB_WCSNLEN=0;
11627 GNULIB_WCSCPY=0;
11628 GNULIB_WCPCPY=0;
11629 GNULIB_WCSNCPY=0;
11630 GNULIB_WCPNCPY=0;
11631 GNULIB_WCSCAT=0;
11632 GNULIB_WCSNCAT=0;
11633 GNULIB_WCSCMP=0;
11634 GNULIB_WCSNCMP=0;
11635 GNULIB_WCSCASECMP=0;
11636 GNULIB_WCSNCASECMP=0;
11637 GNULIB_WCSCOLL=0;
11638 GNULIB_WCSXFRM=0;
11639 GNULIB_WCSDUP=0;
11640 GNULIB_WCSCHR=0;
11641 GNULIB_WCSRCHR=0;
11642 GNULIB_WCSCSPN=0;
11643 GNULIB_WCSSPN=0;
11644 GNULIB_WCSPBRK=0;
11645 GNULIB_WCSSTR=0;
11646 GNULIB_WCSTOK=0;
11647 GNULIB_WCSWIDTH=0;
11648 HAVE_BTOWC=1;
11649 HAVE_MBSINIT=1;
11650 HAVE_MBRTOWC=1;
11651 HAVE_MBRLEN=1;
11652 HAVE_MBSRTOWCS=1;
11653 HAVE_MBSNRTOWCS=1;
11654 HAVE_WCRTOMB=1;
11655 HAVE_WCSRTOMBS=1;
11656 HAVE_WCSNRTOMBS=1;
11657 HAVE_WMEMCHR=1;
11658 HAVE_WMEMCMP=1;
11659 HAVE_WMEMCPY=1;
11660 HAVE_WMEMMOVE=1;
11661 HAVE_WMEMSET=1;
11662 HAVE_WCSLEN=1;
11663 HAVE_WCSNLEN=1;
11664 HAVE_WCSCPY=1;
11665 HAVE_WCPCPY=1;
11666 HAVE_WCSNCPY=1;
11667 HAVE_WCPNCPY=1;
11668 HAVE_WCSCAT=1;
11669 HAVE_WCSNCAT=1;
11670 HAVE_WCSCMP=1;
11671 HAVE_WCSNCMP=1;
11672 HAVE_WCSCASECMP=1;
11673 HAVE_WCSNCASECMP=1;
11674 HAVE_WCSCOLL=1;
11675 HAVE_WCSXFRM=1;
11676 HAVE_WCSDUP=1;
11677 HAVE_WCSCHR=1;
11678 HAVE_WCSRCHR=1;
11679 HAVE_WCSCSPN=1;
11680 HAVE_WCSSPN=1;
11681 HAVE_WCSPBRK=1;
11682 HAVE_WCSSTR=1;
11683 HAVE_WCSTOK=1;
11684 HAVE_WCSWIDTH=1;
11685 HAVE_DECL_WCTOB=1;
11686 HAVE_DECL_WCWIDTH=1;
11687 REPLACE_MBSTATE_T=0;
11688 REPLACE_BTOWC=0;
11689 REPLACE_WCTOB=0;
11690 REPLACE_MBSINIT=0;
11691 REPLACE_MBRTOWC=0;
11692 REPLACE_MBRLEN=0;
11693 REPLACE_MBSRTOWCS=0;
11694 REPLACE_MBSNRTOWCS=0;
11695 REPLACE_WCRTOMB=0;
11696 REPLACE_WCSRTOMBS=0;
11697 REPLACE_WCSNRTOMBS=0;
11698 REPLACE_WCWIDTH=0;
11699 REPLACE_WCSWIDTH=0;
11700
11701
11702
11703
11704
11705
11706
11707
11708
11709
11710
11711
11712
11713
11714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional japanese locale" >&5
11715 $as_echo_n "checking for a traditional japanese locale... " >&6; }
11716 if ${gt_cv_locale_ja+:} false; then :
11717 $as_echo_n "(cached) " >&6
11718 else
11719
11720 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11721 /* end confdefs.h. */
11722
11723 #include <locale.h>
11724 #include <time.h>
11725 #if HAVE_LANGINFO_CODESET
11726 # include <langinfo.h>
11727 #endif
11728 #include <stdlib.h>
11729 #include <string.h>
11730 struct tm t;
11731 char buf[16];
11732 int main ()
11733 {
11734 const char *p;
11735 /* Check whether the given locale name is recognized by the system. */
11736 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
11737 /* On native Windows, setlocale(category, "") looks at the system settings,
11738 not at the environment variables. Also, when an encoding suffix such
11739 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
11740 category of the locale to "C". */
11741 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
11742 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
11743 return 1;
11744 #else
11745 if (setlocale (LC_ALL, "") == NULL) return 1;
11746 #endif
11747 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
11748 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
11749 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
11750 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
11751 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
11752 some unit tests fail.
11753 On MirBSD 10, when an unsupported locale is specified, setlocale()
11754 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
11755 #if HAVE_LANGINFO_CODESET
11756 {
11757 const char *cs = nl_langinfo (CODESET);
11758 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
11759 || strcmp (cs, "UTF-8") == 0)
11760 return 1;
11761 }
11762 #endif
11763 #ifdef __CYGWIN__
11764 /* On Cygwin, avoid locale names without encoding suffix, because the
11765 locale_charset() function relies on the encoding suffix. Note that
11766 LC_ALL is set on the command line. */
11767 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
11768 #endif
11769 /* Check whether MB_CUR_MAX is > 1. This excludes the dysfunctional locales
11770 on Cygwin 1.5.x. */
11771 if (MB_CUR_MAX == 1)
11772 return 1;
11773 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
11774 This excludes the UTF-8 encoding (except on MirBSD). */
11775 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
11776 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
11777 for (p = buf; *p != '\0'; p++)
11778 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
11779 return 1;
11780 return 0;
11781 }
11782
11783 _ACEOF
11784 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
11785 (eval $ac_link) 2>&5
11786 ac_status=$?
11787 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
11788 test $ac_status = 0; } && test -s conftest$ac_exeext; then
11789 case "$host_os" in
11790 # Handle native Windows specially, because there setlocale() interprets
11791 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
11792 # "fr" or "fra" as "French" or "French_France.1252",
11793 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
11794 # "ja" as "Japanese" or "Japanese_Japan.932",
11795 # and similar.
11796 mingw*)
11797 # Note that on native Windows, the Japanese locale is
11798 # Japanese_Japan.932, and CP932 is very different from EUC-JP, so we
11799 # cannot use it here.
11800 gt_cv_locale_ja=none
11801 ;;
11802 *)
11803 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
11804 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
11805 # configure script would override the LC_ALL setting. Likewise for
11806 # LC_CTYPE, which is also set at the beginning of the configure script.
11807 # Test for the AIX locale name.
11808 if (LC_ALL=ja_JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11809 gt_cv_locale_ja=ja_JP
11810 else
11811 # Test for the locale name with explicit encoding suffix.
11812 if (LC_ALL=ja_JP.EUC-JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11813 gt_cv_locale_ja=ja_JP.EUC-JP
11814 else
11815 # Test for the HP-UX, OSF/1, NetBSD locale name.
11816 if (LC_ALL=ja_JP.eucJP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11817 gt_cv_locale_ja=ja_JP.eucJP
11818 else
11819 # Test for the IRIX, FreeBSD locale name.
11820 if (LC_ALL=ja_JP.EUC LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11821 gt_cv_locale_ja=ja_JP.EUC
11822 else
11823 # Test for the Solaris 7 locale name.
11824 if (LC_ALL=ja LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11825 gt_cv_locale_ja=ja
11826 else
11827 # Special test for NetBSD 1.6.
11828 if test -f /usr/share/locale/ja_JP.eucJP/LC_CTYPE; then
11829 gt_cv_locale_ja=ja_JP.eucJP
11830 else
11831 # None found.
11832 gt_cv_locale_ja=none
11833 fi
11834 fi
11835 fi
11836 fi
11837 fi
11838 fi
11839 ;;
11840 esac
11841 fi
11842 rm -fr conftest*
11843
11844 fi
11845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_ja" >&5
11846 $as_echo "$gt_cv_locale_ja" >&6; }
11847 LOCALE_JA=$gt_cv_locale_ja
11848
11849
11850
11851
11852
11853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a transitional chinese locale" >&5
11854 $as_echo_n "checking for a transitional chinese locale... " >&6; }
11855 if ${gt_cv_locale_zh_CN+:} false; then :
11856 $as_echo_n "(cached) " >&6
11857 else
11858
11859 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11860 /* end confdefs.h. */
11861
11862 #include <locale.h>
11863 #include <stdlib.h>
11864 #include <time.h>
11865 #if HAVE_LANGINFO_CODESET
11866 # include <langinfo.h>
11867 #endif
11868 #include <stdlib.h>
11869 #include <string.h>
11870 struct tm t;
11871 char buf[16];
11872 int main ()
11873 {
11874 const char *p;
11875 /* Check whether the given locale name is recognized by the system. */
11876 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
11877 /* On native Windows, setlocale(category, "") looks at the system settings,
11878 not at the environment variables. Also, when an encoding suffix such
11879 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
11880 category of the locale to "C". */
11881 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
11882 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
11883 return 1;
11884 #else
11885 if (setlocale (LC_ALL, "") == NULL) return 1;
11886 #endif
11887 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
11888 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
11889 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
11890 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
11891 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
11892 some unit tests fail.
11893 On MirBSD 10, when an unsupported locale is specified, setlocale()
11894 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
11895 #if HAVE_LANGINFO_CODESET
11896 {
11897 const char *cs = nl_langinfo (CODESET);
11898 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
11899 || strcmp (cs, "UTF-8") == 0)
11900 return 1;
11901 }
11902 #endif
11903 #ifdef __CYGWIN__
11904 /* On Cygwin, avoid locale names without encoding suffix, because the
11905 locale_charset() function relies on the encoding suffix. Note that
11906 LC_ALL is set on the command line. */
11907 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
11908 #endif
11909 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
11910 This excludes the UTF-8 encoding (except on MirBSD). */
11911 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
11912 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
11913 for (p = buf; *p != '\0'; p++)
11914 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
11915 return 1;
11916 /* Check whether a typical GB18030 multibyte sequence is recognized as a
11917 single wide character. This excludes the GB2312 and GBK encodings. */
11918 if (mblen ("\203\062\332\066", 5) != 4)
11919 return 1;
11920 return 0;
11921 }
11922
11923 _ACEOF
11924 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
11925 (eval $ac_link) 2>&5
11926 ac_status=$?
11927 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
11928 test $ac_status = 0; } && test -s conftest$ac_exeext; then
11929 case "$host_os" in
11930 # Handle native Windows specially, because there setlocale() interprets
11931 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
11932 # "fr" or "fra" as "French" or "French_France.1252",
11933 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
11934 # "ja" as "Japanese" or "Japanese_Japan.932",
11935 # and similar.
11936 mingw*)
11937 # Test for the hypothetical native Windows locale name.
11938 if (LC_ALL=Chinese_China.54936 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11939 gt_cv_locale_zh_CN=Chinese_China.54936
11940 else
11941 # None found.
11942 gt_cv_locale_zh_CN=none
11943 fi
11944 ;;
11945 solaris2.8)
11946 # On Solaris 8, the locales zh_CN.GB18030, zh_CN.GBK, zh.GBK are
11947 # broken. One witness is the test case in gl_MBRTOWC_SANITYCHECK.
11948 # Another witness is that "LC_ALL=zh_CN.GB18030 bash -c true" dumps core.
11949 gt_cv_locale_zh_CN=none
11950 ;;
11951 *)
11952 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
11953 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
11954 # configure script would override the LC_ALL setting. Likewise for
11955 # LC_CTYPE, which is also set at the beginning of the configure script.
11956 # Test for the locale name without encoding suffix.
11957 if (LC_ALL=zh_CN LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11958 gt_cv_locale_zh_CN=zh_CN
11959 else
11960 # Test for the locale name with explicit encoding suffix.
11961 if (LC_ALL=zh_CN.GB18030 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
11962 gt_cv_locale_zh_CN=zh_CN.GB18030
11963 else
11964 # None found.
11965 gt_cv_locale_zh_CN=none
11966 fi
11967 fi
11968 ;;
11969 esac
11970 else
11971 # If there was a link error, due to mblen(), the system is so old that
11972 # it certainly doesn't have a chinese locale.
11973 gt_cv_locale_zh_CN=none
11974 fi
11975 rm -fr conftest*
11976
11977 fi
11978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_zh_CN" >&5
11979 $as_echo "$gt_cv_locale_zh_CN" >&6; }
11980 LOCALE_ZH_CN=$gt_cv_locale_zh_CN
11981
11982
11983
11984
11985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
11986 $as_echo_n "checking for a french Unicode locale... " >&6; }
11987 if ${gt_cv_locale_fr_utf8+:} false; then :
11988 $as_echo_n "(cached) " >&6
11989 else
11990
11991 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11992 /* end confdefs.h. */
11993
11994 #include <locale.h>
11995 #include <time.h>
11996 #if HAVE_LANGINFO_CODESET
11997 # include <langinfo.h>
11998 #endif
11999 #include <stdlib.h>
12000 #include <string.h>
12001 struct tm t;
12002 char buf[16];
12003 int main () {
12004 /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
12005 imitates locale dependent behaviour by looking at the environment
12006 variables, and all locales use the UTF-8 encoding. */
12007 #if !(defined __BEOS__ || defined __HAIKU__)
12008 /* Check whether the given locale name is recognized by the system. */
12009 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
12010 /* On native Windows, setlocale(category, "") looks at the system settings,
12011 not at the environment variables. Also, when an encoding suffix such
12012 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
12013 category of the locale to "C". */
12014 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
12015 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
12016 return 1;
12017 # else
12018 if (setlocale (LC_ALL, "") == NULL) return 1;
12019 # endif
12020 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
12021 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
12022 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
12023 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
12024 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
12025 some unit tests fail. */
12026 # if HAVE_LANGINFO_CODESET
12027 {
12028 const char *cs = nl_langinfo (CODESET);
12029 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
12030 return 1;
12031 }
12032 # endif
12033 # ifdef __CYGWIN__
12034 /* On Cygwin, avoid locale names without encoding suffix, because the
12035 locale_charset() function relies on the encoding suffix. Note that
12036 LC_ALL is set on the command line. */
12037 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
12038 # endif
12039 /* Check whether in the abbreviation of the second month, the second
12040 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
12041 two bytes long, with UTF-8 encoding. */
12042 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
12043 if (strftime (buf, sizeof (buf), "%b", &t) < 4
12044 || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
12045 return 1;
12046 #endif
12047 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
12048 /* Check whether the decimal separator is a comma.
12049 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
12050 are nl_langinfo(RADIXCHAR) are both ".". */
12051 if (localeconv () ->decimal_point[0] != ',') return 1;
12052 #endif
12053 return 0;
12054 }
12055
12056 _ACEOF
12057 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
12058 (eval $ac_link) 2>&5
12059 ac_status=$?
12060 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
12061 test $ac_status = 0; } && test -s conftest$ac_exeext; then
12062 case "$host_os" in
12063 # Handle native Windows specially, because there setlocale() interprets
12064 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
12065 # "fr" or "fra" as "French" or "French_France.1252",
12066 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
12067 # "ja" as "Japanese" or "Japanese_Japan.932",
12068 # and similar.
12069 mingw*)
12070 # Test for the hypothetical native Windows locale name.
12071 if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
12072 gt_cv_locale_fr_utf8=French_France.65001
12073 else
12074 # None found.
12075 gt_cv_locale_fr_utf8=none
12076 fi
12077 ;;
12078 *)
12079 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
12080 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
12081 # configure script would override the LC_ALL setting. Likewise for
12082 # LC_CTYPE, which is also set at the beginning of the configure script.
12083 # Test for the usual locale name.
12084 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
12085 gt_cv_locale_fr_utf8=fr_FR
12086 else
12087 # Test for the locale name with explicit encoding suffix.
12088 if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
12089 gt_cv_locale_fr_utf8=fr_FR.UTF-8
12090 else
12091 # Test for the Solaris 7 locale name.
12092 if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
12093 gt_cv_locale_fr_utf8=fr.UTF-8
12094 else
12095 # None found.
12096 gt_cv_locale_fr_utf8=none
12097 fi
12098 fi
12099 fi
12100 ;;
12101 esac
12102 fi
12103 rm -fr conftest*
12104
12105 fi
12106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
12107 $as_echo "$gt_cv_locale_fr_utf8" >&6; }
12108 LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
12109
12110
12111
12112
12113
12114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
12115 $as_echo_n "checking for a traditional french locale... " >&6; }
12116 if ${gt_cv_locale_fr+:} false; then :
12117 $as_echo_n "(cached) " >&6
12118 else
12119
12120 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12121 /* end confdefs.h. */
12122
12123 #include <locale.h>
12124 #include <time.h>
12125 #if HAVE_LANGINFO_CODESET
12126 # include <langinfo.h>
12127 #endif
12128 #include <stdlib.h>
12129 #include <string.h>
12130 struct tm t;
12131 char buf[16];
12132 int main () {
12133 /* Check whether the given locale name is recognized by the system. */
12134 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
12135 /* On native Windows, setlocale(category, "") looks at the system settings,
12136 not at the environment variables. Also, when an encoding suffix such
12137 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
12138 category of the locale to "C". */
12139 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
12140 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
12141 return 1;
12142 #else
12143 if (setlocale (LC_ALL, "") == NULL) return 1;
12144 #endif
12145 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
12146 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
12147 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
12148 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
12149 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
12150 some unit tests fail.
12151 On MirBSD 10, when an unsupported locale is specified, setlocale()
12152 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
12153 #if HAVE_LANGINFO_CODESET
12154 {
12155 const char *cs = nl_langinfo (CODESET);
12156 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
12157 || strcmp (cs, "UTF-8") == 0)
12158 return 1;
12159 }
12160 #endif
12161 #ifdef __CYGWIN__
12162 /* On Cygwin, avoid locale names without encoding suffix, because the
12163 locale_charset() function relies on the encoding suffix. Note that
12164 LC_ALL is set on the command line. */
12165 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
12166 #endif
12167 /* Check whether in the abbreviation of the second month, the second
12168 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
12169 one byte long. This excludes the UTF-8 encoding. */
12170 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
12171 if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
12172 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
12173 /* Check whether the decimal separator is a comma.
12174 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
12175 are nl_langinfo(RADIXCHAR) are both ".". */
12176 if (localeconv () ->decimal_point[0] != ',') return 1;
12177 #endif
12178 return 0;
12179 }
12180
12181 _ACEOF
12182 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
12183 (eval $ac_link) 2>&5
12184 ac_status=$?
12185 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
12186 test $ac_status = 0; } && test -s conftest$ac_exeext; then
12187 case "$host_os" in
12188 # Handle native Windows specially, because there setlocale() interprets
12189 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
12190 # "fr" or "fra" as "French" or "French_France.1252",
12191 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
12192 # "ja" as "Japanese" or "Japanese_Japan.932",
12193 # and similar.
12194 mingw*)
12195 # Test for the native Windows locale name.
12196 if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
12197 gt_cv_locale_fr=French_France.1252
12198 else
12199 # None found.
12200 gt_cv_locale_fr=none
12201 fi
12202 ;;
12203 *)
12204 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
12205 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
12206 # configure script would override the LC_ALL setting. Likewise for
12207 # LC_CTYPE, which is also set at the beginning of the configure script.
12208 # Test for the usual locale name.
12209 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
12210 gt_cv_locale_fr=fr_FR
12211 else
12212 # Test for the locale name with explicit encoding suffix.
12213 if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
12214 gt_cv_locale_fr=fr_FR.ISO-8859-1
12215 else
12216 # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
12217 if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
12218 gt_cv_locale_fr=fr_FR.ISO8859-1
12219 else
12220 # Test for the HP-UX locale name.
12221 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
12222 gt_cv_locale_fr=fr_FR.iso88591
12223 else
12224 # Test for the Solaris 7 locale name.
12225 if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
12226 gt_cv_locale_fr=fr
12227 else
12228 # None found.
12229 gt_cv_locale_fr=none
12230 fi
12231 fi
12232 fi
12233 fi
12234 fi
12235 ;;
12236 esac
12237 fi
12238 rm -fr conftest*
12239
12240 fi
12241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
12242 $as_echo "$gt_cv_locale_fr" >&6; }
12243 LOCALE_FR=$gt_cv_locale_fr
12244
12245
12246
12247
12248
12249
12250
12251
12252
12253
12254
12255
12256
12257 GNULIB_FFSL=0;
12258 GNULIB_FFSLL=0;
12259 GNULIB_MEMCHR=0;
12260 GNULIB_MEMMEM=0;
12261 GNULIB_MEMPCPY=0;
12262 GNULIB_MEMRCHR=0;
12263 GNULIB_RAWMEMCHR=0;
12264 GNULIB_STPCPY=0;
12265 GNULIB_STPNCPY=0;
12266 GNULIB_STRCHRNUL=0;
12267 GNULIB_STRDUP=0;
12268 GNULIB_STRNCAT=0;
12269 GNULIB_STRNDUP=0;
12270 GNULIB_STRNLEN=0;
12271 GNULIB_STRPBRK=0;
12272 GNULIB_STRSEP=0;
12273 GNULIB_STRSTR=0;
12274 GNULIB_STRCASESTR=0;
12275 GNULIB_STRTOK_R=0;
12276 GNULIB_MBSLEN=0;
12277 GNULIB_MBSNLEN=0;
12278 GNULIB_MBSCHR=0;
12279 GNULIB_MBSRCHR=0;
12280 GNULIB_MBSSTR=0;
12281 GNULIB_MBSCASECMP=0;
12282 GNULIB_MBSNCASECMP=0;
12283 GNULIB_MBSPCASECMP=0;
12284 GNULIB_MBSCASESTR=0;
12285 GNULIB_MBSCSPN=0;
12286 GNULIB_MBSPBRK=0;
12287 GNULIB_MBSSPN=0;
12288 GNULIB_MBSSEP=0;
12289 GNULIB_MBSTOK_R=0;
12290 GNULIB_STRERROR=0;
12291 GNULIB_STRERROR_R=0;
12292 GNULIB_STRSIGNAL=0;
12293 GNULIB_STRVERSCMP=0;
12294 HAVE_MBSLEN=0;
12295 HAVE_FFSL=1;
12296 HAVE_FFSLL=1;
12297 HAVE_MEMCHR=1;
12298 HAVE_DECL_MEMMEM=1;
12299 HAVE_MEMPCPY=1;
12300 HAVE_DECL_MEMRCHR=1;
12301 HAVE_RAWMEMCHR=1;
12302 HAVE_STPCPY=1;
12303 HAVE_STPNCPY=1;
12304 HAVE_STRCHRNUL=1;
12305 HAVE_DECL_STRDUP=1;
12306 HAVE_DECL_STRNDUP=1;
12307 HAVE_DECL_STRNLEN=1;
12308 HAVE_STRPBRK=1;
12309 HAVE_STRSEP=1;
12310 HAVE_STRCASESTR=1;
12311 HAVE_DECL_STRTOK_R=1;
12312 HAVE_DECL_STRERROR_R=1;
12313 HAVE_DECL_STRSIGNAL=1;
12314 HAVE_STRVERSCMP=1;
12315 REPLACE_MEMCHR=0;
12316 REPLACE_MEMMEM=0;
12317 REPLACE_STPNCPY=0;
12318 REPLACE_STRDUP=0;
12319 REPLACE_STRSTR=0;
12320 REPLACE_STRCASESTR=0;
12321 REPLACE_STRCHRNUL=0;
12322 REPLACE_STRERROR=0;
12323 REPLACE_STRERROR_R=0;
12324 REPLACE_STRNCAT=0;
12325 REPLACE_STRNDUP=0;
12326 REPLACE_STRNLEN=0;
12327 REPLACE_STRSIGNAL=0;
12328 REPLACE_STRTOK_R=0;
12329 UNDEFINE_STRTOK_R=0;
12330
12331
12332
12333
12334
12335 # Check for mmap(). Don't use AC_FUNC_MMAP, because it checks too much: it
12336 # fails on HP-UX 11, because MAP_FIXED mappings do not work. But this is
12337 # irrelevant for anonymous mappings.
12338 ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap"
12339 if test "x$ac_cv_func_mmap" = xyes; then :
12340 gl_have_mmap=yes
12341 else
12342 gl_have_mmap=no
12343 fi
12344
12345
12346 # Try to allow MAP_ANONYMOUS.
12347 gl_have_mmap_anonymous=no
12348 if test $gl_have_mmap = yes; then
12349 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAP_ANONYMOUS" >&5
12350 $as_echo_n "checking for MAP_ANONYMOUS... " >&6; }
12351 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12352 /* end confdefs.h. */
12353
12354 #include <sys/mman.h>
12355 #ifdef MAP_ANONYMOUS
12356 I cannot identify this map
12357 #endif
12358
12359 _ACEOF
12360 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12361 $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
12362 gl_have_mmap_anonymous=yes
12363 fi
12364 rm -f conftest*
12365
12366 if test $gl_have_mmap_anonymous != yes; then
12367 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12368 /* end confdefs.h. */
12369
12370 #include <sys/mman.h>
12371 #ifdef MAP_ANON
12372 I cannot identify this map
12373 #endif
12374
12375 _ACEOF
12376 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12377 $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
12378
12379 $as_echo "#define MAP_ANONYMOUS MAP_ANON" >>confdefs.h
12380
12381 gl_have_mmap_anonymous=yes
12382 fi
12383 rm -f conftest*
12384
12385 fi
12386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_have_mmap_anonymous" >&5
12387 $as_echo "$gl_have_mmap_anonymous" >&6; }
12388 if test $gl_have_mmap_anonymous = yes; then
12389
12390 $as_echo "#define HAVE_MAP_ANONYMOUS 1" >>confdefs.h
12391
12392 fi
12393 fi
12394
12395
12396 :
12397
12398
12399
12400
12401
12402
12403 :
12404
12405
12406
12407
12408
12409
12410
12411
12412 if test $HAVE_MEMCHR = 1; then
12413 # Detect platform-specific bugs in some versions of glibc:
12414 # memchr should not dereference anything with length 0
12415 # http://bugzilla.redhat.com/499689
12416 # memchr should not dereference overestimated length after a match
12417 # http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=521737
12418 # http://sourceware.org/bugzilla/show_bug.cgi?id=10162
12419 # Assume that memchr works on platforms that lack mprotect.
12420 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memchr works" >&5
12421 $as_echo_n "checking whether memchr works... " >&6; }
12422 if ${gl_cv_func_memchr_works+:} false; then :
12423 $as_echo_n "(cached) " >&6
12424 else
12425 if test "$cross_compiling" = yes; then :
12426 gl_cv_func_memchr_works="guessing no"
12427 else
12428 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12429 /* end confdefs.h. */
12430
12431 #include <string.h>
12432 #if HAVE_SYS_MMAN_H
12433 # include <fcntl.h>
12434 # include <unistd.h>
12435 # include <sys/types.h>
12436 # include <sys/mman.h>
12437 # ifndef MAP_FILE
12438 # define MAP_FILE 0
12439 # endif
12440 #endif
12441
12442 int
12443 main ()
12444 {
12445
12446 int result = 0;
12447 char *fence = NULL;
12448 #if HAVE_SYS_MMAN_H && HAVE_MPROTECT
12449 # if HAVE_MAP_ANONYMOUS
12450 const int flags = MAP_ANONYMOUS | MAP_PRIVATE;
12451 const int fd = -1;
12452 # else /* !HAVE_MAP_ANONYMOUS */
12453 const int flags = MAP_FILE | MAP_PRIVATE;
12454 int fd = open ("/dev/zero", O_RDONLY, 0666);
12455 if (fd >= 0)
12456 # endif
12457 {
12458 int pagesize = getpagesize ();
12459 char *two_pages =
12460 (char *) mmap (NULL, 2 * pagesize, PROT_READ | PROT_WRITE,
12461 flags, fd, 0);
12462 if (two_pages != (char *)(-1)
12463 && mprotect (two_pages + pagesize, pagesize, PROT_NONE) == 0)
12464 fence = two_pages + pagesize;
12465 }
12466 #endif
12467 if (fence)
12468 {
12469 if (memchr (fence, 0, 0))
12470 result |= 1;
12471 strcpy (fence - 9, "12345678");
12472 if (memchr (fence - 9, 0, 79) != fence - 1)
12473 result |= 2;
12474 if (memchr (fence - 1, 0, 3) != fence - 1)
12475 result |= 4;
12476 }
12477 return result;
12478
12479 ;
12480 return 0;
12481 }
12482 _ACEOF
12483 if ac_fn_c_try_run "$LINENO"; then :
12484 gl_cv_func_memchr_works=yes
12485 else
12486 gl_cv_func_memchr_works=no
12487 fi
12488 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12489 conftest.$ac_objext conftest.beam conftest.$ac_ext
12490 fi
12491
12492 fi
12493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memchr_works" >&5
12494 $as_echo "$gl_cv_func_memchr_works" >&6; }
12495 if test "$gl_cv_func_memchr_works" != yes; then
12496 REPLACE_MEMCHR=1
12497 fi
12498 fi
12499
12500
12501 ac_fn_c_check_decl "$LINENO" "memmem" "ac_cv_have_decl_memmem" "$ac_includes_default"
12502 if test "x$ac_cv_have_decl_memmem" = xyes; then :
12503 ac_have_decl=1
12504 else
12505 ac_have_decl=0
12506 fi
12507
12508 cat >>confdefs.h <<_ACEOF
12509 #define HAVE_DECL_MEMMEM $ac_have_decl
12510 _ACEOF
12511
12512
12513
12514
12515
12516
12517 for ac_func in memmem
12518 do :
12519 ac_fn_c_check_func "$LINENO" "memmem" "ac_cv_func_memmem"
12520 if test "x$ac_cv_func_memmem" = xyes; then :
12521 cat >>confdefs.h <<_ACEOF
12522 #define HAVE_MEMMEM 1
12523 _ACEOF
12524
12525 fi
12526 done
12527
12528 if test $ac_cv_func_memmem = yes; then
12529 HAVE_MEMMEM=1
12530 else
12531 HAVE_MEMMEM=0
12532 fi
12533
12534 :
12535
12536
12537
12538
12539
12540 if test $ac_cv_have_decl_memmem = no; then
12541 HAVE_DECL_MEMMEM=0
12542 else
12543 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memmem works" >&5
12544 $as_echo_n "checking whether memmem works... " >&6; }
12545 if ${gl_cv_func_memmem_works_always+:} false; then :
12546 $as_echo_n "(cached) " >&6
12547 else
12548 if test "$cross_compiling" = yes; then :
12549 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12550 /* end confdefs.h. */
12551
12552 #ifdef __GNU_LIBRARY__
12553 #include <features.h>
12554 #if ((__GLIBC__ == 2 && ((__GLIBC_MINOR > 0 && __GLIBC_MINOR__ < 9) \
12555 || __GLIBC_MINOR__ > 12)) \
12556 || (__GLIBC__ > 2)) \
12557 || defined __UCLIBC__
12558 Lucky user
12559 #endif
12560 #elif defined __CYGWIN__
12561 #include <cygwin/version.h>
12562 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
12563 Lucky user
12564 #endif
12565 #else
12566 Lucky user
12567 #endif
12568
12569 _ACEOF
12570 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12571 $EGREP "Lucky user" >/dev/null 2>&1; then :
12572 gl_cv_func_memmem_works_always="guessing yes"
12573 else
12574 gl_cv_func_memmem_works_always="guessing no"
12575 fi
12576 rm -f conftest*
12577
12578
12579 else
12580 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12581 /* end confdefs.h. */
12582
12583 #include <string.h> /* for memmem */
12584 #define P "_EF_BF_BD"
12585 #define HAYSTACK "F_BD_CE_BD" P P P P "_C3_88_20" P P P "_C3_A7_20" P
12586 #define NEEDLE P P P P P
12587
12588 int
12589 main ()
12590 {
12591
12592 int result = 0;
12593 if (memmem (HAYSTACK, strlen (HAYSTACK), NEEDLE, strlen (NEEDLE)))
12594 result |= 1;
12595 /* Check for empty needle behavior. */
12596 {
12597 const char *haystack = "AAA";
12598 if (memmem (haystack, 3, NULL, 0) != haystack)
12599 result |= 2;
12600 }
12601 return result;
12602
12603 ;
12604 return 0;
12605 }
12606 _ACEOF
12607 if ac_fn_c_try_run "$LINENO"; then :
12608 gl_cv_func_memmem_works_always=yes
12609 else
12610 gl_cv_func_memmem_works_always=no
12611 fi
12612 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12613 conftest.$ac_objext conftest.beam conftest.$ac_ext
12614 fi
12615
12616
12617 fi
12618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memmem_works_always" >&5
12619 $as_echo "$gl_cv_func_memmem_works_always" >&6; }
12620 case "$gl_cv_func_memmem_works_always" in
12621 *yes) ;;
12622 *)
12623 REPLACE_MEMMEM=1
12624 ;;
12625 esac
12626 fi
12627 :
12628
12629
12630 ac_fn_c_check_decl "$LINENO" "memrchr" "ac_cv_have_decl_memrchr" "$ac_includes_default"
12631 if test "x$ac_cv_have_decl_memrchr" = xyes; then :
12632 ac_have_decl=1
12633 else
12634 ac_have_decl=0
12635 fi
12636
12637 cat >>confdefs.h <<_ACEOF
12638 #define HAVE_DECL_MEMRCHR $ac_have_decl
12639 _ACEOF
12640
12641
12642
12643
12644
12645
12646
12647
12648
12649
12650
12651
12652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for promoted mode_t type" >&5
12653 $as_echo_n "checking for promoted mode_t type... " >&6; }
12654 if ${gl_cv_promoted_mode_t+:} false; then :
12655 $as_echo_n "(cached) " >&6
12656 else
12657
12658 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12659 /* end confdefs.h. */
12660 #include <sys/types.h>
12661 int
12662 main ()
12663 {
12664 typedef int array[2 * (sizeof (mode_t) < sizeof (int)) - 1];
12665 ;
12666 return 0;
12667 }
12668 _ACEOF
12669 if ac_fn_c_try_compile "$LINENO"; then :
12670 gl_cv_promoted_mode_t='int'
12671 else
12672 gl_cv_promoted_mode_t='mode_t'
12673 fi
12674 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12675
12676 fi
12677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_promoted_mode_t" >&5
12678 $as_echo "$gl_cv_promoted_mode_t" >&6; }
12679
12680 cat >>confdefs.h <<_ACEOF
12681 #define PROMOTED_MODE_T $gl_cv_promoted_mode_t
12682 _ACEOF
12683
12684
12685
12686
12687
12688
12689
12690
12691 GNULIB_DPRINTF=0;
12692 GNULIB_FCLOSE=0;
12693 GNULIB_FDOPEN=0;
12694 GNULIB_FFLUSH=0;
12695 GNULIB_FGETC=0;
12696 GNULIB_FGETS=0;
12697 GNULIB_FOPEN=0;
12698 GNULIB_FPRINTF=0;
12699 GNULIB_FPRINTF_POSIX=0;
12700 GNULIB_FPURGE=0;
12701 GNULIB_FPUTC=0;
12702 GNULIB_FPUTS=0;
12703 GNULIB_FREAD=0;
12704 GNULIB_FREOPEN=0;
12705 GNULIB_FSCANF=0;
12706 GNULIB_FSEEK=0;
12707 GNULIB_FSEEKO=0;
12708 GNULIB_FTELL=0;
12709 GNULIB_FTELLO=0;
12710 GNULIB_FWRITE=0;
12711 GNULIB_GETC=0;
12712 GNULIB_GETCHAR=0;
12713 GNULIB_GETDELIM=0;
12714 GNULIB_GETLINE=0;
12715 GNULIB_OBSTACK_PRINTF=0;
12716 GNULIB_OBSTACK_PRINTF_POSIX=0;
12717 GNULIB_PCLOSE=0;
12718 GNULIB_PERROR=0;
12719 GNULIB_POPEN=0;
12720 GNULIB_PRINTF=0;
12721 GNULIB_PRINTF_POSIX=0;
12722 GNULIB_PUTC=0;
12723 GNULIB_PUTCHAR=0;
12724 GNULIB_PUTS=0;
12725 GNULIB_REMOVE=0;
12726 GNULIB_RENAME=0;
12727 GNULIB_RENAMEAT=0;
12728 GNULIB_SCANF=0;
12729 GNULIB_SNPRINTF=0;
12730 GNULIB_SPRINTF_POSIX=0;
12731 GNULIB_STDIO_H_NONBLOCKING=0;
12732 GNULIB_STDIO_H_SIGPIPE=0;
12733 GNULIB_TMPFILE=0;
12734 GNULIB_VASPRINTF=0;
12735 GNULIB_VFSCANF=0;
12736 GNULIB_VSCANF=0;
12737 GNULIB_VDPRINTF=0;
12738 GNULIB_VFPRINTF=0;
12739 GNULIB_VFPRINTF_POSIX=0;
12740 GNULIB_VPRINTF=0;
12741 GNULIB_VPRINTF_POSIX=0;
12742 GNULIB_VSNPRINTF=0;
12743 GNULIB_VSPRINTF_POSIX=0;
12744 HAVE_DECL_FPURGE=1;
12745 HAVE_DECL_FSEEKO=1;
12746 HAVE_DECL_FTELLO=1;
12747 HAVE_DECL_GETDELIM=1;
12748 HAVE_DECL_GETLINE=1;
12749 HAVE_DECL_OBSTACK_PRINTF=1;
12750 HAVE_DECL_SNPRINTF=1;
12751 HAVE_DECL_VSNPRINTF=1;
12752 HAVE_DPRINTF=1;
12753 HAVE_FSEEKO=1;
12754 HAVE_FTELLO=1;
12755 HAVE_PCLOSE=1;
12756 HAVE_POPEN=1;
12757 HAVE_RENAMEAT=1;
12758 HAVE_VASPRINTF=1;
12759 HAVE_VDPRINTF=1;
12760 REPLACE_DPRINTF=0;
12761 REPLACE_FCLOSE=0;
12762 REPLACE_FDOPEN=0;
12763 REPLACE_FFLUSH=0;
12764 REPLACE_FOPEN=0;
12765 REPLACE_FPRINTF=0;
12766 REPLACE_FPURGE=0;
12767 REPLACE_FREOPEN=0;
12768 REPLACE_FSEEK=0;
12769 REPLACE_FSEEKO=0;
12770 REPLACE_FTELL=0;
12771 REPLACE_FTELLO=0;
12772 REPLACE_GETDELIM=0;
12773 REPLACE_GETLINE=0;
12774 REPLACE_OBSTACK_PRINTF=0;
12775 REPLACE_PERROR=0;
12776 REPLACE_POPEN=0;
12777 REPLACE_PRINTF=0;
12778 REPLACE_REMOVE=0;
12779 REPLACE_RENAME=0;
12780 REPLACE_RENAMEAT=0;
12781 REPLACE_SNPRINTF=0;
12782 REPLACE_SPRINTF=0;
12783 REPLACE_STDIO_READ_FUNCS=0;
12784 REPLACE_STDIO_WRITE_FUNCS=0;
12785 REPLACE_TMPFILE=0;
12786 REPLACE_VASPRINTF=0;
12787 REPLACE_VDPRINTF=0;
12788 REPLACE_VFPRINTF=0;
12789 REPLACE_VPRINTF=0;
12790 REPLACE_VSNPRINTF=0;
12791 REPLACE_VSPRINTF=0;
12792
12793
12794
12795
12796
12797
12798
12799
12800
12801
12802
12803
12804
12805
12806
12807
12808
12809
12810
12811
12812
12813
12814
12815
12816
12817
12818
12819
12820
12821
12822
12823
12824 ac_fn_c_check_decl "$LINENO" "setenv" "ac_cv_have_decl_setenv" "$ac_includes_default"
12825 if test "x$ac_cv_have_decl_setenv" = xyes; then :
12826 ac_have_decl=1
12827 else
12828 ac_have_decl=0
12829 fi
12830
12831 cat >>confdefs.h <<_ACEOF
12832 #define HAVE_DECL_SETENV $ac_have_decl
12833 _ACEOF
12834
12835
12836
12837
12838
12839
12840
12841
12842
12843
12844 :
12845
12846
12847
12848
12849
12850 if test $ac_cv_have_decl_setenv = no; then
12851 HAVE_DECL_SETENV=0
12852 fi
12853
12854 :
12855
12856
12857
12858
12859
12860
12861
12862
12863
12864 :
12865
12866
12867
12868
12869
12870 for ac_header in search.h
12871 do :
12872 ac_fn_c_check_header_mongrel "$LINENO" "search.h" "ac_cv_header_search_h" "$ac_includes_default"
12873 if test "x$ac_cv_header_search_h" = xyes; then :
12874 cat >>confdefs.h <<_ACEOF
12875 #define HAVE_SEARCH_H 1
12876 _ACEOF
12877
12878 fi
12879
12880 done
12881
12882 for ac_func in tsearch
12883 do :
12884 ac_fn_c_check_func "$LINENO" "tsearch" "ac_cv_func_tsearch"
12885 if test "x$ac_cv_func_tsearch" = xyes; then :
12886 cat >>confdefs.h <<_ACEOF
12887 #define HAVE_TSEARCH 1
12888 _ACEOF
12889
12890 fi
12891 done
12892
12893
12894
12895
12896 GNULIB_PTHREAD_SIGMASK=0;
12897 GNULIB_RAISE=0;
12898 GNULIB_SIGNAL_H_SIGPIPE=0;
12899 GNULIB_SIGPROCMASK=0;
12900 GNULIB_SIGACTION=0;
12901 HAVE_POSIX_SIGNALBLOCKING=1;
12902 HAVE_PTHREAD_SIGMASK=1;
12903 HAVE_RAISE=1;
12904 HAVE_SIGSET_T=1;
12905 HAVE_SIGINFO_T=1;
12906 HAVE_SIGACTION=1;
12907 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
12908
12909 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
12910
12911 HAVE_SIGHANDLER_T=1;
12912 REPLACE_PTHREAD_SIGMASK=0;
12913 REPLACE_RAISE=0;
12914
12915
12916 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
12917 #include <signal.h>
12918 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
12919 #include <sys/types.h>
12920
12921 "
12922 if test "x$ac_cv_type_sigset_t" = xyes; then :
12923
12924 cat >>confdefs.h <<_ACEOF
12925 #define HAVE_SIGSET_T 1
12926 _ACEOF
12927
12928 gl_cv_type_sigset_t=yes
12929 else
12930 gl_cv_type_sigset_t=no
12931 fi
12932
12933 if test $gl_cv_type_sigset_t != yes; then
12934 HAVE_SIGSET_T=0
12935 fi
12936
12937 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
12938 $as_echo_n "checking for uid_t in sys/types.h... " >&6; }
12939 if ${ac_cv_type_uid_t+:} false; then :
12940 $as_echo_n "(cached) " >&6
12941 else
12942 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12943 /* end confdefs.h. */
12944 #include <sys/types.h>
12945
12946 _ACEOF
12947 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12948 $EGREP "uid_t" >/dev/null 2>&1; then :
12949 ac_cv_type_uid_t=yes
12950 else
12951 ac_cv_type_uid_t=no
12952 fi
12953 rm -f conftest*
12954
12955 fi
12956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
12957 $as_echo "$ac_cv_type_uid_t" >&6; }
12958 if test $ac_cv_type_uid_t = no; then
12959
12960 $as_echo "#define uid_t int" >>confdefs.h
12961
12962
12963 $as_echo "#define gid_t int" >>confdefs.h
12964
12965 fi
12966
12967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
12968 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
12969 if ${ac_cv_header_stdbool_h+:} false; then :
12970 $as_echo_n "(cached) " >&6
12971 else
12972 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12973 /* end confdefs.h. */
12974
12975 #include <stdbool.h>
12976
12977 #ifdef __cplusplus
12978 typedef bool Bool;
12979 #else
12980 typedef _Bool Bool;
12981 #ifndef bool
12982 "error: bool is not defined"
12983 #endif
12984 #ifndef false
12985 "error: false is not defined"
12986 #endif
12987 #if false
12988 "error: false is not 0"
12989 #endif
12990 #ifndef true
12991 "error: true is not defined"
12992 #endif
12993 #if true != 1
12994 "error: true is not 1"
12995 #endif
12996 #endif
12997
12998 #ifndef __bool_true_false_are_defined
12999 "error: __bool_true_false_are_defined is not defined"
13000 #endif
13001
13002 struct s { Bool s: 1; Bool t; bool u: 1; bool v; } s;
13003
13004 char a[true == 1 ? 1 : -1];
13005 char b[false == 0 ? 1 : -1];
13006 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
13007 char d[(bool) 0.5 == true ? 1 : -1];
13008 /* See body of main program for 'e'. */
13009 char f[(Bool) 0.0 == false ? 1 : -1];
13010 char g[true];
13011 char h[sizeof (Bool)];
13012 char i[sizeof s.t];
13013 enum { j = false, k = true, l = false * true, m = true * 256 };
13014 /* The following fails for
13015 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
13016 Bool n[m];
13017 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
13018 char p[-1 - (Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
13019 /* Catch a bug in an HP-UX C compiler. See
13020 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
13021 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
13022 */
13023 Bool q = true;
13024 Bool *pq = &q;
13025 bool *qq = &q;
13026
13027 int
13028 main ()
13029 {
13030
13031 bool e = &s;
13032 *pq |= q; *pq |= ! q;
13033 *qq |= q; *qq |= ! q;
13034 /* Refer to every declared value, to avoid compiler optimizations. */
13035 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
13036 + !m + !n + !o + !p + !q + !pq + !qq);
13037
13038 ;
13039 return 0;
13040 }
13041 _ACEOF
13042 if ac_fn_c_try_compile "$LINENO"; then :
13043 ac_cv_header_stdbool_h=yes
13044 else
13045 ac_cv_header_stdbool_h=no
13046 fi
13047 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13048 fi
13049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
13050 $as_echo "$ac_cv_header_stdbool_h" >&6; }
13051 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
13052 if test "x$ac_cv_type__Bool" = xyes; then :
13053
13054 cat >>confdefs.h <<_ACEOF
13055 #define HAVE__BOOL 1
13056 _ACEOF
13057
13058
13059 fi
13060
13061
13062
13063 REPLACE_NULL=0;
13064 HAVE_MAX_ALIGN_T=1;
13065 HAVE_WCHAR_T=1;
13066
13067
13068 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
13069 $as_echo_n "checking for wchar_t... " >&6; }
13070 if ${gt_cv_c_wchar_t+:} false; then :
13071 $as_echo_n "(cached) " >&6
13072 else
13073 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13074 /* end confdefs.h. */
13075 #include <stddef.h>
13076 wchar_t foo = (wchar_t)'\0';
13077 int
13078 main ()
13079 {
13080
13081 ;
13082 return 0;
13083 }
13084 _ACEOF
13085 if ac_fn_c_try_compile "$LINENO"; then :
13086 gt_cv_c_wchar_t=yes
13087 else
13088 gt_cv_c_wchar_t=no
13089 fi
13090 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13091 fi
13092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
13093 $as_echo "$gt_cv_c_wchar_t" >&6; }
13094 if test $gt_cv_c_wchar_t = yes; then
13095
13096 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
13097
13098 fi
13099
13100
13101
13102
13103
13104
13105
13106 ac_fn_c_check_decl "$LINENO" "strdup" "ac_cv_have_decl_strdup" "$ac_includes_default"
13107 if test "x$ac_cv_have_decl_strdup" = xyes; then :
13108 ac_have_decl=1
13109 else
13110 ac_have_decl=0
13111 fi
13112
13113 cat >>confdefs.h <<_ACEOF
13114 #define HAVE_DECL_STRDUP $ac_have_decl
13115 _ACEOF
13116
13117
13118
13119 REPLACE_STRERROR_0=0
13120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror(0) succeeds" >&5
13121 $as_echo_n "checking whether strerror(0) succeeds... " >&6; }
13122 if ${gl_cv_func_strerror_0_works+:} false; then :
13123 $as_echo_n "(cached) " >&6
13124 else
13125 if test "$cross_compiling" = yes; then :
13126 case "$host_os" in
13127 # Guess yes on glibc systems.
13128 *-gnu*) gl_cv_func_strerror_0_works="guessing yes" ;;
13129 # If we don't know, assume the worst.
13130 *) gl_cv_func_strerror_0_works="guessing no" ;;
13131 esac
13132
13133 else
13134 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13135 /* end confdefs.h. */
13136 #include <string.h>
13137 #include <errno.h>
13138
13139 int
13140 main ()
13141 {
13142 int result = 0;
13143 char *str;
13144 errno = 0;
13145 str = strerror (0);
13146 if (!*str) result |= 1;
13147 if (errno) result |= 2;
13148 if (strstr (str, "nknown") || strstr (str, "ndefined"))
13149 result |= 4;
13150 return result;
13151 ;
13152 return 0;
13153 }
13154 _ACEOF
13155 if ac_fn_c_try_run "$LINENO"; then :
13156 gl_cv_func_strerror_0_works=yes
13157 else
13158 gl_cv_func_strerror_0_works=no
13159 fi
13160 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13161 conftest.$ac_objext conftest.beam conftest.$ac_ext
13162 fi
13163
13164
13165 fi
13166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strerror_0_works" >&5
13167 $as_echo "$gl_cv_func_strerror_0_works" >&6; }
13168 case "$gl_cv_func_strerror_0_works" in
13169 *yes) ;;
13170 *)
13171 REPLACE_STRERROR_0=1
13172
13173 $as_echo "#define REPLACE_STRERROR_0 1" >>confdefs.h
13174
13175 ;;
13176 esac
13177
13178
13179
13180
13181
13182
13183
13184
13185
13186
13187
13188
13189 if test $gl_cv_have_include_next = yes; then
13190 gl_cv_next_string_h='<'string.h'>'
13191 else
13192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <string.h>" >&5
13193 $as_echo_n "checking absolute name of <string.h>... " >&6; }
13194 if ${gl_cv_next_string_h+:} false; then :
13195 $as_echo_n "(cached) " >&6
13196 else
13197
13198
13199
13200 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13201 /* end confdefs.h. */
13202 #include <string.h>
13203 _ACEOF
13204 case "$host_os" in
13205 aix*) gl_absname_cpp="$ac_cpp -C" ;;
13206 *) gl_absname_cpp="$ac_cpp" ;;
13207 esac
13208
13209 case "$host_os" in
13210 mingw*)
13211 gl_dirsep_regex='[/\\]'
13212 ;;
13213 *)
13214 gl_dirsep_regex='\/'
13215 ;;
13216 esac
13217 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
13218 gl_header_literal_regex=`echo 'string.h' \
13219 | sed -e "$gl_make_literal_regex_sed"`
13220 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
13221 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
13222 s|^/[^/]|//&|
13223 p
13224 q
13225 }'
13226
13227 gl_cv_absolute_string_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
13228 sed -n "$gl_absolute_header_sed"`
13229
13230 gl_header=$gl_cv_absolute_string_h
13231 gl_cv_next_string_h='"'$gl_header'"'
13232
13233
13234 fi
13235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_string_h" >&5
13236 $as_echo "$gl_cv_next_string_h" >&6; }
13237 fi
13238 NEXT_STRING_H=$gl_cv_next_string_h
13239
13240 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
13241 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
13242 gl_next_as_first_directive='<'string.h'>'
13243 else
13244 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
13245 gl_next_as_first_directive=$gl_cv_next_string_h
13246 fi
13247 NEXT_AS_FIRST_DIRECTIVE_STRING_H=$gl_next_as_first_directive
13248
13249
13250
13251
13252
13253
13254 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
13255 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
13256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
13257 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
13258 if eval \${$as_gl_Symbol+:} false; then :
13259 $as_echo_n "(cached) " >&6
13260 else
13261 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13262 /* end confdefs.h. */
13263 #include <string.h>
13264
13265 int
13266 main ()
13267 {
13268 #undef $gl_func
13269 (void) $gl_func;
13270 ;
13271 return 0;
13272 }
13273 _ACEOF
13274 if ac_fn_c_try_compile "$LINENO"; then :
13275 eval "$as_gl_Symbol=yes"
13276 else
13277 eval "$as_gl_Symbol=no"
13278 fi
13279 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13280 fi
13281 eval ac_res=\$$as_gl_Symbol
13282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
13283 $as_echo "$ac_res" >&6; }
13284 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
13285 cat >>confdefs.h <<_ACEOF
13286 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
13287 _ACEOF
13288
13289 eval ac_cv_have_decl_$gl_func=yes
13290 fi
13291 done
13292
13293
13294
13295
13296
13297 if test "$gl_cv_func_memchr_works" != yes; then
13298 REPLACE_STRSTR=1
13299 else
13300 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strstr works" >&5
13301 $as_echo_n "checking whether strstr works... " >&6; }
13302 if ${gl_cv_func_strstr_works_always+:} false; then :
13303 $as_echo_n "(cached) " >&6
13304 else
13305 if test "$cross_compiling" = yes; then :
13306 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13307 /* end confdefs.h. */
13308
13309 #ifdef __GNU_LIBRARY__
13310 #include <features.h>
13311 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ > 12) || (__GLIBC__ > 2)) \
13312 || defined __UCLIBC__
13313 Lucky user
13314 #endif
13315 #elif defined __CYGWIN__
13316 #include <cygwin/version.h>
13317 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
13318 Lucky user
13319 #endif
13320 #else
13321 Lucky user
13322 #endif
13323
13324 _ACEOF
13325 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13326 $EGREP "Lucky user" >/dev/null 2>&1; then :
13327 gl_cv_func_strstr_works_always="guessing yes"
13328 else
13329 gl_cv_func_strstr_works_always="guessing no"
13330 fi
13331 rm -f conftest*
13332
13333
13334 else
13335 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13336 /* end confdefs.h. */
13337
13338 #include <string.h> /* for strstr */
13339 #define P "_EF_BF_BD"
13340 #define HAYSTACK "F_BD_CE_BD" P P P P "_C3_88_20" P P P "_C3_A7_20" P
13341 #define NEEDLE P P P P P
13342
13343 int
13344 main ()
13345 {
13346 return !!strstr (HAYSTACK, NEEDLE);
13347
13348 ;
13349 return 0;
13350 }
13351 _ACEOF
13352 if ac_fn_c_try_run "$LINENO"; then :
13353 gl_cv_func_strstr_works_always=yes
13354 else
13355 gl_cv_func_strstr_works_always=no
13356 fi
13357 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13358 conftest.$ac_objext conftest.beam conftest.$ac_ext
13359 fi
13360
13361
13362 fi
13363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strstr_works_always" >&5
13364 $as_echo "$gl_cv_func_strstr_works_always" >&6; }
13365 case "$gl_cv_func_strstr_works_always" in
13366 *yes) ;;
13367 *)
13368 REPLACE_STRSTR=1
13369 ;;
13370 esac
13371 fi
13372
13373
13374 ac_fn_c_check_decl "$LINENO" "strtok_r" "ac_cv_have_decl_strtok_r" "$ac_includes_default"
13375 if test "x$ac_cv_have_decl_strtok_r" = xyes; then :
13376 ac_have_decl=1
13377 else
13378 ac_have_decl=0
13379 fi
13380
13381 cat >>confdefs.h <<_ACEOF
13382 #define HAVE_DECL_STRTOK_R $ac_have_decl
13383 _ACEOF
13384
13385
13386 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
13387 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
13388 if test -z "$MKDIR_P"; then
13389 if ${ac_cv_path_mkdir+:} false; then :
13390 $as_echo_n "(cached) " >&6
13391 else
13392 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13393 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
13394 do
13395 IFS=$as_save_IFS
13396 test -z "$as_dir" && as_dir=.
13397 for ac_prog in mkdir gmkdir; do
13398 for ac_exec_ext in '' $ac_executable_extensions; do
13399 as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
13400 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
13401 'mkdir (GNU coreutils) '* | \
13402 'mkdir (coreutils) '* | \
13403 'mkdir (fileutils) '4.1*)
13404 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
13405 break 3;;
13406 esac
13407 done
13408 done
13409 done
13410 IFS=$as_save_IFS
13411
13412 fi
13413
13414 test -d ./--version && rmdir ./--version
13415 if test "${ac_cv_path_mkdir+set}" = set; then
13416 MKDIR_P="$ac_cv_path_mkdir -p"
13417 else
13418 # As a last resort, use the slow shell script. Don't cache a
13419 # value for MKDIR_P within a source directory, because that will
13420 # break other packages using the cache if that directory is
13421 # removed, or if the value is a relative name.
13422 MKDIR_P="$ac_install_sh -d"
13423 fi
13424 fi
13425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
13426 $as_echo "$MKDIR_P" >&6; }
13427
13428
13429
13430
13431
13432
13433
13434
13435
13436
13437
13438
13439
13440
13441
13442
13443
13444
13445
13446 if test $gl_cv_have_include_next = yes; then
13447 gl_cv_next_sys_types_h='<'sys/types.h'>'
13448 else
13449 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/types.h>" >&5
13450 $as_echo_n "checking absolute name of <sys/types.h>... " >&6; }
13451 if ${gl_cv_next_sys_types_h+:} false; then :
13452 $as_echo_n "(cached) " >&6
13453 else
13454
13455
13456
13457 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13458 /* end confdefs.h. */
13459 #include <sys/types.h>
13460 _ACEOF
13461 case "$host_os" in
13462 aix*) gl_absname_cpp="$ac_cpp -C" ;;
13463 *) gl_absname_cpp="$ac_cpp" ;;
13464 esac
13465
13466 case "$host_os" in
13467 mingw*)
13468 gl_dirsep_regex='[/\\]'
13469 ;;
13470 *)
13471 gl_dirsep_regex='\/'
13472 ;;
13473 esac
13474 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
13475 gl_header_literal_regex=`echo 'sys/types.h' \
13476 | sed -e "$gl_make_literal_regex_sed"`
13477 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
13478 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
13479 s|^/[^/]|//&|
13480 p
13481 q
13482 }'
13483
13484 gl_cv_absolute_sys_types_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
13485 sed -n "$gl_absolute_header_sed"`
13486
13487 gl_header=$gl_cv_absolute_sys_types_h
13488 gl_cv_next_sys_types_h='"'$gl_header'"'
13489
13490
13491 fi
13492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_types_h" >&5
13493 $as_echo "$gl_cv_next_sys_types_h" >&6; }
13494 fi
13495 NEXT_SYS_TYPES_H=$gl_cv_next_sys_types_h
13496
13497 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
13498 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
13499 gl_next_as_first_directive='<'sys/types.h'>'
13500 else
13501 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
13502 gl_next_as_first_directive=$gl_cv_next_sys_types_h
13503 fi
13504 NEXT_AS_FIRST_DIRECTIVE_SYS_TYPES_H=$gl_next_as_first_directive
13505
13506
13507
13508
13509
13510
13511
13512
13513
13514
13515
13516
13517 GNULIB_MKTIME=0;
13518 GNULIB_NANOSLEEP=0;
13519 GNULIB_STRPTIME=0;
13520 GNULIB_TIMEGM=0;
13521 GNULIB_TIME_R=0;
13522 GNULIB_TIME_RZ=0;
13523 HAVE_DECL_LOCALTIME_R=1;
13524 HAVE_NANOSLEEP=1;
13525 HAVE_STRPTIME=1;
13526 HAVE_TIMEGM=1;
13527 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
13528 REPLACE_MKTIME=GNULIB_PORTCHECK;
13529 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
13530 REPLACE_TIMEGM=GNULIB_PORTCHECK;
13531
13532 : ${GNULIB_GETTIMEOFDAY=0};
13533 REPLACE_GMTIME=0;
13534 REPLACE_LOCALTIME=0;
13535
13536
13537
13538 :
13539
13540
13541
13542
13543
13544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
13545 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
13546 if ${gl_cv_sys_struct_timespec_in_time_h+:} false; then :
13547 $as_echo_n "(cached) " >&6
13548 else
13549 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13550 /* end confdefs.h. */
13551 #include <time.h>
13552
13553 int
13554 main ()
13555 {
13556 static struct timespec x; x.tv_sec = x.tv_nsec;
13557 ;
13558 return 0;
13559 }
13560 _ACEOF
13561 if ac_fn_c_try_compile "$LINENO"; then :
13562 gl_cv_sys_struct_timespec_in_time_h=yes
13563 else
13564 gl_cv_sys_struct_timespec_in_time_h=no
13565 fi
13566 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13567 fi
13568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
13569 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
13570
13571 TIME_H_DEFINES_STRUCT_TIMESPEC=0
13572 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
13573 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
13574 UNISTD_H_DEFINES_STRUCT_TIMESPEC=0
13575 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
13576 TIME_H_DEFINES_STRUCT_TIMESPEC=1
13577 else
13578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
13579 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
13580 if ${gl_cv_sys_struct_timespec_in_sys_time_h+:} false; then :
13581 $as_echo_n "(cached) " >&6
13582 else
13583 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13584 /* end confdefs.h. */
13585 #include <sys/time.h>
13586
13587 int
13588 main ()
13589 {
13590 static struct timespec x; x.tv_sec = x.tv_nsec;
13591 ;
13592 return 0;
13593 }
13594 _ACEOF
13595 if ac_fn_c_try_compile "$LINENO"; then :
13596 gl_cv_sys_struct_timespec_in_sys_time_h=yes
13597 else
13598 gl_cv_sys_struct_timespec_in_sys_time_h=no
13599 fi
13600 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13601 fi
13602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
13603 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
13604 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
13605 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
13606 else
13607 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
13608 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
13609 if ${gl_cv_sys_struct_timespec_in_pthread_h+:} false; then :
13610 $as_echo_n "(cached) " >&6
13611 else
13612 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13613 /* end confdefs.h. */
13614 #include <pthread.h>
13615
13616 int
13617 main ()
13618 {
13619 static struct timespec x; x.tv_sec = x.tv_nsec;
13620 ;
13621 return 0;
13622 }
13623 _ACEOF
13624 if ac_fn_c_try_compile "$LINENO"; then :
13625 gl_cv_sys_struct_timespec_in_pthread_h=yes
13626 else
13627 gl_cv_sys_struct_timespec_in_pthread_h=no
13628 fi
13629 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13630 fi
13631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
13632 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
13633 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
13634 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
13635 else
13636 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <unistd.h>" >&5
13637 $as_echo_n "checking for struct timespec in <unistd.h>... " >&6; }
13638 if ${gl_cv_sys_struct_timespec_in_unistd_h+:} false; then :
13639 $as_echo_n "(cached) " >&6
13640 else
13641 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13642 /* end confdefs.h. */
13643 #include <unistd.h>
13644
13645 int
13646 main ()
13647 {
13648 static struct timespec x; x.tv_sec = x.tv_nsec;
13649 ;
13650 return 0;
13651 }
13652 _ACEOF
13653 if ac_fn_c_try_compile "$LINENO"; then :
13654 gl_cv_sys_struct_timespec_in_unistd_h=yes
13655 else
13656 gl_cv_sys_struct_timespec_in_unistd_h=no
13657 fi
13658 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13659 fi
13660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_unistd_h" >&5
13661 $as_echo "$gl_cv_sys_struct_timespec_in_unistd_h" >&6; }
13662 if test $gl_cv_sys_struct_timespec_in_unistd_h = yes; then
13663 UNISTD_H_DEFINES_STRUCT_TIMESPEC=1
13664 fi
13665 fi
13666 fi
13667 fi
13668
13669
13670
13671
13672
13673
13674
13675
13676
13677
13678
13679
13680
13681
13682
13683
13684 if test $gl_cv_have_include_next = yes; then
13685 gl_cv_next_time_h='<'time.h'>'
13686 else
13687 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
13688 $as_echo_n "checking absolute name of <time.h>... " >&6; }
13689 if ${gl_cv_next_time_h+:} false; then :
13690 $as_echo_n "(cached) " >&6
13691 else
13692
13693
13694
13695 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13696 /* end confdefs.h. */
13697 #include <time.h>
13698 _ACEOF
13699 case "$host_os" in
13700 aix*) gl_absname_cpp="$ac_cpp -C" ;;
13701 *) gl_absname_cpp="$ac_cpp" ;;
13702 esac
13703
13704 case "$host_os" in
13705 mingw*)
13706 gl_dirsep_regex='[/\\]'
13707 ;;
13708 *)
13709 gl_dirsep_regex='\/'
13710 ;;
13711 esac
13712 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
13713 gl_header_literal_regex=`echo 'time.h' \
13714 | sed -e "$gl_make_literal_regex_sed"`
13715 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
13716 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
13717 s|^/[^/]|//&|
13718 p
13719 q
13720 }'
13721
13722 gl_cv_absolute_time_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
13723 sed -n "$gl_absolute_header_sed"`
13724
13725 gl_header=$gl_cv_absolute_time_h
13726 gl_cv_next_time_h='"'$gl_header'"'
13727
13728
13729 fi
13730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
13731 $as_echo "$gl_cv_next_time_h" >&6; }
13732 fi
13733 NEXT_TIME_H=$gl_cv_next_time_h
13734
13735 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
13736 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
13737 gl_next_as_first_directive='<'time.h'>'
13738 else
13739 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
13740 gl_next_as_first_directive=$gl_cv_next_time_h
13741 fi
13742 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
13743
13744
13745
13746
13747
13748
13749
13750
13751
13752
13753
13754
13755 ac_fn_c_check_decl "$LINENO" "unsetenv" "ac_cv_have_decl_unsetenv" "$ac_includes_default"
13756 if test "x$ac_cv_have_decl_unsetenv" = xyes; then :
13757 ac_have_decl=1
13758 else
13759 ac_have_decl=0
13760 fi
13761
13762 cat >>confdefs.h <<_ACEOF
13763 #define HAVE_DECL_UNSETENV $ac_have_decl
13764 _ACEOF
13765
13766
13767
13768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <wchar.h> uses 'inline' correctly" >&5
13769 $as_echo_n "checking whether <wchar.h> uses 'inline' correctly... " >&6; }
13770 if ${gl_cv_header_wchar_h_correct_inline+:} false; then :
13771 $as_echo_n "(cached) " >&6
13772 else
13773 gl_cv_header_wchar_h_correct_inline=yes
13774 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13775 /* end confdefs.h. */
13776
13777 #define wcstod renamed_wcstod
13778 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
13779 <wchar.h>.
13780 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
13781 included before <wchar.h>. */
13782 #include <stddef.h>
13783 #include <stdio.h>
13784 #include <time.h>
13785 #include <wchar.h>
13786 extern int zero (void);
13787 int main () { return zero(); }
13788
13789 _ACEOF
13790 save_ac_compile="$ac_compile"
13791 ac_compile=`echo "$save_ac_compile" | sed s/conftest/conftest1/`
13792 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
13793 (eval $ac_compile) 2>&5
13794 ac_status=$?
13795 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
13796 test $ac_status = 0; }; then
13797 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13798 /* end confdefs.h. */
13799
13800 #define wcstod renamed_wcstod
13801 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
13802 <wchar.h>.
13803 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
13804 included before <wchar.h>. */
13805 #include <stddef.h>
13806 #include <stdio.h>
13807 #include <time.h>
13808 #include <wchar.h>
13809 int zero (void) { return 0; }
13810
13811 _ACEOF
13812 ac_compile=`echo "$save_ac_compile" | sed s/conftest/conftest2/`
13813 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
13814 (eval $ac_compile) 2>&5
13815 ac_status=$?
13816 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
13817 test $ac_status = 0; }; then
13818 if $CC -o conftest$ac_exeext $CFLAGS $LDFLAGS conftest1.$ac_objext conftest2.$ac_objext $LIBS >&5 2>&1; then
13819 :
13820 else
13821 gl_cv_header_wchar_h_correct_inline=no
13822 fi
13823 fi
13824 fi
13825 ac_compile="$save_ac_compile"
13826 rm -f conftest1.$ac_objext conftest2.$ac_objext conftest$ac_exeext
13827
13828 fi
13829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_wchar_h_correct_inline" >&5
13830 $as_echo "$gl_cv_header_wchar_h_correct_inline" >&6; }
13831 if test $gl_cv_header_wchar_h_correct_inline = no; then
13832 as_fn_error $? "<wchar.h> cannot be used with this compiler ($CC $CFLAGS $CPPFLAGS).
13833 This is a known interoperability problem of glibc <= 2.5 with gcc >= 4.3 in
13834 C99 mode. You have four options:
13835 - Add the flag -fgnu89-inline to CC and reconfigure, or
13836 - Fix your include files, using parts of
13837 <http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=b037a293a48718af30d706c2e18c929d0e69a621>, or
13838 - Use a gcc version older than 4.3, or
13839 - Don't use the flags -std=c99 or -std=gnu99.
13840 Configuration aborted." "$LINENO" 5
13841 fi
13842
13843
13844
13845
13846
13847
13848
13849
13850 :
13851
13852
13853
13854
13855
13856 if test $ac_cv_header_features_h = yes; then
13857 HAVE_FEATURES_H=1
13858 else
13859 HAVE_FEATURES_H=0
13860 fi
13861
13862
13863
13864 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wint_t" >&5
13865 $as_echo_n "checking for wint_t... " >&6; }
13866 if ${gt_cv_c_wint_t+:} false; then :
13867 $as_echo_n "(cached) " >&6
13868 else
13869 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13870 /* end confdefs.h. */
13871
13872 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
13873 <wchar.h>.
13874 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
13875 before <wchar.h>. */
13876 #include <stddef.h>
13877 #include <stdio.h>
13878 #include <time.h>
13879 #include <wchar.h>
13880 wint_t foo = (wchar_t)'\0';
13881 int
13882 main ()
13883 {
13884
13885 ;
13886 return 0;
13887 }
13888 _ACEOF
13889 if ac_fn_c_try_compile "$LINENO"; then :
13890 gt_cv_c_wint_t=yes
13891 else
13892 gt_cv_c_wint_t=no
13893 fi
13894 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13895 fi
13896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wint_t" >&5
13897 $as_echo "$gt_cv_c_wint_t" >&6; }
13898 if test $gt_cv_c_wint_t = yes; then
13899
13900 $as_echo "#define HAVE_WINT_T 1" >>confdefs.h
13901
13902 fi
13903
13904
13905 GNULIB_ISWBLANK=0;
13906 GNULIB_WCTYPE=0;
13907 GNULIB_ISWCTYPE=0;
13908 GNULIB_WCTRANS=0;
13909 GNULIB_TOWCTRANS=0;
13910 HAVE_ISWBLANK=1;
13911 HAVE_WCTYPE_T=1;
13912 HAVE_WCTRANS_T=1;
13913 REPLACE_ISWBLANK=0;
13914
13915
13916
13917
13918
13919
13920
13921 if false; then
13922 GL_COND_LIBTOOL_TRUE=
13923 GL_COND_LIBTOOL_FALSE='#'
13924 else
13925 GL_COND_LIBTOOL_TRUE='#'
13926 GL_COND_LIBTOOL_FALSE=
13927 fi
13928
13929 gl_cond_libtool=false
13930 gl_libdeps=
13931 gl_ltlibdeps=
13932 gl_m4_base='import/m4'
13933
13934
13935
13936
13937
13938
13939
13940
13941
13942 gl_source_base='import'
13943
13944
13945 if test $ac_cv_func_alloca_works = no; then
13946 :
13947 fi
13948
13949 # Define an additional variable used in the Makefile substitution.
13950 if test $ac_cv_working_alloca_h = yes; then
13951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
13952 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
13953 if ${gl_cv_rpl_alloca+:} false; then :
13954 $as_echo_n "(cached) " >&6
13955 else
13956
13957 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13958 /* end confdefs.h. */
13959
13960 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
13961 Need own alloca
13962 #endif
13963
13964 _ACEOF
13965 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13966 $EGREP "Need own alloca" >/dev/null 2>&1; then :
13967 gl_cv_rpl_alloca=yes
13968 else
13969 gl_cv_rpl_alloca=no
13970 fi
13971 rm -f conftest*
13972
13973
13974 fi
13975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
13976 $as_echo "$gl_cv_rpl_alloca" >&6; }
13977 if test $gl_cv_rpl_alloca = yes; then
13978
13979 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
13980
13981 ALLOCA_H=alloca.h
13982 else
13983 ALLOCA_H=
13984 fi
13985 else
13986 ALLOCA_H=alloca.h
13987 fi
13988
13989 if test -n "$ALLOCA_H"; then
13990 GL_GENERATE_ALLOCA_H_TRUE=
13991 GL_GENERATE_ALLOCA_H_FALSE='#'
13992 else
13993 GL_GENERATE_ALLOCA_H_TRUE='#'
13994 GL_GENERATE_ALLOCA_H_FALSE=
13995 fi
13996
13997
13998
13999
14000
14001
14002
14003
14004
14005
14006 gl_LIBOBJS="$gl_LIBOBJS openat-proc.$ac_objext"
14007
14008
14009
14010
14011 if test $ac_cv_func_canonicalize_file_name = no; then
14012 HAVE_CANONICALIZE_FILE_NAME=0
14013 if test $ac_cv_func_realpath = no; then
14014 HAVE_REALPATH=0
14015 else
14016 case "$gl_cv_func_realpath_works" in
14017 *yes) ;;
14018 *) REPLACE_REALPATH=1 ;;
14019 esac
14020 fi
14021 else
14022 case "$gl_cv_func_realpath_works" in
14023 *yes)
14024 ;;
14025 *)
14026 REPLACE_CANONICALIZE_FILE_NAME=1
14027 REPLACE_REALPATH=1
14028 ;;
14029 esac
14030 fi
14031
14032 if test $HAVE_CANONICALIZE_FILE_NAME = 0 || test $REPLACE_CANONICALIZE_FILE_NAME = 1; then
14033
14034
14035
14036
14037
14038
14039
14040
14041 gl_LIBOBJS="$gl_LIBOBJS canonicalize-lgpl.$ac_objext"
14042
14043 fi
14044
14045
14046 cat >>confdefs.h <<_ACEOF
14047 #define GNULIB_CANONICALIZE_LGPL 1
14048 _ACEOF
14049
14050
14051
14052
14053
14054
14055
14056 GNULIB_CANONICALIZE_FILE_NAME=1
14057
14058
14059
14060
14061
14062 $as_echo "#define GNULIB_TEST_CANONICALIZE_FILE_NAME 1" >>confdefs.h
14063
14064
14065
14066
14067
14068
14069
14070
14071 GNULIB_REALPATH=1
14072
14073
14074
14075
14076
14077 $as_echo "#define GNULIB_TEST_REALPATH 1" >>confdefs.h
14078
14079
14080
14081
14082
14083
14084
14085
14086 GNULIB_CHDIR=1
14087
14088
14089
14090
14091
14092 $as_echo "#define GNULIB_TEST_CHDIR 1" >>confdefs.h
14093
14094
14095
14096
14097
14098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether this system has an arbitrary file name length limit" >&5
14099 $as_echo_n "checking whether this system has an arbitrary file name length limit... " >&6; }
14100 if ${gl_cv_have_arbitrary_file_name_length_limit+:} false; then :
14101 $as_echo_n "(cached) " >&6
14102 else
14103 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14104 /* end confdefs.h. */
14105
14106 /* Arrange to define PATH_MAX, like "pathmax.h" does. */
14107 #if HAVE_UNISTD_H
14108 # include <unistd.h>
14109 #endif
14110 #include <limits.h>
14111 #if defined HAVE_SYS_PARAM_H && !defined PATH_MAX && !defined MAXPATHLEN
14112 # include <sys/param.h>
14113 #endif
14114 #if !defined PATH_MAX && defined MAXPATHLEN
14115 # define PATH_MAX MAXPATHLEN
14116 #endif
14117 #ifdef __hpux
14118 # undef PATH_MAX
14119 # define PATH_MAX 1024
14120 #endif
14121 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
14122 # undef PATH_MAX
14123 # define PATH_MAX 260
14124 #endif
14125
14126 #ifdef PATH_MAX
14127 have_arbitrary_file_name_length_limit
14128 #endif
14129 _ACEOF
14130 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14131 $EGREP "have_arbitrary_file_name_length_limit" >/dev/null 2>&1; then :
14132 gl_cv_have_arbitrary_file_name_length_limit=yes
14133 else
14134 gl_cv_have_arbitrary_file_name_length_limit=no
14135 fi
14136 rm -f conftest*
14137
14138 fi
14139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_arbitrary_file_name_length_limit" >&5
14140 $as_echo "$gl_cv_have_arbitrary_file_name_length_limit" >&6; }
14141
14142 if test $gl_cv_have_arbitrary_file_name_length_limit = yes; then
14143
14144
14145
14146
14147
14148
14149
14150
14151 gl_LIBOBJS="$gl_LIBOBJS chdir-long.$ac_objext"
14152
14153 :
14154 fi
14155
14156
14157 $as_echo "#define GNULIB_TEST_CLOEXEC 1" >>confdefs.h
14158
14159
14160
14161
14162
14163 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
14164 REPLACE_CLOSE=1
14165 fi
14166
14167
14168
14169
14170
14171 :
14172
14173
14174
14175
14176
14177 if test $ac_cv_header_sys_socket_h != yes; then
14178 for ac_header in winsock2.h
14179 do :
14180 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
14181 if test "x$ac_cv_header_winsock2_h" = xyes; then :
14182 cat >>confdefs.h <<_ACEOF
14183 #define HAVE_WINSOCK2_H 1
14184 _ACEOF
14185
14186 fi
14187
14188 done
14189
14190 fi
14191 if test "$ac_cv_header_winsock2_h" = yes; then
14192 HAVE_WINSOCK2_H=1
14193 UNISTD_H_HAVE_WINSOCK2_H=1
14194 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
14195 else
14196 HAVE_WINSOCK2_H=0
14197 fi
14198
14199
14200 if test $UNISTD_H_HAVE_WINSOCK2_H = 1; then
14201 REPLACE_CLOSE=1
14202 fi
14203
14204
14205 if test $REPLACE_CLOSE = 0; then
14206
14207
14208
14209 :
14210
14211
14212
14213
14214
14215 if test $ac_cv_func_fchdir = no; then
14216 HAVE_FCHDIR=0
14217 fi
14218
14219 if test $HAVE_FCHDIR = 0; then
14220 REPLACE_CLOSE=1
14221 fi
14222 fi
14223
14224
14225 if test $REPLACE_CLOSE = 1; then
14226
14227
14228
14229
14230
14231
14232
14233
14234 gl_LIBOBJS="$gl_LIBOBJS close.$ac_objext"
14235
14236 fi
14237
14238
14239
14240
14241
14242 GNULIB_CLOSE=1
14243
14244
14245
14246
14247
14248 $as_echo "#define GNULIB_TEST_CLOSE 1" >>confdefs.h
14249
14250
14251
14252
14253
14254
14255 for ac_func in closedir
14256 do :
14257 ac_fn_c_check_func "$LINENO" "closedir" "ac_cv_func_closedir"
14258 if test "x$ac_cv_func_closedir" = xyes; then :
14259 cat >>confdefs.h <<_ACEOF
14260 #define HAVE_CLOSEDIR 1
14261 _ACEOF
14262
14263 fi
14264 done
14265
14266 if test $ac_cv_func_closedir = no; then
14267 HAVE_CLOSEDIR=0
14268 fi
14269
14270
14271
14272
14273 :
14274
14275
14276
14277
14278
14279 if test $ac_cv_func_fchdir = no; then
14280 HAVE_FCHDIR=0
14281 fi
14282
14283 if test $HAVE_FCHDIR = 0; then
14284 if test $HAVE_CLOSEDIR = 1; then
14285 REPLACE_CLOSEDIR=1
14286 fi
14287 fi
14288
14289 case $host_os,$HAVE_CLOSEDIR in
14290 os2*,1)
14291 REPLACE_CLOSEDIR=1;;
14292 esac
14293
14294 if test $HAVE_CLOSEDIR = 0 || test $REPLACE_CLOSEDIR = 1; then
14295
14296
14297
14298
14299
14300
14301
14302
14303 gl_LIBOBJS="$gl_LIBOBJS closedir.$ac_objext"
14304
14305 fi
14306
14307
14308
14309
14310
14311 GNULIB_CLOSEDIR=1
14312
14313
14314
14315
14316
14317 $as_echo "#define GNULIB_TEST_CLOSEDIR 1" >>confdefs.h
14318
14319
14320
14321
14322 if test "x$datarootdir" = x; then
14323 datarootdir='${datadir}'
14324
14325 fi
14326 if test "x$docdir" = x; then
14327 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
14328
14329 fi
14330 if test "x$htmldir" = x; then
14331 htmldir='${docdir}'
14332
14333 fi
14334 if test "x$dvidir" = x; then
14335 dvidir='${docdir}'
14336
14337 fi
14338 if test "x$pdfdir" = x; then
14339 pdfdir='${docdir}'
14340
14341 fi
14342 if test "x$psdir" = x; then
14343 psdir='${docdir}'
14344
14345 fi
14346 if test "x$lispdir" = x; then
14347 lispdir='${datarootdir}/emacs/site-lisp'
14348
14349 fi
14350 if test "x$localedir" = x; then
14351 localedir='${datarootdir}/locale'
14352
14353 fi
14354 if test "x$runstatedir" = x; then
14355 runstatedir='${localstatedir}/run'
14356
14357 fi
14358
14359 pkglibexecdir='${libexecdir}/${PACKAGE}'
14360
14361
14362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for d_ino member in directory struct" >&5
14363 $as_echo_n "checking for d_ino member in directory struct... " >&6; }
14364 if ${gl_cv_struct_dirent_d_ino+:} false; then :
14365 $as_echo_n "(cached) " >&6
14366 else
14367 if test "$cross_compiling" = yes; then :
14368 case "$host_os" in
14369 # Guess yes on glibc systems with Linux kernel.
14370 linux*-gnu*) gl_cv_struct_dirent_d_ino="guessing yes" ;;
14371 # If we don't know, assume the worst.
14372 *) gl_cv_struct_dirent_d_ino="guessing no" ;;
14373 esac
14374
14375 else
14376 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14377 /* end confdefs.h. */
14378 #include <sys/types.h>
14379 #include <sys/stat.h>
14380 #include <dirent.h>
14381
14382 int
14383 main ()
14384 {
14385 DIR *dp = opendir (".");
14386 struct dirent *e;
14387 struct stat st;
14388 if (! dp)
14389 return 1;
14390 e = readdir (dp);
14391 if (! e)
14392 return 2;
14393 if (lstat (e->d_name, &st) != 0)
14394 return 3;
14395 if (e->d_ino != st.st_ino)
14396 return 4;
14397 closedir (dp);
14398 return 0;
14399
14400 ;
14401 return 0;
14402 }
14403 _ACEOF
14404 if ac_fn_c_try_run "$LINENO"; then :
14405 gl_cv_struct_dirent_d_ino=yes
14406 else
14407 gl_cv_struct_dirent_d_ino=no
14408 fi
14409 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14410 conftest.$ac_objext conftest.beam conftest.$ac_ext
14411 fi
14412
14413 fi
14414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_struct_dirent_d_ino" >&5
14415 $as_echo "$gl_cv_struct_dirent_d_ino" >&6; }
14416 case "$gl_cv_struct_dirent_d_ino" in
14417 *yes)
14418
14419 $as_echo "#define D_INO_IN_DIRENT 1" >>confdefs.h
14420
14421 ;;
14422 esac
14423
14424
14425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for d_type member in directory struct" >&5
14426 $as_echo_n "checking for d_type member in directory struct... " >&6; }
14427 if ${gl_cv_struct_dirent_d_type+:} false; then :
14428 $as_echo_n "(cached) " >&6
14429 else
14430 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14431 /* end confdefs.h. */
14432
14433 #include <sys/types.h>
14434 #include <dirent.h>
14435
14436 int
14437 main ()
14438 {
14439 struct dirent dp; dp.d_type = 0;
14440 ;
14441 return 0;
14442 }
14443 _ACEOF
14444 if ac_fn_c_try_link "$LINENO"; then :
14445 gl_cv_struct_dirent_d_type=yes
14446 else
14447 gl_cv_struct_dirent_d_type=no
14448 fi
14449 rm -f core conftest.err conftest.$ac_objext \
14450 conftest$ac_exeext conftest.$ac_ext
14451
14452
14453 fi
14454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_struct_dirent_d_type" >&5
14455 $as_echo "$gl_cv_struct_dirent_d_type" >&6; }
14456 if test $gl_cv_struct_dirent_d_type = yes; then
14457
14458 $as_echo "#define HAVE_STRUCT_DIRENT_D_TYPE 1" >>confdefs.h
14459
14460 fi
14461
14462
14463
14464
14465
14466
14467
14468
14469
14470
14471
14472 :
14473
14474
14475
14476
14477
14478
14479
14480
14481 if test $gl_cv_have_include_next = yes; then
14482 gl_cv_next_dirent_h='<'dirent.h'>'
14483 else
14484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <dirent.h>" >&5
14485 $as_echo_n "checking absolute name of <dirent.h>... " >&6; }
14486 if ${gl_cv_next_dirent_h+:} false; then :
14487 $as_echo_n "(cached) " >&6
14488 else
14489
14490 if test $ac_cv_header_dirent_h = yes; then
14491
14492
14493
14494
14495 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14496 /* end confdefs.h. */
14497 #include <dirent.h>
14498 _ACEOF
14499 case "$host_os" in
14500 aix*) gl_absname_cpp="$ac_cpp -C" ;;
14501 *) gl_absname_cpp="$ac_cpp" ;;
14502 esac
14503
14504 case "$host_os" in
14505 mingw*)
14506 gl_dirsep_regex='[/\\]'
14507 ;;
14508 *)
14509 gl_dirsep_regex='\/'
14510 ;;
14511 esac
14512 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
14513 gl_header_literal_regex=`echo 'dirent.h' \
14514 | sed -e "$gl_make_literal_regex_sed"`
14515 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
14516 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
14517 s|^/[^/]|//&|
14518 p
14519 q
14520 }'
14521
14522 gl_cv_absolute_dirent_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
14523 sed -n "$gl_absolute_header_sed"`
14524
14525 gl_header=$gl_cv_absolute_dirent_h
14526 gl_cv_next_dirent_h='"'$gl_header'"'
14527 else
14528 gl_cv_next_dirent_h='<'dirent.h'>'
14529 fi
14530
14531
14532 fi
14533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_dirent_h" >&5
14534 $as_echo "$gl_cv_next_dirent_h" >&6; }
14535 fi
14536 NEXT_DIRENT_H=$gl_cv_next_dirent_h
14537
14538 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
14539 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
14540 gl_next_as_first_directive='<'dirent.h'>'
14541 else
14542 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
14543 gl_next_as_first_directive=$gl_cv_next_dirent_h
14544 fi
14545 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H=$gl_next_as_first_directive
14546
14547
14548
14549
14550 if test $ac_cv_header_dirent_h = yes; then
14551 HAVE_DIRENT_H=1
14552 else
14553 HAVE_DIRENT_H=0
14554 fi
14555
14556
14557
14558 for gl_func in alphasort closedir dirfd fdopendir opendir readdir rewinddir scandir; do
14559 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
14560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
14561 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
14562 if eval \${$as_gl_Symbol+:} false; then :
14563 $as_echo_n "(cached) " >&6
14564 else
14565 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14566 /* end confdefs.h. */
14567 #include <dirent.h>
14568
14569 int
14570 main ()
14571 {
14572 #undef $gl_func
14573 (void) $gl_func;
14574 ;
14575 return 0;
14576 }
14577 _ACEOF
14578 if ac_fn_c_try_compile "$LINENO"; then :
14579 eval "$as_gl_Symbol=yes"
14580 else
14581 eval "$as_gl_Symbol=no"
14582 fi
14583 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14584 fi
14585 eval ac_res=\$$as_gl_Symbol
14586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
14587 $as_echo "$ac_res" >&6; }
14588 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
14589 cat >>confdefs.h <<_ACEOF
14590 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
14591 _ACEOF
14592
14593 eval ac_cv_have_decl_$gl_func=yes
14594 fi
14595 done
14596
14597
14598
14599
14600
14601
14602
14603 for ac_func in dirfd
14604 do :
14605 ac_fn_c_check_func "$LINENO" "dirfd" "ac_cv_func_dirfd"
14606 if test "x$ac_cv_func_dirfd" = xyes; then :
14607 cat >>confdefs.h <<_ACEOF
14608 #define HAVE_DIRFD 1
14609 _ACEOF
14610
14611 fi
14612 done
14613
14614 ac_fn_c_check_decl "$LINENO" "dirfd" "ac_cv_have_decl_dirfd" "#include <sys/types.h>
14615 #include <dirent.h>
14616 "
14617 if test "x$ac_cv_have_decl_dirfd" = xyes; then :
14618 ac_have_decl=1
14619 else
14620 ac_have_decl=0
14621 fi
14622
14623 cat >>confdefs.h <<_ACEOF
14624 #define HAVE_DECL_DIRFD $ac_have_decl
14625 _ACEOF
14626
14627 if test $ac_cv_have_decl_dirfd = no; then
14628 HAVE_DECL_DIRFD=0
14629 fi
14630
14631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dirfd is a macro" >&5
14632 $as_echo_n "checking whether dirfd is a macro... " >&6; }
14633 if ${gl_cv_func_dirfd_macro+:} false; then :
14634 $as_echo_n "(cached) " >&6
14635 else
14636 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14637 /* end confdefs.h. */
14638
14639 #include <sys/types.h>
14640 #include <dirent.h>
14641 #ifdef dirfd
14642 dirent_header_defines_dirfd
14643 #endif
14644 _ACEOF
14645 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14646 $EGREP "dirent_header_defines_dirfd" >/dev/null 2>&1; then :
14647 gl_cv_func_dirfd_macro=yes
14648 else
14649 gl_cv_func_dirfd_macro=no
14650 fi
14651 rm -f conftest*
14652
14653 fi
14654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dirfd_macro" >&5
14655 $as_echo "$gl_cv_func_dirfd_macro" >&6; }
14656
14657 # Use the replacement if we have no function or macro with that name,
14658 # or if OS/2 kLIBC whose dirfd() does not work.
14659 # Replace only if the system declares dirfd already.
14660 case $ac_cv_func_dirfd,$gl_cv_func_dirfd_macro,$host_os,$ac_cv_have_decl_dirfd in
14661 no,no,*,yes | *,*,os2*,yes)
14662 REPLACE_DIRFD=1
14663
14664 $as_echo "#define REPLACE_DIRFD 1" >>confdefs.h
14665 ;;
14666 esac
14667
14668 if test $ac_cv_func_dirfd = no && test $gl_cv_func_dirfd_macro = no \
14669 || test $REPLACE_DIRFD = 1; then
14670
14671
14672
14673
14674
14675
14676
14677
14678 gl_LIBOBJS="$gl_LIBOBJS dirfd.$ac_objext"
14679
14680
14681 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to get the file descriptor associated with an open DIR*" >&5
14682 $as_echo_n "checking how to get the file descriptor associated with an open DIR*... " >&6; }
14683 if ${gl_cv_sys_dir_fd_member_name+:} false; then :
14684 $as_echo_n "(cached) " >&6
14685 else
14686
14687 dirfd_save_CFLAGS=$CFLAGS
14688 for ac_expr in d_fd dd_fd; do
14689
14690 CFLAGS="$CFLAGS -DDIR_FD_MEMBER_NAME=$ac_expr"
14691 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14692 /* end confdefs.h. */
14693
14694 #include <sys/types.h>
14695 #include <dirent.h>
14696 int
14697 main ()
14698 {
14699 DIR *dir_p = opendir("."); (void) dir_p->DIR_FD_MEMBER_NAME;
14700 ;
14701 return 0;
14702 }
14703 _ACEOF
14704 if ac_fn_c_try_compile "$LINENO"; then :
14705 dir_fd_found=yes
14706
14707 fi
14708 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14709 CFLAGS=$dirfd_save_CFLAGS
14710 test "$dir_fd_found" = yes && break
14711 done
14712 test "$dir_fd_found" = yes || ac_expr=no_such_member
14713
14714 gl_cv_sys_dir_fd_member_name=$ac_expr
14715
14716
14717 fi
14718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_dir_fd_member_name" >&5
14719 $as_echo "$gl_cv_sys_dir_fd_member_name" >&6; }
14720 if test $gl_cv_sys_dir_fd_member_name != no_such_member; then
14721
14722 cat >>confdefs.h <<_ACEOF
14723 #define DIR_FD_MEMBER_NAME $gl_cv_sys_dir_fd_member_name
14724 _ACEOF
14725
14726 fi
14727
14728
14729 fi
14730
14731
14732
14733
14734
14735 GNULIB_DIRFD=1
14736
14737
14738
14739
14740
14741 $as_echo "#define GNULIB_TEST_DIRFD 1" >>confdefs.h
14742
14743
14744
14745
14746
14747
14748
14749
14750
14751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether // is distinct from /" >&5
14752 $as_echo_n "checking whether // is distinct from /... " >&6; }
14753 if ${gl_cv_double_slash_root+:} false; then :
14754 $as_echo_n "(cached) " >&6
14755 else
14756 if test x"$cross_compiling" = xyes ; then
14757 # When cross-compiling, there is no way to tell whether // is special
14758 # short of a list of hosts. However, the only known hosts to date
14759 # that have a distinct // are Apollo DomainOS (too old to port to),
14760 # Cygwin, and z/OS. If anyone knows of another system for which // has
14761 # special semantics and is distinct from /, please report it to
14762 # <bug-gnulib@gnu.org>.
14763 case $host in
14764 *-cygwin | i370-ibm-openedition)
14765 gl_cv_double_slash_root=yes ;;
14766 *)
14767 # Be optimistic and assume that / and // are the same when we
14768 # don't know.
14769 gl_cv_double_slash_root='unknown, assuming no' ;;
14770 esac
14771 else
14772 set x `ls -di / // 2>/dev/null`
14773 if test "$2" = "$4" && wc //dev/null >/dev/null 2>&1; then
14774 gl_cv_double_slash_root=no
14775 else
14776 gl_cv_double_slash_root=yes
14777 fi
14778 fi
14779 fi
14780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_double_slash_root" >&5
14781 $as_echo "$gl_cv_double_slash_root" >&6; }
14782 if test "$gl_cv_double_slash_root" = yes; then
14783
14784 $as_echo "#define DOUBLE_SLASH_IS_DISTINCT_ROOT 1" >>confdefs.h
14785
14786 fi
14787
14788
14789
14790
14791 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
14792 REPLACE_DUP=1
14793 fi
14794
14795
14796
14797
14798 :
14799
14800
14801
14802
14803
14804 if test $ac_cv_func_fchdir = no; then
14805 HAVE_FCHDIR=0
14806 fi
14807
14808 if test $HAVE_FCHDIR = 0; then
14809 REPLACE_DUP=1
14810 fi
14811
14812 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup works" >&5
14813 $as_echo_n "checking whether dup works... " >&6; }
14814 if ${gl_cv_func_dup_works+:} false; then :
14815 $as_echo_n "(cached) " >&6
14816 else
14817 if test "$cross_compiling" = yes; then :
14818 gl_cv_func_dup_works='guessing yes'
14819 else
14820 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14821 /* end confdefs.h. */
14822 #include <unistd.h>
14823 #include <fcntl.h>
14824 #include <errno.h>
14825 int
14826 main ()
14827 {
14828 /* On OS/2 kLIBC, dup does not work on a directory fd. */
14829 int fd = open (".", O_RDONLY);
14830 return fd < 0 ? 1 : dup (fd) < 0 ? 2 : 0;
14831
14832 ;
14833 return 0;
14834 }
14835
14836 _ACEOF
14837 if ac_fn_c_try_run "$LINENO"; then :
14838 gl_cv_func_dup_works=yes
14839 else
14840 gl_cv_func_dup_works=no
14841 fi
14842 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14843 conftest.$ac_objext conftest.beam conftest.$ac_ext
14844 fi
14845
14846
14847 fi
14848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup_works" >&5
14849 $as_echo "$gl_cv_func_dup_works" >&6; }
14850 case "$gl_cv_func_dup_works" in
14851 *yes) ;;
14852 *)
14853 REPLACE_DUP=1
14854 ;;
14855 esac
14856
14857 if test $REPLACE_DUP = 1; then
14858
14859
14860
14861
14862
14863
14864
14865
14866 gl_LIBOBJS="$gl_LIBOBJS dup.$ac_objext"
14867
14868 :
14869 fi
14870
14871
14872
14873
14874
14875 GNULIB_DUP=1
14876
14877
14878
14879
14880
14881 $as_echo "#define GNULIB_TEST_DUP 1" >>confdefs.h
14882
14883
14884
14885
14886
14887
14888
14889
14890 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
14891
14892
14893 if test $HAVE_DUP2 = 1; then
14894 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
14895 $as_echo_n "checking whether dup2 works... " >&6; }
14896 if ${gl_cv_func_dup2_works+:} false; then :
14897 $as_echo_n "(cached) " >&6
14898 else
14899 if test "$cross_compiling" = yes; then :
14900 case "$host_os" in
14901 mingw*) # on this platform, dup2 always returns 0 for success
14902 gl_cv_func_dup2_works="guessing no" ;;
14903 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
14904 gl_cv_func_dup2_works="guessing no" ;;
14905 aix* | freebsd*)
14906 # on AIX 7.1 and FreeBSD 6.1, dup2 (1,toobig) gives EMFILE,
14907 # not EBADF.
14908 gl_cv_func_dup2_works="guessing no" ;;
14909 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
14910 gl_cv_func_dup2_works="guessing no" ;;
14911 *-android*) # implemented using dup3(), which fails if oldfd == newfd
14912 gl_cv_func_dup2_works="guessing no" ;;
14913 os2*) # on OS/2 kLIBC, dup2() does not work on a directory fd.
14914 gl_cv_func_dup2_works="guessing no" ;;
14915 *) gl_cv_func_dup2_works="guessing yes" ;;
14916 esac
14917 else
14918 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14919 /* end confdefs.h. */
14920
14921 #include <errno.h>
14922 #include <fcntl.h>
14923 #include <limits.h>
14924 #include <sys/resource.h>
14925 #include <unistd.h>
14926 #ifndef RLIM_SAVED_CUR
14927 # define RLIM_SAVED_CUR RLIM_INFINITY
14928 #endif
14929 #ifndef RLIM_SAVED_MAX
14930 # define RLIM_SAVED_MAX RLIM_INFINITY
14931 #endif
14932
14933 int
14934 main ()
14935 {
14936 int result = 0;
14937 int bad_fd = INT_MAX;
14938 struct rlimit rlim;
14939 if (getrlimit (RLIMIT_NOFILE, &rlim) == 0
14940 && 0 <= rlim.rlim_cur && rlim.rlim_cur <= INT_MAX
14941 && rlim.rlim_cur != RLIM_INFINITY
14942 && rlim.rlim_cur != RLIM_SAVED_MAX
14943 && rlim.rlim_cur != RLIM_SAVED_CUR)
14944 bad_fd = rlim.rlim_cur;
14945 #ifdef FD_CLOEXEC
14946 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
14947 result |= 1;
14948 #endif
14949 if (dup2 (1, 1) != 1)
14950 result |= 2;
14951 #ifdef FD_CLOEXEC
14952 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
14953 result |= 4;
14954 #endif
14955 close (0);
14956 if (dup2 (0, 0) != -1)
14957 result |= 8;
14958 /* Many gnulib modules require POSIX conformance of EBADF. */
14959 if (dup2 (2, bad_fd) == -1 && errno != EBADF)
14960 result |= 16;
14961 /* Flush out some cygwin core dumps. */
14962 if (dup2 (2, -1) != -1 || errno != EBADF)
14963 result |= 32;
14964 dup2 (2, 255);
14965 dup2 (2, 256);
14966 /* On OS/2 kLIBC, dup2() does not work on a directory fd. */
14967 {
14968 int fd = open (".", O_RDONLY);
14969 if (fd == -1)
14970 result |= 64;
14971 else if (dup2 (fd, fd + 1) == -1)
14972 result |= 128;
14973
14974 close (fd);
14975 }
14976 return result;
14977 ;
14978 return 0;
14979 }
14980
14981 _ACEOF
14982 if ac_fn_c_try_run "$LINENO"; then :
14983 gl_cv_func_dup2_works=yes
14984 else
14985 gl_cv_func_dup2_works=no
14986 fi
14987 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14988 conftest.$ac_objext conftest.beam conftest.$ac_ext
14989 fi
14990
14991
14992 fi
14993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
14994 $as_echo "$gl_cv_func_dup2_works" >&6; }
14995 case "$gl_cv_func_dup2_works" in
14996 *yes) ;;
14997 *)
14998 REPLACE_DUP2=1
14999 for ac_func in setdtablesize
15000 do :
15001 ac_fn_c_check_func "$LINENO" "setdtablesize" "ac_cv_func_setdtablesize"
15002 if test "x$ac_cv_func_setdtablesize" = xyes; then :
15003 cat >>confdefs.h <<_ACEOF
15004 #define HAVE_SETDTABLESIZE 1
15005 _ACEOF
15006
15007 fi
15008 done
15009
15010 ;;
15011 esac
15012 fi
15013
15014
15015
15016
15017 :
15018
15019
15020
15021
15022
15023 if test $ac_cv_func_fchdir = no; then
15024 HAVE_FCHDIR=0
15025 fi
15026
15027 if test $HAVE_FCHDIR = 0; then
15028 if test $HAVE_DUP2 = 1; then
15029 REPLACE_DUP2=1
15030 fi
15031 fi
15032
15033
15034 if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
15035
15036
15037
15038
15039
15040
15041
15042
15043 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
15044
15045
15046 fi
15047
15048
15049
15050
15051
15052 GNULIB_DUP2=1
15053
15054
15055
15056
15057
15058 $as_echo "#define GNULIB_TEST_DUP2 1" >>confdefs.h
15059
15060
15061
15062
15063
15064
15065
15066
15067
15068 GNULIB_ENVIRON=1
15069
15070
15071
15072
15073
15074 $as_echo "#define GNULIB_TEST_ENVIRON 1" >>confdefs.h
15075
15076
15077
15078
15079
15080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for error_at_line" >&5
15081 $as_echo_n "checking for error_at_line... " >&6; }
15082 if ${ac_cv_lib_error_at_line+:} false; then :
15083 $as_echo_n "(cached) " >&6
15084 else
15085 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15086 /* end confdefs.h. */
15087 #include <error.h>
15088 int
15089 main ()
15090 {
15091 error_at_line (0, 0, "", 0, "an error occurred");
15092 ;
15093 return 0;
15094 }
15095 _ACEOF
15096 if ac_fn_c_try_link "$LINENO"; then :
15097 ac_cv_lib_error_at_line=yes
15098 else
15099 ac_cv_lib_error_at_line=no
15100 fi
15101 rm -f core conftest.err conftest.$ac_objext \
15102 conftest$ac_exeext conftest.$ac_ext
15103 fi
15104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_error_at_line" >&5
15105 $as_echo "$ac_cv_lib_error_at_line" >&6; }
15106
15107 if test $ac_cv_lib_error_at_line = no; then
15108
15109
15110
15111
15112
15113
15114
15115
15116 gl_LIBOBJS="$gl_LIBOBJS error.$ac_objext"
15117
15118
15119
15120 :
15121
15122 fi
15123
15124
15125
15126
15127
15128
15129
15130 :
15131
15132
15133
15134
15135
15136 if test $ac_cv_have_decl_fchdir = no; then
15137 HAVE_DECL_FCHDIR=0
15138 fi
15139
15140
15141 if test $HAVE_FCHDIR = 0; then
15142
15143
15144
15145
15146
15147
15148
15149
15150 gl_LIBOBJS="$gl_LIBOBJS fchdir.$ac_objext"
15151
15152 :
15153
15154 $as_echo "#define REPLACE_FCHDIR 1" >>confdefs.h
15155
15156 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether open can visit directories" >&5
15157 $as_echo_n "checking whether open can visit directories... " >&6; }
15158 if ${gl_cv_func_open_directory_works+:} false; then :
15159 $as_echo_n "(cached) " >&6
15160 else
15161 if test "$cross_compiling" = yes; then :
15162 case "$host_os" in
15163 # Guess yes on glibc systems.
15164 *-gnu*) gl_cv_func_open_directory_works="guessing yes" ;;
15165 # If we don't know, assume the worst.
15166 *) gl_cv_func_open_directory_works="guessing no" ;;
15167 esac
15168
15169 else
15170 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15171 /* end confdefs.h. */
15172 #include <fcntl.h>
15173
15174 int
15175 main ()
15176 {
15177 return open(".", O_RDONLY) < 0;
15178 ;
15179 return 0;
15180 }
15181 _ACEOF
15182 if ac_fn_c_try_run "$LINENO"; then :
15183 gl_cv_func_open_directory_works=yes
15184 else
15185 gl_cv_func_open_directory_works=no
15186 fi
15187 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15188 conftest.$ac_objext conftest.beam conftest.$ac_ext
15189 fi
15190
15191 fi
15192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_open_directory_works" >&5
15193 $as_echo "$gl_cv_func_open_directory_works" >&6; }
15194 case "$gl_cv_func_open_directory_works" in
15195 *yes) ;;
15196 *)
15197
15198 $as_echo "#define REPLACE_OPEN_DIRECTORY 1" >>confdefs.h
15199
15200 ;;
15201 esac
15202 fi
15203
15204
15205
15206
15207
15208
15209 GNULIB_FCHDIR=1
15210
15211
15212
15213
15214
15215 $as_echo "#define GNULIB_TEST_FCHDIR 1" >>confdefs.h
15216
15217
15218
15219
15220
15221
15222
15223
15224 :
15225
15226
15227
15228
15229
15230 if test $ac_cv_func_fcntl = no; then
15231
15232
15233
15234 :
15235
15236
15237
15238
15239
15240 if test $ac_cv_func_fcntl = no; then
15241 HAVE_FCNTL=0
15242 else
15243 REPLACE_FCNTL=1
15244 fi
15245
15246 else
15247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl handles F_DUPFD correctly" >&5
15248 $as_echo_n "checking whether fcntl handles F_DUPFD correctly... " >&6; }
15249 if ${gl_cv_func_fcntl_f_dupfd_works+:} false; then :
15250 $as_echo_n "(cached) " >&6
15251 else
15252 if test "$cross_compiling" = yes; then :
15253 case $host_os in
15254 aix* | cygwin* | haiku*)
15255 gl_cv_func_fcntl_f_dupfd_works="guessing no" ;;
15256 *) gl_cv_func_fcntl_f_dupfd_works="guessing yes" ;;
15257 esac
15258 else
15259 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15260 /* end confdefs.h. */
15261 #include <errno.h>
15262 #include <fcntl.h>
15263 #include <limits.h>
15264 #include <sys/resource.h>
15265 #include <unistd.h>
15266 #ifndef RLIM_SAVED_CUR
15267 # define RLIM_SAVED_CUR RLIM_INFINITY
15268 #endif
15269 #ifndef RLIM_SAVED_MAX
15270 # define RLIM_SAVED_MAX RLIM_INFINITY
15271 #endif
15272
15273 int
15274 main ()
15275 {
15276 int result = 0;
15277 int bad_fd = INT_MAX;
15278 struct rlimit rlim;
15279 if (getrlimit (RLIMIT_NOFILE, &rlim) == 0
15280 && 0 <= rlim.rlim_cur && rlim.rlim_cur <= INT_MAX
15281 && rlim.rlim_cur != RLIM_INFINITY
15282 && rlim.rlim_cur != RLIM_SAVED_MAX
15283 && rlim.rlim_cur != RLIM_SAVED_CUR)
15284 bad_fd = rlim.rlim_cur;
15285 if (fcntl (0, F_DUPFD, -1) != -1) result |= 1;
15286 if (errno != EINVAL) result |= 2;
15287 if (fcntl (0, F_DUPFD, bad_fd) != -1) result |= 4;
15288 if (errno != EINVAL) result |= 8;
15289 /* On OS/2 kLIBC, F_DUPFD does not work on a directory fd */
15290 {
15291 int fd;
15292 fd = open (".", O_RDONLY);
15293 if (fd == -1)
15294 result |= 16;
15295 else if (fcntl (fd, F_DUPFD, STDERR_FILENO + 1) == -1)
15296 result |= 32;
15297
15298 close (fd);
15299 }
15300 return result;
15301 ;
15302 return 0;
15303 }
15304 _ACEOF
15305 if ac_fn_c_try_run "$LINENO"; then :
15306 gl_cv_func_fcntl_f_dupfd_works=yes
15307 else
15308 gl_cv_func_fcntl_f_dupfd_works=no
15309 fi
15310 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15311 conftest.$ac_objext conftest.beam conftest.$ac_ext
15312 fi
15313
15314 fi
15315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_works" >&5
15316 $as_echo "$gl_cv_func_fcntl_f_dupfd_works" >&6; }
15317 case $gl_cv_func_fcntl_f_dupfd_works in
15318 *yes) ;;
15319 *)
15320
15321
15322 :
15323
15324
15325
15326
15327
15328 if test $ac_cv_func_fcntl = no; then
15329 HAVE_FCNTL=0
15330 else
15331 REPLACE_FCNTL=1
15332 fi
15333
15334
15335 $as_echo "#define FCNTL_DUPFD_BUGGY 1" >>confdefs.h
15336 ;;
15337 esac
15338
15339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl understands F_DUPFD_CLOEXEC" >&5
15340 $as_echo_n "checking whether fcntl understands F_DUPFD_CLOEXEC... " >&6; }
15341 if ${gl_cv_func_fcntl_f_dupfd_cloexec+:} false; then :
15342 $as_echo_n "(cached) " >&6
15343 else
15344 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15345 /* end confdefs.h. */
15346
15347 #include <fcntl.h>
15348 #ifndef F_DUPFD_CLOEXEC
15349 choke me
15350 #endif
15351
15352 int
15353 main ()
15354 {
15355
15356 ;
15357 return 0;
15358 }
15359 _ACEOF
15360 if ac_fn_c_try_compile "$LINENO"; then :
15361 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15362 /* end confdefs.h. */
15363
15364 #ifdef __linux__
15365 /* The Linux kernel only added F_DUPFD_CLOEXEC in 2.6.24, so we always replace
15366 it to support the semantics on older kernels that failed with EINVAL. */
15367 choke me
15368 #endif
15369
15370 int
15371 main ()
15372 {
15373
15374 ;
15375 return 0;
15376 }
15377 _ACEOF
15378 if ac_fn_c_try_compile "$LINENO"; then :
15379 gl_cv_func_fcntl_f_dupfd_cloexec=yes
15380 else
15381 gl_cv_func_fcntl_f_dupfd_cloexec="needs runtime check"
15382 fi
15383 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15384 else
15385 gl_cv_func_fcntl_f_dupfd_cloexec=no
15386 fi
15387 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15388 fi
15389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_cloexec" >&5
15390 $as_echo "$gl_cv_func_fcntl_f_dupfd_cloexec" >&6; }
15391 if test "$gl_cv_func_fcntl_f_dupfd_cloexec" != yes; then
15392
15393
15394
15395 :
15396
15397
15398
15399
15400
15401 if test $ac_cv_func_fcntl = no; then
15402 HAVE_FCNTL=0
15403 else
15404 REPLACE_FCNTL=1
15405 fi
15406
15407 fi
15408 fi
15409
15410
15411
15412
15413 :
15414
15415
15416
15417
15418
15419 if test $ac_cv_func_fchdir = no; then
15420 HAVE_FCHDIR=0
15421 fi
15422
15423 if test $HAVE_FCHDIR = 0; then
15424
15425
15426
15427 :
15428
15429
15430
15431
15432
15433 if test $ac_cv_func_fcntl = no; then
15434 HAVE_FCNTL=0
15435 else
15436 REPLACE_FCNTL=1
15437 fi
15438
15439 fi
15440
15441
15442 if test $HAVE_FCNTL = 0 || test $REPLACE_FCNTL = 1; then
15443
15444
15445
15446
15447
15448
15449
15450
15451 gl_LIBOBJS="$gl_LIBOBJS fcntl.$ac_objext"
15452
15453 fi
15454
15455
15456
15457
15458
15459 GNULIB_FCNTL=1
15460
15461
15462
15463
15464
15465 $as_echo "#define GNULIB_TEST_FCNTL 1" >>confdefs.h
15466
15467
15468
15469
15470
15471
15472
15473
15474
15475
15476
15477
15478
15479
15480 if test $gl_cv_have_include_next = yes; then
15481 gl_cv_next_fcntl_h='<'fcntl.h'>'
15482 else
15483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <fcntl.h>" >&5
15484 $as_echo_n "checking absolute name of <fcntl.h>... " >&6; }
15485 if ${gl_cv_next_fcntl_h+:} false; then :
15486 $as_echo_n "(cached) " >&6
15487 else
15488
15489
15490
15491 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15492 /* end confdefs.h. */
15493 #include <fcntl.h>
15494 _ACEOF
15495 case "$host_os" in
15496 aix*) gl_absname_cpp="$ac_cpp -C" ;;
15497 *) gl_absname_cpp="$ac_cpp" ;;
15498 esac
15499
15500 case "$host_os" in
15501 mingw*)
15502 gl_dirsep_regex='[/\\]'
15503 ;;
15504 *)
15505 gl_dirsep_regex='\/'
15506 ;;
15507 esac
15508 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
15509 gl_header_literal_regex=`echo 'fcntl.h' \
15510 | sed -e "$gl_make_literal_regex_sed"`
15511 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
15512 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
15513 s|^/[^/]|//&|
15514 p
15515 q
15516 }'
15517
15518 gl_cv_absolute_fcntl_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
15519 sed -n "$gl_absolute_header_sed"`
15520
15521 gl_header=$gl_cv_absolute_fcntl_h
15522 gl_cv_next_fcntl_h='"'$gl_header'"'
15523
15524
15525 fi
15526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_fcntl_h" >&5
15527 $as_echo "$gl_cv_next_fcntl_h" >&6; }
15528 fi
15529 NEXT_FCNTL_H=$gl_cv_next_fcntl_h
15530
15531 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
15532 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
15533 gl_next_as_first_directive='<'fcntl.h'>'
15534 else
15535 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
15536 gl_next_as_first_directive=$gl_cv_next_fcntl_h
15537 fi
15538 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H=$gl_next_as_first_directive
15539
15540
15541
15542
15543
15544
15545
15546
15547
15548
15549 for gl_func in fcntl openat; do
15550 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
15551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
15552 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
15553 if eval \${$as_gl_Symbol+:} false; then :
15554 $as_echo_n "(cached) " >&6
15555 else
15556 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15557 /* end confdefs.h. */
15558 #include <fcntl.h>
15559
15560 int
15561 main ()
15562 {
15563 #undef $gl_func
15564 (void) $gl_func;
15565 ;
15566 return 0;
15567 }
15568 _ACEOF
15569 if ac_fn_c_try_compile "$LINENO"; then :
15570 eval "$as_gl_Symbol=yes"
15571 else
15572 eval "$as_gl_Symbol=no"
15573 fi
15574 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15575 fi
15576 eval ac_res=\$$as_gl_Symbol
15577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15578 $as_echo "$ac_res" >&6; }
15579 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
15580 cat >>confdefs.h <<_ACEOF
15581 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
15582 _ACEOF
15583
15584 eval ac_cv_have_decl_$gl_func=yes
15585 fi
15586 done
15587
15588
15589
15590
15591
15592
15593
15594 ac_fn_c_check_decl "$LINENO" "fdopendir" "ac_cv_have_decl_fdopendir" "
15595 #include <dirent.h>
15596
15597 "
15598 if test "x$ac_cv_have_decl_fdopendir" = xyes; then :
15599 ac_have_decl=1
15600 else
15601 ac_have_decl=0
15602 fi
15603
15604 cat >>confdefs.h <<_ACEOF
15605 #define HAVE_DECL_FDOPENDIR $ac_have_decl
15606 _ACEOF
15607 if test $ac_have_decl = 1; then :
15608
15609 else
15610 HAVE_DECL_FDOPENDIR=0
15611 fi
15612
15613
15614 :
15615
15616
15617
15618
15619
15620 if test $ac_cv_func_fdopendir = no; then
15621 HAVE_FDOPENDIR=0
15622 else
15623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fdopendir works" >&5
15624 $as_echo_n "checking whether fdopendir works... " >&6; }
15625 if ${gl_cv_func_fdopendir_works+:} false; then :
15626 $as_echo_n "(cached) " >&6
15627 else
15628 if test "$cross_compiling" = yes; then :
15629 case "$host_os" in
15630 # Guess yes on glibc systems.
15631 *-gnu*) gl_cv_func_fdopendir_works="guessing yes" ;;
15632 # If we don't know, assume the worst.
15633 *) gl_cv_func_fdopendir_works="guessing no" ;;
15634 esac
15635
15636 else
15637 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15638 /* end confdefs.h. */
15639
15640 #include <dirent.h>
15641 #include <fcntl.h>
15642 #include <unistd.h>
15643 #if !HAVE_DECL_FDOPENDIR
15644 extern
15645 # ifdef __cplusplus
15646 "C"
15647 # endif
15648 DIR *fdopendir (int);
15649 #endif
15650
15651 int
15652 main ()
15653 {
15654 int result = 0;
15655 int fd = open ("conftest.c", O_RDONLY);
15656 if (fd < 0) result |= 1;
15657 if (fdopendir (fd)) result |= 2;
15658 if (close (fd)) result |= 4;
15659 return result;
15660 ;
15661 return 0;
15662 }
15663 _ACEOF
15664 if ac_fn_c_try_run "$LINENO"; then :
15665 gl_cv_func_fdopendir_works=yes
15666 else
15667 gl_cv_func_fdopendir_works=no
15668 fi
15669 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15670 conftest.$ac_objext conftest.beam conftest.$ac_ext
15671 fi
15672
15673 fi
15674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fdopendir_works" >&5
15675 $as_echo "$gl_cv_func_fdopendir_works" >&6; }
15676 case "$gl_cv_func_fdopendir_works" in
15677 *yes) ;;
15678 *)
15679 REPLACE_FDOPENDIR=1
15680 ;;
15681 esac
15682 fi
15683
15684 if test $HAVE_FDOPENDIR = 0 || test $REPLACE_FDOPENDIR = 1; then
15685
15686
15687
15688
15689
15690
15691
15692
15693 gl_LIBOBJS="$gl_LIBOBJS fdopendir.$ac_objext"
15694
15695 fi
15696
15697
15698
15699
15700
15701 GNULIB_FDOPENDIR=1
15702
15703
15704
15705
15706
15707 $as_echo "#define GNULIB_TEST_FDOPENDIR 1" >>confdefs.h
15708
15709
15710
15711
15712
15713 cat >>confdefs.h <<_ACEOF
15714 #define GNULIB_FDOPENDIR 1
15715 _ACEOF
15716
15717
15718
15719
15720 :
15721
15722
15723
15724
15725
15726
15727
15728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flexible array member" >&5
15729 $as_echo_n "checking for flexible array member... " >&6; }
15730 if ${ac_cv_c_flexmember+:} false; then :
15731 $as_echo_n "(cached) " >&6
15732 else
15733 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15734 /* end confdefs.h. */
15735 #include <stdlib.h>
15736 #include <stdio.h>
15737 #include <stddef.h>
15738 struct s { int n; double d[]; };
15739 int
15740 main ()
15741 {
15742 int m = getchar ();
15743 size_t nbytes = offsetof (struct s, d) + m * sizeof (double);
15744 nbytes += sizeof (struct s) - 1;
15745 nbytes -= nbytes % sizeof (struct s);
15746 struct s *p = malloc (nbytes);
15747 p->d[0] = 0.0;
15748 return p->d != (double *) NULL;
15749 ;
15750 return 0;
15751 }
15752 _ACEOF
15753 if ac_fn_c_try_compile "$LINENO"; then :
15754 ac_cv_c_flexmember=yes
15755 else
15756 ac_cv_c_flexmember=no
15757 fi
15758 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15759 fi
15760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_flexmember" >&5
15761 $as_echo "$ac_cv_c_flexmember" >&6; }
15762 if test $ac_cv_c_flexmember = yes; then
15763
15764 $as_echo "#define FLEXIBLE_ARRAY_MEMBER /**/" >>confdefs.h
15765
15766 else
15767 $as_echo "#define FLEXIBLE_ARRAY_MEMBER 1" >>confdefs.h
15768
15769 fi
15770
15771
15772
15773
15774 FLOAT_H=
15775 REPLACE_FLOAT_LDBL=0
15776 case "$host_os" in
15777 aix* | beos* | openbsd* | mirbsd* | irix*)
15778 FLOAT_H=float.h
15779 ;;
15780 freebsd*)
15781 case "$host_cpu" in
15782 i[34567]86 )
15783 FLOAT_H=float.h
15784 ;;
15785 x86_64 )
15786 # On x86_64 systems, the C compiler may still be generating
15787 # 32-bit code.
15788 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15789 /* end confdefs.h. */
15790 #if defined __LP64__ || defined __x86_64__ || defined __amd64__
15791 yes
15792 #endif
15793 _ACEOF
15794 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15795 $EGREP "yes" >/dev/null 2>&1; then :
15796
15797 else
15798 FLOAT_H=float.h
15799 fi
15800 rm -f conftest*
15801
15802 ;;
15803 esac
15804 ;;
15805 linux*)
15806 case "$host_cpu" in
15807 powerpc*)
15808 FLOAT_H=float.h
15809 ;;
15810 esac
15811 ;;
15812 esac
15813 case "$host_os" in
15814 aix* | freebsd* | linux*)
15815 if test -n "$FLOAT_H"; then
15816 REPLACE_FLOAT_LDBL=1
15817 fi
15818 ;;
15819 esac
15820
15821 REPLACE_ITOLD=0
15822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether conversion from 'int' to 'long double' works" >&5
15823 $as_echo_n "checking whether conversion from 'int' to 'long double' works... " >&6; }
15824 if ${gl_cv_func_itold_works+:} false; then :
15825 $as_echo_n "(cached) " >&6
15826 else
15827
15828 if test "$cross_compiling" = yes; then :
15829 case "$host" in
15830 sparc*-*-linux*)
15831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15832 /* end confdefs.h. */
15833 #if defined __LP64__ || defined __arch64__
15834 yes
15835 #endif
15836 _ACEOF
15837 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15838 $EGREP "yes" >/dev/null 2>&1; then :
15839 gl_cv_func_itold_works="guessing no"
15840 else
15841 gl_cv_func_itold_works="guessing yes"
15842 fi
15843 rm -f conftest*
15844
15845 ;;
15846 *) gl_cv_func_itold_works="guessing yes" ;;
15847 esac
15848
15849 else
15850 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15851 /* end confdefs.h. */
15852
15853 int i = -1;
15854 volatile long double ld;
15855 int main ()
15856 {
15857 ld += i * 1.0L;
15858 if (ld > 0)
15859 return 1;
15860 return 0;
15861 }
15862 _ACEOF
15863 if ac_fn_c_try_run "$LINENO"; then :
15864 gl_cv_func_itold_works=yes
15865 else
15866 gl_cv_func_itold_works=no
15867 fi
15868 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15869 conftest.$ac_objext conftest.beam conftest.$ac_ext
15870 fi
15871
15872
15873 fi
15874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_itold_works" >&5
15875 $as_echo "$gl_cv_func_itold_works" >&6; }
15876 case "$gl_cv_func_itold_works" in
15877 *no)
15878 REPLACE_ITOLD=1
15879 FLOAT_H=float.h
15880 ;;
15881 esac
15882
15883 if test -n "$FLOAT_H"; then
15884
15885
15886
15887
15888
15889
15890
15891
15892 if test $gl_cv_have_include_next = yes; then
15893 gl_cv_next_float_h='<'float.h'>'
15894 else
15895 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <float.h>" >&5
15896 $as_echo_n "checking absolute name of <float.h>... " >&6; }
15897 if ${gl_cv_next_float_h+:} false; then :
15898 $as_echo_n "(cached) " >&6
15899 else
15900
15901
15902
15903 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15904 /* end confdefs.h. */
15905 #include <float.h>
15906 _ACEOF
15907 case "$host_os" in
15908 aix*) gl_absname_cpp="$ac_cpp -C" ;;
15909 *) gl_absname_cpp="$ac_cpp" ;;
15910 esac
15911
15912 case "$host_os" in
15913 mingw*)
15914 gl_dirsep_regex='[/\\]'
15915 ;;
15916 *)
15917 gl_dirsep_regex='\/'
15918 ;;
15919 esac
15920 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
15921 gl_header_literal_regex=`echo 'float.h' \
15922 | sed -e "$gl_make_literal_regex_sed"`
15923 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
15924 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
15925 s|^/[^/]|//&|
15926 p
15927 q
15928 }'
15929
15930 gl_cv_absolute_float_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
15931 sed -n "$gl_absolute_header_sed"`
15932
15933 gl_header=$gl_cv_absolute_float_h
15934 gl_cv_next_float_h='"'$gl_header'"'
15935
15936
15937 fi
15938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_float_h" >&5
15939 $as_echo "$gl_cv_next_float_h" >&6; }
15940 fi
15941 NEXT_FLOAT_H=$gl_cv_next_float_h
15942
15943 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
15944 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
15945 gl_next_as_first_directive='<'float.h'>'
15946 else
15947 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
15948 gl_next_as_first_directive=$gl_cv_next_float_h
15949 fi
15950 NEXT_AS_FIRST_DIRECTIVE_FLOAT_H=$gl_next_as_first_directive
15951
15952
15953
15954
15955 fi
15956
15957 if test -n "$FLOAT_H"; then
15958 GL_GENERATE_FLOAT_H_TRUE=
15959 GL_GENERATE_FLOAT_H_FALSE='#'
15960 else
15961 GL_GENERATE_FLOAT_H_TRUE='#'
15962 GL_GENERATE_FLOAT_H_FALSE=
15963 fi
15964
15965
15966
15967 if test $REPLACE_FLOAT_LDBL = 1; then
15968
15969
15970
15971
15972
15973
15974
15975
15976 gl_LIBOBJS="$gl_LIBOBJS float.$ac_objext"
15977
15978 fi
15979 if test $REPLACE_ITOLD = 1; then
15980
15981
15982
15983
15984
15985
15986
15987
15988 gl_LIBOBJS="$gl_LIBOBJS itold.$ac_objext"
15989
15990 fi
15991
15992
15993
15994
15995
15996 FNMATCH_H=
15997 gl_fnmatch_required_lowercase=`
15998 echo $gl_fnmatch_required | LC_ALL=C tr '[A-Z]' '[a-z]'
15999 `
16000 gl_fnmatch_cache_var="gl_cv_func_fnmatch_${gl_fnmatch_required_lowercase}"
16001 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working $gl_fnmatch_required fnmatch" >&5
16002 $as_echo_n "checking for working $gl_fnmatch_required fnmatch... " >&6; }
16003 if eval \${$gl_fnmatch_cache_var+:} false; then :
16004 $as_echo_n "(cached) " >&6
16005 else
16006 if test $gl_fnmatch_required = GNU; then
16007 gl_fnmatch_gnu_start=
16008 gl_fnmatch_gnu_end=
16009 else
16010 gl_fnmatch_gnu_start='#if 0'
16011 gl_fnmatch_gnu_end='#endif'
16012 fi
16013 if test "$cross_compiling" = yes; then :
16014 eval "$gl_fnmatch_cache_var=\"guessing no\""
16015 else
16016 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16017 /* end confdefs.h. */
16018 #include <fnmatch.h>
16019 static int
16020 y (char const *pattern, char const *string, int flags)
16021 {
16022 return fnmatch (pattern, string, flags) == 0;
16023 }
16024 static int
16025 n (char const *pattern, char const *string, int flags)
16026 {
16027 return fnmatch (pattern, string, flags) == FNM_NOMATCH;
16028 }
16029
16030 int
16031 main ()
16032 {
16033 char const *Apat = 'A' < '\\\\' ? "[A-\\\\\\\\]" : "[\\\\\\\\-A]";
16034 char const *apat = 'a' < '\\\\' ? "[a-\\\\\\\\]" : "[\\\\\\\\-a]";
16035 static char const A_1[] = { 'A' - 1, 0 };
16036 static char const A01[] = { 'A' + 1, 0 };
16037 static char const a_1[] = { 'a' - 1, 0 };
16038 static char const a01[] = { 'a' + 1, 0 };
16039 static char const bs_1[] = { '\\\\' - 1, 0 };
16040 static char const bs01[] = { '\\\\' + 1, 0 };
16041 int result = 0;
16042 if (!n ("a*", "", 0))
16043 return 1;
16044 if (!y ("a*", "abc", 0))
16045 return 1;
16046 if (!y ("[/b", "[/b", 0)) /*"]]"*/ /* glibc Bugzilla bug 12378 */
16047 return 1;
16048 if (!n ("d*/*1", "d/s/1", FNM_PATHNAME))
16049 return 2;
16050 if (!y ("a\\\\bc", "abc", 0))
16051 return 3;
16052 if (!n ("a\\\\bc", "abc", FNM_NOESCAPE))
16053 return 3;
16054 if (!y ("*x", ".x", 0))
16055 return 4;
16056 if (!n ("*x", ".x", FNM_PERIOD))
16057 return 4;
16058 if (!y (Apat, "\\\\", 0))
16059 return 5;
16060 if (!y (Apat, "A", 0))
16061 return 5;
16062 if (!y (apat, "\\\\", 0))
16063 return 5;
16064 if (!y (apat, "a", 0))
16065 return 5;
16066 if (!(n (Apat, A_1, 0) == ('A' < '\\\\')))
16067 return 5;
16068 if (!(n (apat, a_1, 0) == ('a' < '\\\\')))
16069 return 5;
16070 if (!(y (Apat, A01, 0) == ('A' < '\\\\')))
16071 return 5;
16072 if (!(y (apat, a01, 0) == ('a' < '\\\\')))
16073 return 5;
16074 if (!(y (Apat, bs_1, 0) == ('A' < '\\\\')))
16075 return 5;
16076 if (!(y (apat, bs_1, 0) == ('a' < '\\\\')))
16077 return 5;
16078 if (!(n (Apat, bs01, 0) == ('A' < '\\\\')))
16079 return 5;
16080 if (!(n (apat, bs01, 0) == ('a' < '\\\\')))
16081 return 5;
16082 $gl_fnmatch_gnu_start
16083 if (!y ("xxXX", "xXxX", FNM_CASEFOLD))
16084 result |= 8;
16085 if (!y ("a++(x|yy)b", "a+xyyyyxb", FNM_EXTMATCH))
16086 result |= 16;
16087 if (!n ("d*/*1", "d/s/1", FNM_FILE_NAME))
16088 result |= 32;
16089 if (!y ("*", "x", FNM_FILE_NAME | FNM_LEADING_DIR))
16090 result |= 64;
16091 if (!y ("x*", "x/y/z", FNM_FILE_NAME | FNM_LEADING_DIR))
16092 result |= 64;
16093 if (!y ("*c*", "c/x", FNM_FILE_NAME | FNM_LEADING_DIR))
16094 result |= 64;
16095 $gl_fnmatch_gnu_end
16096 return result;
16097
16098 ;
16099 return 0;
16100 }
16101 _ACEOF
16102 if ac_fn_c_try_run "$LINENO"; then :
16103 eval "$gl_fnmatch_cache_var=yes"
16104 else
16105 eval "$gl_fnmatch_cache_var=no"
16106 fi
16107 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16108 conftest.$ac_objext conftest.beam conftest.$ac_ext
16109 fi
16110
16111
16112 fi
16113 eval ac_res=\$$gl_fnmatch_cache_var
16114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
16115 $as_echo "$ac_res" >&6; }
16116 eval "gl_fnmatch_result=\"\$$gl_fnmatch_cache_var\""
16117 if test "$gl_fnmatch_result" = yes; then
16118 rm -f "$gl_source_base/fnmatch.h"
16119 else
16120 FNMATCH_H=fnmatch.h
16121 fi
16122
16123 if test -n "$FNMATCH_H"; then
16124 GL_GENERATE_FNMATCH_H_TRUE=
16125 GL_GENERATE_FNMATCH_H_FALSE='#'
16126 else
16127 GL_GENERATE_FNMATCH_H_TRUE='#'
16128 GL_GENERATE_FNMATCH_H_FALSE=
16129 fi
16130
16131
16132 if test -n "$FNMATCH_H"; then
16133
16134
16135
16136
16137
16138
16139
16140
16141 gl_LIBOBJS="$gl_LIBOBJS fnmatch.$ac_objext"
16142
16143
16144
16145 cat >>confdefs.h <<_ACEOF
16146 #define fnmatch ${gl_fnmatch_required_lowercase}_fnmatch
16147 _ACEOF
16148
16149
16150 ac_fn_c_check_decl "$LINENO" "isblank" "ac_cv_have_decl_isblank" "#include <ctype.h>
16151 "
16152 if test "x$ac_cv_have_decl_isblank" = xyes; then :
16153 ac_have_decl=1
16154 else
16155 ac_have_decl=0
16156 fi
16157
16158 cat >>confdefs.h <<_ACEOF
16159 #define HAVE_DECL_ISBLANK $ac_have_decl
16160 _ACEOF
16161
16162
16163 :
16164
16165
16166
16167
16168
16169
16170
16171
16172
16173
16174
16175
16176
16177
16178
16179
16180
16181
16182
16183
16184
16185
16186
16187
16188
16189
16190
16191 :
16192
16193
16194
16195
16196
16197
16198 fi
16199
16200
16201
16202
16203
16204 if test -n "$FNMATCH_H"; then
16205
16206
16207
16208
16209
16210
16211
16212
16213 gl_LIBOBJS="$gl_LIBOBJS fnmatch.$ac_objext"
16214
16215
16216
16217 cat >>confdefs.h <<_ACEOF
16218 #define fnmatch ${gl_fnmatch_required_lowercase}_fnmatch
16219 _ACEOF
16220
16221
16222 ac_fn_c_check_decl "$LINENO" "isblank" "ac_cv_have_decl_isblank" "#include <ctype.h>
16223 "
16224 if test "x$ac_cv_have_decl_isblank" = xyes; then :
16225 ac_have_decl=1
16226 else
16227 ac_have_decl=0
16228 fi
16229
16230 cat >>confdefs.h <<_ACEOF
16231 #define HAVE_DECL_ISBLANK $ac_have_decl
16232 _ACEOF
16233
16234
16235 :
16236
16237
16238
16239
16240
16241
16242
16243
16244
16245
16246
16247
16248
16249
16250
16251
16252
16253
16254
16255
16256
16257
16258
16259
16260
16261
16262
16263 :
16264
16265
16266
16267
16268
16269
16270 fi
16271
16272
16273
16274 FREXP_LIBM=
16275 if test $gl_cv_func_frexp_no_libm = no; then
16276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexp() can be used with libm" >&5
16277 $as_echo_n "checking whether frexp() can be used with libm... " >&6; }
16278 if ${gl_cv_func_frexp_in_libm+:} false; then :
16279 $as_echo_n "(cached) " >&6
16280 else
16281
16282 save_LIBS="$LIBS"
16283 LIBS="$LIBS -lm"
16284 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16285 /* end confdefs.h. */
16286 #include <math.h>
16287 double x;
16288 int
16289 main ()
16290 {
16291 int e; return frexp (x, &e) > 0;
16292 ;
16293 return 0;
16294 }
16295 _ACEOF
16296 if ac_fn_c_try_link "$LINENO"; then :
16297 gl_cv_func_frexp_in_libm=yes
16298 else
16299 gl_cv_func_frexp_in_libm=no
16300 fi
16301 rm -f core conftest.err conftest.$ac_objext \
16302 conftest$ac_exeext conftest.$ac_ext
16303 LIBS="$save_LIBS"
16304
16305 fi
16306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexp_in_libm" >&5
16307 $as_echo "$gl_cv_func_frexp_in_libm" >&6; }
16308 if test $gl_cv_func_frexp_in_libm = yes; then
16309 FREXP_LIBM=-lm
16310 fi
16311 fi
16312 if test $gl_cv_func_frexp_no_libm = yes \
16313 || test $gl_cv_func_frexp_in_libm = yes; then
16314 save_LIBS="$LIBS"
16315 LIBS="$LIBS $FREXP_LIBM"
16316
16317
16318
16319 :
16320
16321
16322
16323
16324
16325 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexp works" >&5
16326 $as_echo_n "checking whether frexp works... " >&6; }
16327 if ${gl_cv_func_frexp_works+:} false; then :
16328 $as_echo_n "(cached) " >&6
16329 else
16330
16331 if test "$cross_compiling" = yes; then :
16332 case "$host_os" in
16333 netbsd* | irix* | mingw*) gl_cv_func_frexp_works="guessing no";;
16334 *) gl_cv_func_frexp_works="guessing yes";;
16335 esac
16336
16337 else
16338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16339 /* end confdefs.h. */
16340
16341 #include <float.h>
16342 #include <math.h>
16343 #include <string.h>
16344 #if HAVE_DECL_ALARM
16345 # include <signal.h>
16346 # include <unistd.h>
16347 #endif
16348 /* HP cc on HP-UX 10.20 has a bug with the constant expression -0.0.
16349 ICC 10.0 has a bug when optimizing the expression -zero.
16350 The expression -DBL_MIN * DBL_MIN does not work when cross-compiling
16351 to PowerPC on Mac OS X 10.5. */
16352 #if defined __hpux || defined __sgi || defined __ICC
16353 static double
16354 compute_minus_zero (void)
16355 {
16356 return -DBL_MIN * DBL_MIN;
16357 }
16358 # define minus_zero compute_minus_zero ()
16359 #else
16360 double minus_zero = -0.0;
16361 #endif
16362 int main()
16363 {
16364 int result = 0;
16365 int i;
16366 volatile double x;
16367 double zero = 0.0;
16368 #if HAVE_DECL_ALARM
16369 /* NeXTstep 3.3 frexp() runs into an endless loop when called on an infinite
16370 number. Let the test fail in this case. */
16371 signal (SIGALRM, SIG_DFL);
16372 alarm (5);
16373 #endif
16374 /* Test on denormalized numbers. */
16375 for (i = 1, x = 1.0; i >= DBL_MIN_EXP; i--, x *= 0.5)
16376 ;
16377 if (x > 0.0)
16378 {
16379 int exp;
16380 double y = frexp (x, &exp);
16381 /* On machines with IEEE754 arithmetic: x = 1.11254e-308, exp = -1022.
16382 On NetBSD: y = 0.75. Correct: y = 0.5. */
16383 if (y != 0.5)
16384 result |= 1;
16385 }
16386 /* Test on infinite numbers. */
16387 x = 1.0 / zero;
16388 {
16389 int exp;
16390 double y = frexp (x, &exp);
16391 if (y != x)
16392 result |= 2;
16393 }
16394 /* Test on negative zero. */
16395 x = minus_zero;
16396 {
16397 int exp;
16398 double y = frexp (x, &exp);
16399 if (memcmp (&y, &x, sizeof x))
16400 result |= 4;
16401 }
16402 return result;
16403 }
16404 _ACEOF
16405 if ac_fn_c_try_run "$LINENO"; then :
16406 gl_cv_func_frexp_works=yes
16407 else
16408 gl_cv_func_frexp_works=no
16409 fi
16410 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16411 conftest.$ac_objext conftest.beam conftest.$ac_ext
16412 fi
16413
16414
16415 fi
16416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexp_works" >&5
16417 $as_echo "$gl_cv_func_frexp_works" >&6; }
16418
16419 LIBS="$save_LIBS"
16420 case "$gl_cv_func_frexp_works" in
16421 *yes) gl_func_frexp=yes ;;
16422 *) gl_func_frexp=no; REPLACE_FREXP=1; FREXP_LIBM= ;;
16423 esac
16424 else
16425 gl_func_frexp=no
16426 fi
16427 if test $gl_func_frexp = yes; then
16428
16429 $as_echo "#define HAVE_FREXP 1" >>confdefs.h
16430
16431 fi
16432
16433
16434 if test $gl_func_frexp != yes; then
16435
16436
16437
16438
16439
16440
16441
16442
16443 gl_LIBOBJS="$gl_LIBOBJS frexp.$ac_objext"
16444
16445 fi
16446
16447
16448
16449
16450
16451 GNULIB_FREXP=1
16452
16453
16454
16455
16456
16457 $as_echo "#define GNULIB_TEST_FREXP 1" >>confdefs.h
16458
16459
16460
16461
16462
16463
16464
16465
16466
16467 ac_fn_c_check_decl "$LINENO" "frexpl" "ac_cv_have_decl_frexpl" "#include <math.h>
16468 "
16469 if test "x$ac_cv_have_decl_frexpl" = xyes; then :
16470
16471 else
16472 HAVE_DECL_FREXPL=0
16473 fi
16474
16475
16476 FREXPL_LIBM=
16477 if test $HAVE_DECL_FREXPL = 1; then
16478
16479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexpl() can be used without linking with libm" >&5
16480 $as_echo_n "checking whether frexpl() can be used without linking with libm... " >&6; }
16481 if ${gl_cv_func_frexpl_no_libm+:} false; then :
16482 $as_echo_n "(cached) " >&6
16483 else
16484
16485 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16486 /* end confdefs.h. */
16487 #include <math.h>
16488 long double x;
16489 int
16490 main ()
16491 {
16492 int e; return frexpl (x, &e) > 0;
16493 ;
16494 return 0;
16495 }
16496 _ACEOF
16497 if ac_fn_c_try_link "$LINENO"; then :
16498 gl_cv_func_frexpl_no_libm=yes
16499 else
16500 gl_cv_func_frexpl_no_libm=no
16501 fi
16502 rm -f core conftest.err conftest.$ac_objext \
16503 conftest$ac_exeext conftest.$ac_ext
16504
16505 fi
16506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexpl_no_libm" >&5
16507 $as_echo "$gl_cv_func_frexpl_no_libm" >&6; }
16508
16509 if test $gl_cv_func_frexpl_no_libm = no; then
16510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexpl() can be used with libm" >&5
16511 $as_echo_n "checking whether frexpl() can be used with libm... " >&6; }
16512 if ${gl_cv_func_frexpl_in_libm+:} false; then :
16513 $as_echo_n "(cached) " >&6
16514 else
16515
16516 save_LIBS="$LIBS"
16517 LIBS="$LIBS -lm"
16518 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16519 /* end confdefs.h. */
16520 #include <math.h>
16521 long double x;
16522 int
16523 main ()
16524 {
16525 int e; return frexpl (x, &e) > 0;
16526 ;
16527 return 0;
16528 }
16529 _ACEOF
16530 if ac_fn_c_try_link "$LINENO"; then :
16531 gl_cv_func_frexpl_in_libm=yes
16532 else
16533 gl_cv_func_frexpl_in_libm=no
16534 fi
16535 rm -f core conftest.err conftest.$ac_objext \
16536 conftest$ac_exeext conftest.$ac_ext
16537 LIBS="$save_LIBS"
16538
16539 fi
16540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexpl_in_libm" >&5
16541 $as_echo "$gl_cv_func_frexpl_in_libm" >&6; }
16542 if test $gl_cv_func_frexpl_in_libm = yes; then
16543 FREXPL_LIBM=-lm
16544 fi
16545 fi
16546 if test $gl_cv_func_frexpl_no_libm = yes \
16547 || test $gl_cv_func_frexpl_in_libm = yes; then
16548 save_LIBS="$LIBS"
16549 LIBS="$LIBS $FREXPL_LIBM"
16550
16551
16552 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether frexpl works" >&5
16553 $as_echo_n "checking whether frexpl works... " >&6; }
16554 if ${gl_cv_func_frexpl_works+:} false; then :
16555 $as_echo_n "(cached) " >&6
16556 else
16557
16558 if test "$cross_compiling" = yes; then :
16559
16560 case "$host_os" in
16561 aix | aix[3-6]* | beos* | darwin* | irix* | mingw* | pw*)
16562 gl_cv_func_frexpl_works="guessing no";;
16563 *) gl_cv_func_frexpl_works="guessing yes";;
16564 esac
16565
16566 else
16567 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16568 /* end confdefs.h. */
16569
16570 #include <float.h>
16571 #include <math.h>
16572 /* Override the values of <float.h>, like done in float.in.h. */
16573 #if defined __i386__ && (defined __BEOS__ || defined __OpenBSD__)
16574 # undef LDBL_MIN_EXP
16575 # define LDBL_MIN_EXP (-16381)
16576 #endif
16577 #if defined __i386__ && defined __FreeBSD__
16578 # undef LDBL_MIN_EXP
16579 # define LDBL_MIN_EXP (-16381)
16580 #endif
16581 #if (defined _ARCH_PPC || defined _POWER) && defined _AIX && (LDBL_MANT_DIG == 106) && defined __GNUC__
16582 # undef LDBL_MIN_EXP
16583 # define LDBL_MIN_EXP DBL_MIN_EXP
16584 #endif
16585 #if defined __sgi && (LDBL_MANT_DIG >= 106)
16586 # if defined __GNUC__
16587 # undef LDBL_MIN_EXP
16588 # define LDBL_MIN_EXP DBL_MIN_EXP
16589 # endif
16590 #endif
16591 extern
16592 #ifdef __cplusplus
16593 "C"
16594 #endif
16595 long double frexpl (long double, int *);
16596 int main()
16597 {
16598 int result = 0;
16599 volatile long double x;
16600 /* Test on finite numbers that fails on AIX 5.1. */
16601 x = 16.0L;
16602 {
16603 int exp = -9999;
16604 frexpl (x, &exp);
16605 if (exp != 5)
16606 result |= 1;
16607 }
16608 /* Test on finite numbers that fails on Mac OS X 10.4, because its frexpl
16609 function returns an invalid (incorrectly normalized) value: it returns
16610 y = { 0x3fe028f5, 0xc28f5c28, 0x3c9eb851, 0xeb851eb8 }
16611 but the correct result is
16612 0.505L = { 0x3fe028f5, 0xc28f5c29, 0xbc547ae1, 0x47ae1480 } */
16613 x = 1.01L;
16614 {
16615 int exp = -9999;
16616 long double y = frexpl (x, &exp);
16617 if (!(exp == 1 && y == 0.505L))
16618 result |= 2;
16619 }
16620 /* Test on large finite numbers. This fails on BeOS at i = 16322, while
16621 LDBL_MAX_EXP = 16384.
16622 In the loop end test, we test x against Infinity, rather than comparing
16623 i with LDBL_MAX_EXP, because BeOS <float.h> has a wrong LDBL_MAX_EXP. */
16624 {
16625 int i;
16626 for (i = 1, x = 1.0L; x != x + x; i++, x *= 2.0L)
16627 {
16628 int exp = -9999;
16629 frexpl (x, &exp);
16630 if (exp != i)
16631 {
16632 result |= 4;
16633 break;
16634 }
16635 }
16636 }
16637 /* Test on denormalized numbers. */
16638 {
16639 int i;
16640 for (i = 1, x = 1.0L; i >= LDBL_MIN_EXP; i--, x *= 0.5L)
16641 ;
16642 if (x > 0.0L)
16643 {
16644 int exp;
16645 long double y = frexpl (x, &exp);
16646 /* On machines with IEEE854 arithmetic: x = 1.68105e-4932,
16647 exp = -16382, y = 0.5. On Mac OS X 10.5: exp = -16384, y = 0.5. */
16648 if (exp != LDBL_MIN_EXP - 1)
16649 result |= 8;
16650 }
16651 }
16652 /* Test on infinite numbers. */
16653 x = 1.0L / 0.0L;
16654 {
16655 int exp;
16656 long double y = frexpl (x, &exp);
16657 if (y != x)
16658 result |= 16;
16659 }
16660 return result;
16661 }
16662 _ACEOF
16663 if ac_fn_c_try_run "$LINENO"; then :
16664 gl_cv_func_frexpl_works=yes
16665 else
16666 gl_cv_func_frexpl_works=no
16667 fi
16668 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16669 conftest.$ac_objext conftest.beam conftest.$ac_ext
16670 fi
16671
16672
16673 fi
16674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_frexpl_works" >&5
16675 $as_echo "$gl_cv_func_frexpl_works" >&6; }
16676
16677 LIBS="$save_LIBS"
16678 case "$gl_cv_func_frexpl_works" in
16679 *yes) gl_func_frexpl=yes ;;
16680 *) gl_func_frexpl=no; REPLACE_FREXPL=1 ;;
16681 esac
16682 else
16683 gl_func_frexpl=no
16684 fi
16685 if test $gl_func_frexpl = yes; then
16686
16687 $as_echo "#define HAVE_FREXPL 1" >>confdefs.h
16688
16689 fi
16690 fi
16691 if test $HAVE_DECL_FREXPL = 0 || test $gl_func_frexpl = no; then
16692 if test $HAVE_SAME_LONG_DOUBLE_AS_DOUBLE = 1; then
16693
16694 FREXPL_LIBM="$FREXP_LIBM"
16695 else
16696 FREXPL_LIBM=
16697 fi
16698 fi
16699
16700
16701 if test $HAVE_DECL_FREXPL = 0 || test $gl_func_frexpl = no; then
16702
16703
16704
16705
16706
16707
16708
16709
16710 gl_LIBOBJS="$gl_LIBOBJS frexpl.$ac_objext"
16711
16712 fi
16713
16714
16715
16716
16717
16718 GNULIB_FREXPL=1
16719
16720
16721
16722
16723
16724 $as_echo "#define GNULIB_TEST_FREXPL 1" >>confdefs.h
16725
16726
16727
16728
16729
16730
16731
16732 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
16733 REPLACE_FSTAT=1
16734 fi
16735
16736
16737 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
16738 REPLACE_FSTAT=1
16739 fi
16740
16741
16742
16743
16744
16745 :
16746
16747
16748
16749
16750
16751 if test $ac_cv_func_fchdir = no; then
16752 HAVE_FCHDIR=0
16753 fi
16754
16755 if test $HAVE_FCHDIR = 0; then
16756 case "$gl_cv_func_open_directory_works" in
16757 *yes) ;;
16758 *)
16759 REPLACE_FSTAT=1
16760 ;;
16761 esac
16762 fi
16763
16764
16765 if test $REPLACE_FSTAT = 1; then
16766
16767
16768
16769
16770
16771
16772
16773
16774 gl_LIBOBJS="$gl_LIBOBJS fstat.$ac_objext"
16775
16776 :
16777 fi
16778
16779
16780
16781
16782
16783 GNULIB_FSTAT=1
16784
16785
16786
16787
16788
16789 $as_echo "#define GNULIB_TEST_FSTAT 1" >>confdefs.h
16790
16791
16792
16793
16794
16795
16796
16797
16798 :
16799
16800
16801
16802
16803
16804
16805 if test $ac_cv_func_fstatat = no; then
16806 HAVE_FSTATAT=0
16807 else
16808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fstatat (..., 0) works" >&5
16809 $as_echo_n "checking whether fstatat (..., 0) works... " >&6; }
16810 if ${gl_cv_func_fstatat_zero_flag+:} false; then :
16811 $as_echo_n "(cached) " >&6
16812 else
16813 if test "$cross_compiling" = yes; then :
16814 case "$host_os" in
16815 aix*) gl_cv_func_fstatat_zero_flag="guessing no";;
16816 *) gl_cv_func_fstatat_zero_flag="guessing yes";;
16817 esac
16818
16819 else
16820 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16821 /* end confdefs.h. */
16822
16823 #include <fcntl.h>
16824 #include <sys/stat.h>
16825 int
16826 main (void)
16827 {
16828 struct stat a;
16829 return fstatat (AT_FDCWD, ".", &a, 0) != 0;
16830 }
16831
16832 _ACEOF
16833 if ac_fn_c_try_run "$LINENO"; then :
16834 gl_cv_func_fstatat_zero_flag=yes
16835 else
16836 gl_cv_func_fstatat_zero_flag=no
16837 fi
16838 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16839 conftest.$ac_objext conftest.beam conftest.$ac_ext
16840 fi
16841
16842
16843 fi
16844 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fstatat_zero_flag" >&5
16845 $as_echo "$gl_cv_func_fstatat_zero_flag" >&6; }
16846
16847 case $gl_cv_func_fstatat_zero_flag+$gl_cv_func_lstat_dereferences_slashed_symlink in
16848 *yes+*yes) ;;
16849 *) REPLACE_FSTATAT=1
16850 case $gl_cv_func_fstatat_zero_flag in
16851 *yes)
16852
16853 $as_echo "#define HAVE_WORKING_FSTATAT_ZERO_FLAG 1" >>confdefs.h
16854
16855 ;;
16856 esac
16857 ;;
16858 esac
16859 fi
16860
16861 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
16862
16863
16864
16865
16866
16867
16868
16869
16870 gl_LIBOBJS="$gl_LIBOBJS fstatat.$ac_objext"
16871
16872 fi
16873
16874
16875
16876
16877
16878 GNULIB_FSTATAT=1
16879
16880
16881
16882
16883
16884 $as_echo "#define GNULIB_TEST_FSTATAT 1" >>confdefs.h
16885
16886
16887
16888
16889
16890
16891
16892
16893 gl_abort_bug=no
16894 case "$host_os" in
16895 mingw*)
16896 gl_cv_func_getcwd_path_max=yes
16897 ;;
16898 *)
16899
16900
16901 :
16902
16903
16904
16905
16906
16907
16908
16909 :
16910
16911
16912
16913
16914
16915
16916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getcwd handles long file names properly" >&5
16917 $as_echo_n "checking whether getcwd handles long file names properly... " >&6; }
16918 if ${gl_cv_func_getcwd_path_max+:} false; then :
16919 $as_echo_n "(cached) " >&6
16920 else
16921 # Arrange for deletion of the temporary directory this test creates.
16922 ac_clean_files="$ac_clean_files confdir3"
16923 if test "$cross_compiling" = yes; then :
16924 case "$host_os" in
16925 aix*) gl_cv_func_getcwd_path_max='no, it has the AIX bug';;
16926 *) gl_cv_func_getcwd_path_max=no;;
16927 esac
16928 else
16929 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16930 /* end confdefs.h. */
16931
16932 #include <errno.h>
16933 #include <stdlib.h>
16934 #if HAVE_UNISTD_H
16935 # include <unistd.h>
16936 #else
16937 # include <direct.h>
16938 #endif
16939 #include <string.h>
16940 #include <limits.h>
16941 #include <sys/stat.h>
16942 #include <sys/types.h>
16943 #include <fcntl.h>
16944
16945
16946 /* Arrange to define PATH_MAX, like "pathmax.h" does. */
16947 #if HAVE_UNISTD_H
16948 # include <unistd.h>
16949 #endif
16950 #include <limits.h>
16951 #if defined HAVE_SYS_PARAM_H && !defined PATH_MAX && !defined MAXPATHLEN
16952 # include <sys/param.h>
16953 #endif
16954 #if !defined PATH_MAX && defined MAXPATHLEN
16955 # define PATH_MAX MAXPATHLEN
16956 #endif
16957 #ifdef __hpux
16958 # undef PATH_MAX
16959 # define PATH_MAX 1024
16960 #endif
16961 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
16962 # undef PATH_MAX
16963 # define PATH_MAX 260
16964 #endif
16965
16966
16967 #ifndef AT_FDCWD
16968 # define AT_FDCWD 0
16969 #endif
16970 #ifdef ENAMETOOLONG
16971 # define is_ENAMETOOLONG(x) ((x) == ENAMETOOLONG)
16972 #else
16973 # define is_ENAMETOOLONG(x) 0
16974 #endif
16975
16976 /* Use the getcwd function, not any macro. */
16977 #undef getcwd
16978
16979 /* Don't get link errors because mkdir is redefined to rpl_mkdir. */
16980 #undef mkdir
16981
16982 #ifndef S_IRWXU
16983 # define S_IRWXU 0700
16984 #endif
16985
16986 /* The length of this name must be 8. */
16987 #define DIR_NAME "confdir3"
16988 #define DIR_NAME_LEN 8
16989 #define DIR_NAME_SIZE (DIR_NAME_LEN + 1)
16990
16991 /* The length of "../". */
16992 #define DOTDOTSLASH_LEN 3
16993
16994 /* Leftover bytes in the buffer, to work around library or OS bugs. */
16995 #define BUF_SLOP 20
16996
16997 int
16998 main ()
16999 {
17000 #ifndef PATH_MAX
17001 /* The Hurd doesn't define this, so getcwd can't exhibit the bug --
17002 at least not on a local file system. And if we were to start worrying
17003 about remote file systems, we'd have to enable the wrapper function
17004 all of the time, just to be safe. That's not worth the cost. */
17005 exit (0);
17006 #elif ((INT_MAX / (DIR_NAME_SIZE / DOTDOTSLASH_LEN + 1) \
17007 - DIR_NAME_SIZE - BUF_SLOP) \
17008 <= PATH_MAX)
17009 /* FIXME: Assuming there's a system for which this is true,
17010 this should be done in a compile test. */
17011 exit (0);
17012 #else
17013 char buf[PATH_MAX * (DIR_NAME_SIZE / DOTDOTSLASH_LEN + 1)
17014 + DIR_NAME_SIZE + BUF_SLOP];
17015 char *cwd = getcwd (buf, PATH_MAX);
17016 size_t initial_cwd_len;
17017 size_t cwd_len;
17018 int fail = 0;
17019 size_t n_chdirs = 0;
17020
17021 if (cwd == NULL)
17022 exit (10);
17023
17024 cwd_len = initial_cwd_len = strlen (cwd);
17025
17026 while (1)
17027 {
17028 size_t dotdot_max = PATH_MAX * (DIR_NAME_SIZE / DOTDOTSLASH_LEN);
17029 char *c = NULL;
17030
17031 cwd_len += DIR_NAME_SIZE;
17032 /* If mkdir or chdir fails, it could be that this system cannot create
17033 any file with an absolute name longer than PATH_MAX, such as cygwin.
17034 If so, leave fail as 0, because the current working directory can't
17035 be too long for getcwd if it can't even be created. For other
17036 errors, be pessimistic and consider that as a failure, too. */
17037 if (mkdir (DIR_NAME, S_IRWXU) < 0 || chdir (DIR_NAME) < 0)
17038 {
17039 if (! (errno == ERANGE || is_ENAMETOOLONG (errno)))
17040 fail = 20;
17041 break;
17042 }
17043
17044 if (PATH_MAX <= cwd_len && cwd_len < PATH_MAX + DIR_NAME_SIZE)
17045 {
17046 struct stat sb;
17047
17048 c = getcwd (buf, PATH_MAX);
17049 if (!c && errno == ENOENT)
17050 {
17051 fail = 11;
17052 break;
17053 }
17054 if (c)
17055 {
17056 fail = 31;
17057 break;
17058 }
17059 if (! (errno == ERANGE || is_ENAMETOOLONG (errno)))
17060 {
17061 fail = 21;
17062 break;
17063 }
17064
17065 /* Our replacement needs to be able to stat() long ../../paths,
17066 so generate a path larger than PATH_MAX to check,
17067 avoiding the replacement if we can't stat(). */
17068 c = getcwd (buf, cwd_len + 1);
17069 if (c && !AT_FDCWD && stat (c, &sb) != 0 && is_ENAMETOOLONG (errno))
17070 {
17071 fail = 32;
17072 break;
17073 }
17074 }
17075
17076 if (dotdot_max <= cwd_len - initial_cwd_len)
17077 {
17078 if (dotdot_max + DIR_NAME_SIZE < cwd_len - initial_cwd_len)
17079 break;
17080 c = getcwd (buf, cwd_len + 1);
17081 if (!c)
17082 {
17083 if (! (errno == ERANGE || errno == ENOENT
17084 || is_ENAMETOOLONG (errno)))
17085 {
17086 fail = 22;
17087 break;
17088 }
17089 if (AT_FDCWD || errno == ERANGE || errno == ENOENT)
17090 {
17091 fail = 12;
17092 break;
17093 }
17094 }
17095 }
17096
17097 if (c && strlen (c) != cwd_len)
17098 {
17099 fail = 23;
17100 break;
17101 }
17102 ++n_chdirs;
17103 }
17104
17105 /* Leaving behind such a deep directory is not polite.
17106 So clean up here, right away, even though the driving
17107 shell script would also clean up. */
17108 {
17109 size_t i;
17110
17111 /* Try rmdir first, in case the chdir failed. */
17112 rmdir (DIR_NAME);
17113 for (i = 0; i <= n_chdirs; i++)
17114 {
17115 if (chdir ("..") < 0)
17116 break;
17117 if (rmdir (DIR_NAME) != 0)
17118 break;
17119 }
17120 }
17121
17122 exit (fail);
17123 #endif
17124 }
17125
17126 _ACEOF
17127 if ac_fn_c_try_run "$LINENO"; then :
17128 gl_cv_func_getcwd_path_max=yes
17129 else
17130 case $? in
17131 10|11|12) gl_cv_func_getcwd_path_max='no, but it is partly working';;
17132 31) gl_cv_func_getcwd_path_max='no, it has the AIX bug';;
17133 32) gl_cv_func_getcwd_path_max='yes, but with shorter paths';;
17134 *) gl_cv_func_getcwd_path_max=no;;
17135 esac
17136 fi
17137 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17138 conftest.$ac_objext conftest.beam conftest.$ac_ext
17139 fi
17140
17141
17142 fi
17143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_path_max" >&5
17144 $as_echo "$gl_cv_func_getcwd_path_max" >&6; }
17145
17146 case "$gl_cv_func_getcwd_null" in
17147 *yes)
17148
17149
17150 :
17151
17152
17153
17154
17155
17156
17157 :
17158
17159
17160
17161
17162
17163
17164 for ac_func in getpagesize
17165 do :
17166 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
17167 if test "x$ac_cv_func_getpagesize" = xyes; then :
17168 cat >>confdefs.h <<_ACEOF
17169 #define HAVE_GETPAGESIZE 1
17170 _ACEOF
17171
17172 fi
17173 done
17174
17175 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getcwd aborts when 4k < cwd_length < 16k" >&5
17176 $as_echo_n "checking whether getcwd aborts when 4k < cwd_length < 16k... " >&6; }
17177 if ${gl_cv_func_getcwd_abort_bug+:} false; then :
17178 $as_echo_n "(cached) " >&6
17179 else
17180 # Remove any remnants of a previous test.
17181 rm -rf confdir-14B---
17182 # Arrange for deletion of the temporary directory this test creates.
17183 ac_clean_files="$ac_clean_files confdir-14B---"
17184 if test "$cross_compiling" = yes; then :
17185 gl_cv_func_getcwd_abort_bug=yes
17186 else
17187 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17188 /* end confdefs.h. */
17189
17190 #include <errno.h>
17191 #include <stdlib.h>
17192 #if HAVE_UNISTD_H
17193 # include <unistd.h>
17194 #else /* on Windows with MSVC */
17195 # include <direct.h>
17196 #endif
17197 #include <string.h>
17198 #include <sys/stat.h>
17199
17200
17201 /* Arrange to define PATH_MAX, like "pathmax.h" does. */
17202 #if HAVE_UNISTD_H
17203 # include <unistd.h>
17204 #endif
17205 #include <limits.h>
17206 #if defined HAVE_SYS_PARAM_H && !defined PATH_MAX && !defined MAXPATHLEN
17207 # include <sys/param.h>
17208 #endif
17209 #if !defined PATH_MAX && defined MAXPATHLEN
17210 # define PATH_MAX MAXPATHLEN
17211 #endif
17212 #ifdef __hpux
17213 # undef PATH_MAX
17214 # define PATH_MAX 1024
17215 #endif
17216 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
17217 # undef PATH_MAX
17218 # define PATH_MAX 260
17219 #endif
17220
17221
17222 /* Don't get link errors because mkdir is redefined to rpl_mkdir. */
17223 #undef mkdir
17224
17225 #ifndef S_IRWXU
17226 # define S_IRWXU 0700
17227 #endif
17228
17229 /* FIXME: skip the run-test altogether on systems without getpagesize. */
17230 #if ! HAVE_GETPAGESIZE
17231 # define getpagesize() 0
17232 #endif
17233
17234 /* This size is chosen to be larger than PATH_MAX (4k), yet smaller than
17235 the 16kB pagesize on ia64 linux. Those conditions make the code below
17236 trigger a bug in glibc's getcwd implementation before 2.4.90-10. */
17237 #define TARGET_LEN (5 * 1024)
17238
17239 int
17240 main ()
17241 {
17242 char *cwd;
17243 size_t initial_cwd_len;
17244 int fail = 0;
17245
17246 /* The bug is triggered when PATH_MAX < getpagesize (), so skip
17247 this relatively expensive and invasive test if that's not true. */
17248 #ifdef PATH_MAX
17249 int bug_possible = PATH_MAX < getpagesize ();
17250 #else
17251 int bug_possible = 0;
17252 #endif
17253 if (! bug_possible)
17254 return 0;
17255
17256 cwd = getcwd (NULL, 0);
17257 if (cwd == NULL)
17258 return 2;
17259
17260 initial_cwd_len = strlen (cwd);
17261 free (cwd);
17262
17263 if (1)
17264 {
17265 static char const dir_name[] = "confdir-14B---";
17266 size_t desired_depth = ((TARGET_LEN - 1 - initial_cwd_len)
17267 / sizeof dir_name);
17268 size_t d;
17269 for (d = 0; d < desired_depth; d++)
17270 {
17271 if (mkdir (dir_name, S_IRWXU) < 0 || chdir (dir_name) < 0)
17272 {
17273 if (! (errno == ERANGE || errno == ENAMETOOLONG
17274 || errno == ENOENT))
17275 fail = 3; /* Unable to construct deep hierarchy. */
17276 break;
17277 }
17278 }
17279
17280 /* If libc has the bug in question, this invocation of getcwd
17281 results in a failed assertion. */
17282 cwd = getcwd (NULL, 0);
17283 if (cwd == NULL)
17284 fail = 4; /* getcwd didn't assert, but it failed for a long name
17285 where the answer could have been learned. */
17286 free (cwd);
17287
17288 /* Call rmdir first, in case the above chdir failed. */
17289 rmdir (dir_name);
17290 while (0 < d--)
17291 {
17292 if (chdir ("..") < 0)
17293 {
17294 fail = 5;
17295 break;
17296 }
17297 rmdir (dir_name);
17298 }
17299 }
17300
17301 return fail;
17302 }
17303
17304 _ACEOF
17305 if ac_fn_c_try_run "$LINENO"; then :
17306 gl_cv_func_getcwd_abort_bug=no
17307 else
17308 ret=$?
17309 if test $ret -ge 128 || test $ret = 4; then
17310 gl_cv_func_getcwd_abort_bug=yes
17311 else
17312 gl_cv_func_getcwd_abort_bug=no
17313 fi
17314 fi
17315 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17316 conftest.$ac_objext conftest.beam conftest.$ac_ext
17317 fi
17318
17319
17320 fi
17321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_abort_bug" >&5
17322 $as_echo "$gl_cv_func_getcwd_abort_bug" >&6; }
17323 if test $gl_cv_func_getcwd_abort_bug = yes; then :
17324 gl_abort_bug=yes
17325 fi
17326
17327 ;;
17328 esac
17329 ;;
17330 esac
17331 case "$gl_cv_func_getcwd_path_max" in
17332 "no"|"no, it has the AIX bug") ;;
17333 *)
17334
17335 $as_echo "#define HAVE_MINIMALLY_WORKING_GETCWD 1" >>confdefs.h
17336
17337 ;;
17338 esac
17339 case "$gl_cv_func_getcwd_path_max" in
17340 "no, but it is partly working")
17341
17342 $as_echo "#define HAVE_PARTLY_WORKING_GETCWD 1" >>confdefs.h
17343
17344 ;;
17345 "yes, but with shorter paths")
17346
17347 $as_echo "#define HAVE_GETCWD_SHORTER 1" >>confdefs.h
17348
17349 ;;
17350 esac
17351
17352 if { case "$gl_cv_func_getcwd_null" in *yes) false;; *) true;; esac; } \
17353 || test $gl_cv_func_getcwd_posix_signature != yes \
17354 || { case "$gl_cv_func_getcwd_path_max" in *yes*) false;; *) true;; esac; } \
17355 || test $gl_abort_bug = yes; then
17356 REPLACE_GETCWD=1
17357 fi
17358
17359 if test $REPLACE_GETCWD = 1; then
17360
17361
17362
17363
17364
17365
17366
17367
17368 gl_LIBOBJS="$gl_LIBOBJS getcwd.$ac_objext"
17369
17370
17371
17372
17373 :
17374
17375 fi
17376
17377
17378 cat >>confdefs.h <<_ACEOF
17379 #define GNULIB_GETCWD 1
17380 _ACEOF
17381
17382
17383
17384
17385
17386
17387
17388 GNULIB_GETCWD=1
17389
17390
17391
17392
17393
17394 $as_echo "#define GNULIB_TEST_GETCWD 1" >>confdefs.h
17395
17396
17397
17398
17399
17400
17401
17402
17403 case $gl_cv_func_getcwd_null,$gl_cv_func_getcwd_posix_signature in
17404 *yes,yes) ;;
17405 *)
17406 REPLACE_GETCWD=1
17407 ;;
17408 esac
17409
17410 if test $REPLACE_GETCWD = 1; then
17411
17412
17413
17414
17415
17416
17417
17418
17419 gl_LIBOBJS="$gl_LIBOBJS getcwd-lgpl.$ac_objext"
17420
17421 fi
17422
17423
17424
17425
17426
17427 GNULIB_GETCWD=1
17428
17429
17430
17431
17432
17433 $as_echo "#define GNULIB_TEST_GETCWD 1" >>confdefs.h
17434
17435
17436
17437
17438
17439
17440
17441 :
17442
17443
17444
17445
17446
17447
17448 :
17449
17450
17451
17452
17453
17454 if test $ac_cv_func_getdtablesize = yes &&
17455 test $ac_cv_have_decl_getdtablesize = yes; then
17456 # Cygwin 1.7.25 automatically increases the RLIMIT_NOFILE soft limit
17457 # up to an unchangeable hard limit; all other platforms correctly
17458 # require setrlimit before getdtablesize() can report a larger value.
17459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getdtablesize works" >&5
17460 $as_echo_n "checking whether getdtablesize works... " >&6; }
17461 if ${gl_cv_func_getdtablesize_works+:} false; then :
17462 $as_echo_n "(cached) " >&6
17463 else
17464 if test "$cross_compiling" = yes; then :
17465 case "$host_os" in
17466 cygwin*) # on cygwin 1.5.25, getdtablesize() automatically grows
17467 gl_cv_func_getdtablesize_works="guessing no" ;;
17468 *) gl_cv_func_getdtablesize_works="guessing yes" ;;
17469 esac
17470 else
17471 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17472 /* end confdefs.h. */
17473
17474 #include <unistd.h>
17475 int
17476 main ()
17477 {
17478 int size = getdtablesize();
17479 if (dup2 (0, getdtablesize()) != -1)
17480 return 1;
17481 if (size != getdtablesize())
17482 return 2;
17483
17484 ;
17485 return 0;
17486 }
17487 _ACEOF
17488 if ac_fn_c_try_run "$LINENO"; then :
17489 gl_cv_func_getdtablesize_works=yes
17490 else
17491 gl_cv_func_getdtablesize_works=no
17492 fi
17493 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17494 conftest.$ac_objext conftest.beam conftest.$ac_ext
17495 fi
17496
17497
17498 fi
17499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getdtablesize_works" >&5
17500 $as_echo "$gl_cv_func_getdtablesize_works" >&6; }
17501 case "$gl_cv_func_getdtablesize_works" in
17502 *yes) ;;
17503 *) REPLACE_GETDTABLESIZE=1 ;;
17504 esac
17505 else
17506 HAVE_GETDTABLESIZE=0
17507 fi
17508
17509 if test $HAVE_GETDTABLESIZE = 0 || test $REPLACE_GETDTABLESIZE = 1; then
17510
17511
17512
17513
17514
17515
17516
17517
17518 gl_LIBOBJS="$gl_LIBOBJS getdtablesize.$ac_objext"
17519
17520 :
17521 fi
17522
17523
17524
17525
17526
17527 GNULIB_GETDTABLESIZE=1
17528
17529
17530
17531
17532
17533 $as_echo "#define GNULIB_TEST_GETDTABLESIZE 1" >>confdefs.h
17534
17535
17536
17537
17538
17539
17540
17541
17542
17543 :
17544
17545
17546
17547
17548
17549 if test $ac_cv_have_decl_getlogin_r = no; then
17550 HAVE_DECL_GETLOGIN_R=0
17551 fi
17552
17553
17554 :
17555
17556
17557
17558
17559
17560 if test $ac_cv_func_getlogin_r = no; then
17561 HAVE_GETLOGIN_R=0
17562 else
17563 HAVE_GETLOGIN_R=1
17564
17565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getlogin_r works with small buffers" >&5
17566 $as_echo_n "checking whether getlogin_r works with small buffers... " >&6; }
17567 if ${gl_cv_func_getlogin_r_works+:} false; then :
17568 $as_echo_n "(cached) " >&6
17569 else
17570
17571 case "$host_os" in
17572 # Guess no on OSF/1.
17573 osf*) gl_cv_func_getlogin_r_works="guessing no" ;;
17574 # Guess yes otherwise.
17575 *) gl_cv_func_getlogin_r_works="guessing yes" ;;
17576 esac
17577 if test "$cross_compiling" = yes; then :
17578 :
17579 else
17580 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17581 /* end confdefs.h. */
17582
17583 #include <stddef.h>
17584 #include <unistd.h>
17585 #if !HAVE_DECL_GETLOGIN_R
17586 extern
17587 # ifdef __cplusplus
17588 "C"
17589 # endif
17590 int getlogin_r (char *, size_t);
17591 #endif
17592 int
17593 main (void)
17594 {
17595 int result = 0;
17596 char buf[100];
17597
17598 if (getlogin_r (buf, 0) == 0)
17599 result |= 16;
17600 if (getlogin_r (buf, 1) == 0)
17601 result |= 17;
17602 return result;
17603 }
17604 _ACEOF
17605 if ac_fn_c_try_run "$LINENO"; then :
17606 gl_cv_func_getlogin_r_works=yes
17607 else
17608 case $? in
17609 16 | 17) gl_cv_func_getlogin_r_works=no ;;
17610 esac
17611
17612 fi
17613 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17614 conftest.$ac_objext conftest.beam conftest.$ac_ext
17615 fi
17616
17617
17618 fi
17619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getlogin_r_works" >&5
17620 $as_echo "$gl_cv_func_getlogin_r_works" >&6; }
17621 case "$gl_cv_func_getlogin_r_works" in
17622 *yes) ;;
17623 *) REPLACE_GETLOGIN_R=1 ;;
17624 esac
17625 fi
17626
17627 if test $HAVE_GETLOGIN_R = 0 || test $REPLACE_GETLOGIN_R = 1; then
17628
17629
17630
17631
17632
17633
17634
17635
17636 gl_LIBOBJS="$gl_LIBOBJS getlogin_r.$ac_objext"
17637
17638
17639
17640 :
17641
17642
17643
17644
17645
17646
17647 fi
17648
17649
17650
17651
17652
17653 GNULIB_GETLOGIN_R=1
17654
17655
17656
17657
17658
17659 $as_echo "#define GNULIB_TEST_GETLOGIN_R 1" >>confdefs.h
17660
17661
17662
17663
17664
17665 :
17666
17667
17668
17669
17670
17671
17672
17673
17674
17675 ac_found=0
17676 ac_fn_c_check_decl "$LINENO" "program_invocation_name" "ac_cv_have_decl_program_invocation_name" "#include <errno.h>
17677 "
17678 if test "x$ac_cv_have_decl_program_invocation_name" = xyes; then :
17679 ac_have_decl=1
17680 else
17681 ac_have_decl=0
17682 fi
17683
17684 cat >>confdefs.h <<_ACEOF
17685 #define HAVE_DECL_PROGRAM_INVOCATION_NAME $ac_have_decl
17686 _ACEOF
17687 if test $ac_have_decl = 1; then :
17688 ac_found=1
17689 fi
17690
17691 ac_fn_c_check_decl "$LINENO" "program_invocation_short_name" "ac_cv_have_decl_program_invocation_short_name" "#include <errno.h>
17692 "
17693 if test "x$ac_cv_have_decl_program_invocation_short_name" = xyes; then :
17694 ac_have_decl=1
17695 else
17696 ac_have_decl=0
17697 fi
17698
17699 cat >>confdefs.h <<_ACEOF
17700 #define HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME $ac_have_decl
17701 _ACEOF
17702 if test $ac_have_decl = 1; then :
17703 ac_found=1
17704 fi
17705
17706 ac_fn_c_check_decl "$LINENO" "__argv" "ac_cv_have_decl___argv" "#include <stdlib.h>
17707 "
17708 if test "x$ac_cv_have_decl___argv" = xyes; then :
17709 ac_have_decl=1
17710 else
17711 ac_have_decl=0
17712 fi
17713
17714 cat >>confdefs.h <<_ACEOF
17715 #define HAVE_DECL___ARGV $ac_have_decl
17716 _ACEOF
17717 if test $ac_have_decl = 1; then :
17718 ac_found=1
17719 fi
17720
17721
17722 # Incur the cost of this test only if none of the above worked.
17723 if test $ac_found = 0; then
17724 # On OpenBSD 5.1, using the global __progname variable appears to be
17725 # the only way to implement getprogname.
17726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __progname is defined in default libraries" >&5
17727 $as_echo_n "checking whether __progname is defined in default libraries... " >&6; }
17728 if ${gl_cv_var___progname+:} false; then :
17729 $as_echo_n "(cached) " >&6
17730 else
17731
17732 gl_cv_var___progname=
17733 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17734 /* end confdefs.h. */
17735 extern char *__progname;
17736 int
17737 main ()
17738 {
17739 return *__progname;
17740
17741 ;
17742 return 0;
17743 }
17744 _ACEOF
17745 if ac_fn_c_try_link "$LINENO"; then :
17746 gl_cv_var___progname=yes
17747
17748 fi
17749 rm -f core conftest.err conftest.$ac_objext \
17750 conftest$ac_exeext conftest.$ac_ext
17751
17752
17753 fi
17754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_var___progname" >&5
17755 $as_echo "$gl_cv_var___progname" >&6; }
17756 if test "$gl_cv_var___progname" = yes; then
17757
17758 $as_echo "#define HAVE_VAR___PROGNAME 1" >>confdefs.h
17759
17760 fi
17761 fi
17762
17763
17764
17765
17766
17767
17768
17769
17770 :
17771
17772
17773
17774
17775
17776
17777 gl_gettimeofday_timezone=void
17778 if test $ac_cv_func_gettimeofday != yes; then
17779 HAVE_GETTIMEOFDAY=0
17780 else
17781
17782
17783
17784 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
17785 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
17786 if ${gl_cv_func_gettimeofday_clobber+:} false; then :
17787 $as_echo_n "(cached) " >&6
17788 else
17789 if test "$cross_compiling" = yes; then :
17790 # When cross-compiling:
17791 case "$host_os" in
17792 # Guess all is fine on glibc systems.
17793 *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
17794 # If we don't know, assume the worst.
17795 *) gl_cv_func_gettimeofday_clobber="guessing yes" ;;
17796 esac
17797
17798 else
17799 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17800 /* end confdefs.h. */
17801 #include <string.h>
17802 #include <sys/time.h>
17803 #include <time.h>
17804 #include <stdlib.h>
17805
17806 int
17807 main ()
17808 {
17809
17810 time_t t = 0;
17811 struct tm *lt;
17812 struct tm saved_lt;
17813 struct timeval tv;
17814 lt = localtime (&t);
17815 saved_lt = *lt;
17816 gettimeofday (&tv, NULL);
17817 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
17818
17819 ;
17820 return 0;
17821 }
17822 _ACEOF
17823 if ac_fn_c_try_run "$LINENO"; then :
17824 gl_cv_func_gettimeofday_clobber=no
17825 else
17826 gl_cv_func_gettimeofday_clobber=yes
17827 fi
17828 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17829 conftest.$ac_objext conftest.beam conftest.$ac_ext
17830 fi
17831
17832 fi
17833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
17834 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
17835
17836 case "$gl_cv_func_gettimeofday_clobber" in
17837 *yes)
17838 REPLACE_GETTIMEOFDAY=1
17839
17840 REPLACE_GMTIME=1
17841 REPLACE_LOCALTIME=1
17842
17843
17844 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
17845
17846 ;;
17847 esac
17848
17849 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
17850 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
17851 if ${gl_cv_func_gettimeofday_posix_signature+:} false; then :
17852 $as_echo_n "(cached) " >&6
17853 else
17854 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17855 /* end confdefs.h. */
17856 #include <sys/time.h>
17857 struct timeval c;
17858 int gettimeofday (struct timeval *restrict, void *restrict);
17859
17860 int
17861 main ()
17862 {
17863 /* glibc uses struct timezone * rather than the POSIX void *
17864 if _GNU_SOURCE is defined. However, since the only portable
17865 use of gettimeofday uses NULL as the second parameter, and
17866 since the glibc definition is actually more typesafe, it is
17867 not worth wrapping this to get a compliant signature. */
17868 int (*f) (struct timeval *restrict, void *restrict)
17869 = gettimeofday;
17870 int x = f (&c, 0);
17871 return !(x | c.tv_sec | c.tv_usec);
17872
17873 ;
17874 return 0;
17875 }
17876 _ACEOF
17877 if ac_fn_c_try_compile "$LINENO"; then :
17878 gl_cv_func_gettimeofday_posix_signature=yes
17879 else
17880 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17881 /* end confdefs.h. */
17882 #include <sys/time.h>
17883 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
17884
17885 int
17886 main ()
17887 {
17888
17889 ;
17890 return 0;
17891 }
17892 _ACEOF
17893 if ac_fn_c_try_compile "$LINENO"; then :
17894 gl_cv_func_gettimeofday_posix_signature=almost
17895 else
17896 gl_cv_func_gettimeofday_posix_signature=no
17897 fi
17898 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17899 fi
17900 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17901 fi
17902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
17903 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
17904 if test $gl_cv_func_gettimeofday_posix_signature = almost; then
17905 gl_gettimeofday_timezone='struct timezone'
17906 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
17907 REPLACE_GETTIMEOFDAY=1
17908 fi
17909 if test $REPLACE_STRUCT_TIMEVAL = 1; then
17910 REPLACE_GETTIMEOFDAY=1
17911 fi
17912
17913 fi
17914
17915 cat >>confdefs.h <<_ACEOF
17916 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
17917 _ACEOF
17918
17919
17920 if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
17921
17922
17923
17924
17925
17926
17927
17928
17929 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
17930
17931
17932 for ac_header in sys/timeb.h
17933 do :
17934 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
17935 if test "x$ac_cv_header_sys_timeb_h" = xyes; then :
17936 cat >>confdefs.h <<_ACEOF
17937 #define HAVE_SYS_TIMEB_H 1
17938 _ACEOF
17939
17940 fi
17941
17942 done
17943
17944 for ac_func in _ftime
17945 do :
17946 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
17947 if test "x$ac_cv_func__ftime" = xyes; then :
17948 cat >>confdefs.h <<_ACEOF
17949 #define HAVE__FTIME 1
17950 _ACEOF
17951
17952 fi
17953 done
17954
17955
17956 fi
17957
17958
17959
17960
17961
17962 GNULIB_GETTIMEOFDAY=1
17963
17964
17965
17966
17967
17968 $as_echo "#define GNULIB_TEST_GETTIMEOFDAY 1" >>confdefs.h
17969
17970
17971
17972 GLOB_H=
17973 for ac_header in glob.h
17974 do :
17975 ac_fn_c_check_header_mongrel "$LINENO" "glob.h" "ac_cv_header_glob_h" "$ac_includes_default"
17976 if test "x$ac_cv_header_glob_h" = xyes; then :
17977 cat >>confdefs.h <<_ACEOF
17978 #define HAVE_GLOB_H 1
17979 _ACEOF
17980
17981 else
17982 GLOB_H=glob.h
17983 fi
17984
17985 done
17986
17987
17988 if test -z "$GLOB_H"; then
17989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU glob interface version 1" >&5
17990 $as_echo_n "checking for GNU glob interface version 1... " >&6; }
17991 if ${gl_cv_gnu_glob_interface_version_1+:} false; then :
17992 $as_echo_n "(cached) " >&6
17993 else
17994 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17995 /* end confdefs.h. */
17996 #include <gnu-versions.h>
17997 char a[_GNU_GLOB_INTERFACE_VERSION == 1 ? 1 : -1];
17998 _ACEOF
17999 if ac_fn_c_try_compile "$LINENO"; then :
18000 gl_cv_gnu_glob_interface_version_1=yes
18001 else
18002 gl_cv_gnu_glob_interface_version_1=no
18003 fi
18004 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18005 fi
18006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_gnu_glob_interface_version_1" >&5
18007 $as_echo "$gl_cv_gnu_glob_interface_version_1" >&6; }
18008
18009 if test "$gl_cv_gnu_glob_interface_version_1" = "no"; then
18010 GLOB_H=glob.h
18011 fi
18012 fi
18013
18014 if test -z "$GLOB_H"; then
18015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether glob lists broken symlinks" >&5
18016 $as_echo_n "checking whether glob lists broken symlinks... " >&6; }
18017 if ${gl_cv_glob_lists_symlinks+:} false; then :
18018 $as_echo_n "(cached) " >&6
18019 else
18020 if ln -s conf-doesntexist conf$$-globtest 2>/dev/null; then
18021 gl_cv_glob_lists_symlinks=maybe
18022 else
18023 # If we can't make a symlink, then we cannot test this issue. Be
18024 # pessimistic about this.
18025 gl_cv_glob_lists_symlinks=no
18026 fi
18027
18028 if test $gl_cv_glob_lists_symlinks = maybe; then
18029 if test "$cross_compiling" = yes; then :
18030 gl_cv_glob_lists_symlinks=no
18031 else
18032 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18033 /* end confdefs.h. */
18034
18035 #include <stddef.h>
18036 #include <glob.h>
18037 int
18038 main ()
18039 {
18040 glob_t found;
18041 if (glob ("conf*-globtest", 0, NULL, &found) == GLOB_NOMATCH) return 1;
18042 ;
18043 return 0;
18044 }
18045 _ACEOF
18046 if ac_fn_c_try_run "$LINENO"; then :
18047 gl_cv_glob_lists_symlinks=yes
18048 else
18049 gl_cv_glob_lists_symlinks=no
18050 fi
18051 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18052 conftest.$ac_objext conftest.beam conftest.$ac_ext
18053 fi
18054
18055 fi
18056 fi
18057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_glob_lists_symlinks" >&5
18058 $as_echo "$gl_cv_glob_lists_symlinks" >&6; }
18059
18060 if test $gl_cv_glob_lists_symlinks = no; then
18061 GLOB_H=glob.h
18062 fi
18063 fi
18064
18065 rm -f conf$$-globtest
18066
18067
18068 if test -n "$GLOB_H"; then
18069 GL_GENERATE_GLOB_H_TRUE=
18070 GL_GENERATE_GLOB_H_FALSE='#'
18071 else
18072 GL_GENERATE_GLOB_H_TRUE='#'
18073 GL_GENERATE_GLOB_H_FALSE=
18074 fi
18075
18076
18077 if test -n "$GLOB_H"; then
18078
18079
18080
18081
18082
18083
18084
18085
18086 gl_LIBOBJS="$gl_LIBOBJS glob.$ac_objext"
18087
18088
18089
18090 :
18091
18092
18093
18094
18095
18096
18097
18098 if test $ac_cv_header_sys_cdefs_h = yes; then
18099 HAVE_SYS_CDEFS_H=1
18100 else
18101 HAVE_SYS_CDEFS_H=0
18102 fi
18103
18104
18105 :
18106
18107
18108
18109
18110
18111
18112
18113
18114
18115
18116
18117 fi
18118
18119 :
18120
18121
18122
18123
18124
18125
18126 PRIPTR_PREFIX=
18127 if test -n "$STDINT_H"; then
18128 PRIPTR_PREFIX='"l"'
18129 else
18130 for glpfx in '' l ll I64; do
18131 case $glpfx in
18132 '') gltype1='int';;
18133 l) gltype1='long int';;
18134 ll) gltype1='long long int';;
18135 I64) gltype1='__int64';;
18136 esac
18137 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18138 /* end confdefs.h. */
18139 #include <stdint.h>
18140 extern intptr_t foo;
18141 extern $gltype1 foo;
18142 int
18143 main ()
18144 {
18145
18146 ;
18147 return 0;
18148 }
18149 _ACEOF
18150 if ac_fn_c_try_compile "$LINENO"; then :
18151 PRIPTR_PREFIX='"'$glpfx'"'
18152 fi
18153 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18154 test -n "$PRIPTR_PREFIX" && break
18155 done
18156 fi
18157
18158
18159
18160 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether INT32_MAX < INTMAX_MAX" >&5
18161 $as_echo_n "checking whether INT32_MAX < INTMAX_MAX... " >&6; }
18162 if ${gl_cv_test_INT32_MAX_LT_INTMAX_MAX+:} false; then :
18163 $as_echo_n "(cached) " >&6
18164 else
18165 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18166 /* end confdefs.h. */
18167 /* Work also in C++ mode. */
18168 #define __STDC_LIMIT_MACROS 1
18169
18170 /* Work if build is not clean. */
18171 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
18172
18173 #include <limits.h>
18174 #if HAVE_STDINT_H
18175 #include <stdint.h>
18176 #endif
18177
18178 #if defined INT32_MAX && defined INTMAX_MAX
18179 #define CONDITION (INT32_MAX < INTMAX_MAX)
18180 #elif HAVE_LONG_LONG_INT
18181 #define CONDITION (sizeof (int) < sizeof (long long int))
18182 #else
18183 #define CONDITION 0
18184 #endif
18185 int test[CONDITION ? 1 : -1];
18186 int
18187 main ()
18188 {
18189
18190 ;
18191 return 0;
18192 }
18193 _ACEOF
18194 if ac_fn_c_try_compile "$LINENO"; then :
18195 gl_cv_test_INT32_MAX_LT_INTMAX_MAX=yes
18196 else
18197 gl_cv_test_INT32_MAX_LT_INTMAX_MAX=no
18198 fi
18199 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18200 fi
18201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_INT32_MAX_LT_INTMAX_MAX" >&5
18202 $as_echo "$gl_cv_test_INT32_MAX_LT_INTMAX_MAX" >&6; }
18203 if test $gl_cv_test_INT32_MAX_LT_INTMAX_MAX = yes; then
18204 INT32_MAX_LT_INTMAX_MAX=1;
18205 else
18206 INT32_MAX_LT_INTMAX_MAX=0;
18207 fi
18208
18209
18210 if test $APPLE_UNIVERSAL_BUILD = 0; then
18211
18212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether INT64_MAX == LONG_MAX" >&5
18213 $as_echo_n "checking whether INT64_MAX == LONG_MAX... " >&6; }
18214 if ${gl_cv_test_INT64_MAX_EQ_LONG_MAX+:} false; then :
18215 $as_echo_n "(cached) " >&6
18216 else
18217 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18218 /* end confdefs.h. */
18219 /* Work also in C++ mode. */
18220 #define __STDC_LIMIT_MACROS 1
18221
18222 /* Work if build is not clean. */
18223 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
18224
18225 #include <limits.h>
18226 #if HAVE_STDINT_H
18227 #include <stdint.h>
18228 #endif
18229
18230 #if defined INT64_MAX
18231 #define CONDITION (INT64_MAX == LONG_MAX)
18232 #elif HAVE_LONG_LONG_INT
18233 #define CONDITION (sizeof (long long int) == sizeof (long int))
18234 #else
18235 #define CONDITION 0
18236 #endif
18237 int test[CONDITION ? 1 : -1];
18238 int
18239 main ()
18240 {
18241
18242 ;
18243 return 0;
18244 }
18245 _ACEOF
18246 if ac_fn_c_try_compile "$LINENO"; then :
18247 gl_cv_test_INT64_MAX_EQ_LONG_MAX=yes
18248 else
18249 gl_cv_test_INT64_MAX_EQ_LONG_MAX=no
18250 fi
18251 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18252 fi
18253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_INT64_MAX_EQ_LONG_MAX" >&5
18254 $as_echo "$gl_cv_test_INT64_MAX_EQ_LONG_MAX" >&6; }
18255 if test $gl_cv_test_INT64_MAX_EQ_LONG_MAX = yes; then
18256 INT64_MAX_EQ_LONG_MAX=1;
18257 else
18258 INT64_MAX_EQ_LONG_MAX=0;
18259 fi
18260
18261
18262 else
18263 INT64_MAX_EQ_LONG_MAX=-1
18264 fi
18265
18266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether UINT32_MAX < UINTMAX_MAX" >&5
18267 $as_echo_n "checking whether UINT32_MAX < UINTMAX_MAX... " >&6; }
18268 if ${gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX+:} false; then :
18269 $as_echo_n "(cached) " >&6
18270 else
18271 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18272 /* end confdefs.h. */
18273 /* Work also in C++ mode. */
18274 #define __STDC_LIMIT_MACROS 1
18275
18276 /* Work if build is not clean. */
18277 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
18278
18279 #include <limits.h>
18280 #if HAVE_STDINT_H
18281 #include <stdint.h>
18282 #endif
18283
18284 #if defined UINT32_MAX && defined UINTMAX_MAX
18285 #define CONDITION (UINT32_MAX < UINTMAX_MAX)
18286 #elif HAVE_LONG_LONG_INT
18287 #define CONDITION (sizeof (unsigned int) < sizeof (unsigned long long int))
18288 #else
18289 #define CONDITION 0
18290 #endif
18291 int test[CONDITION ? 1 : -1];
18292 int
18293 main ()
18294 {
18295
18296 ;
18297 return 0;
18298 }
18299 _ACEOF
18300 if ac_fn_c_try_compile "$LINENO"; then :
18301 gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX=yes
18302 else
18303 gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX=no
18304 fi
18305 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18306 fi
18307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX" >&5
18308 $as_echo "$gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX" >&6; }
18309 if test $gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX = yes; then
18310 UINT32_MAX_LT_UINTMAX_MAX=1;
18311 else
18312 UINT32_MAX_LT_UINTMAX_MAX=0;
18313 fi
18314
18315
18316 if test $APPLE_UNIVERSAL_BUILD = 0; then
18317
18318 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether UINT64_MAX == ULONG_MAX" >&5
18319 $as_echo_n "checking whether UINT64_MAX == ULONG_MAX... " >&6; }
18320 if ${gl_cv_test_UINT64_MAX_EQ_ULONG_MAX+:} false; then :
18321 $as_echo_n "(cached) " >&6
18322 else
18323 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18324 /* end confdefs.h. */
18325 /* Work also in C++ mode. */
18326 #define __STDC_LIMIT_MACROS 1
18327
18328 /* Work if build is not clean. */
18329 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
18330
18331 #include <limits.h>
18332 #if HAVE_STDINT_H
18333 #include <stdint.h>
18334 #endif
18335
18336 #if defined UINT64_MAX
18337 #define CONDITION (UINT64_MAX == ULONG_MAX)
18338 #elif HAVE_LONG_LONG_INT
18339 #define CONDITION (sizeof (unsigned long long int) == sizeof (unsigned long int))
18340 #else
18341 #define CONDITION 0
18342 #endif
18343 int test[CONDITION ? 1 : -1];
18344 int
18345 main ()
18346 {
18347
18348 ;
18349 return 0;
18350 }
18351 _ACEOF
18352 if ac_fn_c_try_compile "$LINENO"; then :
18353 gl_cv_test_UINT64_MAX_EQ_ULONG_MAX=yes
18354 else
18355 gl_cv_test_UINT64_MAX_EQ_ULONG_MAX=no
18356 fi
18357 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18358 fi
18359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_UINT64_MAX_EQ_ULONG_MAX" >&5
18360 $as_echo "$gl_cv_test_UINT64_MAX_EQ_ULONG_MAX" >&6; }
18361 if test $gl_cv_test_UINT64_MAX_EQ_ULONG_MAX = yes; then
18362 UINT64_MAX_EQ_ULONG_MAX=1;
18363 else
18364 UINT64_MAX_EQ_ULONG_MAX=0;
18365 fi
18366
18367
18368 else
18369 UINT64_MAX_EQ_ULONG_MAX=-1
18370 fi
18371
18372
18373
18374
18375
18376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnan(double) can be used without linking with libm" >&5
18377 $as_echo_n "checking whether isnan(double) can be used without linking with libm... " >&6; }
18378 if ${gl_cv_func_isnand_no_libm+:} false; then :
18379 $as_echo_n "(cached) " >&6
18380 else
18381
18382 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18383 /* end confdefs.h. */
18384 #include <math.h>
18385 #if __GNUC__ >= 4
18386 # undef isnand
18387 # define isnand(x) __builtin_isnan ((double)(x))
18388 #else
18389 # undef isnand
18390 # define isnand(x) isnan ((double)(x))
18391 #endif
18392 double x;
18393 int
18394 main ()
18395 {
18396 return isnand (x);
18397 ;
18398 return 0;
18399 }
18400 _ACEOF
18401 if ac_fn_c_try_link "$LINENO"; then :
18402 gl_cv_func_isnand_no_libm=yes
18403 else
18404 gl_cv_func_isnand_no_libm=no
18405 fi
18406 rm -f core conftest.err conftest.$ac_objext \
18407 conftest$ac_exeext conftest.$ac_ext
18408
18409 fi
18410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnand_no_libm" >&5
18411 $as_echo "$gl_cv_func_isnand_no_libm" >&6; }
18412
18413 gl_func_isnand_no_libm=$gl_cv_func_isnand_no_libm
18414 if test $gl_cv_func_isnand_no_libm = yes; then
18415
18416 $as_echo "#define HAVE_ISNAND_IN_LIBC 1" >>confdefs.h
18417
18418 fi
18419
18420 if test $gl_func_isnand_no_libm != yes; then
18421
18422
18423
18424
18425
18426
18427
18428
18429 gl_LIBOBJS="$gl_LIBOBJS isnand.$ac_objext"
18430
18431
18432
18433
18434 fi
18435
18436
18437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnan(long double) can be used without linking with libm" >&5
18438 $as_echo_n "checking whether isnan(long double) can be used without linking with libm... " >&6; }
18439 if ${gl_cv_func_isnanl_no_libm+:} false; then :
18440 $as_echo_n "(cached) " >&6
18441 else
18442
18443 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18444 /* end confdefs.h. */
18445 #include <math.h>
18446 #if __GNUC__ >= 4
18447 # undef isnanl
18448 # define isnanl(x) __builtin_isnanl ((long double)(x))
18449 #elif defined isnan
18450 # undef isnanl
18451 # define isnanl(x) isnan ((long double)(x))
18452 #endif
18453 long double x;
18454 int
18455 main ()
18456 {
18457 return isnanl (x);
18458 ;
18459 return 0;
18460 }
18461 _ACEOF
18462 if ac_fn_c_try_link "$LINENO"; then :
18463 gl_cv_func_isnanl_no_libm=yes
18464 else
18465 gl_cv_func_isnanl_no_libm=no
18466 fi
18467 rm -f core conftest.err conftest.$ac_objext \
18468 conftest$ac_exeext conftest.$ac_ext
18469
18470 fi
18471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnanl_no_libm" >&5
18472 $as_echo "$gl_cv_func_isnanl_no_libm" >&6; }
18473
18474 gl_func_isnanl_no_libm=$gl_cv_func_isnanl_no_libm
18475 if test $gl_func_isnanl_no_libm = yes; then
18476
18477
18478
18479
18480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnanl works" >&5
18481 $as_echo_n "checking whether isnanl works... " >&6; }
18482 if ${gl_cv_func_isnanl_works+:} false; then :
18483 $as_echo_n "(cached) " >&6
18484 else
18485
18486 if test "$cross_compiling" = yes; then :
18487 gl_cv_func_isnanl_works="guessing yes"
18488 else
18489 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18490 /* end confdefs.h. */
18491
18492 #include <float.h>
18493 #include <limits.h>
18494 #include <math.h>
18495 #if __GNUC__ >= 4
18496 # undef isnanl
18497 # define isnanl(x) __builtin_isnanl ((long double)(x))
18498 #elif defined isnan
18499 # undef isnanl
18500 # define isnanl(x) isnan ((long double)(x))
18501 #endif
18502 #define NWORDS \
18503 ((sizeof (long double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
18504 typedef union { unsigned int word[NWORDS]; long double value; }
18505 memory_long_double;
18506 /* On Irix 6.5, gcc 3.4.3 can't compute compile-time NaN, and needs the
18507 runtime type conversion. */
18508 #ifdef __sgi
18509 static long double NaNl ()
18510 {
18511 double zero = 0.0;
18512 return zero / zero;
18513 }
18514 #else
18515 # define NaNl() (0.0L / 0.0L)
18516 #endif
18517 int main ()
18518 {
18519 int result = 0;
18520
18521 if (!isnanl (NaNl ()))
18522 result |= 1;
18523
18524 {
18525 memory_long_double m;
18526 unsigned int i;
18527
18528 /* The isnanl function should be immune against changes in the sign bit and
18529 in the mantissa bits. The xor operation twiddles a bit that can only be
18530 a sign bit or a mantissa bit (since the exponent never extends to
18531 bit 31). */
18532 m.value = NaNl ();
18533 m.word[NWORDS / 2] ^= (unsigned int) 1 << (sizeof (unsigned int) * CHAR_BIT - 1);
18534 for (i = 0; i < NWORDS; i++)
18535 m.word[i] |= 1;
18536 if (!isnanl (m.value))
18537 result |= 1;
18538 }
18539
18540 #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
18541 /* Representation of an 80-bit 'long double' as an initializer for a sequence
18542 of 'unsigned int' words. */
18543 # ifdef WORDS_BIGENDIAN
18544 # define LDBL80_WORDS(exponent,manthi,mantlo) \
18545 { ((unsigned int) (exponent) << 16) | ((unsigned int) (manthi) >> 16), \
18546 ((unsigned int) (manthi) << 16) | ((unsigned int) (mantlo) >> 16), \
18547 (unsigned int) (mantlo) << 16 \
18548 }
18549 # else
18550 # define LDBL80_WORDS(exponent,manthi,mantlo) \
18551 { mantlo, manthi, exponent }
18552 # endif
18553 { /* Quiet NaN. */
18554 static memory_long_double x =
18555 { LDBL80_WORDS (0xFFFF, 0xC3333333, 0x00000000) };
18556 if (!isnanl (x.value))
18557 result |= 2;
18558 }
18559 {
18560 /* Signalling NaN. */
18561 static memory_long_double x =
18562 { LDBL80_WORDS (0xFFFF, 0x83333333, 0x00000000) };
18563 if (!isnanl (x.value))
18564 result |= 2;
18565 }
18566 /* isnanl should return something even for noncanonical values. */
18567 { /* Pseudo-NaN. */
18568 static memory_long_double x =
18569 { LDBL80_WORDS (0xFFFF, 0x40000001, 0x00000000) };
18570 if (isnanl (x.value) && !isnanl (x.value))
18571 result |= 4;
18572 }
18573 { /* Pseudo-Infinity. */
18574 static memory_long_double x =
18575 { LDBL80_WORDS (0xFFFF, 0x00000000, 0x00000000) };
18576 if (isnanl (x.value) && !isnanl (x.value))
18577 result |= 8;
18578 }
18579 { /* Pseudo-Zero. */
18580 static memory_long_double x =
18581 { LDBL80_WORDS (0x4004, 0x00000000, 0x00000000) };
18582 if (isnanl (x.value) && !isnanl (x.value))
18583 result |= 16;
18584 }
18585 { /* Unnormalized number. */
18586 static memory_long_double x =
18587 { LDBL80_WORDS (0x4000, 0x63333333, 0x00000000) };
18588 if (isnanl (x.value) && !isnanl (x.value))
18589 result |= 32;
18590 }
18591 { /* Pseudo-Denormal. */
18592 static memory_long_double x =
18593 { LDBL80_WORDS (0x0000, 0x83333333, 0x00000000) };
18594 if (isnanl (x.value) && !isnanl (x.value))
18595 result |= 64;
18596 }
18597 #endif
18598
18599 return result;
18600 }
18601 _ACEOF
18602 if ac_fn_c_try_run "$LINENO"; then :
18603 gl_cv_func_isnanl_works=yes
18604 else
18605 gl_cv_func_isnanl_works=no
18606 fi
18607 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18608 conftest.$ac_objext conftest.beam conftest.$ac_ext
18609 fi
18610
18611
18612 fi
18613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnanl_works" >&5
18614 $as_echo "$gl_cv_func_isnanl_works" >&6; }
18615
18616 case "$gl_cv_func_isnanl_works" in
18617 *yes) ;;
18618 *) gl_func_isnanl_no_libm=no ;;
18619 esac
18620 fi
18621 if test $gl_func_isnanl_no_libm = yes; then
18622
18623 $as_echo "#define HAVE_ISNANL_IN_LIBC 1" >>confdefs.h
18624
18625 fi
18626
18627 if test $gl_func_isnanl_no_libm != yes; then
18628
18629
18630
18631
18632
18633
18634
18635
18636 gl_LIBOBJS="$gl_LIBOBJS isnanl.$ac_objext"
18637
18638
18639
18640
18641 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'long double'" >&5
18642 $as_echo_n "checking where to find the exponent in a 'long double'... " >&6; }
18643 if ${gl_cv_cc_long_double_expbit0+:} false; then :
18644 $as_echo_n "(cached) " >&6
18645 else
18646
18647 if test "$cross_compiling" = yes; then :
18648
18649 gl_cv_cc_long_double_expbit0="unknown"
18650
18651 else
18652 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18653 /* end confdefs.h. */
18654
18655 #include <float.h>
18656 #include <stddef.h>
18657 #include <stdio.h>
18658 #include <string.h>
18659 #define NWORDS \
18660 ((sizeof (long double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
18661 typedef union { long double value; unsigned int word[NWORDS]; }
18662 memory_long_double;
18663 static unsigned int ored_words[NWORDS];
18664 static unsigned int anded_words[NWORDS];
18665 static void add_to_ored_words (long double x)
18666 {
18667 memory_long_double m;
18668 size_t i;
18669 /* Clear it first, in case
18670 sizeof (long double) < sizeof (memory_long_double). */
18671 memset (&m, 0, sizeof (memory_long_double));
18672 m.value = x;
18673 for (i = 0; i < NWORDS; i++)
18674 {
18675 ored_words[i] |= m.word[i];
18676 anded_words[i] &= m.word[i];
18677 }
18678 }
18679 int main ()
18680 {
18681 size_t j;
18682 FILE *fp = fopen ("conftest.out", "w");
18683 if (fp == NULL)
18684 return 1;
18685 for (j = 0; j < NWORDS; j++)
18686 anded_words[j] = ~ (unsigned int) 0;
18687 add_to_ored_words (0.25L);
18688 add_to_ored_words (0.5L);
18689 add_to_ored_words (1.0L);
18690 add_to_ored_words (2.0L);
18691 add_to_ored_words (4.0L);
18692 /* Remove bits that are common (e.g. if representation of the first mantissa
18693 bit is explicit). */
18694 for (j = 0; j < NWORDS; j++)
18695 ored_words[j] &= ~anded_words[j];
18696 /* Now find the nonzero word. */
18697 for (j = 0; j < NWORDS; j++)
18698 if (ored_words[j] != 0)
18699 break;
18700 if (j < NWORDS)
18701 {
18702 size_t i;
18703 for (i = j + 1; i < NWORDS; i++)
18704 if (ored_words[i] != 0)
18705 {
18706 fprintf (fp, "unknown");
18707 return (fclose (fp) != 0);
18708 }
18709 for (i = 0; ; i++)
18710 if ((ored_words[j] >> i) & 1)
18711 {
18712 fprintf (fp, "word %d bit %d", (int) j, (int) i);
18713 return (fclose (fp) != 0);
18714 }
18715 }
18716 fprintf (fp, "unknown");
18717 return (fclose (fp) != 0);
18718 }
18719
18720 _ACEOF
18721 if ac_fn_c_try_run "$LINENO"; then :
18722 gl_cv_cc_long_double_expbit0=`cat conftest.out`
18723 else
18724 gl_cv_cc_long_double_expbit0="unknown"
18725 fi
18726 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18727 conftest.$ac_objext conftest.beam conftest.$ac_ext
18728 fi
18729
18730 rm -f conftest.out
18731
18732 fi
18733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_long_double_expbit0" >&5
18734 $as_echo "$gl_cv_cc_long_double_expbit0" >&6; }
18735 case "$gl_cv_cc_long_double_expbit0" in
18736 word*bit*)
18737 word=`echo "$gl_cv_cc_long_double_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
18738 bit=`echo "$gl_cv_cc_long_double_expbit0" | sed -e 's/word.*bit //'`
18739
18740 cat >>confdefs.h <<_ACEOF
18741 #define LDBL_EXPBIT0_WORD $word
18742 _ACEOF
18743
18744
18745 cat >>confdefs.h <<_ACEOF
18746 #define LDBL_EXPBIT0_BIT $bit
18747 _ACEOF
18748
18749 ;;
18750 esac
18751
18752
18753
18754 fi
18755
18756
18757
18758
18759
18760
18761 :
18762
18763
18764
18765
18766
18767
18768
18769
18770
18771 LOCALCHARSET_TESTS_ENVIRONMENT="CHARSETALIASDIR=\"\$(abs_top_builddir)/$gl_source_base\""
18772
18773
18774
18775
18776 :
18777
18778
18779
18780
18781
18782 if test $ac_cv_func_lstat = yes; then
18783
18784 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
18785 *no)
18786 REPLACE_LSTAT=1
18787 ;;
18788 esac
18789 else
18790 HAVE_LSTAT=0
18791 fi
18792
18793 if test $REPLACE_LSTAT = 1; then
18794
18795
18796
18797
18798
18799
18800
18801
18802 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
18803
18804 :
18805 fi
18806
18807
18808
18809
18810
18811 GNULIB_LSTAT=1
18812
18813
18814
18815
18816
18817 $as_echo "#define GNULIB_TEST_LSTAT 1" >>confdefs.h
18818
18819
18820
18821
18822
18823
18824 if test $gl_cv_func_malloc_posix = yes; then
18825
18826 $as_echo "#define HAVE_MALLOC_POSIX 1" >>confdefs.h
18827
18828 else
18829 REPLACE_MALLOC=1
18830 fi
18831
18832 if test $REPLACE_MALLOC = 1; then
18833
18834
18835
18836
18837
18838
18839
18840
18841 gl_LIBOBJS="$gl_LIBOBJS malloc.$ac_objext"
18842
18843 fi
18844
18845
18846
18847
18848
18849 GNULIB_MALLOC_POSIX=1
18850
18851
18852
18853
18854
18855 $as_echo "#define GNULIB_TEST_MALLOC_POSIX 1" >>confdefs.h
18856
18857
18858
18859
18860
18861
18862
18863
18864
18865
18866
18867
18868
18869
18870
18871 :
18872
18873
18874
18875
18876
18877
18878
18879
18880 if test $gl_cv_have_include_next = yes; then
18881 gl_cv_next_math_h='<'math.h'>'
18882 else
18883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <math.h>" >&5
18884 $as_echo_n "checking absolute name of <math.h>... " >&6; }
18885 if ${gl_cv_next_math_h+:} false; then :
18886 $as_echo_n "(cached) " >&6
18887 else
18888
18889 if test $ac_cv_header_math_h = yes; then
18890
18891
18892
18893
18894 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18895 /* end confdefs.h. */
18896 #include <math.h>
18897 _ACEOF
18898 case "$host_os" in
18899 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18900 *) gl_absname_cpp="$ac_cpp" ;;
18901 esac
18902
18903 case "$host_os" in
18904 mingw*)
18905 gl_dirsep_regex='[/\\]'
18906 ;;
18907 *)
18908 gl_dirsep_regex='\/'
18909 ;;
18910 esac
18911 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18912 gl_header_literal_regex=`echo 'math.h' \
18913 | sed -e "$gl_make_literal_regex_sed"`
18914 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18915 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18916 s|^/[^/]|//&|
18917 p
18918 q
18919 }'
18920
18921 gl_cv_absolute_math_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18922 sed -n "$gl_absolute_header_sed"`
18923
18924 gl_header=$gl_cv_absolute_math_h
18925 gl_cv_next_math_h='"'$gl_header'"'
18926 else
18927 gl_cv_next_math_h='<'math.h'>'
18928 fi
18929
18930
18931 fi
18932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_math_h" >&5
18933 $as_echo "$gl_cv_next_math_h" >&6; }
18934 fi
18935 NEXT_MATH_H=$gl_cv_next_math_h
18936
18937 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18938 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18939 gl_next_as_first_directive='<'math.h'>'
18940 else
18941 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18942 gl_next_as_first_directive=$gl_cv_next_math_h
18943 fi
18944 NEXT_AS_FIRST_DIRECTIVE_MATH_H=$gl_next_as_first_directive
18945
18946
18947
18948
18949
18950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NAN macro works" >&5
18951 $as_echo_n "checking whether NAN macro works... " >&6; }
18952 if ${gl_cv_header_math_nan_works+:} false; then :
18953 $as_echo_n "(cached) " >&6
18954 else
18955 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18956 /* end confdefs.h. */
18957 #include <math.h>
18958 int
18959 main ()
18960 {
18961 /* Solaris 10 has a broken definition of NAN. Other platforms
18962 fail to provide NAN, or provide it only in C99 mode; this
18963 test only needs to fail when NAN is provided but wrong. */
18964 float f = 1.0f;
18965 #ifdef NAN
18966 f = NAN;
18967 #endif
18968 return f == 0;
18969 ;
18970 return 0;
18971 }
18972 _ACEOF
18973 if ac_fn_c_try_compile "$LINENO"; then :
18974 gl_cv_header_math_nan_works=yes
18975 else
18976 gl_cv_header_math_nan_works=no
18977 fi
18978 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18979 fi
18980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_math_nan_works" >&5
18981 $as_echo "$gl_cv_header_math_nan_works" >&6; }
18982 if test $gl_cv_header_math_nan_works = no; then
18983 REPLACE_NAN=1
18984 fi
18985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether HUGE_VAL works" >&5
18986 $as_echo_n "checking whether HUGE_VAL works... " >&6; }
18987 if ${gl_cv_header_math_huge_val_works+:} false; then :
18988 $as_echo_n "(cached) " >&6
18989 else
18990 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18991 /* end confdefs.h. */
18992 #include <math.h>
18993 int
18994 main ()
18995 {
18996 /* Solaris 10 has a broken definition of HUGE_VAL. */
18997 double d = HUGE_VAL;
18998 return d == 0;
18999 ;
19000 return 0;
19001 }
19002 _ACEOF
19003 if ac_fn_c_try_compile "$LINENO"; then :
19004 gl_cv_header_math_huge_val_works=yes
19005 else
19006 gl_cv_header_math_huge_val_works=no
19007 fi
19008 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19009 fi
19010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_math_huge_val_works" >&5
19011 $as_echo "$gl_cv_header_math_huge_val_works" >&6; }
19012 if test $gl_cv_header_math_huge_val_works = no; then
19013 REPLACE_HUGE_VAL=1
19014 fi
19015
19016
19017 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
19018 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
19019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
19020 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
19021 if eval \${$as_gl_Symbol+:} false; then :
19022 $as_echo_n "(cached) " >&6
19023 else
19024 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19025 /* end confdefs.h. */
19026 #include <math.h>
19027 int
19028 main ()
19029 {
19030 #undef $gl_func
19031 (void) $gl_func;
19032 ;
19033 return 0;
19034 }
19035 _ACEOF
19036 if ac_fn_c_try_compile "$LINENO"; then :
19037 eval "$as_gl_Symbol=yes"
19038 else
19039 eval "$as_gl_Symbol=no"
19040 fi
19041 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19042 fi
19043 eval ac_res=\$$as_gl_Symbol
19044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
19045 $as_echo "$ac_res" >&6; }
19046 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
19047 cat >>confdefs.h <<_ACEOF
19048 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
19049 _ACEOF
19050
19051 eval ac_cv_have_decl_$gl_func=yes
19052 fi
19053 done
19054
19055
19056
19057
19058
19059
19060
19061
19062
19063
19064
19065 :
19066
19067
19068
19069
19070
19071
19072 :
19073
19074
19075
19076
19077
19078 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
19079
19080
19081
19082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
19083 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
19084 if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then :
19085 $as_echo_n "(cached) " >&6
19086 else
19087
19088 case "$host_os" in
19089 # Guess no on AIX and OSF/1.
19090 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
19091 # Guess yes otherwise.
19092 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
19093 esac
19094 if test $LOCALE_JA != none; then
19095 if test "$cross_compiling" = yes; then :
19096 :
19097 else
19098 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19099 /* end confdefs.h. */
19100
19101 #include <locale.h>
19102 #include <string.h>
19103 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19104 <wchar.h>.
19105 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19106 included before <wchar.h>. */
19107 #include <stddef.h>
19108 #include <stdio.h>
19109 #include <time.h>
19110 #include <wchar.h>
19111 int main ()
19112 {
19113 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
19114 {
19115 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
19116 mbstate_t state;
19117 wchar_t wc;
19118
19119 memset (&state, '\0', sizeof (mbstate_t));
19120 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
19121 if (mbsinit (&state))
19122 return 1;
19123 }
19124 return 0;
19125 }
19126 _ACEOF
19127 if ac_fn_c_try_run "$LINENO"; then :
19128 gl_cv_func_mbrtowc_incomplete_state=yes
19129 else
19130 gl_cv_func_mbrtowc_incomplete_state=no
19131 fi
19132 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19133 conftest.$ac_objext conftest.beam conftest.$ac_ext
19134 fi
19135
19136 fi
19137
19138 fi
19139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
19140 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
19141
19142
19143
19144
19145 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
19146 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
19147 if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then :
19148 $as_echo_n "(cached) " >&6
19149 else
19150
19151 case "$host_os" in
19152 # Guess no on Solaris 8.
19153 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
19154 # Guess yes otherwise.
19155 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
19156 esac
19157 if test $LOCALE_ZH_CN != none; then
19158 if test "$cross_compiling" = yes; then :
19159 :
19160 else
19161 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19162 /* end confdefs.h. */
19163
19164 #include <locale.h>
19165 #include <stdlib.h>
19166 #include <string.h>
19167 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19168 <wchar.h>.
19169 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19170 included before <wchar.h>. */
19171 #include <stddef.h>
19172 #include <stdio.h>
19173 #include <time.h>
19174 #include <wchar.h>
19175 int main ()
19176 {
19177 /* This fails on Solaris 8:
19178 mbrtowc returns 2, and sets wc to 0x00F0.
19179 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
19180 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
19181 {
19182 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
19183 mbstate_t state;
19184 wchar_t wc;
19185
19186 memset (&state, '\0', sizeof (mbstate_t));
19187 if (mbrtowc (&wc, input + 3, 6, &state) != 4
19188 && mbtowc (&wc, input + 3, 6) == 4)
19189 return 1;
19190 }
19191 return 0;
19192 }
19193 _ACEOF
19194 if ac_fn_c_try_run "$LINENO"; then :
19195 gl_cv_func_mbrtowc_sanitycheck=yes
19196 else
19197 gl_cv_func_mbrtowc_sanitycheck=no
19198 fi
19199 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19200 conftest.$ac_objext conftest.beam conftest.$ac_ext
19201 fi
19202
19203 fi
19204
19205 fi
19206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
19207 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
19208
19209 REPLACE_MBSTATE_T=0
19210 case "$gl_cv_func_mbrtowc_incomplete_state" in
19211 *yes) ;;
19212 *) REPLACE_MBSTATE_T=1 ;;
19213 esac
19214 case "$gl_cv_func_mbrtowc_sanitycheck" in
19215 *yes) ;;
19216 *) REPLACE_MBSTATE_T=1 ;;
19217 esac
19218 else
19219 REPLACE_MBSTATE_T=1
19220 fi
19221
19222
19223
19224 :
19225
19226
19227
19228
19229
19230 if test $ac_cv_func_mbrtowc = no; then
19231 HAVE_MBRTOWC=0
19232 ac_fn_c_check_decl "$LINENO" "mbrtowc" "ac_cv_have_decl_mbrtowc" "
19233 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19234 <wchar.h>.
19235 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19236 included before <wchar.h>. */
19237 #include <stddef.h>
19238 #include <stdio.h>
19239 #include <time.h>
19240 #include <wchar.h>
19241
19242 "
19243 if test "x$ac_cv_have_decl_mbrtowc" = xyes; then :
19244 ac_have_decl=1
19245 else
19246 ac_have_decl=0
19247 fi
19248
19249 cat >>confdefs.h <<_ACEOF
19250 #define HAVE_DECL_MBRTOWC $ac_have_decl
19251 _ACEOF
19252
19253 if test $ac_cv_have_decl_mbrtowc = yes; then
19254 REPLACE_MBRTOWC=1
19255 fi
19256 else
19257 if test $REPLACE_MBSTATE_T = 1; then
19258 REPLACE_MBRTOWC=1
19259 else
19260
19261
19262
19263 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles a NULL pwc argument" >&5
19264 $as_echo_n "checking whether mbrtowc handles a NULL pwc argument... " >&6; }
19265 if ${gl_cv_func_mbrtowc_null_arg1+:} false; then :
19266 $as_echo_n "(cached) " >&6
19267 else
19268
19269 case "$host_os" in
19270 # Guess no on Solaris.
19271 solaris*) gl_cv_func_mbrtowc_null_arg1="guessing no" ;;
19272 # Guess yes otherwise.
19273 *) gl_cv_func_mbrtowc_null_arg1="guessing yes" ;;
19274 esac
19275 if test $LOCALE_FR_UTF8 != none; then
19276 if test "$cross_compiling" = yes; then :
19277 :
19278 else
19279 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19280 /* end confdefs.h. */
19281
19282 #include <locale.h>
19283 #include <stdlib.h>
19284 #include <string.h>
19285 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19286 <wchar.h>.
19287 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19288 included before <wchar.h>. */
19289 #include <stddef.h>
19290 #include <stdio.h>
19291 #include <time.h>
19292 #include <wchar.h>
19293 int main ()
19294 {
19295 int result = 0;
19296
19297 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
19298 {
19299 char input[] = "\303\237er";
19300 mbstate_t state;
19301 wchar_t wc;
19302 size_t ret;
19303
19304 memset (&state, '\0', sizeof (mbstate_t));
19305 wc = (wchar_t) 0xBADFACE;
19306 ret = mbrtowc (&wc, input, 5, &state);
19307 if (ret != 2)
19308 result |= 1;
19309 if (!mbsinit (&state))
19310 result |= 2;
19311
19312 memset (&state, '\0', sizeof (mbstate_t));
19313 ret = mbrtowc (NULL, input, 5, &state);
19314 if (ret != 2) /* Solaris 7 fails here: ret is -1. */
19315 result |= 4;
19316 if (!mbsinit (&state))
19317 result |= 8;
19318 }
19319 return result;
19320 }
19321 _ACEOF
19322 if ac_fn_c_try_run "$LINENO"; then :
19323 gl_cv_func_mbrtowc_null_arg1=yes
19324 else
19325 gl_cv_func_mbrtowc_null_arg1=no
19326 fi
19327 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19328 conftest.$ac_objext conftest.beam conftest.$ac_ext
19329 fi
19330
19331 fi
19332
19333 fi
19334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_null_arg1" >&5
19335 $as_echo "$gl_cv_func_mbrtowc_null_arg1" >&6; }
19336
19337
19338
19339
19340 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles a NULL string argument" >&5
19341 $as_echo_n "checking whether mbrtowc handles a NULL string argument... " >&6; }
19342 if ${gl_cv_func_mbrtowc_null_arg2+:} false; then :
19343 $as_echo_n "(cached) " >&6
19344 else
19345
19346 case "$host_os" in
19347 # Guess no on OSF/1.
19348 osf*) gl_cv_func_mbrtowc_null_arg2="guessing no" ;;
19349 # Guess yes otherwise.
19350 *) gl_cv_func_mbrtowc_null_arg2="guessing yes" ;;
19351 esac
19352 if test $LOCALE_FR_UTF8 != none; then
19353 if test "$cross_compiling" = yes; then :
19354 :
19355 else
19356 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19357 /* end confdefs.h. */
19358
19359 #include <locale.h>
19360 #include <string.h>
19361 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19362 <wchar.h>.
19363 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19364 included before <wchar.h>. */
19365 #include <stddef.h>
19366 #include <stdio.h>
19367 #include <time.h>
19368 #include <wchar.h>
19369 int main ()
19370 {
19371 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
19372 {
19373 mbstate_t state;
19374 wchar_t wc;
19375 int ret;
19376
19377 memset (&state, '\0', sizeof (mbstate_t));
19378 wc = (wchar_t) 0xBADFACE;
19379 mbrtowc (&wc, NULL, 5, &state);
19380 /* Check that wc was not modified. */
19381 if (wc != (wchar_t) 0xBADFACE)
19382 return 1;
19383 }
19384 return 0;
19385 }
19386 _ACEOF
19387 if ac_fn_c_try_run "$LINENO"; then :
19388 gl_cv_func_mbrtowc_null_arg2=yes
19389 else
19390 gl_cv_func_mbrtowc_null_arg2=no
19391 fi
19392 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19393 conftest.$ac_objext conftest.beam conftest.$ac_ext
19394 fi
19395
19396 fi
19397
19398 fi
19399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_null_arg2" >&5
19400 $as_echo "$gl_cv_func_mbrtowc_null_arg2" >&6; }
19401
19402
19403
19404
19405
19406
19407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc has a correct return value" >&5
19408 $as_echo_n "checking whether mbrtowc has a correct return value... " >&6; }
19409 if ${gl_cv_func_mbrtowc_retval+:} false; then :
19410 $as_echo_n "(cached) " >&6
19411 else
19412
19413 case "$host_os" in
19414 # Guess no on HP-UX, Solaris, native Windows.
19415 hpux* | solaris* | mingw*) gl_cv_func_mbrtowc_retval="guessing no" ;;
19416 # Guess yes otherwise.
19417 *) gl_cv_func_mbrtowc_retval="guessing yes" ;;
19418 esac
19419 if test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none \
19420 || { case "$host_os" in mingw*) true;; *) false;; esac; }; then
19421 if test "$cross_compiling" = yes; then :
19422 :
19423 else
19424 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19425 /* end confdefs.h. */
19426
19427 #include <locale.h>
19428 #include <string.h>
19429 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19430 <wchar.h>.
19431 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19432 included before <wchar.h>. */
19433 #include <stddef.h>
19434 #include <stdio.h>
19435 #include <time.h>
19436 #include <wchar.h>
19437 int main ()
19438 {
19439 int result = 0;
19440 int found_some_locale = 0;
19441 /* This fails on Solaris. */
19442 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
19443 {
19444 char input[] = "B\303\274\303\237er"; /* "Büßer" */
19445 mbstate_t state;
19446 wchar_t wc;
19447
19448 memset (&state, '\0', sizeof (mbstate_t));
19449 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
19450 {
19451 input[1] = '\0';
19452 if (mbrtowc (&wc, input + 2, 5, &state) != 1)
19453 result |= 1;
19454 }
19455 found_some_locale = 1;
19456 }
19457 /* This fails on HP-UX 11.11. */
19458 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
19459 {
19460 char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
19461 mbstate_t state;
19462 wchar_t wc;
19463
19464 memset (&state, '\0', sizeof (mbstate_t));
19465 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
19466 {
19467 input[1] = '\0';
19468 if (mbrtowc (&wc, input + 2, 5, &state) != 2)
19469 result |= 2;
19470 }
19471 found_some_locale = 1;
19472 }
19473 /* This fails on native Windows. */
19474 if (setlocale (LC_ALL, "Japanese_Japan.932") != NULL)
19475 {
19476 char input[] = "<\223\372\226\173\214\352>"; /* "<日本語>" */
19477 mbstate_t state;
19478 wchar_t wc;
19479
19480 memset (&state, '\0', sizeof (mbstate_t));
19481 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
19482 {
19483 input[3] = '\0';
19484 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
19485 result |= 4;
19486 }
19487 found_some_locale = 1;
19488 }
19489 if (setlocale (LC_ALL, "Chinese_Taiwan.950") != NULL)
19490 {
19491 char input[] = "<\244\351\245\273\273\171>"; /* "<日本語>" */
19492 mbstate_t state;
19493 wchar_t wc;
19494
19495 memset (&state, '\0', sizeof (mbstate_t));
19496 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
19497 {
19498 input[3] = '\0';
19499 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
19500 result |= 8;
19501 }
19502 found_some_locale = 1;
19503 }
19504 if (setlocale (LC_ALL, "Chinese_China.936") != NULL)
19505 {
19506 char input[] = "<\310\325\261\276\325\132>"; /* "<日本語>" */
19507 mbstate_t state;
19508 wchar_t wc;
19509
19510 memset (&state, '\0', sizeof (mbstate_t));
19511 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
19512 {
19513 input[3] = '\0';
19514 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
19515 result |= 16;
19516 }
19517 found_some_locale = 1;
19518 }
19519 return (found_some_locale ? result : 77);
19520 }
19521 _ACEOF
19522 if ac_fn_c_try_run "$LINENO"; then :
19523 gl_cv_func_mbrtowc_retval=yes
19524 else
19525 if test $? != 77; then
19526 gl_cv_func_mbrtowc_retval=no
19527 fi
19528
19529 fi
19530 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19531 conftest.$ac_objext conftest.beam conftest.$ac_ext
19532 fi
19533
19534 fi
19535
19536 fi
19537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_retval" >&5
19538 $as_echo "$gl_cv_func_mbrtowc_retval" >&6; }
19539
19540
19541
19542
19543 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc returns 0 when parsing a NUL character" >&5
19544 $as_echo_n "checking whether mbrtowc returns 0 when parsing a NUL character... " >&6; }
19545 if ${gl_cv_func_mbrtowc_nul_retval+:} false; then :
19546 $as_echo_n "(cached) " >&6
19547 else
19548
19549 case "$host_os" in
19550 # Guess no on Solaris 8 and 9.
19551 solaris2.[89]) gl_cv_func_mbrtowc_nul_retval="guessing no" ;;
19552 # Guess yes otherwise.
19553 *) gl_cv_func_mbrtowc_nul_retval="guessing yes" ;;
19554 esac
19555 if test $LOCALE_ZH_CN != none; then
19556 if test "$cross_compiling" = yes; then :
19557 :
19558 else
19559 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19560 /* end confdefs.h. */
19561
19562 #include <locale.h>
19563 #include <string.h>
19564 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19565 <wchar.h>.
19566 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19567 included before <wchar.h>. */
19568 #include <stddef.h>
19569 #include <stdio.h>
19570 #include <time.h>
19571 #include <wchar.h>
19572 int main ()
19573 {
19574 /* This fails on Solaris 8 and 9. */
19575 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
19576 {
19577 mbstate_t state;
19578 wchar_t wc;
19579
19580 memset (&state, '\0', sizeof (mbstate_t));
19581 if (mbrtowc (&wc, "", 1, &state) != 0)
19582 return 1;
19583 }
19584 return 0;
19585 }
19586 _ACEOF
19587 if ac_fn_c_try_run "$LINENO"; then :
19588 gl_cv_func_mbrtowc_nul_retval=yes
19589 else
19590 gl_cv_func_mbrtowc_nul_retval=no
19591 fi
19592 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19593 conftest.$ac_objext conftest.beam conftest.$ac_ext
19594 fi
19595
19596 fi
19597
19598 fi
19599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_nul_retval" >&5
19600 $as_echo "$gl_cv_func_mbrtowc_nul_retval" >&6; }
19601
19602
19603
19604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works on empty input" >&5
19605 $as_echo_n "checking whether mbrtowc works on empty input... " >&6; }
19606 if ${gl_cv_func_mbrtowc_empty_input+:} false; then :
19607 $as_echo_n "(cached) " >&6
19608 else
19609
19610 case "$host_os" in
19611 # Guess no on AIX and glibc systems.
19612 aix* | *-gnu*)
19613 gl_cv_func_mbrtowc_empty_input="guessing no" ;;
19614 *) gl_cv_func_mbrtowc_empty_input="guessing yes" ;;
19615 esac
19616 if test "$cross_compiling" = yes; then :
19617 :
19618 else
19619 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19620 /* end confdefs.h. */
19621
19622 #include <wchar.h>
19623 static wchar_t wc;
19624 static mbstate_t mbs;
19625 int
19626 main (void)
19627 {
19628 return mbrtowc (&wc, "", 0, &mbs) != (size_t) -2;
19629 }
19630 _ACEOF
19631 if ac_fn_c_try_run "$LINENO"; then :
19632 gl_cv_func_mbrtowc_empty_input=yes
19633 else
19634 gl_cv_func_mbrtowc_empty_input=no
19635 fi
19636 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19637 conftest.$ac_objext conftest.beam conftest.$ac_ext
19638 fi
19639
19640
19641 fi
19642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_empty_input" >&5
19643 $as_echo "$gl_cv_func_mbrtowc_empty_input" >&6; }
19644
19645
19646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C locale is free of encoding errors" >&5
19647 $as_echo_n "checking whether the C locale is free of encoding errors... " >&6; }
19648 if ${gl_cv_C_locale_sans_EILSEQ+:} false; then :
19649 $as_echo_n "(cached) " >&6
19650 else
19651
19652 gl_cv_C_locale_sans_EILSEQ="guessing no"
19653
19654 if test "$cross_compiling" = yes; then :
19655 :
19656 else
19657 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19658 /* end confdefs.h. */
19659 #include <limits.h>
19660 #include <locale.h>
19661 #include <wchar.h>
19662
19663 int
19664 main ()
19665 {
19666
19667 int i;
19668 char *locale = setlocale (LC_ALL, "C");
19669 if (! locale)
19670 return 1;
19671 for (i = CHAR_MIN; i <= CHAR_MAX; i++)
19672 {
19673 char c = i;
19674 wchar_t wc;
19675 mbstate_t mbs = { 0, };
19676 size_t ss = mbrtowc (&wc, &c, 1, &mbs);
19677 if (1 < ss)
19678 return 1;
19679 }
19680 return 0;
19681
19682 ;
19683 return 0;
19684 }
19685 _ACEOF
19686 if ac_fn_c_try_run "$LINENO"; then :
19687 gl_cv_C_locale_sans_EILSEQ=yes
19688 else
19689 gl_cv_C_locale_sans_EILSEQ=no
19690 fi
19691 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19692 conftest.$ac_objext conftest.beam conftest.$ac_ext
19693 fi
19694
19695 fi
19696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_C_locale_sans_EILSEQ" >&5
19697 $as_echo "$gl_cv_C_locale_sans_EILSEQ" >&6; }
19698
19699 case "$gl_cv_func_mbrtowc_null_arg1" in
19700 *yes) ;;
19701 *)
19702 $as_echo "#define MBRTOWC_NULL_ARG1_BUG 1" >>confdefs.h
19703
19704 REPLACE_MBRTOWC=1
19705 ;;
19706 esac
19707 case "$gl_cv_func_mbrtowc_null_arg2" in
19708 *yes) ;;
19709 *)
19710 $as_echo "#define MBRTOWC_NULL_ARG2_BUG 1" >>confdefs.h
19711
19712 REPLACE_MBRTOWC=1
19713 ;;
19714 esac
19715 case "$gl_cv_func_mbrtowc_retval" in
19716 *yes) ;;
19717 *)
19718 $as_echo "#define MBRTOWC_RETVAL_BUG 1" >>confdefs.h
19719
19720 REPLACE_MBRTOWC=1
19721 ;;
19722 esac
19723 case "$gl_cv_func_mbrtowc_nul_retval" in
19724 *yes) ;;
19725 *)
19726 $as_echo "#define MBRTOWC_NUL_RETVAL_BUG 1" >>confdefs.h
19727
19728 REPLACE_MBRTOWC=1
19729 ;;
19730 esac
19731 case "$gl_cv_func_mbrtowc_empty_input" in
19732 *yes) ;;
19733 *)
19734 $as_echo "#define MBRTOWC_EMPTY_INPUT_BUG 1" >>confdefs.h
19735
19736 REPLACE_MBRTOWC=1
19737 ;;
19738 esac
19739 case $gl_cv_C_locale_sans_EILSEQ in
19740 *yes) ;;
19741 *)
19742 $as_echo "#define C_LOCALE_MAYBE_EILSEQ 1" >>confdefs.h
19743
19744 REPLACE_MBRTOWC=1
19745 ;;
19746 esac
19747 fi
19748 fi
19749
19750 if test $HAVE_MBRTOWC = 0 || test $REPLACE_MBRTOWC = 1; then
19751
19752
19753
19754
19755
19756
19757
19758
19759 gl_LIBOBJS="$gl_LIBOBJS mbrtowc.$ac_objext"
19760
19761
19762 :
19763
19764 fi
19765
19766
19767
19768
19769
19770 GNULIB_MBRTOWC=1
19771
19772
19773
19774
19775
19776 $as_echo "#define GNULIB_TEST_MBRTOWC 1" >>confdefs.h
19777
19778
19779
19780
19781
19782
19783
19784
19785
19786
19787
19788
19789
19790 :
19791
19792
19793
19794
19795
19796
19797 :
19798
19799
19800
19801
19802
19803 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
19804
19805
19806
19807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
19808 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
19809 if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then :
19810 $as_echo_n "(cached) " >&6
19811 else
19812
19813 case "$host_os" in
19814 # Guess no on AIX and OSF/1.
19815 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
19816 # Guess yes otherwise.
19817 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
19818 esac
19819 if test $LOCALE_JA != none; then
19820 if test "$cross_compiling" = yes; then :
19821 :
19822 else
19823 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19824 /* end confdefs.h. */
19825
19826 #include <locale.h>
19827 #include <string.h>
19828 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19829 <wchar.h>.
19830 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19831 included before <wchar.h>. */
19832 #include <stddef.h>
19833 #include <stdio.h>
19834 #include <time.h>
19835 #include <wchar.h>
19836 int main ()
19837 {
19838 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
19839 {
19840 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
19841 mbstate_t state;
19842 wchar_t wc;
19843
19844 memset (&state, '\0', sizeof (mbstate_t));
19845 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
19846 if (mbsinit (&state))
19847 return 1;
19848 }
19849 return 0;
19850 }
19851 _ACEOF
19852 if ac_fn_c_try_run "$LINENO"; then :
19853 gl_cv_func_mbrtowc_incomplete_state=yes
19854 else
19855 gl_cv_func_mbrtowc_incomplete_state=no
19856 fi
19857 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19858 conftest.$ac_objext conftest.beam conftest.$ac_ext
19859 fi
19860
19861 fi
19862
19863 fi
19864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
19865 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
19866
19867
19868
19869
19870 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
19871 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
19872 if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then :
19873 $as_echo_n "(cached) " >&6
19874 else
19875
19876 case "$host_os" in
19877 # Guess no on Solaris 8.
19878 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
19879 # Guess yes otherwise.
19880 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
19881 esac
19882 if test $LOCALE_ZH_CN != none; then
19883 if test "$cross_compiling" = yes; then :
19884 :
19885 else
19886 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19887 /* end confdefs.h. */
19888
19889 #include <locale.h>
19890 #include <stdlib.h>
19891 #include <string.h>
19892 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19893 <wchar.h>.
19894 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19895 included before <wchar.h>. */
19896 #include <stddef.h>
19897 #include <stdio.h>
19898 #include <time.h>
19899 #include <wchar.h>
19900 int main ()
19901 {
19902 /* This fails on Solaris 8:
19903 mbrtowc returns 2, and sets wc to 0x00F0.
19904 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
19905 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
19906 {
19907 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
19908 mbstate_t state;
19909 wchar_t wc;
19910
19911 memset (&state, '\0', sizeof (mbstate_t));
19912 if (mbrtowc (&wc, input + 3, 6, &state) != 4
19913 && mbtowc (&wc, input + 3, 6) == 4)
19914 return 1;
19915 }
19916 return 0;
19917 }
19918 _ACEOF
19919 if ac_fn_c_try_run "$LINENO"; then :
19920 gl_cv_func_mbrtowc_sanitycheck=yes
19921 else
19922 gl_cv_func_mbrtowc_sanitycheck=no
19923 fi
19924 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19925 conftest.$ac_objext conftest.beam conftest.$ac_ext
19926 fi
19927
19928 fi
19929
19930 fi
19931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
19932 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
19933
19934 REPLACE_MBSTATE_T=0
19935 case "$gl_cv_func_mbrtowc_incomplete_state" in
19936 *yes) ;;
19937 *) REPLACE_MBSTATE_T=1 ;;
19938 esac
19939 case "$gl_cv_func_mbrtowc_sanitycheck" in
19940 *yes) ;;
19941 *) REPLACE_MBSTATE_T=1 ;;
19942 esac
19943 else
19944 REPLACE_MBSTATE_T=1
19945 fi
19946
19947
19948
19949 :
19950
19951
19952
19953
19954
19955 if test $ac_cv_func_mbsinit = no; then
19956 HAVE_MBSINIT=0
19957 ac_fn_c_check_decl "$LINENO" "mbsinit" "ac_cv_have_decl_mbsinit" "
19958 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19959 <wchar.h>.
19960 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19961 included before <wchar.h>. */
19962 #include <stddef.h>
19963 #include <stdio.h>
19964 #include <time.h>
19965 #include <wchar.h>
19966
19967 "
19968 if test "x$ac_cv_have_decl_mbsinit" = xyes; then :
19969 ac_have_decl=1
19970 else
19971 ac_have_decl=0
19972 fi
19973
19974 cat >>confdefs.h <<_ACEOF
19975 #define HAVE_DECL_MBSINIT $ac_have_decl
19976 _ACEOF
19977
19978 if test $ac_cv_have_decl_mbsinit = yes; then
19979 REPLACE_MBSINIT=1
19980 fi
19981 else
19982 if test $REPLACE_MBSTATE_T = 1; then
19983 REPLACE_MBSINIT=1
19984 else
19985 case "$host_os" in
19986 mingw*) REPLACE_MBSINIT=1 ;;
19987 esac
19988 fi
19989 fi
19990
19991 if test $HAVE_MBSINIT = 0 || test $REPLACE_MBSINIT = 1; then
19992
19993
19994
19995
19996
19997
19998
19999
20000 gl_LIBOBJS="$gl_LIBOBJS mbsinit.$ac_objext"
20001
20002
20003 :
20004
20005 fi
20006
20007
20008
20009
20010
20011 GNULIB_MBSINIT=1
20012
20013
20014
20015
20016
20017 $as_echo "#define GNULIB_TEST_MBSINIT 1" >>confdefs.h
20018
20019
20020
20021
20022
20023
20024
20025
20026
20027
20028
20029
20030 :
20031
20032
20033
20034
20035
20036
20037 :
20038
20039
20040
20041
20042
20043 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
20044
20045
20046
20047 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
20048 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
20049 if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then :
20050 $as_echo_n "(cached) " >&6
20051 else
20052
20053 case "$host_os" in
20054 # Guess no on AIX and OSF/1.
20055 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
20056 # Guess yes otherwise.
20057 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
20058 esac
20059 if test $LOCALE_JA != none; then
20060 if test "$cross_compiling" = yes; then :
20061 :
20062 else
20063 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20064 /* end confdefs.h. */
20065
20066 #include <locale.h>
20067 #include <string.h>
20068 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
20069 <wchar.h>.
20070 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20071 included before <wchar.h>. */
20072 #include <stddef.h>
20073 #include <stdio.h>
20074 #include <time.h>
20075 #include <wchar.h>
20076 int main ()
20077 {
20078 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
20079 {
20080 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
20081 mbstate_t state;
20082 wchar_t wc;
20083
20084 memset (&state, '\0', sizeof (mbstate_t));
20085 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
20086 if (mbsinit (&state))
20087 return 1;
20088 }
20089 return 0;
20090 }
20091 _ACEOF
20092 if ac_fn_c_try_run "$LINENO"; then :
20093 gl_cv_func_mbrtowc_incomplete_state=yes
20094 else
20095 gl_cv_func_mbrtowc_incomplete_state=no
20096 fi
20097 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20098 conftest.$ac_objext conftest.beam conftest.$ac_ext
20099 fi
20100
20101 fi
20102
20103 fi
20104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
20105 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
20106
20107
20108
20109
20110 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
20111 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
20112 if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then :
20113 $as_echo_n "(cached) " >&6
20114 else
20115
20116 case "$host_os" in
20117 # Guess no on Solaris 8.
20118 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
20119 # Guess yes otherwise.
20120 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
20121 esac
20122 if test $LOCALE_ZH_CN != none; then
20123 if test "$cross_compiling" = yes; then :
20124 :
20125 else
20126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20127 /* end confdefs.h. */
20128
20129 #include <locale.h>
20130 #include <stdlib.h>
20131 #include <string.h>
20132 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
20133 <wchar.h>.
20134 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20135 included before <wchar.h>. */
20136 #include <stddef.h>
20137 #include <stdio.h>
20138 #include <time.h>
20139 #include <wchar.h>
20140 int main ()
20141 {
20142 /* This fails on Solaris 8:
20143 mbrtowc returns 2, and sets wc to 0x00F0.
20144 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
20145 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
20146 {
20147 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
20148 mbstate_t state;
20149 wchar_t wc;
20150
20151 memset (&state, '\0', sizeof (mbstate_t));
20152 if (mbrtowc (&wc, input + 3, 6, &state) != 4
20153 && mbtowc (&wc, input + 3, 6) == 4)
20154 return 1;
20155 }
20156 return 0;
20157 }
20158 _ACEOF
20159 if ac_fn_c_try_run "$LINENO"; then :
20160 gl_cv_func_mbrtowc_sanitycheck=yes
20161 else
20162 gl_cv_func_mbrtowc_sanitycheck=no
20163 fi
20164 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20165 conftest.$ac_objext conftest.beam conftest.$ac_ext
20166 fi
20167
20168 fi
20169
20170 fi
20171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
20172 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
20173
20174 REPLACE_MBSTATE_T=0
20175 case "$gl_cv_func_mbrtowc_incomplete_state" in
20176 *yes) ;;
20177 *) REPLACE_MBSTATE_T=1 ;;
20178 esac
20179 case "$gl_cv_func_mbrtowc_sanitycheck" in
20180 *yes) ;;
20181 *) REPLACE_MBSTATE_T=1 ;;
20182 esac
20183 else
20184 REPLACE_MBSTATE_T=1
20185 fi
20186
20187
20188
20189 :
20190
20191
20192
20193
20194
20195 if test $ac_cv_func_mbsrtowcs = no; then
20196 HAVE_MBSRTOWCS=0
20197 ac_fn_c_check_decl "$LINENO" "mbsrtowcs" "ac_cv_have_decl_mbsrtowcs" "
20198 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
20199 <wchar.h>.
20200 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20201 included before <wchar.h>. */
20202 #include <stddef.h>
20203 #include <stdio.h>
20204 #include <time.h>
20205 #include <wchar.h>
20206
20207 "
20208 if test "x$ac_cv_have_decl_mbsrtowcs" = xyes; then :
20209 ac_have_decl=1
20210 else
20211 ac_have_decl=0
20212 fi
20213
20214 cat >>confdefs.h <<_ACEOF
20215 #define HAVE_DECL_MBSRTOWCS $ac_have_decl
20216 _ACEOF
20217
20218 if test $ac_cv_have_decl_mbsrtowcs = yes; then
20219 REPLACE_MBSRTOWCS=1
20220 fi
20221 else
20222 if test $REPLACE_MBSTATE_T = 1; then
20223 REPLACE_MBSRTOWCS=1
20224 else
20225
20226
20227
20228
20229
20230
20231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbsrtowcs works" >&5
20232 $as_echo_n "checking whether mbsrtowcs works... " >&6; }
20233 if ${gl_cv_func_mbsrtowcs_works+:} false; then :
20234 $as_echo_n "(cached) " >&6
20235 else
20236
20237 case "$host_os" in
20238 # Guess no on HP-UX, Solaris, mingw.
20239 hpux* | solaris* | mingw*) gl_cv_func_mbsrtowcs_works="guessing no" ;;
20240 # Guess yes otherwise.
20241 *) gl_cv_func_mbsrtowcs_works="guessing yes" ;;
20242 esac
20243 if test $LOCALE_FR != none || test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none || test $LOCALE_ZH_CN != none; then
20244 if test "$cross_compiling" = yes; then :
20245 :
20246 else
20247 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20248 /* end confdefs.h. */
20249
20250 #include <locale.h>
20251 #include <string.h>
20252 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
20253 <wchar.h>.
20254 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20255 included before <wchar.h>. */
20256 #include <stddef.h>
20257 #include <stdio.h>
20258 #include <time.h>
20259 #include <wchar.h>
20260 int main ()
20261 {
20262 int result = 0;
20263 /* Test whether the function supports a NULL destination argument.
20264 This fails on native Windows. */
20265 if (setlocale (LC_ALL, "$LOCALE_FR") != NULL)
20266 {
20267 const char input[] = "\337er";
20268 const char *src = input;
20269 mbstate_t state;
20270
20271 memset (&state, '\0', sizeof (mbstate_t));
20272 if (mbsrtowcs (NULL, &src, 1, &state) != 3
20273 || src != input)
20274 result |= 1;
20275 }
20276 /* Test whether the function works when started with a conversion state
20277 in non-initial state. This fails on HP-UX 11.11 and Solaris 10. */
20278 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
20279 {
20280 const char input[] = "B\303\274\303\237er";
20281 mbstate_t state;
20282
20283 memset (&state, '\0', sizeof (mbstate_t));
20284 if (mbrtowc (NULL, input + 1, 1, &state) == (size_t)(-2))
20285 if (!mbsinit (&state))
20286 {
20287 const char *src = input + 2;
20288 if (mbsrtowcs (NULL, &src, 10, &state) != 4)
20289 result |= 2;
20290 }
20291 }
20292 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
20293 {
20294 const char input[] = "<\306\374\313\334\270\354>";
20295 mbstate_t state;
20296
20297 memset (&state, '\0', sizeof (mbstate_t));
20298 if (mbrtowc (NULL, input + 3, 1, &state) == (size_t)(-2))
20299 if (!mbsinit (&state))
20300 {
20301 const char *src = input + 4;
20302 if (mbsrtowcs (NULL, &src, 10, &state) != 3)
20303 result |= 4;
20304 }
20305 }
20306 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
20307 {
20308 const char input[] = "B\250\271\201\060\211\070er";
20309 mbstate_t state;
20310
20311 memset (&state, '\0', sizeof (mbstate_t));
20312 if (mbrtowc (NULL, input + 1, 1, &state) == (size_t)(-2))
20313 if (!mbsinit (&state))
20314 {
20315 const char *src = input + 2;
20316 if (mbsrtowcs (NULL, &src, 10, &state) != 4)
20317 result |= 8;
20318 }
20319 }
20320 return result;
20321 }
20322 _ACEOF
20323 if ac_fn_c_try_run "$LINENO"; then :
20324 gl_cv_func_mbsrtowcs_works=yes
20325 else
20326 gl_cv_func_mbsrtowcs_works=no
20327 fi
20328 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20329 conftest.$ac_objext conftest.beam conftest.$ac_ext
20330 fi
20331
20332 fi
20333
20334 fi
20335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbsrtowcs_works" >&5
20336 $as_echo "$gl_cv_func_mbsrtowcs_works" >&6; }
20337
20338 case "$gl_cv_func_mbsrtowcs_works" in
20339 *yes) ;;
20340 *) REPLACE_MBSRTOWCS=1 ;;
20341 esac
20342 fi
20343 fi
20344
20345 if test $HAVE_MBSRTOWCS = 0 || test $REPLACE_MBSRTOWCS = 1; then
20346
20347
20348
20349
20350
20351
20352
20353
20354 gl_LIBOBJS="$gl_LIBOBJS mbsrtowcs.$ac_objext"
20355
20356
20357
20358
20359
20360
20361
20362
20363
20364 gl_LIBOBJS="$gl_LIBOBJS mbsrtowcs-state.$ac_objext"
20365
20366
20367 :
20368
20369 fi
20370
20371
20372
20373
20374
20375 GNULIB_MBSRTOWCS=1
20376
20377
20378
20379
20380
20381 $as_echo "#define GNULIB_TEST_MBSRTOWCS 1" >>confdefs.h
20382
20383
20384
20385
20386 if test $HAVE_MEMCHR = 0 || test $REPLACE_MEMCHR = 1; then
20387
20388
20389
20390
20391
20392
20393
20394
20395 gl_LIBOBJS="$gl_LIBOBJS memchr.$ac_objext"
20396
20397
20398 for ac_header in bp-sym.h
20399 do :
20400 ac_fn_c_check_header_mongrel "$LINENO" "bp-sym.h" "ac_cv_header_bp_sym_h" "$ac_includes_default"
20401 if test "x$ac_cv_header_bp_sym_h" = xyes; then :
20402 cat >>confdefs.h <<_ACEOF
20403 #define HAVE_BP_SYM_H 1
20404 _ACEOF
20405
20406 fi
20407
20408 done
20409
20410
20411 fi
20412
20413
20414
20415
20416
20417 GNULIB_MEMCHR=1
20418
20419
20420
20421
20422
20423 $as_echo "#define GNULIB_TEST_MEMCHR 1" >>confdefs.h
20424
20425
20426
20427
20428
20429 if test $HAVE_DECL_MEMMEM = 1 && test $REPLACE_MEMMEM = 0; then
20430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memmem works in linear time" >&5
20431 $as_echo_n "checking whether memmem works in linear time... " >&6; }
20432 if ${gl_cv_func_memmem_works_fast+:} false; then :
20433 $as_echo_n "(cached) " >&6
20434 else
20435 if test "$cross_compiling" = yes; then :
20436 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20437 /* end confdefs.h. */
20438
20439 #include <features.h>
20440 #ifdef __GNU_LIBRARY__
20441 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 9) || (__GLIBC__ > 2)) \
20442 && !defined __UCLIBC__
20443 Lucky user
20444 #endif
20445 #endif
20446 #ifdef __CYGWIN__
20447 #include <cygwin/version.h>
20448 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 0)
20449 Lucky user
20450 #endif
20451 #endif
20452
20453 _ACEOF
20454 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20455 $EGREP "Lucky user" >/dev/null 2>&1; then :
20456 gl_cv_func_memmem_works_fast="guessing yes"
20457 else
20458 gl_cv_func_memmem_works_fast="guessing no"
20459 fi
20460 rm -f conftest*
20461
20462
20463 else
20464 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20465 /* end confdefs.h. */
20466
20467 #include <signal.h> /* for signal */
20468 #include <string.h> /* for memmem */
20469 #include <stdlib.h> /* for malloc */
20470 #include <unistd.h> /* for alarm */
20471 static void quit (int sig) { _exit (sig + 128); }
20472
20473 int
20474 main ()
20475 {
20476
20477 int result = 0;
20478 size_t m = 1000000;
20479 char *haystack = (char *) malloc (2 * m + 1);
20480 char *needle = (char *) malloc (m + 1);
20481 /* Failure to compile this test due to missing alarm is okay,
20482 since all such platforms (mingw) also lack memmem. */
20483 signal (SIGALRM, quit);
20484 alarm (5);
20485 /* Check for quadratic performance. */
20486 if (haystack && needle)
20487 {
20488 memset (haystack, 'A', 2 * m);
20489 haystack[2 * m] = 'B';
20490 memset (needle, 'A', m);
20491 needle[m] = 'B';
20492 if (!memmem (haystack, 2 * m + 1, needle, m + 1))
20493 result |= 1;
20494 }
20495 return result;
20496
20497 ;
20498 return 0;
20499 }
20500 _ACEOF
20501 if ac_fn_c_try_run "$LINENO"; then :
20502 gl_cv_func_memmem_works_fast=yes
20503 else
20504 gl_cv_func_memmem_works_fast=no
20505 fi
20506 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20507 conftest.$ac_objext conftest.beam conftest.$ac_ext
20508 fi
20509
20510
20511 fi
20512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memmem_works_fast" >&5
20513 $as_echo "$gl_cv_func_memmem_works_fast" >&6; }
20514 case "$gl_cv_func_memmem_works_fast" in
20515 *yes) ;;
20516 *)
20517 REPLACE_MEMMEM=1
20518 ;;
20519 esac
20520 fi
20521
20522 if test $HAVE_MEMMEM = 0 || test $REPLACE_MEMMEM = 1; then
20523
20524
20525
20526
20527
20528
20529
20530
20531 gl_LIBOBJS="$gl_LIBOBJS memmem.$ac_objext"
20532
20533 fi
20534
20535
20536
20537
20538 for ac_func in memmem
20539 do :
20540 ac_fn_c_check_func "$LINENO" "memmem" "ac_cv_func_memmem"
20541 if test "x$ac_cv_func_memmem" = xyes; then :
20542 cat >>confdefs.h <<_ACEOF
20543 #define HAVE_MEMMEM 1
20544 _ACEOF
20545
20546 fi
20547 done
20548
20549 if test $ac_cv_func_memmem = yes; then
20550 HAVE_MEMMEM=1
20551 else
20552 HAVE_MEMMEM=0
20553 fi
20554
20555 :
20556
20557
20558
20559
20560
20561 if test $ac_cv_have_decl_memmem = no; then
20562 HAVE_DECL_MEMMEM=0
20563 else
20564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memmem works" >&5
20565 $as_echo_n "checking whether memmem works... " >&6; }
20566 if ${gl_cv_func_memmem_works_always+:} false; then :
20567 $as_echo_n "(cached) " >&6
20568 else
20569 if test "$cross_compiling" = yes; then :
20570 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20571 /* end confdefs.h. */
20572
20573 #ifdef __GNU_LIBRARY__
20574 #include <features.h>
20575 #if ((__GLIBC__ == 2 && ((__GLIBC_MINOR > 0 && __GLIBC_MINOR__ < 9) \
20576 || __GLIBC_MINOR__ > 12)) \
20577 || (__GLIBC__ > 2)) \
20578 || defined __UCLIBC__
20579 Lucky user
20580 #endif
20581 #elif defined __CYGWIN__
20582 #include <cygwin/version.h>
20583 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
20584 Lucky user
20585 #endif
20586 #else
20587 Lucky user
20588 #endif
20589
20590 _ACEOF
20591 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20592 $EGREP "Lucky user" >/dev/null 2>&1; then :
20593 gl_cv_func_memmem_works_always="guessing yes"
20594 else
20595 gl_cv_func_memmem_works_always="guessing no"
20596 fi
20597 rm -f conftest*
20598
20599
20600 else
20601 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20602 /* end confdefs.h. */
20603
20604 #include <string.h> /* for memmem */
20605 #define P "_EF_BF_BD"
20606 #define HAYSTACK "F_BD_CE_BD" P P P P "_C3_88_20" P P P "_C3_A7_20" P
20607 #define NEEDLE P P P P P
20608
20609 int
20610 main ()
20611 {
20612
20613 int result = 0;
20614 if (memmem (HAYSTACK, strlen (HAYSTACK), NEEDLE, strlen (NEEDLE)))
20615 result |= 1;
20616 /* Check for empty needle behavior. */
20617 {
20618 const char *haystack = "AAA";
20619 if (memmem (haystack, 3, NULL, 0) != haystack)
20620 result |= 2;
20621 }
20622 return result;
20623
20624 ;
20625 return 0;
20626 }
20627 _ACEOF
20628 if ac_fn_c_try_run "$LINENO"; then :
20629 gl_cv_func_memmem_works_always=yes
20630 else
20631 gl_cv_func_memmem_works_always=no
20632 fi
20633 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20634 conftest.$ac_objext conftest.beam conftest.$ac_ext
20635 fi
20636
20637
20638 fi
20639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memmem_works_always" >&5
20640 $as_echo "$gl_cv_func_memmem_works_always" >&6; }
20641 case "$gl_cv_func_memmem_works_always" in
20642 *yes) ;;
20643 *)
20644 REPLACE_MEMMEM=1
20645 ;;
20646 esac
20647 fi
20648 :
20649
20650 if test $HAVE_MEMMEM = 0 || test $REPLACE_MEMMEM = 1; then
20651
20652
20653
20654
20655
20656
20657
20658
20659 gl_LIBOBJS="$gl_LIBOBJS memmem.$ac_objext"
20660
20661 fi
20662
20663
20664
20665
20666
20667 GNULIB_MEMMEM=1
20668
20669
20670
20671
20672
20673 $as_echo "#define GNULIB_TEST_MEMMEM 1" >>confdefs.h
20674
20675
20676
20677
20678
20679
20680
20681
20682
20683 for ac_func in mempcpy
20684 do :
20685 ac_fn_c_check_func "$LINENO" "mempcpy" "ac_cv_func_mempcpy"
20686 if test "x$ac_cv_func_mempcpy" = xyes; then :
20687 cat >>confdefs.h <<_ACEOF
20688 #define HAVE_MEMPCPY 1
20689 _ACEOF
20690
20691 fi
20692 done
20693
20694 if test $ac_cv_func_mempcpy = no; then
20695 HAVE_MEMPCPY=0
20696 fi
20697
20698 if test $HAVE_MEMPCPY = 0; then
20699
20700
20701
20702
20703
20704
20705
20706
20707 gl_LIBOBJS="$gl_LIBOBJS mempcpy.$ac_objext"
20708
20709
20710 :
20711
20712 fi
20713
20714
20715
20716
20717
20718 GNULIB_MEMPCPY=1
20719
20720
20721
20722
20723
20724 $as_echo "#define GNULIB_TEST_MEMPCPY 1" >>confdefs.h
20725
20726
20727
20728
20729
20730
20731
20732
20733 :
20734
20735
20736
20737
20738
20739 if test $ac_cv_have_decl_memrchr = no; then
20740 HAVE_DECL_MEMRCHR=0
20741 fi
20742
20743 for ac_func in memrchr
20744 do :
20745 ac_fn_c_check_func "$LINENO" "memrchr" "ac_cv_func_memrchr"
20746 if test "x$ac_cv_func_memrchr" = xyes; then :
20747 cat >>confdefs.h <<_ACEOF
20748 #define HAVE_MEMRCHR 1
20749 _ACEOF
20750
20751 fi
20752 done
20753
20754
20755 if test $ac_cv_func_memrchr = no; then
20756
20757
20758
20759
20760
20761
20762
20763
20764 gl_LIBOBJS="$gl_LIBOBJS memrchr.$ac_objext"
20765
20766 :
20767 fi
20768
20769
20770
20771
20772
20773 GNULIB_MEMRCHR=1
20774
20775
20776
20777
20778
20779 $as_echo "#define GNULIB_TEST_MEMRCHR 1" >>confdefs.h
20780
20781
20782
20783
20784
20785 :
20786
20787
20788
20789
20790
20791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mkdir handles trailing slash" >&5
20792 $as_echo_n "checking whether mkdir handles trailing slash... " >&6; }
20793 if ${gl_cv_func_mkdir_trailing_slash_works+:} false; then :
20794 $as_echo_n "(cached) " >&6
20795 else
20796 rm -rf conftest.dir
20797 if test "$cross_compiling" = yes; then :
20798 case "$host_os" in
20799 # Guess yes on glibc systems.
20800 *-gnu*) gl_cv_func_mkdir_trailing_slash_works="guessing yes" ;;
20801 # If we don't know, assume the worst.
20802 *) gl_cv_func_mkdir_trailing_slash_works="guessing no" ;;
20803 esac
20804
20805 else
20806 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20807 /* end confdefs.h. */
20808
20809 # include <sys/types.h>
20810 # include <sys/stat.h>
20811
20812 int
20813 main ()
20814 {
20815 return mkdir ("conftest.dir/", 0700);
20816 ;
20817 return 0;
20818 }
20819 _ACEOF
20820 if ac_fn_c_try_run "$LINENO"; then :
20821 gl_cv_func_mkdir_trailing_slash_works=yes
20822 else
20823 gl_cv_func_mkdir_trailing_slash_works=no
20824 fi
20825 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20826 conftest.$ac_objext conftest.beam conftest.$ac_ext
20827 fi
20828
20829 rm -rf conftest.dir
20830
20831
20832 fi
20833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mkdir_trailing_slash_works" >&5
20834 $as_echo "$gl_cv_func_mkdir_trailing_slash_works" >&6; }
20835 case "$gl_cv_func_mkdir_trailing_slash_works" in
20836 *yes) ;;
20837 *)
20838 REPLACE_MKDIR=1
20839 ;;
20840 esac
20841
20842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mkdir handles trailing dot" >&5
20843 $as_echo_n "checking whether mkdir handles trailing dot... " >&6; }
20844 if ${gl_cv_func_mkdir_trailing_dot_works+:} false; then :
20845 $as_echo_n "(cached) " >&6
20846 else
20847 rm -rf conftest.dir
20848 if test "$cross_compiling" = yes; then :
20849 case "$host_os" in
20850 # Guess yes on glibc systems.
20851 *-gnu*) gl_cv_func_mkdir_trailing_dot_works="guessing yes" ;;
20852 # If we don't know, assume the worst.
20853 *) gl_cv_func_mkdir_trailing_dot_works="guessing no" ;;
20854 esac
20855
20856 else
20857 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20858 /* end confdefs.h. */
20859
20860 # include <sys/types.h>
20861 # include <sys/stat.h>
20862
20863 int
20864 main ()
20865 {
20866 return !mkdir ("conftest.dir/./", 0700);
20867 ;
20868 return 0;
20869 }
20870 _ACEOF
20871 if ac_fn_c_try_run "$LINENO"; then :
20872 gl_cv_func_mkdir_trailing_dot_works=yes
20873 else
20874 gl_cv_func_mkdir_trailing_dot_works=no
20875 fi
20876 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20877 conftest.$ac_objext conftest.beam conftest.$ac_ext
20878 fi
20879
20880 rm -rf conftest.dir
20881
20882
20883 fi
20884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mkdir_trailing_dot_works" >&5
20885 $as_echo "$gl_cv_func_mkdir_trailing_dot_works" >&6; }
20886 case "$gl_cv_func_mkdir_trailing_dot_works" in
20887 *yes) ;;
20888 *)
20889 REPLACE_MKDIR=1
20890
20891 $as_echo "#define FUNC_MKDIR_DOT_BUG 1" >>confdefs.h
20892
20893 ;;
20894 esac
20895
20896 if test $REPLACE_MKDIR = 1; then
20897
20898
20899
20900
20901
20902
20903
20904
20905 gl_LIBOBJS="$gl_LIBOBJS mkdir.$ac_objext"
20906
20907 fi
20908
20909
20910
20911
20912 :
20913
20914
20915
20916
20917
20918 if test $ac_cv_func_mkstemp = yes; then
20919 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mkstemp" >&5
20920 $as_echo_n "checking for working mkstemp... " >&6; }
20921 if ${gl_cv_func_working_mkstemp+:} false; then :
20922 $as_echo_n "(cached) " >&6
20923 else
20924
20925 mkdir conftest.mkstemp
20926 if test "$cross_compiling" = yes; then :
20927 case "$host_os" in
20928 # Guess yes on glibc systems.
20929 *-gnu*) gl_cv_func_working_mkstemp="guessing yes" ;;
20930 # If we don't know, assume the worst.
20931 *) gl_cv_func_working_mkstemp="guessing no" ;;
20932 esac
20933
20934 else
20935 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20936 /* end confdefs.h. */
20937 $ac_includes_default
20938 int
20939 main ()
20940 {
20941 int result = 0;
20942 int i;
20943 off_t large = (off_t) 4294967295u;
20944 if (large < 0)
20945 large = 2147483647;
20946 umask (0);
20947 for (i = 0; i < 70; i++)
20948 {
20949 char templ[] = "conftest.mkstemp/coXXXXXX";
20950 int (*mkstemp_function) (char *) = mkstemp;
20951 int fd = mkstemp_function (templ);
20952 if (fd < 0)
20953 result |= 1;
20954 else
20955 {
20956 struct stat st;
20957 if (lseek (fd, large, SEEK_SET) != large)
20958 result |= 2;
20959 if (fstat (fd, &st) < 0)
20960 result |= 4;
20961 else if (st.st_mode & 0077)
20962 result |= 8;
20963 if (close (fd))
20964 result |= 16;
20965 }
20966 }
20967 return result;
20968 ;
20969 return 0;
20970 }
20971 _ACEOF
20972 if ac_fn_c_try_run "$LINENO"; then :
20973 gl_cv_func_working_mkstemp=yes
20974 else
20975 gl_cv_func_working_mkstemp=no
20976 fi
20977 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20978 conftest.$ac_objext conftest.beam conftest.$ac_ext
20979 fi
20980
20981 rm -rf conftest.mkstemp
20982
20983 fi
20984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mkstemp" >&5
20985 $as_echo "$gl_cv_func_working_mkstemp" >&6; }
20986 case "$gl_cv_func_working_mkstemp" in
20987 *yes) ;;
20988 *)
20989 REPLACE_MKSTEMP=1
20990 ;;
20991 esac
20992 else
20993 HAVE_MKSTEMP=0
20994 fi
20995
20996 if test $HAVE_MKSTEMP = 0 || test $REPLACE_MKSTEMP = 1; then
20997
20998
20999
21000
21001
21002
21003
21004
21005 gl_LIBOBJS="$gl_LIBOBJS mkstemp.$ac_objext"
21006
21007
21008
21009 fi
21010
21011
21012
21013
21014
21015 GNULIB_MKSTEMP=1
21016
21017
21018
21019
21020
21021 $as_echo "#define GNULIB_TEST_MKSTEMP 1" >>confdefs.h
21022
21023
21024
21025
21026 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
21027
21028
21029
21030
21031
21032
21033
21034
21035 gl_LIBOBJS="$gl_LIBOBJS msvc-inval.$ac_objext"
21036
21037 fi
21038
21039 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
21040
21041
21042
21043
21044
21045
21046
21047
21048 gl_LIBOBJS="$gl_LIBOBJS msvc-nothrow.$ac_objext"
21049
21050 fi
21051
21052
21053
21054 case "$host_os" in
21055 mingw* | pw*)
21056 REPLACE_OPEN=1
21057 ;;
21058 *)
21059
21060 :
21061
21062
21063
21064
21065
21066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether open recognizes a trailing slash" >&5
21067 $as_echo_n "checking whether open recognizes a trailing slash... " >&6; }
21068 if ${gl_cv_func_open_slash+:} false; then :
21069 $as_echo_n "(cached) " >&6
21070 else
21071 # Assume that if we have lstat, we can also check symlinks.
21072 if test $ac_cv_func_lstat = yes; then
21073 touch conftest.tmp
21074 ln -s conftest.tmp conftest.lnk
21075 fi
21076 if test "$cross_compiling" = yes; then :
21077
21078 case "$host_os" in
21079 freebsd* | aix* | hpux* | solaris2.[0-9] | solaris2.[0-9].*)
21080 gl_cv_func_open_slash="guessing no" ;;
21081 *)
21082 gl_cv_func_open_slash="guessing yes" ;;
21083 esac
21084
21085 else
21086 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21087 /* end confdefs.h. */
21088
21089 #include <fcntl.h>
21090 #if HAVE_UNISTD_H
21091 # include <unistd.h>
21092 #endif
21093 int main ()
21094 {
21095 int result = 0;
21096 #if HAVE_LSTAT
21097 if (open ("conftest.lnk/", O_RDONLY) != -1)
21098 result |= 1;
21099 #endif
21100 if (open ("conftest.sl/", O_CREAT, 0600) >= 0)
21101 result |= 2;
21102 return result;
21103 }
21104 _ACEOF
21105 if ac_fn_c_try_run "$LINENO"; then :
21106 gl_cv_func_open_slash=yes
21107 else
21108 gl_cv_func_open_slash=no
21109 fi
21110 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21111 conftest.$ac_objext conftest.beam conftest.$ac_ext
21112 fi
21113
21114 rm -f conftest.sl conftest.tmp conftest.lnk
21115
21116 fi
21117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_open_slash" >&5
21118 $as_echo "$gl_cv_func_open_slash" >&6; }
21119 case "$gl_cv_func_open_slash" in
21120 *no)
21121
21122 $as_echo "#define OPEN_TRAILING_SLASH_BUG 1" >>confdefs.h
21123
21124 REPLACE_OPEN=1
21125 ;;
21126 esac
21127 ;;
21128 esac
21129
21130 if test $REPLACE_OPEN = 0; then
21131
21132
21133
21134 :
21135
21136
21137
21138
21139
21140 if test $ac_cv_func_fchdir = no; then
21141 HAVE_FCHDIR=0
21142 fi
21143
21144 if test $HAVE_FCHDIR = 0; then
21145 REPLACE_OPEN=1
21146 fi
21147 fi
21148
21149
21150
21151 if test $REPLACE_OPEN = 1; then
21152
21153
21154
21155
21156
21157
21158
21159
21160 gl_LIBOBJS="$gl_LIBOBJS open.$ac_objext"
21161
21162
21163
21164 :
21165
21166 fi
21167
21168
21169
21170
21171
21172 GNULIB_OPEN=1
21173
21174
21175
21176
21177
21178 $as_echo "#define GNULIB_TEST_OPEN 1" >>confdefs.h
21179
21180
21181
21182
21183
21184
21185
21186 :
21187
21188
21189
21190
21191
21192
21193 case $ac_cv_func_openat+$gl_cv_func_lstat_dereferences_slashed_symlink in
21194 yes+*yes)
21195 ;;
21196 yes+*)
21197 # Solaris 9 has *at functions, but uniformly mishandles trailing
21198 # slash in all of them.
21199 REPLACE_OPENAT=1
21200 ;;
21201 *)
21202 HAVE_OPENAT=0
21203 ;;
21204 esac
21205
21206 if test $HAVE_OPENAT = 0 || test $REPLACE_OPENAT = 1; then
21207
21208
21209
21210
21211
21212
21213
21214
21215 gl_LIBOBJS="$gl_LIBOBJS openat.$ac_objext"
21216
21217
21218
21219 :
21220
21221 fi
21222
21223
21224 cat >>confdefs.h <<_ACEOF
21225 #define GNULIB_OPENAT 1
21226 _ACEOF
21227
21228
21229
21230
21231
21232
21233 GNULIB_OPENAT=1
21234
21235
21236
21237
21238
21239 $as_echo "#define GNULIB_TEST_OPENAT 1" >>confdefs.h
21240
21241
21242
21243
21244
21245
21246 for ac_func in opendir
21247 do :
21248 ac_fn_c_check_func "$LINENO" "opendir" "ac_cv_func_opendir"
21249 if test "x$ac_cv_func_opendir" = xyes; then :
21250 cat >>confdefs.h <<_ACEOF
21251 #define HAVE_OPENDIR 1
21252 _ACEOF
21253
21254 fi
21255 done
21256
21257 if test $ac_cv_func_opendir = no; then
21258 HAVE_OPENDIR=0
21259 fi
21260
21261
21262
21263
21264 :
21265
21266
21267
21268
21269
21270 if test $ac_cv_func_fchdir = no; then
21271 HAVE_FCHDIR=0
21272 fi
21273
21274 if test $HAVE_FCHDIR = 0; then
21275 if test $HAVE_OPENDIR = 1; then
21276 REPLACE_OPENDIR=1
21277 fi
21278 fi
21279
21280 case $host_os,$HAVE_OPENDIR in
21281 os2*,1)
21282 REPLACE_OPENDIR=1;;
21283 esac
21284
21285 if test $HAVE_OPENDIR = 0 || test $REPLACE_OPENDIR = 1; then
21286
21287
21288
21289
21290
21291
21292
21293
21294 gl_LIBOBJS="$gl_LIBOBJS opendir.$ac_objext"
21295
21296 fi
21297
21298
21299
21300
21301
21302 GNULIB_OPENDIR=1
21303
21304
21305
21306
21307
21308 $as_echo "#define GNULIB_TEST_OPENDIR 1" >>confdefs.h
21309
21310
21311
21312
21313
21314 :
21315
21316
21317
21318
21319
21320
21321
21322
21323
21324
21325 for ac_func in rawmemchr
21326 do :
21327 ac_fn_c_check_func "$LINENO" "rawmemchr" "ac_cv_func_rawmemchr"
21328 if test "x$ac_cv_func_rawmemchr" = xyes; then :
21329 cat >>confdefs.h <<_ACEOF
21330 #define HAVE_RAWMEMCHR 1
21331 _ACEOF
21332
21333 fi
21334 done
21335
21336 if test $ac_cv_func_rawmemchr = no; then
21337 HAVE_RAWMEMCHR=0
21338 fi
21339
21340 if test $HAVE_RAWMEMCHR = 0; then
21341
21342
21343
21344
21345
21346
21347
21348
21349 gl_LIBOBJS="$gl_LIBOBJS rawmemchr.$ac_objext"
21350
21351 :
21352 fi
21353
21354
21355
21356
21357
21358 GNULIB_RAWMEMCHR=1
21359
21360
21361
21362
21363
21364 $as_echo "#define GNULIB_TEST_RAWMEMCHR 1" >>confdefs.h
21365
21366
21367
21368
21369
21370
21371 for ac_func in readdir
21372 do :
21373 ac_fn_c_check_func "$LINENO" "readdir" "ac_cv_func_readdir"
21374 if test "x$ac_cv_func_readdir" = xyes; then :
21375 cat >>confdefs.h <<_ACEOF
21376 #define HAVE_READDIR 1
21377 _ACEOF
21378
21379 fi
21380 done
21381
21382 if test $ac_cv_func_readdir = no; then
21383 HAVE_READDIR=0
21384 fi
21385
21386 if test $HAVE_READDIR = 0; then
21387
21388
21389
21390
21391
21392
21393
21394
21395 gl_LIBOBJS="$gl_LIBOBJS readdir.$ac_objext"
21396
21397 fi
21398
21399
21400
21401
21402
21403 GNULIB_READDIR=1
21404
21405
21406
21407
21408
21409 $as_echo "#define GNULIB_TEST_READDIR 1" >>confdefs.h
21410
21411
21412
21413
21414
21415
21416 :
21417
21418
21419
21420
21421
21422 if test $ac_cv_func_readlink = no; then
21423 HAVE_READLINK=0
21424 else
21425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
21426 $as_echo_n "checking whether readlink signature is correct... " >&6; }
21427 if ${gl_cv_decl_readlink_works+:} false; then :
21428 $as_echo_n "(cached) " >&6
21429 else
21430 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21431 /* end confdefs.h. */
21432 #include <unistd.h>
21433 /* Cause compilation failure if original declaration has wrong type. */
21434 ssize_t readlink (const char *, char *, size_t);
21435 int
21436 main ()
21437 {
21438
21439 ;
21440 return 0;
21441 }
21442 _ACEOF
21443 if ac_fn_c_try_compile "$LINENO"; then :
21444 gl_cv_decl_readlink_works=yes
21445 else
21446 gl_cv_decl_readlink_works=no
21447 fi
21448 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21449 fi
21450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
21451 $as_echo "$gl_cv_decl_readlink_works" >&6; }
21452 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
21453 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
21454 if ${gl_cv_func_readlink_works+:} false; then :
21455 $as_echo_n "(cached) " >&6
21456 else
21457 # We have readlink, so assume ln -s works.
21458 ln -s conftest.no-such conftest.link
21459 ln -s conftest.link conftest.lnk2
21460 if test "$cross_compiling" = yes; then :
21461 case "$host_os" in
21462 # Guess yes on glibc systems.
21463 *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
21464 # If we don't know, assume the worst.
21465 *) gl_cv_func_readlink_works="guessing no" ;;
21466 esac
21467
21468 else
21469 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21470 /* end confdefs.h. */
21471 #include <unistd.h>
21472
21473 int
21474 main ()
21475 {
21476 char buf[20];
21477 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
21478 ;
21479 return 0;
21480 }
21481 _ACEOF
21482 if ac_fn_c_try_run "$LINENO"; then :
21483 gl_cv_func_readlink_works=yes
21484 else
21485 gl_cv_func_readlink_works=no
21486 fi
21487 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21488 conftest.$ac_objext conftest.beam conftest.$ac_ext
21489 fi
21490
21491 rm -f conftest.link conftest.lnk2
21492 fi
21493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
21494 $as_echo "$gl_cv_func_readlink_works" >&6; }
21495 case "$gl_cv_func_readlink_works" in
21496 *yes)
21497 if test "$gl_cv_decl_readlink_works" != yes; then
21498 REPLACE_READLINK=1
21499 fi
21500 ;;
21501 *)
21502
21503 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
21504
21505 REPLACE_READLINK=1
21506 ;;
21507 esac
21508 fi
21509
21510 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
21511
21512
21513
21514
21515
21516
21517
21518
21519 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
21520
21521
21522 :
21523
21524 fi
21525
21526
21527
21528
21529
21530 GNULIB_READLINK=1
21531
21532
21533
21534
21535
21536 $as_echo "#define GNULIB_TEST_READLINK 1" >>confdefs.h
21537
21538
21539
21540
21541
21542
21543 if test $gl_cv_func_malloc_posix = yes; then
21544
21545 $as_echo "#define HAVE_REALLOC_POSIX 1" >>confdefs.h
21546
21547 else
21548 REPLACE_REALLOC=1
21549 fi
21550
21551 if test $REPLACE_REALLOC = 1; then
21552
21553
21554
21555
21556
21557
21558
21559
21560 gl_LIBOBJS="$gl_LIBOBJS realloc.$ac_objext"
21561
21562 fi
21563
21564
21565
21566
21567
21568 GNULIB_REALLOC_POSIX=1
21569
21570
21571
21572
21573
21574 $as_echo "#define GNULIB_TEST_REALLOC_POSIX 1" >>confdefs.h
21575
21576
21577
21578
21579
21580
21581
21582 :
21583
21584
21585
21586
21587
21588
21589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename honors trailing slash on destination" >&5
21590 $as_echo_n "checking whether rename honors trailing slash on destination... " >&6; }
21591 if ${gl_cv_func_rename_slash_dst_works+:} false; then :
21592 $as_echo_n "(cached) " >&6
21593 else
21594 rm -rf conftest.f conftest.f1 conftest.f2 conftest.d1 conftest.d2 conftest.lnk
21595 touch conftest.f && touch conftest.f1 && mkdir conftest.d1 ||
21596 as_fn_error $? "cannot create temporary files" "$LINENO" 5
21597 # Assume that if we have lstat, we can also check symlinks.
21598 if test $ac_cv_func_lstat = yes; then
21599 ln -s conftest.f conftest.lnk
21600 fi
21601 if test "$cross_compiling" = yes; then :
21602 case "$host_os" in
21603 # Guess yes on glibc systems.
21604 *-gnu*) gl_cv_func_rename_slash_dst_works="guessing yes" ;;
21605 # If we don't know, assume the worst.
21606 *) gl_cv_func_rename_slash_dst_works="guessing no" ;;
21607 esac
21608
21609 else
21610 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21611 /* end confdefs.h. */
21612
21613 # include <stdio.h>
21614 # include <stdlib.h>
21615
21616 int
21617 main ()
21618 {
21619 int result = 0;
21620 if (rename ("conftest.f1", "conftest.f2/") == 0)
21621 result |= 1;
21622 if (rename ("conftest.d1", "conftest.d2/") != 0)
21623 result |= 2;
21624 #if HAVE_LSTAT
21625 if (rename ("conftest.f", "conftest.lnk/") == 0)
21626 result |= 4;
21627 #endif
21628 return result;
21629
21630 ;
21631 return 0;
21632 }
21633 _ACEOF
21634 if ac_fn_c_try_run "$LINENO"; then :
21635 gl_cv_func_rename_slash_dst_works=yes
21636 else
21637 gl_cv_func_rename_slash_dst_works=no
21638 fi
21639 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21640 conftest.$ac_objext conftest.beam conftest.$ac_ext
21641 fi
21642
21643 rm -rf conftest.f conftest.f1 conftest.f2 conftest.d1 conftest.d2 conftest.lnk
21644
21645 fi
21646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_slash_dst_works" >&5
21647 $as_echo "$gl_cv_func_rename_slash_dst_works" >&6; }
21648 case "$gl_cv_func_rename_slash_dst_works" in
21649 *yes) ;;
21650 *)
21651 REPLACE_RENAME=1
21652
21653 $as_echo "#define RENAME_TRAILING_SLASH_DEST_BUG 1" >>confdefs.h
21654
21655 ;;
21656 esac
21657
21658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename honors trailing slash on source" >&5
21659 $as_echo_n "checking whether rename honors trailing slash on source... " >&6; }
21660 if ${gl_cv_func_rename_slash_src_works+:} false; then :
21661 $as_echo_n "(cached) " >&6
21662 else
21663 rm -rf conftest.f conftest.f1 conftest.d1 conftest.d2 conftest.d3 conftest.lnk
21664 touch conftest.f && touch conftest.f1 && mkdir conftest.d1 ||
21665 as_fn_error $? "cannot create temporary files" "$LINENO" 5
21666 # Assume that if we have lstat, we can also check symlinks.
21667 if test $ac_cv_func_lstat = yes; then
21668 ln -s conftest.f conftest.lnk
21669 fi
21670 if test "$cross_compiling" = yes; then :
21671 case "$host_os" in
21672 # Guess yes on glibc systems.
21673 *-gnu*) gl_cv_func_rename_slash_src_works="guessing yes" ;;
21674 # If we don't know, assume the worst.
21675 *) gl_cv_func_rename_slash_src_works="guessing no" ;;
21676 esac
21677
21678 else
21679 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21680 /* end confdefs.h. */
21681
21682 # include <stdio.h>
21683 # include <stdlib.h>
21684
21685 int
21686 main ()
21687 {
21688 int result = 0;
21689 if (rename ("conftest.f1/", "conftest.d3") == 0)
21690 result |= 1;
21691 if (rename ("conftest.d1/", "conftest.d2") != 0)
21692 result |= 2;
21693 #if HAVE_LSTAT
21694 if (rename ("conftest.lnk/", "conftest.f") == 0)
21695 result |= 4;
21696 #endif
21697 return result;
21698
21699 ;
21700 return 0;
21701 }
21702 _ACEOF
21703 if ac_fn_c_try_run "$LINENO"; then :
21704 gl_cv_func_rename_slash_src_works=yes
21705 else
21706 gl_cv_func_rename_slash_src_works=no
21707 fi
21708 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21709 conftest.$ac_objext conftest.beam conftest.$ac_ext
21710 fi
21711
21712 rm -rf conftest.f conftest.f1 conftest.d1 conftest.d2 conftest.d3 conftest.lnk
21713
21714 fi
21715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_slash_src_works" >&5
21716 $as_echo "$gl_cv_func_rename_slash_src_works" >&6; }
21717 case "$gl_cv_func_rename_slash_src_works" in
21718 *yes) ;;
21719 *)
21720 REPLACE_RENAME=1
21721
21722 $as_echo "#define RENAME_TRAILING_SLASH_SOURCE_BUG 1" >>confdefs.h
21723
21724 ;;
21725 esac
21726
21727
21728 :
21729
21730
21731
21732
21733
21734 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename manages hard links correctly" >&5
21735 $as_echo_n "checking whether rename manages hard links correctly... " >&6; }
21736 if ${gl_cv_func_rename_link_works+:} false; then :
21737 $as_echo_n "(cached) " >&6
21738 else
21739 if test $ac_cv_func_link = yes; then
21740 rm -rf conftest.f conftest.f1
21741 if touch conftest.f && ln conftest.f conftest.f1 &&
21742 set x `ls -i conftest.f conftest.f1` && test "" = ""; then
21743 if test "$cross_compiling" = yes; then :
21744 case "$host_os" in
21745 # Guess yes on glibc systems.
21746 *-gnu*) gl_cv_func_rename_link_works="guessing yes" ;;
21747 # If we don't know, assume the worst.
21748 *) gl_cv_func_rename_link_works="guessing no" ;;
21749 esac
21750
21751 else
21752 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21753 /* end confdefs.h. */
21754
21755 # include <stdio.h>
21756 # include <stdlib.h>
21757 # include <unistd.h>
21758
21759 int
21760 main ()
21761 {
21762 int result = 0;
21763 if (rename ("conftest.f", "conftest.f1"))
21764 result |= 1;
21765 if (unlink ("conftest.f1"))
21766 result |= 2;
21767 if (rename ("conftest.f", "conftest.f"))
21768 result |= 4;
21769 if (rename ("conftest.f1", "conftest.f1") == 0)
21770 result |= 8;
21771 return result;
21772
21773 ;
21774 return 0;
21775 }
21776 _ACEOF
21777 if ac_fn_c_try_run "$LINENO"; then :
21778 gl_cv_func_rename_link_works=yes
21779 else
21780 gl_cv_func_rename_link_works=no
21781 fi
21782 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21783 conftest.$ac_objext conftest.beam conftest.$ac_ext
21784 fi
21785
21786 else
21787 gl_cv_func_rename_link_works="guessing no"
21788 fi
21789 rm -rf conftest.f conftest.f1
21790 else
21791 gl_cv_func_rename_link_works=yes
21792 fi
21793
21794 fi
21795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_link_works" >&5
21796 $as_echo "$gl_cv_func_rename_link_works" >&6; }
21797 case "$gl_cv_func_rename_link_works" in
21798 *yes) ;;
21799 *)
21800 REPLACE_RENAME=1
21801
21802 $as_echo "#define RENAME_HARD_LINK_BUG 1" >>confdefs.h
21803
21804 ;;
21805 esac
21806
21807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rename manages existing destinations correctly" >&5
21808 $as_echo_n "checking whether rename manages existing destinations correctly... " >&6; }
21809 if ${gl_cv_func_rename_dest_works+:} false; then :
21810 $as_echo_n "(cached) " >&6
21811 else
21812 rm -rf conftest.f conftest.d1 conftest.d2
21813 touch conftest.f && mkdir conftest.d1 conftest.d2 ||
21814 as_fn_error $? "cannot create temporary files" "$LINENO" 5
21815 if test "$cross_compiling" = yes; then :
21816 case "$host_os" in
21817 # Guess yes on glibc systems.
21818 *-gnu*) gl_cv_func_rename_dest_works="guessing yes" ;;
21819 # If we don't know, assume the worst.
21820 *) gl_cv_func_rename_dest_works="guessing no" ;;
21821 esac
21822
21823 else
21824 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21825 /* end confdefs.h. */
21826
21827 # include <stdio.h>
21828 # include <stdlib.h>
21829
21830 int
21831 main ()
21832 {
21833 int result = 0;
21834 if (rename ("conftest.d1", "conftest.d2") != 0)
21835 result |= 1;
21836 if (rename ("conftest.d2", "conftest.f") == 0)
21837 result |= 2;
21838 return result;
21839
21840 ;
21841 return 0;
21842 }
21843 _ACEOF
21844 if ac_fn_c_try_run "$LINENO"; then :
21845 gl_cv_func_rename_dest_works=yes
21846 else
21847 gl_cv_func_rename_dest_works=no
21848 fi
21849 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21850 conftest.$ac_objext conftest.beam conftest.$ac_ext
21851 fi
21852
21853 rm -rf conftest.f conftest.d1 conftest.d2
21854
21855 fi
21856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rename_dest_works" >&5
21857 $as_echo "$gl_cv_func_rename_dest_works" >&6; }
21858 case "$gl_cv_func_rename_dest_works" in
21859 *yes) ;;
21860 *)
21861 REPLACE_RENAME=1
21862
21863 $as_echo "#define RENAME_DEST_EXISTS_BUG 1" >>confdefs.h
21864
21865 ;;
21866 esac
21867
21868 if test $REPLACE_RENAME = 1; then
21869
21870
21871
21872
21873
21874
21875
21876
21877 gl_LIBOBJS="$gl_LIBOBJS rename.$ac_objext"
21878
21879 fi
21880
21881
21882
21883
21884
21885 GNULIB_RENAME=1
21886
21887
21888
21889
21890
21891 $as_echo "#define GNULIB_TEST_RENAME 1" >>confdefs.h
21892
21893
21894
21895
21896
21897
21898 for ac_func in rewinddir
21899 do :
21900 ac_fn_c_check_func "$LINENO" "rewinddir" "ac_cv_func_rewinddir"
21901 if test "x$ac_cv_func_rewinddir" = xyes; then :
21902 cat >>confdefs.h <<_ACEOF
21903 #define HAVE_REWINDDIR 1
21904 _ACEOF
21905
21906 fi
21907 done
21908
21909 if test $ac_cv_func_rewinddir = no; then
21910 HAVE_REWINDDIR=0
21911 fi
21912
21913 if test $HAVE_REWINDDIR = 0; then
21914
21915
21916
21917
21918
21919
21920
21921
21922 gl_LIBOBJS="$gl_LIBOBJS rewinddir.$ac_objext"
21923
21924 fi
21925
21926
21927
21928
21929
21930 GNULIB_REWINDDIR=1
21931
21932
21933
21934
21935
21936 $as_echo "#define GNULIB_TEST_REWINDDIR 1" >>confdefs.h
21937
21938
21939
21940
21941
21942
21943 :
21944
21945
21946
21947
21948
21949 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether rmdir works" >&5
21950 $as_echo_n "checking whether rmdir works... " >&6; }
21951 if ${gl_cv_func_rmdir_works+:} false; then :
21952 $as_echo_n "(cached) " >&6
21953 else
21954 mkdir conftest.dir
21955 touch conftest.file
21956 if test "$cross_compiling" = yes; then :
21957 case "$host_os" in
21958 # Guess yes on glibc systems.
21959 *-gnu*) gl_cv_func_rmdir_works="guessing yes" ;;
21960 # If we don't know, assume the worst.
21961 *) gl_cv_func_rmdir_works="guessing no" ;;
21962 esac
21963
21964 else
21965 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21966 /* end confdefs.h. */
21967 #include <stdio.h>
21968 #include <errno.h>
21969 #if HAVE_UNISTD_H
21970 # include <unistd.h>
21971 #else /* on Windows with MSVC */
21972 # include <direct.h>
21973 #endif
21974
21975 int
21976 main ()
21977 {
21978 int result = 0;
21979 if (!rmdir ("conftest.file/"))
21980 result |= 1;
21981 else if (errno != ENOTDIR)
21982 result |= 2;
21983 if (!rmdir ("conftest.dir/./"))
21984 result |= 4;
21985 return result;
21986
21987 ;
21988 return 0;
21989 }
21990 _ACEOF
21991 if ac_fn_c_try_run "$LINENO"; then :
21992 gl_cv_func_rmdir_works=yes
21993 else
21994 gl_cv_func_rmdir_works=no
21995 fi
21996 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21997 conftest.$ac_objext conftest.beam conftest.$ac_ext
21998 fi
21999
22000 rm -rf conftest.dir conftest.file
22001 fi
22002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_rmdir_works" >&5
22003 $as_echo "$gl_cv_func_rmdir_works" >&6; }
22004 case "$gl_cv_func_rmdir_works" in
22005 *yes) ;;
22006 *)
22007 REPLACE_RMDIR=1
22008 ;;
22009 esac
22010
22011 if test $REPLACE_RMDIR = 1; then
22012
22013
22014
22015
22016
22017
22018
22019
22020 gl_LIBOBJS="$gl_LIBOBJS rmdir.$ac_objext"
22021
22022 fi
22023
22024
22025
22026
22027
22028 GNULIB_RMDIR=1
22029
22030
22031
22032
22033
22034 $as_echo "#define GNULIB_TEST_RMDIR 1" >>confdefs.h
22035
22036
22037
22038
22039
22040 :
22041
22042
22043
22044
22045
22046
22047
22048
22049
22050
22051
22052 :
22053
22054
22055
22056
22057
22058 if test $ac_cv_func_secure_getenv = no; then
22059 HAVE_SECURE_GETENV=0
22060 fi
22061
22062 if test $HAVE_SECURE_GETENV = 0; then
22063
22064
22065
22066
22067
22068
22069
22070
22071 gl_LIBOBJS="$gl_LIBOBJS secure_getenv.$ac_objext"
22072
22073
22074 for ac_func in __secure_getenv
22075 do :
22076 ac_fn_c_check_func "$LINENO" "__secure_getenv" "ac_cv_func___secure_getenv"
22077 if test "x$ac_cv_func___secure_getenv" = xyes; then :
22078 cat >>confdefs.h <<_ACEOF
22079 #define HAVE___SECURE_GETENV 1
22080 _ACEOF
22081
22082 fi
22083 done
22084
22085 if test $ac_cv_func___secure_getenv = no; then
22086 for ac_func in issetugid
22087 do :
22088 ac_fn_c_check_func "$LINENO" "issetugid" "ac_cv_func_issetugid"
22089 if test "x$ac_cv_func_issetugid" = xyes; then :
22090 cat >>confdefs.h <<_ACEOF
22091 #define HAVE_ISSETUGID 1
22092 _ACEOF
22093
22094 fi
22095 done
22096
22097 fi
22098
22099 :
22100
22101
22102
22103
22104
22105
22106
22107
22108
22109
22110
22111
22112
22113
22114
22115 fi
22116
22117
22118
22119
22120
22121 GNULIB_SECURE_GETENV=1
22122
22123
22124
22125
22126
22127 $as_echo "#define GNULIB_TEST_SECURE_GETENV 1" >>confdefs.h
22128
22129
22130
22131
22132
22133 if test $ac_cv_func_setenv = no; then
22134 HAVE_SETENV=0
22135 else
22136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setenv validates arguments" >&5
22137 $as_echo_n "checking whether setenv validates arguments... " >&6; }
22138 if ${gl_cv_func_setenv_works+:} false; then :
22139 $as_echo_n "(cached) " >&6
22140 else
22141 if test "$cross_compiling" = yes; then :
22142 case "$host_os" in
22143 # Guess yes on glibc systems.
22144 *-gnu*) gl_cv_func_setenv_works="guessing yes" ;;
22145 # If we don't know, assume the worst.
22146 *) gl_cv_func_setenv_works="guessing no" ;;
22147 esac
22148
22149 else
22150 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22151 /* end confdefs.h. */
22152
22153 #include <stdlib.h>
22154 #include <errno.h>
22155 #include <string.h>
22156
22157 int
22158 main ()
22159 {
22160
22161 int result = 0;
22162 {
22163 if (setenv ("", "", 0) != -1)
22164 result |= 1;
22165 else if (errno != EINVAL)
22166 result |= 2;
22167 }
22168 {
22169 if (setenv ("a", "=", 1) != 0)
22170 result |= 4;
22171 else if (strcmp (getenv ("a"), "=") != 0)
22172 result |= 8;
22173 }
22174 return result;
22175
22176 ;
22177 return 0;
22178 }
22179 _ACEOF
22180 if ac_fn_c_try_run "$LINENO"; then :
22181 gl_cv_func_setenv_works=yes
22182 else
22183 gl_cv_func_setenv_works=no
22184 fi
22185 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22186 conftest.$ac_objext conftest.beam conftest.$ac_ext
22187 fi
22188
22189 fi
22190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_setenv_works" >&5
22191 $as_echo "$gl_cv_func_setenv_works" >&6; }
22192 case "$gl_cv_func_setenv_works" in
22193 *yes) ;;
22194 *)
22195 REPLACE_SETENV=1
22196 ;;
22197 esac
22198 fi
22199
22200 if test $HAVE_SETENV = 0 || test $REPLACE_SETENV = 1; then
22201
22202
22203
22204
22205
22206
22207
22208
22209 gl_LIBOBJS="$gl_LIBOBJS setenv.$ac_objext"
22210
22211 fi
22212
22213
22214
22215
22216
22217 GNULIB_SETENV=1
22218
22219
22220
22221
22222
22223 $as_echo "#define GNULIB_TEST_SETENV 1" >>confdefs.h
22224
22225
22226
22227
22228
22229
22230
22231
22232
22233
22234
22235
22236
22237
22238 if test $gl_cv_have_include_next = yes; then
22239 gl_cv_next_signal_h='<'signal.h'>'
22240 else
22241 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
22242 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
22243 if ${gl_cv_next_signal_h+:} false; then :
22244 $as_echo_n "(cached) " >&6
22245 else
22246
22247
22248
22249 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22250 /* end confdefs.h. */
22251 #include <signal.h>
22252 _ACEOF
22253 case "$host_os" in
22254 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22255 *) gl_absname_cpp="$ac_cpp" ;;
22256 esac
22257
22258 case "$host_os" in
22259 mingw*)
22260 gl_dirsep_regex='[/\\]'
22261 ;;
22262 *)
22263 gl_dirsep_regex='\/'
22264 ;;
22265 esac
22266 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22267 gl_header_literal_regex=`echo 'signal.h' \
22268 | sed -e "$gl_make_literal_regex_sed"`
22269 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22270 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22271 s|^/[^/]|//&|
22272 p
22273 q
22274 }'
22275
22276 gl_cv_absolute_signal_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22277 sed -n "$gl_absolute_header_sed"`
22278
22279 gl_header=$gl_cv_absolute_signal_h
22280 gl_cv_next_signal_h='"'$gl_header'"'
22281
22282
22283 fi
22284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
22285 $as_echo "$gl_cv_next_signal_h" >&6; }
22286 fi
22287 NEXT_SIGNAL_H=$gl_cv_next_signal_h
22288
22289 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22290 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22291 gl_next_as_first_directive='<'signal.h'>'
22292 else
22293 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22294 gl_next_as_first_directive=$gl_cv_next_signal_h
22295 fi
22296 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
22297
22298
22299
22300
22301
22302 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
22303 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
22304 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
22305 #include <signal.h>
22306
22307 "
22308 if test "x$ac_cv_type_volatile_sig_atomic_t" = xyes; then :
22309
22310 else
22311 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
22312 fi
22313
22314
22315
22316
22317
22318
22319
22320 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
22321 #include <signal.h>
22322
22323 "
22324 if test "x$ac_cv_type_sighandler_t" = xyes; then :
22325
22326 else
22327 HAVE_SIGHANDLER_T=0
22328 fi
22329
22330
22331
22332 for gl_func in pthread_sigmask sigaction sigaddset sigdelset sigemptyset sigfillset sigismember sigpending sigprocmask; do
22333 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
22334 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
22335 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
22336 if eval \${$as_gl_Symbol+:} false; then :
22337 $as_echo_n "(cached) " >&6
22338 else
22339 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22340 /* end confdefs.h. */
22341 #include <signal.h>
22342
22343 int
22344 main ()
22345 {
22346 #undef $gl_func
22347 (void) $gl_func;
22348 ;
22349 return 0;
22350 }
22351 _ACEOF
22352 if ac_fn_c_try_compile "$LINENO"; then :
22353 eval "$as_gl_Symbol=yes"
22354 else
22355 eval "$as_gl_Symbol=no"
22356 fi
22357 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22358 fi
22359 eval ac_res=\$$as_gl_Symbol
22360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
22361 $as_echo "$ac_res" >&6; }
22362 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
22363 cat >>confdefs.h <<_ACEOF
22364 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
22365 _ACEOF
22366
22367 eval ac_cv_have_decl_$gl_func=yes
22368 fi
22369 done
22370
22371
22372
22373 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
22374 $as_echo_n "checking for ssize_t... " >&6; }
22375 if ${gt_cv_ssize_t+:} false; then :
22376 $as_echo_n "(cached) " >&6
22377 else
22378 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22379 /* end confdefs.h. */
22380 #include <sys/types.h>
22381 int
22382 main ()
22383 {
22384 int x = sizeof (ssize_t *) + sizeof (ssize_t);
22385 return !x;
22386 ;
22387 return 0;
22388 }
22389 _ACEOF
22390 if ac_fn_c_try_compile "$LINENO"; then :
22391 gt_cv_ssize_t=yes
22392 else
22393 gt_cv_ssize_t=no
22394 fi
22395 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22396 fi
22397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
22398 $as_echo "$gt_cv_ssize_t" >&6; }
22399 if test $gt_cv_ssize_t = no; then
22400
22401 $as_echo "#define ssize_t int" >>confdefs.h
22402
22403 fi
22404
22405
22406
22407
22408 :
22409
22410
22411
22412
22413
22414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
22415 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
22416 if ${gl_cv_func_stat_dir_slash+:} false; then :
22417 $as_echo_n "(cached) " >&6
22418 else
22419 if test "$cross_compiling" = yes; then :
22420 case $host_os in
22421 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
22422 *) gl_cv_func_stat_dir_slash="guessing yes";;
22423 esac
22424 else
22425 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22426 /* end confdefs.h. */
22427 #include <sys/stat.h>
22428
22429 int
22430 main ()
22431 {
22432 struct stat st; return stat (".", &st) != stat ("./", &st);
22433 ;
22434 return 0;
22435 }
22436 _ACEOF
22437 if ac_fn_c_try_run "$LINENO"; then :
22438 gl_cv_func_stat_dir_slash=yes
22439 else
22440 gl_cv_func_stat_dir_slash=no
22441 fi
22442 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22443 conftest.$ac_objext conftest.beam conftest.$ac_ext
22444 fi
22445
22446 fi
22447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
22448 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
22449 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
22450 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
22451 if ${gl_cv_func_stat_file_slash+:} false; then :
22452 $as_echo_n "(cached) " >&6
22453 else
22454 touch conftest.tmp
22455 # Assume that if we have lstat, we can also check symlinks.
22456 if test $ac_cv_func_lstat = yes; then
22457 ln -s conftest.tmp conftest.lnk
22458 fi
22459 if test "$cross_compiling" = yes; then :
22460 case "$host_os" in
22461 # Guess yes on glibc systems.
22462 *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
22463 # If we don't know, assume the worst.
22464 *) gl_cv_func_stat_file_slash="guessing no" ;;
22465 esac
22466
22467 else
22468 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22469 /* end confdefs.h. */
22470 #include <sys/stat.h>
22471
22472 int
22473 main ()
22474 {
22475 int result = 0;
22476 struct stat st;
22477 if (!stat ("conftest.tmp/", &st))
22478 result |= 1;
22479 #if HAVE_LSTAT
22480 if (!stat ("conftest.lnk/", &st))
22481 result |= 2;
22482 #endif
22483 return result;
22484
22485 ;
22486 return 0;
22487 }
22488 _ACEOF
22489 if ac_fn_c_try_run "$LINENO"; then :
22490 gl_cv_func_stat_file_slash=yes
22491 else
22492 gl_cv_func_stat_file_slash=no
22493 fi
22494 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22495 conftest.$ac_objext conftest.beam conftest.$ac_ext
22496 fi
22497
22498 rm -f conftest.tmp conftest.lnk
22499 fi
22500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
22501 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
22502 case $gl_cv_func_stat_dir_slash in
22503 *no) REPLACE_STAT=1
22504
22505 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
22506 ;;
22507 esac
22508 case $gl_cv_func_stat_file_slash in
22509 *no) REPLACE_STAT=1
22510
22511 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
22512 ;;
22513 esac
22514
22515 if test $REPLACE_STAT = 1; then
22516
22517
22518
22519
22520
22521
22522
22523
22524 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
22525
22526 :
22527 fi
22528
22529
22530
22531
22532
22533 GNULIB_STAT=1
22534
22535
22536
22537
22538
22539 $as_echo "#define GNULIB_TEST_STAT 1" >>confdefs.h
22540
22541
22542
22543
22544
22545
22546 # Define two additional variables used in the Makefile substitution.
22547
22548 if test "$ac_cv_header_stdbool_h" = yes; then
22549 STDBOOL_H=''
22550 else
22551 STDBOOL_H='stdbool.h'
22552 fi
22553
22554 if test -n "$STDBOOL_H"; then
22555 GL_GENERATE_STDBOOL_H_TRUE=
22556 GL_GENERATE_STDBOOL_H_FALSE='#'
22557 else
22558 GL_GENERATE_STDBOOL_H_TRUE='#'
22559 GL_GENERATE_STDBOOL_H_FALSE=
22560 fi
22561
22562
22563 if test "$ac_cv_type__Bool" = yes; then
22564 HAVE__BOOL=1
22565 else
22566 HAVE__BOOL=0
22567 fi
22568
22569
22570
22571
22572
22573 STDDEF_H=
22574 ac_fn_c_check_type "$LINENO" "max_align_t" "ac_cv_type_max_align_t" "#include <stddef.h>
22575
22576 "
22577 if test "x$ac_cv_type_max_align_t" = xyes; then :
22578
22579 else
22580 HAVE_MAX_ALIGN_T=0; STDDEF_H=stddef.h
22581 fi
22582
22583 if test $gt_cv_c_wchar_t = no; then
22584 HAVE_WCHAR_T=0
22585 STDDEF_H=stddef.h
22586 fi
22587 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
22588 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
22589 if ${gl_cv_decl_null_works+:} false; then :
22590 $as_echo_n "(cached) " >&6
22591 else
22592 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22593 /* end confdefs.h. */
22594 #include <stddef.h>
22595 int test[2 * (sizeof NULL == sizeof (void *)) -1];
22596
22597 int
22598 main ()
22599 {
22600
22601 ;
22602 return 0;
22603 }
22604 _ACEOF
22605 if ac_fn_c_try_compile "$LINENO"; then :
22606 gl_cv_decl_null_works=yes
22607 else
22608 gl_cv_decl_null_works=no
22609 fi
22610 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22611 fi
22612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
22613 $as_echo "$gl_cv_decl_null_works" >&6; }
22614 if test $gl_cv_decl_null_works = no; then
22615 REPLACE_NULL=1
22616 STDDEF_H=stddef.h
22617 fi
22618
22619 if test -n "$STDDEF_H"; then
22620 GL_GENERATE_STDDEF_H_TRUE=
22621 GL_GENERATE_STDDEF_H_FALSE='#'
22622 else
22623 GL_GENERATE_STDDEF_H_TRUE='#'
22624 GL_GENERATE_STDDEF_H_FALSE=
22625 fi
22626
22627 if test -n "$STDDEF_H"; then
22628
22629
22630
22631
22632
22633
22634
22635
22636 if test $gl_cv_have_include_next = yes; then
22637 gl_cv_next_stddef_h='<'stddef.h'>'
22638 else
22639 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
22640 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
22641 if ${gl_cv_next_stddef_h+:} false; then :
22642 $as_echo_n "(cached) " >&6
22643 else
22644
22645
22646
22647 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22648 /* end confdefs.h. */
22649 #include <stddef.h>
22650 _ACEOF
22651 case "$host_os" in
22652 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22653 *) gl_absname_cpp="$ac_cpp" ;;
22654 esac
22655
22656 case "$host_os" in
22657 mingw*)
22658 gl_dirsep_regex='[/\\]'
22659 ;;
22660 *)
22661 gl_dirsep_regex='\/'
22662 ;;
22663 esac
22664 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22665 gl_header_literal_regex=`echo 'stddef.h' \
22666 | sed -e "$gl_make_literal_regex_sed"`
22667 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22668 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22669 s|^/[^/]|//&|
22670 p
22671 q
22672 }'
22673
22674 gl_cv_absolute_stddef_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22675 sed -n "$gl_absolute_header_sed"`
22676
22677 gl_header=$gl_cv_absolute_stddef_h
22678 gl_cv_next_stddef_h='"'$gl_header'"'
22679
22680
22681 fi
22682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
22683 $as_echo "$gl_cv_next_stddef_h" >&6; }
22684 fi
22685 NEXT_STDDEF_H=$gl_cv_next_stddef_h
22686
22687 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22688 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22689 gl_next_as_first_directive='<'stddef.h'>'
22690 else
22691 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22692 gl_next_as_first_directive=$gl_cv_next_stddef_h
22693 fi
22694 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
22695
22696
22697
22698
22699 fi
22700
22701
22702
22703
22704 $as_echo "#define __USE_MINGW_ANSI_STDIO 1" >>confdefs.h
22705
22706
22707
22708
22709
22710
22711
22712
22713
22714
22715 if test $gl_cv_have_include_next = yes; then
22716 gl_cv_next_stdio_h='<'stdio.h'>'
22717 else
22718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
22719 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
22720 if ${gl_cv_next_stdio_h+:} false; then :
22721 $as_echo_n "(cached) " >&6
22722 else
22723
22724
22725
22726 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22727 /* end confdefs.h. */
22728 #include <stdio.h>
22729 _ACEOF
22730 case "$host_os" in
22731 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22732 *) gl_absname_cpp="$ac_cpp" ;;
22733 esac
22734
22735 case "$host_os" in
22736 mingw*)
22737 gl_dirsep_regex='[/\\]'
22738 ;;
22739 *)
22740 gl_dirsep_regex='\/'
22741 ;;
22742 esac
22743 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22744 gl_header_literal_regex=`echo 'stdio.h' \
22745 | sed -e "$gl_make_literal_regex_sed"`
22746 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22747 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22748 s|^/[^/]|//&|
22749 p
22750 q
22751 }'
22752
22753 gl_cv_absolute_stdio_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22754 sed -n "$gl_absolute_header_sed"`
22755
22756 gl_header=$gl_cv_absolute_stdio_h
22757 gl_cv_next_stdio_h='"'$gl_header'"'
22758
22759
22760 fi
22761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
22762 $as_echo "$gl_cv_next_stdio_h" >&6; }
22763 fi
22764 NEXT_STDIO_H=$gl_cv_next_stdio_h
22765
22766 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22767 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22768 gl_next_as_first_directive='<'stdio.h'>'
22769 else
22770 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22771 gl_next_as_first_directive=$gl_cv_next_stdio_h
22772 fi
22773 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
22774
22775
22776
22777
22778
22779 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which flavor of printf attribute matches inttypes macros" >&5
22780 $as_echo_n "checking which flavor of printf attribute matches inttypes macros... " >&6; }
22781 if ${gl_cv_func_printf_attribute_flavor+:} false; then :
22782 $as_echo_n "(cached) " >&6
22783 else
22784 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22785 /* end confdefs.h. */
22786
22787 #define __STDC_FORMAT_MACROS 1
22788 #include <stdio.h>
22789 #include <inttypes.h>
22790 /* For non-mingw systems, compilation will trivially succeed.
22791 For mingw, compilation will succeed for older mingw (system
22792 printf, "I64d") and fail for newer mingw (gnu printf, "lld"). */
22793 #if ((defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__) && \
22794 (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4))
22795 extern char PRIdMAX_probe[sizeof PRIdMAX == sizeof "I64d" ? 1 : -1];
22796 #endif
22797
22798 int
22799 main ()
22800 {
22801
22802 ;
22803 return 0;
22804 }
22805 _ACEOF
22806 if ac_fn_c_try_compile "$LINENO"; then :
22807 gl_cv_func_printf_attribute_flavor=system
22808 else
22809 gl_cv_func_printf_attribute_flavor=gnu
22810 fi
22811 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22812 fi
22813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_attribute_flavor" >&5
22814 $as_echo "$gl_cv_func_printf_attribute_flavor" >&6; }
22815 if test "$gl_cv_func_printf_attribute_flavor" = gnu; then
22816
22817 $as_echo "#define GNULIB_PRINTF_ATTRIBUTE_FLAVOR_GNU 1" >>confdefs.h
22818
22819 fi
22820
22821 GNULIB_FSCANF=1
22822
22823
22824 cat >>confdefs.h <<_ACEOF
22825 #define GNULIB_FSCANF 1
22826 _ACEOF
22827
22828
22829 GNULIB_SCANF=1
22830
22831
22832 cat >>confdefs.h <<_ACEOF
22833 #define GNULIB_SCANF 1
22834 _ACEOF
22835
22836
22837 GNULIB_FGETC=1
22838 GNULIB_GETC=1
22839 GNULIB_GETCHAR=1
22840 GNULIB_FGETS=1
22841 GNULIB_FREAD=1
22842
22843
22844 GNULIB_FPRINTF=1
22845 GNULIB_PRINTF=1
22846 GNULIB_VFPRINTF=1
22847 GNULIB_VPRINTF=1
22848 GNULIB_FPUTC=1
22849 GNULIB_PUTC=1
22850 GNULIB_PUTCHAR=1
22851 GNULIB_FPUTS=1
22852 GNULIB_PUTS=1
22853 GNULIB_FWRITE=1
22854
22855
22856
22857
22858 for gl_func in dprintf fpurge fseeko ftello getdelim getline gets pclose popen renameat snprintf tmpfile vdprintf vsnprintf; do
22859 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
22860 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
22861 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
22862 if eval \${$as_gl_Symbol+:} false; then :
22863 $as_echo_n "(cached) " >&6
22864 else
22865 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22866 /* end confdefs.h. */
22867 #include <stdio.h>
22868
22869 int
22870 main ()
22871 {
22872 #undef $gl_func
22873 (void) $gl_func;
22874 ;
22875 return 0;
22876 }
22877 _ACEOF
22878 if ac_fn_c_try_compile "$LINENO"; then :
22879 eval "$as_gl_Symbol=yes"
22880 else
22881 eval "$as_gl_Symbol=no"
22882 fi
22883 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22884 fi
22885 eval ac_res=\$$as_gl_Symbol
22886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
22887 $as_echo "$ac_res" >&6; }
22888 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
22889 cat >>confdefs.h <<_ACEOF
22890 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
22891 _ACEOF
22892
22893 eval ac_cv_have_decl_$gl_func=yes
22894 fi
22895 done
22896
22897
22898
22899
22900
22901
22902
22903
22904
22905
22906
22907
22908 if test $gl_cv_have_include_next = yes; then
22909 gl_cv_next_stdlib_h='<'stdlib.h'>'
22910 else
22911 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
22912 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
22913 if ${gl_cv_next_stdlib_h+:} false; then :
22914 $as_echo_n "(cached) " >&6
22915 else
22916
22917
22918
22919 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22920 /* end confdefs.h. */
22921 #include <stdlib.h>
22922 _ACEOF
22923 case "$host_os" in
22924 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22925 *) gl_absname_cpp="$ac_cpp" ;;
22926 esac
22927
22928 case "$host_os" in
22929 mingw*)
22930 gl_dirsep_regex='[/\\]'
22931 ;;
22932 *)
22933 gl_dirsep_regex='\/'
22934 ;;
22935 esac
22936 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22937 gl_header_literal_regex=`echo 'stdlib.h' \
22938 | sed -e "$gl_make_literal_regex_sed"`
22939 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22940 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22941 s|^/[^/]|//&|
22942 p
22943 q
22944 }'
22945
22946 gl_cv_absolute_stdlib_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22947 sed -n "$gl_absolute_header_sed"`
22948
22949 gl_header=$gl_cv_absolute_stdlib_h
22950 gl_cv_next_stdlib_h='"'$gl_header'"'
22951
22952
22953 fi
22954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
22955 $as_echo "$gl_cv_next_stdlib_h" >&6; }
22956 fi
22957 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
22958
22959 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22960 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22961 gl_next_as_first_directive='<'stdlib.h'>'
22962 else
22963 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22964 gl_next_as_first_directive=$gl_cv_next_stdlib_h
22965 fi
22966 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
22967
22968
22969
22970
22971
22972
22973 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
22974 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
22975 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
22976 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
22977 if eval \${$as_gl_Symbol+:} false; then :
22978 $as_echo_n "(cached) " >&6
22979 else
22980 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22981 /* end confdefs.h. */
22982 #include <stdlib.h>
22983 #if HAVE_SYS_LOADAVG_H
22984 # include <sys/loadavg.h>
22985 #endif
22986 #if HAVE_RANDOM_H
22987 # include <random.h>
22988 #endif
22989
22990 int
22991 main ()
22992 {
22993 #undef $gl_func
22994 (void) $gl_func;
22995 ;
22996 return 0;
22997 }
22998 _ACEOF
22999 if ac_fn_c_try_compile "$LINENO"; then :
23000 eval "$as_gl_Symbol=yes"
23001 else
23002 eval "$as_gl_Symbol=no"
23003 fi
23004 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23005 fi
23006 eval ac_res=\$$as_gl_Symbol
23007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
23008 $as_echo "$ac_res" >&6; }
23009 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
23010 cat >>confdefs.h <<_ACEOF
23011 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
23012 _ACEOF
23013
23014 eval ac_cv_have_decl_$gl_func=yes
23015 fi
23016 done
23017
23018
23019
23020
23021
23022
23023 for ac_func in strchrnul
23024 do :
23025 ac_fn_c_check_func "$LINENO" "strchrnul" "ac_cv_func_strchrnul"
23026 if test "x$ac_cv_func_strchrnul" = xyes; then :
23027 cat >>confdefs.h <<_ACEOF
23028 #define HAVE_STRCHRNUL 1
23029 _ACEOF
23030
23031 fi
23032 done
23033
23034 if test $ac_cv_func_strchrnul = no; then
23035 HAVE_STRCHRNUL=0
23036 else
23037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strchrnul works" >&5
23038 $as_echo_n "checking whether strchrnul works... " >&6; }
23039 if ${gl_cv_func_strchrnul_works+:} false; then :
23040 $as_echo_n "(cached) " >&6
23041 else
23042 if test "$cross_compiling" = yes; then :
23043 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23044 /* end confdefs.h. */
23045
23046 #if defined __CYGWIN__
23047 #include <cygwin/version.h>
23048 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 9)
23049 Lucky user
23050 #endif
23051 #else
23052 Lucky user
23053 #endif
23054
23055 _ACEOF
23056 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23057 $EGREP "Lucky user" >/dev/null 2>&1; then :
23058 gl_cv_func_strchrnul_works="guessing yes"
23059 else
23060 gl_cv_func_strchrnul_works="guessing no"
23061 fi
23062 rm -f conftest*
23063
23064
23065 else
23066 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23067 /* end confdefs.h. */
23068
23069 #include <string.h> /* for strchrnul */
23070
23071 int
23072 main ()
23073 {
23074 const char *buf = "a";
23075 return strchrnul (buf, 'b') != buf + 1;
23076
23077 ;
23078 return 0;
23079 }
23080 _ACEOF
23081 if ac_fn_c_try_run "$LINENO"; then :
23082 gl_cv_func_strchrnul_works=yes
23083 else
23084 gl_cv_func_strchrnul_works=no
23085 fi
23086 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23087 conftest.$ac_objext conftest.beam conftest.$ac_ext
23088 fi
23089
23090
23091 fi
23092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strchrnul_works" >&5
23093 $as_echo "$gl_cv_func_strchrnul_works" >&6; }
23094 case "$gl_cv_func_strchrnul_works" in
23095 *yes) ;;
23096 *) REPLACE_STRCHRNUL=1 ;;
23097 esac
23098 fi
23099
23100 if test $HAVE_STRCHRNUL = 0 || test $REPLACE_STRCHRNUL = 1; then
23101
23102
23103
23104
23105
23106
23107
23108
23109 gl_LIBOBJS="$gl_LIBOBJS strchrnul.$ac_objext"
23110
23111 :
23112 fi
23113
23114
23115
23116
23117
23118 GNULIB_STRCHRNUL=1
23119
23120
23121
23122
23123
23124 $as_echo "#define GNULIB_TEST_STRCHRNUL 1" >>confdefs.h
23125
23126
23127
23128
23129
23130
23131
23132 :
23133
23134
23135
23136
23137
23138 if test $ac_cv_func_strdup = yes; then
23139 if test $gl_cv_func_malloc_posix != yes; then
23140 REPLACE_STRDUP=1
23141 fi
23142 fi
23143
23144 :
23145
23146
23147
23148
23149
23150 if test $ac_cv_have_decl_strdup = no; then
23151 HAVE_DECL_STRDUP=0
23152 fi
23153
23154 if test $ac_cv_func_strdup = no || test $REPLACE_STRDUP = 1; then
23155
23156
23157
23158
23159
23160
23161
23162
23163 gl_LIBOBJS="$gl_LIBOBJS strdup.$ac_objext"
23164
23165 :
23166 fi
23167
23168
23169
23170
23171
23172 GNULIB_STRDUP=1
23173
23174
23175
23176
23177
23178 $as_echo "#define GNULIB_TEST_STRDUP 1" >>confdefs.h
23179
23180
23181
23182
23183
23184
23185
23186
23187 if test "$ERRNO_H:$REPLACE_STRERROR_0" = :0; then
23188 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strerror function" >&5
23189 $as_echo_n "checking for working strerror function... " >&6; }
23190 if ${gl_cv_func_working_strerror+:} false; then :
23191 $as_echo_n "(cached) " >&6
23192 else
23193 if test "$cross_compiling" = yes; then :
23194 case "$host_os" in
23195 # Guess yes on glibc systems.
23196 *-gnu*) gl_cv_func_working_strerror="guessing yes" ;;
23197 # If we don't know, assume the worst.
23198 *) gl_cv_func_working_strerror="guessing no" ;;
23199 esac
23200
23201 else
23202 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23203 /* end confdefs.h. */
23204 #include <string.h>
23205
23206 int
23207 main ()
23208 {
23209 if (!*strerror (-2)) return 1;
23210 ;
23211 return 0;
23212 }
23213 _ACEOF
23214 if ac_fn_c_try_run "$LINENO"; then :
23215 gl_cv_func_working_strerror=yes
23216 else
23217 gl_cv_func_working_strerror=no
23218 fi
23219 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23220 conftest.$ac_objext conftest.beam conftest.$ac_ext
23221 fi
23222
23223
23224 fi
23225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_strerror" >&5
23226 $as_echo "$gl_cv_func_working_strerror" >&6; }
23227 case "$gl_cv_func_working_strerror" in
23228 *yes) ;;
23229 *)
23230 REPLACE_STRERROR=1
23231 ;;
23232 esac
23233
23234 else
23235 REPLACE_STRERROR=1
23236 fi
23237
23238 if test $REPLACE_STRERROR = 1; then
23239
23240
23241
23242
23243
23244
23245
23246
23247 gl_LIBOBJS="$gl_LIBOBJS strerror.$ac_objext"
23248
23249 fi
23250
23251
23252 cat >>confdefs.h <<_ACEOF
23253 #define GNULIB_STRERROR 1
23254 _ACEOF
23255
23256
23257
23258
23259
23260
23261
23262 GNULIB_STRERROR=1
23263
23264
23265
23266
23267
23268 $as_echo "#define GNULIB_TEST_STRERROR 1" >>confdefs.h
23269
23270
23271
23272
23273
23274 if test -n "$ERRNO_H" || test $REPLACE_STRERROR_0 = 1; then
23275
23276
23277
23278
23279
23280
23281
23282
23283 gl_LIBOBJS="$gl_LIBOBJS strerror-override.$ac_objext"
23284
23285
23286
23287
23288
23289 :
23290
23291
23292
23293
23294
23295 if test $ac_cv_header_sys_socket_h != yes; then
23296 for ac_header in winsock2.h
23297 do :
23298 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
23299 if test "x$ac_cv_header_winsock2_h" = xyes; then :
23300 cat >>confdefs.h <<_ACEOF
23301 #define HAVE_WINSOCK2_H 1
23302 _ACEOF
23303
23304 fi
23305
23306 done
23307
23308 fi
23309 if test "$ac_cv_header_winsock2_h" = yes; then
23310 HAVE_WINSOCK2_H=1
23311 UNISTD_H_HAVE_WINSOCK2_H=1
23312 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
23313 else
23314 HAVE_WINSOCK2_H=0
23315 fi
23316
23317
23318 fi
23319
23320
23321
23322
23323
23324 if test $REPLACE_STRSTR = 0; then
23325 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strstr works in linear time" >&5
23326 $as_echo_n "checking whether strstr works in linear time... " >&6; }
23327 if ${gl_cv_func_strstr_linear+:} false; then :
23328 $as_echo_n "(cached) " >&6
23329 else
23330 if test "$cross_compiling" = yes; then :
23331 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23332 /* end confdefs.h. */
23333
23334 #include <features.h>
23335 #ifdef __GNU_LIBRARY__
23336 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ > 12) || (__GLIBC__ > 2)) \
23337 && !(defined __i386__ || defined __x86_64__) \
23338 && !defined __UCLIBC__
23339 Lucky user
23340 #endif
23341 #endif
23342 #ifdef __CYGWIN__
23343 #include <cygwin/version.h>
23344 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
23345 Lucky user
23346 #endif
23347 #endif
23348
23349 _ACEOF
23350 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23351 $EGREP "Lucky user" >/dev/null 2>&1; then :
23352 gl_cv_func_strstr_linear="guessing yes"
23353 else
23354 gl_cv_func_strstr_linear="guessing no"
23355 fi
23356 rm -f conftest*
23357
23358
23359 else
23360 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23361 /* end confdefs.h. */
23362
23363 #ifdef __MVS__
23364 /* z/OS does not deliver signals while strstr() is running (thanks to
23365 restrictions on its LE runtime), which prevents us from limiting the
23366 running time of this test. */
23367 # error "This test does not work properly on z/OS"
23368 #endif
23369 #include <signal.h> /* for signal */
23370 #include <string.h> /* for strstr */
23371 #include <stdlib.h> /* for malloc */
23372 #include <unistd.h> /* for alarm */
23373 static void quit (int sig) { _exit (sig + 128); }
23374
23375 int
23376 main ()
23377 {
23378
23379 int result = 0;
23380 size_t m = 1000000;
23381 char *haystack = (char *) malloc (2 * m + 2);
23382 char *needle = (char *) malloc (m + 2);
23383 /* Failure to compile this test due to missing alarm is okay,
23384 since all such platforms (mingw) also have quadratic strstr. */
23385 signal (SIGALRM, quit);
23386 alarm (5);
23387 /* Check for quadratic performance. */
23388 if (haystack && needle)
23389 {
23390 memset (haystack, 'A', 2 * m);
23391 haystack[2 * m] = 'B';
23392 haystack[2 * m + 1] = 0;
23393 memset (needle, 'A', m);
23394 needle[m] = 'B';
23395 needle[m + 1] = 0;
23396 if (!strstr (haystack, needle))
23397 result |= 1;
23398 }
23399 return result;
23400
23401 ;
23402 return 0;
23403 }
23404 _ACEOF
23405 if ac_fn_c_try_run "$LINENO"; then :
23406 gl_cv_func_strstr_linear=yes
23407 else
23408 gl_cv_func_strstr_linear=no
23409 fi
23410 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23411 conftest.$ac_objext conftest.beam conftest.$ac_ext
23412 fi
23413
23414
23415 fi
23416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strstr_linear" >&5
23417 $as_echo "$gl_cv_func_strstr_linear" >&6; }
23418 case "$gl_cv_func_strstr_linear" in
23419 *yes) ;;
23420 *)
23421 REPLACE_STRSTR=1
23422 ;;
23423 esac
23424 fi
23425
23426 if test $REPLACE_STRSTR = 1; then
23427
23428
23429
23430
23431
23432
23433
23434
23435 gl_LIBOBJS="$gl_LIBOBJS strstr.$ac_objext"
23436
23437 fi
23438
23439
23440
23441 if test "$gl_cv_func_memchr_works" != yes; then
23442 REPLACE_STRSTR=1
23443 else
23444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strstr works" >&5
23445 $as_echo_n "checking whether strstr works... " >&6; }
23446 if ${gl_cv_func_strstr_works_always+:} false; then :
23447 $as_echo_n "(cached) " >&6
23448 else
23449 if test "$cross_compiling" = yes; then :
23450 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23451 /* end confdefs.h. */
23452
23453 #ifdef __GNU_LIBRARY__
23454 #include <features.h>
23455 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ > 12) || (__GLIBC__ > 2)) \
23456 || defined __UCLIBC__
23457 Lucky user
23458 #endif
23459 #elif defined __CYGWIN__
23460 #include <cygwin/version.h>
23461 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 7)
23462 Lucky user
23463 #endif
23464 #else
23465 Lucky user
23466 #endif
23467
23468 _ACEOF
23469 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23470 $EGREP "Lucky user" >/dev/null 2>&1; then :
23471 gl_cv_func_strstr_works_always="guessing yes"
23472 else
23473 gl_cv_func_strstr_works_always="guessing no"
23474 fi
23475 rm -f conftest*
23476
23477
23478 else
23479 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23480 /* end confdefs.h. */
23481
23482 #include <string.h> /* for strstr */
23483 #define P "_EF_BF_BD"
23484 #define HAYSTACK "F_BD_CE_BD" P P P P "_C3_88_20" P P P "_C3_A7_20" P
23485 #define NEEDLE P P P P P
23486
23487 int
23488 main ()
23489 {
23490 return !!strstr (HAYSTACK, NEEDLE);
23491
23492 ;
23493 return 0;
23494 }
23495 _ACEOF
23496 if ac_fn_c_try_run "$LINENO"; then :
23497 gl_cv_func_strstr_works_always=yes
23498 else
23499 gl_cv_func_strstr_works_always=no
23500 fi
23501 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23502 conftest.$ac_objext conftest.beam conftest.$ac_ext
23503 fi
23504
23505
23506 fi
23507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strstr_works_always" >&5
23508 $as_echo "$gl_cv_func_strstr_works_always" >&6; }
23509 case "$gl_cv_func_strstr_works_always" in
23510 *yes) ;;
23511 *)
23512 REPLACE_STRSTR=1
23513 ;;
23514 esac
23515 fi
23516
23517 if test $REPLACE_STRSTR = 1; then
23518
23519
23520
23521
23522
23523
23524
23525
23526 gl_LIBOBJS="$gl_LIBOBJS strstr.$ac_objext"
23527
23528 fi
23529
23530
23531
23532
23533
23534 GNULIB_STRSTR=1
23535
23536
23537
23538
23539
23540 $as_echo "#define GNULIB_TEST_STRSTR 1" >>confdefs.h
23541
23542
23543
23544
23545
23546
23547
23548 for ac_func in strtok_r
23549 do :
23550 ac_fn_c_check_func "$LINENO" "strtok_r" "ac_cv_func_strtok_r"
23551 if test "x$ac_cv_func_strtok_r" = xyes; then :
23552 cat >>confdefs.h <<_ACEOF
23553 #define HAVE_STRTOK_R 1
23554 _ACEOF
23555
23556 fi
23557 done
23558
23559 if test $ac_cv_func_strtok_r = yes; then
23560 HAVE_STRTOK_R=1
23561 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtok_r works" >&5
23562 $as_echo_n "checking whether strtok_r works... " >&6; }
23563 if ${gl_cv_func_strtok_r_works+:} false; then :
23564 $as_echo_n "(cached) " >&6
23565 else
23566 if test "$cross_compiling" = yes; then :
23567
23568 case "$host_os" in
23569 # Guess no on glibc systems.
23570 *-gnu*) gl_cv_func_strtok_r_works="guessing no";;
23571 *) gl_cv_func_strtok_r_works="guessing yes";;
23572 esac
23573
23574 else
23575 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23576 /* end confdefs.h. */
23577
23578 #ifndef __OPTIMIZE__
23579 # define __OPTIMIZE__ 1
23580 #endif
23581 #undef __OPTIMIZE_SIZE__
23582 #undef __NO_INLINE__
23583 #include <stdlib.h>
23584 #include <string.h>
23585
23586 int
23587 main ()
23588 {
23589 static const char dummy[] = "\177\01a";
23590 char delimiters[] = "xxxxxxxx";
23591 char *save_ptr = (char *) dummy;
23592 strtok_r (delimiters, "x", &save_ptr);
23593 strtok_r (NULL, "x", &save_ptr);
23594 return 0;
23595
23596 ;
23597 return 0;
23598 }
23599
23600 _ACEOF
23601 if ac_fn_c_try_run "$LINENO"; then :
23602 gl_cv_func_strtok_r_works=yes
23603 else
23604 gl_cv_func_strtok_r_works=no
23605 fi
23606 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23607 conftest.$ac_objext conftest.beam conftest.$ac_ext
23608 fi
23609
23610
23611 fi
23612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strtok_r_works" >&5
23613 $as_echo "$gl_cv_func_strtok_r_works" >&6; }
23614 case "$gl_cv_func_strtok_r_works" in
23615 *no)
23616 UNDEFINE_STRTOK_R=1
23617 ;;
23618 esac
23619 else
23620 HAVE_STRTOK_R=0
23621 fi
23622
23623 :
23624
23625
23626
23627
23628
23629 if test $ac_cv_have_decl_strtok_r = no; then
23630 HAVE_DECL_STRTOK_R=0
23631 fi
23632
23633 if test $HAVE_STRTOK_R = 0 || test $REPLACE_STRTOK_R = 1; then
23634
23635
23636
23637
23638
23639
23640
23641
23642 gl_LIBOBJS="$gl_LIBOBJS strtok_r.$ac_objext"
23643
23644
23645 :
23646
23647 fi
23648
23649
23650
23651
23652
23653 GNULIB_STRTOK_R=1
23654
23655
23656
23657
23658
23659 $as_echo "#define GNULIB_TEST_STRTOK_R 1" >>confdefs.h
23660
23661
23662
23663
23664
23665
23666
23667
23668
23669
23670
23671
23672
23673
23674 :
23675
23676
23677
23678
23679
23680
23681
23682
23683 if test $gl_cv_have_include_next = yes; then
23684 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
23685 else
23686 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
23687 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
23688 if ${gl_cv_next_sys_stat_h+:} false; then :
23689 $as_echo_n "(cached) " >&6
23690 else
23691
23692 if test $ac_cv_header_sys_stat_h = yes; then
23693
23694
23695
23696
23697 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23698 /* end confdefs.h. */
23699 #include <sys/stat.h>
23700 _ACEOF
23701 case "$host_os" in
23702 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23703 *) gl_absname_cpp="$ac_cpp" ;;
23704 esac
23705
23706 case "$host_os" in
23707 mingw*)
23708 gl_dirsep_regex='[/\\]'
23709 ;;
23710 *)
23711 gl_dirsep_regex='\/'
23712 ;;
23713 esac
23714 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23715 gl_header_literal_regex=`echo 'sys/stat.h' \
23716 | sed -e "$gl_make_literal_regex_sed"`
23717 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23718 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23719 s|^/[^/]|//&|
23720 p
23721 q
23722 }'
23723
23724 gl_cv_absolute_sys_stat_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23725 sed -n "$gl_absolute_header_sed"`
23726
23727 gl_header=$gl_cv_absolute_sys_stat_h
23728 gl_cv_next_sys_stat_h='"'$gl_header'"'
23729 else
23730 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
23731 fi
23732
23733
23734 fi
23735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
23736 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
23737 fi
23738 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
23739
23740 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23741 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23742 gl_next_as_first_directive='<'sys/stat.h'>'
23743 else
23744 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23745 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
23746 fi
23747 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
23748
23749
23750
23751
23752
23753
23754
23755
23756
23757
23758
23759 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
23760
23761 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
23762
23763 fi
23764
23765 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
23766 #include <sys/stat.h>
23767 "
23768 if test "x$ac_cv_type_nlink_t" = xyes; then :
23769
23770 else
23771
23772 $as_echo "#define nlink_t int" >>confdefs.h
23773
23774 fi
23775
23776
23777
23778 for gl_func in fchmodat fstat fstatat futimens lchmod lstat mkdirat mkfifo mkfifoat mknod mknodat stat utimensat; do
23779 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
23780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
23781 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
23782 if eval \${$as_gl_Symbol+:} false; then :
23783 $as_echo_n "(cached) " >&6
23784 else
23785 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23786 /* end confdefs.h. */
23787 #include <sys/stat.h>
23788
23789 int
23790 main ()
23791 {
23792 #undef $gl_func
23793 (void) $gl_func;
23794 ;
23795 return 0;
23796 }
23797 _ACEOF
23798 if ac_fn_c_try_compile "$LINENO"; then :
23799 eval "$as_gl_Symbol=yes"
23800 else
23801 eval "$as_gl_Symbol=no"
23802 fi
23803 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23804 fi
23805 eval ac_res=\$$as_gl_Symbol
23806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
23807 $as_echo "$ac_res" >&6; }
23808 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
23809 cat >>confdefs.h <<_ACEOF
23810 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
23811 _ACEOF
23812
23813 eval ac_cv_have_decl_$gl_func=yes
23814 fi
23815 done
23816
23817
23818
23819
23820
23821
23822
23823
23824
23825
23826
23827 :
23828
23829
23830
23831
23832
23833
23834
23835
23836
23837
23838
23839
23840
23841
23842 :
23843
23844
23845
23846
23847
23848
23849
23850
23851 if test $gl_cv_have_include_next = yes; then
23852 gl_cv_next_unistd_h='<'unistd.h'>'
23853 else
23854 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
23855 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
23856 if ${gl_cv_next_unistd_h+:} false; then :
23857 $as_echo_n "(cached) " >&6
23858 else
23859
23860 if test $ac_cv_header_unistd_h = yes; then
23861
23862
23863
23864
23865 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23866 /* end confdefs.h. */
23867 #include <unistd.h>
23868 _ACEOF
23869 case "$host_os" in
23870 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23871 *) gl_absname_cpp="$ac_cpp" ;;
23872 esac
23873
23874 case "$host_os" in
23875 mingw*)
23876 gl_dirsep_regex='[/\\]'
23877 ;;
23878 *)
23879 gl_dirsep_regex='\/'
23880 ;;
23881 esac
23882 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23883 gl_header_literal_regex=`echo 'unistd.h' \
23884 | sed -e "$gl_make_literal_regex_sed"`
23885 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23886 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23887 s|^/[^/]|//&|
23888 p
23889 q
23890 }'
23891
23892 gl_cv_absolute_unistd_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23893 sed -n "$gl_absolute_header_sed"`
23894
23895 gl_header=$gl_cv_absolute_unistd_h
23896 gl_cv_next_unistd_h='"'$gl_header'"'
23897 else
23898 gl_cv_next_unistd_h='<'unistd.h'>'
23899 fi
23900
23901
23902 fi
23903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
23904 $as_echo "$gl_cv_next_unistd_h" >&6; }
23905 fi
23906 NEXT_UNISTD_H=$gl_cv_next_unistd_h
23907
23908 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23909 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23910 gl_next_as_first_directive='<'unistd.h'>'
23911 else
23912 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23913 gl_next_as_first_directive=$gl_cv_next_unistd_h
23914 fi
23915 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
23916
23917
23918
23919
23920 if test $ac_cv_header_unistd_h = yes; then
23921 HAVE_UNISTD_H=1
23922 else
23923 HAVE_UNISTD_H=0
23924 fi
23925
23926
23927
23928
23929
23930
23931
23932 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
23933 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
23934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
23935 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
23936 if eval \${$as_gl_Symbol+:} false; then :
23937 $as_echo_n "(cached) " >&6
23938 else
23939 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23940 /* end confdefs.h. */
23941
23942 #if HAVE_UNISTD_H
23943 # include <unistd.h>
23944 #endif
23945 /* Some systems declare various items in the wrong headers. */
23946 #if !(defined __GLIBC__ && !defined __UCLIBC__)
23947 # include <fcntl.h>
23948 # include <stdio.h>
23949 # include <stdlib.h>
23950 # if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
23951 # include <io.h>
23952 # endif
23953 #endif
23954
23955 int
23956 main ()
23957 {
23958 #undef $gl_func
23959 (void) $gl_func;
23960 ;
23961 return 0;
23962 }
23963 _ACEOF
23964 if ac_fn_c_try_compile "$LINENO"; then :
23965 eval "$as_gl_Symbol=yes"
23966 else
23967 eval "$as_gl_Symbol=no"
23968 fi
23969 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23970 fi
23971 eval ac_res=\$$as_gl_Symbol
23972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
23973 $as_echo "$ac_res" >&6; }
23974 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
23975 cat >>confdefs.h <<_ACEOF
23976 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
23977 _ACEOF
23978
23979 eval ac_cv_have_decl_$gl_func=yes
23980 fi
23981 done
23982
23983
23984
23985
23986 :
23987
23988
23989
23990
23991
23992
23993
23994
23995
23996 :
23997
23998
23999
24000
24001
24002 if test $ac_cv_have_decl_unsetenv = no; then
24003 HAVE_DECL_UNSETENV=0
24004 fi
24005 for ac_func in unsetenv
24006 do :
24007 ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv"
24008 if test "x$ac_cv_func_unsetenv" = xyes; then :
24009 cat >>confdefs.h <<_ACEOF
24010 #define HAVE_UNSETENV 1
24011 _ACEOF
24012
24013 fi
24014 done
24015
24016 if test $ac_cv_func_unsetenv = no; then
24017 HAVE_UNSETENV=0
24018 else
24019 HAVE_UNSETENV=1
24020 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsetenv() return type" >&5
24021 $as_echo_n "checking for unsetenv() return type... " >&6; }
24022 if ${gt_cv_func_unsetenv_ret+:} false; then :
24023 $as_echo_n "(cached) " >&6
24024 else
24025 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24026 /* end confdefs.h. */
24027
24028 #undef _BSD
24029 #define _BSD 1 /* unhide unsetenv declaration in OSF/1 5.1 <stdlib.h> */
24030 #include <stdlib.h>
24031 extern
24032 #ifdef __cplusplus
24033 "C"
24034 #endif
24035 int unsetenv (const char *name);
24036
24037 int
24038 main ()
24039 {
24040
24041 ;
24042 return 0;
24043 }
24044 _ACEOF
24045 if ac_fn_c_try_compile "$LINENO"; then :
24046 gt_cv_func_unsetenv_ret='int'
24047 else
24048 gt_cv_func_unsetenv_ret='void'
24049 fi
24050 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24051 fi
24052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_unsetenv_ret" >&5
24053 $as_echo "$gt_cv_func_unsetenv_ret" >&6; }
24054 if test $gt_cv_func_unsetenv_ret = 'void'; then
24055
24056 $as_echo "#define VOID_UNSETENV 1" >>confdefs.h
24057
24058 REPLACE_UNSETENV=1
24059 fi
24060
24061 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether unsetenv obeys POSIX" >&5
24062 $as_echo_n "checking whether unsetenv obeys POSIX... " >&6; }
24063 if ${gl_cv_func_unsetenv_works+:} false; then :
24064 $as_echo_n "(cached) " >&6
24065 else
24066 if test "$cross_compiling" = yes; then :
24067 case "$host_os" in
24068 # Guess yes on glibc systems.
24069 *-gnu*) gl_cv_func_unsetenv_works="guessing yes" ;;
24070 # If we don't know, assume the worst.
24071 *) gl_cv_func_unsetenv_works="guessing no" ;;
24072 esac
24073
24074 else
24075 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24076 /* end confdefs.h. */
24077
24078 #include <stdlib.h>
24079 #include <errno.h>
24080 extern char **environ;
24081
24082 int
24083 main ()
24084 {
24085
24086 char entry1[] = "a=1";
24087 char entry2[] = "b=2";
24088 char *env[] = { entry1, entry2, NULL };
24089 if (putenv ((char *) "a=1")) return 1;
24090 if (putenv (entry2)) return 2;
24091 entry2[0] = 'a';
24092 unsetenv ("a");
24093 if (getenv ("a")) return 3;
24094 if (!unsetenv ("") || errno != EINVAL) return 4;
24095 entry2[0] = 'b';
24096 environ = env;
24097 if (!getenv ("a")) return 5;
24098 entry2[0] = 'a';
24099 unsetenv ("a");
24100 if (getenv ("a")) return 6;
24101
24102 ;
24103 return 0;
24104 }
24105 _ACEOF
24106 if ac_fn_c_try_run "$LINENO"; then :
24107 gl_cv_func_unsetenv_works=yes
24108 else
24109 gl_cv_func_unsetenv_works=no
24110 fi
24111 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24112 conftest.$ac_objext conftest.beam conftest.$ac_ext
24113 fi
24114
24115 fi
24116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_unsetenv_works" >&5
24117 $as_echo "$gl_cv_func_unsetenv_works" >&6; }
24118 case "$gl_cv_func_unsetenv_works" in
24119 *yes) ;;
24120 *)
24121 REPLACE_UNSETENV=1
24122 ;;
24123 esac
24124 fi
24125
24126 if test $HAVE_UNSETENV = 0 || test $REPLACE_UNSETENV = 1; then
24127
24128
24129
24130
24131
24132
24133
24134
24135 gl_LIBOBJS="$gl_LIBOBJS unsetenv.$ac_objext"
24136
24137
24138
24139
24140 :
24141
24142
24143
24144
24145
24146
24147 fi
24148
24149
24150
24151
24152
24153 GNULIB_UNSETENV=1
24154
24155
24156
24157
24158
24159 $as_echo "#define GNULIB_TEST_UNSETENV 1" >>confdefs.h
24160
24161
24162
24163
24164
24165
24166
24167
24168
24169
24170
24171
24172 :
24173
24174
24175
24176
24177
24178
24179
24180
24181 if test $gl_cv_have_include_next = yes; then
24182 gl_cv_next_wchar_h='<'wchar.h'>'
24183 else
24184 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <wchar.h>" >&5
24185 $as_echo_n "checking absolute name of <wchar.h>... " >&6; }
24186 if ${gl_cv_next_wchar_h+:} false; then :
24187 $as_echo_n "(cached) " >&6
24188 else
24189
24190 if test $ac_cv_header_wchar_h = yes; then
24191
24192
24193
24194
24195 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24196 /* end confdefs.h. */
24197 #include <wchar.h>
24198 _ACEOF
24199 case "$host_os" in
24200 aix*) gl_absname_cpp="$ac_cpp -C" ;;
24201 *) gl_absname_cpp="$ac_cpp" ;;
24202 esac
24203
24204 case "$host_os" in
24205 mingw*)
24206 gl_dirsep_regex='[/\\]'
24207 ;;
24208 *)
24209 gl_dirsep_regex='\/'
24210 ;;
24211 esac
24212 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
24213 gl_header_literal_regex=`echo 'wchar.h' \
24214 | sed -e "$gl_make_literal_regex_sed"`
24215 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
24216 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
24217 s|^/[^/]|//&|
24218 p
24219 q
24220 }'
24221
24222 gl_cv_absolute_wchar_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
24223 sed -n "$gl_absolute_header_sed"`
24224
24225 gl_header=$gl_cv_absolute_wchar_h
24226 gl_cv_next_wchar_h='"'$gl_header'"'
24227 else
24228 gl_cv_next_wchar_h='<'wchar.h'>'
24229 fi
24230
24231
24232 fi
24233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wchar_h" >&5
24234 $as_echo "$gl_cv_next_wchar_h" >&6; }
24235 fi
24236 NEXT_WCHAR_H=$gl_cv_next_wchar_h
24237
24238 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
24239 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
24240 gl_next_as_first_directive='<'wchar.h'>'
24241 else
24242 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
24243 gl_next_as_first_directive=$gl_cv_next_wchar_h
24244 fi
24245 NEXT_AS_FIRST_DIRECTIVE_WCHAR_H=$gl_next_as_first_directive
24246
24247
24248
24249
24250 if test $ac_cv_header_wchar_h = yes; then
24251 HAVE_WCHAR_H=1
24252 else
24253 HAVE_WCHAR_H=0
24254 fi
24255
24256
24257
24258
24259
24260 if test $gt_cv_c_wint_t = yes; then
24261 HAVE_WINT_T=1
24262 else
24263 HAVE_WINT_T=0
24264 fi
24265
24266
24267
24268 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
24269 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
24270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
24271 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
24272 if eval \${$as_gl_Symbol+:} false; then :
24273 $as_echo_n "(cached) " >&6
24274 else
24275 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24276 /* end confdefs.h. */
24277
24278 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
24279 <wchar.h>.
24280 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
24281 included before <wchar.h>. */
24282 #if !(defined __GLIBC__ && !defined __UCLIBC__)
24283 # include <stddef.h>
24284 # include <stdio.h>
24285 # include <time.h>
24286 #endif
24287 #include <wchar.h>
24288
24289 int
24290 main ()
24291 {
24292 #undef $gl_func
24293 (void) $gl_func;
24294 ;
24295 return 0;
24296 }
24297 _ACEOF
24298 if ac_fn_c_try_compile "$LINENO"; then :
24299 eval "$as_gl_Symbol=yes"
24300 else
24301 eval "$as_gl_Symbol=no"
24302 fi
24303 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24304 fi
24305 eval ac_res=\$$as_gl_Symbol
24306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
24307 $as_echo "$ac_res" >&6; }
24308 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
24309 cat >>confdefs.h <<_ACEOF
24310 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
24311 _ACEOF
24312
24313 eval ac_cv_have_decl_$gl_func=yes
24314 fi
24315 done
24316
24317
24318
24319
24320
24321
24322
24323 :
24324
24325
24326
24327
24328
24329 if test $ac_cv_func_iswcntrl = yes; then
24330 HAVE_ISWCNTRL=1
24331 else
24332 HAVE_ISWCNTRL=0
24333 fi
24334
24335
24336
24337 if test $gt_cv_c_wint_t = yes; then
24338 HAVE_WINT_T=1
24339 else
24340 HAVE_WINT_T=0
24341 fi
24342
24343
24344
24345
24346
24347
24348
24349
24350 :
24351
24352
24353
24354
24355
24356
24357
24358
24359 if test $gl_cv_have_include_next = yes; then
24360 gl_cv_next_wctype_h='<'wctype.h'>'
24361 else
24362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <wctype.h>" >&5
24363 $as_echo_n "checking absolute name of <wctype.h>... " >&6; }
24364 if ${gl_cv_next_wctype_h+:} false; then :
24365 $as_echo_n "(cached) " >&6
24366 else
24367
24368 if test $ac_cv_header_wctype_h = yes; then
24369
24370
24371
24372
24373 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24374 /* end confdefs.h. */
24375 #include <wctype.h>
24376 _ACEOF
24377 case "$host_os" in
24378 aix*) gl_absname_cpp="$ac_cpp -C" ;;
24379 *) gl_absname_cpp="$ac_cpp" ;;
24380 esac
24381
24382 case "$host_os" in
24383 mingw*)
24384 gl_dirsep_regex='[/\\]'
24385 ;;
24386 *)
24387 gl_dirsep_regex='\/'
24388 ;;
24389 esac
24390 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
24391 gl_header_literal_regex=`echo 'wctype.h' \
24392 | sed -e "$gl_make_literal_regex_sed"`
24393 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
24394 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
24395 s|^/[^/]|//&|
24396 p
24397 q
24398 }'
24399
24400 gl_cv_absolute_wctype_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
24401 sed -n "$gl_absolute_header_sed"`
24402
24403 gl_header=$gl_cv_absolute_wctype_h
24404 gl_cv_next_wctype_h='"'$gl_header'"'
24405 else
24406 gl_cv_next_wctype_h='<'wctype.h'>'
24407 fi
24408
24409
24410 fi
24411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wctype_h" >&5
24412 $as_echo "$gl_cv_next_wctype_h" >&6; }
24413 fi
24414 NEXT_WCTYPE_H=$gl_cv_next_wctype_h
24415
24416 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
24417 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
24418 gl_next_as_first_directive='<'wctype.h'>'
24419 else
24420 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
24421 gl_next_as_first_directive=$gl_cv_next_wctype_h
24422 fi
24423 NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H=$gl_next_as_first_directive
24424
24425
24426
24427
24428 if test $ac_cv_header_wctype_h = yes; then
24429 if test $ac_cv_func_iswcntrl = yes; then
24430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether iswcntrl works" >&5
24431 $as_echo_n "checking whether iswcntrl works... " >&6; }
24432 if ${gl_cv_func_iswcntrl_works+:} false; then :
24433 $as_echo_n "(cached) " >&6
24434 else
24435
24436 if test "$cross_compiling" = yes; then :
24437 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24438 /* end confdefs.h. */
24439 #include <stdlib.h>
24440 #if __GNU_LIBRARY__ == 1
24441 Linux libc5 i18n is broken.
24442 #endif
24443 int
24444 main ()
24445 {
24446
24447 ;
24448 return 0;
24449 }
24450 _ACEOF
24451 if ac_fn_c_try_compile "$LINENO"; then :
24452 gl_cv_func_iswcntrl_works="guessing yes"
24453 else
24454 gl_cv_func_iswcntrl_works="guessing no"
24455 fi
24456 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24457
24458 else
24459 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24460 /* end confdefs.h. */
24461
24462 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
24463 included before <wchar.h>.
24464 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
24465 must be included before <wchar.h>. */
24466 #include <stddef.h>
24467 #include <stdio.h>
24468 #include <time.h>
24469 #include <wchar.h>
24470 #include <wctype.h>
24471 int main () { return iswprint ('x') == 0; }
24472
24473 _ACEOF
24474 if ac_fn_c_try_run "$LINENO"; then :
24475 gl_cv_func_iswcntrl_works=yes
24476 else
24477 gl_cv_func_iswcntrl_works=no
24478 fi
24479 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24480 conftest.$ac_objext conftest.beam conftest.$ac_ext
24481 fi
24482
24483
24484 fi
24485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_iswcntrl_works" >&5
24486 $as_echo "$gl_cv_func_iswcntrl_works" >&6; }
24487 fi
24488 HAVE_WCTYPE_H=1
24489 else
24490 HAVE_WCTYPE_H=0
24491 fi
24492
24493
24494 case "$gl_cv_func_iswcntrl_works" in
24495 *yes) REPLACE_ISWCNTRL=0 ;;
24496 *) REPLACE_ISWCNTRL=1 ;;
24497 esac
24498
24499
24500 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_ISWCNTRL = 1; then
24501 :
24502 fi
24503
24504 if test $REPLACE_ISWCNTRL = 1; then
24505 REPLACE_TOWLOWER=1
24506 else
24507 for ac_func in towlower
24508 do :
24509 ac_fn_c_check_func "$LINENO" "towlower" "ac_cv_func_towlower"
24510 if test "x$ac_cv_func_towlower" = xyes; then :
24511 cat >>confdefs.h <<_ACEOF
24512 #define HAVE_TOWLOWER 1
24513 _ACEOF
24514
24515 fi
24516 done
24517
24518 if test $ac_cv_func_towlower = yes; then
24519 REPLACE_TOWLOWER=0
24520 else
24521 ac_fn_c_check_decl "$LINENO" "towlower" "ac_cv_have_decl_towlower" "/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
24522 included before <wchar.h>.
24523 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
24524 must be included before <wchar.h>. */
24525 #include <stddef.h>
24526 #include <stdio.h>
24527 #include <time.h>
24528 #include <wchar.h>
24529 #if HAVE_WCTYPE_H
24530 # include <wctype.h>
24531 #endif
24532
24533 "
24534 if test "x$ac_cv_have_decl_towlower" = xyes; then :
24535 ac_have_decl=1
24536 else
24537 ac_have_decl=0
24538 fi
24539
24540 cat >>confdefs.h <<_ACEOF
24541 #define HAVE_DECL_TOWLOWER $ac_have_decl
24542 _ACEOF
24543
24544 if test $ac_cv_have_decl_towlower = yes; then
24545 REPLACE_TOWLOWER=1
24546 else
24547 REPLACE_TOWLOWER=0
24548 fi
24549 fi
24550 fi
24551
24552
24553 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_TOWLOWER = 1; then
24554 :
24555 fi
24556
24557 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctype_t" >&5
24558 $as_echo_n "checking for wctype_t... " >&6; }
24559 if ${gl_cv_type_wctype_t+:} false; then :
24560 $as_echo_n "(cached) " >&6
24561 else
24562 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24563 /* end confdefs.h. */
24564 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
24565 included before <wchar.h>.
24566 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
24567 must be included before <wchar.h>. */
24568 #include <stddef.h>
24569 #include <stdio.h>
24570 #include <time.h>
24571 #include <wchar.h>
24572 #if HAVE_WCTYPE_H
24573 # include <wctype.h>
24574 #endif
24575 wctype_t a;
24576
24577 int
24578 main ()
24579 {
24580
24581 ;
24582 return 0;
24583 }
24584 _ACEOF
24585 if ac_fn_c_try_compile "$LINENO"; then :
24586 gl_cv_type_wctype_t=yes
24587 else
24588 gl_cv_type_wctype_t=no
24589 fi
24590 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24591
24592 fi
24593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctype_t" >&5
24594 $as_echo "$gl_cv_type_wctype_t" >&6; }
24595 if test $gl_cv_type_wctype_t = no; then
24596 HAVE_WCTYPE_T=0
24597 fi
24598
24599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctrans_t" >&5
24600 $as_echo_n "checking for wctrans_t... " >&6; }
24601 if ${gl_cv_type_wctrans_t+:} false; then :
24602 $as_echo_n "(cached) " >&6
24603 else
24604 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24605 /* end confdefs.h. */
24606 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
24607 included before <wchar.h>.
24608 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
24609 must be included before <wchar.h>. */
24610 #include <stddef.h>
24611 #include <stdio.h>
24612 #include <time.h>
24613 #include <wchar.h>
24614 #include <wctype.h>
24615 wctrans_t a;
24616
24617 int
24618 main ()
24619 {
24620
24621 ;
24622 return 0;
24623 }
24624 _ACEOF
24625 if ac_fn_c_try_compile "$LINENO"; then :
24626 gl_cv_type_wctrans_t=yes
24627 else
24628 gl_cv_type_wctrans_t=no
24629 fi
24630 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24631
24632 fi
24633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctrans_t" >&5
24634 $as_echo "$gl_cv_type_wctrans_t" >&6; }
24635 if test $gl_cv_type_wctrans_t = no; then
24636 HAVE_WCTRANS_T=0
24637 fi
24638
24639
24640 for gl_func in wctype iswctype wctrans towctrans ; do
24641 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
24642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
24643 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
24644 if eval \${$as_gl_Symbol+:} false; then :
24645 $as_echo_n "(cached) " >&6
24646 else
24647 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24648 /* end confdefs.h. */
24649
24650 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
24651 <wchar.h>.
24652 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
24653 included before <wchar.h>. */
24654 #if !(defined __GLIBC__ && !defined __UCLIBC__)
24655 # include <stddef.h>
24656 # include <stdio.h>
24657 # include <time.h>
24658 # include <wchar.h>
24659 #endif
24660 #include <wctype.h>
24661
24662 int
24663 main ()
24664 {
24665 #undef $gl_func
24666 (void) $gl_func;
24667 ;
24668 return 0;
24669 }
24670 _ACEOF
24671 if ac_fn_c_try_compile "$LINENO"; then :
24672 eval "$as_gl_Symbol=yes"
24673 else
24674 eval "$as_gl_Symbol=no"
24675 fi
24676 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24677 fi
24678 eval ac_res=\$$as_gl_Symbol
24679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
24680 $as_echo "$ac_res" >&6; }
24681 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
24682 cat >>confdefs.h <<_ACEOF
24683 #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
24684 _ACEOF
24685
24686 eval ac_cv_have_decl_$gl_func=yes
24687 fi
24688 done
24689
24690
24691 # End of code from modules
24692
24693
24694
24695
24696
24697
24698
24699
24700
24701 gltests_libdeps=
24702 gltests_ltlibdeps=
24703
24704
24705
24706
24707
24708
24709
24710
24711
24712 gl_source_base='tests'
24713 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
24714
24715 gl_module_indicator_condition=$gltests_WITNESS
24716
24717
24718
24719
24720
24721
24722
24723
24724
24725 LIBGNU_LIBDEPS="$gl_libdeps"
24726
24727 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
24728
24729
24730
24731 # We don't use automake, but gnulib does. This line lets us generate
24732 # its Makefile.in.
24733 am__api_version='1.15'
24734
24735 # Find a good install program. We prefer a C program (faster),
24736 # so one script is as good as another. But avoid the broken or
24737 # incompatible versions:
24738 # SysV /etc/install, /usr/sbin/install
24739 # SunOS /usr/etc/install
24740 # IRIX /sbin/install
24741 # AIX /bin/install
24742 # AmigaOS /C/install, which installs bootblocks on floppy discs
24743 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
24744 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
24745 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
24746 # OS/2's system install, which has a completely different semantic
24747 # ./install, which can be erroneously created by make from ./install.sh.
24748 # Reject install programs that cannot install multiple files.
24749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
24750 $as_echo_n "checking for a BSD-compatible install... " >&6; }
24751 if test -z "$INSTALL"; then
24752 if ${ac_cv_path_install+:} false; then :
24753 $as_echo_n "(cached) " >&6
24754 else
24755 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24756 for as_dir in $PATH
24757 do
24758 IFS=$as_save_IFS
24759 test -z "$as_dir" && as_dir=.
24760 # Account for people who put trailing slashes in PATH elements.
24761 case $as_dir/ in #((
24762 ./ | .// | /[cC]/* | \
24763 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
24764 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
24765 /usr/ucb/* ) ;;
24766 *)
24767 # OSF1 and SCO ODT 3.0 have their own names for install.
24768 # Don't use installbsd from OSF since it installs stuff as root
24769 # by default.
24770 for ac_prog in ginstall scoinst install; do
24771 for ac_exec_ext in '' $ac_executable_extensions; do
24772 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
24773 if test $ac_prog = install &&
24774 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
24775 # AIX install. It has an incompatible calling convention.
24776 :
24777 elif test $ac_prog = install &&
24778 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
24779 # program-specific install script used by HP pwplus--don't use.
24780 :
24781 else
24782 rm -rf conftest.one conftest.two conftest.dir
24783 echo one > conftest.one
24784 echo two > conftest.two
24785 mkdir conftest.dir
24786 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
24787 test -s conftest.one && test -s conftest.two &&
24788 test -s conftest.dir/conftest.one &&
24789 test -s conftest.dir/conftest.two
24790 then
24791 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
24792 break 3
24793 fi
24794 fi
24795 fi
24796 done
24797 done
24798 ;;
24799 esac
24800
24801 done
24802 IFS=$as_save_IFS
24803
24804 rm -rf conftest.one conftest.two conftest.dir
24805
24806 fi
24807 if test "${ac_cv_path_install+set}" = set; then
24808 INSTALL=$ac_cv_path_install
24809 else
24810 # As a last resort, use the slow shell script. Don't cache a
24811 # value for INSTALL within a source directory, because that will
24812 # break other packages using the cache if that directory is
24813 # removed, or if the value is a relative name.
24814 INSTALL=$ac_install_sh
24815 fi
24816 fi
24817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
24818 $as_echo "$INSTALL" >&6; }
24819
24820 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
24821 # It thinks the first close brace ends the variable substitution.
24822 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
24823
24824 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
24825
24826 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
24827
24828 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
24829 $as_echo_n "checking whether build environment is sane... " >&6; }
24830 # Reject unsafe characters in $srcdir or the absolute working directory
24831 # name. Accept space and tab only in the latter.
24832 am_lf='
24833 '
24834 case `pwd` in
24835 *[\\\"\#\$\&\'\`$am_lf]*)
24836 as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
24837 esac
24838 case $srcdir in
24839 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
24840 as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
24841 esac
24842
24843 # Do 'set' in a subshell so we don't clobber the current shell's
24844 # arguments. Must try -L first in case configure is actually a
24845 # symlink; some systems play weird games with the mod time of symlinks
24846 # (eg FreeBSD returns the mod time of the symlink's containing
24847 # directory).
24848 if (
24849 am_has_slept=no
24850 for am_try in 1 2; do
24851 echo "timestamp, slept: $am_has_slept" > conftest.file
24852 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
24853 if test "$*" = "X"; then
24854 # -L didn't work.
24855 set X `ls -t "$srcdir/configure" conftest.file`
24856 fi
24857 if test "$*" != "X $srcdir/configure conftest.file" \
24858 && test "$*" != "X conftest.file $srcdir/configure"; then
24859
24860 # If neither matched, then we have a broken ls. This can happen
24861 # if, for instance, CONFIG_SHELL is bash and it inherits a
24862 # broken ls alias from the environment. This has actually
24863 # happened. Such a system could not be considered "sane".
24864 as_fn_error $? "ls -t appears to fail. Make sure there is not a broken
24865 alias in your environment" "$LINENO" 5
24866 fi
24867 if test "$2" = conftest.file || test $am_try -eq 2; then
24868 break
24869 fi
24870 # Just in case.
24871 sleep 1
24872 am_has_slept=yes
24873 done
24874 test "$2" = conftest.file
24875 )
24876 then
24877 # Ok.
24878 :
24879 else
24880 as_fn_error $? "newly created file is older than distributed files!
24881 Check your system clock" "$LINENO" 5
24882 fi
24883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
24884 $as_echo "yes" >&6; }
24885 # If we didn't sleep, we still need to ensure time stamps of config.status and
24886 # generated files are strictly newer.
24887 am_sleep_pid=
24888 if grep 'slept: no' conftest.file >/dev/null 2>&1; then
24889 ( sleep 1 ) &
24890 am_sleep_pid=$!
24891 fi
24892
24893 rm -f conftest.file
24894
24895 test "$program_prefix" != NONE &&
24896 program_transform_name="s&^&$program_prefix&;$program_transform_name"
24897 # Use a double $ so make ignores it.
24898 test "$program_suffix" != NONE &&
24899 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
24900 # Double any \ or $.
24901 # By default was `s,x,x', remove it if useless.
24902 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
24903 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
24904
24905 if test x"${MISSING+set}" != xset; then
24906 case $am_aux_dir in
24907 *\ * | *\ *)
24908 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
24909 *)
24910 MISSING="\${SHELL} $am_aux_dir/missing" ;;
24911 esac
24912 fi
24913 # Use eval to expand $SHELL
24914 if eval "$MISSING --is-lightweight"; then
24915 am_missing_run="$MISSING "
24916 else
24917 am_missing_run=
24918 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
24919 $as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
24920 fi
24921
24922 if test x"${install_sh+set}" != xset; then
24923 case $am_aux_dir in
24924 *\ * | *\ *)
24925 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
24926 *)
24927 install_sh="\${SHELL} $am_aux_dir/install-sh"
24928 esac
24929 fi
24930
24931 # Installed binaries are usually stripped using 'strip' when the user
24932 # run "make install-strip". However 'strip' might not be the right
24933 # tool to use in cross-compilation environments, therefore Automake
24934 # will honor the 'STRIP' environment variable to overrule this program.
24935 if test "$cross_compiling" != no; then
24936 if test -n "$ac_tool_prefix"; then
24937 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
24938 set dummy ${ac_tool_prefix}strip; ac_word=$2
24939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24940 $as_echo_n "checking for $ac_word... " >&6; }
24941 if ${ac_cv_prog_STRIP+:} false; then :
24942 $as_echo_n "(cached) " >&6
24943 else
24944 if test -n "$STRIP"; then
24945 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
24946 else
24947 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24948 for as_dir in $PATH
24949 do
24950 IFS=$as_save_IFS
24951 test -z "$as_dir" && as_dir=.
24952 for ac_exec_ext in '' $ac_executable_extensions; do
24953 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24954 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
24955 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24956 break 2
24957 fi
24958 done
24959 done
24960 IFS=$as_save_IFS
24961
24962 fi
24963 fi
24964 STRIP=$ac_cv_prog_STRIP
24965 if test -n "$STRIP"; then
24966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
24967 $as_echo "$STRIP" >&6; }
24968 else
24969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24970 $as_echo "no" >&6; }
24971 fi
24972
24973
24974 fi
24975 if test -z "$ac_cv_prog_STRIP"; then
24976 ac_ct_STRIP=$STRIP
24977 # Extract the first word of "strip", so it can be a program name with args.
24978 set dummy strip; ac_word=$2
24979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24980 $as_echo_n "checking for $ac_word... " >&6; }
24981 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
24982 $as_echo_n "(cached) " >&6
24983 else
24984 if test -n "$ac_ct_STRIP"; then
24985 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
24986 else
24987 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24988 for as_dir in $PATH
24989 do
24990 IFS=$as_save_IFS
24991 test -z "$as_dir" && as_dir=.
24992 for ac_exec_ext in '' $ac_executable_extensions; do
24993 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24994 ac_cv_prog_ac_ct_STRIP="strip"
24995 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24996 break 2
24997 fi
24998 done
24999 done
25000 IFS=$as_save_IFS
25001
25002 fi
25003 fi
25004 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
25005 if test -n "$ac_ct_STRIP"; then
25006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
25007 $as_echo "$ac_ct_STRIP" >&6; }
25008 else
25009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25010 $as_echo "no" >&6; }
25011 fi
25012
25013 if test "x$ac_ct_STRIP" = x; then
25014 STRIP=":"
25015 else
25016 case $cross_compiling:$ac_tool_warned in
25017 yes:)
25018 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
25019 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
25020 ac_tool_warned=yes ;;
25021 esac
25022 STRIP=$ac_ct_STRIP
25023 fi
25024 else
25025 STRIP="$ac_cv_prog_STRIP"
25026 fi
25027
25028 fi
25029 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
25030
25031 for ac_prog in gawk mawk nawk awk
25032 do
25033 # Extract the first word of "$ac_prog", so it can be a program name with args.
25034 set dummy $ac_prog; ac_word=$2
25035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25036 $as_echo_n "checking for $ac_word... " >&6; }
25037 if ${ac_cv_prog_AWK+:} false; then :
25038 $as_echo_n "(cached) " >&6
25039 else
25040 if test -n "$AWK"; then
25041 ac_cv_prog_AWK="$AWK" # Let the user override the test.
25042 else
25043 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25044 for as_dir in $PATH
25045 do
25046 IFS=$as_save_IFS
25047 test -z "$as_dir" && as_dir=.
25048 for ac_exec_ext in '' $ac_executable_extensions; do
25049 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25050 ac_cv_prog_AWK="$ac_prog"
25051 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25052 break 2
25053 fi
25054 done
25055 done
25056 IFS=$as_save_IFS
25057
25058 fi
25059 fi
25060 AWK=$ac_cv_prog_AWK
25061 if test -n "$AWK"; then
25062 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
25063 $as_echo "$AWK" >&6; }
25064 else
25065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25066 $as_echo "no" >&6; }
25067 fi
25068
25069
25070 test -n "$AWK" && break
25071 done
25072
25073 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
25074 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
25075 set x ${MAKE-make}
25076 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
25077 if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
25078 $as_echo_n "(cached) " >&6
25079 else
25080 cat >conftest.make <<\_ACEOF
25081 SHELL = /bin/sh
25082 all:
25083 @echo '@@@%%%=$(MAKE)=@@@%%%'
25084 _ACEOF
25085 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
25086 case `${MAKE-make} -f conftest.make 2>/dev/null` in
25087 *@@@%%%=?*=@@@%%%*)
25088 eval ac_cv_prog_make_${ac_make}_set=yes;;
25089 *)
25090 eval ac_cv_prog_make_${ac_make}_set=no;;
25091 esac
25092 rm -f conftest.make
25093 fi
25094 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
25095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
25096 $as_echo "yes" >&6; }
25097 SET_MAKE=
25098 else
25099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25100 $as_echo "no" >&6; }
25101 SET_MAKE="MAKE=${MAKE-make}"
25102 fi
25103
25104 rm -rf .tst 2>/dev/null
25105 mkdir .tst 2>/dev/null
25106 if test -d .tst; then
25107 am__leading_dot=.
25108 else
25109 am__leading_dot=_
25110 fi
25111 rmdir .tst 2>/dev/null
25112
25113 DEPDIR="${am__leading_dot}deps"
25114
25115 ac_config_commands="$ac_config_commands depfiles"
25116
25117
25118 am_make=${MAKE-make}
25119 cat > confinc << 'END'
25120 am__doit:
25121 @echo this is the am__doit target
25122 .PHONY: am__doit
25123 END
25124 # If we don't find an include directive, just comment out the code.
25125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
25126 $as_echo_n "checking for style of include used by $am_make... " >&6; }
25127 am__include="#"
25128 am__quote=
25129 _am_result=none
25130 # First try GNU make style include.
25131 echo "include confinc" > confmf
25132 # Ignore all kinds of additional output from 'make'.
25133 case `$am_make -s -f confmf 2> /dev/null` in #(
25134 *the\ am__doit\ target*)
25135 am__include=include
25136 am__quote=
25137 _am_result=GNU
25138 ;;
25139 esac
25140 # Now try BSD make style include.
25141 if test "$am__include" = "#"; then
25142 echo '.include "confinc"' > confmf
25143 case `$am_make -s -f confmf 2> /dev/null` in #(
25144 *the\ am__doit\ target*)
25145 am__include=.include
25146 am__quote="\""
25147 _am_result=BSD
25148 ;;
25149 esac
25150 fi
25151
25152
25153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
25154 $as_echo "$_am_result" >&6; }
25155 rm -f confinc confmf
25156
25157 # Check whether --enable-dependency-tracking was given.
25158 if test "${enable_dependency_tracking+set}" = set; then :
25159 enableval=$enable_dependency_tracking;
25160 fi
25161
25162 if test "x$enable_dependency_tracking" != xno; then
25163 am_depcomp="$ac_aux_dir/depcomp"
25164 AMDEPBACKSLASH='\'
25165 am__nodep='_no'
25166 fi
25167 if test "x$enable_dependency_tracking" != xno; then
25168 AMDEP_TRUE=
25169 AMDEP_FALSE='#'
25170 else
25171 AMDEP_TRUE='#'
25172 AMDEP_FALSE=
25173 fi
25174
25175
25176 # Check whether --enable-silent-rules was given.
25177 if test "${enable_silent_rules+set}" = set; then :
25178 enableval=$enable_silent_rules;
25179 fi
25180
25181 case $enable_silent_rules in # (((
25182 yes) AM_DEFAULT_VERBOSITY=0;;
25183 no) AM_DEFAULT_VERBOSITY=1;;
25184 *) AM_DEFAULT_VERBOSITY=1;;
25185 esac
25186 am_make=${MAKE-make}
25187 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
25188 $as_echo_n "checking whether $am_make supports nested variables... " >&6; }
25189 if ${am_cv_make_support_nested_variables+:} false; then :
25190 $as_echo_n "(cached) " >&6
25191 else
25192 if $as_echo 'TRUE=$(BAR$(V))
25193 BAR0=false
25194 BAR1=true
25195 V=1
25196 am__doit:
25197 @$(TRUE)
25198 .PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
25199 am_cv_make_support_nested_variables=yes
25200 else
25201 am_cv_make_support_nested_variables=no
25202 fi
25203 fi
25204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
25205 $as_echo "$am_cv_make_support_nested_variables" >&6; }
25206 if test $am_cv_make_support_nested_variables = yes; then
25207 AM_V='$(V)'
25208 AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
25209 else
25210 AM_V=$AM_DEFAULT_VERBOSITY
25211 AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
25212 fi
25213 AM_BACKSLASH='\'
25214
25215 if test "`cd $srcdir && pwd`" != "`pwd`"; then
25216 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
25217 # is not polluted with repeated "-I."
25218 am__isrc=' -I$(srcdir)'
25219 # test to see if srcdir already configured
25220 if test -f $srcdir/config.status; then
25221 as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
25222 fi
25223 fi
25224
25225 # test whether we have cygpath
25226 if test -z "$CYGPATH_W"; then
25227 if (cygpath --version) >/dev/null 2>/dev/null; then
25228 CYGPATH_W='cygpath -w'
25229 else
25230 CYGPATH_W=echo
25231 fi
25232 fi
25233
25234
25235 # Define the identity of the package.
25236 PACKAGE='libgnu'
25237 VERSION='UNUSED-VERSION'
25238
25239
25240 # Some tools Automake needs.
25241
25242 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
25243
25244
25245 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
25246
25247
25248 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
25249
25250
25251 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
25252
25253
25254 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
25255
25256 # For better backward compatibility. To be removed once Automake 1.9.x
25257 # dies out for good. For more background, see:
25258 # <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
25259 # <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
25260 mkdir_p='$(MKDIR_P)'
25261
25262 # We need awk for the "check" target (and possibly the TAP driver). The
25263 # system "awk" is bad on some platforms.
25264 # Always define AMTAR for backward compatibility. Yes, it's still used
25265 # in the wild :-( We should find a proper way to deprecate it ...
25266 AMTAR='$${TAR-tar}'
25267
25268
25269 # We'll loop over all known methods to create a tar archive until one works.
25270 _am_tools='gnutar pax cpio none'
25271
25272 am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
25273
25274
25275
25276
25277
25278 depcc="$CC" am_compiler_list=
25279
25280 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
25281 $as_echo_n "checking dependency style of $depcc... " >&6; }
25282 if ${am_cv_CC_dependencies_compiler_type+:} false; then :
25283 $as_echo_n "(cached) " >&6
25284 else
25285 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
25286 # We make a subdir and do the tests there. Otherwise we can end up
25287 # making bogus files that we don't know about and never remove. For
25288 # instance it was reported that on HP-UX the gcc test will end up
25289 # making a dummy file named 'D' -- because '-MD' means "put the output
25290 # in D".
25291 rm -rf conftest.dir
25292 mkdir conftest.dir
25293 # Copy depcomp to subdir because otherwise we won't find it if we're
25294 # using a relative directory.
25295 cp "$am_depcomp" conftest.dir
25296 cd conftest.dir
25297 # We will build objects and dependencies in a subdirectory because
25298 # it helps to detect inapplicable dependency modes. For instance
25299 # both Tru64's cc and ICC support -MD to output dependencies as a
25300 # side effect of compilation, but ICC will put the dependencies in
25301 # the current directory while Tru64 will put them in the object
25302 # directory.
25303 mkdir sub
25304
25305 am_cv_CC_dependencies_compiler_type=none
25306 if test "$am_compiler_list" = ""; then
25307 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
25308 fi
25309 am__universal=false
25310 case " $depcc " in #(
25311 *\ -arch\ *\ -arch\ *) am__universal=true ;;
25312 esac
25313
25314 for depmode in $am_compiler_list; do
25315 # Setup a source with many dependencies, because some compilers
25316 # like to wrap large dependency lists on column 80 (with \), and
25317 # we should not choose a depcomp mode which is confused by this.
25318 #
25319 # We need to recreate these files for each test, as the compiler may
25320 # overwrite some of them when testing with obscure command lines.
25321 # This happens at least with the AIX C compiler.
25322 : > sub/conftest.c
25323 for i in 1 2 3 4 5 6; do
25324 echo '#include "conftst'$i'.h"' >> sub/conftest.c
25325 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
25326 # Solaris 10 /bin/sh.
25327 echo '/* dummy */' > sub/conftst$i.h
25328 done
25329 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
25330
25331 # We check with '-c' and '-o' for the sake of the "dashmstdout"
25332 # mode. It turns out that the SunPro C++ compiler does not properly
25333 # handle '-M -o', and we need to detect this. Also, some Intel
25334 # versions had trouble with output in subdirs.
25335 am__obj=sub/conftest.${OBJEXT-o}
25336 am__minus_obj="-o $am__obj"
25337 case $depmode in
25338 gcc)
25339 # This depmode causes a compiler race in universal mode.
25340 test "$am__universal" = false || continue
25341 ;;
25342 nosideeffect)
25343 # After this tag, mechanisms are not by side-effect, so they'll
25344 # only be used when explicitly requested.
25345 if test "x$enable_dependency_tracking" = xyes; then
25346 continue
25347 else
25348 break
25349 fi
25350 ;;
25351 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
25352 # This compiler won't grok '-c -o', but also, the minuso test has
25353 # not run yet. These depmodes are late enough in the game, and
25354 # so weak that their functioning should not be impacted.
25355 am__obj=conftest.${OBJEXT-o}
25356 am__minus_obj=
25357 ;;
25358 none) break ;;
25359 esac
25360 if depmode=$depmode \
25361 source=sub/conftest.c object=$am__obj \
25362 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
25363 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
25364 >/dev/null 2>conftest.err &&
25365 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
25366 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
25367 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
25368 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
25369 # icc doesn't choke on unknown options, it will just issue warnings
25370 # or remarks (even with -Werror). So we grep stderr for any message
25371 # that says an option was ignored or not supported.
25372 # When given -MP, icc 7.0 and 7.1 complain thusly:
25373 # icc: Command line warning: ignoring option '-M'; no argument required
25374 # The diagnosis changed in icc 8.0:
25375 # icc: Command line remark: option '-MP' not supported
25376 if (grep 'ignoring option' conftest.err ||
25377 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
25378 am_cv_CC_dependencies_compiler_type=$depmode
25379 break
25380 fi
25381 fi
25382 done
25383
25384 cd ..
25385 rm -rf conftest.dir
25386 else
25387 am_cv_CC_dependencies_compiler_type=none
25388 fi
25389
25390 fi
25391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
25392 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
25393 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
25394
25395 if
25396 test "x$enable_dependency_tracking" != xno \
25397 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
25398 am__fastdepCC_TRUE=
25399 am__fastdepCC_FALSE='#'
25400 else
25401 am__fastdepCC_TRUE='#'
25402 am__fastdepCC_FALSE=
25403 fi
25404
25405
25406
25407 # POSIX will say in a future version that running "rm -f" with no argument
25408 # is OK; and we want to be able to make that assumption in our Makefile
25409 # recipes. So use an aggressive probe to check that the usage we want is
25410 # actually supported "in the wild" to an acceptable degree.
25411 # See automake bug#10828.
25412 # To make any issue more visible, cause the running configure to be aborted
25413 # by default if the 'rm' program in use doesn't match our expectations; the
25414 # user can still override this though.
25415 if rm -f && rm -fr && rm -rf; then : OK; else
25416 cat >&2 <<'END'
25417 Oops!
25418
25419 Your 'rm' program seems unable to run without file operands specified
25420 on the command line, even when the '-f' option is present. This is contrary
25421 to the behaviour of most rm programs out there, and not conforming with
25422 the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
25423
25424 Please tell bug-automake@gnu.org about your system, including the value
25425 of your $PATH and any error possibly output before this message. This
25426 can help us improve future automake versions.
25427
25428 END
25429 if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
25430 echo 'Configuration will proceed anyway, since you have set the' >&2
25431 echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
25432 echo >&2
25433 else
25434 cat >&2 <<'END'
25435 Aborting the configuration process, to ensure you take notice of the issue.
25436
25437 You can download and install GNU coreutils to get an 'rm' implementation
25438 that behaves properly: <http://www.gnu.org/software/coreutils/>.
25439
25440 If you want to complete the configuration process using your problematic
25441 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
25442 to "yes", and re-run configure.
25443
25444 END
25445 as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5
25446 fi
25447 fi
25448
25449
25450 # Check whether --enable-silent-rules was given.
25451 if test "${enable_silent_rules+set}" = set; then :
25452 enableval=$enable_silent_rules;
25453 fi
25454
25455 case $enable_silent_rules in # (((
25456 yes) AM_DEFAULT_VERBOSITY=0;;
25457 no) AM_DEFAULT_VERBOSITY=1;;
25458 *) AM_DEFAULT_VERBOSITY=0;;
25459 esac
25460 am_make=${MAKE-make}
25461 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
25462 $as_echo_n "checking whether $am_make supports nested variables... " >&6; }
25463 if ${am_cv_make_support_nested_variables+:} false; then :
25464 $as_echo_n "(cached) " >&6
25465 else
25466 if $as_echo 'TRUE=$(BAR$(V))
25467 BAR0=false
25468 BAR1=true
25469 V=1
25470 am__doit:
25471 @$(TRUE)
25472 .PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
25473 am_cv_make_support_nested_variables=yes
25474 else
25475 am_cv_make_support_nested_variables=no
25476 fi
25477 fi
25478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
25479 $as_echo "$am_cv_make_support_nested_variables" >&6; }
25480 if test $am_cv_make_support_nested_variables = yes; then
25481 AM_V='$(V)'
25482 AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
25483 else
25484 AM_V=$AM_DEFAULT_VERBOSITY
25485 AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
25486 fi
25487 AM_BACKSLASH='\'
25488
25489
25490 # --------------------- #
25491 # Checks for programs. #
25492 # --------------------- #
25493
25494
25495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
25496 $as_echo_n "checking whether ln -s works... " >&6; }
25497 LN_S=$as_ln_s
25498 if test "$LN_S" = "ln -s"; then
25499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
25500 $as_echo "yes" >&6; }
25501 else
25502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
25503 $as_echo "no, using $LN_S" >&6; }
25504 fi
25505
25506 if test -n "$ac_tool_prefix"; then
25507 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
25508 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
25509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25510 $as_echo_n "checking for $ac_word... " >&6; }
25511 if ${ac_cv_prog_RANLIB+:} false; then :
25512 $as_echo_n "(cached) " >&6
25513 else
25514 if test -n "$RANLIB"; then
25515 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
25516 else
25517 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25518 for as_dir in $PATH
25519 do
25520 IFS=$as_save_IFS
25521 test -z "$as_dir" && as_dir=.
25522 for ac_exec_ext in '' $ac_executable_extensions; do
25523 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25524 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
25525 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25526 break 2
25527 fi
25528 done
25529 done
25530 IFS=$as_save_IFS
25531
25532 fi
25533 fi
25534 RANLIB=$ac_cv_prog_RANLIB
25535 if test -n "$RANLIB"; then
25536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
25537 $as_echo "$RANLIB" >&6; }
25538 else
25539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25540 $as_echo "no" >&6; }
25541 fi
25542
25543
25544 fi
25545 if test -z "$ac_cv_prog_RANLIB"; then
25546 ac_ct_RANLIB=$RANLIB
25547 # Extract the first word of "ranlib", so it can be a program name with args.
25548 set dummy ranlib; ac_word=$2
25549 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25550 $as_echo_n "checking for $ac_word... " >&6; }
25551 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
25552 $as_echo_n "(cached) " >&6
25553 else
25554 if test -n "$ac_ct_RANLIB"; then
25555 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
25556 else
25557 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25558 for as_dir in $PATH
25559 do
25560 IFS=$as_save_IFS
25561 test -z "$as_dir" && as_dir=.
25562 for ac_exec_ext in '' $ac_executable_extensions; do
25563 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25564 ac_cv_prog_ac_ct_RANLIB="ranlib"
25565 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25566 break 2
25567 fi
25568 done
25569 done
25570 IFS=$as_save_IFS
25571
25572 fi
25573 fi
25574 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
25575 if test -n "$ac_ct_RANLIB"; then
25576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
25577 $as_echo "$ac_ct_RANLIB" >&6; }
25578 else
25579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25580 $as_echo "no" >&6; }
25581 fi
25582
25583 if test "x$ac_ct_RANLIB" = x; then
25584 RANLIB=":"
25585 else
25586 case $cross_compiling:$ac_tool_warned in
25587 yes:)
25588 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
25589 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
25590 ac_tool_warned=yes ;;
25591 esac
25592 RANLIB=$ac_ct_RANLIB
25593 fi
25594 else
25595 RANLIB="$ac_cv_prog_RANLIB"
25596 fi
25597
25598
25599 if test -n "$ac_tool_prefix"; then
25600 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
25601 set dummy ${ac_tool_prefix}ar; ac_word=$2
25602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25603 $as_echo_n "checking for $ac_word... " >&6; }
25604 if ${ac_cv_prog_AR+:} false; then :
25605 $as_echo_n "(cached) " >&6
25606 else
25607 if test -n "$AR"; then
25608 ac_cv_prog_AR="$AR" # Let the user override the test.
25609 else
25610 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25611 for as_dir in $PATH
25612 do
25613 IFS=$as_save_IFS
25614 test -z "$as_dir" && as_dir=.
25615 for ac_exec_ext in '' $ac_executable_extensions; do
25616 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25617 ac_cv_prog_AR="${ac_tool_prefix}ar"
25618 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25619 break 2
25620 fi
25621 done
25622 done
25623 IFS=$as_save_IFS
25624
25625 fi
25626 fi
25627 AR=$ac_cv_prog_AR
25628 if test -n "$AR"; then
25629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
25630 $as_echo "$AR" >&6; }
25631 else
25632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25633 $as_echo "no" >&6; }
25634 fi
25635
25636
25637 fi
25638 if test -z "$ac_cv_prog_AR"; then
25639 ac_ct_AR=$AR
25640 # Extract the first word of "ar", so it can be a program name with args.
25641 set dummy ar; ac_word=$2
25642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25643 $as_echo_n "checking for $ac_word... " >&6; }
25644 if ${ac_cv_prog_ac_ct_AR+:} false; then :
25645 $as_echo_n "(cached) " >&6
25646 else
25647 if test -n "$ac_ct_AR"; then
25648 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
25649 else
25650 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25651 for as_dir in $PATH
25652 do
25653 IFS=$as_save_IFS
25654 test -z "$as_dir" && as_dir=.
25655 for ac_exec_ext in '' $ac_executable_extensions; do
25656 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25657 ac_cv_prog_ac_ct_AR="ar"
25658 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25659 break 2
25660 fi
25661 done
25662 done
25663 IFS=$as_save_IFS
25664
25665 fi
25666 fi
25667 ac_ct_AR=$ac_cv_prog_ac_ct_AR
25668 if test -n "$ac_ct_AR"; then
25669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
25670 $as_echo "$ac_ct_AR" >&6; }
25671 else
25672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25673 $as_echo "no" >&6; }
25674 fi
25675
25676 if test "x$ac_ct_AR" = x; then
25677 AR=""
25678 else
25679 case $cross_compiling:$ac_tool_warned in
25680 yes:)
25681 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
25682 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
25683 ac_tool_warned=yes ;;
25684 esac
25685 AR=$ac_ct_AR
25686 fi
25687 else
25688 AR="$ac_cv_prog_AR"
25689 fi
25690
25691
25692 # ---------------------- #
25693 # Checks for libraries. #
25694 # ---------------------- #
25695
25696 ac_config_files="$ac_config_files Makefile import/Makefile"
25697
25698 ac_config_commands="$ac_config_commands default"
25699
25700 cat >confcache <<\_ACEOF
25701 # This file is a shell script that caches the results of configure
25702 # tests run on this system so they can be shared between configure
25703 # scripts and configure runs, see configure's option --config-cache.
25704 # It is not useful on other systems. If it contains results you don't
25705 # want to keep, you may remove or edit it.
25706 #
25707 # config.status only pays attention to the cache file if you give it
25708 # the --recheck option to rerun configure.
25709 #
25710 # `ac_cv_env_foo' variables (set or unset) will be overridden when
25711 # loading this file, other *unset* `ac_cv_foo' will be assigned the
25712 # following values.
25713
25714 _ACEOF
25715
25716 # The following way of writing the cache mishandles newlines in values,
25717 # but we know of no workaround that is simple, portable, and efficient.
25718 # So, we kill variables containing newlines.
25719 # Ultrix sh set writes to stderr and can't be redirected directly,
25720 # and sets the high bit in the cache file unless we assign to the vars.
25721 (
25722 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
25723 eval ac_val=\$$ac_var
25724 case $ac_val in #(
25725 *${as_nl}*)
25726 case $ac_var in #(
25727 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
25728 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
25729 esac
25730 case $ac_var in #(
25731 _ | IFS | as_nl) ;; #(
25732 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
25733 *) { eval $ac_var=; unset $ac_var;} ;;
25734 esac ;;
25735 esac
25736 done
25737
25738 (set) 2>&1 |
25739 case $as_nl`(ac_space=' '; set) 2>&1` in #(
25740 *${as_nl}ac_space=\ *)
25741 # `set' does not quote correctly, so add quotes: double-quote
25742 # substitution turns \\\\ into \\, and sed turns \\ into \.
25743 sed -n \
25744 "s/'/'\\\\''/g;
25745 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
25746 ;; #(
25747 *)
25748 # `set' quotes correctly as required by POSIX, so do not add quotes.
25749 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
25750 ;;
25751 esac |
25752 sort
25753 ) |
25754 sed '
25755 /^ac_cv_env_/b end
25756 t clear
25757 :clear
25758 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
25759 t end
25760 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
25761 :end' >>confcache
25762 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
25763 if test -w "$cache_file"; then
25764 if test "x$cache_file" != "x/dev/null"; then
25765 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
25766 $as_echo "$as_me: updating cache $cache_file" >&6;}
25767 if test ! -f "$cache_file" || test -h "$cache_file"; then
25768 cat confcache >"$cache_file"
25769 else
25770 case $cache_file in #(
25771 */* | ?:*)
25772 mv -f confcache "$cache_file"$$ &&
25773 mv -f "$cache_file"$$ "$cache_file" ;; #(
25774 *)
25775 mv -f confcache "$cache_file" ;;
25776 esac
25777 fi
25778 fi
25779 else
25780 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
25781 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
25782 fi
25783 fi
25784 rm -f confcache
25785
25786 test "x$prefix" = xNONE && prefix=$ac_default_prefix
25787 # Let make expand exec_prefix.
25788 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
25789
25790 DEFS=-DHAVE_CONFIG_H
25791
25792 ac_libobjs=
25793 ac_ltlibobjs=
25794 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
25795 # 1. Remove the extension, and $U if already installed.
25796 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
25797 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
25798 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
25799 # will be set to the directory where LIBOBJS objects are built.
25800 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
25801 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
25802 done
25803 LIBOBJS=$ac_libobjs
25804
25805 LTLIBOBJS=$ac_ltlibobjs
25806
25807
25808 if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
25809 as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
25810 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25811 fi
25812 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
25813 as_fn_error $? "conditional \"GL_COND_LIBTOOL\" was never defined.
25814 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25815 fi
25816 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
25817 as_fn_error $? "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
25818 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25819 fi
25820 if test -z "${GL_GENERATE_ERRNO_H_TRUE}" && test -z "${GL_GENERATE_ERRNO_H_FALSE}"; then
25821 as_fn_error $? "conditional \"GL_GENERATE_ERRNO_H\" was never defined.
25822 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25823 fi
25824 if test -z "${GL_GENERATE_FLOAT_H_TRUE}" && test -z "${GL_GENERATE_FLOAT_H_FALSE}"; then
25825 as_fn_error $? "conditional \"GL_GENERATE_FLOAT_H\" was never defined.
25826 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25827 fi
25828 if test -z "${GL_GENERATE_FNMATCH_H_TRUE}" && test -z "${GL_GENERATE_FNMATCH_H_FALSE}"; then
25829 as_fn_error $? "conditional \"GL_GENERATE_FNMATCH_H\" was never defined.
25830 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25831 fi
25832 if test -z "${GL_GENERATE_GLOB_H_TRUE}" && test -z "${GL_GENERATE_GLOB_H_FALSE}"; then
25833 as_fn_error $? "conditional \"GL_GENERATE_GLOB_H\" was never defined.
25834 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25835 fi
25836 if test -z "${GL_GENERATE_LIMITS_H_TRUE}" && test -z "${GL_GENERATE_LIMITS_H_FALSE}"; then
25837 as_fn_error $? "conditional \"GL_GENERATE_LIMITS_H\" was never defined.
25838 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25839 fi
25840 if test -z "${GL_GENERATE_LIMITS_H_TRUE}" && test -z "${GL_GENERATE_LIMITS_H_FALSE}"; then
25841 as_fn_error $? "conditional \"GL_GENERATE_LIMITS_H\" was never defined.
25842 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25843 fi
25844 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
25845 as_fn_error $? "conditional \"GL_GENERATE_STDINT_H\" was never defined.
25846 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25847 fi
25848
25849
25850 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
25851 as_fn_error $? "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
25852 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25853 fi
25854 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
25855 as_fn_error $? "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
25856 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25857 fi
25858
25859 gl_libobjs=
25860 gl_ltlibobjs=
25861 if test -n "$gl_LIBOBJS"; then
25862 # Remove the extension.
25863 sed_drop_objext='s/\.o$//;s/\.obj$//'
25864 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
25865 gl_libobjs="$gl_libobjs $i.$ac_objext"
25866 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
25867 done
25868 fi
25869 gl_LIBOBJS=$gl_libobjs
25870
25871 gl_LTLIBOBJS=$gl_ltlibobjs
25872
25873
25874
25875 gltests_libobjs=
25876 gltests_ltlibobjs=
25877 if test -n "$gltests_LIBOBJS"; then
25878 # Remove the extension.
25879 sed_drop_objext='s/\.o$//;s/\.obj$//'
25880 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
25881 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
25882 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
25883 done
25884 fi
25885 gltests_LIBOBJS=$gltests_libobjs
25886
25887 gltests_LTLIBOBJS=$gltests_ltlibobjs
25888
25889
25890 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
25891 $as_echo_n "checking that generated files are newer than configure... " >&6; }
25892 if test -n "$am_sleep_pid"; then
25893 # Hide warnings about reused PIDs.
25894 wait $am_sleep_pid 2>/dev/null
25895 fi
25896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
25897 $as_echo "done" >&6; }
25898 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
25899 as_fn_error $? "conditional \"AMDEP\" was never defined.
25900 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25901 fi
25902 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
25903 as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
25904 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25905 fi
25906 if test -n "$EXEEXT"; then
25907 am__EXEEXT_TRUE=
25908 am__EXEEXT_FALSE='#'
25909 else
25910 am__EXEEXT_TRUE='#'
25911 am__EXEEXT_FALSE=
25912 fi
25913
25914
25915 : "${CONFIG_STATUS=./config.status}"
25916 ac_write_fail=0
25917 ac_clean_files_save=$ac_clean_files
25918 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
25919 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
25920 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
25921 as_write_fail=0
25922 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
25923 #! $SHELL
25924 # Generated by $as_me.
25925 # Run this file to recreate the current configuration.
25926 # Compiler output produced by configure, useful for debugging
25927 # configure, is in config.log if it exists.
25928
25929 debug=false
25930 ac_cs_recheck=false
25931 ac_cs_silent=false
25932
25933 SHELL=\${CONFIG_SHELL-$SHELL}
25934 export SHELL
25935 _ASEOF
25936 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
25937 ## -------------------- ##
25938 ## M4sh Initialization. ##
25939 ## -------------------- ##
25940
25941 # Be more Bourne compatible
25942 DUALCASE=1; export DUALCASE # for MKS sh
25943 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
25944 emulate sh
25945 NULLCMD=:
25946 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
25947 # is contrary to our usage. Disable this feature.
25948 alias -g '${1+"$@"}'='"$@"'
25949 setopt NO_GLOB_SUBST
25950 else
25951 case `(set -o) 2>/dev/null` in #(
25952 *posix*) :
25953 set -o posix ;; #(
25954 *) :
25955 ;;
25956 esac
25957 fi
25958
25959
25960 as_nl='
25961 '
25962 export as_nl
25963 # Printing a long string crashes Solaris 7 /usr/bin/printf.
25964 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
25965 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
25966 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
25967 # Prefer a ksh shell builtin over an external printf program on Solaris,
25968 # but without wasting forks for bash or zsh.
25969 if test -z "$BASH_VERSION$ZSH_VERSION" \
25970 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
25971 as_echo='print -r --'
25972 as_echo_n='print -rn --'
25973 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
25974 as_echo='printf %s\n'
25975 as_echo_n='printf %s'
25976 else
25977 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
25978 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
25979 as_echo_n='/usr/ucb/echo -n'
25980 else
25981 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
25982 as_echo_n_body='eval
25983 arg=$1;
25984 case $arg in #(
25985 *"$as_nl"*)
25986 expr "X$arg" : "X\\(.*\\)$as_nl";
25987 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
25988 esac;
25989 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
25990 '
25991 export as_echo_n_body
25992 as_echo_n='sh -c $as_echo_n_body as_echo'
25993 fi
25994 export as_echo_body
25995 as_echo='sh -c $as_echo_body as_echo'
25996 fi
25997
25998 # The user is always right.
25999 if test "${PATH_SEPARATOR+set}" != set; then
26000 PATH_SEPARATOR=:
26001 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
26002 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
26003 PATH_SEPARATOR=';'
26004 }
26005 fi
26006
26007
26008 # IFS
26009 # We need space, tab and new line, in precisely that order. Quoting is
26010 # there to prevent editors from complaining about space-tab.
26011 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
26012 # splitting by setting IFS to empty value.)
26013 IFS=" "" $as_nl"
26014
26015 # Find who we are. Look in the path if we contain no directory separator.
26016 as_myself=
26017 case $0 in #((
26018 *[\\/]* ) as_myself=$0 ;;
26019 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26020 for as_dir in $PATH
26021 do
26022 IFS=$as_save_IFS
26023 test -z "$as_dir" && as_dir=.
26024 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
26025 done
26026 IFS=$as_save_IFS
26027
26028 ;;
26029 esac
26030 # We did not find ourselves, most probably we were run as `sh COMMAND'
26031 # in which case we are not to be found in the path.
26032 if test "x$as_myself" = x; then
26033 as_myself=$0
26034 fi
26035 if test ! -f "$as_myself"; then
26036 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
26037 exit 1
26038 fi
26039
26040 # Unset variables that we do not need and which cause bugs (e.g. in
26041 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
26042 # suppresses any "Segmentation fault" message there. '((' could
26043 # trigger a bug in pdksh 5.2.14.
26044 for as_var in BASH_ENV ENV MAIL MAILPATH
26045 do eval test x\${$as_var+set} = xset \
26046 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
26047 done
26048 PS1='$ '
26049 PS2='> '
26050 PS4='+ '
26051
26052 # NLS nuisances.
26053 LC_ALL=C
26054 export LC_ALL
26055 LANGUAGE=C
26056 export LANGUAGE
26057
26058 # CDPATH.
26059 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
26060
26061
26062 # as_fn_error STATUS ERROR [LINENO LOG_FD]
26063 # ----------------------------------------
26064 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
26065 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
26066 # script with STATUS, using 1 if that was 0.
26067 as_fn_error ()
26068 {
26069 as_status=$1; test $as_status -eq 0 && as_status=1
26070 if test "$4"; then
26071 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
26072 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
26073 fi
26074 $as_echo "$as_me: error: $2" >&2
26075 as_fn_exit $as_status
26076 } # as_fn_error
26077
26078
26079 # as_fn_set_status STATUS
26080 # -----------------------
26081 # Set $? to STATUS, without forking.
26082 as_fn_set_status ()
26083 {
26084 return $1
26085 } # as_fn_set_status
26086
26087 # as_fn_exit STATUS
26088 # -----------------
26089 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
26090 as_fn_exit ()
26091 {
26092 set +e
26093 as_fn_set_status $1
26094 exit $1
26095 } # as_fn_exit
26096
26097 # as_fn_unset VAR
26098 # ---------------
26099 # Portably unset VAR.
26100 as_fn_unset ()
26101 {
26102 { eval $1=; unset $1;}
26103 }
26104 as_unset=as_fn_unset
26105 # as_fn_append VAR VALUE
26106 # ----------------------
26107 # Append the text in VALUE to the end of the definition contained in VAR. Take
26108 # advantage of any shell optimizations that allow amortized linear growth over
26109 # repeated appends, instead of the typical quadratic growth present in naive
26110 # implementations.
26111 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
26112 eval 'as_fn_append ()
26113 {
26114 eval $1+=\$2
26115 }'
26116 else
26117 as_fn_append ()
26118 {
26119 eval $1=\$$1\$2
26120 }
26121 fi # as_fn_append
26122
26123 # as_fn_arith ARG...
26124 # ------------------
26125 # Perform arithmetic evaluation on the ARGs, and store the result in the
26126 # global $as_val. Take advantage of shells that can avoid forks. The arguments
26127 # must be portable across $(()) and expr.
26128 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
26129 eval 'as_fn_arith ()
26130 {
26131 as_val=$(( $* ))
26132 }'
26133 else
26134 as_fn_arith ()
26135 {
26136 as_val=`expr "$@" || test $? -eq 1`
26137 }
26138 fi # as_fn_arith
26139
26140
26141 if expr a : '\(a\)' >/dev/null 2>&1 &&
26142 test "X`expr 00001 : '.*\(...\)'`" = X001; then
26143 as_expr=expr
26144 else
26145 as_expr=false
26146 fi
26147
26148 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
26149 as_basename=basename
26150 else
26151 as_basename=false
26152 fi
26153
26154 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
26155 as_dirname=dirname
26156 else
26157 as_dirname=false
26158 fi
26159
26160 as_me=`$as_basename -- "$0" ||
26161 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
26162 X"$0" : 'X\(//\)$' \| \
26163 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
26164 $as_echo X/"$0" |
26165 sed '/^.*\/\([^/][^/]*\)\/*$/{
26166 s//\1/
26167 q
26168 }
26169 /^X\/\(\/\/\)$/{
26170 s//\1/
26171 q
26172 }
26173 /^X\/\(\/\).*/{
26174 s//\1/
26175 q
26176 }
26177 s/.*/./; q'`
26178
26179 # Avoid depending upon Character Ranges.
26180 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
26181 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
26182 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
26183 as_cr_digits='0123456789'
26184 as_cr_alnum=$as_cr_Letters$as_cr_digits
26185
26186 ECHO_C= ECHO_N= ECHO_T=
26187 case `echo -n x` in #(((((
26188 -n*)
26189 case `echo 'xy\c'` in
26190 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
26191 xy) ECHO_C='\c';;
26192 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
26193 ECHO_T=' ';;
26194 esac;;
26195 *)
26196 ECHO_N='-n';;
26197 esac
26198
26199 rm -f conf$$ conf$$.exe conf$$.file
26200 if test -d conf$$.dir; then
26201 rm -f conf$$.dir/conf$$.file
26202 else
26203 rm -f conf$$.dir
26204 mkdir conf$$.dir 2>/dev/null
26205 fi
26206 if (echo >conf$$.file) 2>/dev/null; then
26207 if ln -s conf$$.file conf$$ 2>/dev/null; then
26208 as_ln_s='ln -s'
26209 # ... but there are two gotchas:
26210 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
26211 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
26212 # In both cases, we have to default to `cp -pR'.
26213 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
26214 as_ln_s='cp -pR'
26215 elif ln conf$$.file conf$$ 2>/dev/null; then
26216 as_ln_s=ln
26217 else
26218 as_ln_s='cp -pR'
26219 fi
26220 else
26221 as_ln_s='cp -pR'
26222 fi
26223 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
26224 rmdir conf$$.dir 2>/dev/null
26225
26226
26227 # as_fn_mkdir_p
26228 # -------------
26229 # Create "$as_dir" as a directory, including parents if necessary.
26230 as_fn_mkdir_p ()
26231 {
26232
26233 case $as_dir in #(
26234 -*) as_dir=./$as_dir;;
26235 esac
26236 test -d "$as_dir" || eval $as_mkdir_p || {
26237 as_dirs=
26238 while :; do
26239 case $as_dir in #(
26240 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
26241 *) as_qdir=$as_dir;;
26242 esac
26243 as_dirs="'$as_qdir' $as_dirs"
26244 as_dir=`$as_dirname -- "$as_dir" ||
26245 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26246 X"$as_dir" : 'X\(//\)[^/]' \| \
26247 X"$as_dir" : 'X\(//\)$' \| \
26248 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
26249 $as_echo X"$as_dir" |
26250 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
26251 s//\1/
26252 q
26253 }
26254 /^X\(\/\/\)[^/].*/{
26255 s//\1/
26256 q
26257 }
26258 /^X\(\/\/\)$/{
26259 s//\1/
26260 q
26261 }
26262 /^X\(\/\).*/{
26263 s//\1/
26264 q
26265 }
26266 s/.*/./; q'`
26267 test -d "$as_dir" && break
26268 done
26269 test -z "$as_dirs" || eval "mkdir $as_dirs"
26270 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
26271
26272
26273 } # as_fn_mkdir_p
26274 if mkdir -p . 2>/dev/null; then
26275 as_mkdir_p='mkdir -p "$as_dir"'
26276 else
26277 test -d ./-p && rmdir ./-p
26278 as_mkdir_p=false
26279 fi
26280
26281
26282 # as_fn_executable_p FILE
26283 # -----------------------
26284 # Test if FILE is an executable regular file.
26285 as_fn_executable_p ()
26286 {
26287 test -f "$1" && test -x "$1"
26288 } # as_fn_executable_p
26289 as_test_x='test -x'
26290 as_executable_p=as_fn_executable_p
26291
26292 # Sed expression to map a string onto a valid CPP name.
26293 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
26294
26295 # Sed expression to map a string onto a valid variable name.
26296 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
26297
26298
26299 exec 6>&1
26300 ## ----------------------------------- ##
26301 ## Main body of $CONFIG_STATUS script. ##
26302 ## ----------------------------------- ##
26303 _ASEOF
26304 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
26305
26306 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26307 # Save the log message, to keep $0 and so on meaningful, and to
26308 # report actual input values of CONFIG_FILES etc. instead of their
26309 # values after options handling.
26310 ac_log="
26311 This file was extended by libgnu $as_me UNUSED-VERSION, which was
26312 generated by GNU Autoconf 2.69. Invocation command line was
26313
26314 CONFIG_FILES = $CONFIG_FILES
26315 CONFIG_HEADERS = $CONFIG_HEADERS
26316 CONFIG_LINKS = $CONFIG_LINKS
26317 CONFIG_COMMANDS = $CONFIG_COMMANDS
26318 $ $0 $@
26319
26320 on `(hostname || uname -n) 2>/dev/null | sed 1q`
26321 "
26322
26323 _ACEOF
26324
26325 case $ac_config_files in *"
26326 "*) set x $ac_config_files; shift; ac_config_files=$*;;
26327 esac
26328
26329 case $ac_config_headers in *"
26330 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
26331 esac
26332
26333
26334 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26335 # Files that config.status was made for.
26336 config_files="$ac_config_files"
26337 config_headers="$ac_config_headers"
26338 config_commands="$ac_config_commands"
26339
26340 _ACEOF
26341
26342 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26343 ac_cs_usage="\
26344 \`$as_me' instantiates files and other configuration actions
26345 from templates according to the current configuration. Unless the files
26346 and actions are specified as TAGs, all are instantiated by default.
26347
26348 Usage: $0 [OPTION]... [TAG]...
26349
26350 -h, --help print this help, then exit
26351 -V, --version print version number and configuration settings, then exit
26352 --config print configuration, then exit
26353 -q, --quiet, --silent
26354 do not print progress messages
26355 -d, --debug don't remove temporary files
26356 --recheck update $as_me by reconfiguring in the same conditions
26357 --file=FILE[:TEMPLATE]
26358 instantiate the configuration file FILE
26359 --header=FILE[:TEMPLATE]
26360 instantiate the configuration header FILE
26361
26362 Configuration files:
26363 $config_files
26364
26365 Configuration headers:
26366 $config_headers
26367
26368 Configuration commands:
26369 $config_commands
26370
26371 Report bugs to the package provider."
26372
26373 _ACEOF
26374 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26375 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
26376 ac_cs_version="\\
26377 libgnu config.status UNUSED-VERSION
26378 configured by $0, generated by GNU Autoconf 2.69,
26379 with options \\"\$ac_cs_config\\"
26380
26381 Copyright (C) 2012 Free Software Foundation, Inc.
26382 This config.status script is free software; the Free Software Foundation
26383 gives unlimited permission to copy, distribute and modify it."
26384
26385 ac_pwd='$ac_pwd'
26386 srcdir='$srcdir'
26387 INSTALL='$INSTALL'
26388 MKDIR_P='$MKDIR_P'
26389 AWK='$AWK'
26390 test -n "\$AWK" || AWK=awk
26391 _ACEOF
26392
26393 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26394 # The default lists apply if the user does not specify any file.
26395 ac_need_defaults=:
26396 while test $# != 0
26397 do
26398 case $1 in
26399 --*=?*)
26400 ac_option=`expr "X$1" : 'X\([^=]*\)='`
26401 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
26402 ac_shift=:
26403 ;;
26404 --*=)
26405 ac_option=`expr "X$1" : 'X\([^=]*\)='`
26406 ac_optarg=
26407 ac_shift=:
26408 ;;
26409 *)
26410 ac_option=$1
26411 ac_optarg=$2
26412 ac_shift=shift
26413 ;;
26414 esac
26415
26416 case $ac_option in
26417 # Handling of the options.
26418 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
26419 ac_cs_recheck=: ;;
26420 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
26421 $as_echo "$ac_cs_version"; exit ;;
26422 --config | --confi | --conf | --con | --co | --c )
26423 $as_echo "$ac_cs_config"; exit ;;
26424 --debug | --debu | --deb | --de | --d | -d )
26425 debug=: ;;
26426 --file | --fil | --fi | --f )
26427 $ac_shift
26428 case $ac_optarg in
26429 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
26430 '') as_fn_error $? "missing file argument" ;;
26431 esac
26432 as_fn_append CONFIG_FILES " '$ac_optarg'"
26433 ac_need_defaults=false;;
26434 --header | --heade | --head | --hea )
26435 $ac_shift
26436 case $ac_optarg in
26437 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
26438 esac
26439 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
26440 ac_need_defaults=false;;
26441 --he | --h)
26442 # Conflict between --help and --header
26443 as_fn_error $? "ambiguous option: \`$1'
26444 Try \`$0 --help' for more information.";;
26445 --help | --hel | -h )
26446 $as_echo "$ac_cs_usage"; exit ;;
26447 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
26448 | -silent | --silent | --silen | --sile | --sil | --si | --s)
26449 ac_cs_silent=: ;;
26450
26451 # This is an error.
26452 -*) as_fn_error $? "unrecognized option: \`$1'
26453 Try \`$0 --help' for more information." ;;
26454
26455 *) as_fn_append ac_config_targets " $1"
26456 ac_need_defaults=false ;;
26457
26458 esac
26459 shift
26460 done
26461
26462 ac_configure_extra_args=
26463
26464 if $ac_cs_silent; then
26465 exec 6>/dev/null
26466 ac_configure_extra_args="$ac_configure_extra_args --silent"
26467 fi
26468
26469 _ACEOF
26470 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26471 if \$ac_cs_recheck; then
26472 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
26473 shift
26474 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
26475 CONFIG_SHELL='$SHELL'
26476 export CONFIG_SHELL
26477 exec "\$@"
26478 fi
26479
26480 _ACEOF
26481 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26482 exec 5>>config.log
26483 {
26484 echo
26485 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
26486 ## Running $as_me. ##
26487 _ASBOX
26488 $as_echo "$ac_log"
26489 } >&5
26490
26491 _ACEOF
26492 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26493 #
26494 # INIT-COMMANDS
26495 #
26496 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
26497
26498 _ACEOF
26499
26500 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26501
26502 # Handling of arguments.
26503 for ac_config_target in $ac_config_targets
26504 do
26505 case $ac_config_target in
26506 "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
26507 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
26508 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
26509 "import/Makefile") CONFIG_FILES="$CONFIG_FILES import/Makefile" ;;
26510 "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
26511
26512 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
26513 esac
26514 done
26515
26516
26517 # If the user did not use the arguments to specify the items to instantiate,
26518 # then the envvar interface is used. Set only those that are not.
26519 # We use the long form for the default assignment because of an extremely
26520 # bizarre bug on SunOS 4.1.3.
26521 if $ac_need_defaults; then
26522 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
26523 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
26524 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
26525 fi
26526
26527 # Have a temporary directory for convenience. Make it in the build tree
26528 # simply because there is no reason against having it here, and in addition,
26529 # creating and moving files from /tmp can sometimes cause problems.
26530 # Hook for its removal unless debugging.
26531 # Note that there is a small window in which the directory will not be cleaned:
26532 # after its creation but before its name has been assigned to `$tmp'.
26533 $debug ||
26534 {
26535 tmp= ac_tmp=
26536 trap 'exit_status=$?
26537 : "${ac_tmp:=$tmp}"
26538 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
26539 ' 0
26540 trap 'as_fn_exit 1' 1 2 13 15
26541 }
26542 # Create a (secure) tmp directory for tmp files.
26543
26544 {
26545 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
26546 test -d "$tmp"
26547 } ||
26548 {
26549 tmp=./conf$$-$RANDOM
26550 (umask 077 && mkdir "$tmp")
26551 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
26552 ac_tmp=$tmp
26553
26554 # Set up the scripts for CONFIG_FILES section.
26555 # No need to generate them if there are no CONFIG_FILES.
26556 # This happens for instance with `./config.status config.h'.
26557 if test -n "$CONFIG_FILES"; then
26558
26559
26560 ac_cr=`echo X | tr X '\015'`
26561 # On cygwin, bash can eat \r inside `` if the user requested igncr.
26562 # But we know of no other shell where ac_cr would be empty at this
26563 # point, so we can use a bashism as a fallback.
26564 if test "x$ac_cr" = x; then
26565 eval ac_cr=\$\'\\r\'
26566 fi
26567 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
26568 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
26569 ac_cs_awk_cr='\\r'
26570 else
26571 ac_cs_awk_cr=$ac_cr
26572 fi
26573
26574 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
26575 _ACEOF
26576
26577
26578 {
26579 echo "cat >conf$$subs.awk <<_ACEOF" &&
26580 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
26581 echo "_ACEOF"
26582 } >conf$$subs.sh ||
26583 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
26584 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
26585 ac_delim='%!_!# '
26586 for ac_last_try in false false false false false :; do
26587 . ./conf$$subs.sh ||
26588 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
26589
26590 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
26591 if test $ac_delim_n = $ac_delim_num; then
26592 break
26593 elif $ac_last_try; then
26594 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
26595 else
26596 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
26597 fi
26598 done
26599 rm -f conf$$subs.sh
26600
26601 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26602 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
26603 _ACEOF
26604 sed -n '
26605 h
26606 s/^/S["/; s/!.*/"]=/
26607 p
26608 g
26609 s/^[^!]*!//
26610 :repl
26611 t repl
26612 s/'"$ac_delim"'$//
26613 t delim
26614 :nl
26615 h
26616 s/\(.\{148\}\)..*/\1/
26617 t more1
26618 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
26619 p
26620 n
26621 b repl
26622 :more1
26623 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
26624 p
26625 g
26626 s/.\{148\}//
26627 t nl
26628 :delim
26629 h
26630 s/\(.\{148\}\)..*/\1/
26631 t more2
26632 s/["\\]/\\&/g; s/^/"/; s/$/"/
26633 p
26634 b
26635 :more2
26636 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
26637 p
26638 g
26639 s/.\{148\}//
26640 t delim
26641 ' <conf$$subs.awk | sed '
26642 /^[^""]/{
26643 N
26644 s/\n//
26645 }
26646 ' >>$CONFIG_STATUS || ac_write_fail=1
26647 rm -f conf$$subs.awk
26648 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26649 _ACAWK
26650 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
26651 for (key in S) S_is_set[key] = 1
26652 FS = "\a"
26653
26654 }
26655 {
26656 line = $ 0
26657 nfields = split(line, field, "@")
26658 substed = 0
26659 len = length(field[1])
26660 for (i = 2; i < nfields; i++) {
26661 key = field[i]
26662 keylen = length(key)
26663 if (S_is_set[key]) {
26664 value = S[key]
26665 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
26666 len += length(value) + length(field[++i])
26667 substed = 1
26668 } else
26669 len += 1 + keylen
26670 }
26671
26672 print line
26673 }
26674
26675 _ACAWK
26676 _ACEOF
26677 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26678 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
26679 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
26680 else
26681 cat
26682 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
26683 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
26684 _ACEOF
26685
26686 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
26687 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
26688 # trailing colons and then remove the whole line if VPATH becomes empty
26689 # (actually we leave an empty line to preserve line numbers).
26690 if test "x$srcdir" = x.; then
26691 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
26692 h
26693 s///
26694 s/^/:/
26695 s/[ ]*$/:/
26696 s/:\$(srcdir):/:/g
26697 s/:\${srcdir}:/:/g
26698 s/:@srcdir@:/:/g
26699 s/^:*//
26700 s/:*$//
26701 x
26702 s/\(=[ ]*\).*/\1/
26703 G
26704 s/\n//
26705 s/^[^=]*=[ ]*$//
26706 }'
26707 fi
26708
26709 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26710 fi # test -n "$CONFIG_FILES"
26711
26712 # Set up the scripts for CONFIG_HEADERS section.
26713 # No need to generate them if there are no CONFIG_HEADERS.
26714 # This happens for instance with `./config.status Makefile'.
26715 if test -n "$CONFIG_HEADERS"; then
26716 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
26717 BEGIN {
26718 _ACEOF
26719
26720 # Transform confdefs.h into an awk script `defines.awk', embedded as
26721 # here-document in config.status, that substitutes the proper values into
26722 # config.h.in to produce config.h.
26723
26724 # Create a delimiter string that does not exist in confdefs.h, to ease
26725 # handling of long lines.
26726 ac_delim='%!_!# '
26727 for ac_last_try in false false :; do
26728 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
26729 if test -z "$ac_tt"; then
26730 break
26731 elif $ac_last_try; then
26732 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
26733 else
26734 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
26735 fi
26736 done
26737
26738 # For the awk script, D is an array of macro values keyed by name,
26739 # likewise P contains macro parameters if any. Preserve backslash
26740 # newline sequences.
26741
26742 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
26743 sed -n '
26744 s/.\{148\}/&'"$ac_delim"'/g
26745 t rset
26746 :rset
26747 s/^[ ]*#[ ]*define[ ][ ]*/ /
26748 t def
26749 d
26750 :def
26751 s/\\$//
26752 t bsnl
26753 s/["\\]/\\&/g
26754 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
26755 D["\1"]=" \3"/p
26756 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
26757 d
26758 :bsnl
26759 s/["\\]/\\&/g
26760 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
26761 D["\1"]=" \3\\\\\\n"\\/p
26762 t cont
26763 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
26764 t cont
26765 d
26766 :cont
26767 n
26768 s/.\{148\}/&'"$ac_delim"'/g
26769 t clear
26770 :clear
26771 s/\\$//
26772 t bsnlc
26773 s/["\\]/\\&/g; s/^/"/; s/$/"/p
26774 d
26775 :bsnlc
26776 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
26777 b cont
26778 ' <confdefs.h | sed '
26779 s/'"$ac_delim"'/"\\\
26780 "/g' >>$CONFIG_STATUS || ac_write_fail=1
26781
26782 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26783 for (key in D) D_is_set[key] = 1
26784 FS = "\a"
26785 }
26786 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
26787 line = \$ 0
26788 split(line, arg, " ")
26789 if (arg[1] == "#") {
26790 defundef = arg[2]
26791 mac1 = arg[3]
26792 } else {
26793 defundef = substr(arg[1], 2)
26794 mac1 = arg[2]
26795 }
26796 split(mac1, mac2, "(") #)
26797 macro = mac2[1]
26798 prefix = substr(line, 1, index(line, defundef) - 1)
26799 if (D_is_set[macro]) {
26800 # Preserve the white space surrounding the "#".
26801 print prefix "define", macro P[macro] D[macro]
26802 next
26803 } else {
26804 # Replace #undef with comments. This is necessary, for example,
26805 # in the case of _POSIX_SOURCE, which is predefined and required
26806 # on some systems where configure will not decide to define it.
26807 if (defundef == "undef") {
26808 print "/*", prefix defundef, macro, "*/"
26809 next
26810 }
26811 }
26812 }
26813 { print }
26814 _ACAWK
26815 _ACEOF
26816 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26817 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
26818 fi # test -n "$CONFIG_HEADERS"
26819
26820
26821 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
26822 shift
26823 for ac_tag
26824 do
26825 case $ac_tag in
26826 :[FHLC]) ac_mode=$ac_tag; continue;;
26827 esac
26828 case $ac_mode$ac_tag in
26829 :[FHL]*:*);;
26830 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
26831 :[FH]-) ac_tag=-:-;;
26832 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
26833 esac
26834 ac_save_IFS=$IFS
26835 IFS=:
26836 set x $ac_tag
26837 IFS=$ac_save_IFS
26838 shift
26839 ac_file=$1
26840 shift
26841
26842 case $ac_mode in
26843 :L) ac_source=$1;;
26844 :[FH])
26845 ac_file_inputs=
26846 for ac_f
26847 do
26848 case $ac_f in
26849 -) ac_f="$ac_tmp/stdin";;
26850 *) # Look for the file first in the build tree, then in the source tree
26851 # (if the path is not absolute). The absolute path cannot be DOS-style,
26852 # because $ac_f cannot contain `:'.
26853 test -f "$ac_f" ||
26854 case $ac_f in
26855 [\\/$]*) false;;
26856 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
26857 esac ||
26858 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
26859 esac
26860 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
26861 as_fn_append ac_file_inputs " '$ac_f'"
26862 done
26863
26864 # Let's still pretend it is `configure' which instantiates (i.e., don't
26865 # use $as_me), people would be surprised to read:
26866 # /* config.h. Generated by config.status. */
26867 configure_input='Generated from '`
26868 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
26869 `' by configure.'
26870 if test x"$ac_file" != x-; then
26871 configure_input="$ac_file. $configure_input"
26872 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
26873 $as_echo "$as_me: creating $ac_file" >&6;}
26874 fi
26875 # Neutralize special characters interpreted by sed in replacement strings.
26876 case $configure_input in #(
26877 *\&* | *\|* | *\\* )
26878 ac_sed_conf_input=`$as_echo "$configure_input" |
26879 sed 's/[\\\\&|]/\\\\&/g'`;; #(
26880 *) ac_sed_conf_input=$configure_input;;
26881 esac
26882
26883 case $ac_tag in
26884 *:-:* | *:-) cat >"$ac_tmp/stdin" \
26885 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
26886 esac
26887 ;;
26888 esac
26889
26890 ac_dir=`$as_dirname -- "$ac_file" ||
26891 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26892 X"$ac_file" : 'X\(//\)[^/]' \| \
26893 X"$ac_file" : 'X\(//\)$' \| \
26894 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
26895 $as_echo X"$ac_file" |
26896 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
26897 s//\1/
26898 q
26899 }
26900 /^X\(\/\/\)[^/].*/{
26901 s//\1/
26902 q
26903 }
26904 /^X\(\/\/\)$/{
26905 s//\1/
26906 q
26907 }
26908 /^X\(\/\).*/{
26909 s//\1/
26910 q
26911 }
26912 s/.*/./; q'`
26913 as_dir="$ac_dir"; as_fn_mkdir_p
26914 ac_builddir=.
26915
26916 case "$ac_dir" in
26917 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
26918 *)
26919 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
26920 # A ".." for each directory in $ac_dir_suffix.
26921 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
26922 case $ac_top_builddir_sub in
26923 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
26924 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
26925 esac ;;
26926 esac
26927 ac_abs_top_builddir=$ac_pwd
26928 ac_abs_builddir=$ac_pwd$ac_dir_suffix
26929 # for backward compatibility:
26930 ac_top_builddir=$ac_top_build_prefix
26931
26932 case $srcdir in
26933 .) # We are building in place.
26934 ac_srcdir=.
26935 ac_top_srcdir=$ac_top_builddir_sub
26936 ac_abs_top_srcdir=$ac_pwd ;;
26937 [\\/]* | ?:[\\/]* ) # Absolute name.
26938 ac_srcdir=$srcdir$ac_dir_suffix;
26939 ac_top_srcdir=$srcdir
26940 ac_abs_top_srcdir=$srcdir ;;
26941 *) # Relative name.
26942 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
26943 ac_top_srcdir=$ac_top_build_prefix$srcdir
26944 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
26945 esac
26946 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
26947
26948
26949 case $ac_mode in
26950 :F)
26951 #
26952 # CONFIG_FILE
26953 #
26954
26955 case $INSTALL in
26956 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
26957 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
26958 esac
26959 ac_MKDIR_P=$MKDIR_P
26960 case $MKDIR_P in
26961 [\\/$]* | ?:[\\/]* ) ;;
26962 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
26963 esac
26964 _ACEOF
26965
26966 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26967 # If the template does not know about datarootdir, expand it.
26968 # FIXME: This hack should be removed a few years after 2.60.
26969 ac_datarootdir_hack=; ac_datarootdir_seen=
26970 ac_sed_dataroot='
26971 /datarootdir/ {
26972 p
26973 q
26974 }
26975 /@datadir@/p
26976 /@docdir@/p
26977 /@infodir@/p
26978 /@localedir@/p
26979 /@mandir@/p'
26980 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
26981 *datarootdir*) ac_datarootdir_seen=yes;;
26982 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
26983 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
26984 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
26985 _ACEOF
26986 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26987 ac_datarootdir_hack='
26988 s&@datadir@&$datadir&g
26989 s&@docdir@&$docdir&g
26990 s&@infodir@&$infodir&g
26991 s&@localedir@&$localedir&g
26992 s&@mandir@&$mandir&g
26993 s&\\\${datarootdir}&$datarootdir&g' ;;
26994 esac
26995 _ACEOF
26996
26997 # Neutralize VPATH when `$srcdir' = `.'.
26998 # Shell code in configure.ac might set extrasub.
26999 # FIXME: do we really want to maintain this feature?
27000 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27001 ac_sed_extra="$ac_vpsub
27002 $extrasub
27003 _ACEOF
27004 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27005 :t
27006 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
27007 s|@configure_input@|$ac_sed_conf_input|;t t
27008 s&@top_builddir@&$ac_top_builddir_sub&;t t
27009 s&@top_build_prefix@&$ac_top_build_prefix&;t t
27010 s&@srcdir@&$ac_srcdir&;t t
27011 s&@abs_srcdir@&$ac_abs_srcdir&;t t
27012 s&@top_srcdir@&$ac_top_srcdir&;t t
27013 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
27014 s&@builddir@&$ac_builddir&;t t
27015 s&@abs_builddir@&$ac_abs_builddir&;t t
27016 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
27017 s&@INSTALL@&$ac_INSTALL&;t t
27018 s&@MKDIR_P@&$ac_MKDIR_P&;t t
27019 $ac_datarootdir_hack
27020 "
27021 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
27022 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
27023
27024 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
27025 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
27026 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
27027 "$ac_tmp/out"`; test -z "$ac_out"; } &&
27028 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
27029 which seems to be undefined. Please make sure it is defined" >&5
27030 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
27031 which seems to be undefined. Please make sure it is defined" >&2;}
27032
27033 rm -f "$ac_tmp/stdin"
27034 case $ac_file in
27035 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
27036 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
27037 esac \
27038 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
27039 ;;
27040 :H)
27041 #
27042 # CONFIG_HEADER
27043 #
27044 if test x"$ac_file" != x-; then
27045 {
27046 $as_echo "/* $configure_input */" \
27047 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
27048 } >"$ac_tmp/config.h" \
27049 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
27050 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
27051 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
27052 $as_echo "$as_me: $ac_file is unchanged" >&6;}
27053 else
27054 rm -f "$ac_file"
27055 mv "$ac_tmp/config.h" "$ac_file" \
27056 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
27057 fi
27058 else
27059 $as_echo "/* $configure_input */" \
27060 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
27061 || as_fn_error $? "could not create -" "$LINENO" 5
27062 fi
27063 # Compute "$ac_file"'s index in $config_headers.
27064 _am_arg="$ac_file"
27065 _am_stamp_count=1
27066 for _am_header in $config_headers :; do
27067 case $_am_header in
27068 $_am_arg | $_am_arg:* )
27069 break ;;
27070 * )
27071 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
27072 esac
27073 done
27074 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
27075 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
27076 X"$_am_arg" : 'X\(//\)[^/]' \| \
27077 X"$_am_arg" : 'X\(//\)$' \| \
27078 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
27079 $as_echo X"$_am_arg" |
27080 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
27081 s//\1/
27082 q
27083 }
27084 /^X\(\/\/\)[^/].*/{
27085 s//\1/
27086 q
27087 }
27088 /^X\(\/\/\)$/{
27089 s//\1/
27090 q
27091 }
27092 /^X\(\/\).*/{
27093 s//\1/
27094 q
27095 }
27096 s/.*/./; q'`/stamp-h$_am_stamp_count
27097 ;;
27098
27099 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
27100 $as_echo "$as_me: executing $ac_file commands" >&6;}
27101 ;;
27102 esac
27103
27104
27105 case $ac_file$ac_mode in
27106 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
27107 # Older Autoconf quotes --file arguments for eval, but not when files
27108 # are listed without --file. Let's play safe and only enable the eval
27109 # if we detect the quoting.
27110 case $CONFIG_FILES in
27111 *\'*) eval set x "$CONFIG_FILES" ;;
27112 *) set x $CONFIG_FILES ;;
27113 esac
27114 shift
27115 for mf
27116 do
27117 # Strip MF so we end up with the name of the file.
27118 mf=`echo "$mf" | sed -e 's/:.*$//'`
27119 # Check whether this is an Automake generated Makefile or not.
27120 # We used to match only the files named 'Makefile.in', but
27121 # some people rename them; so instead we look at the file content.
27122 # Grep'ing the first line is not enough: some people post-process
27123 # each Makefile.in and add a new line on top of each file to say so.
27124 # Grep'ing the whole file is not good either: AIX grep has a line
27125 # limit of 2048, but all sed's we know have understand at least 4000.
27126 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
27127 dirpart=`$as_dirname -- "$mf" ||
27128 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
27129 X"$mf" : 'X\(//\)[^/]' \| \
27130 X"$mf" : 'X\(//\)$' \| \
27131 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
27132 $as_echo X"$mf" |
27133 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
27134 s//\1/
27135 q
27136 }
27137 /^X\(\/\/\)[^/].*/{
27138 s//\1/
27139 q
27140 }
27141 /^X\(\/\/\)$/{
27142 s//\1/
27143 q
27144 }
27145 /^X\(\/\).*/{
27146 s//\1/
27147 q
27148 }
27149 s/.*/./; q'`
27150 else
27151 continue
27152 fi
27153 # Extract the definition of DEPDIR, am__include, and am__quote
27154 # from the Makefile without running 'make'.
27155 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
27156 test -z "$DEPDIR" && continue
27157 am__include=`sed -n 's/^am__include = //p' < "$mf"`
27158 test -z "$am__include" && continue
27159 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
27160 # Find all dependency output files, they are included files with
27161 # $(DEPDIR) in their names. We invoke sed twice because it is the
27162 # simplest approach to changing $(DEPDIR) to its actual value in the
27163 # expansion.
27164 for file in `sed -n "
27165 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
27166 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
27167 # Make sure the directory exists.
27168 test -f "$dirpart/$file" && continue
27169 fdir=`$as_dirname -- "$file" ||
27170 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
27171 X"$file" : 'X\(//\)[^/]' \| \
27172 X"$file" : 'X\(//\)$' \| \
27173 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
27174 $as_echo X"$file" |
27175 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
27176 s//\1/
27177 q
27178 }
27179 /^X\(\/\/\)[^/].*/{
27180 s//\1/
27181 q
27182 }
27183 /^X\(\/\/\)$/{
27184 s//\1/
27185 q
27186 }
27187 /^X\(\/\).*/{
27188 s//\1/
27189 q
27190 }
27191 s/.*/./; q'`
27192 as_dir=$dirpart/$fdir; as_fn_mkdir_p
27193 # echo "creating $dirpart/$file"
27194 echo '# dummy' > "$dirpart/$file"
27195 done
27196 done
27197 }
27198 ;;
27199 "default":C)
27200 case x$CONFIG_HEADERS in
27201 xconfig.h:config.in)
27202 echo > stamp-h ;;
27203 esac
27204 ;;
27205
27206 esac
27207 done # for ac_tag
27208
27209
27210 as_fn_exit 0
27211 _ACEOF
27212 ac_clean_files=$ac_clean_files_save
27213
27214 test $ac_write_fail = 0 ||
27215 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
27216
27217
27218 # configure is writing to config.log, and then calls config.status.
27219 # config.status does its own redirection, appending to config.log.
27220 # Unfortunately, on DOS this fails, as config.log is still kept open
27221 # by configure, so config.status won't be able to write to it; its
27222 # output is simply discarded. So we exec the FD to /dev/null,
27223 # effectively closing config.log, so it can be properly (re)opened and
27224 # appended to by config.status. When coming back to configure, we
27225 # need to make the FD available again.
27226 if test "$no_create" != yes; then
27227 ac_cs_success=:
27228 ac_config_status_args=
27229 test "$silent" = yes &&
27230 ac_config_status_args="$ac_config_status_args --quiet"
27231 exec 5>/dev/null
27232 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
27233 exec 5>>config.log
27234 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
27235 # would make configure fail if this is the last instruction.
27236 $ac_cs_success || as_fn_exit 1
27237 fi
27238 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
27239 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
27240 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
27241 fi
27242
27243
27244 exit 0
This page took 0.556182 seconds and 5 git commands to generate.