]> git.proxmox.com Git - grub2.git/blame - configure
Improve handling of Debian kernel version numbers
[grub2.git] / configure
CommitLineData
4d8d554a
CW
1#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.
3# Generated by GNU Autoconf 2.69 for GRUB 2.02.
4#
5# Report bugs to <bug-grub@gnu.org>.
6#
7#
8# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
9#
10#
11# This configure script is free software; the Free Software Foundation
12# gives unlimited permission to copy, distribute and modify it.
13## -------------------- ##
14## M4sh Initialization. ##
15## -------------------- ##
16
17# Be more Bourne compatible
18DUALCASE=1; export DUALCASE # for MKS sh
19if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
20 emulate sh
21 NULLCMD=:
22 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23 # is contrary to our usage. Disable this feature.
24 alias -g '${1+"$@"}'='"$@"'
25 setopt NO_GLOB_SUBST
26else
27 case `(set -o) 2>/dev/null` in #(
28 *posix*) :
29 set -o posix ;; #(
30 *) :
31 ;;
32esac
33fi
34
35
36as_nl='
37'
38export as_nl
39# Printing a long string crashes Solaris 7 /usr/bin/printf.
40as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
41as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
42as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
43# Prefer a ksh shell builtin over an external printf program on Solaris,
44# but without wasting forks for bash or zsh.
45if test -z "$BASH_VERSION$ZSH_VERSION" \
46 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
47 as_echo='print -r --'
48 as_echo_n='print -rn --'
49elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
50 as_echo='printf %s\n'
51 as_echo_n='printf %s'
52else
53 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
54 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
55 as_echo_n='/usr/ucb/echo -n'
56 else
57 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
58 as_echo_n_body='eval
59 arg=$1;
60 case $arg in #(
61 *"$as_nl"*)
62 expr "X$arg" : "X\\(.*\\)$as_nl";
63 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
64 esac;
65 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
66 '
67 export as_echo_n_body
68 as_echo_n='sh -c $as_echo_n_body as_echo'
69 fi
70 export as_echo_body
71 as_echo='sh -c $as_echo_body as_echo'
72fi
73
74# The user is always right.
75if test "${PATH_SEPARATOR+set}" != set; then
76 PATH_SEPARATOR=:
77 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
78 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
79 PATH_SEPARATOR=';'
80 }
81fi
82
83
84# IFS
85# We need space, tab and new line, in precisely that order. Quoting is
86# there to prevent editors from complaining about space-tab.
87# (If _AS_PATH_WALK were called with IFS unset, it would disable word
88# splitting by setting IFS to empty value.)
89IFS=" "" $as_nl"
90
91# Find who we are. Look in the path if we contain no directory separator.
92as_myself=
93case $0 in #((
94 *[\\/]* ) as_myself=$0 ;;
95 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
96for as_dir in $PATH
97do
98 IFS=$as_save_IFS
99 test -z "$as_dir" && as_dir=.
100 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
101 done
102IFS=$as_save_IFS
103
104 ;;
105esac
106# We did not find ourselves, most probably we were run as `sh COMMAND'
107# in which case we are not to be found in the path.
108if test "x$as_myself" = x; then
109 as_myself=$0
110fi
111if test ! -f "$as_myself"; then
112 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
113 exit 1
114fi
115
116# Unset variables that we do not need and which cause bugs (e.g. in
117# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
118# suppresses any "Segmentation fault" message there. '((' could
119# trigger a bug in pdksh 5.2.14.
120for as_var in BASH_ENV ENV MAIL MAILPATH
121do eval test x\${$as_var+set} = xset \
122 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
123done
124PS1='$ '
125PS2='> '
126PS4='+ '
127
128# NLS nuisances.
129LC_ALL=C
130export LC_ALL
131LANGUAGE=C
132export LANGUAGE
133
134# CDPATH.
135(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
136
137# Use a proper internal environment variable to ensure we don't fall
138 # into an infinite loop, continuously re-executing ourselves.
139 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
140 _as_can_reexec=no; export _as_can_reexec;
141 # We cannot yet assume a decent shell, so we have to provide a
142# neutralization value for shells without unset; and this also
143# works around shells that cannot unset nonexistent variables.
144# Preserve -v and -x to the replacement shell.
145BASH_ENV=/dev/null
146ENV=/dev/null
147(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
148case $- in # ((((
149 *v*x* | *x*v* ) as_opts=-vx ;;
150 *v* ) as_opts=-v ;;
151 *x* ) as_opts=-x ;;
152 * ) as_opts= ;;
153esac
154exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
155# Admittedly, this is quite paranoid, since all the known shells bail
156# out after a failed `exec'.
157$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
158as_fn_exit 255
159 fi
160 # We don't want this to propagate to other subprocesses.
161 { _as_can_reexec=; unset _as_can_reexec;}
162if test "x$CONFIG_SHELL" = x; then
163 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
164 emulate sh
165 NULLCMD=:
166 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
167 # is contrary to our usage. Disable this feature.
168 alias -g '\${1+\"\$@\"}'='\"\$@\"'
169 setopt NO_GLOB_SUBST
170else
171 case \`(set -o) 2>/dev/null\` in #(
172 *posix*) :
173 set -o posix ;; #(
174 *) :
175 ;;
176esac
177fi
178"
179 as_required="as_fn_return () { (exit \$1); }
180as_fn_success () { as_fn_return 0; }
181as_fn_failure () { as_fn_return 1; }
182as_fn_ret_success () { return 0; }
183as_fn_ret_failure () { return 1; }
184
185exitcode=0
186as_fn_success || { exitcode=1; echo as_fn_success failed.; }
187as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
188as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
189as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
190if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
191
192else
193 exitcode=1; echo positional parameters were not saved.
194fi
195test x\$exitcode = x0 || exit 1
196test -x / || exit 1"
197 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
198 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
199 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
200 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
201test \$(( 1 + 1 )) = 2 || exit 1"
202 if (eval "$as_required") 2>/dev/null; then :
203 as_have_required=yes
204else
205 as_have_required=no
206fi
207 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
208
209else
210 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
211as_found=false
212for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
213do
214 IFS=$as_save_IFS
215 test -z "$as_dir" && as_dir=.
216 as_found=:
217 case $as_dir in #(
218 /*)
219 for as_base in sh bash ksh sh5; do
220 # Try only shells that exist, to save several forks.
221 as_shell=$as_dir/$as_base
222 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
223 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
224 CONFIG_SHELL=$as_shell as_have_required=yes
225 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
226 break 2
227fi
228fi
229 done;;
230 esac
231 as_found=false
232done
233$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
234 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
235 CONFIG_SHELL=$SHELL as_have_required=yes
236fi; }
237IFS=$as_save_IFS
238
239
240 if test "x$CONFIG_SHELL" != x; then :
241 export CONFIG_SHELL
242 # We cannot yet assume a decent shell, so we have to provide a
243# neutralization value for shells without unset; and this also
244# works around shells that cannot unset nonexistent variables.
245# Preserve -v and -x to the replacement shell.
246BASH_ENV=/dev/null
247ENV=/dev/null
248(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
249case $- in # ((((
250 *v*x* | *x*v* ) as_opts=-vx ;;
251 *v* ) as_opts=-v ;;
252 *x* ) as_opts=-x ;;
253 * ) as_opts= ;;
254esac
255exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
256# Admittedly, this is quite paranoid, since all the known shells bail
257# out after a failed `exec'.
258$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
259exit 255
260fi
261
262 if test x$as_have_required = xno; then :
263 $as_echo "$0: This script requires a shell more modern than all"
264 $as_echo "$0: the shells that I found on your system."
265 if test x${ZSH_VERSION+set} = xset ; then
266 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
267 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
268 else
269 $as_echo "$0: Please tell bug-autoconf@gnu.org and bug-grub@gnu.org
270$0: about your system, including any error possibly output
271$0: before this message. Then install a modern shell, or
272$0: manually run the script under such a shell if you do
273$0: have one."
274 fi
275 exit 1
276fi
277fi
278fi
279SHELL=${CONFIG_SHELL-/bin/sh}
280export SHELL
281# Unset more variables known to interfere with behavior of common tools.
282CLICOLOR_FORCE= GREP_OPTIONS=
283unset CLICOLOR_FORCE GREP_OPTIONS
284
285## --------------------- ##
286## M4sh Shell Functions. ##
287## --------------------- ##
288# as_fn_unset VAR
289# ---------------
290# Portably unset VAR.
291as_fn_unset ()
292{
293 { eval $1=; unset $1;}
294}
295as_unset=as_fn_unset
296
297# as_fn_set_status STATUS
298# -----------------------
299# Set $? to STATUS, without forking.
300as_fn_set_status ()
301{
302 return $1
303} # as_fn_set_status
304
305# as_fn_exit STATUS
306# -----------------
307# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
308as_fn_exit ()
309{
310 set +e
311 as_fn_set_status $1
312 exit $1
313} # as_fn_exit
314
315# as_fn_mkdir_p
316# -------------
317# Create "$as_dir" as a directory, including parents if necessary.
318as_fn_mkdir_p ()
319{
320
321 case $as_dir in #(
322 -*) as_dir=./$as_dir;;
323 esac
324 test -d "$as_dir" || eval $as_mkdir_p || {
325 as_dirs=
326 while :; do
327 case $as_dir in #(
328 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
329 *) as_qdir=$as_dir;;
330 esac
331 as_dirs="'$as_qdir' $as_dirs"
332 as_dir=`$as_dirname -- "$as_dir" ||
333$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
334 X"$as_dir" : 'X\(//\)[^/]' \| \
335 X"$as_dir" : 'X\(//\)$' \| \
336 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
337$as_echo X"$as_dir" |
338 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
339 s//\1/
340 q
341 }
342 /^X\(\/\/\)[^/].*/{
343 s//\1/
344 q
345 }
346 /^X\(\/\/\)$/{
347 s//\1/
348 q
349 }
350 /^X\(\/\).*/{
351 s//\1/
352 q
353 }
354 s/.*/./; q'`
355 test -d "$as_dir" && break
356 done
357 test -z "$as_dirs" || eval "mkdir $as_dirs"
358 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
359
360
361} # as_fn_mkdir_p
362
363# as_fn_executable_p FILE
364# -----------------------
365# Test if FILE is an executable regular file.
366as_fn_executable_p ()
367{
368 test -f "$1" && test -x "$1"
369} # as_fn_executable_p
370# as_fn_append VAR VALUE
371# ----------------------
372# Append the text in VALUE to the end of the definition contained in VAR. Take
373# advantage of any shell optimizations that allow amortized linear growth over
374# repeated appends, instead of the typical quadratic growth present in naive
375# implementations.
376if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
377 eval 'as_fn_append ()
378 {
379 eval $1+=\$2
380 }'
381else
382 as_fn_append ()
383 {
384 eval $1=\$$1\$2
385 }
386fi # as_fn_append
387
388# as_fn_arith ARG...
389# ------------------
390# Perform arithmetic evaluation on the ARGs, and store the result in the
391# global $as_val. Take advantage of shells that can avoid forks. The arguments
392# must be portable across $(()) and expr.
393if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
394 eval 'as_fn_arith ()
395 {
396 as_val=$(( $* ))
397 }'
398else
399 as_fn_arith ()
400 {
401 as_val=`expr "$@" || test $? -eq 1`
402 }
403fi # as_fn_arith
404
405
406# as_fn_error STATUS ERROR [LINENO LOG_FD]
407# ----------------------------------------
408# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
409# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
410# script with STATUS, using 1 if that was 0.
411as_fn_error ()
412{
413 as_status=$1; test $as_status -eq 0 && as_status=1
414 if test "$4"; then
415 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
416 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
417 fi
418 $as_echo "$as_me: error: $2" >&2
419 as_fn_exit $as_status
420} # as_fn_error
421
422if expr a : '\(a\)' >/dev/null 2>&1 &&
423 test "X`expr 00001 : '.*\(...\)'`" = X001; then
424 as_expr=expr
425else
426 as_expr=false
427fi
428
429if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
430 as_basename=basename
431else
432 as_basename=false
433fi
434
435if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
436 as_dirname=dirname
437else
438 as_dirname=false
439fi
440
441as_me=`$as_basename -- "$0" ||
442$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
443 X"$0" : 'X\(//\)$' \| \
444 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
445$as_echo X/"$0" |
446 sed '/^.*\/\([^/][^/]*\)\/*$/{
447 s//\1/
448 q
449 }
450 /^X\/\(\/\/\)$/{
451 s//\1/
452 q
453 }
454 /^X\/\(\/\).*/{
455 s//\1/
456 q
457 }
458 s/.*/./; q'`
459
460# Avoid depending upon Character Ranges.
461as_cr_letters='abcdefghijklmnopqrstuvwxyz'
462as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
463as_cr_Letters=$as_cr_letters$as_cr_LETTERS
464as_cr_digits='0123456789'
465as_cr_alnum=$as_cr_Letters$as_cr_digits
466
467
468 as_lineno_1=$LINENO as_lineno_1a=$LINENO
469 as_lineno_2=$LINENO as_lineno_2a=$LINENO
470 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
471 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
472 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
473 sed -n '
474 p
475 /[$]LINENO/=
476 ' <$as_myself |
477 sed '
478 s/[$]LINENO.*/&-/
479 t lineno
480 b
481 :lineno
482 N
483 :loop
484 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
485 t loop
486 s/-\n.*//
487 ' >$as_me.lineno &&
488 chmod +x "$as_me.lineno" ||
489 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
490
491 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
492 # already done that, so ensure we don't try to do so again and fall
493 # in an infinite loop. This has already happened in practice.
494 _as_can_reexec=no; export _as_can_reexec
495 # Don't try to exec as it changes $[0], causing all sort of problems
496 # (the dirname of $[0] is not the place where we might find the
497 # original and so on. Autoconf is especially sensitive to this).
498 . "./$as_me.lineno"
499 # Exit status is that of the last command.
500 exit
501}
502
503ECHO_C= ECHO_N= ECHO_T=
504case `echo -n x` in #(((((
505-n*)
506 case `echo 'xy\c'` in
507 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
508 xy) ECHO_C='\c';;
509 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
510 ECHO_T=' ';;
511 esac;;
512*)
513 ECHO_N='-n';;
514esac
515
516rm -f conf$$ conf$$.exe conf$$.file
517if test -d conf$$.dir; then
518 rm -f conf$$.dir/conf$$.file
519else
520 rm -f conf$$.dir
521 mkdir conf$$.dir 2>/dev/null
522fi
523if (echo >conf$$.file) 2>/dev/null; then
524 if ln -s conf$$.file conf$$ 2>/dev/null; then
525 as_ln_s='ln -s'
526 # ... but there are two gotchas:
527 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
528 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
529 # In both cases, we have to default to `cp -pR'.
530 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
531 as_ln_s='cp -pR'
532 elif ln conf$$.file conf$$ 2>/dev/null; then
533 as_ln_s=ln
534 else
535 as_ln_s='cp -pR'
536 fi
537else
538 as_ln_s='cp -pR'
539fi
540rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
541rmdir conf$$.dir 2>/dev/null
542
543if mkdir -p . 2>/dev/null; then
544 as_mkdir_p='mkdir -p "$as_dir"'
545else
546 test -d ./-p && rmdir ./-p
547 as_mkdir_p=false
548fi
549
550as_test_x='test -x'
551as_executable_p=as_fn_executable_p
552
553# Sed expression to map a string onto a valid CPP name.
554as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
555
556# Sed expression to map a string onto a valid variable name.
557as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
558
559
560test -n "$DJDIR" || exec 7<&0 </dev/null
561exec 6>&1
562
563# Name of the host.
564# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
565# so uname gets run too.
566ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
567
568#
569# Initializations.
570#
571ac_default_prefix=/usr/local
572ac_clean_files=
573ac_config_libobj_dir=.
574LIBOBJS=
575cross_compiling=no
576subdirs=
577MFLAGS=
578MAKEFLAGS=
579
580# Identity of this package.
581PACKAGE_NAME='GRUB'
582PACKAGE_TARNAME='grub'
583PACKAGE_VERSION='2.02'
584PACKAGE_STRING='GRUB 2.02'
585PACKAGE_BUGREPORT='bug-grub@gnu.org'
586PACKAGE_URL=''
587
588ac_unique_file="include/grub/dl.h"
589# Factoring default headers for most tests.
590ac_includes_default="\
591#include <stdio.h>
592#ifdef HAVE_SYS_TYPES_H
593# include <sys/types.h>
594#endif
595#ifdef HAVE_SYS_STAT_H
596# include <sys/stat.h>
597#endif
598#ifdef STDC_HEADERS
599# include <stdlib.h>
600# include <stddef.h>
601#else
602# ifdef HAVE_STDLIB_H
603# include <stdlib.h>
604# endif
605#endif
606#ifdef HAVE_STRING_H
607# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
608# include <memory.h>
609# endif
610# include <string.h>
611#endif
612#ifdef HAVE_STRINGS_H
613# include <strings.h>
614#endif
615#ifdef HAVE_INTTYPES_H
616# include <inttypes.h>
617#endif
618#ifdef HAVE_STDINT_H
619# include <stdint.h>
620#endif
621#ifdef HAVE_UNISTD_H
622# include <unistd.h>
623#endif"
624
625gt_needs=
626ac_func_list=
627ac_header_list=
628gl_fnmatch_required=POSIX
629gl_getopt_required=POSIX
630gl_getopt_required=POSIX
631ac_subst_vars='gltests_LTLIBOBJS
632gltests_LIBOBJS
633gl_LTLIBOBJS
634gl_LIBOBJS
635am__EXEEXT_FALSE
636am__EXEEXT_TRUE
637LTLIBOBJS
638LIBOBJS
639COND_HAVE_EXEC_FALSE
640COND_HAVE_EXEC_TRUE
641COND_STARFIELD_FALSE
642COND_STARFIELD_TRUE
643COND_HAVE_ASM_USCORE_FALSE
644COND_HAVE_ASM_USCORE_TRUE
645COND_HAVE_CXX_FALSE
646COND_HAVE_CXX_TRUE
647COND_ENABLE_BOOT_TIME_STATS_FALSE
648COND_ENABLE_BOOT_TIME_STATS_TRUE
649COND_ENABLE_CACHE_STATS_FALSE
650COND_ENABLE_CACHE_STATS_TRUE
651COND_ENABLE_EFIEMU_FALSE
652COND_ENABLE_EFIEMU_TRUE
653COND_APPLE_LINKER_FALSE
654COND_APPLE_LINKER_TRUE
655HAVE_FONT_SOURCE
656COND_HAVE_FONT_SOURCE_FALSE
657COND_HAVE_FONT_SOURCE_TRUE
658COND_GRUB_MOUNT_FALSE
659COND_GRUB_MOUNT_TRUE
660COND_GRUB_MKFONT_FALSE
661COND_GRUB_MKFONT_TRUE
662COND_GRUB_EMU_PCI_FALSE
663COND_GRUB_EMU_PCI_TRUE
664COND_GRUB_EMU_SDL_FALSE
665COND_GRUB_EMU_SDL_TRUE
666COND_MAN_PAGES_FALSE
667COND_MAN_PAGES_TRUE
668COND_HOST_ILLUMOS_FALSE
669COND_HOST_ILLUMOS_TRUE
670COND_HOST_XNU_FALSE
671COND_HOST_XNU_TRUE
672COND_HOST_KFREEBSD_FALSE
673COND_HOST_KFREEBSD_TRUE
674COND_HOST_WINDOWS_FALSE
675COND_HOST_WINDOWS_TRUE
676COND_HOST_NETBSD_FALSE
677COND_HOST_NETBSD_TRUE
678COND_HOST_LINUX_FALSE
679COND_HOST_LINUX_TRUE
680COND_HOST_HURD_FALSE
681COND_HOST_HURD_TRUE
682COND_arm64_efi_FALSE
683COND_arm64_efi_TRUE
684COND_arm64_FALSE
685COND_arm64_TRUE
686COND_arm_efi_FALSE
687COND_arm_efi_TRUE
688COND_arm_uboot_FALSE
689COND_arm_uboot_TRUE
690COND_arm_FALSE
691COND_arm_TRUE
692COND_mipseb_FALSE
693COND_mipseb_TRUE
694COND_mipsel_FALSE
695COND_mipsel_TRUE
696COND_mips_FALSE
697COND_mips_TRUE
698COND_powerpc_ieee1275_FALSE
699COND_powerpc_ieee1275_TRUE
700COND_sparc64_emu_FALSE
701COND_sparc64_emu_TRUE
702COND_sparc64_ieee1275_FALSE
703COND_sparc64_ieee1275_TRUE
704COND_mips_arc_FALSE
705COND_mips_arc_TRUE
706COND_mips_qemu_mips_FALSE
707COND_mips_qemu_mips_TRUE
708COND_mips_loongson_FALSE
709COND_mips_loongson_TRUE
710COND_x86_64_xen_FALSE
711COND_x86_64_xen_TRUE
712COND_i386_xen_FALSE
713COND_i386_xen_TRUE
714COND_x86_64_efi_FALSE
715COND_x86_64_efi_TRUE
716COND_i386_multiboot_FALSE
717COND_i386_multiboot_TRUE
718COND_i386_coreboot_FALSE
719COND_i386_coreboot_TRUE
720COND_i386_ieee1275_FALSE
721COND_i386_ieee1275_TRUE
722COND_i386_qemu_FALSE
723COND_i386_qemu_TRUE
724COND_ia64_efi_FALSE
725COND_ia64_efi_TRUE
726COND_i386_efi_FALSE
727COND_i386_efi_TRUE
728COND_i386_pc_FALSE
729COND_i386_pc_TRUE
730COND_emu_FALSE
731COND_emu_TRUE
732COND_real_platform_FALSE
733COND_real_platform_TRUE
734BUILD_LIBM
735HOST_CCASFLAGS
736HOST_CPPFLAGS
737HOST_LDFLAGS
738HOST_CFLAGS
739TARGET_APPLE_LINKER
740TARGET_IMG_BASE_LDOPT
741TARGET_IMG_CFLAGS
742TARGET_IMG_LDFLAGS
743TARGET_CCASFLAGS
744TARGET_CPPFLAGS
745TARGET_LDFLAGS
746TARGET_CFLAGS
747TARGET_CC_VERSION
748TARGET_MODULE_FORMAT
749TARGET_OBJ2ELF
750TARGET_CCAS
751TARGET_CPP
752GRUB_PLATFORM
753GRUB_TARGET_CPU
754END_SYMBOL
755BSS_START_SYMBOL
756HAVE_ASM_USCORE
757GRUB_BOOT_MACHINE_LINK_ADDR
758LIBNVPAIR
759LIBZFS
760LIBLZMA
761LIBGEOM
762LIBDEVMAPPER
763enable_grub_mount
764FONT_SOURCE
765DJVU_FONT_SOURCE
766build_freetype_libs
767build_freetype_cflags
768BUILD_FREETYPE
769BUILD_WORDS_BIGENDIAN
770BUILD_SIZEOF_VOID_P
771BUILD_SIZEOF_LONG
772freetype_libs
773freetype_cflags
774enable_grub_mkfont
775ac_ct_FREETYPE
776FREETYPE
777enable_grub_emu_pci
778enable_grub_emu_sdl
779LIBPCIACCESS
780LIBSDL
781BOOT_TIME_STATS
782DISK_CACHE_STATS
783TARGET_NMFLAGS_DEFINED_ONLY
784TARGET_NMFLAGS_MINUS_P
785TARGET_LDFLAGS_OLDMAGIC
786EFIEMU64_LINK_FORMAT
787enable_efiemu
788TARGET_OBJCONV
789BUILD_LDFLAGS
790BUILD_CPPFLAGS
791BUILD_CFLAGS
792HOST_CC
793TARGET_RANLIB
794TARGET_NM
795TARGET_STRIP
796TARGET_OBJCOPY
797ac_ct_TARGET_CC
798TARGET_CC
799LIBGNU_LTLIBDEPS
800LIBGNU_LIBDEPS
801gltests_WITNESS
802REPLACE_TOWLOWER
803REPLACE_ISWCNTRL
804HAVE_WCTYPE_H
805NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H
806NEXT_WCTYPE_H
807HAVE_ISWCNTRL
808REPLACE_ISWBLANK
809HAVE_WCTRANS_T
810HAVE_WCTYPE_T
811HAVE_ISWBLANK
812GNULIB_TOWCTRANS
813GNULIB_WCTRANS
814GNULIB_ISWCTYPE
815GNULIB_WCTYPE
816GNULIB_ISWBLANK
817HAVE_WINT_T
818NEXT_AS_FIRST_DIRECTIVE_WCHAR_H
819NEXT_WCHAR_H
820HAVE_FEATURES_H
821LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_FALSE
822LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_TRUE
823LIBUNISTRING_UNIWIDTH_H
824LIBUNISTRING_UNITYPES_H
825HAVE_UNISTD_H
826NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
827NEXT_UNISTD_H
828GL_GENERATE_SYSEXITS_H_FALSE
829GL_GENERATE_SYSEXITS_H_TRUE
830SYSEXITS_H
831HAVE_SYSEXITS_H
832NEXT_AS_FIRST_DIRECTIVE_SYSEXITS_H
833NEXT_SYSEXITS_H
834WINDOWS_64_BIT_OFF_T
835NEXT_AS_FIRST_DIRECTIVE_SYS_TYPES_H
836NEXT_SYS_TYPES_H
837HAVE_STRINGS_H
838NEXT_AS_FIRST_DIRECTIVE_STRINGS_H
839NEXT_STRINGS_H
840NEXT_AS_FIRST_DIRECTIVE_STRING_H
841NEXT_STRING_H
842HAVE_WINSOCK2_H
843HAVE_DECL_STRNCASECMP
844HAVE_STRCASECMP
845HAVE_FFS
846GNULIB_FFS
847NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
848NEXT_STDLIB_H
849NEXT_AS_FIRST_DIRECTIVE_STDIO_H
850NEXT_STDIO_H
851GL_GENERATE_STDINT_H_FALSE
852GL_GENERATE_STDINT_H_TRUE
853STDINT_H
854WINT_T_SUFFIX
855WCHAR_T_SUFFIX
856SIG_ATOMIC_T_SUFFIX
857SIZE_T_SUFFIX
858PTRDIFF_T_SUFFIX
859HAVE_SIGNED_WINT_T
860HAVE_SIGNED_WCHAR_T
861HAVE_SIGNED_SIG_ATOMIC_T
862BITSIZEOF_WINT_T
863BITSIZEOF_WCHAR_T
864BITSIZEOF_SIG_ATOMIC_T
865BITSIZEOF_SIZE_T
866BITSIZEOF_PTRDIFF_T
867HAVE_SYS_BITYPES_H
868HAVE_SYS_INTTYPES_H
869HAVE_STDINT_H
870NEXT_AS_FIRST_DIRECTIVE_STDINT_H
871NEXT_STDINT_H
872HAVE_SYS_TYPES_H
873HAVE_INTTYPES_H
874HAVE_WCHAR_H
875HAVE_UNSIGNED_LONG_LONG_INT
876HAVE_LONG_LONG_INT
877HAVE__BOOL
878GL_GENERATE_STDBOOL_H_FALSE
879GL_GENERATE_STDBOOL_H_TRUE
880STDBOOL_H
881GL_GENERATE_STDALIGN_H_FALSE
882GL_GENERATE_STDALIGN_H_TRUE
883STDALIGN_H
884APPLE_UNIVERSAL_BUILD
885HAVE_MSVC_INVALID_PARAMETER_HANDLER
886UNDEFINE_STRTOK_R
887REPLACE_STRTOK_R
888REPLACE_STRSIGNAL
889REPLACE_STRNLEN
890REPLACE_STRNDUP
891REPLACE_STRNCAT
892REPLACE_STRERROR_R
893REPLACE_STRERROR
894REPLACE_STRCHRNUL
895REPLACE_STRCASESTR
896REPLACE_STRSTR
897REPLACE_STRDUP
898REPLACE_STPNCPY
899REPLACE_MEMMEM
900REPLACE_MEMCHR
901HAVE_STRVERSCMP
902HAVE_DECL_STRSIGNAL
903HAVE_DECL_STRERROR_R
904HAVE_DECL_STRTOK_R
905HAVE_STRCASESTR
906HAVE_STRSEP
907HAVE_STRPBRK
908HAVE_DECL_STRNLEN
909HAVE_DECL_STRNDUP
910HAVE_DECL_STRDUP
911HAVE_STRCHRNUL
912HAVE_STPNCPY
913HAVE_STPCPY
914HAVE_RAWMEMCHR
915HAVE_DECL_MEMRCHR
916HAVE_MEMPCPY
917HAVE_DECL_MEMMEM
918HAVE_MEMCHR
919HAVE_FFSLL
920HAVE_FFSL
921HAVE_MBSLEN
922GNULIB_STRVERSCMP
923GNULIB_STRSIGNAL
924GNULIB_STRERROR_R
925GNULIB_STRERROR
926GNULIB_MBSTOK_R
927GNULIB_MBSSEP
928GNULIB_MBSSPN
929GNULIB_MBSPBRK
930GNULIB_MBSCSPN
931GNULIB_MBSCASESTR
932GNULIB_MBSPCASECMP
933GNULIB_MBSNCASECMP
934GNULIB_MBSCASECMP
935GNULIB_MBSSTR
936GNULIB_MBSRCHR
937GNULIB_MBSCHR
938GNULIB_MBSNLEN
939GNULIB_MBSLEN
940GNULIB_STRTOK_R
941GNULIB_STRCASESTR
942GNULIB_STRSTR
943GNULIB_STRSEP
944GNULIB_STRPBRK
945GNULIB_STRNLEN
946GNULIB_STRNDUP
947GNULIB_STRNCAT
948GNULIB_STRDUP
949GNULIB_STRCHRNUL
950GNULIB_STPNCPY
951GNULIB_STPCPY
952GNULIB_RAWMEMCHR
953GNULIB_MEMRCHR
954GNULIB_MEMPCPY
955GNULIB_MEMMEM
956GNULIB_MEMCHR
957GNULIB_FFSLL
958GNULIB_FFSL
959LOCALE_FR_UTF8
960LOCALE_ZH_CN
961LOCALE_JA
962REPLACE_WCTOMB
963REPLACE_UNSETENV
964REPLACE_STRTOD
965REPLACE_SETENV
966REPLACE_REALPATH
967REPLACE_REALLOC
968REPLACE_RANDOM_R
969REPLACE_PUTENV
970REPLACE_PTSNAME_R
971REPLACE_PTSNAME
972REPLACE_MKSTEMP
973REPLACE_MBTOWC
974REPLACE_MALLOC
975REPLACE_CANONICALIZE_FILE_NAME
976REPLACE_CALLOC
977HAVE_DECL_UNSETENV
978HAVE_UNLOCKPT
979HAVE_SYS_LOADAVG_H
980HAVE_STRUCT_RANDOM_DATA
981HAVE_STRTOULL
982HAVE_STRTOLL
983HAVE_STRTOD
984HAVE_DECL_SETENV
985HAVE_SETENV
986HAVE_SECURE_GETENV
987HAVE_RPMATCH
988HAVE_REALPATH
989HAVE_RANDOM_R
990HAVE_RANDOM_H
991HAVE_RANDOM
992HAVE_PTSNAME_R
993HAVE_PTSNAME
994HAVE_POSIX_OPENPT
995HAVE_MKSTEMPS
996HAVE_MKSTEMP
997HAVE_MKOSTEMPS
998HAVE_MKOSTEMP
999HAVE_MKDTEMP
1000HAVE_GRANTPT
1001HAVE_GETSUBOPT
1002HAVE_DECL_GETLOADAVG
1003HAVE_CANONICALIZE_FILE_NAME
1004HAVE_ATOLL
1005HAVE__EXIT
1006GNULIB_WCTOMB
1007GNULIB_UNSETENV
1008GNULIB_UNLOCKPT
1009GNULIB_SYSTEM_POSIX
1010GNULIB_STRTOULL
1011GNULIB_STRTOLL
1012GNULIB_STRTOD
1013GNULIB_SETENV
1014GNULIB_SECURE_GETENV
1015GNULIB_RPMATCH
1016GNULIB_REALPATH
1017GNULIB_REALLOC_POSIX
1018GNULIB_RANDOM_R
1019GNULIB_RANDOM
1020GNULIB_PUTENV
1021GNULIB_PTSNAME_R
1022GNULIB_PTSNAME
1023GNULIB_POSIX_OPENPT
1024GNULIB_MKSTEMPS
1025GNULIB_MKSTEMP
1026GNULIB_MKOSTEMPS
1027GNULIB_MKOSTEMP
1028GNULIB_MKDTEMP
1029GNULIB_MBTOWC
1030GNULIB_MALLOC_POSIX
1031GNULIB_GRANTPT
1032GNULIB_GETSUBOPT
1033GNULIB_GETLOADAVG
1034GNULIB_CANONICALIZE_FILE_NAME
1035GNULIB_CALLOC_POSIX
1036GNULIB_ATOLL
1037GNULIB__EXIT
1038NEXT_AS_FIRST_DIRECTIVE_LOCALE_H
1039NEXT_LOCALE_H
1040HAVE_XLOCALE_H
1041NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
1042NEXT_STDDEF_H
1043GL_GENERATE_STDDEF_H_FALSE
1044GL_GENERATE_STDDEF_H_TRUE
1045STDDEF_H
1046HAVE_WCHAR_T
1047REPLACE_NULL
1048REPLACE_STRUCT_LCONV
1049REPLACE_DUPLOCALE
1050REPLACE_SETLOCALE
1051REPLACE_LOCALECONV
1052HAVE_DUPLOCALE
1053GNULIB_DUPLOCALE
1054GNULIB_SETLOCALE
1055GNULIB_LOCALECONV
1056LOCALCHARSET_TESTS_ENVIRONMENT
1057GLIBC21
1058HAVE_LANGINFO_YESEXPR
1059HAVE_LANGINFO_ERA
1060HAVE_LANGINFO_T_FMT_AMPM
1061HAVE_LANGINFO_CODESET
1062HAVE_LANGINFO_H
1063NEXT_AS_FIRST_DIRECTIVE_LANGINFO_H
1064NEXT_LANGINFO_H
1065REPLACE_NL_LANGINFO
1066HAVE_NL_LANGINFO
1067GNULIB_NL_LANGINFO
1068GNULIB_GL_UNISTD_H_GETOPT
1069GETOPT_H
1070HAVE_GETOPT_H
1071NEXT_AS_FIRST_DIRECTIVE_GETOPT_H
1072NEXT_GETOPT_H
1073UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
1074UNISTD_H_HAVE_WINSOCK2_H
1075REPLACE_WRITE
1076REPLACE_USLEEP
1077REPLACE_UNLINKAT
1078REPLACE_UNLINK
1079REPLACE_TTYNAME_R
1080REPLACE_SYMLINK
1081REPLACE_SLEEP
1082REPLACE_RMDIR
1083REPLACE_READLINK
1084REPLACE_READ
1085REPLACE_PWRITE
1086REPLACE_PREAD
1087REPLACE_LSEEK
1088REPLACE_LINKAT
1089REPLACE_LINK
1090REPLACE_LCHOWN
1091REPLACE_ISATTY
1092REPLACE_GETPAGESIZE
1093REPLACE_GETGROUPS
1094REPLACE_GETLOGIN_R
1095REPLACE_GETDOMAINNAME
1096REPLACE_GETCWD
1097REPLACE_FTRUNCATE
1098REPLACE_FCHOWNAT
1099REPLACE_DUP2
1100REPLACE_DUP
1101REPLACE_CLOSE
1102REPLACE_CHOWN
1103HAVE_SYS_PARAM_H
1104HAVE_OS_H
1105HAVE_DECL_TTYNAME_R
1106HAVE_DECL_SETHOSTNAME
1107HAVE_DECL_GETUSERSHELL
1108HAVE_DECL_GETPAGESIZE
1109HAVE_DECL_GETLOGIN_R
1110HAVE_DECL_GETDOMAINNAME
1111HAVE_DECL_FDATASYNC
1112HAVE_DECL_FCHDIR
1113HAVE_DECL_ENVIRON
1114HAVE_USLEEP
1115HAVE_UNLINKAT
1116HAVE_SYMLINKAT
1117HAVE_SYMLINK
1118HAVE_SLEEP
1119HAVE_SETHOSTNAME
1120HAVE_READLINKAT
1121HAVE_READLINK
1122HAVE_PWRITE
1123HAVE_PREAD
1124HAVE_PIPE2
1125HAVE_PIPE
1126HAVE_LINKAT
1127HAVE_LINK
1128HAVE_LCHOWN
1129HAVE_GROUP_MEMBER
1130HAVE_GETPAGESIZE
1131HAVE_GETLOGIN
1132HAVE_GETHOSTNAME
1133HAVE_GETGROUPS
1134HAVE_GETDTABLESIZE
1135HAVE_FTRUNCATE
1136HAVE_FSYNC
1137HAVE_FDATASYNC
1138HAVE_FCHOWNAT
1139HAVE_FCHDIR
1140HAVE_FACCESSAT
1141HAVE_EUIDACCESS
1142HAVE_DUP3
1143HAVE_DUP2
1144HAVE_CHOWN
1145GNULIB_WRITE
1146GNULIB_USLEEP
1147GNULIB_UNLINKAT
1148GNULIB_UNLINK
1149GNULIB_UNISTD_H_SIGPIPE
1150GNULIB_UNISTD_H_NONBLOCKING
1151GNULIB_TTYNAME_R
1152GNULIB_SYMLINKAT
1153GNULIB_SYMLINK
1154GNULIB_SLEEP
1155GNULIB_SETHOSTNAME
1156GNULIB_RMDIR
1157GNULIB_READLINKAT
1158GNULIB_READLINK
1159GNULIB_READ
1160GNULIB_PWRITE
1161GNULIB_PREAD
1162GNULIB_PIPE2
1163GNULIB_PIPE
1164GNULIB_LSEEK
1165GNULIB_LINKAT
1166GNULIB_LINK
1167GNULIB_LCHOWN
1168GNULIB_ISATTY
1169GNULIB_GROUP_MEMBER
1170GNULIB_GETUSERSHELL
1171GNULIB_GETPAGESIZE
1172GNULIB_GETLOGIN_R
1173GNULIB_GETLOGIN
1174GNULIB_GETHOSTNAME
1175GNULIB_GETGROUPS
1176GNULIB_GETDTABLESIZE
1177GNULIB_GETDOMAINNAME
1178GNULIB_GETCWD
1179GNULIB_FTRUNCATE
1180GNULIB_FSYNC
1181GNULIB_FDATASYNC
1182GNULIB_FCHOWNAT
1183GNULIB_FCHDIR
1184GNULIB_FACCESSAT
1185GNULIB_EUIDACCESS
1186GNULIB_ENVIRON
1187GNULIB_DUP3
1188GNULIB_DUP2
1189GNULIB_DUP
1190GNULIB_CLOSE
1191GNULIB_CHOWN
1192GNULIB_CHDIR
1193REPLACE_VSPRINTF
1194REPLACE_VSNPRINTF
1195REPLACE_VPRINTF
1196REPLACE_VFPRINTF
1197REPLACE_VDPRINTF
1198REPLACE_VASPRINTF
1199REPLACE_TMPFILE
1200REPLACE_STDIO_WRITE_FUNCS
1201REPLACE_STDIO_READ_FUNCS
1202REPLACE_SPRINTF
1203REPLACE_SNPRINTF
1204REPLACE_RENAMEAT
1205REPLACE_RENAME
1206REPLACE_REMOVE
1207REPLACE_PRINTF
1208REPLACE_POPEN
1209REPLACE_PERROR
1210REPLACE_OBSTACK_PRINTF
1211REPLACE_GETLINE
1212REPLACE_GETDELIM
1213REPLACE_FTELLO
1214REPLACE_FTELL
1215REPLACE_FSEEKO
1216REPLACE_FSEEK
1217REPLACE_FREOPEN
1218REPLACE_FPURGE
1219REPLACE_FPRINTF
1220REPLACE_FOPEN
1221REPLACE_FFLUSH
1222REPLACE_FDOPEN
1223REPLACE_FCLOSE
1224REPLACE_DPRINTF
1225HAVE_VDPRINTF
1226HAVE_VASPRINTF
1227HAVE_RENAMEAT
1228HAVE_POPEN
1229HAVE_PCLOSE
1230HAVE_FTELLO
1231HAVE_FSEEKO
1232HAVE_DPRINTF
1233HAVE_DECL_VSNPRINTF
1234HAVE_DECL_SNPRINTF
1235HAVE_DECL_OBSTACK_PRINTF
1236HAVE_DECL_GETLINE
1237HAVE_DECL_GETDELIM
1238HAVE_DECL_FTELLO
1239HAVE_DECL_FSEEKO
1240HAVE_DECL_FPURGE
1241GNULIB_VSPRINTF_POSIX
1242GNULIB_VSNPRINTF
1243GNULIB_VPRINTF_POSIX
1244GNULIB_VPRINTF
1245GNULIB_VFPRINTF_POSIX
1246GNULIB_VFPRINTF
1247GNULIB_VDPRINTF
1248GNULIB_VSCANF
1249GNULIB_VFSCANF
1250GNULIB_VASPRINTF
1251GNULIB_TMPFILE
1252GNULIB_STDIO_H_SIGPIPE
1253GNULIB_STDIO_H_NONBLOCKING
1254GNULIB_SPRINTF_POSIX
1255GNULIB_SNPRINTF
1256GNULIB_SCANF
1257GNULIB_RENAMEAT
1258GNULIB_RENAME
1259GNULIB_REMOVE
1260GNULIB_PUTS
1261GNULIB_PUTCHAR
1262GNULIB_PUTC
1263GNULIB_PRINTF_POSIX
1264GNULIB_PRINTF
1265GNULIB_POPEN
1266GNULIB_PERROR
1267GNULIB_PCLOSE
1268GNULIB_OBSTACK_PRINTF_POSIX
1269GNULIB_OBSTACK_PRINTF
1270GNULIB_GETLINE
1271GNULIB_GETDELIM
1272GNULIB_GETCHAR
1273GNULIB_GETC
1274GNULIB_FWRITE
1275GNULIB_FTELLO
1276GNULIB_FTELL
1277GNULIB_FSEEKO
1278GNULIB_FSEEK
1279GNULIB_FSCANF
1280GNULIB_FREOPEN
1281GNULIB_FREAD
1282GNULIB_FPUTS
1283GNULIB_FPUTC
1284GNULIB_FPURGE
1285GNULIB_FPRINTF_POSIX
1286GNULIB_FPRINTF
1287GNULIB_FOPEN
1288GNULIB_FGETS
1289GNULIB_FGETC
1290GNULIB_FFLUSH
1291GNULIB_FDOPEN
1292GNULIB_FCLOSE
1293GNULIB_DPRINTF
1294GL_GENERATE_FNMATCH_H_FALSE
1295GL_GENERATE_FNMATCH_H_TRUE
1296FNMATCH_H
1297REPLACE_ITOLD
1298GL_GENERATE_FLOAT_H_FALSE
1299GL_GENERATE_FLOAT_H_TRUE
1300FLOAT_H
1301NEXT_AS_FIRST_DIRECTIVE_FLOAT_H
1302NEXT_FLOAT_H
1303EOVERFLOW_VALUE
1304EOVERFLOW_HIDDEN
1305ENOLINK_VALUE
1306ENOLINK_HIDDEN
1307EMULTIHOP_VALUE
1308EMULTIHOP_HIDDEN
1309GL_GENERATE_ERRNO_H_FALSE
1310GL_GENERATE_ERRNO_H_TRUE
1311ERRNO_H
1312NEXT_AS_FIRST_DIRECTIVE_ERRNO_H
1313NEXT_ERRNO_H
1314PRAGMA_COLUMNS
1315PRAGMA_SYSTEM_HEADER
1316INCLUDE_NEXT_AS_FIRST_DIRECTIVE
1317INCLUDE_NEXT
1318pkglibexecdir
1319lispdir
1320LOCALE_FR
1321REPLACE_WCSWIDTH
1322REPLACE_WCWIDTH
1323REPLACE_WCSNRTOMBS
1324REPLACE_WCSRTOMBS
1325REPLACE_WCRTOMB
1326REPLACE_MBSNRTOWCS
1327REPLACE_MBSRTOWCS
1328REPLACE_MBRLEN
1329REPLACE_MBRTOWC
1330REPLACE_MBSINIT
1331REPLACE_WCTOB
1332REPLACE_BTOWC
1333REPLACE_MBSTATE_T
1334HAVE_DECL_WCWIDTH
1335HAVE_DECL_WCTOB
1336HAVE_WCSWIDTH
1337HAVE_WCSTOK
1338HAVE_WCSSTR
1339HAVE_WCSPBRK
1340HAVE_WCSSPN
1341HAVE_WCSCSPN
1342HAVE_WCSRCHR
1343HAVE_WCSCHR
1344HAVE_WCSDUP
1345HAVE_WCSXFRM
1346HAVE_WCSCOLL
1347HAVE_WCSNCASECMP
1348HAVE_WCSCASECMP
1349HAVE_WCSNCMP
1350HAVE_WCSCMP
1351HAVE_WCSNCAT
1352HAVE_WCSCAT
1353HAVE_WCPNCPY
1354HAVE_WCSNCPY
1355HAVE_WCPCPY
1356HAVE_WCSCPY
1357HAVE_WCSNLEN
1358HAVE_WCSLEN
1359HAVE_WMEMSET
1360HAVE_WMEMMOVE
1361HAVE_WMEMCPY
1362HAVE_WMEMCMP
1363HAVE_WMEMCHR
1364HAVE_WCSNRTOMBS
1365HAVE_WCSRTOMBS
1366HAVE_WCRTOMB
1367HAVE_MBSNRTOWCS
1368HAVE_MBSRTOWCS
1369HAVE_MBRLEN
1370HAVE_MBRTOWC
1371HAVE_MBSINIT
1372HAVE_BTOWC
1373GNULIB_WCSWIDTH
1374GNULIB_WCSTOK
1375GNULIB_WCSSTR
1376GNULIB_WCSPBRK
1377GNULIB_WCSSPN
1378GNULIB_WCSCSPN
1379GNULIB_WCSRCHR
1380GNULIB_WCSCHR
1381GNULIB_WCSDUP
1382GNULIB_WCSXFRM
1383GNULIB_WCSCOLL
1384GNULIB_WCSNCASECMP
1385GNULIB_WCSCASECMP
1386GNULIB_WCSNCMP
1387GNULIB_WCSCMP
1388GNULIB_WCSNCAT
1389GNULIB_WCSCAT
1390GNULIB_WCPNCPY
1391GNULIB_WCSNCPY
1392GNULIB_WCPCPY
1393GNULIB_WCSCPY
1394GNULIB_WCSNLEN
1395GNULIB_WCSLEN
1396GNULIB_WMEMSET
1397GNULIB_WMEMMOVE
1398GNULIB_WMEMCPY
1399GNULIB_WMEMCMP
1400GNULIB_WMEMCHR
1401GNULIB_WCWIDTH
1402GNULIB_WCSNRTOMBS
1403GNULIB_WCSRTOMBS
1404GNULIB_WCRTOMB
1405GNULIB_MBSNRTOWCS
1406GNULIB_MBSRTOWCS
1407GNULIB_MBRLEN
1408GNULIB_MBRTOWC
1409GNULIB_MBSINIT
1410GNULIB_WCTOB
1411GNULIB_BTOWC
1412GL_GENERATE_ALLOCA_H_FALSE
1413GL_GENERATE_ALLOCA_H_TRUE
1414ALLOCA_H
1415ALLOCA
1416GL_COND_LIBTOOL_FALSE
1417GL_COND_LIBTOOL_TRUE
1418BUILD_EXEEXT
1419BUILD_CC
1420LIBUTIL
1421HELP2MAN
1422POSUB
1423LTLIBINTL
1424LIBINTL
1425INTLLIBS
1426LTLIBICONV
1427LIBICONV
1428INTL_MACOSX_LIBS
1429XGETTEXT_EXTRA_OPTIONS
1430MSGMERGE
1431XGETTEXT_015
1432XGETTEXT
1433GMSGFMT_015
1434MSGFMT_015
1435GMSGFMT
1436MSGFMT
1437GETTEXT_MACRO_VERSION
1438USE_NLS
1439HAVE_CXX
1440am__fastdepCCAS_FALSE
1441am__fastdepCCAS_TRUE
1442CCASDEPMODE
1443CCASFLAGS
1444CCAS
1445am__fastdepCXX_FALSE
1446am__fastdepCXX_TRUE
1447CXXDEPMODE
1448ac_ct_CXX
1449CXXFLAGS
1450CXX
1451ARFLAGS
1452AR
1453EGREP
1454GREP
1455CPP
1456LN_S
1457YFLAGS
1458LEXLIB
1459am__fastdepCC_FALSE
1460am__fastdepCC_TRUE
1461CCDEPMODE
1462am__nodep
1463AMDEPBACKSLASH
1464AMDEP_FALSE
1465AMDEP_TRUE
1466am__quote
1467am__include
1468DEPDIR
1469OBJEXT
1470EXEEXT
1471ac_ct_CC
1472CPPFLAGS
1473LDFLAGS
1474CFLAGS
1475CC
1476LEX_OUTPUT_ROOT
1477LEX
1478RANLIB
1479YACC
1480CMP
1481grubdirname
1482bootdirname
1483platform
1484host_kernel
1485TARGET_DECOMPRESSOR_LINK_ADDR
1486TARGET_LINK_ADDR
1487grub_file
1488grub_render_label
1489grub_sparc64_setup
1490grub_set_default
1491grub_script_check
1492grub_reboot
1493grub_probe
1494grub_mkrescue
1495grub_mkrelpath
1496grub_mkpasswd_pbkdf2
1497grub_mklayout
1498grub_glue_efi
1499grub_mkimage
1500grub_mkfont
1501grub_mkconfig
1502grub_install
1503grub_editenv
1504grub_bios_setup
1505AM_BACKSLASH
1506AM_DEFAULT_VERBOSITY
1507AM_DEFAULT_V
1508AM_V
1509am__untar
1510am__tar
1511AMTAR
1512am__leading_dot
1513SET_MAKE
1514AWK
1515mkdir_p
1516MKDIR_P
1517INSTALL_STRIP_PROGRAM
1518STRIP
1519install_sh
1520MAKEINFO
1521AUTOHEADER
1522AUTOMAKE
1523AUTOCONF
1524ACLOCAL
1525VERSION
1526PACKAGE
1527CYGPATH_W
1528am__isrc
1529INSTALL_DATA
1530INSTALL_SCRIPT
1531INSTALL_PROGRAM
1532target_os
1533target_vendor
1534target_cpu
1535target
1536host_os
1537host_vendor
1538host_cpu
1539host
1540build_os
1541build_vendor
1542build_cpu
1543build
1544target_alias
1545host_alias
1546build_alias
1547LIBS
1548ECHO_T
1549ECHO_N
1550ECHO_C
1551DEFS
1552mandir
1553localedir
1554libdir
1555psdir
1556pdfdir
1557dvidir
1558htmldir
1559infodir
1560docdir
1561oldincludedir
1562includedir
1563runstatedir
1564localstatedir
1565sharedstatedir
1566sysconfdir
1567datadir
1568datarootdir
1569libexecdir
1570sbindir
1571bindir
1572program_transform_name
1573prefix
1574exec_prefix
1575PACKAGE_URL
1576PACKAGE_BUGREPORT
1577PACKAGE_STRING
1578PACKAGE_VERSION
1579PACKAGE_TARNAME
1580PACKAGE_NAME
1581PATH_SEPARATOR
1582SHELL'
1583ac_subst_files=''
1584ac_user_opts='
1585enable_option_checking
1586enable_silent_rules
1587with_platform
1588with_bootdir
1589with_grubdir
1590enable_dependency_tracking
1591enable_nls
1592with_gnu_ld
1593enable_rpath
1594with_libiconv_prefix
1595with_libintl_prefix
1596enable_largefile
1597with_included_regex
1598enable_efiemu
1599enable_mm_debug
1600enable_cache_stats
1601enable_boot_time
1602enable_grub_emu_sdl
1603enable_grub_emu_pci
1604enable_grub_mkfont
1605enable_grub_themes
1606enable_grub_mount
1607enable_device_mapper
1608enable_liblzma
1609enable_libzfs
1610enable_werror
1611'
1612 ac_precious_vars='build_alias
1613host_alias
1614target_alias
1615CC
1616CFLAGS
1617LDFLAGS
1618LIBS
1619CPPFLAGS
1620YACC
1621YFLAGS
1622CPP
1623CXX
1624CXXFLAGS
1625CCC
1626CCAS
1627CCASFLAGS'
1628
1629
1630# Initialize some variables set by options.
1631ac_init_help=
1632ac_init_version=false
1633ac_unrecognized_opts=
1634ac_unrecognized_sep=
1635# The variables have the same names as the options, with
1636# dashes changed to underlines.
1637cache_file=/dev/null
1638exec_prefix=NONE
1639no_create=
1640no_recursion=
1641prefix=NONE
1642program_prefix=NONE
1643program_suffix=NONE
1644program_transform_name=s,x,x,
1645silent=
1646site=
1647srcdir=
1648verbose=
1649x_includes=NONE
1650x_libraries=NONE
1651
1652# Installation directory options.
1653# These are left unexpanded so users can "make install exec_prefix=/foo"
1654# and all the variables that are supposed to be based on exec_prefix
1655# by default will actually change.
1656# Use braces instead of parens because sh, perl, etc. also accept them.
1657# (The list follows the same order as the GNU Coding Standards.)
1658bindir='${exec_prefix}/bin'
1659sbindir='${exec_prefix}/sbin'
1660libexecdir='${exec_prefix}/libexec'
1661datarootdir='${prefix}/share'
1662datadir='${datarootdir}'
1663sysconfdir='${prefix}/etc'
1664sharedstatedir='${prefix}/com'
1665localstatedir='${prefix}/var'
1666runstatedir='${localstatedir}/run'
1667includedir='${prefix}/include'
1668oldincludedir='/usr/include'
1669docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1670infodir='${datarootdir}/info'
1671htmldir='${docdir}'
1672dvidir='${docdir}'
1673pdfdir='${docdir}'
1674psdir='${docdir}'
1675libdir='${exec_prefix}/lib'
1676localedir='${datarootdir}/locale'
1677mandir='${datarootdir}/man'
1678
1679ac_prev=
1680ac_dashdash=
1681for ac_option
1682do
1683 # If the previous option needs an argument, assign it.
1684 if test -n "$ac_prev"; then
1685 eval $ac_prev=\$ac_option
1686 ac_prev=
1687 continue
1688 fi
1689
1690 case $ac_option in
1691 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1692 *=) ac_optarg= ;;
1693 *) ac_optarg=yes ;;
1694 esac
1695
1696 # Accept the important Cygnus configure options, so we can diagnose typos.
1697
1698 case $ac_dashdash$ac_option in
1699 --)
1700 ac_dashdash=yes ;;
1701
1702 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1703 ac_prev=bindir ;;
1704 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1705 bindir=$ac_optarg ;;
1706
1707 -build | --build | --buil | --bui | --bu)
1708 ac_prev=build_alias ;;
1709 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1710 build_alias=$ac_optarg ;;
1711
1712 -cache-file | --cache-file | --cache-fil | --cache-fi \
1713 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1714 ac_prev=cache_file ;;
1715 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1716 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1717 cache_file=$ac_optarg ;;
1718
1719 --config-cache | -C)
1720 cache_file=config.cache ;;
1721
1722 -datadir | --datadir | --datadi | --datad)
1723 ac_prev=datadir ;;
1724 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1725 datadir=$ac_optarg ;;
1726
1727 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1728 | --dataroo | --dataro | --datar)
1729 ac_prev=datarootdir ;;
1730 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1731 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1732 datarootdir=$ac_optarg ;;
1733
1734 -disable-* | --disable-*)
1735 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1736 # Reject names that are not valid shell variable names.
1737 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1738 as_fn_error $? "invalid feature name: $ac_useropt"
1739 ac_useropt_orig=$ac_useropt
1740 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1741 case $ac_user_opts in
1742 *"
1743"enable_$ac_useropt"
1744"*) ;;
1745 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1746 ac_unrecognized_sep=', ';;
1747 esac
1748 eval enable_$ac_useropt=no ;;
1749
1750 -docdir | --docdir | --docdi | --doc | --do)
1751 ac_prev=docdir ;;
1752 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1753 docdir=$ac_optarg ;;
1754
1755 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1756 ac_prev=dvidir ;;
1757 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1758 dvidir=$ac_optarg ;;
1759
1760 -enable-* | --enable-*)
1761 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1762 # Reject names that are not valid shell variable names.
1763 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1764 as_fn_error $? "invalid feature name: $ac_useropt"
1765 ac_useropt_orig=$ac_useropt
1766 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1767 case $ac_user_opts in
1768 *"
1769"enable_$ac_useropt"
1770"*) ;;
1771 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1772 ac_unrecognized_sep=', ';;
1773 esac
1774 eval enable_$ac_useropt=\$ac_optarg ;;
1775
1776 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1777 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1778 | --exec | --exe | --ex)
1779 ac_prev=exec_prefix ;;
1780 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1781 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1782 | --exec=* | --exe=* | --ex=*)
1783 exec_prefix=$ac_optarg ;;
1784
1785 -gas | --gas | --ga | --g)
1786 # Obsolete; use --with-gas.
1787 with_gas=yes ;;
1788
1789 -help | --help | --hel | --he | -h)
1790 ac_init_help=long ;;
1791 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1792 ac_init_help=recursive ;;
1793 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1794 ac_init_help=short ;;
1795
1796 -host | --host | --hos | --ho)
1797 ac_prev=host_alias ;;
1798 -host=* | --host=* | --hos=* | --ho=*)
1799 host_alias=$ac_optarg ;;
1800
1801 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1802 ac_prev=htmldir ;;
1803 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1804 | --ht=*)
1805 htmldir=$ac_optarg ;;
1806
1807 -includedir | --includedir | --includedi | --included | --include \
1808 | --includ | --inclu | --incl | --inc)
1809 ac_prev=includedir ;;
1810 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1811 | --includ=* | --inclu=* | --incl=* | --inc=*)
1812 includedir=$ac_optarg ;;
1813
1814 -infodir | --infodir | --infodi | --infod | --info | --inf)
1815 ac_prev=infodir ;;
1816 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1817 infodir=$ac_optarg ;;
1818
1819 -libdir | --libdir | --libdi | --libd)
1820 ac_prev=libdir ;;
1821 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1822 libdir=$ac_optarg ;;
1823
1824 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1825 | --libexe | --libex | --libe)
1826 ac_prev=libexecdir ;;
1827 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1828 | --libexe=* | --libex=* | --libe=*)
1829 libexecdir=$ac_optarg ;;
1830
1831 -localedir | --localedir | --localedi | --localed | --locale)
1832 ac_prev=localedir ;;
1833 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1834 localedir=$ac_optarg ;;
1835
1836 -localstatedir | --localstatedir | --localstatedi | --localstated \
1837 | --localstate | --localstat | --localsta | --localst | --locals)
1838 ac_prev=localstatedir ;;
1839 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1840 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1841 localstatedir=$ac_optarg ;;
1842
1843 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1844 ac_prev=mandir ;;
1845 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1846 mandir=$ac_optarg ;;
1847
1848 -nfp | --nfp | --nf)
1849 # Obsolete; use --without-fp.
1850 with_fp=no ;;
1851
1852 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1853 | --no-cr | --no-c | -n)
1854 no_create=yes ;;
1855
1856 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1857 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1858 no_recursion=yes ;;
1859
1860 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1861 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1862 | --oldin | --oldi | --old | --ol | --o)
1863 ac_prev=oldincludedir ;;
1864 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1865 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1866 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1867 oldincludedir=$ac_optarg ;;
1868
1869 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1870 ac_prev=prefix ;;
1871 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1872 prefix=$ac_optarg ;;
1873
1874 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1875 | --program-pre | --program-pr | --program-p)
1876 ac_prev=program_prefix ;;
1877 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1878 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1879 program_prefix=$ac_optarg ;;
1880
1881 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1882 | --program-suf | --program-su | --program-s)
1883 ac_prev=program_suffix ;;
1884 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1885 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1886 program_suffix=$ac_optarg ;;
1887
1888 -program-transform-name | --program-transform-name \
1889 | --program-transform-nam | --program-transform-na \
1890 | --program-transform-n | --program-transform- \
1891 | --program-transform | --program-transfor \
1892 | --program-transfo | --program-transf \
1893 | --program-trans | --program-tran \
1894 | --progr-tra | --program-tr | --program-t)
1895 ac_prev=program_transform_name ;;
1896 -program-transform-name=* | --program-transform-name=* \
1897 | --program-transform-nam=* | --program-transform-na=* \
1898 | --program-transform-n=* | --program-transform-=* \
1899 | --program-transform=* | --program-transfor=* \
1900 | --program-transfo=* | --program-transf=* \
1901 | --program-trans=* | --program-tran=* \
1902 | --progr-tra=* | --program-tr=* | --program-t=*)
1903 program_transform_name=$ac_optarg ;;
1904
1905 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1906 ac_prev=pdfdir ;;
1907 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1908 pdfdir=$ac_optarg ;;
1909
1910 -psdir | --psdir | --psdi | --psd | --ps)
1911 ac_prev=psdir ;;
1912 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1913 psdir=$ac_optarg ;;
1914
1915 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1916 | -silent | --silent | --silen | --sile | --sil)
1917 silent=yes ;;
1918
1919 -runstatedir | --runstatedir | --runstatedi | --runstated \
1920 | --runstate | --runstat | --runsta | --runst | --runs \
1921 | --run | --ru | --r)
1922 ac_prev=runstatedir ;;
1923 -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
1924 | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
1925 | --run=* | --ru=* | --r=*)
1926 runstatedir=$ac_optarg ;;
1927
1928 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1929 ac_prev=sbindir ;;
1930 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1931 | --sbi=* | --sb=*)
1932 sbindir=$ac_optarg ;;
1933
1934 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1935 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1936 | --sharedst | --shareds | --shared | --share | --shar \
1937 | --sha | --sh)
1938 ac_prev=sharedstatedir ;;
1939 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1940 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1941 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1942 | --sha=* | --sh=*)
1943 sharedstatedir=$ac_optarg ;;
1944
1945 -site | --site | --sit)
1946 ac_prev=site ;;
1947 -site=* | --site=* | --sit=*)
1948 site=$ac_optarg ;;
1949
1950 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1951 ac_prev=srcdir ;;
1952 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1953 srcdir=$ac_optarg ;;
1954
1955 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1956 | --syscon | --sysco | --sysc | --sys | --sy)
1957 ac_prev=sysconfdir ;;
1958 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1959 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1960 sysconfdir=$ac_optarg ;;
1961
1962 -target | --target | --targe | --targ | --tar | --ta | --t)
1963 ac_prev=target_alias ;;
1964 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1965 target_alias=$ac_optarg ;;
1966
1967 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1968 verbose=yes ;;
1969
1970 -version | --version | --versio | --versi | --vers | -V)
1971 ac_init_version=: ;;
1972
1973 -with-* | --with-*)
1974 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1975 # Reject names that are not valid shell variable names.
1976 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1977 as_fn_error $? "invalid package name: $ac_useropt"
1978 ac_useropt_orig=$ac_useropt
1979 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1980 case $ac_user_opts in
1981 *"
1982"with_$ac_useropt"
1983"*) ;;
1984 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1985 ac_unrecognized_sep=', ';;
1986 esac
1987 eval with_$ac_useropt=\$ac_optarg ;;
1988
1989 -without-* | --without-*)
1990 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1991 # Reject names that are not valid shell variable names.
1992 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1993 as_fn_error $? "invalid package name: $ac_useropt"
1994 ac_useropt_orig=$ac_useropt
1995 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1996 case $ac_user_opts in
1997 *"
1998"with_$ac_useropt"
1999"*) ;;
2000 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
2001 ac_unrecognized_sep=', ';;
2002 esac
2003 eval with_$ac_useropt=no ;;
2004
2005 --x)
2006 # Obsolete; use --with-x.
2007 with_x=yes ;;
2008
2009 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
2010 | --x-incl | --x-inc | --x-in | --x-i)
2011 ac_prev=x_includes ;;
2012 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
2013 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
2014 x_includes=$ac_optarg ;;
2015
2016 -x-libraries | --x-libraries | --x-librarie | --x-librari \
2017 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
2018 ac_prev=x_libraries ;;
2019 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
2020 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
2021 x_libraries=$ac_optarg ;;
2022
2023 -*) as_fn_error $? "unrecognized option: \`$ac_option'
2024Try \`$0 --help' for more information"
2025 ;;
2026
2027 *=*)
2028 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
2029 # Reject names that are not valid shell variable names.
2030 case $ac_envvar in #(
2031 '' | [0-9]* | *[!_$as_cr_alnum]* )
2032 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
2033 esac
2034 eval $ac_envvar=\$ac_optarg
2035 export $ac_envvar ;;
2036
2037 *)
2038 # FIXME: should be removed in autoconf 3.0.
2039 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
2040 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
2041 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
2042 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
2043 ;;
2044
2045 esac
2046done
2047
2048if test -n "$ac_prev"; then
2049 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
2050 as_fn_error $? "missing argument to $ac_option"
2051fi
2052
2053if test -n "$ac_unrecognized_opts"; then
2054 case $enable_option_checking in
2055 no) ;;
2056 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
2057 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
2058 esac
2059fi
2060
2061# Check all directory arguments for consistency.
2062for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
2063 datadir sysconfdir sharedstatedir localstatedir includedir \
2064 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
2065 libdir localedir mandir runstatedir
2066do
2067 eval ac_val=\$$ac_var
2068 # Remove trailing slashes.
2069 case $ac_val in
2070 */ )
2071 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
2072 eval $ac_var=\$ac_val;;
2073 esac
2074 # Be sure to have absolute directory names.
2075 case $ac_val in
2076 [\\/$]* | ?:[\\/]* ) continue;;
2077 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
2078 esac
2079 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
2080done
2081
2082# There might be people who depend on the old broken behavior: `$host'
2083# used to hold the argument of --host etc.
2084# FIXME: To remove some day.
2085build=$build_alias
2086host=$host_alias
2087target=$target_alias
2088
2089# FIXME: To remove some day.
2090if test "x$host_alias" != x; then
2091 if test "x$build_alias" = x; then
2092 cross_compiling=maybe
2093 elif test "x$build_alias" != "x$host_alias"; then
2094 cross_compiling=yes
2095 fi
2096fi
2097
2098ac_tool_prefix=
2099test -n "$host_alias" && ac_tool_prefix=$host_alias-
2100
2101test "$silent" = yes && exec 6>/dev/null
2102
2103
2104ac_pwd=`pwd` && test -n "$ac_pwd" &&
2105ac_ls_di=`ls -di .` &&
2106ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
2107 as_fn_error $? "working directory cannot be determined"
2108test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
2109 as_fn_error $? "pwd does not report name of working directory"
2110
2111
2112# Find the source files, if location was not specified.
2113if test -z "$srcdir"; then
2114 ac_srcdir_defaulted=yes
2115 # Try the directory containing this script, then the parent directory.
2116 ac_confdir=`$as_dirname -- "$as_myself" ||
2117$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
2118 X"$as_myself" : 'X\(//\)[^/]' \| \
2119 X"$as_myself" : 'X\(//\)$' \| \
2120 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
2121$as_echo X"$as_myself" |
2122 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
2123 s//\1/
2124 q
2125 }
2126 /^X\(\/\/\)[^/].*/{
2127 s//\1/
2128 q
2129 }
2130 /^X\(\/\/\)$/{
2131 s//\1/
2132 q
2133 }
2134 /^X\(\/\).*/{
2135 s//\1/
2136 q
2137 }
2138 s/.*/./; q'`
2139 srcdir=$ac_confdir
2140 if test ! -r "$srcdir/$ac_unique_file"; then
2141 srcdir=..
2142 fi
2143else
2144 ac_srcdir_defaulted=no
2145fi
2146if test ! -r "$srcdir/$ac_unique_file"; then
2147 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
2148 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
2149fi
2150ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
2151ac_abs_confdir=`(
2152 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
2153 pwd)`
2154# When building in place, set srcdir=.
2155if test "$ac_abs_confdir" = "$ac_pwd"; then
2156 srcdir=.
2157fi
2158# Remove unnecessary trailing slashes from srcdir.
2159# Double slashes in file names in object file debugging info
2160# mess up M-x gdb in Emacs.
2161case $srcdir in
2162*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
2163esac
2164for ac_var in $ac_precious_vars; do
2165 eval ac_env_${ac_var}_set=\${${ac_var}+set}
2166 eval ac_env_${ac_var}_value=\$${ac_var}
2167 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
2168 eval ac_cv_env_${ac_var}_value=\$${ac_var}
2169done
2170
2171#
2172# Report the --help message.
2173#
2174if test "$ac_init_help" = "long"; then
2175 # Omit some internal or obsolete options to make the list less imposing.
2176 # This message is too long to be a string in the A/UX 3.1 sh.
2177 cat <<_ACEOF
2178\`configure' configures GRUB 2.02 to adapt to many kinds of systems.
2179
2180Usage: $0 [OPTION]... [VAR=VALUE]...
2181
2182To assign environment variables (e.g., CC, CFLAGS...), specify them as
2183VAR=VALUE. See below for descriptions of some of the useful variables.
2184
2185Defaults for the options are specified in brackets.
2186
2187Configuration:
2188 -h, --help display this help and exit
2189 --help=short display options specific to this package
2190 --help=recursive display the short help of all the included packages
2191 -V, --version display version information and exit
2192 -q, --quiet, --silent do not print \`checking ...' messages
2193 --cache-file=FILE cache test results in FILE [disabled]
2194 -C, --config-cache alias for \`--cache-file=config.cache'
2195 -n, --no-create do not create output files
2196 --srcdir=DIR find the sources in DIR [configure dir or \`..']
2197
2198Installation directories:
2199 --prefix=PREFIX install architecture-independent files in PREFIX
2200 [$ac_default_prefix]
2201 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
2202 [PREFIX]
2203
2204By default, \`make install' will install all the files in
2205\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
2206an installation prefix other than \`$ac_default_prefix' using \`--prefix',
2207for instance \`--prefix=\$HOME'.
2208
2209For better control, use the options below.
2210
2211Fine tuning of the installation directories:
2212 --bindir=DIR user executables [EPREFIX/bin]
2213 --sbindir=DIR system admin executables [EPREFIX/sbin]
2214 --libexecdir=DIR program executables [EPREFIX/libexec]
2215 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
2216 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
2217 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
2218 --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run]
2219 --libdir=DIR object code libraries [EPREFIX/lib]
2220 --includedir=DIR C header files [PREFIX/include]
2221 --oldincludedir=DIR C header files for non-gcc [/usr/include]
2222 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
2223 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
2224 --infodir=DIR info documentation [DATAROOTDIR/info]
2225 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
2226 --mandir=DIR man documentation [DATAROOTDIR/man]
2227 --docdir=DIR documentation root [DATAROOTDIR/doc/grub]
2228 --htmldir=DIR html documentation [DOCDIR]
2229 --dvidir=DIR dvi documentation [DOCDIR]
2230 --pdfdir=DIR pdf documentation [DOCDIR]
2231 --psdir=DIR ps documentation [DOCDIR]
2232_ACEOF
2233
2234 cat <<\_ACEOF
2235
2236Program names:
2237 --program-prefix=PREFIX prepend PREFIX to installed program names
2238 --program-suffix=SUFFIX append SUFFIX to installed program names
2239 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
2240
2241System types:
2242 --build=BUILD configure for building on BUILD [guessed]
2243 --host=HOST cross-compile to build programs to run on HOST [BUILD]
2244 --target=TARGET configure for building compilers for TARGET [HOST]
2245_ACEOF
2246fi
2247
2248if test -n "$ac_init_help"; then
2249 case $ac_init_help in
2250 short | recursive ) echo "Configuration of GRUB 2.02:";;
2251 esac
2252 cat <<\_ACEOF
2253
2254Optional Features:
2255 --disable-option-checking ignore unrecognized --enable/--with options
2256 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
2257 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
2258 --enable-silent-rules less verbose build output (undo: "make V=1")
2259 --disable-silent-rules verbose build output (undo: "make V=0")
2260 --enable-dependency-tracking
2261 do not reject slow dependency extractors
2262 --disable-dependency-tracking
2263 speeds up one-time build
2264 --disable-nls do not use Native Language Support
2265 --disable-rpath do not hardcode runtime library paths
2266 --disable-largefile omit support for large files
2267 --enable-efiemu build and install the efiemu runtimes
2268 (default=guessed)
2269 --enable-mm-debug include memory manager debugging
2270 --enable-cache-stats enable disk cache statistics collection
2271 --enable-boot-time enable boot time statistics collection
2272 --enable-grub-emu-sdl build and install the `grub-emu' debugging utility
2273 with SDL support (default=guessed)
2274 --enable-grub-emu-pci build and install the `grub-emu' debugging utility
2275 with PCI support (potentially dangerous)
2276 (default=no)
2277 --enable-grub-mkfont build and install the `grub-mkfont' utility
2278 (default=guessed)
2279 --enable-grub-themes build and install GRUB themes (default=guessed)
2280 --enable-grub-mount build and install the `grub-mount' utility
2281 (default=guessed)
2282 --enable-device-mapper enable Linux device-mapper support (default=guessed)
2283 --enable-liblzma enable liblzma integration (default=guessed)
2284 --enable-libzfs enable libzfs integration (default=guessed)
2285 --disable-werror do not use -Werror when building GRUB
2286
2287Optional Packages:
2288 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
2289 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
2290 --with-platform=PLATFORM
2291 select the host platform [[guessed]]
2292 --with-bootdir=DIR set the name of /boot directory [[guessed]]
2293 --with-grubdir=DIR set the name of grub directory [[guessed]]
2294 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
2295 --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
2296 --without-libiconv-prefix don't search for libiconv in includedir and libdir
2297 --with-libintl-prefix[=DIR] search for libintl in DIR/include and DIR/lib
2298 --without-libintl-prefix don't search for libintl in includedir and libdir
2299 --without-included-regex
2300 don't compile regex; this is the default on systems
2301 with recent-enough versions of the GNU C Library
2302 (use with caution on other systems).
2303
2304Some influential environment variables:
2305 CC C compiler command
2306 CFLAGS C compiler flags
2307 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2308 nonstandard directory <lib dir>
2309 LIBS libraries to pass to the linker, e.g. -l<library>
2310 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2311 you have headers in a nonstandard directory <include dir>
2312 YACC The `Yet Another Compiler Compiler' implementation to use.
2313 Defaults to the first program found out of: `bison -y', `byacc',
2314 `yacc'.
2315 YFLAGS The list of arguments that will be passed by default to $YACC.
2316 This script will default YFLAGS to the empty string to avoid a
2317 default value of `-d' given by some make applications.
2318 CPP C preprocessor
2319 CXX C++ compiler command
2320 CXXFLAGS C++ compiler flags
2321 CCAS assembler compiler command (defaults to CC)
2322 CCASFLAGS assembler compiler flags (defaults to CFLAGS)
2323
2324Use these variables to override the choices made by `configure' or to help
2325it to find libraries and programs with nonstandard names/locations.
2326
2327Report bugs to <bug-grub@gnu.org>.
2328_ACEOF
2329ac_status=$?
2330fi
2331
2332if test "$ac_init_help" = "recursive"; then
2333 # If there are subdirs, report their specific --help.
2334 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2335 test -d "$ac_dir" ||
2336 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2337 continue
2338 ac_builddir=.
2339
2340case "$ac_dir" in
2341.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2342*)
2343 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2344 # A ".." for each directory in $ac_dir_suffix.
2345 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2346 case $ac_top_builddir_sub in
2347 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2348 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2349 esac ;;
2350esac
2351ac_abs_top_builddir=$ac_pwd
2352ac_abs_builddir=$ac_pwd$ac_dir_suffix
2353# for backward compatibility:
2354ac_top_builddir=$ac_top_build_prefix
2355
2356case $srcdir in
2357 .) # We are building in place.
2358 ac_srcdir=.
2359 ac_top_srcdir=$ac_top_builddir_sub
2360 ac_abs_top_srcdir=$ac_pwd ;;
2361 [\\/]* | ?:[\\/]* ) # Absolute name.
2362 ac_srcdir=$srcdir$ac_dir_suffix;
2363 ac_top_srcdir=$srcdir
2364 ac_abs_top_srcdir=$srcdir ;;
2365 *) # Relative name.
2366 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2367 ac_top_srcdir=$ac_top_build_prefix$srcdir
2368 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2369esac
2370ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2371
2372 cd "$ac_dir" || { ac_status=$?; continue; }
2373 # Check for guested configure.
2374 if test -f "$ac_srcdir/configure.gnu"; then
2375 echo &&
2376 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2377 elif test -f "$ac_srcdir/configure"; then
2378 echo &&
2379 $SHELL "$ac_srcdir/configure" --help=recursive
2380 else
2381 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2382 fi || ac_status=$?
2383 cd "$ac_pwd" || { ac_status=$?; break; }
2384 done
2385fi
2386
2387test -n "$ac_init_help" && exit $ac_status
2388if $ac_init_version; then
2389 cat <<\_ACEOF
2390GRUB configure 2.02
2391generated by GNU Autoconf 2.69
2392
2393Copyright (C) 2012 Free Software Foundation, Inc.
2394This configure script is free software; the Free Software Foundation
2395gives unlimited permission to copy, distribute and modify it.
2396_ACEOF
2397 exit
2398fi
2399
2400## ------------------------ ##
2401## Autoconf initialization. ##
2402## ------------------------ ##
2403
2404# ac_fn_c_try_compile LINENO
2405# --------------------------
2406# Try to compile conftest.$ac_ext, and return whether this succeeded.
2407ac_fn_c_try_compile ()
2408{
2409 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2410 rm -f conftest.$ac_objext
2411 if { { ac_try="$ac_compile"
2412case "(($ac_try" in
2413 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2414 *) ac_try_echo=$ac_try;;
2415esac
2416eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2417$as_echo "$ac_try_echo"; } >&5
2418 (eval "$ac_compile") 2>conftest.err
2419 ac_status=$?
2420 if test -s conftest.err; then
2421 grep -v '^ *+' conftest.err >conftest.er1
2422 cat conftest.er1 >&5
2423 mv -f conftest.er1 conftest.err
2424 fi
2425 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2426 test $ac_status = 0; } && {
2427 test -z "$ac_c_werror_flag" ||
2428 test ! -s conftest.err
2429 } && test -s conftest.$ac_objext; then :
2430 ac_retval=0
2431else
2432 $as_echo "$as_me: failed program was:" >&5
2433sed 's/^/| /' conftest.$ac_ext >&5
2434
2435 ac_retval=1
2436fi
2437 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2438 as_fn_set_status $ac_retval
2439
2440} # ac_fn_c_try_compile
2441
2442# ac_fn_c_try_link LINENO
2443# -----------------------
2444# Try to link conftest.$ac_ext, and return whether this succeeded.
2445ac_fn_c_try_link ()
2446{
2447 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2448 rm -f conftest.$ac_objext conftest$ac_exeext
2449 if { { ac_try="$ac_link"
2450case "(($ac_try" in
2451 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2452 *) ac_try_echo=$ac_try;;
2453esac
2454eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2455$as_echo "$ac_try_echo"; } >&5
2456 (eval "$ac_link") 2>conftest.err
2457 ac_status=$?
2458 if test -s conftest.err; then
2459 grep -v '^ *+' conftest.err >conftest.er1
2460 cat conftest.er1 >&5
2461 mv -f conftest.er1 conftest.err
2462 fi
2463 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2464 test $ac_status = 0; } && {
2465 test -z "$ac_c_werror_flag" ||
2466 test ! -s conftest.err
2467 } && test -s conftest$ac_exeext && {
2468 test "$cross_compiling" = yes ||
2469 test -x conftest$ac_exeext
2470 }; then :
2471 ac_retval=0
2472else
2473 $as_echo "$as_me: failed program was:" >&5
2474sed 's/^/| /' conftest.$ac_ext >&5
2475
2476 ac_retval=1
2477fi
2478 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2479 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2480 # interfere with the next link command; also delete a directory that is
2481 # left behind by Apple's compiler. We do this before executing the actions.
2482 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2483 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2484 as_fn_set_status $ac_retval
2485
2486} # ac_fn_c_try_link
2487
2488# ac_fn_c_try_cpp LINENO
2489# ----------------------
2490# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2491ac_fn_c_try_cpp ()
2492{
2493 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2494 if { { ac_try="$ac_cpp conftest.$ac_ext"
2495case "(($ac_try" in
2496 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2497 *) ac_try_echo=$ac_try;;
2498esac
2499eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2500$as_echo "$ac_try_echo"; } >&5
2501 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2502 ac_status=$?
2503 if test -s conftest.err; then
2504 grep -v '^ *+' conftest.err >conftest.er1
2505 cat conftest.er1 >&5
2506 mv -f conftest.er1 conftest.err
2507 fi
2508 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2509 test $ac_status = 0; } > conftest.i && {
2510 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2511 test ! -s conftest.err
2512 }; then :
2513 ac_retval=0
2514else
2515 $as_echo "$as_me: failed program was:" >&5
2516sed 's/^/| /' conftest.$ac_ext >&5
2517
2518 ac_retval=1
2519fi
2520 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2521 as_fn_set_status $ac_retval
2522
2523} # ac_fn_c_try_cpp
2524
2525# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2526# -------------------------------------------------------
2527# Tests whether HEADER exists, giving a warning if it cannot be compiled using
2528# the include files in INCLUDES and setting the cache variable VAR
2529# accordingly.
2530ac_fn_c_check_header_mongrel ()
2531{
2532 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2533 if eval \${$3+:} false; then :
2534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2535$as_echo_n "checking for $2... " >&6; }
2536if eval \${$3+:} false; then :
2537 $as_echo_n "(cached) " >&6
2538fi
2539eval ac_res=\$$3
2540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2541$as_echo "$ac_res" >&6; }
2542else
2543 # Is the header compilable?
2544{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2545$as_echo_n "checking $2 usability... " >&6; }
2546cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2547/* end confdefs.h. */
2548$4
2549#include <$2>
2550_ACEOF
2551if ac_fn_c_try_compile "$LINENO"; then :
2552 ac_header_compiler=yes
2553else
2554 ac_header_compiler=no
2555fi
2556rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2557{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2558$as_echo "$ac_header_compiler" >&6; }
2559
2560# Is the header present?
2561{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2562$as_echo_n "checking $2 presence... " >&6; }
2563cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2564/* end confdefs.h. */
2565#include <$2>
2566_ACEOF
2567if ac_fn_c_try_cpp "$LINENO"; then :
2568 ac_header_preproc=yes
2569else
2570 ac_header_preproc=no
2571fi
2572rm -f conftest.err conftest.i conftest.$ac_ext
2573{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2574$as_echo "$ac_header_preproc" >&6; }
2575
2576# So? What about this header?
2577case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2578 yes:no: )
2579 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2580$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2581 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2582$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2583 ;;
2584 no:yes:* )
2585 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2586$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2587 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2588$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2589 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2590$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2591 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2592$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2593 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2594$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2595( $as_echo "## ------------------------------- ##
2596## Report this to bug-grub@gnu.org ##
2597## ------------------------------- ##"
2598 ) | sed "s/^/$as_me: WARNING: /" >&2
2599 ;;
2600esac
2601 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2602$as_echo_n "checking for $2... " >&6; }
2603if eval \${$3+:} false; then :
2604 $as_echo_n "(cached) " >&6
2605else
2606 eval "$3=\$ac_header_compiler"
2607fi
2608eval ac_res=\$$3
2609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2610$as_echo "$ac_res" >&6; }
2611fi
2612 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2613
2614} # ac_fn_c_check_header_mongrel
2615
2616# ac_fn_c_try_run LINENO
2617# ----------------------
2618# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2619# that executables *can* be run.
2620ac_fn_c_try_run ()
2621{
2622 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2623 if { { ac_try="$ac_link"
2624case "(($ac_try" in
2625 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2626 *) ac_try_echo=$ac_try;;
2627esac
2628eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2629$as_echo "$ac_try_echo"; } >&5
2630 (eval "$ac_link") 2>&5
2631 ac_status=$?
2632 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2633 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2634 { { case "(($ac_try" in
2635 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2636 *) ac_try_echo=$ac_try;;
2637esac
2638eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2639$as_echo "$ac_try_echo"; } >&5
2640 (eval "$ac_try") 2>&5
2641 ac_status=$?
2642 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2643 test $ac_status = 0; }; }; then :
2644 ac_retval=0
2645else
2646 $as_echo "$as_me: program exited with status $ac_status" >&5
2647 $as_echo "$as_me: failed program was:" >&5
2648sed 's/^/| /' conftest.$ac_ext >&5
2649
2650 ac_retval=$ac_status
2651fi
2652 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2653 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2654 as_fn_set_status $ac_retval
2655
2656} # ac_fn_c_try_run
2657
2658# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2659# -------------------------------------------------------
2660# Tests whether HEADER exists and can be compiled using the include files in
2661# INCLUDES, setting the cache variable VAR accordingly.
2662ac_fn_c_check_header_compile ()
2663{
2664 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2665 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2666$as_echo_n "checking for $2... " >&6; }
2667if eval \${$3+:} false; then :
2668 $as_echo_n "(cached) " >&6
2669else
2670 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2671/* end confdefs.h. */
2672$4
2673#include <$2>
2674_ACEOF
2675if ac_fn_c_try_compile "$LINENO"; then :
2676 eval "$3=yes"
2677else
2678 eval "$3=no"
2679fi
2680rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2681fi
2682eval ac_res=\$$3
2683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2684$as_echo "$ac_res" >&6; }
2685 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2686
2687} # ac_fn_c_check_header_compile
2688
2689# ac_fn_cxx_try_compile LINENO
2690# ----------------------------
2691# Try to compile conftest.$ac_ext, and return whether this succeeded.
2692ac_fn_cxx_try_compile ()
2693{
2694 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2695 rm -f conftest.$ac_objext
2696 if { { ac_try="$ac_compile"
2697case "(($ac_try" in
2698 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2699 *) ac_try_echo=$ac_try;;
2700esac
2701eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2702$as_echo "$ac_try_echo"; } >&5
2703 (eval "$ac_compile") 2>conftest.err
2704 ac_status=$?
2705 if test -s conftest.err; then
2706 grep -v '^ *+' conftest.err >conftest.er1
2707 cat conftest.er1 >&5
2708 mv -f conftest.er1 conftest.err
2709 fi
2710 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2711 test $ac_status = 0; } && {
2712 test -z "$ac_cxx_werror_flag" ||
2713 test ! -s conftest.err
2714 } && test -s conftest.$ac_objext; then :
2715 ac_retval=0
2716else
2717 $as_echo "$as_me: failed program was:" >&5
2718sed 's/^/| /' conftest.$ac_ext >&5
2719
2720 ac_retval=1
2721fi
2722 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2723 as_fn_set_status $ac_retval
2724
2725} # ac_fn_cxx_try_compile
2726
2727# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2728# --------------------------------------------
2729# Tries to find the compile-time value of EXPR in a program that includes
2730# INCLUDES, setting VAR accordingly. Returns whether the value could be
2731# computed
2732ac_fn_c_compute_int ()
2733{
2734 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2735 if test "$cross_compiling" = yes; then
2736 # Depending upon the size, compute the lo and hi bounds.
2737cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2738/* end confdefs.h. */
2739$4
2740int
2741main (void)
2742{
2743static int test_array [1 - 2 * !(($2) >= 0)];
2744test_array [0] = 0;
2745return test_array [0];
2746
2747 ;
2748 return 0;
2749}
2750_ACEOF
2751if ac_fn_c_try_compile "$LINENO"; then :
2752 ac_lo=0 ac_mid=0
2753 while :; do
2754 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2755/* end confdefs.h. */
2756$4
2757int
2758main (void)
2759{
2760static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2761test_array [0] = 0;
2762return test_array [0];
2763
2764 ;
2765 return 0;
2766}
2767_ACEOF
2768if ac_fn_c_try_compile "$LINENO"; then :
2769 ac_hi=$ac_mid; break
2770else
2771 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2772 if test $ac_lo -le $ac_mid; then
2773 ac_lo= ac_hi=
2774 break
2775 fi
2776 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2777fi
2778rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2779 done
2780else
2781 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2782/* end confdefs.h. */
2783$4
2784int
2785main (void)
2786{
2787static int test_array [1 - 2 * !(($2) < 0)];
2788test_array [0] = 0;
2789return test_array [0];
2790
2791 ;
2792 return 0;
2793}
2794_ACEOF
2795if ac_fn_c_try_compile "$LINENO"; then :
2796 ac_hi=-1 ac_mid=-1
2797 while :; do
2798 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2799/* end confdefs.h. */
2800$4
2801int
2802main (void)
2803{
2804static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2805test_array [0] = 0;
2806return test_array [0];
2807
2808 ;
2809 return 0;
2810}
2811_ACEOF
2812if ac_fn_c_try_compile "$LINENO"; then :
2813 ac_lo=$ac_mid; break
2814else
2815 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2816 if test $ac_mid -le $ac_hi; then
2817 ac_lo= ac_hi=
2818 break
2819 fi
2820 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2821fi
2822rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2823 done
2824else
2825 ac_lo= ac_hi=
2826fi
2827rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2828fi
2829rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2830# Binary search between lo and hi bounds.
2831while test "x$ac_lo" != "x$ac_hi"; do
2832 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2834/* end confdefs.h. */
2835$4
2836int
2837main (void)
2838{
2839static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2840test_array [0] = 0;
2841return test_array [0];
2842
2843 ;
2844 return 0;
2845}
2846_ACEOF
2847if ac_fn_c_try_compile "$LINENO"; then :
2848 ac_hi=$ac_mid
2849else
2850 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2851fi
2852rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2853done
2854case $ac_lo in #((
2855?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2856'') ac_retval=1 ;;
2857esac
2858 else
2859 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2860/* end confdefs.h. */
2861$4
2862static long int longval () { return $2; }
2863static unsigned long int ulongval () { return $2; }
2864#include <stdio.h>
2865#include <stdlib.h>
2866int
2867main (void)
2868{
2869
2870 FILE *f = fopen ("conftest.val", "w");
2871 if (! f)
2872 return 1;
2873 if (($2) < 0)
2874 {
2875 long int i = longval ();
2876 if (i != ($2))
2877 return 1;
2878 fprintf (f, "%ld", i);
2879 }
2880 else
2881 {
2882 unsigned long int i = ulongval ();
2883 if (i != ($2))
2884 return 1;
2885 fprintf (f, "%lu", i);
2886 }
2887 /* Do not output a trailing newline, as this causes \r\n confusion
2888 on some platforms. */
2889 return ferror (f) || fclose (f) != 0;
2890
2891 ;
2892 return 0;
2893}
2894_ACEOF
2895if ac_fn_c_try_run "$LINENO"; then :
2896 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2897else
2898 ac_retval=1
2899fi
2900rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2901 conftest.$ac_objext conftest.beam conftest.$ac_ext
2902rm -f conftest.val
2903
2904 fi
2905 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2906 as_fn_set_status $ac_retval
2907
2908} # ac_fn_c_compute_int
2909
2910# ac_fn_c_check_func LINENO FUNC VAR
2911# ----------------------------------
2912# Tests whether FUNC exists, setting the cache variable VAR accordingly
2913ac_fn_c_check_func ()
2914{
2915 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2917$as_echo_n "checking for $2... " >&6; }
2918if eval \${$3+:} false; then :
2919 $as_echo_n "(cached) " >&6
2920else
2921 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2922/* end confdefs.h. */
2923/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2924 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2925#define $2 innocuous_$2
2926
2927/* System header to define __stub macros and hopefully few prototypes,
2928 which can conflict with char $2 (); below.
2929 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2930 <limits.h> exists even on freestanding compilers. */
2931
2932#ifdef __STDC__
2933# include <limits.h>
2934#else
2935# include <assert.h>
2936#endif
2937
2938#undef $2
2939
2940/* Override any GCC internal prototype to avoid an error.
2941 Use char because int might match the return type of a GCC
2942 builtin and then its argument prototype would still apply. */
2943#ifdef __cplusplus
2944extern "C"
2945#endif
2946char $2 ();
2947/* The GNU C library defines this for functions which it implements
2948 to always fail with ENOSYS. Some functions are actually named
2949 something starting with __ and the normal name is an alias. */
2950#if defined __stub_$2 || defined __stub___$2
2951choke me
2952#endif
2953
2954int
2955main (void)
2956{
2957return $2 ();
2958 ;
2959 return 0;
2960}
2961_ACEOF
2962if ac_fn_c_try_link "$LINENO"; then :
2963 eval "$3=yes"
2964else
2965 eval "$3=no"
2966fi
2967rm -f core conftest.err conftest.$ac_objext \
2968 conftest$ac_exeext conftest.$ac_ext
2969fi
2970eval ac_res=\$$3
2971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2972$as_echo "$ac_res" >&6; }
2973 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2974
2975} # ac_fn_c_check_func
2976
2977# ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2978# ----------------------------------------------------
2979# Tries to find if the field MEMBER exists in type AGGR, after including
2980# INCLUDES, setting cache variable VAR accordingly.
2981ac_fn_c_check_member ()
2982{
2983 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2985$as_echo_n "checking for $2.$3... " >&6; }
2986if eval \${$4+:} false; then :
2987 $as_echo_n "(cached) " >&6
2988else
2989 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2990/* end confdefs.h. */
2991$5
2992int
2993main (void)
2994{
2995static $2 ac_aggr;
2996if (ac_aggr.$3)
2997return 0;
2998 ;
2999 return 0;
3000}
3001_ACEOF
3002if ac_fn_c_try_compile "$LINENO"; then :
3003 eval "$4=yes"
3004else
3005 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3006/* end confdefs.h. */
3007$5
3008int
3009main (void)
3010{
3011static $2 ac_aggr;
3012if (sizeof ac_aggr.$3)
3013return 0;
3014 ;
3015 return 0;
3016}
3017_ACEOF
3018if ac_fn_c_try_compile "$LINENO"; then :
3019 eval "$4=yes"
3020else
3021 eval "$4=no"
3022fi
3023rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3024fi
3025rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3026fi
3027eval ac_res=\$$4
3028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
3029$as_echo "$ac_res" >&6; }
3030 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3031
3032} # ac_fn_c_check_member
3033
3034# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
3035# -------------------------------------------
3036# Tests whether TYPE exists after having included INCLUDES, setting cache
3037# variable VAR accordingly.
3038ac_fn_c_check_type ()
3039{
3040 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
3041 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
3042$as_echo_n "checking for $2... " >&6; }
3043if eval \${$3+:} false; then :
3044 $as_echo_n "(cached) " >&6
3045else
3046 eval "$3=no"
3047 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3048/* end confdefs.h. */
3049$4
3050int
3051main (void)
3052{
3053if (sizeof ($2))
3054 return 0;
3055 ;
3056 return 0;
3057}
3058_ACEOF
3059if ac_fn_c_try_compile "$LINENO"; then :
3060 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3061/* end confdefs.h. */
3062$4
3063int
3064main (void)
3065{
3066if (sizeof (($2)))
3067 return 0;
3068 ;
3069 return 0;
3070}
3071_ACEOF
3072if ac_fn_c_try_compile "$LINENO"; then :
3073
3074else
3075 eval "$3=yes"
3076fi
3077rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3078fi
3079rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3080fi
3081eval ac_res=\$$3
3082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
3083$as_echo "$ac_res" >&6; }
3084 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3085
3086} # ac_fn_c_check_type
3087
3088# ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
3089# ---------------------------------------------
3090# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
3091# accordingly.
3092ac_fn_c_check_decl ()
3093{
3094 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
3095 as_decl_name=`echo $2|sed 's/ *(.*//'`
3096 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
3097 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
3098$as_echo_n "checking whether $as_decl_name is declared... " >&6; }
3099if eval \${$3+:} false; then :
3100 $as_echo_n "(cached) " >&6
3101else
3102 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3103/* end confdefs.h. */
3104$4
3105int
3106main (void)
3107{
3108#ifndef $as_decl_name
3109#ifdef __cplusplus
3110 (void) $as_decl_use;
3111#else
3112 (void) $as_decl_name;
3113#endif
3114#endif
3115
3116 ;
3117 return 0;
3118}
3119_ACEOF
3120if ac_fn_c_try_compile "$LINENO"; then :
3121 eval "$3=yes"
3122else
3123 eval "$3=no"
3124fi
3125rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3126fi
3127eval ac_res=\$$3
3128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
3129$as_echo "$ac_res" >&6; }
3130 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3131
3132} # ac_fn_c_check_decl
3133cat >config.log <<_ACEOF
3134This file contains any messages produced by compilers while
3135running configure, to aid debugging if configure makes a mistake.
3136
3137It was created by GRUB $as_me 2.02, which was
3138generated by GNU Autoconf 2.69. Invocation command line was
3139
3140 $ $0 $@
3141
3142_ACEOF
3143exec 5>>config.log
3144{
3145cat <<_ASUNAME
3146## --------- ##
3147## Platform. ##
3148## --------- ##
3149
3150hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
3151uname -m = `(uname -m) 2>/dev/null || echo unknown`
3152uname -r = `(uname -r) 2>/dev/null || echo unknown`
3153uname -s = `(uname -s) 2>/dev/null || echo unknown`
3154uname -v = `(uname -v) 2>/dev/null || echo unknown`
3155
3156/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
3157/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
3158
3159/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
3160/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
3161/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
3162/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
3163/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
3164/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
3165/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
3166
3167_ASUNAME
3168
3169as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3170for as_dir in $PATH
3171do
3172 IFS=$as_save_IFS
3173 test -z "$as_dir" && as_dir=.
3174 $as_echo "PATH: $as_dir"
3175 done
3176IFS=$as_save_IFS
3177
3178} >&5
3179
3180cat >&5 <<_ACEOF
3181
3182
3183## ----------- ##
3184## Core tests. ##
3185## ----------- ##
3186
3187_ACEOF
3188
3189
3190# Keep a trace of the command line.
3191# Strip out --no-create and --no-recursion so they do not pile up.
3192# Strip out --silent because we don't want to record it for future runs.
3193# Also quote any args containing shell meta-characters.
3194# Make two passes to allow for proper duplicate-argument suppression.
3195ac_configure_args=
3196ac_configure_args0=
3197ac_configure_args1=
3198ac_must_keep_next=false
3199for ac_pass in 1 2
3200do
3201 for ac_arg
3202 do
3203 case $ac_arg in
3204 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
3205 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
3206 | -silent | --silent | --silen | --sile | --sil)
3207 continue ;;
3208 *\'*)
3209 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
3210 esac
3211 case $ac_pass in
3212 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
3213 2)
3214 as_fn_append ac_configure_args1 " '$ac_arg'"
3215 if test $ac_must_keep_next = true; then
3216 ac_must_keep_next=false # Got value, back to normal.
3217 else
3218 case $ac_arg in
3219 *=* | --config-cache | -C | -disable-* | --disable-* \
3220 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
3221 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
3222 | -with-* | --with-* | -without-* | --without-* | --x)
3223 case "$ac_configure_args0 " in
3224 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
3225 esac
3226 ;;
3227 -* ) ac_must_keep_next=true ;;
3228 esac
3229 fi
3230 as_fn_append ac_configure_args " '$ac_arg'"
3231 ;;
3232 esac
3233 done
3234done
3235{ ac_configure_args0=; unset ac_configure_args0;}
3236{ ac_configure_args1=; unset ac_configure_args1;}
3237
3238# When interrupted or exit'd, cleanup temporary files, and complete
3239# config.log. We remove comments because anyway the quotes in there
3240# would cause problems or look ugly.
3241# WARNING: Use '\'' to represent an apostrophe within the trap.
3242# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3243trap 'exit_status=$?
3244 # Save into config.log some information that might help in debugging.
3245 {
3246 echo
3247
3248 $as_echo "## ---------------- ##
3249## Cache variables. ##
3250## ---------------- ##"
3251 echo
3252 # The following way of writing the cache mishandles newlines in values,
3253(
3254 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3255 eval ac_val=\$$ac_var
3256 case $ac_val in #(
3257 *${as_nl}*)
3258 case $ac_var in #(
3259 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3260$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3261 esac
3262 case $ac_var in #(
3263 _ | IFS | as_nl) ;; #(
3264 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3265 *) { eval $ac_var=; unset $ac_var;} ;;
3266 esac ;;
3267 esac
3268 done
3269 (set) 2>&1 |
3270 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3271 *${as_nl}ac_space=\ *)
3272 sed -n \
3273 "s/'\''/'\''\\\\'\'''\''/g;
3274 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3275 ;; #(
3276 *)
3277 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3278 ;;
3279 esac |
3280 sort
3281)
3282 echo
3283
3284 $as_echo "## ----------------- ##
3285## Output variables. ##
3286## ----------------- ##"
3287 echo
3288 for ac_var in $ac_subst_vars
3289 do
3290 eval ac_val=\$$ac_var
3291 case $ac_val in
3292 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3293 esac
3294 $as_echo "$ac_var='\''$ac_val'\''"
3295 done | sort
3296 echo
3297
3298 if test -n "$ac_subst_files"; then
3299 $as_echo "## ------------------- ##
3300## File substitutions. ##
3301## ------------------- ##"
3302 echo
3303 for ac_var in $ac_subst_files
3304 do
3305 eval ac_val=\$$ac_var
3306 case $ac_val in
3307 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3308 esac
3309 $as_echo "$ac_var='\''$ac_val'\''"
3310 done | sort
3311 echo
3312 fi
3313
3314 if test -s confdefs.h; then
3315 $as_echo "## ----------- ##
3316## confdefs.h. ##
3317## ----------- ##"
3318 echo
3319 cat confdefs.h
3320 echo
3321 fi
3322 test "$ac_signal" != 0 &&
3323 $as_echo "$as_me: caught signal $ac_signal"
3324 $as_echo "$as_me: exit $exit_status"
3325 } >&5
3326 rm -f core *.core core.conftest.* &&
3327 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3328 exit $exit_status
3329' 0
3330for ac_signal in 1 2 13 15; do
3331 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3332done
3333ac_signal=0
3334
3335# confdefs.h avoids OS command line length limits that DEFS can exceed.
3336rm -f -r conftest* confdefs.h
3337
3338$as_echo "/* confdefs.h */" > confdefs.h
3339
3340# Predefined preprocessor variables.
3341
3342cat >>confdefs.h <<_ACEOF
3343#define PACKAGE_NAME "$PACKAGE_NAME"
3344_ACEOF
3345
3346cat >>confdefs.h <<_ACEOF
3347#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3348_ACEOF
3349
3350cat >>confdefs.h <<_ACEOF
3351#define PACKAGE_VERSION "$PACKAGE_VERSION"
3352_ACEOF
3353
3354cat >>confdefs.h <<_ACEOF
3355#define PACKAGE_STRING "$PACKAGE_STRING"
3356_ACEOF
3357
3358cat >>confdefs.h <<_ACEOF
3359#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3360_ACEOF
3361
3362cat >>confdefs.h <<_ACEOF
3363#define PACKAGE_URL "$PACKAGE_URL"
3364_ACEOF
3365
3366
3367# Let the site file select an alternate cache file if it wants to.
3368# Prefer an explicitly selected file to automatically selected ones.
3369ac_site_file1=NONE
3370ac_site_file2=NONE
3371if test -n "$CONFIG_SITE"; then
3372 # We do not want a PATH search for config.site.
3373 case $CONFIG_SITE in #((
3374 -*) ac_site_file1=./$CONFIG_SITE;;
3375 */*) ac_site_file1=$CONFIG_SITE;;
3376 *) ac_site_file1=./$CONFIG_SITE;;
3377 esac
3378elif test "x$prefix" != xNONE; then
3379 ac_site_file1=$prefix/share/config.site
3380 ac_site_file2=$prefix/etc/config.site
3381else
3382 ac_site_file1=$ac_default_prefix/share/config.site
3383 ac_site_file2=$ac_default_prefix/etc/config.site
3384fi
3385for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3386do
3387 test "x$ac_site_file" = xNONE && continue
3388 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3389 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3390$as_echo "$as_me: loading site script $ac_site_file" >&6;}
3391 sed 's/^/| /' "$ac_site_file" >&5
3392 . "$ac_site_file" \
3393 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3394$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3395as_fn_error $? "failed to load site script $ac_site_file
3396See \`config.log' for more details" "$LINENO" 5; }
3397 fi
3398done
3399
3400if test -r "$cache_file"; then
3401 # Some versions of bash will fail to source /dev/null (special files
3402 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3403 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3404 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3405$as_echo "$as_me: loading cache $cache_file" >&6;}
3406 case $cache_file in
3407 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3408 *) . "./$cache_file";;
3409 esac
3410 fi
3411else
3412 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3413$as_echo "$as_me: creating cache $cache_file" >&6;}
3414 >$cache_file
3415fi
3416
3417gt_needs="$gt_needs "
3418as_fn_append ac_func_list " flockfile"
3419as_fn_append ac_func_list " funlockfile"
3420as_fn_append ac_header_list " features.h"
3421as_fn_append ac_header_list " linewrap.h"
3422as_fn_append ac_func_list " btowc"
3423as_fn_append ac_func_list " isblank"
3424as_fn_append ac_func_list " iswctype"
3425as_fn_append ac_func_list " mbsrtowcs"
3426as_fn_append ac_func_list " mempcpy"
3427as_fn_append ac_func_list " wmemchr"
3428as_fn_append ac_func_list " wmemcpy"
3429as_fn_append ac_func_list " wmempcpy"
3430as_fn_append ac_header_list " wctype.h"
3431as_fn_append ac_func_list " getdelim"
3432gl_getopt_required=GNU
3433as_fn_append ac_header_list " getopt.h"
3434as_fn_append ac_header_list " langinfo.h"
3435as_fn_append ac_header_list " unistd.h"
3436as_fn_append ac_func_list " symlink"
3437as_fn_append ac_header_list " xlocale.h"
3438as_fn_append ac_func_list " mbsinit"
3439as_fn_append ac_func_list " mbrtowc"
3440as_fn_append ac_header_list " wchar.h"
3441as_fn_append ac_func_list " isascii"
3442as_fn_append ac_header_list " sys/mman.h"
3443as_fn_append ac_func_list " mprotect"
3444as_fn_append ac_func_list " _set_invalid_parameter_handler"
3445as_fn_append ac_func_list " nl_langinfo"
3446as_fn_append ac_func_list " wcscoll"
3447as_fn_append ac_func_list " sleep"
3448as_fn_append ac_header_list " stdint.h"
3449as_fn_append ac_header_list " sys/socket.h"
3450as_fn_append ac_header_list " strings.h"
3451as_fn_append ac_func_list " strndup"
3452as_fn_append ac_header_list " sysexits.h"
3453as_fn_append ac_func_list " vasnprintf"
3454as_fn_append ac_func_list " snprintf"
3455as_fn_append ac_func_list " wcrtomb"
3456as_fn_append ac_func_list " iswcntrl"
3457as_fn_append ac_func_list " wcwidth"
3458# Check that the precious variables saved in the cache have kept the same
3459# value.
3460ac_cache_corrupted=false
3461for ac_var in $ac_precious_vars; do
3462 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3463 eval ac_new_set=\$ac_env_${ac_var}_set
3464 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3465 eval ac_new_val=\$ac_env_${ac_var}_value
3466 case $ac_old_set,$ac_new_set in
3467 set,)
3468 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3469$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3470 ac_cache_corrupted=: ;;
3471 ,set)
3472 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3473$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3474 ac_cache_corrupted=: ;;
3475 ,);;
3476 *)
3477 if test "x$ac_old_val" != "x$ac_new_val"; then
3478 # differences in whitespace do not lead to failure.
3479 ac_old_val_w=`echo x $ac_old_val`
3480 ac_new_val_w=`echo x $ac_new_val`
3481 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3482 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3483$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3484 ac_cache_corrupted=:
3485 else
3486 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3487$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3488 eval $ac_var=\$ac_old_val
3489 fi
3490 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3491$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3492 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3493$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3494 fi;;
3495 esac
3496 # Pass precious variables to config.status.
3497 if test "$ac_new_set" = set; then
3498 case $ac_new_val in
3499 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3500 *) ac_arg=$ac_var=$ac_new_val ;;
3501 esac
3502 case " $ac_configure_args " in
3503 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3504 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3505 esac
3506 fi
3507done
3508if $ac_cache_corrupted; then
3509 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3510$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3511 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3512$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3513 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3514fi
3515## -------------------- ##
3516## Main body of script. ##
3517## -------------------- ##
3518
3519ac_ext=c
3520ac_cpp='$CPP $CPPFLAGS'
3521ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3522ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3523ac_compiler_gnu=$ac_cv_c_compiler_gnu
3524
3525
3526
3527ac_aux_dir=
3528for ac_dir in build-aux "$srcdir"/build-aux; do
3529 if test -f "$ac_dir/install-sh"; then
3530 ac_aux_dir=$ac_dir
3531 ac_install_sh="$ac_aux_dir/install-sh -c"
3532 break
3533 elif test -f "$ac_dir/install.sh"; then
3534 ac_aux_dir=$ac_dir
3535 ac_install_sh="$ac_aux_dir/install.sh -c"
3536 break
3537 elif test -f "$ac_dir/shtool"; then
3538 ac_aux_dir=$ac_dir
3539 ac_install_sh="$ac_aux_dir/shtool install -c"
3540 break
3541 fi
3542done
3543if test -z "$ac_aux_dir"; then
3544 as_fn_error $? "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
3545fi
3546
3547# These three variables are undocumented and unsupported,
3548# and are intended to be withdrawn in a future Autoconf release.
3549# They can cause serious problems if a builder's source tree is in a directory
3550# whose full name contains unusual characters.
3551ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3552ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3553ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3554
3555
3556
3557# We don't want -g -O2 by default in CFLAGS
3558: ${CFLAGS=""}
3559
3560# Checks for build, host and target systems.
3561# Make sure we can run config.sub.
3562$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
3563 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
3564
3565{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
3566$as_echo_n "checking build system type... " >&6; }
3567if ${ac_cv_build+:} false; then :
3568 $as_echo_n "(cached) " >&6
3569else
3570 ac_build_alias=$build_alias
3571test "x$ac_build_alias" = x &&
3572 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
3573test "x$ac_build_alias" = x &&
3574 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
3575ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
3576 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
3577
3578fi
3579{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
3580$as_echo "$ac_cv_build" >&6; }
3581case $ac_cv_build in
3582*-*-*) ;;
3583*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
3584esac
3585build=$ac_cv_build
3586ac_save_IFS=$IFS; IFS='-'
3587set x $ac_cv_build
3588shift
3589build_cpu=$1
3590build_vendor=$2
3591shift; shift
3592# Remember, the first character of IFS is used to create $*,
3593# except with old shells:
3594build_os=$*
3595IFS=$ac_save_IFS
3596case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
3597
3598
3599{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
3600$as_echo_n "checking host system type... " >&6; }
3601if ${ac_cv_host+:} false; then :
3602 $as_echo_n "(cached) " >&6
3603else
3604 if test "x$host_alias" = x; then
3605 ac_cv_host=$ac_cv_build
3606else
3607 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
3608 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
3609fi
3610
3611fi
3612{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
3613$as_echo "$ac_cv_host" >&6; }
3614case $ac_cv_host in
3615*-*-*) ;;
3616*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
3617esac
3618host=$ac_cv_host
3619ac_save_IFS=$IFS; IFS='-'
3620set x $ac_cv_host
3621shift
3622host_cpu=$1
3623host_vendor=$2
3624shift; shift
3625# Remember, the first character of IFS is used to create $*,
3626# except with old shells:
3627host_os=$*
3628IFS=$ac_save_IFS
3629case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
3630
3631
3632save_program_prefix="${program_prefix}"
3633{ $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
3634$as_echo_n "checking target system type... " >&6; }
3635if ${ac_cv_target+:} false; then :
3636 $as_echo_n "(cached) " >&6
3637else
3638 if test "x$target_alias" = x; then
3639 ac_cv_target=$ac_cv_host
3640else
3641 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
3642 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
3643fi
3644
3645fi
3646{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
3647$as_echo "$ac_cv_target" >&6; }
3648case $ac_cv_target in
3649*-*-*) ;;
3650*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
3651esac
3652target=$ac_cv_target
3653ac_save_IFS=$IFS; IFS='-'
3654set x $ac_cv_target
3655shift
3656target_cpu=$1
3657target_vendor=$2
3658shift; shift
3659# Remember, the first character of IFS is used to create $*,
3660# except with old shells:
3661target_os=$*
3662IFS=$ac_save_IFS
3663case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
3664
3665
3666# The aliases save the names the user supplied, while $host etc.
3667# will get canonicalized.
3668test -n "$target_alias" &&
3669 test "$program_prefix$program_suffix$program_transform_name" = \
3670 NONENONEs,x,x, &&
3671 program_prefix=${target_alias}-
3672program_prefix="${save_program_prefix}"
3673
3674am__api_version='1.15'
3675
3676# Find a good install program. We prefer a C program (faster),
3677# so one script is as good as another. But avoid the broken or
3678# incompatible versions:
3679# SysV /etc/install, /usr/sbin/install
3680# SunOS /usr/etc/install
3681# IRIX /sbin/install
3682# AIX /bin/install
3683# AmigaOS /C/install, which installs bootblocks on floppy discs
3684# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3685# AFS /usr/afsws/bin/install, which mishandles nonexistent args
3686# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3687# OS/2's system install, which has a completely different semantic
3688# ./install, which can be erroneously created by make from ./install.sh.
3689# Reject install programs that cannot install multiple files.
3690{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3691$as_echo_n "checking for a BSD-compatible install... " >&6; }
3692if test -z "$INSTALL"; then
3693if ${ac_cv_path_install+:} false; then :
3694 $as_echo_n "(cached) " >&6
3695else
3696 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3697for as_dir in $PATH
3698do
3699 IFS=$as_save_IFS
3700 test -z "$as_dir" && as_dir=.
3701 # Account for people who put trailing slashes in PATH elements.
3702case $as_dir/ in #((
3703 ./ | .// | /[cC]/* | \
3704 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3705 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3706 /usr/ucb/* ) ;;
3707 *)
3708 # OSF1 and SCO ODT 3.0 have their own names for install.
3709 # Don't use installbsd from OSF since it installs stuff as root
3710 # by default.
3711 for ac_prog in ginstall scoinst install; do
3712 for ac_exec_ext in '' $ac_executable_extensions; do
3713 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3714 if test $ac_prog = install &&
3715 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3716 # AIX install. It has an incompatible calling convention.
3717 :
3718 elif test $ac_prog = install &&
3719 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3720 # program-specific install script used by HP pwplus--don't use.
3721 :
3722 else
3723 rm -rf conftest.one conftest.two conftest.dir
3724 echo one > conftest.one
3725 echo two > conftest.two
3726 mkdir conftest.dir
3727 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3728 test -s conftest.one && test -s conftest.two &&
3729 test -s conftest.dir/conftest.one &&
3730 test -s conftest.dir/conftest.two
3731 then
3732 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3733 break 3
3734 fi
3735 fi
3736 fi
3737 done
3738 done
3739 ;;
3740esac
3741
3742 done
3743IFS=$as_save_IFS
3744
3745rm -rf conftest.one conftest.two conftest.dir
3746
3747fi
3748 if test "${ac_cv_path_install+set}" = set; then
3749 INSTALL=$ac_cv_path_install
3750 else
3751 # As a last resort, use the slow shell script. Don't cache a
3752 # value for INSTALL within a source directory, because that will
3753 # break other packages using the cache if that directory is
3754 # removed, or if the value is a relative name.
3755 INSTALL=$ac_install_sh
3756 fi
3757fi
3758{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3759$as_echo "$INSTALL" >&6; }
3760
3761# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3762# It thinks the first close brace ends the variable substitution.
3763test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3764
3765test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3766
3767test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3768
3769{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3770$as_echo_n "checking whether build environment is sane... " >&6; }
3771# Reject unsafe characters in $srcdir or the absolute working directory
3772# name. Accept space and tab only in the latter.
3773am_lf='
3774'
3775case `pwd` in
3776 *[\\\"\#\$\&\'\`$am_lf]*)
3777 as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
3778esac
3779case $srcdir in
3780 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3781 as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
3782esac
3783
3784# Do 'set' in a subshell so we don't clobber the current shell's
3785# arguments. Must try -L first in case configure is actually a
3786# symlink; some systems play weird games with the mod time of symlinks
3787# (eg FreeBSD returns the mod time of the symlink's containing
3788# directory).
3789if (
3790 am_has_slept=no
3791 for am_try in 1 2; do
3792 echo "timestamp, slept: $am_has_slept" > conftest.file
3793 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3794 if test "$*" = "X"; then
3795 # -L didn't work.
3796 set X `ls -t "$srcdir/configure" conftest.file`
3797 fi
3798 if test "$*" != "X $srcdir/configure conftest.file" \
3799 && test "$*" != "X conftest.file $srcdir/configure"; then
3800
3801 # If neither matched, then we have a broken ls. This can happen
3802 # if, for instance, CONFIG_SHELL is bash and it inherits a
3803 # broken ls alias from the environment. This has actually
3804 # happened. Such a system could not be considered "sane".
3805 as_fn_error $? "ls -t appears to fail. Make sure there is not a broken
3806 alias in your environment" "$LINENO" 5
3807 fi
3808 if test "$2" = conftest.file || test $am_try -eq 2; then
3809 break
3810 fi
3811 # Just in case.
3812 sleep 1
3813 am_has_slept=yes
3814 done
3815 test "$2" = conftest.file
3816 )
3817then
3818 # Ok.
3819 :
3820else
3821 as_fn_error $? "newly created file is older than distributed files!
3822Check your system clock" "$LINENO" 5
3823fi
3824{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3825$as_echo "yes" >&6; }
3826# If we didn't sleep, we still need to ensure time stamps of config.status and
3827# generated files are strictly newer.
3828am_sleep_pid=
3829if grep 'slept: no' conftest.file >/dev/null 2>&1; then
3830 ( sleep 1 ) &
3831 am_sleep_pid=$!
3832fi
3833
3834rm -f conftest.file
3835
3836test "$program_prefix" != NONE &&
3837 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3838# Use a double $ so make ignores it.
3839test "$program_suffix" != NONE &&
3840 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3841# Double any \ or $.
3842# By default was `s,x,x', remove it if useless.
3843ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3844program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3845
3846# Expand $ac_aux_dir to an absolute path.
3847am_aux_dir=`cd "$ac_aux_dir" && pwd`
3848
3849if test x"${MISSING+set}" != xset; then
3850 case $am_aux_dir in
3851 *\ * | *\ *)
3852 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3853 *)
3854 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3855 esac
3856fi
3857# Use eval to expand $SHELL
3858if eval "$MISSING --is-lightweight"; then
3859 am_missing_run="$MISSING "
3860else
3861 am_missing_run=
3862 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
3863$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
3864fi
3865
3866if test x"${install_sh+set}" != xset; then
3867 case $am_aux_dir in
3868 *\ * | *\ *)
3869 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3870 *)
3871 install_sh="\${SHELL} $am_aux_dir/install-sh"
3872 esac
3873fi
3874
3875# Installed binaries are usually stripped using 'strip' when the user
3876# run "make install-strip". However 'strip' might not be the right
3877# tool to use in cross-compilation environments, therefore Automake
3878# will honor the 'STRIP' environment variable to overrule this program.
3879if test "$cross_compiling" != no; then
3880 if test -n "$ac_tool_prefix"; then
3881 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3882set dummy ${ac_tool_prefix}strip; ac_word=$2
3883{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3884$as_echo_n "checking for $ac_word... " >&6; }
3885if ${ac_cv_prog_STRIP+:} false; then :
3886 $as_echo_n "(cached) " >&6
3887else
3888 if test -n "$STRIP"; then
3889 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3890else
3891as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3892for as_dir in $PATH
3893do
3894 IFS=$as_save_IFS
3895 test -z "$as_dir" && as_dir=.
3896 for ac_exec_ext in '' $ac_executable_extensions; do
3897 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3898 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3899 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3900 break 2
3901 fi
3902done
3903 done
3904IFS=$as_save_IFS
3905
3906fi
3907fi
3908STRIP=$ac_cv_prog_STRIP
3909if test -n "$STRIP"; then
3910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3911$as_echo "$STRIP" >&6; }
3912else
3913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3914$as_echo "no" >&6; }
3915fi
3916
3917
3918fi
3919if test -z "$ac_cv_prog_STRIP"; then
3920 ac_ct_STRIP=$STRIP
3921 # Extract the first word of "strip", so it can be a program name with args.
3922set dummy strip; ac_word=$2
3923{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3924$as_echo_n "checking for $ac_word... " >&6; }
3925if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
3926 $as_echo_n "(cached) " >&6
3927else
3928 if test -n "$ac_ct_STRIP"; then
3929 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3930else
3931as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3932for as_dir in $PATH
3933do
3934 IFS=$as_save_IFS
3935 test -z "$as_dir" && as_dir=.
3936 for ac_exec_ext in '' $ac_executable_extensions; do
3937 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3938 ac_cv_prog_ac_ct_STRIP="strip"
3939 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3940 break 2
3941 fi
3942done
3943 done
3944IFS=$as_save_IFS
3945
3946fi
3947fi
3948ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3949if test -n "$ac_ct_STRIP"; then
3950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3951$as_echo "$ac_ct_STRIP" >&6; }
3952else
3953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3954$as_echo "no" >&6; }
3955fi
3956
3957 if test "x$ac_ct_STRIP" = x; then
3958 STRIP=":"
3959 else
3960 case $cross_compiling:$ac_tool_warned in
3961yes:)
3962{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3963$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3964ac_tool_warned=yes ;;
3965esac
3966 STRIP=$ac_ct_STRIP
3967 fi
3968else
3969 STRIP="$ac_cv_prog_STRIP"
3970fi
3971
3972fi
3973INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3974
3975{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3976$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3977if test -z "$MKDIR_P"; then
3978 if ${ac_cv_path_mkdir+:} false; then :
3979 $as_echo_n "(cached) " >&6
3980else
3981 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3982for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3983do
3984 IFS=$as_save_IFS
3985 test -z "$as_dir" && as_dir=.
3986 for ac_prog in mkdir gmkdir; do
3987 for ac_exec_ext in '' $ac_executable_extensions; do
3988 as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
3989 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3990 'mkdir (GNU coreutils) '* | \
3991 'mkdir (coreutils) '* | \
3992 'mkdir (fileutils) '4.1*)
3993 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3994 break 3;;
3995 esac
3996 done
3997 done
3998 done
3999IFS=$as_save_IFS
4000
4001fi
4002
4003 test -d ./--version && rmdir ./--version
4004 if test "${ac_cv_path_mkdir+set}" = set; then
4005 MKDIR_P="$ac_cv_path_mkdir -p"
4006 else
4007 # As a last resort, use the slow shell script. Don't cache a
4008 # value for MKDIR_P within a source directory, because that will
4009 # break other packages using the cache if that directory is
4010 # removed, or if the value is a relative name.
4011 MKDIR_P="$ac_install_sh -d"
4012 fi
4013fi
4014{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
4015$as_echo "$MKDIR_P" >&6; }
4016
4017for ac_prog in gawk mawk nawk awk
4018do
4019 # Extract the first word of "$ac_prog", so it can be a program name with args.
4020set dummy $ac_prog; ac_word=$2
4021{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4022$as_echo_n "checking for $ac_word... " >&6; }
4023if ${ac_cv_prog_AWK+:} false; then :
4024 $as_echo_n "(cached) " >&6
4025else
4026 if test -n "$AWK"; then
4027 ac_cv_prog_AWK="$AWK" # Let the user override the test.
4028else
4029as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4030for as_dir in $PATH
4031do
4032 IFS=$as_save_IFS
4033 test -z "$as_dir" && as_dir=.
4034 for ac_exec_ext in '' $ac_executable_extensions; do
4035 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4036 ac_cv_prog_AWK="$ac_prog"
4037 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4038 break 2
4039 fi
4040done
4041 done
4042IFS=$as_save_IFS
4043
4044fi
4045fi
4046AWK=$ac_cv_prog_AWK
4047if test -n "$AWK"; then
4048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
4049$as_echo "$AWK" >&6; }
4050else
4051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4052$as_echo "no" >&6; }
4053fi
4054
4055
4056 test -n "$AWK" && break
4057done
4058
4059{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
4060$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
4061set x ${MAKE-make}
4062ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
4063if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
4064 $as_echo_n "(cached) " >&6
4065else
4066 cat >conftest.make <<\_ACEOF
4067SHELL = /bin/sh
4068all:
4069 @echo '@@@%%%=$(MAKE)=@@@%%%'
4070_ACEOF
4071# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
4072case `${MAKE-make} -f conftest.make 2>/dev/null` in
4073 *@@@%%%=?*=@@@%%%*)
4074 eval ac_cv_prog_make_${ac_make}_set=yes;;
4075 *)
4076 eval ac_cv_prog_make_${ac_make}_set=no;;
4077esac
4078rm -f conftest.make
4079fi
4080if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
4081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4082$as_echo "yes" >&6; }
4083 SET_MAKE=
4084else
4085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4086$as_echo "no" >&6; }
4087 SET_MAKE="MAKE=${MAKE-make}"
4088fi
4089
4090rm -rf .tst 2>/dev/null
4091mkdir .tst 2>/dev/null
4092if test -d .tst; then
4093 am__leading_dot=.
4094else
4095 am__leading_dot=_
4096fi
4097rmdir .tst 2>/dev/null
4098
4099# Check whether --enable-silent-rules was given.
4100if test "${enable_silent_rules+set}" = set; then :
4101 enableval=$enable_silent_rules;
4102fi
4103
4104case $enable_silent_rules in # (((
4105 yes) AM_DEFAULT_VERBOSITY=0;;
4106 no) AM_DEFAULT_VERBOSITY=1;;
4107 *) AM_DEFAULT_VERBOSITY=1;;
4108esac
4109am_make=${MAKE-make}
4110{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
4111$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
4112if ${am_cv_make_support_nested_variables+:} false; then :
4113 $as_echo_n "(cached) " >&6
4114else
4115 if $as_echo 'TRUE=$(BAR$(V))
4116BAR0=false
4117BAR1=true
4118V=1
4119am__doit:
4120 @$(TRUE)
4121.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
4122 am_cv_make_support_nested_variables=yes
4123else
4124 am_cv_make_support_nested_variables=no
4125fi
4126fi
4127{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
4128$as_echo "$am_cv_make_support_nested_variables" >&6; }
4129if test $am_cv_make_support_nested_variables = yes; then
4130 AM_V='$(V)'
4131 AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
4132else
4133 AM_V=$AM_DEFAULT_VERBOSITY
4134 AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
4135fi
4136AM_BACKSLASH='\'
4137
4138if test "`cd $srcdir && pwd`" != "`pwd`"; then
4139 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
4140 # is not polluted with repeated "-I."
4141 am__isrc=' -I$(srcdir)'
4142 # test to see if srcdir already configured
4143 if test -f $srcdir/config.status; then
4144 as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
4145 fi
4146fi
4147
4148# test whether we have cygpath
4149if test -z "$CYGPATH_W"; then
4150 if (cygpath --version) >/dev/null 2>/dev/null; then
4151 CYGPATH_W='cygpath -w'
4152 else
4153 CYGPATH_W=echo
4154 fi
4155fi
4156
4157
4158# Define the identity of the package.
4159 PACKAGE='grub'
4160 VERSION='2.02'
4161
4162
4163cat >>confdefs.h <<_ACEOF
4164#define PACKAGE "$PACKAGE"
4165_ACEOF
4166
4167
4168cat >>confdefs.h <<_ACEOF
4169#define VERSION "$VERSION"
4170_ACEOF
4171
4172# Some tools Automake needs.
4173
4174ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
4175
4176
4177AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
4178
4179
4180AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
4181
4182
4183AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
4184
4185
4186MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
4187
4188# For better backward compatibility. To be removed once Automake 1.9.x
4189# dies out for good. For more background, see:
4190# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
4191# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
4192mkdir_p='$(MKDIR_P)'
4193
4194# We need awk for the "check" target (and possibly the TAP driver). The
4195# system "awk" is bad on some platforms.
4196# Always define AMTAR for backward compatibility. Yes, it's still used
4197# in the wild :-( We should find a proper way to deprecate it ...
4198AMTAR='$${TAR-tar}'
4199
4200
4201# We'll loop over all known methods to create a tar archive until one works.
4202_am_tools='gnutar pax cpio none'
4203
4204am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
4205
4206
4207
4208
4209
4210
4211# POSIX will say in a future version that running "rm -f" with no argument
4212# is OK; and we want to be able to make that assumption in our Makefile
4213# recipes. So use an aggressive probe to check that the usage we want is
4214# actually supported "in the wild" to an acceptable degree.
4215# See automake bug#10828.
4216# To make any issue more visible, cause the running configure to be aborted
4217# by default if the 'rm' program in use doesn't match our expectations; the
4218# user can still override this though.
4219if rm -f && rm -fr && rm -rf; then : OK; else
4220 cat >&2 <<'END'
4221Oops!
4222
4223Your 'rm' program seems unable to run without file operands specified
4224on the command line, even when the '-f' option is present. This is contrary
4225to the behaviour of most rm programs out there, and not conforming with
4226the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
4227
4228Please tell bug-automake@gnu.org about your system, including the value
4229of your $PATH and any error possibly output before this message. This
4230can help us improve future automake versions.
4231
4232END
4233 if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
4234 echo 'Configuration will proceed anyway, since you have set the' >&2
4235 echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
4236 echo >&2
4237 else
4238 cat >&2 <<'END'
4239Aborting the configuration process, to ensure you take notice of the issue.
4240
4241You can download and install GNU coreutils to get an 'rm' implementation
4242that behaves properly: <http://www.gnu.org/software/coreutils/>.
4243
4244If you want to complete the configuration process using your problematic
4245'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
4246to "yes", and re-run configure.
4247
4248END
4249 as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5
4250 fi
4251fi
4252
4253
4254
4255ac_config_headers="$ac_config_headers config-util.h"
4256
4257
4258# Program name transformations
4259
4260grub_bios_setup=`$as_echo grub-bios-setup | sed "$program_transform_name"`
4261
4262grub_editenv=`$as_echo grub-editenv | sed "$program_transform_name"`
4263
4264grub_install=`$as_echo grub-install | sed "$program_transform_name"`
4265
4266grub_mkconfig=`$as_echo grub-mkconfig | sed "$program_transform_name"`
4267
4268grub_mkfont=`$as_echo grub-mkfont | sed "$program_transform_name"`
4269
4270grub_mkimage=`$as_echo grub-mkimage | sed "$program_transform_name"`
4271
4272grub_glue_efi=`$as_echo grub-glue-efi | sed "$program_transform_name"`
4273
4274grub_mklayout=`$as_echo grub-mklayout | sed "$program_transform_name"`
4275
4276grub_mkpasswd_pbkdf2=`$as_echo grub-mkpasswd-pbkdf2 | sed "$program_transform_name"`
4277
4278grub_mkrelpath=`$as_echo grub-mkrelpath | sed "$program_transform_name"`
4279
4280grub_mkrescue=`$as_echo grub-mkrescue | sed "$program_transform_name"`
4281
4282grub_probe=`$as_echo grub-probe | sed "$program_transform_name"`
4283
4284grub_reboot=`$as_echo grub-reboot | sed "$program_transform_name"`
4285
4286grub_script_check=`$as_echo grub-script-check | sed "$program_transform_name"`
4287
4288grub_set_default=`$as_echo grub-set-default | sed "$program_transform_name"`
4289
4290grub_sparc64_setup=`$as_echo grub-sparc64-setup | sed "$program_transform_name"`
4291
4292grub_render_label=`$as_echo grub-render-label | sed "$program_transform_name"`
4293
4294grub_file=`$as_echo grub-file | sed "$program_transform_name"`
4295
4296
4297# Optimization flag. Allow user to override.
4298if test "x$TARGET_CFLAGS" = x; then
4299 TARGET_CFLAGS="$TARGET_CFLAGS -Os"
4300fi
4301
4302# Default HOST_CPPFLAGS
4303HOST_CPPFLAGS="$HOST_CPPFLAGS -Wall -W"
4304HOST_CPPFLAGS="$HOST_CPPFLAGS -DGRUB_UTIL=1"
4305
4306TARGET_CPPFLAGS="$TARGET_CPPFLAGS -Wall -W"
4307
4308case "$target_cpu" in
4309 i[3456]86) target_cpu=i386 ;;
4310 amd64) target_cpu=x86_64 ;;
4311 sparc) target_cpu=sparc64 ;;
4312 mipsel|mips64el)
4313 target_cpu=mipsel
4314 machine_CPPFLAGS="$machine_CPPFLAGS -DGRUB_CPU_MIPSEL=1"
4315 ;;
4316 mips|mips64)
4317 target_cpu=mips
4318 machine_CPPFLAGS="$machine_CPPFLAGS -DGRUB_CPU_MIPS=1"
4319 ;;
4320 arm*)
4321 target_cpu=arm
4322 ;;
4323 aarch64*)
4324 target_cpu=arm64
4325 ;;
4326esac
4327
4328# Specify the platform (such as firmware).
4329
4330# Check whether --with-platform was given.
4331if test "${with_platform+set}" = set; then :
4332 withval=$with_platform;
4333fi
4334
4335
4336# Guess the platform if not specified.
4337if test "x$with_platform" = x; then
4338 case "$target_cpu"-"$target_vendor" in
4339 i386-apple) platform=efi ;;
4340 i386-*) platform=pc ;;
4341 x86_64-apple) platform=efi ;;
4342 x86_64-*) platform=pc ;;
4343 powerpc-*) platform=ieee1275 ;;
4344 powerpc64-*) platform=ieee1275 ;;
4345 powerpc64le-*) platform=ieee1275 ;;
4346 sparc64-*) platform=ieee1275 ;;
4347 mipsel-*) platform=loongson ;;
4348 mips-*) platform=arc ;;
4349 ia64-*) platform=efi ;;
4350 arm-*) platform=uboot ;;
4351 arm64-*) platform=efi ;;
4352 *)
4353 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unsupported CPU: \"$target_cpu\" - only building utilities" >&5
4354$as_echo "$as_me: WARNING: unsupported CPU: \"$target_cpu\" - only building utilities" >&2;}
4355 platform=none
4356 ;;
4357 esac
4358else
4359 platform="$with_platform"
4360fi
4361
4362case "$target_cpu"-"$platform" in
4363 x86_64-efi) ;;
4364 x86_64-emu) ;;
4365 x86_64-xen) ;;
4366 x86_64-none) ;;
4367 x86_64-*) target_cpu=i386 ;;
4368 powerpc64-ieee1275) target_cpu=powerpc ;;
4369 powerpc64le-ieee1275) target_cpu=powerpc ;;
4370esac
4371
4372# Check if the platform is supported, make final adjustments.
4373case "$target_cpu"-"$platform" in
4374 i386-efi) ;;
4375 x86_64-efi) ;;
4376 i386-xen) ;;
4377 x86_64-xen) ;;
4378 i386-pc) ;;
4379 i386-multiboot) ;;
4380 i386-coreboot) ;;
4381 i386-linuxbios) platform=coreboot ;;
4382 i386-ieee1275) ;;
4383 i386-qemu) ;;
4384 powerpc-ieee1275) ;;
4385 sparc64-ieee1275) ;;
4386 ia64-efi) ;;
4387 mips-qemu_mips) ;;
4388 mips-qemu-mips) platform=qemu_mips;;
4389 mips-arc) ;;
4390 mipsel-arc) ;;
4391 mipsel-qemu_mips) ;;
4392 mipsel-qemu-mips) platform=qemu_mips;;
4393 mipsel-yeeloong) platform=loongson ;;
4394 mipsel-fuloong) platform=loongson ;;
4395 mipsel-loongson) ;;
4396 arm-uboot) ;;
4397 arm-efi) ;;
4398 arm64-efi) ;;
4399 *-emu) ;;
4400 *-none) ;;
4401 *) as_fn_error $? "platform \"$platform\" is not supported for target CPU \"$target_cpu\"" "$LINENO" 5 ;;
4402esac
4403
4404if test x$platform != xemu ; then
4405 case "$target_cpu" in
4406 i386 | powerpc) target_m32=1 ;;
4407 x86_64 | sparc64) target_m64=1 ;;
4408 esac
4409fi
4410
4411if test x"$target_cpu-$platform" = xsparc64-emu ; then
4412 target_m64=1
4413fi
4414
4415case "$target_os" in
4416 windows* | mingw32*) target_os=cygwin ;;
4417esac
4418
4419# This normalizes the names, and creates a new variable ("host_kernel")
4420# while at it, since the mapping is not always 1:1 (e.g. different OSes
4421# using the same kernel type).
4422case "$host_os" in
4423 gnu*) host_kernel=hurd ;;
4424 linux*) host_kernel=linux ;;
4425 freebsd* | kfreebsd*-gnu) host_kernel=kfreebsd ;;
4426 netbsd*) host_kernel=netbsd ;;
4427 solaris*) host_kernel=illumos ;;
4428 darwin*) host_kernel=xnu ;;
4429 cygwin | windows* | mingw32*) host_kernel=windows ;;
4430esac
4431
4432case "$host_os" in
4433 cygwin | windows* | mingw32*) have_exec=n ;;
4434 aros*) have_exec=n ;;
4435 *) have_exec=y;;
4436esac
4437
4438case "$platform" in
4439 coreboot) machine_CPPFLAGS="$machine_CPPFLAGS -DGRUB_MACHINE_COREBOOT=1" ;;
4440 multiboot) machine_CPPFLAGS="$machine_CPPFLAGS -DGRUB_MACHINE_MULTIBOOT=1" ;;
4441 efi) machine_CPPFLAGS="$machine_CPPFLAGS -DGRUB_MACHINE_EFI=1" ;;
4442 xen) machine_CPPFLAGS="$machine_CPPFLAGS -DGRUB_MACHINE_XEN=1" ;;
4443 ieee1275) machine_CPPFLAGS="$machine_CPPFLAGS -DGRUB_MACHINE_IEEE1275=1" ;;
4444 uboot) machine_CPPFLAGS="$machine_CPPFLAGS -DGRUB_MACHINE_UBOOT=1" ;;
4445 qemu) machine_CPPFLAGS="$machine_CPPFLAGS -DGRUB_MACHINE_QEMU=1" ;;
4446 pc) machine_CPPFLAGS="$machine_CPPFLAGS -DGRUB_MACHINE_PCBIOS=1" ;;
4447 emu) machine_CPPFLAGS="$machine_CPPFLAGS -DGRUB_MACHINE_EMU=1" ;;
4448 loongson) machine_CPPFLAGS="$machine_CPPFLAGS -DGRUB_MACHINE_MIPS_LOONGSON=1" ;;
4449 qemu_mips) machine_CPPFLAGS="$machine_CPPFLAGS -DGRUB_MACHINE_MIPS_QEMU_MIPS=1" ;;
4450 arc) machine_CPPFLAGS="$machine_CPPFLAGS -DGRUB_MACHINE_ARC=1" ;;
4451esac
4452if test x${target_cpu} = xmipsel ; then
4453 machine_CPPFLAGS="$machine_CPPFLAGS -DGRUB_MACHINE=`echo mips_$platform | sed y,abcdefghijklmnopqrstuvwxyz,ABCDEFGHIJKLMNOPQRSTUVWXYZ,`"
4454else
4455 machine_CPPFLAGS="$machine_CPPFLAGS -DGRUB_MACHINE=`echo ${target_cpu}_$platform | sed y,abcdefghijklmnopqrstuvwxyz,ABCDEFGHIJKLMNOPQRSTUVWXYZ,`"
4456fi
4457
4458case "${target_cpu}-$platform" in
4459 mips-arc)
4460 TARGET_LINK_ADDR=0x88200000
4461 TARGET_DECOMPRESSOR_LINK_ADDR=0x88100000
4462 ;;
4463 mipsel-arc)
4464 TARGET_LINK_ADDR=0x80700000
4465 TARGET_DECOMPRESSOR_LINK_ADDR=0x80600000
4466 ;;
4467 mips*-qemu_mips | mips*-loongson)
4468 TARGET_DECOMPRESSOR_LINK_ADDR=0x80100000
4469 ;;
4470esac
4471
4472
4473
4474
4475TARGET_CPPFLAGS="$TARGET_CPPFLAGS $machine_CPPFLAGS"
4476
4477
4478
4479
4480
4481
4482
4483
4484# Define default variables
4485
4486have_with_bootdir=n
4487
4488# Check whether --with-bootdir was given.
4489if test "${with_bootdir+set}" = set; then :
4490 withval=$with_bootdir; have_with_bootdir=y
4491else
4492 have_with_bootdir=n
4493fi
4494
4495if test x$have_with_bootdir = xy; then
4496 bootdirname="$with_bootdir"
4497else
4498 case "$host_os" in
4499 netbsd* | openbsd*)
4500 # Because /boot is used for the boot block in NetBSD and OpenBSD,
4501 bootdirname='' ;;
4502 *) bootdirname='boot' ;;
4503 esac
4504fi
4505
4506
4507
4508cat >>confdefs.h <<_ACEOF
4509#define GRUB_BOOT_DIR_NAME "$bootdirname"
4510_ACEOF
4511
4512
4513
4514# Check whether --with-grubdir was given.
4515if test "${with_grubdir+set}" = set; then :
4516 withval=$with_grubdir; grubdirname="$with_grubdir"
4517else
4518 grubdirname="$PACKAGE"
4519fi
4520
4521
4522
4523
4524cat >>confdefs.h <<_ACEOF
4525#define GRUB_DIR_NAME "$grubdirname"
4526_ACEOF
4527
4528
4529#
4530# Checks for build programs.
4531#
4532
4533# Although cmp is listed in the GNU Coding Standards as a command which
4534# can used directly, OpenBSD lacks cmp in the default installation.
4535for ac_prog in cmp
4536do
4537 # Extract the first word of "$ac_prog", so it can be a program name with args.
4538set dummy $ac_prog; ac_word=$2
4539{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4540$as_echo_n "checking for $ac_word... " >&6; }
4541if ${ac_cv_prog_CMP+:} false; then :
4542 $as_echo_n "(cached) " >&6
4543else
4544 if test -n "$CMP"; then
4545 ac_cv_prog_CMP="$CMP" # Let the user override the test.
4546else
4547as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4548for as_dir in $PATH
4549do
4550 IFS=$as_save_IFS
4551 test -z "$as_dir" && as_dir=.
4552 for ac_exec_ext in '' $ac_executable_extensions; do
4553 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4554 ac_cv_prog_CMP="$ac_prog"
4555 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4556 break 2
4557 fi
4558done
4559 done
4560IFS=$as_save_IFS
4561
4562fi
4563fi
4564CMP=$ac_cv_prog_CMP
4565if test -n "$CMP"; then
4566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5
4567$as_echo "$CMP" >&6; }
4568else
4569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4570$as_echo "no" >&6; }
4571fi
4572
4573
4574 test -n "$CMP" && break
4575done
4576
4577if test "x$CMP" = x; then
4578 as_fn_error $? "cmp is not found" "$LINENO" 5
4579fi
4580
4581for ac_prog in bison
4582do
4583 # Extract the first word of "$ac_prog", so it can be a program name with args.
4584set dummy $ac_prog; ac_word=$2
4585{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4586$as_echo_n "checking for $ac_word... " >&6; }
4587if ${ac_cv_prog_YACC+:} false; then :
4588 $as_echo_n "(cached) " >&6
4589else
4590 if test -n "$YACC"; then
4591 ac_cv_prog_YACC="$YACC" # Let the user override the test.
4592else
4593as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4594for as_dir in $PATH
4595do
4596 IFS=$as_save_IFS
4597 test -z "$as_dir" && as_dir=.
4598 for ac_exec_ext in '' $ac_executable_extensions; do
4599 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4600 ac_cv_prog_YACC="$ac_prog"
4601 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4602 break 2
4603 fi
4604done
4605 done
4606IFS=$as_save_IFS
4607
4608fi
4609fi
4610YACC=$ac_cv_prog_YACC
4611if test -n "$YACC"; then
4612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
4613$as_echo "$YACC" >&6; }
4614else
4615 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4616$as_echo "no" >&6; }
4617fi
4618
4619
4620 test -n "$YACC" && break
4621done
4622
4623if test "x$YACC" = x; then
4624 as_fn_error $? "bison is not found" "$LINENO" 5
4625fi
4626
4627if test -n "$ac_tool_prefix"; then
4628 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
4629set dummy ${ac_tool_prefix}ranlib; ac_word=$2
4630{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4631$as_echo_n "checking for $ac_word... " >&6; }
4632if ${ac_cv_prog_RANLIB+:} false; then :
4633 $as_echo_n "(cached) " >&6
4634else
4635 if test -n "$RANLIB"; then
4636 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4637else
4638as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4639for as_dir in $PATH
4640do
4641 IFS=$as_save_IFS
4642 test -z "$as_dir" && as_dir=.
4643 for ac_exec_ext in '' $ac_executable_extensions; do
4644 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4645 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
4646 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4647 break 2
4648 fi
4649done
4650 done
4651IFS=$as_save_IFS
4652
4653fi
4654fi
4655RANLIB=$ac_cv_prog_RANLIB
4656if test -n "$RANLIB"; then
4657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
4658$as_echo "$RANLIB" >&6; }
4659else
4660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4661$as_echo "no" >&6; }
4662fi
4663
4664
4665fi
4666if test -z "$ac_cv_prog_RANLIB"; then
4667 ac_ct_RANLIB=$RANLIB
4668 # Extract the first word of "ranlib", so it can be a program name with args.
4669set dummy ranlib; ac_word=$2
4670{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4671$as_echo_n "checking for $ac_word... " >&6; }
4672if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
4673 $as_echo_n "(cached) " >&6
4674else
4675 if test -n "$ac_ct_RANLIB"; then
4676 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4677else
4678as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4679for as_dir in $PATH
4680do
4681 IFS=$as_save_IFS
4682 test -z "$as_dir" && as_dir=.
4683 for ac_exec_ext in '' $ac_executable_extensions; do
4684 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4685 ac_cv_prog_ac_ct_RANLIB="ranlib"
4686 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4687 break 2
4688 fi
4689done
4690 done
4691IFS=$as_save_IFS
4692
4693fi
4694fi
4695ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4696if test -n "$ac_ct_RANLIB"; then
4697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
4698$as_echo "$ac_ct_RANLIB" >&6; }
4699else
4700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4701$as_echo "no" >&6; }
4702fi
4703
4704 if test "x$ac_ct_RANLIB" = x; then
4705 RANLIB=":"
4706 else
4707 case $cross_compiling:$ac_tool_warned in
4708yes:)
4709{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4710$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4711ac_tool_warned=yes ;;
4712esac
4713 RANLIB=$ac_ct_RANLIB
4714 fi
4715else
4716 RANLIB="$ac_cv_prog_RANLIB"
4717fi
4718
4719
4720for ac_prog in gawk mawk nawk awk
4721do
4722 # Extract the first word of "$ac_prog", so it can be a program name with args.
4723set dummy $ac_prog; ac_word=$2
4724{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4725$as_echo_n "checking for $ac_word... " >&6; }
4726if ${ac_cv_prog_AWK+:} false; then :
4727 $as_echo_n "(cached) " >&6
4728else
4729 if test -n "$AWK"; then
4730 ac_cv_prog_AWK="$AWK" # Let the user override the test.
4731else
4732as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4733for as_dir in $PATH
4734do
4735 IFS=$as_save_IFS
4736 test -z "$as_dir" && as_dir=.
4737 for ac_exec_ext in '' $ac_executable_extensions; do
4738 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4739 ac_cv_prog_AWK="$ac_prog"
4740 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4741 break 2
4742 fi
4743done
4744 done
4745IFS=$as_save_IFS
4746
4747fi
4748fi
4749AWK=$ac_cv_prog_AWK
4750if test -n "$AWK"; then
4751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
4752$as_echo "$AWK" >&6; }
4753else
4754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4755$as_echo "no" >&6; }
4756fi
4757
4758
4759 test -n "$AWK" && break
4760done
4761
4762DEPDIR="${am__leading_dot}deps"
4763
4764ac_config_commands="$ac_config_commands depfiles"
4765
4766
4767am_make=${MAKE-make}
4768cat > confinc << 'END'
4769am__doit:
4770 @echo this is the am__doit target
4771.PHONY: am__doit
4772END
4773# If we don't find an include directive, just comment out the code.
4774{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
4775$as_echo_n "checking for style of include used by $am_make... " >&6; }
4776am__include="#"
4777am__quote=
4778_am_result=none
4779# First try GNU make style include.
4780echo "include confinc" > confmf
4781# Ignore all kinds of additional output from 'make'.
4782case `$am_make -s -f confmf 2> /dev/null` in #(
4783*the\ am__doit\ target*)
4784 am__include=include
4785 am__quote=
4786 _am_result=GNU
4787 ;;
4788esac
4789# Now try BSD make style include.
4790if test "$am__include" = "#"; then
4791 echo '.include "confinc"' > confmf
4792 case `$am_make -s -f confmf 2> /dev/null` in #(
4793 *the\ am__doit\ target*)
4794 am__include=.include
4795 am__quote="\""
4796 _am_result=BSD
4797 ;;
4798 esac
4799fi
4800
4801
4802{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
4803$as_echo "$_am_result" >&6; }
4804rm -f confinc confmf
4805
4806# Check whether --enable-dependency-tracking was given.
4807if test "${enable_dependency_tracking+set}" = set; then :
4808 enableval=$enable_dependency_tracking;
4809fi
4810
4811if test "x$enable_dependency_tracking" != xno; then
4812 am_depcomp="$ac_aux_dir/depcomp"
4813 AMDEPBACKSLASH='\'
4814 am__nodep='_no'
4815fi
4816 if test "x$enable_dependency_tracking" != xno; then
4817 AMDEP_TRUE=
4818 AMDEP_FALSE='#'
4819else
4820 AMDEP_TRUE='#'
4821 AMDEP_FALSE=
4822fi
4823
4824
4825ac_ext=c
4826ac_cpp='$CPP $CPPFLAGS'
4827ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4828ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4829ac_compiler_gnu=$ac_cv_c_compiler_gnu
4830if test -n "$ac_tool_prefix"; then
4831 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4832set dummy ${ac_tool_prefix}gcc; ac_word=$2
4833{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4834$as_echo_n "checking for $ac_word... " >&6; }
4835if ${ac_cv_prog_CC+:} false; then :
4836 $as_echo_n "(cached) " >&6
4837else
4838 if test -n "$CC"; then
4839 ac_cv_prog_CC="$CC" # Let the user override the test.
4840else
4841as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4842for as_dir in $PATH
4843do
4844 IFS=$as_save_IFS
4845 test -z "$as_dir" && as_dir=.
4846 for ac_exec_ext in '' $ac_executable_extensions; do
4847 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4848 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4849 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4850 break 2
4851 fi
4852done
4853 done
4854IFS=$as_save_IFS
4855
4856fi
4857fi
4858CC=$ac_cv_prog_CC
4859if test -n "$CC"; then
4860 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4861$as_echo "$CC" >&6; }
4862else
4863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4864$as_echo "no" >&6; }
4865fi
4866
4867
4868fi
4869if test -z "$ac_cv_prog_CC"; then
4870 ac_ct_CC=$CC
4871 # Extract the first word of "gcc", so it can be a program name with args.
4872set dummy gcc; ac_word=$2
4873{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4874$as_echo_n "checking for $ac_word... " >&6; }
4875if ${ac_cv_prog_ac_ct_CC+:} false; then :
4876 $as_echo_n "(cached) " >&6
4877else
4878 if test -n "$ac_ct_CC"; then
4879 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4880else
4881as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4882for as_dir in $PATH
4883do
4884 IFS=$as_save_IFS
4885 test -z "$as_dir" && as_dir=.
4886 for ac_exec_ext in '' $ac_executable_extensions; do
4887 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4888 ac_cv_prog_ac_ct_CC="gcc"
4889 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4890 break 2
4891 fi
4892done
4893 done
4894IFS=$as_save_IFS
4895
4896fi
4897fi
4898ac_ct_CC=$ac_cv_prog_ac_ct_CC
4899if test -n "$ac_ct_CC"; then
4900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4901$as_echo "$ac_ct_CC" >&6; }
4902else
4903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4904$as_echo "no" >&6; }
4905fi
4906
4907 if test "x$ac_ct_CC" = x; then
4908 CC=""
4909 else
4910 case $cross_compiling:$ac_tool_warned in
4911yes:)
4912{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4913$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4914ac_tool_warned=yes ;;
4915esac
4916 CC=$ac_ct_CC
4917 fi
4918else
4919 CC="$ac_cv_prog_CC"
4920fi
4921
4922if test -z "$CC"; then
4923 if test -n "$ac_tool_prefix"; then
4924 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4925set dummy ${ac_tool_prefix}cc; ac_word=$2
4926{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4927$as_echo_n "checking for $ac_word... " >&6; }
4928if ${ac_cv_prog_CC+:} false; then :
4929 $as_echo_n "(cached) " >&6
4930else
4931 if test -n "$CC"; then
4932 ac_cv_prog_CC="$CC" # Let the user override the test.
4933else
4934as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4935for as_dir in $PATH
4936do
4937 IFS=$as_save_IFS
4938 test -z "$as_dir" && as_dir=.
4939 for ac_exec_ext in '' $ac_executable_extensions; do
4940 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4941 ac_cv_prog_CC="${ac_tool_prefix}cc"
4942 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4943 break 2
4944 fi
4945done
4946 done
4947IFS=$as_save_IFS
4948
4949fi
4950fi
4951CC=$ac_cv_prog_CC
4952if test -n "$CC"; then
4953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4954$as_echo "$CC" >&6; }
4955else
4956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4957$as_echo "no" >&6; }
4958fi
4959
4960
4961 fi
4962fi
4963if test -z "$CC"; then
4964 # Extract the first word of "cc", so it can be a program name with args.
4965set dummy cc; ac_word=$2
4966{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4967$as_echo_n "checking for $ac_word... " >&6; }
4968if ${ac_cv_prog_CC+:} false; then :
4969 $as_echo_n "(cached) " >&6
4970else
4971 if test -n "$CC"; then
4972 ac_cv_prog_CC="$CC" # Let the user override the test.
4973else
4974 ac_prog_rejected=no
4975as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4976for as_dir in $PATH
4977do
4978 IFS=$as_save_IFS
4979 test -z "$as_dir" && as_dir=.
4980 for ac_exec_ext in '' $ac_executable_extensions; do
4981 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4982 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4983 ac_prog_rejected=yes
4984 continue
4985 fi
4986 ac_cv_prog_CC="cc"
4987 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4988 break 2
4989 fi
4990done
4991 done
4992IFS=$as_save_IFS
4993
4994if test $ac_prog_rejected = yes; then
4995 # We found a bogon in the path, so make sure we never use it.
4996 set dummy $ac_cv_prog_CC
4997 shift
4998 if test $# != 0; then
4999 # We chose a different compiler from the bogus one.
5000 # However, it has the same basename, so the bogon will be chosen
5001 # first if we set CC to just the basename; use the full file name.
5002 shift
5003 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
5004 fi
5005fi
5006fi
5007fi
5008CC=$ac_cv_prog_CC
5009if test -n "$CC"; then
5010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5011$as_echo "$CC" >&6; }
5012else
5013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5014$as_echo "no" >&6; }
5015fi
5016
5017
5018fi
5019if test -z "$CC"; then
5020 if test -n "$ac_tool_prefix"; then
5021 for ac_prog in cl.exe
5022 do
5023 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5024set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5025{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5026$as_echo_n "checking for $ac_word... " >&6; }
5027if ${ac_cv_prog_CC+:} false; then :
5028 $as_echo_n "(cached) " >&6
5029else
5030 if test -n "$CC"; then
5031 ac_cv_prog_CC="$CC" # Let the user override the test.
5032else
5033as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5034for as_dir in $PATH
5035do
5036 IFS=$as_save_IFS
5037 test -z "$as_dir" && as_dir=.
5038 for ac_exec_ext in '' $ac_executable_extensions; do
5039 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5040 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
5041 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5042 break 2
5043 fi
5044done
5045 done
5046IFS=$as_save_IFS
5047
5048fi
5049fi
5050CC=$ac_cv_prog_CC
5051if test -n "$CC"; then
5052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5053$as_echo "$CC" >&6; }
5054else
5055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5056$as_echo "no" >&6; }
5057fi
5058
5059
5060 test -n "$CC" && break
5061 done
5062fi
5063if test -z "$CC"; then
5064 ac_ct_CC=$CC
5065 for ac_prog in cl.exe
5066do
5067 # Extract the first word of "$ac_prog", so it can be a program name with args.
5068set dummy $ac_prog; ac_word=$2
5069{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5070$as_echo_n "checking for $ac_word... " >&6; }
5071if ${ac_cv_prog_ac_ct_CC+:} false; then :
5072 $as_echo_n "(cached) " >&6
5073else
5074 if test -n "$ac_ct_CC"; then
5075 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
5076else
5077as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5078for as_dir in $PATH
5079do
5080 IFS=$as_save_IFS
5081 test -z "$as_dir" && as_dir=.
5082 for ac_exec_ext in '' $ac_executable_extensions; do
5083 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5084 ac_cv_prog_ac_ct_CC="$ac_prog"
5085 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5086 break 2
5087 fi
5088done
5089 done
5090IFS=$as_save_IFS
5091
5092fi
5093fi
5094ac_ct_CC=$ac_cv_prog_ac_ct_CC
5095if test -n "$ac_ct_CC"; then
5096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5097$as_echo "$ac_ct_CC" >&6; }
5098else
5099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5100$as_echo "no" >&6; }
5101fi
5102
5103
5104 test -n "$ac_ct_CC" && break
5105done
5106
5107 if test "x$ac_ct_CC" = x; then
5108 CC=""
5109 else
5110 case $cross_compiling:$ac_tool_warned in
5111yes:)
5112{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5113$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5114ac_tool_warned=yes ;;
5115esac
5116 CC=$ac_ct_CC
5117 fi
5118fi
5119
5120fi
5121
5122
5123test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5124$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5125as_fn_error $? "no acceptable C compiler found in \$PATH
5126See \`config.log' for more details" "$LINENO" 5; }
5127
5128# Provide some information about the compiler.
5129$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
5130set X $ac_compile
5131ac_compiler=$2
5132for ac_option in --version -v -V -qversion; do
5133 { { ac_try="$ac_compiler $ac_option >&5"
5134case "(($ac_try" in
5135 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5136 *) ac_try_echo=$ac_try;;
5137esac
5138eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5139$as_echo "$ac_try_echo"; } >&5
5140 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
5141 ac_status=$?
5142 if test -s conftest.err; then
5143 sed '10a\
5144... rest of stderr output deleted ...
5145 10q' conftest.err >conftest.er1
5146 cat conftest.er1 >&5
5147 fi
5148 rm -f conftest.er1 conftest.err
5149 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5150 test $ac_status = 0; }
5151done
5152
5153cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5154/* end confdefs.h. */
5155
5156int
5157main (void)
5158{
5159
5160 ;
5161 return 0;
5162}
5163_ACEOF
5164ac_clean_files_save=$ac_clean_files
5165ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
5166# Try to create an executable without -o first, disregard a.out.
5167# It will help us diagnose broken compilers, and finding out an intuition
5168# of exeext.
5169{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
5170$as_echo_n "checking whether the C compiler works... " >&6; }
5171ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
5172
5173# The possible output files:
5174ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
5175
5176ac_rmfiles=
5177for ac_file in $ac_files
5178do
5179 case $ac_file in
5180 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5181 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
5182 esac
5183done
5184rm -f $ac_rmfiles
5185
5186if { { ac_try="$ac_link_default"
5187case "(($ac_try" in
5188 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5189 *) ac_try_echo=$ac_try;;
5190esac
5191eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5192$as_echo "$ac_try_echo"; } >&5
5193 (eval "$ac_link_default") 2>&5
5194 ac_status=$?
5195 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5196 test $ac_status = 0; }; then :
5197 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
5198# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
5199# in a Makefile. We should not override ac_cv_exeext if it was cached,
5200# so that the user can short-circuit this test for compilers unknown to
5201# Autoconf.
5202for ac_file in $ac_files ''
5203do
5204 test -f "$ac_file" || continue
5205 case $ac_file in
5206 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
5207 ;;
5208 [ab].out )
5209 # We found the default executable, but exeext='' is most
5210 # certainly right.
5211 break;;
5212 *.* )
5213 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
5214 then :; else
5215 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5216 fi
5217 # We set ac_cv_exeext here because the later test for it is not
5218 # safe: cross compilers may not add the suffix if given an `-o'
5219 # argument, so we may need to know it at that point already.
5220 # Even if this section looks crufty: it has the advantage of
5221 # actually working.
5222 break;;
5223 * )
5224 break;;
5225 esac
5226done
5227test "$ac_cv_exeext" = no && ac_cv_exeext=
5228
5229else
5230 ac_file=''
5231fi
5232if test -z "$ac_file"; then :
5233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5234$as_echo "no" >&6; }
5235$as_echo "$as_me: failed program was:" >&5
5236sed 's/^/| /' conftest.$ac_ext >&5
5237
5238{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5239$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5240as_fn_error 77 "C compiler cannot create executables
5241See \`config.log' for more details" "$LINENO" 5; }
5242else
5243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5244$as_echo "yes" >&6; }
5245fi
5246{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
5247$as_echo_n "checking for C compiler default output file name... " >&6; }
5248{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
5249$as_echo "$ac_file" >&6; }
5250ac_exeext=$ac_cv_exeext
5251
5252rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
5253ac_clean_files=$ac_clean_files_save
5254{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
5255$as_echo_n "checking for suffix of executables... " >&6; }
5256if { { ac_try="$ac_link"
5257case "(($ac_try" in
5258 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5259 *) ac_try_echo=$ac_try;;
5260esac
5261eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5262$as_echo "$ac_try_echo"; } >&5
5263 (eval "$ac_link") 2>&5
5264 ac_status=$?
5265 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5266 test $ac_status = 0; }; then :
5267 # If both `conftest.exe' and `conftest' are `present' (well, observable)
5268# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
5269# work properly (i.e., refer to `conftest.exe'), while it won't with
5270# `rm'.
5271for ac_file in conftest.exe conftest conftest.*; do
5272 test -f "$ac_file" || continue
5273 case $ac_file in
5274 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5275 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5276 break;;
5277 * ) break;;
5278 esac
5279done
5280else
5281 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5282$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5283as_fn_error $? "cannot compute suffix of executables: cannot compile and link
5284See \`config.log' for more details" "$LINENO" 5; }
5285fi
5286rm -f conftest conftest$ac_cv_exeext
5287{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
5288$as_echo "$ac_cv_exeext" >&6; }
5289
5290rm -f conftest.$ac_ext
5291EXEEXT=$ac_cv_exeext
5292ac_exeext=$EXEEXT
5293cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5294/* end confdefs.h. */
5295#include <stdio.h>
5296int
5297main (void)
5298{
5299FILE *f = fopen ("conftest.out", "w");
5300 return ferror (f) || fclose (f) != 0;
5301
5302 ;
5303 return 0;
5304}
5305_ACEOF
5306ac_clean_files="$ac_clean_files conftest.out"
5307# Check that the compiler produces executables we can run. If not, either
5308# the compiler is broken, or we cross compile.
5309{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
5310$as_echo_n "checking whether we are cross compiling... " >&6; }
5311if test "$cross_compiling" != yes; then
5312 { { ac_try="$ac_link"
5313case "(($ac_try" in
5314 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5315 *) ac_try_echo=$ac_try;;
5316esac
5317eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5318$as_echo "$ac_try_echo"; } >&5
5319 (eval "$ac_link") 2>&5
5320 ac_status=$?
5321 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5322 test $ac_status = 0; }
5323 if { ac_try='./conftest$ac_cv_exeext'
5324 { { case "(($ac_try" in
5325 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5326 *) ac_try_echo=$ac_try;;
5327esac
5328eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5329$as_echo "$ac_try_echo"; } >&5
5330 (eval "$ac_try") 2>&5
5331 ac_status=$?
5332 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5333 test $ac_status = 0; }; }; then
5334 cross_compiling=no
5335 else
5336 if test "$cross_compiling" = maybe; then
5337 cross_compiling=yes
5338 else
5339 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5340$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5341as_fn_error $? "cannot run C compiled programs.
5342If you meant to cross compile, use \`--host'.
5343See \`config.log' for more details" "$LINENO" 5; }
5344 fi
5345 fi
5346fi
5347{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
5348$as_echo "$cross_compiling" >&6; }
5349
5350rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
5351ac_clean_files=$ac_clean_files_save
5352{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
5353$as_echo_n "checking for suffix of object files... " >&6; }
5354if ${ac_cv_objext+:} false; then :
5355 $as_echo_n "(cached) " >&6
5356else
5357 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5358/* end confdefs.h. */
5359
5360int
5361main (void)
5362{
5363
5364 ;
5365 return 0;
5366}
5367_ACEOF
5368rm -f conftest.o conftest.obj
5369if { { ac_try="$ac_compile"
5370case "(($ac_try" in
5371 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5372 *) ac_try_echo=$ac_try;;
5373esac
5374eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5375$as_echo "$ac_try_echo"; } >&5
5376 (eval "$ac_compile") 2>&5
5377 ac_status=$?
5378 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5379 test $ac_status = 0; }; then :
5380 for ac_file in conftest.o conftest.obj conftest.*; do
5381 test -f "$ac_file" || continue;
5382 case $ac_file in
5383 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5384 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5385 break;;
5386 esac
5387done
5388else
5389 $as_echo "$as_me: failed program was:" >&5
5390sed 's/^/| /' conftest.$ac_ext >&5
5391
5392{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5393$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5394as_fn_error $? "cannot compute suffix of object files: cannot compile
5395See \`config.log' for more details" "$LINENO" 5; }
5396fi
5397rm -f conftest.$ac_cv_objext conftest.$ac_ext
5398fi
5399{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5400$as_echo "$ac_cv_objext" >&6; }
5401OBJEXT=$ac_cv_objext
5402ac_objext=$OBJEXT
5403{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5404$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5405if ${ac_cv_c_compiler_gnu+:} false; then :
5406 $as_echo_n "(cached) " >&6
5407else
5408 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5409/* end confdefs.h. */
5410
5411int
5412main (void)
5413{
5414#ifndef __GNUC__
5415 choke me
5416#endif
5417
5418 ;
5419 return 0;
5420}
5421_ACEOF
5422if ac_fn_c_try_compile "$LINENO"; then :
5423 ac_compiler_gnu=yes
5424else
5425 ac_compiler_gnu=no
5426fi
5427rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5428ac_cv_c_compiler_gnu=$ac_compiler_gnu
5429
5430fi
5431{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5432$as_echo "$ac_cv_c_compiler_gnu" >&6; }
5433if test $ac_compiler_gnu = yes; then
5434 GCC=yes
5435else
5436 GCC=
5437fi
5438ac_test_CFLAGS=${CFLAGS+set}
5439ac_save_CFLAGS=$CFLAGS
5440{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5441$as_echo_n "checking whether $CC accepts -g... " >&6; }
5442if ${ac_cv_prog_cc_g+:} false; then :
5443 $as_echo_n "(cached) " >&6
5444else
5445 ac_save_c_werror_flag=$ac_c_werror_flag
5446 ac_c_werror_flag=yes
5447 ac_cv_prog_cc_g=no
5448 CFLAGS="-g"
5449 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5450/* end confdefs.h. */
5451
5452int
5453main (void)
5454{
5455
5456 ;
5457 return 0;
5458}
5459_ACEOF
5460if ac_fn_c_try_compile "$LINENO"; then :
5461 ac_cv_prog_cc_g=yes
5462else
5463 CFLAGS=""
5464 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5465/* end confdefs.h. */
5466
5467int
5468main (void)
5469{
5470
5471 ;
5472 return 0;
5473}
5474_ACEOF
5475if ac_fn_c_try_compile "$LINENO"; then :
5476
5477else
5478 ac_c_werror_flag=$ac_save_c_werror_flag
5479 CFLAGS="-g"
5480 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5481/* end confdefs.h. */
5482
5483int
5484main (void)
5485{
5486
5487 ;
5488 return 0;
5489}
5490_ACEOF
5491if ac_fn_c_try_compile "$LINENO"; then :
5492 ac_cv_prog_cc_g=yes
5493fi
5494rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5495fi
5496rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5497fi
5498rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5499 ac_c_werror_flag=$ac_save_c_werror_flag
5500fi
5501{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5502$as_echo "$ac_cv_prog_cc_g" >&6; }
5503if test "$ac_test_CFLAGS" = set; then
5504 CFLAGS=$ac_save_CFLAGS
5505elif test $ac_cv_prog_cc_g = yes; then
5506 if test "$GCC" = yes; then
5507 CFLAGS="-g -O2"
5508 else
5509 CFLAGS="-g"
5510 fi
5511else
5512 if test "$GCC" = yes; then
5513 CFLAGS="-O2"
5514 else
5515 CFLAGS=
5516 fi
5517fi
5518{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5519$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5520if ${ac_cv_prog_cc_c89+:} false; then :
5521 $as_echo_n "(cached) " >&6
5522else
5523 ac_cv_prog_cc_c89=no
5524ac_save_CC=$CC
5525cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5526/* end confdefs.h. */
5527#include <stdarg.h>
5528#include <stdio.h>
5529struct stat;
5530/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5531struct buf { int x; };
5532FILE * (*rcsopen) (struct buf *, struct stat *, int);
5533static char *e (p, i)
5534 char **p;
5535 int i;
5536{
5537 return p[i];
5538}
5539static char *f (char * (*g) (char **, int), char **p, ...)
5540{
5541 char *s;
5542 va_list v;
5543 va_start (v,p);
5544 s = g (p, va_arg (v,int));
5545 va_end (v);
5546 return s;
5547}
5548
5549/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5550 function prototypes and stuff, but not '\xHH' hex character constants.
5551 These don't provoke an error unfortunately, instead are silently treated
5552 as 'x'. The following induces an error, until -std is added to get
5553 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5554 array size at least. It's necessary to write '\x00'==0 to get something
5555 that's true only with -std. */
5556int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5557
5558/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5559 inside strings and character constants. */
5560#define FOO(x) 'x'
5561int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5562
5563int test (int i, double x);
5564struct s1 {int (*f) (int a);};
5565struct s2 {int (*f) (double a);};
5566int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5567int argc;
5568char **argv;
5569int
5570main (void)
5571{
5572return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5573 ;
5574 return 0;
5575}
5576_ACEOF
5577for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5578 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5579do
5580 CC="$ac_save_CC $ac_arg"
5581 if ac_fn_c_try_compile "$LINENO"; then :
5582 ac_cv_prog_cc_c89=$ac_arg
5583fi
5584rm -f core conftest.err conftest.$ac_objext
5585 test "x$ac_cv_prog_cc_c89" != "xno" && break
5586done
5587rm -f conftest.$ac_ext
5588CC=$ac_save_CC
5589
5590fi
5591# AC_CACHE_VAL
5592case "x$ac_cv_prog_cc_c89" in
5593 x)
5594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5595$as_echo "none needed" >&6; } ;;
5596 xno)
5597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5598$as_echo "unsupported" >&6; } ;;
5599 *)
5600 CC="$CC $ac_cv_prog_cc_c89"
5601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5602$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5603esac
5604if test "x$ac_cv_prog_cc_c89" != xno; then :
5605
5606fi
5607
5608ac_ext=c
5609ac_cpp='$CPP $CPPFLAGS'
5610ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5611ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5612ac_compiler_gnu=$ac_cv_c_compiler_gnu
5613
5614ac_ext=c
5615ac_cpp='$CPP $CPPFLAGS'
5616ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5617ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5618ac_compiler_gnu=$ac_cv_c_compiler_gnu
5619{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
5620$as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
5621if ${am_cv_prog_cc_c_o+:} false; then :
5622 $as_echo_n "(cached) " >&6
5623else
5624 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5625/* end confdefs.h. */
5626
5627int
5628main (void)
5629{
5630
5631 ;
5632 return 0;
5633}
5634_ACEOF
5635 # Make sure it works both with $CC and with simple cc.
5636 # Following AC_PROG_CC_C_O, we do the test twice because some
5637 # compilers refuse to overwrite an existing .o file with -o,
5638 # though they will create one.
5639 am_cv_prog_cc_c_o=yes
5640 for am_i in 1 2; do
5641 if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
5642 ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
5643 ac_status=$?
5644 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5645 (exit $ac_status); } \
5646 && test -f conftest2.$ac_objext; then
5647 : OK
5648 else
5649 am_cv_prog_cc_c_o=no
5650 break
5651 fi
5652 done
5653 rm -f core conftest*
5654 unset am_i
5655fi
5656{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
5657$as_echo "$am_cv_prog_cc_c_o" >&6; }
5658if test "$am_cv_prog_cc_c_o" != yes; then
5659 # Losing compiler, so override with the script.
5660 # FIXME: It is wrong to rewrite CC.
5661 # But if we don't then we get into trouble of one sort or another.
5662 # A longer-term fix would be to have automake use am__CC in this case,
5663 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5664 CC="$am_aux_dir/compile $CC"
5665fi
5666ac_ext=c
5667ac_cpp='$CPP $CPPFLAGS'
5668ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5669ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5670ac_compiler_gnu=$ac_cv_c_compiler_gnu
5671
5672
5673depcc="$CC" am_compiler_list=
5674
5675{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5676$as_echo_n "checking dependency style of $depcc... " >&6; }
5677if ${am_cv_CC_dependencies_compiler_type+:} false; then :
5678 $as_echo_n "(cached) " >&6
5679else
5680 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5681 # We make a subdir and do the tests there. Otherwise we can end up
5682 # making bogus files that we don't know about and never remove. For
5683 # instance it was reported that on HP-UX the gcc test will end up
5684 # making a dummy file named 'D' -- because '-MD' means "put the output
5685 # in D".
5686 rm -rf conftest.dir
5687 mkdir conftest.dir
5688 # Copy depcomp to subdir because otherwise we won't find it if we're
5689 # using a relative directory.
5690 cp "$am_depcomp" conftest.dir
5691 cd conftest.dir
5692 # We will build objects and dependencies in a subdirectory because
5693 # it helps to detect inapplicable dependency modes. For instance
5694 # both Tru64's cc and ICC support -MD to output dependencies as a
5695 # side effect of compilation, but ICC will put the dependencies in
5696 # the current directory while Tru64 will put them in the object
5697 # directory.
5698 mkdir sub
5699
5700 am_cv_CC_dependencies_compiler_type=none
5701 if test "$am_compiler_list" = ""; then
5702 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5703 fi
5704 am__universal=false
5705 case " $depcc " in #(
5706 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5707 esac
5708
5709 for depmode in $am_compiler_list; do
5710 # Setup a source with many dependencies, because some compilers
5711 # like to wrap large dependency lists on column 80 (with \), and
5712 # we should not choose a depcomp mode which is confused by this.
5713 #
5714 # We need to recreate these files for each test, as the compiler may
5715 # overwrite some of them when testing with obscure command lines.
5716 # This happens at least with the AIX C compiler.
5717 : > sub/conftest.c
5718 for i in 1 2 3 4 5 6; do
5719 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5720 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
5721 # Solaris 10 /bin/sh.
5722 echo '/* dummy */' > sub/conftst$i.h
5723 done
5724 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5725
5726 # We check with '-c' and '-o' for the sake of the "dashmstdout"
5727 # mode. It turns out that the SunPro C++ compiler does not properly
5728 # handle '-M -o', and we need to detect this. Also, some Intel
5729 # versions had trouble with output in subdirs.
5730 am__obj=sub/conftest.${OBJEXT-o}
5731 am__minus_obj="-o $am__obj"
5732 case $depmode in
5733 gcc)
5734 # This depmode causes a compiler race in universal mode.
5735 test "$am__universal" = false || continue
5736 ;;
5737 nosideeffect)
5738 # After this tag, mechanisms are not by side-effect, so they'll
5739 # only be used when explicitly requested.
5740 if test "x$enable_dependency_tracking" = xyes; then
5741 continue
5742 else
5743 break
5744 fi
5745 ;;
5746 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
5747 # This compiler won't grok '-c -o', but also, the minuso test has
5748 # not run yet. These depmodes are late enough in the game, and
5749 # so weak that their functioning should not be impacted.
5750 am__obj=conftest.${OBJEXT-o}
5751 am__minus_obj=
5752 ;;
5753 none) break ;;
5754 esac
5755 if depmode=$depmode \
5756 source=sub/conftest.c object=$am__obj \
5757 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5758 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5759 >/dev/null 2>conftest.err &&
5760 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5761 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5762 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5763 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5764 # icc doesn't choke on unknown options, it will just issue warnings
5765 # or remarks (even with -Werror). So we grep stderr for any message
5766 # that says an option was ignored or not supported.
5767 # When given -MP, icc 7.0 and 7.1 complain thusly:
5768 # icc: Command line warning: ignoring option '-M'; no argument required
5769 # The diagnosis changed in icc 8.0:
5770 # icc: Command line remark: option '-MP' not supported
5771 if (grep 'ignoring option' conftest.err ||
5772 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5773 am_cv_CC_dependencies_compiler_type=$depmode
5774 break
5775 fi
5776 fi
5777 done
5778
5779 cd ..
5780 rm -rf conftest.dir
5781else
5782 am_cv_CC_dependencies_compiler_type=none
5783fi
5784
5785fi
5786{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5787$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5788CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5789
5790 if
5791 test "x$enable_dependency_tracking" != xno \
5792 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5793 am__fastdepCC_TRUE=
5794 am__fastdepCC_FALSE='#'
5795else
5796 am__fastdepCC_TRUE='#'
5797 am__fastdepCC_FALSE=
5798fi
5799
5800
5801
5802for ac_prog in flex lex
5803do
5804 # Extract the first word of "$ac_prog", so it can be a program name with args.
5805set dummy $ac_prog; ac_word=$2
5806{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5807$as_echo_n "checking for $ac_word... " >&6; }
5808if ${ac_cv_prog_LEX+:} false; then :
5809 $as_echo_n "(cached) " >&6
5810else
5811 if test -n "$LEX"; then
5812 ac_cv_prog_LEX="$LEX" # Let the user override the test.
5813else
5814as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5815for as_dir in $PATH
5816do
5817 IFS=$as_save_IFS
5818 test -z "$as_dir" && as_dir=.
5819 for ac_exec_ext in '' $ac_executable_extensions; do
5820 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5821 ac_cv_prog_LEX="$ac_prog"
5822 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5823 break 2
5824 fi
5825done
5826 done
5827IFS=$as_save_IFS
5828
5829fi
5830fi
5831LEX=$ac_cv_prog_LEX
5832if test -n "$LEX"; then
5833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LEX" >&5
5834$as_echo "$LEX" >&6; }
5835else
5836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5837$as_echo "no" >&6; }
5838fi
5839
5840
5841 test -n "$LEX" && break
5842done
5843test -n "$LEX" || LEX=":"
5844
5845if test "x$LEX" != "x:"; then
5846 cat >conftest.l <<_ACEOF
5847%%
5848a { ECHO; }
5849b { REJECT; }
5850c { yymore (); }
5851d { yyless (1); }
5852e { /* IRIX 6.5 flex 2.5.4 underquotes its yyless argument. */
5853 yyless ((input () != 0)); }
5854f { unput (yytext[0]); }
5855. { BEGIN INITIAL; }
5856%%
5857#ifdef YYTEXT_POINTER
5858extern char *yytext;
5859#endif
5860int
5861main (void)
5862{
5863 return ! yylex () + ! yywrap ();
5864}
5865_ACEOF
5866{ { ac_try="$LEX conftest.l"
5867case "(($ac_try" in
5868 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5869 *) ac_try_echo=$ac_try;;
5870esac
5871eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5872$as_echo "$ac_try_echo"; } >&5
5873 (eval "$LEX conftest.l") 2>&5
5874 ac_status=$?
5875 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5876 test $ac_status = 0; }
5877{ $as_echo "$as_me:${as_lineno-$LINENO}: checking lex output file root" >&5
5878$as_echo_n "checking lex output file root... " >&6; }
5879if ${ac_cv_prog_lex_root+:} false; then :
5880 $as_echo_n "(cached) " >&6
5881else
5882
5883if test -f lex.yy.c; then
5884 ac_cv_prog_lex_root=lex.yy
5885elif test -f lexyy.c; then
5886 ac_cv_prog_lex_root=lexyy
5887else
5888 as_fn_error $? "cannot find output from $LEX; giving up" "$LINENO" 5
5889fi
5890fi
5891{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_root" >&5
5892$as_echo "$ac_cv_prog_lex_root" >&6; }
5893LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
5894
5895if test -z "${LEXLIB+set}"; then
5896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking lex library" >&5
5897$as_echo_n "checking lex library... " >&6; }
5898if ${ac_cv_lib_lex+:} false; then :
5899 $as_echo_n "(cached) " >&6
5900else
5901
5902 ac_save_LIBS=$LIBS
5903 ac_cv_lib_lex='none needed'
5904 for ac_lib in '' -lfl -ll; do
5905 LIBS="$ac_lib $ac_save_LIBS"
5906 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5907/* end confdefs.h. */
5908`cat $LEX_OUTPUT_ROOT.c`
5909_ACEOF
5910if ac_fn_c_try_link "$LINENO"; then :
5911 ac_cv_lib_lex=$ac_lib
5912fi
5913rm -f core conftest.err conftest.$ac_objext \
5914 conftest$ac_exeext conftest.$ac_ext
5915 test "$ac_cv_lib_lex" != 'none needed' && break
5916 done
5917 LIBS=$ac_save_LIBS
5918
5919fi
5920{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lex" >&5
5921$as_echo "$ac_cv_lib_lex" >&6; }
5922 test "$ac_cv_lib_lex" != 'none needed' && LEXLIB=$ac_cv_lib_lex
5923fi
5924
5925
5926{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether yytext is a pointer" >&5
5927$as_echo_n "checking whether yytext is a pointer... " >&6; }
5928if ${ac_cv_prog_lex_yytext_pointer+:} false; then :
5929 $as_echo_n "(cached) " >&6
5930else
5931 # POSIX says lex can declare yytext either as a pointer or an array; the
5932# default is implementation-dependent. Figure out which it is, since
5933# not all implementations provide the %pointer and %array declarations.
5934ac_cv_prog_lex_yytext_pointer=no
5935ac_save_LIBS=$LIBS
5936LIBS="$LEXLIB $ac_save_LIBS"
5937cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5938/* end confdefs.h. */
5939
5940 #define YYTEXT_POINTER 1
5941`cat $LEX_OUTPUT_ROOT.c`
5942_ACEOF
5943if ac_fn_c_try_link "$LINENO"; then :
5944 ac_cv_prog_lex_yytext_pointer=yes
5945fi
5946rm -f core conftest.err conftest.$ac_objext \
5947 conftest$ac_exeext conftest.$ac_ext
5948LIBS=$ac_save_LIBS
5949
5950fi
5951{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_yytext_pointer" >&5
5952$as_echo "$ac_cv_prog_lex_yytext_pointer" >&6; }
5953if test $ac_cv_prog_lex_yytext_pointer = yes; then
5954
5955$as_echo "#define YYTEXT_POINTER 1" >>confdefs.h
5956
5957fi
5958rm -f conftest.l $LEX_OUTPUT_ROOT.c
5959
5960fi
5961for ac_prog in 'bison -y' byacc
5962do
5963 # Extract the first word of "$ac_prog", so it can be a program name with args.
5964set dummy $ac_prog; ac_word=$2
5965{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5966$as_echo_n "checking for $ac_word... " >&6; }
5967if ${ac_cv_prog_YACC+:} false; then :
5968 $as_echo_n "(cached) " >&6
5969else
5970 if test -n "$YACC"; then
5971 ac_cv_prog_YACC="$YACC" # Let the user override the test.
5972else
5973as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5974for as_dir in $PATH
5975do
5976 IFS=$as_save_IFS
5977 test -z "$as_dir" && as_dir=.
5978 for ac_exec_ext in '' $ac_executable_extensions; do
5979 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5980 ac_cv_prog_YACC="$ac_prog"
5981 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5982 break 2
5983 fi
5984done
5985 done
5986IFS=$as_save_IFS
5987
5988fi
5989fi
5990YACC=$ac_cv_prog_YACC
5991if test -n "$YACC"; then
5992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
5993$as_echo "$YACC" >&6; }
5994else
5995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5996$as_echo "no" >&6; }
5997fi
5998
5999
6000 test -n "$YACC" && break
6001done
6002test -n "$YACC" || YACC="yacc"
6003
6004{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
6005$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
6006set x ${MAKE-make}
6007ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
6008if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
6009 $as_echo_n "(cached) " >&6
6010else
6011 cat >conftest.make <<\_ACEOF
6012SHELL = /bin/sh
6013all:
6014 @echo '@@@%%%=$(MAKE)=@@@%%%'
6015_ACEOF
6016# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
6017case `${MAKE-make} -f conftest.make 2>/dev/null` in
6018 *@@@%%%=?*=@@@%%%*)
6019 eval ac_cv_prog_make_${ac_make}_set=yes;;
6020 *)
6021 eval ac_cv_prog_make_${ac_make}_set=no;;
6022esac
6023rm -f conftest.make
6024fi
6025if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
6026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6027$as_echo "yes" >&6; }
6028 SET_MAKE=
6029else
6030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6031$as_echo "no" >&6; }
6032 SET_MAKE="MAKE=${MAKE-make}"
6033fi
6034
6035
6036{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
6037$as_echo_n "checking whether ln -s works... " >&6; }
6038LN_S=$as_ln_s
6039if test "$LN_S" = "ln -s"; then
6040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6041$as_echo "yes" >&6; }
6042else
6043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
6044$as_echo "no, using $LN_S" >&6; }
6045fi
6046
6047
6048if test "x$LEX" = "x:"; then
6049 as_fn_error $? "flex is not found" "$LINENO" 5
6050else
6051 version=`$LEX --version | $AWK '{ split($2,x,"."); print x[1]*10000+x[2]*100+x[3]; }'`
6052 if test -n "$version" -a "$version" -ge 20535; then
6053 :
6054 else
6055 as_fn_error $? "flex is too old. GRUB requires 2.5.35 or above" "$LINENO" 5
6056 fi
6057fi
6058
6059# These are not a "must".
6060for ac_prog in makeinfo true
6061do
6062 # Extract the first word of "$ac_prog", so it can be a program name with args.
6063set dummy $ac_prog; ac_word=$2
6064{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6065$as_echo_n "checking for $ac_word... " >&6; }
6066if ${ac_cv_path_MAKEINFO+:} false; then :
6067 $as_echo_n "(cached) " >&6
6068else
6069 case $MAKEINFO in
6070 [\\/]* | ?:[\\/]*)
6071 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
6072 ;;
6073 *)
6074 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6075for as_dir in $PATH
6076do
6077 IFS=$as_save_IFS
6078 test -z "$as_dir" && as_dir=.
6079 for ac_exec_ext in '' $ac_executable_extensions; do
6080 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6081 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
6082 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6083 break 2
6084 fi
6085done
6086 done
6087IFS=$as_save_IFS
6088
6089 ;;
6090esac
6091fi
6092MAKEINFO=$ac_cv_path_MAKEINFO
6093if test -n "$MAKEINFO"; then
6094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
6095$as_echo "$MAKEINFO" >&6; }
6096else
6097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6098$as_echo "no" >&6; }
6099fi
6100
6101
6102 test -n "$MAKEINFO" && break
6103done
6104
6105
6106#
6107# Checks for host programs.
6108#
6109
6110ac_ext=c
6111ac_cpp='$CPP $CPPFLAGS'
6112ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6113ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6114ac_compiler_gnu=$ac_cv_c_compiler_gnu
6115if test -n "$ac_tool_prefix"; then
6116 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
6117set dummy ${ac_tool_prefix}gcc; ac_word=$2
6118{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6119$as_echo_n "checking for $ac_word... " >&6; }
6120if ${ac_cv_prog_CC+:} false; then :
6121 $as_echo_n "(cached) " >&6
6122else
6123 if test -n "$CC"; then
6124 ac_cv_prog_CC="$CC" # Let the user override the test.
6125else
6126as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6127for as_dir in $PATH
6128do
6129 IFS=$as_save_IFS
6130 test -z "$as_dir" && as_dir=.
6131 for ac_exec_ext in '' $ac_executable_extensions; do
6132 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6133 ac_cv_prog_CC="${ac_tool_prefix}gcc"
6134 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6135 break 2
6136 fi
6137done
6138 done
6139IFS=$as_save_IFS
6140
6141fi
6142fi
6143CC=$ac_cv_prog_CC
6144if test -n "$CC"; then
6145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
6146$as_echo "$CC" >&6; }
6147else
6148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6149$as_echo "no" >&6; }
6150fi
6151
6152
6153fi
6154if test -z "$ac_cv_prog_CC"; then
6155 ac_ct_CC=$CC
6156 # Extract the first word of "gcc", so it can be a program name with args.
6157set dummy gcc; ac_word=$2
6158{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6159$as_echo_n "checking for $ac_word... " >&6; }
6160if ${ac_cv_prog_ac_ct_CC+:} false; then :
6161 $as_echo_n "(cached) " >&6
6162else
6163 if test -n "$ac_ct_CC"; then
6164 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
6165else
6166as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6167for as_dir in $PATH
6168do
6169 IFS=$as_save_IFS
6170 test -z "$as_dir" && as_dir=.
6171 for ac_exec_ext in '' $ac_executable_extensions; do
6172 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6173 ac_cv_prog_ac_ct_CC="gcc"
6174 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6175 break 2
6176 fi
6177done
6178 done
6179IFS=$as_save_IFS
6180
6181fi
6182fi
6183ac_ct_CC=$ac_cv_prog_ac_ct_CC
6184if test -n "$ac_ct_CC"; then
6185 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
6186$as_echo "$ac_ct_CC" >&6; }
6187else
6188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6189$as_echo "no" >&6; }
6190fi
6191
6192 if test "x$ac_ct_CC" = x; then
6193 CC=""
6194 else
6195 case $cross_compiling:$ac_tool_warned in
6196yes:)
6197{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6198$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6199ac_tool_warned=yes ;;
6200esac
6201 CC=$ac_ct_CC
6202 fi
6203else
6204 CC="$ac_cv_prog_CC"
6205fi
6206
6207if test -z "$CC"; then
6208 if test -n "$ac_tool_prefix"; then
6209 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
6210set dummy ${ac_tool_prefix}cc; ac_word=$2
6211{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6212$as_echo_n "checking for $ac_word... " >&6; }
6213if ${ac_cv_prog_CC+:} false; then :
6214 $as_echo_n "(cached) " >&6
6215else
6216 if test -n "$CC"; then
6217 ac_cv_prog_CC="$CC" # Let the user override the test.
6218else
6219as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6220for as_dir in $PATH
6221do
6222 IFS=$as_save_IFS
6223 test -z "$as_dir" && as_dir=.
6224 for ac_exec_ext in '' $ac_executable_extensions; do
6225 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6226 ac_cv_prog_CC="${ac_tool_prefix}cc"
6227 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6228 break 2
6229 fi
6230done
6231 done
6232IFS=$as_save_IFS
6233
6234fi
6235fi
6236CC=$ac_cv_prog_CC
6237if test -n "$CC"; then
6238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
6239$as_echo "$CC" >&6; }
6240else
6241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6242$as_echo "no" >&6; }
6243fi
6244
6245
6246 fi
6247fi
6248if test -z "$CC"; then
6249 # Extract the first word of "cc", so it can be a program name with args.
6250set dummy cc; ac_word=$2
6251{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6252$as_echo_n "checking for $ac_word... " >&6; }
6253if ${ac_cv_prog_CC+:} false; then :
6254 $as_echo_n "(cached) " >&6
6255else
6256 if test -n "$CC"; then
6257 ac_cv_prog_CC="$CC" # Let the user override the test.
6258else
6259 ac_prog_rejected=no
6260as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6261for as_dir in $PATH
6262do
6263 IFS=$as_save_IFS
6264 test -z "$as_dir" && as_dir=.
6265 for ac_exec_ext in '' $ac_executable_extensions; do
6266 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6267 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
6268 ac_prog_rejected=yes
6269 continue
6270 fi
6271 ac_cv_prog_CC="cc"
6272 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6273 break 2
6274 fi
6275done
6276 done
6277IFS=$as_save_IFS
6278
6279if test $ac_prog_rejected = yes; then
6280 # We found a bogon in the path, so make sure we never use it.
6281 set dummy $ac_cv_prog_CC
6282 shift
6283 if test $# != 0; then
6284 # We chose a different compiler from the bogus one.
6285 # However, it has the same basename, so the bogon will be chosen
6286 # first if we set CC to just the basename; use the full file name.
6287 shift
6288 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
6289 fi
6290fi
6291fi
6292fi
6293CC=$ac_cv_prog_CC
6294if test -n "$CC"; then
6295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
6296$as_echo "$CC" >&6; }
6297else
6298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6299$as_echo "no" >&6; }
6300fi
6301
6302
6303fi
6304if test -z "$CC"; then
6305 if test -n "$ac_tool_prefix"; then
6306 for ac_prog in cl.exe
6307 do
6308 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
6309set dummy $ac_tool_prefix$ac_prog; ac_word=$2
6310{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6311$as_echo_n "checking for $ac_word... " >&6; }
6312if ${ac_cv_prog_CC+:} false; then :
6313 $as_echo_n "(cached) " >&6
6314else
6315 if test -n "$CC"; then
6316 ac_cv_prog_CC="$CC" # Let the user override the test.
6317else
6318as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6319for as_dir in $PATH
6320do
6321 IFS=$as_save_IFS
6322 test -z "$as_dir" && as_dir=.
6323 for ac_exec_ext in '' $ac_executable_extensions; do
6324 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6325 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
6326 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6327 break 2
6328 fi
6329done
6330 done
6331IFS=$as_save_IFS
6332
6333fi
6334fi
6335CC=$ac_cv_prog_CC
6336if test -n "$CC"; then
6337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
6338$as_echo "$CC" >&6; }
6339else
6340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6341$as_echo "no" >&6; }
6342fi
6343
6344
6345 test -n "$CC" && break
6346 done
6347fi
6348if test -z "$CC"; then
6349 ac_ct_CC=$CC
6350 for ac_prog in cl.exe
6351do
6352 # Extract the first word of "$ac_prog", so it can be a program name with args.
6353set dummy $ac_prog; ac_word=$2
6354{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6355$as_echo_n "checking for $ac_word... " >&6; }
6356if ${ac_cv_prog_ac_ct_CC+:} false; then :
6357 $as_echo_n "(cached) " >&6
6358else
6359 if test -n "$ac_ct_CC"; then
6360 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
6361else
6362as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6363for as_dir in $PATH
6364do
6365 IFS=$as_save_IFS
6366 test -z "$as_dir" && as_dir=.
6367 for ac_exec_ext in '' $ac_executable_extensions; do
6368 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6369 ac_cv_prog_ac_ct_CC="$ac_prog"
6370 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6371 break 2
6372 fi
6373done
6374 done
6375IFS=$as_save_IFS
6376
6377fi
6378fi
6379ac_ct_CC=$ac_cv_prog_ac_ct_CC
6380if test -n "$ac_ct_CC"; then
6381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
6382$as_echo "$ac_ct_CC" >&6; }
6383else
6384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6385$as_echo "no" >&6; }
6386fi
6387
6388
6389 test -n "$ac_ct_CC" && break
6390done
6391
6392 if test "x$ac_ct_CC" = x; then
6393 CC=""
6394 else
6395 case $cross_compiling:$ac_tool_warned in
6396yes:)
6397{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6398$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6399ac_tool_warned=yes ;;
6400esac
6401 CC=$ac_ct_CC
6402 fi
6403fi
6404
6405fi
6406
6407
6408test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6409$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6410as_fn_error $? "no acceptable C compiler found in \$PATH
6411See \`config.log' for more details" "$LINENO" 5; }
6412
6413# Provide some information about the compiler.
6414$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
6415set X $ac_compile
6416ac_compiler=$2
6417for ac_option in --version -v -V -qversion; do
6418 { { ac_try="$ac_compiler $ac_option >&5"
6419case "(($ac_try" in
6420 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6421 *) ac_try_echo=$ac_try;;
6422esac
6423eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
6424$as_echo "$ac_try_echo"; } >&5
6425 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
6426 ac_status=$?
6427 if test -s conftest.err; then
6428 sed '10a\
6429... rest of stderr output deleted ...
6430 10q' conftest.err >conftest.er1
6431 cat conftest.er1 >&5
6432 fi
6433 rm -f conftest.er1 conftest.err
6434 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6435 test $ac_status = 0; }
6436done
6437
6438{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
6439$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
6440if ${ac_cv_c_compiler_gnu+:} false; then :
6441 $as_echo_n "(cached) " >&6
6442else
6443 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6444/* end confdefs.h. */
6445
6446int
6447main (void)
6448{
6449#ifndef __GNUC__
6450 choke me
6451#endif
6452
6453 ;
6454 return 0;
6455}
6456_ACEOF
6457if ac_fn_c_try_compile "$LINENO"; then :
6458 ac_compiler_gnu=yes
6459else
6460 ac_compiler_gnu=no
6461fi
6462rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6463ac_cv_c_compiler_gnu=$ac_compiler_gnu
6464
6465fi
6466{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
6467$as_echo "$ac_cv_c_compiler_gnu" >&6; }
6468if test $ac_compiler_gnu = yes; then
6469 GCC=yes
6470else
6471 GCC=
6472fi
6473ac_test_CFLAGS=${CFLAGS+set}
6474ac_save_CFLAGS=$CFLAGS
6475{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
6476$as_echo_n "checking whether $CC accepts -g... " >&6; }
6477if ${ac_cv_prog_cc_g+:} false; then :
6478 $as_echo_n "(cached) " >&6
6479else
6480 ac_save_c_werror_flag=$ac_c_werror_flag
6481 ac_c_werror_flag=yes
6482 ac_cv_prog_cc_g=no
6483 CFLAGS="-g"
6484 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6485/* end confdefs.h. */
6486
6487int
6488main (void)
6489{
6490
6491 ;
6492 return 0;
6493}
6494_ACEOF
6495if ac_fn_c_try_compile "$LINENO"; then :
6496 ac_cv_prog_cc_g=yes
6497else
6498 CFLAGS=""
6499 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6500/* end confdefs.h. */
6501
6502int
6503main (void)
6504{
6505
6506 ;
6507 return 0;
6508}
6509_ACEOF
6510if ac_fn_c_try_compile "$LINENO"; then :
6511
6512else
6513 ac_c_werror_flag=$ac_save_c_werror_flag
6514 CFLAGS="-g"
6515 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6516/* end confdefs.h. */
6517
6518int
6519main (void)
6520{
6521
6522 ;
6523 return 0;
6524}
6525_ACEOF
6526if ac_fn_c_try_compile "$LINENO"; then :
6527 ac_cv_prog_cc_g=yes
6528fi
6529rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6530fi
6531rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6532fi
6533rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6534 ac_c_werror_flag=$ac_save_c_werror_flag
6535fi
6536{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
6537$as_echo "$ac_cv_prog_cc_g" >&6; }
6538if test "$ac_test_CFLAGS" = set; then
6539 CFLAGS=$ac_save_CFLAGS
6540elif test $ac_cv_prog_cc_g = yes; then
6541 if test "$GCC" = yes; then
6542 CFLAGS="-g -O2"
6543 else
6544 CFLAGS="-g"
6545 fi
6546else
6547 if test "$GCC" = yes; then
6548 CFLAGS="-O2"
6549 else
6550 CFLAGS=
6551 fi
6552fi
6553{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
6554$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
6555if ${ac_cv_prog_cc_c89+:} false; then :
6556 $as_echo_n "(cached) " >&6
6557else
6558 ac_cv_prog_cc_c89=no
6559ac_save_CC=$CC
6560cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6561/* end confdefs.h. */
6562#include <stdarg.h>
6563#include <stdio.h>
6564struct stat;
6565/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
6566struct buf { int x; };
6567FILE * (*rcsopen) (struct buf *, struct stat *, int);
6568static char *e (p, i)
6569 char **p;
6570 int i;
6571{
6572 return p[i];
6573}
6574static char *f (char * (*g) (char **, int), char **p, ...)
6575{
6576 char *s;
6577 va_list v;
6578 va_start (v,p);
6579 s = g (p, va_arg (v,int));
6580 va_end (v);
6581 return s;
6582}
6583
6584/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
6585 function prototypes and stuff, but not '\xHH' hex character constants.
6586 These don't provoke an error unfortunately, instead are silently treated
6587 as 'x'. The following induces an error, until -std is added to get
6588 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
6589 array size at least. It's necessary to write '\x00'==0 to get something
6590 that's true only with -std. */
6591int osf4_cc_array ['\x00' == 0 ? 1 : -1];
6592
6593/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
6594 inside strings and character constants. */
6595#define FOO(x) 'x'
6596int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
6597
6598int test (int i, double x);
6599struct s1 {int (*f) (int a);};
6600struct s2 {int (*f) (double a);};
6601int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
6602int argc;
6603char **argv;
6604int
6605main (void)
6606{
6607return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
6608 ;
6609 return 0;
6610}
6611_ACEOF
6612for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
6613 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
6614do
6615 CC="$ac_save_CC $ac_arg"
6616 if ac_fn_c_try_compile "$LINENO"; then :
6617 ac_cv_prog_cc_c89=$ac_arg
6618fi
6619rm -f core conftest.err conftest.$ac_objext
6620 test "x$ac_cv_prog_cc_c89" != "xno" && break
6621done
6622rm -f conftest.$ac_ext
6623CC=$ac_save_CC
6624
6625fi
6626# AC_CACHE_VAL
6627case "x$ac_cv_prog_cc_c89" in
6628 x)
6629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6630$as_echo "none needed" >&6; } ;;
6631 xno)
6632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6633$as_echo "unsupported" >&6; } ;;
6634 *)
6635 CC="$CC $ac_cv_prog_cc_c89"
6636 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
6637$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
6638esac
6639if test "x$ac_cv_prog_cc_c89" != xno; then :
6640
6641fi
6642
6643ac_ext=c
6644ac_cpp='$CPP $CPPFLAGS'
6645ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6646ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6647ac_compiler_gnu=$ac_cv_c_compiler_gnu
6648
6649ac_ext=c
6650ac_cpp='$CPP $CPPFLAGS'
6651ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6652ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6653ac_compiler_gnu=$ac_cv_c_compiler_gnu
6654{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
6655$as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
6656if ${am_cv_prog_cc_c_o+:} false; then :
6657 $as_echo_n "(cached) " >&6
6658else
6659 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6660/* end confdefs.h. */
6661
6662int
6663main (void)
6664{
6665
6666 ;
6667 return 0;
6668}
6669_ACEOF
6670 # Make sure it works both with $CC and with simple cc.
6671 # Following AC_PROG_CC_C_O, we do the test twice because some
6672 # compilers refuse to overwrite an existing .o file with -o,
6673 # though they will create one.
6674 am_cv_prog_cc_c_o=yes
6675 for am_i in 1 2; do
6676 if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
6677 ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
6678 ac_status=$?
6679 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6680 (exit $ac_status); } \
6681 && test -f conftest2.$ac_objext; then
6682 : OK
6683 else
6684 am_cv_prog_cc_c_o=no
6685 break
6686 fi
6687 done
6688 rm -f core conftest*
6689 unset am_i
6690fi
6691{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
6692$as_echo "$am_cv_prog_cc_c_o" >&6; }
6693if test "$am_cv_prog_cc_c_o" != yes; then
6694 # Losing compiler, so override with the script.
6695 # FIXME: It is wrong to rewrite CC.
6696 # But if we don't then we get into trouble of one sort or another.
6697 # A longer-term fix would be to have automake use am__CC in this case,
6698 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
6699 CC="$am_aux_dir/compile $CC"
6700fi
6701ac_ext=c
6702ac_cpp='$CPP $CPPFLAGS'
6703ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6704ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6705ac_compiler_gnu=$ac_cv_c_compiler_gnu
6706
6707
6708depcc="$CC" am_compiler_list=
6709
6710{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
6711$as_echo_n "checking dependency style of $depcc... " >&6; }
6712if ${am_cv_CC_dependencies_compiler_type+:} false; then :
6713 $as_echo_n "(cached) " >&6
6714else
6715 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
6716 # We make a subdir and do the tests there. Otherwise we can end up
6717 # making bogus files that we don't know about and never remove. For
6718 # instance it was reported that on HP-UX the gcc test will end up
6719 # making a dummy file named 'D' -- because '-MD' means "put the output
6720 # in D".
6721 rm -rf conftest.dir
6722 mkdir conftest.dir
6723 # Copy depcomp to subdir because otherwise we won't find it if we're
6724 # using a relative directory.
6725 cp "$am_depcomp" conftest.dir
6726 cd conftest.dir
6727 # We will build objects and dependencies in a subdirectory because
6728 # it helps to detect inapplicable dependency modes. For instance
6729 # both Tru64's cc and ICC support -MD to output dependencies as a
6730 # side effect of compilation, but ICC will put the dependencies in
6731 # the current directory while Tru64 will put them in the object
6732 # directory.
6733 mkdir sub
6734
6735 am_cv_CC_dependencies_compiler_type=none
6736 if test "$am_compiler_list" = ""; then
6737 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
6738 fi
6739 am__universal=false
6740 case " $depcc " in #(
6741 *\ -arch\ *\ -arch\ *) am__universal=true ;;
6742 esac
6743
6744 for depmode in $am_compiler_list; do
6745 # Setup a source with many dependencies, because some compilers
6746 # like to wrap large dependency lists on column 80 (with \), and
6747 # we should not choose a depcomp mode which is confused by this.
6748 #
6749 # We need to recreate these files for each test, as the compiler may
6750 # overwrite some of them when testing with obscure command lines.
6751 # This happens at least with the AIX C compiler.
6752 : > sub/conftest.c
6753 for i in 1 2 3 4 5 6; do
6754 echo '#include "conftst'$i'.h"' >> sub/conftest.c
6755 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
6756 # Solaris 10 /bin/sh.
6757 echo '/* dummy */' > sub/conftst$i.h
6758 done
6759 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
6760
6761 # We check with '-c' and '-o' for the sake of the "dashmstdout"
6762 # mode. It turns out that the SunPro C++ compiler does not properly
6763 # handle '-M -o', and we need to detect this. Also, some Intel
6764 # versions had trouble with output in subdirs.
6765 am__obj=sub/conftest.${OBJEXT-o}
6766 am__minus_obj="-o $am__obj"
6767 case $depmode in
6768 gcc)
6769 # This depmode causes a compiler race in universal mode.
6770 test "$am__universal" = false || continue
6771 ;;
6772 nosideeffect)
6773 # After this tag, mechanisms are not by side-effect, so they'll
6774 # only be used when explicitly requested.
6775 if test "x$enable_dependency_tracking" = xyes; then
6776 continue
6777 else
6778 break
6779 fi
6780 ;;
6781 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
6782 # This compiler won't grok '-c -o', but also, the minuso test has
6783 # not run yet. These depmodes are late enough in the game, and
6784 # so weak that their functioning should not be impacted.
6785 am__obj=conftest.${OBJEXT-o}
6786 am__minus_obj=
6787 ;;
6788 none) break ;;
6789 esac
6790 if depmode=$depmode \
6791 source=sub/conftest.c object=$am__obj \
6792 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
6793 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
6794 >/dev/null 2>conftest.err &&
6795 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
6796 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
6797 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
6798 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
6799 # icc doesn't choke on unknown options, it will just issue warnings
6800 # or remarks (even with -Werror). So we grep stderr for any message
6801 # that says an option was ignored or not supported.
6802 # When given -MP, icc 7.0 and 7.1 complain thusly:
6803 # icc: Command line warning: ignoring option '-M'; no argument required
6804 # The diagnosis changed in icc 8.0:
6805 # icc: Command line remark: option '-MP' not supported
6806 if (grep 'ignoring option' conftest.err ||
6807 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
6808 am_cv_CC_dependencies_compiler_type=$depmode
6809 break
6810 fi
6811 fi
6812 done
6813
6814 cd ..
6815 rm -rf conftest.dir
6816else
6817 am_cv_CC_dependencies_compiler_type=none
6818fi
6819
6820fi
6821{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
6822$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
6823CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
6824
6825 if
6826 test "x$enable_dependency_tracking" != xno \
6827 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
6828 am__fastdepCC_TRUE=
6829 am__fastdepCC_FALSE='#'
6830else
6831 am__fastdepCC_TRUE='#'
6832 am__fastdepCC_FALSE=
6833fi
6834
6835
6836ac_ext=c
6837ac_cpp='$CPP $CPPFLAGS'
6838ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6839ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6840ac_compiler_gnu=$ac_cv_c_compiler_gnu
6841{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
6842$as_echo_n "checking how to run the C preprocessor... " >&6; }
6843# On Suns, sometimes $CPP names a directory.
6844if test -n "$CPP" && test -d "$CPP"; then
6845 CPP=
6846fi
6847if test -z "$CPP"; then
6848 if ${ac_cv_prog_CPP+:} false; then :
6849 $as_echo_n "(cached) " >&6
6850else
6851 # Double quotes because CPP needs to be expanded
6852 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
6853 do
6854 ac_preproc_ok=false
6855for ac_c_preproc_warn_flag in '' yes
6856do
6857 # Use a header file that comes with gcc, so configuring glibc
6858 # with a fresh cross-compiler works.
6859 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6860 # <limits.h> exists even on freestanding compilers.
6861 # On the NeXT, cc -E runs the code through the compiler's parser,
6862 # not just through cpp. "Syntax error" is here to catch this case.
6863 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6864/* end confdefs.h. */
6865#ifdef __STDC__
6866# include <limits.h>
6867#else
6868# include <assert.h>
6869#endif
6870 Syntax error
6871_ACEOF
6872if ac_fn_c_try_cpp "$LINENO"; then :
6873
6874else
6875 # Broken: fails on valid input.
6876continue
6877fi
6878rm -f conftest.err conftest.i conftest.$ac_ext
6879
6880 # OK, works on sane cases. Now check whether nonexistent headers
6881 # can be detected and how.
6882 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6883/* end confdefs.h. */
6884#include <ac_nonexistent.h>
6885_ACEOF
6886if ac_fn_c_try_cpp "$LINENO"; then :
6887 # Broken: success on invalid input.
6888continue
6889else
6890 # Passes both tests.
6891ac_preproc_ok=:
6892break
6893fi
6894rm -f conftest.err conftest.i conftest.$ac_ext
6895
6896done
6897# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6898rm -f conftest.i conftest.err conftest.$ac_ext
6899if $ac_preproc_ok; then :
6900 break
6901fi
6902
6903 done
6904 ac_cv_prog_CPP=$CPP
6905
6906fi
6907 CPP=$ac_cv_prog_CPP
6908else
6909 ac_cv_prog_CPP=$CPP
6910fi
6911{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
6912$as_echo "$CPP" >&6; }
6913ac_preproc_ok=false
6914for ac_c_preproc_warn_flag in '' yes
6915do
6916 # Use a header file that comes with gcc, so configuring glibc
6917 # with a fresh cross-compiler works.
6918 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6919 # <limits.h> exists even on freestanding compilers.
6920 # On the NeXT, cc -E runs the code through the compiler's parser,
6921 # not just through cpp. "Syntax error" is here to catch this case.
6922 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6923/* end confdefs.h. */
6924#ifdef __STDC__
6925# include <limits.h>
6926#else
6927# include <assert.h>
6928#endif
6929 Syntax error
6930_ACEOF
6931if ac_fn_c_try_cpp "$LINENO"; then :
6932
6933else
6934 # Broken: fails on valid input.
6935continue
6936fi
6937rm -f conftest.err conftest.i conftest.$ac_ext
6938
6939 # OK, works on sane cases. Now check whether nonexistent headers
6940 # can be detected and how.
6941 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6942/* end confdefs.h. */
6943#include <ac_nonexistent.h>
6944_ACEOF
6945if ac_fn_c_try_cpp "$LINENO"; then :
6946 # Broken: success on invalid input.
6947continue
6948else
6949 # Passes both tests.
6950ac_preproc_ok=:
6951break
6952fi
6953rm -f conftest.err conftest.i conftest.$ac_ext
6954
6955done
6956# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6957rm -f conftest.i conftest.err conftest.$ac_ext
6958if $ac_preproc_ok; then :
6959
6960else
6961 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6962$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6963as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
6964See \`config.log' for more details" "$LINENO" 5; }
6965fi
6966
6967ac_ext=c
6968ac_cpp='$CPP $CPPFLAGS'
6969ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6970ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6971ac_compiler_gnu=$ac_cv_c_compiler_gnu
6972
6973
6974{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
6975$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
6976if ${ac_cv_path_GREP+:} false; then :
6977 $as_echo_n "(cached) " >&6
6978else
6979 if test -z "$GREP"; then
6980 ac_path_GREP_found=false
6981 # Loop through the user's path and test for each of PROGNAME-LIST
6982 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6983for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6984do
6985 IFS=$as_save_IFS
6986 test -z "$as_dir" && as_dir=.
6987 for ac_prog in grep ggrep; do
6988 for ac_exec_ext in '' $ac_executable_extensions; do
6989 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
6990 as_fn_executable_p "$ac_path_GREP" || continue
6991# Check for GNU ac_path_GREP and select it if it is found.
6992 # Check for GNU $ac_path_GREP
6993case `"$ac_path_GREP" --version 2>&1` in
6994*GNU*)
6995 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
6996*)
6997 ac_count=0
6998 $as_echo_n 0123456789 >"conftest.in"
6999 while :
7000 do
7001 cat "conftest.in" "conftest.in" >"conftest.tmp"
7002 mv "conftest.tmp" "conftest.in"
7003 cp "conftest.in" "conftest.nl"
7004 $as_echo 'GREP' >> "conftest.nl"
7005 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
7006 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7007 as_fn_arith $ac_count + 1 && ac_count=$as_val
7008 if test $ac_count -gt ${ac_path_GREP_max-0}; then
7009 # Best one so far, save it but keep looking for a better one
7010 ac_cv_path_GREP="$ac_path_GREP"
7011 ac_path_GREP_max=$ac_count
7012 fi
7013 # 10*(2^10) chars as input seems more than enough
7014 test $ac_count -gt 10 && break
7015 done
7016 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7017esac
7018
7019 $ac_path_GREP_found && break 3
7020 done
7021 done
7022 done
7023IFS=$as_save_IFS
7024 if test -z "$ac_cv_path_GREP"; then
7025 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
7026 fi
7027else
7028 ac_cv_path_GREP=$GREP
7029fi
7030
7031fi
7032{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
7033$as_echo "$ac_cv_path_GREP" >&6; }
7034 GREP="$ac_cv_path_GREP"
7035
7036
7037{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
7038$as_echo_n "checking for egrep... " >&6; }
7039if ${ac_cv_path_EGREP+:} false; then :
7040 $as_echo_n "(cached) " >&6
7041else
7042 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
7043 then ac_cv_path_EGREP="$GREP -E"
7044 else
7045 if test -z "$EGREP"; then
7046 ac_path_EGREP_found=false
7047 # Loop through the user's path and test for each of PROGNAME-LIST
7048 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7049for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
7050do
7051 IFS=$as_save_IFS
7052 test -z "$as_dir" && as_dir=.
7053 for ac_prog in egrep; do
7054 for ac_exec_ext in '' $ac_executable_extensions; do
7055 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
7056 as_fn_executable_p "$ac_path_EGREP" || continue
7057# Check for GNU ac_path_EGREP and select it if it is found.
7058 # Check for GNU $ac_path_EGREP
7059case `"$ac_path_EGREP" --version 2>&1` in
7060*GNU*)
7061 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
7062*)
7063 ac_count=0
7064 $as_echo_n 0123456789 >"conftest.in"
7065 while :
7066 do
7067 cat "conftest.in" "conftest.in" >"conftest.tmp"
7068 mv "conftest.tmp" "conftest.in"
7069 cp "conftest.in" "conftest.nl"
7070 $as_echo 'EGREP' >> "conftest.nl"
7071 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
7072 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7073 as_fn_arith $ac_count + 1 && ac_count=$as_val
7074 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
7075 # Best one so far, save it but keep looking for a better one
7076 ac_cv_path_EGREP="$ac_path_EGREP"
7077 ac_path_EGREP_max=$ac_count
7078 fi
7079 # 10*(2^10) chars as input seems more than enough
7080 test $ac_count -gt 10 && break
7081 done
7082 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7083esac
7084
7085 $ac_path_EGREP_found && break 3
7086 done
7087 done
7088 done
7089IFS=$as_save_IFS
7090 if test -z "$ac_cv_path_EGREP"; then
7091 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
7092 fi
7093else
7094 ac_cv_path_EGREP=$EGREP
7095fi
7096
7097 fi
7098fi
7099{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
7100$as_echo "$ac_cv_path_EGREP" >&6; }
7101 EGREP="$ac_cv_path_EGREP"
7102
7103
7104
7105
7106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
7107$as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
7108if ${gl_cv_c_amsterdam_compiler+:} false; then :
7109 $as_echo_n "(cached) " >&6
7110else
7111
7112 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7113/* end confdefs.h. */
7114
7115#ifdef __ACK__
7116Amsterdam
7117#endif
7118
7119_ACEOF
7120if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7121 $EGREP "Amsterdam" >/dev/null 2>&1; then :
7122 gl_cv_c_amsterdam_compiler=yes
7123else
7124 gl_cv_c_amsterdam_compiler=no
7125fi
7126rm -f conftest*
7127
7128
7129fi
7130{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
7131$as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
7132 if test -z "$AR"; then
7133 if test $gl_cv_c_amsterdam_compiler = yes; then
7134 AR='cc -c.a'
7135 if test -z "$ARFLAGS"; then
7136 ARFLAGS='-o'
7137 fi
7138 else
7139 if test -n "$ac_tool_prefix"; then
7140 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
7141set dummy ${ac_tool_prefix}ar; ac_word=$2
7142{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7143$as_echo_n "checking for $ac_word... " >&6; }
7144if ${ac_cv_prog_AR+:} false; then :
7145 $as_echo_n "(cached) " >&6
7146else
7147 if test -n "$AR"; then
7148 ac_cv_prog_AR="$AR" # Let the user override the test.
7149else
7150as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7151for as_dir in $PATH
7152do
7153 IFS=$as_save_IFS
7154 test -z "$as_dir" && as_dir=.
7155 for ac_exec_ext in '' $ac_executable_extensions; do
7156 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7157 ac_cv_prog_AR="${ac_tool_prefix}ar"
7158 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7159 break 2
7160 fi
7161done
7162 done
7163IFS=$as_save_IFS
7164
7165fi
7166fi
7167AR=$ac_cv_prog_AR
7168if test -n "$AR"; then
7169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
7170$as_echo "$AR" >&6; }
7171else
7172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7173$as_echo "no" >&6; }
7174fi
7175
7176
7177fi
7178if test -z "$ac_cv_prog_AR"; then
7179 ac_ct_AR=$AR
7180 # Extract the first word of "ar", so it can be a program name with args.
7181set dummy ar; ac_word=$2
7182{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7183$as_echo_n "checking for $ac_word... " >&6; }
7184if ${ac_cv_prog_ac_ct_AR+:} false; then :
7185 $as_echo_n "(cached) " >&6
7186else
7187 if test -n "$ac_ct_AR"; then
7188 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
7189else
7190as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7191for as_dir in $PATH
7192do
7193 IFS=$as_save_IFS
7194 test -z "$as_dir" && as_dir=.
7195 for ac_exec_ext in '' $ac_executable_extensions; do
7196 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7197 ac_cv_prog_ac_ct_AR="ar"
7198 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7199 break 2
7200 fi
7201done
7202 done
7203IFS=$as_save_IFS
7204
7205fi
7206fi
7207ac_ct_AR=$ac_cv_prog_ac_ct_AR
7208if test -n "$ac_ct_AR"; then
7209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
7210$as_echo "$ac_ct_AR" >&6; }
7211else
7212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7213$as_echo "no" >&6; }
7214fi
7215
7216 if test "x$ac_ct_AR" = x; then
7217 AR="ar"
7218 else
7219 case $cross_compiling:$ac_tool_warned in
7220yes:)
7221{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7222$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7223ac_tool_warned=yes ;;
7224esac
7225 AR=$ac_ct_AR
7226 fi
7227else
7228 AR="$ac_cv_prog_AR"
7229fi
7230
7231 if test -z "$ARFLAGS"; then
7232 ARFLAGS='cru'
7233 fi
7234 fi
7235 else
7236 if test -z "$ARFLAGS"; then
7237 ARFLAGS='cru'
7238 fi
7239 fi
7240
7241
7242 if test -z "$RANLIB"; then
7243 if test $gl_cv_c_amsterdam_compiler = yes; then
7244 RANLIB=':'
7245 else
7246 if test -n "$ac_tool_prefix"; then
7247 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
7248set dummy ${ac_tool_prefix}ranlib; ac_word=$2
7249{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7250$as_echo_n "checking for $ac_word... " >&6; }
7251if ${ac_cv_prog_RANLIB+:} false; then :
7252 $as_echo_n "(cached) " >&6
7253else
7254 if test -n "$RANLIB"; then
7255 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
7256else
7257as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7258for as_dir in $PATH
7259do
7260 IFS=$as_save_IFS
7261 test -z "$as_dir" && as_dir=.
7262 for ac_exec_ext in '' $ac_executable_extensions; do
7263 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7264 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
7265 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7266 break 2
7267 fi
7268done
7269 done
7270IFS=$as_save_IFS
7271
7272fi
7273fi
7274RANLIB=$ac_cv_prog_RANLIB
7275if test -n "$RANLIB"; then
7276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
7277$as_echo "$RANLIB" >&6; }
7278else
7279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7280$as_echo "no" >&6; }
7281fi
7282
7283
7284fi
7285if test -z "$ac_cv_prog_RANLIB"; then
7286 ac_ct_RANLIB=$RANLIB
7287 # Extract the first word of "ranlib", so it can be a program name with args.
7288set dummy ranlib; ac_word=$2
7289{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7290$as_echo_n "checking for $ac_word... " >&6; }
7291if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
7292 $as_echo_n "(cached) " >&6
7293else
7294 if test -n "$ac_ct_RANLIB"; then
7295 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
7296else
7297as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7298for as_dir in $PATH
7299do
7300 IFS=$as_save_IFS
7301 test -z "$as_dir" && as_dir=.
7302 for ac_exec_ext in '' $ac_executable_extensions; do
7303 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7304 ac_cv_prog_ac_ct_RANLIB="ranlib"
7305 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7306 break 2
7307 fi
7308done
7309 done
7310IFS=$as_save_IFS
7311
7312fi
7313fi
7314ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
7315if test -n "$ac_ct_RANLIB"; then
7316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
7317$as_echo "$ac_ct_RANLIB" >&6; }
7318else
7319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7320$as_echo "no" >&6; }
7321fi
7322
7323 if test "x$ac_ct_RANLIB" = x; then
7324 RANLIB=":"
7325 else
7326 case $cross_compiling:$ac_tool_warned in
7327yes:)
7328{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7329$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7330ac_tool_warned=yes ;;
7331esac
7332 RANLIB=$ac_ct_RANLIB
7333 fi
7334else
7335 RANLIB="$ac_cv_prog_RANLIB"
7336fi
7337
7338 fi
7339 fi
7340
7341
7342
7343{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
7344$as_echo_n "checking for ANSI C header files... " >&6; }
7345if ${ac_cv_header_stdc+:} false; then :
7346 $as_echo_n "(cached) " >&6
7347else
7348 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7349/* end confdefs.h. */
7350#include <stdlib.h>
7351#include <stdarg.h>
7352#include <string.h>
7353#include <float.h>
7354
7355int
7356main (void)
7357{
7358
7359 ;
7360 return 0;
7361}
7362_ACEOF
7363if ac_fn_c_try_compile "$LINENO"; then :
7364 ac_cv_header_stdc=yes
7365else
7366 ac_cv_header_stdc=no
7367fi
7368rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7369
7370if test $ac_cv_header_stdc = yes; then
7371 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
7372 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7373/* end confdefs.h. */
7374#include <string.h>
7375
7376_ACEOF
7377if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7378 $EGREP "memchr" >/dev/null 2>&1; then :
7379
7380else
7381 ac_cv_header_stdc=no
7382fi
7383rm -f conftest*
7384
7385fi
7386
7387if test $ac_cv_header_stdc = yes; then
7388 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
7389 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7390/* end confdefs.h. */
7391#include <stdlib.h>
7392
7393_ACEOF
7394if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7395 $EGREP "free" >/dev/null 2>&1; then :
7396
7397else
7398 ac_cv_header_stdc=no
7399fi
7400rm -f conftest*
7401
7402fi
7403
7404if test $ac_cv_header_stdc = yes; then
7405 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
7406 if test "$cross_compiling" = yes; then :
7407 :
7408else
7409 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7410/* end confdefs.h. */
7411#include <ctype.h>
7412#include <stdlib.h>
7413#if ((' ' & 0x0FF) == 0x020)
7414# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
7415# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
7416#else
7417# define ISLOWER(c) \
7418 (('a' <= (c) && (c) <= 'i') \
7419 || ('j' <= (c) && (c) <= 'r') \
7420 || ('s' <= (c) && (c) <= 'z'))
7421# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
7422#endif
7423
7424#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
7425int
7426main ()
7427{
7428 int i;
7429 for (i = 0; i < 256; i++)
7430 if (XOR (islower (i), ISLOWER (i))
7431 || toupper (i) != TOUPPER (i))
7432 return 2;
7433 return 0;
7434}
7435_ACEOF
7436if ac_fn_c_try_run "$LINENO"; then :
7437
7438else
7439 ac_cv_header_stdc=no
7440fi
7441rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7442 conftest.$ac_objext conftest.beam conftest.$ac_ext
7443fi
7444
7445fi
7446fi
7447{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
7448$as_echo "$ac_cv_header_stdc" >&6; }
7449if test $ac_cv_header_stdc = yes; then
7450
7451$as_echo "#define STDC_HEADERS 1" >>confdefs.h
7452
7453fi
7454
7455# On IRIX 5.3, sys/types and inttypes.h are conflicting.
7456for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
7457 inttypes.h stdint.h unistd.h
7458do :
7459 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7460ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
7461"
7462if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
7463 cat >>confdefs.h <<_ACEOF
7464#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7465_ACEOF
7466
7467fi
7468
7469done
7470
7471
7472
7473 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
7474if test "x$ac_cv_header_minix_config_h" = xyes; then :
7475 MINIX=yes
7476else
7477 MINIX=
7478fi
7479
7480
7481 if test "$MINIX" = yes; then
7482
7483$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
7484
7485
7486$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
7487
7488
7489$as_echo "#define _MINIX 1" >>confdefs.h
7490
7491
7492$as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h
7493
7494 fi
7495
7496
7497 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
7498$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
7499if ${ac_cv_safe_to_define___extensions__+:} false; then :
7500 $as_echo_n "(cached) " >&6
7501else
7502 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7503/* end confdefs.h. */
7504
7505# define __EXTENSIONS__ 1
7506 $ac_includes_default
7507int
7508main (void)
7509{
7510
7511 ;
7512 return 0;
7513}
7514_ACEOF
7515if ac_fn_c_try_compile "$LINENO"; then :
7516 ac_cv_safe_to_define___extensions__=yes
7517else
7518 ac_cv_safe_to_define___extensions__=no
7519fi
7520rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7521fi
7522{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
7523$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
7524 test $ac_cv_safe_to_define___extensions__ = yes &&
7525 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
7526
7527 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
7528
7529 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
7530
7531 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
7532
7533 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
7534
7535 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
7536
7537 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5
7538$as_echo_n "checking whether _XOPEN_SOURCE should be defined... " >&6; }
7539if ${ac_cv_should_define__xopen_source+:} false; then :
7540 $as_echo_n "(cached) " >&6
7541else
7542 ac_cv_should_define__xopen_source=no
7543 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7544/* end confdefs.h. */
7545
7546 #include <wchar.h>
7547 mbstate_t x;
7548int
7549main (void)
7550{
7551
7552 ;
7553 return 0;
7554}
7555_ACEOF
7556if ac_fn_c_try_compile "$LINENO"; then :
7557
7558else
7559 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7560/* end confdefs.h. */
7561
7562 #define _XOPEN_SOURCE 500
7563 #include <wchar.h>
7564 mbstate_t x;
7565int
7566main (void)
7567{
7568
7569 ;
7570 return 0;
7571}
7572_ACEOF
7573if ac_fn_c_try_compile "$LINENO"; then :
7574 ac_cv_should_define__xopen_source=yes
7575fi
7576rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7577fi
7578rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7579fi
7580{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5
7581$as_echo "$ac_cv_should_define__xopen_source" >&6; }
7582 test $ac_cv_should_define__xopen_source = yes &&
7583 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
7584
7585
7586
7587
7588
7589
7590
7591
7592
7593
7594
7595 # Code from module alloca:
7596 # Code from module alloca-opt:
7597 # Code from module argp:
7598 # Code from module btowc:
7599 # Code from module configmake:
7600 # Code from module dirname-lgpl:
7601 # Code from module dosname:
7602 # Code from module double-slash-root:
7603 # Code from module errno:
7604 # Code from module error:
7605 # Code from module extensions:
7606
7607 # Code from module extern-inline:
7608 # Code from module float:
7609 # Code from module fnmatch:
7610 # Code from module getdelim:
7611 # Code from module getline:
7612 # Code from module getopt-gnu:
7613 # Code from module getopt-posix:
7614 # Code from module gettext:
7615 # Code from module gettext-h:
7616 # Code from module havelib:
7617 # Code from module include_next:
7618 # Code from module intprops:
7619 # Code from module langinfo:
7620 # Code from module localcharset:
7621 # Code from module locale:
7622 # Code from module localeconv:
7623 # Code from module malloc-gnu:
7624 # Code from module malloc-posix:
7625 # Code from module mbrtowc:
7626 # Code from module mbsinit:
7627 # Code from module mbsrtowcs:
7628 # Code from module mbswidth:
7629 # Code from module mbtowc:
7630 # Code from module memchr:
7631 # Code from module mempcpy:
7632 # Code from module msvc-inval:
7633 # Code from module msvc-nothrow:
7634 # Code from module multiarch:
7635 # Code from module nl_langinfo:
7636 # Code from module nocrash:
7637 # Code from module progname:
7638 # Code from module rawmemchr:
7639 # Code from module realloc-posix:
7640 # Code from module regex:
7641 # Code from module size_max:
7642 # Code from module sleep:
7643 # Code from module snippet/_Noreturn:
7644 # Code from module snippet/arg-nonnull:
7645 # Code from module snippet/c++defs:
7646 # Code from module snippet/warn-on-use:
7647 # Code from module ssize_t:
7648 # Code from module stdalign:
7649 # Code from module stdbool:
7650 # Code from module stddef:
7651 # Code from module stdint:
7652 # Code from module stdio:
7653 # Code from module stdlib:
7654 # Code from module strcase:
7655 # Code from module strchrnul:
7656 # Code from module streq:
7657 # Code from module strerror:
7658 # Code from module strerror-override:
7659 # Code from module string:
7660 # Code from module strings:
7661 # Code from module strndup:
7662 # Code from module strnlen:
7663 # Code from module strnlen1:
7664 # Code from module sys_types:
7665 # Code from module sysexits:
7666 # Code from module unistd:
7667 # Code from module unitypes:
7668 # Code from module uniwidth/base:
7669 # Code from module uniwidth/width:
7670 # Code from module vasnprintf:
7671 # Code from module verify:
7672 # Code from module vsnprintf:
7673 # Code from module wchar:
7674 # Code from module wcrtomb:
7675 # Code from module wctype-h:
7676 # Code from module wcwidth:
7677 # Code from module xsize:
7678
7679ac_ext=cpp
7680ac_cpp='$CXXCPP $CPPFLAGS'
7681ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7682ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7683ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
7684if test -z "$CXX"; then
7685 if test -n "$CCC"; then
7686 CXX=$CCC
7687 else
7688 if test -n "$ac_tool_prefix"; then
7689 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
7690 do
7691 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
7692set dummy $ac_tool_prefix$ac_prog; ac_word=$2
7693{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7694$as_echo_n "checking for $ac_word... " >&6; }
7695if ${ac_cv_prog_CXX+:} false; then :
7696 $as_echo_n "(cached) " >&6
7697else
7698 if test -n "$CXX"; then
7699 ac_cv_prog_CXX="$CXX" # Let the user override the test.
7700else
7701as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7702for as_dir in $PATH
7703do
7704 IFS=$as_save_IFS
7705 test -z "$as_dir" && as_dir=.
7706 for ac_exec_ext in '' $ac_executable_extensions; do
7707 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7708 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
7709 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7710 break 2
7711 fi
7712done
7713 done
7714IFS=$as_save_IFS
7715
7716fi
7717fi
7718CXX=$ac_cv_prog_CXX
7719if test -n "$CXX"; then
7720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
7721$as_echo "$CXX" >&6; }
7722else
7723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7724$as_echo "no" >&6; }
7725fi
7726
7727
7728 test -n "$CXX" && break
7729 done
7730fi
7731if test -z "$CXX"; then
7732 ac_ct_CXX=$CXX
7733 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
7734do
7735 # Extract the first word of "$ac_prog", so it can be a program name with args.
7736set dummy $ac_prog; ac_word=$2
7737{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7738$as_echo_n "checking for $ac_word... " >&6; }
7739if ${ac_cv_prog_ac_ct_CXX+:} false; then :
7740 $as_echo_n "(cached) " >&6
7741else
7742 if test -n "$ac_ct_CXX"; then
7743 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
7744else
7745as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7746for as_dir in $PATH
7747do
7748 IFS=$as_save_IFS
7749 test -z "$as_dir" && as_dir=.
7750 for ac_exec_ext in '' $ac_executable_extensions; do
7751 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7752 ac_cv_prog_ac_ct_CXX="$ac_prog"
7753 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7754 break 2
7755 fi
7756done
7757 done
7758IFS=$as_save_IFS
7759
7760fi
7761fi
7762ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
7763if test -n "$ac_ct_CXX"; then
7764 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
7765$as_echo "$ac_ct_CXX" >&6; }
7766else
7767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7768$as_echo "no" >&6; }
7769fi
7770
7771
7772 test -n "$ac_ct_CXX" && break
7773done
7774
7775 if test "x$ac_ct_CXX" = x; then
7776 CXX="g++"
7777 else
7778 case $cross_compiling:$ac_tool_warned in
7779yes:)
7780{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7781$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7782ac_tool_warned=yes ;;
7783esac
7784 CXX=$ac_ct_CXX
7785 fi
7786fi
7787
7788 fi
7789fi
7790# Provide some information about the compiler.
7791$as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
7792set X $ac_compile
7793ac_compiler=$2
7794for ac_option in --version -v -V -qversion; do
7795 { { ac_try="$ac_compiler $ac_option >&5"
7796case "(($ac_try" in
7797 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7798 *) ac_try_echo=$ac_try;;
7799esac
7800eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
7801$as_echo "$ac_try_echo"; } >&5
7802 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
7803 ac_status=$?
7804 if test -s conftest.err; then
7805 sed '10a\
7806... rest of stderr output deleted ...
7807 10q' conftest.err >conftest.er1
7808 cat conftest.er1 >&5
7809 fi
7810 rm -f conftest.er1 conftest.err
7811 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7812 test $ac_status = 0; }
7813done
7814
7815{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
7816$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
7817if ${ac_cv_cxx_compiler_gnu+:} false; then :
7818 $as_echo_n "(cached) " >&6
7819else
7820 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7821/* end confdefs.h. */
7822
7823int
7824main ()
7825{
7826#ifndef __GNUC__
7827 choke me
7828#endif
7829
7830 ;
7831 return 0;
7832}
7833_ACEOF
7834if ac_fn_cxx_try_compile "$LINENO"; then :
7835 ac_compiler_gnu=yes
7836else
7837 ac_compiler_gnu=no
7838fi
7839rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7840ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
7841
7842fi
7843{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
7844$as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
7845if test $ac_compiler_gnu = yes; then
7846 GXX=yes
7847else
7848 GXX=
7849fi
7850ac_test_CXXFLAGS=${CXXFLAGS+set}
7851ac_save_CXXFLAGS=$CXXFLAGS
7852{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
7853$as_echo_n "checking whether $CXX accepts -g... " >&6; }
7854if ${ac_cv_prog_cxx_g+:} false; then :
7855 $as_echo_n "(cached) " >&6
7856else
7857 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
7858 ac_cxx_werror_flag=yes
7859 ac_cv_prog_cxx_g=no
7860 CXXFLAGS="-g"
7861 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7862/* end confdefs.h. */
7863
7864int
7865main ()
7866{
7867
7868 ;
7869 return 0;
7870}
7871_ACEOF
7872if ac_fn_cxx_try_compile "$LINENO"; then :
7873 ac_cv_prog_cxx_g=yes
7874else
7875 CXXFLAGS=""
7876 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7877/* end confdefs.h. */
7878
7879int
7880main ()
7881{
7882
7883 ;
7884 return 0;
7885}
7886_ACEOF
7887if ac_fn_cxx_try_compile "$LINENO"; then :
7888
7889else
7890 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
7891 CXXFLAGS="-g"
7892 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7893/* end confdefs.h. */
7894
7895int
7896main ()
7897{
7898
7899 ;
7900 return 0;
7901}
7902_ACEOF
7903if ac_fn_cxx_try_compile "$LINENO"; then :
7904 ac_cv_prog_cxx_g=yes
7905fi
7906rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7907fi
7908rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7909fi
7910rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7911 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
7912fi
7913{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
7914$as_echo "$ac_cv_prog_cxx_g" >&6; }
7915if test "$ac_test_CXXFLAGS" = set; then
7916 CXXFLAGS=$ac_save_CXXFLAGS
7917elif test $ac_cv_prog_cxx_g = yes; then
7918 if test "$GXX" = yes; then
7919 CXXFLAGS="-g -O2"
7920 else
7921 CXXFLAGS="-g"
7922 fi
7923else
7924 if test "$GXX" = yes; then
7925 CXXFLAGS="-O2"
7926 else
7927 CXXFLAGS=
7928 fi
7929fi
7930ac_ext=c
7931ac_cpp='$CPP $CPPFLAGS'
7932ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7933ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7934ac_compiler_gnu=$ac_cv_c_compiler_gnu
7935
7936depcc="$CXX" am_compiler_list=
7937
7938{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
7939$as_echo_n "checking dependency style of $depcc... " >&6; }
7940if ${am_cv_CXX_dependencies_compiler_type+:} false; then :
7941 $as_echo_n "(cached) " >&6
7942else
7943 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
7944 # We make a subdir and do the tests there. Otherwise we can end up
7945 # making bogus files that we don't know about and never remove. For
7946 # instance it was reported that on HP-UX the gcc test will end up
7947 # making a dummy file named 'D' -- because '-MD' means "put the output
7948 # in D".
7949 rm -rf conftest.dir
7950 mkdir conftest.dir
7951 # Copy depcomp to subdir because otherwise we won't find it if we're
7952 # using a relative directory.
7953 cp "$am_depcomp" conftest.dir
7954 cd conftest.dir
7955 # We will build objects and dependencies in a subdirectory because
7956 # it helps to detect inapplicable dependency modes. For instance
7957 # both Tru64's cc and ICC support -MD to output dependencies as a
7958 # side effect of compilation, but ICC will put the dependencies in
7959 # the current directory while Tru64 will put them in the object
7960 # directory.
7961 mkdir sub
7962
7963 am_cv_CXX_dependencies_compiler_type=none
7964 if test "$am_compiler_list" = ""; then
7965 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
7966 fi
7967 am__universal=false
7968 case " $depcc " in #(
7969 *\ -arch\ *\ -arch\ *) am__universal=true ;;
7970 esac
7971
7972 for depmode in $am_compiler_list; do
7973 # Setup a source with many dependencies, because some compilers
7974 # like to wrap large dependency lists on column 80 (with \), and
7975 # we should not choose a depcomp mode which is confused by this.
7976 #
7977 # We need to recreate these files for each test, as the compiler may
7978 # overwrite some of them when testing with obscure command lines.
7979 # This happens at least with the AIX C compiler.
7980 : > sub/conftest.c
7981 for i in 1 2 3 4 5 6; do
7982 echo '#include "conftst'$i'.h"' >> sub/conftest.c
7983 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
7984 # Solaris 10 /bin/sh.
7985 echo '/* dummy */' > sub/conftst$i.h
7986 done
7987 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
7988
7989 # We check with '-c' and '-o' for the sake of the "dashmstdout"
7990 # mode. It turns out that the SunPro C++ compiler does not properly
7991 # handle '-M -o', and we need to detect this. Also, some Intel
7992 # versions had trouble with output in subdirs.
7993 am__obj=sub/conftest.${OBJEXT-o}
7994 am__minus_obj="-o $am__obj"
7995 case $depmode in
7996 gcc)
7997 # This depmode causes a compiler race in universal mode.
7998 test "$am__universal" = false || continue
7999 ;;
8000 nosideeffect)
8001 # After this tag, mechanisms are not by side-effect, so they'll
8002 # only be used when explicitly requested.
8003 if test "x$enable_dependency_tracking" = xyes; then
8004 continue
8005 else
8006 break
8007 fi
8008 ;;
8009 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
8010 # This compiler won't grok '-c -o', but also, the minuso test has
8011 # not run yet. These depmodes are late enough in the game, and
8012 # so weak that their functioning should not be impacted.
8013 am__obj=conftest.${OBJEXT-o}
8014 am__minus_obj=
8015 ;;
8016 none) break ;;
8017 esac
8018 if depmode=$depmode \
8019 source=sub/conftest.c object=$am__obj \
8020 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
8021 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
8022 >/dev/null 2>conftest.err &&
8023 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
8024 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
8025 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
8026 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
8027 # icc doesn't choke on unknown options, it will just issue warnings
8028 # or remarks (even with -Werror). So we grep stderr for any message
8029 # that says an option was ignored or not supported.
8030 # When given -MP, icc 7.0 and 7.1 complain thusly:
8031 # icc: Command line warning: ignoring option '-M'; no argument required
8032 # The diagnosis changed in icc 8.0:
8033 # icc: Command line remark: option '-MP' not supported
8034 if (grep 'ignoring option' conftest.err ||
8035 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
8036 am_cv_CXX_dependencies_compiler_type=$depmode
8037 break
8038 fi
8039 fi
8040 done
8041
8042 cd ..
8043 rm -rf conftest.dir
8044else
8045 am_cv_CXX_dependencies_compiler_type=none
8046fi
8047
8048fi
8049{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CXX_dependencies_compiler_type" >&5
8050$as_echo "$am_cv_CXX_dependencies_compiler_type" >&6; }
8051CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type
8052
8053 if
8054 test "x$enable_dependency_tracking" != xno \
8055 && test "$am_cv_CXX_dependencies_compiler_type" = gcc3; then
8056 am__fastdepCXX_TRUE=
8057 am__fastdepCXX_FALSE='#'
8058else
8059 am__fastdepCXX_TRUE='#'
8060 am__fastdepCXX_FALSE=
8061fi
8062
8063
8064
8065# By default we simply use the C compiler to build assembly code.
8066
8067test "${CCAS+set}" = set || CCAS=$CC
8068test "${CCASFLAGS+set}" = set || CCASFLAGS=$CFLAGS
8069
8070
8071
8072depcc="$CCAS" am_compiler_list=
8073
8074{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
8075$as_echo_n "checking dependency style of $depcc... " >&6; }
8076if ${am_cv_CCAS_dependencies_compiler_type+:} false; then :
8077 $as_echo_n "(cached) " >&6
8078else
8079 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
8080 # We make a subdir and do the tests there. Otherwise we can end up
8081 # making bogus files that we don't know about and never remove. For
8082 # instance it was reported that on HP-UX the gcc test will end up
8083 # making a dummy file named 'D' -- because '-MD' means "put the output
8084 # in D".
8085 rm -rf conftest.dir
8086 mkdir conftest.dir
8087 # Copy depcomp to subdir because otherwise we won't find it if we're
8088 # using a relative directory.
8089 cp "$am_depcomp" conftest.dir
8090 cd conftest.dir
8091 # We will build objects and dependencies in a subdirectory because
8092 # it helps to detect inapplicable dependency modes. For instance
8093 # both Tru64's cc and ICC support -MD to output dependencies as a
8094 # side effect of compilation, but ICC will put the dependencies in
8095 # the current directory while Tru64 will put them in the object
8096 # directory.
8097 mkdir sub
8098
8099 am_cv_CCAS_dependencies_compiler_type=none
8100 if test "$am_compiler_list" = ""; then
8101 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
8102 fi
8103 am__universal=false
8104
8105
8106 for depmode in $am_compiler_list; do
8107 # Setup a source with many dependencies, because some compilers
8108 # like to wrap large dependency lists on column 80 (with \), and
8109 # we should not choose a depcomp mode which is confused by this.
8110 #
8111 # We need to recreate these files for each test, as the compiler may
8112 # overwrite some of them when testing with obscure command lines.
8113 # This happens at least with the AIX C compiler.
8114 : > sub/conftest.c
8115 for i in 1 2 3 4 5 6; do
8116 echo '#include "conftst'$i'.h"' >> sub/conftest.c
8117 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
8118 # Solaris 10 /bin/sh.
8119 echo '/* dummy */' > sub/conftst$i.h
8120 done
8121 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
8122
8123 # We check with '-c' and '-o' for the sake of the "dashmstdout"
8124 # mode. It turns out that the SunPro C++ compiler does not properly
8125 # handle '-M -o', and we need to detect this. Also, some Intel
8126 # versions had trouble with output in subdirs.
8127 am__obj=sub/conftest.${OBJEXT-o}
8128 am__minus_obj="-o $am__obj"
8129 case $depmode in
8130 gcc)
8131 # This depmode causes a compiler race in universal mode.
8132 test "$am__universal" = false || continue
8133 ;;
8134 nosideeffect)
8135 # After this tag, mechanisms are not by side-effect, so they'll
8136 # only be used when explicitly requested.
8137 if test "x$enable_dependency_tracking" = xyes; then
8138 continue
8139 else
8140 break
8141 fi
8142 ;;
8143 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
8144 # This compiler won't grok '-c -o', but also, the minuso test has
8145 # not run yet. These depmodes are late enough in the game, and
8146 # so weak that their functioning should not be impacted.
8147 am__obj=conftest.${OBJEXT-o}
8148 am__minus_obj=
8149 ;;
8150 none) break ;;
8151 esac
8152 if depmode=$depmode \
8153 source=sub/conftest.c object=$am__obj \
8154 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
8155 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
8156 >/dev/null 2>conftest.err &&
8157 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
8158 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
8159 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
8160 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
8161 # icc doesn't choke on unknown options, it will just issue warnings
8162 # or remarks (even with -Werror). So we grep stderr for any message
8163 # that says an option was ignored or not supported.
8164 # When given -MP, icc 7.0 and 7.1 complain thusly:
8165 # icc: Command line warning: ignoring option '-M'; no argument required
8166 # The diagnosis changed in icc 8.0:
8167 # icc: Command line remark: option '-MP' not supported
8168 if (grep 'ignoring option' conftest.err ||
8169 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
8170 am_cv_CCAS_dependencies_compiler_type=$depmode
8171 break
8172 fi
8173 fi
8174 done
8175
8176 cd ..
8177 rm -rf conftest.dir
8178else
8179 am_cv_CCAS_dependencies_compiler_type=none
8180fi
8181
8182fi
8183{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CCAS_dependencies_compiler_type" >&5
8184$as_echo "$am_cv_CCAS_dependencies_compiler_type" >&6; }
8185CCASDEPMODE=depmode=$am_cv_CCAS_dependencies_compiler_type
8186
8187 if
8188 test "x$enable_dependency_tracking" != xno \
8189 && test "$am_cv_CCAS_dependencies_compiler_type" = gcc3; then
8190 am__fastdepCCAS_TRUE=
8191 am__fastdepCCAS_FALSE='#'
8192else
8193 am__fastdepCCAS_TRUE='#'
8194 am__fastdepCCAS_FALSE=
8195fi
8196
8197
8198
8199# Must be GCC.
8200test "x$GCC" = xyes || as_fn_error $? "GCC is required" "$LINENO" 5
8201
8202# Extract the first word of "$CXX", so it can be a program name with args.
8203set dummy $CXX; ac_word=$2
8204{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8205$as_echo_n "checking for $ac_word... " >&6; }
8206if ${ac_cv_prog_HAVE_CXX+:} false; then :
8207 $as_echo_n "(cached) " >&6
8208else
8209 if test -n "$HAVE_CXX"; then
8210 ac_cv_prog_HAVE_CXX="$HAVE_CXX" # Let the user override the test.
8211else
8212as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8213for as_dir in $PATH
8214do
8215 IFS=$as_save_IFS
8216 test -z "$as_dir" && as_dir=.
8217 for ac_exec_ext in '' $ac_executable_extensions; do
8218 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8219 ac_cv_prog_HAVE_CXX="yes"
8220 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8221 break 2
8222 fi
8223done
8224 done
8225IFS=$as_save_IFS
8226
8227 test -z "$ac_cv_prog_HAVE_CXX" && ac_cv_prog_HAVE_CXX="no"
8228fi
8229fi
8230HAVE_CXX=$ac_cv_prog_HAVE_CXX
8231if test -n "$HAVE_CXX"; then
8232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_CXX" >&5
8233$as_echo "$HAVE_CXX" >&6; }
8234else
8235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8236$as_echo "no" >&6; }
8237fi
8238
8239
8240
8241
8242
8243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
8244$as_echo_n "checking whether NLS is requested... " >&6; }
8245 # Check whether --enable-nls was given.
8246if test "${enable_nls+set}" = set; then :
8247 enableval=$enable_nls; USE_NLS=$enableval
8248else
8249 USE_NLS=yes
8250fi
8251
8252 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
8253$as_echo "$USE_NLS" >&6; }
8254
8255
8256
8257
8258 GETTEXT_MACRO_VERSION=0.18
8259
8260
8261
8262
8263# Prepare PATH_SEPARATOR.
8264# The user is always right.
8265if test "${PATH_SEPARATOR+set}" != set; then
8266 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
8267 # contains only /bin. Note that ksh looks also at the FPATH variable,
8268 # so we have to set that as well for the test.
8269 PATH_SEPARATOR=:
8270 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8271 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8272 || PATH_SEPARATOR=';'
8273 }
8274fi
8275
8276# Find out how to test for executable files. Don't use a zero-byte file,
8277# as systems may use methods other than mode bits to determine executability.
8278cat >conf$$.file <<_ASEOF
8279#! /bin/sh
8280exit 0
8281_ASEOF
8282chmod +x conf$$.file
8283if test -x conf$$.file >/dev/null 2>&1; then
8284 ac_executable_p="test -x"
8285else
8286 ac_executable_p="test -f"
8287fi
8288rm -f conf$$.file
8289
8290# Extract the first word of "msgfmt", so it can be a program name with args.
8291set dummy msgfmt; ac_word=$2
8292{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8293$as_echo_n "checking for $ac_word... " >&6; }
8294if ${ac_cv_path_MSGFMT+:} false; then :
8295 $as_echo_n "(cached) " >&6
8296else
8297 case "$MSGFMT" in
8298 [\\/]* | ?:[\\/]*)
8299 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
8300 ;;
8301 *)
8302 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
8303 for ac_dir in $PATH; do
8304 IFS="$ac_save_IFS"
8305 test -z "$ac_dir" && ac_dir=.
8306 for ac_exec_ext in '' $ac_executable_extensions; do
8307 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
8308 echo "$as_me: trying $ac_dir/$ac_word..." >&5
8309 if $ac_dir/$ac_word --statistics /dev/null >&5 2>&1 &&
8310 (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
8311 ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
8312 break 2
8313 fi
8314 fi
8315 done
8316 done
8317 IFS="$ac_save_IFS"
8318 test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
8319 ;;
8320esac
8321fi
8322MSGFMT="$ac_cv_path_MSGFMT"
8323if test "$MSGFMT" != ":"; then
8324 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
8325$as_echo "$MSGFMT" >&6; }
8326else
8327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8328$as_echo "no" >&6; }
8329fi
8330
8331 # Extract the first word of "gmsgfmt", so it can be a program name with args.
8332set dummy gmsgfmt; ac_word=$2
8333{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8334$as_echo_n "checking for $ac_word... " >&6; }
8335if ${ac_cv_path_GMSGFMT+:} false; then :
8336 $as_echo_n "(cached) " >&6
8337else
8338 case $GMSGFMT in
8339 [\\/]* | ?:[\\/]*)
8340 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
8341 ;;
8342 *)
8343 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8344for as_dir in $PATH
8345do
8346 IFS=$as_save_IFS
8347 test -z "$as_dir" && as_dir=.
8348 for ac_exec_ext in '' $ac_executable_extensions; do
8349 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8350 ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
8351 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8352 break 2
8353 fi
8354done
8355 done
8356IFS=$as_save_IFS
8357
8358 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
8359 ;;
8360esac
8361fi
8362GMSGFMT=$ac_cv_path_GMSGFMT
8363if test -n "$GMSGFMT"; then
8364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
8365$as_echo "$GMSGFMT" >&6; }
8366else
8367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8368$as_echo "no" >&6; }
8369fi
8370
8371
8372
8373 case `$MSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
8374 '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) MSGFMT_015=: ;;
8375 *) MSGFMT_015=$MSGFMT ;;
8376 esac
8377
8378 case `$GMSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
8379 '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) GMSGFMT_015=: ;;
8380 *) GMSGFMT_015=$GMSGFMT ;;
8381 esac
8382
8383
8384
8385# Prepare PATH_SEPARATOR.
8386# The user is always right.
8387if test "${PATH_SEPARATOR+set}" != set; then
8388 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
8389 # contains only /bin. Note that ksh looks also at the FPATH variable,
8390 # so we have to set that as well for the test.
8391 PATH_SEPARATOR=:
8392 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8393 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8394 || PATH_SEPARATOR=';'
8395 }
8396fi
8397
8398# Find out how to test for executable files. Don't use a zero-byte file,
8399# as systems may use methods other than mode bits to determine executability.
8400cat >conf$$.file <<_ASEOF
8401#! /bin/sh
8402exit 0
8403_ASEOF
8404chmod +x conf$$.file
8405if test -x conf$$.file >/dev/null 2>&1; then
8406 ac_executable_p="test -x"
8407else
8408 ac_executable_p="test -f"
8409fi
8410rm -f conf$$.file
8411
8412# Extract the first word of "xgettext", so it can be a program name with args.
8413set dummy xgettext; ac_word=$2
8414{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8415$as_echo_n "checking for $ac_word... " >&6; }
8416if ${ac_cv_path_XGETTEXT+:} false; then :
8417 $as_echo_n "(cached) " >&6
8418else
8419 case "$XGETTEXT" in
8420 [\\/]* | ?:[\\/]*)
8421 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
8422 ;;
8423 *)
8424 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
8425 for ac_dir in $PATH; do
8426 IFS="$ac_save_IFS"
8427 test -z "$ac_dir" && ac_dir=.
8428 for ac_exec_ext in '' $ac_executable_extensions; do
8429 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
8430 echo "$as_me: trying $ac_dir/$ac_word..." >&5
8431 if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >&5 2>&1 &&
8432 (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
8433 ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
8434 break 2
8435 fi
8436 fi
8437 done
8438 done
8439 IFS="$ac_save_IFS"
8440 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
8441 ;;
8442esac
8443fi
8444XGETTEXT="$ac_cv_path_XGETTEXT"
8445if test "$XGETTEXT" != ":"; then
8446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
8447$as_echo "$XGETTEXT" >&6; }
8448else
8449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8450$as_echo "no" >&6; }
8451fi
8452
8453 rm -f messages.po
8454
8455 case `$XGETTEXT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
8456 '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) XGETTEXT_015=: ;;
8457 *) XGETTEXT_015=$XGETTEXT ;;
8458 esac
8459
8460
8461
8462# Prepare PATH_SEPARATOR.
8463# The user is always right.
8464if test "${PATH_SEPARATOR+set}" != set; then
8465 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
8466 # contains only /bin. Note that ksh looks also at the FPATH variable,
8467 # so we have to set that as well for the test.
8468 PATH_SEPARATOR=:
8469 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8470 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8471 || PATH_SEPARATOR=';'
8472 }
8473fi
8474
8475# Find out how to test for executable files. Don't use a zero-byte file,
8476# as systems may use methods other than mode bits to determine executability.
8477cat >conf$$.file <<_ASEOF
8478#! /bin/sh
8479exit 0
8480_ASEOF
8481chmod +x conf$$.file
8482if test -x conf$$.file >/dev/null 2>&1; then
8483 ac_executable_p="test -x"
8484else
8485 ac_executable_p="test -f"
8486fi
8487rm -f conf$$.file
8488
8489# Extract the first word of "msgmerge", so it can be a program name with args.
8490set dummy msgmerge; ac_word=$2
8491{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8492$as_echo_n "checking for $ac_word... " >&6; }
8493if ${ac_cv_path_MSGMERGE+:} false; then :
8494 $as_echo_n "(cached) " >&6
8495else
8496 case "$MSGMERGE" in
8497 [\\/]* | ?:[\\/]*)
8498 ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
8499 ;;
8500 *)
8501 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
8502 for ac_dir in $PATH; do
8503 IFS="$ac_save_IFS"
8504 test -z "$ac_dir" && ac_dir=.
8505 for ac_exec_ext in '' $ac_executable_extensions; do
8506 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
8507 echo "$as_me: trying $ac_dir/$ac_word..." >&5
8508 if $ac_dir/$ac_word --update -q /dev/null /dev/null >&5 2>&1; then
8509 ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
8510 break 2
8511 fi
8512 fi
8513 done
8514 done
8515 IFS="$ac_save_IFS"
8516 test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
8517 ;;
8518esac
8519fi
8520MSGMERGE="$ac_cv_path_MSGMERGE"
8521if test "$MSGMERGE" != ":"; then
8522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
8523$as_echo "$MSGMERGE" >&6; }
8524else
8525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8526$as_echo "no" >&6; }
8527fi
8528
8529
8530 test -n "$localedir" || localedir='${datadir}/locale'
8531
8532
8533 test -n "${XGETTEXT_EXTRA_OPTIONS+set}" || XGETTEXT_EXTRA_OPTIONS=
8534
8535
8536 ac_config_commands="$ac_config_commands po-directories"
8537
8538
8539
8540 if test "X$prefix" = "XNONE"; then
8541 acl_final_prefix="$ac_default_prefix"
8542 else
8543 acl_final_prefix="$prefix"
8544 fi
8545 if test "X$exec_prefix" = "XNONE"; then
8546 acl_final_exec_prefix='${prefix}'
8547 else
8548 acl_final_exec_prefix="$exec_prefix"
8549 fi
8550 acl_save_prefix="$prefix"
8551 prefix="$acl_final_prefix"
8552 eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
8553 prefix="$acl_save_prefix"
8554
8555
8556
8557# Check whether --with-gnu-ld was given.
8558if test "${with_gnu_ld+set}" = set; then :
8559 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
8560else
8561 with_gnu_ld=no
8562fi
8563
8564# Prepare PATH_SEPARATOR.
8565# The user is always right.
8566if test "${PATH_SEPARATOR+set}" != set; then
8567 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
8568 # contains only /bin. Note that ksh looks also at the FPATH variable,
8569 # so we have to set that as well for the test.
8570 PATH_SEPARATOR=:
8571 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8572 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8573 || PATH_SEPARATOR=';'
8574 }
8575fi
8576
8577ac_prog=ld
8578if test "$GCC" = yes; then
8579 # Check if gcc -print-prog-name=ld gives a path.
8580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
8581$as_echo_n "checking for ld used by $CC... " >&6; }
8582 case $host in
8583 *-*-mingw*)
8584 # gcc leaves a trailing carriage return which upsets mingw
8585 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
8586 *)
8587 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
8588 esac
8589 case $ac_prog in
8590 # Accept absolute paths.
8591 [\\/]* | ?:[\\/]*)
8592 re_direlt='/[^/][^/]*/\.\./'
8593 # Canonicalize the pathname of ld
8594 ac_prog=`echo "$ac_prog"| sed 's%\\\\%/%g'`
8595 while echo "$ac_prog" | grep "$re_direlt" > /dev/null 2>&1; do
8596 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
8597 done
8598 test -z "$LD" && LD="$ac_prog"
8599 ;;
8600 "")
8601 # If it fails, then pretend we aren't using GCC.
8602 ac_prog=ld
8603 ;;
8604 *)
8605 # If it is relative, then search for the first ld in PATH.
8606 with_gnu_ld=unknown
8607 ;;
8608 esac
8609elif test "$with_gnu_ld" = yes; then
8610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
8611$as_echo_n "checking for GNU ld... " >&6; }
8612else
8613 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
8614$as_echo_n "checking for non-GNU ld... " >&6; }
8615fi
8616if ${acl_cv_path_LD+:} false; then :
8617 $as_echo_n "(cached) " >&6
8618else
8619 if test -z "$LD"; then
8620 acl_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
8621 for ac_dir in $PATH; do
8622 IFS="$acl_save_ifs"
8623 test -z "$ac_dir" && ac_dir=.
8624 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
8625 acl_cv_path_LD="$ac_dir/$ac_prog"
8626 # Check to see if the program is GNU ld. I'd rather use --version,
8627 # but apparently some variants of GNU ld only accept -v.
8628 # Break only if it was the GNU/non-GNU ld that we prefer.
8629 case `"$acl_cv_path_LD" -v 2>&1 </dev/null` in
8630 *GNU* | *'with BFD'*)
8631 test "$with_gnu_ld" != no && break
8632 ;;
8633 *)
8634 test "$with_gnu_ld" != yes && break
8635 ;;
8636 esac
8637 fi
8638 done
8639 IFS="$acl_save_ifs"
8640else
8641 acl_cv_path_LD="$LD" # Let the user override the test with a path.
8642fi
8643fi
8644
8645LD="$acl_cv_path_LD"
8646if test -n "$LD"; then
8647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
8648$as_echo "$LD" >&6; }
8649else
8650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8651$as_echo "no" >&6; }
8652fi
8653test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
8654{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
8655$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
8656if ${acl_cv_prog_gnu_ld+:} false; then :
8657 $as_echo_n "(cached) " >&6
8658else
8659 # I'd rather use --version here, but apparently some GNU lds only accept -v.
8660case `$LD -v 2>&1 </dev/null` in
8661*GNU* | *'with BFD'*)
8662 acl_cv_prog_gnu_ld=yes
8663 ;;
8664*)
8665 acl_cv_prog_gnu_ld=no
8666 ;;
8667esac
8668fi
8669{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
8670$as_echo "$acl_cv_prog_gnu_ld" >&6; }
8671with_gnu_ld=$acl_cv_prog_gnu_ld
8672
8673
8674
8675
8676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
8677$as_echo_n "checking for shared library run path origin... " >&6; }
8678if ${acl_cv_rpath+:} false; then :
8679 $as_echo_n "(cached) " >&6
8680else
8681
8682 CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
8683 ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
8684 . ./conftest.sh
8685 rm -f ./conftest.sh
8686 acl_cv_rpath=done
8687
8688fi
8689{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
8690$as_echo "$acl_cv_rpath" >&6; }
8691 wl="$acl_cv_wl"
8692 acl_libext="$acl_cv_libext"
8693 acl_shlibext="$acl_cv_shlibext"
8694 acl_libname_spec="$acl_cv_libname_spec"
8695 acl_library_names_spec="$acl_cv_library_names_spec"
8696 acl_hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
8697 acl_hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
8698 acl_hardcode_direct="$acl_cv_hardcode_direct"
8699 acl_hardcode_minus_L="$acl_cv_hardcode_minus_L"
8700 # Check whether --enable-rpath was given.
8701if test "${enable_rpath+set}" = set; then :
8702 enableval=$enable_rpath; :
8703else
8704 enable_rpath=yes
8705fi
8706
8707
8708
8709
8710 acl_libdirstem=lib
8711 acl_libdirstem2=
8712 case "$host_os" in
8713 solaris*)
8714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit host" >&5
8715$as_echo_n "checking for 64-bit host... " >&6; }
8716if ${gl_cv_solaris_64bit+:} false; then :
8717 $as_echo_n "(cached) " >&6
8718else
8719 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8720/* end confdefs.h. */
8721
8722#ifdef _LP64
8723sixtyfour bits
8724#endif
8725
8726_ACEOF
8727if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8728 $EGREP "sixtyfour bits" >/dev/null 2>&1; then :
8729 gl_cv_solaris_64bit=yes
8730else
8731 gl_cv_solaris_64bit=no
8732fi
8733rm -f conftest*
8734
8735
8736fi
8737{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_solaris_64bit" >&5
8738$as_echo "$gl_cv_solaris_64bit" >&6; }
8739 if test $gl_cv_solaris_64bit = yes; then
8740 acl_libdirstem=lib/64
8741 case "$host_cpu" in
8742 sparc*) acl_libdirstem2=lib/sparcv9 ;;
8743 i*86 | x86_64) acl_libdirstem2=lib/amd64 ;;
8744 esac
8745 fi
8746 ;;
8747 *)
8748 searchpath=`(LC_ALL=C $CC -print-search-dirs) 2>/dev/null | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'`
8749 if test -n "$searchpath"; then
8750 acl_save_IFS="${IFS= }"; IFS=":"
8751 for searchdir in $searchpath; do
8752 if test -d "$searchdir"; then
8753 case "$searchdir" in
8754 */lib64/ | */lib64 ) acl_libdirstem=lib64 ;;
8755 */../ | */.. )
8756 # Better ignore directories of this form. They are misleading.
8757 ;;
8758 *) searchdir=`cd "$searchdir" && pwd`
8759 case "$searchdir" in
8760 */lib64 ) acl_libdirstem=lib64 ;;
8761 esac ;;
8762 esac
8763 fi
8764 done
8765 IFS="$acl_save_IFS"
8766 fi
8767 ;;
8768 esac
8769 test -n "$acl_libdirstem2" || acl_libdirstem2="$acl_libdirstem"
8770
8771
8772
8773
8774
8775
8776
8777
8778
8779
8780
8781
8782 use_additional=yes
8783
8784 acl_save_prefix="$prefix"
8785 prefix="$acl_final_prefix"
8786 acl_save_exec_prefix="$exec_prefix"
8787 exec_prefix="$acl_final_exec_prefix"
8788
8789 eval additional_includedir=\"$includedir\"
8790 eval additional_libdir=\"$libdir\"
8791
8792 exec_prefix="$acl_save_exec_prefix"
8793 prefix="$acl_save_prefix"
8794
8795
8796# Check whether --with-libiconv-prefix was given.
8797if test "${with_libiconv_prefix+set}" = set; then :
8798 withval=$with_libiconv_prefix;
8799 if test "X$withval" = "Xno"; then
8800 use_additional=no
8801 else
8802 if test "X$withval" = "X"; then
8803
8804 acl_save_prefix="$prefix"
8805 prefix="$acl_final_prefix"
8806 acl_save_exec_prefix="$exec_prefix"
8807 exec_prefix="$acl_final_exec_prefix"
8808
8809 eval additional_includedir=\"$includedir\"
8810 eval additional_libdir=\"$libdir\"
8811
8812 exec_prefix="$acl_save_exec_prefix"
8813 prefix="$acl_save_prefix"
8814
8815 else
8816 additional_includedir="$withval/include"
8817 additional_libdir="$withval/$acl_libdirstem"
8818 if test "$acl_libdirstem2" != "$acl_libdirstem" \
8819 && ! test -d "$withval/$acl_libdirstem"; then
8820 additional_libdir="$withval/$acl_libdirstem2"
8821 fi
8822 fi
8823 fi
8824
8825fi
8826
8827 LIBICONV=
8828 LTLIBICONV=
8829 INCICONV=
8830 LIBICONV_PREFIX=
8831 HAVE_LIBICONV=
8832 rpathdirs=
8833 ltrpathdirs=
8834 names_already_handled=
8835 names_next_round='iconv '
8836 while test -n "$names_next_round"; do
8837 names_this_round="$names_next_round"
8838 names_next_round=
8839 for name in $names_this_round; do
8840 already_handled=
8841 for n in $names_already_handled; do
8842 if test "$n" = "$name"; then
8843 already_handled=yes
8844 break
8845 fi
8846 done
8847 if test -z "$already_handled"; then
8848 names_already_handled="$names_already_handled $name"
8849 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./+-|ABCDEFGHIJKLMNOPQRSTUVWXYZ____|'`
8850 eval value=\"\$HAVE_LIB$uppername\"
8851 if test -n "$value"; then
8852 if test "$value" = yes; then
8853 eval value=\"\$LIB$uppername\"
8854 test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
8855 eval value=\"\$LTLIB$uppername\"
8856 test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
8857 else
8858 :
8859 fi
8860 else
8861 found_dir=
8862 found_la=
8863 found_so=
8864 found_a=
8865 eval libname=\"$acl_libname_spec\" # typically: libname=lib$name
8866 if test -n "$acl_shlibext"; then
8867 shrext=".$acl_shlibext" # typically: shrext=.so
8868 else
8869 shrext=
8870 fi
8871 if test $use_additional = yes; then
8872 dir="$additional_libdir"
8873 if test -n "$acl_shlibext"; then
8874 if test -f "$dir/$libname$shrext"; then
8875 found_dir="$dir"
8876 found_so="$dir/$libname$shrext"
8877 else
8878 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
8879 ver=`(cd "$dir" && \
8880 for f in "$libname$shrext".*; do echo "$f"; done \
8881 | sed -e "s,^$libname$shrext\\\\.,," \
8882 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
8883 | sed 1q ) 2>/dev/null`
8884 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
8885 found_dir="$dir"
8886 found_so="$dir/$libname$shrext.$ver"
8887 fi
8888 else
8889 eval library_names=\"$acl_library_names_spec\"
8890 for f in $library_names; do
8891 if test -f "$dir/$f"; then
8892 found_dir="$dir"
8893 found_so="$dir/$f"
8894 break
8895 fi
8896 done
8897 fi
8898 fi
8899 fi
8900 if test "X$found_dir" = "X"; then
8901 if test -f "$dir/$libname.$acl_libext"; then
8902 found_dir="$dir"
8903 found_a="$dir/$libname.$acl_libext"
8904 fi
8905 fi
8906 if test "X$found_dir" != "X"; then
8907 if test -f "$dir/$libname.la"; then
8908 found_la="$dir/$libname.la"
8909 fi
8910 fi
8911 fi
8912 if test "X$found_dir" = "X"; then
8913 for x in $LDFLAGS $LTLIBICONV; do
8914
8915 acl_save_prefix="$prefix"
8916 prefix="$acl_final_prefix"
8917 acl_save_exec_prefix="$exec_prefix"
8918 exec_prefix="$acl_final_exec_prefix"
8919 eval x=\"$x\"
8920 exec_prefix="$acl_save_exec_prefix"
8921 prefix="$acl_save_prefix"
8922
8923 case "$x" in
8924 -L*)
8925 dir=`echo "X$x" | sed -e 's/^X-L//'`
8926 if test -n "$acl_shlibext"; then
8927 if test -f "$dir/$libname$shrext"; then
8928 found_dir="$dir"
8929 found_so="$dir/$libname$shrext"
8930 else
8931 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
8932 ver=`(cd "$dir" && \
8933 for f in "$libname$shrext".*; do echo "$f"; done \
8934 | sed -e "s,^$libname$shrext\\\\.,," \
8935 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
8936 | sed 1q ) 2>/dev/null`
8937 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
8938 found_dir="$dir"
8939 found_so="$dir/$libname$shrext.$ver"
8940 fi
8941 else
8942 eval library_names=\"$acl_library_names_spec\"
8943 for f in $library_names; do
8944 if test -f "$dir/$f"; then
8945 found_dir="$dir"
8946 found_so="$dir/$f"
8947 break
8948 fi
8949 done
8950 fi
8951 fi
8952 fi
8953 if test "X$found_dir" = "X"; then
8954 if test -f "$dir/$libname.$acl_libext"; then
8955 found_dir="$dir"
8956 found_a="$dir/$libname.$acl_libext"
8957 fi
8958 fi
8959 if test "X$found_dir" != "X"; then
8960 if test -f "$dir/$libname.la"; then
8961 found_la="$dir/$libname.la"
8962 fi
8963 fi
8964 ;;
8965 esac
8966 if test "X$found_dir" != "X"; then
8967 break
8968 fi
8969 done
8970 fi
8971 if test "X$found_dir" != "X"; then
8972 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
8973 if test "X$found_so" != "X"; then
8974 if test "$enable_rpath" = no \
8975 || test "X$found_dir" = "X/usr/$acl_libdirstem" \
8976 || test "X$found_dir" = "X/usr/$acl_libdirstem2"; then
8977 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
8978 else
8979 haveit=
8980 for x in $ltrpathdirs; do
8981 if test "X$x" = "X$found_dir"; then
8982 haveit=yes
8983 break
8984 fi
8985 done
8986 if test -z "$haveit"; then
8987 ltrpathdirs="$ltrpathdirs $found_dir"
8988 fi
8989 if test "$acl_hardcode_direct" = yes; then
8990 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
8991 else
8992 if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
8993 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
8994 haveit=
8995 for x in $rpathdirs; do
8996 if test "X$x" = "X$found_dir"; then
8997 haveit=yes
8998 break
8999 fi
9000 done
9001 if test -z "$haveit"; then
9002 rpathdirs="$rpathdirs $found_dir"
9003 fi
9004 else
9005 haveit=
9006 for x in $LDFLAGS $LIBICONV; do
9007
9008 acl_save_prefix="$prefix"
9009 prefix="$acl_final_prefix"
9010 acl_save_exec_prefix="$exec_prefix"
9011 exec_prefix="$acl_final_exec_prefix"
9012 eval x=\"$x\"
9013 exec_prefix="$acl_save_exec_prefix"
9014 prefix="$acl_save_prefix"
9015
9016 if test "X$x" = "X-L$found_dir"; then
9017 haveit=yes
9018 break
9019 fi
9020 done
9021 if test -z "$haveit"; then
9022 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
9023 fi
9024 if test "$acl_hardcode_minus_L" != no; then
9025 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
9026 else
9027 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
9028 fi
9029 fi
9030 fi
9031 fi
9032 else
9033 if test "X$found_a" != "X"; then
9034 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
9035 else
9036 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
9037 fi
9038 fi
9039 additional_includedir=
9040 case "$found_dir" in
9041 */$acl_libdirstem | */$acl_libdirstem/)
9042 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
9043 if test "$name" = 'iconv'; then
9044 LIBICONV_PREFIX="$basedir"
9045 fi
9046 additional_includedir="$basedir/include"
9047 ;;
9048 */$acl_libdirstem2 | */$acl_libdirstem2/)
9049 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
9050 if test "$name" = 'iconv'; then
9051 LIBICONV_PREFIX="$basedir"
9052 fi
9053 additional_includedir="$basedir/include"
9054 ;;
9055 esac
9056 if test "X$additional_includedir" != "X"; then
9057 if test "X$additional_includedir" != "X/usr/include"; then
9058 haveit=
9059 if test "X$additional_includedir" = "X/usr/local/include"; then
9060 if test -n "$GCC"; then
9061 case $host_os in
9062 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
9063 esac
9064 fi
9065 fi
9066 if test -z "$haveit"; then
9067 for x in $CPPFLAGS $INCICONV; do
9068
9069 acl_save_prefix="$prefix"
9070 prefix="$acl_final_prefix"
9071 acl_save_exec_prefix="$exec_prefix"
9072 exec_prefix="$acl_final_exec_prefix"
9073 eval x=\"$x\"
9074 exec_prefix="$acl_save_exec_prefix"
9075 prefix="$acl_save_prefix"
9076
9077 if test "X$x" = "X-I$additional_includedir"; then
9078 haveit=yes
9079 break
9080 fi
9081 done
9082 if test -z "$haveit"; then
9083 if test -d "$additional_includedir"; then
9084 INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
9085 fi
9086 fi
9087 fi
9088 fi
9089 fi
9090 if test -n "$found_la"; then
9091 save_libdir="$libdir"
9092 case "$found_la" in
9093 */* | *\\*) . "$found_la" ;;
9094 *) . "./$found_la" ;;
9095 esac
9096 libdir="$save_libdir"
9097 for dep in $dependency_libs; do
9098 case "$dep" in
9099 -L*)
9100 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
9101 if test "X$additional_libdir" != "X/usr/$acl_libdirstem" \
9102 && test "X$additional_libdir" != "X/usr/$acl_libdirstem2"; then
9103 haveit=
9104 if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem" \
9105 || test "X$additional_libdir" = "X/usr/local/$acl_libdirstem2"; then
9106 if test -n "$GCC"; then
9107 case $host_os in
9108 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
9109 esac
9110 fi
9111 fi
9112 if test -z "$haveit"; then
9113 haveit=
9114 for x in $LDFLAGS $LIBICONV; do
9115
9116 acl_save_prefix="$prefix"
9117 prefix="$acl_final_prefix"
9118 acl_save_exec_prefix="$exec_prefix"
9119 exec_prefix="$acl_final_exec_prefix"
9120 eval x=\"$x\"
9121 exec_prefix="$acl_save_exec_prefix"
9122 prefix="$acl_save_prefix"
9123
9124 if test "X$x" = "X-L$additional_libdir"; then
9125 haveit=yes
9126 break
9127 fi
9128 done
9129 if test -z "$haveit"; then
9130 if test -d "$additional_libdir"; then
9131 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir"
9132 fi
9133 fi
9134 haveit=
9135 for x in $LDFLAGS $LTLIBICONV; do
9136
9137 acl_save_prefix="$prefix"
9138 prefix="$acl_final_prefix"
9139 acl_save_exec_prefix="$exec_prefix"
9140 exec_prefix="$acl_final_exec_prefix"
9141 eval x=\"$x\"
9142 exec_prefix="$acl_save_exec_prefix"
9143 prefix="$acl_save_prefix"
9144
9145 if test "X$x" = "X-L$additional_libdir"; then
9146 haveit=yes
9147 break
9148 fi
9149 done
9150 if test -z "$haveit"; then
9151 if test -d "$additional_libdir"; then
9152 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir"
9153 fi
9154 fi
9155 fi
9156 fi
9157 ;;
9158 -R*)
9159 dir=`echo "X$dep" | sed -e 's/^X-R//'`
9160 if test "$enable_rpath" != no; then
9161 haveit=
9162 for x in $rpathdirs; do
9163 if test "X$x" = "X$dir"; then
9164 haveit=yes
9165 break
9166 fi
9167 done
9168 if test -z "$haveit"; then
9169 rpathdirs="$rpathdirs $dir"
9170 fi
9171 haveit=
9172 for x in $ltrpathdirs; do
9173 if test "X$x" = "X$dir"; then
9174 haveit=yes
9175 break
9176 fi
9177 done
9178 if test -z "$haveit"; then
9179 ltrpathdirs="$ltrpathdirs $dir"
9180 fi
9181 fi
9182 ;;
9183 -l*)
9184 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
9185 ;;
9186 *.la)
9187 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
9188 ;;
9189 *)
9190 LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
9191 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
9192 ;;
9193 esac
9194 done
9195 fi
9196 else
9197 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
9198 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
9199 fi
9200 fi
9201 fi
9202 done
9203 done
9204 if test "X$rpathdirs" != "X"; then
9205 if test -n "$acl_hardcode_libdir_separator"; then
9206 alldirs=
9207 for found_dir in $rpathdirs; do
9208 alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir"
9209 done
9210 acl_save_libdir="$libdir"
9211 libdir="$alldirs"
9212 eval flag=\"$acl_hardcode_libdir_flag_spec\"
9213 libdir="$acl_save_libdir"
9214 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
9215 else
9216 for found_dir in $rpathdirs; do
9217 acl_save_libdir="$libdir"
9218 libdir="$found_dir"
9219 eval flag=\"$acl_hardcode_libdir_flag_spec\"
9220 libdir="$acl_save_libdir"
9221 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
9222 done
9223 fi
9224 fi
9225 if test "X$ltrpathdirs" != "X"; then
9226 for found_dir in $ltrpathdirs; do
9227 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
9228 done
9229 fi
9230
9231
9232
9233
9234
9235
9236
9237
9238
9239
9240
9241
9242
9243
9244
9245
9246
9247
9248
9249
9250
9251
9252
9253
9254
9255
9256
9257
9258
9259
9260
9261 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5
9262$as_echo_n "checking for CFPreferencesCopyAppValue... " >&6; }
9263if ${gt_cv_func_CFPreferencesCopyAppValue+:} false; then :
9264 $as_echo_n "(cached) " >&6
9265else
9266 gt_save_LIBS="$LIBS"
9267 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
9268 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9269/* end confdefs.h. */
9270#include <CoreFoundation/CFPreferences.h>
9271int
9272main (void)
9273{
9274CFPreferencesCopyAppValue(NULL, NULL)
9275 ;
9276 return 0;
9277}
9278_ACEOF
9279if ac_fn_c_try_link "$LINENO"; then :
9280 gt_cv_func_CFPreferencesCopyAppValue=yes
9281else
9282 gt_cv_func_CFPreferencesCopyAppValue=no
9283fi
9284rm -f core conftest.err conftest.$ac_objext \
9285 conftest$ac_exeext conftest.$ac_ext
9286 LIBS="$gt_save_LIBS"
9287fi
9288{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5
9289$as_echo "$gt_cv_func_CFPreferencesCopyAppValue" >&6; }
9290 if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
9291
9292$as_echo "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h
9293
9294 fi
9295 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyCurrent" >&5
9296$as_echo_n "checking for CFLocaleCopyCurrent... " >&6; }
9297if ${gt_cv_func_CFLocaleCopyCurrent+:} false; then :
9298 $as_echo_n "(cached) " >&6
9299else
9300 gt_save_LIBS="$LIBS"
9301 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
9302 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9303/* end confdefs.h. */
9304#include <CoreFoundation/CFLocale.h>
9305int
9306main (void)
9307{
9308CFLocaleCopyCurrent();
9309 ;
9310 return 0;
9311}
9312_ACEOF
9313if ac_fn_c_try_link "$LINENO"; then :
9314 gt_cv_func_CFLocaleCopyCurrent=yes
9315else
9316 gt_cv_func_CFLocaleCopyCurrent=no
9317fi
9318rm -f core conftest.err conftest.$ac_objext \
9319 conftest$ac_exeext conftest.$ac_ext
9320 LIBS="$gt_save_LIBS"
9321fi
9322{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyCurrent" >&5
9323$as_echo "$gt_cv_func_CFLocaleCopyCurrent" >&6; }
9324 if test $gt_cv_func_CFLocaleCopyCurrent = yes; then
9325
9326$as_echo "#define HAVE_CFLOCALECOPYCURRENT 1" >>confdefs.h
9327
9328 fi
9329 INTL_MACOSX_LIBS=
9330 if test $gt_cv_func_CFPreferencesCopyAppValue = yes || test $gt_cv_func_CFLocaleCopyCurrent = yes; then
9331 INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation"
9332 fi
9333
9334
9335
9336
9337
9338
9339 LIBINTL=
9340 LTLIBINTL=
9341 POSUB=
9342
9343 case " $gt_needs " in
9344 *" need-formatstring-macros "*) gt_api_version=3 ;;
9345 *" need-ngettext "*) gt_api_version=2 ;;
9346 *) gt_api_version=1 ;;
9347 esac
9348 gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc"
9349 gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl"
9350
9351 if test "$USE_NLS" = "yes"; then
9352 gt_use_preinstalled_gnugettext=no
9353
9354
9355 if test $gt_api_version -ge 3; then
9356 gt_revision_test_code='
9357#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
9358#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
9359#endif
9360typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
9361'
9362 else
9363 gt_revision_test_code=
9364 fi
9365 if test $gt_api_version -ge 2; then
9366 gt_expression_test_code=' + * ngettext ("", "", 0)'
9367 else
9368 gt_expression_test_code=
9369 fi
9370
9371 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5
9372$as_echo_n "checking for GNU gettext in libc... " >&6; }
9373if eval \${$gt_func_gnugettext_libc+:} false; then :
9374 $as_echo_n "(cached) " >&6
9375else
9376 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9377/* end confdefs.h. */
9378
9379#include <libintl.h>
9380$gt_revision_test_code
9381extern int _nl_msg_cat_cntr;
9382extern int *_nl_domain_bindings;
9383
9384int
9385main (void)
9386{
9387
9388bindtextdomain ("", "");
9389return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_domain_bindings
9390
9391 ;
9392 return 0;
9393}
9394_ACEOF
9395if ac_fn_c_try_link "$LINENO"; then :
9396 eval "$gt_func_gnugettext_libc=yes"
9397else
9398 eval "$gt_func_gnugettext_libc=no"
9399fi
9400rm -f core conftest.err conftest.$ac_objext \
9401 conftest$ac_exeext conftest.$ac_ext
9402fi
9403eval ac_res=\$$gt_func_gnugettext_libc
9404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
9405$as_echo "$ac_res" >&6; }
9406
9407 if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
9408
9409
9410
9411
9412
9413 am_save_CPPFLAGS="$CPPFLAGS"
9414
9415 for element in $INCICONV; do
9416 haveit=
9417 for x in $CPPFLAGS; do
9418
9419 acl_save_prefix="$prefix"
9420 prefix="$acl_final_prefix"
9421 acl_save_exec_prefix="$exec_prefix"
9422 exec_prefix="$acl_final_exec_prefix"
9423 eval x=\"$x\"
9424 exec_prefix="$acl_save_exec_prefix"
9425 prefix="$acl_save_prefix"
9426
9427 if test "X$x" = "X$element"; then
9428 haveit=yes
9429 break
9430 fi
9431 done
9432 if test -z "$haveit"; then
9433 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
9434 fi
9435 done
9436
9437
9438 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
9439$as_echo_n "checking for iconv... " >&6; }
9440if ${am_cv_func_iconv+:} false; then :
9441 $as_echo_n "(cached) " >&6
9442else
9443
9444 am_cv_func_iconv="no, consider installing GNU libiconv"
9445 am_cv_lib_iconv=no
9446 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9447/* end confdefs.h. */
9448
9449#include <stdlib.h>
9450#include <iconv.h>
9451
9452int
9453main (void)
9454{
9455iconv_t cd = iconv_open("","");
9456 iconv(cd,NULL,NULL,NULL,NULL);
9457 iconv_close(cd);
9458 ;
9459 return 0;
9460}
9461_ACEOF
9462if ac_fn_c_try_link "$LINENO"; then :
9463 am_cv_func_iconv=yes
9464fi
9465rm -f core conftest.err conftest.$ac_objext \
9466 conftest$ac_exeext conftest.$ac_ext
9467 if test "$am_cv_func_iconv" != yes; then
9468 am_save_LIBS="$LIBS"
9469 LIBS="$LIBS $LIBICONV"
9470 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9471/* end confdefs.h. */
9472
9473#include <stdlib.h>
9474#include <iconv.h>
9475
9476int
9477main (void)
9478{
9479iconv_t cd = iconv_open("","");
9480 iconv(cd,NULL,NULL,NULL,NULL);
9481 iconv_close(cd);
9482 ;
9483 return 0;
9484}
9485_ACEOF
9486if ac_fn_c_try_link "$LINENO"; then :
9487 am_cv_lib_iconv=yes
9488 am_cv_func_iconv=yes
9489fi
9490rm -f core conftest.err conftest.$ac_objext \
9491 conftest$ac_exeext conftest.$ac_ext
9492 LIBS="$am_save_LIBS"
9493 fi
9494
9495fi
9496{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
9497$as_echo "$am_cv_func_iconv" >&6; }
9498 if test "$am_cv_func_iconv" = yes; then
9499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
9500$as_echo_n "checking for working iconv... " >&6; }
9501if ${am_cv_func_iconv_works+:} false; then :
9502 $as_echo_n "(cached) " >&6
9503else
9504
9505 am_save_LIBS="$LIBS"
9506 if test $am_cv_lib_iconv = yes; then
9507 LIBS="$LIBS $LIBICONV"
9508 fi
9509 if test "$cross_compiling" = yes; then :
9510
9511 case "$host_os" in
9512 aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
9513 *) am_cv_func_iconv_works="guessing yes" ;;
9514 esac
9515
9516else
9517 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9518/* end confdefs.h. */
9519
9520#include <iconv.h>
9521#include <string.h>
9522int main ()
9523{
9524 int result = 0;
9525 /* Test against AIX 5.1 bug: Failures are not distinguishable from successful
9526 returns. */
9527 {
9528 iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
9529 if (cd_utf8_to_88591 != (iconv_t)(-1))
9530 {
9531 static const char input[] = "\342\202\254"; /* EURO SIGN */
9532 char buf[10];
9533 const char *inptr = input;
9534 size_t inbytesleft = strlen (input);
9535 char *outptr = buf;
9536 size_t outbytesleft = sizeof (buf);
9537 size_t res = iconv (cd_utf8_to_88591,
9538 (char **) &inptr, &inbytesleft,
9539 &outptr, &outbytesleft);
9540 if (res == 0)
9541 result |= 1;
9542 iconv_close (cd_utf8_to_88591);
9543 }
9544 }
9545 /* Test against Solaris 10 bug: Failures are not distinguishable from
9546 successful returns. */
9547 {
9548 iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
9549 if (cd_ascii_to_88591 != (iconv_t)(-1))
9550 {
9551 static const char input[] = "\263";
9552 char buf[10];
9553 const char *inptr = input;
9554 size_t inbytesleft = strlen (input);
9555 char *outptr = buf;
9556 size_t outbytesleft = sizeof (buf);
9557 size_t res = iconv (cd_ascii_to_88591,
9558 (char **) &inptr, &inbytesleft,
9559 &outptr, &outbytesleft);
9560 if (res == 0)
9561 result |= 2;
9562 iconv_close (cd_ascii_to_88591);
9563 }
9564 }
9565 /* Test against AIX 6.1..7.1 bug: Buffer overrun. */
9566 {
9567 iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1");
9568 if (cd_88591_to_utf8 != (iconv_t)(-1))
9569 {
9570 static const char input[] = "\304";
9571 static char buf[2] = { (char)0xDE, (char)0xAD };
9572 const char *inptr = input;
9573 size_t inbytesleft = 1;
9574 char *outptr = buf;
9575 size_t outbytesleft = 1;
9576 size_t res = iconv (cd_88591_to_utf8,
9577 (char **) &inptr, &inbytesleft,
9578 &outptr, &outbytesleft);
9579 if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD)
9580 result |= 4;
9581 iconv_close (cd_88591_to_utf8);
9582 }
9583 }
9584#if 0 /* This bug could be worked around by the caller. */
9585 /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */
9586 {
9587 iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
9588 if (cd_88591_to_utf8 != (iconv_t)(-1))
9589 {
9590 static const char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
9591 char buf[50];
9592 const char *inptr = input;
9593 size_t inbytesleft = strlen (input);
9594 char *outptr = buf;
9595 size_t outbytesleft = sizeof (buf);
9596 size_t res = iconv (cd_88591_to_utf8,
9597 (char **) &inptr, &inbytesleft,
9598 &outptr, &outbytesleft);
9599 if ((int)res > 0)
9600 result |= 8;
9601 iconv_close (cd_88591_to_utf8);
9602 }
9603 }
9604#endif
9605 /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
9606 provided. */
9607 if (/* Try standardized names. */
9608 iconv_open ("UTF-8", "EUC-JP") == (iconv_t)(-1)
9609 /* Try IRIX, OSF/1 names. */
9610 && iconv_open ("UTF-8", "eucJP") == (iconv_t)(-1)
9611 /* Try AIX names. */
9612 && iconv_open ("UTF-8", "IBM-eucJP") == (iconv_t)(-1)
9613 /* Try HP-UX names. */
9614 && iconv_open ("utf8", "eucJP") == (iconv_t)(-1))
9615 result |= 16;
9616 return result;
9617}
9618_ACEOF
9619if ac_fn_c_try_run "$LINENO"; then :
9620 am_cv_func_iconv_works=yes
9621else
9622 am_cv_func_iconv_works=no
9623fi
9624rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9625 conftest.$ac_objext conftest.beam conftest.$ac_ext
9626fi
9627
9628 LIBS="$am_save_LIBS"
9629
9630fi
9631{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5
9632$as_echo "$am_cv_func_iconv_works" >&6; }
9633 case "$am_cv_func_iconv_works" in
9634 *no) am_func_iconv=no am_cv_lib_iconv=no ;;
9635 *) am_func_iconv=yes ;;
9636 esac
9637 else
9638 am_func_iconv=no am_cv_lib_iconv=no
9639 fi
9640 if test "$am_func_iconv" = yes; then
9641
9642$as_echo "#define HAVE_ICONV 1" >>confdefs.h
9643
9644 fi
9645 if test "$am_cv_lib_iconv" = yes; then
9646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
9647$as_echo_n "checking how to link with libiconv... " >&6; }
9648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
9649$as_echo "$LIBICONV" >&6; }
9650 else
9651 CPPFLAGS="$am_save_CPPFLAGS"
9652 LIBICONV=
9653 LTLIBICONV=
9654 fi
9655
9656
9657
9658
9659
9660
9661
9662
9663
9664
9665
9666 use_additional=yes
9667
9668 acl_save_prefix="$prefix"
9669 prefix="$acl_final_prefix"
9670 acl_save_exec_prefix="$exec_prefix"
9671 exec_prefix="$acl_final_exec_prefix"
9672
9673 eval additional_includedir=\"$includedir\"
9674 eval additional_libdir=\"$libdir\"
9675
9676 exec_prefix="$acl_save_exec_prefix"
9677 prefix="$acl_save_prefix"
9678
9679
9680# Check whether --with-libintl-prefix was given.
9681if test "${with_libintl_prefix+set}" = set; then :
9682 withval=$with_libintl_prefix;
9683 if test "X$withval" = "Xno"; then
9684 use_additional=no
9685 else
9686 if test "X$withval" = "X"; then
9687
9688 acl_save_prefix="$prefix"
9689 prefix="$acl_final_prefix"
9690 acl_save_exec_prefix="$exec_prefix"
9691 exec_prefix="$acl_final_exec_prefix"
9692
9693 eval additional_includedir=\"$includedir\"
9694 eval additional_libdir=\"$libdir\"
9695
9696 exec_prefix="$acl_save_exec_prefix"
9697 prefix="$acl_save_prefix"
9698
9699 else
9700 additional_includedir="$withval/include"
9701 additional_libdir="$withval/$acl_libdirstem"
9702 if test "$acl_libdirstem2" != "$acl_libdirstem" \
9703 && ! test -d "$withval/$acl_libdirstem"; then
9704 additional_libdir="$withval/$acl_libdirstem2"
9705 fi
9706 fi
9707 fi
9708
9709fi
9710
9711 LIBINTL=
9712 LTLIBINTL=
9713 INCINTL=
9714 LIBINTL_PREFIX=
9715 HAVE_LIBINTL=
9716 rpathdirs=
9717 ltrpathdirs=
9718 names_already_handled=
9719 names_next_round='intl '
9720 while test -n "$names_next_round"; do
9721 names_this_round="$names_next_round"
9722 names_next_round=
9723 for name in $names_this_round; do
9724 already_handled=
9725 for n in $names_already_handled; do
9726 if test "$n" = "$name"; then
9727 already_handled=yes
9728 break
9729 fi
9730 done
9731 if test -z "$already_handled"; then
9732 names_already_handled="$names_already_handled $name"
9733 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./+-|ABCDEFGHIJKLMNOPQRSTUVWXYZ____|'`
9734 eval value=\"\$HAVE_LIB$uppername\"
9735 if test -n "$value"; then
9736 if test "$value" = yes; then
9737 eval value=\"\$LIB$uppername\"
9738 test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value"
9739 eval value=\"\$LTLIB$uppername\"
9740 test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value"
9741 else
9742 :
9743 fi
9744 else
9745 found_dir=
9746 found_la=
9747 found_so=
9748 found_a=
9749 eval libname=\"$acl_libname_spec\" # typically: libname=lib$name
9750 if test -n "$acl_shlibext"; then
9751 shrext=".$acl_shlibext" # typically: shrext=.so
9752 else
9753 shrext=
9754 fi
9755 if test $use_additional = yes; then
9756 dir="$additional_libdir"
9757 if test -n "$acl_shlibext"; then
9758 if test -f "$dir/$libname$shrext"; then
9759 found_dir="$dir"
9760 found_so="$dir/$libname$shrext"
9761 else
9762 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
9763 ver=`(cd "$dir" && \
9764 for f in "$libname$shrext".*; do echo "$f"; done \
9765 | sed -e "s,^$libname$shrext\\\\.,," \
9766 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
9767 | sed 1q ) 2>/dev/null`
9768 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
9769 found_dir="$dir"
9770 found_so="$dir/$libname$shrext.$ver"
9771 fi
9772 else
9773 eval library_names=\"$acl_library_names_spec\"
9774 for f in $library_names; do
9775 if test -f "$dir/$f"; then
9776 found_dir="$dir"
9777 found_so="$dir/$f"
9778 break
9779 fi
9780 done
9781 fi
9782 fi
9783 fi
9784 if test "X$found_dir" = "X"; then
9785 if test -f "$dir/$libname.$acl_libext"; then
9786 found_dir="$dir"
9787 found_a="$dir/$libname.$acl_libext"
9788 fi
9789 fi
9790 if test "X$found_dir" != "X"; then
9791 if test -f "$dir/$libname.la"; then
9792 found_la="$dir/$libname.la"
9793 fi
9794 fi
9795 fi
9796 if test "X$found_dir" = "X"; then
9797 for x in $LDFLAGS $LTLIBINTL; do
9798
9799 acl_save_prefix="$prefix"
9800 prefix="$acl_final_prefix"
9801 acl_save_exec_prefix="$exec_prefix"
9802 exec_prefix="$acl_final_exec_prefix"
9803 eval x=\"$x\"
9804 exec_prefix="$acl_save_exec_prefix"
9805 prefix="$acl_save_prefix"
9806
9807 case "$x" in
9808 -L*)
9809 dir=`echo "X$x" | sed -e 's/^X-L//'`
9810 if test -n "$acl_shlibext"; then
9811 if test -f "$dir/$libname$shrext"; then
9812 found_dir="$dir"
9813 found_so="$dir/$libname$shrext"
9814 else
9815 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
9816 ver=`(cd "$dir" && \
9817 for f in "$libname$shrext".*; do echo "$f"; done \
9818 | sed -e "s,^$libname$shrext\\\\.,," \
9819 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
9820 | sed 1q ) 2>/dev/null`
9821 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
9822 found_dir="$dir"
9823 found_so="$dir/$libname$shrext.$ver"
9824 fi
9825 else
9826 eval library_names=\"$acl_library_names_spec\"
9827 for f in $library_names; do
9828 if test -f "$dir/$f"; then
9829 found_dir="$dir"
9830 found_so="$dir/$f"
9831 break
9832 fi
9833 done
9834 fi
9835 fi
9836 fi
9837 if test "X$found_dir" = "X"; then
9838 if test -f "$dir/$libname.$acl_libext"; then
9839 found_dir="$dir"
9840 found_a="$dir/$libname.$acl_libext"
9841 fi
9842 fi
9843 if test "X$found_dir" != "X"; then
9844 if test -f "$dir/$libname.la"; then
9845 found_la="$dir/$libname.la"
9846 fi
9847 fi
9848 ;;
9849 esac
9850 if test "X$found_dir" != "X"; then
9851 break
9852 fi
9853 done
9854 fi
9855 if test "X$found_dir" != "X"; then
9856 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name"
9857 if test "X$found_so" != "X"; then
9858 if test "$enable_rpath" = no \
9859 || test "X$found_dir" = "X/usr/$acl_libdirstem" \
9860 || test "X$found_dir" = "X/usr/$acl_libdirstem2"; then
9861 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
9862 else
9863 haveit=
9864 for x in $ltrpathdirs; do
9865 if test "X$x" = "X$found_dir"; then
9866 haveit=yes
9867 break
9868 fi
9869 done
9870 if test -z "$haveit"; then
9871 ltrpathdirs="$ltrpathdirs $found_dir"
9872 fi
9873 if test "$acl_hardcode_direct" = yes; then
9874 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
9875 else
9876 if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
9877 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
9878 haveit=
9879 for x in $rpathdirs; do
9880 if test "X$x" = "X$found_dir"; then
9881 haveit=yes
9882 break
9883 fi
9884 done
9885 if test -z "$haveit"; then
9886 rpathdirs="$rpathdirs $found_dir"
9887 fi
9888 else
9889 haveit=
9890 for x in $LDFLAGS $LIBINTL; do
9891
9892 acl_save_prefix="$prefix"
9893 prefix="$acl_final_prefix"
9894 acl_save_exec_prefix="$exec_prefix"
9895 exec_prefix="$acl_final_exec_prefix"
9896 eval x=\"$x\"
9897 exec_prefix="$acl_save_exec_prefix"
9898 prefix="$acl_save_prefix"
9899
9900 if test "X$x" = "X-L$found_dir"; then
9901 haveit=yes
9902 break
9903 fi
9904 done
9905 if test -z "$haveit"; then
9906 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir"
9907 fi
9908 if test "$acl_hardcode_minus_L" != no; then
9909 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
9910 else
9911 LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
9912 fi
9913 fi
9914 fi
9915 fi
9916 else
9917 if test "X$found_a" != "X"; then
9918 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a"
9919 else
9920 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name"
9921 fi
9922 fi
9923 additional_includedir=
9924 case "$found_dir" in
9925 */$acl_libdirstem | */$acl_libdirstem/)
9926 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
9927 if test "$name" = 'intl'; then
9928 LIBINTL_PREFIX="$basedir"
9929 fi
9930 additional_includedir="$basedir/include"
9931 ;;
9932 */$acl_libdirstem2 | */$acl_libdirstem2/)
9933 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
9934 if test "$name" = 'intl'; then
9935 LIBINTL_PREFIX="$basedir"
9936 fi
9937 additional_includedir="$basedir/include"
9938 ;;
9939 esac
9940 if test "X$additional_includedir" != "X"; then
9941 if test "X$additional_includedir" != "X/usr/include"; then
9942 haveit=
9943 if test "X$additional_includedir" = "X/usr/local/include"; then
9944 if test -n "$GCC"; then
9945 case $host_os in
9946 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
9947 esac
9948 fi
9949 fi
9950 if test -z "$haveit"; then
9951 for x in $CPPFLAGS $INCINTL; do
9952
9953 acl_save_prefix="$prefix"
9954 prefix="$acl_final_prefix"
9955 acl_save_exec_prefix="$exec_prefix"
9956 exec_prefix="$acl_final_exec_prefix"
9957 eval x=\"$x\"
9958 exec_prefix="$acl_save_exec_prefix"
9959 prefix="$acl_save_prefix"
9960
9961 if test "X$x" = "X-I$additional_includedir"; then
9962 haveit=yes
9963 break
9964 fi
9965 done
9966 if test -z "$haveit"; then
9967 if test -d "$additional_includedir"; then
9968 INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir"
9969 fi
9970 fi
9971 fi
9972 fi
9973 fi
9974 if test -n "$found_la"; then
9975 save_libdir="$libdir"
9976 case "$found_la" in
9977 */* | *\\*) . "$found_la" ;;
9978 *) . "./$found_la" ;;
9979 esac
9980 libdir="$save_libdir"
9981 for dep in $dependency_libs; do
9982 case "$dep" in
9983 -L*)
9984 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
9985 if test "X$additional_libdir" != "X/usr/$acl_libdirstem" \
9986 && test "X$additional_libdir" != "X/usr/$acl_libdirstem2"; then
9987 haveit=
9988 if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem" \
9989 || test "X$additional_libdir" = "X/usr/local/$acl_libdirstem2"; then
9990 if test -n "$GCC"; then
9991 case $host_os in
9992 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
9993 esac
9994 fi
9995 fi
9996 if test -z "$haveit"; then
9997 haveit=
9998 for x in $LDFLAGS $LIBINTL; do
9999
10000 acl_save_prefix="$prefix"
10001 prefix="$acl_final_prefix"
10002 acl_save_exec_prefix="$exec_prefix"
10003 exec_prefix="$acl_final_exec_prefix"
10004 eval x=\"$x\"
10005 exec_prefix="$acl_save_exec_prefix"
10006 prefix="$acl_save_prefix"
10007
10008 if test "X$x" = "X-L$additional_libdir"; then
10009 haveit=yes
10010 break
10011 fi
10012 done
10013 if test -z "$haveit"; then
10014 if test -d "$additional_libdir"; then
10015 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir"
10016 fi
10017 fi
10018 haveit=
10019 for x in $LDFLAGS $LTLIBINTL; do
10020
10021 acl_save_prefix="$prefix"
10022 prefix="$acl_final_prefix"
10023 acl_save_exec_prefix="$exec_prefix"
10024 exec_prefix="$acl_final_exec_prefix"
10025 eval x=\"$x\"
10026 exec_prefix="$acl_save_exec_prefix"
10027 prefix="$acl_save_prefix"
10028
10029 if test "X$x" = "X-L$additional_libdir"; then
10030 haveit=yes
10031 break
10032 fi
10033 done
10034 if test -z "$haveit"; then
10035 if test -d "$additional_libdir"; then
10036 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir"
10037 fi
10038 fi
10039 fi
10040 fi
10041 ;;
10042 -R*)
10043 dir=`echo "X$dep" | sed -e 's/^X-R//'`
10044 if test "$enable_rpath" != no; then
10045 haveit=
10046 for x in $rpathdirs; do
10047 if test "X$x" = "X$dir"; then
10048 haveit=yes
10049 break
10050 fi
10051 done
10052 if test -z "$haveit"; then
10053 rpathdirs="$rpathdirs $dir"
10054 fi
10055 haveit=
10056 for x in $ltrpathdirs; do
10057 if test "X$x" = "X$dir"; then
10058 haveit=yes
10059 break
10060 fi
10061 done
10062 if test -z "$haveit"; then
10063 ltrpathdirs="$ltrpathdirs $dir"
10064 fi
10065 fi
10066 ;;
10067 -l*)
10068 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
10069 ;;
10070 *.la)
10071 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
10072 ;;
10073 *)
10074 LIBINTL="${LIBINTL}${LIBINTL:+ }$dep"
10075 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep"
10076 ;;
10077 esac
10078 done
10079 fi
10080 else
10081 LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
10082 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name"
10083 fi
10084 fi
10085 fi
10086 done
10087 done
10088 if test "X$rpathdirs" != "X"; then
10089 if test -n "$acl_hardcode_libdir_separator"; then
10090 alldirs=
10091 for found_dir in $rpathdirs; do
10092 alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir"
10093 done
10094 acl_save_libdir="$libdir"
10095 libdir="$alldirs"
10096 eval flag=\"$acl_hardcode_libdir_flag_spec\"
10097 libdir="$acl_save_libdir"
10098 LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
10099 else
10100 for found_dir in $rpathdirs; do
10101 acl_save_libdir="$libdir"
10102 libdir="$found_dir"
10103 eval flag=\"$acl_hardcode_libdir_flag_spec\"
10104 libdir="$acl_save_libdir"
10105 LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
10106 done
10107 fi
10108 fi
10109 if test "X$ltrpathdirs" != "X"; then
10110 for found_dir in $ltrpathdirs; do
10111 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir"
10112 done
10113 fi
10114
10115
10116
10117
10118
10119
10120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5
10121$as_echo_n "checking for GNU gettext in libintl... " >&6; }
10122if eval \${$gt_func_gnugettext_libintl+:} false; then :
10123 $as_echo_n "(cached) " >&6
10124else
10125 gt_save_CPPFLAGS="$CPPFLAGS"
10126 CPPFLAGS="$CPPFLAGS $INCINTL"
10127 gt_save_LIBS="$LIBS"
10128 LIBS="$LIBS $LIBINTL"
10129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10130/* end confdefs.h. */
10131
10132#include <libintl.h>
10133$gt_revision_test_code
10134extern int _nl_msg_cat_cntr;
10135extern
10136#ifdef __cplusplus
10137"C"
10138#endif
10139const char *_nl_expand_alias (const char *);
10140
10141int
10142main (void)
10143{
10144
10145bindtextdomain ("", "");
10146return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_alias ("")
10147
10148 ;
10149 return 0;
10150}
10151_ACEOF
10152if ac_fn_c_try_link "$LINENO"; then :
10153 eval "$gt_func_gnugettext_libintl=yes"
10154else
10155 eval "$gt_func_gnugettext_libintl=no"
10156fi
10157rm -f core conftest.err conftest.$ac_objext \
10158 conftest$ac_exeext conftest.$ac_ext
10159 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then
10160 LIBS="$LIBS $LIBICONV"
10161 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10162/* end confdefs.h. */
10163
10164#include <libintl.h>
10165$gt_revision_test_code
10166extern int _nl_msg_cat_cntr;
10167extern
10168#ifdef __cplusplus
10169"C"
10170#endif
10171const char *_nl_expand_alias (const char *);
10172
10173int
10174main (void)
10175{
10176
10177bindtextdomain ("", "");
10178return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_alias ("")
10179
10180 ;
10181 return 0;
10182}
10183_ACEOF
10184if ac_fn_c_try_link "$LINENO"; then :
10185 LIBINTL="$LIBINTL $LIBICONV"
10186 LTLIBINTL="$LTLIBINTL $LTLIBICONV"
10187 eval "$gt_func_gnugettext_libintl=yes"
10188
10189fi
10190rm -f core conftest.err conftest.$ac_objext \
10191 conftest$ac_exeext conftest.$ac_ext
10192 fi
10193 CPPFLAGS="$gt_save_CPPFLAGS"
10194 LIBS="$gt_save_LIBS"
10195fi
10196eval ac_res=\$$gt_func_gnugettext_libintl
10197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10198$as_echo "$ac_res" >&6; }
10199 fi
10200
10201 if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \
10202 || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \
10203 && test "$PACKAGE" != gettext-runtime \
10204 && test "$PACKAGE" != gettext-tools; }; then
10205 gt_use_preinstalled_gnugettext=yes
10206 else
10207 LIBINTL=
10208 LTLIBINTL=
10209 INCINTL=
10210 fi
10211
10212
10213
10214 if test -n "$INTL_MACOSX_LIBS"; then
10215 if test "$gt_use_preinstalled_gnugettext" = "yes" \
10216 || test "$nls_cv_use_gnu_gettext" = "yes"; then
10217 LIBINTL="$LIBINTL $INTL_MACOSX_LIBS"
10218 LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS"
10219 fi
10220 fi
10221
10222 if test "$gt_use_preinstalled_gnugettext" = "yes" \
10223 || test "$nls_cv_use_gnu_gettext" = "yes"; then
10224
10225$as_echo "#define ENABLE_NLS 1" >>confdefs.h
10226
10227 else
10228 USE_NLS=no
10229 fi
10230 fi
10231
10232 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5
10233$as_echo_n "checking whether to use NLS... " >&6; }
10234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
10235$as_echo "$USE_NLS" >&6; }
10236 if test "$USE_NLS" = "yes"; then
10237 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5
10238$as_echo_n "checking where the gettext function comes from... " >&6; }
10239 if test "$gt_use_preinstalled_gnugettext" = "yes"; then
10240 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
10241 gt_source="external libintl"
10242 else
10243 gt_source="libc"
10244 fi
10245 else
10246 gt_source="included intl directory"
10247 fi
10248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5
10249$as_echo "$gt_source" >&6; }
10250 fi
10251
10252 if test "$USE_NLS" = "yes"; then
10253
10254 if test "$gt_use_preinstalled_gnugettext" = "yes"; then
10255 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
10256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5
10257$as_echo_n "checking how to link with libintl... " >&6; }
10258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5
10259$as_echo "$LIBINTL" >&6; }
10260
10261 for element in $INCINTL; do
10262 haveit=
10263 for x in $CPPFLAGS; do
10264
10265 acl_save_prefix="$prefix"
10266 prefix="$acl_final_prefix"
10267 acl_save_exec_prefix="$exec_prefix"
10268 exec_prefix="$acl_final_exec_prefix"
10269 eval x=\"$x\"
10270 exec_prefix="$acl_save_exec_prefix"
10271 prefix="$acl_save_prefix"
10272
10273 if test "X$x" = "X$element"; then
10274 haveit=yes
10275 break
10276 fi
10277 done
10278 if test -z "$haveit"; then
10279 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
10280 fi
10281 done
10282
10283 fi
10284
10285
10286$as_echo "#define HAVE_GETTEXT 1" >>confdefs.h
10287
10288
10289$as_echo "#define HAVE_DCGETTEXT 1" >>confdefs.h
10290
10291 fi
10292
10293 POSUB=po
10294 fi
10295
10296
10297
10298 INTLLIBS="$LIBINTL"
10299
10300
10301
10302
10303
10304
10305# Check whether --enable-largefile was given.
10306if test "${enable_largefile+set}" = set; then :
10307 enableval=$enable_largefile;
10308fi
10309
10310if test "$enable_largefile" != no; then
10311
10312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
10313$as_echo_n "checking for special C compiler options needed for large files... " >&6; }
10314if ${ac_cv_sys_largefile_CC+:} false; then :
10315 $as_echo_n "(cached) " >&6
10316else
10317 ac_cv_sys_largefile_CC=no
10318 if test "$GCC" != yes; then
10319 ac_save_CC=$CC
10320 while :; do
10321 # IRIX 6.2 and later do not support large files by default,
10322 # so use the C compiler's -n32 option if that helps.
10323 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10324/* end confdefs.h. */
10325#include <sys/types.h>
10326 /* Check that off_t can represent 2**63 - 1 correctly.
10327 We can't simply define LARGE_OFF_T to be 9223372036854775807,
10328 since some C++ compilers masquerading as C compilers
10329 incorrectly reject 9223372036854775807. */
10330#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
10331 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
10332 && LARGE_OFF_T % 2147483647 == 1)
10333 ? 1 : -1];
10334int
10335main (void)
10336{
10337
10338 ;
10339 return 0;
10340}
10341_ACEOF
10342 if ac_fn_c_try_compile "$LINENO"; then :
10343 break
10344fi
10345rm -f core conftest.err conftest.$ac_objext
10346 CC="$CC -n32"
10347 if ac_fn_c_try_compile "$LINENO"; then :
10348 ac_cv_sys_largefile_CC=' -n32'; break
10349fi
10350rm -f core conftest.err conftest.$ac_objext
10351 break
10352 done
10353 CC=$ac_save_CC
10354 rm -f conftest.$ac_ext
10355 fi
10356fi
10357{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
10358$as_echo "$ac_cv_sys_largefile_CC" >&6; }
10359 if test "$ac_cv_sys_largefile_CC" != no; then
10360 CC=$CC$ac_cv_sys_largefile_CC
10361 fi
10362
10363 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
10364$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
10365if ${ac_cv_sys_file_offset_bits+:} false; then :
10366 $as_echo_n "(cached) " >&6
10367else
10368 while :; do
10369 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10370/* end confdefs.h. */
10371#include <sys/types.h>
10372 /* Check that off_t can represent 2**63 - 1 correctly.
10373 We can't simply define LARGE_OFF_T to be 9223372036854775807,
10374 since some C++ compilers masquerading as C compilers
10375 incorrectly reject 9223372036854775807. */
10376#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
10377 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
10378 && LARGE_OFF_T % 2147483647 == 1)
10379 ? 1 : -1];
10380int
10381main (void)
10382{
10383
10384 ;
10385 return 0;
10386}
10387_ACEOF
10388if ac_fn_c_try_compile "$LINENO"; then :
10389 ac_cv_sys_file_offset_bits=no; break
10390fi
10391rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10392 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10393/* end confdefs.h. */
10394#define _FILE_OFFSET_BITS 64
10395#include <sys/types.h>
10396 /* Check that off_t can represent 2**63 - 1 correctly.
10397 We can't simply define LARGE_OFF_T to be 9223372036854775807,
10398 since some C++ compilers masquerading as C compilers
10399 incorrectly reject 9223372036854775807. */
10400#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
10401 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
10402 && LARGE_OFF_T % 2147483647 == 1)
10403 ? 1 : -1];
10404int
10405main (void)
10406{
10407
10408 ;
10409 return 0;
10410}
10411_ACEOF
10412if ac_fn_c_try_compile "$LINENO"; then :
10413 ac_cv_sys_file_offset_bits=64; break
10414fi
10415rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10416 ac_cv_sys_file_offset_bits=unknown
10417 break
10418done
10419fi
10420{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
10421$as_echo "$ac_cv_sys_file_offset_bits" >&6; }
10422case $ac_cv_sys_file_offset_bits in #(
10423 no | unknown) ;;
10424 *)
10425cat >>confdefs.h <<_ACEOF
10426#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
10427_ACEOF
10428;;
10429esac
10430rm -rf conftest*
10431 if test $ac_cv_sys_file_offset_bits = unknown; then
10432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
10433$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
10434if ${ac_cv_sys_large_files+:} false; then :
10435 $as_echo_n "(cached) " >&6
10436else
10437 while :; do
10438 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10439/* end confdefs.h. */
10440#include <sys/types.h>
10441 /* Check that off_t can represent 2**63 - 1 correctly.
10442 We can't simply define LARGE_OFF_T to be 9223372036854775807,
10443 since some C++ compilers masquerading as C compilers
10444 incorrectly reject 9223372036854775807. */
10445#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
10446 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
10447 && LARGE_OFF_T % 2147483647 == 1)
10448 ? 1 : -1];
10449int
10450main (void)
10451{
10452
10453 ;
10454 return 0;
10455}
10456_ACEOF
10457if ac_fn_c_try_compile "$LINENO"; then :
10458 ac_cv_sys_large_files=no; break
10459fi
10460rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10461 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10462/* end confdefs.h. */
10463#define _LARGE_FILES 1
10464#include <sys/types.h>
10465 /* Check that off_t can represent 2**63 - 1 correctly.
10466 We can't simply define LARGE_OFF_T to be 9223372036854775807,
10467 since some C++ compilers masquerading as C compilers
10468 incorrectly reject 9223372036854775807. */
10469#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
10470 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
10471 && LARGE_OFF_T % 2147483647 == 1)
10472 ? 1 : -1];
10473int
10474main (void)
10475{
10476
10477 ;
10478 return 0;
10479}
10480_ACEOF
10481if ac_fn_c_try_compile "$LINENO"; then :
10482 ac_cv_sys_large_files=1; break
10483fi
10484rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10485 ac_cv_sys_large_files=unknown
10486 break
10487done
10488fi
10489{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
10490$as_echo "$ac_cv_sys_large_files" >&6; }
10491case $ac_cv_sys_large_files in #(
10492 no | unknown) ;;
10493 *)
10494cat >>confdefs.h <<_ACEOF
10495#define _LARGE_FILES $ac_cv_sys_large_files
10496_ACEOF
10497;;
10498esac
10499rm -rf conftest*
10500 fi
10501
10502
10503fi
10504
10505
10506# Identify characteristics of the host architecture.
10507unset ac_cv_c_bigendian
10508
10509if test x"$target_cpu-$platform" = xsparc64-emu ; then
10510 CFLAGS="$CFLAGS -m64"
10511 HOST_CFLAGS="$HOST_CFLAGS -m64"
10512fi
10513
10514CPPFLAGS="$CPPFLAGS -D_FILE_OFFSET_BITS=64"
10515HOST_CPPFLAGS="$HOST_CPPFLAGS -D_FILE_OFFSET_BITS=64"
10516
10517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
10518$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
10519if ${ac_cv_c_bigendian+:} false; then :
10520 $as_echo_n "(cached) " >&6
10521else
10522 ac_cv_c_bigendian=unknown
10523 # See if we're dealing with a universal compiler.
10524 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10525/* end confdefs.h. */
10526#ifndef __APPLE_CC__
10527 not a universal capable compiler
10528 #endif
10529 typedef int dummy;
10530
10531_ACEOF
10532if ac_fn_c_try_compile "$LINENO"; then :
10533
10534 # Check for potential -arch flags. It is not universal unless
10535 # there are at least two -arch flags with different values.
10536 ac_arch=
10537 ac_prev=
10538 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
10539 if test -n "$ac_prev"; then
10540 case $ac_word in
10541 i?86 | x86_64 | ppc | ppc64)
10542 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
10543 ac_arch=$ac_word
10544 else
10545 ac_cv_c_bigendian=universal
10546 break
10547 fi
10548 ;;
10549 esac
10550 ac_prev=
10551 elif test "x$ac_word" = "x-arch"; then
10552 ac_prev=arch
10553 fi
10554 done
10555fi
10556rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10557 if test $ac_cv_c_bigendian = unknown; then
10558 # See if sys/param.h defines the BYTE_ORDER macro.
10559 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10560/* end confdefs.h. */
10561#include <sys/types.h>
10562 #include <sys/param.h>
10563
10564int
10565main (void)
10566{
10567#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
10568 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
10569 && LITTLE_ENDIAN)
10570 bogus endian macros
10571 #endif
10572
10573 ;
10574 return 0;
10575}
10576_ACEOF
10577if ac_fn_c_try_compile "$LINENO"; then :
10578 # It does; now see whether it defined to BIG_ENDIAN or not.
10579 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10580/* end confdefs.h. */
10581#include <sys/types.h>
10582 #include <sys/param.h>
10583
10584int
10585main (void)
10586{
10587#if BYTE_ORDER != BIG_ENDIAN
10588 not big endian
10589 #endif
10590
10591 ;
10592 return 0;
10593}
10594_ACEOF
10595if ac_fn_c_try_compile "$LINENO"; then :
10596 ac_cv_c_bigendian=yes
10597else
10598 ac_cv_c_bigendian=no
10599fi
10600rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10601fi
10602rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10603 fi
10604 if test $ac_cv_c_bigendian = unknown; then
10605 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
10606 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10607/* end confdefs.h. */
10608#include <limits.h>
10609
10610int
10611main (void)
10612{
10613#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
10614 bogus endian macros
10615 #endif
10616
10617 ;
10618 return 0;
10619}
10620_ACEOF
10621if ac_fn_c_try_compile "$LINENO"; then :
10622 # It does; now see whether it defined to _BIG_ENDIAN or not.
10623 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10624/* end confdefs.h. */
10625#include <limits.h>
10626
10627int
10628main (void)
10629{
10630#ifndef _BIG_ENDIAN
10631 not big endian
10632 #endif
10633
10634 ;
10635 return 0;
10636}
10637_ACEOF
10638if ac_fn_c_try_compile "$LINENO"; then :
10639 ac_cv_c_bigendian=yes
10640else
10641 ac_cv_c_bigendian=no
10642fi
10643rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10644fi
10645rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10646 fi
10647 if test $ac_cv_c_bigendian = unknown; then
10648 # Compile a test program.
10649 if test "$cross_compiling" = yes; then :
10650 # Try to guess by grepping values from an object file.
10651 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10652/* end confdefs.h. */
10653short int ascii_mm[] =
10654 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
10655 short int ascii_ii[] =
10656 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
10657 int use_ascii (int i) {
10658 return ascii_mm[i] + ascii_ii[i];
10659 }
10660 short int ebcdic_ii[] =
10661 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
10662 short int ebcdic_mm[] =
10663 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
10664 int use_ebcdic (int i) {
10665 return ebcdic_mm[i] + ebcdic_ii[i];
10666 }
10667 extern int foo;
10668
10669int
10670main (void)
10671{
10672return use_ascii (foo) == use_ebcdic (foo);
10673 ;
10674 return 0;
10675}
10676_ACEOF
10677if ac_fn_c_try_compile "$LINENO"; then :
10678 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
10679 ac_cv_c_bigendian=yes
10680 fi
10681 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
10682 if test "$ac_cv_c_bigendian" = unknown; then
10683 ac_cv_c_bigendian=no
10684 else
10685 # finding both strings is unlikely to happen, but who knows?
10686 ac_cv_c_bigendian=unknown
10687 fi
10688 fi
10689fi
10690rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10691else
10692 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10693/* end confdefs.h. */
10694$ac_includes_default
10695int
10696main (void)
10697{
10698
10699 /* Are we little or big endian? From Harbison&Steele. */
10700 union
10701 {
10702 long int l;
10703 char c[sizeof (long int)];
10704 } u;
10705 u.l = 1;
10706 return u.c[sizeof (long int) - 1] == 1;
10707
10708 ;
10709 return 0;
10710}
10711_ACEOF
10712if ac_fn_c_try_run "$LINENO"; then :
10713 ac_cv_c_bigendian=no
10714else
10715 ac_cv_c_bigendian=yes
10716fi
10717rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10718 conftest.$ac_objext conftest.beam conftest.$ac_ext
10719fi
10720
10721 fi
10722fi
10723{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
10724$as_echo "$ac_cv_c_bigendian" >&6; }
10725 case $ac_cv_c_bigendian in #(
10726 yes)
10727 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
10728;; #(
10729 no)
10730 ;; #(
10731 universal)
10732
10733$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
10734
10735 ;; #(
10736 *)
10737 as_fn_error $? "unknown endianness
10738 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
10739 esac
10740
10741# The cast to long int works around a bug in the HP C Compiler
10742# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
10743# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
10744# This bug is HP SR number 8606223364.
10745{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5
10746$as_echo_n "checking size of void *... " >&6; }
10747if ${ac_cv_sizeof_void_p+:} false; then :
10748 $as_echo_n "(cached) " >&6
10749else
10750 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p" "$ac_includes_default"; then :
10751
10752else
10753 if test "$ac_cv_type_void_p" = yes; then
10754 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10755$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
10756as_fn_error 77 "cannot compute sizeof (void *)
10757See \`config.log' for more details" "$LINENO" 5; }
10758 else
10759 ac_cv_sizeof_void_p=0
10760 fi
10761fi
10762
10763fi
10764{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5
10765$as_echo "$ac_cv_sizeof_void_p" >&6; }
10766
10767
10768
10769cat >>confdefs.h <<_ACEOF
10770#define SIZEOF_VOID_P $ac_cv_sizeof_void_p
10771_ACEOF
10772
10773
10774# The cast to long int works around a bug in the HP C Compiler
10775# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
10776# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
10777# This bug is HP SR number 8606223364.
10778{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
10779$as_echo_n "checking size of long... " >&6; }
10780if ${ac_cv_sizeof_long+:} false; then :
10781 $as_echo_n "(cached) " >&6
10782else
10783 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then :
10784
10785else
10786 if test "$ac_cv_type_long" = yes; then
10787 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10788$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
10789as_fn_error 77 "cannot compute sizeof (long)
10790See \`config.log' for more details" "$LINENO" 5; }
10791 else
10792 ac_cv_sizeof_long=0
10793 fi
10794fi
10795
10796fi
10797{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
10798$as_echo "$ac_cv_sizeof_long" >&6; }
10799
10800
10801
10802cat >>confdefs.h <<_ACEOF
10803#define SIZEOF_LONG $ac_cv_sizeof_long
10804_ACEOF
10805
10806
10807
10808case "$host_os" in
10809 cygwin | windows* | mingw32*)
10810 HOST_CPPFLAGS="$HOST_CPPFLAGS -DUNICODE=1 -D_WIN32_WINNT=0x0500"
10811 CPPFLAGS="$CPPFLAGS -DUNICODE=1 -D_WIN32_WINNT=0x0500"
10812 # The cast to long int works around a bug in the HP C Compiler
10813# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
10814# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
10815# This bug is HP SR number 8606223364.
10816{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of TCHAR" >&5
10817$as_echo_n "checking size of TCHAR... " >&6; }
10818if ${ac_cv_sizeof_TCHAR+:} false; then :
10819 $as_echo_n "(cached) " >&6
10820else
10821 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (TCHAR))" "ac_cv_sizeof_TCHAR" "#include <windows.h>
10822"; then :
10823
10824else
10825 if test "$ac_cv_type_TCHAR" = yes; then
10826 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10827$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
10828as_fn_error 77 "cannot compute sizeof (TCHAR)
10829See \`config.log' for more details" "$LINENO" 5; }
10830 else
10831 ac_cv_sizeof_TCHAR=0
10832 fi
10833fi
10834
10835fi
10836{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_TCHAR" >&5
10837$as_echo "$ac_cv_sizeof_TCHAR" >&6; }
10838
10839
10840
10841cat >>confdefs.h <<_ACEOF
10842#define SIZEOF_TCHAR $ac_cv_sizeof_TCHAR
10843_ACEOF
10844
10845
10846 ;;
10847esac
10848
10849case "$host_os" in
10850 cygwin | windows* | mingw32* | aros*)
10851 ;;
10852 *)
10853 # The cast to long int works around a bug in the HP C Compiler
10854# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
10855# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
10856# This bug is HP SR number 8606223364.
10857{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5
10858$as_echo_n "checking size of off_t... " >&6; }
10859if ${ac_cv_sizeof_off_t+:} false; then :
10860 $as_echo_n "(cached) " >&6
10861else
10862 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (off_t))" "ac_cv_sizeof_off_t" "$ac_includes_default"; then :
10863
10864else
10865 if test "$ac_cv_type_off_t" = yes; then
10866 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10867$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
10868as_fn_error 77 "cannot compute sizeof (off_t)
10869See \`config.log' for more details" "$LINENO" 5; }
10870 else
10871 ac_cv_sizeof_off_t=0
10872 fi
10873fi
10874
10875fi
10876{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5
10877$as_echo "$ac_cv_sizeof_off_t" >&6; }
10878
10879
10880
10881cat >>confdefs.h <<_ACEOF
10882#define SIZEOF_OFF_T $ac_cv_sizeof_off_t
10883_ACEOF
10884
10885
10886 test x"$ac_cv_sizeof_off_t" = x8 || as_fn_error $? "Large file support is required" "$LINENO" 5;;
10887esac
10888
10889if test x$USE_NLS = xno; then
10890 HOST_CFLAGS="$HOST_CFLAGS -fno-builtin-gettext"
10891fi
10892
10893if test "x$cross_compiling" = xyes; then
10894 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot generate manual pages while cross compiling" >&5
10895$as_echo "$as_me: WARNING: cannot generate manual pages while cross compiling" >&2;}
10896else
10897 # Extract the first word of "help2man", so it can be a program name with args.
10898set dummy help2man; ac_word=$2
10899{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10900$as_echo_n "checking for $ac_word... " >&6; }
10901if ${ac_cv_path_HELP2MAN+:} false; then :
10902 $as_echo_n "(cached) " >&6
10903else
10904 case $HELP2MAN in
10905 [\\/]* | ?:[\\/]*)
10906 ac_cv_path_HELP2MAN="$HELP2MAN" # Let the user override the test with a path.
10907 ;;
10908 *)
10909 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10910for as_dir in $PATH
10911do
10912 IFS=$as_save_IFS
10913 test -z "$as_dir" && as_dir=.
10914 for ac_exec_ext in '' $ac_executable_extensions; do
10915 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10916 ac_cv_path_HELP2MAN="$as_dir/$ac_word$ac_exec_ext"
10917 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10918 break 2
10919 fi
10920done
10921 done
10922IFS=$as_save_IFS
10923
10924 ;;
10925esac
10926fi
10927HELP2MAN=$ac_cv_path_HELP2MAN
10928if test -n "$HELP2MAN"; then
10929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HELP2MAN" >&5
10930$as_echo "$HELP2MAN" >&6; }
10931else
10932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10933$as_echo "no" >&6; }
10934fi
10935
10936
10937fi
10938
10939# Check for functions and headers.
10940for ac_func in posix_memalign memalign getextmntent
10941do :
10942 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10943ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10944if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
10945 cat >>confdefs.h <<_ACEOF
10946#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10947_ACEOF
10948
10949fi
10950done
10951
10952for ac_header in sys/param.h sys/mount.h sys/mnttab.h limits.h
10953do :
10954 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10955ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
10956if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
10957 cat >>confdefs.h <<_ACEOF
10958#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10959_ACEOF
10960
10961fi
10962
10963done
10964
10965
10966# glibc 2.25 still includes sys/sysmacros.h in sys/types.h but emits deprecation
10967# warning which causes compilation failure later with -Werror. So use -Werror here
10968# as well to force proper sys/sysmacros.h detection.
10969SAVED_CFLAGS="$CFLAGS"
10970CFLAGS="$HOST_CFLAGS -Werror"
10971{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/types.h defines makedev" >&5
10972$as_echo_n "checking whether sys/types.h defines makedev... " >&6; }
10973if ${ac_cv_header_sys_types_h_makedev+:} false; then :
10974 $as_echo_n "(cached) " >&6
10975else
10976 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10977/* end confdefs.h. */
10978#include <sys/types.h>
10979int
10980main (void)
10981{
10982return makedev(0, 0);
10983 ;
10984 return 0;
10985}
10986_ACEOF
10987if ac_fn_c_try_link "$LINENO"; then :
10988 ac_cv_header_sys_types_h_makedev=yes
10989else
10990 ac_cv_header_sys_types_h_makedev=no
10991fi
10992rm -f core conftest.err conftest.$ac_objext \
10993 conftest$ac_exeext conftest.$ac_ext
10994
10995fi
10996{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_types_h_makedev" >&5
10997$as_echo "$ac_cv_header_sys_types_h_makedev" >&6; }
10998
10999if test $ac_cv_header_sys_types_h_makedev = no; then
11000ac_fn_c_check_header_mongrel "$LINENO" "sys/mkdev.h" "ac_cv_header_sys_mkdev_h" "$ac_includes_default"
11001if test "x$ac_cv_header_sys_mkdev_h" = xyes; then :
11002
11003$as_echo "#define MAJOR_IN_MKDEV 1" >>confdefs.h
11004
11005fi
11006
11007
11008
11009 if test $ac_cv_header_sys_mkdev_h = no; then
11010 ac_fn_c_check_header_mongrel "$LINENO" "sys/sysmacros.h" "ac_cv_header_sys_sysmacros_h" "$ac_includes_default"
11011if test "x$ac_cv_header_sys_sysmacros_h" = xyes; then :
11012
11013$as_echo "#define MAJOR_IN_SYSMACROS 1" >>confdefs.h
11014
11015fi
11016
11017
11018 fi
11019fi
11020
11021CFLAGS="$SAVED_CFLAGS"
11022
11023ac_fn_c_check_member "$LINENO" "struct statfs" "f_fstypename" "ac_cv_member_struct_statfs_f_fstypename" "$ac_includes_default
11024#include <sys/param.h>
11025#include <sys/mount.h>
11026"
11027if test "x$ac_cv_member_struct_statfs_f_fstypename" = xyes; then :
11028
11029cat >>confdefs.h <<_ACEOF
11030#define HAVE_STRUCT_STATFS_F_FSTYPENAME 1
11031_ACEOF
11032
11033
11034fi
11035
11036
11037ac_fn_c_check_member "$LINENO" "struct statfs" "f_mntfromname" "ac_cv_member_struct_statfs_f_mntfromname" "$ac_includes_default
11038#include <sys/param.h>
11039#include <sys/mount.h>
11040"
11041if test "x$ac_cv_member_struct_statfs_f_mntfromname" = xyes; then :
11042
11043cat >>confdefs.h <<_ACEOF
11044#define HAVE_STRUCT_STATFS_F_MNTFROMNAME 1
11045_ACEOF
11046
11047
11048fi
11049
11050
11051# For opendisk() and getrawpartition() on NetBSD.
11052# Used in util/deviceiter.c and in util/hostdisk.c.
11053ac_fn_c_check_header_mongrel "$LINENO" "util.h" "ac_cv_header_util_h" "$ac_includes_default"
11054if test "x$ac_cv_header_util_h" = xyes; then :
11055
11056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for opendisk in -lutil" >&5
11057$as_echo_n "checking for opendisk in -lutil... " >&6; }
11058if ${ac_cv_lib_util_opendisk+:} false; then :
11059 $as_echo_n "(cached) " >&6
11060else
11061 ac_check_lib_save_LIBS=$LIBS
11062LIBS="-lutil $LIBS"
11063cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11064/* end confdefs.h. */
11065
11066/* Override any GCC internal prototype to avoid an error.
11067 Use char because int might match the return type of a GCC
11068 builtin and then its argument prototype would still apply. */
11069#ifdef __cplusplus
11070extern "C"
11071#endif
11072char opendisk ();
11073int
11074main (void)
11075{
11076return opendisk ();
11077 ;
11078 return 0;
11079}
11080_ACEOF
11081if ac_fn_c_try_link "$LINENO"; then :
11082 ac_cv_lib_util_opendisk=yes
11083else
11084 ac_cv_lib_util_opendisk=no
11085fi
11086rm -f core conftest.err conftest.$ac_objext \
11087 conftest$ac_exeext conftest.$ac_ext
11088LIBS=$ac_check_lib_save_LIBS
11089fi
11090{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_opendisk" >&5
11091$as_echo "$ac_cv_lib_util_opendisk" >&6; }
11092if test "x$ac_cv_lib_util_opendisk" = xyes; then :
11093
11094 LIBUTIL="-lutil"
11095
11096$as_echo "#define HAVE_OPENDISK 1" >>confdefs.h
11097
11098
11099fi
11100
11101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getrawpartition in -lutil" >&5
11102$as_echo_n "checking for getrawpartition in -lutil... " >&6; }
11103if ${ac_cv_lib_util_getrawpartition+:} false; then :
11104 $as_echo_n "(cached) " >&6
11105else
11106 ac_check_lib_save_LIBS=$LIBS
11107LIBS="-lutil $LIBS"
11108cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11109/* end confdefs.h. */
11110
11111/* Override any GCC internal prototype to avoid an error.
11112 Use char because int might match the return type of a GCC
11113 builtin and then its argument prototype would still apply. */
11114#ifdef __cplusplus
11115extern "C"
11116#endif
11117char getrawpartition ();
11118int
11119main (void)
11120{
11121return getrawpartition ();
11122 ;
11123 return 0;
11124}
11125_ACEOF
11126if ac_fn_c_try_link "$LINENO"; then :
11127 ac_cv_lib_util_getrawpartition=yes
11128else
11129 ac_cv_lib_util_getrawpartition=no
11130fi
11131rm -f core conftest.err conftest.$ac_objext \
11132 conftest$ac_exeext conftest.$ac_ext
11133LIBS=$ac_check_lib_save_LIBS
11134fi
11135{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getrawpartition" >&5
11136$as_echo "$ac_cv_lib_util_getrawpartition" >&6; }
11137if test "x$ac_cv_lib_util_getrawpartition" = xyes; then :
11138
11139 LIBUTIL="-lutil"
11140
11141$as_echo "#define HAVE_GETRAWPARTITION 1" >>confdefs.h
11142
11143
11144fi
11145
11146
11147fi
11148
11149
11150
11151
11152{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wtrampolines work" >&5
11153$as_echo_n "checking whether -Wtrampolines work... " >&6; }
11154if ${grub_cv_host_cc_wtrampolines+:} false; then :
11155 $as_echo_n "(cached) " >&6
11156else
11157
11158 SAVED_CFLAGS="$CFLAGS"
11159 CFLAGS="$HOST_CFLAGS -Wtrampolines -Werror"
11160 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11161/* end confdefs.h. */
11162#include <stdarg.h>
11163int va_arg_func (int fixed, va_list args);
11164int
11165main (void)
11166{
11167
11168 ;
11169 return 0;
11170}
11171_ACEOF
11172if ac_fn_c_try_compile "$LINENO"; then :
11173 grub_cv_host_cc_wtrampolines=yes
11174else
11175 grub_cv_host_cc_wtrampolines=no
11176fi
11177rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11178 CFLAGS="$SAVED_CFLAGS"
11179
11180fi
11181{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_host_cc_wtrampolines" >&5
11182$as_echo "$grub_cv_host_cc_wtrampolines" >&6; }
11183
11184if test x"$grub_host_cv_cc_wtrampolines" = xyes ; then
11185 HOST_CFLAGS="$HOST_CFLAGS -Wtrampolines"
11186fi
11187
11188#
11189# Check for host and build compilers.
11190#
11191HOST_CC=$CC
11192for ac_prog in gcc egcs cc
11193do
11194 # Extract the first word of "$ac_prog", so it can be a program name with args.
11195set dummy $ac_prog; ac_word=$2
11196{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11197$as_echo_n "checking for $ac_word... " >&6; }
11198if ${ac_cv_prog_BUILD_CC+:} false; then :
11199 $as_echo_n "(cached) " >&6
11200else
11201 if test -n "$BUILD_CC"; then
11202 ac_cv_prog_BUILD_CC="$BUILD_CC" # Let the user override the test.
11203else
11204as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11205for as_dir in $PATH
11206do
11207 IFS=$as_save_IFS
11208 test -z "$as_dir" && as_dir=.
11209 for ac_exec_ext in '' $ac_executable_extensions; do
11210 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11211 ac_cv_prog_BUILD_CC="$ac_prog"
11212 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11213 break 2
11214 fi
11215done
11216 done
11217IFS=$as_save_IFS
11218
11219fi
11220fi
11221BUILD_CC=$ac_cv_prog_BUILD_CC
11222if test -n "$BUILD_CC"; then
11223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
11224$as_echo "$BUILD_CC" >&6; }
11225else
11226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11227$as_echo "no" >&6; }
11228fi
11229
11230
11231 test -n "$BUILD_CC" && break
11232done
11233
11234test -z "$BUILD_CC" && as_fn_error $? "none of gcc, egcs and cc is found. set BUILD_CC manually." "$LINENO" 5
11235BUILD_CPP="$BUILD_CC -E"
11236
11237case "$build_os" in
11238 haiku*) BUILD_LIBM= ;;
11239 *) BUILD_LIBM=-lm ;;
11240esac
11241
11242
11243case "$build_os" in
11244 cygwin*|mingw32*|mingw64*) BUILD_EXEEXT=.exe ;;
11245 *) BUILD_EXEEXT= ;;
11246esac
11247
11248
11249# For gnulib.
11250
11251
11252
11253
11254
11255 LIBC_FATAL_STDERR_=1
11256 export LIBC_FATAL_STDERR_
11257
11258ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
11259if test "x$ac_cv_type_size_t" = xyes; then :
11260
11261else
11262
11263cat >>confdefs.h <<_ACEOF
11264#define size_t unsigned int
11265_ACEOF
11266
11267fi
11268
11269# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
11270# for constant arguments. Useless!
11271{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
11272$as_echo_n "checking for working alloca.h... " >&6; }
11273if ${ac_cv_working_alloca_h+:} false; then :
11274 $as_echo_n "(cached) " >&6
11275else
11276 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11277/* end confdefs.h. */
11278#include <alloca.h>
11279int
11280main (void)
11281{
11282char *p = (char *) alloca (2 * sizeof (int));
11283 if (p) return 0;
11284 ;
11285 return 0;
11286}
11287_ACEOF
11288if ac_fn_c_try_link "$LINENO"; then :
11289 ac_cv_working_alloca_h=yes
11290else
11291 ac_cv_working_alloca_h=no
11292fi
11293rm -f core conftest.err conftest.$ac_objext \
11294 conftest$ac_exeext conftest.$ac_ext
11295fi
11296{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
11297$as_echo "$ac_cv_working_alloca_h" >&6; }
11298if test $ac_cv_working_alloca_h = yes; then
11299
11300$as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
11301
11302fi
11303
11304{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
11305$as_echo_n "checking for alloca... " >&6; }
11306if ${ac_cv_func_alloca_works+:} false; then :
11307 $as_echo_n "(cached) " >&6
11308else
11309 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11310/* end confdefs.h. */
11311#ifdef __GNUC__
11312# define alloca __builtin_alloca
11313#else
11314# ifdef _MSC_VER
11315# include <malloc.h>
11316# define alloca _alloca
11317# else
11318# ifdef HAVE_ALLOCA_H
11319# include <alloca.h>
11320# else
11321# ifdef _AIX
11322 #pragma alloca
11323# else
11324# ifndef alloca /* predefined by HP cc +Olibcalls */
11325void *alloca (size_t);
11326# endif
11327# endif
11328# endif
11329# endif
11330#endif
11331
11332int
11333main (void)
11334{
11335char *p = (char *) alloca (1);
11336 if (p) return 0;
11337 ;
11338 return 0;
11339}
11340_ACEOF
11341if ac_fn_c_try_link "$LINENO"; then :
11342 ac_cv_func_alloca_works=yes
11343else
11344 ac_cv_func_alloca_works=no
11345fi
11346rm -f core conftest.err conftest.$ac_objext \
11347 conftest$ac_exeext conftest.$ac_ext
11348fi
11349{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
11350$as_echo "$ac_cv_func_alloca_works" >&6; }
11351
11352if test $ac_cv_func_alloca_works = yes; then
11353
11354$as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
11355
11356else
11357 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
11358# that cause trouble. Some versions do not even contain alloca or
11359# contain a buggy version. If you still want to use their alloca,
11360# use ar to extract alloca.o from them instead of compiling alloca.c.
11361
11362
11363
11364
11365
11366ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
11367
11368$as_echo "#define C_ALLOCA 1" >>confdefs.h
11369
11370
11371{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
11372$as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
11373if ${ac_cv_os_cray+:} false; then :
11374 $as_echo_n "(cached) " >&6
11375else
11376 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11377/* end confdefs.h. */
11378#if defined CRAY && ! defined CRAY2
11379webecray
11380#else
11381wenotbecray
11382#endif
11383
11384_ACEOF
11385if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11386 $EGREP "webecray" >/dev/null 2>&1; then :
11387 ac_cv_os_cray=yes
11388else
11389 ac_cv_os_cray=no
11390fi
11391rm -f conftest*
11392
11393fi
11394{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
11395$as_echo "$ac_cv_os_cray" >&6; }
11396if test $ac_cv_os_cray = yes; then
11397 for ac_func in _getb67 GETB67 getb67; do
11398 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11399ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11400if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
11401
11402cat >>confdefs.h <<_ACEOF
11403#define CRAY_STACKSEG_END $ac_func
11404_ACEOF
11405
11406 break
11407fi
11408
11409 done
11410fi
11411
11412{ $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
11413$as_echo_n "checking stack direction for C alloca... " >&6; }
11414if ${ac_cv_c_stack_direction+:} false; then :
11415 $as_echo_n "(cached) " >&6
11416else
11417 if test "$cross_compiling" = yes; then :
11418 ac_cv_c_stack_direction=0
11419else
11420 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11421/* end confdefs.h. */
11422$ac_includes_default
11423int
11424find_stack_direction (int *addr, int depth)
11425{
11426 int dir, dummy = 0;
11427 if (! addr)
11428 addr = &dummy;
11429 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
11430 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
11431 return dir + dummy;
11432}
11433
11434int
11435main (int argc, char **argv)
11436{
11437 return find_stack_direction (0, argc + !argv + 20) < 0;
11438}
11439_ACEOF
11440if ac_fn_c_try_run "$LINENO"; then :
11441 ac_cv_c_stack_direction=1
11442else
11443 ac_cv_c_stack_direction=-1
11444fi
11445rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11446 conftest.$ac_objext conftest.beam conftest.$ac_ext
11447fi
11448
11449fi
11450{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
11451$as_echo "$ac_cv_c_stack_direction" >&6; }
11452cat >>confdefs.h <<_ACEOF
11453#define STACK_DIRECTION $ac_cv_c_stack_direction
11454_ACEOF
11455
11456
11457fi
11458
11459{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
11460$as_echo_n "checking for inline... " >&6; }
11461if ${ac_cv_c_inline+:} false; then :
11462 $as_echo_n "(cached) " >&6
11463else
11464 ac_cv_c_inline=no
11465for ac_kw in inline __inline__ __inline; do
11466 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11467/* end confdefs.h. */
11468#ifndef __cplusplus
11469typedef int foo_t;
11470static $ac_kw foo_t static_foo () {return 0; }
11471$ac_kw foo_t foo () {return 0; }
11472#endif
11473
11474_ACEOF
11475if ac_fn_c_try_compile "$LINENO"; then :
11476 ac_cv_c_inline=$ac_kw
11477fi
11478rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11479 test "$ac_cv_c_inline" != no && break
11480done
11481
11482fi
11483{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
11484$as_echo "$ac_cv_c_inline" >&6; }
11485
11486case $ac_cv_c_inline in
11487 inline | yes) ;;
11488 *)
11489 case $ac_cv_c_inline in
11490 no) ac_val=;;
11491 *) ac_val=$ac_cv_c_inline;;
11492 esac
11493 cat >>confdefs.h <<_ACEOF
11494#ifndef __cplusplus
11495#define inline $ac_val
11496#endif
11497_ACEOF
11498 ;;
11499esac
11500
11501{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
11502$as_echo_n "checking for C/C++ restrict keyword... " >&6; }
11503if ${ac_cv_c_restrict+:} false; then :
11504 $as_echo_n "(cached) " >&6
11505else
11506 ac_cv_c_restrict=no
11507 # The order here caters to the fact that C++ does not require restrict.
11508 for ac_kw in __restrict __restrict__ _Restrict restrict; do
11509 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11510/* end confdefs.h. */
11511typedef int * int_ptr;
11512 int foo (int_ptr $ac_kw ip) {
11513 return ip[0];
11514 }
11515int
11516main (void)
11517{
11518int s[1];
11519 int * $ac_kw t = s;
11520 t[0] = 0;
11521 return foo(t)
11522 ;
11523 return 0;
11524}
11525_ACEOF
11526if ac_fn_c_try_compile "$LINENO"; then :
11527 ac_cv_c_restrict=$ac_kw
11528fi
11529rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11530 test "$ac_cv_c_restrict" != no && break
11531 done
11532
11533fi
11534{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
11535$as_echo "$ac_cv_c_restrict" >&6; }
11536
11537 case $ac_cv_c_restrict in
11538 restrict) ;;
11539 no) $as_echo "#define restrict /**/" >>confdefs.h
11540 ;;
11541 *) cat >>confdefs.h <<_ACEOF
11542#define restrict $ac_cv_c_restrict
11543_ACEOF
11544 ;;
11545 esac
11546
11547ac_fn_c_check_decl "$LINENO" "clearerr_unlocked" "ac_cv_have_decl_clearerr_unlocked" "$ac_includes_default"
11548if test "x$ac_cv_have_decl_clearerr_unlocked" = xyes; then :
11549 ac_have_decl=1
11550else
11551 ac_have_decl=0
11552fi
11553
11554cat >>confdefs.h <<_ACEOF
11555#define HAVE_DECL_CLEARERR_UNLOCKED $ac_have_decl
11556_ACEOF
11557
11558ac_fn_c_check_decl "$LINENO" "feof_unlocked" "ac_cv_have_decl_feof_unlocked" "$ac_includes_default"
11559if test "x$ac_cv_have_decl_feof_unlocked" = xyes; then :
11560 ac_have_decl=1
11561else
11562 ac_have_decl=0
11563fi
11564
11565cat >>confdefs.h <<_ACEOF
11566#define HAVE_DECL_FEOF_UNLOCKED $ac_have_decl
11567_ACEOF
11568
11569ac_fn_c_check_decl "$LINENO" "ferror_unlocked" "ac_cv_have_decl_ferror_unlocked" "$ac_includes_default"
11570if test "x$ac_cv_have_decl_ferror_unlocked" = xyes; then :
11571 ac_have_decl=1
11572else
11573 ac_have_decl=0
11574fi
11575
11576cat >>confdefs.h <<_ACEOF
11577#define HAVE_DECL_FERROR_UNLOCKED $ac_have_decl
11578_ACEOF
11579
11580ac_fn_c_check_decl "$LINENO" "fflush_unlocked" "ac_cv_have_decl_fflush_unlocked" "$ac_includes_default"
11581if test "x$ac_cv_have_decl_fflush_unlocked" = xyes; then :
11582 ac_have_decl=1
11583else
11584 ac_have_decl=0
11585fi
11586
11587cat >>confdefs.h <<_ACEOF
11588#define HAVE_DECL_FFLUSH_UNLOCKED $ac_have_decl
11589_ACEOF
11590
11591ac_fn_c_check_decl "$LINENO" "fgets_unlocked" "ac_cv_have_decl_fgets_unlocked" "$ac_includes_default"
11592if test "x$ac_cv_have_decl_fgets_unlocked" = xyes; then :
11593 ac_have_decl=1
11594else
11595 ac_have_decl=0
11596fi
11597
11598cat >>confdefs.h <<_ACEOF
11599#define HAVE_DECL_FGETS_UNLOCKED $ac_have_decl
11600_ACEOF
11601
11602ac_fn_c_check_decl "$LINENO" "fputc_unlocked" "ac_cv_have_decl_fputc_unlocked" "$ac_includes_default"
11603if test "x$ac_cv_have_decl_fputc_unlocked" = xyes; then :
11604 ac_have_decl=1
11605else
11606 ac_have_decl=0
11607fi
11608
11609cat >>confdefs.h <<_ACEOF
11610#define HAVE_DECL_FPUTC_UNLOCKED $ac_have_decl
11611_ACEOF
11612
11613ac_fn_c_check_decl "$LINENO" "fputs_unlocked" "ac_cv_have_decl_fputs_unlocked" "$ac_includes_default"
11614if test "x$ac_cv_have_decl_fputs_unlocked" = xyes; then :
11615 ac_have_decl=1
11616else
11617 ac_have_decl=0
11618fi
11619
11620cat >>confdefs.h <<_ACEOF
11621#define HAVE_DECL_FPUTS_UNLOCKED $ac_have_decl
11622_ACEOF
11623
11624ac_fn_c_check_decl "$LINENO" "fread_unlocked" "ac_cv_have_decl_fread_unlocked" "$ac_includes_default"
11625if test "x$ac_cv_have_decl_fread_unlocked" = xyes; then :
11626 ac_have_decl=1
11627else
11628 ac_have_decl=0
11629fi
11630
11631cat >>confdefs.h <<_ACEOF
11632#define HAVE_DECL_FREAD_UNLOCKED $ac_have_decl
11633_ACEOF
11634
11635ac_fn_c_check_decl "$LINENO" "fwrite_unlocked" "ac_cv_have_decl_fwrite_unlocked" "$ac_includes_default"
11636if test "x$ac_cv_have_decl_fwrite_unlocked" = xyes; then :
11637 ac_have_decl=1
11638else
11639 ac_have_decl=0
11640fi
11641
11642cat >>confdefs.h <<_ACEOF
11643#define HAVE_DECL_FWRITE_UNLOCKED $ac_have_decl
11644_ACEOF
11645
11646ac_fn_c_check_decl "$LINENO" "getc_unlocked" "ac_cv_have_decl_getc_unlocked" "$ac_includes_default"
11647if test "x$ac_cv_have_decl_getc_unlocked" = xyes; then :
11648 ac_have_decl=1
11649else
11650 ac_have_decl=0
11651fi
11652
11653cat >>confdefs.h <<_ACEOF
11654#define HAVE_DECL_GETC_UNLOCKED $ac_have_decl
11655_ACEOF
11656
11657ac_fn_c_check_decl "$LINENO" "getchar_unlocked" "ac_cv_have_decl_getchar_unlocked" "$ac_includes_default"
11658if test "x$ac_cv_have_decl_getchar_unlocked" = xyes; then :
11659 ac_have_decl=1
11660else
11661 ac_have_decl=0
11662fi
11663
11664cat >>confdefs.h <<_ACEOF
11665#define HAVE_DECL_GETCHAR_UNLOCKED $ac_have_decl
11666_ACEOF
11667
11668ac_fn_c_check_decl "$LINENO" "putc_unlocked" "ac_cv_have_decl_putc_unlocked" "$ac_includes_default"
11669if test "x$ac_cv_have_decl_putc_unlocked" = xyes; then :
11670 ac_have_decl=1
11671else
11672 ac_have_decl=0
11673fi
11674
11675cat >>confdefs.h <<_ACEOF
11676#define HAVE_DECL_PUTC_UNLOCKED $ac_have_decl
11677_ACEOF
11678
11679ac_fn_c_check_decl "$LINENO" "putchar_unlocked" "ac_cv_have_decl_putchar_unlocked" "$ac_includes_default"
11680if test "x$ac_cv_have_decl_putchar_unlocked" = xyes; then :
11681 ac_have_decl=1
11682else
11683 ac_have_decl=0
11684fi
11685
11686cat >>confdefs.h <<_ACEOF
11687#define HAVE_DECL_PUTCHAR_UNLOCKED $ac_have_decl
11688_ACEOF
11689
11690
11691
11692
11693 for ac_func in $ac_func_list
11694do :
11695 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11696ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11697if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
11698 cat >>confdefs.h <<_ACEOF
11699#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11700_ACEOF
11701
11702fi
11703done
11704
11705
11706
11707
11708
11709
11710
11711
11712 for ac_header in $ac_header_list
11713do :
11714 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11715ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
11716"
11717if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
11718 cat >>confdefs.h <<_ACEOF
11719#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11720_ACEOF
11721
11722fi
11723
11724done
11725
11726
11727
11728
11729
11730
11731 XGETTEXT_EXTRA_OPTIONS=
11732
11733
11734 GNULIB_BTOWC=0;
11735 GNULIB_WCTOB=0;
11736 GNULIB_MBSINIT=0;
11737 GNULIB_MBRTOWC=0;
11738 GNULIB_MBRLEN=0;
11739 GNULIB_MBSRTOWCS=0;
11740 GNULIB_MBSNRTOWCS=0;
11741 GNULIB_WCRTOMB=0;
11742 GNULIB_WCSRTOMBS=0;
11743 GNULIB_WCSNRTOMBS=0;
11744 GNULIB_WCWIDTH=0;
11745 GNULIB_WMEMCHR=0;
11746 GNULIB_WMEMCMP=0;
11747 GNULIB_WMEMCPY=0;
11748 GNULIB_WMEMMOVE=0;
11749 GNULIB_WMEMSET=0;
11750 GNULIB_WCSLEN=0;
11751 GNULIB_WCSNLEN=0;
11752 GNULIB_WCSCPY=0;
11753 GNULIB_WCPCPY=0;
11754 GNULIB_WCSNCPY=0;
11755 GNULIB_WCPNCPY=0;
11756 GNULIB_WCSCAT=0;
11757 GNULIB_WCSNCAT=0;
11758 GNULIB_WCSCMP=0;
11759 GNULIB_WCSNCMP=0;
11760 GNULIB_WCSCASECMP=0;
11761 GNULIB_WCSNCASECMP=0;
11762 GNULIB_WCSCOLL=0;
11763 GNULIB_WCSXFRM=0;
11764 GNULIB_WCSDUP=0;
11765 GNULIB_WCSCHR=0;
11766 GNULIB_WCSRCHR=0;
11767 GNULIB_WCSCSPN=0;
11768 GNULIB_WCSSPN=0;
11769 GNULIB_WCSPBRK=0;
11770 GNULIB_WCSSTR=0;
11771 GNULIB_WCSTOK=0;
11772 GNULIB_WCSWIDTH=0;
11773 HAVE_BTOWC=1;
11774 HAVE_MBSINIT=1;
11775 HAVE_MBRTOWC=1;
11776 HAVE_MBRLEN=1;
11777 HAVE_MBSRTOWCS=1;
11778 HAVE_MBSNRTOWCS=1;
11779 HAVE_WCRTOMB=1;
11780 HAVE_WCSRTOMBS=1;
11781 HAVE_WCSNRTOMBS=1;
11782 HAVE_WMEMCHR=1;
11783 HAVE_WMEMCMP=1;
11784 HAVE_WMEMCPY=1;
11785 HAVE_WMEMMOVE=1;
11786 HAVE_WMEMSET=1;
11787 HAVE_WCSLEN=1;
11788 HAVE_WCSNLEN=1;
11789 HAVE_WCSCPY=1;
11790 HAVE_WCPCPY=1;
11791 HAVE_WCSNCPY=1;
11792 HAVE_WCPNCPY=1;
11793 HAVE_WCSCAT=1;
11794 HAVE_WCSNCAT=1;
11795 HAVE_WCSCMP=1;
11796 HAVE_WCSNCMP=1;
11797 HAVE_WCSCASECMP=1;
11798 HAVE_WCSNCASECMP=1;
11799 HAVE_WCSCOLL=1;
11800 HAVE_WCSXFRM=1;
11801 HAVE_WCSDUP=1;
11802 HAVE_WCSCHR=1;
11803 HAVE_WCSRCHR=1;
11804 HAVE_WCSCSPN=1;
11805 HAVE_WCSSPN=1;
11806 HAVE_WCSPBRK=1;
11807 HAVE_WCSSTR=1;
11808 HAVE_WCSTOK=1;
11809 HAVE_WCSWIDTH=1;
11810 HAVE_DECL_WCTOB=1;
11811 HAVE_DECL_WCWIDTH=1;
11812 REPLACE_MBSTATE_T=0;
11813 REPLACE_BTOWC=0;
11814 REPLACE_WCTOB=0;
11815 REPLACE_MBSINIT=0;
11816 REPLACE_MBRTOWC=0;
11817 REPLACE_MBRLEN=0;
11818 REPLACE_MBSRTOWCS=0;
11819 REPLACE_MBSNRTOWCS=0;
11820 REPLACE_WCRTOMB=0;
11821 REPLACE_WCSRTOMBS=0;
11822 REPLACE_WCSNRTOMBS=0;
11823 REPLACE_WCWIDTH=0;
11824 REPLACE_WCSWIDTH=0;
11825
11826
11827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <wchar.h> uses 'inline' correctly" >&5
11828$as_echo_n "checking whether <wchar.h> uses 'inline' correctly... " >&6; }
11829if ${gl_cv_header_wchar_h_correct_inline+:} false; then :
11830 $as_echo_n "(cached) " >&6
11831else
11832 gl_cv_header_wchar_h_correct_inline=yes
11833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11834/* end confdefs.h. */
11835
11836 #define wcstod renamed_wcstod
11837/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
11838 <wchar.h>.
11839 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
11840 included before <wchar.h>. */
11841#include <stddef.h>
11842#include <stdio.h>
11843#include <time.h>
11844#include <wchar.h>
11845extern int zero (void);
11846int main () { return zero(); }
11847
11848_ACEOF
11849 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
11850 (eval $ac_compile) 2>&5
11851 ac_status=$?
11852 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
11853 test $ac_status = 0; }; then
11854 mv conftest.$ac_objext conftest1.$ac_objext
11855 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11856/* end confdefs.h. */
11857
11858 #define wcstod renamed_wcstod
11859/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
11860 <wchar.h>.
11861 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
11862 included before <wchar.h>. */
11863#include <stddef.h>
11864#include <stdio.h>
11865#include <time.h>
11866#include <wchar.h>
11867int zero (void) { return 0; }
11868
11869_ACEOF
11870 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
11871 (eval $ac_compile) 2>&5
11872 ac_status=$?
11873 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
11874 test $ac_status = 0; }; then
11875 mv conftest.$ac_objext conftest2.$ac_objext
11876 if $CC -o conftest$ac_exeext $CFLAGS $LDFLAGS conftest1.$ac_objext conftest2.$ac_objext $LIBS >&5 2>&1; then
11877 :
11878 else
11879 gl_cv_header_wchar_h_correct_inline=no
11880 fi
11881 fi
11882 fi
11883 rm -f conftest1.$ac_objext conftest2.$ac_objext conftest$ac_exeext
11884
11885fi
11886{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_wchar_h_correct_inline" >&5
11887$as_echo "$gl_cv_header_wchar_h_correct_inline" >&6; }
11888 if test $gl_cv_header_wchar_h_correct_inline = no; then
11889 as_fn_error $? "<wchar.h> cannot be used with this compiler ($CC $CFLAGS $CPPFLAGS).
11890This is a known interoperability problem of glibc <= 2.5 with gcc >= 4.3 in
11891C99 mode. You have four options:
11892 - Add the flag -fgnu89-inline to CC and reconfigure, or
11893 - Fix your include files, using parts of
11894 <http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=b037a293a48718af30d706c2e18c929d0e69a621>, or
11895 - Use a gcc version older than 4.3, or
11896 - Don't use the flags -std=c99 or -std=gnu99.
11897Configuration aborted." "$LINENO" 5
11898 fi
11899
11900
11901
11902
11903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
11904$as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
11905if ${am_cv_langinfo_codeset+:} false; then :
11906 $as_echo_n "(cached) " >&6
11907else
11908 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11909/* end confdefs.h. */
11910#include <langinfo.h>
11911int
11912main (void)
11913{
11914char* cs = nl_langinfo(CODESET); return !cs;
11915 ;
11916 return 0;
11917}
11918_ACEOF
11919if ac_fn_c_try_link "$LINENO"; then :
11920 am_cv_langinfo_codeset=yes
11921else
11922 am_cv_langinfo_codeset=no
11923fi
11924rm -f core conftest.err conftest.$ac_objext \
11925 conftest$ac_exeext conftest.$ac_ext
11926
11927fi
11928{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
11929$as_echo "$am_cv_langinfo_codeset" >&6; }
11930 if test $am_cv_langinfo_codeset = yes; then
11931
11932$as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
11933
11934 fi
11935
11936
11937
11938
11939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
11940$as_echo_n "checking for a traditional french locale... " >&6; }
11941if ${gt_cv_locale_fr+:} false; then :
11942 $as_echo_n "(cached) " >&6
11943else
11944
11945 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11946/* end confdefs.h. */
11947
11948#include <locale.h>
11949#include <time.h>
11950#if HAVE_LANGINFO_CODESET
11951# include <langinfo.h>
11952#endif
11953#include <stdlib.h>
11954#include <string.h>
11955struct tm t;
11956char buf[16];
11957int main () {
11958 /* Check whether the given locale name is recognized by the system. */
11959#if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
11960 /* On native Windows, setlocale(category, "") looks at the system settings,
11961 not at the environment variables. Also, when an encoding suffix such
11962 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
11963 category of the locale to "C". */
11964 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
11965 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
11966 return 1;
11967#else
11968 if (setlocale (LC_ALL, "") == NULL) return 1;
11969#endif
11970 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
11971 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
11972 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
11973 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
11974 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
11975 some unit tests fail.
11976 On MirBSD 10, when an unsupported locale is specified, setlocale()
11977 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
11978#if HAVE_LANGINFO_CODESET
11979 {
11980 const char *cs = nl_langinfo (CODESET);
11981 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
11982 || strcmp (cs, "UTF-8") == 0)
11983 return 1;
11984 }
11985#endif
11986#ifdef __CYGWIN__
11987 /* On Cygwin, avoid locale names without encoding suffix, because the
11988 locale_charset() function relies on the encoding suffix. Note that
11989 LC_ALL is set on the command line. */
11990 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
11991#endif
11992 /* Check whether in the abbreviation of the second month, the second
11993 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
11994 one byte long. This excludes the UTF-8 encoding. */
11995 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
11996 if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
11997#if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
11998 /* Check whether the decimal separator is a comma.
11999 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
12000 are nl_langinfo(RADIXCHAR) are both ".". */
12001 if (localeconv () ->decimal_point[0] != ',') return 1;
12002#endif
12003 return 0;
12004}
12005
12006_ACEOF
12007 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
12008 (eval $ac_link) 2>&5
12009 ac_status=$?
12010 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
12011 test $ac_status = 0; } && test -s conftest$ac_exeext; then
12012 case "$host_os" in
12013 # Handle native Windows specially, because there setlocale() interprets
12014 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
12015 # "fr" or "fra" as "French" or "French_France.1252",
12016 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
12017 # "ja" as "Japanese" or "Japanese_Japan.932",
12018 # and similar.
12019 mingw*)
12020 # Test for the native Windows locale name.
12021 if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
12022 gt_cv_locale_fr=French_France.1252
12023 else
12024 # None found.
12025 gt_cv_locale_fr=none
12026 fi
12027 ;;
12028 *)
12029 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
12030 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
12031 # configure script would override the LC_ALL setting. Likewise for
12032 # LC_CTYPE, which is also set at the beginning of the configure script.
12033 # Test for the usual locale name.
12034 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
12035 gt_cv_locale_fr=fr_FR
12036 else
12037 # Test for the locale name with explicit encoding suffix.
12038 if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
12039 gt_cv_locale_fr=fr_FR.ISO-8859-1
12040 else
12041 # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
12042 if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
12043 gt_cv_locale_fr=fr_FR.ISO8859-1
12044 else
12045 # Test for the HP-UX locale name.
12046 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
12047 gt_cv_locale_fr=fr_FR.iso88591
12048 else
12049 # Test for the Solaris 7 locale name.
12050 if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
12051 gt_cv_locale_fr=fr
12052 else
12053 # None found.
12054 gt_cv_locale_fr=none
12055 fi
12056 fi
12057 fi
12058 fi
12059 fi
12060 ;;
12061 esac
12062 fi
12063 rm -fr conftest*
12064
12065fi
12066{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
12067$as_echo "$gt_cv_locale_fr" >&6; }
12068 LOCALE_FR=$gt_cv_locale_fr
12069
12070
12071
12072
12073 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether // is distinct from /" >&5
12074$as_echo_n "checking whether // is distinct from /... " >&6; }
12075if ${gl_cv_double_slash_root+:} false; then :
12076 $as_echo_n "(cached) " >&6
12077else
12078 if test x"$cross_compiling" = xyes ; then
12079 # When cross-compiling, there is no way to tell whether // is special
12080 # short of a list of hosts. However, the only known hosts to date
12081 # that have a distinct // are Apollo DomainOS (too old to port to),
12082 # Cygwin, and z/OS. If anyone knows of another system for which // has
12083 # special semantics and is distinct from /, please report it to
12084 # <bug-gnulib@gnu.org>.
12085 case $host in
12086 *-cygwin | i370-ibm-openedition)
12087 gl_cv_double_slash_root=yes ;;
12088 *)
12089 # Be optimistic and assume that / and // are the same when we
12090 # don't know.
12091 gl_cv_double_slash_root='unknown, assuming no' ;;
12092 esac
12093 else
12094 set x `ls -di / // 2>/dev/null`
12095 if test "$2" = "$4" && wc //dev/null >/dev/null 2>&1; then
12096 gl_cv_double_slash_root=no
12097 else
12098 gl_cv_double_slash_root=yes
12099 fi
12100 fi
12101fi
12102{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_double_slash_root" >&5
12103$as_echo "$gl_cv_double_slash_root" >&6; }
12104 if test "$gl_cv_double_slash_root" = yes; then
12105
12106$as_echo "#define DOUBLE_SLASH_IS_DISTINCT_ROOT 1" >>confdefs.h
12107
12108 fi
12109
12110
12111
12112 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
12113$as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
12114if ${gl_cv_have_include_next+:} false; then :
12115 $as_echo_n "(cached) " >&6
12116else
12117 rm -rf conftestd1a conftestd1b conftestd2
12118 mkdir conftestd1a conftestd1b conftestd2
12119 cat <<EOF > conftestd1a/conftest.h
12120#define DEFINED_IN_CONFTESTD1
12121#include_next <conftest.h>
12122#ifdef DEFINED_IN_CONFTESTD2
12123int foo;
12124#else
12125#error "include_next doesn't work"
12126#endif
12127EOF
12128 cat <<EOF > conftestd1b/conftest.h
12129#define DEFINED_IN_CONFTESTD1
12130#include <stdio.h>
12131#include_next <conftest.h>
12132#ifdef DEFINED_IN_CONFTESTD2
12133int foo;
12134#else
12135#error "include_next doesn't work"
12136#endif
12137EOF
12138 cat <<EOF > conftestd2/conftest.h
12139#ifndef DEFINED_IN_CONFTESTD1
12140#error "include_next test doesn't work"
12141#endif
12142#define DEFINED_IN_CONFTESTD2
12143EOF
12144 gl_save_CPPFLAGS="$CPPFLAGS"
12145 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
12146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12147/* end confdefs.h. */
12148#include <conftest.h>
12149_ACEOF
12150if ac_fn_c_try_compile "$LINENO"; then :
12151 gl_cv_have_include_next=yes
12152else
12153 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
12154 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12155/* end confdefs.h. */
12156#include <conftest.h>
12157_ACEOF
12158if ac_fn_c_try_compile "$LINENO"; then :
12159 gl_cv_have_include_next=buggy
12160else
12161 gl_cv_have_include_next=no
12162fi
12163rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12164
12165fi
12166rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12167 CPPFLAGS="$gl_save_CPPFLAGS"
12168 rm -rf conftestd1a conftestd1b conftestd2
12169
12170fi
12171{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
12172$as_echo "$gl_cv_have_include_next" >&6; }
12173 PRAGMA_SYSTEM_HEADER=
12174 if test $gl_cv_have_include_next = yes; then
12175 INCLUDE_NEXT=include_next
12176 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
12177 if test -n "$GCC"; then
12178 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
12179 fi
12180 else
12181 if test $gl_cv_have_include_next = buggy; then
12182 INCLUDE_NEXT=include
12183 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
12184 else
12185 INCLUDE_NEXT=include
12186 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
12187 fi
12188 fi
12189
12190
12191
12192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
12193$as_echo_n "checking whether system header files limit the line length... " >&6; }
12194if ${gl_cv_pragma_columns+:} false; then :
12195 $as_echo_n "(cached) " >&6
12196else
12197 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12198/* end confdefs.h. */
12199
12200#ifdef __TANDEM
12201choke me
12202#endif
12203
12204_ACEOF
12205if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12206 $EGREP "choke me" >/dev/null 2>&1; then :
12207 gl_cv_pragma_columns=yes
12208else
12209 gl_cv_pragma_columns=no
12210fi
12211rm -f conftest*
12212
12213
12214fi
12215{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
12216$as_echo "$gl_cv_pragma_columns" >&6; }
12217 if test $gl_cv_pragma_columns = yes; then
12218 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
12219 else
12220 PRAGMA_COLUMNS=
12221 fi
12222
12223
12224
12225
12226 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for complete errno.h" >&5
12227$as_echo_n "checking for complete errno.h... " >&6; }
12228if ${gl_cv_header_errno_h_complete+:} false; then :
12229 $as_echo_n "(cached) " >&6
12230else
12231
12232 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12233/* end confdefs.h. */
12234
12235#include <errno.h>
12236#if !defined ETXTBSY
12237booboo
12238#endif
12239#if !defined ENOMSG
12240booboo
12241#endif
12242#if !defined EIDRM
12243booboo
12244#endif
12245#if !defined ENOLINK
12246booboo
12247#endif
12248#if !defined EPROTO
12249booboo
12250#endif
12251#if !defined EMULTIHOP
12252booboo
12253#endif
12254#if !defined EBADMSG
12255booboo
12256#endif
12257#if !defined EOVERFLOW
12258booboo
12259#endif
12260#if !defined ENOTSUP
12261booboo
12262#endif
12263#if !defined ENETRESET
12264booboo
12265#endif
12266#if !defined ECONNABORTED
12267booboo
12268#endif
12269#if !defined ESTALE
12270booboo
12271#endif
12272#if !defined EDQUOT
12273booboo
12274#endif
12275#if !defined ECANCELED
12276booboo
12277#endif
12278#if !defined EOWNERDEAD
12279booboo
12280#endif
12281#if !defined ENOTRECOVERABLE
12282booboo
12283#endif
12284#if !defined EILSEQ
12285booboo
12286#endif
12287
12288_ACEOF
12289if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12290 $EGREP "booboo" >/dev/null 2>&1; then :
12291 gl_cv_header_errno_h_complete=no
12292else
12293 gl_cv_header_errno_h_complete=yes
12294fi
12295rm -f conftest*
12296
12297
12298fi
12299{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_complete" >&5
12300$as_echo "$gl_cv_header_errno_h_complete" >&6; }
12301 if test $gl_cv_header_errno_h_complete = yes; then
12302 ERRNO_H=''
12303 else
12304
12305
12306
12307
12308
12309
12310
12311
12312 if test $gl_cv_have_include_next = yes; then
12313 gl_cv_next_errno_h='<'errno.h'>'
12314 else
12315 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <errno.h>" >&5
12316$as_echo_n "checking absolute name of <errno.h>... " >&6; }
12317if ${gl_cv_next_errno_h+:} false; then :
12318 $as_echo_n "(cached) " >&6
12319else
12320
12321 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12322/* end confdefs.h. */
12323#include <errno.h>
12324
12325_ACEOF
12326 case "$host_os" in
12327 aix*) gl_absname_cpp="$ac_cpp -C" ;;
12328 *) gl_absname_cpp="$ac_cpp" ;;
12329 esac
12330
12331 case "$host_os" in
12332 mingw*)
12333 gl_dirsep_regex='[/\\]'
12334 ;;
12335 *)
12336 gl_dirsep_regex='\/'
12337 ;;
12338 esac
12339 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
12340
12341 gl_header_literal_regex=`echo 'errno.h' \
12342 | sed -e "$gl_make_literal_regex_sed"`
12343 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
12344 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
12345 s|^/[^/]|//&|
12346 p
12347 q
12348 }'
12349 gl_cv_next_errno_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
12350 sed -n "$gl_absolute_header_sed"`'"'
12351
12352
12353fi
12354{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_errno_h" >&5
12355$as_echo "$gl_cv_next_errno_h" >&6; }
12356 fi
12357 NEXT_ERRNO_H=$gl_cv_next_errno_h
12358
12359 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
12360 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
12361 gl_next_as_first_directive='<'errno.h'>'
12362 else
12363 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
12364 gl_next_as_first_directive=$gl_cv_next_errno_h
12365 fi
12366 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H=$gl_next_as_first_directive
12367
12368
12369
12370
12371 ERRNO_H='errno.h'
12372 fi
12373
12374 if test -n "$ERRNO_H"; then
12375 GL_GENERATE_ERRNO_H_TRUE=
12376 GL_GENERATE_ERRNO_H_FALSE='#'
12377else
12378 GL_GENERATE_ERRNO_H_TRUE='#'
12379 GL_GENERATE_ERRNO_H_FALSE=
12380fi
12381
12382
12383 if test -n "$ERRNO_H"; then
12384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EMULTIHOP value" >&5
12385$as_echo_n "checking for EMULTIHOP value... " >&6; }
12386if ${gl_cv_header_errno_h_EMULTIHOP+:} false; then :
12387 $as_echo_n "(cached) " >&6
12388else
12389
12390 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12391/* end confdefs.h. */
12392
12393#include <errno.h>
12394#ifdef EMULTIHOP
12395yes
12396#endif
12397
12398_ACEOF
12399if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12400 $EGREP "yes" >/dev/null 2>&1; then :
12401 gl_cv_header_errno_h_EMULTIHOP=yes
12402else
12403 gl_cv_header_errno_h_EMULTIHOP=no
12404fi
12405rm -f conftest*
12406
12407 if test $gl_cv_header_errno_h_EMULTIHOP = no; then
12408 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12409/* end confdefs.h. */
12410
12411#define _XOPEN_SOURCE_EXTENDED 1
12412#include <errno.h>
12413#ifdef EMULTIHOP
12414yes
12415#endif
12416
12417_ACEOF
12418if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12419 $EGREP "yes" >/dev/null 2>&1; then :
12420 gl_cv_header_errno_h_EMULTIHOP=hidden
12421fi
12422rm -f conftest*
12423
12424 if test $gl_cv_header_errno_h_EMULTIHOP = hidden; then
12425 if ac_fn_c_compute_int "$LINENO" "EMULTIHOP" "gl_cv_header_errno_h_EMULTIHOP" "
12426#define _XOPEN_SOURCE_EXTENDED 1
12427#include <errno.h>
12428/* The following two lines are a workaround against an autoconf-2.52 bug. */
12429#include <stdio.h>
12430#include <stdlib.h>
12431"; then :
12432
12433fi
12434
12435 fi
12436 fi
12437
12438fi
12439{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EMULTIHOP" >&5
12440$as_echo "$gl_cv_header_errno_h_EMULTIHOP" >&6; }
12441 case $gl_cv_header_errno_h_EMULTIHOP in
12442 yes | no)
12443 EMULTIHOP_HIDDEN=0; EMULTIHOP_VALUE=
12444 ;;
12445 *)
12446 EMULTIHOP_HIDDEN=1; EMULTIHOP_VALUE="$gl_cv_header_errno_h_EMULTIHOP"
12447 ;;
12448 esac
12449
12450
12451 fi
12452
12453
12454 if test -n "$ERRNO_H"; then
12455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ENOLINK value" >&5
12456$as_echo_n "checking for ENOLINK value... " >&6; }
12457if ${gl_cv_header_errno_h_ENOLINK+:} false; then :
12458 $as_echo_n "(cached) " >&6
12459else
12460
12461 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12462/* end confdefs.h. */
12463
12464#include <errno.h>
12465#ifdef ENOLINK
12466yes
12467#endif
12468
12469_ACEOF
12470if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12471 $EGREP "yes" >/dev/null 2>&1; then :
12472 gl_cv_header_errno_h_ENOLINK=yes
12473else
12474 gl_cv_header_errno_h_ENOLINK=no
12475fi
12476rm -f conftest*
12477
12478 if test $gl_cv_header_errno_h_ENOLINK = no; then
12479 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12480/* end confdefs.h. */
12481
12482#define _XOPEN_SOURCE_EXTENDED 1
12483#include <errno.h>
12484#ifdef ENOLINK
12485yes
12486#endif
12487
12488_ACEOF
12489if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12490 $EGREP "yes" >/dev/null 2>&1; then :
12491 gl_cv_header_errno_h_ENOLINK=hidden
12492fi
12493rm -f conftest*
12494
12495 if test $gl_cv_header_errno_h_ENOLINK = hidden; then
12496 if ac_fn_c_compute_int "$LINENO" "ENOLINK" "gl_cv_header_errno_h_ENOLINK" "
12497#define _XOPEN_SOURCE_EXTENDED 1
12498#include <errno.h>
12499/* The following two lines are a workaround against an autoconf-2.52 bug. */
12500#include <stdio.h>
12501#include <stdlib.h>
12502"; then :
12503
12504fi
12505
12506 fi
12507 fi
12508
12509fi
12510{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_ENOLINK" >&5
12511$as_echo "$gl_cv_header_errno_h_ENOLINK" >&6; }
12512 case $gl_cv_header_errno_h_ENOLINK in
12513 yes | no)
12514 ENOLINK_HIDDEN=0; ENOLINK_VALUE=
12515 ;;
12516 *)
12517 ENOLINK_HIDDEN=1; ENOLINK_VALUE="$gl_cv_header_errno_h_ENOLINK"
12518 ;;
12519 esac
12520
12521
12522 fi
12523
12524
12525 if test -n "$ERRNO_H"; then
12526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EOVERFLOW value" >&5
12527$as_echo_n "checking for EOVERFLOW value... " >&6; }
12528if ${gl_cv_header_errno_h_EOVERFLOW+:} false; then :
12529 $as_echo_n "(cached) " >&6
12530else
12531
12532 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12533/* end confdefs.h. */
12534
12535#include <errno.h>
12536#ifdef EOVERFLOW
12537yes
12538#endif
12539
12540_ACEOF
12541if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12542 $EGREP "yes" >/dev/null 2>&1; then :
12543 gl_cv_header_errno_h_EOVERFLOW=yes
12544else
12545 gl_cv_header_errno_h_EOVERFLOW=no
12546fi
12547rm -f conftest*
12548
12549 if test $gl_cv_header_errno_h_EOVERFLOW = no; then
12550 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12551/* end confdefs.h. */
12552
12553#define _XOPEN_SOURCE_EXTENDED 1
12554#include <errno.h>
12555#ifdef EOVERFLOW
12556yes
12557#endif
12558
12559_ACEOF
12560if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12561 $EGREP "yes" >/dev/null 2>&1; then :
12562 gl_cv_header_errno_h_EOVERFLOW=hidden
12563fi
12564rm -f conftest*
12565
12566 if test $gl_cv_header_errno_h_EOVERFLOW = hidden; then
12567 if ac_fn_c_compute_int "$LINENO" "EOVERFLOW" "gl_cv_header_errno_h_EOVERFLOW" "
12568#define _XOPEN_SOURCE_EXTENDED 1
12569#include <errno.h>
12570/* The following two lines are a workaround against an autoconf-2.52 bug. */
12571#include <stdio.h>
12572#include <stdlib.h>
12573"; then :
12574
12575fi
12576
12577 fi
12578 fi
12579
12580fi
12581{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EOVERFLOW" >&5
12582$as_echo "$gl_cv_header_errno_h_EOVERFLOW" >&6; }
12583 case $gl_cv_header_errno_h_EOVERFLOW in
12584 yes | no)
12585 EOVERFLOW_HIDDEN=0; EOVERFLOW_VALUE=
12586 ;;
12587 *)
12588 EOVERFLOW_HIDDEN=1; EOVERFLOW_VALUE="$gl_cv_header_errno_h_EOVERFLOW"
12589 ;;
12590 esac
12591
12592
12593 fi
12594
12595
12596ac_fn_c_check_decl "$LINENO" "strerror_r" "ac_cv_have_decl_strerror_r" "$ac_includes_default"
12597if test "x$ac_cv_have_decl_strerror_r" = xyes; then :
12598 ac_have_decl=1
12599else
12600 ac_have_decl=0
12601fi
12602
12603cat >>confdefs.h <<_ACEOF
12604#define HAVE_DECL_STRERROR_R $ac_have_decl
12605_ACEOF
12606
12607for ac_func in strerror_r
12608do :
12609 ac_fn_c_check_func "$LINENO" "strerror_r" "ac_cv_func_strerror_r"
12610if test "x$ac_cv_func_strerror_r" = xyes; then :
12611 cat >>confdefs.h <<_ACEOF
12612#define HAVE_STRERROR_R 1
12613_ACEOF
12614
12615fi
12616done
12617
12618{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror_r returns char *" >&5
12619$as_echo_n "checking whether strerror_r returns char *... " >&6; }
12620if ${ac_cv_func_strerror_r_char_p+:} false; then :
12621 $as_echo_n "(cached) " >&6
12622else
12623
12624 ac_cv_func_strerror_r_char_p=no
12625 if test $ac_cv_have_decl_strerror_r = yes; then
12626 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12627/* end confdefs.h. */
12628$ac_includes_default
12629int
12630main (void)
12631{
12632
12633 char buf[100];
12634 char x = *strerror_r (0, buf, sizeof buf);
12635 char *p = strerror_r (0, buf, sizeof buf);
12636 return !p || x;
12637
12638 ;
12639 return 0;
12640}
12641_ACEOF
12642if ac_fn_c_try_compile "$LINENO"; then :
12643 ac_cv_func_strerror_r_char_p=yes
12644fi
12645rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12646 else
12647 # strerror_r is not declared. Choose between
12648 # systems that have relatively inaccessible declarations for the
12649 # function. BeOS and DEC UNIX 4.0 fall in this category, but the
12650 # former has a strerror_r that returns char*, while the latter
12651 # has a strerror_r that returns `int'.
12652 # This test should segfault on the DEC system.
12653 if test "$cross_compiling" = yes; then :
12654 :
12655else
12656 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12657/* end confdefs.h. */
12658$ac_includes_default
12659 extern char *strerror_r ();
12660int
12661main (void)
12662{
12663char buf[100];
12664 char x = *strerror_r (0, buf, sizeof buf);
12665 return ! isalpha (x);
12666 ;
12667 return 0;
12668}
12669_ACEOF
12670if ac_fn_c_try_run "$LINENO"; then :
12671 ac_cv_func_strerror_r_char_p=yes
12672fi
12673rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12674 conftest.$ac_objext conftest.beam conftest.$ac_ext
12675fi
12676
12677 fi
12678
12679fi
12680{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strerror_r_char_p" >&5
12681$as_echo "$ac_cv_func_strerror_r_char_p" >&6; }
12682if test $ac_cv_func_strerror_r_char_p = yes; then
12683
12684$as_echo "#define STRERROR_R_CHAR_P 1" >>confdefs.h
12685
12686fi
12687
12688
12689
12690
12691
12692
12693 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
12694$as_echo_n "checking for mbstate_t... " >&6; }
12695if ${ac_cv_type_mbstate_t+:} false; then :
12696 $as_echo_n "(cached) " >&6
12697else
12698 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12699/* end confdefs.h. */
12700$ac_includes_default
12701/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
12702 <wchar.h>.
12703 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
12704 included before <wchar.h>. */
12705#include <stddef.h>
12706#include <stdio.h>
12707#include <time.h>
12708#include <wchar.h>
12709int
12710main (void)
12711{
12712mbstate_t x; return sizeof x;
12713 ;
12714 return 0;
12715}
12716_ACEOF
12717if ac_fn_c_try_compile "$LINENO"; then :
12718 ac_cv_type_mbstate_t=yes
12719else
12720 ac_cv_type_mbstate_t=no
12721fi
12722rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12723fi
12724{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
12725$as_echo "$ac_cv_type_mbstate_t" >&6; }
12726 if test $ac_cv_type_mbstate_t = yes; then
12727
12728$as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
12729
12730 else
12731
12732$as_echo "#define mbstate_t int" >>confdefs.h
12733
12734 fi
12735
12736
12737
12738
12739
12740
12741
12742
12743
12744
12745
12746
12747
12748
12749
12750
12751
12752
12753 GNULIB_DPRINTF=0;
12754 GNULIB_FCLOSE=0;
12755 GNULIB_FDOPEN=0;
12756 GNULIB_FFLUSH=0;
12757 GNULIB_FGETC=0;
12758 GNULIB_FGETS=0;
12759 GNULIB_FOPEN=0;
12760 GNULIB_FPRINTF=0;
12761 GNULIB_FPRINTF_POSIX=0;
12762 GNULIB_FPURGE=0;
12763 GNULIB_FPUTC=0;
12764 GNULIB_FPUTS=0;
12765 GNULIB_FREAD=0;
12766 GNULIB_FREOPEN=0;
12767 GNULIB_FSCANF=0;
12768 GNULIB_FSEEK=0;
12769 GNULIB_FSEEKO=0;
12770 GNULIB_FTELL=0;
12771 GNULIB_FTELLO=0;
12772 GNULIB_FWRITE=0;
12773 GNULIB_GETC=0;
12774 GNULIB_GETCHAR=0;
12775 GNULIB_GETDELIM=0;
12776 GNULIB_GETLINE=0;
12777 GNULIB_OBSTACK_PRINTF=0;
12778 GNULIB_OBSTACK_PRINTF_POSIX=0;
12779 GNULIB_PCLOSE=0;
12780 GNULIB_PERROR=0;
12781 GNULIB_POPEN=0;
12782 GNULIB_PRINTF=0;
12783 GNULIB_PRINTF_POSIX=0;
12784 GNULIB_PUTC=0;
12785 GNULIB_PUTCHAR=0;
12786 GNULIB_PUTS=0;
12787 GNULIB_REMOVE=0;
12788 GNULIB_RENAME=0;
12789 GNULIB_RENAMEAT=0;
12790 GNULIB_SCANF=0;
12791 GNULIB_SNPRINTF=0;
12792 GNULIB_SPRINTF_POSIX=0;
12793 GNULIB_STDIO_H_NONBLOCKING=0;
12794 GNULIB_STDIO_H_SIGPIPE=0;
12795 GNULIB_TMPFILE=0;
12796 GNULIB_VASPRINTF=0;
12797 GNULIB_VFSCANF=0;
12798 GNULIB_VSCANF=0;
12799 GNULIB_VDPRINTF=0;
12800 GNULIB_VFPRINTF=0;
12801 GNULIB_VFPRINTF_POSIX=0;
12802 GNULIB_VPRINTF=0;
12803 GNULIB_VPRINTF_POSIX=0;
12804 GNULIB_VSNPRINTF=0;
12805 GNULIB_VSPRINTF_POSIX=0;
12806 HAVE_DECL_FPURGE=1;
12807 HAVE_DECL_FSEEKO=1;
12808 HAVE_DECL_FTELLO=1;
12809 HAVE_DECL_GETDELIM=1;
12810 HAVE_DECL_GETLINE=1;
12811 HAVE_DECL_OBSTACK_PRINTF=1;
12812 HAVE_DECL_SNPRINTF=1;
12813 HAVE_DECL_VSNPRINTF=1;
12814 HAVE_DPRINTF=1;
12815 HAVE_FSEEKO=1;
12816 HAVE_FTELLO=1;
12817 HAVE_PCLOSE=1;
12818 HAVE_POPEN=1;
12819 HAVE_RENAMEAT=1;
12820 HAVE_VASPRINTF=1;
12821 HAVE_VDPRINTF=1;
12822 REPLACE_DPRINTF=0;
12823 REPLACE_FCLOSE=0;
12824 REPLACE_FDOPEN=0;
12825 REPLACE_FFLUSH=0;
12826 REPLACE_FOPEN=0;
12827 REPLACE_FPRINTF=0;
12828 REPLACE_FPURGE=0;
12829 REPLACE_FREOPEN=0;
12830 REPLACE_FSEEK=0;
12831 REPLACE_FSEEKO=0;
12832 REPLACE_FTELL=0;
12833 REPLACE_FTELLO=0;
12834 REPLACE_GETDELIM=0;
12835 REPLACE_GETLINE=0;
12836 REPLACE_OBSTACK_PRINTF=0;
12837 REPLACE_PERROR=0;
12838 REPLACE_POPEN=0;
12839 REPLACE_PRINTF=0;
12840 REPLACE_REMOVE=0;
12841 REPLACE_RENAME=0;
12842 REPLACE_RENAMEAT=0;
12843 REPLACE_SNPRINTF=0;
12844 REPLACE_SPRINTF=0;
12845 REPLACE_STDIO_READ_FUNCS=0;
12846 REPLACE_STDIO_WRITE_FUNCS=0;
12847 REPLACE_TMPFILE=0;
12848 REPLACE_VASPRINTF=0;
12849 REPLACE_VDPRINTF=0;
12850 REPLACE_VFPRINTF=0;
12851 REPLACE_VPRINTF=0;
12852 REPLACE_VSNPRINTF=0;
12853 REPLACE_VSPRINTF=0;
12854
12855ac_fn_c_check_decl "$LINENO" "getdelim" "ac_cv_have_decl_getdelim" "$ac_includes_default"
12856if test "x$ac_cv_have_decl_getdelim" = xyes; then :
12857 ac_have_decl=1
12858else
12859 ac_have_decl=0
12860fi
12861
12862cat >>confdefs.h <<_ACEOF
12863#define HAVE_DECL_GETDELIM $ac_have_decl
12864_ACEOF
12865
12866
12867
12868ac_fn_c_check_decl "$LINENO" "getline" "ac_cv_have_decl_getline" "$ac_includes_default"
12869if test "x$ac_cv_have_decl_getline" = xyes; then :
12870 ac_have_decl=1
12871else
12872 ac_have_decl=0
12873fi
12874
12875cat >>confdefs.h <<_ACEOF
12876#define HAVE_DECL_GETLINE $ac_have_decl
12877_ACEOF
12878
12879
12880 GNULIB_CHDIR=0;
12881 GNULIB_CHOWN=0;
12882 GNULIB_CLOSE=0;
12883 GNULIB_DUP=0;
12884 GNULIB_DUP2=0;
12885 GNULIB_DUP3=0;
12886 GNULIB_ENVIRON=0;
12887 GNULIB_EUIDACCESS=0;
12888 GNULIB_FACCESSAT=0;
12889 GNULIB_FCHDIR=0;
12890 GNULIB_FCHOWNAT=0;
12891 GNULIB_FDATASYNC=0;
12892 GNULIB_FSYNC=0;
12893 GNULIB_FTRUNCATE=0;
12894 GNULIB_GETCWD=0;
12895 GNULIB_GETDOMAINNAME=0;
12896 GNULIB_GETDTABLESIZE=0;
12897 GNULIB_GETGROUPS=0;
12898 GNULIB_GETHOSTNAME=0;
12899 GNULIB_GETLOGIN=0;
12900 GNULIB_GETLOGIN_R=0;
12901 GNULIB_GETPAGESIZE=0;
12902 GNULIB_GETUSERSHELL=0;
12903 GNULIB_GROUP_MEMBER=0;
12904 GNULIB_ISATTY=0;
12905 GNULIB_LCHOWN=0;
12906 GNULIB_LINK=0;
12907 GNULIB_LINKAT=0;
12908 GNULIB_LSEEK=0;
12909 GNULIB_PIPE=0;
12910 GNULIB_PIPE2=0;
12911 GNULIB_PREAD=0;
12912 GNULIB_PWRITE=0;
12913 GNULIB_READ=0;
12914 GNULIB_READLINK=0;
12915 GNULIB_READLINKAT=0;
12916 GNULIB_RMDIR=0;
12917 GNULIB_SETHOSTNAME=0;
12918 GNULIB_SLEEP=0;
12919 GNULIB_SYMLINK=0;
12920 GNULIB_SYMLINKAT=0;
12921 GNULIB_TTYNAME_R=0;
12922 GNULIB_UNISTD_H_NONBLOCKING=0;
12923 GNULIB_UNISTD_H_SIGPIPE=0;
12924 GNULIB_UNLINK=0;
12925 GNULIB_UNLINKAT=0;
12926 GNULIB_USLEEP=0;
12927 GNULIB_WRITE=0;
12928 HAVE_CHOWN=1;
12929 HAVE_DUP2=1;
12930 HAVE_DUP3=1;
12931 HAVE_EUIDACCESS=1;
12932 HAVE_FACCESSAT=1;
12933 HAVE_FCHDIR=1;
12934 HAVE_FCHOWNAT=1;
12935 HAVE_FDATASYNC=1;
12936 HAVE_FSYNC=1;
12937 HAVE_FTRUNCATE=1;
12938 HAVE_GETDTABLESIZE=1;
12939 HAVE_GETGROUPS=1;
12940 HAVE_GETHOSTNAME=1;
12941 HAVE_GETLOGIN=1;
12942 HAVE_GETPAGESIZE=1;
12943 HAVE_GROUP_MEMBER=1;
12944 HAVE_LCHOWN=1;
12945 HAVE_LINK=1;
12946 HAVE_LINKAT=1;
12947 HAVE_PIPE=1;
12948 HAVE_PIPE2=1;
12949 HAVE_PREAD=1;
12950 HAVE_PWRITE=1;
12951 HAVE_READLINK=1;
12952 HAVE_READLINKAT=1;
12953 HAVE_SETHOSTNAME=1;
12954 HAVE_SLEEP=1;
12955 HAVE_SYMLINK=1;
12956 HAVE_SYMLINKAT=1;
12957 HAVE_UNLINKAT=1;
12958 HAVE_USLEEP=1;
12959 HAVE_DECL_ENVIRON=1;
12960 HAVE_DECL_FCHDIR=1;
12961 HAVE_DECL_FDATASYNC=1;
12962 HAVE_DECL_GETDOMAINNAME=1;
12963 HAVE_DECL_GETLOGIN_R=1;
12964 HAVE_DECL_GETPAGESIZE=1;
12965 HAVE_DECL_GETUSERSHELL=1;
12966 HAVE_DECL_SETHOSTNAME=1;
12967 HAVE_DECL_TTYNAME_R=1;
12968 HAVE_OS_H=0;
12969 HAVE_SYS_PARAM_H=0;
12970 REPLACE_CHOWN=0;
12971 REPLACE_CLOSE=0;
12972 REPLACE_DUP=0;
12973 REPLACE_DUP2=0;
12974 REPLACE_FCHOWNAT=0;
12975 REPLACE_FTRUNCATE=0;
12976 REPLACE_GETCWD=0;
12977 REPLACE_GETDOMAINNAME=0;
12978 REPLACE_GETLOGIN_R=0;
12979 REPLACE_GETGROUPS=0;
12980 REPLACE_GETPAGESIZE=0;
12981 REPLACE_ISATTY=0;
12982 REPLACE_LCHOWN=0;
12983 REPLACE_LINK=0;
12984 REPLACE_LINKAT=0;
12985 REPLACE_LSEEK=0;
12986 REPLACE_PREAD=0;
12987 REPLACE_PWRITE=0;
12988 REPLACE_READ=0;
12989 REPLACE_READLINK=0;
12990 REPLACE_RMDIR=0;
12991 REPLACE_SLEEP=0;
12992 REPLACE_SYMLINK=0;
12993 REPLACE_TTYNAME_R=0;
12994 REPLACE_UNLINK=0;
12995 REPLACE_UNLINKAT=0;
12996 REPLACE_USLEEP=0;
12997 REPLACE_WRITE=0;
12998 UNISTD_H_HAVE_WINSOCK2_H=0;
12999 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
13000
13001
13002
13003
13004
13005
13006
13007
13008
13009
13010
13011
13012
13013
13014
13015
13016
13017 if test $gl_cv_have_include_next = yes; then
13018 gl_cv_next_getopt_h='<'getopt.h'>'
13019 else
13020 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
13021$as_echo_n "checking absolute name of <getopt.h>... " >&6; }
13022if ${gl_cv_next_getopt_h+:} false; then :
13023 $as_echo_n "(cached) " >&6
13024else
13025
13026 if test $ac_cv_header_getopt_h = yes; then
13027
13028
13029 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13030/* end confdefs.h. */
13031#include <getopt.h>
13032
13033_ACEOF
13034 case "$host_os" in
13035 aix*) gl_absname_cpp="$ac_cpp -C" ;;
13036 *) gl_absname_cpp="$ac_cpp" ;;
13037 esac
13038
13039 case "$host_os" in
13040 mingw*)
13041 gl_dirsep_regex='[/\\]'
13042 ;;
13043 *)
13044 gl_dirsep_regex='\/'
13045 ;;
13046 esac
13047 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
13048
13049 gl_header_literal_regex=`echo 'getopt.h' \
13050 | sed -e "$gl_make_literal_regex_sed"`
13051 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
13052 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
13053 s|^/[^/]|//&|
13054 p
13055 q
13056 }'
13057 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
13058 sed -n "$gl_absolute_header_sed"`'"'
13059 else
13060 gl_cv_next_getopt_h='<'getopt.h'>'
13061 fi
13062
13063
13064fi
13065{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
13066$as_echo "$gl_cv_next_getopt_h" >&6; }
13067 fi
13068 NEXT_GETOPT_H=$gl_cv_next_getopt_h
13069
13070 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
13071 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
13072 gl_next_as_first_directive='<'getopt.h'>'
13073 else
13074 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
13075 gl_next_as_first_directive=$gl_cv_next_getopt_h
13076 fi
13077 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
13078
13079
13080
13081
13082 if test $ac_cv_header_getopt_h = yes; then
13083 HAVE_GETOPT_H=1
13084 else
13085 HAVE_GETOPT_H=0
13086 fi
13087
13088
13089 gl_replace_getopt=
13090
13091 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
13092 for ac_header in getopt.h
13093do :
13094 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
13095if test "x$ac_cv_header_getopt_h" = xyes; then :
13096 cat >>confdefs.h <<_ACEOF
13097#define HAVE_GETOPT_H 1
13098_ACEOF
13099
13100else
13101 gl_replace_getopt=yes
13102fi
13103
13104done
13105
13106 fi
13107
13108 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
13109 for ac_func in getopt_long_only
13110do :
13111 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
13112if test "x$ac_cv_func_getopt_long_only" = xyes; then :
13113 cat >>confdefs.h <<_ACEOF
13114#define HAVE_GETOPT_LONG_ONLY 1
13115_ACEOF
13116
13117else
13118 gl_replace_getopt=yes
13119fi
13120done
13121
13122 fi
13123
13124 if test -z "$gl_replace_getopt"; then
13125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
13126$as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
13127if ${gl_cv_func_getopt_posix+:} false; then :
13128 $as_echo_n "(cached) " >&6
13129else
13130
13131 if test $cross_compiling = no; then
13132 if test "$cross_compiling" = yes; then :
13133 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
13134$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
13135as_fn_error $? "cannot run test program while cross compiling
13136See \`config.log' for more details" "$LINENO" 5; }
13137else
13138 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13139/* end confdefs.h. */
13140
13141#include <unistd.h>
13142#include <stdlib.h>
13143#include <string.h>
13144
13145int
13146main ()
13147{
13148 static char program[] = "program";
13149 static char a[] = "-a";
13150 static char foo[] = "foo";
13151 static char bar[] = "bar";
13152 char *argv[] = { program, a, foo, bar, NULL };
13153 int c;
13154
13155 c = getopt (4, argv, "ab");
13156 if (!(c == 'a'))
13157 return 1;
13158 c = getopt (4, argv, "ab");
13159 if (!(c == -1))
13160 return 2;
13161 if (!(optind == 2))
13162 return 3;
13163 return 0;
13164}
13165
13166_ACEOF
13167if ac_fn_c_try_run "$LINENO"; then :
13168 gl_cv_func_getopt_posix=maybe
13169else
13170 gl_cv_func_getopt_posix=no
13171fi
13172rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13173 conftest.$ac_objext conftest.beam conftest.$ac_ext
13174fi
13175
13176 if test $gl_cv_func_getopt_posix = maybe; then
13177 if test "$cross_compiling" = yes; then :
13178 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
13179$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
13180as_fn_error $? "cannot run test program while cross compiling
13181See \`config.log' for more details" "$LINENO" 5; }
13182else
13183 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13184/* end confdefs.h. */
13185
13186#include <unistd.h>
13187#include <stdlib.h>
13188#include <string.h>
13189
13190int
13191main ()
13192{
13193 static char program[] = "program";
13194 static char donald[] = "donald";
13195 static char p[] = "-p";
13196 static char billy[] = "billy";
13197 static char duck[] = "duck";
13198 static char a[] = "-a";
13199 static char bar[] = "bar";
13200 char *argv[] = { program, donald, p, billy, duck, a, bar, NULL };
13201 int c;
13202
13203 c = getopt (7, argv, "+abp:q:");
13204 if (!(c == -1))
13205 return 4;
13206 if (!(strcmp (argv[0], "program") == 0))
13207 return 5;
13208 if (!(strcmp (argv[1], "donald") == 0))
13209 return 6;
13210 if (!(strcmp (argv[2], "-p") == 0))
13211 return 7;
13212 if (!(strcmp (argv[3], "billy") == 0))
13213 return 8;
13214 if (!(strcmp (argv[4], "duck") == 0))
13215 return 9;
13216 if (!(strcmp (argv[5], "-a") == 0))
13217 return 10;
13218 if (!(strcmp (argv[6], "bar") == 0))
13219 return 11;
13220 if (!(optind == 1))
13221 return 12;
13222 return 0;
13223}
13224
13225_ACEOF
13226if ac_fn_c_try_run "$LINENO"; then :
13227 gl_cv_func_getopt_posix=maybe
13228else
13229 gl_cv_func_getopt_posix=no
13230fi
13231rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13232 conftest.$ac_objext conftest.beam conftest.$ac_ext
13233fi
13234
13235 fi
13236 if test $gl_cv_func_getopt_posix = maybe; then
13237 if test "$cross_compiling" = yes; then :
13238 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
13239$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
13240as_fn_error $? "cannot run test program while cross compiling
13241See \`config.log' for more details" "$LINENO" 5; }
13242else
13243 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13244/* end confdefs.h. */
13245
13246#include <unistd.h>
13247#include <stdlib.h>
13248#include <string.h>
13249
13250int
13251main ()
13252{
13253 static char program[] = "program";
13254 static char ab[] = "-ab";
13255 char *argv[3] = { program, ab, NULL };
13256 if (getopt (2, argv, "ab:") != 'a')
13257 return 13;
13258 if (getopt (2, argv, "ab:") != '?')
13259 return 14;
13260 if (optopt != 'b')
13261 return 15;
13262 if (optind != 2)
13263 return 16;
13264 return 0;
13265}
13266
13267_ACEOF
13268if ac_fn_c_try_run "$LINENO"; then :
13269 gl_cv_func_getopt_posix=yes
13270else
13271 gl_cv_func_getopt_posix=no
13272fi
13273rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13274 conftest.$ac_objext conftest.beam conftest.$ac_ext
13275fi
13276
13277 fi
13278 else
13279 case "$host_os" in
13280 darwin* | aix* | mingw*) gl_cv_func_getopt_posix="guessing no";;
13281 *) gl_cv_func_getopt_posix="guessing yes";;
13282 esac
13283 fi
13284
13285fi
13286{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
13287$as_echo "$gl_cv_func_getopt_posix" >&6; }
13288 case "$gl_cv_func_getopt_posix" in
13289 *no) gl_replace_getopt=yes ;;
13290 esac
13291 fi
13292
13293 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
13294 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
13295$as_echo_n "checking for working GNU getopt function... " >&6; }
13296if ${gl_cv_func_getopt_gnu+:} false; then :
13297 $as_echo_n "(cached) " >&6
13298else
13299 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
13300 # optstring is necessary for programs like m4 that have POSIX-mandated
13301 # semantics for supporting options interspersed with files.
13302 # Also, since getopt_long is a GNU extension, we require optind=0.
13303 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
13304 # so take care to revert to the correct (non-)export state.
13305 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
13306 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
13307 xx) gl_had_POSIXLY_CORRECT=exported ;;
13308 x) gl_had_POSIXLY_CORRECT=yes ;;
13309 *) gl_had_POSIXLY_CORRECT= ;;
13310 esac
13311 POSIXLY_CORRECT=1
13312 export POSIXLY_CORRECT
13313 if test "$cross_compiling" = yes; then :
13314 gl_cv_func_getopt_gnu="guessing no"
13315
13316else
13317 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13318/* end confdefs.h. */
13319#include <getopt.h>
13320 #include <stddef.h>
13321 #include <string.h>
13322
13323#include <stdlib.h>
13324#if defined __MACH__ && defined __APPLE__
13325/* Avoid a crash on Mac OS X. */
13326#include <mach/mach.h>
13327#include <mach/mach_error.h>
13328#include <mach/thread_status.h>
13329#include <mach/exception.h>
13330#include <mach/task.h>
13331#include <pthread.h>
13332/* The exception port on which our thread listens. */
13333static mach_port_t our_exception_port;
13334/* The main function of the thread listening for exceptions of type
13335 EXC_BAD_ACCESS. */
13336static void *
13337mach_exception_thread (void *arg)
13338{
13339 /* Buffer for a message to be received. */
13340 struct {
13341 mach_msg_header_t head;
13342 mach_msg_body_t msgh_body;
13343 char data[1024];
13344 } msg;
13345 mach_msg_return_t retval;
13346 /* Wait for a message on the exception port. */
13347 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
13348 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
13349 if (retval != MACH_MSG_SUCCESS)
13350 abort ();
13351 exit (1);
13352}
13353static void
13354nocrash_init (void)
13355{
13356 mach_port_t self = mach_task_self ();
13357 /* Allocate a port on which the thread shall listen for exceptions. */
13358 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
13359 == KERN_SUCCESS) {
13360 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
13361 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
13362 MACH_MSG_TYPE_MAKE_SEND)
13363 == KERN_SUCCESS) {
13364 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
13365 for us. */
13366 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
13367 /* Create the thread listening on the exception port. */
13368 pthread_attr_t attr;
13369 pthread_t thread;
13370 if (pthread_attr_init (&attr) == 0
13371 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
13372 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
13373 pthread_attr_destroy (&attr);
13374 /* Replace the exception port info for these exceptions with our own.
13375 Note that we replace the exception port for the entire task, not only
13376 for a particular thread. This has the effect that when our exception
13377 port gets the message, the thread specific exception port has already
13378 been asked, and we don't need to bother about it.
13379 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
13380 task_set_exception_ports (self, mask, our_exception_port,
13381 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
13382 }
13383 }
13384 }
13385}
13386#elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
13387/* Avoid a crash on native Windows. */
13388#define WIN32_LEAN_AND_MEAN
13389#include <windows.h>
13390#include <winerror.h>
13391static LONG WINAPI
13392exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
13393{
13394 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
13395 {
13396 case EXCEPTION_ACCESS_VIOLATION:
13397 case EXCEPTION_IN_PAGE_ERROR:
13398 case EXCEPTION_STACK_OVERFLOW:
13399 case EXCEPTION_GUARD_PAGE:
13400 case EXCEPTION_PRIV_INSTRUCTION:
13401 case EXCEPTION_ILLEGAL_INSTRUCTION:
13402 case EXCEPTION_DATATYPE_MISALIGNMENT:
13403 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
13404 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
13405 exit (1);
13406 }
13407 return EXCEPTION_CONTINUE_SEARCH;
13408}
13409static void
13410nocrash_init (void)
13411{
13412 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
13413}
13414#else
13415/* Avoid a crash on POSIX systems. */
13416#include <signal.h>
13417/* A POSIX signal handler. */
13418static void
13419exception_handler (int sig)
13420{
13421 exit (1);
13422}
13423static void
13424nocrash_init (void)
13425{
13426#ifdef SIGSEGV
13427 signal (SIGSEGV, exception_handler);
13428#endif
13429#ifdef SIGBUS
13430 signal (SIGBUS, exception_handler);
13431#endif
13432}
13433#endif
13434
13435
13436int
13437main (void)
13438{
13439
13440 int result = 0;
13441
13442 nocrash_init();
13443
13444 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
13445 and fails on Mac OS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
13446 OSF/1 5.1, Solaris 10. */
13447 {
13448 static char conftest[] = "conftest";
13449 static char plus[] = "-+";
13450 char *argv[3] = { conftest, plus, NULL };
13451 opterr = 0;
13452 if (getopt (2, argv, "+a") != '?')
13453 result |= 1;
13454 }
13455 /* This code succeeds on glibc 2.8, mingw,
13456 and fails on Mac OS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
13457 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
13458 {
13459 static char program[] = "program";
13460 static char p[] = "-p";
13461 static char foo[] = "foo";
13462 static char bar[] = "bar";
13463 char *argv[] = { program, p, foo, bar, NULL };
13464
13465 optind = 1;
13466 if (getopt (4, argv, "p::") != 'p')
13467 result |= 2;
13468 else if (optarg != NULL)
13469 result |= 4;
13470 else if (getopt (4, argv, "p::") != -1)
13471 result |= 6;
13472 else if (optind != 2)
13473 result |= 8;
13474 }
13475 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
13476 {
13477 static char program[] = "program";
13478 static char foo[] = "foo";
13479 static char p[] = "-p";
13480 char *argv[] = { program, foo, p, NULL };
13481 optind = 0;
13482 if (getopt (3, argv, "-p") != 1)
13483 result |= 16;
13484 else if (getopt (3, argv, "-p") != 'p')
13485 result |= 16;
13486 }
13487 /* This code fails on glibc 2.11. */
13488 {
13489 static char program[] = "program";
13490 static char b[] = "-b";
13491 static char a[] = "-a";
13492 char *argv[] = { program, b, a, NULL };
13493 optind = opterr = 0;
13494 if (getopt (3, argv, "+:a:b") != 'b')
13495 result |= 32;
13496 else if (getopt (3, argv, "+:a:b") != ':')
13497 result |= 32;
13498 }
13499 /* This code dumps core on glibc 2.14. */
13500 {
13501 static char program[] = "program";
13502 static char w[] = "-W";
13503 static char dummy[] = "dummy";
13504 char *argv[] = { program, w, dummy, NULL };
13505 optind = opterr = 1;
13506 if (getopt (3, argv, "W;") != 'W')
13507 result |= 64;
13508 }
13509 return result;
13510
13511 ;
13512 return 0;
13513}
13514_ACEOF
13515if ac_fn_c_try_run "$LINENO"; then :
13516 gl_cv_func_getopt_gnu=yes
13517else
13518 gl_cv_func_getopt_gnu=no
13519fi
13520rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13521 conftest.$ac_objext conftest.beam conftest.$ac_ext
13522fi
13523
13524 case $gl_had_POSIXLY_CORRECT in
13525 exported) ;;
13526 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
13527 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
13528 esac
13529
13530fi
13531{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
13532$as_echo "$gl_cv_func_getopt_gnu" >&6; }
13533 if test "$gl_cv_func_getopt_gnu" != yes; then
13534 gl_replace_getopt=yes
13535 else
13536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt_long function" >&5
13537$as_echo_n "checking for working GNU getopt_long function... " >&6; }
13538if ${gl_cv_func_getopt_long_gnu+:} false; then :
13539 $as_echo_n "(cached) " >&6
13540else
13541 if test "$cross_compiling" = yes; then :
13542 case "$host_os" in
13543 openbsd*) gl_cv_func_getopt_long_gnu="guessing no";;
13544 *) gl_cv_func_getopt_long_gnu="guessing yes";;
13545 esac
13546
13547else
13548 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13549/* end confdefs.h. */
13550#include <getopt.h>
13551 #include <stddef.h>
13552 #include <string.h>
13553
13554int
13555main (void)
13556{
13557static const struct option long_options[] =
13558 {
13559 { "xtremely-",no_argument, NULL, 1003 },
13560 { "xtra", no_argument, NULL, 1001 },
13561 { "xtreme", no_argument, NULL, 1002 },
13562 { "xtremely", no_argument, NULL, 1003 },
13563 { NULL, 0, NULL, 0 }
13564 };
13565 /* This code fails on OpenBSD 5.0. */
13566 {
13567 static char program[] = "program";
13568 static char xtremel[] = "--xtremel";
13569 char *argv[] = { program, xtremel, NULL };
13570 int option_index;
13571 optind = 1; opterr = 0;
13572 if (getopt_long (2, argv, "", long_options, &option_index) != 1003)
13573 return 1;
13574 }
13575 return 0;
13576
13577 ;
13578 return 0;
13579}
13580_ACEOF
13581if ac_fn_c_try_run "$LINENO"; then :
13582 gl_cv_func_getopt_long_gnu=yes
13583else
13584 gl_cv_func_getopt_long_gnu=no
13585fi
13586rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13587 conftest.$ac_objext conftest.beam conftest.$ac_ext
13588fi
13589
13590
13591fi
13592{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_long_gnu" >&5
13593$as_echo "$gl_cv_func_getopt_long_gnu" >&6; }
13594 case "$gl_cv_func_getopt_long_gnu" in
13595 *yes) ;;
13596 *) gl_replace_getopt=yes ;;
13597 esac
13598 fi
13599 fi
13600
13601
13602
13603
13604
13605
13606 REPLACE_GETOPT=1
13607
13608 if test $REPLACE_GETOPT = 1; then
13609
13610 GETOPT_H=getopt.h
13611
13612$as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
13613
13614
13615
13616 fi
13617
13618ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
13619if test "x$ac_cv_have_decl_getenv" = xyes; then :
13620 ac_have_decl=1
13621else
13622 ac_have_decl=0
13623fi
13624
13625cat >>confdefs.h <<_ACEOF
13626#define HAVE_DECL_GETENV $ac_have_decl
13627_ACEOF
13628
13629
13630 GNULIB_NL_LANGINFO=0;
13631 HAVE_NL_LANGINFO=1;
13632 REPLACE_NL_LANGINFO=0;
13633
13634
13635
13636
13637
13638
13639
13640
13641
13642
13643
13644
13645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fcntl.h" >&5
13646$as_echo_n "checking for working fcntl.h... " >&6; }
13647if ${gl_cv_header_working_fcntl_h+:} false; then :
13648 $as_echo_n "(cached) " >&6
13649else
13650 if test "$cross_compiling" = yes; then :
13651 gl_cv_header_working_fcntl_h=cross-compiling
13652else
13653 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13654/* end confdefs.h. */
13655#include <sys/types.h>
13656 #include <sys/stat.h>
13657 #if HAVE_UNISTD_H
13658 # include <unistd.h>
13659 #else /* on Windows with MSVC */
13660 # include <io.h>
13661 # include <stdlib.h>
13662 # defined sleep(n) _sleep ((n) * 1000)
13663 #endif
13664 #include <fcntl.h>
13665 #ifndef O_NOATIME
13666 #define O_NOATIME 0
13667 #endif
13668 #ifndef O_NOFOLLOW
13669 #define O_NOFOLLOW 0
13670 #endif
13671 static int const constants[] =
13672 {
13673 O_CREAT, O_EXCL, O_NOCTTY, O_TRUNC, O_APPEND,
13674 O_NONBLOCK, O_SYNC, O_ACCMODE, O_RDONLY, O_RDWR, O_WRONLY
13675 };
13676
13677int
13678main (void)
13679{
13680
13681 int result = !constants;
13682 #if HAVE_SYMLINK
13683 {
13684 static char const sym[] = "conftest.sym";
13685 if (symlink ("/dev/null", sym) != 0)
13686 result |= 2;
13687 else
13688 {
13689 int fd = open (sym, O_WRONLY | O_NOFOLLOW | O_CREAT, 0);
13690 if (fd >= 0)
13691 {
13692 close (fd);
13693 result |= 4;
13694 }
13695 }
13696 if (unlink (sym) != 0 || symlink (".", sym) != 0)
13697 result |= 2;
13698 else
13699 {
13700 int fd = open (sym, O_RDONLY | O_NOFOLLOW);
13701 if (fd >= 0)
13702 {
13703 close (fd);
13704 result |= 4;
13705 }
13706 }
13707 unlink (sym);
13708 }
13709 #endif
13710 {
13711 static char const file[] = "confdefs.h";
13712 int fd = open (file, O_RDONLY | O_NOATIME);
13713 if (fd < 0)
13714 result |= 8;
13715 else
13716 {
13717 struct stat st0;
13718 if (fstat (fd, &st0) != 0)
13719 result |= 16;
13720 else
13721 {
13722 char c;
13723 sleep (1);
13724 if (read (fd, &c, 1) != 1)
13725 result |= 24;
13726 else
13727 {
13728 if (close (fd) != 0)
13729 result |= 32;
13730 else
13731 {
13732 struct stat st1;
13733 if (stat (file, &st1) != 0)
13734 result |= 40;
13735 else
13736 if (st0.st_atime != st1.st_atime)
13737 result |= 64;
13738 }
13739 }
13740 }
13741 }
13742 }
13743 return result;
13744 ;
13745 return 0;
13746}
13747_ACEOF
13748if ac_fn_c_try_run "$LINENO"; then :
13749 gl_cv_header_working_fcntl_h=yes
13750else
13751 case $? in #(
13752 4) gl_cv_header_working_fcntl_h='no (bad O_NOFOLLOW)';; #(
13753 64) gl_cv_header_working_fcntl_h='no (bad O_NOATIME)';; #(
13754 68) gl_cv_header_working_fcntl_h='no (bad O_NOATIME, O_NOFOLLOW)';; #(
13755 *) gl_cv_header_working_fcntl_h='no';;
13756 esac
13757fi
13758rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13759 conftest.$ac_objext conftest.beam conftest.$ac_ext
13760fi
13761
13762fi
13763{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_fcntl_h" >&5
13764$as_echo "$gl_cv_header_working_fcntl_h" >&6; }
13765
13766 case $gl_cv_header_working_fcntl_h in #(
13767 *O_NOATIME* | no | cross-compiling) ac_val=0;; #(
13768 *) ac_val=1;;
13769 esac
13770
13771cat >>confdefs.h <<_ACEOF
13772#define HAVE_WORKING_O_NOATIME $ac_val
13773_ACEOF
13774
13775
13776 case $gl_cv_header_working_fcntl_h in #(
13777 *O_NOFOLLOW* | no | cross-compiling) ac_val=0;; #(
13778 *) ac_val=1;;
13779 esac
13780
13781cat >>confdefs.h <<_ACEOF
13782#define HAVE_WORKING_O_NOFOLLOW $ac_val
13783_ACEOF
13784
13785
13786
13787 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C Library >= 2.1 or uClibc" >&5
13788$as_echo_n "checking whether we are using the GNU C Library >= 2.1 or uClibc... " >&6; }
13789if ${ac_cv_gnu_library_2_1+:} false; then :
13790 $as_echo_n "(cached) " >&6
13791else
13792 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13793/* end confdefs.h. */
13794
13795#include <features.h>
13796#ifdef __GNU_LIBRARY__
13797 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)
13798 Lucky GNU user
13799 #endif
13800#endif
13801#ifdef __UCLIBC__
13802 Lucky user
13803#endif
13804
13805_ACEOF
13806if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13807 $EGREP "Lucky" >/dev/null 2>&1; then :
13808 ac_cv_gnu_library_2_1=yes
13809else
13810 ac_cv_gnu_library_2_1=no
13811fi
13812rm -f conftest*
13813
13814
13815
13816fi
13817{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gnu_library_2_1" >&5
13818$as_echo "$ac_cv_gnu_library_2_1" >&6; }
13819
13820 GLIBC21="$ac_cv_gnu_library_2_1"
13821
13822
13823
13824 GNULIB_LOCALECONV=0;
13825 GNULIB_SETLOCALE=0;
13826 GNULIB_DUPLOCALE=0;
13827 HAVE_DUPLOCALE=1;
13828 REPLACE_LOCALECONV=0;
13829 REPLACE_SETLOCALE=0;
13830 REPLACE_DUPLOCALE=0;
13831 REPLACE_STRUCT_LCONV=0;
13832
13833
13834 REPLACE_NULL=0;
13835 HAVE_WCHAR_T=1;
13836
13837
13838 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
13839$as_echo_n "checking for wchar_t... " >&6; }
13840if ${gt_cv_c_wchar_t+:} false; then :
13841 $as_echo_n "(cached) " >&6
13842else
13843 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13844/* end confdefs.h. */
13845#include <stddef.h>
13846 wchar_t foo = (wchar_t)'\0';
13847int
13848main (void)
13849{
13850
13851 ;
13852 return 0;
13853}
13854_ACEOF
13855if ac_fn_c_try_compile "$LINENO"; then :
13856 gt_cv_c_wchar_t=yes
13857else
13858 gt_cv_c_wchar_t=no
13859fi
13860rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13861fi
13862{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
13863$as_echo "$gt_cv_c_wchar_t" >&6; }
13864 if test $gt_cv_c_wchar_t = yes; then
13865
13866$as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
13867
13868 fi
13869
13870
13871
13872
13873 STDDEF_H=
13874 if test $gt_cv_c_wchar_t = no; then
13875 HAVE_WCHAR_T=0
13876 STDDEF_H=stddef.h
13877 fi
13878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
13879$as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
13880if ${gl_cv_decl_null_works+:} false; then :
13881 $as_echo_n "(cached) " >&6
13882else
13883 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13884/* end confdefs.h. */
13885#include <stddef.h>
13886 int test[2 * (sizeof NULL == sizeof (void *)) -1];
13887
13888int
13889main (void)
13890{
13891
13892 ;
13893 return 0;
13894}
13895_ACEOF
13896if ac_fn_c_try_compile "$LINENO"; then :
13897 gl_cv_decl_null_works=yes
13898else
13899 gl_cv_decl_null_works=no
13900fi
13901rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13902fi
13903{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
13904$as_echo "$gl_cv_decl_null_works" >&6; }
13905 if test $gl_cv_decl_null_works = no; then
13906 REPLACE_NULL=1
13907 STDDEF_H=stddef.h
13908 fi
13909
13910 if test -n "$STDDEF_H"; then
13911 GL_GENERATE_STDDEF_H_TRUE=
13912 GL_GENERATE_STDDEF_H_FALSE='#'
13913else
13914 GL_GENERATE_STDDEF_H_TRUE='#'
13915 GL_GENERATE_STDDEF_H_FALSE=
13916fi
13917
13918 if test -n "$STDDEF_H"; then
13919
13920
13921
13922
13923
13924
13925
13926
13927 if test $gl_cv_have_include_next = yes; then
13928 gl_cv_next_stddef_h='<'stddef.h'>'
13929 else
13930 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
13931$as_echo_n "checking absolute name of <stddef.h>... " >&6; }
13932if ${gl_cv_next_stddef_h+:} false; then :
13933 $as_echo_n "(cached) " >&6
13934else
13935
13936 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13937/* end confdefs.h. */
13938#include <stddef.h>
13939
13940_ACEOF
13941 case "$host_os" in
13942 aix*) gl_absname_cpp="$ac_cpp -C" ;;
13943 *) gl_absname_cpp="$ac_cpp" ;;
13944 esac
13945
13946 case "$host_os" in
13947 mingw*)
13948 gl_dirsep_regex='[/\\]'
13949 ;;
13950 *)
13951 gl_dirsep_regex='\/'
13952 ;;
13953 esac
13954 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
13955
13956 gl_header_literal_regex=`echo 'stddef.h' \
13957 | sed -e "$gl_make_literal_regex_sed"`
13958 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
13959 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
13960 s|^/[^/]|//&|
13961 p
13962 q
13963 }'
13964 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
13965 sed -n "$gl_absolute_header_sed"`'"'
13966
13967
13968fi
13969{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
13970$as_echo "$gl_cv_next_stddef_h" >&6; }
13971 fi
13972 NEXT_STDDEF_H=$gl_cv_next_stddef_h
13973
13974 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
13975 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
13976 gl_next_as_first_directive='<'stddef.h'>'
13977 else
13978 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
13979 gl_next_as_first_directive=$gl_cv_next_stddef_h
13980 fi
13981 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
13982
13983
13984
13985
13986 fi
13987
13988
13989
13990
13991 GNULIB__EXIT=0;
13992 GNULIB_ATOLL=0;
13993 GNULIB_CALLOC_POSIX=0;
13994 GNULIB_CANONICALIZE_FILE_NAME=0;
13995 GNULIB_GETLOADAVG=0;
13996 GNULIB_GETSUBOPT=0;
13997 GNULIB_GRANTPT=0;
13998 GNULIB_MALLOC_POSIX=0;
13999 GNULIB_MBTOWC=0;
14000 GNULIB_MKDTEMP=0;
14001 GNULIB_MKOSTEMP=0;
14002 GNULIB_MKOSTEMPS=0;
14003 GNULIB_MKSTEMP=0;
14004 GNULIB_MKSTEMPS=0;
14005 GNULIB_POSIX_OPENPT=0;
14006 GNULIB_PTSNAME=0;
14007 GNULIB_PTSNAME_R=0;
14008 GNULIB_PUTENV=0;
14009 GNULIB_RANDOM=0;
14010 GNULIB_RANDOM_R=0;
14011 GNULIB_REALLOC_POSIX=0;
14012 GNULIB_REALPATH=0;
14013 GNULIB_RPMATCH=0;
14014 GNULIB_SECURE_GETENV=0;
14015 GNULIB_SETENV=0;
14016 GNULIB_STRTOD=0;
14017 GNULIB_STRTOLL=0;
14018 GNULIB_STRTOULL=0;
14019 GNULIB_SYSTEM_POSIX=0;
14020 GNULIB_UNLOCKPT=0;
14021 GNULIB_UNSETENV=0;
14022 GNULIB_WCTOMB=0;
14023 HAVE__EXIT=1;
14024 HAVE_ATOLL=1;
14025 HAVE_CANONICALIZE_FILE_NAME=1;
14026 HAVE_DECL_GETLOADAVG=1;
14027 HAVE_GETSUBOPT=1;
14028 HAVE_GRANTPT=1;
14029 HAVE_MKDTEMP=1;
14030 HAVE_MKOSTEMP=1;
14031 HAVE_MKOSTEMPS=1;
14032 HAVE_MKSTEMP=1;
14033 HAVE_MKSTEMPS=1;
14034 HAVE_POSIX_OPENPT=1;
14035 HAVE_PTSNAME=1;
14036 HAVE_PTSNAME_R=1;
14037 HAVE_RANDOM=1;
14038 HAVE_RANDOM_H=1;
14039 HAVE_RANDOM_R=1;
14040 HAVE_REALPATH=1;
14041 HAVE_RPMATCH=1;
14042 HAVE_SECURE_GETENV=1;
14043 HAVE_SETENV=1;
14044 HAVE_DECL_SETENV=1;
14045 HAVE_STRTOD=1;
14046 HAVE_STRTOLL=1;
14047 HAVE_STRTOULL=1;
14048 HAVE_STRUCT_RANDOM_DATA=1;
14049 HAVE_SYS_LOADAVG_H=0;
14050 HAVE_UNLOCKPT=1;
14051 HAVE_DECL_UNSETENV=1;
14052 REPLACE_CALLOC=0;
14053 REPLACE_CANONICALIZE_FILE_NAME=0;
14054 REPLACE_MALLOC=0;
14055 REPLACE_MBTOWC=0;
14056 REPLACE_MKSTEMP=0;
14057 REPLACE_PTSNAME=0;
14058 REPLACE_PTSNAME_R=0;
14059 REPLACE_PUTENV=0;
14060 REPLACE_RANDOM_R=0;
14061 REPLACE_REALLOC=0;
14062 REPLACE_REALPATH=0;
14063 REPLACE_SETENV=0;
14064 REPLACE_STRTOD=0;
14065 REPLACE_UNSETENV=0;
14066 REPLACE_WCTOMB=0;
14067
14068
14069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc, realloc, calloc are POSIX compliant" >&5
14070$as_echo_n "checking whether malloc, realloc, calloc are POSIX compliant... " >&6; }
14071if ${gl_cv_func_malloc_posix+:} false; then :
14072 $as_echo_n "(cached) " >&6
14073else
14074
14075 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14076/* end confdefs.h. */
14077
14078int
14079main (void)
14080{
14081#if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
14082 choke me
14083 #endif
14084
14085 ;
14086 return 0;
14087}
14088_ACEOF
14089if ac_fn_c_try_compile "$LINENO"; then :
14090 gl_cv_func_malloc_posix=yes
14091else
14092 gl_cv_func_malloc_posix=no
14093fi
14094rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14095
14096fi
14097{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_malloc_posix" >&5
14098$as_echo "$gl_cv_func_malloc_posix" >&6; }
14099
14100
14101
14102
14103
14104
14105
14106
14107 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional japanese locale" >&5
14108$as_echo_n "checking for a traditional japanese locale... " >&6; }
14109if ${gt_cv_locale_ja+:} false; then :
14110 $as_echo_n "(cached) " >&6
14111else
14112
14113 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14114/* end confdefs.h. */
14115
14116#include <locale.h>
14117#include <time.h>
14118#if HAVE_LANGINFO_CODESET
14119# include <langinfo.h>
14120#endif
14121#include <stdlib.h>
14122#include <string.h>
14123struct tm t;
14124char buf[16];
14125int main ()
14126{
14127 const char *p;
14128 /* Check whether the given locale name is recognized by the system. */
14129#if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
14130 /* On native Windows, setlocale(category, "") looks at the system settings,
14131 not at the environment variables. Also, when an encoding suffix such
14132 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
14133 category of the locale to "C". */
14134 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
14135 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
14136 return 1;
14137#else
14138 if (setlocale (LC_ALL, "") == NULL) return 1;
14139#endif
14140 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
14141 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
14142 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
14143 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
14144 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
14145 some unit tests fail.
14146 On MirBSD 10, when an unsupported locale is specified, setlocale()
14147 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
14148#if HAVE_LANGINFO_CODESET
14149 {
14150 const char *cs = nl_langinfo (CODESET);
14151 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
14152 || strcmp (cs, "UTF-8") == 0)
14153 return 1;
14154 }
14155#endif
14156#ifdef __CYGWIN__
14157 /* On Cygwin, avoid locale names without encoding suffix, because the
14158 locale_charset() function relies on the encoding suffix. Note that
14159 LC_ALL is set on the command line. */
14160 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
14161#endif
14162 /* Check whether MB_CUR_MAX is > 1. This excludes the dysfunctional locales
14163 on Cygwin 1.5.x. */
14164 if (MB_CUR_MAX == 1)
14165 return 1;
14166 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
14167 This excludes the UTF-8 encoding (except on MirBSD). */
14168 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
14169 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
14170 for (p = buf; *p != '\0'; p++)
14171 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
14172 return 1;
14173 return 0;
14174}
14175
14176_ACEOF
14177 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
14178 (eval $ac_link) 2>&5
14179 ac_status=$?
14180 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14181 test $ac_status = 0; } && test -s conftest$ac_exeext; then
14182 case "$host_os" in
14183 # Handle native Windows specially, because there setlocale() interprets
14184 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
14185 # "fr" or "fra" as "French" or "French_France.1252",
14186 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
14187 # "ja" as "Japanese" or "Japanese_Japan.932",
14188 # and similar.
14189 mingw*)
14190 # Note that on native Windows, the Japanese locale is
14191 # Japanese_Japan.932, and CP932 is very different from EUC-JP, so we
14192 # cannot use it here.
14193 gt_cv_locale_ja=none
14194 ;;
14195 *)
14196 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
14197 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
14198 # configure script would override the LC_ALL setting. Likewise for
14199 # LC_CTYPE, which is also set at the beginning of the configure script.
14200 # Test for the AIX locale name.
14201 if (LC_ALL=ja_JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14202 gt_cv_locale_ja=ja_JP
14203 else
14204 # Test for the locale name with explicit encoding suffix.
14205 if (LC_ALL=ja_JP.EUC-JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14206 gt_cv_locale_ja=ja_JP.EUC-JP
14207 else
14208 # Test for the HP-UX, OSF/1, NetBSD locale name.
14209 if (LC_ALL=ja_JP.eucJP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14210 gt_cv_locale_ja=ja_JP.eucJP
14211 else
14212 # Test for the IRIX, FreeBSD locale name.
14213 if (LC_ALL=ja_JP.EUC LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14214 gt_cv_locale_ja=ja_JP.EUC
14215 else
14216 # Test for the Solaris 7 locale name.
14217 if (LC_ALL=ja LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14218 gt_cv_locale_ja=ja
14219 else
14220 # Special test for NetBSD 1.6.
14221 if test -f /usr/share/locale/ja_JP.eucJP/LC_CTYPE; then
14222 gt_cv_locale_ja=ja_JP.eucJP
14223 else
14224 # None found.
14225 gt_cv_locale_ja=none
14226 fi
14227 fi
14228 fi
14229 fi
14230 fi
14231 fi
14232 ;;
14233 esac
14234 fi
14235 rm -fr conftest*
14236
14237fi
14238{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_ja" >&5
14239$as_echo "$gt_cv_locale_ja" >&6; }
14240 LOCALE_JA=$gt_cv_locale_ja
14241
14242
14243
14244
14245
14246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a transitional chinese locale" >&5
14247$as_echo_n "checking for a transitional chinese locale... " >&6; }
14248if ${gt_cv_locale_zh_CN+:} false; then :
14249 $as_echo_n "(cached) " >&6
14250else
14251
14252 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14253/* end confdefs.h. */
14254
14255#include <locale.h>
14256#include <stdlib.h>
14257#include <time.h>
14258#if HAVE_LANGINFO_CODESET
14259# include <langinfo.h>
14260#endif
14261#include <stdlib.h>
14262#include <string.h>
14263struct tm t;
14264char buf[16];
14265int main ()
14266{
14267 const char *p;
14268 /* Check whether the given locale name is recognized by the system. */
14269#if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
14270 /* On native Windows, setlocale(category, "") looks at the system settings,
14271 not at the environment variables. Also, when an encoding suffix such
14272 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
14273 category of the locale to "C". */
14274 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
14275 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
14276 return 1;
14277#else
14278 if (setlocale (LC_ALL, "") == NULL) return 1;
14279#endif
14280 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
14281 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
14282 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
14283 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
14284 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
14285 some unit tests fail.
14286 On MirBSD 10, when an unsupported locale is specified, setlocale()
14287 succeeds but then nl_langinfo(CODESET) is "UTF-8". */
14288#if HAVE_LANGINFO_CODESET
14289 {
14290 const char *cs = nl_langinfo (CODESET);
14291 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
14292 || strcmp (cs, "UTF-8") == 0)
14293 return 1;
14294 }
14295#endif
14296#ifdef __CYGWIN__
14297 /* On Cygwin, avoid locale names without encoding suffix, because the
14298 locale_charset() function relies on the encoding suffix. Note that
14299 LC_ALL is set on the command line. */
14300 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
14301#endif
14302 /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
14303 This excludes the UTF-8 encoding (except on MirBSD). */
14304 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
14305 if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
14306 for (p = buf; *p != '\0'; p++)
14307 if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
14308 return 1;
14309 /* Check whether a typical GB18030 multibyte sequence is recognized as a
14310 single wide character. This excludes the GB2312 and GBK encodings. */
14311 if (mblen ("\203\062\332\066", 5) != 4)
14312 return 1;
14313 return 0;
14314}
14315
14316_ACEOF
14317 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
14318 (eval $ac_link) 2>&5
14319 ac_status=$?
14320 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14321 test $ac_status = 0; } && test -s conftest$ac_exeext; then
14322 case "$host_os" in
14323 # Handle native Windows specially, because there setlocale() interprets
14324 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
14325 # "fr" or "fra" as "French" or "French_France.1252",
14326 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
14327 # "ja" as "Japanese" or "Japanese_Japan.932",
14328 # and similar.
14329 mingw*)
14330 # Test for the hypothetical native Windows locale name.
14331 if (LC_ALL=Chinese_China.54936 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14332 gt_cv_locale_zh_CN=Chinese_China.54936
14333 else
14334 # None found.
14335 gt_cv_locale_zh_CN=none
14336 fi
14337 ;;
14338 solaris2.8)
14339 # On Solaris 8, the locales zh_CN.GB18030, zh_CN.GBK, zh.GBK are
14340 # broken. One witness is the test case in gl_MBRTOWC_SANITYCHECK.
14341 # Another witness is that "LC_ALL=zh_CN.GB18030 bash -c true" dumps core.
14342 gt_cv_locale_zh_CN=none
14343 ;;
14344 *)
14345 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
14346 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
14347 # configure script would override the LC_ALL setting. Likewise for
14348 # LC_CTYPE, which is also set at the beginning of the configure script.
14349 # Test for the locale name without encoding suffix.
14350 if (LC_ALL=zh_CN LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14351 gt_cv_locale_zh_CN=zh_CN
14352 else
14353 # Test for the locale name with explicit encoding suffix.
14354 if (LC_ALL=zh_CN.GB18030 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14355 gt_cv_locale_zh_CN=zh_CN.GB18030
14356 else
14357 # None found.
14358 gt_cv_locale_zh_CN=none
14359 fi
14360 fi
14361 ;;
14362 esac
14363 else
14364 # If there was a link error, due to mblen(), the system is so old that
14365 # it certainly doesn't have a chinese locale.
14366 gt_cv_locale_zh_CN=none
14367 fi
14368 rm -fr conftest*
14369
14370fi
14371{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_zh_CN" >&5
14372$as_echo "$gt_cv_locale_zh_CN" >&6; }
14373 LOCALE_ZH_CN=$gt_cv_locale_zh_CN
14374
14375
14376
14377
14378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
14379$as_echo_n "checking for a french Unicode locale... " >&6; }
14380if ${gt_cv_locale_fr_utf8+:} false; then :
14381 $as_echo_n "(cached) " >&6
14382else
14383
14384 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14385/* end confdefs.h. */
14386
14387#include <locale.h>
14388#include <time.h>
14389#if HAVE_LANGINFO_CODESET
14390# include <langinfo.h>
14391#endif
14392#include <stdlib.h>
14393#include <string.h>
14394struct tm t;
14395char buf[16];
14396int main () {
14397 /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
14398 imitates locale dependent behaviour by looking at the environment
14399 variables, and all locales use the UTF-8 encoding. */
14400#if !(defined __BEOS__ || defined __HAIKU__)
14401 /* Check whether the given locale name is recognized by the system. */
14402# if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
14403 /* On native Windows, setlocale(category, "") looks at the system settings,
14404 not at the environment variables. Also, when an encoding suffix such
14405 as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
14406 category of the locale to "C". */
14407 if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
14408 || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
14409 return 1;
14410# else
14411 if (setlocale (LC_ALL, "") == NULL) return 1;
14412# endif
14413 /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
14414 On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
14415 is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
14416 On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
14417 succeeds but then nl_langinfo(CODESET) is "646". In this situation,
14418 some unit tests fail. */
14419# if HAVE_LANGINFO_CODESET
14420 {
14421 const char *cs = nl_langinfo (CODESET);
14422 if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
14423 return 1;
14424 }
14425# endif
14426# ifdef __CYGWIN__
14427 /* On Cygwin, avoid locale names without encoding suffix, because the
14428 locale_charset() function relies on the encoding suffix. Note that
14429 LC_ALL is set on the command line. */
14430 if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
14431# endif
14432 /* Check whether in the abbreviation of the second month, the second
14433 character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
14434 two bytes long, with UTF-8 encoding. */
14435 t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
14436 if (strftime (buf, sizeof (buf), "%b", &t) < 4
14437 || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
14438 return 1;
14439#endif
14440#if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
14441 /* Check whether the decimal separator is a comma.
14442 On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
14443 are nl_langinfo(RADIXCHAR) are both ".". */
14444 if (localeconv () ->decimal_point[0] != ',') return 1;
14445#endif
14446 return 0;
14447}
14448
14449_ACEOF
14450 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
14451 (eval $ac_link) 2>&5
14452 ac_status=$?
14453 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14454 test $ac_status = 0; } && test -s conftest$ac_exeext; then
14455 case "$host_os" in
14456 # Handle native Windows specially, because there setlocale() interprets
14457 # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
14458 # "fr" or "fra" as "French" or "French_France.1252",
14459 # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
14460 # "ja" as "Japanese" or "Japanese_Japan.932",
14461 # and similar.
14462 mingw*)
14463 # Test for the hypothetical native Windows locale name.
14464 if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14465 gt_cv_locale_fr_utf8=French_France.65001
14466 else
14467 # None found.
14468 gt_cv_locale_fr_utf8=none
14469 fi
14470 ;;
14471 *)
14472 # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
14473 # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
14474 # configure script would override the LC_ALL setting. Likewise for
14475 # LC_CTYPE, which is also set at the beginning of the configure script.
14476 # Test for the usual locale name.
14477 if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14478 gt_cv_locale_fr_utf8=fr_FR
14479 else
14480 # Test for the locale name with explicit encoding suffix.
14481 if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14482 gt_cv_locale_fr_utf8=fr_FR.UTF-8
14483 else
14484 # Test for the Solaris 7 locale name.
14485 if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
14486 gt_cv_locale_fr_utf8=fr.UTF-8
14487 else
14488 # None found.
14489 gt_cv_locale_fr_utf8=none
14490 fi
14491 fi
14492 fi
14493 ;;
14494 esac
14495 fi
14496 rm -fr conftest*
14497
14498fi
14499{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
14500$as_echo "$gt_cv_locale_fr_utf8" >&6; }
14501 LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
14502
14503
14504
14505
14506
14507
14508
14509
14510
14511
14512
14513 GNULIB_FFSL=0;
14514 GNULIB_FFSLL=0;
14515 GNULIB_MEMCHR=0;
14516 GNULIB_MEMMEM=0;
14517 GNULIB_MEMPCPY=0;
14518 GNULIB_MEMRCHR=0;
14519 GNULIB_RAWMEMCHR=0;
14520 GNULIB_STPCPY=0;
14521 GNULIB_STPNCPY=0;
14522 GNULIB_STRCHRNUL=0;
14523 GNULIB_STRDUP=0;
14524 GNULIB_STRNCAT=0;
14525 GNULIB_STRNDUP=0;
14526 GNULIB_STRNLEN=0;
14527 GNULIB_STRPBRK=0;
14528 GNULIB_STRSEP=0;
14529 GNULIB_STRSTR=0;
14530 GNULIB_STRCASESTR=0;
14531 GNULIB_STRTOK_R=0;
14532 GNULIB_MBSLEN=0;
14533 GNULIB_MBSNLEN=0;
14534 GNULIB_MBSCHR=0;
14535 GNULIB_MBSRCHR=0;
14536 GNULIB_MBSSTR=0;
14537 GNULIB_MBSCASECMP=0;
14538 GNULIB_MBSNCASECMP=0;
14539 GNULIB_MBSPCASECMP=0;
14540 GNULIB_MBSCASESTR=0;
14541 GNULIB_MBSCSPN=0;
14542 GNULIB_MBSPBRK=0;
14543 GNULIB_MBSSPN=0;
14544 GNULIB_MBSSEP=0;
14545 GNULIB_MBSTOK_R=0;
14546 GNULIB_STRERROR=0;
14547 GNULIB_STRERROR_R=0;
14548 GNULIB_STRSIGNAL=0;
14549 GNULIB_STRVERSCMP=0;
14550 HAVE_MBSLEN=0;
14551 HAVE_FFSL=1;
14552 HAVE_FFSLL=1;
14553 HAVE_MEMCHR=1;
14554 HAVE_DECL_MEMMEM=1;
14555 HAVE_MEMPCPY=1;
14556 HAVE_DECL_MEMRCHR=1;
14557 HAVE_RAWMEMCHR=1;
14558 HAVE_STPCPY=1;
14559 HAVE_STPNCPY=1;
14560 HAVE_STRCHRNUL=1;
14561 HAVE_DECL_STRDUP=1;
14562 HAVE_DECL_STRNDUP=1;
14563 HAVE_DECL_STRNLEN=1;
14564 HAVE_STRPBRK=1;
14565 HAVE_STRSEP=1;
14566 HAVE_STRCASESTR=1;
14567 HAVE_DECL_STRTOK_R=1;
14568 HAVE_DECL_STRERROR_R=1;
14569 HAVE_DECL_STRSIGNAL=1;
14570 HAVE_STRVERSCMP=1;
14571 REPLACE_MEMCHR=0;
14572 REPLACE_MEMMEM=0;
14573 REPLACE_STPNCPY=0;
14574 REPLACE_STRDUP=0;
14575 REPLACE_STRSTR=0;
14576 REPLACE_STRCASESTR=0;
14577 REPLACE_STRCHRNUL=0;
14578 REPLACE_STRERROR=0;
14579 REPLACE_STRERROR_R=0;
14580 REPLACE_STRNCAT=0;
14581 REPLACE_STRNDUP=0;
14582 REPLACE_STRNLEN=0;
14583 REPLACE_STRSIGNAL=0;
14584 REPLACE_STRTOK_R=0;
14585 UNDEFINE_STRTOK_R=0;
14586
14587
14588
14589
14590
14591 # Check for mmap(). Don't use AC_FUNC_MMAP, because it checks too much: it
14592 # fails on HP-UX 11, because MAP_FIXED mappings do not work. But this is
14593 # irrelevant for anonymous mappings.
14594 ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap"
14595if test "x$ac_cv_func_mmap" = xyes; then :
14596 gl_have_mmap=yes
14597else
14598 gl_have_mmap=no
14599fi
14600
14601
14602 # Try to allow MAP_ANONYMOUS.
14603 gl_have_mmap_anonymous=no
14604 if test $gl_have_mmap = yes; then
14605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAP_ANONYMOUS" >&5
14606$as_echo_n "checking for MAP_ANONYMOUS... " >&6; }
14607 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14608/* end confdefs.h. */
14609
14610#include <sys/mman.h>
14611#ifdef MAP_ANONYMOUS
14612 I cannot identify this map
14613#endif
14614
14615_ACEOF
14616if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14617 $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
14618 gl_have_mmap_anonymous=yes
14619fi
14620rm -f conftest*
14621
14622 if test $gl_have_mmap_anonymous != yes; then
14623 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14624/* end confdefs.h. */
14625
14626#include <sys/mman.h>
14627#ifdef MAP_ANON
14628 I cannot identify this map
14629#endif
14630
14631_ACEOF
14632if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14633 $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
14634
14635$as_echo "#define MAP_ANONYMOUS MAP_ANON" >>confdefs.h
14636
14637 gl_have_mmap_anonymous=yes
14638fi
14639rm -f conftest*
14640
14641 fi
14642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_have_mmap_anonymous" >&5
14643$as_echo "$gl_have_mmap_anonymous" >&6; }
14644 if test $gl_have_mmap_anonymous = yes; then
14645
14646$as_echo "#define HAVE_MAP_ANONYMOUS 1" >>confdefs.h
14647
14648 fi
14649 fi
14650
14651
14652
14653
14654
14655
14656 if test $HAVE_MEMCHR = 1; then
14657 # Detect platform-specific bugs in some versions of glibc:
14658 # memchr should not dereference anything with length 0
14659 # http://bugzilla.redhat.com/499689
14660 # memchr should not dereference overestimated length after a match
14661 # http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=521737
14662 # http://sourceware.org/bugzilla/show_bug.cgi?id=10162
14663 # Assume that memchr works on platforms that lack mprotect.
14664 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memchr works" >&5
14665$as_echo_n "checking whether memchr works... " >&6; }
14666if ${gl_cv_func_memchr_works+:} false; then :
14667 $as_echo_n "(cached) " >&6
14668else
14669 if test "$cross_compiling" = yes; then :
14670 gl_cv_func_memchr_works="guessing no"
14671else
14672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14673/* end confdefs.h. */
14674
14675#include <string.h>
14676#if HAVE_SYS_MMAN_H
14677# include <fcntl.h>
14678# include <unistd.h>
14679# include <sys/types.h>
14680# include <sys/mman.h>
14681# ifndef MAP_FILE
14682# define MAP_FILE 0
14683# endif
14684#endif
14685
14686int
14687main (void)
14688{
14689
14690 int result = 0;
14691 char *fence = NULL;
14692#if HAVE_SYS_MMAN_H && HAVE_MPROTECT
14693# if HAVE_MAP_ANONYMOUS
14694 const int flags = MAP_ANONYMOUS | MAP_PRIVATE;
14695 const int fd = -1;
14696# else /* !HAVE_MAP_ANONYMOUS */
14697 const int flags = MAP_FILE | MAP_PRIVATE;
14698 int fd = open ("/dev/zero", O_RDONLY, 0666);
14699 if (fd >= 0)
14700# endif
14701 {
14702 int pagesize = getpagesize ();
14703 char *two_pages =
14704 (char *) mmap (NULL, 2 * pagesize, PROT_READ | PROT_WRITE,
14705 flags, fd, 0);
14706 if (two_pages != (char *)(-1)
14707 && mprotect (two_pages + pagesize, pagesize, PROT_NONE) == 0)
14708 fence = two_pages + pagesize;
14709 }
14710#endif
14711 if (fence)
14712 {
14713 if (memchr (fence, 0, 0))
14714 result |= 1;
14715 strcpy (fence - 9, "12345678");
14716 if (memchr (fence - 9, 0, 79) != fence - 1)
14717 result |= 2;
14718 if (memchr (fence - 1, 0, 3) != fence - 1)
14719 result |= 4;
14720 }
14721 return result;
14722
14723 ;
14724 return 0;
14725}
14726_ACEOF
14727if ac_fn_c_try_run "$LINENO"; then :
14728 gl_cv_func_memchr_works=yes
14729else
14730 gl_cv_func_memchr_works=no
14731fi
14732rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14733 conftest.$ac_objext conftest.beam conftest.$ac_ext
14734fi
14735
14736fi
14737{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memchr_works" >&5
14738$as_echo "$gl_cv_func_memchr_works" >&6; }
14739 if test "$gl_cv_func_memchr_works" != yes; then
14740 REPLACE_MEMCHR=1
14741 fi
14742 fi
14743
14744
14745
14746
14747 gl_cv_c_multiarch=no
14748 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14749/* end confdefs.h. */
14750#ifndef __APPLE_CC__
14751 not a universal capable compiler
14752 #endif
14753 typedef int dummy;
14754
14755_ACEOF
14756if ac_fn_c_try_compile "$LINENO"; then :
14757
14758 arch=
14759 prev=
14760 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
14761 if test -n "$prev"; then
14762 case $word in
14763 i?86 | x86_64 | ppc | ppc64)
14764 if test -z "$arch" || test "$arch" = "$word"; then
14765 arch="$word"
14766 else
14767 gl_cv_c_multiarch=yes
14768 fi
14769 ;;
14770 esac
14771 prev=
14772 else
14773 if test "x$word" = "x-arch"; then
14774 prev=arch
14775 fi
14776 fi
14777 done
14778
14779fi
14780rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14781 if test $gl_cv_c_multiarch = yes; then
14782 APPLE_UNIVERSAL_BUILD=1
14783 else
14784 APPLE_UNIVERSAL_BUILD=0
14785 fi
14786
14787
14788
14789
14790ac_fn_c_check_decl "$LINENO" "alarm" "ac_cv_have_decl_alarm" "$ac_includes_default"
14791if test "x$ac_cv_have_decl_alarm" = xyes; then :
14792 ac_have_decl=1
14793else
14794 ac_have_decl=0
14795fi
14796
14797cat >>confdefs.h <<_ACEOF
14798#define HAVE_DECL_ALARM $ac_have_decl
14799_ACEOF
14800
14801
14802
14803 for ac_header in stdlib.h
14804do :
14805 ac_fn_c_check_header_mongrel "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default"
14806if test "x$ac_cv_header_stdlib_h" = xyes; then :
14807 cat >>confdefs.h <<_ACEOF
14808#define HAVE_STDLIB_H 1
14809_ACEOF
14810
14811fi
14812
14813done
14814
14815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5
14816$as_echo_n "checking for GNU libc compatible malloc... " >&6; }
14817if ${ac_cv_func_malloc_0_nonnull+:} false; then :
14818 $as_echo_n "(cached) " >&6
14819else
14820 if test "$cross_compiling" = yes; then :
14821 case "$host_os" in
14822 # Guess yes on platforms where we know the result.
14823 *-gnu* | freebsd* | netbsd* | openbsd* \
14824 | hpux* | solaris* | cygwin* | mingw*)
14825 ac_cv_func_malloc_0_nonnull=yes ;;
14826 # If we don't know, assume the worst.
14827 *) ac_cv_func_malloc_0_nonnull=no ;;
14828 esac
14829
14830else
14831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14832/* end confdefs.h. */
14833#if defined STDC_HEADERS || defined HAVE_STDLIB_H
14834 # include <stdlib.h>
14835 #else
14836 char *malloc ();
14837 #endif
14838
14839int
14840main (void)
14841{
14842return ! malloc (0);
14843 ;
14844 return 0;
14845}
14846
14847_ACEOF
14848if ac_fn_c_try_run "$LINENO"; then :
14849 ac_cv_func_malloc_0_nonnull=yes
14850else
14851 ac_cv_func_malloc_0_nonnull=no
14852fi
14853rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14854 conftest.$ac_objext conftest.beam conftest.$ac_ext
14855fi
14856
14857
14858fi
14859{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_malloc_0_nonnull" >&5
14860$as_echo "$ac_cv_func_malloc_0_nonnull" >&6; }
14861 if test $ac_cv_func_malloc_0_nonnull = yes; then :
14862 gl_cv_func_malloc_0_nonnull=1
14863else
14864 gl_cv_func_malloc_0_nonnull=0
14865fi
14866
14867
14868cat >>confdefs.h <<_ACEOF
14869#define MALLOC_0_IS_NONNULL $gl_cv_func_malloc_0_nonnull
14870_ACEOF
14871
14872
14873
14874
14875
14876
14877{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
14878$as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
14879if ${ac_cv_header_stdbool_h+:} false; then :
14880 $as_echo_n "(cached) " >&6
14881else
14882 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14883/* end confdefs.h. */
14884
14885 #include <stdbool.h>
14886 #ifndef bool
14887 "error: bool is not defined"
14888 #endif
14889 #ifndef false
14890 "error: false is not defined"
14891 #endif
14892 #if false
14893 "error: false is not 0"
14894 #endif
14895 #ifndef true
14896 "error: true is not defined"
14897 #endif
14898 #if true != 1
14899 "error: true is not 1"
14900 #endif
14901 #ifndef __bool_true_false_are_defined
14902 "error: __bool_true_false_are_defined is not defined"
14903 #endif
14904
14905 struct s { _Bool s: 1; _Bool t; } s;
14906
14907 char a[true == 1 ? 1 : -1];
14908 char b[false == 0 ? 1 : -1];
14909 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
14910 char d[(bool) 0.5 == true ? 1 : -1];
14911 /* See body of main program for 'e'. */
14912 char f[(_Bool) 0.0 == false ? 1 : -1];
14913 char g[true];
14914 char h[sizeof (_Bool)];
14915 char i[sizeof s.t];
14916 enum { j = false, k = true, l = false * true, m = true * 256 };
14917 /* The following fails for
14918 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
14919 _Bool n[m];
14920 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
14921 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
14922 /* Catch a bug in an HP-UX C compiler. See
14923 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
14924 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
14925 */
14926 _Bool q = true;
14927 _Bool *pq = &q;
14928
14929int
14930main (void)
14931{
14932
14933 bool e = &s;
14934 *pq |= q;
14935 *pq |= ! q;
14936 /* Refer to every declared value, to avoid compiler optimizations. */
14937 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
14938 + !m + !n + !o + !p + !q + !pq);
14939
14940 ;
14941 return 0;
14942}
14943_ACEOF
14944if ac_fn_c_try_compile "$LINENO"; then :
14945 ac_cv_header_stdbool_h=yes
14946else
14947 ac_cv_header_stdbool_h=no
14948fi
14949rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14950fi
14951{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
14952$as_echo "$ac_cv_header_stdbool_h" >&6; }
14953 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
14954if test "x$ac_cv_type__Bool" = xyes; then :
14955
14956cat >>confdefs.h <<_ACEOF
14957#define HAVE__BOOL 1
14958_ACEOF
14959
14960
14961fi
14962
14963
14964
14965 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
14966$as_echo_n "checking for unsigned long long int... " >&6; }
14967if ${ac_cv_type_unsigned_long_long_int+:} false; then :
14968 $as_echo_n "(cached) " >&6
14969else
14970 ac_cv_type_unsigned_long_long_int=yes
14971 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
14972 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14973/* end confdefs.h. */
14974
14975 /* For now, do not test the preprocessor; as of 2007 there are too many
14976 implementations with broken preprocessors. Perhaps this can
14977 be revisited in 2012. In the meantime, code should not expect
14978 #if to work with literals wider than 32 bits. */
14979 /* Test literals. */
14980 long long int ll = 9223372036854775807ll;
14981 long long int nll = -9223372036854775807LL;
14982 unsigned long long int ull = 18446744073709551615ULL;
14983 /* Test constant expressions. */
14984 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
14985 ? 1 : -1)];
14986 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
14987 ? 1 : -1)];
14988 int i = 63;
14989int
14990main (void)
14991{
14992/* Test availability of runtime routines for shift and division. */
14993 long long int llmax = 9223372036854775807ll;
14994 unsigned long long int ullmax = 18446744073709551615ull;
14995 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
14996 | (llmax / ll) | (llmax % ll)
14997 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
14998 | (ullmax / ull) | (ullmax % ull));
14999 ;
15000 return 0;
15001}
15002
15003_ACEOF
15004if ac_fn_c_try_link "$LINENO"; then :
15005
15006else
15007 ac_cv_type_unsigned_long_long_int=no
15008fi
15009rm -f core conftest.err conftest.$ac_objext \
15010 conftest$ac_exeext conftest.$ac_ext
15011 fi
15012fi
15013{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
15014$as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
15015 if test $ac_cv_type_unsigned_long_long_int = yes; then
15016
15017$as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
15018
15019 fi
15020
15021
15022
15023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
15024$as_echo_n "checking for long long int... " >&6; }
15025if ${ac_cv_type_long_long_int+:} false; then :
15026 $as_echo_n "(cached) " >&6
15027else
15028 ac_cv_type_long_long_int=yes
15029 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
15030 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
15031 if test $ac_cv_type_long_long_int = yes; then
15032 if test "$cross_compiling" = yes; then :
15033 :
15034else
15035 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15036/* end confdefs.h. */
15037#include <limits.h>
15038 #ifndef LLONG_MAX
15039 # define HALF \
15040 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
15041 # define LLONG_MAX (HALF - 1 + HALF)
15042 #endif
15043int
15044main (void)
15045{
15046long long int n = 1;
15047 int i;
15048 for (i = 0; ; i++)
15049 {
15050 long long int m = n << i;
15051 if (m >> i != n)
15052 return 1;
15053 if (LLONG_MAX / 2 < m)
15054 break;
15055 }
15056 return 0;
15057 ;
15058 return 0;
15059}
15060_ACEOF
15061if ac_fn_c_try_run "$LINENO"; then :
15062
15063else
15064 ac_cv_type_long_long_int=no
15065fi
15066rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15067 conftest.$ac_objext conftest.beam conftest.$ac_ext
15068fi
15069
15070 fi
15071 fi
15072fi
15073{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
15074$as_echo "$ac_cv_type_long_long_int" >&6; }
15075 if test $ac_cv_type_long_long_int = yes; then
15076
15077$as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
15078
15079 fi
15080
15081
15082
15083
15084
15085
15086 if test $ac_cv_type_long_long_int = yes; then
15087 HAVE_LONG_LONG_INT=1
15088 else
15089 HAVE_LONG_LONG_INT=0
15090 fi
15091
15092
15093 if test $ac_cv_type_unsigned_long_long_int = yes; then
15094 HAVE_UNSIGNED_LONG_LONG_INT=1
15095 else
15096 HAVE_UNSIGNED_LONG_LONG_INT=0
15097 fi
15098
15099
15100
15101 if test $ac_cv_header_wchar_h = yes; then
15102 HAVE_WCHAR_H=1
15103 else
15104 HAVE_WCHAR_H=0
15105 fi
15106
15107
15108 if test $ac_cv_header_inttypes_h = yes; then
15109 HAVE_INTTYPES_H=1
15110 else
15111 HAVE_INTTYPES_H=0
15112 fi
15113
15114
15115 if test $ac_cv_header_sys_types_h = yes; then
15116 HAVE_SYS_TYPES_H=1
15117 else
15118 HAVE_SYS_TYPES_H=0
15119 fi
15120
15121
15122
15123
15124
15125
15126
15127
15128
15129
15130
15131 if test $gl_cv_have_include_next = yes; then
15132 gl_cv_next_stdint_h='<'stdint.h'>'
15133 else
15134 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
15135$as_echo_n "checking absolute name of <stdint.h>... " >&6; }
15136if ${gl_cv_next_stdint_h+:} false; then :
15137 $as_echo_n "(cached) " >&6
15138else
15139
15140 if test $ac_cv_header_stdint_h = yes; then
15141
15142
15143 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15144/* end confdefs.h. */
15145#include <stdint.h>
15146
15147_ACEOF
15148 case "$host_os" in
15149 aix*) gl_absname_cpp="$ac_cpp -C" ;;
15150 *) gl_absname_cpp="$ac_cpp" ;;
15151 esac
15152
15153 case "$host_os" in
15154 mingw*)
15155 gl_dirsep_regex='[/\\]'
15156 ;;
15157 *)
15158 gl_dirsep_regex='\/'
15159 ;;
15160 esac
15161 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
15162
15163 gl_header_literal_regex=`echo 'stdint.h' \
15164 | sed -e "$gl_make_literal_regex_sed"`
15165 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
15166 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
15167 s|^/[^/]|//&|
15168 p
15169 q
15170 }'
15171 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
15172 sed -n "$gl_absolute_header_sed"`'"'
15173 else
15174 gl_cv_next_stdint_h='<'stdint.h'>'
15175 fi
15176
15177
15178fi
15179{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
15180$as_echo "$gl_cv_next_stdint_h" >&6; }
15181 fi
15182 NEXT_STDINT_H=$gl_cv_next_stdint_h
15183
15184 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
15185 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
15186 gl_next_as_first_directive='<'stdint.h'>'
15187 else
15188 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
15189 gl_next_as_first_directive=$gl_cv_next_stdint_h
15190 fi
15191 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
15192
15193
15194
15195
15196 if test $ac_cv_header_stdint_h = yes; then
15197 HAVE_STDINT_H=1
15198 else
15199 HAVE_STDINT_H=0
15200 fi
15201
15202
15203 if test $ac_cv_header_stdint_h = yes; then
15204 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
15205$as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
15206if ${gl_cv_header_working_stdint_h+:} false; then :
15207 $as_echo_n "(cached) " >&6
15208else
15209 gl_cv_header_working_stdint_h=no
15210 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15211/* end confdefs.h. */
15212
15213
15214#define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
15215#include <stdint.h>
15216/* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
15217#if !(defined WCHAR_MIN && defined WCHAR_MAX)
15218#error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
15219#endif
15220
15221
15222 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15223 included before <wchar.h>. */
15224 #include <stddef.h>
15225 #include <signal.h>
15226 #if HAVE_WCHAR_H
15227 # include <stdio.h>
15228 # include <time.h>
15229 # include <wchar.h>
15230 #endif
15231
15232
15233#ifdef INT8_MAX
15234int8_t a1 = INT8_MAX;
15235int8_t a1min = INT8_MIN;
15236#endif
15237#ifdef INT16_MAX
15238int16_t a2 = INT16_MAX;
15239int16_t a2min = INT16_MIN;
15240#endif
15241#ifdef INT32_MAX
15242int32_t a3 = INT32_MAX;
15243int32_t a3min = INT32_MIN;
15244#endif
15245#ifdef INT64_MAX
15246int64_t a4 = INT64_MAX;
15247int64_t a4min = INT64_MIN;
15248#endif
15249#ifdef UINT8_MAX
15250uint8_t b1 = UINT8_MAX;
15251#else
15252typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
15253#endif
15254#ifdef UINT16_MAX
15255uint16_t b2 = UINT16_MAX;
15256#endif
15257#ifdef UINT32_MAX
15258uint32_t b3 = UINT32_MAX;
15259#endif
15260#ifdef UINT64_MAX
15261uint64_t b4 = UINT64_MAX;
15262#endif
15263int_least8_t c1 = INT8_C (0x7f);
15264int_least8_t c1max = INT_LEAST8_MAX;
15265int_least8_t c1min = INT_LEAST8_MIN;
15266int_least16_t c2 = INT16_C (0x7fff);
15267int_least16_t c2max = INT_LEAST16_MAX;
15268int_least16_t c2min = INT_LEAST16_MIN;
15269int_least32_t c3 = INT32_C (0x7fffffff);
15270int_least32_t c3max = INT_LEAST32_MAX;
15271int_least32_t c3min = INT_LEAST32_MIN;
15272int_least64_t c4 = INT64_C (0x7fffffffffffffff);
15273int_least64_t c4max = INT_LEAST64_MAX;
15274int_least64_t c4min = INT_LEAST64_MIN;
15275uint_least8_t d1 = UINT8_C (0xff);
15276uint_least8_t d1max = UINT_LEAST8_MAX;
15277uint_least16_t d2 = UINT16_C (0xffff);
15278uint_least16_t d2max = UINT_LEAST16_MAX;
15279uint_least32_t d3 = UINT32_C (0xffffffff);
15280uint_least32_t d3max = UINT_LEAST32_MAX;
15281uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
15282uint_least64_t d4max = UINT_LEAST64_MAX;
15283int_fast8_t e1 = INT_FAST8_MAX;
15284int_fast8_t e1min = INT_FAST8_MIN;
15285int_fast16_t e2 = INT_FAST16_MAX;
15286int_fast16_t e2min = INT_FAST16_MIN;
15287int_fast32_t e3 = INT_FAST32_MAX;
15288int_fast32_t e3min = INT_FAST32_MIN;
15289int_fast64_t e4 = INT_FAST64_MAX;
15290int_fast64_t e4min = INT_FAST64_MIN;
15291uint_fast8_t f1 = UINT_FAST8_MAX;
15292uint_fast16_t f2 = UINT_FAST16_MAX;
15293uint_fast32_t f3 = UINT_FAST32_MAX;
15294uint_fast64_t f4 = UINT_FAST64_MAX;
15295#ifdef INTPTR_MAX
15296intptr_t g = INTPTR_MAX;
15297intptr_t gmin = INTPTR_MIN;
15298#endif
15299#ifdef UINTPTR_MAX
15300uintptr_t h = UINTPTR_MAX;
15301#endif
15302intmax_t i = INTMAX_MAX;
15303uintmax_t j = UINTMAX_MAX;
15304
15305#include <limits.h> /* for CHAR_BIT */
15306#define TYPE_MINIMUM(t) \
15307 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
15308#define TYPE_MAXIMUM(t) \
15309 ((t) ((t) 0 < (t) -1 \
15310 ? (t) -1 \
15311 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
15312struct s {
15313 int check_PTRDIFF:
15314 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
15315 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
15316 ? 1 : -1;
15317 /* Detect bug in FreeBSD 6.0 / ia64. */
15318 int check_SIG_ATOMIC:
15319 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
15320 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
15321 ? 1 : -1;
15322 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
15323 int check_WCHAR:
15324 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
15325 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
15326 ? 1 : -1;
15327 /* Detect bug in mingw. */
15328 int check_WINT:
15329 WINT_MIN == TYPE_MINIMUM (wint_t)
15330 && WINT_MAX == TYPE_MAXIMUM (wint_t)
15331 ? 1 : -1;
15332
15333 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
15334 int check_UINT8_C:
15335 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
15336 int check_UINT16_C:
15337 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
15338
15339 /* Detect bugs in OpenBSD 3.9 stdint.h. */
15340#ifdef UINT8_MAX
15341 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
15342#endif
15343#ifdef UINT16_MAX
15344 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
15345#endif
15346#ifdef UINT32_MAX
15347 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
15348#endif
15349#ifdef UINT64_MAX
15350 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
15351#endif
15352 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
15353 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
15354 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
15355 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
15356 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
15357 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
15358 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
15359 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
15360 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
15361 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
15362 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
15363};
15364
15365int
15366main (void)
15367{
15368
15369 ;
15370 return 0;
15371}
15372_ACEOF
15373if ac_fn_c_try_compile "$LINENO"; then :
15374 if test "$cross_compiling" = yes; then :
15375 gl_cv_header_working_stdint_h=yes
15376
15377else
15378 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15379/* end confdefs.h. */
15380
15381
15382#define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
15383#include <stdint.h>
15384
15385
15386 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15387 included before <wchar.h>. */
15388 #include <stddef.h>
15389 #include <signal.h>
15390 #if HAVE_WCHAR_H
15391 # include <stdio.h>
15392 # include <time.h>
15393 # include <wchar.h>
15394 #endif
15395
15396
15397#include <stdio.h>
15398#include <string.h>
15399#define MVAL(macro) MVAL1(macro)
15400#define MVAL1(expression) #expression
15401static const char *macro_values[] =
15402 {
15403#ifdef INT8_MAX
15404 MVAL (INT8_MAX),
15405#endif
15406#ifdef INT16_MAX
15407 MVAL (INT16_MAX),
15408#endif
15409#ifdef INT32_MAX
15410 MVAL (INT32_MAX),
15411#endif
15412#ifdef INT64_MAX
15413 MVAL (INT64_MAX),
15414#endif
15415#ifdef UINT8_MAX
15416 MVAL (UINT8_MAX),
15417#endif
15418#ifdef UINT16_MAX
15419 MVAL (UINT16_MAX),
15420#endif
15421#ifdef UINT32_MAX
15422 MVAL (UINT32_MAX),
15423#endif
15424#ifdef UINT64_MAX
15425 MVAL (UINT64_MAX),
15426#endif
15427 NULL
15428 };
15429
15430int
15431main (void)
15432{
15433
15434 const char **mv;
15435 for (mv = macro_values; *mv != NULL; mv++)
15436 {
15437 const char *value = *mv;
15438 /* Test whether it looks like a cast expression. */
15439 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
15440 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
15441 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
15442 || strncmp (value, "((int)"/*)*/, 6) == 0
15443 || strncmp (value, "((signed short)"/*)*/, 15) == 0
15444 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
15445 return mv - macro_values + 1;
15446 }
15447 return 0;
15448
15449 ;
15450 return 0;
15451}
15452_ACEOF
15453if ac_fn_c_try_run "$LINENO"; then :
15454 gl_cv_header_working_stdint_h=yes
15455fi
15456rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15457 conftest.$ac_objext conftest.beam conftest.$ac_ext
15458fi
15459
15460
15461fi
15462rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15463
15464fi
15465{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
15466$as_echo "$gl_cv_header_working_stdint_h" >&6; }
15467 fi
15468 if test "$gl_cv_header_working_stdint_h" = yes; then
15469 STDINT_H=
15470 else
15471 for ac_header in sys/inttypes.h sys/bitypes.h
15472do :
15473 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
15474ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
15475if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
15476 cat >>confdefs.h <<_ACEOF
15477#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
15478_ACEOF
15479
15480fi
15481
15482done
15483
15484 if test $ac_cv_header_sys_inttypes_h = yes; then
15485 HAVE_SYS_INTTYPES_H=1
15486 else
15487 HAVE_SYS_INTTYPES_H=0
15488 fi
15489
15490 if test $ac_cv_header_sys_bitypes_h = yes; then
15491 HAVE_SYS_BITYPES_H=1
15492 else
15493 HAVE_SYS_BITYPES_H=0
15494 fi
15495
15496
15497
15498
15499 if test $APPLE_UNIVERSAL_BUILD = 0; then
15500
15501
15502 for gltype in ptrdiff_t size_t ; do
15503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
15504$as_echo_n "checking for bit size of $gltype... " >&6; }
15505if eval \${gl_cv_bitsizeof_${gltype}+:} false; then :
15506 $as_echo_n "(cached) " >&6
15507else
15508 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
15509 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15510 included before <wchar.h>. */
15511 #include <stddef.h>
15512 #include <signal.h>
15513 #if HAVE_WCHAR_H
15514 # include <stdio.h>
15515 # include <time.h>
15516 # include <wchar.h>
15517 #endif
15518
15519#include <limits.h>"; then :
15520
15521else
15522 result=unknown
15523fi
15524
15525 eval gl_cv_bitsizeof_${gltype}=\$result
15526
15527fi
15528eval ac_res=\$gl_cv_bitsizeof_${gltype}
15529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15530$as_echo "$ac_res" >&6; }
15531 eval result=\$gl_cv_bitsizeof_${gltype}
15532 if test $result = unknown; then
15533 result=0
15534 fi
15535 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
15536 cat >>confdefs.h <<_ACEOF
15537#define BITSIZEOF_${GLTYPE} $result
15538_ACEOF
15539
15540 eval BITSIZEOF_${GLTYPE}=\$result
15541 done
15542
15543
15544 fi
15545
15546
15547 for gltype in sig_atomic_t wchar_t wint_t ; do
15548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
15549$as_echo_n "checking for bit size of $gltype... " >&6; }
15550if eval \${gl_cv_bitsizeof_${gltype}+:} false; then :
15551 $as_echo_n "(cached) " >&6
15552else
15553 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
15554 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15555 included before <wchar.h>. */
15556 #include <stddef.h>
15557 #include <signal.h>
15558 #if HAVE_WCHAR_H
15559 # include <stdio.h>
15560 # include <time.h>
15561 # include <wchar.h>
15562 #endif
15563
15564#include <limits.h>"; then :
15565
15566else
15567 result=unknown
15568fi
15569
15570 eval gl_cv_bitsizeof_${gltype}=\$result
15571
15572fi
15573eval ac_res=\$gl_cv_bitsizeof_${gltype}
15574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15575$as_echo "$ac_res" >&6; }
15576 eval result=\$gl_cv_bitsizeof_${gltype}
15577 if test $result = unknown; then
15578 result=0
15579 fi
15580 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
15581 cat >>confdefs.h <<_ACEOF
15582#define BITSIZEOF_${GLTYPE} $result
15583_ACEOF
15584
15585 eval BITSIZEOF_${GLTYPE}=\$result
15586 done
15587
15588
15589
15590
15591 for gltype in sig_atomic_t wchar_t wint_t ; do
15592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
15593$as_echo_n "checking whether $gltype is signed... " >&6; }
15594if eval \${gl_cv_type_${gltype}_signed+:} false; then :
15595 $as_echo_n "(cached) " >&6
15596else
15597 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15598/* end confdefs.h. */
15599
15600 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15601 included before <wchar.h>. */
15602 #include <stddef.h>
15603 #include <signal.h>
15604 #if HAVE_WCHAR_H
15605 # include <stdio.h>
15606 # include <time.h>
15607 # include <wchar.h>
15608 #endif
15609
15610 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
15611int
15612main (void)
15613{
15614
15615 ;
15616 return 0;
15617}
15618_ACEOF
15619if ac_fn_c_try_compile "$LINENO"; then :
15620 result=yes
15621else
15622 result=no
15623fi
15624rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15625 eval gl_cv_type_${gltype}_signed=\$result
15626
15627fi
15628eval ac_res=\$gl_cv_type_${gltype}_signed
15629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15630$as_echo "$ac_res" >&6; }
15631 eval result=\$gl_cv_type_${gltype}_signed
15632 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
15633 if test "$result" = yes; then
15634 cat >>confdefs.h <<_ACEOF
15635#define HAVE_SIGNED_${GLTYPE} 1
15636_ACEOF
15637
15638 eval HAVE_SIGNED_${GLTYPE}=1
15639 else
15640 eval HAVE_SIGNED_${GLTYPE}=0
15641 fi
15642 done
15643
15644
15645 gl_cv_type_ptrdiff_t_signed=yes
15646 gl_cv_type_size_t_signed=no
15647 if test $APPLE_UNIVERSAL_BUILD = 0; then
15648
15649
15650 for gltype in ptrdiff_t size_t ; do
15651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
15652$as_echo_n "checking for $gltype integer literal suffix... " >&6; }
15653if eval \${gl_cv_type_${gltype}_suffix+:} false; then :
15654 $as_echo_n "(cached) " >&6
15655else
15656 eval gl_cv_type_${gltype}_suffix=no
15657 eval result=\$gl_cv_type_${gltype}_signed
15658 if test "$result" = yes; then
15659 glsufu=
15660 else
15661 glsufu=u
15662 fi
15663 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
15664 case $glsuf in
15665 '') gltype1='int';;
15666 l) gltype1='long int';;
15667 ll) gltype1='long long int';;
15668 i64) gltype1='__int64';;
15669 u) gltype1='unsigned int';;
15670 ul) gltype1='unsigned long int';;
15671 ull) gltype1='unsigned long long int';;
15672 ui64)gltype1='unsigned __int64';;
15673 esac
15674 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15675/* end confdefs.h. */
15676
15677 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15678 included before <wchar.h>. */
15679 #include <stddef.h>
15680 #include <signal.h>
15681 #if HAVE_WCHAR_H
15682 # include <stdio.h>
15683 # include <time.h>
15684 # include <wchar.h>
15685 #endif
15686
15687 extern $gltype foo;
15688 extern $gltype1 foo;
15689int
15690main (void)
15691{
15692
15693 ;
15694 return 0;
15695}
15696_ACEOF
15697if ac_fn_c_try_compile "$LINENO"; then :
15698 eval gl_cv_type_${gltype}_suffix=\$glsuf
15699fi
15700rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15701 eval result=\$gl_cv_type_${gltype}_suffix
15702 test "$result" != no && break
15703 done
15704fi
15705eval ac_res=\$gl_cv_type_${gltype}_suffix
15706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15707$as_echo "$ac_res" >&6; }
15708 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
15709 eval result=\$gl_cv_type_${gltype}_suffix
15710 test "$result" = no && result=
15711 eval ${GLTYPE}_SUFFIX=\$result
15712 cat >>confdefs.h <<_ACEOF
15713#define ${GLTYPE}_SUFFIX $result
15714_ACEOF
15715
15716 done
15717
15718
15719 fi
15720
15721
15722 for gltype in sig_atomic_t wchar_t wint_t ; do
15723 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
15724$as_echo_n "checking for $gltype integer literal suffix... " >&6; }
15725if eval \${gl_cv_type_${gltype}_suffix+:} false; then :
15726 $as_echo_n "(cached) " >&6
15727else
15728 eval gl_cv_type_${gltype}_suffix=no
15729 eval result=\$gl_cv_type_${gltype}_signed
15730 if test "$result" = yes; then
15731 glsufu=
15732 else
15733 glsufu=u
15734 fi
15735 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
15736 case $glsuf in
15737 '') gltype1='int';;
15738 l) gltype1='long int';;
15739 ll) gltype1='long long int';;
15740 i64) gltype1='__int64';;
15741 u) gltype1='unsigned int';;
15742 ul) gltype1='unsigned long int';;
15743 ull) gltype1='unsigned long long int';;
15744 ui64)gltype1='unsigned __int64';;
15745 esac
15746 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15747/* end confdefs.h. */
15748
15749 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15750 included before <wchar.h>. */
15751 #include <stddef.h>
15752 #include <signal.h>
15753 #if HAVE_WCHAR_H
15754 # include <stdio.h>
15755 # include <time.h>
15756 # include <wchar.h>
15757 #endif
15758
15759 extern $gltype foo;
15760 extern $gltype1 foo;
15761int
15762main (void)
15763{
15764
15765 ;
15766 return 0;
15767}
15768_ACEOF
15769if ac_fn_c_try_compile "$LINENO"; then :
15770 eval gl_cv_type_${gltype}_suffix=\$glsuf
15771fi
15772rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15773 eval result=\$gl_cv_type_${gltype}_suffix
15774 test "$result" != no && break
15775 done
15776fi
15777eval ac_res=\$gl_cv_type_${gltype}_suffix
15778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15779$as_echo "$ac_res" >&6; }
15780 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
15781 eval result=\$gl_cv_type_${gltype}_suffix
15782 test "$result" = no && result=
15783 eval ${GLTYPE}_SUFFIX=\$result
15784 cat >>confdefs.h <<_ACEOF
15785#define ${GLTYPE}_SUFFIX $result
15786_ACEOF
15787
15788 done
15789
15790
15791
15792 if test $BITSIZEOF_WINT_T -lt 32; then
15793 BITSIZEOF_WINT_T=32
15794 fi
15795
15796 STDINT_H=stdint.h
15797 fi
15798
15799 if test -n "$STDINT_H"; then
15800 GL_GENERATE_STDINT_H_TRUE=
15801 GL_GENERATE_STDINT_H_FALSE='#'
15802else
15803 GL_GENERATE_STDINT_H_TRUE='#'
15804 GL_GENERATE_STDINT_H_FALSE=
15805fi
15806
15807
15808
15809 GNULIB_FFS=0;
15810 HAVE_FFS=1;
15811 HAVE_STRCASECMP=1;
15812 HAVE_DECL_STRNCASECMP=1;
15813
15814
15815 REPLACE_STRERROR_0=0
15816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror(0) succeeds" >&5
15817$as_echo_n "checking whether strerror(0) succeeds... " >&6; }
15818if ${gl_cv_func_strerror_0_works+:} false; then :
15819 $as_echo_n "(cached) " >&6
15820else
15821 if test "$cross_compiling" = yes; then :
15822 case "$host_os" in
15823 # Guess yes on glibc systems.
15824 *-gnu*) gl_cv_func_strerror_0_works="guessing yes" ;;
15825 # If we don't know, assume the worst.
15826 *) gl_cv_func_strerror_0_works="guessing no" ;;
15827 esac
15828
15829else
15830 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15831/* end confdefs.h. */
15832#include <string.h>
15833 #include <errno.h>
15834
15835int
15836main (void)
15837{
15838int result = 0;
15839 char *str;
15840 errno = 0;
15841 str = strerror (0);
15842 if (!*str) result |= 1;
15843 if (errno) result |= 2;
15844 if (strstr (str, "nknown") || strstr (str, "ndefined"))
15845 result |= 4;
15846 return result;
15847 ;
15848 return 0;
15849}
15850_ACEOF
15851if ac_fn_c_try_run "$LINENO"; then :
15852 gl_cv_func_strerror_0_works=yes
15853else
15854 gl_cv_func_strerror_0_works=no
15855fi
15856rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15857 conftest.$ac_objext conftest.beam conftest.$ac_ext
15858fi
15859
15860
15861fi
15862{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strerror_0_works" >&5
15863$as_echo "$gl_cv_func_strerror_0_works" >&6; }
15864 case "$gl_cv_func_strerror_0_works" in
15865 *yes) ;;
15866 *)
15867 REPLACE_STRERROR_0=1
15868
15869$as_echo "#define REPLACE_STRERROR_0 1" >>confdefs.h
15870
15871 ;;
15872 esac
15873
15874
15875
15876
15877
15878
15879
15880
15881
15882
15883
15884
15885
15886
15887 if test $gl_cv_have_include_next = yes; then
15888 gl_cv_next_string_h='<'string.h'>'
15889 else
15890 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <string.h>" >&5
15891$as_echo_n "checking absolute name of <string.h>... " >&6; }
15892if ${gl_cv_next_string_h+:} false; then :
15893 $as_echo_n "(cached) " >&6
15894else
15895
15896 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15897/* end confdefs.h. */
15898#include <string.h>
15899
15900_ACEOF
15901 case "$host_os" in
15902 aix*) gl_absname_cpp="$ac_cpp -C" ;;
15903 *) gl_absname_cpp="$ac_cpp" ;;
15904 esac
15905
15906 case "$host_os" in
15907 mingw*)
15908 gl_dirsep_regex='[/\\]'
15909 ;;
15910 *)
15911 gl_dirsep_regex='\/'
15912 ;;
15913 esac
15914 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
15915
15916 gl_header_literal_regex=`echo 'string.h' \
15917 | sed -e "$gl_make_literal_regex_sed"`
15918 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
15919 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
15920 s|^/[^/]|//&|
15921 p
15922 q
15923 }'
15924 gl_cv_next_string_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
15925 sed -n "$gl_absolute_header_sed"`'"'
15926
15927
15928fi
15929{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_string_h" >&5
15930$as_echo "$gl_cv_next_string_h" >&6; }
15931 fi
15932 NEXT_STRING_H=$gl_cv_next_string_h
15933
15934 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
15935 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
15936 gl_next_as_first_directive='<'string.h'>'
15937 else
15938 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
15939 gl_next_as_first_directive=$gl_cv_next_string_h
15940 fi
15941 NEXT_AS_FIRST_DIRECTIVE_STRING_H=$gl_next_as_first_directive
15942
15943
15944
15945
15946
15947
15948 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
15949 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
15950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
15951$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
15952if eval \${$as_gl_Symbol+:} false; then :
15953 $as_echo_n "(cached) " >&6
15954else
15955 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15956/* end confdefs.h. */
15957#include <string.h>
15958
15959int
15960main (void)
15961{
15962#undef $gl_func
15963 (void) $gl_func;
15964 ;
15965 return 0;
15966}
15967_ACEOF
15968if ac_fn_c_try_compile "$LINENO"; then :
15969 eval "$as_gl_Symbol=yes"
15970else
15971 eval "$as_gl_Symbol=no"
15972fi
15973rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15974fi
15975eval ac_res=\$$as_gl_Symbol
15976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15977$as_echo "$ac_res" >&6; }
15978 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
15979 cat >>confdefs.h <<_ACEOF
15980#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
15981_ACEOF
15982
15983 eval ac_cv_have_decl_$gl_func=yes
15984fi
15985 done
15986
15987
15988
15989
15990
15991
15992
15993
15994
15995
15996
15997
15998
15999
16000
16001
16002 if test $gl_cv_have_include_next = yes; then
16003 gl_cv_next_strings_h='<'strings.h'>'
16004 else
16005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <strings.h>" >&5
16006$as_echo_n "checking absolute name of <strings.h>... " >&6; }
16007if ${gl_cv_next_strings_h+:} false; then :
16008 $as_echo_n "(cached) " >&6
16009else
16010
16011 if test $ac_cv_header_strings_h = yes; then
16012
16013
16014 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16015/* end confdefs.h. */
16016#include <strings.h>
16017
16018_ACEOF
16019 case "$host_os" in
16020 aix*) gl_absname_cpp="$ac_cpp -C" ;;
16021 *) gl_absname_cpp="$ac_cpp" ;;
16022 esac
16023
16024 case "$host_os" in
16025 mingw*)
16026 gl_dirsep_regex='[/\\]'
16027 ;;
16028 *)
16029 gl_dirsep_regex='\/'
16030 ;;
16031 esac
16032 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
16033
16034 gl_header_literal_regex=`echo 'strings.h' \
16035 | sed -e "$gl_make_literal_regex_sed"`
16036 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
16037 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
16038 s|^/[^/]|//&|
16039 p
16040 q
16041 }'
16042 gl_cv_next_strings_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
16043 sed -n "$gl_absolute_header_sed"`'"'
16044 else
16045 gl_cv_next_strings_h='<'strings.h'>'
16046 fi
16047
16048
16049fi
16050{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_strings_h" >&5
16051$as_echo "$gl_cv_next_strings_h" >&6; }
16052 fi
16053 NEXT_STRINGS_H=$gl_cv_next_strings_h
16054
16055 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
16056 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
16057 gl_next_as_first_directive='<'strings.h'>'
16058 else
16059 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
16060 gl_next_as_first_directive=$gl_cv_next_strings_h
16061 fi
16062 NEXT_AS_FIRST_DIRECTIVE_STRINGS_H=$gl_next_as_first_directive
16063
16064
16065
16066
16067 if test $ac_cv_header_strings_h = yes; then
16068 HAVE_STRINGS_H=1
16069 else
16070 HAVE_STRINGS_H=0
16071 fi
16072
16073
16074
16075 for gl_func in ffs strcasecmp strncasecmp; do
16076 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
16077 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
16078$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
16079if eval \${$as_gl_Symbol+:} false; then :
16080 $as_echo_n "(cached) " >&6
16081else
16082 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16083/* end confdefs.h. */
16084
16085 /* Minix 3.1.8 has a bug: <sys/types.h> must be included before
16086 <strings.h>. */
16087 #include <sys/types.h>
16088 #include <strings.h>
16089
16090int
16091main (void)
16092{
16093#undef $gl_func
16094 (void) $gl_func;
16095 ;
16096 return 0;
16097}
16098_ACEOF
16099if ac_fn_c_try_compile "$LINENO"; then :
16100 eval "$as_gl_Symbol=yes"
16101else
16102 eval "$as_gl_Symbol=no"
16103fi
16104rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16105fi
16106eval ac_res=\$$as_gl_Symbol
16107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
16108$as_echo "$ac_res" >&6; }
16109 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
16110 cat >>confdefs.h <<_ACEOF
16111#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
16112_ACEOF
16113
16114 eval ac_cv_have_decl_$gl_func=yes
16115fi
16116 done
16117
16118
16119ac_fn_c_check_decl "$LINENO" "strndup" "ac_cv_have_decl_strndup" "$ac_includes_default"
16120if test "x$ac_cv_have_decl_strndup" = xyes; then :
16121 ac_have_decl=1
16122else
16123 ac_have_decl=0
16124fi
16125
16126cat >>confdefs.h <<_ACEOF
16127#define HAVE_DECL_STRNDUP $ac_have_decl
16128_ACEOF
16129
16130
16131
16132ac_fn_c_check_decl "$LINENO" "strnlen" "ac_cv_have_decl_strnlen" "$ac_includes_default"
16133if test "x$ac_cv_have_decl_strnlen" = xyes; then :
16134 ac_have_decl=1
16135else
16136 ac_have_decl=0
16137fi
16138
16139cat >>confdefs.h <<_ACEOF
16140#define HAVE_DECL_STRNLEN $ac_have_decl
16141_ACEOF
16142
16143
16144
16145ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
16146if test "x$ac_cv_type_pid_t" = xyes; then :
16147
16148else
16149
16150cat >>confdefs.h <<_ACEOF
16151#define pid_t int
16152_ACEOF
16153
16154fi
16155
16156ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
16157if test "x$ac_cv_type_mode_t" = xyes; then :
16158
16159else
16160
16161cat >>confdefs.h <<_ACEOF
16162#define mode_t int
16163_ACEOF
16164
16165fi
16166
16167
16168
16169 WINDOWS_64_BIT_OFF_T=0
16170
16171
16172
16173
16174
16175
16176
16177
16178
16179
16180
16181
16182
16183 if test $gl_cv_have_include_next = yes; then
16184 gl_cv_next_sys_types_h='<'sys/types.h'>'
16185 else
16186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/types.h>" >&5
16187$as_echo_n "checking absolute name of <sys/types.h>... " >&6; }
16188if ${gl_cv_next_sys_types_h+:} false; then :
16189 $as_echo_n "(cached) " >&6
16190else
16191
16192 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16193/* end confdefs.h. */
16194#include <sys/types.h>
16195
16196_ACEOF
16197 case "$host_os" in
16198 aix*) gl_absname_cpp="$ac_cpp -C" ;;
16199 *) gl_absname_cpp="$ac_cpp" ;;
16200 esac
16201
16202 case "$host_os" in
16203 mingw*)
16204 gl_dirsep_regex='[/\\]'
16205 ;;
16206 *)
16207 gl_dirsep_regex='\/'
16208 ;;
16209 esac
16210 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
16211
16212 gl_header_literal_regex=`echo 'sys/types.h' \
16213 | sed -e "$gl_make_literal_regex_sed"`
16214 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
16215 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
16216 s|^/[^/]|//&|
16217 p
16218 q
16219 }'
16220 gl_cv_next_sys_types_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
16221 sed -n "$gl_absolute_header_sed"`'"'
16222
16223
16224fi
16225{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_types_h" >&5
16226$as_echo "$gl_cv_next_sys_types_h" >&6; }
16227 fi
16228 NEXT_SYS_TYPES_H=$gl_cv_next_sys_types_h
16229
16230 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
16231 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
16232 gl_next_as_first_directive='<'sys/types.h'>'
16233 else
16234 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
16235 gl_next_as_first_directive=$gl_cv_next_sys_types_h
16236 fi
16237 NEXT_AS_FIRST_DIRECTIVE_SYS_TYPES_H=$gl_next_as_first_directive
16238
16239
16240
16241
16242
16243
16244
16245
16246
16247
16248
16249
16250
16251
16252
16253
16254
16255
16256
16257gl_libunistring_sed_extract_major='/^[0-9]/{s/^\([0-9]*\).*/\1/p;q;}
16258i\
162590
16260q
16261'
16262gl_libunistring_sed_extract_minor='/^[0-9][0-9]*[.][0-9]/{s/^[0-9]*[.]\([0-9]*\).*/\1/p;q;}
16263i\
162640
16265q
16266'
16267gl_libunistring_sed_extract_subminor='/^[0-9][0-9]*[.][0-9][0-9]*[.][0-9]/{s/^[0-9]*[.][0-9]*[.]\([0-9]*\).*/\1/p;q;}
16268i\
162690
16270q
16271'
16272
16273
16274 if test "$HAVE_LIBUNISTRING" = yes; then
16275 LIBUNISTRING_VERSION_MAJOR=`echo "$LIBUNISTRING_VERSION" | sed -n -e "$gl_libunistring_sed_extract_major"`
16276 LIBUNISTRING_VERSION_MINOR=`echo "$LIBUNISTRING_VERSION" | sed -n -e "$gl_libunistring_sed_extract_minor"`
16277 LIBUNISTRING_VERSION_SUBMINOR=`echo "$LIBUNISTRING_VERSION" | sed -n -e "$gl_libunistring_sed_extract_subminor"`
16278 fi
16279
16280
16281
16282
16283 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wint_t" >&5
16284$as_echo_n "checking for wint_t... " >&6; }
16285if ${gt_cv_c_wint_t+:} false; then :
16286 $as_echo_n "(cached) " >&6
16287else
16288 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16289/* end confdefs.h. */
16290
16291/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
16292 <wchar.h>.
16293 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
16294 before <wchar.h>. */
16295#include <stddef.h>
16296#include <stdio.h>
16297#include <time.h>
16298#include <wchar.h>
16299 wint_t foo = (wchar_t)'\0';
16300int
16301main (void)
16302{
16303
16304 ;
16305 return 0;
16306}
16307_ACEOF
16308if ac_fn_c_try_compile "$LINENO"; then :
16309 gt_cv_c_wint_t=yes
16310else
16311 gt_cv_c_wint_t=no
16312fi
16313rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16314fi
16315{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wint_t" >&5
16316$as_echo "$gt_cv_c_wint_t" >&6; }
16317 if test $gt_cv_c_wint_t = yes; then
16318
16319$as_echo "#define HAVE_WINT_T 1" >>confdefs.h
16320
16321 fi
16322
16323
16324
16325 if test $ac_cv_header_features_h = yes; then
16326 HAVE_FEATURES_H=1
16327 else
16328 HAVE_FEATURES_H=0
16329 fi
16330
16331
16332
16333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inttypes.h" >&5
16334$as_echo_n "checking for inttypes.h... " >&6; }
16335if ${gl_cv_header_inttypes_h+:} false; then :
16336 $as_echo_n "(cached) " >&6
16337else
16338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16339/* end confdefs.h. */
16340
16341#include <sys/types.h>
16342#include <inttypes.h>
16343
16344int
16345main (void)
16346{
16347uintmax_t i = (uintmax_t) -1; return !i;
16348 ;
16349 return 0;
16350}
16351_ACEOF
16352if ac_fn_c_try_compile "$LINENO"; then :
16353 gl_cv_header_inttypes_h=yes
16354else
16355 gl_cv_header_inttypes_h=no
16356fi
16357rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16358fi
16359{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_inttypes_h" >&5
16360$as_echo "$gl_cv_header_inttypes_h" >&6; }
16361 if test $gl_cv_header_inttypes_h = yes; then
16362
16363cat >>confdefs.h <<_ACEOF
16364#define HAVE_INTTYPES_H_WITH_UINTMAX 1
16365_ACEOF
16366
16367 fi
16368
16369
16370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdint.h" >&5
16371$as_echo_n "checking for stdint.h... " >&6; }
16372if ${gl_cv_header_stdint_h+:} false; then :
16373 $as_echo_n "(cached) " >&6
16374else
16375 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16376/* end confdefs.h. */
16377#include <sys/types.h>
16378 #include <stdint.h>
16379int
16380main (void)
16381{
16382uintmax_t i = (uintmax_t) -1; return !i;
16383 ;
16384 return 0;
16385}
16386_ACEOF
16387if ac_fn_c_try_compile "$LINENO"; then :
16388 gl_cv_header_stdint_h=yes
16389else
16390 gl_cv_header_stdint_h=no
16391fi
16392rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16393fi
16394{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_stdint_h" >&5
16395$as_echo "$gl_cv_header_stdint_h" >&6; }
16396 if test $gl_cv_header_stdint_h = yes; then
16397
16398cat >>confdefs.h <<_ACEOF
16399#define HAVE_STDINT_H_WITH_UINTMAX 1
16400_ACEOF
16401
16402 fi
16403
16404
16405
16406
16407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for intmax_t" >&5
16408$as_echo_n "checking for intmax_t... " >&6; }
16409if ${gt_cv_c_intmax_t+:} false; then :
16410 $as_echo_n "(cached) " >&6
16411else
16412 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16413/* end confdefs.h. */
16414
16415#include <stddef.h>
16416#include <stdlib.h>
16417#if HAVE_STDINT_H_WITH_UINTMAX
16418#include <stdint.h>
16419#endif
16420#if HAVE_INTTYPES_H_WITH_UINTMAX
16421#include <inttypes.h>
16422#endif
16423
16424int
16425main (void)
16426{
16427intmax_t x = -1; return !x;
16428 ;
16429 return 0;
16430}
16431_ACEOF
16432if ac_fn_c_try_compile "$LINENO"; then :
16433 gt_cv_c_intmax_t=yes
16434else
16435 gt_cv_c_intmax_t=no
16436fi
16437rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16438fi
16439{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_intmax_t" >&5
16440$as_echo "$gt_cv_c_intmax_t" >&6; }
16441 if test $gt_cv_c_intmax_t = yes; then
16442
16443$as_echo "#define HAVE_INTMAX_T 1" >>confdefs.h
16444
16445 else
16446
16447 test $ac_cv_type_long_long_int = yes \
16448 && ac_type='long long' \
16449 || ac_type='long'
16450
16451cat >>confdefs.h <<_ACEOF
16452#define intmax_t $ac_type
16453_ACEOF
16454
16455 fi
16456
16457
16458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'double'" >&5
16459$as_echo_n "checking where to find the exponent in a 'double'... " >&6; }
16460if ${gl_cv_cc_double_expbit0+:} false; then :
16461 $as_echo_n "(cached) " >&6
16462else
16463
16464 if test "$cross_compiling" = yes; then :
16465
16466 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16467/* end confdefs.h. */
16468
16469#if defined arm || defined __arm || defined __arm__
16470 mixed_endianness
16471#endif
16472
16473_ACEOF
16474if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16475 $EGREP "mixed_endianness" >/dev/null 2>&1; then :
16476 gl_cv_cc_double_expbit0="unknown"
16477else
16478
16479 :
16480if ${ac_cv_c_bigendian+:} false; then :
16481 $as_echo_n "(cached) " >&6
16482else
16483 ac_cv_c_bigendian=unknown
16484 # See if we're dealing with a universal compiler.
16485 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16486/* end confdefs.h. */
16487#ifndef __APPLE_CC__
16488 not a universal capable compiler
16489 #endif
16490 typedef int dummy;
16491
16492_ACEOF
16493if ac_fn_c_try_compile "$LINENO"; then :
16494
16495 # Check for potential -arch flags. It is not universal unless
16496 # there are at least two -arch flags with different values.
16497 ac_arch=
16498 ac_prev=
16499 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
16500 if test -n "$ac_prev"; then
16501 case $ac_word in
16502 i?86 | x86_64 | ppc | ppc64)
16503 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
16504 ac_arch=$ac_word
16505 else
16506 ac_cv_c_bigendian=universal
16507 break
16508 fi
16509 ;;
16510 esac
16511 ac_prev=
16512 elif test "x$ac_word" = "x-arch"; then
16513 ac_prev=arch
16514 fi
16515 done
16516fi
16517rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16518 if test $ac_cv_c_bigendian = unknown; then
16519 # See if sys/param.h defines the BYTE_ORDER macro.
16520 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16521/* end confdefs.h. */
16522#include <sys/types.h>
16523 #include <sys/param.h>
16524
16525int
16526main (void)
16527{
16528#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
16529 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
16530 && LITTLE_ENDIAN)
16531 bogus endian macros
16532 #endif
16533
16534 ;
16535 return 0;
16536}
16537_ACEOF
16538if ac_fn_c_try_compile "$LINENO"; then :
16539 # It does; now see whether it defined to BIG_ENDIAN or not.
16540 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16541/* end confdefs.h. */
16542#include <sys/types.h>
16543 #include <sys/param.h>
16544
16545int
16546main (void)
16547{
16548#if BYTE_ORDER != BIG_ENDIAN
16549 not big endian
16550 #endif
16551
16552 ;
16553 return 0;
16554}
16555_ACEOF
16556if ac_fn_c_try_compile "$LINENO"; then :
16557 ac_cv_c_bigendian=yes
16558else
16559 ac_cv_c_bigendian=no
16560fi
16561rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16562fi
16563rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16564 fi
16565 if test $ac_cv_c_bigendian = unknown; then
16566 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
16567 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16568/* end confdefs.h. */
16569#include <limits.h>
16570
16571int
16572main (void)
16573{
16574#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
16575 bogus endian macros
16576 #endif
16577
16578 ;
16579 return 0;
16580}
16581_ACEOF
16582if ac_fn_c_try_compile "$LINENO"; then :
16583 # It does; now see whether it defined to _BIG_ENDIAN or not.
16584 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16585/* end confdefs.h. */
16586#include <limits.h>
16587
16588int
16589main (void)
16590{
16591#ifndef _BIG_ENDIAN
16592 not big endian
16593 #endif
16594
16595 ;
16596 return 0;
16597}
16598_ACEOF
16599if ac_fn_c_try_compile "$LINENO"; then :
16600 ac_cv_c_bigendian=yes
16601else
16602 ac_cv_c_bigendian=no
16603fi
16604rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16605fi
16606rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16607 fi
16608 if test $ac_cv_c_bigendian = unknown; then
16609 # Compile a test program.
16610 if test "$cross_compiling" = yes; then :
16611 # Try to guess by grepping values from an object file.
16612 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16613/* end confdefs.h. */
16614short int ascii_mm[] =
16615 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
16616 short int ascii_ii[] =
16617 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
16618 int use_ascii (int i) {
16619 return ascii_mm[i] + ascii_ii[i];
16620 }
16621 short int ebcdic_ii[] =
16622 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
16623 short int ebcdic_mm[] =
16624 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
16625 int use_ebcdic (int i) {
16626 return ebcdic_mm[i] + ebcdic_ii[i];
16627 }
16628 extern int foo;
16629
16630int
16631main (void)
16632{
16633return use_ascii (foo) == use_ebcdic (foo);
16634 ;
16635 return 0;
16636}
16637_ACEOF
16638if ac_fn_c_try_compile "$LINENO"; then :
16639 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
16640 ac_cv_c_bigendian=yes
16641 fi
16642 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
16643 if test "$ac_cv_c_bigendian" = unknown; then
16644 ac_cv_c_bigendian=no
16645 else
16646 # finding both strings is unlikely to happen, but who knows?
16647 ac_cv_c_bigendian=unknown
16648 fi
16649 fi
16650fi
16651rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16652else
16653 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16654/* end confdefs.h. */
16655$ac_includes_default
16656int
16657main (void)
16658{
16659
16660 /* Are we little or big endian? From Harbison&Steele. */
16661 union
16662 {
16663 long int l;
16664 char c[sizeof (long int)];
16665 } u;
16666 u.l = 1;
16667 return u.c[sizeof (long int) - 1] == 1;
16668
16669 ;
16670 return 0;
16671}
16672_ACEOF
16673if ac_fn_c_try_run "$LINENO"; then :
16674 ac_cv_c_bigendian=no
16675else
16676 ac_cv_c_bigendian=yes
16677fi
16678rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16679 conftest.$ac_objext conftest.beam conftest.$ac_ext
16680fi
16681
16682 fi
16683fi
16684:
16685 case $ac_cv_c_bigendian in #(
16686 yes)
16687 gl_cv_cc_double_expbit0="word 0 bit 20";; #(
16688 no)
16689 gl_cv_cc_double_expbit0="word 1 bit 20" ;; #(
16690 universal)
16691
16692$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
16693
16694 ;; #(
16695 *)
16696 gl_cv_cc_double_expbit0="unknown" ;;
16697 esac
16698
16699
16700fi
16701rm -f conftest*
16702
16703
16704else
16705 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16706/* end confdefs.h. */
16707
16708#include <float.h>
16709#include <stddef.h>
16710#include <stdio.h>
16711#include <string.h>
16712#define NWORDS \
16713 ((sizeof (double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
16714typedef union { double value; unsigned int word[NWORDS]; } memory_double;
16715static unsigned int ored_words[NWORDS];
16716static unsigned int anded_words[NWORDS];
16717static void add_to_ored_words (double x)
16718{
16719 memory_double m;
16720 size_t i;
16721 /* Clear it first, in case sizeof (double) < sizeof (memory_double). */
16722 memset (&m, 0, sizeof (memory_double));
16723 m.value = x;
16724 for (i = 0; i < NWORDS; i++)
16725 {
16726 ored_words[i] |= m.word[i];
16727 anded_words[i] &= m.word[i];
16728 }
16729}
16730int main ()
16731{
16732 size_t j;
16733 FILE *fp = fopen ("conftest.out", "w");
16734 if (fp == NULL)
16735 return 1;
16736 for (j = 0; j < NWORDS; j++)
16737 anded_words[j] = ~ (unsigned int) 0;
16738 add_to_ored_words (0.25);
16739 add_to_ored_words (0.5);
16740 add_to_ored_words (1.0);
16741 add_to_ored_words (2.0);
16742 add_to_ored_words (4.0);
16743 /* Remove bits that are common (e.g. if representation of the first mantissa
16744 bit is explicit). */
16745 for (j = 0; j < NWORDS; j++)
16746 ored_words[j] &= ~anded_words[j];
16747 /* Now find the nonzero word. */
16748 for (j = 0; j < NWORDS; j++)
16749 if (ored_words[j] != 0)
16750 break;
16751 if (j < NWORDS)
16752 {
16753 size_t i;
16754 for (i = j + 1; i < NWORDS; i++)
16755 if (ored_words[i] != 0)
16756 {
16757 fprintf (fp, "unknown");
16758 return (fclose (fp) != 0);
16759 }
16760 for (i = 0; ; i++)
16761 if ((ored_words[j] >> i) & 1)
16762 {
16763 fprintf (fp, "word %d bit %d", (int) j, (int) i);
16764 return (fclose (fp) != 0);
16765 }
16766 }
16767 fprintf (fp, "unknown");
16768 return (fclose (fp) != 0);
16769}
16770
16771_ACEOF
16772if ac_fn_c_try_run "$LINENO"; then :
16773 gl_cv_cc_double_expbit0=`cat conftest.out`
16774else
16775 gl_cv_cc_double_expbit0="unknown"
16776fi
16777rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16778 conftest.$ac_objext conftest.beam conftest.$ac_ext
16779fi
16780
16781 rm -f conftest.out
16782
16783fi
16784{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_double_expbit0" >&5
16785$as_echo "$gl_cv_cc_double_expbit0" >&6; }
16786 case "$gl_cv_cc_double_expbit0" in
16787 word*bit*)
16788 word=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
16789 bit=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word.*bit //'`
16790
16791cat >>confdefs.h <<_ACEOF
16792#define DBL_EXPBIT0_WORD $word
16793_ACEOF
16794
16795
16796cat >>confdefs.h <<_ACEOF
16797#define DBL_EXPBIT0_BIT $bit
16798_ACEOF
16799
16800 ;;
16801 esac
16802
16803
16804
16805
16806
16807
16808
16809
16810
16811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf returns a byte count as in C99" >&5
16812$as_echo_n "checking whether snprintf returns a byte count as in C99... " >&6; }
16813if ${gl_cv_func_snprintf_retval_c99+:} false; then :
16814 $as_echo_n "(cached) " >&6
16815else
16816
16817 if test "$cross_compiling" = yes; then :
16818
16819 case "$host_os" in
16820 # Guess yes on glibc systems.
16821 *-gnu*) gl_cv_func_snprintf_retval_c99="guessing yes";;
16822 # Guess yes on FreeBSD >= 5.
16823 freebsd[1-4]*) gl_cv_func_snprintf_retval_c99="guessing no";;
16824 freebsd* | kfreebsd*) gl_cv_func_snprintf_retval_c99="guessing yes";;
16825 # Guess yes on Mac OS X >= 10.3.
16826 darwin[1-6].*) gl_cv_func_snprintf_retval_c99="guessing no";;
16827 darwin*) gl_cv_func_snprintf_retval_c99="guessing yes";;
16828 # Guess yes on OpenBSD >= 3.9.
16829 openbsd[1-2].* | openbsd3.[0-8] | openbsd3.[0-8].*)
16830 gl_cv_func_snprintf_retval_c99="guessing no";;
16831 openbsd*) gl_cv_func_snprintf_retval_c99="guessing yes";;
16832 # Guess yes on Solaris >= 2.10.
16833 solaris2.[1-9][0-9]*) gl_cv_func_printf_sizes_c99="guessing yes";;
16834 solaris*) gl_cv_func_printf_sizes_c99="guessing no";;
16835 # Guess yes on AIX >= 4.
16836 aix[1-3]*) gl_cv_func_snprintf_retval_c99="guessing no";;
16837 aix*) gl_cv_func_snprintf_retval_c99="guessing yes";;
16838 # Guess yes on NetBSD >= 3.
16839 netbsd[1-2]* | netbsdelf[1-2]* | netbsdaout[1-2]* | netbsdcoff[1-2]*)
16840 gl_cv_func_snprintf_retval_c99="guessing no";;
16841 netbsd*) gl_cv_func_snprintf_retval_c99="guessing yes";;
16842 # Guess yes on BeOS.
16843 beos*) gl_cv_func_snprintf_retval_c99="guessing yes";;
16844 # If we don't know, assume the worst.
16845 *) gl_cv_func_snprintf_retval_c99="guessing no";;
16846 esac
16847
16848else
16849 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16850/* end confdefs.h. */
16851
16852#include <stdio.h>
16853#include <string.h>
16854#if HAVE_SNPRINTF
16855# define my_snprintf snprintf
16856#else
16857# include <stdarg.h>
16858static int my_snprintf (char *buf, int size, const char *format, ...)
16859{
16860 va_list args;
16861 int ret;
16862 va_start (args, format);
16863 ret = vsnprintf (buf, size, format, args);
16864 va_end (args);
16865 return ret;
16866}
16867#endif
16868static char buf[100];
16869int main ()
16870{
16871 strcpy (buf, "ABCDEF");
16872 if (my_snprintf (buf, 3, "%d %d", 4567, 89) != 7)
16873 return 1;
16874 if (my_snprintf (buf, 0, "%d %d", 4567, 89) != 7)
16875 return 2;
16876 if (my_snprintf (NULL, 0, "%d %d", 4567, 89) != 7)
16877 return 3;
16878 return 0;
16879}
16880_ACEOF
16881if ac_fn_c_try_run "$LINENO"; then :
16882 gl_cv_func_snprintf_retval_c99=yes
16883else
16884 gl_cv_func_snprintf_retval_c99=no
16885fi
16886rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16887 conftest.$ac_objext conftest.beam conftest.$ac_ext
16888fi
16889
16890
16891fi
16892{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_snprintf_retval_c99" >&5
16893$as_echo "$gl_cv_func_snprintf_retval_c99" >&6; }
16894
16895
16896
16897
16898
16899
16900 for ac_func in snprintf strnlen wcslen wcsnlen mbrtowc wcrtomb
16901do :
16902 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16903ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16904if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
16905 cat >>confdefs.h <<_ACEOF
16906#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16907_ACEOF
16908
16909fi
16910done
16911
16912 ac_fn_c_check_decl "$LINENO" "_snprintf" "ac_cv_have_decl__snprintf" "#include <stdio.h>
16913"
16914if test "x$ac_cv_have_decl__snprintf" = xyes; then :
16915 ac_have_decl=1
16916else
16917 ac_have_decl=0
16918fi
16919
16920cat >>confdefs.h <<_ACEOF
16921#define HAVE_DECL__SNPRINTF $ac_have_decl
16922_ACEOF
16923
16924
16925
16926 case "$gl_cv_func_snprintf_retval_c99" in
16927 *yes)
16928
16929$as_echo "#define HAVE_SNPRINTF_RETVAL_C99 1" >>confdefs.h
16930
16931 ;;
16932 esac
16933
16934ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
16935if test "x$ac_cv_have_decl_vsnprintf" = xyes; then :
16936 ac_have_decl=1
16937else
16938 ac_have_decl=0
16939fi
16940
16941cat >>confdefs.h <<_ACEOF
16942#define HAVE_DECL_VSNPRINTF $ac_have_decl
16943_ACEOF
16944
16945
16946
16947
16948 GNULIB_ISWBLANK=0;
16949 GNULIB_WCTYPE=0;
16950 GNULIB_ISWCTYPE=0;
16951 GNULIB_WCTRANS=0;
16952 GNULIB_TOWCTRANS=0;
16953 HAVE_ISWBLANK=1;
16954 HAVE_WCTYPE_T=1;
16955 HAVE_WCTRANS_T=1;
16956 REPLACE_ISWBLANK=0;
16957
16958
16959
16960
16961
16962
16963 if false; then
16964 GL_COND_LIBTOOL_TRUE=
16965 GL_COND_LIBTOOL_FALSE='#'
16966else
16967 GL_COND_LIBTOOL_TRUE='#'
16968 GL_COND_LIBTOOL_FALSE=
16969fi
16970
16971 gl_cond_libtool=false
16972 gl_libdeps=
16973 gl_ltlibdeps=
16974 gl_m4_base='m4'
16975
16976
16977
16978
16979
16980
16981
16982
16983
16984 gl_source_base='grub-core/gnulib'
16985
16986
16987 if test $ac_cv_func_alloca_works = no; then
16988 :
16989 fi
16990
16991 # Define an additional variable used in the Makefile substitution.
16992 if test $ac_cv_working_alloca_h = yes; then
16993 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
16994$as_echo_n "checking for alloca as a compiler built-in... " >&6; }
16995if ${gl_cv_rpl_alloca+:} false; then :
16996 $as_echo_n "(cached) " >&6
16997else
16998
16999 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17000/* end confdefs.h. */
17001
17002#if defined __GNUC__ || defined _AIX || defined _MSC_VER
17003 Need own alloca
17004#endif
17005
17006_ACEOF
17007if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17008 $EGREP "Need own alloca" >/dev/null 2>&1; then :
17009 gl_cv_rpl_alloca=yes
17010else
17011 gl_cv_rpl_alloca=no
17012fi
17013rm -f conftest*
17014
17015
17016fi
17017{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
17018$as_echo "$gl_cv_rpl_alloca" >&6; }
17019 if test $gl_cv_rpl_alloca = yes; then
17020
17021$as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
17022
17023 ALLOCA_H=alloca.h
17024 else
17025 ALLOCA_H=
17026 fi
17027 else
17028 ALLOCA_H=alloca.h
17029 fi
17030
17031 if test -n "$ALLOCA_H"; then
17032 GL_GENERATE_ALLOCA_H_TRUE=
17033 GL_GENERATE_ALLOCA_H_FALSE='#'
17034else
17035 GL_GENERATE_ALLOCA_H_TRUE='#'
17036 GL_GENERATE_ALLOCA_H_FALSE=
17037fi
17038
17039
17040
17041
17042
17043
17044
17045 ac_fn_c_check_decl "$LINENO" "program_invocation_name" "ac_cv_have_decl_program_invocation_name" "#include <errno.h>
17046"
17047if test "x$ac_cv_have_decl_program_invocation_name" = xyes; then :
17048 ac_have_decl=1
17049else
17050 ac_have_decl=0
17051fi
17052
17053cat >>confdefs.h <<_ACEOF
17054#define HAVE_DECL_PROGRAM_INVOCATION_NAME $ac_have_decl
17055_ACEOF
17056if test $ac_have_decl = 1; then :
17057
17058else
17059
17060$as_echo "#define GNULIB_PROGRAM_INVOCATION_NAME 1" >>confdefs.h
17061
17062fi
17063
17064 ac_fn_c_check_decl "$LINENO" "program_invocation_short_name" "ac_cv_have_decl_program_invocation_short_name" "#include <errno.h>
17065"
17066if test "x$ac_cv_have_decl_program_invocation_short_name" = xyes; then :
17067 ac_have_decl=1
17068else
17069 ac_have_decl=0
17070fi
17071
17072cat >>confdefs.h <<_ACEOF
17073#define HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME $ac_have_decl
17074_ACEOF
17075if test $ac_have_decl = 1; then :
17076
17077else
17078
17079$as_echo "#define GNULIB_PROGRAM_INVOCATION_SHORT_NAME 1" >>confdefs.h
17080
17081fi
17082
17083
17084 # Check if program_invocation_name and program_invocation_short_name
17085 # are defined elsewhere. It is improbable that only one of them will
17086 # be defined and other not, I prefer to stay on the safe side and to
17087 # test each one separately.
17088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether program_invocation_name is defined" >&5
17089$as_echo_n "checking whether program_invocation_name is defined... " >&6; }
17090 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17091/* end confdefs.h. */
17092#include <argp.h>
17093int
17094main (void)
17095{
17096program_invocation_name = "test";
17097 ;
17098 return 0;
17099}
17100_ACEOF
17101if ac_fn_c_try_link "$LINENO"; then :
17102
17103$as_echo "#define HAVE_PROGRAM_INVOCATION_NAME 1" >>confdefs.h
17104
17105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17106$as_echo "yes" >&6; }
17107else
17108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17109$as_echo "no" >&6; }
17110fi
17111rm -f core conftest.err conftest.$ac_objext \
17112 conftest$ac_exeext conftest.$ac_ext
17113
17114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether program_invocation_short_name is defined" >&5
17115$as_echo_n "checking whether program_invocation_short_name is defined... " >&6; }
17116 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17117/* end confdefs.h. */
17118#include <argp.h>
17119int
17120main (void)
17121{
17122program_invocation_short_name = "test";
17123 ;
17124 return 0;
17125}
17126_ACEOF
17127if ac_fn_c_try_link "$LINENO"; then :
17128
17129$as_echo "#define HAVE_PROGRAM_INVOCATION_SHORT_NAME 1" >>confdefs.h
17130
17131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17132$as_echo "yes" >&6; }
17133else
17134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17135$as_echo "no" >&6; }
17136fi
17137rm -f core conftest.err conftest.$ac_objext \
17138 conftest$ac_exeext conftest.$ac_ext
17139
17140
17141
17142
17143
17144
17145
17146
17147
17148
17149
17150
17151
17152
17153
17154
17155
17156
17157
17158 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=argp_error:2:c-format"
17159
17160
17161
17162 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=argp_failure:4:c-format"
17163
17164
17165
17166
17167
17168
17169
17170 if test $ac_cv_func_btowc = no; then
17171 HAVE_BTOWC=0
17172 else
17173
17174
17175
17176
17177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether btowc(0) is correct" >&5
17178$as_echo_n "checking whether btowc(0) is correct... " >&6; }
17179if ${gl_cv_func_btowc_nul+:} false; then :
17180 $as_echo_n "(cached) " >&6
17181else
17182
17183 if test "$cross_compiling" = yes; then :
17184
17185 case "$host_os" in
17186 # Guess no on Cygwin.
17187 cygwin*) gl_cv_func_btowc_nul="guessing no" ;;
17188 # Guess yes otherwise.
17189 *) gl_cv_func_btowc_nul="guessing yes" ;;
17190 esac
17191
17192else
17193 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17194/* end confdefs.h. */
17195
17196#include <string.h>
17197/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
17198 <wchar.h>.
17199 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
17200 included before <wchar.h>. */
17201#include <stddef.h>
17202#include <stdio.h>
17203#include <time.h>
17204#include <wchar.h>
17205int main ()
17206{
17207 if (btowc ('\0') != 0)
17208 return 1;
17209 return 0;
17210}
17211_ACEOF
17212if ac_fn_c_try_run "$LINENO"; then :
17213 gl_cv_func_btowc_nul=yes
17214else
17215 gl_cv_func_btowc_nul=no
17216fi
17217rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17218 conftest.$ac_objext conftest.beam conftest.$ac_ext
17219fi
17220
17221
17222fi
17223{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_btowc_nul" >&5
17224$as_echo "$gl_cv_func_btowc_nul" >&6; }
17225
17226 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether btowc(EOF) is correct" >&5
17227$as_echo_n "checking whether btowc(EOF) is correct... " >&6; }
17228if ${gl_cv_func_btowc_eof+:} false; then :
17229 $as_echo_n "(cached) " >&6
17230else
17231
17232 case "$host_os" in
17233 # Guess no on IRIX.
17234 irix*) gl_cv_func_btowc_eof="guessing no" ;;
17235 # Guess yes otherwise.
17236 *) gl_cv_func_btowc_eof="guessing yes" ;;
17237 esac
17238 if test $LOCALE_FR != none; then
17239 if test "$cross_compiling" = yes; then :
17240 :
17241else
17242 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17243/* end confdefs.h. */
17244
17245#include <locale.h>
17246#include <string.h>
17247/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
17248 <wchar.h>.
17249 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
17250 included before <wchar.h>. */
17251#include <stddef.h>
17252#include <stdio.h>
17253#include <time.h>
17254#include <wchar.h>
17255int main ()
17256{
17257 if (setlocale (LC_ALL, "$LOCALE_FR") != NULL)
17258 {
17259 if (btowc (EOF) != WEOF)
17260 return 1;
17261 }
17262 return 0;
17263}
17264_ACEOF
17265if ac_fn_c_try_run "$LINENO"; then :
17266 gl_cv_func_btowc_eof=yes
17267else
17268 gl_cv_func_btowc_eof=no
17269fi
17270rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17271 conftest.$ac_objext conftest.beam conftest.$ac_ext
17272fi
17273
17274 fi
17275
17276fi
17277{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_btowc_eof" >&5
17278$as_echo "$gl_cv_func_btowc_eof" >&6; }
17279
17280 case "$gl_cv_func_btowc_nul" in
17281 *yes) ;;
17282 *) REPLACE_BTOWC=1 ;;
17283 esac
17284 case "$gl_cv_func_btowc_eof" in
17285 *yes) ;;
17286 *) REPLACE_BTOWC=1 ;;
17287 esac
17288 fi
17289
17290 if test $HAVE_BTOWC = 0 || test $REPLACE_BTOWC = 1; then
17291
17292
17293
17294
17295
17296
17297
17298
17299 gl_LIBOBJS="$gl_LIBOBJS btowc.$ac_objext"
17300
17301
17302 :
17303
17304 fi
17305
17306
17307
17308
17309
17310 GNULIB_BTOWC=1
17311
17312
17313
17314
17315
17316$as_echo "#define GNULIB_TEST_BTOWC 1" >>confdefs.h
17317
17318
17319
17320
17321 if test "x$datarootdir" = x; then
17322 datarootdir='${datadir}'
17323
17324 fi
17325 if test "x$docdir" = x; then
17326 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
17327
17328 fi
17329 if test "x$htmldir" = x; then
17330 htmldir='${docdir}'
17331
17332 fi
17333 if test "x$dvidir" = x; then
17334 dvidir='${docdir}'
17335
17336 fi
17337 if test "x$pdfdir" = x; then
17338 pdfdir='${docdir}'
17339
17340 fi
17341 if test "x$psdir" = x; then
17342 psdir='${docdir}'
17343
17344 fi
17345 if test "x$lispdir" = x; then
17346 lispdir='${datarootdir}/emacs/site-lisp'
17347
17348 fi
17349 if test "x$localedir" = x; then
17350 localedir='${datarootdir}/locale'
17351
17352 fi
17353
17354 pkglibexecdir='${libexecdir}/${PACKAGE}'
17355
17356
17357
17358
17359
17360
17361
17362
17363 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether // is distinct from /" >&5
17364$as_echo_n "checking whether // is distinct from /... " >&6; }
17365if ${gl_cv_double_slash_root+:} false; then :
17366 $as_echo_n "(cached) " >&6
17367else
17368 if test x"$cross_compiling" = xyes ; then
17369 # When cross-compiling, there is no way to tell whether // is special
17370 # short of a list of hosts. However, the only known hosts to date
17371 # that have a distinct // are Apollo DomainOS (too old to port to),
17372 # Cygwin, and z/OS. If anyone knows of another system for which // has
17373 # special semantics and is distinct from /, please report it to
17374 # <bug-gnulib@gnu.org>.
17375 case $host in
17376 *-cygwin | i370-ibm-openedition)
17377 gl_cv_double_slash_root=yes ;;
17378 *)
17379 # Be optimistic and assume that / and // are the same when we
17380 # don't know.
17381 gl_cv_double_slash_root='unknown, assuming no' ;;
17382 esac
17383 else
17384 set x `ls -di / // 2>/dev/null`
17385 if test "$2" = "$4" && wc //dev/null >/dev/null 2>&1; then
17386 gl_cv_double_slash_root=no
17387 else
17388 gl_cv_double_slash_root=yes
17389 fi
17390 fi
17391fi
17392{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_double_slash_root" >&5
17393$as_echo "$gl_cv_double_slash_root" >&6; }
17394 if test "$gl_cv_double_slash_root" = yes; then
17395
17396$as_echo "#define DOUBLE_SLASH_IS_DISTINCT_ROOT 1" >>confdefs.h
17397
17398 fi
17399
17400
17401
17402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for error_at_line" >&5
17403$as_echo_n "checking for error_at_line... " >&6; }
17404if ${ac_cv_lib_error_at_line+:} false; then :
17405 $as_echo_n "(cached) " >&6
17406else
17407 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17408/* end confdefs.h. */
17409#include <error.h>
17410int
17411main (void)
17412{
17413error_at_line (0, 0, "", 0, "an error occurred");
17414 ;
17415 return 0;
17416}
17417_ACEOF
17418if ac_fn_c_try_link "$LINENO"; then :
17419 ac_cv_lib_error_at_line=yes
17420else
17421 ac_cv_lib_error_at_line=no
17422fi
17423rm -f core conftest.err conftest.$ac_objext \
17424 conftest$ac_exeext conftest.$ac_ext
17425fi
17426{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_error_at_line" >&5
17427$as_echo "$ac_cv_lib_error_at_line" >&6; }
17428
17429 if test $ac_cv_lib_error_at_line = no; then
17430
17431
17432
17433
17434
17435
17436
17437
17438 gl_LIBOBJS="$gl_LIBOBJS error.$ac_objext"
17439
17440
17441
17442 :
17443
17444 fi
17445
17446
17447 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=error:3:c-format"
17448
17449
17450
17451 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=error_at_line:5:c-format"
17452
17453
17454
17455
17456
17457 FLOAT_H=
17458 REPLACE_FLOAT_LDBL=0
17459 case "$host_os" in
17460 aix* | beos* | openbsd* | mirbsd* | irix*)
17461 FLOAT_H=float.h
17462 ;;
17463 freebsd*)
17464 case "$host_cpu" in
17465 i[34567]86 )
17466 FLOAT_H=float.h
17467 ;;
17468 x86_64 )
17469 # On x86_64 systems, the C compiler may still be generating
17470 # 32-bit code.
17471 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17472/* end confdefs.h. */
17473#if defined __LP64__ || defined __x86_64__ || defined __amd64__
17474 yes
17475 #endif
17476_ACEOF
17477if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17478 $EGREP "yes" >/dev/null 2>&1; then :
17479
17480else
17481 FLOAT_H=float.h
17482fi
17483rm -f conftest*
17484
17485 ;;
17486 esac
17487 ;;
17488 linux*)
17489 case "$host_cpu" in
17490 powerpc*)
17491 FLOAT_H=float.h
17492 ;;
17493 esac
17494 ;;
17495 esac
17496 case "$host_os" in
17497 aix* | freebsd* | linux*)
17498 if test -n "$FLOAT_H"; then
17499 REPLACE_FLOAT_LDBL=1
17500 fi
17501 ;;
17502 esac
17503
17504 REPLACE_ITOLD=0
17505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether conversion from 'int' to 'long double' works" >&5
17506$as_echo_n "checking whether conversion from 'int' to 'long double' works... " >&6; }
17507if ${gl_cv_func_itold_works+:} false; then :
17508 $as_echo_n "(cached) " >&6
17509else
17510
17511 if test "$cross_compiling" = yes; then :
17512 case "$host" in
17513 sparc*-*-linux*)
17514 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17515/* end confdefs.h. */
17516#if defined __LP64__ || defined __arch64__
17517 yes
17518 #endif
17519_ACEOF
17520if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17521 $EGREP "yes" >/dev/null 2>&1; then :
17522 gl_cv_func_itold_works="guessing no"
17523else
17524 gl_cv_func_itold_works="guessing yes"
17525fi
17526rm -f conftest*
17527
17528 ;;
17529 *) gl_cv_func_itold_works="guessing yes" ;;
17530 esac
17531
17532else
17533 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17534/* end confdefs.h. */
17535
17536int i = -1;
17537volatile long double ld;
17538int main ()
17539{
17540 ld += i * 1.0L;
17541 if (ld > 0)
17542 return 1;
17543 return 0;
17544}
17545_ACEOF
17546if ac_fn_c_try_run "$LINENO"; then :
17547 gl_cv_func_itold_works=yes
17548else
17549 gl_cv_func_itold_works=no
17550fi
17551rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17552 conftest.$ac_objext conftest.beam conftest.$ac_ext
17553fi
17554
17555
17556fi
17557{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_itold_works" >&5
17558$as_echo "$gl_cv_func_itold_works" >&6; }
17559 case "$gl_cv_func_itold_works" in
17560 *no)
17561 REPLACE_ITOLD=1
17562 FLOAT_H=float.h
17563 ;;
17564 esac
17565
17566 if test -n "$FLOAT_H"; then
17567
17568
17569
17570
17571
17572
17573
17574
17575 if test $gl_cv_have_include_next = yes; then
17576 gl_cv_next_float_h='<'float.h'>'
17577 else
17578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <float.h>" >&5
17579$as_echo_n "checking absolute name of <float.h>... " >&6; }
17580if ${gl_cv_next_float_h+:} false; then :
17581 $as_echo_n "(cached) " >&6
17582else
17583
17584 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17585/* end confdefs.h. */
17586#include <float.h>
17587
17588_ACEOF
17589 case "$host_os" in
17590 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17591 *) gl_absname_cpp="$ac_cpp" ;;
17592 esac
17593
17594 case "$host_os" in
17595 mingw*)
17596 gl_dirsep_regex='[/\\]'
17597 ;;
17598 *)
17599 gl_dirsep_regex='\/'
17600 ;;
17601 esac
17602 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17603
17604 gl_header_literal_regex=`echo 'float.h' \
17605 | sed -e "$gl_make_literal_regex_sed"`
17606 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17607 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17608 s|^/[^/]|//&|
17609 p
17610 q
17611 }'
17612 gl_cv_next_float_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17613 sed -n "$gl_absolute_header_sed"`'"'
17614
17615
17616fi
17617{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_float_h" >&5
17618$as_echo "$gl_cv_next_float_h" >&6; }
17619 fi
17620 NEXT_FLOAT_H=$gl_cv_next_float_h
17621
17622 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17623 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17624 gl_next_as_first_directive='<'float.h'>'
17625 else
17626 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17627 gl_next_as_first_directive=$gl_cv_next_float_h
17628 fi
17629 NEXT_AS_FIRST_DIRECTIVE_FLOAT_H=$gl_next_as_first_directive
17630
17631
17632
17633
17634 fi
17635
17636 if test -n "$FLOAT_H"; then
17637 GL_GENERATE_FLOAT_H_TRUE=
17638 GL_GENERATE_FLOAT_H_FALSE='#'
17639else
17640 GL_GENERATE_FLOAT_H_TRUE='#'
17641 GL_GENERATE_FLOAT_H_FALSE=
17642fi
17643
17644
17645
17646 if test $REPLACE_FLOAT_LDBL = 1; then
17647
17648
17649
17650
17651
17652
17653
17654
17655 gl_LIBOBJS="$gl_LIBOBJS float.$ac_objext"
17656
17657 fi
17658 if test $REPLACE_ITOLD = 1; then
17659
17660
17661
17662
17663
17664
17665
17666
17667 gl_LIBOBJS="$gl_LIBOBJS itold.$ac_objext"
17668
17669 fi
17670
17671
17672
17673
17674
17675 FNMATCH_H=
17676 gl_fnmatch_required_lowercase=`
17677 echo $gl_fnmatch_required | LC_ALL=C tr '[A-Z]' '[a-z]'
17678 `
17679 gl_fnmatch_cache_var="gl_cv_func_fnmatch_${gl_fnmatch_required_lowercase}"
17680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working $gl_fnmatch_required fnmatch" >&5
17681$as_echo_n "checking for working $gl_fnmatch_required fnmatch... " >&6; }
17682if eval \${$gl_fnmatch_cache_var+:} false; then :
17683 $as_echo_n "(cached) " >&6
17684else
17685 if test $gl_fnmatch_required = GNU; then
17686 gl_fnmatch_gnu_start=
17687 gl_fnmatch_gnu_end=
17688 else
17689 gl_fnmatch_gnu_start='#if 0'
17690 gl_fnmatch_gnu_end='#endif'
17691 fi
17692 if test "$cross_compiling" = yes; then :
17693 eval "$gl_fnmatch_cache_var=\"guessing no\""
17694else
17695 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17696/* end confdefs.h. */
17697#include <fnmatch.h>
17698 static int
17699 y (char const *pattern, char const *string, int flags)
17700 {
17701 return fnmatch (pattern, string, flags) == 0;
17702 }
17703 static int
17704 n (char const *pattern, char const *string, int flags)
17705 {
17706 return fnmatch (pattern, string, flags) == FNM_NOMATCH;
17707 }
17708
17709int
17710main (void)
17711{
17712char const *Apat = 'A' < '\\\\' ? "[A-\\\\\\\\]" : "[\\\\\\\\-A]";
17713 char const *apat = 'a' < '\\\\' ? "[a-\\\\\\\\]" : "[\\\\\\\\-a]";
17714 static char const A_1[] = { 'A' - 1, 0 };
17715 static char const A01[] = { 'A' + 1, 0 };
17716 static char const a_1[] = { 'a' - 1, 0 };
17717 static char const a01[] = { 'a' + 1, 0 };
17718 static char const bs_1[] = { '\\\\' - 1, 0 };
17719 static char const bs01[] = { '\\\\' + 1, 0 };
17720 int result = 0;
17721 if (!n ("a*", "", 0))
17722 return 1;
17723 if (!y ("a*", "abc", 0))
17724 return 1;
17725 if (!y ("[/b", "[/b", 0)) /*"]]"*/ /* glibc Bugzilla bug 12378 */
17726 return 1;
17727 if (!n ("d*/*1", "d/s/1", FNM_PATHNAME))
17728 return 2;
17729 if (!y ("a\\\\bc", "abc", 0))
17730 return 3;
17731 if (!n ("a\\\\bc", "abc", FNM_NOESCAPE))
17732 return 3;
17733 if (!y ("*x", ".x", 0))
17734 return 4;
17735 if (!n ("*x", ".x", FNM_PERIOD))
17736 return 4;
17737 if (!y (Apat, "\\\\", 0))
17738 return 5;
17739 if (!y (Apat, "A", 0))
17740 return 5;
17741 if (!y (apat, "\\\\", 0))
17742 return 5;
17743 if (!y (apat, "a", 0))
17744 return 5;
17745 if (!(n (Apat, A_1, 0) == ('A' < '\\\\')))
17746 return 5;
17747 if (!(n (apat, a_1, 0) == ('a' < '\\\\')))
17748 return 5;
17749 if (!(y (Apat, A01, 0) == ('A' < '\\\\')))
17750 return 5;
17751 if (!(y (apat, a01, 0) == ('a' < '\\\\')))
17752 return 5;
17753 if (!(y (Apat, bs_1, 0) == ('A' < '\\\\')))
17754 return 5;
17755 if (!(y (apat, bs_1, 0) == ('a' < '\\\\')))
17756 return 5;
17757 if (!(n (Apat, bs01, 0) == ('A' < '\\\\')))
17758 return 5;
17759 if (!(n (apat, bs01, 0) == ('a' < '\\\\')))
17760 return 5;
17761 $gl_fnmatch_gnu_start
17762 if (!y ("xxXX", "xXxX", FNM_CASEFOLD))
17763 result |= 8;
17764 if (!y ("a++(x|yy)b", "a+xyyyyxb", FNM_EXTMATCH))
17765 result |= 16;
17766 if (!n ("d*/*1", "d/s/1", FNM_FILE_NAME))
17767 result |= 32;
17768 if (!y ("*", "x", FNM_FILE_NAME | FNM_LEADING_DIR))
17769 result |= 64;
17770 if (!y ("x*", "x/y/z", FNM_FILE_NAME | FNM_LEADING_DIR))
17771 result |= 64;
17772 if (!y ("*c*", "c/x", FNM_FILE_NAME | FNM_LEADING_DIR))
17773 result |= 64;
17774 $gl_fnmatch_gnu_end
17775 return result;
17776
17777 ;
17778 return 0;
17779}
17780_ACEOF
17781if ac_fn_c_try_run "$LINENO"; then :
17782 eval "$gl_fnmatch_cache_var=yes"
17783else
17784 eval "$gl_fnmatch_cache_var=no"
17785fi
17786rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17787 conftest.$ac_objext conftest.beam conftest.$ac_ext
17788fi
17789
17790
17791fi
17792eval ac_res=\$$gl_fnmatch_cache_var
17793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
17794$as_echo "$ac_res" >&6; }
17795 eval "gl_fnmatch_result=\"\$$gl_fnmatch_cache_var\""
17796 if test "$gl_fnmatch_result" = yes; then
17797 rm -f "$gl_source_base/fnmatch.h"
17798 else
17799 FNMATCH_H=fnmatch.h
17800 fi
17801
17802 if test -n "$FNMATCH_H"; then
17803 GL_GENERATE_FNMATCH_H_TRUE=
17804 GL_GENERATE_FNMATCH_H_FALSE='#'
17805else
17806 GL_GENERATE_FNMATCH_H_TRUE='#'
17807 GL_GENERATE_FNMATCH_H_FALSE=
17808fi
17809
17810
17811 if test -n "$FNMATCH_H"; then
17812
17813
17814
17815
17816
17817
17818
17819
17820 gl_LIBOBJS="$gl_LIBOBJS fnmatch.$ac_objext"
17821
17822
17823
17824cat >>confdefs.h <<_ACEOF
17825#define fnmatch ${gl_fnmatch_required_lowercase}_fnmatch
17826_ACEOF
17827
17828
17829 ac_fn_c_check_decl "$LINENO" "isblank" "ac_cv_have_decl_isblank" "#include <ctype.h>
17830"
17831if test "x$ac_cv_have_decl_isblank" = xyes; then :
17832 ac_have_decl=1
17833else
17834 ac_have_decl=0
17835fi
17836
17837cat >>confdefs.h <<_ACEOF
17838#define HAVE_DECL_ISBLANK $ac_have_decl
17839_ACEOF
17840
17841
17842
17843
17844 fi
17845
17846
17847
17848
17849
17850
17851
17852
17853 if test $ac_cv_func_getdelim = yes; then
17854 HAVE_GETDELIM=1
17855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getdelim function" >&5
17856$as_echo_n "checking for working getdelim function... " >&6; }
17857if ${gl_cv_func_working_getdelim+:} false; then :
17858 $as_echo_n "(cached) " >&6
17859else
17860 echo fooNbarN | tr -d '\012' | tr N '\012' > conftest.data
17861 if test "$cross_compiling" = yes; then :
17862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17863/* end confdefs.h. */
17864
17865#include <features.h>
17866#ifdef __GNU_LIBRARY__
17867 #if (__GLIBC__ >= 2) && !defined __UCLIBC__
17868 Lucky GNU user
17869 #endif
17870#endif
17871
17872_ACEOF
17873if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17874 $EGREP "Lucky GNU user" >/dev/null 2>&1; then :
17875 gl_cv_func_working_getdelim="guessing yes"
17876else
17877 gl_cv_func_working_getdelim="guessing no"
17878fi
17879rm -f conftest*
17880
17881
17882else
17883 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17884/* end confdefs.h. */
17885
17886# include <stdio.h>
17887# include <stdlib.h>
17888# include <string.h>
17889 int main ()
17890 {
17891 FILE *in = fopen ("./conftest.data", "r");
17892 if (!in)
17893 return 1;
17894 {
17895 /* Test result for a NULL buffer and a zero size.
17896 Based on a test program from Karl Heuer. */
17897 char *line = NULL;
17898 size_t siz = 0;
17899 int len = getdelim (&line, &siz, '\n', in);
17900 if (!(len == 4 && line && strcmp (line, "foo\n") == 0))
17901 return 2;
17902 }
17903 {
17904 /* Test result for a NULL buffer and a non-zero size.
17905 This crashes on FreeBSD 8.0. */
17906 char *line = NULL;
17907 size_t siz = (size_t)(~0) / 4;
17908 if (getdelim (&line, &siz, '\n', in) == -1)
17909 return 3;
17910 }
17911 return 0;
17912 }
17913
17914_ACEOF
17915if ac_fn_c_try_run "$LINENO"; then :
17916 gl_cv_func_working_getdelim=yes
17917else
17918 gl_cv_func_working_getdelim=no
17919fi
17920rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17921 conftest.$ac_objext conftest.beam conftest.$ac_ext
17922fi
17923
17924fi
17925{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_getdelim" >&5
17926$as_echo "$gl_cv_func_working_getdelim" >&6; }
17927 case "$gl_cv_func_working_getdelim" in
17928 *no)
17929 REPLACE_GETDELIM=1
17930 ;;
17931 esac
17932 else
17933 HAVE_GETDELIM=0
17934 fi
17935
17936 if test $ac_cv_have_decl_getdelim = no; then
17937 HAVE_DECL_GETDELIM=0
17938 fi
17939
17940 if test $HAVE_GETDELIM = 0 || test $REPLACE_GETDELIM = 1; then
17941
17942
17943
17944
17945
17946
17947
17948
17949 gl_LIBOBJS="$gl_LIBOBJS getdelim.$ac_objext"
17950
17951
17952 for ac_func in flockfile funlockfile
17953do :
17954 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
17955ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
17956if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
17957 cat >>confdefs.h <<_ACEOF
17958#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
17959_ACEOF
17960
17961fi
17962done
17963
17964 ac_fn_c_check_decl "$LINENO" "getc_unlocked" "ac_cv_have_decl_getc_unlocked" "$ac_includes_default"
17965if test "x$ac_cv_have_decl_getc_unlocked" = xyes; then :
17966 ac_have_decl=1
17967else
17968 ac_have_decl=0
17969fi
17970
17971cat >>confdefs.h <<_ACEOF
17972#define HAVE_DECL_GETC_UNLOCKED $ac_have_decl
17973_ACEOF
17974
17975
17976 fi
17977
17978
17979
17980
17981
17982 GNULIB_GETDELIM=1
17983
17984
17985
17986
17987
17988$as_echo "#define GNULIB_TEST_GETDELIM 1" >>confdefs.h
17989
17990
17991
17992
17993
17994
17995
17996
17997
17998
17999 gl_getline_needs_run_time_check=no
18000 ac_fn_c_check_func "$LINENO" "getline" "ac_cv_func_getline"
18001if test "x$ac_cv_func_getline" = xyes; then :
18002 gl_getline_needs_run_time_check=yes
18003else
18004 am_cv_func_working_getline=no
18005fi
18006
18007 if test $gl_getline_needs_run_time_check = yes; then
18008 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getline function" >&5
18009$as_echo_n "checking for working getline function... " >&6; }
18010if ${am_cv_func_working_getline+:} false; then :
18011 $as_echo_n "(cached) " >&6
18012else
18013 echo fooNbarN | tr -d '\012' | tr N '\012' > conftest.data
18014 if test "$cross_compiling" = yes; then :
18015 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18016/* end confdefs.h. */
18017
18018#include <features.h>
18019#ifdef __GNU_LIBRARY__
18020 #if (__GLIBC__ >= 2) && !defined __UCLIBC__
18021 Lucky GNU user
18022 #endif
18023#endif
18024
18025_ACEOF
18026if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18027 $EGREP "Lucky GNU user" >/dev/null 2>&1; then :
18028 am_cv_func_working_getline="guessing yes"
18029else
18030 am_cv_func_working_getline="guessing no"
18031fi
18032rm -f conftest*
18033
18034
18035else
18036 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18037/* end confdefs.h. */
18038
18039# include <stdio.h>
18040# include <stdlib.h>
18041# include <string.h>
18042 int main ()
18043 {
18044 FILE *in = fopen ("./conftest.data", "r");
18045 if (!in)
18046 return 1;
18047 {
18048 /* Test result for a NULL buffer and a zero size.
18049 Based on a test program from Karl Heuer. */
18050 char *line = NULL;
18051 size_t siz = 0;
18052 int len = getline (&line, &siz, in);
18053 if (!(len == 4 && line && strcmp (line, "foo\n") == 0))
18054 return 2;
18055 }
18056 {
18057 /* Test result for a NULL buffer and a non-zero size.
18058 This crashes on FreeBSD 8.0. */
18059 char *line = NULL;
18060 size_t siz = (size_t)(~0) / 4;
18061 if (getline (&line, &siz, in) == -1)
18062 return 3;
18063 }
18064 return 0;
18065 }
18066
18067_ACEOF
18068if ac_fn_c_try_run "$LINENO"; then :
18069 am_cv_func_working_getline=yes
18070else
18071 am_cv_func_working_getline=no
18072fi
18073rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18074 conftest.$ac_objext conftest.beam conftest.$ac_ext
18075fi
18076
18077fi
18078{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_working_getline" >&5
18079$as_echo "$am_cv_func_working_getline" >&6; }
18080 fi
18081
18082 if test $ac_cv_have_decl_getline = no; then
18083 HAVE_DECL_GETLINE=0
18084 fi
18085
18086 case "$am_cv_func_working_getline" in
18087 *no)
18088 REPLACE_GETLINE=1
18089 ;;
18090 esac
18091
18092 if test $REPLACE_GETLINE = 1; then
18093
18094
18095
18096
18097
18098
18099
18100
18101 gl_LIBOBJS="$gl_LIBOBJS getline.$ac_objext"
18102
18103
18104 :
18105
18106 fi
18107
18108
18109
18110
18111
18112 GNULIB_GETLINE=1
18113
18114
18115
18116
18117
18118$as_echo "#define GNULIB_TEST_GETLINE 1" >>confdefs.h
18119
18120
18121
18122
18123
18124
18125
18126
18127 if test $REPLACE_GETOPT = 1; then
18128
18129
18130
18131
18132
18133
18134
18135
18136 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
18137
18138
18139
18140
18141
18142
18143
18144
18145
18146 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
18147
18148
18149
18150
18151 GNULIB_GL_UNISTD_H_GETOPT=1
18152 fi
18153
18154
18155
18156$as_echo "#define GNULIB_TEST_GETOPT_GNU 1" >>confdefs.h
18157
18158
18159
18160
18161
18162
18163
18164 REPLACE_GETOPT=1
18165
18166 if test $REPLACE_GETOPT = 1; then
18167
18168 GETOPT_H=getopt.h
18169
18170$as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
18171
18172
18173
18174 fi
18175
18176 if test $REPLACE_GETOPT = 1; then
18177
18178
18179
18180
18181
18182
18183
18184
18185 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
18186
18187
18188
18189
18190
18191
18192
18193
18194
18195 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
18196
18197
18198
18199
18200 GNULIB_GL_UNISTD_H_GETOPT=1
18201 fi
18202
18203
18204
18205
18206
18207
18208
18209
18210
18211
18212
18213
18214
18215
18216
18217
18218
18219
18220 if test $gl_cv_have_include_next = yes; then
18221 gl_cv_next_langinfo_h='<'langinfo.h'>'
18222 else
18223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <langinfo.h>" >&5
18224$as_echo_n "checking absolute name of <langinfo.h>... " >&6; }
18225if ${gl_cv_next_langinfo_h+:} false; then :
18226 $as_echo_n "(cached) " >&6
18227else
18228
18229 if test $ac_cv_header_langinfo_h = yes; then
18230
18231
18232 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18233/* end confdefs.h. */
18234#include <langinfo.h>
18235
18236_ACEOF
18237 case "$host_os" in
18238 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18239 *) gl_absname_cpp="$ac_cpp" ;;
18240 esac
18241
18242 case "$host_os" in
18243 mingw*)
18244 gl_dirsep_regex='[/\\]'
18245 ;;
18246 *)
18247 gl_dirsep_regex='\/'
18248 ;;
18249 esac
18250 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18251
18252 gl_header_literal_regex=`echo 'langinfo.h' \
18253 | sed -e "$gl_make_literal_regex_sed"`
18254 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18255 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18256 s|^/[^/]|//&|
18257 p
18258 q
18259 }'
18260 gl_cv_next_langinfo_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18261 sed -n "$gl_absolute_header_sed"`'"'
18262 else
18263 gl_cv_next_langinfo_h='<'langinfo.h'>'
18264 fi
18265
18266
18267fi
18268{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_langinfo_h" >&5
18269$as_echo "$gl_cv_next_langinfo_h" >&6; }
18270 fi
18271 NEXT_LANGINFO_H=$gl_cv_next_langinfo_h
18272
18273 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18274 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18275 gl_next_as_first_directive='<'langinfo.h'>'
18276 else
18277 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18278 gl_next_as_first_directive=$gl_cv_next_langinfo_h
18279 fi
18280 NEXT_AS_FIRST_DIRECTIVE_LANGINFO_H=$gl_next_as_first_directive
18281
18282
18283
18284
18285
18286 HAVE_LANGINFO_CODESET=0
18287 HAVE_LANGINFO_T_FMT_AMPM=0
18288 HAVE_LANGINFO_ERA=0
18289 HAVE_LANGINFO_YESEXPR=0
18290
18291 if test $ac_cv_header_langinfo_h = yes; then
18292 HAVE_LANGINFO_H=1
18293 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether langinfo.h defines CODESET" >&5
18294$as_echo_n "checking whether langinfo.h defines CODESET... " >&6; }
18295if ${gl_cv_header_langinfo_codeset+:} false; then :
18296 $as_echo_n "(cached) " >&6
18297else
18298 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18299/* end confdefs.h. */
18300#include <langinfo.h>
18301int a = CODESET;
18302
18303int
18304main (void)
18305{
18306
18307 ;
18308 return 0;
18309}
18310_ACEOF
18311if ac_fn_c_try_compile "$LINENO"; then :
18312 gl_cv_header_langinfo_codeset=yes
18313else
18314 gl_cv_header_langinfo_codeset=no
18315fi
18316rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18317
18318fi
18319{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_langinfo_codeset" >&5
18320$as_echo "$gl_cv_header_langinfo_codeset" >&6; }
18321 if test $gl_cv_header_langinfo_codeset = yes; then
18322 HAVE_LANGINFO_CODESET=1
18323 fi
18324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether langinfo.h defines T_FMT_AMPM" >&5
18325$as_echo_n "checking whether langinfo.h defines T_FMT_AMPM... " >&6; }
18326if ${gl_cv_header_langinfo_t_fmt_ampm+:} false; then :
18327 $as_echo_n "(cached) " >&6
18328else
18329 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18330/* end confdefs.h. */
18331#include <langinfo.h>
18332int a = T_FMT_AMPM;
18333
18334int
18335main (void)
18336{
18337
18338 ;
18339 return 0;
18340}
18341_ACEOF
18342if ac_fn_c_try_compile "$LINENO"; then :
18343 gl_cv_header_langinfo_t_fmt_ampm=yes
18344else
18345 gl_cv_header_langinfo_t_fmt_ampm=no
18346fi
18347rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18348
18349fi
18350{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_langinfo_t_fmt_ampm" >&5
18351$as_echo "$gl_cv_header_langinfo_t_fmt_ampm" >&6; }
18352 if test $gl_cv_header_langinfo_t_fmt_ampm = yes; then
18353 HAVE_LANGINFO_T_FMT_AMPM=1
18354 fi
18355 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether langinfo.h defines ERA" >&5
18356$as_echo_n "checking whether langinfo.h defines ERA... " >&6; }
18357if ${gl_cv_header_langinfo_era+:} false; then :
18358 $as_echo_n "(cached) " >&6
18359else
18360 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18361/* end confdefs.h. */
18362#include <langinfo.h>
18363int a = ERA;
18364
18365int
18366main (void)
18367{
18368
18369 ;
18370 return 0;
18371}
18372_ACEOF
18373if ac_fn_c_try_compile "$LINENO"; then :
18374 gl_cv_header_langinfo_era=yes
18375else
18376 gl_cv_header_langinfo_era=no
18377fi
18378rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18379
18380fi
18381{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_langinfo_era" >&5
18382$as_echo "$gl_cv_header_langinfo_era" >&6; }
18383 if test $gl_cv_header_langinfo_era = yes; then
18384 HAVE_LANGINFO_ERA=1
18385 fi
18386 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether langinfo.h defines YESEXPR" >&5
18387$as_echo_n "checking whether langinfo.h defines YESEXPR... " >&6; }
18388if ${gl_cv_header_langinfo_yesexpr+:} false; then :
18389 $as_echo_n "(cached) " >&6
18390else
18391 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18392/* end confdefs.h. */
18393#include <langinfo.h>
18394int a = YESEXPR;
18395
18396int
18397main (void)
18398{
18399
18400 ;
18401 return 0;
18402}
18403_ACEOF
18404if ac_fn_c_try_compile "$LINENO"; then :
18405 gl_cv_header_langinfo_yesexpr=yes
18406else
18407 gl_cv_header_langinfo_yesexpr=no
18408fi
18409rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18410
18411fi
18412{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_langinfo_yesexpr" >&5
18413$as_echo "$gl_cv_header_langinfo_yesexpr" >&6; }
18414 if test $gl_cv_header_langinfo_yesexpr = yes; then
18415 HAVE_LANGINFO_YESEXPR=1
18416 fi
18417 else
18418 HAVE_LANGINFO_H=0
18419 fi
18420
18421
18422
18423
18424
18425
18426
18427 for gl_func in nl_langinfo; do
18428 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
18429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
18430$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
18431if eval \${$as_gl_Symbol+:} false; then :
18432 $as_echo_n "(cached) " >&6
18433else
18434 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18435/* end confdefs.h. */
18436#include <langinfo.h>
18437
18438int
18439main (void)
18440{
18441#undef $gl_func
18442 (void) $gl_func;
18443 ;
18444 return 0;
18445}
18446_ACEOF
18447if ac_fn_c_try_compile "$LINENO"; then :
18448 eval "$as_gl_Symbol=yes"
18449else
18450 eval "$as_gl_Symbol=no"
18451fi
18452rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18453fi
18454eval ac_res=\$$as_gl_Symbol
18455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18456$as_echo "$ac_res" >&6; }
18457 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
18458 cat >>confdefs.h <<_ACEOF
18459#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
18460_ACEOF
18461
18462 eval ac_cv_have_decl_$gl_func=yes
18463fi
18464 done
18465
18466
18467
18468
18469
18470
18471
18472
18473
18474
18475 LOCALCHARSET_TESTS_ENVIRONMENT="CHARSETALIASDIR=\"\$(abs_top_builddir)/$gl_source_base\""
18476
18477
18478
18479
18480
18481
18482
18483
18484
18485 case "$host_os" in
18486 solaris*)
18487
18488$as_echo "#define _LCONV_C99 1" >>confdefs.h
18489
18490 ;;
18491 esac
18492
18493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether locale.h conforms to POSIX:2001" >&5
18494$as_echo_n "checking whether locale.h conforms to POSIX:2001... " >&6; }
18495if ${gl_cv_header_locale_h_posix2001+:} false; then :
18496 $as_echo_n "(cached) " >&6
18497else
18498 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18499/* end confdefs.h. */
18500#include <locale.h>
18501 int x = LC_MESSAGES;
18502 int y = sizeof (((struct lconv *) 0)->decimal_point);
18503int
18504main (void)
18505{
18506
18507 ;
18508 return 0;
18509}
18510_ACEOF
18511if ac_fn_c_try_compile "$LINENO"; then :
18512 gl_cv_header_locale_h_posix2001=yes
18513else
18514 gl_cv_header_locale_h_posix2001=no
18515fi
18516rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18517fi
18518{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_locale_h_posix2001" >&5
18519$as_echo "$gl_cv_header_locale_h_posix2001" >&6; }
18520
18521
18522 if test $ac_cv_header_xlocale_h = yes; then
18523 HAVE_XLOCALE_H=1
18524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether locale.h defines locale_t" >&5
18525$as_echo_n "checking whether locale.h defines locale_t... " >&6; }
18526if ${gl_cv_header_locale_has_locale_t+:} false; then :
18527 $as_echo_n "(cached) " >&6
18528else
18529 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18530/* end confdefs.h. */
18531#include <locale.h>
18532 locale_t x;
18533int
18534main (void)
18535{
18536
18537 ;
18538 return 0;
18539}
18540_ACEOF
18541if ac_fn_c_try_compile "$LINENO"; then :
18542 gl_cv_header_locale_has_locale_t=yes
18543else
18544 gl_cv_header_locale_has_locale_t=no
18545fi
18546rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18547
18548fi
18549{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_locale_has_locale_t" >&5
18550$as_echo "$gl_cv_header_locale_has_locale_t" >&6; }
18551 if test $gl_cv_header_locale_has_locale_t = yes; then
18552 gl_cv_header_locale_h_needs_xlocale_h=no
18553 else
18554 gl_cv_header_locale_h_needs_xlocale_h=yes
18555 fi
18556 else
18557 HAVE_XLOCALE_H=0
18558 gl_cv_header_locale_h_needs_xlocale_h=no
18559 fi
18560
18561
18562 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct lconv is properly defined" >&5
18563$as_echo_n "checking whether struct lconv is properly defined... " >&6; }
18564if ${gl_cv_sys_struct_lconv_ok+:} false; then :
18565 $as_echo_n "(cached) " >&6
18566else
18567 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18568/* end confdefs.h. */
18569#include <locale.h>
18570 struct lconv l;
18571 int x = sizeof (l.decimal_point);
18572 int y = sizeof (l.int_p_cs_precedes);
18573int
18574main (void)
18575{
18576
18577 ;
18578 return 0;
18579}
18580_ACEOF
18581if ac_fn_c_try_compile "$LINENO"; then :
18582 gl_cv_sys_struct_lconv_ok=yes
18583else
18584 gl_cv_sys_struct_lconv_ok=no
18585fi
18586rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18587
18588fi
18589{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_lconv_ok" >&5
18590$as_echo "$gl_cv_sys_struct_lconv_ok" >&6; }
18591 if test $gl_cv_sys_struct_lconv_ok = no; then
18592 REPLACE_STRUCT_LCONV=1
18593 fi
18594
18595
18596
18597
18598
18599
18600
18601
18602
18603 if test $gl_cv_have_include_next = yes; then
18604 gl_cv_next_locale_h='<'locale.h'>'
18605 else
18606 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <locale.h>" >&5
18607$as_echo_n "checking absolute name of <locale.h>... " >&6; }
18608if ${gl_cv_next_locale_h+:} false; then :
18609 $as_echo_n "(cached) " >&6
18610else
18611
18612 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18613/* end confdefs.h. */
18614#include <locale.h>
18615
18616_ACEOF
18617 case "$host_os" in
18618 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18619 *) gl_absname_cpp="$ac_cpp" ;;
18620 esac
18621
18622 case "$host_os" in
18623 mingw*)
18624 gl_dirsep_regex='[/\\]'
18625 ;;
18626 *)
18627 gl_dirsep_regex='\/'
18628 ;;
18629 esac
18630 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18631
18632 gl_header_literal_regex=`echo 'locale.h' \
18633 | sed -e "$gl_make_literal_regex_sed"`
18634 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18635 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18636 s|^/[^/]|//&|
18637 p
18638 q
18639 }'
18640 gl_cv_next_locale_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18641 sed -n "$gl_absolute_header_sed"`'"'
18642
18643
18644fi
18645{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_locale_h" >&5
18646$as_echo "$gl_cv_next_locale_h" >&6; }
18647 fi
18648 NEXT_LOCALE_H=$gl_cv_next_locale_h
18649
18650 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18651 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18652 gl_next_as_first_directive='<'locale.h'>'
18653 else
18654 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18655 gl_next_as_first_directive=$gl_cv_next_locale_h
18656 fi
18657 NEXT_AS_FIRST_DIRECTIVE_LOCALE_H=$gl_next_as_first_directive
18658
18659
18660
18661
18662
18663
18664 for gl_func in setlocale duplocale; do
18665 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
18666 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
18667$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
18668if eval \${$as_gl_Symbol+:} false; then :
18669 $as_echo_n "(cached) " >&6
18670else
18671 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18672/* end confdefs.h. */
18673#include <locale.h>
18674/* Some systems provide declarations in a non-standard header. */
18675#if HAVE_XLOCALE_H
18676# include <xlocale.h>
18677#endif
18678
18679int
18680main (void)
18681{
18682#undef $gl_func
18683 (void) $gl_func;
18684 ;
18685 return 0;
18686}
18687_ACEOF
18688if ac_fn_c_try_compile "$LINENO"; then :
18689 eval "$as_gl_Symbol=yes"
18690else
18691 eval "$as_gl_Symbol=no"
18692fi
18693rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18694fi
18695eval ac_res=\$$as_gl_Symbol
18696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18697$as_echo "$ac_res" >&6; }
18698 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
18699 cat >>confdefs.h <<_ACEOF
18700#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
18701_ACEOF
18702
18703 eval ac_cv_have_decl_$gl_func=yes
18704fi
18705 done
18706
18707
18708
18709
18710
18711
18712 if test $REPLACE_STRUCT_LCONV = 1; then
18713 REPLACE_LOCALECONV=1
18714 fi
18715
18716 if test $REPLACE_LOCALECONV = 1; then
18717
18718
18719
18720
18721
18722
18723
18724
18725 gl_LIBOBJS="$gl_LIBOBJS localeconv.$ac_objext"
18726
18727
18728 ac_fn_c_check_member "$LINENO" "struct lconv" "decimal_point" "ac_cv_member_struct_lconv_decimal_point" "#include <locale.h>
18729"
18730if test "x$ac_cv_member_struct_lconv_decimal_point" = xyes; then :
18731
18732cat >>confdefs.h <<_ACEOF
18733#define HAVE_STRUCT_LCONV_DECIMAL_POINT 1
18734_ACEOF
18735
18736
18737fi
18738
18739
18740 fi
18741
18742
18743
18744
18745
18746 GNULIB_LOCALECONV=1
18747
18748
18749
18750
18751
18752$as_echo "#define GNULIB_TEST_LOCALECONV 1" >>confdefs.h
18753
18754
18755
18756
18757
18758
18759 for ac_header in stdlib.h
18760do :
18761 ac_fn_c_check_header_mongrel "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default"
18762if test "x$ac_cv_header_stdlib_h" = xyes; then :
18763 cat >>confdefs.h <<_ACEOF
18764#define HAVE_STDLIB_H 1
18765_ACEOF
18766
18767fi
18768
18769done
18770
18771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5
18772$as_echo_n "checking for GNU libc compatible malloc... " >&6; }
18773if ${ac_cv_func_malloc_0_nonnull+:} false; then :
18774 $as_echo_n "(cached) " >&6
18775else
18776 if test "$cross_compiling" = yes; then :
18777 case "$host_os" in
18778 # Guess yes on platforms where we know the result.
18779 *-gnu* | freebsd* | netbsd* | openbsd* \
18780 | hpux* | solaris* | cygwin* | mingw*)
18781 ac_cv_func_malloc_0_nonnull=yes ;;
18782 # If we don't know, assume the worst.
18783 *) ac_cv_func_malloc_0_nonnull=no ;;
18784 esac
18785
18786else
18787 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18788/* end confdefs.h. */
18789#if defined STDC_HEADERS || defined HAVE_STDLIB_H
18790 # include <stdlib.h>
18791 #else
18792 char *malloc ();
18793 #endif
18794
18795int
18796main (void)
18797{
18798return ! malloc (0);
18799 ;
18800 return 0;
18801}
18802
18803_ACEOF
18804if ac_fn_c_try_run "$LINENO"; then :
18805 ac_cv_func_malloc_0_nonnull=yes
18806else
18807 ac_cv_func_malloc_0_nonnull=no
18808fi
18809rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18810 conftest.$ac_objext conftest.beam conftest.$ac_ext
18811fi
18812
18813
18814fi
18815{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_malloc_0_nonnull" >&5
18816$as_echo "$ac_cv_func_malloc_0_nonnull" >&6; }
18817 if test $ac_cv_func_malloc_0_nonnull = yes; then :
18818
18819$as_echo "#define HAVE_MALLOC_GNU 1" >>confdefs.h
18820
18821else
18822 $as_echo "#define HAVE_MALLOC_GNU 0" >>confdefs.h
18823
18824 REPLACE_MALLOC=1
18825
18826fi
18827
18828
18829 if test $REPLACE_MALLOC = 1; then
18830
18831
18832
18833
18834
18835
18836
18837
18838 gl_LIBOBJS="$gl_LIBOBJS malloc.$ac_objext"
18839
18840 fi
18841
18842
18843cat >>confdefs.h <<_ACEOF
18844#define GNULIB_MALLOC_GNU 1
18845_ACEOF
18846
18847
18848
18849
18850
18851 if test $gl_cv_func_malloc_posix = yes; then
18852
18853$as_echo "#define HAVE_MALLOC_POSIX 1" >>confdefs.h
18854
18855 else
18856 REPLACE_MALLOC=1
18857 fi
18858
18859 if test $REPLACE_MALLOC = 1; then
18860
18861
18862
18863
18864
18865
18866
18867
18868 gl_LIBOBJS="$gl_LIBOBJS malloc.$ac_objext"
18869
18870 fi
18871
18872
18873
18874
18875
18876 GNULIB_MALLOC_POSIX=1
18877
18878
18879
18880
18881
18882$as_echo "#define GNULIB_TEST_MALLOC_POSIX 1" >>confdefs.h
18883
18884
18885
18886
18887
18888
18889
18890
18891
18892
18893
18894
18895
18896 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
18897
18898
18899
18900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
18901$as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
18902if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then :
18903 $as_echo_n "(cached) " >&6
18904else
18905
18906 case "$host_os" in
18907 # Guess no on AIX and OSF/1.
18908 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
18909 # Guess yes otherwise.
18910 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
18911 esac
18912 if test $LOCALE_JA != none; then
18913 if test "$cross_compiling" = yes; then :
18914 :
18915else
18916 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18917/* end confdefs.h. */
18918
18919#include <locale.h>
18920#include <string.h>
18921/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
18922 <wchar.h>.
18923 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18924 included before <wchar.h>. */
18925#include <stddef.h>
18926#include <stdio.h>
18927#include <time.h>
18928#include <wchar.h>
18929int main ()
18930{
18931 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
18932 {
18933 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
18934 mbstate_t state;
18935 wchar_t wc;
18936
18937 memset (&state, '\0', sizeof (mbstate_t));
18938 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
18939 if (mbsinit (&state))
18940 return 1;
18941 }
18942 return 0;
18943}
18944_ACEOF
18945if ac_fn_c_try_run "$LINENO"; then :
18946 gl_cv_func_mbrtowc_incomplete_state=yes
18947else
18948 gl_cv_func_mbrtowc_incomplete_state=no
18949fi
18950rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18951 conftest.$ac_objext conftest.beam conftest.$ac_ext
18952fi
18953
18954 fi
18955
18956fi
18957{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
18958$as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
18959
18960
18961
18962
18963 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
18964$as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
18965if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then :
18966 $as_echo_n "(cached) " >&6
18967else
18968
18969 case "$host_os" in
18970 # Guess no on Solaris 8.
18971 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
18972 # Guess yes otherwise.
18973 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
18974 esac
18975 if test $LOCALE_ZH_CN != none; then
18976 if test "$cross_compiling" = yes; then :
18977 :
18978else
18979 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18980/* end confdefs.h. */
18981
18982#include <locale.h>
18983#include <stdlib.h>
18984#include <string.h>
18985/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
18986 <wchar.h>.
18987 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18988 included before <wchar.h>. */
18989#include <stddef.h>
18990#include <stdio.h>
18991#include <time.h>
18992#include <wchar.h>
18993int main ()
18994{
18995 /* This fails on Solaris 8:
18996 mbrtowc returns 2, and sets wc to 0x00F0.
18997 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
18998 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
18999 {
19000 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
19001 mbstate_t state;
19002 wchar_t wc;
19003
19004 memset (&state, '\0', sizeof (mbstate_t));
19005 if (mbrtowc (&wc, input + 3, 6, &state) != 4
19006 && mbtowc (&wc, input + 3, 6) == 4)
19007 return 1;
19008 }
19009 return 0;
19010}
19011_ACEOF
19012if ac_fn_c_try_run "$LINENO"; then :
19013 gl_cv_func_mbrtowc_sanitycheck=yes
19014else
19015 gl_cv_func_mbrtowc_sanitycheck=no
19016fi
19017rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19018 conftest.$ac_objext conftest.beam conftest.$ac_ext
19019fi
19020
19021 fi
19022
19023fi
19024{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
19025$as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
19026
19027 REPLACE_MBSTATE_T=0
19028 case "$gl_cv_func_mbrtowc_incomplete_state" in
19029 *yes) ;;
19030 *) REPLACE_MBSTATE_T=1 ;;
19031 esac
19032 case "$gl_cv_func_mbrtowc_sanitycheck" in
19033 *yes) ;;
19034 *) REPLACE_MBSTATE_T=1 ;;
19035 esac
19036 else
19037 REPLACE_MBSTATE_T=1
19038 fi
19039
19040
19041
19042 if test $ac_cv_func_mbrtowc = no; then
19043 HAVE_MBRTOWC=0
19044 ac_fn_c_check_decl "$LINENO" "mbrtowc" "ac_cv_have_decl_mbrtowc" "
19045/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19046 <wchar.h>.
19047 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19048 included before <wchar.h>. */
19049#include <stddef.h>
19050#include <stdio.h>
19051#include <time.h>
19052#include <wchar.h>
19053
19054"
19055if test "x$ac_cv_have_decl_mbrtowc" = xyes; then :
19056 ac_have_decl=1
19057else
19058 ac_have_decl=0
19059fi
19060
19061cat >>confdefs.h <<_ACEOF
19062#define HAVE_DECL_MBRTOWC $ac_have_decl
19063_ACEOF
19064
19065 if test $ac_cv_have_decl_mbrtowc = yes; then
19066 REPLACE_MBRTOWC=1
19067 fi
19068 else
19069 if test $REPLACE_MBSTATE_T = 1; then
19070 REPLACE_MBRTOWC=1
19071 else
19072
19073
19074
19075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles a NULL pwc argument" >&5
19076$as_echo_n "checking whether mbrtowc handles a NULL pwc argument... " >&6; }
19077if ${gl_cv_func_mbrtowc_null_arg1+:} false; then :
19078 $as_echo_n "(cached) " >&6
19079else
19080
19081 case "$host_os" in
19082 # Guess no on Solaris.
19083 solaris*) gl_cv_func_mbrtowc_null_arg1="guessing no" ;;
19084 # Guess yes otherwise.
19085 *) gl_cv_func_mbrtowc_null_arg1="guessing yes" ;;
19086 esac
19087 if test $LOCALE_FR_UTF8 != none; then
19088 if test "$cross_compiling" = yes; then :
19089 :
19090else
19091 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19092/* end confdefs.h. */
19093
19094#include <locale.h>
19095#include <stdlib.h>
19096#include <string.h>
19097/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19098 <wchar.h>.
19099 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19100 included before <wchar.h>. */
19101#include <stddef.h>
19102#include <stdio.h>
19103#include <time.h>
19104#include <wchar.h>
19105int main ()
19106{
19107 int result = 0;
19108
19109 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
19110 {
19111 char input[] = "\303\237er";
19112 mbstate_t state;
19113 wchar_t wc;
19114 size_t ret;
19115
19116 memset (&state, '\0', sizeof (mbstate_t));
19117 wc = (wchar_t) 0xBADFACE;
19118 ret = mbrtowc (&wc, input, 5, &state);
19119 if (ret != 2)
19120 result |= 1;
19121 if (!mbsinit (&state))
19122 result |= 2;
19123
19124 memset (&state, '\0', sizeof (mbstate_t));
19125 ret = mbrtowc (NULL, input, 5, &state);
19126 if (ret != 2) /* Solaris 7 fails here: ret is -1. */
19127 result |= 4;
19128 if (!mbsinit (&state))
19129 result |= 8;
19130 }
19131 return result;
19132}
19133_ACEOF
19134if ac_fn_c_try_run "$LINENO"; then :
19135 gl_cv_func_mbrtowc_null_arg1=yes
19136else
19137 gl_cv_func_mbrtowc_null_arg1=no
19138fi
19139rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19140 conftest.$ac_objext conftest.beam conftest.$ac_ext
19141fi
19142
19143 fi
19144
19145fi
19146{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_null_arg1" >&5
19147$as_echo "$gl_cv_func_mbrtowc_null_arg1" >&6; }
19148
19149
19150
19151
19152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles a NULL string argument" >&5
19153$as_echo_n "checking whether mbrtowc handles a NULL string argument... " >&6; }
19154if ${gl_cv_func_mbrtowc_null_arg2+:} false; then :
19155 $as_echo_n "(cached) " >&6
19156else
19157
19158 case "$host_os" in
19159 # Guess no on OSF/1.
19160 osf*) gl_cv_func_mbrtowc_null_arg2="guessing no" ;;
19161 # Guess yes otherwise.
19162 *) gl_cv_func_mbrtowc_null_arg2="guessing yes" ;;
19163 esac
19164 if test $LOCALE_FR_UTF8 != none; then
19165 if test "$cross_compiling" = yes; then :
19166 :
19167else
19168 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19169/* end confdefs.h. */
19170
19171#include <locale.h>
19172#include <string.h>
19173/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19174 <wchar.h>.
19175 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19176 included before <wchar.h>. */
19177#include <stddef.h>
19178#include <stdio.h>
19179#include <time.h>
19180#include <wchar.h>
19181int main ()
19182{
19183 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
19184 {
19185 mbstate_t state;
19186 wchar_t wc;
19187 int ret;
19188
19189 memset (&state, '\0', sizeof (mbstate_t));
19190 wc = (wchar_t) 0xBADFACE;
19191 mbrtowc (&wc, NULL, 5, &state);
19192 /* Check that wc was not modified. */
19193 if (wc != (wchar_t) 0xBADFACE)
19194 return 1;
19195 }
19196 return 0;
19197}
19198_ACEOF
19199if ac_fn_c_try_run "$LINENO"; then :
19200 gl_cv_func_mbrtowc_null_arg2=yes
19201else
19202 gl_cv_func_mbrtowc_null_arg2=no
19203fi
19204rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19205 conftest.$ac_objext conftest.beam conftest.$ac_ext
19206fi
19207
19208 fi
19209
19210fi
19211{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_null_arg2" >&5
19212$as_echo "$gl_cv_func_mbrtowc_null_arg2" >&6; }
19213
19214
19215
19216
19217
19218
19219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc has a correct return value" >&5
19220$as_echo_n "checking whether mbrtowc has a correct return value... " >&6; }
19221if ${gl_cv_func_mbrtowc_retval+:} false; then :
19222 $as_echo_n "(cached) " >&6
19223else
19224
19225 case "$host_os" in
19226 # Guess no on HP-UX, Solaris, native Windows.
19227 hpux* | solaris* | mingw*) gl_cv_func_mbrtowc_retval="guessing no" ;;
19228 # Guess yes otherwise.
19229 *) gl_cv_func_mbrtowc_retval="guessing yes" ;;
19230 esac
19231 if test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none \
19232 || { case "$host_os" in mingw*) true;; *) false;; esac; }; then
19233 if test "$cross_compiling" = yes; then :
19234 :
19235else
19236 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19237/* end confdefs.h. */
19238
19239#include <locale.h>
19240#include <string.h>
19241/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19242 <wchar.h>.
19243 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19244 included before <wchar.h>. */
19245#include <stddef.h>
19246#include <stdio.h>
19247#include <time.h>
19248#include <wchar.h>
19249int main ()
19250{
19251 int result = 0;
19252 int found_some_locale = 0;
19253 /* This fails on Solaris. */
19254 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
19255 {
19256 char input[] = "B\303\274\303\237er"; /* "Büßer" */
19257 mbstate_t state;
19258 wchar_t wc;
19259
19260 memset (&state, '\0', sizeof (mbstate_t));
19261 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
19262 {
19263 input[1] = '\0';
19264 if (mbrtowc (&wc, input + 2, 5, &state) != 1)
19265 result |= 1;
19266 }
19267 found_some_locale = 1;
19268 }
19269 /* This fails on HP-UX 11.11. */
19270 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
19271 {
19272 char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
19273 mbstate_t state;
19274 wchar_t wc;
19275
19276 memset (&state, '\0', sizeof (mbstate_t));
19277 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
19278 {
19279 input[1] = '\0';
19280 if (mbrtowc (&wc, input + 2, 5, &state) != 2)
19281 result |= 2;
19282 }
19283 found_some_locale = 1;
19284 }
19285 /* This fails on native Windows. */
19286 if (setlocale (LC_ALL, "Japanese_Japan.932") != NULL)
19287 {
19288 char input[] = "<\223\372\226\173\214\352>"; /* "<日本語>" */
19289 mbstate_t state;
19290 wchar_t wc;
19291
19292 memset (&state, '\0', sizeof (mbstate_t));
19293 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
19294 {
19295 input[3] = '\0';
19296 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
19297 result |= 4;
19298 }
19299 found_some_locale = 1;
19300 }
19301 if (setlocale (LC_ALL, "Chinese_Taiwan.950") != NULL)
19302 {
19303 char input[] = "<\244\351\245\273\273\171>"; /* "<日本語>" */
19304 mbstate_t state;
19305 wchar_t wc;
19306
19307 memset (&state, '\0', sizeof (mbstate_t));
19308 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
19309 {
19310 input[3] = '\0';
19311 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
19312 result |= 8;
19313 }
19314 found_some_locale = 1;
19315 }
19316 if (setlocale (LC_ALL, "Chinese_China.936") != NULL)
19317 {
19318 char input[] = "<\310\325\261\276\325\132>"; /* "<日本語>" */
19319 mbstate_t state;
19320 wchar_t wc;
19321
19322 memset (&state, '\0', sizeof (mbstate_t));
19323 if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
19324 {
19325 input[3] = '\0';
19326 if (mbrtowc (&wc, input + 4, 4, &state) != 1)
19327 result |= 16;
19328 }
19329 found_some_locale = 1;
19330 }
19331 return (found_some_locale ? result : 77);
19332}
19333_ACEOF
19334if ac_fn_c_try_run "$LINENO"; then :
19335 gl_cv_func_mbrtowc_retval=yes
19336else
19337 if test $? != 77; then
19338 gl_cv_func_mbrtowc_retval=no
19339 fi
19340
19341fi
19342rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19343 conftest.$ac_objext conftest.beam conftest.$ac_ext
19344fi
19345
19346 fi
19347
19348fi
19349{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_retval" >&5
19350$as_echo "$gl_cv_func_mbrtowc_retval" >&6; }
19351
19352
19353
19354
19355 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc returns 0 when parsing a NUL character" >&5
19356$as_echo_n "checking whether mbrtowc returns 0 when parsing a NUL character... " >&6; }
19357if ${gl_cv_func_mbrtowc_nul_retval+:} false; then :
19358 $as_echo_n "(cached) " >&6
19359else
19360
19361 case "$host_os" in
19362 # Guess no on Solaris 8 and 9.
19363 solaris2.[89]) gl_cv_func_mbrtowc_nul_retval="guessing no" ;;
19364 # Guess yes otherwise.
19365 *) gl_cv_func_mbrtowc_nul_retval="guessing yes" ;;
19366 esac
19367 if test $LOCALE_ZH_CN != none; then
19368 if test "$cross_compiling" = yes; then :
19369 :
19370else
19371 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19372/* end confdefs.h. */
19373
19374#include <locale.h>
19375#include <string.h>
19376/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19377 <wchar.h>.
19378 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19379 included before <wchar.h>. */
19380#include <stddef.h>
19381#include <stdio.h>
19382#include <time.h>
19383#include <wchar.h>
19384int main ()
19385{
19386 /* This fails on Solaris 8 and 9. */
19387 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
19388 {
19389 mbstate_t state;
19390 wchar_t wc;
19391
19392 memset (&state, '\0', sizeof (mbstate_t));
19393 if (mbrtowc (&wc, "", 1, &state) != 0)
19394 return 1;
19395 }
19396 return 0;
19397}
19398_ACEOF
19399if ac_fn_c_try_run "$LINENO"; then :
19400 gl_cv_func_mbrtowc_nul_retval=yes
19401else
19402 gl_cv_func_mbrtowc_nul_retval=no
19403fi
19404rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19405 conftest.$ac_objext conftest.beam conftest.$ac_ext
19406fi
19407
19408 fi
19409
19410fi
19411{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_nul_retval" >&5
19412$as_echo "$gl_cv_func_mbrtowc_nul_retval" >&6; }
19413
19414 case "$gl_cv_func_mbrtowc_null_arg1" in
19415 *yes) ;;
19416 *)
19417$as_echo "#define MBRTOWC_NULL_ARG1_BUG 1" >>confdefs.h
19418
19419 REPLACE_MBRTOWC=1
19420 ;;
19421 esac
19422 case "$gl_cv_func_mbrtowc_null_arg2" in
19423 *yes) ;;
19424 *)
19425$as_echo "#define MBRTOWC_NULL_ARG2_BUG 1" >>confdefs.h
19426
19427 REPLACE_MBRTOWC=1
19428 ;;
19429 esac
19430 case "$gl_cv_func_mbrtowc_retval" in
19431 *yes) ;;
19432 *)
19433$as_echo "#define MBRTOWC_RETVAL_BUG 1" >>confdefs.h
19434
19435 REPLACE_MBRTOWC=1
19436 ;;
19437 esac
19438 case "$gl_cv_func_mbrtowc_nul_retval" in
19439 *yes) ;;
19440 *)
19441$as_echo "#define MBRTOWC_NUL_RETVAL_BUG 1" >>confdefs.h
19442
19443 REPLACE_MBRTOWC=1
19444 ;;
19445 esac
19446 fi
19447 fi
19448
19449 if test $HAVE_MBRTOWC = 0 || test $REPLACE_MBRTOWC = 1; then
19450
19451
19452
19453
19454
19455
19456
19457
19458 gl_LIBOBJS="$gl_LIBOBJS mbrtowc.$ac_objext"
19459
19460
19461 :
19462
19463 fi
19464
19465
19466
19467
19468
19469 GNULIB_MBRTOWC=1
19470
19471
19472
19473
19474
19475$as_echo "#define GNULIB_TEST_MBRTOWC 1" >>confdefs.h
19476
19477
19478
19479
19480
19481
19482
19483
19484
19485
19486
19487
19488
19489
19490 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
19491
19492
19493
19494 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
19495$as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
19496if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then :
19497 $as_echo_n "(cached) " >&6
19498else
19499
19500 case "$host_os" in
19501 # Guess no on AIX and OSF/1.
19502 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
19503 # Guess yes otherwise.
19504 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
19505 esac
19506 if test $LOCALE_JA != none; then
19507 if test "$cross_compiling" = yes; then :
19508 :
19509else
19510 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19511/* end confdefs.h. */
19512
19513#include <locale.h>
19514#include <string.h>
19515/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19516 <wchar.h>.
19517 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19518 included before <wchar.h>. */
19519#include <stddef.h>
19520#include <stdio.h>
19521#include <time.h>
19522#include <wchar.h>
19523int main ()
19524{
19525 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
19526 {
19527 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
19528 mbstate_t state;
19529 wchar_t wc;
19530
19531 memset (&state, '\0', sizeof (mbstate_t));
19532 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
19533 if (mbsinit (&state))
19534 return 1;
19535 }
19536 return 0;
19537}
19538_ACEOF
19539if ac_fn_c_try_run "$LINENO"; then :
19540 gl_cv_func_mbrtowc_incomplete_state=yes
19541else
19542 gl_cv_func_mbrtowc_incomplete_state=no
19543fi
19544rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19545 conftest.$ac_objext conftest.beam conftest.$ac_ext
19546fi
19547
19548 fi
19549
19550fi
19551{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
19552$as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
19553
19554
19555
19556
19557 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
19558$as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
19559if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then :
19560 $as_echo_n "(cached) " >&6
19561else
19562
19563 case "$host_os" in
19564 # Guess no on Solaris 8.
19565 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
19566 # Guess yes otherwise.
19567 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
19568 esac
19569 if test $LOCALE_ZH_CN != none; then
19570 if test "$cross_compiling" = yes; then :
19571 :
19572else
19573 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19574/* end confdefs.h. */
19575
19576#include <locale.h>
19577#include <stdlib.h>
19578#include <string.h>
19579/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19580 <wchar.h>.
19581 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19582 included before <wchar.h>. */
19583#include <stddef.h>
19584#include <stdio.h>
19585#include <time.h>
19586#include <wchar.h>
19587int main ()
19588{
19589 /* This fails on Solaris 8:
19590 mbrtowc returns 2, and sets wc to 0x00F0.
19591 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
19592 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
19593 {
19594 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
19595 mbstate_t state;
19596 wchar_t wc;
19597
19598 memset (&state, '\0', sizeof (mbstate_t));
19599 if (mbrtowc (&wc, input + 3, 6, &state) != 4
19600 && mbtowc (&wc, input + 3, 6) == 4)
19601 return 1;
19602 }
19603 return 0;
19604}
19605_ACEOF
19606if ac_fn_c_try_run "$LINENO"; then :
19607 gl_cv_func_mbrtowc_sanitycheck=yes
19608else
19609 gl_cv_func_mbrtowc_sanitycheck=no
19610fi
19611rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19612 conftest.$ac_objext conftest.beam conftest.$ac_ext
19613fi
19614
19615 fi
19616
19617fi
19618{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
19619$as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
19620
19621 REPLACE_MBSTATE_T=0
19622 case "$gl_cv_func_mbrtowc_incomplete_state" in
19623 *yes) ;;
19624 *) REPLACE_MBSTATE_T=1 ;;
19625 esac
19626 case "$gl_cv_func_mbrtowc_sanitycheck" in
19627 *yes) ;;
19628 *) REPLACE_MBSTATE_T=1 ;;
19629 esac
19630 else
19631 REPLACE_MBSTATE_T=1
19632 fi
19633
19634
19635
19636 if test $ac_cv_func_mbsinit = no; then
19637 HAVE_MBSINIT=0
19638 ac_fn_c_check_decl "$LINENO" "mbsinit" "ac_cv_have_decl_mbsinit" "
19639/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19640 <wchar.h>.
19641 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19642 included before <wchar.h>. */
19643#include <stddef.h>
19644#include <stdio.h>
19645#include <time.h>
19646#include <wchar.h>
19647
19648"
19649if test "x$ac_cv_have_decl_mbsinit" = xyes; then :
19650 ac_have_decl=1
19651else
19652 ac_have_decl=0
19653fi
19654
19655cat >>confdefs.h <<_ACEOF
19656#define HAVE_DECL_MBSINIT $ac_have_decl
19657_ACEOF
19658
19659 if test $ac_cv_have_decl_mbsinit = yes; then
19660 REPLACE_MBSINIT=1
19661 fi
19662 else
19663 if test $REPLACE_MBSTATE_T = 1; then
19664 REPLACE_MBSINIT=1
19665 else
19666 case "$host_os" in
19667 mingw*) REPLACE_MBSINIT=1 ;;
19668 esac
19669 fi
19670 fi
19671
19672 if test $HAVE_MBSINIT = 0 || test $REPLACE_MBSINIT = 1; then
19673
19674
19675
19676
19677
19678
19679
19680
19681 gl_LIBOBJS="$gl_LIBOBJS mbsinit.$ac_objext"
19682
19683
19684 :
19685
19686 fi
19687
19688
19689
19690
19691
19692 GNULIB_MBSINIT=1
19693
19694
19695
19696
19697
19698$as_echo "#define GNULIB_TEST_MBSINIT 1" >>confdefs.h
19699
19700
19701
19702
19703
19704
19705
19706
19707
19708
19709
19710
19711
19712 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
19713
19714
19715
19716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
19717$as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
19718if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then :
19719 $as_echo_n "(cached) " >&6
19720else
19721
19722 case "$host_os" in
19723 # Guess no on AIX and OSF/1.
19724 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
19725 # Guess yes otherwise.
19726 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
19727 esac
19728 if test $LOCALE_JA != none; then
19729 if test "$cross_compiling" = yes; then :
19730 :
19731else
19732 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19733/* end confdefs.h. */
19734
19735#include <locale.h>
19736#include <string.h>
19737/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19738 <wchar.h>.
19739 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19740 included before <wchar.h>. */
19741#include <stddef.h>
19742#include <stdio.h>
19743#include <time.h>
19744#include <wchar.h>
19745int main ()
19746{
19747 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
19748 {
19749 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
19750 mbstate_t state;
19751 wchar_t wc;
19752
19753 memset (&state, '\0', sizeof (mbstate_t));
19754 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
19755 if (mbsinit (&state))
19756 return 1;
19757 }
19758 return 0;
19759}
19760_ACEOF
19761if ac_fn_c_try_run "$LINENO"; then :
19762 gl_cv_func_mbrtowc_incomplete_state=yes
19763else
19764 gl_cv_func_mbrtowc_incomplete_state=no
19765fi
19766rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19767 conftest.$ac_objext conftest.beam conftest.$ac_ext
19768fi
19769
19770 fi
19771
19772fi
19773{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
19774$as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
19775
19776
19777
19778
19779 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
19780$as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
19781if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then :
19782 $as_echo_n "(cached) " >&6
19783else
19784
19785 case "$host_os" in
19786 # Guess no on Solaris 8.
19787 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
19788 # Guess yes otherwise.
19789 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
19790 esac
19791 if test $LOCALE_ZH_CN != none; then
19792 if test "$cross_compiling" = yes; then :
19793 :
19794else
19795 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19796/* end confdefs.h. */
19797
19798#include <locale.h>
19799#include <stdlib.h>
19800#include <string.h>
19801/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19802 <wchar.h>.
19803 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19804 included before <wchar.h>. */
19805#include <stddef.h>
19806#include <stdio.h>
19807#include <time.h>
19808#include <wchar.h>
19809int main ()
19810{
19811 /* This fails on Solaris 8:
19812 mbrtowc returns 2, and sets wc to 0x00F0.
19813 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
19814 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
19815 {
19816 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
19817 mbstate_t state;
19818 wchar_t wc;
19819
19820 memset (&state, '\0', sizeof (mbstate_t));
19821 if (mbrtowc (&wc, input + 3, 6, &state) != 4
19822 && mbtowc (&wc, input + 3, 6) == 4)
19823 return 1;
19824 }
19825 return 0;
19826}
19827_ACEOF
19828if ac_fn_c_try_run "$LINENO"; then :
19829 gl_cv_func_mbrtowc_sanitycheck=yes
19830else
19831 gl_cv_func_mbrtowc_sanitycheck=no
19832fi
19833rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19834 conftest.$ac_objext conftest.beam conftest.$ac_ext
19835fi
19836
19837 fi
19838
19839fi
19840{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
19841$as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
19842
19843 REPLACE_MBSTATE_T=0
19844 case "$gl_cv_func_mbrtowc_incomplete_state" in
19845 *yes) ;;
19846 *) REPLACE_MBSTATE_T=1 ;;
19847 esac
19848 case "$gl_cv_func_mbrtowc_sanitycheck" in
19849 *yes) ;;
19850 *) REPLACE_MBSTATE_T=1 ;;
19851 esac
19852 else
19853 REPLACE_MBSTATE_T=1
19854 fi
19855
19856
19857
19858 if test $ac_cv_func_mbsrtowcs = no; then
19859 HAVE_MBSRTOWCS=0
19860 ac_fn_c_check_decl "$LINENO" "mbsrtowcs" "ac_cv_have_decl_mbsrtowcs" "
19861/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19862 <wchar.h>.
19863 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19864 included before <wchar.h>. */
19865#include <stddef.h>
19866#include <stdio.h>
19867#include <time.h>
19868#include <wchar.h>
19869
19870"
19871if test "x$ac_cv_have_decl_mbsrtowcs" = xyes; then :
19872 ac_have_decl=1
19873else
19874 ac_have_decl=0
19875fi
19876
19877cat >>confdefs.h <<_ACEOF
19878#define HAVE_DECL_MBSRTOWCS $ac_have_decl
19879_ACEOF
19880
19881 if test $ac_cv_have_decl_mbsrtowcs = yes; then
19882 REPLACE_MBSRTOWCS=1
19883 fi
19884 else
19885 if test $REPLACE_MBSTATE_T = 1; then
19886 REPLACE_MBSRTOWCS=1
19887 else
19888
19889
19890
19891
19892
19893
19894 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbsrtowcs works" >&5
19895$as_echo_n "checking whether mbsrtowcs works... " >&6; }
19896if ${gl_cv_func_mbsrtowcs_works+:} false; then :
19897 $as_echo_n "(cached) " >&6
19898else
19899
19900 case "$host_os" in
19901 # Guess no on HP-UX, Solaris, mingw.
19902 hpux* | solaris* | mingw*) gl_cv_func_mbsrtowcs_works="guessing no" ;;
19903 # Guess yes otherwise.
19904 *) gl_cv_func_mbsrtowcs_works="guessing yes" ;;
19905 esac
19906 if test $LOCALE_FR != none || test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none || test $LOCALE_ZH_CN != none; then
19907 if test "$cross_compiling" = yes; then :
19908 :
19909else
19910 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19911/* end confdefs.h. */
19912
19913#include <locale.h>
19914#include <string.h>
19915/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
19916 <wchar.h>.
19917 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19918 included before <wchar.h>. */
19919#include <stddef.h>
19920#include <stdio.h>
19921#include <time.h>
19922#include <wchar.h>
19923int main ()
19924{
19925 int result = 0;
19926 /* Test whether the function supports a NULL destination argument.
19927 This fails on native Windows. */
19928 if (setlocale (LC_ALL, "$LOCALE_FR") != NULL)
19929 {
19930 const char input[] = "\337er";
19931 const char *src = input;
19932 mbstate_t state;
19933
19934 memset (&state, '\0', sizeof (mbstate_t));
19935 if (mbsrtowcs (NULL, &src, 1, &state) != 3
19936 || src != input)
19937 result |= 1;
19938 }
19939 /* Test whether the function works when started with a conversion state
19940 in non-initial state. This fails on HP-UX 11.11 and Solaris 10. */
19941 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
19942 {
19943 const char input[] = "B\303\274\303\237er";
19944 mbstate_t state;
19945
19946 memset (&state, '\0', sizeof (mbstate_t));
19947 if (mbrtowc (NULL, input + 1, 1, &state) == (size_t)(-2))
19948 if (!mbsinit (&state))
19949 {
19950 const char *src = input + 2;
19951 if (mbsrtowcs (NULL, &src, 10, &state) != 4)
19952 result |= 2;
19953 }
19954 }
19955 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
19956 {
19957 const char input[] = "<\306\374\313\334\270\354>";
19958 mbstate_t state;
19959
19960 memset (&state, '\0', sizeof (mbstate_t));
19961 if (mbrtowc (NULL, input + 3, 1, &state) == (size_t)(-2))
19962 if (!mbsinit (&state))
19963 {
19964 const char *src = input + 4;
19965 if (mbsrtowcs (NULL, &src, 10, &state) != 3)
19966 result |= 4;
19967 }
19968 }
19969 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
19970 {
19971 const char input[] = "B\250\271\201\060\211\070er";
19972 mbstate_t state;
19973
19974 memset (&state, '\0', sizeof (mbstate_t));
19975 if (mbrtowc (NULL, input + 1, 1, &state) == (size_t)(-2))
19976 if (!mbsinit (&state))
19977 {
19978 const char *src = input + 2;
19979 if (mbsrtowcs (NULL, &src, 10, &state) != 4)
19980 result |= 8;
19981 }
19982 }
19983 return result;
19984}
19985_ACEOF
19986if ac_fn_c_try_run "$LINENO"; then :
19987 gl_cv_func_mbsrtowcs_works=yes
19988else
19989 gl_cv_func_mbsrtowcs_works=no
19990fi
19991rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19992 conftest.$ac_objext conftest.beam conftest.$ac_ext
19993fi
19994
19995 fi
19996
19997fi
19998{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbsrtowcs_works" >&5
19999$as_echo "$gl_cv_func_mbsrtowcs_works" >&6; }
20000
20001 case "$gl_cv_func_mbsrtowcs_works" in
20002 *yes) ;;
20003 *) REPLACE_MBSRTOWCS=1 ;;
20004 esac
20005 fi
20006 fi
20007
20008 if test $HAVE_MBSRTOWCS = 0 || test $REPLACE_MBSRTOWCS = 1; then
20009
20010
20011
20012
20013
20014
20015
20016
20017 gl_LIBOBJS="$gl_LIBOBJS mbsrtowcs.$ac_objext"
20018
20019
20020
20021
20022
20023
20024
20025
20026
20027 gl_LIBOBJS="$gl_LIBOBJS mbsrtowcs-state.$ac_objext"
20028
20029
20030 :
20031
20032 fi
20033
20034
20035
20036
20037
20038 GNULIB_MBSRTOWCS=1
20039
20040
20041
20042
20043
20044$as_echo "#define GNULIB_TEST_MBSRTOWCS 1" >>confdefs.h
20045
20046
20047
20048
20049
20050
20051
20052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbswidth is declared in <wchar.h>" >&5
20053$as_echo_n "checking whether mbswidth is declared in <wchar.h>... " >&6; }
20054if ${ac_cv_have_decl_mbswidth+:} false; then :
20055 $as_echo_n "(cached) " >&6
20056else
20057 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20058/* end confdefs.h. */
20059
20060/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
20061 <wchar.h>.
20062 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
20063 before <wchar.h>. */
20064#include <stddef.h>
20065#include <stdio.h>
20066#include <time.h>
20067#include <wchar.h>
20068
20069int
20070main (void)
20071{
20072
20073 char *p = (char *) mbswidth;
20074 return !p;
20075
20076 ;
20077 return 0;
20078}
20079_ACEOF
20080if ac_fn_c_try_compile "$LINENO"; then :
20081 ac_cv_have_decl_mbswidth=yes
20082else
20083 ac_cv_have_decl_mbswidth=no
20084fi
20085rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20086fi
20087{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_decl_mbswidth" >&5
20088$as_echo "$ac_cv_have_decl_mbswidth" >&6; }
20089 if test $ac_cv_have_decl_mbswidth = yes; then
20090 ac_val=1
20091 else
20092 ac_val=0
20093 fi
20094
20095cat >>confdefs.h <<_ACEOF
20096#define HAVE_DECL_MBSWIDTH_IN_WCHAR_H $ac_val
20097_ACEOF
20098
20099
20100
20101
20102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
20103$as_echo_n "checking for mbstate_t... " >&6; }
20104if ${ac_cv_type_mbstate_t+:} false; then :
20105 $as_echo_n "(cached) " >&6
20106else
20107 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20108/* end confdefs.h. */
20109$ac_includes_default
20110/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
20111 <wchar.h>.
20112 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20113 included before <wchar.h>. */
20114#include <stddef.h>
20115#include <stdio.h>
20116#include <time.h>
20117#include <wchar.h>
20118int
20119main (void)
20120{
20121mbstate_t x; return sizeof x;
20122 ;
20123 return 0;
20124}
20125_ACEOF
20126if ac_fn_c_try_compile "$LINENO"; then :
20127 ac_cv_type_mbstate_t=yes
20128else
20129 ac_cv_type_mbstate_t=no
20130fi
20131rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20132fi
20133{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
20134$as_echo "$ac_cv_type_mbstate_t" >&6; }
20135 if test $ac_cv_type_mbstate_t = yes; then
20136
20137$as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
20138
20139 else
20140
20141$as_echo "#define mbstate_t int" >>confdefs.h
20142
20143 fi
20144
20145
20146
20147
20148
20149 if false; then
20150 REPLACE_MBTOWC=1
20151 fi
20152
20153 if test $REPLACE_MBTOWC = 1; then
20154
20155
20156
20157
20158
20159
20160
20161
20162 gl_LIBOBJS="$gl_LIBOBJS mbtowc.$ac_objext"
20163
20164
20165 :
20166
20167 fi
20168
20169
20170
20171
20172
20173 GNULIB_MBTOWC=1
20174
20175
20176
20177
20178
20179$as_echo "#define GNULIB_TEST_MBTOWC 1" >>confdefs.h
20180
20181
20182
20183
20184 if test $HAVE_MEMCHR = 0 || test $REPLACE_MEMCHR = 1; then
20185
20186
20187
20188
20189
20190
20191
20192
20193 gl_LIBOBJS="$gl_LIBOBJS memchr.$ac_objext"
20194
20195
20196 for ac_header in bp-sym.h
20197do :
20198 ac_fn_c_check_header_mongrel "$LINENO" "bp-sym.h" "ac_cv_header_bp_sym_h" "$ac_includes_default"
20199if test "x$ac_cv_header_bp_sym_h" = xyes; then :
20200 cat >>confdefs.h <<_ACEOF
20201#define HAVE_BP_SYM_H 1
20202_ACEOF
20203
20204fi
20205
20206done
20207
20208
20209 fi
20210
20211
20212
20213
20214
20215 GNULIB_MEMCHR=1
20216
20217
20218
20219
20220
20221$as_echo "#define GNULIB_TEST_MEMCHR 1" >>confdefs.h
20222
20223
20224
20225
20226
20227
20228
20229
20230
20231 for ac_func in mempcpy
20232do :
20233 ac_fn_c_check_func "$LINENO" "mempcpy" "ac_cv_func_mempcpy"
20234if test "x$ac_cv_func_mempcpy" = xyes; then :
20235 cat >>confdefs.h <<_ACEOF
20236#define HAVE_MEMPCPY 1
20237_ACEOF
20238
20239fi
20240done
20241
20242 if test $ac_cv_func_mempcpy = no; then
20243 HAVE_MEMPCPY=0
20244 fi
20245
20246 if test $HAVE_MEMPCPY = 0; then
20247
20248
20249
20250
20251
20252
20253
20254
20255 gl_LIBOBJS="$gl_LIBOBJS mempcpy.$ac_objext"
20256
20257
20258 :
20259
20260 fi
20261
20262
20263
20264
20265
20266 GNULIB_MEMPCPY=1
20267
20268
20269
20270
20271
20272$as_echo "#define GNULIB_TEST_MEMPCPY 1" >>confdefs.h
20273
20274
20275
20276
20277
20278 if test $ac_cv_func__set_invalid_parameter_handler = yes; then
20279 HAVE_MSVC_INVALID_PARAMETER_HANDLER=1
20280
20281$as_echo "#define HAVE_MSVC_INVALID_PARAMETER_HANDLER 1" >>confdefs.h
20282
20283 else
20284 HAVE_MSVC_INVALID_PARAMETER_HANDLER=0
20285 fi
20286
20287
20288 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
20289
20290
20291
20292
20293
20294
20295
20296
20297 gl_LIBOBJS="$gl_LIBOBJS msvc-inval.$ac_objext"
20298
20299 fi
20300
20301
20302
20303 if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
20304
20305
20306
20307
20308
20309
20310
20311
20312 gl_LIBOBJS="$gl_LIBOBJS msvc-nothrow.$ac_objext"
20313
20314 fi
20315
20316
20317
20318
20319
20320 if test $ac_cv_func_nl_langinfo = yes; then
20321 # On Irix 6.5, YESEXPR is defined, but nl_langinfo(YESEXPR) is broken.
20322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether YESEXPR works" >&5
20323$as_echo_n "checking whether YESEXPR works... " >&6; }
20324if ${gl_cv_func_nl_langinfo_yesexpr_works+:} false; then :
20325 $as_echo_n "(cached) " >&6
20326else
20327 if test "$cross_compiling" = yes; then :
20328
20329 case "$host_os" in
20330 # Guess no on irix systems.
20331 irix*) gl_cv_func_nl_langinfo_yesexpr_works="guessing no";;
20332 # Guess yes elsewhere.
20333 *) gl_cv_func_nl_langinfo_yesexpr_works="guessing yes";;
20334 esac
20335
20336else
20337 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20338/* end confdefs.h. */
20339#include <langinfo.h>
20340
20341int
20342main (void)
20343{
20344return !*nl_langinfo(YESEXPR);
20345
20346 ;
20347 return 0;
20348}
20349_ACEOF
20350if ac_fn_c_try_run "$LINENO"; then :
20351 gl_cv_func_nl_langinfo_yesexpr_works=yes
20352else
20353 gl_cv_func_nl_langinfo_yesexpr_works=no
20354fi
20355rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20356 conftest.$ac_objext conftest.beam conftest.$ac_ext
20357fi
20358
20359
20360fi
20361{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_nl_langinfo_yesexpr_works" >&5
20362$as_echo "$gl_cv_func_nl_langinfo_yesexpr_works" >&6; }
20363 case $gl_cv_func_nl_langinfo_yesexpr_works in
20364 *yes) FUNC_NL_LANGINFO_YESEXPR_WORKS=1 ;;
20365 *) FUNC_NL_LANGINFO_YESEXPR_WORKS=0 ;;
20366 esac
20367
20368cat >>confdefs.h <<_ACEOF
20369#define FUNC_NL_LANGINFO_YESEXPR_WORKS $FUNC_NL_LANGINFO_YESEXPR_WORKS
20370_ACEOF
20371
20372 if test $HAVE_LANGINFO_CODESET = 1 && test $HAVE_LANGINFO_ERA = 1 \
20373 && test $FUNC_NL_LANGINFO_YESEXPR_WORKS = 1; then
20374 :
20375 else
20376 REPLACE_NL_LANGINFO=1
20377
20378$as_echo "#define REPLACE_NL_LANGINFO 1" >>confdefs.h
20379
20380 fi
20381 else
20382 HAVE_NL_LANGINFO=0
20383 fi
20384
20385 if test $HAVE_NL_LANGINFO = 0 || test $REPLACE_NL_LANGINFO = 1; then
20386
20387
20388
20389
20390
20391
20392
20393
20394 gl_LIBOBJS="$gl_LIBOBJS nl_langinfo.$ac_objext"
20395
20396 fi
20397
20398
20399
20400
20401
20402 GNULIB_NL_LANGINFO=1
20403
20404
20405
20406
20407
20408$as_echo "#define GNULIB_TEST_NL_LANGINFO 1" >>confdefs.h
20409
20410
20411
20412 ac_fn_c_check_decl "$LINENO" "program_invocation_name" "ac_cv_have_decl_program_invocation_name" "#include <errno.h>
20413"
20414if test "x$ac_cv_have_decl_program_invocation_name" = xyes; then :
20415 ac_have_decl=1
20416else
20417 ac_have_decl=0
20418fi
20419
20420cat >>confdefs.h <<_ACEOF
20421#define HAVE_DECL_PROGRAM_INVOCATION_NAME $ac_have_decl
20422_ACEOF
20423
20424 ac_fn_c_check_decl "$LINENO" "program_invocation_short_name" "ac_cv_have_decl_program_invocation_short_name" "#include <errno.h>
20425"
20426if test "x$ac_cv_have_decl_program_invocation_short_name" = xyes; then :
20427 ac_have_decl=1
20428else
20429 ac_have_decl=0
20430fi
20431
20432cat >>confdefs.h <<_ACEOF
20433#define HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME $ac_have_decl
20434_ACEOF
20435
20436
20437
20438
20439
20440 for ac_func in rawmemchr
20441do :
20442 ac_fn_c_check_func "$LINENO" "rawmemchr" "ac_cv_func_rawmemchr"
20443if test "x$ac_cv_func_rawmemchr" = xyes; then :
20444 cat >>confdefs.h <<_ACEOF
20445#define HAVE_RAWMEMCHR 1
20446_ACEOF
20447
20448fi
20449done
20450
20451 if test $ac_cv_func_rawmemchr = no; then
20452 HAVE_RAWMEMCHR=0
20453 fi
20454
20455 if test $HAVE_RAWMEMCHR = 0; then
20456
20457
20458
20459
20460
20461
20462
20463
20464 gl_LIBOBJS="$gl_LIBOBJS rawmemchr.$ac_objext"
20465
20466 :
20467 fi
20468
20469
20470
20471
20472
20473 GNULIB_RAWMEMCHR=1
20474
20475
20476
20477
20478
20479$as_echo "#define GNULIB_TEST_RAWMEMCHR 1" >>confdefs.h
20480
20481
20482
20483
20484
20485
20486 if test $gl_cv_func_malloc_posix = yes; then
20487
20488$as_echo "#define HAVE_REALLOC_POSIX 1" >>confdefs.h
20489
20490 else
20491 REPLACE_REALLOC=1
20492 fi
20493
20494 if test $REPLACE_REALLOC = 1; then
20495
20496
20497
20498
20499
20500
20501
20502
20503 gl_LIBOBJS="$gl_LIBOBJS realloc.$ac_objext"
20504
20505 fi
20506
20507
20508
20509
20510
20511 GNULIB_REALLOC_POSIX=1
20512
20513
20514
20515
20516
20517$as_echo "#define GNULIB_TEST_REALLOC_POSIX 1" >>confdefs.h
20518
20519
20520
20521
20522
20523# Check whether --with-included-regex was given.
20524if test "${with_included_regex+set}" = set; then :
20525 withval=$with_included_regex;
20526fi
20527
20528
20529 case $with_included_regex in #(
20530 yes|no) ac_use_included_regex=$with_included_regex
20531 ;;
20532 '')
20533 # If the system regex support is good enough that it passes the
20534 # following run test, then default to *not* using the included regex.c.
20535 # If cross compiling, assume the test would fail and use the included
20536 # regex.c.
20537
20538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working re_compile_pattern" >&5
20539$as_echo_n "checking for working re_compile_pattern... " >&6; }
20540if ${gl_cv_func_re_compile_pattern_working+:} false; then :
20541 $as_echo_n "(cached) " >&6
20542else
20543 if test "$cross_compiling" = yes; then :
20544 gl_cv_func_re_compile_pattern_working=no
20545else
20546 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20547/* end confdefs.h. */
20548#include <regex.h>
20549
20550 #include <locale.h>
20551 #include <limits.h>
20552 #include <string.h>
20553 #if HAVE_DECL_ALARM
20554 # include <unistd.h>
20555 # include <signal.h>
20556 #endif
20557
20558int
20559main (void)
20560{
20561int result = 0;
20562 static struct re_pattern_buffer regex;
20563 unsigned char folded_chars[UCHAR_MAX + 1];
20564 int i;
20565 const char *s;
20566 struct re_registers regs;
20567
20568#if HAVE_DECL_ALARM
20569 /* Some builds of glibc go into an infinite loop on this test. */
20570 signal (SIGALRM, SIG_DFL);
20571 alarm (2);
20572#endif
20573 if (setlocale (LC_ALL, "en_US.UTF-8"))
20574 {
20575 {
20576 /* http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html
20577 This test needs valgrind to catch the bug on Debian
20578 GNU/Linux 3.1 x86, but it might catch the bug better
20579 on other platforms and it shouldn't hurt to try the
20580 test here. */
20581 static char const pat[] = "insert into";
20582 static char const data[] =
20583 "\xFF\0\x12\xA2\xAA\xC4\xB1,K\x12\xC4\xB1*\xACK";
20584 re_set_syntax (RE_SYNTAX_GREP | RE_HAT_LISTS_NOT_NEWLINE
20585 | RE_ICASE);
20586 memset (&regex, 0, sizeof regex);
20587 s = re_compile_pattern (pat, sizeof pat - 1, &regex);
20588 if (s)
20589 result |= 1;
20590 else if (re_search (&regex, data, sizeof data - 1,
20591 0, sizeof data - 1, &regs)
20592 != -1)
20593 result |= 1;
20594 }
20595
20596 {
20597 /* This test is from glibc bug 15078.
20598 The test case is from Andreas Schwab in
20599 <http://www.sourceware.org/ml/libc-alpha/2013-01/msg00967.html>.
20600 */
20601 static char const pat[] = "[^x]x";
20602 static char const data[] =
20603 "\xe1\x80\x80\xe1\x80\xbb\xe1\x80\xbd\xe1\x80\x94\xe1\x80"
20604 "\xba\xe1\x80\xaf\xe1\x80\x95\xe1\x80\xbax";
20605 re_set_syntax (0);
20606 memset (&regex, 0, sizeof regex);
20607 s = re_compile_pattern (pat, sizeof pat - 1, &regex);
20608 if (s)
20609 result |= 1;
20610 else if (re_search (&regex, data, sizeof data - 1,
20611 0, sizeof data - 1, 0)
20612 != 21)
20613 result |= 1;
20614 }
20615
20616 if (! setlocale (LC_ALL, "C"))
20617 return 1;
20618 }
20619
20620 /* This test is from glibc bug 3957, reported by Andrew Mackey. */
20621 re_set_syntax (RE_SYNTAX_EGREP | RE_HAT_LISTS_NOT_NEWLINE);
20622 memset (&regex, 0, sizeof regex);
20623 s = re_compile_pattern ("a[^x]b", 6, &regex);
20624 if (s)
20625 result |= 2;
20626 /* This should fail, but succeeds for glibc-2.5. */
20627 else if (re_search (&regex, "a\nb", 3, 0, 3, &regs) != -1)
20628 result |= 2;
20629
20630 /* This regular expression is from Spencer ere test number 75
20631 in grep-2.3. */
20632 re_set_syntax (RE_SYNTAX_POSIX_EGREP);
20633 memset (&regex, 0, sizeof regex);
20634 for (i = 0; i <= UCHAR_MAX; i++)
20635 folded_chars[i] = i;
20636 regex.translate = folded_chars;
20637 s = re_compile_pattern ("a[[:]:]]b\n", 11, &regex);
20638 /* This should fail with _Invalid character class name_ error. */
20639 if (!s)
20640 result |= 4;
20641
20642 /* Ensure that [b-a] is diagnosed as invalid, when
20643 using RE_NO_EMPTY_RANGES. */
20644 re_set_syntax (RE_SYNTAX_POSIX_EGREP | RE_NO_EMPTY_RANGES);
20645 memset (&regex, 0, sizeof regex);
20646 s = re_compile_pattern ("a[b-a]", 6, &regex);
20647 if (s == 0)
20648 result |= 8;
20649
20650 /* This should succeed, but does not for glibc-2.1.3. */
20651 memset (&regex, 0, sizeof regex);
20652 s = re_compile_pattern ("{1", 2, &regex);
20653 if (s)
20654 result |= 8;
20655
20656 /* The following example is derived from a problem report
20657 against gawk from Jorge Stolfi <stolfi@ic.unicamp.br>. */
20658 memset (&regex, 0, sizeof regex);
20659 s = re_compile_pattern ("[an\371]*n", 7, &regex);
20660 if (s)
20661 result |= 8;
20662 /* This should match, but does not for glibc-2.2.1. */
20663 else if (re_match (&regex, "an", 2, 0, &regs) != 2)
20664 result |= 8;
20665
20666 memset (&regex, 0, sizeof regex);
20667 s = re_compile_pattern ("x", 1, &regex);
20668 if (s)
20669 result |= 8;
20670 /* glibc-2.2.93 does not work with a negative RANGE argument. */
20671 else if (re_search (&regex, "wxy", 3, 2, -2, &regs) != 1)
20672 result |= 8;
20673
20674 /* The version of regex.c in older versions of gnulib
20675 ignored RE_ICASE. Detect that problem too. */
20676 re_set_syntax (RE_SYNTAX_EMACS | RE_ICASE);
20677 memset (&regex, 0, sizeof regex);
20678 s = re_compile_pattern ("x", 1, &regex);
20679 if (s)
20680 result |= 16;
20681 else if (re_search (&regex, "WXY", 3, 0, 3, &regs) < 0)
20682 result |= 16;
20683
20684 /* Catch a bug reported by Vin Shelton in
20685 http://lists.gnu.org/archive/html/bug-coreutils/2007-06/msg00089.html
20686 */
20687 re_set_syntax (RE_SYNTAX_POSIX_BASIC
20688 & ~RE_CONTEXT_INVALID_DUP
20689 & ~RE_NO_EMPTY_RANGES);
20690 memset (&regex, 0, sizeof regex);
20691 s = re_compile_pattern ("[[:alnum:]_-]\\\\+$", 16, &regex);
20692 if (s)
20693 result |= 32;
20694
20695 /* REG_STARTEND was added to glibc on 2004-01-15.
20696 Reject older versions. */
20697 if (! REG_STARTEND)
20698 result |= 64;
20699
20700#if 0
20701 /* It would be nice to reject hosts whose regoff_t values are too
20702 narrow (including glibc on hosts with 64-bit ptrdiff_t and
20703 32-bit int), but we should wait until glibc implements this
20704 feature. Otherwise, support for equivalence classes and
20705 multibyte collation symbols would always be broken except
20706 when compiling --without-included-regex. */
20707 if (sizeof (regoff_t) < sizeof (ptrdiff_t)
20708 || sizeof (regoff_t) < sizeof (ssize_t))
20709 result |= 64;
20710#endif
20711
20712 return result;
20713
20714 ;
20715 return 0;
20716}
20717_ACEOF
20718if ac_fn_c_try_run "$LINENO"; then :
20719 gl_cv_func_re_compile_pattern_working=yes
20720else
20721 gl_cv_func_re_compile_pattern_working=no
20722fi
20723rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20724 conftest.$ac_objext conftest.beam conftest.$ac_ext
20725fi
20726
20727fi
20728{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_re_compile_pattern_working" >&5
20729$as_echo "$gl_cv_func_re_compile_pattern_working" >&6; }
20730 case $gl_cv_func_re_compile_pattern_working in #(
20731 yes) ac_use_included_regex=no;; #(
20732 no) ac_use_included_regex=yes;;
20733 esac
20734 ;;
20735 *) as_fn_error $? "Invalid value for --with-included-regex: $with_included_regex" "$LINENO" 5
20736 ;;
20737 esac
20738
20739 if test $ac_use_included_regex = yes; then
20740
20741$as_echo "#define _REGEX_INCLUDE_LIMITS_H 1" >>confdefs.h
20742
20743
20744$as_echo "#define _REGEX_LARGE_OFFSETS 1" >>confdefs.h
20745
20746
20747$as_echo "#define re_syntax_options rpl_re_syntax_options" >>confdefs.h
20748
20749
20750$as_echo "#define re_set_syntax rpl_re_set_syntax" >>confdefs.h
20751
20752
20753$as_echo "#define re_compile_pattern rpl_re_compile_pattern" >>confdefs.h
20754
20755
20756$as_echo "#define re_compile_fastmap rpl_re_compile_fastmap" >>confdefs.h
20757
20758
20759$as_echo "#define re_search rpl_re_search" >>confdefs.h
20760
20761
20762$as_echo "#define re_search_2 rpl_re_search_2" >>confdefs.h
20763
20764
20765$as_echo "#define re_match rpl_re_match" >>confdefs.h
20766
20767
20768$as_echo "#define re_match_2 rpl_re_match_2" >>confdefs.h
20769
20770
20771$as_echo "#define re_set_registers rpl_re_set_registers" >>confdefs.h
20772
20773
20774$as_echo "#define re_comp rpl_re_comp" >>confdefs.h
20775
20776
20777$as_echo "#define re_exec rpl_re_exec" >>confdefs.h
20778
20779
20780$as_echo "#define regcomp rpl_regcomp" >>confdefs.h
20781
20782
20783$as_echo "#define regexec rpl_regexec" >>confdefs.h
20784
20785
20786$as_echo "#define regerror rpl_regerror" >>confdefs.h
20787
20788
20789$as_echo "#define regfree rpl_regfree" >>confdefs.h
20790
20791 fi
20792
20793 if test $ac_use_included_regex = yes; then
20794
20795
20796
20797
20798
20799
20800
20801
20802 gl_LIBOBJS="$gl_LIBOBJS regex.$ac_objext"
20803
20804
20805
20806
20807
20808
20809
20810 for ac_header in libintl.h
20811do :
20812 ac_fn_c_check_header_mongrel "$LINENO" "libintl.h" "ac_cv_header_libintl_h" "$ac_includes_default"
20813if test "x$ac_cv_header_libintl_h" = xyes; then :
20814 cat >>confdefs.h <<_ACEOF
20815#define HAVE_LIBINTL_H 1
20816_ACEOF
20817
20818fi
20819
20820done
20821
20822
20823 ac_fn_c_check_decl "$LINENO" "isblank" "ac_cv_have_decl_isblank" "#include <ctype.h>
20824"
20825if test "x$ac_cv_have_decl_isblank" = xyes; then :
20826 ac_have_decl=1
20827else
20828 ac_have_decl=0
20829fi
20830
20831cat >>confdefs.h <<_ACEOF
20832#define HAVE_DECL_ISBLANK $ac_have_decl
20833_ACEOF
20834
20835
20836 fi
20837
20838 for ac_header in stdint.h
20839do :
20840 ac_fn_c_check_header_mongrel "$LINENO" "stdint.h" "ac_cv_header_stdint_h" "$ac_includes_default"
20841if test "x$ac_cv_header_stdint_h" = xyes; then :
20842 cat >>confdefs.h <<_ACEOF
20843#define HAVE_STDINT_H 1
20844_ACEOF
20845
20846fi
20847
20848done
20849
20850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SIZE_MAX" >&5
20851$as_echo_n "checking for SIZE_MAX... " >&6; }
20852if ${gl_cv_size_max+:} false; then :
20853 $as_echo_n "(cached) " >&6
20854else
20855
20856 gl_cv_size_max=
20857 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20858/* end confdefs.h. */
20859
20860#include <limits.h>
20861#if HAVE_STDINT_H
20862#include <stdint.h>
20863#endif
20864#ifdef SIZE_MAX
20865Found it
20866#endif
20867
20868_ACEOF
20869if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20870 $EGREP "Found it" >/dev/null 2>&1; then :
20871 gl_cv_size_max=yes
20872fi
20873rm -f conftest*
20874
20875 if test -z "$gl_cv_size_max"; then
20876 if ac_fn_c_compute_int "$LINENO" "sizeof (size_t) * CHAR_BIT - 1" "size_t_bits_minus_1" "#include <stddef.h>
20877#include <limits.h>"; then :
20878
20879else
20880 size_t_bits_minus_1=
20881fi
20882
20883 if ac_fn_c_compute_int "$LINENO" "sizeof (size_t) <= sizeof (unsigned int)" "fits_in_uint" "#include <stddef.h>"; then :
20884
20885else
20886 fits_in_uint=
20887fi
20888
20889 if test -n "$size_t_bits_minus_1" && test -n "$fits_in_uint"; then
20890 if test $fits_in_uint = 1; then
20891 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20892/* end confdefs.h. */
20893#include <stddef.h>
20894 extern size_t foo;
20895 extern unsigned long foo;
20896
20897int
20898main (void)
20899{
20900
20901 ;
20902 return 0;
20903}
20904_ACEOF
20905if ac_fn_c_try_compile "$LINENO"; then :
20906 fits_in_uint=0
20907fi
20908rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20909 fi
20910 if test $fits_in_uint = 1; then
20911 gl_cv_size_max="(((1U << $size_t_bits_minus_1) - 1) * 2 + 1)"
20912 else
20913 gl_cv_size_max="(((1UL << $size_t_bits_minus_1) - 1) * 2 + 1)"
20914 fi
20915 else
20916 gl_cv_size_max='((size_t)~(size_t)0)'
20917 fi
20918 fi
20919
20920fi
20921{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_size_max" >&5
20922$as_echo "$gl_cv_size_max" >&6; }
20923 if test "$gl_cv_size_max" != yes; then
20924
20925cat >>confdefs.h <<_ACEOF
20926#define SIZE_MAX $gl_cv_size_max
20927_ACEOF
20928
20929 fi
20930
20931
20932
20933
20934 ac_fn_c_check_decl "$LINENO" "sleep" "ac_cv_have_decl_sleep" "#include <unistd.h>
20935"
20936if test "x$ac_cv_have_decl_sleep" = xyes; then :
20937 ac_have_decl=1
20938else
20939 ac_have_decl=0
20940fi
20941
20942cat >>confdefs.h <<_ACEOF
20943#define HAVE_DECL_SLEEP $ac_have_decl
20944_ACEOF
20945
20946
20947 if test $ac_cv_have_decl_sleep != yes; then
20948 HAVE_SLEEP=0
20949 else
20950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working sleep" >&5
20951$as_echo_n "checking for working sleep... " >&6; }
20952if ${gl_cv_func_sleep_works+:} false; then :
20953 $as_echo_n "(cached) " >&6
20954else
20955 if test "$cross_compiling" = yes; then :
20956 case "$host_os" in
20957 # Guess yes on glibc systems.
20958 *-gnu*) gl_cv_func_sleep_works="guessing yes" ;;
20959 # If we don't know, assume the worst.
20960 *) gl_cv_func_sleep_works="guessing no" ;;
20961 esac
20962
20963else
20964 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20965/* end confdefs.h. */
20966
20967#include <errno.h>
20968#include <unistd.h>
20969#include <signal.h>
20970static void
20971handle_alarm (int sig)
20972{
20973 if (sig != SIGALRM)
20974 _exit (2);
20975}
20976
20977int
20978main (void)
20979{
20980
20981 /* Failure to compile this test due to missing alarm is okay,
20982 since all such platforms (mingw) also lack sleep. */
20983 unsigned int pentecost = 50 * 24 * 60 * 60; /* 50 days. */
20984 unsigned int remaining;
20985 signal (SIGALRM, handle_alarm);
20986 alarm (1);
20987 remaining = sleep (pentecost);
20988 if (remaining > pentecost)
20989 return 3;
20990 if (remaining <= pentecost - 10)
20991 return 4;
20992 return 0;
20993
20994 ;
20995 return 0;
20996}
20997_ACEOF
20998if ac_fn_c_try_run "$LINENO"; then :
20999 gl_cv_func_sleep_works=yes
21000else
21001 gl_cv_func_sleep_works=no
21002fi
21003rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21004 conftest.$ac_objext conftest.beam conftest.$ac_ext
21005fi
21006
21007fi
21008{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_sleep_works" >&5
21009$as_echo "$gl_cv_func_sleep_works" >&6; }
21010 case "$gl_cv_func_sleep_works" in
21011 *yes) ;;
21012 *)
21013 REPLACE_SLEEP=1
21014 ;;
21015 esac
21016 fi
21017
21018 if test $HAVE_SLEEP = 0 || test $REPLACE_SLEEP = 1; then
21019
21020
21021
21022
21023
21024
21025
21026
21027 gl_LIBOBJS="$gl_LIBOBJS sleep.$ac_objext"
21028
21029 fi
21030
21031
21032
21033
21034
21035 GNULIB_SLEEP=1
21036
21037
21038
21039
21040
21041$as_echo "#define GNULIB_TEST_SLEEP 1" >>confdefs.h
21042
21043
21044
21045
21046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
21047$as_echo_n "checking for ssize_t... " >&6; }
21048if ${gt_cv_ssize_t+:} false; then :
21049 $as_echo_n "(cached) " >&6
21050else
21051 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21052/* end confdefs.h. */
21053#include <sys/types.h>
21054int
21055main (void)
21056{
21057int x = sizeof (ssize_t *) + sizeof (ssize_t);
21058 return !x;
21059 ;
21060 return 0;
21061}
21062_ACEOF
21063if ac_fn_c_try_compile "$LINENO"; then :
21064 gt_cv_ssize_t=yes
21065else
21066 gt_cv_ssize_t=no
21067fi
21068rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21069fi
21070{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
21071$as_echo "$gt_cv_ssize_t" >&6; }
21072 if test $gt_cv_ssize_t = no; then
21073
21074$as_echo "#define ssize_t int" >>confdefs.h
21075
21076 fi
21077
21078
21079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdalign.h" >&5
21080$as_echo_n "checking for working stdalign.h... " >&6; }
21081if ${gl_cv_header_working_stdalign_h+:} false; then :
21082 $as_echo_n "(cached) " >&6
21083else
21084 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21085/* end confdefs.h. */
21086#include <stdalign.h>
21087 #include <stddef.h>
21088
21089 /* Test that alignof yields a result consistent with offsetof.
21090 This catches GCC bug 52023
21091 <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023>. */
21092 #ifdef __cplusplus
21093 template <class t> struct alignof_helper { char a; t b; };
21094 # define ao(type) offsetof (alignof_helper<type>, b)
21095 #else
21096 # define ao(type) offsetof (struct { char a; type b; }, b)
21097 #endif
21098 char test_double[ao (double) % _Alignof (double) == 0 ? 1 : -1];
21099 char test_long[ao (long int) % _Alignof (long int) == 0 ? 1 : -1];
21100 char test_alignof[alignof (double) == _Alignof (double) ? 1 : -1];
21101
21102 /* Test _Alignas only on platforms where gnulib can help. */
21103 #if \
21104 (__GNUC__ || __IBMC__ || __IBMCPP__ \
21105 || 0x5110 <= __SUNPRO_C || 1300 <= _MSC_VER)
21106 struct alignas_test { char c; char alignas (8) alignas_8; };
21107 char test_alignas[offsetof (struct alignas_test, alignas_8) == 8
21108 ? 1 : -1];
21109 #endif
21110
21111int
21112main (void)
21113{
21114
21115 ;
21116 return 0;
21117}
21118_ACEOF
21119if ac_fn_c_try_compile "$LINENO"; then :
21120 gl_cv_header_working_stdalign_h=yes
21121else
21122 gl_cv_header_working_stdalign_h=no
21123fi
21124rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21125fi
21126{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdalign_h" >&5
21127$as_echo "$gl_cv_header_working_stdalign_h" >&6; }
21128
21129 if test $gl_cv_header_working_stdalign_h = yes; then
21130 STDALIGN_H=''
21131 else
21132 STDALIGN_H='stdalign.h'
21133 fi
21134
21135
21136 if test -n "$STDALIGN_H"; then
21137 GL_GENERATE_STDALIGN_H_TRUE=
21138 GL_GENERATE_STDALIGN_H_FALSE='#'
21139else
21140 GL_GENERATE_STDALIGN_H_TRUE='#'
21141 GL_GENERATE_STDALIGN_H_FALSE=
21142fi
21143
21144
21145
21146
21147
21148 # Define two additional variables used in the Makefile substitution.
21149
21150 if test "$ac_cv_header_stdbool_h" = yes; then
21151 STDBOOL_H=''
21152 else
21153 STDBOOL_H='stdbool.h'
21154 fi
21155
21156 if test -n "$STDBOOL_H"; then
21157 GL_GENERATE_STDBOOL_H_TRUE=
21158 GL_GENERATE_STDBOOL_H_FALSE='#'
21159else
21160 GL_GENERATE_STDBOOL_H_TRUE='#'
21161 GL_GENERATE_STDBOOL_H_FALSE=
21162fi
21163
21164
21165 if test "$ac_cv_type__Bool" = yes; then
21166 HAVE__BOOL=1
21167 else
21168 HAVE__BOOL=0
21169 fi
21170
21171
21172
21173
21174
21175 STDDEF_H=
21176 if test $gt_cv_c_wchar_t = no; then
21177 HAVE_WCHAR_T=0
21178 STDDEF_H=stddef.h
21179 fi
21180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
21181$as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
21182if ${gl_cv_decl_null_works+:} false; then :
21183 $as_echo_n "(cached) " >&6
21184else
21185 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21186/* end confdefs.h. */
21187#include <stddef.h>
21188 int test[2 * (sizeof NULL == sizeof (void *)) -1];
21189
21190int
21191main (void)
21192{
21193
21194 ;
21195 return 0;
21196}
21197_ACEOF
21198if ac_fn_c_try_compile "$LINENO"; then :
21199 gl_cv_decl_null_works=yes
21200else
21201 gl_cv_decl_null_works=no
21202fi
21203rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21204fi
21205{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
21206$as_echo "$gl_cv_decl_null_works" >&6; }
21207 if test $gl_cv_decl_null_works = no; then
21208 REPLACE_NULL=1
21209 STDDEF_H=stddef.h
21210 fi
21211
21212 if test -n "$STDDEF_H"; then
21213 GL_GENERATE_STDDEF_H_TRUE=
21214 GL_GENERATE_STDDEF_H_FALSE='#'
21215else
21216 GL_GENERATE_STDDEF_H_TRUE='#'
21217 GL_GENERATE_STDDEF_H_FALSE=
21218fi
21219
21220 if test -n "$STDDEF_H"; then
21221
21222
21223
21224
21225
21226
21227
21228
21229 if test $gl_cv_have_include_next = yes; then
21230 gl_cv_next_stddef_h='<'stddef.h'>'
21231 else
21232 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
21233$as_echo_n "checking absolute name of <stddef.h>... " >&6; }
21234if ${gl_cv_next_stddef_h+:} false; then :
21235 $as_echo_n "(cached) " >&6
21236else
21237
21238 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21239/* end confdefs.h. */
21240#include <stddef.h>
21241
21242_ACEOF
21243 case "$host_os" in
21244 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21245 *) gl_absname_cpp="$ac_cpp" ;;
21246 esac
21247
21248 case "$host_os" in
21249 mingw*)
21250 gl_dirsep_regex='[/\\]'
21251 ;;
21252 *)
21253 gl_dirsep_regex='\/'
21254 ;;
21255 esac
21256 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21257
21258 gl_header_literal_regex=`echo 'stddef.h' \
21259 | sed -e "$gl_make_literal_regex_sed"`
21260 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21261 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21262 s|^/[^/]|//&|
21263 p
21264 q
21265 }'
21266 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21267 sed -n "$gl_absolute_header_sed"`'"'
21268
21269
21270fi
21271{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
21272$as_echo "$gl_cv_next_stddef_h" >&6; }
21273 fi
21274 NEXT_STDDEF_H=$gl_cv_next_stddef_h
21275
21276 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21277 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21278 gl_next_as_first_directive='<'stddef.h'>'
21279 else
21280 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21281 gl_next_as_first_directive=$gl_cv_next_stddef_h
21282 fi
21283 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
21284
21285
21286
21287
21288 fi
21289
21290
21291
21292
21293
21294
21295
21296
21297
21298
21299
21300
21301 if test $gl_cv_have_include_next = yes; then
21302 gl_cv_next_stdio_h='<'stdio.h'>'
21303 else
21304 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
21305$as_echo_n "checking absolute name of <stdio.h>... " >&6; }
21306if ${gl_cv_next_stdio_h+:} false; then :
21307 $as_echo_n "(cached) " >&6
21308else
21309
21310 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21311/* end confdefs.h. */
21312#include <stdio.h>
21313
21314_ACEOF
21315 case "$host_os" in
21316 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21317 *) gl_absname_cpp="$ac_cpp" ;;
21318 esac
21319
21320 case "$host_os" in
21321 mingw*)
21322 gl_dirsep_regex='[/\\]'
21323 ;;
21324 *)
21325 gl_dirsep_regex='\/'
21326 ;;
21327 esac
21328 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21329
21330 gl_header_literal_regex=`echo 'stdio.h' \
21331 | sed -e "$gl_make_literal_regex_sed"`
21332 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21333 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21334 s|^/[^/]|//&|
21335 p
21336 q
21337 }'
21338 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21339 sed -n "$gl_absolute_header_sed"`'"'
21340
21341
21342fi
21343{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
21344$as_echo "$gl_cv_next_stdio_h" >&6; }
21345 fi
21346 NEXT_STDIO_H=$gl_cv_next_stdio_h
21347
21348 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21349 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21350 gl_next_as_first_directive='<'stdio.h'>'
21351 else
21352 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21353 gl_next_as_first_directive=$gl_cv_next_stdio_h
21354 fi
21355 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
21356
21357
21358
21359
21360
21361 GNULIB_FSCANF=1
21362
21363
21364cat >>confdefs.h <<_ACEOF
21365#define GNULIB_FSCANF 1
21366_ACEOF
21367
21368
21369 GNULIB_SCANF=1
21370
21371
21372cat >>confdefs.h <<_ACEOF
21373#define GNULIB_SCANF 1
21374_ACEOF
21375
21376
21377 GNULIB_FGETC=1
21378 GNULIB_GETC=1
21379 GNULIB_GETCHAR=1
21380 GNULIB_FGETS=1
21381 GNULIB_FREAD=1
21382
21383
21384 GNULIB_FPRINTF=1
21385 GNULIB_PRINTF=1
21386 GNULIB_VFPRINTF=1
21387 GNULIB_VPRINTF=1
21388 GNULIB_FPUTC=1
21389 GNULIB_PUTC=1
21390 GNULIB_PUTCHAR=1
21391 GNULIB_FPUTS=1
21392 GNULIB_PUTS=1
21393 GNULIB_FWRITE=1
21394
21395
21396
21397
21398 for gl_func in dprintf fpurge fseeko ftello getdelim getline gets pclose popen renameat snprintf tmpfile vdprintf vsnprintf; do
21399 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
21400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
21401$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
21402if eval \${$as_gl_Symbol+:} false; then :
21403 $as_echo_n "(cached) " >&6
21404else
21405 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21406/* end confdefs.h. */
21407#include <stdio.h>
21408
21409int
21410main (void)
21411{
21412#undef $gl_func
21413 (void) $gl_func;
21414 ;
21415 return 0;
21416}
21417_ACEOF
21418if ac_fn_c_try_compile "$LINENO"; then :
21419 eval "$as_gl_Symbol=yes"
21420else
21421 eval "$as_gl_Symbol=no"
21422fi
21423rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21424fi
21425eval ac_res=\$$as_gl_Symbol
21426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
21427$as_echo "$ac_res" >&6; }
21428 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
21429 cat >>confdefs.h <<_ACEOF
21430#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
21431_ACEOF
21432
21433 eval ac_cv_have_decl_$gl_func=yes
21434fi
21435 done
21436
21437
21438
21439
21440
21441
21442
21443
21444
21445
21446
21447
21448 if test $gl_cv_have_include_next = yes; then
21449 gl_cv_next_stdlib_h='<'stdlib.h'>'
21450 else
21451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
21452$as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
21453if ${gl_cv_next_stdlib_h+:} false; then :
21454 $as_echo_n "(cached) " >&6
21455else
21456
21457 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21458/* end confdefs.h. */
21459#include <stdlib.h>
21460
21461_ACEOF
21462 case "$host_os" in
21463 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21464 *) gl_absname_cpp="$ac_cpp" ;;
21465 esac
21466
21467 case "$host_os" in
21468 mingw*)
21469 gl_dirsep_regex='[/\\]'
21470 ;;
21471 *)
21472 gl_dirsep_regex='\/'
21473 ;;
21474 esac
21475 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21476
21477 gl_header_literal_regex=`echo 'stdlib.h' \
21478 | sed -e "$gl_make_literal_regex_sed"`
21479 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21480 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21481 s|^/[^/]|//&|
21482 p
21483 q
21484 }'
21485 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21486 sed -n "$gl_absolute_header_sed"`'"'
21487
21488
21489fi
21490{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
21491$as_echo "$gl_cv_next_stdlib_h" >&6; }
21492 fi
21493 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
21494
21495 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21496 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21497 gl_next_as_first_directive='<'stdlib.h'>'
21498 else
21499 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21500 gl_next_as_first_directive=$gl_cv_next_stdlib_h
21501 fi
21502 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
21503
21504
21505
21506
21507
21508
21509 for gl_func in _Exit atoll canonicalize_file_name getloadavg getsubopt grantpt initstate initstate_r mkdtemp mkostemp mkostemps mkstemp mkstemps posix_openpt ptsname ptsname_r random random_r realpath rpmatch secure_getenv setenv setstate setstate_r srandom srandom_r strtod strtoll strtoull unlockpt unsetenv; do
21510 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
21511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
21512$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
21513if eval \${$as_gl_Symbol+:} false; then :
21514 $as_echo_n "(cached) " >&6
21515else
21516 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21517/* end confdefs.h. */
21518#include <stdlib.h>
21519#if HAVE_SYS_LOADAVG_H
21520# include <sys/loadavg.h>
21521#endif
21522#if HAVE_RANDOM_H
21523# include <random.h>
21524#endif
21525
21526int
21527main (void)
21528{
21529#undef $gl_func
21530 (void) $gl_func;
21531 ;
21532 return 0;
21533}
21534_ACEOF
21535if ac_fn_c_try_compile "$LINENO"; then :
21536 eval "$as_gl_Symbol=yes"
21537else
21538 eval "$as_gl_Symbol=no"
21539fi
21540rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21541fi
21542eval ac_res=\$$as_gl_Symbol
21543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
21544$as_echo "$ac_res" >&6; }
21545 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
21546 cat >>confdefs.h <<_ACEOF
21547#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
21548_ACEOF
21549
21550 eval ac_cv_have_decl_$gl_func=yes
21551fi
21552 done
21553
21554
21555
21556
21557
21558 for ac_func in strcasecmp
21559do :
21560 ac_fn_c_check_func "$LINENO" "strcasecmp" "ac_cv_func_strcasecmp"
21561if test "x$ac_cv_func_strcasecmp" = xyes; then :
21562 cat >>confdefs.h <<_ACEOF
21563#define HAVE_STRCASECMP 1
21564_ACEOF
21565
21566fi
21567done
21568
21569 if test $ac_cv_func_strcasecmp = no; then
21570 HAVE_STRCASECMP=0
21571 fi
21572
21573
21574
21575 for ac_func in strncasecmp
21576do :
21577 ac_fn_c_check_func "$LINENO" "strncasecmp" "ac_cv_func_strncasecmp"
21578if test "x$ac_cv_func_strncasecmp" = xyes; then :
21579 cat >>confdefs.h <<_ACEOF
21580#define HAVE_STRNCASECMP 1
21581_ACEOF
21582
21583fi
21584done
21585
21586 if test $ac_cv_func_strncasecmp = yes; then
21587 HAVE_STRNCASECMP=1
21588 else
21589 HAVE_STRNCASECMP=0
21590 fi
21591 ac_fn_c_check_decl "$LINENO" "strncasecmp" "ac_cv_have_decl_strncasecmp" "$ac_includes_default"
21592if test "x$ac_cv_have_decl_strncasecmp" = xyes; then :
21593 ac_have_decl=1
21594else
21595 ac_have_decl=0
21596fi
21597
21598cat >>confdefs.h <<_ACEOF
21599#define HAVE_DECL_STRNCASECMP $ac_have_decl
21600_ACEOF
21601
21602 if test $ac_cv_have_decl_strncasecmp = no; then
21603 HAVE_DECL_STRNCASECMP=0
21604 fi
21605
21606
21607 if test $HAVE_STRCASECMP = 0; then
21608
21609
21610
21611
21612
21613
21614
21615
21616 gl_LIBOBJS="$gl_LIBOBJS strcasecmp.$ac_objext"
21617
21618
21619 :
21620
21621 fi
21622 if test $HAVE_STRNCASECMP = 0; then
21623
21624
21625
21626
21627
21628
21629
21630
21631 gl_LIBOBJS="$gl_LIBOBJS strncasecmp.$ac_objext"
21632
21633
21634 :
21635
21636 fi
21637
21638
21639
21640
21641 for ac_func in strchrnul
21642do :
21643 ac_fn_c_check_func "$LINENO" "strchrnul" "ac_cv_func_strchrnul"
21644if test "x$ac_cv_func_strchrnul" = xyes; then :
21645 cat >>confdefs.h <<_ACEOF
21646#define HAVE_STRCHRNUL 1
21647_ACEOF
21648
21649fi
21650done
21651
21652 if test $ac_cv_func_strchrnul = no; then
21653 HAVE_STRCHRNUL=0
21654 else
21655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strchrnul works" >&5
21656$as_echo_n "checking whether strchrnul works... " >&6; }
21657if ${gl_cv_func_strchrnul_works+:} false; then :
21658 $as_echo_n "(cached) " >&6
21659else
21660 if test "$cross_compiling" = yes; then :
21661 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21662/* end confdefs.h. */
21663
21664#if defined __CYGWIN__
21665 #include <cygwin/version.h>
21666 #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 9)
21667 Lucky user
21668 #endif
21669#else
21670 Lucky user
21671#endif
21672
21673_ACEOF
21674if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
21675 $EGREP "Lucky user" >/dev/null 2>&1; then :
21676 gl_cv_func_strchrnul_works="guessing yes"
21677else
21678 gl_cv_func_strchrnul_works="guessing no"
21679fi
21680rm -f conftest*
21681
21682
21683else
21684 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21685/* end confdefs.h. */
21686
21687#include <string.h> /* for strchrnul */
21688
21689int
21690main (void)
21691{
21692const char *buf = "a";
21693 return strchrnul (buf, 'b') != buf + 1;
21694
21695 ;
21696 return 0;
21697}
21698_ACEOF
21699if ac_fn_c_try_run "$LINENO"; then :
21700 gl_cv_func_strchrnul_works=yes
21701else
21702 gl_cv_func_strchrnul_works=no
21703fi
21704rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21705 conftest.$ac_objext conftest.beam conftest.$ac_ext
21706fi
21707
21708
21709fi
21710{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strchrnul_works" >&5
21711$as_echo "$gl_cv_func_strchrnul_works" >&6; }
21712 case "$gl_cv_func_strchrnul_works" in
21713 *yes) ;;
21714 *) REPLACE_STRCHRNUL=1 ;;
21715 esac
21716 fi
21717
21718 if test $HAVE_STRCHRNUL = 0 || test $REPLACE_STRCHRNUL = 1; then
21719
21720
21721
21722
21723
21724
21725
21726
21727 gl_LIBOBJS="$gl_LIBOBJS strchrnul.$ac_objext"
21728
21729 :
21730 fi
21731
21732
21733
21734
21735
21736 GNULIB_STRCHRNUL=1
21737
21738
21739
21740
21741
21742$as_echo "#define GNULIB_TEST_STRCHRNUL 1" >>confdefs.h
21743
21744
21745
21746
21747
21748
21749
21750
21751 if test "$ERRNO_H:$REPLACE_STRERROR_0" = :0; then
21752 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strerror function" >&5
21753$as_echo_n "checking for working strerror function... " >&6; }
21754if ${gl_cv_func_working_strerror+:} false; then :
21755 $as_echo_n "(cached) " >&6
21756else
21757 if test "$cross_compiling" = yes; then :
21758 case "$host_os" in
21759 # Guess yes on glibc systems.
21760 *-gnu*) gl_cv_func_working_strerror="guessing yes" ;;
21761 # If we don't know, assume the worst.
21762 *) gl_cv_func_working_strerror="guessing no" ;;
21763 esac
21764
21765else
21766 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21767/* end confdefs.h. */
21768#include <string.h>
21769
21770int
21771main (void)
21772{
21773if (!*strerror (-2)) return 1;
21774 ;
21775 return 0;
21776}
21777_ACEOF
21778if ac_fn_c_try_run "$LINENO"; then :
21779 gl_cv_func_working_strerror=yes
21780else
21781 gl_cv_func_working_strerror=no
21782fi
21783rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21784 conftest.$ac_objext conftest.beam conftest.$ac_ext
21785fi
21786
21787
21788fi
21789{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_strerror" >&5
21790$as_echo "$gl_cv_func_working_strerror" >&6; }
21791 case "$gl_cv_func_working_strerror" in
21792 *yes) ;;
21793 *)
21794 REPLACE_STRERROR=1
21795 ;;
21796 esac
21797
21798 else
21799 REPLACE_STRERROR=1
21800 fi
21801
21802 if test $REPLACE_STRERROR = 1; then
21803
21804
21805
21806
21807
21808
21809
21810
21811 gl_LIBOBJS="$gl_LIBOBJS strerror.$ac_objext"
21812
21813 fi
21814
21815
21816cat >>confdefs.h <<_ACEOF
21817#define GNULIB_STRERROR 1
21818_ACEOF
21819
21820
21821
21822
21823
21824
21825
21826 GNULIB_STRERROR=1
21827
21828
21829
21830
21831
21832$as_echo "#define GNULIB_TEST_STRERROR 1" >>confdefs.h
21833
21834
21835
21836
21837
21838 if test -n "$ERRNO_H" || test $REPLACE_STRERROR_0 = 1; then
21839
21840
21841
21842
21843
21844
21845
21846
21847 gl_LIBOBJS="$gl_LIBOBJS strerror-override.$ac_objext"
21848
21849
21850
21851
21852
21853 if test $ac_cv_header_sys_socket_h != yes; then
21854 for ac_header in winsock2.h
21855do :
21856 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
21857if test "x$ac_cv_header_winsock2_h" = xyes; then :
21858 cat >>confdefs.h <<_ACEOF
21859#define HAVE_WINSOCK2_H 1
21860_ACEOF
21861
21862fi
21863
21864done
21865
21866 fi
21867 if test "$ac_cv_header_winsock2_h" = yes; then
21868 HAVE_WINSOCK2_H=1
21869 UNISTD_H_HAVE_WINSOCK2_H=1
21870 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
21871 else
21872 HAVE_WINSOCK2_H=0
21873 fi
21874
21875
21876 fi
21877
21878
21879
21880
21881
21882
21883
21884
21885
21886
21887
21888
21889 if test $ac_cv_have_decl_strndup = no; then
21890 HAVE_DECL_STRNDUP=0
21891 fi
21892
21893 if test $ac_cv_func_strndup = yes; then
21894 HAVE_STRNDUP=1
21895 # AIX 4.3.3, AIX 5.1 have a function that fails to add the terminating '\0'.
21896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strndup" >&5
21897$as_echo_n "checking for working strndup... " >&6; }
21898if ${gl_cv_func_strndup_works+:} false; then :
21899 $as_echo_n "(cached) " >&6
21900else
21901 if test "$cross_compiling" = yes; then :
21902
21903 case $host_os in
21904 aix | aix[3-6]*) gl_cv_func_strndup_works="guessing no";;
21905 *) gl_cv_func_strndup_works="guessing yes";;
21906 esac
21907
21908else
21909 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21910/* end confdefs.h. */
21911
21912 #include <string.h>
21913 #include <stdlib.h>
21914int
21915main (void)
21916{
21917
21918#if !HAVE_DECL_STRNDUP
21919 extern
21920 #ifdef __cplusplus
21921 "C"
21922 #endif
21923 char *strndup (const char *, size_t);
21924#endif
21925 char *s;
21926 s = strndup ("some longer string", 15);
21927 free (s);
21928 s = strndup ("shorter string", 13);
21929 return s[13] != '\0';
21930 ;
21931 return 0;
21932}
21933_ACEOF
21934if ac_fn_c_try_run "$LINENO"; then :
21935 gl_cv_func_strndup_works=yes
21936else
21937 gl_cv_func_strndup_works=no
21938fi
21939rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21940 conftest.$ac_objext conftest.beam conftest.$ac_ext
21941fi
21942
21943fi
21944{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strndup_works" >&5
21945$as_echo "$gl_cv_func_strndup_works" >&6; }
21946 case $gl_cv_func_strndup_works in
21947 *no) REPLACE_STRNDUP=1 ;;
21948 esac
21949 else
21950 HAVE_STRNDUP=0
21951 fi
21952
21953 if test $HAVE_STRNDUP = 0 || test $REPLACE_STRNDUP = 1; then
21954
21955
21956
21957
21958
21959
21960
21961
21962 gl_LIBOBJS="$gl_LIBOBJS strndup.$ac_objext"
21963
21964 fi
21965
21966
21967
21968
21969
21970 GNULIB_STRNDUP=1
21971
21972
21973
21974
21975
21976$as_echo "#define GNULIB_TEST_STRNDUP 1" >>confdefs.h
21977
21978
21979
21980
21981
21982
21983
21984
21985
21986 if test $ac_cv_have_decl_strnlen = no; then
21987 HAVE_DECL_STRNLEN=0
21988 else
21989
21990 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strnlen" >&5
21991$as_echo_n "checking for working strnlen... " >&6; }
21992if ${ac_cv_func_strnlen_working+:} false; then :
21993 $as_echo_n "(cached) " >&6
21994else
21995 if test "$cross_compiling" = yes; then :
21996 # Guess no on AIX systems, yes otherwise.
21997 case "$host_os" in
21998 aix*) ac_cv_func_strnlen_working=no;;
21999 *) ac_cv_func_strnlen_working=yes;;
22000 esac
22001else
22002 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22003/* end confdefs.h. */
22004$ac_includes_default
22005int
22006main (void)
22007{
22008
22009#define S "foobar"
22010#define S_LEN (sizeof S - 1)
22011
22012 /* At least one implementation is buggy: that of AIX 4.3 would
22013 give strnlen (S, 1) == 3. */
22014
22015 int i;
22016 for (i = 0; i < S_LEN + 1; ++i)
22017 {
22018 int expected = i <= S_LEN ? i : S_LEN;
22019 if (strnlen (S, i) != expected)
22020 return 1;
22021 }
22022 return 0;
22023
22024 ;
22025 return 0;
22026}
22027_ACEOF
22028if ac_fn_c_try_run "$LINENO"; then :
22029 ac_cv_func_strnlen_working=yes
22030else
22031 ac_cv_func_strnlen_working=no
22032fi
22033rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22034 conftest.$ac_objext conftest.beam conftest.$ac_ext
22035fi
22036
22037fi
22038{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strnlen_working" >&5
22039$as_echo "$ac_cv_func_strnlen_working" >&6; }
22040test $ac_cv_func_strnlen_working = no && :
22041
22042
22043 if test $ac_cv_func_strnlen_working = no; then
22044 REPLACE_STRNLEN=1
22045 fi
22046 fi
22047
22048 if test $HAVE_DECL_STRNLEN = 0 || test $REPLACE_STRNLEN = 1; then
22049
22050
22051
22052
22053
22054
22055
22056
22057 gl_LIBOBJS="$gl_LIBOBJS strnlen.$ac_objext"
22058
22059 :
22060 fi
22061
22062
22063
22064
22065
22066 GNULIB_STRNLEN=1
22067
22068
22069
22070
22071
22072$as_echo "#define GNULIB_TEST_STRNLEN 1" >>confdefs.h
22073
22074
22075
22076
22077
22078
22079
22080 if test $ac_cv_header_sysexits_h = yes; then
22081 HAVE_SYSEXITS_H=1
22082
22083
22084
22085
22086
22087
22088
22089
22090
22091 if test $gl_cv_have_include_next = yes; then
22092 gl_cv_next_sysexits_h='<'sysexits.h'>'
22093 else
22094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sysexits.h>" >&5
22095$as_echo_n "checking absolute name of <sysexits.h>... " >&6; }
22096if ${gl_cv_next_sysexits_h+:} false; then :
22097 $as_echo_n "(cached) " >&6
22098else
22099
22100 if test $ac_cv_header_sysexits_h = yes; then
22101
22102
22103 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22104/* end confdefs.h. */
22105#include <sysexits.h>
22106
22107_ACEOF
22108 case "$host_os" in
22109 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22110 *) gl_absname_cpp="$ac_cpp" ;;
22111 esac
22112
22113 case "$host_os" in
22114 mingw*)
22115 gl_dirsep_regex='[/\\]'
22116 ;;
22117 *)
22118 gl_dirsep_regex='\/'
22119 ;;
22120 esac
22121 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22122
22123 gl_header_literal_regex=`echo 'sysexits.h' \
22124 | sed -e "$gl_make_literal_regex_sed"`
22125 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22126 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22127 s|^/[^/]|//&|
22128 p
22129 q
22130 }'
22131 gl_cv_next_sysexits_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22132 sed -n "$gl_absolute_header_sed"`'"'
22133 else
22134 gl_cv_next_sysexits_h='<'sysexits.h'>'
22135 fi
22136
22137
22138fi
22139{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sysexits_h" >&5
22140$as_echo "$gl_cv_next_sysexits_h" >&6; }
22141 fi
22142 NEXT_SYSEXITS_H=$gl_cv_next_sysexits_h
22143
22144 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22145 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22146 gl_next_as_first_directive='<'sysexits.h'>'
22147 else
22148 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22149 gl_next_as_first_directive=$gl_cv_next_sysexits_h
22150 fi
22151 NEXT_AS_FIRST_DIRECTIVE_SYSEXITS_H=$gl_next_as_first_directive
22152
22153
22154
22155
22156 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22157/* end confdefs.h. */
22158#include <sysexits.h>
22159int
22160main (void)
22161{
22162switch (0)
22163 {
22164 case EX_OK:
22165 case EX_USAGE:
22166 case EX_DATAERR:
22167 case EX_NOINPUT:
22168 case EX_NOUSER:
22169 case EX_NOHOST:
22170 case EX_UNAVAILABLE:
22171 case EX_SOFTWARE:
22172 case EX_OSERR:
22173 case EX_OSFILE:
22174 case EX_CANTCREAT:
22175 case EX_IOERR:
22176 case EX_TEMPFAIL:
22177 case EX_PROTOCOL:
22178 case EX_NOPERM:
22179 case EX_CONFIG:
22180 break;
22181 }
22182
22183 ;
22184 return 0;
22185}
22186_ACEOF
22187if ac_fn_c_try_compile "$LINENO"; then :
22188 SYSEXITS_H=
22189else
22190 SYSEXITS_H=sysexits.h
22191fi
22192rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22193 else
22194 HAVE_SYSEXITS_H=0
22195 SYSEXITS_H=sysexits.h
22196 fi
22197
22198
22199 if test -n "$SYSEXITS_H"; then
22200 GL_GENERATE_SYSEXITS_H_TRUE=
22201 GL_GENERATE_SYSEXITS_H_FALSE='#'
22202else
22203 GL_GENERATE_SYSEXITS_H_TRUE='#'
22204 GL_GENERATE_SYSEXITS_H_FALSE=
22205fi
22206
22207
22208
22209
22210
22211
22212
22213
22214
22215
22216
22217
22218
22219
22220 if test $gl_cv_have_include_next = yes; then
22221 gl_cv_next_unistd_h='<'unistd.h'>'
22222 else
22223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
22224$as_echo_n "checking absolute name of <unistd.h>... " >&6; }
22225if ${gl_cv_next_unistd_h+:} false; then :
22226 $as_echo_n "(cached) " >&6
22227else
22228
22229 if test $ac_cv_header_unistd_h = yes; then
22230
22231
22232 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22233/* end confdefs.h. */
22234#include <unistd.h>
22235
22236_ACEOF
22237 case "$host_os" in
22238 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22239 *) gl_absname_cpp="$ac_cpp" ;;
22240 esac
22241
22242 case "$host_os" in
22243 mingw*)
22244 gl_dirsep_regex='[/\\]'
22245 ;;
22246 *)
22247 gl_dirsep_regex='\/'
22248 ;;
22249 esac
22250 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22251
22252 gl_header_literal_regex=`echo 'unistd.h' \
22253 | sed -e "$gl_make_literal_regex_sed"`
22254 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22255 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22256 s|^/[^/]|//&|
22257 p
22258 q
22259 }'
22260 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22261 sed -n "$gl_absolute_header_sed"`'"'
22262 else
22263 gl_cv_next_unistd_h='<'unistd.h'>'
22264 fi
22265
22266
22267fi
22268{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
22269$as_echo "$gl_cv_next_unistd_h" >&6; }
22270 fi
22271 NEXT_UNISTD_H=$gl_cv_next_unistd_h
22272
22273 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22274 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22275 gl_next_as_first_directive='<'unistd.h'>'
22276 else
22277 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22278 gl_next_as_first_directive=$gl_cv_next_unistd_h
22279 fi
22280 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
22281
22282
22283
22284
22285 if test $ac_cv_header_unistd_h = yes; then
22286 HAVE_UNISTD_H=1
22287 else
22288 HAVE_UNISTD_H=0
22289 fi
22290
22291
22292
22293
22294
22295
22296
22297 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
22298 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
22299 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
22300$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
22301if eval \${$as_gl_Symbol+:} false; then :
22302 $as_echo_n "(cached) " >&6
22303else
22304 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22305/* end confdefs.h. */
22306
22307#if HAVE_UNISTD_H
22308# include <unistd.h>
22309#endif
22310/* Some systems declare various items in the wrong headers. */
22311#if !(defined __GLIBC__ && !defined __UCLIBC__)
22312# include <fcntl.h>
22313# include <stdio.h>
22314# include <stdlib.h>
22315# if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
22316# include <io.h>
22317# endif
22318#endif
22319
22320int
22321main (void)
22322{
22323#undef $gl_func
22324 (void) $gl_func;
22325 ;
22326 return 0;
22327}
22328_ACEOF
22329if ac_fn_c_try_compile "$LINENO"; then :
22330 eval "$as_gl_Symbol=yes"
22331else
22332 eval "$as_gl_Symbol=no"
22333fi
22334rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22335fi
22336eval ac_res=\$$as_gl_Symbol
22337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
22338$as_echo "$ac_res" >&6; }
22339 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
22340 cat >>confdefs.h <<_ACEOF
22341#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
22342_ACEOF
22343
22344 eval ac_cv_have_decl_$gl_func=yes
22345fi
22346 done
22347
22348
22349
22350
22351 if { test "$HAVE_LIBUNISTRING" != yes \
22352 || {
22353
22354
22355
22356 test $LIBUNISTRING_VERSION_MAJOR -lt 0 \
22357 || { test $LIBUNISTRING_VERSION_MAJOR -eq 0 \
22358 && { test $LIBUNISTRING_VERSION_MINOR -lt 9 \
22359 || { test $LIBUNISTRING_VERSION_MINOR -eq 9 \
22360 && test $LIBUNISTRING_VERSION_SUBMINOR -lt 0
22361 }
22362 }
22363 }
22364
22365
22366
22367
22368 }
22369 }; then
22370 LIBUNISTRING_UNITYPES_H='unitypes.h'
22371 else
22372 LIBUNISTRING_UNITYPES_H=
22373 fi
22374
22375
22376
22377
22378 if { test "$HAVE_LIBUNISTRING" != yes \
22379 || {
22380
22381
22382
22383 test $LIBUNISTRING_VERSION_MAJOR -lt 0 \
22384 || { test $LIBUNISTRING_VERSION_MAJOR -eq 0 \
22385 && { test $LIBUNISTRING_VERSION_MINOR -lt 9 \
22386 || { test $LIBUNISTRING_VERSION_MINOR -eq 9 \
22387 && test $LIBUNISTRING_VERSION_SUBMINOR -lt 0
22388 }
22389 }
22390 }
22391
22392
22393
22394
22395 }
22396 }; then
22397 LIBUNISTRING_UNIWIDTH_H='uniwidth.h'
22398 else
22399 LIBUNISTRING_UNIWIDTH_H=
22400 fi
22401
22402
22403
22404
22405 if { test "$HAVE_LIBUNISTRING" != yes \
22406 || {
22407
22408
22409
22410 test $LIBUNISTRING_VERSION_MAJOR -lt 0 \
22411 || { test $LIBUNISTRING_VERSION_MAJOR -eq 0 \
22412 && { test $LIBUNISTRING_VERSION_MINOR -lt 9 \
22413 || { test $LIBUNISTRING_VERSION_MINOR -eq 9 \
22414 && test $LIBUNISTRING_VERSION_SUBMINOR -lt 4
22415 }
22416 }
22417 }
22418
22419
22420
22421
22422 }
22423 }; then
22424 LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_TRUE=
22425 LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_FALSE='#'
22426else
22427 LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_TRUE='#'
22428 LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_FALSE=
22429fi
22430
22431
22432
22433
22434 if test $ac_cv_func_vasnprintf = no; then
22435
22436
22437
22438
22439
22440
22441
22442
22443
22444
22445 gl_LIBOBJS="$gl_LIBOBJS vasnprintf.$ac_objext"
22446
22447
22448
22449
22450
22451
22452
22453
22454
22455 gl_LIBOBJS="$gl_LIBOBJS printf-args.$ac_objext"
22456
22457
22458
22459
22460
22461
22462
22463
22464
22465 gl_LIBOBJS="$gl_LIBOBJS printf-parse.$ac_objext"
22466
22467
22468
22469
22470
22471
22472
22473
22474
22475 gl_LIBOBJS="$gl_LIBOBJS asnprintf.$ac_objext"
22476
22477 if test $ac_cv_func_vasnprintf = yes; then
22478
22479$as_echo "#define REPLACE_VASNPRINTF 1" >>confdefs.h
22480
22481 fi
22482
22483
22484
22485
22486
22487
22488
22489
22490
22491
22492
22493 ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
22494if test "x$ac_cv_type_ptrdiff_t" = xyes; then :
22495
22496else
22497
22498$as_echo "#define ptrdiff_t long" >>confdefs.h
22499
22500
22501fi
22502
22503
22504
22505
22506
22507
22508
22509 fi
22510
22511
22512
22513 gl_cv_func_vsnprintf_usable=no
22514 for ac_func in vsnprintf
22515do :
22516 ac_fn_c_check_func "$LINENO" "vsnprintf" "ac_cv_func_vsnprintf"
22517if test "x$ac_cv_func_vsnprintf" = xyes; then :
22518 cat >>confdefs.h <<_ACEOF
22519#define HAVE_VSNPRINTF 1
22520_ACEOF
22521
22522fi
22523done
22524
22525 if test $ac_cv_func_vsnprintf = yes; then
22526
22527
22528
22529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf respects a size of 1" >&5
22530$as_echo_n "checking whether snprintf respects a size of 1... " >&6; }
22531if ${gl_cv_func_snprintf_size1+:} false; then :
22532 $as_echo_n "(cached) " >&6
22533else
22534
22535 if test "$cross_compiling" = yes; then :
22536 gl_cv_func_snprintf_size1="guessing yes"
22537else
22538 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22539/* end confdefs.h. */
22540
22541#include <stdio.h>
22542#if HAVE_SNPRINTF
22543# define my_snprintf snprintf
22544#else
22545# include <stdarg.h>
22546static int my_snprintf (char *buf, int size, const char *format, ...)
22547{
22548 va_list args;
22549 int ret;
22550 va_start (args, format);
22551 ret = vsnprintf (buf, size, format, args);
22552 va_end (args);
22553 return ret;
22554}
22555#endif
22556int main()
22557{
22558 static char buf[8] = { 'D', 'E', 'A', 'D', 'B', 'E', 'E', 'F' };
22559 my_snprintf (buf, 1, "%d", 12345);
22560 return buf[1] != 'E';
22561}
22562_ACEOF
22563if ac_fn_c_try_run "$LINENO"; then :
22564 gl_cv_func_snprintf_size1=yes
22565else
22566 gl_cv_func_snprintf_size1=no
22567fi
22568rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22569 conftest.$ac_objext conftest.beam conftest.$ac_ext
22570fi
22571
22572
22573fi
22574{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_snprintf_size1" >&5
22575$as_echo "$gl_cv_func_snprintf_size1" >&6; }
22576
22577 case "$gl_cv_func_snprintf_size1" in
22578 *yes)
22579
22580 case "$gl_cv_func_snprintf_retval_c99" in
22581 *yes)
22582
22583
22584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether printf supports POSIX/XSI format strings with positions" >&5
22585$as_echo_n "checking whether printf supports POSIX/XSI format strings with positions... " >&6; }
22586if ${gl_cv_func_printf_positions+:} false; then :
22587 $as_echo_n "(cached) " >&6
22588else
22589
22590 if test "$cross_compiling" = yes; then :
22591
22592 case "$host_os" in
22593 netbsd[1-3]* | netbsdelf[1-3]* | netbsdaout[1-3]* | netbsdcoff[1-3]*)
22594 gl_cv_func_printf_positions="guessing no";;
22595 beos*) gl_cv_func_printf_positions="guessing no";;
22596 mingw* | pw*) gl_cv_func_printf_positions="guessing no";;
22597 *) gl_cv_func_printf_positions="guessing yes";;
22598 esac
22599
22600else
22601 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22602/* end confdefs.h. */
22603
22604#include <stdio.h>
22605#include <string.h>
22606/* The string "%2$d %1$d", with dollar characters protected from the shell's
22607 dollar expansion (possibly an autoconf bug). */
22608static char format[] = { '%', '2', '$', 'd', ' ', '%', '1', '$', 'd', '\0' };
22609static char buf[100];
22610int main ()
22611{
22612 sprintf (buf, format, 33, 55);
22613 return (strcmp (buf, "55 33") != 0);
22614}
22615_ACEOF
22616if ac_fn_c_try_run "$LINENO"; then :
22617 gl_cv_func_printf_positions=yes
22618else
22619 gl_cv_func_printf_positions=no
22620fi
22621rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22622 conftest.$ac_objext conftest.beam conftest.$ac_ext
22623fi
22624
22625
22626fi
22627{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_positions" >&5
22628$as_echo "$gl_cv_func_printf_positions" >&6; }
22629
22630 case "$gl_cv_func_printf_positions" in
22631 *yes)
22632 gl_cv_func_vsnprintf_usable=yes
22633 ;;
22634 esac
22635 ;;
22636 esac
22637 ;;
22638 esac
22639 fi
22640 if test $gl_cv_func_vsnprintf_usable = no; then
22641
22642
22643
22644
22645
22646
22647
22648
22649
22650
22651 gl_LIBOBJS="$gl_LIBOBJS vsnprintf.$ac_objext"
22652
22653 if test $ac_cv_func_vsnprintf = yes; then
22654 REPLACE_VSNPRINTF=1
22655 fi
22656 :
22657
22658 fi
22659
22660 if test $ac_cv_have_decl_vsnprintf = no; then
22661 HAVE_DECL_VSNPRINTF=0
22662 fi
22663
22664
22665
22666
22667
22668
22669 GNULIB_VSNPRINTF=1
22670
22671
22672
22673
22674
22675$as_echo "#define GNULIB_TEST_VSNPRINTF 1" >>confdefs.h
22676
22677
22678
22679
22680
22681
22682
22683
22684
22685
22686
22687
22688
22689
22690
22691 if test $gl_cv_have_include_next = yes; then
22692 gl_cv_next_wchar_h='<'wchar.h'>'
22693 else
22694 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <wchar.h>" >&5
22695$as_echo_n "checking absolute name of <wchar.h>... " >&6; }
22696if ${gl_cv_next_wchar_h+:} false; then :
22697 $as_echo_n "(cached) " >&6
22698else
22699
22700 if test $ac_cv_header_wchar_h = yes; then
22701
22702
22703 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22704/* end confdefs.h. */
22705#include <wchar.h>
22706
22707_ACEOF
22708 case "$host_os" in
22709 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22710 *) gl_absname_cpp="$ac_cpp" ;;
22711 esac
22712
22713 case "$host_os" in
22714 mingw*)
22715 gl_dirsep_regex='[/\\]'
22716 ;;
22717 *)
22718 gl_dirsep_regex='\/'
22719 ;;
22720 esac
22721 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22722
22723 gl_header_literal_regex=`echo 'wchar.h' \
22724 | sed -e "$gl_make_literal_regex_sed"`
22725 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22726 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22727 s|^/[^/]|//&|
22728 p
22729 q
22730 }'
22731 gl_cv_next_wchar_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22732 sed -n "$gl_absolute_header_sed"`'"'
22733 else
22734 gl_cv_next_wchar_h='<'wchar.h'>'
22735 fi
22736
22737
22738fi
22739{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wchar_h" >&5
22740$as_echo "$gl_cv_next_wchar_h" >&6; }
22741 fi
22742 NEXT_WCHAR_H=$gl_cv_next_wchar_h
22743
22744 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22745 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22746 gl_next_as_first_directive='<'wchar.h'>'
22747 else
22748 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22749 gl_next_as_first_directive=$gl_cv_next_wchar_h
22750 fi
22751 NEXT_AS_FIRST_DIRECTIVE_WCHAR_H=$gl_next_as_first_directive
22752
22753
22754
22755
22756 if test $ac_cv_header_wchar_h = yes; then
22757 HAVE_WCHAR_H=1
22758 else
22759 HAVE_WCHAR_H=0
22760 fi
22761
22762
22763
22764
22765
22766 if test $gt_cv_c_wint_t = yes; then
22767 HAVE_WINT_T=1
22768 else
22769 HAVE_WINT_T=0
22770 fi
22771
22772
22773
22774 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
22775 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
22776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
22777$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
22778if eval \${$as_gl_Symbol+:} false; then :
22779 $as_echo_n "(cached) " >&6
22780else
22781 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22782/* end confdefs.h. */
22783
22784/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
22785 <wchar.h>.
22786 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
22787 included before <wchar.h>. */
22788#if !(defined __GLIBC__ && !defined __UCLIBC__)
22789# include <stddef.h>
22790# include <stdio.h>
22791# include <time.h>
22792#endif
22793#include <wchar.h>
22794
22795int
22796main (void)
22797{
22798#undef $gl_func
22799 (void) $gl_func;
22800 ;
22801 return 0;
22802}
22803_ACEOF
22804if ac_fn_c_try_compile "$LINENO"; then :
22805 eval "$as_gl_Symbol=yes"
22806else
22807 eval "$as_gl_Symbol=no"
22808fi
22809rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22810fi
22811eval ac_res=\$$as_gl_Symbol
22812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
22813$as_echo "$ac_res" >&6; }
22814 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
22815 cat >>confdefs.h <<_ACEOF
22816#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
22817_ACEOF
22818
22819 eval ac_cv_have_decl_$gl_func=yes
22820fi
22821 done
22822
22823
22824
22825
22826
22827
22828
22829
22830
22831
22832
22833
22834 if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
22835
22836
22837
22838 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
22839$as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
22840if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then :
22841 $as_echo_n "(cached) " >&6
22842else
22843
22844 case "$host_os" in
22845 # Guess no on AIX and OSF/1.
22846 aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
22847 # Guess yes otherwise.
22848 *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
22849 esac
22850 if test $LOCALE_JA != none; then
22851 if test "$cross_compiling" = yes; then :
22852 :
22853else
22854 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22855/* end confdefs.h. */
22856
22857#include <locale.h>
22858#include <string.h>
22859/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
22860 <wchar.h>.
22861 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
22862 included before <wchar.h>. */
22863#include <stddef.h>
22864#include <stdio.h>
22865#include <time.h>
22866#include <wchar.h>
22867int main ()
22868{
22869 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
22870 {
22871 const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
22872 mbstate_t state;
22873 wchar_t wc;
22874
22875 memset (&state, '\0', sizeof (mbstate_t));
22876 if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
22877 if (mbsinit (&state))
22878 return 1;
22879 }
22880 return 0;
22881}
22882_ACEOF
22883if ac_fn_c_try_run "$LINENO"; then :
22884 gl_cv_func_mbrtowc_incomplete_state=yes
22885else
22886 gl_cv_func_mbrtowc_incomplete_state=no
22887fi
22888rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22889 conftest.$ac_objext conftest.beam conftest.$ac_ext
22890fi
22891
22892 fi
22893
22894fi
22895{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
22896$as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
22897
22898
22899
22900
22901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
22902$as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
22903if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then :
22904 $as_echo_n "(cached) " >&6
22905else
22906
22907 case "$host_os" in
22908 # Guess no on Solaris 8.
22909 solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
22910 # Guess yes otherwise.
22911 *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
22912 esac
22913 if test $LOCALE_ZH_CN != none; then
22914 if test "$cross_compiling" = yes; then :
22915 :
22916else
22917 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22918/* end confdefs.h. */
22919
22920#include <locale.h>
22921#include <stdlib.h>
22922#include <string.h>
22923/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
22924 <wchar.h>.
22925 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
22926 included before <wchar.h>. */
22927#include <stddef.h>
22928#include <stdio.h>
22929#include <time.h>
22930#include <wchar.h>
22931int main ()
22932{
22933 /* This fails on Solaris 8:
22934 mbrtowc returns 2, and sets wc to 0x00F0.
22935 mbtowc returns 4 (correct) and sets wc to 0x5EDC. */
22936 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
22937 {
22938 char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
22939 mbstate_t state;
22940 wchar_t wc;
22941
22942 memset (&state, '\0', sizeof (mbstate_t));
22943 if (mbrtowc (&wc, input + 3, 6, &state) != 4
22944 && mbtowc (&wc, input + 3, 6) == 4)
22945 return 1;
22946 }
22947 return 0;
22948}
22949_ACEOF
22950if ac_fn_c_try_run "$LINENO"; then :
22951 gl_cv_func_mbrtowc_sanitycheck=yes
22952else
22953 gl_cv_func_mbrtowc_sanitycheck=no
22954fi
22955rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22956 conftest.$ac_objext conftest.beam conftest.$ac_ext
22957fi
22958
22959 fi
22960
22961fi
22962{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
22963$as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
22964
22965 REPLACE_MBSTATE_T=0
22966 case "$gl_cv_func_mbrtowc_incomplete_state" in
22967 *yes) ;;
22968 *) REPLACE_MBSTATE_T=1 ;;
22969 esac
22970 case "$gl_cv_func_mbrtowc_sanitycheck" in
22971 *yes) ;;
22972 *) REPLACE_MBSTATE_T=1 ;;
22973 esac
22974 else
22975 REPLACE_MBSTATE_T=1
22976 fi
22977
22978
22979
22980 if test $ac_cv_func_wcrtomb = no; then
22981 HAVE_WCRTOMB=0
22982 ac_fn_c_check_decl "$LINENO" "wcrtomb" "ac_cv_have_decl_wcrtomb" "
22983/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
22984 <wchar.h>.
22985 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
22986 included before <wchar.h>. */
22987#include <stddef.h>
22988#include <stdio.h>
22989#include <time.h>
22990#include <wchar.h>
22991
22992"
22993if test "x$ac_cv_have_decl_wcrtomb" = xyes; then :
22994 ac_have_decl=1
22995else
22996 ac_have_decl=0
22997fi
22998
22999cat >>confdefs.h <<_ACEOF
23000#define HAVE_DECL_WCRTOMB $ac_have_decl
23001_ACEOF
23002
23003 if test $ac_cv_have_decl_wcrtomb = yes; then
23004 REPLACE_WCRTOMB=1
23005 fi
23006 else
23007 if test $REPLACE_MBSTATE_T = 1; then
23008 REPLACE_WCRTOMB=1
23009 else
23010
23011
23012
23013
23014
23015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether wcrtomb return value is correct" >&5
23016$as_echo_n "checking whether wcrtomb return value is correct... " >&6; }
23017if ${gl_cv_func_wcrtomb_retval+:} false; then :
23018 $as_echo_n "(cached) " >&6
23019else
23020
23021 case "$host_os" in
23022 # Guess no on AIX 4, OSF/1 and Solaris.
23023 aix4* | osf* | solaris*) gl_cv_func_wcrtomb_retval="guessing no" ;;
23024 # Guess yes otherwise.
23025 *) gl_cv_func_wcrtomb_retval="guessing yes" ;;
23026 esac
23027 if test $LOCALE_FR != none || test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none || test $LOCALE_ZH_CN != none; then
23028 if test "$cross_compiling" = yes; then :
23029 :
23030else
23031 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23032/* end confdefs.h. */
23033
23034#include <locale.h>
23035#include <string.h>
23036/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
23037 <wchar.h>.
23038 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
23039 included before <wchar.h>. */
23040#include <stddef.h>
23041#include <stdio.h>
23042#include <time.h>
23043#include <wchar.h>
23044int main ()
23045{
23046 int result = 0;
23047 if (setlocale (LC_ALL, "$LOCALE_FR") != NULL)
23048 {
23049 if (wcrtomb (NULL, 0, NULL) != 1)
23050 result |= 1;
23051 }
23052 if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
23053 {
23054 if (wcrtomb (NULL, 0, NULL) != 1)
23055 result |= 2;
23056 }
23057 if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
23058 {
23059 if (wcrtomb (NULL, 0, NULL) != 1)
23060 result |= 4;
23061 }
23062 if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
23063 {
23064 if (wcrtomb (NULL, 0, NULL) != 1)
23065 result |= 8;
23066 }
23067 return result;
23068}
23069_ACEOF
23070if ac_fn_c_try_run "$LINENO"; then :
23071 gl_cv_func_wcrtomb_retval=yes
23072else
23073 gl_cv_func_wcrtomb_retval=no
23074fi
23075rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23076 conftest.$ac_objext conftest.beam conftest.$ac_ext
23077fi
23078
23079 fi
23080
23081fi
23082{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_wcrtomb_retval" >&5
23083$as_echo "$gl_cv_func_wcrtomb_retval" >&6; }
23084 case "$gl_cv_func_wcrtomb_retval" in
23085 *yes) ;;
23086 *) REPLACE_WCRTOMB=1 ;;
23087 esac
23088 fi
23089 fi
23090
23091 if test $HAVE_WCRTOMB = 0 || test $REPLACE_WCRTOMB = 1; then
23092
23093
23094
23095
23096
23097
23098
23099
23100 gl_LIBOBJS="$gl_LIBOBJS wcrtomb.$ac_objext"
23101
23102
23103 :
23104
23105 fi
23106
23107
23108
23109
23110
23111 GNULIB_WCRTOMB=1
23112
23113
23114
23115
23116
23117$as_echo "#define GNULIB_TEST_WCRTOMB 1" >>confdefs.h
23118
23119
23120
23121
23122
23123
23124
23125
23126 if test $ac_cv_func_iswcntrl = yes; then
23127 HAVE_ISWCNTRL=1
23128 else
23129 HAVE_ISWCNTRL=0
23130 fi
23131
23132
23133
23134 if test $gt_cv_c_wint_t = yes; then
23135 HAVE_WINT_T=1
23136 else
23137 HAVE_WINT_T=0
23138 fi
23139
23140
23141
23142
23143
23144
23145
23146
23147
23148
23149
23150 if test $gl_cv_have_include_next = yes; then
23151 gl_cv_next_wctype_h='<'wctype.h'>'
23152 else
23153 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <wctype.h>" >&5
23154$as_echo_n "checking absolute name of <wctype.h>... " >&6; }
23155if ${gl_cv_next_wctype_h+:} false; then :
23156 $as_echo_n "(cached) " >&6
23157else
23158
23159 if test $ac_cv_header_wctype_h = yes; then
23160
23161
23162 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23163/* end confdefs.h. */
23164#include <wctype.h>
23165
23166_ACEOF
23167 case "$host_os" in
23168 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23169 *) gl_absname_cpp="$ac_cpp" ;;
23170 esac
23171
23172 case "$host_os" in
23173 mingw*)
23174 gl_dirsep_regex='[/\\]'
23175 ;;
23176 *)
23177 gl_dirsep_regex='\/'
23178 ;;
23179 esac
23180 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23181
23182 gl_header_literal_regex=`echo 'wctype.h' \
23183 | sed -e "$gl_make_literal_regex_sed"`
23184 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23185 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23186 s|^/[^/]|//&|
23187 p
23188 q
23189 }'
23190 gl_cv_next_wctype_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23191 sed -n "$gl_absolute_header_sed"`'"'
23192 else
23193 gl_cv_next_wctype_h='<'wctype.h'>'
23194 fi
23195
23196
23197fi
23198{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wctype_h" >&5
23199$as_echo "$gl_cv_next_wctype_h" >&6; }
23200 fi
23201 NEXT_WCTYPE_H=$gl_cv_next_wctype_h
23202
23203 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23204 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23205 gl_next_as_first_directive='<'wctype.h'>'
23206 else
23207 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23208 gl_next_as_first_directive=$gl_cv_next_wctype_h
23209 fi
23210 NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H=$gl_next_as_first_directive
23211
23212
23213
23214
23215 if test $ac_cv_header_wctype_h = yes; then
23216 if test $ac_cv_func_iswcntrl = yes; then
23217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether iswcntrl works" >&5
23218$as_echo_n "checking whether iswcntrl works... " >&6; }
23219if ${gl_cv_func_iswcntrl_works+:} false; then :
23220 $as_echo_n "(cached) " >&6
23221else
23222
23223 if test "$cross_compiling" = yes; then :
23224 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23225/* end confdefs.h. */
23226#include <stdlib.h>
23227 #if __GNU_LIBRARY__ == 1
23228 Linux libc5 i18n is broken.
23229 #endif
23230int
23231main (void)
23232{
23233
23234 ;
23235 return 0;
23236}
23237_ACEOF
23238if ac_fn_c_try_compile "$LINENO"; then :
23239 gl_cv_func_iswcntrl_works="guessing yes"
23240else
23241 gl_cv_func_iswcntrl_works="guessing no"
23242fi
23243rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23244
23245else
23246 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23247/* end confdefs.h. */
23248
23249 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
23250 included before <wchar.h>.
23251 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
23252 must be included before <wchar.h>. */
23253 #include <stddef.h>
23254 #include <stdio.h>
23255 #include <time.h>
23256 #include <wchar.h>
23257 #include <wctype.h>
23258 int main () { return iswprint ('x') == 0; }
23259
23260_ACEOF
23261if ac_fn_c_try_run "$LINENO"; then :
23262 gl_cv_func_iswcntrl_works=yes
23263else
23264 gl_cv_func_iswcntrl_works=no
23265fi
23266rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23267 conftest.$ac_objext conftest.beam conftest.$ac_ext
23268fi
23269
23270
23271fi
23272{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_iswcntrl_works" >&5
23273$as_echo "$gl_cv_func_iswcntrl_works" >&6; }
23274 fi
23275 HAVE_WCTYPE_H=1
23276 else
23277 HAVE_WCTYPE_H=0
23278 fi
23279
23280
23281 case "$gl_cv_func_iswcntrl_works" in
23282 *yes) REPLACE_ISWCNTRL=0 ;;
23283 *) REPLACE_ISWCNTRL=1 ;;
23284 esac
23285
23286
23287 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_ISWCNTRL = 1; then
23288 :
23289 fi
23290
23291 if test $REPLACE_ISWCNTRL = 1; then
23292 REPLACE_TOWLOWER=1
23293 else
23294 for ac_func in towlower
23295do :
23296 ac_fn_c_check_func "$LINENO" "towlower" "ac_cv_func_towlower"
23297if test "x$ac_cv_func_towlower" = xyes; then :
23298 cat >>confdefs.h <<_ACEOF
23299#define HAVE_TOWLOWER 1
23300_ACEOF
23301
23302fi
23303done
23304
23305 if test $ac_cv_func_towlower = yes; then
23306 REPLACE_TOWLOWER=0
23307 else
23308 ac_fn_c_check_decl "$LINENO" "towlower" "ac_cv_have_decl_towlower" "/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
23309 included before <wchar.h>.
23310 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
23311 must be included before <wchar.h>. */
23312 #include <stddef.h>
23313 #include <stdio.h>
23314 #include <time.h>
23315 #include <wchar.h>
23316 #if HAVE_WCTYPE_H
23317 # include <wctype.h>
23318 #endif
23319
23320"
23321if test "x$ac_cv_have_decl_towlower" = xyes; then :
23322 ac_have_decl=1
23323else
23324 ac_have_decl=0
23325fi
23326
23327cat >>confdefs.h <<_ACEOF
23328#define HAVE_DECL_TOWLOWER $ac_have_decl
23329_ACEOF
23330
23331 if test $ac_cv_have_decl_towlower = yes; then
23332 REPLACE_TOWLOWER=1
23333 else
23334 REPLACE_TOWLOWER=0
23335 fi
23336 fi
23337 fi
23338
23339
23340 if test $HAVE_ISWCNTRL = 0 || test $REPLACE_TOWLOWER = 1; then
23341 :
23342 fi
23343
23344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctype_t" >&5
23345$as_echo_n "checking for wctype_t... " >&6; }
23346if ${gl_cv_type_wctype_t+:} false; then :
23347 $as_echo_n "(cached) " >&6
23348else
23349 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23350/* end confdefs.h. */
23351/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
23352 included before <wchar.h>.
23353 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
23354 must be included before <wchar.h>. */
23355 #include <stddef.h>
23356 #include <stdio.h>
23357 #include <time.h>
23358 #include <wchar.h>
23359 #if HAVE_WCTYPE_H
23360 # include <wctype.h>
23361 #endif
23362 wctype_t a;
23363
23364int
23365main (void)
23366{
23367
23368 ;
23369 return 0;
23370}
23371_ACEOF
23372if ac_fn_c_try_compile "$LINENO"; then :
23373 gl_cv_type_wctype_t=yes
23374else
23375 gl_cv_type_wctype_t=no
23376fi
23377rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23378
23379fi
23380{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctype_t" >&5
23381$as_echo "$gl_cv_type_wctype_t" >&6; }
23382 if test $gl_cv_type_wctype_t = no; then
23383 HAVE_WCTYPE_T=0
23384 fi
23385
23386 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctrans_t" >&5
23387$as_echo_n "checking for wctrans_t... " >&6; }
23388if ${gl_cv_type_wctrans_t+:} false; then :
23389 $as_echo_n "(cached) " >&6
23390else
23391 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23392/* end confdefs.h. */
23393/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
23394 included before <wchar.h>.
23395 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
23396 must be included before <wchar.h>. */
23397 #include <stddef.h>
23398 #include <stdio.h>
23399 #include <time.h>
23400 #include <wchar.h>
23401 #include <wctype.h>
23402 wctrans_t a;
23403
23404int
23405main (void)
23406{
23407
23408 ;
23409 return 0;
23410}
23411_ACEOF
23412if ac_fn_c_try_compile "$LINENO"; then :
23413 gl_cv_type_wctrans_t=yes
23414else
23415 gl_cv_type_wctrans_t=no
23416fi
23417rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23418
23419fi
23420{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctrans_t" >&5
23421$as_echo "$gl_cv_type_wctrans_t" >&6; }
23422 if test $gl_cv_type_wctrans_t = no; then
23423 HAVE_WCTRANS_T=0
23424 fi
23425
23426
23427 for gl_func in wctype iswctype wctrans towctrans ; do
23428 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
23429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
23430$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
23431if eval \${$as_gl_Symbol+:} false; then :
23432 $as_echo_n "(cached) " >&6
23433else
23434 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23435/* end confdefs.h. */
23436
23437/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
23438 <wchar.h>.
23439 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
23440 included before <wchar.h>. */
23441#if !(defined __GLIBC__ && !defined __UCLIBC__)
23442# include <stddef.h>
23443# include <stdio.h>
23444# include <time.h>
23445# include <wchar.h>
23446#endif
23447#include <wctype.h>
23448
23449int
23450main (void)
23451{
23452#undef $gl_func
23453 (void) $gl_func;
23454 ;
23455 return 0;
23456}
23457_ACEOF
23458if ac_fn_c_try_compile "$LINENO"; then :
23459 eval "$as_gl_Symbol=yes"
23460else
23461 eval "$as_gl_Symbol=no"
23462fi
23463rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23464fi
23465eval ac_res=\$$as_gl_Symbol
23466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
23467$as_echo "$ac_res" >&6; }
23468 if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then :
23469 cat >>confdefs.h <<_ACEOF
23470#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
23471_ACEOF
23472
23473 eval ac_cv_have_decl_$gl_func=yes
23474fi
23475 done
23476
23477
23478
23479
23480
23481
23482
23483
23484
23485
23486
23487
23488
23489 ac_fn_c_check_decl "$LINENO" "wcwidth" "ac_cv_have_decl_wcwidth" "
23490/* AIX 3.2.5 declares wcwidth in <string.h>. */
23491#include <string.h>
23492/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
23493 <wchar.h>.
23494 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
23495 before <wchar.h>. */
23496#include <stddef.h>
23497#include <stdio.h>
23498#include <time.h>
23499#include <wchar.h>
23500
23501"
23502if test "x$ac_cv_have_decl_wcwidth" = xyes; then :
23503 ac_have_decl=1
23504else
23505 ac_have_decl=0
23506fi
23507
23508cat >>confdefs.h <<_ACEOF
23509#define HAVE_DECL_WCWIDTH $ac_have_decl
23510_ACEOF
23511
23512 if test $ac_cv_have_decl_wcwidth != yes; then
23513 HAVE_DECL_WCWIDTH=0
23514 fi
23515
23516 if test $ac_cv_func_wcwidth = yes; then
23517 HAVE_WCWIDTH=1
23518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether wcwidth works reasonably in UTF-8 locales" >&5
23519$as_echo_n "checking whether wcwidth works reasonably in UTF-8 locales... " >&6; }
23520if ${gl_cv_func_wcwidth_works+:} false; then :
23521 $as_echo_n "(cached) " >&6
23522else
23523
23524 if test "$cross_compiling" = yes; then :
23525
23526 case "$host_os" in
23527 # Guess yes on glibc and AIX 7 systems.
23528 *-gnu* | aix[7-9]*) gl_cv_func_wcwidth_works="guessing yes";;
23529 *) gl_cv_func_wcwidth_works="guessing no";;
23530 esac
23531
23532else
23533 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23534/* end confdefs.h. */
23535
23536#include <locale.h>
23537/* AIX 3.2.5 declares wcwidth in <string.h>. */
23538#include <string.h>
23539/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
23540 <wchar.h>.
23541 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
23542 before <wchar.h>. */
23543#include <stddef.h>
23544#include <stdio.h>
23545#include <time.h>
23546#include <wchar.h>
23547#if !HAVE_DECL_WCWIDTH
23548extern
23549# ifdef __cplusplus
23550"C"
23551# endif
23552int wcwidth (int);
23553#endif
23554int main ()
23555{
23556 int result = 0;
23557 if (setlocale (LC_ALL, "fr_FR.UTF-8") != NULL)
23558 {
23559 if (wcwidth (0x0301) > 0)
23560 result |= 1;
23561 if (wcwidth (0x05B0) > 0)
23562 result |= 2;
23563 if (wcwidth (0x200B) > 0)
23564 result |= 4;
23565 }
23566 return result;
23567}
23568_ACEOF
23569if ac_fn_c_try_run "$LINENO"; then :
23570 gl_cv_func_wcwidth_works=yes
23571else
23572 gl_cv_func_wcwidth_works=no
23573fi
23574rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23575 conftest.$ac_objext conftest.beam conftest.$ac_ext
23576fi
23577
23578
23579fi
23580{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_wcwidth_works" >&5
23581$as_echo "$gl_cv_func_wcwidth_works" >&6; }
23582 case "$gl_cv_func_wcwidth_works" in
23583 *yes) ;;
23584 *no) REPLACE_WCWIDTH=1 ;;
23585 esac
23586 else
23587 HAVE_WCWIDTH=0
23588 fi
23589
23590 if test $HAVE_WCWIDTH = 0 || test $REPLACE_WCWIDTH = 1; then
23591
23592
23593
23594
23595
23596
23597
23598
23599 gl_LIBOBJS="$gl_LIBOBJS wcwidth.$ac_objext"
23600
23601 fi
23602
23603
23604
23605
23606
23607 GNULIB_WCWIDTH=1
23608
23609
23610
23611
23612
23613$as_echo "#define GNULIB_TEST_WCWIDTH 1" >>confdefs.h
23614
23615
23616
23617
23618
23619 for ac_header in stdint.h
23620do :
23621 ac_fn_c_check_header_mongrel "$LINENO" "stdint.h" "ac_cv_header_stdint_h" "$ac_includes_default"
23622if test "x$ac_cv_header_stdint_h" = xyes; then :
23623 cat >>confdefs.h <<_ACEOF
23624#define HAVE_STDINT_H 1
23625_ACEOF
23626
23627fi
23628
23629done
23630
23631
23632 # End of code from modules
23633
23634
23635
23636
23637
23638
23639
23640
23641
23642 gltests_libdeps=
23643 gltests_ltlibdeps=
23644
23645
23646
23647
23648
23649
23650
23651
23652
23653 gl_source_base='tests'
23654 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
23655
23656 gl_module_indicator_condition=$gltests_WITNESS
23657
23658
23659
23660
23661
23662
23663
23664
23665
23666 LIBGNU_LIBDEPS="$gl_libdeps"
23667
23668 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
23669
23670
23671
23672WARN_FLAGS="-Wall -W -Wshadow -Wpointer-arith -Wundef -Wchar-subscripts -Wcomment -Wdeprecated-declarations -Wdisabled-optimization -Wdiv-by-zero -Wfloat-equal -Wformat-extra-args -Wformat-security -Wformat-y2k -Wimplicit -Wimplicit-function-declaration -Wimplicit-int -Wmain -Wmissing-braces -Wmissing-format-attribute -Wmultichar -Wparentheses -Wreturn-type -Wsequence-point -Wshadow -Wsign-compare -Wswitch -Wtrigraphs -Wunknown-pragmas -Wunused -Wunused-function -Wunused-label -Wunused-parameter -Wunused-value -Wunused-variable -Wwrite-strings -Wnested-externs -Wstrict-prototypes"
23673EXTRA_WARN_FLAGS="-Wextra -Wattributes -Wendif-labels -Winit-self -Wint-to-pointer-cast -Winvalid-pch -Wmissing-field-initializers -Wnonnull -Woverflow -Wvla -Wpointer-to-int-cast -Wstrict-aliasing -Wvariadic-macros -Wvolatile-register-var -Wpointer-sign -Wmissing-include-dirs -Wmissing-prototypes -Wmissing-declarations -Wformat=2"
23674
23675HOST_CFLAGS="$HOST_CFLAGS $WARN_FLAGS -Wcast-align"
23676
23677{ $as_echo "$as_me:${as_lineno-$LINENO}: checking which extra warnings work" >&5
23678$as_echo_n "checking which extra warnings work... " >&6; }
23679if ${grub_cv_cc_w_extra_flags+:} false; then :
23680 $as_echo_n "(cached) " >&6
23681else
23682
23683 SAVED_CFLAGS="$CFLAGS"
23684 grub_cv_cc_w_extra_flags=
23685 for x in $EXTRA_WARN_FLAGS; do
23686 CFLAGS="$HOST_CFLAGS $x -Werror"
23687 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23688/* end confdefs.h. */
23689
23690int
23691main (void)
23692{
23693
23694 ;
23695 return 0;
23696}
23697_ACEOF
23698if ac_fn_c_try_link "$LINENO"; then :
23699 flag=1
23700else
23701 flag=0
23702fi
23703rm -f core conftest.err conftest.$ac_objext \
23704 conftest$ac_exeext conftest.$ac_ext
23705 if test x$flag = x1 ; then
23706 grub_cv_cc_w_extra_flags="$grub_cv_cc_w_extra_flags $x"
23707 fi
23708 done
23709 CFLAGS="$SAVED_CFLAGS"
23710
23711fi
23712{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_w_extra_flags" >&5
23713$as_echo "$grub_cv_cc_w_extra_flags" >&6; }
23714
23715HOST_CFLAGS="$HOST_CFLAGS $grub_cv_cc_w_extra_flags"
23716
23717#
23718# Check for target programs.
23719#
23720
23721# Find tools for the target.
23722if test "x$target_alias" != x && test "x$host_alias" != "x$target_alias"; then
23723 tmp_ac_tool_prefix="$ac_tool_prefix"
23724 ac_tool_prefix=$target_alias-
23725
23726 if test -n "$ac_tool_prefix"; then
23727 for ac_prog in gcc egcs cc
23728 do
23729 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
23730set dummy $ac_tool_prefix$ac_prog; ac_word=$2
23731{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
23732$as_echo_n "checking for $ac_word... " >&6; }
23733if ${ac_cv_prog_TARGET_CC+:} false; then :
23734 $as_echo_n "(cached) " >&6
23735else
23736 if test -n "$TARGET_CC"; then
23737 ac_cv_prog_TARGET_CC="$TARGET_CC" # Let the user override the test.
23738else
23739as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23740for as_dir in $PATH
23741do
23742 IFS=$as_save_IFS
23743 test -z "$as_dir" && as_dir=.
23744 for ac_exec_ext in '' $ac_executable_extensions; do
23745 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
23746 ac_cv_prog_TARGET_CC="$ac_tool_prefix$ac_prog"
23747 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
23748 break 2
23749 fi
23750done
23751 done
23752IFS=$as_save_IFS
23753
23754fi
23755fi
23756TARGET_CC=$ac_cv_prog_TARGET_CC
23757if test -n "$TARGET_CC"; then
23758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TARGET_CC" >&5
23759$as_echo "$TARGET_CC" >&6; }
23760else
23761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23762$as_echo "no" >&6; }
23763fi
23764
23765
23766 test -n "$TARGET_CC" && break
23767 done
23768fi
23769if test -z "$TARGET_CC"; then
23770 ac_ct_TARGET_CC=$TARGET_CC
23771 for ac_prog in gcc egcs cc
23772do
23773 # Extract the first word of "$ac_prog", so it can be a program name with args.
23774set dummy $ac_prog; ac_word=$2
23775{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
23776$as_echo_n "checking for $ac_word... " >&6; }
23777if ${ac_cv_prog_ac_ct_TARGET_CC+:} false; then :
23778 $as_echo_n "(cached) " >&6
23779else
23780 if test -n "$ac_ct_TARGET_CC"; then
23781 ac_cv_prog_ac_ct_TARGET_CC="$ac_ct_TARGET_CC" # Let the user override the test.
23782else
23783as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23784for as_dir in $PATH
23785do
23786 IFS=$as_save_IFS
23787 test -z "$as_dir" && as_dir=.
23788 for ac_exec_ext in '' $ac_executable_extensions; do
23789 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
23790 ac_cv_prog_ac_ct_TARGET_CC="$ac_prog"
23791 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
23792 break 2
23793 fi
23794done
23795 done
23796IFS=$as_save_IFS
23797
23798fi
23799fi
23800ac_ct_TARGET_CC=$ac_cv_prog_ac_ct_TARGET_CC
23801if test -n "$ac_ct_TARGET_CC"; then
23802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_TARGET_CC" >&5
23803$as_echo "$ac_ct_TARGET_CC" >&6; }
23804else
23805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23806$as_echo "no" >&6; }
23807fi
23808
23809
23810 test -n "$ac_ct_TARGET_CC" && break
23811done
23812
23813 if test "x$ac_ct_TARGET_CC" = x; then
23814 TARGET_CC="as_fn_error $? "none of gcc, egcs and cc is found. set TARGET_CC manually." "$LINENO" 5"
23815 else
23816 case $cross_compiling:$ac_tool_warned in
23817yes:)
23818{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
23819$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
23820ac_tool_warned=yes ;;
23821esac
23822 TARGET_CC=$ac_ct_TARGET_CC
23823 fi
23824fi
23825
23826 if test -n "$ac_tool_prefix"; then
23827 # Extract the first word of "${ac_tool_prefix}objcopy", so it can be a program name with args.
23828set dummy ${ac_tool_prefix}objcopy; ac_word=$2
23829{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
23830$as_echo_n "checking for $ac_word... " >&6; }
23831if ${ac_cv_prog_TARGET_OBJCOPY+:} false; then :
23832 $as_echo_n "(cached) " >&6
23833else
23834 if test -n "$TARGET_OBJCOPY"; then
23835 ac_cv_prog_TARGET_OBJCOPY="$TARGET_OBJCOPY" # Let the user override the test.
23836else
23837as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23838for as_dir in $PATH
23839do
23840 IFS=$as_save_IFS
23841 test -z "$as_dir" && as_dir=.
23842 for ac_exec_ext in '' $ac_executable_extensions; do
23843 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
23844 ac_cv_prog_TARGET_OBJCOPY="${ac_tool_prefix}objcopy"
23845 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
23846 break 2
23847 fi
23848done
23849 done
23850IFS=$as_save_IFS
23851
23852fi
23853fi
23854TARGET_OBJCOPY=$ac_cv_prog_TARGET_OBJCOPY
23855if test -n "$TARGET_OBJCOPY"; then
23856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TARGET_OBJCOPY" >&5
23857$as_echo "$TARGET_OBJCOPY" >&6; }
23858else
23859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23860$as_echo "no" >&6; }
23861fi
23862
23863
23864fi
23865if test -z "$ac_cv_prog_TARGET_OBJCOPY"; then
23866 ac_ct_TARGET_OBJCOPY=$TARGET_OBJCOPY
23867 # Extract the first word of "objcopy", so it can be a program name with args.
23868set dummy objcopy; ac_word=$2
23869{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
23870$as_echo_n "checking for $ac_word... " >&6; }
23871if ${ac_cv_prog_ac_ct_TARGET_OBJCOPY+:} false; then :
23872 $as_echo_n "(cached) " >&6
23873else
23874 if test -n "$ac_ct_TARGET_OBJCOPY"; then
23875 ac_cv_prog_ac_ct_TARGET_OBJCOPY="$ac_ct_TARGET_OBJCOPY" # Let the user override the test.
23876else
23877as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23878for as_dir in $PATH
23879do
23880 IFS=$as_save_IFS
23881 test -z "$as_dir" && as_dir=.
23882 for ac_exec_ext in '' $ac_executable_extensions; do
23883 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
23884 ac_cv_prog_ac_ct_TARGET_OBJCOPY="objcopy"
23885 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
23886 break 2
23887 fi
23888done
23889 done
23890IFS=$as_save_IFS
23891
23892fi
23893fi
23894ac_ct_TARGET_OBJCOPY=$ac_cv_prog_ac_ct_TARGET_OBJCOPY
23895if test -n "$ac_ct_TARGET_OBJCOPY"; then
23896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_TARGET_OBJCOPY" >&5
23897$as_echo "$ac_ct_TARGET_OBJCOPY" >&6; }
23898else
23899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23900$as_echo "no" >&6; }
23901fi
23902
23903 if test "x$ac_ct_TARGET_OBJCOPY" = x; then
23904 TARGET_OBJCOPY=""
23905 else
23906 case $cross_compiling:$ac_tool_warned in
23907yes:)
23908{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
23909$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
23910ac_tool_warned=yes ;;
23911esac
23912 TARGET_OBJCOPY=$ac_ct_TARGET_OBJCOPY
23913 fi
23914else
23915 TARGET_OBJCOPY="$ac_cv_prog_TARGET_OBJCOPY"
23916fi
23917
23918 if test -n "$ac_tool_prefix"; then
23919 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
23920set dummy ${ac_tool_prefix}strip; ac_word=$2
23921{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
23922$as_echo_n "checking for $ac_word... " >&6; }
23923if ${ac_cv_prog_TARGET_STRIP+:} false; then :
23924 $as_echo_n "(cached) " >&6
23925else
23926 if test -n "$TARGET_STRIP"; then
23927 ac_cv_prog_TARGET_STRIP="$TARGET_STRIP" # Let the user override the test.
23928else
23929as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23930for as_dir in $PATH
23931do
23932 IFS=$as_save_IFS
23933 test -z "$as_dir" && as_dir=.
23934 for ac_exec_ext in '' $ac_executable_extensions; do
23935 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
23936 ac_cv_prog_TARGET_STRIP="${ac_tool_prefix}strip"
23937 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
23938 break 2
23939 fi
23940done
23941 done
23942IFS=$as_save_IFS
23943
23944fi
23945fi
23946TARGET_STRIP=$ac_cv_prog_TARGET_STRIP
23947if test -n "$TARGET_STRIP"; then
23948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TARGET_STRIP" >&5
23949$as_echo "$TARGET_STRIP" >&6; }
23950else
23951 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23952$as_echo "no" >&6; }
23953fi
23954
23955
23956fi
23957if test -z "$ac_cv_prog_TARGET_STRIP"; then
23958 ac_ct_TARGET_STRIP=$TARGET_STRIP
23959 # Extract the first word of "strip", so it can be a program name with args.
23960set dummy strip; ac_word=$2
23961{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
23962$as_echo_n "checking for $ac_word... " >&6; }
23963if ${ac_cv_prog_ac_ct_TARGET_STRIP+:} false; then :
23964 $as_echo_n "(cached) " >&6
23965else
23966 if test -n "$ac_ct_TARGET_STRIP"; then
23967 ac_cv_prog_ac_ct_TARGET_STRIP="$ac_ct_TARGET_STRIP" # Let the user override the test.
23968else
23969as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23970for as_dir in $PATH
23971do
23972 IFS=$as_save_IFS
23973 test -z "$as_dir" && as_dir=.
23974 for ac_exec_ext in '' $ac_executable_extensions; do
23975 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
23976 ac_cv_prog_ac_ct_TARGET_STRIP="strip"
23977 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
23978 break 2
23979 fi
23980done
23981 done
23982IFS=$as_save_IFS
23983
23984fi
23985fi
23986ac_ct_TARGET_STRIP=$ac_cv_prog_ac_ct_TARGET_STRIP
23987if test -n "$ac_ct_TARGET_STRIP"; then
23988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_TARGET_STRIP" >&5
23989$as_echo "$ac_ct_TARGET_STRIP" >&6; }
23990else
23991 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23992$as_echo "no" >&6; }
23993fi
23994
23995 if test "x$ac_ct_TARGET_STRIP" = x; then
23996 TARGET_STRIP=""
23997 else
23998 case $cross_compiling:$ac_tool_warned in
23999yes:)
24000{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
24001$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
24002ac_tool_warned=yes ;;
24003esac
24004 TARGET_STRIP=$ac_ct_TARGET_STRIP
24005 fi
24006else
24007 TARGET_STRIP="$ac_cv_prog_TARGET_STRIP"
24008fi
24009
24010 if test -n "$ac_tool_prefix"; then
24011 # Extract the first word of "${ac_tool_prefix}nm", so it can be a program name with args.
24012set dummy ${ac_tool_prefix}nm; ac_word=$2
24013{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24014$as_echo_n "checking for $ac_word... " >&6; }
24015if ${ac_cv_prog_TARGET_NM+:} false; then :
24016 $as_echo_n "(cached) " >&6
24017else
24018 if test -n "$TARGET_NM"; then
24019 ac_cv_prog_TARGET_NM="$TARGET_NM" # Let the user override the test.
24020else
24021as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24022for as_dir in $PATH
24023do
24024 IFS=$as_save_IFS
24025 test -z "$as_dir" && as_dir=.
24026 for ac_exec_ext in '' $ac_executable_extensions; do
24027 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24028 ac_cv_prog_TARGET_NM="${ac_tool_prefix}nm"
24029 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24030 break 2
24031 fi
24032done
24033 done
24034IFS=$as_save_IFS
24035
24036fi
24037fi
24038TARGET_NM=$ac_cv_prog_TARGET_NM
24039if test -n "$TARGET_NM"; then
24040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TARGET_NM" >&5
24041$as_echo "$TARGET_NM" >&6; }
24042else
24043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24044$as_echo "no" >&6; }
24045fi
24046
24047
24048fi
24049if test -z "$ac_cv_prog_TARGET_NM"; then
24050 ac_ct_TARGET_NM=$TARGET_NM
24051 # Extract the first word of "nm", so it can be a program name with args.
24052set dummy nm; ac_word=$2
24053{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24054$as_echo_n "checking for $ac_word... " >&6; }
24055if ${ac_cv_prog_ac_ct_TARGET_NM+:} false; then :
24056 $as_echo_n "(cached) " >&6
24057else
24058 if test -n "$ac_ct_TARGET_NM"; then
24059 ac_cv_prog_ac_ct_TARGET_NM="$ac_ct_TARGET_NM" # Let the user override the test.
24060else
24061as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24062for as_dir in $PATH
24063do
24064 IFS=$as_save_IFS
24065 test -z "$as_dir" && as_dir=.
24066 for ac_exec_ext in '' $ac_executable_extensions; do
24067 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24068 ac_cv_prog_ac_ct_TARGET_NM="nm"
24069 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24070 break 2
24071 fi
24072done
24073 done
24074IFS=$as_save_IFS
24075
24076fi
24077fi
24078ac_ct_TARGET_NM=$ac_cv_prog_ac_ct_TARGET_NM
24079if test -n "$ac_ct_TARGET_NM"; then
24080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_TARGET_NM" >&5
24081$as_echo "$ac_ct_TARGET_NM" >&6; }
24082else
24083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24084$as_echo "no" >&6; }
24085fi
24086
24087 if test "x$ac_ct_TARGET_NM" = x; then
24088 TARGET_NM=""
24089 else
24090 case $cross_compiling:$ac_tool_warned in
24091yes:)
24092{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
24093$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
24094ac_tool_warned=yes ;;
24095esac
24096 TARGET_NM=$ac_ct_TARGET_NM
24097 fi
24098else
24099 TARGET_NM="$ac_cv_prog_TARGET_NM"
24100fi
24101
24102 if test -n "$ac_tool_prefix"; then
24103 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
24104set dummy ${ac_tool_prefix}ranlib; ac_word=$2
24105{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24106$as_echo_n "checking for $ac_word... " >&6; }
24107if ${ac_cv_prog_TARGET_RANLIB+:} false; then :
24108 $as_echo_n "(cached) " >&6
24109else
24110 if test -n "$TARGET_RANLIB"; then
24111 ac_cv_prog_TARGET_RANLIB="$TARGET_RANLIB" # Let the user override the test.
24112else
24113as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24114for as_dir in $PATH
24115do
24116 IFS=$as_save_IFS
24117 test -z "$as_dir" && as_dir=.
24118 for ac_exec_ext in '' $ac_executable_extensions; do
24119 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24120 ac_cv_prog_TARGET_RANLIB="${ac_tool_prefix}ranlib"
24121 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24122 break 2
24123 fi
24124done
24125 done
24126IFS=$as_save_IFS
24127
24128fi
24129fi
24130TARGET_RANLIB=$ac_cv_prog_TARGET_RANLIB
24131if test -n "$TARGET_RANLIB"; then
24132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TARGET_RANLIB" >&5
24133$as_echo "$TARGET_RANLIB" >&6; }
24134else
24135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24136$as_echo "no" >&6; }
24137fi
24138
24139
24140fi
24141if test -z "$ac_cv_prog_TARGET_RANLIB"; then
24142 ac_ct_TARGET_RANLIB=$TARGET_RANLIB
24143 # Extract the first word of "ranlib", so it can be a program name with args.
24144set dummy ranlib; ac_word=$2
24145{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24146$as_echo_n "checking for $ac_word... " >&6; }
24147if ${ac_cv_prog_ac_ct_TARGET_RANLIB+:} false; then :
24148 $as_echo_n "(cached) " >&6
24149else
24150 if test -n "$ac_ct_TARGET_RANLIB"; then
24151 ac_cv_prog_ac_ct_TARGET_RANLIB="$ac_ct_TARGET_RANLIB" # Let the user override the test.
24152else
24153as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24154for as_dir in $PATH
24155do
24156 IFS=$as_save_IFS
24157 test -z "$as_dir" && as_dir=.
24158 for ac_exec_ext in '' $ac_executable_extensions; do
24159 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24160 ac_cv_prog_ac_ct_TARGET_RANLIB="ranlib"
24161 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24162 break 2
24163 fi
24164done
24165 done
24166IFS=$as_save_IFS
24167
24168fi
24169fi
24170ac_ct_TARGET_RANLIB=$ac_cv_prog_ac_ct_TARGET_RANLIB
24171if test -n "$ac_ct_TARGET_RANLIB"; then
24172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_TARGET_RANLIB" >&5
24173$as_echo "$ac_ct_TARGET_RANLIB" >&6; }
24174else
24175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24176$as_echo "no" >&6; }
24177fi
24178
24179 if test "x$ac_ct_TARGET_RANLIB" = x; then
24180 TARGET_RANLIB=""
24181 else
24182 case $cross_compiling:$ac_tool_warned in
24183yes:)
24184{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
24185$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
24186ac_tool_warned=yes ;;
24187esac
24188 TARGET_RANLIB=$ac_ct_TARGET_RANLIB
24189 fi
24190else
24191 TARGET_RANLIB="$ac_cv_prog_TARGET_RANLIB"
24192fi
24193
24194
24195 ac_tool_prefix="$tmp_ac_tool_prefix"
24196else
24197 if test "x$TARGET_CC" = x; then
24198 TARGET_CC=$CC
24199 fi
24200 if test -n "$ac_tool_prefix"; then
24201 # Extract the first word of "${ac_tool_prefix}objcopy", so it can be a program name with args.
24202set dummy ${ac_tool_prefix}objcopy; ac_word=$2
24203{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24204$as_echo_n "checking for $ac_word... " >&6; }
24205if ${ac_cv_prog_TARGET_OBJCOPY+:} false; then :
24206 $as_echo_n "(cached) " >&6
24207else
24208 if test -n "$TARGET_OBJCOPY"; then
24209 ac_cv_prog_TARGET_OBJCOPY="$TARGET_OBJCOPY" # Let the user override the test.
24210else
24211as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24212for as_dir in $PATH
24213do
24214 IFS=$as_save_IFS
24215 test -z "$as_dir" && as_dir=.
24216 for ac_exec_ext in '' $ac_executable_extensions; do
24217 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24218 ac_cv_prog_TARGET_OBJCOPY="${ac_tool_prefix}objcopy"
24219 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24220 break 2
24221 fi
24222done
24223 done
24224IFS=$as_save_IFS
24225
24226fi
24227fi
24228TARGET_OBJCOPY=$ac_cv_prog_TARGET_OBJCOPY
24229if test -n "$TARGET_OBJCOPY"; then
24230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TARGET_OBJCOPY" >&5
24231$as_echo "$TARGET_OBJCOPY" >&6; }
24232else
24233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24234$as_echo "no" >&6; }
24235fi
24236
24237
24238fi
24239if test -z "$ac_cv_prog_TARGET_OBJCOPY"; then
24240 ac_ct_TARGET_OBJCOPY=$TARGET_OBJCOPY
24241 # Extract the first word of "objcopy", so it can be a program name with args.
24242set dummy objcopy; ac_word=$2
24243{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24244$as_echo_n "checking for $ac_word... " >&6; }
24245if ${ac_cv_prog_ac_ct_TARGET_OBJCOPY+:} false; then :
24246 $as_echo_n "(cached) " >&6
24247else
24248 if test -n "$ac_ct_TARGET_OBJCOPY"; then
24249 ac_cv_prog_ac_ct_TARGET_OBJCOPY="$ac_ct_TARGET_OBJCOPY" # Let the user override the test.
24250else
24251as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24252for as_dir in $PATH
24253do
24254 IFS=$as_save_IFS
24255 test -z "$as_dir" && as_dir=.
24256 for ac_exec_ext in '' $ac_executable_extensions; do
24257 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24258 ac_cv_prog_ac_ct_TARGET_OBJCOPY="objcopy"
24259 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24260 break 2
24261 fi
24262done
24263 done
24264IFS=$as_save_IFS
24265
24266fi
24267fi
24268ac_ct_TARGET_OBJCOPY=$ac_cv_prog_ac_ct_TARGET_OBJCOPY
24269if test -n "$ac_ct_TARGET_OBJCOPY"; then
24270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_TARGET_OBJCOPY" >&5
24271$as_echo "$ac_ct_TARGET_OBJCOPY" >&6; }
24272else
24273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24274$as_echo "no" >&6; }
24275fi
24276
24277 if test "x$ac_ct_TARGET_OBJCOPY" = x; then
24278 TARGET_OBJCOPY=""
24279 else
24280 case $cross_compiling:$ac_tool_warned in
24281yes:)
24282{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
24283$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
24284ac_tool_warned=yes ;;
24285esac
24286 TARGET_OBJCOPY=$ac_ct_TARGET_OBJCOPY
24287 fi
24288else
24289 TARGET_OBJCOPY="$ac_cv_prog_TARGET_OBJCOPY"
24290fi
24291
24292 if test -n "$ac_tool_prefix"; then
24293 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
24294set dummy ${ac_tool_prefix}strip; ac_word=$2
24295{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24296$as_echo_n "checking for $ac_word... " >&6; }
24297if ${ac_cv_prog_TARGET_STRIP+:} false; then :
24298 $as_echo_n "(cached) " >&6
24299else
24300 if test -n "$TARGET_STRIP"; then
24301 ac_cv_prog_TARGET_STRIP="$TARGET_STRIP" # Let the user override the test.
24302else
24303as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24304for as_dir in $PATH
24305do
24306 IFS=$as_save_IFS
24307 test -z "$as_dir" && as_dir=.
24308 for ac_exec_ext in '' $ac_executable_extensions; do
24309 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24310 ac_cv_prog_TARGET_STRIP="${ac_tool_prefix}strip"
24311 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24312 break 2
24313 fi
24314done
24315 done
24316IFS=$as_save_IFS
24317
24318fi
24319fi
24320TARGET_STRIP=$ac_cv_prog_TARGET_STRIP
24321if test -n "$TARGET_STRIP"; then
24322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TARGET_STRIP" >&5
24323$as_echo "$TARGET_STRIP" >&6; }
24324else
24325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24326$as_echo "no" >&6; }
24327fi
24328
24329
24330fi
24331if test -z "$ac_cv_prog_TARGET_STRIP"; then
24332 ac_ct_TARGET_STRIP=$TARGET_STRIP
24333 # Extract the first word of "strip", so it can be a program name with args.
24334set dummy strip; ac_word=$2
24335{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24336$as_echo_n "checking for $ac_word... " >&6; }
24337if ${ac_cv_prog_ac_ct_TARGET_STRIP+:} false; then :
24338 $as_echo_n "(cached) " >&6
24339else
24340 if test -n "$ac_ct_TARGET_STRIP"; then
24341 ac_cv_prog_ac_ct_TARGET_STRIP="$ac_ct_TARGET_STRIP" # Let the user override the test.
24342else
24343as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24344for as_dir in $PATH
24345do
24346 IFS=$as_save_IFS
24347 test -z "$as_dir" && as_dir=.
24348 for ac_exec_ext in '' $ac_executable_extensions; do
24349 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24350 ac_cv_prog_ac_ct_TARGET_STRIP="strip"
24351 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24352 break 2
24353 fi
24354done
24355 done
24356IFS=$as_save_IFS
24357
24358fi
24359fi
24360ac_ct_TARGET_STRIP=$ac_cv_prog_ac_ct_TARGET_STRIP
24361if test -n "$ac_ct_TARGET_STRIP"; then
24362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_TARGET_STRIP" >&5
24363$as_echo "$ac_ct_TARGET_STRIP" >&6; }
24364else
24365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24366$as_echo "no" >&6; }
24367fi
24368
24369 if test "x$ac_ct_TARGET_STRIP" = x; then
24370 TARGET_STRIP=""
24371 else
24372 case $cross_compiling:$ac_tool_warned in
24373yes:)
24374{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
24375$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
24376ac_tool_warned=yes ;;
24377esac
24378 TARGET_STRIP=$ac_ct_TARGET_STRIP
24379 fi
24380else
24381 TARGET_STRIP="$ac_cv_prog_TARGET_STRIP"
24382fi
24383
24384 if test -n "$ac_tool_prefix"; then
24385 # Extract the first word of "${ac_tool_prefix}nm", so it can be a program name with args.
24386set dummy ${ac_tool_prefix}nm; ac_word=$2
24387{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24388$as_echo_n "checking for $ac_word... " >&6; }
24389if ${ac_cv_prog_TARGET_NM+:} false; then :
24390 $as_echo_n "(cached) " >&6
24391else
24392 if test -n "$TARGET_NM"; then
24393 ac_cv_prog_TARGET_NM="$TARGET_NM" # Let the user override the test.
24394else
24395as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24396for as_dir in $PATH
24397do
24398 IFS=$as_save_IFS
24399 test -z "$as_dir" && as_dir=.
24400 for ac_exec_ext in '' $ac_executable_extensions; do
24401 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24402 ac_cv_prog_TARGET_NM="${ac_tool_prefix}nm"
24403 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24404 break 2
24405 fi
24406done
24407 done
24408IFS=$as_save_IFS
24409
24410fi
24411fi
24412TARGET_NM=$ac_cv_prog_TARGET_NM
24413if test -n "$TARGET_NM"; then
24414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TARGET_NM" >&5
24415$as_echo "$TARGET_NM" >&6; }
24416else
24417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24418$as_echo "no" >&6; }
24419fi
24420
24421
24422fi
24423if test -z "$ac_cv_prog_TARGET_NM"; then
24424 ac_ct_TARGET_NM=$TARGET_NM
24425 # Extract the first word of "nm", so it can be a program name with args.
24426set dummy nm; ac_word=$2
24427{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24428$as_echo_n "checking for $ac_word... " >&6; }
24429if ${ac_cv_prog_ac_ct_TARGET_NM+:} false; then :
24430 $as_echo_n "(cached) " >&6
24431else
24432 if test -n "$ac_ct_TARGET_NM"; then
24433 ac_cv_prog_ac_ct_TARGET_NM="$ac_ct_TARGET_NM" # Let the user override the test.
24434else
24435as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24436for as_dir in $PATH
24437do
24438 IFS=$as_save_IFS
24439 test -z "$as_dir" && as_dir=.
24440 for ac_exec_ext in '' $ac_executable_extensions; do
24441 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24442 ac_cv_prog_ac_ct_TARGET_NM="nm"
24443 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24444 break 2
24445 fi
24446done
24447 done
24448IFS=$as_save_IFS
24449
24450fi
24451fi
24452ac_ct_TARGET_NM=$ac_cv_prog_ac_ct_TARGET_NM
24453if test -n "$ac_ct_TARGET_NM"; then
24454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_TARGET_NM" >&5
24455$as_echo "$ac_ct_TARGET_NM" >&6; }
24456else
24457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24458$as_echo "no" >&6; }
24459fi
24460
24461 if test "x$ac_ct_TARGET_NM" = x; then
24462 TARGET_NM=""
24463 else
24464 case $cross_compiling:$ac_tool_warned in
24465yes:)
24466{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
24467$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
24468ac_tool_warned=yes ;;
24469esac
24470 TARGET_NM=$ac_ct_TARGET_NM
24471 fi
24472else
24473 TARGET_NM="$ac_cv_prog_TARGET_NM"
24474fi
24475
24476 if test -n "$ac_tool_prefix"; then
24477 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
24478set dummy ${ac_tool_prefix}ranlib; ac_word=$2
24479{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24480$as_echo_n "checking for $ac_word... " >&6; }
24481if ${ac_cv_prog_TARGET_RANLIB+:} false; then :
24482 $as_echo_n "(cached) " >&6
24483else
24484 if test -n "$TARGET_RANLIB"; then
24485 ac_cv_prog_TARGET_RANLIB="$TARGET_RANLIB" # Let the user override the test.
24486else
24487as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24488for as_dir in $PATH
24489do
24490 IFS=$as_save_IFS
24491 test -z "$as_dir" && as_dir=.
24492 for ac_exec_ext in '' $ac_executable_extensions; do
24493 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24494 ac_cv_prog_TARGET_RANLIB="${ac_tool_prefix}ranlib"
24495 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24496 break 2
24497 fi
24498done
24499 done
24500IFS=$as_save_IFS
24501
24502fi
24503fi
24504TARGET_RANLIB=$ac_cv_prog_TARGET_RANLIB
24505if test -n "$TARGET_RANLIB"; then
24506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TARGET_RANLIB" >&5
24507$as_echo "$TARGET_RANLIB" >&6; }
24508else
24509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24510$as_echo "no" >&6; }
24511fi
24512
24513
24514fi
24515if test -z "$ac_cv_prog_TARGET_RANLIB"; then
24516 ac_ct_TARGET_RANLIB=$TARGET_RANLIB
24517 # Extract the first word of "ranlib", so it can be a program name with args.
24518set dummy ranlib; ac_word=$2
24519{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24520$as_echo_n "checking for $ac_word... " >&6; }
24521if ${ac_cv_prog_ac_ct_TARGET_RANLIB+:} false; then :
24522 $as_echo_n "(cached) " >&6
24523else
24524 if test -n "$ac_ct_TARGET_RANLIB"; then
24525 ac_cv_prog_ac_ct_TARGET_RANLIB="$ac_ct_TARGET_RANLIB" # Let the user override the test.
24526else
24527as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24528for as_dir in $PATH
24529do
24530 IFS=$as_save_IFS
24531 test -z "$as_dir" && as_dir=.
24532 for ac_exec_ext in '' $ac_executable_extensions; do
24533 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24534 ac_cv_prog_ac_ct_TARGET_RANLIB="ranlib"
24535 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24536 break 2
24537 fi
24538done
24539 done
24540IFS=$as_save_IFS
24541
24542fi
24543fi
24544ac_ct_TARGET_RANLIB=$ac_cv_prog_ac_ct_TARGET_RANLIB
24545if test -n "$ac_ct_TARGET_RANLIB"; then
24546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_TARGET_RANLIB" >&5
24547$as_echo "$ac_ct_TARGET_RANLIB" >&6; }
24548else
24549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24550$as_echo "no" >&6; }
24551fi
24552
24553 if test "x$ac_ct_TARGET_RANLIB" = x; then
24554 TARGET_RANLIB=""
24555 else
24556 case $cross_compiling:$ac_tool_warned in
24557yes:)
24558{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
24559$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
24560ac_tool_warned=yes ;;
24561esac
24562 TARGET_RANLIB=$ac_ct_TARGET_RANLIB
24563 fi
24564else
24565 TARGET_RANLIB="$ac_cv_prog_TARGET_RANLIB"
24566fi
24567
24568fi
24569
24570
24571
24572
24573
24574
24575
24576
24577
24578
24579
24580
24581# Test the C compiler for the target environment.
24582tmp_CC="$CC"
24583tmp_CFLAGS="$CFLAGS"
24584tmp_LDFLAGS="$LDFLAGS"
24585tmp_CPPFLAGS="$CPPFLAGS"
24586tmp_LIBS="$LIBS"
24587CC="$TARGET_CC"
24588CFLAGS="$TARGET_CFLAGS"
24589CPPFLAGS="$TARGET_CPPFLAGS"
24590LDFLAGS="$TARGET_LDFLAGS"
24591LIBS=""
24592
24593# debug flags.
24594TARGET_CFLAGS="$TARGET_CFLAGS $WARN_FLAGS -g -Wredundant-decls -Wmissing-prototypes -Wmissing-declarations"
24595TARGET_CCASFLAGS="$TARGET_CCASFLAGS -g"
24596
24597if test "x$target_cpu" != xi386 && test "x$target_cpu" != xx86_64; then
24598TARGET_CFLAGS="$TARGET_CFLAGS -Wcast-align"
24599fi
24600
24601TARGET_CC_VERSION="$(LC_ALL=C $TARGET_CC --version | head -n1)"
24602
24603{ $as_echo "$as_me:${as_lineno-$LINENO}: checking which extra warnings work" >&5
24604$as_echo_n "checking which extra warnings work... " >&6; }
24605if ${grub_cv_target_cc_w_extra_flags+:} false; then :
24606 $as_echo_n "(cached) " >&6
24607else
24608
24609 LDFLAGS="$TARGET_LDFLAGS -nostdlib -static"
24610
24611 grub_cv_target_cc_w_extra_flags=
24612 for x in $EXTRA_WARN_FLAGS; do
24613 CFLAGS="$TARGET_CFLAGS $x -Werror"
24614 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24615/* end confdefs.h. */
24616
24617asm (".globl start; start:");
24618void __main (void);
24619void __main (void) {}
24620int main (void);
24621
24622int
24623main (void)
24624{
24625
24626 ;
24627 return 0;
24628}
24629_ACEOF
24630if ac_fn_c_try_link "$LINENO"; then :
24631 flag=1
24632else
24633 flag=0
24634fi
24635rm -f core conftest.err conftest.$ac_objext \
24636 conftest$ac_exeext conftest.$ac_ext
24637 if test x$flag = x1 ; then
24638 grub_cv_target_cc_w_extra_flags="$grub_cv_target_cc_w_extra_flags $x"
24639 fi
24640 done
24641
24642fi
24643{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_target_cc_w_extra_flags" >&5
24644$as_echo "$grub_cv_target_cc_w_extra_flags" >&6; }
24645
24646TARGET_CFLAGS="$TARGET_CFLAGS $grub_cv_target_cc_w_extra_flags"
24647
24648{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiling with clang" >&5
24649$as_echo_n "checking if compiling with clang... " >&6; }
24650if ${grub_cv_cc_target_clang+:} false; then :
24651 $as_echo_n "(cached) " >&6
24652else
24653
24654CFLAGS="$TARGET_CFLAGS"
24655cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24656/* end confdefs.h. */
24657
24658int
24659main (void)
24660{
24661
24662#ifdef __clang__
24663#error "is clang"
24664#endif
24665
24666 ;
24667 return 0;
24668}
24669_ACEOF
24670if ac_fn_c_try_compile "$LINENO"; then :
24671 grub_cv_cc_target_clang=no
24672else
24673 grub_cv_cc_target_clang=yes
24674fi
24675rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24676fi
24677{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_target_clang" >&5
24678$as_echo "$grub_cv_cc_target_clang" >&6; }
24679
24680if test x$target_cpu = xpowerpc -o x$target_cpu = xmips; then
24681 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for options to get big-endian compilation" >&5
24682$as_echo_n "checking for options to get big-endian compilation... " >&6; }
24683if ${grub_cv_target_cc_big_endian+:} false; then :
24684 $as_echo_n "(cached) " >&6
24685else
24686
24687 grub_cv_target_cc_big_endian=no
24688 for cand in "-target $target_cpu -Wl,-EB" "-target $target_cpu" \
24689 "-target $target_cpu-linux-gnu -Wl,-EB" "-target $target_cpu-linux-gnu" \
24690 "-EB" "-mbig-endian"; do
24691 if test x"$grub_cv_target_cc_big_endian" != xno ; then
24692 break
24693 fi
24694 CFLAGS="$TARGET_CFLAGS $cand -Werror"
24695 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24696/* end confdefs.h. */
24697
24698#if defined(__BYTE_ORDER__) && defined(__ORDER_BIG_ENDIAN__) && (__ORDER_BIG_ENDIAN__ != __BYTE_ORDER__)
24699#error still little endian
24700#endif
24701asm (".globl start; start:");
24702asm (".globl _start; _start:");
24703asm (".globl __start; __start:");
24704void __main (void);
24705void __main (void) {}
24706int main (void);
24707
24708int
24709main (void)
24710{
24711
24712 ;
24713 return 0;
24714}
24715_ACEOF
24716if ac_fn_c_try_link "$LINENO"; then :
24717 grub_cv_target_cc_big_endian="$cand"
24718fi
24719rm -f core conftest.err conftest.$ac_objext \
24720 conftest$ac_exeext conftest.$ac_ext
24721 done
24722
24723fi
24724{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_target_cc_big_endian" >&5
24725$as_echo "$grub_cv_target_cc_big_endian" >&6; }
24726
24727 if test x"$grub_cv_target_cc_big_endian" = xno ; then
24728 as_fn_error $? "could not force big-endian" "$LINENO" 5
24729 fi
24730
24731 skip_linkflags="$(echo "$grub_cv_target_cc_big_endian"|sed 's@-Wl,-EB@@')"
24732
24733 TARGET_CFLAGS="$TARGET_CFLAGS $skip_linkflags"
24734 TARGET_CPPFLAGS="$TARGET_CPPFLAGS $skip_linkflags"
24735 TARGET_CCASFLAGS="$TARGET_CCASFLAGS $skip_linkflags"
24736 TARGET_LDFLAGS="$TARGET_LDFLAGS $grub_cv_target_cc_big_endian"
24737elif test x$target_cpu = xmipsel; then
24738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for options to get little-endian compilation" >&5
24739$as_echo_n "checking for options to get little-endian compilation... " >&6; }
24740if ${grub_cv_target_cc_little_endian+:} false; then :
24741 $as_echo_n "(cached) " >&6
24742else
24743
24744 grub_cv_target_cc_little_endian=no
24745 for cand in "-target $target_cpu -Wl,-EL" "-target $target_cpu" \
24746 "-target $target_cpu-linux-gnu -Wl,-EL" "-target $target_cpu-linux-gnu" \
24747 "-EL"; do
24748 if test x"$grub_cv_target_cc_little_endian" != xno ; then
24749 break
24750 fi
24751 CFLAGS="$TARGET_CFLAGS $cand -Werror"
24752 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24753/* end confdefs.h. */
24754
24755#if defined(__BYTE_ORDER__) && defined(__ORDER_BIG_ENDIAN__) && (__ORDER_BIG_ENDIAN__ == __BYTE_ORDER__)
24756#error still big endian
24757#endif
24758asm (".globl start; start:");
24759asm (".globl _start; _start:");
24760asm (".globl __start; __start:");
24761void __main (void);
24762void __main (void) {}
24763int main (void);
24764
24765int
24766main (void)
24767{
24768
24769 ;
24770 return 0;
24771}
24772_ACEOF
24773if ac_fn_c_try_link "$LINENO"; then :
24774 grub_cv_target_cc_little_endian="$cand"
24775fi
24776rm -f core conftest.err conftest.$ac_objext \
24777 conftest$ac_exeext conftest.$ac_ext
24778 done
24779
24780fi
24781{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_target_cc_little_endian" >&5
24782$as_echo "$grub_cv_target_cc_little_endian" >&6; }
24783
24784 if test x"$grub_cv_target_cc_little_endian" = xno ; then
24785 as_fn_error $? "could not force little-endian" "$LINENO" 5
24786 fi
24787
24788 skip_linkflags="$(echo "$grub_cv_target_cc_little_endian"|sed 's@-Wl,-EL@@')"
24789
24790 TARGET_CFLAGS="$TARGET_CFLAGS $skip_linkflags"
24791 TARGET_CPPFLAGS="$TARGET_CPPFLAGS $skip_linkflags"
24792 TARGET_CCASFLAGS="$TARGET_CCASFLAGS $skip_linkflags"
24793 TARGET_LDFLAGS="$TARGET_LDFLAGS $grub_cv_target_cc_little_endian"
24794fi
24795
24796# GRUB code is N32-compliant but it's experimental and we would prefer to
24797# avoid having too much variety when it doesn't result in any real improvement.
24798# Moreover N64 isn't supported.
24799if test "x$target_cpu" = xmips || test "x$target_cpu" = xmipsel ; then
24800 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for options to force MIPS o32 ABI" >&5
24801$as_echo_n "checking for options to force MIPS o32 ABI... " >&6; }
24802if ${grub_cv_target_cc_mips_o32_abi+:} false; then :
24803 $as_echo_n "(cached) " >&6
24804else
24805
24806 grub_cv_target_cc_mips_o32_abi=no
24807 for arg in "" "-mabi=32" "-target $target_cpu -mabi=32" ; do
24808 if test x"$grub_cv_target_cc_mips_o32_abi" != xno ; then
24809 break
24810 fi
24811 CFLAGS="$TARGET_CFLAGS $arg -Werror"
24812 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24813/* end confdefs.h. */
24814
24815#if !defined(_ABIO32) || !defined(_MIPS_SIM) || (_MIPS_SIM != _ABIO32)
24816#error not o32 ABI
24817#endif
24818asm (".globl start; start:");
24819asm (".globl _start; _start:");
24820asm (".globl __start; __start:");
24821void __main (void);
24822void __main (void) {}
24823int main (void);
24824
24825int
24826main (void)
24827{
24828
24829 ;
24830 return 0;
24831}
24832_ACEOF
24833if ac_fn_c_try_link "$LINENO"; then :
24834 grub_cv_target_cc_mips_o32_abi="$arg"
24835fi
24836rm -f core conftest.err conftest.$ac_objext \
24837 conftest$ac_exeext conftest.$ac_ext
24838 done
24839
24840fi
24841{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_target_cc_mips_o32_abi" >&5
24842$as_echo "$grub_cv_target_cc_mips_o32_abi" >&6; }
24843
24844 if test x"$grub_cv_target_cc_mips_o32_abi" = xno ; then
24845 as_fn_error $? "could not force MIPS o32 ABI" "$LINENO" 5
24846 fi
24847
24848 TARGET_CFLAGS="$TARGET_CFLAGS $grub_cv_target_cc_mips_o32_abi"
24849 TARGET_CCASFLAGS="$TARGET_CCASFLAGS $grub_cv_target_cc_mips_o32_abi"
24850fi
24851
24852{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for options to compile assembly" >&5
24853$as_echo_n "checking for options to compile assembly... " >&6; }
24854if ${grub_cv_cc_target_asm_compile+:} false; then :
24855 $as_echo_n "(cached) " >&6
24856else
24857
24858test_program=
24859case "x$target_cpu-$platform" in
24860 xmips-* | xmipsel-*)
24861 test_program=mips
24862 ;;
24863 xi386-pc)
24864 test_program=i386-pc
24865 ;;
24866 xi386-* | xx86_64-*)
24867 test_program=i386
24868 ;;
24869 xpowerpc-* | xsparc64-* | xarm-*)
24870 test_program=$target_cpu
24871 ;;
24872esac
24873if test x"$test_program" = x ; then
24874 grub_cv_cc_target_asm_compile=
24875else
24876 found=no
24877 for arg in "" "-no-integrated-as"; do
24878 cmdline="$TARGET_CC -c -o /dev/null $TARGET_CCASFLAGS $arg $TARGET_CPPFLAGS $srcdir/asm-tests/$test_program.S"
24879 echo "Running $cmdline" >&5
24880 if $cmdline >&5 2>&5; then
24881 grub_cv_cc_target_asm_compile="$arg"
24882 found=yes
24883 break
24884 fi
24885 done
24886 if test x"$found" = xno ; then
24887 as_fn_error $? "could not compile assembly" "$LINENO" 5
24888 fi
24889fi
24890
24891fi
24892{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_target_asm_compile" >&5
24893$as_echo "$grub_cv_cc_target_asm_compile" >&6; }
24894
24895TARGET_CCASFLAGS="$TARGET_CCASFLAGS $grub_cv_cc_target_asm_compile"
24896
24897if test "x$target_cpu" = xi386 && test "x$platform" != xemu; then
24898 TARGET_CFLAGS="$TARGET_CFLAGS -march=i386"
24899fi
24900
24901if test "x$target_m32" = x1; then
24902 # Force 32-bit mode.
24903 TARGET_CFLAGS="$TARGET_CFLAGS -m32"
24904 TARGET_CCASFLAGS="$TARGET_CCASFLAGS -m32"
24905 TARGET_CPPFLAGS="$TARGET_CPPFLAGS -m32"
24906 TARGET_LDFLAGS="$TARGET_LDFLAGS -m32"
24907 TARGET_MODULE_FORMAT="elf32"
24908fi
24909
24910if test "x$target_m64" = x1; then
24911 # Force 64-bit mode.
24912 TARGET_CFLAGS="$TARGET_CFLAGS -m64"
24913 TARGET_CCASFLAGS="$TARGET_CCASFLAGS -m64"
24914 TARGET_CPPFLAGS="$TARGET_CPPFLAGS -m64"
24915 TARGET_LDFLAGS="$TARGET_LDFLAGS -m64"
24916 TARGET_MODULE_FORMAT="elf64"
24917fi
24918
24919if test "x$grub_cv_cc_target_clang" = xno && test "x$target_cpu" = xi386 && test "x$platform" != xemu && test "x$platform" != xefi; then
24920 TARGET_CFLAGS="$TARGET_CFLAGS -mrtd -mregparm=3"
24921fi
24922
24923# on mips redirect cache flushing function to non-existant one.
24924if test "x$target_cpu" = xmips || test "x$target_cpu" = xmipsel ; then
24925 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -mflush-func=grub_red_herring works" >&5
24926$as_echo_n "checking whether -mflush-func=grub_red_herring works... " >&6; }
24927if ${grub_cv_cc_mflush_func+:} false; then :
24928 $as_echo_n "(cached) " >&6
24929else
24930
24931 CFLAGS="$TARGET_CFLAGS -mflush-func=grub_red_herring -Werror"
24932 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24933/* end confdefs.h. */
24934
24935int
24936main (void)
24937{
24938
24939 ;
24940 return 0;
24941}
24942_ACEOF
24943if ac_fn_c_try_compile "$LINENO"; then :
24944 grub_cv_cc_mflush_func=yes
24945else
24946 grub_cv_cc_mflush_func=no
24947fi
24948rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24949
24950fi
24951{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_mflush_func" >&5
24952$as_echo "$grub_cv_cc_mflush_func" >&6; }
24953
24954 if test "x$grub_cv_cc_mflush_func" = xyes; then
24955 TARGET_CFLAGS="$TARGET_CFLAGS -mflush-func=grub_red_herring"
24956 fi
24957fi
24958
24959
24960# Force no alignment to save space on i386.
24961if test "x$target_cpu" = xi386; then
24962 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -falign-loops works" >&5
24963$as_echo_n "checking whether -falign-loops works... " >&6; }
24964if ${grub_cv_cc_falign_loop+:} false; then :
24965 $as_echo_n "(cached) " >&6
24966else
24967
24968 CFLAGS="$TARGET_CFLAGS -falign-loops=1 -Werror"
24969 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24970/* end confdefs.h. */
24971
24972int
24973main (void)
24974{
24975
24976 ;
24977 return 0;
24978}
24979_ACEOF
24980if ac_fn_c_try_compile "$LINENO"; then :
24981 grub_cv_cc_falign_loop=yes
24982else
24983 grub_cv_cc_falign_loop=no
24984fi
24985rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24986
24987fi
24988{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_falign_loop" >&5
24989$as_echo "$grub_cv_cc_falign_loop" >&6; }
24990
24991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -malign-loops works" >&5
24992$as_echo_n "checking whether -malign-loops works... " >&6; }
24993if ${grub_cv_cc_malign_loop+:} false; then :
24994 $as_echo_n "(cached) " >&6
24995else
24996
24997 CFLAGS="$TARGET_CFLAGS -malign-loops=1 -Werror"
24998 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24999/* end confdefs.h. */
25000
25001int
25002main (void)
25003{
25004
25005 ;
25006 return 0;
25007}
25008_ACEOF
25009if ac_fn_c_try_compile "$LINENO"; then :
25010 grub_cv_cc_malign_loop=yes
25011else
25012 grub_cv_cc_malign_loop=no
25013fi
25014rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25015
25016fi
25017{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_malign_loop" >&5
25018$as_echo "$grub_cv_cc_malign_loop" >&6; }
25019
25020 if test "x$grub_cv_cc_falign_loop" = xyes; then
25021 TARGET_CFLAGS="$TARGET_CFLAGS -falign-jumps=1 -falign-loops=1 -falign-functions=1"
25022 elif test "x$grub_cv_cc_malign_loop" = xyes; then
25023 TARGET_CFLAGS="$TARGET_CFLAGS -malign-jumps=1 -malign-loops=1 -malign-functions=1"
25024 fi
25025fi
25026
25027{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -freg-struct-return works" >&5
25028$as_echo_n "checking whether -freg-struct-return works... " >&6; }
25029if ${grub_cv_cc_freg_struct_return+:} false; then :
25030 $as_echo_n "(cached) " >&6
25031else
25032
25033 CFLAGS="$TARGET_CFLAGS -freg-struct-return -Werror"
25034 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25035/* end confdefs.h. */
25036
25037int
25038main (void)
25039{
25040
25041 ;
25042 return 0;
25043}
25044_ACEOF
25045if ac_fn_c_try_compile "$LINENO"; then :
25046 grub_cv_cc_freg_struct_return=yes
25047else
25048 grub_cv_cc_freg_struct_return=no
25049fi
25050rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25051
25052fi
25053{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_freg_struct_return" >&5
25054$as_echo "$grub_cv_cc_freg_struct_return" >&6; }
25055
25056if test "x$grub_cv_cc_freg_struct_return" = xyes; then
25057 TARGET_CFLAGS="$TARGET_CFLAGS -freg-struct-return"
25058fi
25059
25060if ( test "x$target_cpu" = xi386 || test "x$target_cpu" = xx86_64 ) && test "x$platform" != xemu; then
25061 # Some toolchains enable these features by default, but they need
25062 # registers that aren't set up properly in GRUB.
25063 TARGET_CFLAGS="$TARGET_CFLAGS -mno-mmx -mno-sse -mno-sse2 -mno-sse3 -mno-3dnow"
25064fi
25065
25066# GRUB doesn't use float or doubles at all. Yet some toolchains may decide
25067# that floats are a good fit to run instead of what's written in the code.
25068# Given that floating point unit is disabled (if present to begin with)
25069# when GRUB is running which may result in various hard crashes.
25070if test x"$platform" != xemu ; then
25071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for options to get soft-float" >&5
25072$as_echo_n "checking for options to get soft-float... " >&6; }
25073if ${grub_cv_target_cc_soft_float+:} false; then :
25074 $as_echo_n "(cached) " >&6
25075else
25076
25077 grub_cv_target_cc_soft_float=no
25078 if test "x$target_cpu" = xarm64; then
25079 CFLAGS="$TARGET_CFLAGS -mgeneral-regs-only -Werror"
25080 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25081/* end confdefs.h. */
25082
25083int
25084main (void)
25085{
25086
25087 ;
25088 return 0;
25089}
25090_ACEOF
25091if ac_fn_c_try_compile "$LINENO"; then :
25092 grub_cv_target_cc_soft_float="-mgeneral-regs-only"
25093fi
25094rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25095 fi
25096 if test "x$target_cpu" = xia64; then
25097 CFLAGS="$TARGET_CFLAGS -mno-inline-float-divide -mno-inline-sqrt -Werror"
25098 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25099/* end confdefs.h. */
25100
25101int
25102main (void)
25103{
25104
25105 ;
25106 return 0;
25107}
25108_ACEOF
25109if ac_fn_c_try_compile "$LINENO"; then :
25110 grub_cv_target_cc_soft_float="-mno-inline-float-divide -mno-inline-sqrt"
25111fi
25112rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25113 fi
25114 for cand in "-msoft-float -Xclang -msoft-float -Xclang -no-implicit-float" \
25115 "-Xclang -msoft-float -Xclang -no-implicit-float" \
25116 "-Xclang -msoft-float" "-msoft-float"; do
25117 if test x"$grub_cv_target_cc_soft_float" != xno ; then
25118 break
25119 fi
25120 CFLAGS="$TARGET_CFLAGS $cand -Werror"
25121 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25122/* end confdefs.h. */
25123
25124int
25125main (void)
25126{
25127
25128 ;
25129 return 0;
25130}
25131_ACEOF
25132if ac_fn_c_try_compile "$LINENO"; then :
25133 grub_cv_target_cc_soft_float="$cand"
25134fi
25135rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25136 done
25137
25138fi
25139{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_target_cc_soft_float" >&5
25140$as_echo "$grub_cv_target_cc_soft_float" >&6; }
25141
25142 if test x"$grub_cv_target_cc_soft_float" = xno ; then
25143 as_fn_error $? "could not force soft-float" "$LINENO" 5
25144 fi
25145
25146 case x"$grub_cv_target_cc_soft_float" in
25147 x*"-Xclang"*)
25148 # A trick so that clang doesn't see it on link stаge
25149 TARGET_CPPFLAGS="$TARGET_CPPFLAGS $grub_cv_target_cc_soft_float"
25150 ;;
25151 *)
25152 TARGET_CFLAGS="$TARGET_CFLAGS $grub_cv_target_cc_soft_float"
25153 ;;
25154 esac
25155 TARGET_CCASFLAGS="$TARGET_CCASFLAGS $grub_cv_target_cc_soft_float"
25156
25157fi
25158
25159if test x"$target_cpu" = xsparc64 ; then
25160 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for options to reserve application registers" >&5
25161$as_echo_n "checking for options to reserve application registers... " >&6; }
25162if ${grub_cv_target_cc_mno_app_regs+:} false; then :
25163 $as_echo_n "(cached) " >&6
25164else
25165
25166 grub_cv_target_cc_mno_app_regs=no
25167 for cand in "-mllvm -sparc-reserve-app-registers" \
25168 "-mno-app-regs"; do
25169 if test x"$grub_cv_target_cc_mno_app_regs" != xno ; then
25170 break
25171 fi
25172 CFLAGS="$TARGET_CFLAGS $cand -Werror"
25173 CPPFLAGS="$TARGET_CPPFLAGS"
25174 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25175/* end confdefs.h. */
25176
25177int
25178main (void)
25179{
25180
25181 ;
25182 return 0;
25183}
25184_ACEOF
25185if ac_fn_c_try_compile "$LINENO"; then :
25186 grub_cv_target_cc_mno_app_regs="$cand"
25187fi
25188rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25189 done
25190
25191fi
25192{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_target_cc_mno_app_regs" >&5
25193$as_echo "$grub_cv_target_cc_mno_app_regs" >&6; }
25194
25195 if test x"$grub_cv_target_cc_mno_app_regs" = xno ; then
25196 as_fn_error $? "could not reserve application registers" "$LINENO" 5
25197 fi
25198 if test x"$grub_cv_target_cc_mno_app_regs" = x"-mllvm -sparc-reserve-app-registers" ; then
25199 # A trick so that clang doesn't see it on link stаge
25200 TARGET_CPPFLAGS="$TARGET_CPPFLAGS $grub_cv_target_cc_mno_app_regs"
25201 else
25202 TARGET_CFLAGS="$TARGET_CFLAGS $grub_cv_target_cc_mno_app_regs"
25203 fi
25204
25205 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for no-relax options" >&5
25206$as_echo_n "checking for no-relax options... " >&6; }
25207if ${grub_cv_target_cc_mno_relax+:} false; then :
25208 $as_echo_n "(cached) " >&6
25209else
25210
25211 grub_cv_target_cc_mno_relax=no
25212 for cand in "-mno-relax" "-Wl,--no-relax"; do
25213 if test x"$grub_cv_target_cc_mno_relax" != xno ; then
25214 break
25215 fi
25216 LDFLAGS="$TARGET_LDFLAGS $cand -nostdlib -static"
25217 CFLAGS="$TARGET_CFLAGS -Werror"
25218 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25219/* end confdefs.h. */
25220
25221 asm (".globl start; start:");
25222 void __main (void);
25223 void __main (void) {}
25224 int main (void);
25225
25226int
25227main (void)
25228{
25229
25230 ;
25231 return 0;
25232}
25233_ACEOF
25234if ac_fn_c_try_link "$LINENO"; then :
25235 grub_cv_target_cc_mno_relax="$cand"
25236fi
25237rm -f core conftest.err conftest.$ac_objext \
25238 conftest$ac_exeext conftest.$ac_ext
25239 done
25240
25241fi
25242{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_target_cc_mno_relax" >&5
25243$as_echo "$grub_cv_target_cc_mno_relax" >&6; }
25244 LDFLAGS="$TARGET_LDFLAGS"
25245 CFLAGS="$TARGET_CFLAGS"
25246
25247 if test x"$grub_cv_target_cc_mno_relax" = xno ; then
25248 as_fn_error $? "could not find no-relax options" "$LINENO" 5
25249 fi
25250 TARGET_LDFLAGS="$TARGET_LDFLAGS $grub_cv_target_cc_mno_relax"
25251fi
25252
25253# By default, GCC 4.4 generates .eh_frame sections containing unwind
25254# information in some cases where it previously did not. GRUB doesn't need
25255# these and they just use up vital space. Restore the old compiler
25256# behaviour.
25257{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -fno-dwarf2-cfi-asm works" >&5
25258$as_echo_n "checking whether -fno-dwarf2-cfi-asm works... " >&6; }
25259if ${grub_cv_cc_fno_dwarf2_cfi_asm+:} false; then :
25260 $as_echo_n "(cached) " >&6
25261else
25262
25263 CFLAGS="$TARGET_CFLAGS -fno-dwarf2-cfi-asm"
25264 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25265/* end confdefs.h. */
25266
25267int
25268main (void)
25269{
25270
25271 ;
25272 return 0;
25273}
25274_ACEOF
25275if ac_fn_c_try_compile "$LINENO"; then :
25276 grub_cv_cc_fno_dwarf2_cfi_asm=yes
25277else
25278 grub_cv_cc_fno_dwarf2_cfi_asm=no
25279fi
25280rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25281
25282fi
25283{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_fno_dwarf2_cfi_asm" >&5
25284$as_echo "$grub_cv_cc_fno_dwarf2_cfi_asm" >&6; }
25285
25286if test "x$grub_cv_cc_fno_dwarf2_cfi_asm" = xyes; then
25287 TARGET_CFLAGS="$TARGET_CFLAGS -fno-dwarf2-cfi-asm"
25288fi
25289
25290if test x"$target_os" = xcygwin; then
25291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether option -fno-reorder-functions works" >&5
25292$as_echo_n "checking whether option -fno-reorder-functions works... " >&6; }
25293if ${grub_cv_cc_no_reorder_functions+:} false; then :
25294 $as_echo_n "(cached) " >&6
25295else
25296
25297 CFLAGS="$TARGET_CFLAGS -fno-reorder-functions"
25298 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25299/* end confdefs.h. */
25300
25301int
25302main (void)
25303{
25304
25305 ;
25306 return 0;
25307}
25308_ACEOF
25309if ac_fn_c_try_compile "$LINENO"; then :
25310 grub_cv_cc_no_reorder_functions=yes
25311else
25312 grub_cv_cc_no_reorder_functions=no
25313fi
25314rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25315
25316fi
25317{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_no_reorder_functions" >&5
25318$as_echo "$grub_cv_cc_no_reorder_functions" >&6; }
25319fi
25320
25321if test x"$target_os" = xcygwin && test "x$grub_cv_cc_no_reorder_functions" = xyes; then
25322 TARGET_CFLAGS="$TARGET_CFLAGS -fno-reorder-functions"
25323fi
25324
25325{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -mno-stack-arg-probe works" >&5
25326$as_echo_n "checking whether -mno-stack-arg-probe works... " >&6; }
25327if ${grub_cv_cc_mno_stack_arg_probe+:} false; then :
25328 $as_echo_n "(cached) " >&6
25329else
25330
25331 CFLAGS="$TARGET_CFLAGS -mno-stack-arg-probe"
25332 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25333/* end confdefs.h. */
25334
25335int
25336main (void)
25337{
25338
25339 ;
25340 return 0;
25341}
25342_ACEOF
25343if ac_fn_c_try_compile "$LINENO"; then :
25344 grub_cv_cc_mno_stack_arg_probe=yes
25345else
25346 grub_cv_cc_mno_stack_arg_probe=no
25347fi
25348rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25349
25350fi
25351{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_mno_stack_arg_probe" >&5
25352$as_echo "$grub_cv_cc_mno_stack_arg_probe" >&6; }
25353
25354if test "x$grub_cv_cc_mno_stack_arg_probe" = xyes; then
25355 TARGET_CFLAGS="$TARGET_CFLAGS -mno-stack-arg-probe"
25356fi
25357
25358
25359# By default, GCC 4.6 generates .eh_frame sections containing unwind
25360# information in some cases where it previously did not. GRUB doesn't need
25361# these and they just use up vital space. Restore the old compiler
25362# behaviour.
25363{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -fno-asynchronous-unwind-tables works" >&5
25364$as_echo_n "checking whether -fno-asynchronous-unwind-tables works... " >&6; }
25365if ${grub_cv_cc_fno_asynchronous_unwind_tables+:} false; then :
25366 $as_echo_n "(cached) " >&6
25367else
25368
25369 CFLAGS="$TARGET_CFLAGS -fno-asynchronous-unwind-tables"
25370 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25371/* end confdefs.h. */
25372
25373int
25374main (void)
25375{
25376
25377 ;
25378 return 0;
25379}
25380_ACEOF
25381if ac_fn_c_try_compile "$LINENO"; then :
25382 grub_cv_cc_fno_asynchronous_unwind_tables=yes
25383else
25384 grub_cv_cc_fno_asynchronous_unwind_tables=no
25385fi
25386rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25387
25388fi
25389{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_fno_asynchronous_unwind_tables" >&5
25390$as_echo "$grub_cv_cc_fno_asynchronous_unwind_tables" >&6; }
25391
25392if test "x$grub_cv_cc_fno_asynchronous_unwind_tables" = xyes; then
25393 TARGET_CFLAGS="$TARGET_CFLAGS -fno-asynchronous-unwind-tables"
25394fi
25395
25396{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -fno-unwind-tables works" >&5
25397$as_echo_n "checking whether -fno-unwind-tables works... " >&6; }
25398if ${grub_cv_cc_fno_unwind_tables+:} false; then :
25399 $as_echo_n "(cached) " >&6
25400else
25401
25402 CFLAGS="$TARGET_CFLAGS -fno-unwind-tables"
25403 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25404/* end confdefs.h. */
25405
25406int
25407main (void)
25408{
25409
25410 ;
25411 return 0;
25412}
25413_ACEOF
25414if ac_fn_c_try_compile "$LINENO"; then :
25415 grub_cv_cc_fno_unwind_tables=yes
25416else
25417 grub_cv_cc_fno_unwind_tables=no
25418fi
25419rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25420
25421fi
25422{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_fno_unwind_tables" >&5
25423$as_echo "$grub_cv_cc_fno_unwind_tables" >&6; }
25424
25425if test "x$grub_cv_cc_fno_unwind_tables" = xyes; then
25426 TARGET_CFLAGS="$TARGET_CFLAGS -fno-unwind-tables"
25427fi
25428
25429
25430CFLAGS="$TARGET_CFLAGS"
25431
25432
25433if test x"$platform" = xemu ; then
25434 TARGET_OBJ2ELF=
25435 grub_cv_target_cc_link_format=
25436 case "$host_os" in
25437 *darwin* | *mac*)
25438 grub_cv_target_cc_link_format="-arch,${target_cpu}"
25439 TARGET_LDFLAGS="$TARGET_LDFLAGS -Wl,$grub_cv_target_cc_link_format"
25440 ;;
25441 *windows* | *cygwin* | *mingw*)
25442 if test x${target_cpu} = xi386 ; then
25443 grub_cv_target_cc_link_format=-mi386pe
25444 TARGET_OBJ2ELF='./build-grub-pe2elf$(BUILD_EXEEXT)'
25445 fi
25446 if test x${target_cpu} = xx86_64 ; then
25447 grub_cv_target_cc_link_format=-mi386pep
25448 TARGET_OBJ2ELF='./build-grub-pep2elf$(BUILD_EXEEXT)'
25449 fi
25450 TARGET_LDFLAGS="$TARGET_LDFLAGS -Wl,$grub_cv_target_cc_link_format"
25451 ;;
25452 esac
25453elif test x"$target_cpu" = xi386 || test x"$target_cpu" = xx86_64; then
25454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for target linking format" >&5
25455$as_echo_n "checking for target linking format... " >&6; }
25456if ${grub_cv_target_cc_link_format+:} false; then :
25457 $as_echo_n "(cached) " >&6
25458else
25459
25460 grub_cv_target_cc_link_format=unknown
25461 for format in -melf_${target_cpu} -melf_${target_cpu}_fbsd -melf_${target_cpu}_obsd -melf_${target_cpu}_haiku -mi386pe -mi386pep -arch,${target_cpu}; do
25462 if test x${target_cpu} != xi386 && test x$format = x-mi386pe; then
25463 continue
25464 fi
25465 if test x${target_cpu} != xx86_64 && test x$format = x-mi386pep; then
25466 continue
25467 fi
25468 CFLAGS="$TARGET_CFLAGS"
25469 LDFLAGS="$TARGET_LDFLAGS -Wl,$format -nostdlib -static"
25470 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25471/* end confdefs.h. */
25472
25473 asm (".globl start; start:");
25474 asm (".globl _start; _start:");
25475 asm (".globl __start; __start:");
25476 void __main (void);
25477 void __main (void) {}
25478
25479int
25480main (void)
25481{
25482
25483 ;
25484 return 0;
25485}
25486_ACEOF
25487if ac_fn_c_try_link "$LINENO"; then :
25488 flag=1
25489else
25490 flag=0
25491fi
25492rm -f core conftest.err conftest.$ac_objext \
25493 conftest$ac_exeext conftest.$ac_ext
25494 if test x"$flag" = x1; then
25495 grub_cv_target_cc_link_format="$format"
25496 break
25497 fi
25498 done
25499fi
25500{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_target_cc_link_format" >&5
25501$as_echo "$grub_cv_target_cc_link_format" >&6; }
25502 if test x"$grub_cv_target_cc_link_format" = xunknown; then
25503 as_fn_error $? "no suitable link format found" "$LINENO" 5
25504 fi
25505 TARGET_LDFLAGS="$TARGET_LDFLAGS -Wl,$grub_cv_target_cc_link_format"
25506 if test x"$grub_cv_target_cc_link_format" = x-mi386pe ; then
25507 TARGET_OBJ2ELF='./build-grub-pe2elf$(BUILD_EXEEXT)'
25508 fi
25509 if test x"$grub_cv_target_cc_link_format" = x-mi386pep ; then
25510 TARGET_OBJ2ELF='./build-grub-pep2elf$(BUILD_EXEEXT)'
25511 fi
25512fi
25513
25514if test x$grub_cv_target_cc_link_format = x-arch,i386 || test x$grub_cv_target_cc_link_format = x-arch,x86_64; then
25515 TARGET_APPLE_LINKER=1
25516 # Extract the first word of "objconv", so it can be a program name with args.
25517set dummy objconv; ac_word=$2
25518{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25519$as_echo_n "checking for $ac_word... " >&6; }
25520if ${ac_cv_prog_TARGET_OBJCONV+:} false; then :
25521 $as_echo_n "(cached) " >&6
25522else
25523 if test -n "$TARGET_OBJCONV"; then
25524 ac_cv_prog_TARGET_OBJCONV="$TARGET_OBJCONV" # Let the user override the test.
25525else
25526as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25527for as_dir in $PATH
25528do
25529 IFS=$as_save_IFS
25530 test -z "$as_dir" && as_dir=.
25531 for ac_exec_ext in '' $ac_executable_extensions; do
25532 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25533 ac_cv_prog_TARGET_OBJCONV="objconv"
25534 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25535 break 2
25536 fi
25537done
25538 done
25539IFS=$as_save_IFS
25540
25541fi
25542fi
25543TARGET_OBJCONV=$ac_cv_prog_TARGET_OBJCONV
25544if test -n "$TARGET_OBJCONV"; then
25545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TARGET_OBJCONV" >&5
25546$as_echo "$TARGET_OBJCONV" >&6; }
25547else
25548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25549$as_echo "no" >&6; }
25550fi
25551
25552
25553 if test "x$TARGET_OBJCONV" = x ; then
25554 # Extract the first word of "objconv", so it can be a program name with args.
25555set dummy objconv; ac_word=$2
25556{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25557$as_echo_n "checking for $ac_word... " >&6; }
25558if ${ac_cv_prog_TARGET_OBJCONV+:} false; then :
25559 $as_echo_n "(cached) " >&6
25560else
25561 if test -n "$TARGET_OBJCONV"; then
25562 ac_cv_prog_TARGET_OBJCONV="$TARGET_OBJCONV" # Let the user override the test.
25563else
25564as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25565for as_dir in .
25566do
25567 IFS=$as_save_IFS
25568 test -z "$as_dir" && as_dir=.
25569 for ac_exec_ext in '' $ac_executable_extensions; do
25570 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25571 ac_cv_prog_TARGET_OBJCONV="./objconv"
25572 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25573 break 2
25574 fi
25575done
25576 done
25577IFS=$as_save_IFS
25578
25579fi
25580fi
25581TARGET_OBJCONV=$ac_cv_prog_TARGET_OBJCONV
25582if test -n "$TARGET_OBJCONV"; then
25583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TARGET_OBJCONV" >&5
25584$as_echo "$TARGET_OBJCONV" >&6; }
25585else
25586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25587$as_echo "no" >&6; }
25588fi
25589
25590
25591 fi
25592 if test "x$TARGET_OBJCONV" = x ; then
25593 as_fn_error $? "objconv not found which is required when building with apple compiler" "$LINENO" 5
25594 fi
25595 TARGET_IMG_LDSCRIPT=
25596 TARGET_IMG_CFLAGS="-static"
25597 TARGET_IMG_LDFLAGS='-nostdlib -static -Wl,-preload -Wl,-segalign,20'
25598 TARGET_IMG_LDFLAGS_AC='-nostdlib -static -Wl,-preload -Wl,-segalign,20'
25599 TARGET_IMG_BASE_LDOPT="-Wl,-image_base"
25600 TARGET_LDFLAGS_OLDMAGIC=""
25601elif test x$grub_cv_target_cc_link_format = x-mi386pe || test x$grub_cv_target_cc_link_format = x-mi386pep ; then
25602 TARGET_APPLE_LINKER=0
25603 TARGET_LDFLAGS_OLDMAGIC="-Wl,-N"
25604 TARGET_IMG_LDSCRIPT='$(top_srcdir)'"/${grub_coredir}/conf/i386-cygwin-img-ld.sc"
25605 TARGET_IMG_LDFLAGS="-Wl,-T${TARGET_IMG_LDSCRIPT}"
25606 TARGET_IMG_LDFLAGS_AC="-Wl,-T${srcdir}/${grub_coredir}/conf/i386-cygwin-img-ld.sc"
25607 TARGET_IMG_BASE_LDOPT="-Wl,-Ttext"
25608 TARGET_IMG_CFLAGS=
25609else
25610 TARGET_APPLE_LINKER=0
25611 TARGET_LDFLAGS_OLDMAGIC="-Wl,-N"
25612 TARGET_IMG_LDSCRIPT=
25613 TARGET_IMG_LDFLAGS='-Wl,-N'
25614 TARGET_IMG_LDFLAGS_AC='-Wl,-N'
25615 TARGET_IMG_BASE_LDOPT="-Wl,-Ttext"
25616 TARGET_IMG_CFLAGS=
25617fi
25618
25619CFLAGS="$TARGET_CFLAGS"
25620
25621# Check whether --enable-efiemu was given.
25622if test "${enable_efiemu+set}" = set; then :
25623 enableval=$enable_efiemu;
25624fi
25625
25626if test x"$enable_efiemu" = xno ; then
25627 efiemu_excuse="explicitly disabled"
25628fi
25629
25630if test x"$grub_cv_target_cc_link_format" = x-mi386pe || test x"$grub_cv_target_cc_link_format" = x-mi386pep ; then
25631 efiemu_excuse="not available on cygwin"
25632fi
25633if test x"$target_cpu" != xi386 ; then
25634 efiemu_excuse="only available on i386"
25635fi
25636if test x"$platform" = xefi ; then
25637 efiemu_excuse="not available on efi"
25638fi
25639
25640if test x"$efiemu_excuse" = x ; then
25641 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether options required for efiemu work" >&5
25642$as_echo_n "checking whether options required for efiemu work... " >&6; }
25643if ${grub_cv_cc_efiemu+:} false; then :
25644 $as_echo_n "(cached) " >&6
25645else
25646
25647 CFLAGS="-m64 -nostdlib -O2 -mcmodel=large -mno-red-zone"
25648 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25649/* end confdefs.h. */
25650
25651int
25652main (void)
25653{
25654
25655 ;
25656 return 0;
25657}
25658_ACEOF
25659if ac_fn_c_try_compile "$LINENO"; then :
25660 grub_cv_cc_efiemu=yes
25661else
25662 grub_cv_cc_efiemu=no
25663fi
25664rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25665
25666fi
25667{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_efiemu" >&5
25668$as_echo "$grub_cv_cc_efiemu" >&6; }
25669 if test x$grub_cv_cc_efiemu = xno; then
25670 efiemu_excuse="cannot compile with -m64 -mcmodel=large -mno-red-zone -nostdlib"
25671 fi
25672fi
25673if test x"$efiemu_excuse" = x ; then
25674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for efiemu64 linking format" >&5
25675$as_echo_n "checking for efiemu64 linking format... " >&6; }
25676if ${grub_cv_target_cc_efiemu64_link_format+:} false; then :
25677 $as_echo_n "(cached) " >&6
25678else
25679
25680 grub_cv_target_cc_efiemu64_link_format=unknown
25681 for format in -melf_x86_64 -melf_x86_64_fbsd -melf_x86_64_obsd -melf_x86_64_haiku -arch,x86_64; do
25682 CFLAGS="-m64 -nostdlib -O2 -mcmodel=large -mno-red-zone"
25683 LDFLAGS="-m64 -Wl,$format -nostdlib -static"
25684 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25685/* end confdefs.h. */
25686
25687 asm (".globl start; start:");
25688 asm (".globl _start; _start:");
25689 asm (".globl __start; __start:");
25690 void __main (void);
25691 void __main (void) {}
25692
25693int
25694main (void)
25695{
25696
25697 ;
25698 return 0;
25699}
25700_ACEOF
25701if ac_fn_c_try_link "$LINENO"; then :
25702 flag=1
25703else
25704 flag=0
25705fi
25706rm -f core conftest.err conftest.$ac_objext \
25707 conftest$ac_exeext conftest.$ac_ext
25708 if test x"$flag" = x1; then
25709 grub_cv_target_cc_efiemu64_link_format="$format"
25710 break
25711 fi
25712 done
25713fi
25714{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_target_cc_efiemu64_link_format" >&5
25715$as_echo "$grub_cv_target_cc_efiemu64_link_format" >&6; }
25716 if test x"$grub_cv_target_cc_efiemu64_link_format" = xunknown; then
25717 efiemu_excuse="no suitable link format for efiemu64 found"
25718 else
25719 EFIEMU64_LINK_FORMAT="-Wl,$grub_cv_target_cc_efiemu64_link_format"
25720 fi
25721fi
25722if test x"$enable_efiemu" = xyes && test x"$efiemu_excuse" != x ; then
25723 as_fn_error $? "efiemu runtime was explicitly requested but can't be compiled ($efiemu_excuse)" "$LINENO" 5
25724fi
25725if test x"$efiemu_excuse" = x ; then
25726enable_efiemu=yes
25727else
25728enable_efiemu=no
25729fi
25730
25731
25732
25733CFLAGS="$TARGET_CFLAGS"
25734
25735
25736
25737
25738LDFLAGS="$TARGET_LDFLAGS"
25739
25740if test "$target_cpu" = x86_64 || test "$target_cpu" = sparc64 ; then
25741 # Use large model to support 4G memory
25742 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether option -mcmodel=large works" >&5
25743$as_echo_n "checking whether option -mcmodel=large works... " >&6; }
25744if ${grub_cv_cc_mcmodel+:} false; then :
25745 $as_echo_n "(cached) " >&6
25746else
25747
25748 CFLAGS="$TARGET_CFLAGS -mcmodel=large"
25749 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25750/* end confdefs.h. */
25751
25752int
25753main (void)
25754{
25755
25756 ;
25757 return 0;
25758}
25759_ACEOF
25760if ac_fn_c_try_compile "$LINENO"; then :
25761 grub_cv_cc_mcmodel=yes
25762else
25763 grub_cv_cc_mcmodel=no
25764fi
25765rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25766
25767fi
25768{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_mcmodel" >&5
25769$as_echo "$grub_cv_cc_mcmodel" >&6; }
25770 if test "x$grub_cv_cc_mcmodel" = xyes; then
25771 TARGET_CFLAGS="$TARGET_CFLAGS -mcmodel=large"
25772 elif test "$target_cpu" = sparc64; then
25773 TARGET_CFLAGS="$TARGET_CFLAGS -mcmodel=medany"
25774 fi
25775fi
25776
25777if test "$target_cpu"-"$platform" = x86_64-efi; then
25778 # EFI writes to stack below %rsp, we must not use the red zone
25779 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether option -mno-red-zone works" >&5
25780$as_echo_n "checking whether option -mno-red-zone works... " >&6; }
25781if ${grub_cv_cc_no_red_zone+:} false; then :
25782 $as_echo_n "(cached) " >&6
25783else
25784
25785 CFLAGS="$TARGET_CFLAGS -mno-red-zone"
25786 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25787/* end confdefs.h. */
25788
25789int
25790main (void)
25791{
25792
25793 ;
25794 return 0;
25795}
25796_ACEOF
25797if ac_fn_c_try_compile "$LINENO"; then :
25798 grub_cv_cc_no_red_zone=yes
25799else
25800 grub_cv_cc_no_red_zone=no
25801fi
25802rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25803
25804fi
25805{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_no_red_zone" >&5
25806$as_echo "$grub_cv_cc_no_red_zone" >&6; }
25807 if test "x$grub_cv_cc_no_red_zone" = xno; then
25808 as_fn_error $? "-mno-red-zone not supported, upgrade your gcc" "$LINENO" 5
25809 fi
25810
25811 TARGET_CFLAGS="$TARGET_CFLAGS -mno-red-zone"
25812fi
25813
25814if test "x$target_cpu" = xarm; then
25815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for options to disable movt and movw" >&5
25816$as_echo_n "checking for options to disable movt and movw... " >&6; }
25817if ${grub_cv_target_cc_mno_movt+:} false; then :
25818 $as_echo_n "(cached) " >&6
25819else
25820
25821 grub_cv_target_cc_mno_movt=no
25822 for cand in "-mno-movt" \
25823 "-mllvm -arm-use-movt=0"; do
25824 if test x"$grub_cv_target_cc_mno_movt" != xno ; then
25825 break
25826 fi
25827 CFLAGS="$TARGET_CFLAGS $cand -Werror"
25828 CPPFLAGS="$TARGET_CPPFLAGS"
25829 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25830/* end confdefs.h. */
25831
25832int
25833main (void)
25834{
25835
25836 ;
25837 return 0;
25838}
25839_ACEOF
25840if ac_fn_c_try_compile "$LINENO"; then :
25841 grub_cv_target_cc_mno_movt="$cand"
25842fi
25843rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25844 done
25845
25846fi
25847{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_target_cc_mno_movt" >&5
25848$as_echo "$grub_cv_target_cc_mno_movt" >&6; }
25849
25850 if test x"$grub_cv_target_cc_mno_movt" != xno ; then
25851 # A trick so that clang doesn't see it on link stage
25852 TARGET_CPPFLAGS="$TARGET_CPPFLAGS $grub_cv_target_cc_mno_movt"
25853 fi
25854 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether option -mthumb-interwork works" >&5
25855$as_echo_n "checking whether option -mthumb-interwork works... " >&6; }
25856if ${grub_cv_cc_mthumb_interwork+:} false; then :
25857 $as_echo_n "(cached) " >&6
25858else
25859
25860 CFLAGS="$TARGET_CFLAGS -mthumb-interwork -Werror"
25861 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25862/* end confdefs.h. */
25863
25864int
25865main (void)
25866{
25867
25868 ;
25869 return 0;
25870}
25871_ACEOF
25872if ac_fn_c_try_compile "$LINENO"; then :
25873 grub_cv_cc_mthumb_interwork=yes
25874else
25875 grub_cv_cc_mthumb_interwork=no
25876fi
25877rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25878
25879fi
25880{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_mthumb_interwork" >&5
25881$as_echo "$grub_cv_cc_mthumb_interwork" >&6; }
25882 if test "x$grub_cv_cc_mthumb_interwork" = xyes; then
25883 TARGET_CFLAGS="$TARGET_CFLAGS -mthumb-interwork"
25884 # Clang defaults to thumb interworking
25885 elif test "x$grub_cv_cc_target_clang" = xno ; then
25886 as_fn_error $? "your compiler doesn't support -mthumb-interwork" "$LINENO" 5
25887 fi
25888fi
25889
25890{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether option -Qn works" >&5
25891$as_echo_n "checking whether option -Qn works... " >&6; }
25892if ${grub_cv_target_cc_qn+:} false; then :
25893 $as_echo_n "(cached) " >&6
25894else
25895
25896 CFLAGS="$TARGET_CFLAGS -Qn -Werror"
25897 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25898/* end confdefs.h. */
25899
25900int
25901main (void)
25902{
25903
25904 ;
25905 return 0;
25906}
25907_ACEOF
25908if ac_fn_c_try_compile "$LINENO"; then :
25909 grub_cv_target_cc_qn=yes
25910else
25911 grub_cv_target_cc_qn=no
25912fi
25913rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25914fi
25915{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_target_cc_qn" >&5
25916$as_echo "$grub_cv_target_cc_qn" >&6; }
25917if test "x$grub_cv_target_cc_qn" = xyes; then
25918 TARGET_CFLAGS="$TARGET_CFLAGS -Qn"
25919fi
25920
25921#
25922# Compiler features.
25923#
25924
25925CFLAGS="$TARGET_CFLAGS"
25926
25927# Position independent executable.
25928
25929# Position independent executable.
25930pie_possible=yes
25931{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`$CC' has \`-fPIE' as default" >&5
25932$as_echo_n "checking whether \`$CC' has \`-fPIE' as default... " >&6; }
25933# Is this a reliable test case?
25934cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25935/* end confdefs.h. */
25936
25937#ifdef __PIE__
25938int main() {
25939 return 0;
25940}
25941#else
25942#error NO __PIE__ DEFINED
25943#endif
25944
25945_ACEOF
25946
25947# `$CC -c -o ...' might not be portable. But, oh, well... Is calling
25948# `ac_compile' like this correct, after all?
25949if eval "$ac_compile -S -o conftest.s" 2> /dev/null; then
25950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
25951$as_echo "yes" >&6; }
25952 # Should we clear up other files as well, having called `AC_LANG_CONFTEST'?
25953 rm -f conftest.s
25954else
25955 pie_possible=no
25956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25957$as_echo "no" >&6; }
25958fi
25959
25960{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether linker accepts -no-pie" >&5
25961$as_echo_n "checking whether linker accepts -no-pie... " >&6; }
25962if ${grub_cv_cc_ld_no_pie+:} false; then :
25963 $as_echo_n "(cached) " >&6
25964else
25965 save_LDFLAGS="$LDFLAGS"
25966LDFLAGS="$LDFLAGS -no-pie -nostdlib -Werror"
25967cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25968/* end confdefs.h. */
25969
25970int
25971main (void)
25972{
25973
25974 ;
25975 return 0;
25976}
25977_ACEOF
25978if ac_fn_c_try_link "$LINENO"; then :
25979 grub_cv_cc_ld_no_pie=yes
25980else
25981 grub_cv_cc_ld_no_pie=no
25982fi
25983rm -f core conftest.err conftest.$ac_objext \
25984 conftest$ac_exeext conftest.$ac_ext
25985LDFLAGS="$save_LDFLAGS"
25986
25987fi
25988
25989{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_ld_no_pie" >&5
25990$as_echo "$grub_cv_cc_ld_no_pie" >&6; }
25991nopie_possible=no
25992if test "x$grub_cv_cc_ld_no_pie" = xyes ; then
25993 nopie_possible=yes
25994fi
25995
25996{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether linker accepts -nopie" >&5
25997$as_echo_n "checking whether linker accepts -nopie... " >&6; }
25998if ${grub_cv_cc_ld_no_pie_oneword+:} false; then :
25999 $as_echo_n "(cached) " >&6
26000else
26001 save_LDFLAGS="$LDFLAGS"
26002LDFLAGS="$LDFLAGS -nopie -nostdlib -Werror"
26003cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26004/* end confdefs.h. */
26005
26006int
26007main (void)
26008{
26009
26010 ;
26011 return 0;
26012}
26013_ACEOF
26014if ac_fn_c_try_link "$LINENO"; then :
26015 grub_cv_cc_ld_no_pie_oneword=yes
26016else
26017 grub_cv_cc_ld_no_pie_oneword=no
26018fi
26019rm -f core conftest.err conftest.$ac_objext \
26020 conftest$ac_exeext conftest.$ac_ext
26021LDFLAGS="$save_LDFLAGS"
26022
26023fi
26024
26025{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_ld_no_pie_oneword" >&5
26026$as_echo "$grub_cv_cc_ld_no_pie_oneword" >&6; }
26027nopie_oneword_possible=no
26028if test "x$grub_cv_cc_ld_no_pie_oneword" = xyes ; then
26029 nopie_oneword_possible=yes
26030fi
26031
26032
26033# Position independent executable.
26034link_nopie_needed=no
26035{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether linker needs disabling of PIE to work" >&5
26036$as_echo_n "checking whether linker needs disabling of PIE to work... " >&6; }
26037cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26038/* end confdefs.h. */
26039
26040_ACEOF
26041
26042if eval "$ac_compile -Wl,-r,-d -nostdlib -Werror -o conftest.o" 2> /dev/null; then
26043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26044$as_echo "no" >&6; }
26045 # Should we clear up other files as well, having called `AC_LANG_CONFTEST'?
26046 rm -f conftest.o
26047else
26048 link_nopie_needed=yes
26049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26050$as_echo "yes" >&6; }
26051fi
26052
26053# Need that, because some distributions ship compilers that include
26054# `-fPIE' or '-fpie' and '-pie' in the default specs.
26055if [ x"$pie_possible" = xyes ]; then
26056 TARGET_CFLAGS="$TARGET_CFLAGS -fno-PIE -fno-pie"
26057fi
26058
26059if [ x"$link_nopie_needed" = xyes ] || [ x"$pie_possible" = xyes ]; then
26060 if [ x"$nopie_possible" = xyes ]; then
26061 TARGET_LDFLAGS="$TARGET_LDFLAGS -no-pie"
26062 fi
26063 if [ x"$nopie_oneword_possible" = xyes ]; then
26064 TARGET_LDFLAGS="$TARGET_LDFLAGS -nopie"
26065 fi
26066fi
26067
26068CFLAGS="$TARGET_CFLAGS"
26069LDFLAGS="$TARGET_LDFLAGS"
26070
26071# Position independent executable.
26072
26073# Position independent executable.
26074pic_possible=yes
26075{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`$CC' has \`-fPIC' as default" >&5
26076$as_echo_n "checking whether \`$CC' has \`-fPIC' as default... " >&6; }
26077# Is this a reliable test case?
26078cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26079/* end confdefs.h. */
26080
26081#ifdef __PIC__
26082int main() {
26083 return 0;
26084}
26085#else
26086#error NO __PIC__ DEFINED
26087#endif
26088
26089_ACEOF
26090
26091# `$CC -c -o ...' might not be portable. But, oh, well... Is calling
26092# `ac_compile' like this correct, after all?
26093if eval "$ac_compile -S -o conftest.s" 2> /dev/null; then
26094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26095$as_echo "yes" >&6; }
26096 # Should we clear up other files as well, having called `AC_LANG_CONFTEST'?
26097 rm -f conftest.s
26098else
26099 pic_possible=no
26100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26101$as_echo "no" >&6; }
26102fi
26103
26104# On most platforms we don't want PIC as it only makes relocations harder
26105# and code less efficient. On mips we want to have one got table per module
26106# and reload $gp in every function.
26107# GCC implements it using symbol __gnu_local_gp in non-PIC as well.
26108# However with clang we need PIC for this reloading to happen.
26109# With arm64 we need relocations that are in some way representable in
26110# PE as we need to support arm64-efi. Without -fPIC clang generates
26111# movk's which aren't representable.
26112# Since default varies across dictributions use either -fPIC or -fno-PIC
26113# explicitly.
26114if ( test x$target_cpu = xmips || test x$target_cpu = xmipsel || test x$target_cpu = xarm64 ) && test "x$grub_cv_cc_target_clang" = xyes ; then
26115 TARGET_CFLAGS="$TARGET_CFLAGS -fPIC"
26116elif [ x"$pic_possible" = xyes ]; then
26117 TARGET_CFLAGS="$TARGET_CFLAGS -fno-PIC"
26118fi
26119
26120CFLAGS="$TARGET_CFLAGS"
26121
26122# Smashing stack protector.
26123
26124# Smashing stack protector.
26125ssp_possible=yes
26126{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`$CC' accepts \`-fstack-protector'" >&5
26127$as_echo_n "checking whether \`$CC' accepts \`-fstack-protector'... " >&6; }
26128# Is this a reliable test case?
26129cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26130/* end confdefs.h. */
26131
26132void foo (void) { volatile char a[8]; a[3]; }
26133
26134_ACEOF
26135# `$CC -c -o ...' might not be portable. But, oh, well... Is calling
26136# `ac_compile' like this correct, after all?
26137if eval "$ac_compile -S -fstack-protector -o conftest.s" 2> /dev/null; then
26138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26139$as_echo "yes" >&6; }
26140 # Should we clear up other files as well, having called `AC_LANG_CONFTEST'?
26141 rm -f conftest.s
26142else
26143 ssp_possible=no
26144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26145$as_echo "no" >&6; }
26146fi
26147
26148# Need that, because some distributions ship compilers that include
26149# `-fstack-protector' in the default specs.
26150if test "x$ssp_possible" = xyes; then
26151 TARGET_CFLAGS="$TARGET_CFLAGS -fno-stack-protector"
26152fi
26153
26154CFLAGS="$TARGET_CFLAGS"
26155
26156
26157# Smashing stack arg probe.
26158sap_possible=yes
26159{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`$CC' accepts \`-mstack-arg-probe'" >&5
26160$as_echo_n "checking whether \`$CC' accepts \`-mstack-arg-probe'... " >&6; }
26161cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26162/* end confdefs.h. */
26163
26164void foo (void) { volatile char a[8]; a[3]; }
26165
26166_ACEOF
26167if eval "$ac_compile -S -mstack-arg-probe -Werror -o conftest.s" 2> /dev/null; then
26168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26169$as_echo "yes" >&6; }
26170 # Should we clear up other files as well, having called `AC_LANG_CONFTEST'?
26171 rm -f conftest.s
26172else
26173 sap_possible=no
26174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26175$as_echo "no" >&6; }
26176fi
26177
26178# Cygwin's GCC uses alloca() to probe the stackframe on static
26179# stack allocations above some threshold.
26180if test x"$sap_possible" = xyes; then
26181 TARGET_CFLAGS="$TARGET_CFLAGS -mno-stack-arg-probe"
26182fi
26183
26184CFLAGS="$TARGET_CFLAGS"
26185
26186# -mno-unaligned-access -mstrict-align
26187if test "$target_cpu" = arm; then
26188 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compile options to get strict alignment" >&5
26189$as_echo_n "checking for compile options to get strict alignment... " >&6; }
26190if ${grub_cv_target_cc_strict_align+:} false; then :
26191 $as_echo_n "(cached) " >&6
26192else
26193
26194 grub_cv_target_cc_strict_align=
26195 for arg in -mno-unaligned-access "-Xclang -mstrict-align" -mstrict-align; do
26196 CFLAGS="$TARGET_CFLAGS $arg -Werror"
26197 LDFLAGS="$TARGET_LDFLAGS"
26198 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26199/* end confdefs.h. */
26200
26201int
26202main (void)
26203{
26204
26205 ;
26206 return 0;
26207}
26208_ACEOF
26209if ac_fn_c_try_compile "$LINENO"; then :
26210 flag=1
26211else
26212 flag=0
26213fi
26214rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26215 if test x"$flag" = x1; then
26216 grub_cv_target_cc_strict_align="$arg"
26217 break
26218 fi
26219 done
26220fi
26221{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_target_cc_strict_align" >&5
26222$as_echo "$grub_cv_target_cc_strict_align" >&6; }
26223
26224 TARGET_CFLAGS="$TARGET_CFLAGS $grub_cv_target_cc_strict_align"
26225 if test x"$grub_cv_target_cc_strict_align" = x"-Xclang -mstrict-align"; then
26226 TARGET_LDFLAGS="$TARGET_LDFLAGS -Qunused-arguments"
26227 fi
26228 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler generates unaligned accesses" >&5
26229$as_echo_n "checking if compiler generates unaligned accesses... " >&6; }
26230if ${grub_cv_cc_target_emits_unaligned+:} false; then :
26231 $as_echo_n "(cached) " >&6
26232else
26233 CFLAGS="$TARGET_CFLAGS"
26234 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26235/* end confdefs.h. */
26236
26237int
26238main (void)
26239{
26240
26241#ifdef __ARM_FEATURE_UNALIGNED
26242#error "unaligned"
26243#endif
26244
26245 ;
26246 return 0;
26247}
26248_ACEOF
26249if ac_fn_c_try_compile "$LINENO"; then :
26250 grub_cv_cc_target_emits_unaligned=no
26251else
26252 grub_cv_cc_target_emits_unaligned=yes
26253fi
26254rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26255fi
26256{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_target_emits_unaligned" >&5
26257$as_echo "$grub_cv_cc_target_emits_unaligned" >&6; }
26258 if test x$grub_cv_cc_target_emits_unaligned = xyes; then
26259 as_fn_error $? "compiler generates unaligned accesses" "$LINENO" 5
26260 fi
26261fi
26262
26263# Set them to their new values for the tests below.
26264CC="$TARGET_CC"
26265if test x"$platform" = xemu ; then
26266CFLAGS="$TARGET_CFLAGS -Wno-error"
26267elif test "x$TARGET_APPLE_LINKER" = x1 ; then
26268CFLAGS="$TARGET_CFLAGS -nostdlib -static -Wno-error"
26269else
26270CFLAGS="$TARGET_CFLAGS -nostdlib -Wno-error"
26271fi
26272CPPFLAGS="$TARGET_CPPFLAGS"
26273
26274
26275
26276{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if C symbols get an underscore after compilation" >&5
26277$as_echo_n "checking if C symbols get an underscore after compilation... " >&6; }
26278if ${grub_cv_asm_uscore+:} false; then :
26279 $as_echo_n "(cached) " >&6
26280else
26281 cat > conftest.c <<\EOF
26282int func (int *);
26283int
26284func (int *list)
26285{
26286 *list = 0;
26287 return *list;
26288}
26289EOF
26290
26291if { ac_try='${CC-cc} ${CFLAGS} -S conftest.c'
26292 { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
26293 (eval $ac_try) 2>&5
26294 ac_status=$?
26295 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
26296 test $ac_status = 0; }; } && test -s conftest.s; then
26297 true
26298else
26299 as_fn_error $? "${CC-cc} failed to produce assembly code" "$LINENO" 5
26300fi
26301
26302if $EGREP '(^|^_[:alnum])_func' conftest.s >/dev/null 2>&1; then
26303 HAVE_ASM_USCORE=1
26304 grub_cv_asm_uscore=yes
26305else
26306 HAVE_ASM_USCORE=0
26307 grub_cv_asm_uscore=no
26308fi
26309
26310rm -f conftest*
26311fi
26312
26313
26314{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_asm_uscore" >&5
26315$as_echo "$grub_cv_asm_uscore" >&6; }
26316
26317if test "x$TARGET_APPLE_LINKER" = x0 && test x"$platform" != xemu; then
26318if test x$grub_cv_asm_uscore = xyes; then
26319DEFSYM="-Wl,--defsym,_abort=_main -Wl,--defsym,__main=_main"
26320else
26321DEFSYM="-Wl,--defsym,abort=main -Wl,--defsym,_main=main -Wl,--defsym,__main=main"
26322fi
26323CFLAGS="$TARGET_CFLAGS -nostdlib $DEFSYM"
26324fi
26325
26326# Check for libgcc symbols
26327if test x"$platform" = xemu; then
26328for ac_func in __udivsi3 __umodsi3 __divsi3 __modsi3 __divdi3 __moddi3 __udivdi3 __umoddi3 __ctzdi2 __ctzsi2 __aeabi_uidiv __aeabi_uidivmod __aeabi_idiv __aeabi_idivmod __aeabi_ulcmp __muldi3 __aeabi_lmul __aeabi_memcpy __aeabi_memcpy4 __aeabi_memcpy8 __aeabi_memclr __aeabi_memclr4 __aeabi_memclr8 __aeabi_memset __aeabi_lasr __aeabi_llsl __aeabi_llsr _restgpr_14_x __ucmpdi2 __ashldi3 __ashrdi3 __lshrdi3 __bswapsi2 __bswapdi2 __bzero __register_frame_info __deregister_frame_info ___chkstk_ms __chkstk_ms
26329do :
26330 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
26331ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
26332if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
26333 cat >>confdefs.h <<_ACEOF
26334#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
26335_ACEOF
26336
26337fi
26338done
26339
26340fi
26341
26342if test "x$TARGET_APPLE_LINKER" = x1 ; then
26343CFLAGS="$TARGET_CFLAGS -nostdlib -static"
26344else
26345CFLAGS="$TARGET_CFLAGS -nostdlib"
26346fi
26347LIBS=""
26348
26349# Defined in aclocal.m4.
26350{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether target compiler is working" >&5
26351$as_echo_n "checking whether target compiler is working... " >&6; }
26352if ${grub_cv_prog_target_cc+:} false; then :
26353 $as_echo_n "(cached) " >&6
26354else
26355 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26356/* end confdefs.h. */
26357
26358asm (".globl start; start:");
26359void __main (void);
26360void __main (void) {}
26361int main (void);
26362
26363int
26364main (void)
26365{
26366
26367 ;
26368 return 0;
26369}
26370_ACEOF
26371if ac_fn_c_try_link "$LINENO"; then :
26372 grub_cv_prog_target_cc=yes
26373else
26374 grub_cv_prog_target_cc=no
26375fi
26376rm -f core conftest.err conftest.$ac_objext \
26377 conftest$ac_exeext conftest.$ac_ext
26378
26379fi
26380
26381{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_prog_target_cc" >&5
26382$as_echo "$grub_cv_prog_target_cc" >&6; }
26383
26384if test "x$grub_cv_prog_target_cc" = xno; then
26385 as_fn_error $? "cannot compile for the target" "$LINENO" 5
26386fi
26387
26388if test "x$TARGET_APPLE_LINKER" != x1 ; then
26389{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${TARGET_OBJCOPY} works for absolute addresses" >&5
26390$as_echo_n "checking whether ${TARGET_OBJCOPY} works for absolute addresses... " >&6; }
26391if ${grub_cv_prog_objcopy_absolute+:} false; then :
26392 $as_echo_n "(cached) " >&6
26393else
26394 cat > conftest.c <<\EOF
26395void cmain (void);
26396void
26397cmain (void)
26398{
26399 *((int *) 0x1000) = 2;
26400}
26401EOF
26402
26403if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
26404 (eval $ac_compile) 2>&5
26405 ac_status=$?
26406 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
26407 test $ac_status = 0; } && test -s conftest.o; then :
26408else
26409 as_fn_error $? "${CC-cc} cannot compile C source code" "$LINENO" 5
26410fi
26411grub_cv_prog_objcopy_absolute=yes
26412for link_addr in 0x2000 0x8000 0x7C00; do
26413 if { ac_try='${CC-cc} ${TARGET_CFLAGS} ${TARGET_LDFLAGS} -nostdlib ${TARGET_IMG_LDFLAGS_AC} ${TARGET_IMG_BASE_LDOPT},$link_addr conftest.o -o conftest.exec'
26414 { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
26415 (eval $ac_try) 2>&5
26416 ac_status=$?
26417 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
26418 test $ac_status = 0; }; }; then :
26419 else
26420 as_fn_error $? "${CC-cc} cannot link at address $link_addr" "$LINENO" 5
26421 fi
26422 if { ac_try='${TARGET_OBJCOPY-objcopy} --only-section=.text -O binary conftest.exec conftest'
26423 { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
26424 (eval $ac_try) 2>&5
26425 ac_status=$?
26426 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
26427 test $ac_status = 0; }; }; then :
26428 else
26429 as_fn_error $? "${TARGET_OBJCOPY-objcopy} cannot create binary files" "$LINENO" 5
26430 fi
26431 if test ! -f conftest.old || { ac_try='cmp -s conftest.old conftest'
26432 { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
26433 (eval $ac_try) 2>&5
26434 ac_status=$?
26435 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
26436 test $ac_status = 0; }; }; then
26437 mv -f conftest conftest.old
26438 else
26439 grub_cv_prog_objcopy_absolute=no
26440 break
26441 fi
26442done
26443rm -f conftest*
26444fi
26445
26446{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_prog_objcopy_absolute" >&5
26447$as_echo "$grub_cv_prog_objcopy_absolute" >&6; }
26448
26449if test "x$grub_cv_prog_objcopy_absolute" = xno; then
26450 as_fn_error $? "GRUB requires a working absolute objcopy; upgrade your binutils" "$LINENO" 5
26451fi
26452
26453fi
26454{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether linker accepts --build-id=none" >&5
26455$as_echo_n "checking whether linker accepts --build-id=none... " >&6; }
26456if ${grub_cv_prog_ld_build_id_none+:} false; then :
26457 $as_echo_n "(cached) " >&6
26458else
26459 save_LDFLAGS="$LDFLAGS"
26460LDFLAGS="$LDFLAGS -Wl,--build-id=none"
26461cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26462/* end confdefs.h. */
26463
26464int
26465main (void)
26466{
26467
26468 ;
26469 return 0;
26470}
26471_ACEOF
26472if ac_fn_c_try_link "$LINENO"; then :
26473 grub_cv_prog_ld_build_id_none=yes
26474else
26475 grub_cv_prog_ld_build_id_none=no
26476fi
26477rm -f core conftest.err conftest.$ac_objext \
26478 conftest$ac_exeext conftest.$ac_ext
26479LDFLAGS="$save_LDFLAGS"
26480
26481fi
26482
26483{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_prog_ld_build_id_none" >&5
26484$as_echo "$grub_cv_prog_ld_build_id_none" >&6; }
26485
26486if test "x$grub_cv_prog_ld_build_id_none" = xyes; then
26487 TARGET_LDFLAGS="$TARGET_LDFLAGS -Wl,--build-id=none"
26488fi
26489
26490if test "x$target_cpu" = xi386; then
26491 if test "$platform" != emu && test "x$TARGET_APPLE_LINKER" != x1 ; then
26492 if test ! -z "$TARGET_IMG_LDSCRIPT"; then
26493 # Check symbols provided by linker script.
26494 CFLAGS="$TARGET_CFLAGS -nostdlib ${TARGET_IMG_LDFLAGS_AC} ${TARGET_IMG_BASE_LDOPT},0x8000"
26495 fi
26496
26497{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if __bss_start is defined by the compiler" >&5
26498$as_echo_n "checking if __bss_start is defined by the compiler... " >&6; }
26499if ${grub_cv_check_uscore_uscore_bss_start_symbol+:} false; then :
26500 $as_echo_n "(cached) " >&6
26501else
26502 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26503/* end confdefs.h. */
26504
26505asm (".globl start; start:");
26506void __main (void);
26507void __main (void) {}
26508int main (void);
26509
26510int
26511main (void)
26512{
26513asm ("incl __bss_start")
26514 ;
26515 return 0;
26516}
26517_ACEOF
26518if ac_fn_c_try_link "$LINENO"; then :
26519 grub_cv_check_uscore_uscore_bss_start_symbol=yes
26520else
26521 grub_cv_check_uscore_uscore_bss_start_symbol=no
26522fi
26523rm -f core conftest.err conftest.$ac_objext \
26524 conftest$ac_exeext conftest.$ac_ext
26525fi
26526
26527
26528{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_check_uscore_uscore_bss_start_symbol" >&5
26529$as_echo "$grub_cv_check_uscore_uscore_bss_start_symbol" >&6; }
26530
26531{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if edata is defined by the compiler" >&5
26532$as_echo_n "checking if edata is defined by the compiler... " >&6; }
26533if ${grub_cv_check_edata_symbol+:} false; then :
26534 $as_echo_n "(cached) " >&6
26535else
26536 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26537/* end confdefs.h. */
26538
26539asm (".globl start; start:");
26540void __main (void);
26541void __main (void) {}
26542int main (void);
26543int
26544main (void)
26545{
26546asm ("incl edata")
26547 ;
26548 return 0;
26549}
26550_ACEOF
26551if ac_fn_c_try_link "$LINENO"; then :
26552 grub_cv_check_edata_symbol=yes
26553else
26554 grub_cv_check_edata_symbol=no
26555fi
26556rm -f core conftest.err conftest.$ac_objext \
26557 conftest$ac_exeext conftest.$ac_ext
26558fi
26559
26560
26561{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_check_edata_symbol" >&5
26562$as_echo "$grub_cv_check_edata_symbol" >&6; }
26563
26564{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if _edata is defined by the compiler" >&5
26565$as_echo_n "checking if _edata is defined by the compiler... " >&6; }
26566if ${grub_cv_check_uscore_edata_symbol+:} false; then :
26567 $as_echo_n "(cached) " >&6
26568else
26569 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26570/* end confdefs.h. */
26571
26572asm (".globl start; start:");
26573void __main (void);
26574void __main (void) {}
26575int main (void);
26576int
26577main (void)
26578{
26579asm ("incl _edata")
26580 ;
26581 return 0;
26582}
26583_ACEOF
26584if ac_fn_c_try_link "$LINENO"; then :
26585 grub_cv_check_uscore_edata_symbol=yes
26586else
26587 grub_cv_check_uscore_edata_symbol=no
26588fi
26589rm -f core conftest.err conftest.$ac_objext \
26590 conftest$ac_exeext conftest.$ac_ext
26591fi
26592
26593
26594{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_check_uscore_edata_symbol" >&5
26595$as_echo "$grub_cv_check_uscore_edata_symbol" >&6; }
26596
26597if test "x$grub_cv_check_uscore_uscore_bss_start_symbol" = xyes; then
26598 BSS_START_SYMBOL=__bss_start
26599elif test "x$grub_cv_check_edata_symbol" = xyes; then
26600 BSS_START_SYMBOL=edata
26601elif test "x$grub_cv_check_uscore_edata_symbol" = xyes; then
26602 BSS_START_SYMBOL=_edata
26603else
26604 as_fn_error $? "none of __bss_start, edata or _edata is defined" "$LINENO" 5
26605fi
26606
26607
26608{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if end is defined by the compiler" >&5
26609$as_echo_n "checking if end is defined by the compiler... " >&6; }
26610if ${grub_cv_check_end_symbol+:} false; then :
26611 $as_echo_n "(cached) " >&6
26612else
26613 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26614/* end confdefs.h. */
26615
26616asm (".globl start; start:");
26617void __main (void);
26618void __main (void) {}
26619int main (void);
26620int
26621main (void)
26622{
26623asm ("incl end")
26624 ;
26625 return 0;
26626}
26627_ACEOF
26628if ac_fn_c_try_link "$LINENO"; then :
26629 grub_cv_check_end_symbol=yes
26630else
26631 grub_cv_check_end_symbol=no
26632fi
26633rm -f core conftest.err conftest.$ac_objext \
26634 conftest$ac_exeext conftest.$ac_ext
26635fi
26636
26637
26638{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_check_end_symbol" >&5
26639$as_echo "$grub_cv_check_end_symbol" >&6; }
26640
26641{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if _end is defined by the compiler" >&5
26642$as_echo_n "checking if _end is defined by the compiler... " >&6; }
26643if ${grub_cv_check_uscore_end_symbol+:} false; then :
26644 $as_echo_n "(cached) " >&6
26645else
26646 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26647/* end confdefs.h. */
26648
26649asm (".globl start; start:");
26650void __main (void);
26651void __main (void) {}
26652int main (void);
26653int
26654main (void)
26655{
26656asm ("incl _end")
26657 ;
26658 return 0;
26659}
26660_ACEOF
26661if ac_fn_c_try_link "$LINENO"; then :
26662 grub_cv_check_uscore_end_symbol=yes
26663else
26664 grub_cv_check_uscore_end_symbol=no
26665fi
26666rm -f core conftest.err conftest.$ac_objext \
26667 conftest$ac_exeext conftest.$ac_ext
26668fi
26669
26670
26671{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_check_uscore_end_symbol" >&5
26672$as_echo "$grub_cv_check_uscore_end_symbol" >&6; }
26673
26674if test "x$grub_cv_check_end_symbol" = xyes; then
26675 END_SYMBOL=end
26676elif test "x$grub_cv_check_uscore_end_symbol" = xyes; then
26677 END_SYMBOL=_end
26678else
26679 as_fn_error $? "neither end nor _end is defined" "$LINENO" 5
26680fi
26681
26682 fi
26683 CFLAGS="$TARGET_CFLAGS"
26684fi
26685
26686{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether nm works" >&5
26687$as_echo_n "checking whether nm works... " >&6; }
26688if ${grub_cv_prog_nm_works+:} false; then :
26689 $as_echo_n "(cached) " >&6
26690else
26691
26692nm_works_tmp_dir="$(mktemp -d "./confXXXXXX")"
26693cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26694/* end confdefs.h. */
26695
26696int
26697main (void)
26698{
26699
26700 ;
26701 return 0;
26702}
26703_ACEOF
26704$TARGET_CC $TARGET_CFLAGS -c conftest.c -o "$nm_works_tmp_dir/ef"
26705if $TARGET_NM "$nm_works_tmp_dir/ef" > /dev/null; then
26706 grub_cv_prog_nm_works=yes
26707else
26708 grub_cv_prog_nm_minus_p=no
26709fi
26710rm "$nm_works_tmp_dir/ef"
26711rmdir "$nm_works_tmp_dir"
26712
26713fi
26714
26715{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_prog_nm_works" >&5
26716$as_echo "$grub_cv_prog_nm_works" >&6; }
26717
26718if test "x$grub_cv_prog_nm_works" != xyes; then
26719 as_fn_error $? "nm does not work" "$LINENO" 5
26720fi
26721
26722{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether nm accepts -P" >&5
26723$as_echo_n "checking whether nm accepts -P... " >&6; }
26724if ${grub_cv_prog_nm_minus_p+:} false; then :
26725 $as_echo_n "(cached) " >&6
26726else
26727
26728nm_minus_p_tmp_dir="$(mktemp -d "./confXXXXXX")"
26729cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26730/* end confdefs.h. */
26731
26732int
26733main (void)
26734{
26735
26736 ;
26737 return 0;
26738}
26739_ACEOF
26740$TARGET_CC $TARGET_CFLAGS -c conftest.c -o "$nm_minus_p_tmp_dir/ef"
26741if $TARGET_NM -P "$nm_minus_p_tmp_dir/ef" 2>&1 > /dev/null; then
26742 grub_cv_prog_nm_minus_p=yes
26743else
26744 grub_cv_prog_nm_minus_p=no
26745fi
26746rm "$nm_minus_p_tmp_dir/ef"
26747rmdir "$nm_minus_p_tmp_dir"
26748
26749fi
26750
26751{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_prog_nm_minus_p" >&5
26752$as_echo "$grub_cv_prog_nm_minus_p" >&6; }
26753
26754if test "x$grub_cv_prog_nm_minus_p" = xyes; then
26755 TARGET_NMFLAGS_MINUS_P="-P"
26756else
26757 TARGET_NMFLAGS_MINUS_P=
26758fi
26759
26760{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether nm accepts --defined-only" >&5
26761$as_echo_n "checking whether nm accepts --defined-only... " >&6; }
26762if ${grub_cv_prog_nm_defined_only+:} false; then :
26763 $as_echo_n "(cached) " >&6
26764else
26765
26766nm_defined_only_tmp_dir="$(mktemp -d "./confXXXXXX")"
26767cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26768/* end confdefs.h. */
26769
26770int
26771main (void)
26772{
26773
26774 ;
26775 return 0;
26776}
26777_ACEOF
26778$TARGET_CC $TARGET_CFLAGS -c conftest.c -o "$nm_defined_only_tmp_dir/ef"
26779if $TARGET_NM --defined-only "$nm_defined_only_tmp_dir/ef" 2>&1 > /dev/null; then
26780 grub_cv_prog_nm_defined_only=yes
26781else
26782 grub_cv_prog_nm_defined_only=no
26783fi
26784rm "$nm_defined_only_tmp_dir/ef"
26785rmdir "$nm_defined_only_tmp_dir"
26786
26787fi
26788
26789{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_prog_nm_defined_only" >&5
26790$as_echo "$grub_cv_prog_nm_defined_only" >&6; }
26791
26792if test "x$grub_cv_prog_nm_defined_only" = xyes; then
26793 TARGET_NMFLAGS_DEFINED_ONLY=--defined-only
26794else
26795 TARGET_NMFLAGS_DEFINED_ONLY=
26796fi
26797
26798
26799
26800
26801if test "$platform" != emu; then
26802{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -nostdinc -isystem works" >&5
26803$as_echo_n "checking whether -nostdinc -isystem works... " >&6; }
26804if ${grub_cv_cc_isystem+:} false; then :
26805 $as_echo_n "(cached) " >&6
26806else
26807
26808 SAVED_CPPFLAGS="$CPPFLAGS"
26809 CPPFLAGS="$TARGET_CPPFLAGS -nostdinc -isystem `$TARGET_CC -print-file-name=include`"
26810 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26811/* end confdefs.h. */
26812#include <stdarg.h>
26813#include <stddef.h>
26814int va_arg_func (int fixed, va_list args);
26815int
26816main (void)
26817{
26818
26819 ;
26820 return 0;
26821}
26822_ACEOF
26823if ac_fn_c_try_compile "$LINENO"; then :
26824 grub_cv_cc_isystem=yes
26825else
26826 grub_cv_cc_isystem=no
26827fi
26828rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26829 CPPFLAGS="$SAVED_CPPFLAGS"
26830
26831fi
26832{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_isystem" >&5
26833$as_echo "$grub_cv_cc_isystem" >&6; }
26834
26835if test x"$grub_cv_cc_isystem" = xyes ; then
26836 TARGET_CPPFLAGS="$TARGET_CPPFLAGS -nostdinc -isystem `$TARGET_CC -print-file-name=include`"
26837fi
26838fi
26839
26840{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wtrampolines work" >&5
26841$as_echo_n "checking whether -Wtrampolines work... " >&6; }
26842if ${grub_cv_cc_wtrampolines+:} false; then :
26843 $as_echo_n "(cached) " >&6
26844else
26845
26846 CFLAGS="$TARGET_CFLAGS -Wtrampolines -Werror"
26847 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26848/* end confdefs.h. */
26849#include <stdarg.h>
26850int va_arg_func (int fixed, va_list args);
26851int
26852main (void)
26853{
26854
26855 ;
26856 return 0;
26857}
26858_ACEOF
26859if ac_fn_c_try_compile "$LINENO"; then :
26860 grub_cv_cc_wtrampolines=yes
26861else
26862 grub_cv_cc_wtrampolines=no
26863fi
26864rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26865
26866fi
26867{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $grub_cv_cc_wtrampolines" >&5
26868$as_echo "$grub_cv_cc_wtrampolines" >&6; }
26869
26870if test x"$grub_cv_cc_wtrampolines" = xyes ; then
26871 TARGET_CFLAGS="$TARGET_CFLAGS -Wtrampolines"
26872fi
26873
26874# Restore the flags.
26875CC="$tmp_CC"
26876CFLAGS="$tmp_CFLAGS"
26877CPPFLAGS="$tmp_CPPFLAGS"
26878LDFLAGS="$tmp_LDFLAGS"
26879LIBS="$tmp_LIBS"
26880
26881#
26882# Check for options.
26883#
26884
26885# Memory manager debugging.
26886# Check whether --enable-mm-debug was given.
26887if test "${enable_mm_debug+set}" = set; then :
26888 enableval=$enable_mm_debug;
26889$as_echo "#define MM_DEBUG 1" >>confdefs.h
26890
26891fi
26892
26893
26894# Check whether --enable-cache-stats was given.
26895if test "${enable_cache_stats+set}" = set; then :
26896 enableval=$enable_cache_stats;
26897fi
26898
26899
26900if test x$enable_cache_stats = xyes; then
26901 DISK_CACHE_STATS=1
26902else
26903 DISK_CACHE_STATS=0
26904fi
26905
26906
26907# Check whether --enable-boot-time was given.
26908if test "${enable_boot_time+set}" = set; then :
26909 enableval=$enable_boot_time;
26910fi
26911
26912
26913if test x$enable_boot_time = xyes; then
26914 BOOT_TIME_STATS=1
26915else
26916 BOOT_TIME_STATS=0
26917fi
26918
26919
26920# Check whether --enable-grub-emu-sdl was given.
26921if test "${enable_grub_emu_sdl+set}" = set; then :
26922 enableval=$enable_grub_emu_sdl;
26923fi
26924
26925
26926# Check whether --enable-grub-emu-pci was given.
26927if test "${enable_grub_emu_pci+set}" = set; then :
26928 enableval=$enable_grub_emu_pci;
26929fi
26930
26931
26932if test "$platform" = emu; then
26933
26934if test x"$enable_grub_emu_sdl" = xno ; then
26935 grub_emu_sdl_excuse="explicitly disabled"
26936fi
26937if [ x"$grub_emu_sdl_excuse" = x ]; then
26938 # Check for libSDL libraries.
26939{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for SDL_Init in -lSDL" >&5
26940$as_echo_n "checking for SDL_Init in -lSDL... " >&6; }
26941if ${ac_cv_lib_SDL_SDL_Init+:} false; then :
26942 $as_echo_n "(cached) " >&6
26943else
26944 ac_check_lib_save_LIBS=$LIBS
26945LIBS="-lSDL $LIBS"
26946cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26947/* end confdefs.h. */
26948
26949/* Override any GCC internal prototype to avoid an error.
26950 Use char because int might match the return type of a GCC
26951 builtin and then its argument prototype would still apply. */
26952#ifdef __cplusplus
26953extern "C"
26954#endif
26955char SDL_Init ();
26956int
26957main (void)
26958{
26959return SDL_Init ();
26960 ;
26961 return 0;
26962}
26963_ACEOF
26964if ac_fn_c_try_link "$LINENO"; then :
26965 ac_cv_lib_SDL_SDL_Init=yes
26966else
26967 ac_cv_lib_SDL_SDL_Init=no
26968fi
26969rm -f core conftest.err conftest.$ac_objext \
26970 conftest$ac_exeext conftest.$ac_ext
26971LIBS=$ac_check_lib_save_LIBS
26972fi
26973{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SDL_SDL_Init" >&5
26974$as_echo "$ac_cv_lib_SDL_SDL_Init" >&6; }
26975if test "x$ac_cv_lib_SDL_SDL_Init" = xyes; then :
26976 LIBSDL="-lSDL"
26977else
26978 grub_emu_sdl_excuse="libSDL libraries are required to build \`grub-emu' with SDL support"
26979fi
26980
26981
26982fi
26983
26984if [ x"$grub_emu_sdl_excuse" = x ]; then
26985 # Check for headers.
26986 for ac_header in SDL/SDL.h
26987do :
26988 ac_fn_c_check_header_mongrel "$LINENO" "SDL/SDL.h" "ac_cv_header_SDL_SDL_h" "$ac_includes_default"
26989if test "x$ac_cv_header_SDL_SDL_h" = xyes; then :
26990 cat >>confdefs.h <<_ACEOF
26991#define HAVE_SDL_SDL_H 1
26992_ACEOF
26993
26994else
26995 grub_emu_sdl_excuse="libSDL header file is required to build \`grub-emu' with SDL support"
26996fi
26997
26998done
26999
27000fi
27001
27002if test x"enable_grub_emu_sdl" = xyes && test x"$grub_emu_sdl_excuse" != x ; then
27003 as_fn_error $? "SDL support for grub-emu was explicitly requested but can't be compiled ($grub_emu_sdl_excuse)" "$LINENO" 5
27004fi
27005if test x"$grub_emu_sdl_excuse" = x ; then
27006enable_grub_emu_sdl=yes
27007else
27008enable_grub_emu_sdl=no
27009fi
27010
27011if test x"$enable_grub_emu_pci" != xyes ; then
27012 grub_emu_pci_excuse="not enabled"
27013fi
27014
27015if [ x"$grub_emu_pci_excuse" = x ]; then
27016 # Check for libpci libraries.
27017 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pci_system_init in -lpciaccess" >&5
27018$as_echo_n "checking for pci_system_init in -lpciaccess... " >&6; }
27019if ${ac_cv_lib_pciaccess_pci_system_init+:} false; then :
27020 $as_echo_n "(cached) " >&6
27021else
27022 ac_check_lib_save_LIBS=$LIBS
27023LIBS="-lpciaccess $LIBS"
27024cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27025/* end confdefs.h. */
27026
27027/* Override any GCC internal prototype to avoid an error.
27028 Use char because int might match the return type of a GCC
27029 builtin and then its argument prototype would still apply. */
27030#ifdef __cplusplus
27031extern "C"
27032#endif
27033char pci_system_init ();
27034int
27035main (void)
27036{
27037return pci_system_init ();
27038 ;
27039 return 0;
27040}
27041_ACEOF
27042if ac_fn_c_try_link "$LINENO"; then :
27043 ac_cv_lib_pciaccess_pci_system_init=yes
27044else
27045 ac_cv_lib_pciaccess_pci_system_init=no
27046fi
27047rm -f core conftest.err conftest.$ac_objext \
27048 conftest$ac_exeext conftest.$ac_ext
27049LIBS=$ac_check_lib_save_LIBS
27050fi
27051{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pciaccess_pci_system_init" >&5
27052$as_echo "$ac_cv_lib_pciaccess_pci_system_init" >&6; }
27053if test "x$ac_cv_lib_pciaccess_pci_system_init" = xyes; then :
27054 LIBPCIACCESS="-lpciaccess"
27055else
27056 grub_emu_pci_excuse="need libpciaccess library"
27057fi
27058
27059
27060fi
27061if [ x"$grub_emu_pci_excuse" = x ]; then
27062 # Check for headers.
27063 for ac_header in pciaccess.h
27064do :
27065 ac_fn_c_check_header_mongrel "$LINENO" "pciaccess.h" "ac_cv_header_pciaccess_h" "$ac_includes_default"
27066if test "x$ac_cv_header_pciaccess_h" = xyes; then :
27067 cat >>confdefs.h <<_ACEOF
27068#define HAVE_PCIACCESS_H 1
27069_ACEOF
27070
27071else
27072 grub_emu_pci_excuse="need libpciaccess headers"
27073fi
27074
27075done
27076
27077fi
27078
27079if test x"$grub_emu_pci_excuse" = x ; then
27080enable_grub_emu_pci=yes
27081else
27082
27083enable_grub_emu_pci=no
27084fi
27085
27086
27087
27088
27089else
27090
27091# Ignore --enable-emu-* if platform is not emu
27092enable_grub_emu_sdl=no
27093enable_grub_emu_pci=no
27094fi
27095
27096# Check whether --enable-grub-mkfont was given.
27097if test "${enable_grub_mkfont+set}" = set; then :
27098 enableval=$enable_grub_mkfont;
27099fi
27100
27101if test x"$enable_grub_mkfont" = xno ; then
27102 grub_mkfont_excuse="explicitly disabled"
27103fi
27104
27105if test x"$grub_mkfont_excuse" = x ; then
27106 # Check for freetype libraries.
27107 if test -n "$ac_tool_prefix"; then
27108 for ac_prog in freetype-config
27109 do
27110 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
27111set dummy $ac_tool_prefix$ac_prog; ac_word=$2
27112{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27113$as_echo_n "checking for $ac_word... " >&6; }
27114if ${ac_cv_prog_FREETYPE+:} false; then :
27115 $as_echo_n "(cached) " >&6
27116else
27117 if test -n "$FREETYPE"; then
27118 ac_cv_prog_FREETYPE="$FREETYPE" # Let the user override the test.
27119else
27120as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27121for as_dir in $PATH
27122do
27123 IFS=$as_save_IFS
27124 test -z "$as_dir" && as_dir=.
27125 for ac_exec_ext in '' $ac_executable_extensions; do
27126 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27127 ac_cv_prog_FREETYPE="$ac_tool_prefix$ac_prog"
27128 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27129 break 2
27130 fi
27131done
27132 done
27133IFS=$as_save_IFS
27134
27135fi
27136fi
27137FREETYPE=$ac_cv_prog_FREETYPE
27138if test -n "$FREETYPE"; then
27139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE" >&5
27140$as_echo "$FREETYPE" >&6; }
27141else
27142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27143$as_echo "no" >&6; }
27144fi
27145
27146
27147 test -n "$FREETYPE" && break
27148 done
27149fi
27150if test -z "$FREETYPE"; then
27151 ac_ct_FREETYPE=$FREETYPE
27152 for ac_prog in freetype-config
27153do
27154 # Extract the first word of "$ac_prog", so it can be a program name with args.
27155set dummy $ac_prog; ac_word=$2
27156{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27157$as_echo_n "checking for $ac_word... " >&6; }
27158if ${ac_cv_prog_ac_ct_FREETYPE+:} false; then :
27159 $as_echo_n "(cached) " >&6
27160else
27161 if test -n "$ac_ct_FREETYPE"; then
27162 ac_cv_prog_ac_ct_FREETYPE="$ac_ct_FREETYPE" # Let the user override the test.
27163else
27164as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27165for as_dir in $PATH
27166do
27167 IFS=$as_save_IFS
27168 test -z "$as_dir" && as_dir=.
27169 for ac_exec_ext in '' $ac_executable_extensions; do
27170 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27171 ac_cv_prog_ac_ct_FREETYPE="$ac_prog"
27172 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27173 break 2
27174 fi
27175done
27176 done
27177IFS=$as_save_IFS
27178
27179fi
27180fi
27181ac_ct_FREETYPE=$ac_cv_prog_ac_ct_FREETYPE
27182if test -n "$ac_ct_FREETYPE"; then
27183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_FREETYPE" >&5
27184$as_echo "$ac_ct_FREETYPE" >&6; }
27185else
27186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27187$as_echo "no" >&6; }
27188fi
27189
27190
27191 test -n "$ac_ct_FREETYPE" && break
27192done
27193
27194 if test "x$ac_ct_FREETYPE" = x; then
27195 FREETYPE=""
27196 else
27197 case $cross_compiling:$ac_tool_warned in
27198yes:)
27199{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
27200$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
27201ac_tool_warned=yes ;;
27202esac
27203 FREETYPE=$ac_ct_FREETYPE
27204 fi
27205fi
27206
27207 if test "x$FREETYPE" = x ; then
27208 grub_mkfont_excuse="need freetype2 library"
27209 fi
27210fi
27211
27212unset ac_cv_header_ft2build_h
27213
27214if test x"$grub_mkfont_excuse" = x ; then
27215 # Check for freetype libraries.
27216 freetype_cflags=`$FREETYPE --cflags`
27217 freetype_libs=`$FREETYPE --libs`
27218 SAVED_CPPFLAGS="$CPPFLAGS"
27219 SAVED_LIBS="$LIBS"
27220 CPPFLAGS="$CPPFLAGS $freetype_cflags"
27221 LIBS="$LIBS $freetype_libs"
27222 for ac_header in ft2build.h
27223do :
27224 ac_fn_c_check_header_mongrel "$LINENO" "ft2build.h" "ac_cv_header_ft2build_h" "$ac_includes_default"
27225if test "x$ac_cv_header_ft2build_h" = xyes; then :
27226 cat >>confdefs.h <<_ACEOF
27227#define HAVE_FT2BUILD_H 1
27228_ACEOF
27229
27230else
27231 grub_mkfont_excuse="need freetype2 headers"
27232fi
27233
27234done
27235
27236 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27237/* end confdefs.h. */
27238
27239/* Override any GCC internal prototype to avoid an error.
27240 Use char because int might match the return type of a GCC
27241 builtin and then its argument prototype would still apply. */
27242#ifdef __cplusplus
27243extern "C"
27244#endif
27245char FT_Load_Glyph ();
27246int
27247main (void)
27248{
27249return FT_Load_Glyph ();
27250 ;
27251 return 0;
27252}
27253_ACEOF
27254if ac_fn_c_try_link "$LINENO"; then :
27255
27256else
27257 grub_mkfont_excuse="freetype2 library unusable"
27258fi
27259rm -f core conftest.err conftest.$ac_objext \
27260 conftest$ac_exeext conftest.$ac_ext
27261 CPPFLAGS="$SAVED_CPPFLAGS"
27262 LIBS="$SAVED_LIBS"
27263fi
27264
27265if test x"$enable_grub_mkfont" = xyes && test x"$grub_mkfont_excuse" != x ; then
27266 as_fn_error $? "grub-mkfont was explicitly requested but can't be compiled ($grub_mkfont_excuse)" "$LINENO" 5
27267fi
27268if test x"$grub_mkfont_excuse" = x ; then
27269enable_grub_mkfont=yes
27270else
27271enable_grub_mkfont=no
27272fi
27273
27274
27275
27276
27277SAVED_CC="$CC"
27278SAVED_CPP="$CPP"
27279SAVED_CFLAGS="$CFLAGS"
27280SAVED_CPPFLAGS="$CPPFLAGS"
27281SAVED_LDFLAGS="$LDFLAGS"
27282CC="$BUILD_CC"
27283CPP="$BUILD_CPP"
27284CFLAGS="$BUILD_CFLAGS"
27285CPPFLAGS="$BUILD_CPPFLAGS"
27286LDFLAGS="$BUILD_LDFAGS"
27287
27288unset ac_cv_c_bigendian
27289unset ac_cv_header_ft2build_h
27290
27291if ac_fn_c_compute_int "$LINENO" "sizeof (void *)" "BUILD_SIZEOF_VOID_P" ""; then :
27292
27293fi
27294
27295if ac_fn_c_compute_int "$LINENO" "sizeof (long)" "BUILD_SIZEOF_LONG" ""; then :
27296
27297fi
27298
27299 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
27300$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
27301if ${ac_cv_c_bigendian+:} false; then :
27302 $as_echo_n "(cached) " >&6
27303else
27304 ac_cv_c_bigendian=unknown
27305 # See if we're dealing with a universal compiler.
27306 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27307/* end confdefs.h. */
27308#ifndef __APPLE_CC__
27309 not a universal capable compiler
27310 #endif
27311 typedef int dummy;
27312
27313_ACEOF
27314if ac_fn_c_try_compile "$LINENO"; then :
27315
27316 # Check for potential -arch flags. It is not universal unless
27317 # there are at least two -arch flags with different values.
27318 ac_arch=
27319 ac_prev=
27320 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
27321 if test -n "$ac_prev"; then
27322 case $ac_word in
27323 i?86 | x86_64 | ppc | ppc64)
27324 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
27325 ac_arch=$ac_word
27326 else
27327 ac_cv_c_bigendian=universal
27328 break
27329 fi
27330 ;;
27331 esac
27332 ac_prev=
27333 elif test "x$ac_word" = "x-arch"; then
27334 ac_prev=arch
27335 fi
27336 done
27337fi
27338rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27339 if test $ac_cv_c_bigendian = unknown; then
27340 # See if sys/param.h defines the BYTE_ORDER macro.
27341 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27342/* end confdefs.h. */
27343#include <sys/types.h>
27344 #include <sys/param.h>
27345
27346int
27347main (void)
27348{
27349#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
27350 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
27351 && LITTLE_ENDIAN)
27352 bogus endian macros
27353 #endif
27354
27355 ;
27356 return 0;
27357}
27358_ACEOF
27359if ac_fn_c_try_compile "$LINENO"; then :
27360 # It does; now see whether it defined to BIG_ENDIAN or not.
27361 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27362/* end confdefs.h. */
27363#include <sys/types.h>
27364 #include <sys/param.h>
27365
27366int
27367main (void)
27368{
27369#if BYTE_ORDER != BIG_ENDIAN
27370 not big endian
27371 #endif
27372
27373 ;
27374 return 0;
27375}
27376_ACEOF
27377if ac_fn_c_try_compile "$LINENO"; then :
27378 ac_cv_c_bigendian=yes
27379else
27380 ac_cv_c_bigendian=no
27381fi
27382rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27383fi
27384rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27385 fi
27386 if test $ac_cv_c_bigendian = unknown; then
27387 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
27388 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27389/* end confdefs.h. */
27390#include <limits.h>
27391
27392int
27393main (void)
27394{
27395#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
27396 bogus endian macros
27397 #endif
27398
27399 ;
27400 return 0;
27401}
27402_ACEOF
27403if ac_fn_c_try_compile "$LINENO"; then :
27404 # It does; now see whether it defined to _BIG_ENDIAN or not.
27405 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27406/* end confdefs.h. */
27407#include <limits.h>
27408
27409int
27410main (void)
27411{
27412#ifndef _BIG_ENDIAN
27413 not big endian
27414 #endif
27415
27416 ;
27417 return 0;
27418}
27419_ACEOF
27420if ac_fn_c_try_compile "$LINENO"; then :
27421 ac_cv_c_bigendian=yes
27422else
27423 ac_cv_c_bigendian=no
27424fi
27425rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27426fi
27427rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27428 fi
27429 if test $ac_cv_c_bigendian = unknown; then
27430 # Compile a test program.
27431 if test "$cross_compiling" = yes; then :
27432 # Try to guess by grepping values from an object file.
27433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27434/* end confdefs.h. */
27435short int ascii_mm[] =
27436 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
27437 short int ascii_ii[] =
27438 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
27439 int use_ascii (int i) {
27440 return ascii_mm[i] + ascii_ii[i];
27441 }
27442 short int ebcdic_ii[] =
27443 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
27444 short int ebcdic_mm[] =
27445 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
27446 int use_ebcdic (int i) {
27447 return ebcdic_mm[i] + ebcdic_ii[i];
27448 }
27449 extern int foo;
27450
27451int
27452main (void)
27453{
27454return use_ascii (foo) == use_ebcdic (foo);
27455 ;
27456 return 0;
27457}
27458_ACEOF
27459if ac_fn_c_try_compile "$LINENO"; then :
27460 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
27461 ac_cv_c_bigendian=yes
27462 fi
27463 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
27464 if test "$ac_cv_c_bigendian" = unknown; then
27465 ac_cv_c_bigendian=no
27466 else
27467 # finding both strings is unlikely to happen, but who knows?
27468 ac_cv_c_bigendian=unknown
27469 fi
27470 fi
27471fi
27472rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27473else
27474 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27475/* end confdefs.h. */
27476$ac_includes_default
27477int
27478main (void)
27479{
27480
27481 /* Are we little or big endian? From Harbison&Steele. */
27482 union
27483 {
27484 long int l;
27485 char c[sizeof (long int)];
27486 } u;
27487 u.l = 1;
27488 return u.c[sizeof (long int) - 1] == 1;
27489
27490 ;
27491 return 0;
27492}
27493_ACEOF
27494if ac_fn_c_try_run "$LINENO"; then :
27495 ac_cv_c_bigendian=no
27496else
27497 ac_cv_c_bigendian=yes
27498fi
27499rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27500 conftest.$ac_objext conftest.beam conftest.$ac_ext
27501fi
27502
27503 fi
27504fi
27505{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
27506$as_echo "$ac_cv_c_bigendian" >&6; }
27507 case $ac_cv_c_bigendian in #(
27508 yes)
27509 BUILD_WORDS_BIGENDIAN=1;; #(
27510 no)
27511 BUILD_WORDS_BIGENDIAN=0 ;; #(
27512 universal)
27513 BUILD_WORDS_BIGENDIAN=err
27514 ;; #(
27515 *)
27516 BUILD_WORDS_BIGENDIAN=err ;;
27517 esac
27518
27519
27520if test x$BUILD_WORDS_BIGENDIAN = xerr ; then
27521 as_fn_error $? "couldnt determine build endianness" "$LINENO" 5
27522fi
27523
27524
27525
27526
27527
27528if test x"$grub_build_mkfont_excuse" = x ; then
27529 # Check for freetype libraries.
27530 for ac_prog in freetype-config
27531do
27532 # Extract the first word of "$ac_prog", so it can be a program name with args.
27533set dummy $ac_prog; ac_word=$2
27534{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27535$as_echo_n "checking for $ac_word... " >&6; }
27536if ${ac_cv_prog_BUILD_FREETYPE+:} false; then :
27537 $as_echo_n "(cached) " >&6
27538else
27539 if test -n "$BUILD_FREETYPE"; then
27540 ac_cv_prog_BUILD_FREETYPE="$BUILD_FREETYPE" # Let the user override the test.
27541else
27542as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27543for as_dir in $PATH
27544do
27545 IFS=$as_save_IFS
27546 test -z "$as_dir" && as_dir=.
27547 for ac_exec_ext in '' $ac_executable_extensions; do
27548 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27549 ac_cv_prog_BUILD_FREETYPE="$ac_prog"
27550 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27551 break 2
27552 fi
27553done
27554 done
27555IFS=$as_save_IFS
27556
27557fi
27558fi
27559BUILD_FREETYPE=$ac_cv_prog_BUILD_FREETYPE
27560if test -n "$BUILD_FREETYPE"; then
27561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_FREETYPE" >&5
27562$as_echo "$BUILD_FREETYPE" >&6; }
27563else
27564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27565$as_echo "no" >&6; }
27566fi
27567
27568
27569 test -n "$BUILD_FREETYPE" && break
27570done
27571
27572 if test "x$BUILD_FREETYPE" = x ; then
27573 grub_build_mkfont_excuse="need freetype2 library"
27574 fi
27575fi
27576
27577if test x"$grub_build_mkfont_excuse" = x ; then
27578 # Check for freetype libraries.
27579 build_freetype_cflags=`$BUILD_FREETYPE --cflags`
27580 build_freetype_libs=`$BUILD_FREETYPE --libs`
27581 SAVED_CPPFLAGS_2="$CPPFLAGS"
27582 SAVED_LIBS="$LIBS"
27583 CPPFLAGS="$CPPFLAGS $build_freetype_cflags"
27584 LIBS="$LIBS $build_freetype_libs"
27585 for ac_header in ft2build.h
27586do :
27587 ac_fn_c_check_header_mongrel "$LINENO" "ft2build.h" "ac_cv_header_ft2build_h" "$ac_includes_default"
27588if test "x$ac_cv_header_ft2build_h" = xyes; then :
27589 cat >>confdefs.h <<_ACEOF
27590#define HAVE_FT2BUILD_H 1
27591_ACEOF
27592
27593else
27594 grub_build_mkfont_excuse="need freetype2 headers"
27595fi
27596
27597done
27598
27599 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27600/* end confdefs.h. */
27601
27602/* Override any GCC internal prototype to avoid an error.
27603 Use char because int might match the return type of a GCC
27604 builtin and then its argument prototype would still apply. */
27605#ifdef __cplusplus
27606extern "C"
27607#endif
27608char FT_Load_Glyph ();
27609int
27610main (void)
27611{
27612return FT_Load_Glyph ();
27613 ;
27614 return 0;
27615}
27616_ACEOF
27617if ac_fn_c_try_link "$LINENO"; then :
27618
27619else
27620 grub_build_mkfont_excuse="freetype2 library unusable"
27621fi
27622rm -f core conftest.err conftest.$ac_objext \
27623 conftest$ac_exeext conftest.$ac_ext
27624 LIBS="$SAVED_LIBS"
27625 CPPFLAGS="$SAVED_CPPFLAGS_2"
27626fi
27627
27628if test x"$enable_build_grub_mkfont" = xyes && test x"$grub_build_mkfont_excuse" != x ; then
27629 as_fn_error $? "build-grub-mkfont was explicitly requested but can't be compiled ($grub_build_mkfont_excuse)" "$LINENO" 5
27630fi
27631if test x"$grub_build_mkfont_excuse" = x ; then
27632 enable_build_grub_mkfont=yes
27633else
27634 enable_build_grub_mkfont=no
27635fi
27636if test x"$enable_build_grub_mkfont" = xno && ( test "x$platform" = xqemu || test "x$platform" = xloongson || test "x$platform" = xqemu_mips || test "x$platform" = xcoreboot ); then
27637 if test x"$grub_build_mkfont_excuse" = x ; then
27638 as_fn_error $? "qemu, coreboot and loongson ports need build-time grub-mkfont" "$LINENO" 5
27639 else
27640 as_fn_error $? "qemu, coreboot and loongson ports need build-time grub-mkfont ($grub_build_mkfont_excuse)" "$LINENO" 5
27641 fi
27642fi
27643
27644
27645
27646
27647CC="$SAVED_CC"
27648CPP="$SAVED_CPP"
27649CFLAGS="$SAVED_CFLAGS"
27650CPPFLAGS="$SAVED_CPPFLAGS"
27651LDFLAGS="$SAVED_LDFLAGS"
27652
27653
27654DJVU_FONT_SOURCE=
27655
27656starfield_excuse=
27657
27658# Check whether --enable-grub-themes was given.
27659if test "${enable_grub_themes+set}" = set; then :
27660 enableval=$enable_grub_themes;
27661fi
27662
27663if test x"$enable_grub_themes" = xno ; then
27664 starfield_excuse="explicitly disabled"
27665fi
27666
27667if test x"$starfield_excuse" = x && test x"$enable_build_grub_mkfont" = xno ; then
27668 starfield_excuse="No build-time grub-mkfont"
27669fi
27670
27671if test x"$starfield_excuse" = x; then
27672 for ext in pcf pcf.gz bdf bdf.gz ttf ttf.gz; do
27673 for dir in . /usr/src /usr/share/fonts/X11/misc /usr/share/fonts/truetype/ttf-dejavu /usr/share/fonts/dejavu /usr/share/fonts/truetype; do
27674 if test -f "$dir/DejaVuSans.$ext"; then
27675 DJVU_FONT_SOURCE="$dir/DejaVuSans.$ext"
27676 break 2
27677 fi
27678 done
27679 done
27680
27681 if test "x$DJVU_FONT_SOURCE" = x; then
27682 starfield_excuse="No DejaVu found"
27683 fi
27684fi
27685
27686if test x"$enable_grub_themes" = xyes && test x"$starfield_excuse" != x; then
27687 as_fn_error $? "themes were explicitly requested but requirements are not satisfied ($starfield_excuse)" "$LINENO" 5
27688fi
27689
27690
27691
27692FONT_SOURCE=
27693
27694for ext in pcf pcf.gz bdf bdf.gz ttf ttf.gz; do
27695 for dir in . /usr/src /usr/share/fonts/X11/misc /usr/share/fonts/unifont /usr/share/fonts/uni /usr/share/fonts/truetype/unifont /usr/share/fonts/misc; do
27696 if test -f "$dir/unifont.$ext"; then
27697 md5="$(md5sum "$dir/unifont.$ext"|awk '{ print $1; }')"
27698 # PCF and BDF from version 6.3 isn't hanled properly by libfreetype.
27699 if test "$md5" = 0a54834d2788c83886a3e1785a6a1e61 || test "$md5" = 28f2565c7a41d8d407e2551159385edb || test "$md5" = dae5e588461b3b92b87b6ffee734f936 || test "$md5" = 4a3d687aa5bb329ed05f4263a1016791 ; then
27700 continue
27701 fi
27702 FONT_SOURCE="$dir/unifont.$ext"
27703 break 2
27704 fi
27705 done
27706done
27707
27708if test x"$enable_build_grub_mkfont" = xno ; then
27709 FONT_SOURCE=
27710fi
27711
27712if test "x$FONT_SOURCE" = x && ( test "x$platform" = xqemu || test "x$platform" = xloongson || test "x$platform" = xqemu_mips || test "x$platform" = xcoreboot ); then
27713 if test x"$grub_build_mkfont_excuse" = x ; then
27714 as_fn_error $? "qemu, coreboot and loongson ports need unifont" "$LINENO" 5
27715 else
27716 as_fn_error $? "qemu, coreboot and loongson ports need unifont ($grub_build_mkfont_excuse)" "$LINENO" 5
27717 fi
27718fi
27719
27720
27721
27722if test x"$FONT_SOURCE" = x && test x"$DJVU_FONT_SOURCE" = x && test x"$grub_build_mkfont_excuse" = x; then
27723 grub_build_mkfont_excuse="no fonts"
27724fi
27725
27726
27727# Check whether --enable-grub-mount was given.
27728if test "${enable_grub_mount+set}" = set; then :
27729 enableval=$enable_grub_mount;
27730fi
27731
27732if test x"$enable_grub_mount" = xno ; then
27733 grub_mount_excuse="explicitly disabled"
27734fi
27735
27736if test x"$grub_mount_excuse" = x ; then
27737 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fuse_main_real in -lfuse" >&5
27738$as_echo_n "checking for fuse_main_real in -lfuse... " >&6; }
27739if ${ac_cv_lib_fuse_fuse_main_real+:} false; then :
27740 $as_echo_n "(cached) " >&6
27741else
27742 ac_check_lib_save_LIBS=$LIBS
27743LIBS="-lfuse $LIBS"
27744cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27745/* end confdefs.h. */
27746
27747/* Override any GCC internal prototype to avoid an error.
27748 Use char because int might match the return type of a GCC
27749 builtin and then its argument prototype would still apply. */
27750#ifdef __cplusplus
27751extern "C"
27752#endif
27753char fuse_main_real ();
27754int
27755main (void)
27756{
27757return fuse_main_real ();
27758 ;
27759 return 0;
27760}
27761_ACEOF
27762if ac_fn_c_try_link "$LINENO"; then :
27763 ac_cv_lib_fuse_fuse_main_real=yes
27764else
27765 ac_cv_lib_fuse_fuse_main_real=no
27766fi
27767rm -f core conftest.err conftest.$ac_objext \
27768 conftest$ac_exeext conftest.$ac_ext
27769LIBS=$ac_check_lib_save_LIBS
27770fi
27771{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fuse_fuse_main_real" >&5
27772$as_echo "$ac_cv_lib_fuse_fuse_main_real" >&6; }
27773if test "x$ac_cv_lib_fuse_fuse_main_real" = xyes; then :
27774 cat >>confdefs.h <<_ACEOF
27775#define HAVE_LIBFUSE 1
27776_ACEOF
27777
27778 LIBS="-lfuse $LIBS"
27779
27780else
27781 grub_mount_excuse="need FUSE library"
27782fi
27783
27784fi
27785
27786if test x"$grub_mount_excuse" = x ; then
27787 # Check for fuse headers.
27788 SAVED_CPPFLAGS="$CPPFLAGS"
27789 CPPFLAGS="$CPPFLAGS -DFUSE_USE_VERSION=26"
27790 for ac_header in fuse/fuse.h
27791do :
27792 ac_fn_c_check_header_mongrel "$LINENO" "fuse/fuse.h" "ac_cv_header_fuse_fuse_h" "$ac_includes_default"
27793if test "x$ac_cv_header_fuse_fuse_h" = xyes; then :
27794 cat >>confdefs.h <<_ACEOF
27795#define HAVE_FUSE_FUSE_H 1
27796_ACEOF
27797
27798else
27799 grub_mount_excuse="need FUSE headers"
27800fi
27801
27802done
27803
27804 CPPFLAGS="$SAVED_CPPFLAGS"
27805fi
27806
27807if test x"$enable_grub_mount" = xyes && test x"$grub_mount_excuse" != x ; then
27808 as_fn_error $? "grub-mount was explicitly requested but can't be compiled ($grub_mount_excuse)" "$LINENO" 5
27809fi
27810if test x"$grub_mount_excuse" = x ; then
27811enable_grub_mount=yes
27812else
27813enable_grub_mount=no
27814fi
27815
27816
27817# Check whether --enable-device-mapper was given.
27818if test "${enable_device_mapper+set}" = set; then :
27819 enableval=$enable_device_mapper;
27820fi
27821
27822if test x"$enable_device_mapper" = xno ; then
27823 device_mapper_excuse="explicitly disabled"
27824fi
27825
27826if test x"$device_mapper_excuse" = x ; then
27827 # Check for device-mapper header.
27828 ac_fn_c_check_header_mongrel "$LINENO" "libdevmapper.h" "ac_cv_header_libdevmapper_h" "$ac_includes_default"
27829if test "x$ac_cv_header_libdevmapper_h" = xyes; then :
27830
27831else
27832 device_mapper_excuse="need libdevmapper header"
27833fi
27834
27835
27836fi
27837
27838if test x"$device_mapper_excuse" = x ; then
27839 # Check for device-mapper library.
27840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dm_task_create in -ldevmapper" >&5
27841$as_echo_n "checking for dm_task_create in -ldevmapper... " >&6; }
27842if ${ac_cv_lib_devmapper_dm_task_create+:} false; then :
27843 $as_echo_n "(cached) " >&6
27844else
27845 ac_check_lib_save_LIBS=$LIBS
27846LIBS="-ldevmapper $LIBS"
27847cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27848/* end confdefs.h. */
27849
27850/* Override any GCC internal prototype to avoid an error.
27851 Use char because int might match the return type of a GCC
27852 builtin and then its argument prototype would still apply. */
27853#ifdef __cplusplus
27854extern "C"
27855#endif
27856char dm_task_create ();
27857int
27858main (void)
27859{
27860return dm_task_create ();
27861 ;
27862 return 0;
27863}
27864_ACEOF
27865if ac_fn_c_try_link "$LINENO"; then :
27866 ac_cv_lib_devmapper_dm_task_create=yes
27867else
27868 ac_cv_lib_devmapper_dm_task_create=no
27869fi
27870rm -f core conftest.err conftest.$ac_objext \
27871 conftest$ac_exeext conftest.$ac_ext
27872LIBS=$ac_check_lib_save_LIBS
27873fi
27874{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_devmapper_dm_task_create" >&5
27875$as_echo "$ac_cv_lib_devmapper_dm_task_create" >&6; }
27876if test "x$ac_cv_lib_devmapper_dm_task_create" = xyes; then :
27877 cat >>confdefs.h <<_ACEOF
27878#define HAVE_LIBDEVMAPPER 1
27879_ACEOF
27880
27881 LIBS="-ldevmapper $LIBS"
27882
27883else
27884 device_mapper_excuse="need devmapper library"
27885fi
27886
27887fi
27888
27889if test x"$device_mapper_excuse" = x ; then
27890 # Check for device-mapper library.
27891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dm_log_with_errno_init in -ldevmapper" >&5
27892$as_echo_n "checking for dm_log_with_errno_init in -ldevmapper... " >&6; }
27893if ${ac_cv_lib_devmapper_dm_log_with_errno_init+:} false; then :
27894 $as_echo_n "(cached) " >&6
27895else
27896 ac_check_lib_save_LIBS=$LIBS
27897LIBS="-ldevmapper $LIBS"
27898cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27899/* end confdefs.h. */
27900
27901/* Override any GCC internal prototype to avoid an error.
27902 Use char because int might match the return type of a GCC
27903 builtin and then its argument prototype would still apply. */
27904#ifdef __cplusplus
27905extern "C"
27906#endif
27907char dm_log_with_errno_init ();
27908int
27909main (void)
27910{
27911return dm_log_with_errno_init ();
27912 ;
27913 return 0;
27914}
27915_ACEOF
27916if ac_fn_c_try_link "$LINENO"; then :
27917 ac_cv_lib_devmapper_dm_log_with_errno_init=yes
27918else
27919 ac_cv_lib_devmapper_dm_log_with_errno_init=no
27920fi
27921rm -f core conftest.err conftest.$ac_objext \
27922 conftest$ac_exeext conftest.$ac_ext
27923LIBS=$ac_check_lib_save_LIBS
27924fi
27925{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_devmapper_dm_log_with_errno_init" >&5
27926$as_echo "$ac_cv_lib_devmapper_dm_log_with_errno_init" >&6; }
27927if test "x$ac_cv_lib_devmapper_dm_log_with_errno_init" = xyes; then :
27928 cat >>confdefs.h <<_ACEOF
27929#define HAVE_LIBDEVMAPPER 1
27930_ACEOF
27931
27932 LIBS="-ldevmapper $LIBS"
27933
27934else
27935 device_mapper_excuse="need devmapper library"
27936fi
27937
27938fi
27939
27940if test x"$device_mapper_excuse" = x ; then
27941 LIBDEVMAPPER="-ldevmapper"
27942
27943$as_echo "#define HAVE_DEVICE_MAPPER 1" >>confdefs.h
27944
27945fi
27946
27947
27948
27949LIBGEOM=
27950if test x$host_kernel = xkfreebsd; then
27951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for geom_gettree in -lgeom" >&5
27952$as_echo_n "checking for geom_gettree in -lgeom... " >&6; }
27953if ${ac_cv_lib_geom_geom_gettree+:} false; then :
27954 $as_echo_n "(cached) " >&6
27955else
27956 ac_check_lib_save_LIBS=$LIBS
27957LIBS="-lgeom $LIBS"
27958cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27959/* end confdefs.h. */
27960
27961/* Override any GCC internal prototype to avoid an error.
27962 Use char because int might match the return type of a GCC
27963 builtin and then its argument prototype would still apply. */
27964#ifdef __cplusplus
27965extern "C"
27966#endif
27967char geom_gettree ();
27968int
27969main (void)
27970{
27971return geom_gettree ();
27972 ;
27973 return 0;
27974}
27975_ACEOF
27976if ac_fn_c_try_link "$LINENO"; then :
27977 ac_cv_lib_geom_geom_gettree=yes
27978else
27979 ac_cv_lib_geom_geom_gettree=no
27980fi
27981rm -f core conftest.err conftest.$ac_objext \
27982 conftest$ac_exeext conftest.$ac_ext
27983LIBS=$ac_check_lib_save_LIBS
27984fi
27985{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_geom_geom_gettree" >&5
27986$as_echo "$ac_cv_lib_geom_geom_gettree" >&6; }
27987if test "x$ac_cv_lib_geom_geom_gettree" = xyes; then :
27988 cat >>confdefs.h <<_ACEOF
27989#define HAVE_LIBGEOM 1
27990_ACEOF
27991
27992 LIBS="-lgeom $LIBS"
27993
27994else
27995 as_fn_error $? "Your platform requires libgeom" "$LINENO" 5
27996fi
27997
27998 LIBGEOM="-lgeom"
27999fi
28000
28001
28002
28003# Check whether --enable-liblzma was given.
28004if test "${enable_liblzma+set}" = set; then :
28005 enableval=$enable_liblzma;
28006fi
28007
28008if test x"$enable_liblzma" = xno ; then
28009 liblzma_excuse="explicitly disabled"
28010fi
28011
28012if test x"$liblzma_excuse" = x ; then
28013{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for lzma_code in -llzma" >&5
28014$as_echo_n "checking for lzma_code in -llzma... " >&6; }
28015if ${ac_cv_lib_lzma_lzma_code+:} false; then :
28016 $as_echo_n "(cached) " >&6
28017else
28018 ac_check_lib_save_LIBS=$LIBS
28019LIBS="-llzma $LIBS"
28020cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28021/* end confdefs.h. */
28022
28023/* Override any GCC internal prototype to avoid an error.
28024 Use char because int might match the return type of a GCC
28025 builtin and then its argument prototype would still apply. */
28026#ifdef __cplusplus
28027extern "C"
28028#endif
28029char lzma_code ();
28030int
28031main (void)
28032{
28033return lzma_code ();
28034 ;
28035 return 0;
28036}
28037_ACEOF
28038if ac_fn_c_try_link "$LINENO"; then :
28039 ac_cv_lib_lzma_lzma_code=yes
28040else
28041 ac_cv_lib_lzma_lzma_code=no
28042fi
28043rm -f core conftest.err conftest.$ac_objext \
28044 conftest$ac_exeext conftest.$ac_ext
28045LIBS=$ac_check_lib_save_LIBS
28046fi
28047{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lzma_lzma_code" >&5
28048$as_echo "$ac_cv_lib_lzma_lzma_code" >&6; }
28049if test "x$ac_cv_lib_lzma_lzma_code" = xyes; then :
28050 cat >>confdefs.h <<_ACEOF
28051#define HAVE_LIBLZMA 1
28052_ACEOF
28053
28054 LIBS="-llzma $LIBS"
28055
28056else
28057 liblzma_excuse="need lzma library"
28058fi
28059
28060fi
28061if test x"$liblzma_excuse" = x ; then
28062ac_fn_c_check_header_mongrel "$LINENO" "lzma.h" "ac_cv_header_lzma_h" "$ac_includes_default"
28063if test "x$ac_cv_header_lzma_h" = xyes; then :
28064
28065else
28066 liblzma_excuse="need lzma header"
28067fi
28068
28069
28070fi
28071
28072if test x"$enable_liblzma" = xyes && test x"$liblzma_excuse" != x ; then
28073 as_fn_error $? "liblzma support was explicitly requested but requirements are not satisfied ($liblzma_excuse)" "$LINENO" 5
28074fi
28075
28076
28077if test x"$liblzma_excuse" = x ; then
28078 LIBLZMA="-llzma"
28079
28080$as_echo "#define USE_LIBLZMA 1" >>confdefs.h
28081
28082fi
28083
28084
28085
28086# Check whether --enable-libzfs was given.
28087if test "${enable_libzfs+set}" = set; then :
28088 enableval=$enable_libzfs;
28089fi
28090
28091if test x"$enable_libzfs" = xno ; then
28092 libzfs_excuse="explicitly disabled"
28093fi
28094
28095if test x"$libzfs_excuse" = x ; then
28096 # Only check for system headers if libzfs support has not been disabled.
28097 for ac_header in libzfs.h libnvpair.h
28098do :
28099 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
28100ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
28101if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
28102 cat >>confdefs.h <<_ACEOF
28103#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
28104_ACEOF
28105
28106fi
28107
28108done
28109
28110fi
28111
28112if test x"$libzfs_excuse" = x ; then
28113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libzfs_init in -lzfs" >&5
28114$as_echo_n "checking for libzfs_init in -lzfs... " >&6; }
28115if ${ac_cv_lib_zfs_libzfs_init+:} false; then :
28116 $as_echo_n "(cached) " >&6
28117else
28118 ac_check_lib_save_LIBS=$LIBS
28119LIBS="-lzfs $LIBS"
28120cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28121/* end confdefs.h. */
28122
28123/* Override any GCC internal prototype to avoid an error.
28124 Use char because int might match the return type of a GCC
28125 builtin and then its argument prototype would still apply. */
28126#ifdef __cplusplus
28127extern "C"
28128#endif
28129char libzfs_init ();
28130int
28131main (void)
28132{
28133return libzfs_init ();
28134 ;
28135 return 0;
28136}
28137_ACEOF
28138if ac_fn_c_try_link "$LINENO"; then :
28139 ac_cv_lib_zfs_libzfs_init=yes
28140else
28141 ac_cv_lib_zfs_libzfs_init=no
28142fi
28143rm -f core conftest.err conftest.$ac_objext \
28144 conftest$ac_exeext conftest.$ac_ext
28145LIBS=$ac_check_lib_save_LIBS
28146fi
28147{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_zfs_libzfs_init" >&5
28148$as_echo "$ac_cv_lib_zfs_libzfs_init" >&6; }
28149if test "x$ac_cv_lib_zfs_libzfs_init" = xyes; then :
28150 cat >>confdefs.h <<_ACEOF
28151#define HAVE_LIBZFS 1
28152_ACEOF
28153
28154 LIBS="-lzfs $LIBS"
28155
28156else
28157 libzfs_excuse="need zfs library"
28158fi
28159
28160fi
28161
28162if test x"$libzfs_excuse" = x ; then
28163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nvlist_lookup_string in -lnvpair" >&5
28164$as_echo_n "checking for nvlist_lookup_string in -lnvpair... " >&6; }
28165if ${ac_cv_lib_nvpair_nvlist_lookup_string+:} false; then :
28166 $as_echo_n "(cached) " >&6
28167else
28168 ac_check_lib_save_LIBS=$LIBS
28169LIBS="-lnvpair $LIBS"
28170cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28171/* end confdefs.h. */
28172
28173/* Override any GCC internal prototype to avoid an error.
28174 Use char because int might match the return type of a GCC
28175 builtin and then its argument prototype would still apply. */
28176#ifdef __cplusplus
28177extern "C"
28178#endif
28179char nvlist_lookup_string ();
28180int
28181main (void)
28182{
28183return nvlist_lookup_string ();
28184 ;
28185 return 0;
28186}
28187_ACEOF
28188if ac_fn_c_try_link "$LINENO"; then :
28189 ac_cv_lib_nvpair_nvlist_lookup_string=yes
28190else
28191 ac_cv_lib_nvpair_nvlist_lookup_string=no
28192fi
28193rm -f core conftest.err conftest.$ac_objext \
28194 conftest$ac_exeext conftest.$ac_ext
28195LIBS=$ac_check_lib_save_LIBS
28196fi
28197{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nvpair_nvlist_lookup_string" >&5
28198$as_echo "$ac_cv_lib_nvpair_nvlist_lookup_string" >&6; }
28199if test "x$ac_cv_lib_nvpair_nvlist_lookup_string" = xyes; then :
28200 cat >>confdefs.h <<_ACEOF
28201#define HAVE_LIBNVPAIR 1
28202_ACEOF
28203
28204 LIBS="-lnvpair $LIBS"
28205
28206else
28207 libzfs_excuse="need nvpair library"
28208fi
28209
28210fi
28211
28212if test x"$enable_libzfs" = xyes && test x"$libzfs_excuse" != x ; then
28213 as_fn_error $? "libzfs support was explicitly requested but requirements are not satisfied ($libzfs_excuse)" "$LINENO" 5
28214fi
28215
28216if test x"$libzfs_excuse" = x ; then
28217 # We need both libzfs and libnvpair for a successful build.
28218 LIBZFS="-lzfs"
28219
28220$as_echo "#define HAVE_LIBZFS 1" >>confdefs.h
28221
28222 LIBNVPAIR="-lnvpair"
28223
28224$as_echo "#define HAVE_LIBNVPAIR 1" >>confdefs.h
28225
28226fi
28227
28228
28229
28230
28231LIBS=""
28232
28233
28234if test x$target_cpu = xi386 -a x$platform = xqemu; then :
28235 GRUB_BOOT_MACHINE_LINK_ADDR=0xffe00
28236
28237fi
28238
28239
28240
28241
28242
28243
28244
28245# Check whether --enable-werror was given.
28246if test "${enable_werror+set}" = set; then :
28247 enableval=$enable_werror;
28248fi
28249
28250if test x"$enable_werror" != xno ; then
28251 TARGET_CFLAGS="$TARGET_CFLAGS -Werror"
28252 HOST_CFLAGS="$HOST_CFLAGS -Werror"
28253fi
28254
28255TARGET_CPP="$TARGET_CC -E"
28256TARGET_CCAS=$TARGET_CC
28257
28258# Includes which include make-time substitutions. They must come last
28259# as to avoid executing top_builddir in shell.
28260HOST_CPPFLAGS="$HOST_CPPFLAGS -I\$(top_builddir)/include"
28261TARGET_CPPFLAGS="$TARGET_CPPFLAGS -I\$(top_srcdir)/include"
28262TARGET_CPPFLAGS="$TARGET_CPPFLAGS -I\$(top_builddir)/include"
28263
28264GRUB_TARGET_CPU="${target_cpu}"
28265GRUB_PLATFORM="${platform}"
28266
28267
28268
28269
28270
28271
28272
28273
28274
28275
28276
28277
28278
28279
28280
28281
28282
28283
28284
28285
28286
28287
28288
28289
28290
28291
28292
28293
28294#
28295# Automake conditionals
28296#
28297
28298 if test x$platform != xnone; then
28299 COND_real_platform_TRUE=
28300 COND_real_platform_FALSE='#'
28301else
28302 COND_real_platform_TRUE='#'
28303 COND_real_platform_FALSE=
28304fi
28305
28306 if test x$platform = xemu; then
28307 COND_emu_TRUE=
28308 COND_emu_FALSE='#'
28309else
28310 COND_emu_TRUE='#'
28311 COND_emu_FALSE=
28312fi
28313
28314 if test x$target_cpu = xi386 -a x$platform = xpc; then
28315 COND_i386_pc_TRUE=
28316 COND_i386_pc_FALSE='#'
28317else
28318 COND_i386_pc_TRUE='#'
28319 COND_i386_pc_FALSE=
28320fi
28321
28322 if test x$target_cpu = xi386 -a x$platform = xefi; then
28323 COND_i386_efi_TRUE=
28324 COND_i386_efi_FALSE='#'
28325else
28326 COND_i386_efi_TRUE='#'
28327 COND_i386_efi_FALSE=
28328fi
28329
28330 if test x$target_cpu = xia64 -a x$platform = xefi; then
28331 COND_ia64_efi_TRUE=
28332 COND_ia64_efi_FALSE='#'
28333else
28334 COND_ia64_efi_TRUE='#'
28335 COND_ia64_efi_FALSE=
28336fi
28337
28338 if test x$target_cpu = xi386 -a x$platform = xqemu; then
28339 COND_i386_qemu_TRUE=
28340 COND_i386_qemu_FALSE='#'
28341else
28342 COND_i386_qemu_TRUE='#'
28343 COND_i386_qemu_FALSE=
28344fi
28345
28346 if test x$target_cpu = xi386 -a x$platform = xieee1275; then
28347 COND_i386_ieee1275_TRUE=
28348 COND_i386_ieee1275_FALSE='#'
28349else
28350 COND_i386_ieee1275_TRUE='#'
28351 COND_i386_ieee1275_FALSE=
28352fi
28353
28354 if test x$target_cpu = xi386 -a x$platform = xcoreboot; then
28355 COND_i386_coreboot_TRUE=
28356 COND_i386_coreboot_FALSE='#'
28357else
28358 COND_i386_coreboot_TRUE='#'
28359 COND_i386_coreboot_FALSE=
28360fi
28361
28362 if test x$target_cpu = xi386 -a x$platform = xmultiboot; then
28363 COND_i386_multiboot_TRUE=
28364 COND_i386_multiboot_FALSE='#'
28365else
28366 COND_i386_multiboot_TRUE='#'
28367 COND_i386_multiboot_FALSE=
28368fi
28369
28370 if test x$target_cpu = xx86_64 -a x$platform = xefi; then
28371 COND_x86_64_efi_TRUE=
28372 COND_x86_64_efi_FALSE='#'
28373else
28374 COND_x86_64_efi_TRUE='#'
28375 COND_x86_64_efi_FALSE=
28376fi
28377
28378 if test x$target_cpu = xi386 -a x$platform = xxen; then
28379 COND_i386_xen_TRUE=
28380 COND_i386_xen_FALSE='#'
28381else
28382 COND_i386_xen_TRUE='#'
28383 COND_i386_xen_FALSE=
28384fi
28385
28386 if test x$target_cpu = xx86_64 -a x$platform = xxen; then
28387 COND_x86_64_xen_TRUE=
28388 COND_x86_64_xen_FALSE='#'
28389else
28390 COND_x86_64_xen_TRUE='#'
28391 COND_x86_64_xen_FALSE=
28392fi
28393
28394 if test x$target_cpu = xmipsel -a x$platform = xloongson; then
28395 COND_mips_loongson_TRUE=
28396 COND_mips_loongson_FALSE='#'
28397else
28398 COND_mips_loongson_TRUE='#'
28399 COND_mips_loongson_FALSE=
28400fi
28401
28402 if test "(" x$target_cpu = xmips -o x$target_cpu = xmipsel ")" -a x$platform = xqemu_mips; then
28403 COND_mips_qemu_mips_TRUE=
28404 COND_mips_qemu_mips_FALSE='#'
28405else
28406 COND_mips_qemu_mips_TRUE='#'
28407 COND_mips_qemu_mips_FALSE=
28408fi
28409
28410 if test "(" x$target_cpu = xmips -o x$target_cpu = xmipsel ")" -a x$platform = xarc; then
28411 COND_mips_arc_TRUE=
28412 COND_mips_arc_FALSE='#'
28413else
28414 COND_mips_arc_TRUE='#'
28415 COND_mips_arc_FALSE=
28416fi
28417
28418 if test x$target_cpu = xsparc64 -a x$platform = xieee1275; then
28419 COND_sparc64_ieee1275_TRUE=
28420 COND_sparc64_ieee1275_FALSE='#'
28421else
28422 COND_sparc64_ieee1275_TRUE='#'
28423 COND_sparc64_ieee1275_FALSE=
28424fi
28425
28426 if test x$target_cpu = xsparc64 -a x$platform = xemu; then
28427 COND_sparc64_emu_TRUE=
28428 COND_sparc64_emu_FALSE='#'
28429else
28430 COND_sparc64_emu_TRUE='#'
28431 COND_sparc64_emu_FALSE=
28432fi
28433
28434 if test x$target_cpu = xpowerpc -a x$platform = xieee1275; then
28435 COND_powerpc_ieee1275_TRUE=
28436 COND_powerpc_ieee1275_FALSE='#'
28437else
28438 COND_powerpc_ieee1275_TRUE='#'
28439 COND_powerpc_ieee1275_FALSE=
28440fi
28441
28442 if test x$target_cpu = xmips -o x$target_cpu = xmipsel; then
28443 COND_mips_TRUE=
28444 COND_mips_FALSE='#'
28445else
28446 COND_mips_TRUE='#'
28447 COND_mips_FALSE=
28448fi
28449
28450 if test x$target_cpu = xmipsel; then
28451 COND_mipsel_TRUE=
28452 COND_mipsel_FALSE='#'
28453else
28454 COND_mipsel_TRUE='#'
28455 COND_mipsel_FALSE=
28456fi
28457
28458 if test x$target_cpu = xmips; then
28459 COND_mipseb_TRUE=
28460 COND_mipseb_FALSE='#'
28461else
28462 COND_mipseb_TRUE='#'
28463 COND_mipseb_FALSE=
28464fi
28465
28466 if test x$target_cpu = xarm ; then
28467 COND_arm_TRUE=
28468 COND_arm_FALSE='#'
28469else
28470 COND_arm_TRUE='#'
28471 COND_arm_FALSE=
28472fi
28473
28474 if test x$target_cpu = xarm -a x$platform = xuboot; then
28475 COND_arm_uboot_TRUE=
28476 COND_arm_uboot_FALSE='#'
28477else
28478 COND_arm_uboot_TRUE='#'
28479 COND_arm_uboot_FALSE=
28480fi
28481
28482 if test x$target_cpu = xarm -a x$platform = xefi; then
28483 COND_arm_efi_TRUE=
28484 COND_arm_efi_FALSE='#'
28485else
28486 COND_arm_efi_TRUE='#'
28487 COND_arm_efi_FALSE=
28488fi
28489
28490 if test x$target_cpu = xarm64 ; then
28491 COND_arm64_TRUE=
28492 COND_arm64_FALSE='#'
28493else
28494 COND_arm64_TRUE='#'
28495 COND_arm64_FALSE=
28496fi
28497
28498 if test x$target_cpu = xarm64 -a x$platform = xefi; then
28499 COND_arm64_efi_TRUE=
28500 COND_arm64_efi_FALSE='#'
28501else
28502 COND_arm64_efi_TRUE='#'
28503 COND_arm64_efi_FALSE=
28504fi
28505
28506
28507 if test x$host_kernel = xhurd; then
28508 COND_HOST_HURD_TRUE=
28509 COND_HOST_HURD_FALSE='#'
28510else
28511 COND_HOST_HURD_TRUE='#'
28512 COND_HOST_HURD_FALSE=
28513fi
28514
28515 if test x$host_kernel = xlinux; then
28516 COND_HOST_LINUX_TRUE=
28517 COND_HOST_LINUX_FALSE='#'
28518else
28519 COND_HOST_LINUX_TRUE='#'
28520 COND_HOST_LINUX_FALSE=
28521fi
28522
28523 if test x$host_kernel = xnetbsd; then
28524 COND_HOST_NETBSD_TRUE=
28525 COND_HOST_NETBSD_FALSE='#'
28526else
28527 COND_HOST_NETBSD_TRUE='#'
28528 COND_HOST_NETBSD_FALSE=
28529fi
28530
28531 if test x$host_kernel = xwindows; then
28532 COND_HOST_WINDOWS_TRUE=
28533 COND_HOST_WINDOWS_FALSE='#'
28534else
28535 COND_HOST_WINDOWS_TRUE='#'
28536 COND_HOST_WINDOWS_FALSE=
28537fi
28538
28539 if test x$host_kernel = xkfreebsd; then
28540 COND_HOST_KFREEBSD_TRUE=
28541 COND_HOST_KFREEBSD_FALSE='#'
28542else
28543 COND_HOST_KFREEBSD_TRUE='#'
28544 COND_HOST_KFREEBSD_FALSE=
28545fi
28546
28547 if test x$host_kernel = xxnu; then
28548 COND_HOST_XNU_TRUE=
28549 COND_HOST_XNU_FALSE='#'
28550else
28551 COND_HOST_XNU_TRUE='#'
28552 COND_HOST_XNU_FALSE=
28553fi
28554
28555 if test x$host_kernel = xillumos; then
28556 COND_HOST_ILLUMOS_TRUE=
28557 COND_HOST_ILLUMOS_FALSE='#'
28558else
28559 COND_HOST_ILLUMOS_TRUE='#'
28560 COND_HOST_ILLUMOS_FALSE=
28561fi
28562
28563
28564 if test x$cross_compiling = xno -a x$HELP2MAN != x; then
28565 COND_MAN_PAGES_TRUE=
28566 COND_MAN_PAGES_FALSE='#'
28567else
28568 COND_MAN_PAGES_TRUE='#'
28569 COND_MAN_PAGES_FALSE=
28570fi
28571
28572 if test x$enable_grub_emu_sdl = xyes; then
28573 COND_GRUB_EMU_SDL_TRUE=
28574 COND_GRUB_EMU_SDL_FALSE='#'
28575else
28576 COND_GRUB_EMU_SDL_TRUE='#'
28577 COND_GRUB_EMU_SDL_FALSE=
28578fi
28579
28580 if test x$enable_grub_emu_pci = xyes; then
28581 COND_GRUB_EMU_PCI_TRUE=
28582 COND_GRUB_EMU_PCI_FALSE='#'
28583else
28584 COND_GRUB_EMU_PCI_TRUE='#'
28585 COND_GRUB_EMU_PCI_FALSE=
28586fi
28587
28588 if test x$enable_grub_mkfont = xyes; then
28589 COND_GRUB_MKFONT_TRUE=
28590 COND_GRUB_MKFONT_FALSE='#'
28591else
28592 COND_GRUB_MKFONT_TRUE='#'
28593 COND_GRUB_MKFONT_FALSE=
28594fi
28595
28596 if test x$enable_grub_mount = xyes; then
28597 COND_GRUB_MOUNT_TRUE=
28598 COND_GRUB_MOUNT_FALSE='#'
28599else
28600 COND_GRUB_MOUNT_TRUE='#'
28601 COND_GRUB_MOUNT_FALSE=
28602fi
28603
28604 if test x$FONT_SOURCE != x; then
28605 COND_HAVE_FONT_SOURCE_TRUE=
28606 COND_HAVE_FONT_SOURCE_FALSE='#'
28607else
28608 COND_HAVE_FONT_SOURCE_TRUE='#'
28609 COND_HAVE_FONT_SOURCE_FALSE=
28610fi
28611
28612if test x$FONT_SOURCE != x ; then
28613 HAVE_FONT_SOURCE=1
28614else
28615 HAVE_FONT_SOURCE=0
28616fi
28617
28618 if test x$TARGET_APPLE_LINKER = x1; then
28619 COND_APPLE_LINKER_TRUE=
28620 COND_APPLE_LINKER_FALSE='#'
28621else
28622 COND_APPLE_LINKER_TRUE='#'
28623 COND_APPLE_LINKER_FALSE=
28624fi
28625
28626 if test x$enable_efiemu = xyes; then
28627 COND_ENABLE_EFIEMU_TRUE=
28628 COND_ENABLE_EFIEMU_FALSE='#'
28629else
28630 COND_ENABLE_EFIEMU_TRUE='#'
28631 COND_ENABLE_EFIEMU_FALSE=
28632fi
28633
28634 if test x$DISK_CACHE_STATS = x1; then
28635 COND_ENABLE_CACHE_STATS_TRUE=
28636 COND_ENABLE_CACHE_STATS_FALSE='#'
28637else
28638 COND_ENABLE_CACHE_STATS_TRUE='#'
28639 COND_ENABLE_CACHE_STATS_FALSE=
28640fi
28641
28642 if test x$BOOT_TIME_STATS = x1; then
28643 COND_ENABLE_BOOT_TIME_STATS_TRUE=
28644 COND_ENABLE_BOOT_TIME_STATS_FALSE='#'
28645else
28646 COND_ENABLE_BOOT_TIME_STATS_TRUE='#'
28647 COND_ENABLE_BOOT_TIME_STATS_FALSE=
28648fi
28649
28650
28651 if test x$HAVE_CXX = xyes; then
28652 COND_HAVE_CXX_TRUE=
28653 COND_HAVE_CXX_FALSE='#'
28654else
28655 COND_HAVE_CXX_TRUE='#'
28656 COND_HAVE_CXX_FALSE=
28657fi
28658
28659
28660 if test x$HAVE_ASM_USCORE = x1; then
28661 COND_HAVE_ASM_USCORE_TRUE=
28662 COND_HAVE_ASM_USCORE_FALSE='#'
28663else
28664 COND_HAVE_ASM_USCORE_TRUE='#'
28665 COND_HAVE_ASM_USCORE_FALSE=
28666fi
28667
28668 if test "x$starfield_excuse" = x; then
28669 COND_STARFIELD_TRUE=
28670 COND_STARFIELD_FALSE='#'
28671else
28672 COND_STARFIELD_TRUE='#'
28673 COND_STARFIELD_FALSE=
28674fi
28675
28676 if test "x$have_exec" = xy; then
28677 COND_HAVE_EXEC_TRUE=
28678 COND_HAVE_EXEC_FALSE='#'
28679else
28680 COND_HAVE_EXEC_TRUE='#'
28681 COND_HAVE_EXEC_FALSE=
28682fi
28683
28684
28685test "x$prefix" = xNONE && prefix="$ac_default_prefix"
28686test "x$exec_prefix" = xNONE && exec_prefix="${prefix}"
28687datarootdir="$(eval echo "$datarootdir")"
28688grub_libdir="$(eval echo "$libdir")"
28689grub_localedir="$(eval echo "$localedir")"
28690grub_datadir="$(eval echo "$datadir")"
28691grub_sysconfdir="$(eval echo "$sysconfdir")"
28692
28693cat >>confdefs.h <<_ACEOF
28694#define LOCALEDIR "$grub_localedir"
28695_ACEOF
28696
28697
28698cat >>confdefs.h <<_ACEOF
28699#define GRUB_LIBDIR "$grub_libdir"
28700_ACEOF
28701
28702
28703cat >>confdefs.h <<_ACEOF
28704#define GRUB_DATADIR "$grub_datadir"
28705_ACEOF
28706
28707
28708cat >>confdefs.h <<_ACEOF
28709#define GRUB_SYSCONFDIR "$grub_sysconfdir"
28710_ACEOF
28711
28712
28713
28714# Output files.
28715if test "$platform" != none; then
28716 cpudir="${target_cpu}"
28717 if test x${cpudir} = xmipsel; then
28718 cpudir=mips;
28719 fi
28720
28721{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s can handle directories properly" >&5
28722$as_echo_n "checking whether ln -s can handle directories properly... " >&6; }
28723mkdir testdir 2>/dev/null
28724case $srcdir in
28725[\\/$]* | ?:[\\/]* ) reldir=$srcdir/include/grub/util ;;
28726 *) reldir=../$srcdir/include/grub/util ;;
28727esac
28728if ln -s $reldir testdir/util 2>/dev/null && rm -f testdir/util 2>/dev/null ; then
28729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
28730$as_echo "yes" >&6; }
28731 link_dir=yes
28732else
28733 link_dir=no
28734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28735$as_echo "no" >&6; }
28736fi
28737rm -rf testdir
28738
28739 if test x"$link_dir" = xyes ; then
28740 ac_config_links="$ac_config_links include/grub/cpu:include/grub/$cpudir"
28741
28742 if test "$platform" != emu ; then
28743 ac_config_links="$ac_config_links include/grub/machine:include/grub/$cpudir/$platform"
28744
28745 fi
28746 else
28747 mkdir -p include/grub 2>/dev/null
28748 rm -rf include/grub/cpu
28749 cp -rp $srcdir/include/grub/$cpudir include/grub/cpu 2>/dev/null
28750 if test "$platform" != emu ; then
28751 rm -rf include/grub/machine
28752 cp -rp $srcdir/include/grub/$cpudir/$platform include/grub/machine 2>/dev/null
28753 fi
28754 fi
28755else
28756 # Just enough to stop the compiler failing with -I$(srcdir)/include.
28757 mkdir -p include 2>/dev/null
28758 rm -rf include/grub/cpu include/grub/machine
28759fi
28760
28761ac_config_files="$ac_config_files Makefile"
28762
28763ac_config_files="$ac_config_files grub-core/Makefile"
28764
28765ac_config_files="$ac_config_files grub-core/gnulib/Makefile"
28766
28767ac_config_files="$ac_config_files po/Makefile.in"
28768
28769ac_config_files="$ac_config_files docs/Makefile"
28770
28771ac_config_files="$ac_config_files util/bash-completion.d/Makefile"
28772
28773ac_config_files="$ac_config_files stamp-h"
28774
28775ac_config_files="$ac_config_files config.h"
28776
28777
28778cat >confcache <<\_ACEOF
28779# This file is a shell script that caches the results of configure
28780# tests run on this system so they can be shared between configure
28781# scripts and configure runs, see configure's option --config-cache.
28782# It is not useful on other systems. If it contains results you don't
28783# want to keep, you may remove or edit it.
28784#
28785# config.status only pays attention to the cache file if you give it
28786# the --recheck option to rerun configure.
28787#
28788# `ac_cv_env_foo' variables (set or unset) will be overridden when
28789# loading this file, other *unset* `ac_cv_foo' will be assigned the
28790# following values.
28791
28792_ACEOF
28793
28794# The following way of writing the cache mishandles newlines in values,
28795# but we know of no workaround that is simple, portable, and efficient.
28796# So, we kill variables containing newlines.
28797# Ultrix sh set writes to stderr and can't be redirected directly,
28798# and sets the high bit in the cache file unless we assign to the vars.
28799(
28800 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
28801 eval ac_val=\$$ac_var
28802 case $ac_val in #(
28803 *${as_nl}*)
28804 case $ac_var in #(
28805 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
28806$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
28807 esac
28808 case $ac_var in #(
28809 _ | IFS | as_nl) ;; #(
28810 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
28811 *) { eval $ac_var=; unset $ac_var;} ;;
28812 esac ;;
28813 esac
28814 done
28815
28816 (set) 2>&1 |
28817 case $as_nl`(ac_space=' '; set) 2>&1` in #(
28818 *${as_nl}ac_space=\ *)
28819 # `set' does not quote correctly, so add quotes: double-quote
28820 # substitution turns \\\\ into \\, and sed turns \\ into \.
28821 sed -n \
28822 "s/'/'\\\\''/g;
28823 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
28824 ;; #(
28825 *)
28826 # `set' quotes correctly as required by POSIX, so do not add quotes.
28827 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
28828 ;;
28829 esac |
28830 sort
28831) |
28832 sed '
28833 /^ac_cv_env_/b end
28834 t clear
28835 :clear
28836 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
28837 t end
28838 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
28839 :end' >>confcache
28840if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
28841 if test -w "$cache_file"; then
28842 if test "x$cache_file" != "x/dev/null"; then
28843 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
28844$as_echo "$as_me: updating cache $cache_file" >&6;}
28845 if test ! -f "$cache_file" || test -h "$cache_file"; then
28846 cat confcache >"$cache_file"
28847 else
28848 case $cache_file in #(
28849 */* | ?:*)
28850 mv -f confcache "$cache_file"$$ &&
28851 mv -f "$cache_file"$$ "$cache_file" ;; #(
28852 *)
28853 mv -f confcache "$cache_file" ;;
28854 esac
28855 fi
28856 fi
28857 else
28858 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
28859$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
28860 fi
28861fi
28862rm -f confcache
28863
28864test "x$prefix" = xNONE && prefix=$ac_default_prefix
28865# Let make expand exec_prefix.
28866test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
28867
28868DEFS=-DHAVE_CONFIG_H
28869
28870ac_libobjs=
28871ac_ltlibobjs=
28872U=
28873for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
28874 # 1. Remove the extension, and $U if already installed.
28875 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
28876 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
28877 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
28878 # will be set to the directory where LIBOBJS objects are built.
28879 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
28880 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
28881done
28882LIBOBJS=$ac_libobjs
28883
28884LTLIBOBJS=$ac_ltlibobjs
28885
28886
28887{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
28888$as_echo_n "checking that generated files are newer than configure... " >&6; }
28889 if test -n "$am_sleep_pid"; then
28890 # Hide warnings about reused PIDs.
28891 wait $am_sleep_pid 2>/dev/null
28892 fi
28893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
28894$as_echo "done" >&6; }
28895 if test -n "$EXEEXT"; then
28896 am__EXEEXT_TRUE=
28897 am__EXEEXT_FALSE='#'
28898else
28899 am__EXEEXT_TRUE='#'
28900 am__EXEEXT_FALSE=
28901fi
28902
28903if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
28904 as_fn_error $? "conditional \"AMDEP\" was never defined.
28905Usually this means the macro was only invoked conditionally." "$LINENO" 5
28906fi
28907if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
28908 as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
28909Usually this means the macro was only invoked conditionally." "$LINENO" 5
28910fi
28911if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
28912 as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
28913Usually this means the macro was only invoked conditionally." "$LINENO" 5
28914fi
28915if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then
28916 as_fn_error $? "conditional \"am__fastdepCXX\" was never defined.
28917Usually this means the macro was only invoked conditionally." "$LINENO" 5
28918fi
28919if test -z "${am__fastdepCCAS_TRUE}" && test -z "${am__fastdepCCAS_FALSE}"; then
28920 as_fn_error $? "conditional \"am__fastdepCCAS\" was never defined.
28921Usually this means the macro was only invoked conditionally." "$LINENO" 5
28922fi
28923
28924if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
28925 as_fn_error $? "conditional \"GL_COND_LIBTOOL\" was never defined.
28926Usually this means the macro was only invoked conditionally." "$LINENO" 5
28927fi
28928if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
28929 as_fn_error $? "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
28930Usually this means the macro was only invoked conditionally." "$LINENO" 5
28931fi
28932if test -z "${GL_GENERATE_ERRNO_H_TRUE}" && test -z "${GL_GENERATE_ERRNO_H_FALSE}"; then
28933 as_fn_error $? "conditional \"GL_GENERATE_ERRNO_H\" was never defined.
28934Usually this means the macro was only invoked conditionally." "$LINENO" 5
28935fi
28936if test -z "${GL_GENERATE_FLOAT_H_TRUE}" && test -z "${GL_GENERATE_FLOAT_H_FALSE}"; then
28937 as_fn_error $? "conditional \"GL_GENERATE_FLOAT_H\" was never defined.
28938Usually this means the macro was only invoked conditionally." "$LINENO" 5
28939fi
28940if test -z "${GL_GENERATE_FNMATCH_H_TRUE}" && test -z "${GL_GENERATE_FNMATCH_H_FALSE}"; then
28941 as_fn_error $? "conditional \"GL_GENERATE_FNMATCH_H\" was never defined.
28942Usually this means the macro was only invoked conditionally." "$LINENO" 5
28943fi
28944if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
28945 as_fn_error $? "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
28946Usually this means the macro was only invoked conditionally." "$LINENO" 5
28947fi
28948if test -z "${GL_GENERATE_STDALIGN_H_TRUE}" && test -z "${GL_GENERATE_STDALIGN_H_FALSE}"; then
28949 as_fn_error $? "conditional \"GL_GENERATE_STDALIGN_H\" was never defined.
28950Usually this means the macro was only invoked conditionally." "$LINENO" 5
28951fi
28952if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
28953 as_fn_error $? "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
28954Usually this means the macro was only invoked conditionally." "$LINENO" 5
28955fi
28956if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
28957 as_fn_error $? "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
28958Usually this means the macro was only invoked conditionally." "$LINENO" 5
28959fi
28960if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
28961 as_fn_error $? "conditional \"GL_GENERATE_STDINT_H\" was never defined.
28962Usually this means the macro was only invoked conditionally." "$LINENO" 5
28963fi
28964if test -z "${GL_GENERATE_SYSEXITS_H_TRUE}" && test -z "${GL_GENERATE_SYSEXITS_H_FALSE}"; then
28965 as_fn_error $? "conditional \"GL_GENERATE_SYSEXITS_H\" was never defined.
28966Usually this means the macro was only invoked conditionally." "$LINENO" 5
28967fi
28968if test -z "${LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_TRUE}" && test -z "${LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH_FALSE}"; then
28969 as_fn_error $? "conditional \"LIBUNISTRING_COMPILE_UNIWIDTH_WIDTH\" was never defined.
28970Usually this means the macro was only invoked conditionally." "$LINENO" 5
28971fi
28972
28973
28974 gl_libobjs=
28975 gl_ltlibobjs=
28976 if test -n "$gl_LIBOBJS"; then
28977 # Remove the extension.
28978 sed_drop_objext='s/\.o$//;s/\.obj$//'
28979 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
28980 gl_libobjs="$gl_libobjs $i.$ac_objext"
28981 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
28982 done
28983 fi
28984 gl_LIBOBJS=$gl_libobjs
28985
28986 gl_LTLIBOBJS=$gl_ltlibobjs
28987
28988
28989
28990 gltests_libobjs=
28991 gltests_ltlibobjs=
28992 if test -n "$gltests_LIBOBJS"; then
28993 # Remove the extension.
28994 sed_drop_objext='s/\.o$//;s/\.obj$//'
28995 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
28996 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
28997 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
28998 done
28999 fi
29000 gltests_LIBOBJS=$gltests_libobjs
29001
29002 gltests_LTLIBOBJS=$gltests_ltlibobjs
29003
29004
29005if test -z "${COND_real_platform_TRUE}" && test -z "${COND_real_platform_FALSE}"; then
29006 as_fn_error $? "conditional \"COND_real_platform\" was never defined.
29007Usually this means the macro was only invoked conditionally." "$LINENO" 5
29008fi
29009if test -z "${COND_emu_TRUE}" && test -z "${COND_emu_FALSE}"; then
29010 as_fn_error $? "conditional \"COND_emu\" was never defined.
29011Usually this means the macro was only invoked conditionally." "$LINENO" 5
29012fi
29013if test -z "${COND_i386_pc_TRUE}" && test -z "${COND_i386_pc_FALSE}"; then
29014 as_fn_error $? "conditional \"COND_i386_pc\" was never defined.
29015Usually this means the macro was only invoked conditionally." "$LINENO" 5
29016fi
29017if test -z "${COND_i386_efi_TRUE}" && test -z "${COND_i386_efi_FALSE}"; then
29018 as_fn_error $? "conditional \"COND_i386_efi\" was never defined.
29019Usually this means the macro was only invoked conditionally." "$LINENO" 5
29020fi
29021if test -z "${COND_ia64_efi_TRUE}" && test -z "${COND_ia64_efi_FALSE}"; then
29022 as_fn_error $? "conditional \"COND_ia64_efi\" was never defined.
29023Usually this means the macro was only invoked conditionally." "$LINENO" 5
29024fi
29025if test -z "${COND_i386_qemu_TRUE}" && test -z "${COND_i386_qemu_FALSE}"; then
29026 as_fn_error $? "conditional \"COND_i386_qemu\" was never defined.
29027Usually this means the macro was only invoked conditionally." "$LINENO" 5
29028fi
29029if test -z "${COND_i386_ieee1275_TRUE}" && test -z "${COND_i386_ieee1275_FALSE}"; then
29030 as_fn_error $? "conditional \"COND_i386_ieee1275\" was never defined.
29031Usually this means the macro was only invoked conditionally." "$LINENO" 5
29032fi
29033if test -z "${COND_i386_coreboot_TRUE}" && test -z "${COND_i386_coreboot_FALSE}"; then
29034 as_fn_error $? "conditional \"COND_i386_coreboot\" was never defined.
29035Usually this means the macro was only invoked conditionally." "$LINENO" 5
29036fi
29037if test -z "${COND_i386_multiboot_TRUE}" && test -z "${COND_i386_multiboot_FALSE}"; then
29038 as_fn_error $? "conditional \"COND_i386_multiboot\" was never defined.
29039Usually this means the macro was only invoked conditionally." "$LINENO" 5
29040fi
29041if test -z "${COND_x86_64_efi_TRUE}" && test -z "${COND_x86_64_efi_FALSE}"; then
29042 as_fn_error $? "conditional \"COND_x86_64_efi\" was never defined.
29043Usually this means the macro was only invoked conditionally." "$LINENO" 5
29044fi
29045if test -z "${COND_i386_xen_TRUE}" && test -z "${COND_i386_xen_FALSE}"; then
29046 as_fn_error $? "conditional \"COND_i386_xen\" was never defined.
29047Usually this means the macro was only invoked conditionally." "$LINENO" 5
29048fi
29049if test -z "${COND_x86_64_xen_TRUE}" && test -z "${COND_x86_64_xen_FALSE}"; then
29050 as_fn_error $? "conditional \"COND_x86_64_xen\" was never defined.
29051Usually this means the macro was only invoked conditionally." "$LINENO" 5
29052fi
29053if test -z "${COND_mips_loongson_TRUE}" && test -z "${COND_mips_loongson_FALSE}"; then
29054 as_fn_error $? "conditional \"COND_mips_loongson\" was never defined.
29055Usually this means the macro was only invoked conditionally." "$LINENO" 5
29056fi
29057if test -z "${COND_mips_qemu_mips_TRUE}" && test -z "${COND_mips_qemu_mips_FALSE}"; then
29058 as_fn_error $? "conditional \"COND_mips_qemu_mips\" was never defined.
29059Usually this means the macro was only invoked conditionally." "$LINENO" 5
29060fi
29061if test -z "${COND_mips_arc_TRUE}" && test -z "${COND_mips_arc_FALSE}"; then
29062 as_fn_error $? "conditional \"COND_mips_arc\" was never defined.
29063Usually this means the macro was only invoked conditionally." "$LINENO" 5
29064fi
29065if test -z "${COND_sparc64_ieee1275_TRUE}" && test -z "${COND_sparc64_ieee1275_FALSE}"; then
29066 as_fn_error $? "conditional \"COND_sparc64_ieee1275\" was never defined.
29067Usually this means the macro was only invoked conditionally." "$LINENO" 5
29068fi
29069if test -z "${COND_sparc64_emu_TRUE}" && test -z "${COND_sparc64_emu_FALSE}"; then
29070 as_fn_error $? "conditional \"COND_sparc64_emu\" was never defined.
29071Usually this means the macro was only invoked conditionally." "$LINENO" 5
29072fi
29073if test -z "${COND_powerpc_ieee1275_TRUE}" && test -z "${COND_powerpc_ieee1275_FALSE}"; then
29074 as_fn_error $? "conditional \"COND_powerpc_ieee1275\" was never defined.
29075Usually this means the macro was only invoked conditionally." "$LINENO" 5
29076fi
29077if test -z "${COND_mips_TRUE}" && test -z "${COND_mips_FALSE}"; then
29078 as_fn_error $? "conditional \"COND_mips\" was never defined.
29079Usually this means the macro was only invoked conditionally." "$LINENO" 5
29080fi
29081if test -z "${COND_mipsel_TRUE}" && test -z "${COND_mipsel_FALSE}"; then
29082 as_fn_error $? "conditional \"COND_mipsel\" was never defined.
29083Usually this means the macro was only invoked conditionally." "$LINENO" 5
29084fi
29085if test -z "${COND_mipseb_TRUE}" && test -z "${COND_mipseb_FALSE}"; then
29086 as_fn_error $? "conditional \"COND_mipseb\" was never defined.
29087Usually this means the macro was only invoked conditionally." "$LINENO" 5
29088fi
29089if test -z "${COND_arm_TRUE}" && test -z "${COND_arm_FALSE}"; then
29090 as_fn_error $? "conditional \"COND_arm\" was never defined.
29091Usually this means the macro was only invoked conditionally." "$LINENO" 5
29092fi
29093if test -z "${COND_arm_uboot_TRUE}" && test -z "${COND_arm_uboot_FALSE}"; then
29094 as_fn_error $? "conditional \"COND_arm_uboot\" was never defined.
29095Usually this means the macro was only invoked conditionally." "$LINENO" 5
29096fi
29097if test -z "${COND_arm_efi_TRUE}" && test -z "${COND_arm_efi_FALSE}"; then
29098 as_fn_error $? "conditional \"COND_arm_efi\" was never defined.
29099Usually this means the macro was only invoked conditionally." "$LINENO" 5
29100fi
29101if test -z "${COND_arm64_TRUE}" && test -z "${COND_arm64_FALSE}"; then
29102 as_fn_error $? "conditional \"COND_arm64\" was never defined.
29103Usually this means the macro was only invoked conditionally." "$LINENO" 5
29104fi
29105if test -z "${COND_arm64_efi_TRUE}" && test -z "${COND_arm64_efi_FALSE}"; then
29106 as_fn_error $? "conditional \"COND_arm64_efi\" was never defined.
29107Usually this means the macro was only invoked conditionally." "$LINENO" 5
29108fi
29109if test -z "${COND_HOST_HURD_TRUE}" && test -z "${COND_HOST_HURD_FALSE}"; then
29110 as_fn_error $? "conditional \"COND_HOST_HURD\" was never defined.
29111Usually this means the macro was only invoked conditionally." "$LINENO" 5
29112fi
29113if test -z "${COND_HOST_LINUX_TRUE}" && test -z "${COND_HOST_LINUX_FALSE}"; then
29114 as_fn_error $? "conditional \"COND_HOST_LINUX\" was never defined.
29115Usually this means the macro was only invoked conditionally." "$LINENO" 5
29116fi
29117if test -z "${COND_HOST_NETBSD_TRUE}" && test -z "${COND_HOST_NETBSD_FALSE}"; then
29118 as_fn_error $? "conditional \"COND_HOST_NETBSD\" was never defined.
29119Usually this means the macro was only invoked conditionally." "$LINENO" 5
29120fi
29121if test -z "${COND_HOST_WINDOWS_TRUE}" && test -z "${COND_HOST_WINDOWS_FALSE}"; then
29122 as_fn_error $? "conditional \"COND_HOST_WINDOWS\" was never defined.
29123Usually this means the macro was only invoked conditionally." "$LINENO" 5
29124fi
29125if test -z "${COND_HOST_KFREEBSD_TRUE}" && test -z "${COND_HOST_KFREEBSD_FALSE}"; then
29126 as_fn_error $? "conditional \"COND_HOST_KFREEBSD\" was never defined.
29127Usually this means the macro was only invoked conditionally." "$LINENO" 5
29128fi
29129if test -z "${COND_HOST_XNU_TRUE}" && test -z "${COND_HOST_XNU_FALSE}"; then
29130 as_fn_error $? "conditional \"COND_HOST_XNU\" was never defined.
29131Usually this means the macro was only invoked conditionally." "$LINENO" 5
29132fi
29133if test -z "${COND_HOST_ILLUMOS_TRUE}" && test -z "${COND_HOST_ILLUMOS_FALSE}"; then
29134 as_fn_error $? "conditional \"COND_HOST_ILLUMOS\" was never defined.
29135Usually this means the macro was only invoked conditionally." "$LINENO" 5
29136fi
29137if test -z "${COND_MAN_PAGES_TRUE}" && test -z "${COND_MAN_PAGES_FALSE}"; then
29138 as_fn_error $? "conditional \"COND_MAN_PAGES\" was never defined.
29139Usually this means the macro was only invoked conditionally." "$LINENO" 5
29140fi
29141if test -z "${COND_GRUB_EMU_SDL_TRUE}" && test -z "${COND_GRUB_EMU_SDL_FALSE}"; then
29142 as_fn_error $? "conditional \"COND_GRUB_EMU_SDL\" was never defined.
29143Usually this means the macro was only invoked conditionally." "$LINENO" 5
29144fi
29145if test -z "${COND_GRUB_EMU_PCI_TRUE}" && test -z "${COND_GRUB_EMU_PCI_FALSE}"; then
29146 as_fn_error $? "conditional \"COND_GRUB_EMU_PCI\" was never defined.
29147Usually this means the macro was only invoked conditionally." "$LINENO" 5
29148fi
29149if test -z "${COND_GRUB_MKFONT_TRUE}" && test -z "${COND_GRUB_MKFONT_FALSE}"; then
29150 as_fn_error $? "conditional \"COND_GRUB_MKFONT\" was never defined.
29151Usually this means the macro was only invoked conditionally." "$LINENO" 5
29152fi
29153if test -z "${COND_GRUB_MOUNT_TRUE}" && test -z "${COND_GRUB_MOUNT_FALSE}"; then
29154 as_fn_error $? "conditional \"COND_GRUB_MOUNT\" was never defined.
29155Usually this means the macro was only invoked conditionally." "$LINENO" 5
29156fi
29157if test -z "${COND_HAVE_FONT_SOURCE_TRUE}" && test -z "${COND_HAVE_FONT_SOURCE_FALSE}"; then
29158 as_fn_error $? "conditional \"COND_HAVE_FONT_SOURCE\" was never defined.
29159Usually this means the macro was only invoked conditionally." "$LINENO" 5
29160fi
29161if test -z "${COND_APPLE_LINKER_TRUE}" && test -z "${COND_APPLE_LINKER_FALSE}"; then
29162 as_fn_error $? "conditional \"COND_APPLE_LINKER\" was never defined.
29163Usually this means the macro was only invoked conditionally." "$LINENO" 5
29164fi
29165if test -z "${COND_ENABLE_EFIEMU_TRUE}" && test -z "${COND_ENABLE_EFIEMU_FALSE}"; then
29166 as_fn_error $? "conditional \"COND_ENABLE_EFIEMU\" was never defined.
29167Usually this means the macro was only invoked conditionally." "$LINENO" 5
29168fi
29169if test -z "${COND_ENABLE_CACHE_STATS_TRUE}" && test -z "${COND_ENABLE_CACHE_STATS_FALSE}"; then
29170 as_fn_error $? "conditional \"COND_ENABLE_CACHE_STATS\" was never defined.
29171Usually this means the macro was only invoked conditionally." "$LINENO" 5
29172fi
29173if test -z "${COND_ENABLE_BOOT_TIME_STATS_TRUE}" && test -z "${COND_ENABLE_BOOT_TIME_STATS_FALSE}"; then
29174 as_fn_error $? "conditional \"COND_ENABLE_BOOT_TIME_STATS\" was never defined.
29175Usually this means the macro was only invoked conditionally." "$LINENO" 5
29176fi
29177if test -z "${COND_HAVE_CXX_TRUE}" && test -z "${COND_HAVE_CXX_FALSE}"; then
29178 as_fn_error $? "conditional \"COND_HAVE_CXX\" was never defined.
29179Usually this means the macro was only invoked conditionally." "$LINENO" 5
29180fi
29181if test -z "${COND_HAVE_ASM_USCORE_TRUE}" && test -z "${COND_HAVE_ASM_USCORE_FALSE}"; then
29182 as_fn_error $? "conditional \"COND_HAVE_ASM_USCORE\" was never defined.
29183Usually this means the macro was only invoked conditionally." "$LINENO" 5
29184fi
29185if test -z "${COND_STARFIELD_TRUE}" && test -z "${COND_STARFIELD_FALSE}"; then
29186 as_fn_error $? "conditional \"COND_STARFIELD\" was never defined.
29187Usually this means the macro was only invoked conditionally." "$LINENO" 5
29188fi
29189if test -z "${COND_HAVE_EXEC_TRUE}" && test -z "${COND_HAVE_EXEC_FALSE}"; then
29190 as_fn_error $? "conditional \"COND_HAVE_EXEC\" was never defined.
29191Usually this means the macro was only invoked conditionally." "$LINENO" 5
29192fi
29193
29194: "${CONFIG_STATUS=./config.status}"
29195ac_write_fail=0
29196ac_clean_files_save=$ac_clean_files
29197ac_clean_files="$ac_clean_files $CONFIG_STATUS"
29198{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
29199$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
29200as_write_fail=0
29201cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
29202#! $SHELL
29203# Generated by $as_me.
29204# Run this file to recreate the current configuration.
29205# Compiler output produced by configure, useful for debugging
29206# configure, is in config.log if it exists.
29207
29208debug=false
29209ac_cs_recheck=false
29210ac_cs_silent=false
29211
29212SHELL=\${CONFIG_SHELL-$SHELL}
29213export SHELL
29214_ASEOF
29215cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
29216## -------------------- ##
29217## M4sh Initialization. ##
29218## -------------------- ##
29219
29220# Be more Bourne compatible
29221DUALCASE=1; export DUALCASE # for MKS sh
29222if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
29223 emulate sh
29224 NULLCMD=:
29225 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
29226 # is contrary to our usage. Disable this feature.
29227 alias -g '${1+"$@"}'='"$@"'
29228 setopt NO_GLOB_SUBST
29229else
29230 case `(set -o) 2>/dev/null` in #(
29231 *posix*) :
29232 set -o posix ;; #(
29233 *) :
29234 ;;
29235esac
29236fi
29237
29238
29239as_nl='
29240'
29241export as_nl
29242# Printing a long string crashes Solaris 7 /usr/bin/printf.
29243as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
29244as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
29245as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
29246# Prefer a ksh shell builtin over an external printf program on Solaris,
29247# but without wasting forks for bash or zsh.
29248if test -z "$BASH_VERSION$ZSH_VERSION" \
29249 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
29250 as_echo='print -r --'
29251 as_echo_n='print -rn --'
29252elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
29253 as_echo='printf %s\n'
29254 as_echo_n='printf %s'
29255else
29256 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
29257 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
29258 as_echo_n='/usr/ucb/echo -n'
29259 else
29260 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
29261 as_echo_n_body='eval
29262 arg=$1;
29263 case $arg in #(
29264 *"$as_nl"*)
29265 expr "X$arg" : "X\\(.*\\)$as_nl";
29266 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
29267 esac;
29268 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
29269 '
29270 export as_echo_n_body
29271 as_echo_n='sh -c $as_echo_n_body as_echo'
29272 fi
29273 export as_echo_body
29274 as_echo='sh -c $as_echo_body as_echo'
29275fi
29276
29277# The user is always right.
29278if test "${PATH_SEPARATOR+set}" != set; then
29279 PATH_SEPARATOR=:
29280 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
29281 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
29282 PATH_SEPARATOR=';'
29283 }
29284fi
29285
29286
29287# IFS
29288# We need space, tab and new line, in precisely that order. Quoting is
29289# there to prevent editors from complaining about space-tab.
29290# (If _AS_PATH_WALK were called with IFS unset, it would disable word
29291# splitting by setting IFS to empty value.)
29292IFS=" "" $as_nl"
29293
29294# Find who we are. Look in the path if we contain no directory separator.
29295as_myself=
29296case $0 in #((
29297 *[\\/]* ) as_myself=$0 ;;
29298 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29299for as_dir in $PATH
29300do
29301 IFS=$as_save_IFS
29302 test -z "$as_dir" && as_dir=.
29303 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
29304 done
29305IFS=$as_save_IFS
29306
29307 ;;
29308esac
29309# We did not find ourselves, most probably we were run as `sh COMMAND'
29310# in which case we are not to be found in the path.
29311if test "x$as_myself" = x; then
29312 as_myself=$0
29313fi
29314if test ! -f "$as_myself"; then
29315 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
29316 exit 1
29317fi
29318
29319# Unset variables that we do not need and which cause bugs (e.g. in
29320# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
29321# suppresses any "Segmentation fault" message there. '((' could
29322# trigger a bug in pdksh 5.2.14.
29323for as_var in BASH_ENV ENV MAIL MAILPATH
29324do eval test x\${$as_var+set} = xset \
29325 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
29326done
29327PS1='$ '
29328PS2='> '
29329PS4='+ '
29330
29331# NLS nuisances.
29332LC_ALL=C
29333export LC_ALL
29334LANGUAGE=C
29335export LANGUAGE
29336
29337# CDPATH.
29338(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
29339
29340
29341# as_fn_error STATUS ERROR [LINENO LOG_FD]
29342# ----------------------------------------
29343# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
29344# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
29345# script with STATUS, using 1 if that was 0.
29346as_fn_error ()
29347{
29348 as_status=$1; test $as_status -eq 0 && as_status=1
29349 if test "$4"; then
29350 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
29351 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
29352 fi
29353 $as_echo "$as_me: error: $2" >&2
29354 as_fn_exit $as_status
29355} # as_fn_error
29356
29357
29358# as_fn_set_status STATUS
29359# -----------------------
29360# Set $? to STATUS, without forking.
29361as_fn_set_status ()
29362{
29363 return $1
29364} # as_fn_set_status
29365
29366# as_fn_exit STATUS
29367# -----------------
29368# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
29369as_fn_exit ()
29370{
29371 set +e
29372 as_fn_set_status $1
29373 exit $1
29374} # as_fn_exit
29375
29376# as_fn_unset VAR
29377# ---------------
29378# Portably unset VAR.
29379as_fn_unset ()
29380{
29381 { eval $1=; unset $1;}
29382}
29383as_unset=as_fn_unset
29384# as_fn_append VAR VALUE
29385# ----------------------
29386# Append the text in VALUE to the end of the definition contained in VAR. Take
29387# advantage of any shell optimizations that allow amortized linear growth over
29388# repeated appends, instead of the typical quadratic growth present in naive
29389# implementations.
29390if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
29391 eval 'as_fn_append ()
29392 {
29393 eval $1+=\$2
29394 }'
29395else
29396 as_fn_append ()
29397 {
29398 eval $1=\$$1\$2
29399 }
29400fi # as_fn_append
29401
29402# as_fn_arith ARG...
29403# ------------------
29404# Perform arithmetic evaluation on the ARGs, and store the result in the
29405# global $as_val. Take advantage of shells that can avoid forks. The arguments
29406# must be portable across $(()) and expr.
29407if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
29408 eval 'as_fn_arith ()
29409 {
29410 as_val=$(( $* ))
29411 }'
29412else
29413 as_fn_arith ()
29414 {
29415 as_val=`expr "$@" || test $? -eq 1`
29416 }
29417fi # as_fn_arith
29418
29419
29420if expr a : '\(a\)' >/dev/null 2>&1 &&
29421 test "X`expr 00001 : '.*\(...\)'`" = X001; then
29422 as_expr=expr
29423else
29424 as_expr=false
29425fi
29426
29427if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
29428 as_basename=basename
29429else
29430 as_basename=false
29431fi
29432
29433if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
29434 as_dirname=dirname
29435else
29436 as_dirname=false
29437fi
29438
29439as_me=`$as_basename -- "$0" ||
29440$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
29441 X"$0" : 'X\(//\)$' \| \
29442 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
29443$as_echo X/"$0" |
29444 sed '/^.*\/\([^/][^/]*\)\/*$/{
29445 s//\1/
29446 q
29447 }
29448 /^X\/\(\/\/\)$/{
29449 s//\1/
29450 q
29451 }
29452 /^X\/\(\/\).*/{
29453 s//\1/
29454 q
29455 }
29456 s/.*/./; q'`
29457
29458# Avoid depending upon Character Ranges.
29459as_cr_letters='abcdefghijklmnopqrstuvwxyz'
29460as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
29461as_cr_Letters=$as_cr_letters$as_cr_LETTERS
29462as_cr_digits='0123456789'
29463as_cr_alnum=$as_cr_Letters$as_cr_digits
29464
29465ECHO_C= ECHO_N= ECHO_T=
29466case `echo -n x` in #(((((
29467-n*)
29468 case `echo 'xy\c'` in
29469 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
29470 xy) ECHO_C='\c';;
29471 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
29472 ECHO_T=' ';;
29473 esac;;
29474*)
29475 ECHO_N='-n';;
29476esac
29477
29478rm -f conf$$ conf$$.exe conf$$.file
29479if test -d conf$$.dir; then
29480 rm -f conf$$.dir/conf$$.file
29481else
29482 rm -f conf$$.dir
29483 mkdir conf$$.dir 2>/dev/null
29484fi
29485if (echo >conf$$.file) 2>/dev/null; then
29486 if ln -s conf$$.file conf$$ 2>/dev/null; then
29487 as_ln_s='ln -s'
29488 # ... but there are two gotchas:
29489 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
29490 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
29491 # In both cases, we have to default to `cp -pR'.
29492 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
29493 as_ln_s='cp -pR'
29494 elif ln conf$$.file conf$$ 2>/dev/null; then
29495 as_ln_s=ln
29496 else
29497 as_ln_s='cp -pR'
29498 fi
29499else
29500 as_ln_s='cp -pR'
29501fi
29502rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
29503rmdir conf$$.dir 2>/dev/null
29504
29505
29506# as_fn_mkdir_p
29507# -------------
29508# Create "$as_dir" as a directory, including parents if necessary.
29509as_fn_mkdir_p ()
29510{
29511
29512 case $as_dir in #(
29513 -*) as_dir=./$as_dir;;
29514 esac
29515 test -d "$as_dir" || eval $as_mkdir_p || {
29516 as_dirs=
29517 while :; do
29518 case $as_dir in #(
29519 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
29520 *) as_qdir=$as_dir;;
29521 esac
29522 as_dirs="'$as_qdir' $as_dirs"
29523 as_dir=`$as_dirname -- "$as_dir" ||
29524$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
29525 X"$as_dir" : 'X\(//\)[^/]' \| \
29526 X"$as_dir" : 'X\(//\)$' \| \
29527 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
29528$as_echo X"$as_dir" |
29529 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
29530 s//\1/
29531 q
29532 }
29533 /^X\(\/\/\)[^/].*/{
29534 s//\1/
29535 q
29536 }
29537 /^X\(\/\/\)$/{
29538 s//\1/
29539 q
29540 }
29541 /^X\(\/\).*/{
29542 s//\1/
29543 q
29544 }
29545 s/.*/./; q'`
29546 test -d "$as_dir" && break
29547 done
29548 test -z "$as_dirs" || eval "mkdir $as_dirs"
29549 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
29550
29551
29552} # as_fn_mkdir_p
29553if mkdir -p . 2>/dev/null; then
29554 as_mkdir_p='mkdir -p "$as_dir"'
29555else
29556 test -d ./-p && rmdir ./-p
29557 as_mkdir_p=false
29558fi
29559
29560
29561# as_fn_executable_p FILE
29562# -----------------------
29563# Test if FILE is an executable regular file.
29564as_fn_executable_p ()
29565{
29566 test -f "$1" && test -x "$1"
29567} # as_fn_executable_p
29568as_test_x='test -x'
29569as_executable_p=as_fn_executable_p
29570
29571# Sed expression to map a string onto a valid CPP name.
29572as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
29573
29574# Sed expression to map a string onto a valid variable name.
29575as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
29576
29577
29578exec 6>&1
29579## ----------------------------------- ##
29580## Main body of $CONFIG_STATUS script. ##
29581## ----------------------------------- ##
29582_ASEOF
29583test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
29584
29585cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29586# Save the log message, to keep $0 and so on meaningful, and to
29587# report actual input values of CONFIG_FILES etc. instead of their
29588# values after options handling.
29589ac_log="
29590This file was extended by GRUB $as_me 2.02, which was
29591generated by GNU Autoconf 2.69. Invocation command line was
29592
29593 CONFIG_FILES = $CONFIG_FILES
29594 CONFIG_HEADERS = $CONFIG_HEADERS
29595 CONFIG_LINKS = $CONFIG_LINKS
29596 CONFIG_COMMANDS = $CONFIG_COMMANDS
29597 $ $0 $@
29598
29599on `(hostname || uname -n) 2>/dev/null | sed 1q`
29600"
29601
29602_ACEOF
29603
29604case $ac_config_files in *"
29605"*) set x $ac_config_files; shift; ac_config_files=$*;;
29606esac
29607
29608case $ac_config_headers in *"
29609"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
29610esac
29611
29612
29613cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29614# Files that config.status was made for.
29615config_files="$ac_config_files"
29616config_headers="$ac_config_headers"
29617config_links="$ac_config_links"
29618config_commands="$ac_config_commands"
29619
29620_ACEOF
29621
29622cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29623ac_cs_usage="\
29624\`$as_me' instantiates files and other configuration actions
29625from templates according to the current configuration. Unless the files
29626and actions are specified as TAGs, all are instantiated by default.
29627
29628Usage: $0 [OPTION]... [TAG]...
29629
29630 -h, --help print this help, then exit
29631 -V, --version print version number and configuration settings, then exit
29632 --config print configuration, then exit
29633 -q, --quiet, --silent
29634 do not print progress messages
29635 -d, --debug don't remove temporary files
29636 --recheck update $as_me by reconfiguring in the same conditions
29637 --file=FILE[:TEMPLATE]
29638 instantiate the configuration file FILE
29639 --header=FILE[:TEMPLATE]
29640 instantiate the configuration header FILE
29641
29642Configuration files:
29643$config_files
29644
29645Configuration headers:
29646$config_headers
29647
29648Configuration links:
29649$config_links
29650
29651Configuration commands:
29652$config_commands
29653
29654Report bugs to <bug-grub@gnu.org>."
29655
29656_ACEOF
29657cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29658ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
29659ac_cs_version="\\
29660GRUB config.status 2.02
29661configured by $0, generated by GNU Autoconf 2.69,
29662 with options \\"\$ac_cs_config\\"
29663
29664Copyright (C) 2012 Free Software Foundation, Inc.
29665This config.status script is free software; the Free Software Foundation
29666gives unlimited permission to copy, distribute and modify it."
29667
29668ac_pwd='$ac_pwd'
29669srcdir='$srcdir'
29670INSTALL='$INSTALL'
29671MKDIR_P='$MKDIR_P'
29672AWK='$AWK'
29673test -n "\$AWK" || AWK=awk
29674_ACEOF
29675
29676cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29677# The default lists apply if the user does not specify any file.
29678ac_need_defaults=:
29679while test $# != 0
29680do
29681 case $1 in
29682 --*=?*)
29683 ac_option=`expr "X$1" : 'X\([^=]*\)='`
29684 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
29685 ac_shift=:
29686 ;;
29687 --*=)
29688 ac_option=`expr "X$1" : 'X\([^=]*\)='`
29689 ac_optarg=
29690 ac_shift=:
29691 ;;
29692 *)
29693 ac_option=$1
29694 ac_optarg=$2
29695 ac_shift=shift
29696 ;;
29697 esac
29698
29699 case $ac_option in
29700 # Handling of the options.
29701 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
29702 ac_cs_recheck=: ;;
29703 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
29704 $as_echo "$ac_cs_version"; exit ;;
29705 --config | --confi | --conf | --con | --co | --c )
29706 $as_echo "$ac_cs_config"; exit ;;
29707 --debug | --debu | --deb | --de | --d | -d )
29708 debug=: ;;
29709 --file | --fil | --fi | --f )
29710 $ac_shift
29711 case $ac_optarg in
29712 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
29713 '') as_fn_error $? "missing file argument" ;;
29714 esac
29715 as_fn_append CONFIG_FILES " '$ac_optarg'"
29716 ac_need_defaults=false;;
29717 --header | --heade | --head | --hea )
29718 $ac_shift
29719 case $ac_optarg in
29720 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
29721 esac
29722 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
29723 ac_need_defaults=false;;
29724 --he | --h)
29725 # Conflict between --help and --header
29726 as_fn_error $? "ambiguous option: \`$1'
29727Try \`$0 --help' for more information.";;
29728 --help | --hel | -h )
29729 $as_echo "$ac_cs_usage"; exit ;;
29730 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
29731 | -silent | --silent | --silen | --sile | --sil | --si | --s)
29732 ac_cs_silent=: ;;
29733
29734 # This is an error.
29735 -*) as_fn_error $? "unrecognized option: \`$1'
29736Try \`$0 --help' for more information." ;;
29737
29738 *) as_fn_append ac_config_targets " $1"
29739 ac_need_defaults=false ;;
29740
29741 esac
29742 shift
29743done
29744
29745ac_configure_extra_args=
29746
29747if $ac_cs_silent; then
29748 exec 6>/dev/null
29749 ac_configure_extra_args="$ac_configure_extra_args --silent"
29750fi
29751
29752_ACEOF
29753cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29754if \$ac_cs_recheck; then
29755 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
29756 shift
29757 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
29758 CONFIG_SHELL='$SHELL'
29759 export CONFIG_SHELL
29760 exec "\$@"
29761fi
29762
29763_ACEOF
29764cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29765exec 5>>config.log
29766{
29767 echo
29768 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
29769## Running $as_me. ##
29770_ASBOX
29771 $as_echo "$ac_log"
29772} >&5
29773
29774_ACEOF
29775cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29776#
29777# INIT-COMMANDS
29778#
29779AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
29780# Capture the value of obsolete ALL_LINGUAS because we need it to compute
29781 # POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES, CATALOGS. But hide it
29782 # from automake < 1.5.
29783 eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
29784 # Capture the value of LINGUAS because we need it to compute CATALOGS.
29785 LINGUAS="${LINGUAS-%UNSET%}"
29786
29787
29788_ACEOF
29789
29790cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29791
29792# Handling of arguments.
29793for ac_config_target in $ac_config_targets
29794do
29795 case $ac_config_target in
29796 "config-util.h") CONFIG_HEADERS="$CONFIG_HEADERS config-util.h" ;;
29797 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
29798 "po-directories") CONFIG_COMMANDS="$CONFIG_COMMANDS po-directories" ;;
29799 "include/grub/cpu") CONFIG_LINKS="$CONFIG_LINKS include/grub/cpu:include/grub/$cpudir" ;;
29800 "include/grub/machine") CONFIG_LINKS="$CONFIG_LINKS include/grub/machine:include/grub/$cpudir/$platform" ;;
29801 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
29802 "grub-core/Makefile") CONFIG_FILES="$CONFIG_FILES grub-core/Makefile" ;;
29803 "grub-core/gnulib/Makefile") CONFIG_FILES="$CONFIG_FILES grub-core/gnulib/Makefile" ;;
29804 "po/Makefile.in") CONFIG_FILES="$CONFIG_FILES po/Makefile.in" ;;
29805 "docs/Makefile") CONFIG_FILES="$CONFIG_FILES docs/Makefile" ;;
29806 "util/bash-completion.d/Makefile") CONFIG_FILES="$CONFIG_FILES util/bash-completion.d/Makefile" ;;
29807 "stamp-h") CONFIG_FILES="$CONFIG_FILES stamp-h" ;;
29808 "config.h") CONFIG_FILES="$CONFIG_FILES config.h" ;;
29809
29810 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
29811 esac
29812done
29813
29814
29815# If the user did not use the arguments to specify the items to instantiate,
29816# then the envvar interface is used. Set only those that are not.
29817# We use the long form for the default assignment because of an extremely
29818# bizarre bug on SunOS 4.1.3.
29819if $ac_need_defaults; then
29820 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
29821 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
29822 test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
29823 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
29824fi
29825
29826# Have a temporary directory for convenience. Make it in the build tree
29827# simply because there is no reason against having it here, and in addition,
29828# creating and moving files from /tmp can sometimes cause problems.
29829# Hook for its removal unless debugging.
29830# Note that there is a small window in which the directory will not be cleaned:
29831# after its creation but before its name has been assigned to `$tmp'.
29832$debug ||
29833{
29834 tmp= ac_tmp=
29835 trap 'exit_status=$?
29836 : "${ac_tmp:=$tmp}"
29837 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
29838' 0
29839 trap 'as_fn_exit 1' 1 2 13 15
29840}
29841# Create a (secure) tmp directory for tmp files.
29842
29843{
29844 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
29845 test -d "$tmp"
29846} ||
29847{
29848 tmp=./conf$$-$RANDOM
29849 (umask 077 && mkdir "$tmp")
29850} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
29851ac_tmp=$tmp
29852
29853# Set up the scripts for CONFIG_FILES section.
29854# No need to generate them if there are no CONFIG_FILES.
29855# This happens for instance with `./config.status config.h'.
29856if test -n "$CONFIG_FILES"; then
29857
29858
29859ac_cr=`echo X | tr X '\015'`
29860# On cygwin, bash can eat \r inside `` if the user requested igncr.
29861# But we know of no other shell where ac_cr would be empty at this
29862# point, so we can use a bashism as a fallback.
29863if test "x$ac_cr" = x; then
29864 eval ac_cr=\$\'\\r\'
29865fi
29866ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
29867if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
29868 ac_cs_awk_cr='\\r'
29869else
29870 ac_cs_awk_cr=$ac_cr
29871fi
29872
29873echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
29874_ACEOF
29875
29876
29877{
29878 echo "cat >conf$$subs.awk <<_ACEOF" &&
29879 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
29880 echo "_ACEOF"
29881} >conf$$subs.sh ||
29882 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
29883ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
29884ac_delim='%!_!# '
29885for ac_last_try in false false false false false :; do
29886 . ./conf$$subs.sh ||
29887 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
29888
29889 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
29890 if test $ac_delim_n = $ac_delim_num; then
29891 break
29892 elif $ac_last_try; then
29893 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
29894 else
29895 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
29896 fi
29897done
29898rm -f conf$$subs.sh
29899
29900cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29901cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
29902_ACEOF
29903sed -n '
29904h
29905s/^/S["/; s/!.*/"]=/
29906p
29907g
29908s/^[^!]*!//
29909:repl
29910t repl
29911s/'"$ac_delim"'$//
29912t delim
29913:nl
29914h
29915s/\(.\{148\}\)..*/\1/
29916t more1
29917s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
29918p
29919n
29920b repl
29921:more1
29922s/["\\]/\\&/g; s/^/"/; s/$/"\\/
29923p
29924g
29925s/.\{148\}//
29926t nl
29927:delim
29928h
29929s/\(.\{148\}\)..*/\1/
29930t more2
29931s/["\\]/\\&/g; s/^/"/; s/$/"/
29932p
29933b
29934:more2
29935s/["\\]/\\&/g; s/^/"/; s/$/"\\/
29936p
29937g
29938s/.\{148\}//
29939t delim
29940' <conf$$subs.awk | sed '
29941/^[^""]/{
29942 N
29943 s/\n//
29944}
29945' >>$CONFIG_STATUS || ac_write_fail=1
29946rm -f conf$$subs.awk
29947cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29948_ACAWK
29949cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
29950 for (key in S) S_is_set[key] = 1
29951 FS = "\a"
29952
29953}
29954{
29955 line = $ 0
29956 nfields = split(line, field, "@")
29957 substed = 0
29958 len = length(field[1])
29959 for (i = 2; i < nfields; i++) {
29960 key = field[i]
29961 keylen = length(key)
29962 if (S_is_set[key]) {
29963 value = S[key]
29964 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
29965 len += length(value) + length(field[++i])
29966 substed = 1
29967 } else
29968 len += 1 + keylen
29969 }
29970
29971 print line
29972}
29973
29974_ACAWK
29975_ACEOF
29976cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29977if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
29978 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
29979else
29980 cat
29981fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
29982 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
29983_ACEOF
29984
29985# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
29986# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
29987# trailing colons and then remove the whole line if VPATH becomes empty
29988# (actually we leave an empty line to preserve line numbers).
29989if test "x$srcdir" = x.; then
29990 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
29991h
29992s///
29993s/^/:/
29994s/[ ]*$/:/
29995s/:\$(srcdir):/:/g
29996s/:\${srcdir}:/:/g
29997s/:@srcdir@:/:/g
29998s/^:*//
29999s/:*$//
30000x
30001s/\(=[ ]*\).*/\1/
30002G
30003s/\n//
30004s/^[^=]*=[ ]*$//
30005}'
30006fi
30007
30008cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30009fi # test -n "$CONFIG_FILES"
30010
30011# Set up the scripts for CONFIG_HEADERS section.
30012# No need to generate them if there are no CONFIG_HEADERS.
30013# This happens for instance with `./config.status Makefile'.
30014if test -n "$CONFIG_HEADERS"; then
30015cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
30016BEGIN {
30017_ACEOF
30018
30019# Transform confdefs.h into an awk script `defines.awk', embedded as
30020# here-document in config.status, that substitutes the proper values into
30021# config.h.in to produce config.h.
30022
30023# Create a delimiter string that does not exist in confdefs.h, to ease
30024# handling of long lines.
30025ac_delim='%!_!# '
30026for ac_last_try in false false :; do
30027 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
30028 if test -z "$ac_tt"; then
30029 break
30030 elif $ac_last_try; then
30031 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
30032 else
30033 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
30034 fi
30035done
30036
30037# For the awk script, D is an array of macro values keyed by name,
30038# likewise P contains macro parameters if any. Preserve backslash
30039# newline sequences.
30040
30041ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
30042sed -n '
30043s/.\{148\}/&'"$ac_delim"'/g
30044t rset
30045:rset
30046s/^[ ]*#[ ]*define[ ][ ]*/ /
30047t def
30048d
30049:def
30050s/\\$//
30051t bsnl
30052s/["\\]/\\&/g
30053s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
30054D["\1"]=" \3"/p
30055s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
30056d
30057:bsnl
30058s/["\\]/\\&/g
30059s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
30060D["\1"]=" \3\\\\\\n"\\/p
30061t cont
30062s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
30063t cont
30064d
30065:cont
30066n
30067s/.\{148\}/&'"$ac_delim"'/g
30068t clear
30069:clear
30070s/\\$//
30071t bsnlc
30072s/["\\]/\\&/g; s/^/"/; s/$/"/p
30073d
30074:bsnlc
30075s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
30076b cont
30077' <confdefs.h | sed '
30078s/'"$ac_delim"'/"\\\
30079"/g' >>$CONFIG_STATUS || ac_write_fail=1
30080
30081cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30082 for (key in D) D_is_set[key] = 1
30083 FS = "\a"
30084}
30085/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
30086 line = \$ 0
30087 split(line, arg, " ")
30088 if (arg[1] == "#") {
30089 defundef = arg[2]
30090 mac1 = arg[3]
30091 } else {
30092 defundef = substr(arg[1], 2)
30093 mac1 = arg[2]
30094 }
30095 split(mac1, mac2, "(") #)
30096 macro = mac2[1]
30097 prefix = substr(line, 1, index(line, defundef) - 1)
30098 if (D_is_set[macro]) {
30099 # Preserve the white space surrounding the "#".
30100 print prefix "define", macro P[macro] D[macro]
30101 next
30102 } else {
30103 # Replace #undef with comments. This is necessary, for example,
30104 # in the case of _POSIX_SOURCE, which is predefined and required
30105 # on some systems where configure will not decide to define it.
30106 if (defundef == "undef") {
30107 print "/*", prefix defundef, macro, "*/"
30108 next
30109 }
30110 }
30111}
30112{ print }
30113_ACAWK
30114_ACEOF
30115cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30116 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
30117fi # test -n "$CONFIG_HEADERS"
30118
30119
30120eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :L $CONFIG_LINKS :C $CONFIG_COMMANDS"
30121shift
30122for ac_tag
30123do
30124 case $ac_tag in
30125 :[FHLC]) ac_mode=$ac_tag; continue;;
30126 esac
30127 case $ac_mode$ac_tag in
30128 :[FHL]*:*);;
30129 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
30130 :[FH]-) ac_tag=-:-;;
30131 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
30132 esac
30133 ac_save_IFS=$IFS
30134 IFS=:
30135 set x $ac_tag
30136 IFS=$ac_save_IFS
30137 shift
30138 ac_file=$1
30139 shift
30140
30141 case $ac_mode in
30142 :L) ac_source=$1;;
30143 :[FH])
30144 ac_file_inputs=
30145 for ac_f
30146 do
30147 case $ac_f in
30148 -) ac_f="$ac_tmp/stdin";;
30149 *) # Look for the file first in the build tree, then in the source tree
30150 # (if the path is not absolute). The absolute path cannot be DOS-style,
30151 # because $ac_f cannot contain `:'.
30152 test -f "$ac_f" ||
30153 case $ac_f in
30154 [\\/$]*) false;;
30155 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
30156 esac ||
30157 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
30158 esac
30159 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
30160 as_fn_append ac_file_inputs " '$ac_f'"
30161 done
30162
30163 # Let's still pretend it is `configure' which instantiates (i.e., don't
30164 # use $as_me), people would be surprised to read:
30165 # /* config.h. Generated by config.status. */
30166 configure_input='Generated from '`
30167 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
30168 `' by configure.'
30169 if test x"$ac_file" != x-; then
30170 configure_input="$ac_file. $configure_input"
30171 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
30172$as_echo "$as_me: creating $ac_file" >&6;}
30173 fi
30174 # Neutralize special characters interpreted by sed in replacement strings.
30175 case $configure_input in #(
30176 *\&* | *\|* | *\\* )
30177 ac_sed_conf_input=`$as_echo "$configure_input" |
30178 sed 's/[\\\\&|]/\\\\&/g'`;; #(
30179 *) ac_sed_conf_input=$configure_input;;
30180 esac
30181
30182 case $ac_tag in
30183 *:-:* | *:-) cat >"$ac_tmp/stdin" \
30184 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
30185 esac
30186 ;;
30187 esac
30188
30189 ac_dir=`$as_dirname -- "$ac_file" ||
30190$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30191 X"$ac_file" : 'X\(//\)[^/]' \| \
30192 X"$ac_file" : 'X\(//\)$' \| \
30193 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
30194$as_echo X"$ac_file" |
30195 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30196 s//\1/
30197 q
30198 }
30199 /^X\(\/\/\)[^/].*/{
30200 s//\1/
30201 q
30202 }
30203 /^X\(\/\/\)$/{
30204 s//\1/
30205 q
30206 }
30207 /^X\(\/\).*/{
30208 s//\1/
30209 q
30210 }
30211 s/.*/./; q'`
30212 as_dir="$ac_dir"; as_fn_mkdir_p
30213 ac_builddir=.
30214
30215case "$ac_dir" in
30216.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
30217*)
30218 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
30219 # A ".." for each directory in $ac_dir_suffix.
30220 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
30221 case $ac_top_builddir_sub in
30222 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
30223 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
30224 esac ;;
30225esac
30226ac_abs_top_builddir=$ac_pwd
30227ac_abs_builddir=$ac_pwd$ac_dir_suffix
30228# for backward compatibility:
30229ac_top_builddir=$ac_top_build_prefix
30230
30231case $srcdir in
30232 .) # We are building in place.
30233 ac_srcdir=.
30234 ac_top_srcdir=$ac_top_builddir_sub
30235 ac_abs_top_srcdir=$ac_pwd ;;
30236 [\\/]* | ?:[\\/]* ) # Absolute name.
30237 ac_srcdir=$srcdir$ac_dir_suffix;
30238 ac_top_srcdir=$srcdir
30239 ac_abs_top_srcdir=$srcdir ;;
30240 *) # Relative name.
30241 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
30242 ac_top_srcdir=$ac_top_build_prefix$srcdir
30243 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
30244esac
30245ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
30246
30247
30248 case $ac_mode in
30249 :F)
30250 #
30251 # CONFIG_FILE
30252 #
30253
30254 case $INSTALL in
30255 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
30256 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
30257 esac
30258 ac_MKDIR_P=$MKDIR_P
30259 case $MKDIR_P in
30260 [\\/$]* | ?:[\\/]* ) ;;
30261 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
30262 esac
30263_ACEOF
30264
30265cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30266# If the template does not know about datarootdir, expand it.
30267# FIXME: This hack should be removed a few years after 2.60.
30268ac_datarootdir_hack=; ac_datarootdir_seen=
30269ac_sed_dataroot='
30270/datarootdir/ {
30271 p
30272 q
30273}
30274/@datadir@/p
30275/@docdir@/p
30276/@infodir@/p
30277/@localedir@/p
30278/@mandir@/p'
30279case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
30280*datarootdir*) ac_datarootdir_seen=yes;;
30281*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
30282 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
30283$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
30284_ACEOF
30285cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30286 ac_datarootdir_hack='
30287 s&@datadir@&$datadir&g
30288 s&@docdir@&$docdir&g
30289 s&@infodir@&$infodir&g
30290 s&@localedir@&$localedir&g
30291 s&@mandir@&$mandir&g
30292 s&\\\${datarootdir}&$datarootdir&g' ;;
30293esac
30294_ACEOF
30295
30296# Neutralize VPATH when `$srcdir' = `.'.
30297# Shell code in configure.ac might set extrasub.
30298# FIXME: do we really want to maintain this feature?
30299cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30300ac_sed_extra="$ac_vpsub
30301$extrasub
30302_ACEOF
30303cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30304:t
30305/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
30306s|@configure_input@|$ac_sed_conf_input|;t t
30307s&@top_builddir@&$ac_top_builddir_sub&;t t
30308s&@top_build_prefix@&$ac_top_build_prefix&;t t
30309s&@srcdir@&$ac_srcdir&;t t
30310s&@abs_srcdir@&$ac_abs_srcdir&;t t
30311s&@top_srcdir@&$ac_top_srcdir&;t t
30312s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
30313s&@builddir@&$ac_builddir&;t t
30314s&@abs_builddir@&$ac_abs_builddir&;t t
30315s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
30316s&@INSTALL@&$ac_INSTALL&;t t
30317s&@MKDIR_P@&$ac_MKDIR_P&;t t
30318$ac_datarootdir_hack
30319"
30320eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
30321 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
30322
30323test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
30324 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
30325 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
30326 "$ac_tmp/out"`; test -z "$ac_out"; } &&
30327 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30328which seems to be undefined. Please make sure it is defined" >&5
30329$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30330which seems to be undefined. Please make sure it is defined" >&2;}
30331
30332 rm -f "$ac_tmp/stdin"
30333 case $ac_file in
30334 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
30335 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
30336 esac \
30337 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
30338 ;;
30339 :H)
30340 #
30341 # CONFIG_HEADER
30342 #
30343 if test x"$ac_file" != x-; then
30344 {
30345 $as_echo "/* $configure_input */" \
30346 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
30347 } >"$ac_tmp/config.h" \
30348 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
30349 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
30350 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
30351$as_echo "$as_me: $ac_file is unchanged" >&6;}
30352 else
30353 rm -f "$ac_file"
30354 mv "$ac_tmp/config.h" "$ac_file" \
30355 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
30356 fi
30357 else
30358 $as_echo "/* $configure_input */" \
30359 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
30360 || as_fn_error $? "could not create -" "$LINENO" 5
30361 fi
30362# Compute "$ac_file"'s index in $config_headers.
30363_am_arg="$ac_file"
30364_am_stamp_count=1
30365for _am_header in $config_headers :; do
30366 case $_am_header in
30367 $_am_arg | $_am_arg:* )
30368 break ;;
30369 * )
30370 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
30371 esac
30372done
30373echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
30374$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30375 X"$_am_arg" : 'X\(//\)[^/]' \| \
30376 X"$_am_arg" : 'X\(//\)$' \| \
30377 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
30378$as_echo X"$_am_arg" |
30379 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30380 s//\1/
30381 q
30382 }
30383 /^X\(\/\/\)[^/].*/{
30384 s//\1/
30385 q
30386 }
30387 /^X\(\/\/\)$/{
30388 s//\1/
30389 q
30390 }
30391 /^X\(\/\).*/{
30392 s//\1/
30393 q
30394 }
30395 s/.*/./; q'`/stamp-h$_am_stamp_count
30396 ;;
30397 :L)
30398 #
30399 # CONFIG_LINK
30400 #
30401
30402 if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
30403 :
30404 else
30405 # Prefer the file from the source tree if names are identical.
30406 if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
30407 ac_source=$srcdir/$ac_source
30408 fi
30409
30410 { $as_echo "$as_me:${as_lineno-$LINENO}: linking $ac_source to $ac_file" >&5
30411$as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
30412
30413 if test ! -r "$ac_source"; then
30414 as_fn_error $? "$ac_source: file not found" "$LINENO" 5
30415 fi
30416 rm -f "$ac_file"
30417
30418 # Try a relative symlink, then a hard link, then a copy.
30419 case $ac_source in
30420 [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
30421 *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
30422 esac
30423 ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
30424 ln "$ac_source" "$ac_file" 2>/dev/null ||
30425 cp -p "$ac_source" "$ac_file" ||
30426 as_fn_error $? "cannot link or copy $ac_source to $ac_file" "$LINENO" 5
30427 fi
30428 ;;
30429 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
30430$as_echo "$as_me: executing $ac_file commands" >&6;}
30431 ;;
30432 esac
30433
30434
30435 case $ac_file$ac_mode in
30436 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
30437 # Older Autoconf quotes --file arguments for eval, but not when files
30438 # are listed without --file. Let's play safe and only enable the eval
30439 # if we detect the quoting.
30440 case $CONFIG_FILES in
30441 *\'*) eval set x "$CONFIG_FILES" ;;
30442 *) set x $CONFIG_FILES ;;
30443 esac
30444 shift
30445 for mf
30446 do
30447 # Strip MF so we end up with the name of the file.
30448 mf=`echo "$mf" | sed -e 's/:.*$//'`
30449 # Check whether this is an Automake generated Makefile or not.
30450 # We used to match only the files named 'Makefile.in', but
30451 # some people rename them; so instead we look at the file content.
30452 # Grep'ing the first line is not enough: some people post-process
30453 # each Makefile.in and add a new line on top of each file to say so.
30454 # Grep'ing the whole file is not good either: AIX grep has a line
30455 # limit of 2048, but all sed's we know have understand at least 4000.
30456 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
30457 dirpart=`$as_dirname -- "$mf" ||
30458$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30459 X"$mf" : 'X\(//\)[^/]' \| \
30460 X"$mf" : 'X\(//\)$' \| \
30461 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
30462$as_echo X"$mf" |
30463 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30464 s//\1/
30465 q
30466 }
30467 /^X\(\/\/\)[^/].*/{
30468 s//\1/
30469 q
30470 }
30471 /^X\(\/\/\)$/{
30472 s//\1/
30473 q
30474 }
30475 /^X\(\/\).*/{
30476 s//\1/
30477 q
30478 }
30479 s/.*/./; q'`
30480 else
30481 continue
30482 fi
30483 # Extract the definition of DEPDIR, am__include, and am__quote
30484 # from the Makefile without running 'make'.
30485 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
30486 test -z "$DEPDIR" && continue
30487 am__include=`sed -n 's/^am__include = //p' < "$mf"`
30488 test -z "$am__include" && continue
30489 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
30490 # Find all dependency output files, they are included files with
30491 # $(DEPDIR) in their names. We invoke sed twice because it is the
30492 # simplest approach to changing $(DEPDIR) to its actual value in the
30493 # expansion.
30494 for file in `sed -n "
30495 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
30496 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
30497 # Make sure the directory exists.
30498 test -f "$dirpart/$file" && continue
30499 fdir=`$as_dirname -- "$file" ||
30500$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30501 X"$file" : 'X\(//\)[^/]' \| \
30502 X"$file" : 'X\(//\)$' \| \
30503 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
30504$as_echo X"$file" |
30505 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30506 s//\1/
30507 q
30508 }
30509 /^X\(\/\/\)[^/].*/{
30510 s//\1/
30511 q
30512 }
30513 /^X\(\/\/\)$/{
30514 s//\1/
30515 q
30516 }
30517 /^X\(\/\).*/{
30518 s//\1/
30519 q
30520 }
30521 s/.*/./; q'`
30522 as_dir=$dirpart/$fdir; as_fn_mkdir_p
30523 # echo "creating $dirpart/$file"
30524 echo '# dummy' > "$dirpart/$file"
30525 done
30526 done
30527}
30528 ;;
30529 "po-directories":C)
30530 for ac_file in $CONFIG_FILES; do
30531 # Support "outfile[:infile[:infile...]]"
30532 case "$ac_file" in
30533 *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
30534 esac
30535 # PO directories have a Makefile.in generated from Makefile.in.in.
30536 case "$ac_file" in */Makefile.in)
30537 # Adjust a relative srcdir.
30538 ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
30539 ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
30540 ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
30541 # In autoconf-2.13 it is called $ac_given_srcdir.
30542 # In autoconf-2.50 it is called $srcdir.
30543 test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
30544 case "$ac_given_srcdir" in
30545 .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
30546 /*) top_srcdir="$ac_given_srcdir" ;;
30547 *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
30548 esac
30549 # Treat a directory as a PO directory if and only if it has a
30550 # POTFILES.in file. This allows packages to have multiple PO
30551 # directories under different names or in different locations.
30552 if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
30553 rm -f "$ac_dir/POTFILES"
30554 test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
30555 gt_tab=`printf '\t'`
30556 cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ${gt_tab}]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
30557 POMAKEFILEDEPS="POTFILES.in"
30558 # ALL_LINGUAS, POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES depend
30559 # on $ac_dir but don't depend on user-specified configuration
30560 # parameters.
30561 if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
30562 # The LINGUAS file contains the set of available languages.
30563 if test -n "$OBSOLETE_ALL_LINGUAS"; then
30564 test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete"
30565 fi
30566 ALL_LINGUAS_=`sed -e "/^#/d" -e "s/#.*//" "$ac_given_srcdir/$ac_dir/LINGUAS"`
30567 # Hide the ALL_LINGUAS assignment from automake < 1.5.
30568 eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
30569 POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
30570 else
30571 # The set of available languages was given in configure.in.
30572 # Hide the ALL_LINGUAS assignment from automake < 1.5.
30573 eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
30574 fi
30575 # Compute POFILES
30576 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).po)
30577 # Compute UPDATEPOFILES
30578 # as $(foreach lang, $(ALL_LINGUAS), $(lang).po-update)
30579 # Compute DUMMYPOFILES
30580 # as $(foreach lang, $(ALL_LINGUAS), $(lang).nop)
30581 # Compute GMOFILES
30582 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).gmo)
30583 case "$ac_given_srcdir" in
30584 .) srcdirpre= ;;
30585 *) srcdirpre='$(srcdir)/' ;;
30586 esac
30587 POFILES=
30588 UPDATEPOFILES=
30589 DUMMYPOFILES=
30590 GMOFILES=
30591 for lang in $ALL_LINGUAS; do
30592 POFILES="$POFILES $srcdirpre$lang.po"
30593 UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
30594 DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
30595 GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
30596 done
30597 # CATALOGS depends on both $ac_dir and the user's LINGUAS
30598 # environment variable.
30599 INST_LINGUAS=
30600 if test -n "$ALL_LINGUAS"; then
30601 for presentlang in $ALL_LINGUAS; do
30602 useit=no
30603 if test "%UNSET%" != "$LINGUAS"; then
30604 desiredlanguages="$LINGUAS"
30605 else
30606 desiredlanguages="$ALL_LINGUAS"
30607 fi
30608 for desiredlang in $desiredlanguages; do
30609 # Use the presentlang catalog if desiredlang is
30610 # a. equal to presentlang, or
30611 # b. a variant of presentlang (because in this case,
30612 # presentlang can be used as a fallback for messages
30613 # which are not translated in the desiredlang catalog).
30614 case "$desiredlang" in
30615 "$presentlang"*) useit=yes;;
30616 esac
30617 done
30618 if test $useit = yes; then
30619 INST_LINGUAS="$INST_LINGUAS $presentlang"
30620 fi
30621 done
30622 fi
30623 CATALOGS=
30624 if test -n "$INST_LINGUAS"; then
30625 for lang in $INST_LINGUAS; do
30626 CATALOGS="$CATALOGS $lang.gmo"
30627 done
30628 fi
30629 test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
30630 sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
30631 for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
30632 if test -f "$f"; then
30633 case "$f" in
30634 *.orig | *.bak | *~) ;;
30635 *) cat "$f" >> "$ac_dir/Makefile" ;;
30636 esac
30637 fi
30638 done
30639 fi
30640 ;;
30641 esac
30642 done ;;
30643 "stamp-h":F) echo timestamp > stamp-h ;;
30644
30645 esac
30646done # for ac_tag
30647
30648
30649as_fn_exit 0
30650_ACEOF
30651ac_clean_files=$ac_clean_files_save
30652
30653test $ac_write_fail = 0 ||
30654 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
30655
30656
30657# configure is writing to config.log, and then calls config.status.
30658# config.status does its own redirection, appending to config.log.
30659# Unfortunately, on DOS this fails, as config.log is still kept open
30660# by configure, so config.status won't be able to write to it; its
30661# output is simply discarded. So we exec the FD to /dev/null,
30662# effectively closing config.log, so it can be properly (re)opened and
30663# appended to by config.status. When coming back to configure, we
30664# need to make the FD available again.
30665if test "$no_create" != yes; then
30666 ac_cs_success=:
30667 ac_config_status_args=
30668 test "$silent" = yes &&
30669 ac_config_status_args="$ac_config_status_args --quiet"
30670 exec 5>/dev/null
30671 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
30672 exec 5>>config.log
30673 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
30674 # would make configure fail if this is the last instruction.
30675 $ac_cs_success || as_fn_exit 1
30676fi
30677if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
30678 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
30679$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
30680fi
30681
30682
30683echo "*******************************************************"
30684echo GRUB2 will be compiled with following components:
30685echo Platform: "$target_cpu"-"$platform"
30686if [ x"$platform" = xemu ]; then
30687if [ x"$grub_emu_sdl_excuse" = x ]; then
30688echo SDL support for grub-emu: Yes
30689else
30690echo SDL support for grub-emu: No "($grub_emu_sdl_excuse)"
30691fi
30692if [ x"$grub_emu_pci_excuse" = x ]; then
30693echo PCI support for grub-emu: Yes
30694else
30695echo PCI support for grub-emu: No "($grub_emu_pci_excuse)"
30696fi
30697fi
30698if test x"$device_mapper_excuse" = x ; then
30699echo With devmapper support: Yes
30700else
30701echo With devmapper support: No "($device_mapper_excuse)"
30702fi
30703if [ x"$enable_mm_debug" = xyes ]; then
30704echo With memory debugging: Yes
30705else
30706echo With memory debugging: No
30707fi
30708if [ x"$enable_cache_stats" = xyes ]; then
30709echo With disk cache statistics: Yes
30710else
30711echo With disk cache statistics: No
30712fi
30713
30714if [ x"$enable_boot_time" = xyes ]; then
30715echo With boot time statistics: Yes
30716else
30717echo With boot time statistics: No
30718fi
30719
30720if [ x"$efiemu_excuse" = x ]; then
30721echo efiemu runtime: Yes
30722else
30723echo efiemu runtime: No "($efiemu_excuse)"
30724fi
30725if [ x"$grub_mkfont_excuse" = x ]; then
30726echo grub-mkfont: Yes
30727else
30728echo grub-mkfont: No "($grub_mkfont_excuse)"
30729fi
30730if [ x"$grub_mount_excuse" = x ]; then
30731echo grub-mount: Yes
30732else
30733echo grub-mount: No "($grub_mount_excuse)"
30734fi
30735if [ x"$starfield_excuse" = x ]; then
30736echo starfield theme: Yes
30737echo With DejaVuSans font from $DJVU_FONT_SOURCE
30738else
30739echo starfield theme: No "($starfield_excuse)"
30740fi
30741if [ x"$libzfs_excuse" = x ]; then
30742echo With libzfs support: Yes
30743else
30744echo With libzfs support: No "($libzfs_excuse)"
30745fi
30746if [ x"$grub_build_mkfont_excuse" = x ]; then
30747 echo Build-time grub-mkfont: Yes
30748 if test "x$FONT_SOURCE" = x ; then
30749 echo "Without unifont"
30750 else
30751 echo "With unifont from $FONT_SOURCE"
30752 fi
30753else
30754 echo Build-time grub-mkfont: No "($grub_build_mkfont_excuse)"
30755 echo "Without unifont (no build-time grub-mkfont)"
30756fi
30757if test x"$liblzma_excuse" != x ; then
30758echo "Without liblzma (no support for XZ-compressed mips images) ($liblzma_excuse)"
30759else
30760echo "With liblzma from $LIBLZMA (support for XZ-compressed mips images)"
30761fi
30762echo "*******************************************************"
30763