]> git.proxmox.com Git - grub2.git/blame - configure
2006-04-01 Vesa Jaaskelainen <chaac@nic.fi>
[grub2.git] / configure
CommitLineData
6a161fa9 1#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.
5f97350b 3# Generated by GNU Autoconf 2.59 for GRUB 1.93.
6a161fa9 4#
3b1139cb 5# Report bugs to <bug-grub@gnu.org>.
6a161fa9 6#
924b6140 7# Copyright (C) 2003 Free Software Foundation, Inc.
6a161fa9 8# This configure script is free software; the Free Software Foundation
9# gives unlimited permission to copy, distribute and modify it.
6a161fa9 10## --------------------- ##
11## M4sh Initialization. ##
12## --------------------- ##
13
14# Be Bourne compatible
15if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
16 emulate sh
17 NULLCMD=:
98d15063 18 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
19 # is contrary to our usage. Disable this feature.
20 alias -g '${1+"$@"}'='"$@"'
6a161fa9 21elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
22 set -o posix
23fi
924b6140 24DUALCASE=1; export DUALCASE # for MKS sh
6a161fa9 25
6a161fa9 26# Support unset when possible.
924b6140 27if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
6a161fa9 28 as_unset=unset
29else
30 as_unset=false
31fi
32
98d15063 33
34# Work around bugs in pre-3.0 UWIN ksh.
35$as_unset ENV MAIL MAILPATH
36PS1='$ '
37PS2='> '
38PS4='+ '
39
40# NLS nuisances.
41for as_var in \
42 LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
43 LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
44 LC_TELEPHONE LC_TIME
45do
924b6140 46 if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
98d15063 47 eval $as_var=C; export $as_var
48 else
49 $as_unset $as_var
50 fi
51done
52
53# Required to use basename.
54if expr a : '\(a\)' >/dev/null 2>&1; then
55 as_expr=expr
56else
57 as_expr=false
58fi
59
60if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
61 as_basename=basename
62else
63 as_basename=false
64fi
6a161fa9 65
66
67# Name of the executable.
98d15063 68as_me=`$as_basename "$0" ||
6a161fa9 69$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
70 X"$0" : 'X\(//\)$' \| \
71 X"$0" : 'X\(/\)$' \| \
72 . : '\(.\)' 2>/dev/null ||
73echo X/"$0" |
74 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
75 /^X\/\(\/\/\)$/{ s//\1/; q; }
76 /^X\/\(\/\).*/{ s//\1/; q; }
77 s/.*/./; q'`
78
98d15063 79
6a161fa9 80# PATH needs CR, and LINENO needs CR and PATH.
81# Avoid depending upon Character Ranges.
82as_cr_letters='abcdefghijklmnopqrstuvwxyz'
83as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
84as_cr_Letters=$as_cr_letters$as_cr_LETTERS
85as_cr_digits='0123456789'
86as_cr_alnum=$as_cr_Letters$as_cr_digits
87
88# The user is always right.
89if test "${PATH_SEPARATOR+set}" != set; then
98d15063 90 echo "#! /bin/sh" >conf$$.sh
91 echo "exit 0" >>conf$$.sh
92 chmod +x conf$$.sh
93 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
6a161fa9 94 PATH_SEPARATOR=';'
95 else
96 PATH_SEPARATOR=:
97 fi
98d15063 98 rm -f conf$$.sh
6a161fa9 99fi
100
101
102 as_lineno_1=$LINENO
103 as_lineno_2=$LINENO
104 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
105 test "x$as_lineno_1" != "x$as_lineno_2" &&
106 test "x$as_lineno_3" = "x$as_lineno_2" || {
107 # Find who we are. Look in the path if we contain no path at all
108 # relative or not.
109 case $0 in
110 *[\\/]* ) as_myself=$0 ;;
111 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
112for as_dir in $PATH
113do
114 IFS=$as_save_IFS
115 test -z "$as_dir" && as_dir=.
116 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
117done
118
119 ;;
120 esac
121 # We did not find ourselves, most probably we were run as `sh COMMAND'
122 # in which case we are not to be found in the path.
123 if test "x$as_myself" = x; then
124 as_myself=$0
125 fi
126 if test ! -f "$as_myself"; then
127 { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
128 { (exit 1); exit 1; }; }
129 fi
130 case $CONFIG_SHELL in
131 '')
132 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
133for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
134do
135 IFS=$as_save_IFS
136 test -z "$as_dir" && as_dir=.
137 for as_base in sh bash ksh sh5; do
138 case $as_dir in
139 /*)
140 if ("$as_dir/$as_base" -c '
141 as_lineno_1=$LINENO
142 as_lineno_2=$LINENO
143 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
144 test "x$as_lineno_1" != "x$as_lineno_2" &&
145 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
98d15063 146 $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
147 $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
6a161fa9 148 CONFIG_SHELL=$as_dir/$as_base
149 export CONFIG_SHELL
150 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
151 fi;;
152 esac
153 done
154done
155;;
156 esac
157
158 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
159 # uniformly replaced by the line number. The first 'sed' inserts a
160 # line-number line before each line; the second 'sed' does the real
161 # work. The second script uses 'N' to pair each line-number line
162 # with the numbered line, and appends trailing '-' during
163 # substitution so that $LINENO is not a special case at line end.
164 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
165 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
166 sed '=' <$as_myself |
167 sed '
168 N
169 s,$,-,
170 : loop
171 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
172 t loop
173 s,-$,,
174 s,^['$as_cr_digits']*\n,,
175 ' >$as_me.lineno &&
176 chmod +x $as_me.lineno ||
177 { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
178 { (exit 1); exit 1; }; }
179
180 # Don't try to exec as it changes $[0], causing all sort of problems
181 # (the dirname of $[0] is not the place where we might find the
182 # original and so on. Autoconf is especially sensible to this).
183 . ./$as_me.lineno
184 # Exit status is that of the last command.
185 exit
186}
187
188
189case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
190 *c*,-n*) ECHO_N= ECHO_C='
191' ECHO_T=' ' ;;
192 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
193 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
194esac
195
196if expr a : '\(a\)' >/dev/null 2>&1; then
197 as_expr=expr
198else
199 as_expr=false
200fi
201
202rm -f conf$$ conf$$.exe conf$$.file
203echo >conf$$.file
204if ln -s conf$$.file conf$$ 2>/dev/null; then
205 # We could just check for DJGPP; but this test a) works b) is more generic
206 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
207 if test -f conf$$.exe; then
208 # Don't use ln at all; we don't have any links
209 as_ln_s='cp -p'
210 else
211 as_ln_s='ln -s'
212 fi
213elif ln conf$$.file conf$$ 2>/dev/null; then
214 as_ln_s=ln
215else
216 as_ln_s='cp -p'
217fi
218rm -f conf$$ conf$$.exe conf$$.file
219
98d15063 220if mkdir -p . 2>/dev/null; then
221 as_mkdir_p=:
222else
924b6140 223 test -d ./-p && rmdir ./-p
98d15063 224 as_mkdir_p=false
225fi
226
6a161fa9 227as_executable_p="test -f"
228
229# Sed expression to map a string onto a valid CPP name.
924b6140 230as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
6a161fa9 231
232# Sed expression to map a string onto a valid variable name.
924b6140 233as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
6a161fa9 234
235
236# IFS
237# We need space, tab and new line, in precisely that order.
238as_nl='
239'
240IFS=" $as_nl"
241
242# CDPATH.
98d15063 243$as_unset CDPATH
6a161fa9 244
245
246# Name of the host.
247# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
248# so uname gets run too.
249ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
250
251exec 6>&1
252
253#
254# Initializations.
255#
256ac_default_prefix=/usr/local
98d15063 257ac_config_libobj_dir=.
6a161fa9 258cross_compiling=no
259subdirs=
260MFLAGS=
261MAKEFLAGS=
262SHELL=${CONFIG_SHELL-/bin/sh}
263
264# Maximum number of lines to put in a shell here document.
265# This variable seems obsolete. It should probably be removed, and
266# only ac_max_sed_lines should be used.
267: ${ac_max_here_lines=38}
268
269# Identity of this package.
3b1139cb 270PACKAGE_NAME='GRUB'
271PACKAGE_TARNAME='grub'
5f97350b 272PACKAGE_VERSION='1.93'
273PACKAGE_STRING='GRUB 1.93'
3b1139cb 274PACKAGE_BUGREPORT='bug-grub@gnu.org'
6a161fa9 275
4b13b216 276ac_unique_file="include/grub/dl.h"
6a161fa9 277# Factoring default headers for most tests.
278ac_includes_default="\
279#include <stdio.h>
280#if HAVE_SYS_TYPES_H
281# include <sys/types.h>
282#endif
283#if HAVE_SYS_STAT_H
284# include <sys/stat.h>
285#endif
286#if STDC_HEADERS
287# include <stdlib.h>
288# include <stddef.h>
289#else
290# if HAVE_STDLIB_H
291# include <stdlib.h>
292# endif
293#endif
294#if HAVE_STRING_H
295# if !STDC_HEADERS && HAVE_MEMORY_H
296# include <memory.h>
297# endif
298# include <string.h>
299#endif
300#if HAVE_STRINGS_H
301# include <strings.h>
302#endif
303#if HAVE_INTTYPES_H
304# include <inttypes.h>
305#else
306# if HAVE_STDINT_H
307# include <stdint.h>
308# endif
309#endif
310#if HAVE_UNISTD_H
311# include <unistd.h>
312#endif"
313
daac212a 314ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT YACC INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA SET_MAKE OBJCOPY ac_ct_OBJCOPY STRIP ac_ct_STRIP NM ac_ct_NM LD ac_ct_LD RUBY BUILD_CC CPP EGREP LIBLZO LIBCURSES LIBOBJS LTLIBOBJS'
98d15063 315ac_subst_files=''
6a161fa9 316
317# Initialize some variables set by options.
318ac_init_help=
319ac_init_version=false
320# The variables have the same names as the options, with
321# dashes changed to underlines.
322cache_file=/dev/null
323exec_prefix=NONE
324no_create=
325no_recursion=
326prefix=NONE
327program_prefix=NONE
328program_suffix=NONE
329program_transform_name=s,x,x,
330silent=
331site=
332srcdir=
333verbose=
334x_includes=NONE
335x_libraries=NONE
336
337# Installation directory options.
338# These are left unexpanded so users can "make install exec_prefix=/foo"
339# and all the variables that are supposed to be based on exec_prefix
340# by default will actually change.
341# Use braces instead of parens because sh, perl, etc. also accept them.
342bindir='${exec_prefix}/bin'
343sbindir='${exec_prefix}/sbin'
344libexecdir='${exec_prefix}/libexec'
345datadir='${prefix}/share'
346sysconfdir='${prefix}/etc'
347sharedstatedir='${prefix}/com'
348localstatedir='${prefix}/var'
349libdir='${exec_prefix}/lib'
350includedir='${prefix}/include'
351oldincludedir='/usr/include'
352infodir='${prefix}/info'
353mandir='${prefix}/man'
354
355ac_prev=
356for ac_option
357do
358 # If the previous option needs an argument, assign it.
359 if test -n "$ac_prev"; then
360 eval "$ac_prev=\$ac_option"
361 ac_prev=
362 continue
363 fi
364
365 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
366
367 # Accept the important Cygnus configure options, so we can diagnose typos.
368
369 case $ac_option in
370
371 -bindir | --bindir | --bindi | --bind | --bin | --bi)
372 ac_prev=bindir ;;
373 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
374 bindir=$ac_optarg ;;
375
376 -build | --build | --buil | --bui | --bu)
377 ac_prev=build_alias ;;
378 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
379 build_alias=$ac_optarg ;;
380
381 -cache-file | --cache-file | --cache-fil | --cache-fi \
382 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
383 ac_prev=cache_file ;;
384 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
385 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
386 cache_file=$ac_optarg ;;
387
388 --config-cache | -C)
389 cache_file=config.cache ;;
390
391 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
392 ac_prev=datadir ;;
393 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
394 | --da=*)
395 datadir=$ac_optarg ;;
396
397 -disable-* | --disable-*)
398 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
399 # Reject names that are not valid shell variable names.
400 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
401 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
402 { (exit 1); exit 1; }; }
403 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
404 eval "enable_$ac_feature=no" ;;
405
406 -enable-* | --enable-*)
407 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
408 # Reject names that are not valid shell variable names.
409 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
410 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
411 { (exit 1); exit 1; }; }
412 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
413 case $ac_option in
414 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
415 *) ac_optarg=yes ;;
416 esac
417 eval "enable_$ac_feature='$ac_optarg'" ;;
418
419 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
420 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
421 | --exec | --exe | --ex)
422 ac_prev=exec_prefix ;;
423 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
424 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
425 | --exec=* | --exe=* | --ex=*)
426 exec_prefix=$ac_optarg ;;
427
428 -gas | --gas | --ga | --g)
429 # Obsolete; use --with-gas.
430 with_gas=yes ;;
431
432 -help | --help | --hel | --he | -h)
433 ac_init_help=long ;;
434 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
435 ac_init_help=recursive ;;
436 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
437 ac_init_help=short ;;
438
439 -host | --host | --hos | --ho)
440 ac_prev=host_alias ;;
441 -host=* | --host=* | --hos=* | --ho=*)
442 host_alias=$ac_optarg ;;
443
444 -includedir | --includedir | --includedi | --included | --include \
445 | --includ | --inclu | --incl | --inc)
446 ac_prev=includedir ;;
447 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
448 | --includ=* | --inclu=* | --incl=* | --inc=*)
449 includedir=$ac_optarg ;;
450
451 -infodir | --infodir | --infodi | --infod | --info | --inf)
452 ac_prev=infodir ;;
453 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
454 infodir=$ac_optarg ;;
455
456 -libdir | --libdir | --libdi | --libd)
457 ac_prev=libdir ;;
458 -libdir=* | --libdir=* | --libdi=* | --libd=*)
459 libdir=$ac_optarg ;;
460
461 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
462 | --libexe | --libex | --libe)
463 ac_prev=libexecdir ;;
464 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
465 | --libexe=* | --libex=* | --libe=*)
466 libexecdir=$ac_optarg ;;
467
468 -localstatedir | --localstatedir | --localstatedi | --localstated \
469 | --localstate | --localstat | --localsta | --localst \
470 | --locals | --local | --loca | --loc | --lo)
471 ac_prev=localstatedir ;;
472 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
473 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
474 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
475 localstatedir=$ac_optarg ;;
476
477 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
478 ac_prev=mandir ;;
479 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
480 mandir=$ac_optarg ;;
481
482 -nfp | --nfp | --nf)
483 # Obsolete; use --without-fp.
484 with_fp=no ;;
485
486 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
487 | --no-cr | --no-c | -n)
488 no_create=yes ;;
489
490 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
491 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
492 no_recursion=yes ;;
493
494 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
495 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
496 | --oldin | --oldi | --old | --ol | --o)
497 ac_prev=oldincludedir ;;
498 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
499 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
500 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
501 oldincludedir=$ac_optarg ;;
502
503 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
504 ac_prev=prefix ;;
505 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
506 prefix=$ac_optarg ;;
507
508 -program-prefix | --program-prefix | --program-prefi | --program-pref \
509 | --program-pre | --program-pr | --program-p)
510 ac_prev=program_prefix ;;
511 -program-prefix=* | --program-prefix=* | --program-prefi=* \
512 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
513 program_prefix=$ac_optarg ;;
514
515 -program-suffix | --program-suffix | --program-suffi | --program-suff \
516 | --program-suf | --program-su | --program-s)
517 ac_prev=program_suffix ;;
518 -program-suffix=* | --program-suffix=* | --program-suffi=* \
519 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
520 program_suffix=$ac_optarg ;;
521
522 -program-transform-name | --program-transform-name \
523 | --program-transform-nam | --program-transform-na \
524 | --program-transform-n | --program-transform- \
525 | --program-transform | --program-transfor \
526 | --program-transfo | --program-transf \
527 | --program-trans | --program-tran \
528 | --progr-tra | --program-tr | --program-t)
529 ac_prev=program_transform_name ;;
530 -program-transform-name=* | --program-transform-name=* \
531 | --program-transform-nam=* | --program-transform-na=* \
532 | --program-transform-n=* | --program-transform-=* \
533 | --program-transform=* | --program-transfor=* \
534 | --program-transfo=* | --program-transf=* \
535 | --program-trans=* | --program-tran=* \
536 | --progr-tra=* | --program-tr=* | --program-t=*)
537 program_transform_name=$ac_optarg ;;
538
539 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
540 | -silent | --silent | --silen | --sile | --sil)
541 silent=yes ;;
542
543 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
544 ac_prev=sbindir ;;
545 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
546 | --sbi=* | --sb=*)
547 sbindir=$ac_optarg ;;
548
549 -sharedstatedir | --sharedstatedir | --sharedstatedi \
550 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
551 | --sharedst | --shareds | --shared | --share | --shar \
552 | --sha | --sh)
553 ac_prev=sharedstatedir ;;
554 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
555 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
556 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
557 | --sha=* | --sh=*)
558 sharedstatedir=$ac_optarg ;;
559
560 -site | --site | --sit)
561 ac_prev=site ;;
562 -site=* | --site=* | --sit=*)
563 site=$ac_optarg ;;
564
565 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
566 ac_prev=srcdir ;;
567 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
568 srcdir=$ac_optarg ;;
569
570 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
571 | --syscon | --sysco | --sysc | --sys | --sy)
572 ac_prev=sysconfdir ;;
573 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
574 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
575 sysconfdir=$ac_optarg ;;
576
577 -target | --target | --targe | --targ | --tar | --ta | --t)
578 ac_prev=target_alias ;;
579 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
580 target_alias=$ac_optarg ;;
581
582 -v | -verbose | --verbose | --verbos | --verbo | --verb)
583 verbose=yes ;;
584
585 -version | --version | --versio | --versi | --vers | -V)
586 ac_init_version=: ;;
587
588 -with-* | --with-*)
589 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
590 # Reject names that are not valid shell variable names.
591 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
592 { echo "$as_me: error: invalid package name: $ac_package" >&2
593 { (exit 1); exit 1; }; }
594 ac_package=`echo $ac_package| sed 's/-/_/g'`
595 case $ac_option in
596 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
597 *) ac_optarg=yes ;;
598 esac
599 eval "with_$ac_package='$ac_optarg'" ;;
600
601 -without-* | --without-*)
602 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
603 # Reject names that are not valid shell variable names.
604 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
605 { echo "$as_me: error: invalid package name: $ac_package" >&2
606 { (exit 1); exit 1; }; }
607 ac_package=`echo $ac_package | sed 's/-/_/g'`
608 eval "with_$ac_package=no" ;;
609
610 --x)
611 # Obsolete; use --with-x.
612 with_x=yes ;;
613
614 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
615 | --x-incl | --x-inc | --x-in | --x-i)
616 ac_prev=x_includes ;;
617 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
618 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
619 x_includes=$ac_optarg ;;
620
621 -x-libraries | --x-libraries | --x-librarie | --x-librari \
622 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
623 ac_prev=x_libraries ;;
624 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
625 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
626 x_libraries=$ac_optarg ;;
627
628 -*) { echo "$as_me: error: unrecognized option: $ac_option
629Try \`$0 --help' for more information." >&2
630 { (exit 1); exit 1; }; }
631 ;;
632
633 *=*)
634 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
635 # Reject names that are not valid shell variable names.
636 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
637 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
638 { (exit 1); exit 1; }; }
639 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
640 eval "$ac_envvar='$ac_optarg'"
641 export $ac_envvar ;;
642
643 *)
644 # FIXME: should be removed in autoconf 3.0.
645 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
646 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
647 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
648 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
649 ;;
650
651 esac
652done
653
654if test -n "$ac_prev"; then
655 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
656 { echo "$as_me: error: missing argument to $ac_option" >&2
657 { (exit 1); exit 1; }; }
658fi
659
660# Be sure to have absolute paths.
661for ac_var in exec_prefix prefix
662do
663 eval ac_val=$`echo $ac_var`
664 case $ac_val in
665 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
666 *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
667 { (exit 1); exit 1; }; };;
668 esac
669done
670
671# Be sure to have absolute paths.
672for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
924b6140 673 localstatedir libdir includedir oldincludedir infodir mandir
6a161fa9 674do
675 eval ac_val=$`echo $ac_var`
676 case $ac_val in
677 [\\/$]* | ?:[\\/]* ) ;;
678 *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
679 { (exit 1); exit 1; }; };;
680 esac
681done
682
683# There might be people who depend on the old broken behavior: `$host'
684# used to hold the argument of --host etc.
685# FIXME: To remove some day.
686build=$build_alias
687host=$host_alias
688target=$target_alias
689
690# FIXME: To remove some day.
691if test "x$host_alias" != x; then
692 if test "x$build_alias" = x; then
693 cross_compiling=maybe
694 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
695 If a cross compiler is detected then cross compile mode will be used." >&2
696 elif test "x$build_alias" != "x$host_alias"; then
697 cross_compiling=yes
698 fi
699fi
700
701ac_tool_prefix=
702test -n "$host_alias" && ac_tool_prefix=$host_alias-
703
704test "$silent" = yes && exec 6>/dev/null
705
706
707# Find the source files, if location was not specified.
708if test -z "$srcdir"; then
709 ac_srcdir_defaulted=yes
710 # Try the directory containing this script, then its parent.
711 ac_confdir=`(dirname "$0") 2>/dev/null ||
712$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
924b6140 713 X"$0" : 'X\(//\)[^/]' \| \
714 X"$0" : 'X\(//\)$' \| \
715 X"$0" : 'X\(/\)' \| \
716 . : '\(.\)' 2>/dev/null ||
6a161fa9 717echo X"$0" |
718 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
719 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
720 /^X\(\/\/\)$/{ s//\1/; q; }
721 /^X\(\/\).*/{ s//\1/; q; }
722 s/.*/./; q'`
723 srcdir=$ac_confdir
724 if test ! -r $srcdir/$ac_unique_file; then
725 srcdir=..
726 fi
727else
728 ac_srcdir_defaulted=no
729fi
730if test ! -r $srcdir/$ac_unique_file; then
731 if test "$ac_srcdir_defaulted" = yes; then
732 { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
733 { (exit 1); exit 1; }; }
734 else
735 { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
736 { (exit 1); exit 1; }; }
737 fi
738fi
98d15063 739(cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null ||
740 { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2
741 { (exit 1); exit 1; }; }
6a161fa9 742srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
743ac_env_build_alias_set=${build_alias+set}
744ac_env_build_alias_value=$build_alias
745ac_cv_env_build_alias_set=${build_alias+set}
746ac_cv_env_build_alias_value=$build_alias
747ac_env_host_alias_set=${host_alias+set}
748ac_env_host_alias_value=$host_alias
749ac_cv_env_host_alias_set=${host_alias+set}
750ac_cv_env_host_alias_value=$host_alias
751ac_env_target_alias_set=${target_alias+set}
752ac_env_target_alias_value=$target_alias
753ac_cv_env_target_alias_set=${target_alias+set}
754ac_cv_env_target_alias_value=$target_alias
755ac_env_CC_set=${CC+set}
756ac_env_CC_value=$CC
757ac_cv_env_CC_set=${CC+set}
758ac_cv_env_CC_value=$CC
759ac_env_CFLAGS_set=${CFLAGS+set}
760ac_env_CFLAGS_value=$CFLAGS
761ac_cv_env_CFLAGS_set=${CFLAGS+set}
762ac_cv_env_CFLAGS_value=$CFLAGS
763ac_env_LDFLAGS_set=${LDFLAGS+set}
764ac_env_LDFLAGS_value=$LDFLAGS
765ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
766ac_cv_env_LDFLAGS_value=$LDFLAGS
767ac_env_CPPFLAGS_set=${CPPFLAGS+set}
768ac_env_CPPFLAGS_value=$CPPFLAGS
769ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
770ac_cv_env_CPPFLAGS_value=$CPPFLAGS
771ac_env_CPP_set=${CPP+set}
772ac_env_CPP_value=$CPP
773ac_cv_env_CPP_set=${CPP+set}
774ac_cv_env_CPP_value=$CPP
775
776#
777# Report the --help message.
778#
779if test "$ac_init_help" = "long"; then
780 # Omit some internal or obsolete options to make the list less imposing.
781 # This message is too long to be a string in the A/UX 3.1 sh.
782 cat <<_ACEOF
5f97350b 783\`configure' configures GRUB 1.93 to adapt to many kinds of systems.
6a161fa9 784
785Usage: $0 [OPTION]... [VAR=VALUE]...
786
787To assign environment variables (e.g., CC, CFLAGS...), specify them as
788VAR=VALUE. See below for descriptions of some of the useful variables.
789
790Defaults for the options are specified in brackets.
791
792Configuration:
793 -h, --help display this help and exit
794 --help=short display options specific to this package
795 --help=recursive display the short help of all the included packages
796 -V, --version display version information and exit
797 -q, --quiet, --silent do not print \`checking...' messages
798 --cache-file=FILE cache test results in FILE [disabled]
799 -C, --config-cache alias for \`--cache-file=config.cache'
800 -n, --no-create do not create output files
801 --srcdir=DIR find the sources in DIR [configure dir or \`..']
802
803_ACEOF
804
805 cat <<_ACEOF
806Installation directories:
807 --prefix=PREFIX install architecture-independent files in PREFIX
924b6140 808 [$ac_default_prefix]
6a161fa9 809 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
924b6140 810 [PREFIX]
6a161fa9 811
812By default, \`make install' will install all the files in
813\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
814an installation prefix other than \`$ac_default_prefix' using \`--prefix',
815for instance \`--prefix=\$HOME'.
816
817For better control, use the options below.
818
819Fine tuning of the installation directories:
820 --bindir=DIR user executables [EPREFIX/bin]
821 --sbindir=DIR system admin executables [EPREFIX/sbin]
822 --libexecdir=DIR program executables [EPREFIX/libexec]
823 --datadir=DIR read-only architecture-independent data [PREFIX/share]
824 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
825 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
826 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
827 --libdir=DIR object code libraries [EPREFIX/lib]
828 --includedir=DIR C header files [PREFIX/include]
829 --oldincludedir=DIR C header files for non-gcc [/usr/include]
830 --infodir=DIR info documentation [PREFIX/info]
831 --mandir=DIR man documentation [PREFIX/man]
832_ACEOF
833
834 cat <<\_ACEOF
835
836System types:
837 --build=BUILD configure for building on BUILD [guessed]
838 --host=HOST cross-compile to build programs to run on HOST [BUILD]
839_ACEOF
840fi
841
842if test -n "$ac_init_help"; then
843 case $ac_init_help in
5f97350b 844 short | recursive ) echo "Configuration of GRUB 1.93:";;
6a161fa9 845 esac
846 cat <<\_ACEOF
847
a35eed7c 848Optional Features:
849 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
850 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
851 --disable-largefile omit support for large files
852
6a161fa9 853Some influential environment variables:
854 CC C compiler command
855 CFLAGS C compiler flags
856 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
857 nonstandard directory <lib dir>
858 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
859 headers in a nonstandard directory <include dir>
860 CPP C preprocessor
861
862Use these variables to override the choices made by `configure' or to help
863it to find libraries and programs with nonstandard names/locations.
864
3b1139cb 865Report bugs to <bug-grub@gnu.org>.
6a161fa9 866_ACEOF
867fi
868
869if test "$ac_init_help" = "recursive"; then
870 # If there are subdirs, report their specific --help.
871 ac_popdir=`pwd`
872 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
873 test -d $ac_dir || continue
874 ac_builddir=.
875
876if test "$ac_dir" != .; then
877 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
878 # A "../" for each directory in $ac_dir_suffix.
879 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
880else
881 ac_dir_suffix= ac_top_builddir=
882fi
883
884case $srcdir in
885 .) # No --srcdir option. We are building in place.
886 ac_srcdir=.
887 if test -z "$ac_top_builddir"; then
888 ac_top_srcdir=.
889 else
890 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
891 fi ;;
892 [\\/]* | ?:[\\/]* ) # Absolute path.
893 ac_srcdir=$srcdir$ac_dir_suffix;
894 ac_top_srcdir=$srcdir ;;
895 *) # Relative path.
896 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
897 ac_top_srcdir=$ac_top_builddir$srcdir ;;
898esac
924b6140 899
900# Do not use `cd foo && pwd` to compute absolute paths, because
901# the directories may not exist.
902case `pwd` in
903.) ac_abs_builddir="$ac_dir";;
904*)
905 case "$ac_dir" in
906 .) ac_abs_builddir=`pwd`;;
907 [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
908 *) ac_abs_builddir=`pwd`/"$ac_dir";;
909 esac;;
910esac
911case $ac_abs_builddir in
912.) ac_abs_top_builddir=${ac_top_builddir}.;;
913*)
914 case ${ac_top_builddir}. in
915 .) ac_abs_top_builddir=$ac_abs_builddir;;
916 [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
917 *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
918 esac;;
919esac
920case $ac_abs_builddir in
921.) ac_abs_srcdir=$ac_srcdir;;
922*)
923 case $ac_srcdir in
924 .) ac_abs_srcdir=$ac_abs_builddir;;
925 [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
926 *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
927 esac;;
928esac
929case $ac_abs_builddir in
930.) ac_abs_top_srcdir=$ac_top_srcdir;;
931*)
932 case $ac_top_srcdir in
933 .) ac_abs_top_srcdir=$ac_abs_builddir;;
934 [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
935 *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
936 esac;;
937esac
6a161fa9 938
939 cd $ac_dir
940 # Check for guested configure; otherwise get Cygnus style configure.
941 if test -f $ac_srcdir/configure.gnu; then
942 echo
943 $SHELL $ac_srcdir/configure.gnu --help=recursive
944 elif test -f $ac_srcdir/configure; then
945 echo
946 $SHELL $ac_srcdir/configure --help=recursive
947 elif test -f $ac_srcdir/configure.ac ||
924b6140 948 test -f $ac_srcdir/configure.in; then
6a161fa9 949 echo
950 $ac_configure --help
951 else
952 echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
953 fi
144f1f98 954 cd "$ac_popdir"
6a161fa9 955 done
956fi
957
958test -n "$ac_init_help" && exit 0
959if $ac_init_version; then
960 cat <<\_ACEOF
5f97350b 961GRUB configure 1.93
924b6140 962generated by GNU Autoconf 2.59
6a161fa9 963
924b6140 964Copyright (C) 2003 Free Software Foundation, Inc.
6a161fa9 965This configure script is free software; the Free Software Foundation
966gives unlimited permission to copy, distribute and modify it.
967_ACEOF
968 exit 0
969fi
970exec 5>config.log
971cat >&5 <<_ACEOF
972This file contains any messages produced by compilers while
973running configure, to aid debugging if configure makes a mistake.
974
5f97350b 975It was created by GRUB $as_me 1.93, which was
924b6140 976generated by GNU Autoconf 2.59. Invocation command line was
6a161fa9 977
978 $ $0 $@
979
980_ACEOF
981{
982cat <<_ASUNAME
983## --------- ##
984## Platform. ##
985## --------- ##
986
987hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
988uname -m = `(uname -m) 2>/dev/null || echo unknown`
989uname -r = `(uname -r) 2>/dev/null || echo unknown`
990uname -s = `(uname -s) 2>/dev/null || echo unknown`
991uname -v = `(uname -v) 2>/dev/null || echo unknown`
992
993/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
994/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
995
996/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
997/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
998/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
999hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
1000/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
1001/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
1002/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
1003
1004_ASUNAME
1005
1006as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1007for as_dir in $PATH
1008do
1009 IFS=$as_save_IFS
1010 test -z "$as_dir" && as_dir=.
1011 echo "PATH: $as_dir"
1012done
1013
1014} >&5
1015
1016cat >&5 <<_ACEOF
1017
1018
1019## ----------- ##
1020## Core tests. ##
1021## ----------- ##
1022
1023_ACEOF
1024
1025
1026# Keep a trace of the command line.
1027# Strip out --no-create and --no-recursion so they do not pile up.
98d15063 1028# Strip out --silent because we don't want to record it for future runs.
6a161fa9 1029# Also quote any args containing shell meta-characters.
98d15063 1030# Make two passes to allow for proper duplicate-argument suppression.
6a161fa9 1031ac_configure_args=
98d15063 1032ac_configure_args0=
1033ac_configure_args1=
6a161fa9 1034ac_sep=
98d15063 1035ac_must_keep_next=false
1036for ac_pass in 1 2
6a161fa9 1037do
98d15063 1038 for ac_arg
1039 do
1040 case $ac_arg in
1041 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1042 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1043 | -silent | --silent | --silen | --sile | --sil)
1044 continue ;;
1045 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1046 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1047 esac
1048 case $ac_pass in
1049 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1050 2)
1051 ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1052 if test $ac_must_keep_next = true; then
924b6140 1053 ac_must_keep_next=false # Got value, back to normal.
98d15063 1054 else
924b6140 1055 case $ac_arg in
1056 *=* | --config-cache | -C | -disable-* | --disable-* \
1057 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1058 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1059 | -with-* | --with-* | -without-* | --without-* | --x)
1060 case "$ac_configure_args0 " in
1061 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1062 esac
1063 ;;
1064 -* ) ac_must_keep_next=true ;;
1065 esac
98d15063 1066 fi
1067 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1068 # Get rid of the leading space.
1069 ac_sep=" "
1070 ;;
1071 esac
1072 done
6a161fa9 1073done
98d15063 1074$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1075$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
6a161fa9 1076
1077# When interrupted or exit'd, cleanup temporary files, and complete
1078# config.log. We remove comments because anyway the quotes in there
1079# would cause problems or look ugly.
1080# WARNING: Be sure not to use single quotes in there, as some shells,
1081# such as our DU 5.0 friend, will then `close' the trap.
1082trap 'exit_status=$?
1083 # Save into config.log some information that might help in debugging.
1084 {
1085 echo
98d15063 1086
6a161fa9 1087 cat <<\_ASBOX
1088## ---------------- ##
1089## Cache variables. ##
1090## ---------------- ##
1091_ASBOX
1092 echo
1093 # The following way of writing the cache mishandles newlines in values,
1094{
1095 (set) 2>&1 |
1096 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1097 *ac_space=\ *)
1098 sed -n \
924b6140 1099 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1100 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
6a161fa9 1101 ;;
1102 *)
1103 sed -n \
924b6140 1104 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
6a161fa9 1105 ;;
1106 esac;
1107}
1108 echo
98d15063 1109
1110 cat <<\_ASBOX
1111## ----------------- ##
1112## Output variables. ##
1113## ----------------- ##
1114_ASBOX
1115 echo
1116 for ac_var in $ac_subst_vars
1117 do
1118 eval ac_val=$`echo $ac_var`
1119 echo "$ac_var='"'"'$ac_val'"'"'"
1120 done | sort
1121 echo
1122
1123 if test -n "$ac_subst_files"; then
1124 cat <<\_ASBOX
1125## ------------- ##
1126## Output files. ##
1127## ------------- ##
1128_ASBOX
1129 echo
1130 for ac_var in $ac_subst_files
1131 do
1132 eval ac_val=$`echo $ac_var`
924b6140 1133 echo "$ac_var='"'"'$ac_val'"'"'"
98d15063 1134 done | sort
1135 echo
1136 fi
1137
6a161fa9 1138 if test -s confdefs.h; then
1139 cat <<\_ASBOX
1140## ----------- ##
1141## confdefs.h. ##
1142## ----------- ##
1143_ASBOX
1144 echo
98d15063 1145 sed "/^$/d" confdefs.h | sort
6a161fa9 1146 echo
1147 fi
1148 test "$ac_signal" != 0 &&
1149 echo "$as_me: caught signal $ac_signal"
1150 echo "$as_me: exit $exit_status"
1151 } >&5
924b6140 1152 rm -f core *.core &&
6a161fa9 1153 rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1154 exit $exit_status
1155 ' 0
1156for ac_signal in 1 2 13 15; do
1157 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1158done
1159ac_signal=0
1160
1161# confdefs.h avoids OS command line length limits that DEFS can exceed.
1162rm -rf conftest* confdefs.h
1163# AIX cpp loses on an empty file, so make sure it contains at least a newline.
1164echo >confdefs.h
1165
1166# Predefined preprocessor variables.
1167
1168cat >>confdefs.h <<_ACEOF
1169#define PACKAGE_NAME "$PACKAGE_NAME"
1170_ACEOF
1171
1172
1173cat >>confdefs.h <<_ACEOF
1174#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1175_ACEOF
1176
1177
1178cat >>confdefs.h <<_ACEOF
1179#define PACKAGE_VERSION "$PACKAGE_VERSION"
1180_ACEOF
1181
1182
1183cat >>confdefs.h <<_ACEOF
1184#define PACKAGE_STRING "$PACKAGE_STRING"
1185_ACEOF
1186
1187
1188cat >>confdefs.h <<_ACEOF
1189#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1190_ACEOF
1191
1192
1193# Let the site file select an alternate cache file if it wants to.
1194# Prefer explicitly selected file to automatically selected ones.
1195if test -z "$CONFIG_SITE"; then
1196 if test "x$prefix" != xNONE; then
1197 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1198 else
1199 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1200 fi
1201fi
1202for ac_site_file in $CONFIG_SITE; do
1203 if test -r "$ac_site_file"; then
1204 { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1205echo "$as_me: loading site script $ac_site_file" >&6;}
1206 sed 's/^/| /' "$ac_site_file" >&5
1207 . "$ac_site_file"
1208 fi
1209done
1210
1211if test -r "$cache_file"; then
1212 # Some versions of bash will fail to source /dev/null (special
1213 # files actually), so we avoid doing that.
1214 if test -f "$cache_file"; then
1215 { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1216echo "$as_me: loading cache $cache_file" >&6;}
1217 case $cache_file in
1218 [\\/]* | ?:[\\/]* ) . $cache_file;;
1219 *) . ./$cache_file;;
1220 esac
1221 fi
1222else
1223 { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1224echo "$as_me: creating cache $cache_file" >&6;}
1225 >$cache_file
1226fi
1227
1228# Check that the precious variables saved in the cache have kept the same
1229# value.
1230ac_cache_corrupted=false
1231for ac_var in `(set) 2>&1 |
924b6140 1232 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
6a161fa9 1233 eval ac_old_set=\$ac_cv_env_${ac_var}_set
1234 eval ac_new_set=\$ac_env_${ac_var}_set
1235 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1236 eval ac_new_val="\$ac_env_${ac_var}_value"
1237 case $ac_old_set,$ac_new_set in
1238 set,)
1239 { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1240echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1241 ac_cache_corrupted=: ;;
1242 ,set)
1243 { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1244echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1245 ac_cache_corrupted=: ;;
1246 ,);;
1247 *)
1248 if test "x$ac_old_val" != "x$ac_new_val"; then
924b6140 1249 { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
6a161fa9 1250echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
924b6140 1251 { echo "$as_me:$LINENO: former value: $ac_old_val" >&5
6a161fa9 1252echo "$as_me: former value: $ac_old_val" >&2;}
924b6140 1253 { echo "$as_me:$LINENO: current value: $ac_new_val" >&5
6a161fa9 1254echo "$as_me: current value: $ac_new_val" >&2;}
924b6140 1255 ac_cache_corrupted=:
6a161fa9 1256 fi;;
1257 esac
1258 # Pass precious variables to config.status.
1259 if test "$ac_new_set" = set; then
1260 case $ac_new_val in
1261 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1262 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1263 *) ac_arg=$ac_var=$ac_new_val ;;
1264 esac
1265 case " $ac_configure_args " in
1266 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
1267 *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1268 esac
1269 fi
1270done
1271if $ac_cache_corrupted; then
1272 { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1273echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1274 { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1275echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1276 { (exit 1); exit 1; }; }
1277fi
1278
1279ac_ext=c
1280ac_cpp='$CPP $CPPFLAGS'
1281ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1282ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1283ac_compiler_gnu=$ac_cv_c_compiler_gnu
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
98d15063 1312
1313 ac_config_headers="$ac_config_headers config.h"
6a161fa9 1314
1315
1316# Checks for build and host systems.
1317ac_aux_dir=
1318for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1319 if test -f $ac_dir/install-sh; then
1320 ac_aux_dir=$ac_dir
1321 ac_install_sh="$ac_aux_dir/install-sh -c"
1322 break
1323 elif test -f $ac_dir/install.sh; then
1324 ac_aux_dir=$ac_dir
1325 ac_install_sh="$ac_aux_dir/install.sh -c"
1326 break
1327 elif test -f $ac_dir/shtool; then
1328 ac_aux_dir=$ac_dir
1329 ac_install_sh="$ac_aux_dir/shtool install -c"
1330 break
1331 fi
1332done
1333if test -z "$ac_aux_dir"; then
1334 { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1335echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1336 { (exit 1); exit 1; }; }
1337fi
1338ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1339ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1340ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1341
1342# Make sure we can run config.sub.
1343$ac_config_sub sun4 >/dev/null 2>&1 ||
1344 { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
1345echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1346 { (exit 1); exit 1; }; }
1347
1348echo "$as_me:$LINENO: checking build system type" >&5
1349echo $ECHO_N "checking build system type... $ECHO_C" >&6
1350if test "${ac_cv_build+set}" = set; then
1351 echo $ECHO_N "(cached) $ECHO_C" >&6
1352else
1353 ac_cv_build_alias=$build_alias
1354test -z "$ac_cv_build_alias" &&
1355 ac_cv_build_alias=`$ac_config_guess`
1356test -z "$ac_cv_build_alias" &&
1357 { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
1358echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1359 { (exit 1); exit 1; }; }
1360ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1361 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
1362echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
1363 { (exit 1); exit 1; }; }
1364
1365fi
1366echo "$as_me:$LINENO: result: $ac_cv_build" >&5
1367echo "${ECHO_T}$ac_cv_build" >&6
1368build=$ac_cv_build
1369build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1370build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1371build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1372
1373
1374echo "$as_me:$LINENO: checking host system type" >&5
1375echo $ECHO_N "checking host system type... $ECHO_C" >&6
1376if test "${ac_cv_host+set}" = set; then
1377 echo $ECHO_N "(cached) $ECHO_C" >&6
1378else
1379 ac_cv_host_alias=$host_alias
1380test -z "$ac_cv_host_alias" &&
1381 ac_cv_host_alias=$ac_cv_build_alias
1382ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1383 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1384echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1385 { (exit 1); exit 1; }; }
1386
1387fi
1388echo "$as_me:$LINENO: result: $ac_cv_host" >&5
1389echo "${ECHO_T}$ac_cv_host" >&6
1390host=$ac_cv_host
1391host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1392host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1393host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1394
1395
1396
1397case "$host_cpu" in
1398 i[3456]86) host_cpu=i386 ;;
be973c1b 1399 x86_64) host_cpu=i386 biarch32=1 ;;
e56cdf21 1400 powerpc) ;;
be973c1b 1401 powerpc64) host_cpu=powerpc biarch32=1;;
e9211b5d 1402 sparc64) ;;
6a161fa9 1403 *) { { echo "$as_me:$LINENO: error: unsupported CPU type" >&5
1404echo "$as_me: error: unsupported CPU type" >&2;}
1405 { (exit 1); exit 1; }; } ;;
1406esac
1407
1408case "$host_cpu"-"$host_vendor" in
1409 i386-*) host_vendor=pc ;;
e56cdf21 1410 powerpc-*) host_vendor=ieee1275 ;;
e9211b5d 1411 sparc64-*) host_vendor=ieee1275 ;;
6a161fa9 1412 *) { { echo "$as_me:$LINENO: error: unsupported machine type" >&5
1413echo "$as_me: error: unsupported machine type" >&2;}
1414 { (exit 1); exit 1; }; } ;;
1415esac
1416
1417
1418
1419
1420# Checks for programs.
1421if test "x$CFLAGS" = x; then
1422 default_CFLAGS=yes
1423fi
1424
1425ac_ext=c
1426ac_cpp='$CPP $CPPFLAGS'
1427ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1428ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1429ac_compiler_gnu=$ac_cv_c_compiler_gnu
1430if test -n "$ac_tool_prefix"; then
1431 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1432set dummy ${ac_tool_prefix}gcc; ac_word=$2
1433echo "$as_me:$LINENO: checking for $ac_word" >&5
1434echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1435if test "${ac_cv_prog_CC+set}" = set; then
1436 echo $ECHO_N "(cached) $ECHO_C" >&6
1437else
1438 if test -n "$CC"; then
1439 ac_cv_prog_CC="$CC" # Let the user override the test.
1440else
1441as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1442for as_dir in $PATH
1443do
1444 IFS=$as_save_IFS
1445 test -z "$as_dir" && as_dir=.
1446 for ac_exec_ext in '' $ac_executable_extensions; do
1447 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1448 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1449 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1450 break 2
1451 fi
1452done
1453done
1454
1455fi
1456fi
1457CC=$ac_cv_prog_CC
1458if test -n "$CC"; then
1459 echo "$as_me:$LINENO: result: $CC" >&5
1460echo "${ECHO_T}$CC" >&6
1461else
1462 echo "$as_me:$LINENO: result: no" >&5
1463echo "${ECHO_T}no" >&6
1464fi
1465
1466fi
1467if test -z "$ac_cv_prog_CC"; then
1468 ac_ct_CC=$CC
1469 # Extract the first word of "gcc", so it can be a program name with args.
1470set dummy gcc; ac_word=$2
1471echo "$as_me:$LINENO: checking for $ac_word" >&5
1472echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1473if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1474 echo $ECHO_N "(cached) $ECHO_C" >&6
1475else
1476 if test -n "$ac_ct_CC"; then
1477 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1478else
1479as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1480for as_dir in $PATH
1481do
1482 IFS=$as_save_IFS
1483 test -z "$as_dir" && as_dir=.
1484 for ac_exec_ext in '' $ac_executable_extensions; do
1485 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1486 ac_cv_prog_ac_ct_CC="gcc"
1487 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1488 break 2
1489 fi
1490done
1491done
1492
1493fi
1494fi
1495ac_ct_CC=$ac_cv_prog_ac_ct_CC
1496if test -n "$ac_ct_CC"; then
1497 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1498echo "${ECHO_T}$ac_ct_CC" >&6
1499else
1500 echo "$as_me:$LINENO: result: no" >&5
1501echo "${ECHO_T}no" >&6
1502fi
1503
1504 CC=$ac_ct_CC
1505else
1506 CC="$ac_cv_prog_CC"
1507fi
1508
1509if test -z "$CC"; then
1510 if test -n "$ac_tool_prefix"; then
1511 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1512set dummy ${ac_tool_prefix}cc; ac_word=$2
1513echo "$as_me:$LINENO: checking for $ac_word" >&5
1514echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1515if test "${ac_cv_prog_CC+set}" = set; then
1516 echo $ECHO_N "(cached) $ECHO_C" >&6
1517else
1518 if test -n "$CC"; then
1519 ac_cv_prog_CC="$CC" # Let the user override the test.
1520else
1521as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1522for as_dir in $PATH
1523do
1524 IFS=$as_save_IFS
1525 test -z "$as_dir" && as_dir=.
1526 for ac_exec_ext in '' $ac_executable_extensions; do
1527 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1528 ac_cv_prog_CC="${ac_tool_prefix}cc"
1529 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1530 break 2
1531 fi
1532done
1533done
1534
1535fi
1536fi
1537CC=$ac_cv_prog_CC
1538if test -n "$CC"; then
1539 echo "$as_me:$LINENO: result: $CC" >&5
1540echo "${ECHO_T}$CC" >&6
1541else
1542 echo "$as_me:$LINENO: result: no" >&5
1543echo "${ECHO_T}no" >&6
1544fi
1545
1546fi
1547if test -z "$ac_cv_prog_CC"; then
1548 ac_ct_CC=$CC
1549 # Extract the first word of "cc", so it can be a program name with args.
1550set dummy cc; ac_word=$2
1551echo "$as_me:$LINENO: checking for $ac_word" >&5
1552echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1553if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1554 echo $ECHO_N "(cached) $ECHO_C" >&6
1555else
1556 if test -n "$ac_ct_CC"; then
1557 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1558else
1559as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1560for as_dir in $PATH
1561do
1562 IFS=$as_save_IFS
1563 test -z "$as_dir" && as_dir=.
1564 for ac_exec_ext in '' $ac_executable_extensions; do
1565 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1566 ac_cv_prog_ac_ct_CC="cc"
1567 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1568 break 2
1569 fi
1570done
1571done
1572
1573fi
1574fi
1575ac_ct_CC=$ac_cv_prog_ac_ct_CC
1576if test -n "$ac_ct_CC"; then
1577 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1578echo "${ECHO_T}$ac_ct_CC" >&6
1579else
1580 echo "$as_me:$LINENO: result: no" >&5
1581echo "${ECHO_T}no" >&6
1582fi
1583
1584 CC=$ac_ct_CC
1585else
1586 CC="$ac_cv_prog_CC"
1587fi
1588
1589fi
1590if test -z "$CC"; then
1591 # Extract the first word of "cc", so it can be a program name with args.
1592set dummy cc; ac_word=$2
1593echo "$as_me:$LINENO: checking for $ac_word" >&5
1594echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1595if test "${ac_cv_prog_CC+set}" = set; then
1596 echo $ECHO_N "(cached) $ECHO_C" >&6
1597else
1598 if test -n "$CC"; then
1599 ac_cv_prog_CC="$CC" # Let the user override the test.
1600else
1601 ac_prog_rejected=no
1602as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1603for as_dir in $PATH
1604do
1605 IFS=$as_save_IFS
1606 test -z "$as_dir" && as_dir=.
1607 for ac_exec_ext in '' $ac_executable_extensions; do
1608 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1609 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
1610 ac_prog_rejected=yes
1611 continue
1612 fi
1613 ac_cv_prog_CC="cc"
1614 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1615 break 2
1616 fi
1617done
1618done
1619
1620if test $ac_prog_rejected = yes; then
1621 # We found a bogon in the path, so make sure we never use it.
1622 set dummy $ac_cv_prog_CC
1623 shift
1624 if test $# != 0; then
1625 # We chose a different compiler from the bogus one.
1626 # However, it has the same basename, so the bogon will be chosen
1627 # first if we set CC to just the basename; use the full file name.
1628 shift
98d15063 1629 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
6a161fa9 1630 fi
1631fi
1632fi
1633fi
1634CC=$ac_cv_prog_CC
1635if test -n "$CC"; then
1636 echo "$as_me:$LINENO: result: $CC" >&5
1637echo "${ECHO_T}$CC" >&6
1638else
1639 echo "$as_me:$LINENO: result: no" >&5
1640echo "${ECHO_T}no" >&6
1641fi
1642
1643fi
1644if test -z "$CC"; then
1645 if test -n "$ac_tool_prefix"; then
1646 for ac_prog in cl
1647 do
1648 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1649set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1650echo "$as_me:$LINENO: checking for $ac_word" >&5
1651echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1652if test "${ac_cv_prog_CC+set}" = set; then
1653 echo $ECHO_N "(cached) $ECHO_C" >&6
1654else
1655 if test -n "$CC"; then
1656 ac_cv_prog_CC="$CC" # Let the user override the test.
1657else
1658as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1659for as_dir in $PATH
1660do
1661 IFS=$as_save_IFS
1662 test -z "$as_dir" && as_dir=.
1663 for ac_exec_ext in '' $ac_executable_extensions; do
1664 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1665 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1666 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1667 break 2
1668 fi
1669done
1670done
1671
1672fi
1673fi
1674CC=$ac_cv_prog_CC
1675if test -n "$CC"; then
1676 echo "$as_me:$LINENO: result: $CC" >&5
1677echo "${ECHO_T}$CC" >&6
1678else
1679 echo "$as_me:$LINENO: result: no" >&5
1680echo "${ECHO_T}no" >&6
1681fi
1682
1683 test -n "$CC" && break
1684 done
1685fi
1686if test -z "$CC"; then
1687 ac_ct_CC=$CC
1688 for ac_prog in cl
1689do
1690 # Extract the first word of "$ac_prog", so it can be a program name with args.
1691set dummy $ac_prog; ac_word=$2
1692echo "$as_me:$LINENO: checking for $ac_word" >&5
1693echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1694if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1695 echo $ECHO_N "(cached) $ECHO_C" >&6
1696else
1697 if test -n "$ac_ct_CC"; then
1698 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1699else
1700as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1701for as_dir in $PATH
1702do
1703 IFS=$as_save_IFS
1704 test -z "$as_dir" && as_dir=.
1705 for ac_exec_ext in '' $ac_executable_extensions; do
1706 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1707 ac_cv_prog_ac_ct_CC="$ac_prog"
1708 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1709 break 2
1710 fi
1711done
1712done
1713
1714fi
1715fi
1716ac_ct_CC=$ac_cv_prog_ac_ct_CC
1717if test -n "$ac_ct_CC"; then
1718 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1719echo "${ECHO_T}$ac_ct_CC" >&6
1720else
1721 echo "$as_me:$LINENO: result: no" >&5
1722echo "${ECHO_T}no" >&6
1723fi
1724
1725 test -n "$ac_ct_CC" && break
1726done
1727
1728 CC=$ac_ct_CC
1729fi
1730
1731fi
1732
1733
98d15063 1734test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
1735See \`config.log' for more details." >&5
1736echo "$as_me: error: no acceptable C compiler found in \$PATH
1737See \`config.log' for more details." >&2;}
6a161fa9 1738 { (exit 1); exit 1; }; }
1739
1740# Provide some information about the compiler.
1741echo "$as_me:$LINENO:" \
1742 "checking for C compiler version" >&5
1743ac_compiler=`set X $ac_compile; echo $2`
1744{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
1745 (eval $ac_compiler --version </dev/null >&5) 2>&5
1746 ac_status=$?
1747 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1748 (exit $ac_status); }
1749{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
1750 (eval $ac_compiler -v </dev/null >&5) 2>&5
1751 ac_status=$?
1752 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1753 (exit $ac_status); }
1754{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
1755 (eval $ac_compiler -V </dev/null >&5) 2>&5
1756 ac_status=$?
1757 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1758 (exit $ac_status); }
1759
1760cat >conftest.$ac_ext <<_ACEOF
98d15063 1761/* confdefs.h. */
1762_ACEOF
1763cat confdefs.h >>conftest.$ac_ext
1764cat >>conftest.$ac_ext <<_ACEOF
1765/* end confdefs.h. */
6a161fa9 1766
6a161fa9 1767int
1768main ()
1769{
1770
1771 ;
1772 return 0;
1773}
1774_ACEOF
1775ac_clean_files_save=$ac_clean_files
98d15063 1776ac_clean_files="$ac_clean_files a.out a.exe b.out"
6a161fa9 1777# Try to create an executable without -o first, disregard a.out.
1778# It will help us diagnose broken compilers, and finding out an intuition
1779# of exeext.
924b6140 1780echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
1781echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6
6a161fa9 1782ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1783if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
1784 (eval $ac_link_default) 2>&5
1785 ac_status=$?
1786 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1787 (exit $ac_status); }; then
1788 # Find the output, starting from the most likely. This scheme is
1789# not robust to junk in `.', hence go to wildcards (a.*) only as a last
1790# resort.
1791
1792# Be careful to initialize this variable, since it used to be cached.
1793# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
1794ac_cv_exeext=
98d15063 1795# b.out is created by i960 compilers.
1796for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
1797do
1798 test -f "$ac_file" || continue
6a161fa9 1799 case $ac_file in
98d15063 1800 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
924b6140 1801 ;;
98d15063 1802 conftest.$ac_ext )
924b6140 1803 # This is the source file.
1804 ;;
98d15063 1805 [ab].out )
924b6140 1806 # We found the default executable, but exeext='' is most
1807 # certainly right.
1808 break;;
98d15063 1809 *.* )
924b6140 1810 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1811 # FIXME: I believe we export ac_cv_exeext for Libtool,
1812 # but it would be cool to find out if it's true. Does anybody
1813 # maintain Libtool? --akim.
1814 export ac_cv_exeext
1815 break;;
98d15063 1816 * )
924b6140 1817 break;;
6a161fa9 1818 esac
1819done
1820else
1821 echo "$as_me: failed program was:" >&5
98d15063 1822sed 's/^/| /' conftest.$ac_ext >&5
1823
1824{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
1825See \`config.log' for more details." >&5
1826echo "$as_me: error: C compiler cannot create executables
1827See \`config.log' for more details." >&2;}
6a161fa9 1828 { (exit 77); exit 77; }; }
1829fi
1830
1831ac_exeext=$ac_cv_exeext
1832echo "$as_me:$LINENO: result: $ac_file" >&5
1833echo "${ECHO_T}$ac_file" >&6
1834
1835# Check the compiler produces executables we can run. If not, either
1836# the compiler is broken, or we cross compile.
1837echo "$as_me:$LINENO: checking whether the C compiler works" >&5
1838echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1839# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1840# If not cross compiling, check that we can run a simple program.
1841if test "$cross_compiling" != yes; then
1842 if { ac_try='./$ac_file'
1843 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1844 (eval $ac_try) 2>&5
1845 ac_status=$?
1846 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1847 (exit $ac_status); }; }; then
1848 cross_compiling=no
1849 else
1850 if test "$cross_compiling" = maybe; then
1851 cross_compiling=yes
1852 else
1853 { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
98d15063 1854If you meant to cross compile, use \`--host'.
1855See \`config.log' for more details." >&5
6a161fa9 1856echo "$as_me: error: cannot run C compiled programs.
98d15063 1857If you meant to cross compile, use \`--host'.
1858See \`config.log' for more details." >&2;}
6a161fa9 1859 { (exit 1); exit 1; }; }
1860 fi
1861 fi
1862fi
1863echo "$as_me:$LINENO: result: yes" >&5
1864echo "${ECHO_T}yes" >&6
1865
98d15063 1866rm -f a.out a.exe conftest$ac_cv_exeext b.out
6a161fa9 1867ac_clean_files=$ac_clean_files_save
1868# Check the compiler produces executables we can run. If not, either
1869# the compiler is broken, or we cross compile.
1870echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
1871echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1872echo "$as_me:$LINENO: result: $cross_compiling" >&5
1873echo "${ECHO_T}$cross_compiling" >&6
1874
1875echo "$as_me:$LINENO: checking for suffix of executables" >&5
1876echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
1877if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
1878 (eval $ac_link) 2>&5
1879 ac_status=$?
1880 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1881 (exit $ac_status); }; then
1882 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1883# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1884# work properly (i.e., refer to `conftest.exe'), while it won't with
1885# `rm'.
98d15063 1886for ac_file in conftest.exe conftest conftest.*; do
1887 test -f "$ac_file" || continue
6a161fa9 1888 case $ac_file in
98d15063 1889 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
6a161fa9 1890 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
924b6140 1891 export ac_cv_exeext
1892 break;;
6a161fa9 1893 * ) break;;
1894 esac
1895done
1896else
98d15063 1897 { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
1898See \`config.log' for more details." >&5
1899echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
1900See \`config.log' for more details." >&2;}
6a161fa9 1901 { (exit 1); exit 1; }; }
1902fi
1903
1904rm -f conftest$ac_cv_exeext
1905echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
1906echo "${ECHO_T}$ac_cv_exeext" >&6
1907
1908rm -f conftest.$ac_ext
1909EXEEXT=$ac_cv_exeext
1910ac_exeext=$EXEEXT
1911echo "$as_me:$LINENO: checking for suffix of object files" >&5
1912echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
1913if test "${ac_cv_objext+set}" = set; then
1914 echo $ECHO_N "(cached) $ECHO_C" >&6
1915else
1916 cat >conftest.$ac_ext <<_ACEOF
98d15063 1917/* confdefs.h. */
1918_ACEOF
1919cat confdefs.h >>conftest.$ac_ext
1920cat >>conftest.$ac_ext <<_ACEOF
1921/* end confdefs.h. */
6a161fa9 1922
6a161fa9 1923int
1924main ()
1925{
1926
1927 ;
1928 return 0;
1929}
1930_ACEOF
1931rm -f conftest.o conftest.obj
1932if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
1933 (eval $ac_compile) 2>&5
1934 ac_status=$?
1935 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1936 (exit $ac_status); }; then
1937 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1938 case $ac_file in
98d15063 1939 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
6a161fa9 1940 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1941 break;;
1942 esac
1943done
1944else
1945 echo "$as_me: failed program was:" >&5
98d15063 1946sed 's/^/| /' conftest.$ac_ext >&5
1947
1948{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
1949See \`config.log' for more details." >&5
1950echo "$as_me: error: cannot compute suffix of object files: cannot compile
1951See \`config.log' for more details." >&2;}
6a161fa9 1952 { (exit 1); exit 1; }; }
1953fi
1954
1955rm -f conftest.$ac_cv_objext conftest.$ac_ext
1956fi
1957echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
1958echo "${ECHO_T}$ac_cv_objext" >&6
1959OBJEXT=$ac_cv_objext
1960ac_objext=$OBJEXT
1961echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
1962echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1963if test "${ac_cv_c_compiler_gnu+set}" = set; then
1964 echo $ECHO_N "(cached) $ECHO_C" >&6
1965else
1966 cat >conftest.$ac_ext <<_ACEOF
98d15063 1967/* confdefs.h. */
1968_ACEOF
1969cat confdefs.h >>conftest.$ac_ext
1970cat >>conftest.$ac_ext <<_ACEOF
1971/* end confdefs.h. */
6a161fa9 1972
6a161fa9 1973int
1974main ()
1975{
1976#ifndef __GNUC__
1977 choke me
1978#endif
1979
1980 ;
1981 return 0;
1982}
1983_ACEOF
1984rm -f conftest.$ac_objext
1985if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 1986 (eval $ac_compile) 2>conftest.er1
6a161fa9 1987 ac_status=$?
924b6140 1988 grep -v '^ *+' conftest.er1 >conftest.err
1989 rm -f conftest.er1
1990 cat conftest.err >&5
6a161fa9 1991 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1992 (exit $ac_status); } &&
144f1f98 1993 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 1994 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1995 (eval $ac_try) 2>&5
1996 ac_status=$?
1997 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1998 (exit $ac_status); }; } &&
1999 { ac_try='test -s conftest.$ac_objext'
6a161fa9 2000 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2001 (eval $ac_try) 2>&5
2002 ac_status=$?
2003 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2004 (exit $ac_status); }; }; then
2005 ac_compiler_gnu=yes
2006else
2007 echo "$as_me: failed program was:" >&5
98d15063 2008sed 's/^/| /' conftest.$ac_ext >&5
2009
6a161fa9 2010ac_compiler_gnu=no
2011fi
924b6140 2012rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 2013ac_cv_c_compiler_gnu=$ac_compiler_gnu
2014
2015fi
2016echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
2017echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
2018GCC=`test $ac_compiler_gnu = yes && echo yes`
2019ac_test_CFLAGS=${CFLAGS+set}
2020ac_save_CFLAGS=$CFLAGS
2021CFLAGS="-g"
2022echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
2023echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
2024if test "${ac_cv_prog_cc_g+set}" = set; then
2025 echo $ECHO_N "(cached) $ECHO_C" >&6
2026else
2027 cat >conftest.$ac_ext <<_ACEOF
98d15063 2028/* confdefs.h. */
2029_ACEOF
2030cat confdefs.h >>conftest.$ac_ext
2031cat >>conftest.$ac_ext <<_ACEOF
2032/* end confdefs.h. */
6a161fa9 2033
6a161fa9 2034int
2035main ()
2036{
2037
2038 ;
2039 return 0;
2040}
2041_ACEOF
2042rm -f conftest.$ac_objext
2043if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 2044 (eval $ac_compile) 2>conftest.er1
6a161fa9 2045 ac_status=$?
924b6140 2046 grep -v '^ *+' conftest.er1 >conftest.err
2047 rm -f conftest.er1
2048 cat conftest.err >&5
6a161fa9 2049 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2050 (exit $ac_status); } &&
144f1f98 2051 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 2052 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2053 (eval $ac_try) 2>&5
2054 ac_status=$?
2055 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2056 (exit $ac_status); }; } &&
2057 { ac_try='test -s conftest.$ac_objext'
6a161fa9 2058 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2059 (eval $ac_try) 2>&5
2060 ac_status=$?
2061 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2062 (exit $ac_status); }; }; then
2063 ac_cv_prog_cc_g=yes
2064else
2065 echo "$as_me: failed program was:" >&5
98d15063 2066sed 's/^/| /' conftest.$ac_ext >&5
2067
6a161fa9 2068ac_cv_prog_cc_g=no
2069fi
924b6140 2070rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 2071fi
2072echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
2073echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
2074if test "$ac_test_CFLAGS" = set; then
2075 CFLAGS=$ac_save_CFLAGS
2076elif test $ac_cv_prog_cc_g = yes; then
2077 if test "$GCC" = yes; then
2078 CFLAGS="-g -O2"
2079 else
2080 CFLAGS="-g"
2081 fi
2082else
2083 if test "$GCC" = yes; then
2084 CFLAGS="-O2"
2085 else
2086 CFLAGS=
2087 fi
2088fi
98d15063 2089echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
2090echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2091if test "${ac_cv_prog_cc_stdc+set}" = set; then
2092 echo $ECHO_N "(cached) $ECHO_C" >&6
2093else
2094 ac_cv_prog_cc_stdc=no
2095ac_save_CC=$CC
2096cat >conftest.$ac_ext <<_ACEOF
98d15063 2097/* confdefs.h. */
2098_ACEOF
2099cat confdefs.h >>conftest.$ac_ext
2100cat >>conftest.$ac_ext <<_ACEOF
2101/* end confdefs.h. */
2102#include <stdarg.h>
2103#include <stdio.h>
2104#include <sys/types.h>
2105#include <sys/stat.h>
2106/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
2107struct buf { int x; };
2108FILE * (*rcsopen) (struct buf *, struct stat *, int);
2109static char *e (p, i)
2110 char **p;
2111 int i;
2112{
2113 return p[i];
2114}
2115static char *f (char * (*g) (char **, int), char **p, ...)
2116{
2117 char *s;
2118 va_list v;
2119 va_start (v,p);
2120 s = g (p, va_arg (v,int));
2121 va_end (v);
2122 return s;
2123}
924b6140 2124
2125/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
2126 function prototypes and stuff, but not '\xHH' hex character constants.
2127 These don't provoke an error unfortunately, instead are silently treated
2128 as 'x'. The following induces an error, until -std1 is added to get
2129 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
2130 array size at least. It's necessary to write '\x00'==0 to get something
2131 that's true only with -std1. */
2132int osf4_cc_array ['\x00' == 0 ? 1 : -1];
2133
98d15063 2134int test (int i, double x);
2135struct s1 {int (*f) (int a);};
2136struct s2 {int (*f) (double a);};
2137int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2138int argc;
2139char **argv;
2140int
2141main ()
2142{
2143return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
2144 ;
2145 return 0;
2146}
2147_ACEOF
2148# Don't try gcc -ansi; that turns off useful extensions and
2149# breaks some systems' header files.
2150# AIX -qlanglvl=ansi
2151# Ultrix and OSF/1 -std1
2152# HP-UX 10.20 and later -Ae
2153# HP-UX older versions -Aa -D_HPUX_SOURCE
2154# SVR4 -Xc -D__EXTENSIONS__
2155for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2156do
2157 CC="$ac_save_CC $ac_arg"
2158 rm -f conftest.$ac_objext
2159if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 2160 (eval $ac_compile) 2>conftest.er1
98d15063 2161 ac_status=$?
924b6140 2162 grep -v '^ *+' conftest.er1 >conftest.err
2163 rm -f conftest.er1
2164 cat conftest.err >&5
98d15063 2165 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2166 (exit $ac_status); } &&
144f1f98 2167 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 2168 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2169 (eval $ac_try) 2>&5
2170 ac_status=$?
2171 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2172 (exit $ac_status); }; } &&
2173 { ac_try='test -s conftest.$ac_objext'
98d15063 2174 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2175 (eval $ac_try) 2>&5
2176 ac_status=$?
2177 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2178 (exit $ac_status); }; }; then
2179 ac_cv_prog_cc_stdc=$ac_arg
2180break
2181else
2182 echo "$as_me: failed program was:" >&5
2183sed 's/^/| /' conftest.$ac_ext >&5
2184
2185fi
924b6140 2186rm -f conftest.err conftest.$ac_objext
98d15063 2187done
2188rm -f conftest.$ac_ext conftest.$ac_objext
2189CC=$ac_save_CC
2190
2191fi
2192
2193case "x$ac_cv_prog_cc_stdc" in
2194 x|xno)
2195 echo "$as_me:$LINENO: result: none needed" >&5
2196echo "${ECHO_T}none needed" >&6 ;;
2197 *)
2198 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
2199echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2200 CC="$CC $ac_cv_prog_cc_stdc" ;;
2201esac
2202
6a161fa9 2203# Some people use a C++ compiler to compile C. Since we use `exit',
2204# in C++ we need to declare it. In case someone uses the same compiler
2205# for both compiling C and C++ we need to have the C++ compiler decide
2206# the declaration of exit, since it's the most demanding environment.
2207cat >conftest.$ac_ext <<_ACEOF
2208#ifndef __cplusplus
2209 choke me
2210#endif
2211_ACEOF
2212rm -f conftest.$ac_objext
2213if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 2214 (eval $ac_compile) 2>conftest.er1
6a161fa9 2215 ac_status=$?
924b6140 2216 grep -v '^ *+' conftest.er1 >conftest.err
2217 rm -f conftest.er1
2218 cat conftest.err >&5
6a161fa9 2219 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2220 (exit $ac_status); } &&
144f1f98 2221 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 2222 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2223 (eval $ac_try) 2>&5
2224 ac_status=$?
2225 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2226 (exit $ac_status); }; } &&
2227 { ac_try='test -s conftest.$ac_objext'
6a161fa9 2228 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2229 (eval $ac_try) 2>&5
2230 ac_status=$?
2231 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2232 (exit $ac_status); }; }; then
2233 for ac_declaration in \
924b6140 2234 '' \
6a161fa9 2235 'extern "C" void std::exit (int) throw (); using std::exit;' \
2236 'extern "C" void std::exit (int); using std::exit;' \
2237 'extern "C" void exit (int) throw ();' \
2238 'extern "C" void exit (int);' \
2239 'void exit (int);'
2240do
2241 cat >conftest.$ac_ext <<_ACEOF
98d15063 2242/* confdefs.h. */
2243_ACEOF
2244cat confdefs.h >>conftest.$ac_ext
2245cat >>conftest.$ac_ext <<_ACEOF
2246/* end confdefs.h. */
6a161fa9 2247$ac_declaration
924b6140 2248#include <stdlib.h>
6a161fa9 2249int
2250main ()
2251{
2252exit (42);
2253 ;
2254 return 0;
2255}
2256_ACEOF
2257rm -f conftest.$ac_objext
2258if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 2259 (eval $ac_compile) 2>conftest.er1
6a161fa9 2260 ac_status=$?
924b6140 2261 grep -v '^ *+' conftest.er1 >conftest.err
2262 rm -f conftest.er1
2263 cat conftest.err >&5
6a161fa9 2264 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2265 (exit $ac_status); } &&
144f1f98 2266 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 2267 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2268 (eval $ac_try) 2>&5
2269 ac_status=$?
2270 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2271 (exit $ac_status); }; } &&
2272 { ac_try='test -s conftest.$ac_objext'
6a161fa9 2273 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2274 (eval $ac_try) 2>&5
2275 ac_status=$?
2276 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2277 (exit $ac_status); }; }; then
2278 :
2279else
2280 echo "$as_me: failed program was:" >&5
98d15063 2281sed 's/^/| /' conftest.$ac_ext >&5
2282
6a161fa9 2283continue
2284fi
924b6140 2285rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 2286 cat >conftest.$ac_ext <<_ACEOF
98d15063 2287/* confdefs.h. */
2288_ACEOF
2289cat confdefs.h >>conftest.$ac_ext
2290cat >>conftest.$ac_ext <<_ACEOF
2291/* end confdefs.h. */
6a161fa9 2292$ac_declaration
6a161fa9 2293int
2294main ()
2295{
2296exit (42);
2297 ;
2298 return 0;
2299}
2300_ACEOF
2301rm -f conftest.$ac_objext
2302if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 2303 (eval $ac_compile) 2>conftest.er1
6a161fa9 2304 ac_status=$?
924b6140 2305 grep -v '^ *+' conftest.er1 >conftest.err
2306 rm -f conftest.er1
2307 cat conftest.err >&5
6a161fa9 2308 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2309 (exit $ac_status); } &&
144f1f98 2310 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 2311 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2312 (eval $ac_try) 2>&5
2313 ac_status=$?
2314 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2315 (exit $ac_status); }; } &&
2316 { ac_try='test -s conftest.$ac_objext'
6a161fa9 2317 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2318 (eval $ac_try) 2>&5
2319 ac_status=$?
2320 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2321 (exit $ac_status); }; }; then
2322 break
2323else
2324 echo "$as_me: failed program was:" >&5
98d15063 2325sed 's/^/| /' conftest.$ac_ext >&5
2326
6a161fa9 2327fi
924b6140 2328rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 2329done
2330rm -f conftest*
2331if test -n "$ac_declaration"; then
2332 echo '#ifdef __cplusplus' >>confdefs.h
2333 echo $ac_declaration >>confdefs.h
2334 echo '#endif' >>confdefs.h
2335fi
2336
2337else
2338 echo "$as_me: failed program was:" >&5
98d15063 2339sed 's/^/| /' conftest.$ac_ext >&5
2340
6a161fa9 2341fi
924b6140 2342rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 2343ac_ext=c
2344ac_cpp='$CPP $CPPFLAGS'
2345ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2346ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2347ac_compiler_gnu=$ac_cv_c_compiler_gnu
2348
144f1f98 2349
2350for ac_prog in bison
daac212a 2351do
2352 # Extract the first word of "$ac_prog", so it can be a program name with args.
2353set dummy $ac_prog; ac_word=$2
2354echo "$as_me:$LINENO: checking for $ac_word" >&5
2355echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2356if test "${ac_cv_prog_YACC+set}" = set; then
2357 echo $ECHO_N "(cached) $ECHO_C" >&6
2358else
2359 if test -n "$YACC"; then
2360 ac_cv_prog_YACC="$YACC" # Let the user override the test.
2361else
2362as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2363for as_dir in $PATH
2364do
2365 IFS=$as_save_IFS
2366 test -z "$as_dir" && as_dir=.
2367 for ac_exec_ext in '' $ac_executable_extensions; do
2368 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2369 ac_cv_prog_YACC="$ac_prog"
2370 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2371 break 2
2372 fi
2373done
2374done
2375
2376fi
2377fi
2378YACC=$ac_cv_prog_YACC
2379if test -n "$YACC"; then
2380 echo "$as_me:$LINENO: result: $YACC" >&5
2381echo "${ECHO_T}$YACC" >&6
2382else
2383 echo "$as_me:$LINENO: result: no" >&5
2384echo "${ECHO_T}no" >&6
2385fi
2386
2387 test -n "$YACC" && break
2388done
1569ec51 2389
2390if test "x$YACC" = x; then
144f1f98 2391 { { echo "$as_me:$LINENO: error: Could not find bison." >&5
2392echo "$as_me: error: Could not find bison." >&2;}
1569ec51 2393 { (exit 1); exit 1; }; }
2394fi
2395
6a161fa9 2396
a35eed7c 2397# Check whether --enable-largefile or --disable-largefile was given.
2398if test "${enable_largefile+set}" = set; then
2399 enableval="$enable_largefile"
2400
2401fi;
2402if test "$enable_largefile" != no; then
2403
2404 echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
2405echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
2406if test "${ac_cv_sys_largefile_CC+set}" = set; then
2407 echo $ECHO_N "(cached) $ECHO_C" >&6
2408else
2409 ac_cv_sys_largefile_CC=no
2410 if test "$GCC" != yes; then
2411 ac_save_CC=$CC
2412 while :; do
2413 # IRIX 6.2 and later do not support large files by default,
2414 # so use the C compiler's -n32 option if that helps.
924b6140 2415 cat >conftest.$ac_ext <<_ACEOF
a35eed7c 2416/* confdefs.h. */
2417_ACEOF
2418cat confdefs.h >>conftest.$ac_ext
2419cat >>conftest.$ac_ext <<_ACEOF
2420/* end confdefs.h. */
2421#include <sys/types.h>
2422 /* Check that off_t can represent 2**63 - 1 correctly.
2423 We can't simply define LARGE_OFF_T to be 9223372036854775807,
2424 since some C++ compilers masquerading as C compilers
2425 incorrectly reject 9223372036854775807. */
2426#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
2427 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
2428 && LARGE_OFF_T % 2147483647 == 1)
2429 ? 1 : -1];
2430int
2431main ()
2432{
2433
2434 ;
2435 return 0;
2436}
2437_ACEOF
2438 rm -f conftest.$ac_objext
2439if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 2440 (eval $ac_compile) 2>conftest.er1
a35eed7c 2441 ac_status=$?
924b6140 2442 grep -v '^ *+' conftest.er1 >conftest.err
2443 rm -f conftest.er1
2444 cat conftest.err >&5
a35eed7c 2445 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2446 (exit $ac_status); } &&
144f1f98 2447 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 2448 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2449 (eval $ac_try) 2>&5
2450 ac_status=$?
2451 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2452 (exit $ac_status); }; } &&
2453 { ac_try='test -s conftest.$ac_objext'
a35eed7c 2454 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2455 (eval $ac_try) 2>&5
2456 ac_status=$?
2457 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2458 (exit $ac_status); }; }; then
2459 break
2460else
2461 echo "$as_me: failed program was:" >&5
2462sed 's/^/| /' conftest.$ac_ext >&5
2463
2464fi
924b6140 2465rm -f conftest.err conftest.$ac_objext
a35eed7c 2466 CC="$CC -n32"
2467 rm -f conftest.$ac_objext
2468if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 2469 (eval $ac_compile) 2>conftest.er1
a35eed7c 2470 ac_status=$?
924b6140 2471 grep -v '^ *+' conftest.er1 >conftest.err
2472 rm -f conftest.er1
2473 cat conftest.err >&5
a35eed7c 2474 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2475 (exit $ac_status); } &&
144f1f98 2476 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 2477 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2478 (eval $ac_try) 2>&5
2479 ac_status=$?
2480 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2481 (exit $ac_status); }; } &&
2482 { ac_try='test -s conftest.$ac_objext'
a35eed7c 2483 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2484 (eval $ac_try) 2>&5
2485 ac_status=$?
2486 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2487 (exit $ac_status); }; }; then
2488 ac_cv_sys_largefile_CC=' -n32'; break
2489else
2490 echo "$as_me: failed program was:" >&5
2491sed 's/^/| /' conftest.$ac_ext >&5
2492
2493fi
924b6140 2494rm -f conftest.err conftest.$ac_objext
2495 break
a35eed7c 2496 done
2497 CC=$ac_save_CC
2498 rm -f conftest.$ac_ext
2499 fi
2500fi
2501echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
2502echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
2503 if test "$ac_cv_sys_largefile_CC" != no; then
2504 CC=$CC$ac_cv_sys_largefile_CC
2505 fi
2506
2507 echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
2508echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
2509if test "${ac_cv_sys_file_offset_bits+set}" = set; then
2510 echo $ECHO_N "(cached) $ECHO_C" >&6
2511else
2512 while :; do
2513 ac_cv_sys_file_offset_bits=no
2514 cat >conftest.$ac_ext <<_ACEOF
a35eed7c 2515/* confdefs.h. */
2516_ACEOF
2517cat confdefs.h >>conftest.$ac_ext
2518cat >>conftest.$ac_ext <<_ACEOF
2519/* end confdefs.h. */
2520#include <sys/types.h>
2521 /* Check that off_t can represent 2**63 - 1 correctly.
2522 We can't simply define LARGE_OFF_T to be 9223372036854775807,
2523 since some C++ compilers masquerading as C compilers
2524 incorrectly reject 9223372036854775807. */
2525#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
2526 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
2527 && LARGE_OFF_T % 2147483647 == 1)
2528 ? 1 : -1];
2529int
2530main ()
2531{
2532
2533 ;
2534 return 0;
2535}
2536_ACEOF
2537rm -f conftest.$ac_objext
2538if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 2539 (eval $ac_compile) 2>conftest.er1
a35eed7c 2540 ac_status=$?
924b6140 2541 grep -v '^ *+' conftest.er1 >conftest.err
2542 rm -f conftest.er1
2543 cat conftest.err >&5
a35eed7c 2544 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2545 (exit $ac_status); } &&
144f1f98 2546 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 2547 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2548 (eval $ac_try) 2>&5
2549 ac_status=$?
2550 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2551 (exit $ac_status); }; } &&
2552 { ac_try='test -s conftest.$ac_objext'
a35eed7c 2553 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2554 (eval $ac_try) 2>&5
2555 ac_status=$?
2556 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2557 (exit $ac_status); }; }; then
2558 break
2559else
2560 echo "$as_me: failed program was:" >&5
2561sed 's/^/| /' conftest.$ac_ext >&5
2562
2563fi
924b6140 2564rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
a35eed7c 2565 cat >conftest.$ac_ext <<_ACEOF
a35eed7c 2566/* confdefs.h. */
2567_ACEOF
2568cat confdefs.h >>conftest.$ac_ext
2569cat >>conftest.$ac_ext <<_ACEOF
2570/* end confdefs.h. */
2571#define _FILE_OFFSET_BITS 64
2572#include <sys/types.h>
2573 /* Check that off_t can represent 2**63 - 1 correctly.
2574 We can't simply define LARGE_OFF_T to be 9223372036854775807,
2575 since some C++ compilers masquerading as C compilers
2576 incorrectly reject 9223372036854775807. */
2577#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
2578 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
2579 && LARGE_OFF_T % 2147483647 == 1)
2580 ? 1 : -1];
2581int
2582main ()
2583{
2584
2585 ;
2586 return 0;
2587}
2588_ACEOF
2589rm -f conftest.$ac_objext
2590if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 2591 (eval $ac_compile) 2>conftest.er1
a35eed7c 2592 ac_status=$?
924b6140 2593 grep -v '^ *+' conftest.er1 >conftest.err
2594 rm -f conftest.er1
2595 cat conftest.err >&5
a35eed7c 2596 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2597 (exit $ac_status); } &&
144f1f98 2598 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 2599 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2600 (eval $ac_try) 2>&5
2601 ac_status=$?
2602 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2603 (exit $ac_status); }; } &&
2604 { ac_try='test -s conftest.$ac_objext'
a35eed7c 2605 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2606 (eval $ac_try) 2>&5
2607 ac_status=$?
2608 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2609 (exit $ac_status); }; }; then
2610 ac_cv_sys_file_offset_bits=64; break
2611else
2612 echo "$as_me: failed program was:" >&5
2613sed 's/^/| /' conftest.$ac_ext >&5
2614
2615fi
924b6140 2616rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
a35eed7c 2617 break
2618done
2619fi
2620echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
2621echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
2622if test "$ac_cv_sys_file_offset_bits" != no; then
2623
2624cat >>confdefs.h <<_ACEOF
2625#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
2626_ACEOF
2627
2628fi
2629rm -f conftest*
2630 echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
2631echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
2632if test "${ac_cv_sys_large_files+set}" = set; then
2633 echo $ECHO_N "(cached) $ECHO_C" >&6
2634else
2635 while :; do
2636 ac_cv_sys_large_files=no
2637 cat >conftest.$ac_ext <<_ACEOF
a35eed7c 2638/* confdefs.h. */
2639_ACEOF
2640cat confdefs.h >>conftest.$ac_ext
2641cat >>conftest.$ac_ext <<_ACEOF
2642/* end confdefs.h. */
2643#include <sys/types.h>
2644 /* Check that off_t can represent 2**63 - 1 correctly.
2645 We can't simply define LARGE_OFF_T to be 9223372036854775807,
2646 since some C++ compilers masquerading as C compilers
2647 incorrectly reject 9223372036854775807. */
2648#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
2649 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
2650 && LARGE_OFF_T % 2147483647 == 1)
2651 ? 1 : -1];
2652int
2653main ()
2654{
2655
2656 ;
2657 return 0;
2658}
2659_ACEOF
2660rm -f conftest.$ac_objext
2661if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 2662 (eval $ac_compile) 2>conftest.er1
a35eed7c 2663 ac_status=$?
924b6140 2664 grep -v '^ *+' conftest.er1 >conftest.err
2665 rm -f conftest.er1
2666 cat conftest.err >&5
a35eed7c 2667 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2668 (exit $ac_status); } &&
144f1f98 2669 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 2670 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2671 (eval $ac_try) 2>&5
2672 ac_status=$?
2673 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2674 (exit $ac_status); }; } &&
2675 { ac_try='test -s conftest.$ac_objext'
a35eed7c 2676 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2677 (eval $ac_try) 2>&5
2678 ac_status=$?
2679 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2680 (exit $ac_status); }; }; then
2681 break
2682else
2683 echo "$as_me: failed program was:" >&5
2684sed 's/^/| /' conftest.$ac_ext >&5
2685
2686fi
924b6140 2687rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
a35eed7c 2688 cat >conftest.$ac_ext <<_ACEOF
a35eed7c 2689/* confdefs.h. */
2690_ACEOF
2691cat confdefs.h >>conftest.$ac_ext
2692cat >>conftest.$ac_ext <<_ACEOF
2693/* end confdefs.h. */
2694#define _LARGE_FILES 1
2695#include <sys/types.h>
2696 /* Check that off_t can represent 2**63 - 1 correctly.
2697 We can't simply define LARGE_OFF_T to be 9223372036854775807,
2698 since some C++ compilers masquerading as C compilers
2699 incorrectly reject 9223372036854775807. */
2700#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
2701 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
2702 && LARGE_OFF_T % 2147483647 == 1)
2703 ? 1 : -1];
2704int
2705main ()
2706{
2707
2708 ;
2709 return 0;
2710}
2711_ACEOF
2712rm -f conftest.$ac_objext
2713if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 2714 (eval $ac_compile) 2>conftest.er1
a35eed7c 2715 ac_status=$?
924b6140 2716 grep -v '^ *+' conftest.er1 >conftest.err
2717 rm -f conftest.er1
2718 cat conftest.err >&5
a35eed7c 2719 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2720 (exit $ac_status); } &&
144f1f98 2721 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 2722 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2723 (eval $ac_try) 2>&5
2724 ac_status=$?
2725 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2726 (exit $ac_status); }; } &&
2727 { ac_try='test -s conftest.$ac_objext'
a35eed7c 2728 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2729 (eval $ac_try) 2>&5
2730 ac_status=$?
2731 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2732 (exit $ac_status); }; }; then
2733 ac_cv_sys_large_files=1; break
2734else
2735 echo "$as_me: failed program was:" >&5
2736sed 's/^/| /' conftest.$ac_ext >&5
2737
2738fi
924b6140 2739rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
a35eed7c 2740 break
2741done
2742fi
2743echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
2744echo "${ECHO_T}$ac_cv_sys_large_files" >&6
2745if test "$ac_cv_sys_large_files" != no; then
2746
2747cat >>confdefs.h <<_ACEOF
2748#define _LARGE_FILES $ac_cv_sys_large_files
2749_ACEOF
2750
2751fi
2752rm -f conftest*
2753fi
2754
2755
6a161fa9 2756# Must be GCC.
2757test "x$GCC" = xyes || { { echo "$as_me:$LINENO: error: GCC is required" >&5
2758echo "$as_me: error: GCC is required" >&2;}
2759 { (exit 1); exit 1; }; }
2760
2761if test "x$default_CFLAGS" = xyes; then
2762 # debug flags.
a5ffe966 2763 tmp_CFLAGS="-Wall -W -Wshadow -Wpointer-arith -Wmissing-prototypes \
2764 -Wundef -Wstrict-prototypes -g"
6a161fa9 2765
2766 # optimization flags.
a35eed7c 2767 echo "$as_me:$LINENO: checking whether optimization for size works" >&5
6a161fa9 2768echo $ECHO_N "checking whether optimization for size works... $ECHO_C" >&6
2769if test "${size_flag+set}" = set; then
2770 echo $ECHO_N "(cached) $ECHO_C" >&6
2771else
2772
2773 CFLAGS=-Os
98d15063 2774 cat >conftest.$ac_ext <<_ACEOF
98d15063 2775/* confdefs.h. */
2776_ACEOF
2777cat confdefs.h >>conftest.$ac_ext
2778cat >>conftest.$ac_ext <<_ACEOF
2779/* end confdefs.h. */
6a161fa9 2780
6a161fa9 2781int
2782main ()
2783{
2784
2785 ;
2786 return 0;
2787}
2788_ACEOF
2789rm -f conftest.$ac_objext
2790if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 2791 (eval $ac_compile) 2>conftest.er1
6a161fa9 2792 ac_status=$?
924b6140 2793 grep -v '^ *+' conftest.er1 >conftest.err
2794 rm -f conftest.er1
2795 cat conftest.err >&5
6a161fa9 2796 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2797 (exit $ac_status); } &&
144f1f98 2798 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 2799 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2800 (eval $ac_try) 2>&5
2801 ac_status=$?
2802 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2803 (exit $ac_status); }; } &&
2804 { ac_try='test -s conftest.$ac_objext'
6a161fa9 2805 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2806 (eval $ac_try) 2>&5
2807 ac_status=$?
2808 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2809 (exit $ac_status); }; }; then
2810 size_flag=yes
2811else
2812 echo "$as_me: failed program was:" >&5
98d15063 2813sed 's/^/| /' conftest.$ac_ext >&5
2814
6a161fa9 2815size_flag=no
2816fi
924b6140 2817rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 2818
2819fi
2820echo "$as_me:$LINENO: result: $size_flag" >&5
2821echo "${ECHO_T}$size_flag" >&6
2822 if test "x$size_flag" = xyes; then
2823 tmp_CFLAGS="$tmp_CFLAGS -Os"
2824 else
2825 tmp_CFLAGS="$tmp_CFLAGS -O2 -fno-strength-reduce -fno-unroll-loops"
2826 fi
2827
2828 # Force no alignment to save space on i386.
2829 if test "x$host_cpu" = xi386; then
2830 echo "$as_me:$LINENO: checking whether -falign-loops works" >&5
2831echo $ECHO_N "checking whether -falign-loops works... $ECHO_C" >&6
2832if test "${falign_loop_flag+set}" = set; then
2833 echo $ECHO_N "(cached) $ECHO_C" >&6
2834else
2835
2836 CFLAGS="-falign-loops=1"
2837 cat >conftest.$ac_ext <<_ACEOF
98d15063 2838/* confdefs.h. */
2839_ACEOF
2840cat confdefs.h >>conftest.$ac_ext
2841cat >>conftest.$ac_ext <<_ACEOF
2842/* end confdefs.h. */
6a161fa9 2843
6a161fa9 2844int
2845main ()
2846{
2847
2848 ;
2849 return 0;
2850}
2851_ACEOF
2852rm -f conftest.$ac_objext
2853if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 2854 (eval $ac_compile) 2>conftest.er1
6a161fa9 2855 ac_status=$?
924b6140 2856 grep -v '^ *+' conftest.er1 >conftest.err
2857 rm -f conftest.er1
2858 cat conftest.err >&5
6a161fa9 2859 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2860 (exit $ac_status); } &&
144f1f98 2861 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 2862 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2863 (eval $ac_try) 2>&5
2864 ac_status=$?
2865 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2866 (exit $ac_status); }; } &&
2867 { ac_try='test -s conftest.$ac_objext'
6a161fa9 2868 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2869 (eval $ac_try) 2>&5
2870 ac_status=$?
2871 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2872 (exit $ac_status); }; }; then
2873 falign_loop_flag=yes
2874else
2875 echo "$as_me: failed program was:" >&5
98d15063 2876sed 's/^/| /' conftest.$ac_ext >&5
2877
6a161fa9 2878falign_loop_flag=no
2879fi
924b6140 2880rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 2881
2882fi
2883echo "$as_me:$LINENO: result: $falign_loop_flag" >&5
2884echo "${ECHO_T}$falign_loop_flag" >&6
2885
2886 if test "x$falign_loop_flag" = xyes; then
2887 tmp_CFLAGS="$tmp_CFLAGS -falign-jumps=1 -falign-loops=1 -falign-functions=1"
2888 else
2889 tmp_CFLAGS="$tmp_CFLAGS -malign-jumps=1 -malign-loops=1 -malign-functions=1"
2890 fi
2891 fi
2892
be973c1b 2893 if test "x$biarch32" = x1; then
59b8208a 2894 tmp_CFLAGS="$tmp_CFLAGS -m32"
2895 fi
2896
6a161fa9 2897 CFLAGS="$tmp_CFLAGS"
2898fi
2899
2900
2901# Defined in aclocal.m4.
2902
2903echo "$as_me:$LINENO: checking if C symbols get an underscore after compilation" >&5
2904echo $ECHO_N "checking if C symbols get an underscore after compilation... $ECHO_C" >&6
4b13b216 2905if test "${grub_cv_asm_uscore+set}" = set; then
6a161fa9 2906 echo $ECHO_N "(cached) $ECHO_C" >&6
2907else
2908 cat > conftest.c <<\EOF
2909int
2910func (int *list)
2911{
2912 *list = 0;
2913 return *list;
2914}
2915EOF
2916
2917if { ac_try='${CC-cc} ${CFLAGS} -S conftest.c'
2918 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2919 (eval $ac_try) 2>&5
2920 ac_status=$?
2921 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2922 (exit $ac_status); }; } && test -s conftest.s; then
2923 true
2924else
2925 { { echo "$as_me:$LINENO: error: ${CC-cc} failed to produce assembly code" >&5
2926echo "$as_me: error: ${CC-cc} failed to produce assembly code" >&2;}
2927 { (exit 1); exit 1; }; }
2928fi
2929
2930if grep _func conftest.s >/dev/null 2>&1; then
4b13b216 2931 grub_cv_asm_uscore=yes
6a161fa9 2932else
4b13b216 2933 grub_cv_asm_uscore=no
6a161fa9 2934fi
2935
2936rm -f conftest*
2937fi
2938
2939
4b13b216 2940if test "x$grub_cv_asm_uscore" = xyes; then
6a161fa9 2941
2942cat >>confdefs.h <<_ACEOF
4b13b216 2943#define HAVE_ASM_USCORE $grub_cv_asm_uscore
6a161fa9 2944_ACEOF
2945
2946fi
2947
4b13b216 2948echo "$as_me:$LINENO: result: $grub_cv_asm_uscore" >&5
2949echo "${ECHO_T}$grub_cv_asm_uscore" >&6
6a161fa9 2950
e56cdf21 2951if test "x$host_cpu" = xi386; then
6a161fa9 2952
2953echo "$as_me:$LINENO: checking if start is defined by the compiler" >&5
2954echo $ECHO_N "checking if start is defined by the compiler... $ECHO_C" >&6
4b13b216 2955if test "${grub_cv_check_start_symbol+set}" = set; then
6a161fa9 2956 echo $ECHO_N "(cached) $ECHO_C" >&6
2957else
2958 cat >conftest.$ac_ext <<_ACEOF
98d15063 2959/* confdefs.h. */
2960_ACEOF
2961cat confdefs.h >>conftest.$ac_ext
2962cat >>conftest.$ac_ext <<_ACEOF
2963/* end confdefs.h. */
6a161fa9 2964
6a161fa9 2965int
2966main ()
2967{
2968asm ("incl start")
2969 ;
2970 return 0;
2971}
2972_ACEOF
2973rm -f conftest.$ac_objext conftest$ac_exeext
2974if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
924b6140 2975 (eval $ac_link) 2>conftest.er1
6a161fa9 2976 ac_status=$?
924b6140 2977 grep -v '^ *+' conftest.er1 >conftest.err
2978 rm -f conftest.er1
2979 cat conftest.err >&5
6a161fa9 2980 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2981 (exit $ac_status); } &&
144f1f98 2982 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 2983 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2984 (eval $ac_try) 2>&5
2985 ac_status=$?
2986 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2987 (exit $ac_status); }; } &&
2988 { ac_try='test -s conftest$ac_exeext'
6a161fa9 2989 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2990 (eval $ac_try) 2>&5
2991 ac_status=$?
2992 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2993 (exit $ac_status); }; }; then
4b13b216 2994 grub_cv_check_start_symbol=yes
6a161fa9 2995else
2996 echo "$as_me: failed program was:" >&5
98d15063 2997sed 's/^/| /' conftest.$ac_ext >&5
2998
4b13b216 2999grub_cv_check_start_symbol=no
6a161fa9 3000fi
924b6140 3001rm -f conftest.err conftest.$ac_objext \
3002 conftest$ac_exeext conftest.$ac_ext
6a161fa9 3003fi
3004
3005
4b13b216 3006echo "$as_me:$LINENO: result: $grub_cv_check_start_symbol" >&5
3007echo "${ECHO_T}$grub_cv_check_start_symbol" >&6
6a161fa9 3008
3009echo "$as_me:$LINENO: checking if _start is defined by the compiler" >&5
3010echo $ECHO_N "checking if _start is defined by the compiler... $ECHO_C" >&6
4b13b216 3011if test "${grub_cv_check_uscore_start_symbol+set}" = set; then
6a161fa9 3012 echo $ECHO_N "(cached) $ECHO_C" >&6
3013else
3014 cat >conftest.$ac_ext <<_ACEOF
98d15063 3015/* confdefs.h. */
3016_ACEOF
3017cat confdefs.h >>conftest.$ac_ext
3018cat >>conftest.$ac_ext <<_ACEOF
3019/* end confdefs.h. */
6a161fa9 3020
6a161fa9 3021int
3022main ()
3023{
3024asm ("incl _start")
3025 ;
3026 return 0;
3027}
3028_ACEOF
3029rm -f conftest.$ac_objext conftest$ac_exeext
3030if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
924b6140 3031 (eval $ac_link) 2>conftest.er1
6a161fa9 3032 ac_status=$?
924b6140 3033 grep -v '^ *+' conftest.er1 >conftest.err
3034 rm -f conftest.er1
3035 cat conftest.err >&5
6a161fa9 3036 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3037 (exit $ac_status); } &&
144f1f98 3038 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 3039 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3040 (eval $ac_try) 2>&5
3041 ac_status=$?
3042 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3043 (exit $ac_status); }; } &&
3044 { ac_try='test -s conftest$ac_exeext'
6a161fa9 3045 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3046 (eval $ac_try) 2>&5
3047 ac_status=$?
3048 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3049 (exit $ac_status); }; }; then
4b13b216 3050 grub_cv_check_uscore_start_symbol=yes
6a161fa9 3051else
3052 echo "$as_me: failed program was:" >&5
98d15063 3053sed 's/^/| /' conftest.$ac_ext >&5
3054
4b13b216 3055grub_cv_check_uscore_start_symbol=no
6a161fa9 3056fi
924b6140 3057rm -f conftest.err conftest.$ac_objext \
3058 conftest$ac_exeext conftest.$ac_ext
6a161fa9 3059fi
3060
3061
4b13b216 3062echo "$as_me:$LINENO: result: $grub_cv_check_uscore_start_symbol" >&5
3063echo "${ECHO_T}$grub_cv_check_uscore_start_symbol" >&6
6a161fa9 3064
3065
3066
3067
4b13b216 3068if test "x$grub_cv_check_start_symbol" = xyes; then
6a161fa9 3069 cat >>confdefs.h <<\_ACEOF
3070#define START_SYMBOL start
3071_ACEOF
3072
4b13b216 3073elif test "x$grub_cv_check_uscore_start_symbol" = xyes; then
6a161fa9 3074 cat >>confdefs.h <<\_ACEOF
3075#define START_SYMBOL _start
3076_ACEOF
3077
3078else
3079 { { echo "$as_me:$LINENO: error: neither start nor _start is defined" >&5
3080echo "$as_me: error: neither start nor _start is defined" >&2;}
3081 { (exit 1); exit 1; }; }
3082fi
3083
3084
3085echo "$as_me:$LINENO: checking if __bss_start is defined by the compiler" >&5
3086echo $ECHO_N "checking if __bss_start is defined by the compiler... $ECHO_C" >&6
4b13b216 3087if test "${grub_cv_check_uscore_uscore_bss_start_symbol+set}" = set; then
6a161fa9 3088 echo $ECHO_N "(cached) $ECHO_C" >&6
3089else
3090 cat >conftest.$ac_ext <<_ACEOF
98d15063 3091/* confdefs.h. */
3092_ACEOF
3093cat confdefs.h >>conftest.$ac_ext
3094cat >>conftest.$ac_ext <<_ACEOF
3095/* end confdefs.h. */
6a161fa9 3096
6a161fa9 3097int
3098main ()
3099{
3100asm ("incl __bss_start")
3101 ;
3102 return 0;
3103}
3104_ACEOF
3105rm -f conftest.$ac_objext conftest$ac_exeext
3106if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
924b6140 3107 (eval $ac_link) 2>conftest.er1
6a161fa9 3108 ac_status=$?
924b6140 3109 grep -v '^ *+' conftest.er1 >conftest.err
3110 rm -f conftest.er1
3111 cat conftest.err >&5
6a161fa9 3112 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3113 (exit $ac_status); } &&
144f1f98 3114 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 3115 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3116 (eval $ac_try) 2>&5
3117 ac_status=$?
3118 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3119 (exit $ac_status); }; } &&
3120 { ac_try='test -s conftest$ac_exeext'
6a161fa9 3121 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3122 (eval $ac_try) 2>&5
3123 ac_status=$?
3124 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3125 (exit $ac_status); }; }; then
4b13b216 3126 grub_cv_check_uscore_uscore_bss_start_symbol=yes
6a161fa9 3127else
3128 echo "$as_me: failed program was:" >&5
98d15063 3129sed 's/^/| /' conftest.$ac_ext >&5
3130
4b13b216 3131grub_cv_check_uscore_uscore_bss_start_symbol=no
6a161fa9 3132fi
924b6140 3133rm -f conftest.err conftest.$ac_objext \
3134 conftest$ac_exeext conftest.$ac_ext
6a161fa9 3135fi
3136
3137
4b13b216 3138echo "$as_me:$LINENO: result: $grub_cv_check_uscore_uscore_bss_start_symbol" >&5
3139echo "${ECHO_T}$grub_cv_check_uscore_uscore_bss_start_symbol" >&6
6a161fa9 3140
3141echo "$as_me:$LINENO: checking if edata is defined by the compiler" >&5
3142echo $ECHO_N "checking if edata is defined by the compiler... $ECHO_C" >&6
4b13b216 3143if test "${grub_cv_check_edata_symbol+set}" = set; then
6a161fa9 3144 echo $ECHO_N "(cached) $ECHO_C" >&6
3145else
3146 cat >conftest.$ac_ext <<_ACEOF
98d15063 3147/* confdefs.h. */
3148_ACEOF
3149cat confdefs.h >>conftest.$ac_ext
3150cat >>conftest.$ac_ext <<_ACEOF
3151/* end confdefs.h. */
6a161fa9 3152
6a161fa9 3153int
3154main ()
3155{
3156asm ("incl edata")
3157 ;
3158 return 0;
3159}
3160_ACEOF
3161rm -f conftest.$ac_objext conftest$ac_exeext
3162if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
924b6140 3163 (eval $ac_link) 2>conftest.er1
6a161fa9 3164 ac_status=$?
924b6140 3165 grep -v '^ *+' conftest.er1 >conftest.err
3166 rm -f conftest.er1
3167 cat conftest.err >&5
6a161fa9 3168 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3169 (exit $ac_status); } &&
144f1f98 3170 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 3171 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3172 (eval $ac_try) 2>&5
3173 ac_status=$?
3174 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3175 (exit $ac_status); }; } &&
3176 { ac_try='test -s conftest$ac_exeext'
6a161fa9 3177 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3178 (eval $ac_try) 2>&5
3179 ac_status=$?
3180 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3181 (exit $ac_status); }; }; then
4b13b216 3182 grub_cv_check_edata_symbol=yes
6a161fa9 3183else
3184 echo "$as_me: failed program was:" >&5
98d15063 3185sed 's/^/| /' conftest.$ac_ext >&5
3186
4b13b216 3187grub_cv_check_edata_symbol=no
6a161fa9 3188fi
924b6140 3189rm -f conftest.err conftest.$ac_objext \
3190 conftest$ac_exeext conftest.$ac_ext
6a161fa9 3191fi
3192
3193
4b13b216 3194echo "$as_me:$LINENO: result: $grub_cv_check_edata_symbol" >&5
3195echo "${ECHO_T}$grub_cv_check_edata_symbol" >&6
6a161fa9 3196
3197echo "$as_me:$LINENO: checking if _edata is defined by the compiler" >&5
3198echo $ECHO_N "checking if _edata is defined by the compiler... $ECHO_C" >&6
4b13b216 3199if test "${grub_cv_check_uscore_edata_symbol+set}" = set; then
6a161fa9 3200 echo $ECHO_N "(cached) $ECHO_C" >&6
3201else
3202 cat >conftest.$ac_ext <<_ACEOF
98d15063 3203/* confdefs.h. */
3204_ACEOF
3205cat confdefs.h >>conftest.$ac_ext
3206cat >>conftest.$ac_ext <<_ACEOF
3207/* end confdefs.h. */
6a161fa9 3208
6a161fa9 3209int
3210main ()
3211{
3212asm ("incl _edata")
3213 ;
3214 return 0;
3215}
3216_ACEOF
3217rm -f conftest.$ac_objext conftest$ac_exeext
3218if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
924b6140 3219 (eval $ac_link) 2>conftest.er1
6a161fa9 3220 ac_status=$?
924b6140 3221 grep -v '^ *+' conftest.er1 >conftest.err
3222 rm -f conftest.er1
3223 cat conftest.err >&5
6a161fa9 3224 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3225 (exit $ac_status); } &&
144f1f98 3226 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 3227 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3228 (eval $ac_try) 2>&5
3229 ac_status=$?
3230 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3231 (exit $ac_status); }; } &&
3232 { ac_try='test -s conftest$ac_exeext'
6a161fa9 3233 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3234 (eval $ac_try) 2>&5
3235 ac_status=$?
3236 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3237 (exit $ac_status); }; }; then
4b13b216 3238 grub_cv_check_uscore_edata_symbol=yes
6a161fa9 3239else
3240 echo "$as_me: failed program was:" >&5
98d15063 3241sed 's/^/| /' conftest.$ac_ext >&5
3242
4b13b216 3243grub_cv_check_uscore_edata_symbol=no
6a161fa9 3244fi
924b6140 3245rm -f conftest.err conftest.$ac_objext \
3246 conftest$ac_exeext conftest.$ac_ext
6a161fa9 3247fi
3248
3249
4b13b216 3250echo "$as_me:$LINENO: result: $grub_cv_check_uscore_edata_symbol" >&5
3251echo "${ECHO_T}$grub_cv_check_uscore_edata_symbol" >&6
6a161fa9 3252
3253
3254
3255
4b13b216 3256if test "x$grub_cv_check_uscore_uscore_bss_start_symbol" = xyes; then
6a161fa9 3257 cat >>confdefs.h <<\_ACEOF
3258#define BSS_START_SYMBOL __bss_start
3259_ACEOF
3260
4b13b216 3261elif test "x$grub_cv_check_edata_symbol" = xyes; then
6a161fa9 3262 cat >>confdefs.h <<\_ACEOF
3263#define BSS_START_SYMBOL edata
3264_ACEOF
3265
4b13b216 3266elif test "x$grub_cv_check_uscore_edata_symbol" = xyes; then
6a161fa9 3267 cat >>confdefs.h <<\_ACEOF
3268#define BSS_START_SYMBOL _edata
3269_ACEOF
3270
3271else
3272 { { echo "$as_me:$LINENO: error: none of __bss_start, edata or _edata is defined" >&5
3273echo "$as_me: error: none of __bss_start, edata or _edata is defined" >&2;}
3274 { (exit 1); exit 1; }; }
3275fi
3276
3277
3278echo "$as_me:$LINENO: checking if end is defined by the compiler" >&5
3279echo $ECHO_N "checking if end is defined by the compiler... $ECHO_C" >&6
4b13b216 3280if test "${grub_cv_check_end_symbol+set}" = set; then
6a161fa9 3281 echo $ECHO_N "(cached) $ECHO_C" >&6
3282else
3283 cat >conftest.$ac_ext <<_ACEOF
98d15063 3284/* confdefs.h. */
3285_ACEOF
3286cat confdefs.h >>conftest.$ac_ext
3287cat >>conftest.$ac_ext <<_ACEOF
3288/* end confdefs.h. */
6a161fa9 3289
6a161fa9 3290int
3291main ()
3292{
3293asm ("incl end")
3294 ;
3295 return 0;
3296}
3297_ACEOF
3298rm -f conftest.$ac_objext conftest$ac_exeext
3299if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
924b6140 3300 (eval $ac_link) 2>conftest.er1
6a161fa9 3301 ac_status=$?
924b6140 3302 grep -v '^ *+' conftest.er1 >conftest.err
3303 rm -f conftest.er1
3304 cat conftest.err >&5
6a161fa9 3305 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3306 (exit $ac_status); } &&
144f1f98 3307 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 3308 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3309 (eval $ac_try) 2>&5
3310 ac_status=$?
3311 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3312 (exit $ac_status); }; } &&
3313 { ac_try='test -s conftest$ac_exeext'
6a161fa9 3314 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3315 (eval $ac_try) 2>&5
3316 ac_status=$?
3317 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3318 (exit $ac_status); }; }; then
4b13b216 3319 grub_cv_check_end_symbol=yes
6a161fa9 3320else
3321 echo "$as_me: failed program was:" >&5
98d15063 3322sed 's/^/| /' conftest.$ac_ext >&5
3323
4b13b216 3324grub_cv_check_end_symbol=no
6a161fa9 3325fi
924b6140 3326rm -f conftest.err conftest.$ac_objext \
3327 conftest$ac_exeext conftest.$ac_ext
6a161fa9 3328fi
3329
3330
4b13b216 3331echo "$as_me:$LINENO: result: $grub_cv_check_end_symbol" >&5
3332echo "${ECHO_T}$grub_cv_check_end_symbol" >&6
6a161fa9 3333
3334echo "$as_me:$LINENO: checking if _end is defined by the compiler" >&5
3335echo $ECHO_N "checking if _end is defined by the compiler... $ECHO_C" >&6
4b13b216 3336if test "${grub_cv_check_uscore_end_symbol+set}" = set; then
6a161fa9 3337 echo $ECHO_N "(cached) $ECHO_C" >&6
3338else
3339 cat >conftest.$ac_ext <<_ACEOF
98d15063 3340/* confdefs.h. */
3341_ACEOF
3342cat confdefs.h >>conftest.$ac_ext
3343cat >>conftest.$ac_ext <<_ACEOF
3344/* end confdefs.h. */
6a161fa9 3345
6a161fa9 3346int
3347main ()
3348{
3349asm ("incl _end")
3350 ;
3351 return 0;
3352}
3353_ACEOF
3354rm -f conftest.$ac_objext conftest$ac_exeext
3355if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
924b6140 3356 (eval $ac_link) 2>conftest.er1
6a161fa9 3357 ac_status=$?
924b6140 3358 grep -v '^ *+' conftest.er1 >conftest.err
3359 rm -f conftest.er1
3360 cat conftest.err >&5
6a161fa9 3361 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3362 (exit $ac_status); } &&
144f1f98 3363 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 3364 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3365 (eval $ac_try) 2>&5
3366 ac_status=$?
3367 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3368 (exit $ac_status); }; } &&
3369 { ac_try='test -s conftest$ac_exeext'
6a161fa9 3370 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3371 (eval $ac_try) 2>&5
3372 ac_status=$?
3373 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3374 (exit $ac_status); }; }; then
4b13b216 3375 grub_cv_check_uscore_end_symbol=yes
6a161fa9 3376else
3377 echo "$as_me: failed program was:" >&5
98d15063 3378sed 's/^/| /' conftest.$ac_ext >&5
3379
4b13b216 3380grub_cv_check_uscore_end_symbol=no
6a161fa9 3381fi
924b6140 3382rm -f conftest.err conftest.$ac_objext \
3383 conftest$ac_exeext conftest.$ac_ext
6a161fa9 3384fi
3385
3386
4b13b216 3387echo "$as_me:$LINENO: result: $grub_cv_check_uscore_end_symbol" >&5
3388echo "${ECHO_T}$grub_cv_check_uscore_end_symbol" >&6
6a161fa9 3389
3390
3391
3392
4b13b216 3393if test "x$grub_cv_check_end_symbol" = xyes; then
6a161fa9 3394 cat >>confdefs.h <<\_ACEOF
3395#define END_SYMBOL end
3396_ACEOF
3397
4b13b216 3398elif test "x$grub_cv_check_uscore_end_symbol" = xyes; then
6a161fa9 3399 cat >>confdefs.h <<\_ACEOF
3400#define END_SYMBOL _end
3401_ACEOF
3402
3403else
3404 { { echo "$as_me:$LINENO: error: neither end nor _end is defined" >&5
3405echo "$as_me: error: neither end nor _end is defined" >&2;}
3406 { (exit 1); exit 1; }; }
3407fi
3408
e56cdf21 3409fi
6a161fa9 3410
3411if test "x$host_cpu" = xi386; then
3412
3413echo "$as_me:$LINENO: checking whether addr32 must be in the same line as the instruction" >&5
3414echo $ECHO_N "checking whether addr32 must be in the same line as the instruction... $ECHO_C" >&6
4b13b216 3415if test "${grub_cv_i386_asm_prefix_requirement+set}" = set; then
6a161fa9 3416 echo $ECHO_N "(cached) $ECHO_C" >&6
3417else
3418 cat > conftest.s <<\EOF
3419 .code16
3420l1: addr32 movb %al, l1
3421EOF
3422
3423if { ac_try='${CC-cc} ${CFLAGS} -c conftest.s'
3424 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3425 (eval $ac_try) 2>&5
3426 ac_status=$?
3427 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3428 (exit $ac_status); }; } && test -s conftest.o; then
4b13b216 3429 grub_cv_i386_asm_prefix_requirement=yes
6a161fa9 3430else
4b13b216 3431 grub_cv_i386_asm_prefix_requirement=no
6a161fa9 3432fi
3433
3434rm -f conftest*
3435fi
3436
3437
4b13b216 3438if test "x$grub_cv_i386_asm_prefix_requirement" = xyes; then
3439 grub_tmp_addr32="addr32"
3440 grub_tmp_data32="data32"
6a161fa9 3441else
4b13b216 3442 grub_tmp_addr32="addr32;"
3443 grub_tmp_data32="data32;"
6a161fa9 3444fi
3445
3446
3447cat >>confdefs.h <<_ACEOF
4b13b216 3448#define ADDR32 $grub_tmp_addr32
6a161fa9 3449_ACEOF
3450
3451
3452cat >>confdefs.h <<_ACEOF
4b13b216 3453#define DATA32 $grub_tmp_data32
6a161fa9 3454_ACEOF
3455
3456
4b13b216 3457echo "$as_me:$LINENO: result: $grub_cv_i386_asm_prefix_requirement" >&5
3458echo "${ECHO_T}$grub_cv_i386_asm_prefix_requirement" >&6
6a161fa9 3459
3460
3461echo "$as_me:$LINENO: checking for .code16 addr32 assembler support" >&5
3462echo $ECHO_N "checking for .code16 addr32 assembler support... $ECHO_C" >&6
4b13b216 3463if test "${grub_cv_i386_asm_addr32+set}" = set; then
6a161fa9 3464 echo $ECHO_N "(cached) $ECHO_C" >&6
3465else
3466 cat > conftest.s.in <<\EOF
3467 .code16
3468l1: @ADDR32@ movb %al, l1
3469EOF
3470
4b13b216 3471if test "x$grub_cv_i386_asm_prefix_requirement" = xyes; then
6a161fa9 3472 sed -e s/@ADDR32@/addr32/ < conftest.s.in > conftest.s
3473else
3474 sed -e s/@ADDR32@/addr32\;/ < conftest.s.in > conftest.s
3475fi
3476
3477if { ac_try='${CC-cc} ${CFLAGS} -c conftest.s'
3478 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3479 (eval $ac_try) 2>&5
3480 ac_status=$?
3481 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3482 (exit $ac_status); }; } && test -s conftest.o; then
4b13b216 3483 grub_cv_i386_asm_addr32=yes
6a161fa9 3484else
4b13b216 3485 grub_cv_i386_asm_addr32=no
6a161fa9 3486fi
3487
3488rm -f conftest*
3489fi
3490
3491
4b13b216 3492echo "$as_me:$LINENO: result: $grub_cv_i386_asm_addr32" >&5
3493echo "${ECHO_T}$grub_cv_i386_asm_addr32" >&6
6a161fa9 3494
3495echo "$as_me:$LINENO: checking whether an absolute indirect call/jump must not be prefixed with an asterisk" >&5
3496echo $ECHO_N "checking whether an absolute indirect call/jump must not be prefixed with an asterisk... $ECHO_C" >&6
4b13b216 3497if test "${grub_cv_i386_asm_absolute_without_asterisk+set}" = set; then
6a161fa9 3498 echo $ECHO_N "(cached) $ECHO_C" >&6
3499else
3500 cat > conftest.s <<\EOF
3501 lcall *(offset)
3502offset:
3503 .long 0
3504 .word 0
3505EOF
3506
3507if { ac_try='${CC-cc} ${CFLAGS} -c conftest.s'
3508 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3509 (eval $ac_try) 2>&5
3510 ac_status=$?
3511 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3512 (exit $ac_status); }; } && test -s conftest.o; then
4b13b216 3513 grub_cv_i386_asm_absolute_without_asterisk=no
6a161fa9 3514else
4b13b216 3515 grub_cv_i386_asm_absolute_without_asterisk=yes
6a161fa9 3516fi
3517
3518rm -f conftest*
3519fi
3520
3521
4b13b216 3522if test "x$grub_cv_i386_asm_absolute_without_asterisk" = xyes; then
6a161fa9 3523
3524cat >>confdefs.h <<\_ACEOF
3525#define ABSOLUTE_WITHOUT_ASTERISK 1
3526_ACEOF
3527
3528fi
3529
4b13b216 3530echo "$as_me:$LINENO: result: $grub_cv_i386_asm_absolute_without_asterisk" >&5
3531echo "${ECHO_T}$grub_cv_i386_asm_absolute_without_asterisk" >&6
5aded270 3532
3533echo "$as_me:$LINENO: checking if GCC has the regparm=3 bug" >&5
3534echo $ECHO_N "checking if GCC has the regparm=3 bug... $ECHO_C" >&6
4b13b216 3535if test "${grub_cv_i386_check_nested_functions+set}" = set; then
5aded270 3536 echo $ECHO_N "(cached) $ECHO_C" >&6
3537else
3538 if test "$cross_compiling" = yes; then
3539 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
3540See \`config.log' for more details." >&5
3541echo "$as_me: error: cannot run test program while cross compiling
3542See \`config.log' for more details." >&2;}
3543 { (exit 1); exit 1; }; }
3544else
3545 cat >conftest.$ac_ext <<_ACEOF
5aded270 3546/* confdefs.h. */
3547_ACEOF
3548cat confdefs.h >>conftest.$ac_ext
3549cat >>conftest.$ac_ext <<_ACEOF
3550/* end confdefs.h. */
5aded270 3551
e9c6f39b 3552static int
3553test (int *n)
3554{
3555 return *n == -1;
3556}
3557
3558static int
3559testfunc (int __attribute__ ((__regparm__ (3))) (*hook) (int a, int b, int *c))
5aded270 3560{
e9c6f39b 3561 int a = 0;
3562 int b = 0;
3563 int c = -1;
3564 return hook (a, b, &c);
3565}
5aded270 3566
e9c6f39b 3567int
3568main (void)
3569{
3570 int __attribute__ ((__regparm__ (3))) nestedfunc (int a, int b, int *c)
5aded270 3571 {
e9c6f39b 3572 return a == b && test (c);
5aded270 3573 }
e9c6f39b 3574 return testfunc (nestedfunc) ? 0 : 1;
5aded270 3575}
3576
3577_ACEOF
3578rm -f conftest$ac_exeext
3579if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3580 (eval $ac_link) 2>&5
3581 ac_status=$?
3582 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3583 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3584 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3585 (eval $ac_try) 2>&5
3586 ac_status=$?
3587 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3588 (exit $ac_status); }; }; then
e9c6f39b 3589 grub_cv_i386_check_nested_functions=no
5aded270 3590else
3591 echo "$as_me: program exited with status $ac_status" >&5
3592echo "$as_me: failed program was:" >&5
3593sed 's/^/| /' conftest.$ac_ext >&5
3594
3595( exit $ac_status )
e9c6f39b 3596grub_cv_i386_check_nested_functions=yes
5aded270 3597fi
924b6140 3598rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5aded270 3599fi
3600fi
3601
3602
4b13b216 3603echo "$as_me:$LINENO: result: $grub_cv_i386_check_nested_functions" >&5
3604echo "${ECHO_T}$grub_cv_i386_check_nested_functions" >&6
5aded270 3605
4b13b216 3606if test "x$grub_cv_i386_check_nested_functions" = xyes; then
5aded270 3607
3608cat >>confdefs.h <<\_ACEOF
3609#define NESTED_FUNC_ATTR __attribute__ ((__regparm__ (2)))
3610_ACEOF
3611
3612else
3613
3614cat >>confdefs.h <<\_ACEOF
e9c6f39b 3615#define NESTED_FUNC_ATTR __attribute__ ((__regparm__ (2)))
5aded270 3616_ACEOF
3617
6a161fa9 3618fi
3619
5aded270 3620else
3621
3622cat >>confdefs.h <<\_ACEOF
3623#define NESTED_FUNC_ATTR
3624_ACEOF
3625
3626fi
6a161fa9 3627
3628# Find a good install program. We prefer a C program (faster),
3629# so one script is as good as another. But avoid the broken or
3630# incompatible versions:
3631# SysV /etc/install, /usr/sbin/install
3632# SunOS /usr/etc/install
3633# IRIX /sbin/install
3634# AIX /bin/install
3635# AmigaOS /C/install, which installs bootblocks on floppy discs
3636# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3637# AFS /usr/afsws/bin/install, which mishandles nonexistent args
3638# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
924b6140 3639# OS/2's system install, which has a completely different semantic
6a161fa9 3640# ./install, which can be erroneously created by make from ./install.sh.
3641echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
3642echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
3643if test -z "$INSTALL"; then
3644if test "${ac_cv_path_install+set}" = set; then
3645 echo $ECHO_N "(cached) $ECHO_C" >&6
3646else
3647 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3648for as_dir in $PATH
3649do
3650 IFS=$as_save_IFS
3651 test -z "$as_dir" && as_dir=.
3652 # Account for people who put trailing slashes in PATH elements.
3653case $as_dir/ in
3654 ./ | .// | /cC/* | \
3655 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
924b6140 3656 ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
6a161fa9 3657 /usr/ucb/* ) ;;
3658 *)
3659 # OSF1 and SCO ODT 3.0 have their own names for install.
3660 # Don't use installbsd from OSF since it installs stuff as root
3661 # by default.
3662 for ac_prog in ginstall scoinst install; do
3663 for ac_exec_ext in '' $ac_executable_extensions; do
924b6140 3664 if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3665 if test $ac_prog = install &&
3666 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3667 # AIX install. It has an incompatible calling convention.
3668 :
3669 elif test $ac_prog = install &&
3670 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3671 # program-specific install script used by HP pwplus--don't use.
3672 :
3673 else
3674 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3675 break 3
3676 fi
3677 fi
6a161fa9 3678 done
3679 done
3680 ;;
3681esac
3682done
3683
3684
3685fi
3686 if test "${ac_cv_path_install+set}" = set; then
3687 INSTALL=$ac_cv_path_install
3688 else
3689 # As a last resort, use the slow shell script. We don't cache a
3690 # path for INSTALL within a source directory, because that will
3691 # break other packages using the cache if that directory is
3692 # removed, or if the path is relative.
3693 INSTALL=$ac_install_sh
3694 fi
3695fi
3696echo "$as_me:$LINENO: result: $INSTALL" >&5
3697echo "${ECHO_T}$INSTALL" >&6
3698
3699# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3700# It thinks the first close brace ends the variable substitution.
3701test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3702
3703test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3704
3705test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3706
98d15063 3707echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3708echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6
924b6140 3709set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,:./+-,___p_,'`
6a161fa9 3710if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
3711 echo $ECHO_N "(cached) $ECHO_C" >&6
3712else
3713 cat >conftest.make <<\_ACEOF
3714all:
98d15063 3715 @echo 'ac_maketemp="$(MAKE)"'
6a161fa9 3716_ACEOF
3717# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3718eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
3719if test -n "$ac_maketemp"; then
3720 eval ac_cv_prog_make_${ac_make}_set=yes
3721else
3722 eval ac_cv_prog_make_${ac_make}_set=no
3723fi
3724rm -f conftest.make
3725fi
3726if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
3727 echo "$as_me:$LINENO: result: yes" >&5
3728echo "${ECHO_T}yes" >&6
3729 SET_MAKE=
3730else
3731 echo "$as_me:$LINENO: result: no" >&5
3732echo "${ECHO_T}no" >&6
3733 SET_MAKE="MAKE=${MAKE-make}"
3734fi
3735
3736if test -n "$ac_tool_prefix"; then
3737 # Extract the first word of "${ac_tool_prefix}objcopy", so it can be a program name with args.
3738set dummy ${ac_tool_prefix}objcopy; ac_word=$2
3739echo "$as_me:$LINENO: checking for $ac_word" >&5
3740echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3741if test "${ac_cv_prog_OBJCOPY+set}" = set; then
3742 echo $ECHO_N "(cached) $ECHO_C" >&6
3743else
3744 if test -n "$OBJCOPY"; then
3745 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
3746else
3747as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3748for as_dir in $PATH
3749do
3750 IFS=$as_save_IFS
3751 test -z "$as_dir" && as_dir=.
3752 for ac_exec_ext in '' $ac_executable_extensions; do
3753 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3754 ac_cv_prog_OBJCOPY="${ac_tool_prefix}objcopy"
3755 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3756 break 2
3757 fi
3758done
3759done
3760
3761fi
3762fi
3763OBJCOPY=$ac_cv_prog_OBJCOPY
3764if test -n "$OBJCOPY"; then
3765 echo "$as_me:$LINENO: result: $OBJCOPY" >&5
3766echo "${ECHO_T}$OBJCOPY" >&6
3767else
3768 echo "$as_me:$LINENO: result: no" >&5
3769echo "${ECHO_T}no" >&6
3770fi
3771
3772fi
3773if test -z "$ac_cv_prog_OBJCOPY"; then
3774 ac_ct_OBJCOPY=$OBJCOPY
3775 # Extract the first word of "objcopy", so it can be a program name with args.
3776set dummy objcopy; ac_word=$2
3777echo "$as_me:$LINENO: checking for $ac_word" >&5
3778echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3779if test "${ac_cv_prog_ac_ct_OBJCOPY+set}" = set; then
3780 echo $ECHO_N "(cached) $ECHO_C" >&6
3781else
3782 if test -n "$ac_ct_OBJCOPY"; then
3783 ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test.
3784else
3785as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3786for as_dir in $PATH
3787do
3788 IFS=$as_save_IFS
3789 test -z "$as_dir" && as_dir=.
3790 for ac_exec_ext in '' $ac_executable_extensions; do
3791 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3792 ac_cv_prog_ac_ct_OBJCOPY="objcopy"
3793 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3794 break 2
3795 fi
3796done
3797done
3798
3799fi
3800fi
3801ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY
3802if test -n "$ac_ct_OBJCOPY"; then
3803 echo "$as_me:$LINENO: result: $ac_ct_OBJCOPY" >&5
3804echo "${ECHO_T}$ac_ct_OBJCOPY" >&6
3805else
3806 echo "$as_me:$LINENO: result: no" >&5
3807echo "${ECHO_T}no" >&6
3808fi
3809
3810 OBJCOPY=$ac_ct_OBJCOPY
3811else
3812 OBJCOPY="$ac_cv_prog_OBJCOPY"
3813fi
3814
3815echo "$as_me:$LINENO: checking whether ${OBJCOPY} works for absolute addresses" >&5
3816echo $ECHO_N "checking whether ${OBJCOPY} works for absolute addresses... $ECHO_C" >&6
4b13b216 3817if test "${grub_cv_prog_objcopy_absolute+set}" = set; then
6a161fa9 3818 echo $ECHO_N "(cached) $ECHO_C" >&6
3819else
3820 cat > conftest.c <<\EOF
3821void
3822cmain (void)
3823{
3824 *((int *) 0x1000) = 2;
3825}
3826EOF
3827
3828if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3829 (eval $ac_compile) 2>&5
3830 ac_status=$?
3831 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3832 (exit $ac_status); } && test -s conftest.o; then :
3833else
3834 { { echo "$as_me:$LINENO: error: ${CC-cc} cannot compile C source code" >&5
3835echo "$as_me: error: ${CC-cc} cannot compile C source code" >&2;}
3836 { (exit 1); exit 1; }; }
3837fi
4b13b216 3838grub_cv_prog_objcopy_absolute=yes
6a161fa9 3839for link_addr in 2000 8000 7C00; do
3840 if { ac_try='${CC-cc} ${CFLAGS} -nostdlib -Wl,-N -Wl,-Ttext -Wl,$link_addr conftest.o -o conftest.exec'
3841 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3842 (eval $ac_try) 2>&5
3843 ac_status=$?
3844 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3845 (exit $ac_status); }; }; then :
3846 else
3847 { { echo "$as_me:$LINENO: error: ${CC-cc} cannot link at address $link_addr" >&5
3848echo "$as_me: error: ${CC-cc} cannot link at address $link_addr" >&2;}
3849 { (exit 1); exit 1; }; }
3850 fi
3851 if { ac_try='${OBJCOPY-objcopy} -O binary conftest.exec conftest'
3852 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3853 (eval $ac_try) 2>&5
3854 ac_status=$?
3855 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3856 (exit $ac_status); }; }; then :
3857 else
3858 { { echo "$as_me:$LINENO: error: ${OBJCOPY-objcopy} cannot create binary files" >&5
3859echo "$as_me: error: ${OBJCOPY-objcopy} cannot create binary files" >&2;}
3860 { (exit 1); exit 1; }; }
3861 fi
3862 if test ! -f conftest.old || { ac_try='cmp -s conftest.old conftest'
3863 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3864 (eval $ac_try) 2>&5
3865 ac_status=$?
3866 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3867 (exit $ac_status); }; }; then
3868 mv -f conftest conftest.old
3869 else
4b13b216 3870 grub_cv_prog_objcopy_absolute=no
6a161fa9 3871 break
3872 fi
3873done
3874rm -f conftest*
3875fi
3876
4b13b216 3877echo "$as_me:$LINENO: result: $grub_cv_prog_objcopy_absolute" >&5
3878echo "${ECHO_T}$grub_cv_prog_objcopy_absolute" >&6
6a161fa9 3879
4b13b216 3880if test "x$grub_cv_prog_objcopy_absolute" = xno; then
3881 { { echo "$as_me:$LINENO: error: GRUB requires a working absolute objcopy; upgrade your binutils" >&5
3882echo "$as_me: error: GRUB requires a working absolute objcopy; upgrade your binutils" >&2;}
6a161fa9 3883 { (exit 1); exit 1; }; }
3884fi
3885
3886if test -n "$ac_tool_prefix"; then
3887 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3888set dummy ${ac_tool_prefix}strip; ac_word=$2
3889echo "$as_me:$LINENO: checking for $ac_word" >&5
3890echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3891if test "${ac_cv_prog_STRIP+set}" = set; then
3892 echo $ECHO_N "(cached) $ECHO_C" >&6
3893else
3894 if test -n "$STRIP"; then
3895 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3896else
3897as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3898for as_dir in $PATH
3899do
3900 IFS=$as_save_IFS
3901 test -z "$as_dir" && as_dir=.
3902 for ac_exec_ext in '' $ac_executable_extensions; do
3903 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3904 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3905 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3906 break 2
3907 fi
3908done
3909done
3910
3911fi
3912fi
3913STRIP=$ac_cv_prog_STRIP
3914if test -n "$STRIP"; then
3915 echo "$as_me:$LINENO: result: $STRIP" >&5
3916echo "${ECHO_T}$STRIP" >&6
3917else
3918 echo "$as_me:$LINENO: result: no" >&5
3919echo "${ECHO_T}no" >&6
3920fi
3921
3922fi
3923if test -z "$ac_cv_prog_STRIP"; then
3924 ac_ct_STRIP=$STRIP
3925 # Extract the first word of "strip", so it can be a program name with args.
3926set dummy strip; ac_word=$2
3927echo "$as_me:$LINENO: checking for $ac_word" >&5
3928echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3929if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
3930 echo $ECHO_N "(cached) $ECHO_C" >&6
3931else
3932 if test -n "$ac_ct_STRIP"; then
3933 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3934else
3935as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3936for as_dir in $PATH
3937do
3938 IFS=$as_save_IFS
3939 test -z "$as_dir" && as_dir=.
3940 for ac_exec_ext in '' $ac_executable_extensions; do
3941 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3942 ac_cv_prog_ac_ct_STRIP="strip"
3943 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3944 break 2
3945 fi
3946done
3947done
3948
3949fi
3950fi
3951ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3952if test -n "$ac_ct_STRIP"; then
3953 echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
3954echo "${ECHO_T}$ac_ct_STRIP" >&6
3955else
3956 echo "$as_me:$LINENO: result: no" >&5
3957echo "${ECHO_T}no" >&6
3958fi
3959
3960 STRIP=$ac_ct_STRIP
3961else
3962 STRIP="$ac_cv_prog_STRIP"
3963fi
3964
3965if test -n "$ac_tool_prefix"; then
3966 # Extract the first word of "${ac_tool_prefix}nm", so it can be a program name with args.
3967set dummy ${ac_tool_prefix}nm; ac_word=$2
3968echo "$as_me:$LINENO: checking for $ac_word" >&5
3969echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3970if test "${ac_cv_prog_NM+set}" = set; then
3971 echo $ECHO_N "(cached) $ECHO_C" >&6
3972else
3973 if test -n "$NM"; then
3974 ac_cv_prog_NM="$NM" # Let the user override the test.
3975else
3976as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3977for as_dir in $PATH
3978do
3979 IFS=$as_save_IFS
3980 test -z "$as_dir" && as_dir=.
3981 for ac_exec_ext in '' $ac_executable_extensions; do
3982 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3983 ac_cv_prog_NM="${ac_tool_prefix}nm"
3984 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3985 break 2
3986 fi
3987done
3988done
3989
3990fi
3991fi
3992NM=$ac_cv_prog_NM
3993if test -n "$NM"; then
3994 echo "$as_me:$LINENO: result: $NM" >&5
3995echo "${ECHO_T}$NM" >&6
3996else
3997 echo "$as_me:$LINENO: result: no" >&5
3998echo "${ECHO_T}no" >&6
3999fi
4000
4001fi
4002if test -z "$ac_cv_prog_NM"; then
4003 ac_ct_NM=$NM
4004 # Extract the first word of "nm", so it can be a program name with args.
4005set dummy nm; ac_word=$2
4006echo "$as_me:$LINENO: checking for $ac_word" >&5
4007echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4008if test "${ac_cv_prog_ac_ct_NM+set}" = set; then
4009 echo $ECHO_N "(cached) $ECHO_C" >&6
4010else
4011 if test -n "$ac_ct_NM"; then
4012 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test.
4013else
4014as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4015for as_dir in $PATH
4016do
4017 IFS=$as_save_IFS
4018 test -z "$as_dir" && as_dir=.
4019 for ac_exec_ext in '' $ac_executable_extensions; do
4020 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4021 ac_cv_prog_ac_ct_NM="nm"
4022 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4023 break 2
4024 fi
4025done
4026done
4027
4028fi
4029fi
4030ac_ct_NM=$ac_cv_prog_ac_ct_NM
4031if test -n "$ac_ct_NM"; then
4032 echo "$as_me:$LINENO: result: $ac_ct_NM" >&5
4033echo "${ECHO_T}$ac_ct_NM" >&6
4034else
4035 echo "$as_me:$LINENO: result: no" >&5
4036echo "${ECHO_T}no" >&6
4037fi
4038
4039 NM=$ac_ct_NM
4040else
4041 NM="$ac_cv_prog_NM"
4042fi
4043
9962ed99 4044if test -n "$ac_tool_prefix"; then
4045 # Extract the first word of "${ac_tool_prefix}ld", so it can be a program name with args.
4046set dummy ${ac_tool_prefix}ld; ac_word=$2
4047echo "$as_me:$LINENO: checking for $ac_word" >&5
4048echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4049if test "${ac_cv_prog_LD+set}" = set; then
4050 echo $ECHO_N "(cached) $ECHO_C" >&6
4051else
4052 if test -n "$LD"; then
4053 ac_cv_prog_LD="$LD" # Let the user override the test.
4054else
4055as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4056for as_dir in $PATH
4057do
4058 IFS=$as_save_IFS
4059 test -z "$as_dir" && as_dir=.
4060 for ac_exec_ext in '' $ac_executable_extensions; do
4061 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4062 ac_cv_prog_LD="${ac_tool_prefix}ld"
4063 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4064 break 2
4065 fi
4066done
4067done
4068
4069fi
4070fi
4071LD=$ac_cv_prog_LD
4072if test -n "$LD"; then
4073 echo "$as_me:$LINENO: result: $LD" >&5
4074echo "${ECHO_T}$LD" >&6
4075else
4076 echo "$as_me:$LINENO: result: no" >&5
4077echo "${ECHO_T}no" >&6
4078fi
4079
4080fi
4081if test -z "$ac_cv_prog_LD"; then
4082 ac_ct_LD=$LD
4083 # Extract the first word of "ld", so it can be a program name with args.
4084set dummy ld; ac_word=$2
4085echo "$as_me:$LINENO: checking for $ac_word" >&5
4086echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4087if test "${ac_cv_prog_ac_ct_LD+set}" = set; then
4088 echo $ECHO_N "(cached) $ECHO_C" >&6
4089else
4090 if test -n "$ac_ct_LD"; then
4091 ac_cv_prog_ac_ct_LD="$ac_ct_LD" # Let the user override the test.
4092else
4093as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4094for as_dir in $PATH
4095do
4096 IFS=$as_save_IFS
4097 test -z "$as_dir" && as_dir=.
4098 for ac_exec_ext in '' $ac_executable_extensions; do
4099 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4100 ac_cv_prog_ac_ct_LD="ld"
4101 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4102 break 2
4103 fi
4104done
4105done
4106
4107fi
4108fi
4109ac_ct_LD=$ac_cv_prog_ac_ct_LD
4110if test -n "$ac_ct_LD"; then
4111 echo "$as_me:$LINENO: result: $ac_ct_LD" >&5
4112echo "${ECHO_T}$ac_ct_LD" >&6
4113else
4114 echo "$as_me:$LINENO: result: no" >&5
4115echo "${ECHO_T}no" >&6
4116fi
4117
4118 LD=$ac_ct_LD
4119else
4120 LD="$ac_cv_prog_LD"
4121fi
4122
6a161fa9 4123
4124# This is not a "must".
4125# Extract the first word of "ruby", so it can be a program name with args.
4126set dummy ruby; ac_word=$2
4127echo "$as_me:$LINENO: checking for $ac_word" >&5
4128echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4129if test "${ac_cv_path_RUBY+set}" = set; then
4130 echo $ECHO_N "(cached) $ECHO_C" >&6
4131else
4132 case $RUBY in
4133 [\\/]* | ?:[\\/]*)
4134 ac_cv_path_RUBY="$RUBY" # Let the user override the test with a path.
4135 ;;
4136 *)
4137 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4138for as_dir in $PATH
4139do
4140 IFS=$as_save_IFS
4141 test -z "$as_dir" && as_dir=.
4142 for ac_exec_ext in '' $ac_executable_extensions; do
4143 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4144 ac_cv_path_RUBY="$as_dir/$ac_word$ac_exec_ext"
4145 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4146 break 2
4147 fi
4148done
4149done
4150
4151 ;;
4152esac
4153fi
4154RUBY=$ac_cv_path_RUBY
4155
4156if test -n "$RUBY"; then
4157 echo "$as_me:$LINENO: result: $RUBY" >&5
4158echo "${ECHO_T}$RUBY" >&6
4159else
4160 echo "$as_me:$LINENO: result: no" >&5
4161echo "${ECHO_T}no" >&6
4162fi
4163
4164
4165# For cross-compiling.
121c1d83 4166if test "x$build" != "x$host"; then
6a161fa9 4167 for ac_prog in gcc egcs cc
4168do
4169 # Extract the first word of "$ac_prog", so it can be a program name with args.
4170set dummy $ac_prog; ac_word=$2
4171echo "$as_me:$LINENO: checking for $ac_word" >&5
4172echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4173if test "${ac_cv_prog_BUILD_CC+set}" = set; then
4174 echo $ECHO_N "(cached) $ECHO_C" >&6
4175else
4176 if test -n "$BUILD_CC"; then
4177 ac_cv_prog_BUILD_CC="$BUILD_CC" # Let the user override the test.
4178else
4179as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4180for as_dir in $PATH
4181do
4182 IFS=$as_save_IFS
4183 test -z "$as_dir" && as_dir=.
4184 for ac_exec_ext in '' $ac_executable_extensions; do
4185 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4186 ac_cv_prog_BUILD_CC="$ac_prog"
4187 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4188 break 2
4189 fi
4190done
4191done
4192
4193fi
4194fi
4195BUILD_CC=$ac_cv_prog_BUILD_CC
4196if test -n "$BUILD_CC"; then
4197 echo "$as_me:$LINENO: result: $BUILD_CC" >&5
4198echo "${ECHO_T}$BUILD_CC" >&6
4199else
4200 echo "$as_me:$LINENO: result: no" >&5
4201echo "${ECHO_T}no" >&6
4202fi
4203
4204 test -n "$BUILD_CC" && break
4205done
4206test -n "$BUILD_CC" || BUILD_CC="{ { echo "$as_me:$LINENO: error: none of gcc, egcs and cc is found. set BUILD_CC manually." >&5
4207echo "$as_me: error: none of gcc, egcs and cc is found. set BUILD_CC manually." >&2;}
4208 { (exit 1); exit 1; }; }"
4209
e56cdf21 4210else
4211 BUILD_CC="$CC"
4212
6a161fa9 4213fi
4214
4215# Test the C compiler for the build environment.
9962ed99 4216tmp_CC="$CC"
4217tmp_CFLAGS="$CFLAGS"
59b8208a 4218tmp_LDFLAGS="$LDFLAGS"
9962ed99 4219tmp_CPPFLAGS="$CPPFLAGS"
6a161fa9 4220CC="$BUILD_CC"
9962ed99 4221CFLAGS="$BUILD_CFLAGS"
4222CPPFLAGS="$BUILD_CPPFLAGS"
59b8208a 4223LDFLAGS="$BUILD_LDDFLAGS"
1f5ab428 4224
4225# Identify characteristics of the build architecture.
6a161fa9 4226echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
4227echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
4228if test "${ac_cv_c_bigendian+set}" = set; then
4229 echo $ECHO_N "(cached) $ECHO_C" >&6
4230else
4231 # See if sys/param.h defines the BYTE_ORDER macro.
4232cat >conftest.$ac_ext <<_ACEOF
98d15063 4233/* confdefs.h. */
4234_ACEOF
4235cat confdefs.h >>conftest.$ac_ext
4236cat >>conftest.$ac_ext <<_ACEOF
4237/* end confdefs.h. */
6a161fa9 4238#include <sys/types.h>
4239#include <sys/param.h>
4240
6a161fa9 4241int
4242main ()
4243{
4244#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
4245 bogus endian macros
4246#endif
4247
4248 ;
4249 return 0;
4250}
4251_ACEOF
4252rm -f conftest.$ac_objext
4253if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 4254 (eval $ac_compile) 2>conftest.er1
6a161fa9 4255 ac_status=$?
924b6140 4256 grep -v '^ *+' conftest.er1 >conftest.err
4257 rm -f conftest.er1
4258 cat conftest.err >&5
6a161fa9 4259 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4260 (exit $ac_status); } &&
144f1f98 4261 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 4262 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4263 (eval $ac_try) 2>&5
4264 ac_status=$?
4265 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4266 (exit $ac_status); }; } &&
4267 { ac_try='test -s conftest.$ac_objext'
6a161fa9 4268 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4269 (eval $ac_try) 2>&5
4270 ac_status=$?
4271 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4272 (exit $ac_status); }; }; then
4273 # It does; now see whether it defined to BIG_ENDIAN or not.
4274cat >conftest.$ac_ext <<_ACEOF
98d15063 4275/* confdefs.h. */
4276_ACEOF
4277cat confdefs.h >>conftest.$ac_ext
4278cat >>conftest.$ac_ext <<_ACEOF
4279/* end confdefs.h. */
6a161fa9 4280#include <sys/types.h>
4281#include <sys/param.h>
4282
6a161fa9 4283int
4284main ()
4285{
4286#if BYTE_ORDER != BIG_ENDIAN
4287 not big endian
4288#endif
4289
4290 ;
4291 return 0;
4292}
4293_ACEOF
4294rm -f conftest.$ac_objext
4295if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 4296 (eval $ac_compile) 2>conftest.er1
6a161fa9 4297 ac_status=$?
924b6140 4298 grep -v '^ *+' conftest.er1 >conftest.err
4299 rm -f conftest.er1
4300 cat conftest.err >&5
6a161fa9 4301 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4302 (exit $ac_status); } &&
144f1f98 4303 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 4304 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4305 (eval $ac_try) 2>&5
4306 ac_status=$?
4307 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4308 (exit $ac_status); }; } &&
4309 { ac_try='test -s conftest.$ac_objext'
6a161fa9 4310 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4311 (eval $ac_try) 2>&5
4312 ac_status=$?
4313 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4314 (exit $ac_status); }; }; then
4315 ac_cv_c_bigendian=yes
4316else
4317 echo "$as_me: failed program was:" >&5
98d15063 4318sed 's/^/| /' conftest.$ac_ext >&5
4319
6a161fa9 4320ac_cv_c_bigendian=no
4321fi
924b6140 4322rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 4323else
4324 echo "$as_me: failed program was:" >&5
98d15063 4325sed 's/^/| /' conftest.$ac_ext >&5
4326
6a161fa9 4327# It does not; compile a test program.
4328if test "$cross_compiling" = yes; then
98d15063 4329 # try to guess the endianness by grepping values into an object file
6a161fa9 4330 ac_cv_c_bigendian=unknown
4331 cat >conftest.$ac_ext <<_ACEOF
98d15063 4332/* confdefs.h. */
4333_ACEOF
4334cat confdefs.h >>conftest.$ac_ext
4335cat >>conftest.$ac_ext <<_ACEOF
4336/* end confdefs.h. */
6a161fa9 4337short ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
4338short ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
4339void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
4340short ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
4341short ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
4342void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
6a161fa9 4343int
4344main ()
4345{
4346 _ascii (); _ebcdic ();
4347 ;
4348 return 0;
4349}
4350_ACEOF
4351rm -f conftest.$ac_objext
4352if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 4353 (eval $ac_compile) 2>conftest.er1
6a161fa9 4354 ac_status=$?
924b6140 4355 grep -v '^ *+' conftest.er1 >conftest.err
4356 rm -f conftest.er1
4357 cat conftest.err >&5
6a161fa9 4358 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4359 (exit $ac_status); } &&
144f1f98 4360 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 4361 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4362 (eval $ac_try) 2>&5
4363 ac_status=$?
4364 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4365 (exit $ac_status); }; } &&
4366 { ac_try='test -s conftest.$ac_objext'
6a161fa9 4367 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4368 (eval $ac_try) 2>&5
4369 ac_status=$?
4370 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4371 (exit $ac_status); }; }; then
98d15063 4372 if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
6a161fa9 4373 ac_cv_c_bigendian=yes
4374fi
98d15063 4375if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
6a161fa9 4376 if test "$ac_cv_c_bigendian" = unknown; then
4377 ac_cv_c_bigendian=no
4378 else
4379 # finding both strings is unlikely to happen, but who knows?
4380 ac_cv_c_bigendian=unknown
4381 fi
4382fi
4383else
4384 echo "$as_me: failed program was:" >&5
98d15063 4385sed 's/^/| /' conftest.$ac_ext >&5
4386
6a161fa9 4387fi
924b6140 4388rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 4389else
4390 cat >conftest.$ac_ext <<_ACEOF
98d15063 4391/* confdefs.h. */
4392_ACEOF
4393cat confdefs.h >>conftest.$ac_ext
4394cat >>conftest.$ac_ext <<_ACEOF
4395/* end confdefs.h. */
6a161fa9 4396int
4397main ()
4398{
4399 /* Are we little or big endian? From Harbison&Steele. */
4400 union
4401 {
4402 long l;
4403 char c[sizeof (long)];
4404 } u;
4405 u.l = 1;
4406 exit (u.c[sizeof (long) - 1] == 1);
4407}
4408_ACEOF
4409rm -f conftest$ac_exeext
4410if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4411 (eval $ac_link) 2>&5
4412 ac_status=$?
4413 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4414 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4415 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4416 (eval $ac_try) 2>&5
4417 ac_status=$?
4418 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4419 (exit $ac_status); }; }; then
4420 ac_cv_c_bigendian=no
4421else
4422 echo "$as_me: program exited with status $ac_status" >&5
4423echo "$as_me: failed program was:" >&5
98d15063 4424sed 's/^/| /' conftest.$ac_ext >&5
4425
6a161fa9 4426( exit $ac_status )
4427ac_cv_c_bigendian=yes
4428fi
924b6140 4429rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6a161fa9 4430fi
4431fi
924b6140 4432rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 4433fi
4434echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
4435echo "${ECHO_T}$ac_cv_c_bigendian" >&6
4436case $ac_cv_c_bigendian in
4437 yes)
4438
4439cat >>confdefs.h <<\_ACEOF
4440#define WORDS_BIGENDIAN 1
4441_ACEOF
4442 ;;
4443 no)
4444 ;;
4445 *)
98d15063 4446 { { echo "$as_me:$LINENO: error: unknown endianness
6a161fa9 4447presetting ac_cv_c_bigendian=no (or yes) will help" >&5
98d15063 4448echo "$as_me: error: unknown endianness
6a161fa9 4449presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
4450 { (exit 1); exit 1; }; } ;;
4451esac
4452
4453ac_ext=c
4454ac_cpp='$CPP $CPPFLAGS'
4455ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4456ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4457ac_compiler_gnu=$ac_cv_c_compiler_gnu
4458echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
4459echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
4460# On Suns, sometimes $CPP names a directory.
4461if test -n "$CPP" && test -d "$CPP"; then
4462 CPP=
4463fi
4464if test -z "$CPP"; then
4465 if test "${ac_cv_prog_CPP+set}" = set; then
4466 echo $ECHO_N "(cached) $ECHO_C" >&6
4467else
4468 # Double quotes because CPP needs to be expanded
4469 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4470 do
4471 ac_preproc_ok=false
4472for ac_c_preproc_warn_flag in '' yes
4473do
4474 # Use a header file that comes with gcc, so configuring glibc
4475 # with a fresh cross-compiler works.
98d15063 4476 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4477 # <limits.h> exists even on freestanding compilers.
6a161fa9 4478 # On the NeXT, cc -E runs the code through the compiler's parser,
4479 # not just through cpp. "Syntax error" is here to catch this case.
4480 cat >conftest.$ac_ext <<_ACEOF
98d15063 4481/* confdefs.h. */
4482_ACEOF
4483cat confdefs.h >>conftest.$ac_ext
4484cat >>conftest.$ac_ext <<_ACEOF
4485/* end confdefs.h. */
4486#ifdef __STDC__
4487# include <limits.h>
4488#else
4489# include <assert.h>
4490#endif
924b6140 4491 Syntax error
6a161fa9 4492_ACEOF
4493if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
4494 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4495 ac_status=$?
98d15063 4496 grep -v '^ *+' conftest.er1 >conftest.err
6a161fa9 4497 rm -f conftest.er1
4498 cat conftest.err >&5
4499 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4500 (exit $ac_status); } >/dev/null; then
4501 if test -s conftest.err; then
4502 ac_cpp_err=$ac_c_preproc_warn_flag
924b6140 4503 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6a161fa9 4504 else
4505 ac_cpp_err=
4506 fi
4507else
4508 ac_cpp_err=yes
4509fi
4510if test -z "$ac_cpp_err"; then
4511 :
4512else
4513 echo "$as_me: failed program was:" >&5
98d15063 4514sed 's/^/| /' conftest.$ac_ext >&5
4515
6a161fa9 4516 # Broken: fails on valid input.
4517continue
4518fi
4519rm -f conftest.err conftest.$ac_ext
4520
4521 # OK, works on sane cases. Now check whether non-existent headers
4522 # can be detected and how.
4523 cat >conftest.$ac_ext <<_ACEOF
98d15063 4524/* confdefs.h. */
4525_ACEOF
4526cat confdefs.h >>conftest.$ac_ext
4527cat >>conftest.$ac_ext <<_ACEOF
4528/* end confdefs.h. */
6a161fa9 4529#include <ac_nonexistent.h>
4530_ACEOF
4531if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
4532 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4533 ac_status=$?
98d15063 4534 grep -v '^ *+' conftest.er1 >conftest.err
6a161fa9 4535 rm -f conftest.er1
4536 cat conftest.err >&5
4537 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4538 (exit $ac_status); } >/dev/null; then
4539 if test -s conftest.err; then
4540 ac_cpp_err=$ac_c_preproc_warn_flag
924b6140 4541 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6a161fa9 4542 else
4543 ac_cpp_err=
4544 fi
4545else
4546 ac_cpp_err=yes
4547fi
4548if test -z "$ac_cpp_err"; then
4549 # Broken: success on invalid input.
4550continue
4551else
4552 echo "$as_me: failed program was:" >&5
98d15063 4553sed 's/^/| /' conftest.$ac_ext >&5
4554
6a161fa9 4555 # Passes both tests.
4556ac_preproc_ok=:
4557break
4558fi
4559rm -f conftest.err conftest.$ac_ext
4560
4561done
4562# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4563rm -f conftest.err conftest.$ac_ext
4564if $ac_preproc_ok; then
4565 break
4566fi
4567
4568 done
4569 ac_cv_prog_CPP=$CPP
4570
4571fi
4572 CPP=$ac_cv_prog_CPP
4573else
4574 ac_cv_prog_CPP=$CPP
4575fi
4576echo "$as_me:$LINENO: result: $CPP" >&5
4577echo "${ECHO_T}$CPP" >&6
4578ac_preproc_ok=false
4579for ac_c_preproc_warn_flag in '' yes
4580do
4581 # Use a header file that comes with gcc, so configuring glibc
4582 # with a fresh cross-compiler works.
98d15063 4583 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4584 # <limits.h> exists even on freestanding compilers.
6a161fa9 4585 # On the NeXT, cc -E runs the code through the compiler's parser,
4586 # not just through cpp. "Syntax error" is here to catch this case.
4587 cat >conftest.$ac_ext <<_ACEOF
98d15063 4588/* confdefs.h. */
4589_ACEOF
4590cat confdefs.h >>conftest.$ac_ext
4591cat >>conftest.$ac_ext <<_ACEOF
4592/* end confdefs.h. */
4593#ifdef __STDC__
4594# include <limits.h>
4595#else
4596# include <assert.h>
4597#endif
924b6140 4598 Syntax error
6a161fa9 4599_ACEOF
4600if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
4601 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4602 ac_status=$?
98d15063 4603 grep -v '^ *+' conftest.er1 >conftest.err
6a161fa9 4604 rm -f conftest.er1
4605 cat conftest.err >&5
4606 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4607 (exit $ac_status); } >/dev/null; then
4608 if test -s conftest.err; then
4609 ac_cpp_err=$ac_c_preproc_warn_flag
924b6140 4610 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6a161fa9 4611 else
4612 ac_cpp_err=
4613 fi
4614else
4615 ac_cpp_err=yes
4616fi
4617if test -z "$ac_cpp_err"; then
4618 :
4619else
4620 echo "$as_me: failed program was:" >&5
98d15063 4621sed 's/^/| /' conftest.$ac_ext >&5
4622
6a161fa9 4623 # Broken: fails on valid input.
4624continue
4625fi
4626rm -f conftest.err conftest.$ac_ext
4627
4628 # OK, works on sane cases. Now check whether non-existent headers
4629 # can be detected and how.
4630 cat >conftest.$ac_ext <<_ACEOF
98d15063 4631/* confdefs.h. */
4632_ACEOF
4633cat confdefs.h >>conftest.$ac_ext
4634cat >>conftest.$ac_ext <<_ACEOF
4635/* end confdefs.h. */
6a161fa9 4636#include <ac_nonexistent.h>
4637_ACEOF
4638if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
4639 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4640 ac_status=$?
98d15063 4641 grep -v '^ *+' conftest.er1 >conftest.err
6a161fa9 4642 rm -f conftest.er1
4643 cat conftest.err >&5
4644 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4645 (exit $ac_status); } >/dev/null; then
4646 if test -s conftest.err; then
4647 ac_cpp_err=$ac_c_preproc_warn_flag
924b6140 4648 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6a161fa9 4649 else
4650 ac_cpp_err=
4651 fi
4652else
4653 ac_cpp_err=yes
4654fi
4655if test -z "$ac_cpp_err"; then
4656 # Broken: success on invalid input.
4657continue
4658else
4659 echo "$as_me: failed program was:" >&5
98d15063 4660sed 's/^/| /' conftest.$ac_ext >&5
4661
6a161fa9 4662 # Passes both tests.
4663ac_preproc_ok=:
4664break
4665fi
4666rm -f conftest.err conftest.$ac_ext
4667
4668done
4669# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4670rm -f conftest.err conftest.$ac_ext
4671if $ac_preproc_ok; then
4672 :
4673else
98d15063 4674 { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
4675See \`config.log' for more details." >&5
4676echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
4677See \`config.log' for more details." >&2;}
6a161fa9 4678 { (exit 1); exit 1; }; }
4679fi
4680
4681ac_ext=c
4682ac_cpp='$CPP $CPPFLAGS'
4683ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4684ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4685ac_compiler_gnu=$ac_cv_c_compiler_gnu
4686
4687
98d15063 4688echo "$as_me:$LINENO: checking for egrep" >&5
4689echo $ECHO_N "checking for egrep... $ECHO_C" >&6
4690if test "${ac_cv_prog_egrep+set}" = set; then
4691 echo $ECHO_N "(cached) $ECHO_C" >&6
4692else
4693 if echo a | (grep -E '(a|b)') >/dev/null 2>&1
4694 then ac_cv_prog_egrep='grep -E'
4695 else ac_cv_prog_egrep='egrep'
4696 fi
4697fi
4698echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
4699echo "${ECHO_T}$ac_cv_prog_egrep" >&6
4700 EGREP=$ac_cv_prog_egrep
4701
4702
6a161fa9 4703echo "$as_me:$LINENO: checking for ANSI C header files" >&5
4704echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
4705if test "${ac_cv_header_stdc+set}" = set; then
4706 echo $ECHO_N "(cached) $ECHO_C" >&6
4707else
4708 cat >conftest.$ac_ext <<_ACEOF
98d15063 4709/* confdefs.h. */
4710_ACEOF
4711cat confdefs.h >>conftest.$ac_ext
4712cat >>conftest.$ac_ext <<_ACEOF
4713/* end confdefs.h. */
6a161fa9 4714#include <stdlib.h>
4715#include <stdarg.h>
4716#include <string.h>
4717#include <float.h>
4718
98d15063 4719int
4720main ()
4721{
4722
4723 ;
4724 return 0;
4725}
6a161fa9 4726_ACEOF
98d15063 4727rm -f conftest.$ac_objext
4728if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 4729 (eval $ac_compile) 2>conftest.er1
6a161fa9 4730 ac_status=$?
924b6140 4731 grep -v '^ *+' conftest.er1 >conftest.err
4732 rm -f conftest.er1
4733 cat conftest.err >&5
6a161fa9 4734 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98d15063 4735 (exit $ac_status); } &&
144f1f98 4736 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 4737 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4738 (eval $ac_try) 2>&5
4739 ac_status=$?
4740 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4741 (exit $ac_status); }; } &&
4742 { ac_try='test -s conftest.$ac_objext'
98d15063 4743 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4744 (eval $ac_try) 2>&5
4745 ac_status=$?
4746 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4747 (exit $ac_status); }; }; then
6a161fa9 4748 ac_cv_header_stdc=yes
4749else
4750 echo "$as_me: failed program was:" >&5
98d15063 4751sed 's/^/| /' conftest.$ac_ext >&5
4752
4753ac_cv_header_stdc=no
6a161fa9 4754fi
924b6140 4755rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 4756
4757if test $ac_cv_header_stdc = yes; then
4758 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4759 cat >conftest.$ac_ext <<_ACEOF
98d15063 4760/* confdefs.h. */
4761_ACEOF
4762cat confdefs.h >>conftest.$ac_ext
4763cat >>conftest.$ac_ext <<_ACEOF
4764/* end confdefs.h. */
6a161fa9 4765#include <string.h>
4766
4767_ACEOF
4768if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
98d15063 4769 $EGREP "memchr" >/dev/null 2>&1; then
6a161fa9 4770 :
4771else
4772 ac_cv_header_stdc=no
4773fi
4774rm -f conftest*
4775
4776fi
4777
4778if test $ac_cv_header_stdc = yes; then
4779 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4780 cat >conftest.$ac_ext <<_ACEOF
98d15063 4781/* confdefs.h. */
4782_ACEOF
4783cat confdefs.h >>conftest.$ac_ext
4784cat >>conftest.$ac_ext <<_ACEOF
4785/* end confdefs.h. */
6a161fa9 4786#include <stdlib.h>
4787
4788_ACEOF
4789if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
98d15063 4790 $EGREP "free" >/dev/null 2>&1; then
6a161fa9 4791 :
4792else
4793 ac_cv_header_stdc=no
4794fi
4795rm -f conftest*
4796
4797fi
4798
4799if test $ac_cv_header_stdc = yes; then
4800 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4801 if test "$cross_compiling" = yes; then
4802 :
4803else
4804 cat >conftest.$ac_ext <<_ACEOF
98d15063 4805/* confdefs.h. */
4806_ACEOF
4807cat confdefs.h >>conftest.$ac_ext
4808cat >>conftest.$ac_ext <<_ACEOF
4809/* end confdefs.h. */
6a161fa9 4810#include <ctype.h>
4811#if ((' ' & 0x0FF) == 0x020)
4812# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4813# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4814#else
98d15063 4815# define ISLOWER(c) \
924b6140 4816 (('a' <= (c) && (c) <= 'i') \
4817 || ('j' <= (c) && (c) <= 'r') \
4818 || ('s' <= (c) && (c) <= 'z'))
6a161fa9 4819# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4820#endif
4821
4822#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4823int
4824main ()
4825{
4826 int i;
4827 for (i = 0; i < 256; i++)
4828 if (XOR (islower (i), ISLOWER (i))
924b6140 4829 || toupper (i) != TOUPPER (i))
6a161fa9 4830 exit(2);
4831 exit (0);
4832}
4833_ACEOF
4834rm -f conftest$ac_exeext
4835if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4836 (eval $ac_link) 2>&5
4837 ac_status=$?
4838 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4839 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4840 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4841 (eval $ac_try) 2>&5
4842 ac_status=$?
4843 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4844 (exit $ac_status); }; }; then
4845 :
4846else
4847 echo "$as_me: program exited with status $ac_status" >&5
4848echo "$as_me: failed program was:" >&5
98d15063 4849sed 's/^/| /' conftest.$ac_ext >&5
4850
6a161fa9 4851( exit $ac_status )
4852ac_cv_header_stdc=no
4853fi
924b6140 4854rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6a161fa9 4855fi
4856fi
4857fi
4858echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
4859echo "${ECHO_T}$ac_cv_header_stdc" >&6
4860if test $ac_cv_header_stdc = yes; then
4861
4862cat >>confdefs.h <<\_ACEOF
4863#define STDC_HEADERS 1
4864_ACEOF
4865
4866fi
4867
4868# On IRIX 5.3, sys/types and inttypes.h are conflicting.
4869
4870
4871
4872
4873
4874
4875
4876
4877
4878for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
924b6140 4879 inttypes.h stdint.h unistd.h
6a161fa9 4880do
4881as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4882echo "$as_me:$LINENO: checking for $ac_header" >&5
4883echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4884if eval "test \"\${$as_ac_Header+set}\" = set"; then
4885 echo $ECHO_N "(cached) $ECHO_C" >&6
4886else
4887 cat >conftest.$ac_ext <<_ACEOF
98d15063 4888/* confdefs.h. */
4889_ACEOF
4890cat confdefs.h >>conftest.$ac_ext
4891cat >>conftest.$ac_ext <<_ACEOF
4892/* end confdefs.h. */
6a161fa9 4893$ac_includes_default
4894
4895#include <$ac_header>
4896_ACEOF
4897rm -f conftest.$ac_objext
4898if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 4899 (eval $ac_compile) 2>conftest.er1
6a161fa9 4900 ac_status=$?
924b6140 4901 grep -v '^ *+' conftest.er1 >conftest.err
4902 rm -f conftest.er1
4903 cat conftest.err >&5
6a161fa9 4904 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4905 (exit $ac_status); } &&
144f1f98 4906 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 4907 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4908 (eval $ac_try) 2>&5
4909 ac_status=$?
4910 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4911 (exit $ac_status); }; } &&
4912 { ac_try='test -s conftest.$ac_objext'
6a161fa9 4913 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4914 (eval $ac_try) 2>&5
4915 ac_status=$?
4916 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4917 (exit $ac_status); }; }; then
4918 eval "$as_ac_Header=yes"
4919else
4920 echo "$as_me: failed program was:" >&5
98d15063 4921sed 's/^/| /' conftest.$ac_ext >&5
4922
6a161fa9 4923eval "$as_ac_Header=no"
4924fi
924b6140 4925rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 4926fi
4927echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4928echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4929if test `eval echo '${'$as_ac_Header'}'` = yes; then
4930 cat >>confdefs.h <<_ACEOF
4931#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4932_ACEOF
4933
4934fi
4935
4936done
4937
4938
4939echo "$as_me:$LINENO: checking for void *" >&5
4940echo $ECHO_N "checking for void *... $ECHO_C" >&6
4941if test "${ac_cv_type_void_p+set}" = set; then
4942 echo $ECHO_N "(cached) $ECHO_C" >&6
4943else
4944 cat >conftest.$ac_ext <<_ACEOF
98d15063 4945/* confdefs.h. */
4946_ACEOF
4947cat confdefs.h >>conftest.$ac_ext
4948cat >>conftest.$ac_ext <<_ACEOF
4949/* end confdefs.h. */
6a161fa9 4950$ac_includes_default
6a161fa9 4951int
4952main ()
4953{
4954if ((void * *) 0)
4955 return 0;
4956if (sizeof (void *))
4957 return 0;
4958 ;
4959 return 0;
4960}
4961_ACEOF
4962rm -f conftest.$ac_objext
4963if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 4964 (eval $ac_compile) 2>conftest.er1
6a161fa9 4965 ac_status=$?
924b6140 4966 grep -v '^ *+' conftest.er1 >conftest.err
4967 rm -f conftest.er1
4968 cat conftest.err >&5
6a161fa9 4969 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4970 (exit $ac_status); } &&
144f1f98 4971 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 4972 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4973 (eval $ac_try) 2>&5
4974 ac_status=$?
4975 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4976 (exit $ac_status); }; } &&
4977 { ac_try='test -s conftest.$ac_objext'
6a161fa9 4978 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4979 (eval $ac_try) 2>&5
4980 ac_status=$?
4981 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4982 (exit $ac_status); }; }; then
4983 ac_cv_type_void_p=yes
4984else
4985 echo "$as_me: failed program was:" >&5
98d15063 4986sed 's/^/| /' conftest.$ac_ext >&5
4987
6a161fa9 4988ac_cv_type_void_p=no
4989fi
924b6140 4990rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 4991fi
4992echo "$as_me:$LINENO: result: $ac_cv_type_void_p" >&5
4993echo "${ECHO_T}$ac_cv_type_void_p" >&6
4994
4995echo "$as_me:$LINENO: checking size of void *" >&5
4996echo $ECHO_N "checking size of void *... $ECHO_C" >&6
4997if test "${ac_cv_sizeof_void_p+set}" = set; then
4998 echo $ECHO_N "(cached) $ECHO_C" >&6
4999else
5000 if test "$ac_cv_type_void_p" = yes; then
5001 # The cast to unsigned long works around a bug in the HP C Compiler
5002 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5003 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5004 # This bug is HP SR number 8606223364.
5005 if test "$cross_compiling" = yes; then
5006 # Depending upon the size, compute the lo and hi bounds.
5007cat >conftest.$ac_ext <<_ACEOF
98d15063 5008/* confdefs.h. */
5009_ACEOF
5010cat confdefs.h >>conftest.$ac_ext
5011cat >>conftest.$ac_ext <<_ACEOF
5012/* end confdefs.h. */
6a161fa9 5013$ac_includes_default
6a161fa9 5014int
5015main ()
5016{
5017static int test_array [1 - 2 * !(((long) (sizeof (void *))) >= 0)];
5018test_array [0] = 0
5019
5020 ;
5021 return 0;
5022}
5023_ACEOF
5024rm -f conftest.$ac_objext
5025if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 5026 (eval $ac_compile) 2>conftest.er1
6a161fa9 5027 ac_status=$?
924b6140 5028 grep -v '^ *+' conftest.er1 >conftest.err
5029 rm -f conftest.er1
5030 cat conftest.err >&5
6a161fa9 5031 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5032 (exit $ac_status); } &&
144f1f98 5033 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 5034 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5035 (eval $ac_try) 2>&5
5036 ac_status=$?
5037 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5038 (exit $ac_status); }; } &&
5039 { ac_try='test -s conftest.$ac_objext'
6a161fa9 5040 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5041 (eval $ac_try) 2>&5
5042 ac_status=$?
5043 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5044 (exit $ac_status); }; }; then
5045 ac_lo=0 ac_mid=0
5046 while :; do
5047 cat >conftest.$ac_ext <<_ACEOF
98d15063 5048/* confdefs.h. */
5049_ACEOF
5050cat confdefs.h >>conftest.$ac_ext
5051cat >>conftest.$ac_ext <<_ACEOF
5052/* end confdefs.h. */
6a161fa9 5053$ac_includes_default
6a161fa9 5054int
5055main ()
5056{
5057static int test_array [1 - 2 * !(((long) (sizeof (void *))) <= $ac_mid)];
5058test_array [0] = 0
5059
5060 ;
5061 return 0;
5062}
5063_ACEOF
5064rm -f conftest.$ac_objext
5065if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 5066 (eval $ac_compile) 2>conftest.er1
6a161fa9 5067 ac_status=$?
924b6140 5068 grep -v '^ *+' conftest.er1 >conftest.err
5069 rm -f conftest.er1
5070 cat conftest.err >&5
6a161fa9 5071 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5072 (exit $ac_status); } &&
144f1f98 5073 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 5074 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5075 (eval $ac_try) 2>&5
5076 ac_status=$?
5077 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5078 (exit $ac_status); }; } &&
5079 { ac_try='test -s conftest.$ac_objext'
6a161fa9 5080 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5081 (eval $ac_try) 2>&5
5082 ac_status=$?
5083 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5084 (exit $ac_status); }; }; then
5085 ac_hi=$ac_mid; break
5086else
5087 echo "$as_me: failed program was:" >&5
98d15063 5088sed 's/^/| /' conftest.$ac_ext >&5
5089
6a161fa9 5090ac_lo=`expr $ac_mid + 1`
924b6140 5091 if test $ac_lo -le $ac_mid; then
5092 ac_lo= ac_hi=
5093 break
5094 fi
5095 ac_mid=`expr 2 '*' $ac_mid + 1`
6a161fa9 5096fi
924b6140 5097rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 5098 done
5099else
5100 echo "$as_me: failed program was:" >&5
98d15063 5101sed 's/^/| /' conftest.$ac_ext >&5
5102
6a161fa9 5103cat >conftest.$ac_ext <<_ACEOF
98d15063 5104/* confdefs.h. */
5105_ACEOF
5106cat confdefs.h >>conftest.$ac_ext
5107cat >>conftest.$ac_ext <<_ACEOF
5108/* end confdefs.h. */
6a161fa9 5109$ac_includes_default
6a161fa9 5110int
5111main ()
5112{
5113static int test_array [1 - 2 * !(((long) (sizeof (void *))) < 0)];
5114test_array [0] = 0
5115
5116 ;
5117 return 0;
5118}
5119_ACEOF
5120rm -f conftest.$ac_objext
5121if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 5122 (eval $ac_compile) 2>conftest.er1
6a161fa9 5123 ac_status=$?
924b6140 5124 grep -v '^ *+' conftest.er1 >conftest.err
5125 rm -f conftest.er1
5126 cat conftest.err >&5
6a161fa9 5127 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5128 (exit $ac_status); } &&
144f1f98 5129 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 5130 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5131 (eval $ac_try) 2>&5
5132 ac_status=$?
5133 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5134 (exit $ac_status); }; } &&
5135 { ac_try='test -s conftest.$ac_objext'
6a161fa9 5136 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5137 (eval $ac_try) 2>&5
5138 ac_status=$?
5139 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5140 (exit $ac_status); }; }; then
5141 ac_hi=-1 ac_mid=-1
5142 while :; do
5143 cat >conftest.$ac_ext <<_ACEOF
98d15063 5144/* confdefs.h. */
5145_ACEOF
5146cat confdefs.h >>conftest.$ac_ext
5147cat >>conftest.$ac_ext <<_ACEOF
5148/* end confdefs.h. */
6a161fa9 5149$ac_includes_default
6a161fa9 5150int
5151main ()
5152{
5153static int test_array [1 - 2 * !(((long) (sizeof (void *))) >= $ac_mid)];
5154test_array [0] = 0
5155
5156 ;
5157 return 0;
5158}
5159_ACEOF
5160rm -f conftest.$ac_objext
5161if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 5162 (eval $ac_compile) 2>conftest.er1
6a161fa9 5163 ac_status=$?
924b6140 5164 grep -v '^ *+' conftest.er1 >conftest.err
5165 rm -f conftest.er1
5166 cat conftest.err >&5
6a161fa9 5167 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5168 (exit $ac_status); } &&
144f1f98 5169 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 5170 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5171 (eval $ac_try) 2>&5
5172 ac_status=$?
5173 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5174 (exit $ac_status); }; } &&
5175 { ac_try='test -s conftest.$ac_objext'
6a161fa9 5176 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5177 (eval $ac_try) 2>&5
5178 ac_status=$?
5179 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5180 (exit $ac_status); }; }; then
5181 ac_lo=$ac_mid; break
5182else
5183 echo "$as_me: failed program was:" >&5
98d15063 5184sed 's/^/| /' conftest.$ac_ext >&5
5185
6a161fa9 5186ac_hi=`expr '(' $ac_mid ')' - 1`
924b6140 5187 if test $ac_mid -le $ac_hi; then
5188 ac_lo= ac_hi=
5189 break
5190 fi
5191 ac_mid=`expr 2 '*' $ac_mid`
6a161fa9 5192fi
924b6140 5193rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 5194 done
5195else
5196 echo "$as_me: failed program was:" >&5
98d15063 5197sed 's/^/| /' conftest.$ac_ext >&5
5198
6a161fa9 5199ac_lo= ac_hi=
5200fi
924b6140 5201rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 5202fi
924b6140 5203rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 5204# Binary search between lo and hi bounds.
5205while test "x$ac_lo" != "x$ac_hi"; do
5206 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
5207 cat >conftest.$ac_ext <<_ACEOF
98d15063 5208/* confdefs.h. */
5209_ACEOF
5210cat confdefs.h >>conftest.$ac_ext
5211cat >>conftest.$ac_ext <<_ACEOF
5212/* end confdefs.h. */
6a161fa9 5213$ac_includes_default
6a161fa9 5214int
5215main ()
5216{
5217static int test_array [1 - 2 * !(((long) (sizeof (void *))) <= $ac_mid)];
5218test_array [0] = 0
5219
5220 ;
5221 return 0;
5222}
5223_ACEOF
5224rm -f conftest.$ac_objext
5225if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 5226 (eval $ac_compile) 2>conftest.er1
6a161fa9 5227 ac_status=$?
924b6140 5228 grep -v '^ *+' conftest.er1 >conftest.err
5229 rm -f conftest.er1
5230 cat conftest.err >&5
6a161fa9 5231 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5232 (exit $ac_status); } &&
144f1f98 5233 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 5234 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5235 (eval $ac_try) 2>&5
5236 ac_status=$?
5237 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5238 (exit $ac_status); }; } &&
5239 { ac_try='test -s conftest.$ac_objext'
6a161fa9 5240 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5241 (eval $ac_try) 2>&5
5242 ac_status=$?
5243 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5244 (exit $ac_status); }; }; then
5245 ac_hi=$ac_mid
5246else
5247 echo "$as_me: failed program was:" >&5
98d15063 5248sed 's/^/| /' conftest.$ac_ext >&5
5249
6a161fa9 5250ac_lo=`expr '(' $ac_mid ')' + 1`
5251fi
924b6140 5252rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 5253done
5254case $ac_lo in
5255?*) ac_cv_sizeof_void_p=$ac_lo;;
98d15063 5256'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (void *), 77
5257See \`config.log' for more details." >&5
5258echo "$as_me: error: cannot compute sizeof (void *), 77
5259See \`config.log' for more details." >&2;}
6a161fa9 5260 { (exit 1); exit 1; }; } ;;
5261esac
5262else
5263 if test "$cross_compiling" = yes; then
144f1f98 5264 { { echo "$as_me:$LINENO: error: internal error: not reached in cross-compile" >&5
5265echo "$as_me: error: internal error: not reached in cross-compile" >&2;}
6a161fa9 5266 { (exit 1); exit 1; }; }
5267else
5268 cat >conftest.$ac_ext <<_ACEOF
98d15063 5269/* confdefs.h. */
5270_ACEOF
5271cat confdefs.h >>conftest.$ac_ext
5272cat >>conftest.$ac_ext <<_ACEOF
5273/* end confdefs.h. */
6a161fa9 5274$ac_includes_default
5275long longval () { return (long) (sizeof (void *)); }
5276unsigned long ulongval () { return (long) (sizeof (void *)); }
5277#include <stdio.h>
5278#include <stdlib.h>
6a161fa9 5279int
5280main ()
5281{
5282
5283 FILE *f = fopen ("conftest.val", "w");
5284 if (! f)
5285 exit (1);
5286 if (((long) (sizeof (void *))) < 0)
5287 {
5288 long i = longval ();
5289 if (i != ((long) (sizeof (void *))))
5290 exit (1);
5291 fprintf (f, "%ld\n", i);
5292 }
5293 else
5294 {
5295 unsigned long i = ulongval ();
5296 if (i != ((long) (sizeof (void *))))
5297 exit (1);
5298 fprintf (f, "%lu\n", i);
5299 }
5300 exit (ferror (f) || fclose (f) != 0);
5301
5302 ;
5303 return 0;
5304}
5305_ACEOF
5306rm -f conftest$ac_exeext
5307if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5308 (eval $ac_link) 2>&5
5309 ac_status=$?
5310 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5311 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5312 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5313 (eval $ac_try) 2>&5
5314 ac_status=$?
5315 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5316 (exit $ac_status); }; }; then
5317 ac_cv_sizeof_void_p=`cat conftest.val`
5318else
5319 echo "$as_me: program exited with status $ac_status" >&5
5320echo "$as_me: failed program was:" >&5
98d15063 5321sed 's/^/| /' conftest.$ac_ext >&5
5322
6a161fa9 5323( exit $ac_status )
98d15063 5324{ { echo "$as_me:$LINENO: error: cannot compute sizeof (void *), 77
5325See \`config.log' for more details." >&5
5326echo "$as_me: error: cannot compute sizeof (void *), 77
5327See \`config.log' for more details." >&2;}
6a161fa9 5328 { (exit 1); exit 1; }; }
5329fi
924b6140 5330rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6a161fa9 5331fi
5332fi
5333rm -f conftest.val
5334else
5335 ac_cv_sizeof_void_p=0
5336fi
5337fi
5338echo "$as_me:$LINENO: result: $ac_cv_sizeof_void_p" >&5
5339echo "${ECHO_T}$ac_cv_sizeof_void_p" >&6
5340cat >>confdefs.h <<_ACEOF
5341#define SIZEOF_VOID_P $ac_cv_sizeof_void_p
5342_ACEOF
5343
5344
5345echo "$as_me:$LINENO: checking for long" >&5
5346echo $ECHO_N "checking for long... $ECHO_C" >&6
5347if test "${ac_cv_type_long+set}" = set; then
5348 echo $ECHO_N "(cached) $ECHO_C" >&6
5349else
5350 cat >conftest.$ac_ext <<_ACEOF
98d15063 5351/* confdefs.h. */
5352_ACEOF
5353cat confdefs.h >>conftest.$ac_ext
5354cat >>conftest.$ac_ext <<_ACEOF
5355/* end confdefs.h. */
6a161fa9 5356$ac_includes_default
6a161fa9 5357int
5358main ()
5359{
5360if ((long *) 0)
5361 return 0;
5362if (sizeof (long))
5363 return 0;
5364 ;
5365 return 0;
5366}
5367_ACEOF
5368rm -f conftest.$ac_objext
5369if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 5370 (eval $ac_compile) 2>conftest.er1
6a161fa9 5371 ac_status=$?
924b6140 5372 grep -v '^ *+' conftest.er1 >conftest.err
5373 rm -f conftest.er1
5374 cat conftest.err >&5
6a161fa9 5375 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5376 (exit $ac_status); } &&
144f1f98 5377 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 5378 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5379 (eval $ac_try) 2>&5
5380 ac_status=$?
5381 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5382 (exit $ac_status); }; } &&
5383 { ac_try='test -s conftest.$ac_objext'
6a161fa9 5384 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5385 (eval $ac_try) 2>&5
5386 ac_status=$?
5387 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5388 (exit $ac_status); }; }; then
5389 ac_cv_type_long=yes
5390else
5391 echo "$as_me: failed program was:" >&5
98d15063 5392sed 's/^/| /' conftest.$ac_ext >&5
5393
6a161fa9 5394ac_cv_type_long=no
5395fi
924b6140 5396rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 5397fi
5398echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
5399echo "${ECHO_T}$ac_cv_type_long" >&6
5400
5401echo "$as_me:$LINENO: checking size of long" >&5
5402echo $ECHO_N "checking size of long... $ECHO_C" >&6
5403if test "${ac_cv_sizeof_long+set}" = set; then
5404 echo $ECHO_N "(cached) $ECHO_C" >&6
5405else
5406 if test "$ac_cv_type_long" = yes; then
5407 # The cast to unsigned long works around a bug in the HP C Compiler
5408 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5409 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5410 # This bug is HP SR number 8606223364.
5411 if test "$cross_compiling" = yes; then
5412 # Depending upon the size, compute the lo and hi bounds.
5413cat >conftest.$ac_ext <<_ACEOF
98d15063 5414/* confdefs.h. */
5415_ACEOF
5416cat confdefs.h >>conftest.$ac_ext
5417cat >>conftest.$ac_ext <<_ACEOF
5418/* end confdefs.h. */
6a161fa9 5419$ac_includes_default
6a161fa9 5420int
5421main ()
5422{
5423static int test_array [1 - 2 * !(((long) (sizeof (long))) >= 0)];
5424test_array [0] = 0
5425
5426 ;
5427 return 0;
5428}
5429_ACEOF
5430rm -f conftest.$ac_objext
5431if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 5432 (eval $ac_compile) 2>conftest.er1
6a161fa9 5433 ac_status=$?
924b6140 5434 grep -v '^ *+' conftest.er1 >conftest.err
5435 rm -f conftest.er1
5436 cat conftest.err >&5
6a161fa9 5437 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5438 (exit $ac_status); } &&
144f1f98 5439 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 5440 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5441 (eval $ac_try) 2>&5
5442 ac_status=$?
5443 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5444 (exit $ac_status); }; } &&
5445 { ac_try='test -s conftest.$ac_objext'
6a161fa9 5446 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5447 (eval $ac_try) 2>&5
5448 ac_status=$?
5449 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5450 (exit $ac_status); }; }; then
5451 ac_lo=0 ac_mid=0
5452 while :; do
5453 cat >conftest.$ac_ext <<_ACEOF
98d15063 5454/* confdefs.h. */
5455_ACEOF
5456cat confdefs.h >>conftest.$ac_ext
5457cat >>conftest.$ac_ext <<_ACEOF
5458/* end confdefs.h. */
6a161fa9 5459$ac_includes_default
6a161fa9 5460int
5461main ()
5462{
5463static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
5464test_array [0] = 0
5465
5466 ;
5467 return 0;
5468}
5469_ACEOF
5470rm -f conftest.$ac_objext
5471if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 5472 (eval $ac_compile) 2>conftest.er1
6a161fa9 5473 ac_status=$?
924b6140 5474 grep -v '^ *+' conftest.er1 >conftest.err
5475 rm -f conftest.er1
5476 cat conftest.err >&5
6a161fa9 5477 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5478 (exit $ac_status); } &&
144f1f98 5479 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 5480 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5481 (eval $ac_try) 2>&5
5482 ac_status=$?
5483 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5484 (exit $ac_status); }; } &&
5485 { ac_try='test -s conftest.$ac_objext'
6a161fa9 5486 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5487 (eval $ac_try) 2>&5
5488 ac_status=$?
5489 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5490 (exit $ac_status); }; }; then
5491 ac_hi=$ac_mid; break
5492else
5493 echo "$as_me: failed program was:" >&5
98d15063 5494sed 's/^/| /' conftest.$ac_ext >&5
5495
6a161fa9 5496ac_lo=`expr $ac_mid + 1`
924b6140 5497 if test $ac_lo -le $ac_mid; then
5498 ac_lo= ac_hi=
5499 break
5500 fi
5501 ac_mid=`expr 2 '*' $ac_mid + 1`
6a161fa9 5502fi
924b6140 5503rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 5504 done
5505else
5506 echo "$as_me: failed program was:" >&5
98d15063 5507sed 's/^/| /' conftest.$ac_ext >&5
5508
6a161fa9 5509cat >conftest.$ac_ext <<_ACEOF
98d15063 5510/* confdefs.h. */
5511_ACEOF
5512cat confdefs.h >>conftest.$ac_ext
5513cat >>conftest.$ac_ext <<_ACEOF
5514/* end confdefs.h. */
6a161fa9 5515$ac_includes_default
6a161fa9 5516int
5517main ()
5518{
5519static int test_array [1 - 2 * !(((long) (sizeof (long))) < 0)];
5520test_array [0] = 0
5521
5522 ;
5523 return 0;
5524}
5525_ACEOF
5526rm -f conftest.$ac_objext
5527if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 5528 (eval $ac_compile) 2>conftest.er1
6a161fa9 5529 ac_status=$?
924b6140 5530 grep -v '^ *+' conftest.er1 >conftest.err
5531 rm -f conftest.er1
5532 cat conftest.err >&5
6a161fa9 5533 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5534 (exit $ac_status); } &&
144f1f98 5535 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 5536 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5537 (eval $ac_try) 2>&5
5538 ac_status=$?
5539 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5540 (exit $ac_status); }; } &&
5541 { ac_try='test -s conftest.$ac_objext'
6a161fa9 5542 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5543 (eval $ac_try) 2>&5
5544 ac_status=$?
5545 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5546 (exit $ac_status); }; }; then
5547 ac_hi=-1 ac_mid=-1
5548 while :; do
5549 cat >conftest.$ac_ext <<_ACEOF
98d15063 5550/* confdefs.h. */
5551_ACEOF
5552cat confdefs.h >>conftest.$ac_ext
5553cat >>conftest.$ac_ext <<_ACEOF
5554/* end confdefs.h. */
6a161fa9 5555$ac_includes_default
6a161fa9 5556int
5557main ()
5558{
5559static int test_array [1 - 2 * !(((long) (sizeof (long))) >= $ac_mid)];
5560test_array [0] = 0
5561
5562 ;
5563 return 0;
5564}
5565_ACEOF
5566rm -f conftest.$ac_objext
5567if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 5568 (eval $ac_compile) 2>conftest.er1
6a161fa9 5569 ac_status=$?
924b6140 5570 grep -v '^ *+' conftest.er1 >conftest.err
5571 rm -f conftest.er1
5572 cat conftest.err >&5
6a161fa9 5573 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5574 (exit $ac_status); } &&
144f1f98 5575 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 5576 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5577 (eval $ac_try) 2>&5
5578 ac_status=$?
5579 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5580 (exit $ac_status); }; } &&
5581 { ac_try='test -s conftest.$ac_objext'
6a161fa9 5582 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5583 (eval $ac_try) 2>&5
5584 ac_status=$?
5585 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5586 (exit $ac_status); }; }; then
5587 ac_lo=$ac_mid; break
5588else
5589 echo "$as_me: failed program was:" >&5
98d15063 5590sed 's/^/| /' conftest.$ac_ext >&5
5591
6a161fa9 5592ac_hi=`expr '(' $ac_mid ')' - 1`
924b6140 5593 if test $ac_mid -le $ac_hi; then
5594 ac_lo= ac_hi=
5595 break
5596 fi
5597 ac_mid=`expr 2 '*' $ac_mid`
6a161fa9 5598fi
924b6140 5599rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 5600 done
5601else
5602 echo "$as_me: failed program was:" >&5
98d15063 5603sed 's/^/| /' conftest.$ac_ext >&5
5604
6a161fa9 5605ac_lo= ac_hi=
5606fi
924b6140 5607rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 5608fi
924b6140 5609rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 5610# Binary search between lo and hi bounds.
5611while test "x$ac_lo" != "x$ac_hi"; do
5612 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
5613 cat >conftest.$ac_ext <<_ACEOF
98d15063 5614/* confdefs.h. */
5615_ACEOF
5616cat confdefs.h >>conftest.$ac_ext
5617cat >>conftest.$ac_ext <<_ACEOF
5618/* end confdefs.h. */
6a161fa9 5619$ac_includes_default
6a161fa9 5620int
5621main ()
5622{
5623static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
5624test_array [0] = 0
5625
5626 ;
5627 return 0;
5628}
5629_ACEOF
5630rm -f conftest.$ac_objext
5631if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
924b6140 5632 (eval $ac_compile) 2>conftest.er1
6a161fa9 5633 ac_status=$?
924b6140 5634 grep -v '^ *+' conftest.er1 >conftest.err
5635 rm -f conftest.er1
5636 cat conftest.err >&5
6a161fa9 5637 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5638 (exit $ac_status); } &&
144f1f98 5639 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 5640 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5641 (eval $ac_try) 2>&5
5642 ac_status=$?
5643 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5644 (exit $ac_status); }; } &&
5645 { ac_try='test -s conftest.$ac_objext'
6a161fa9 5646 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5647 (eval $ac_try) 2>&5
5648 ac_status=$?
5649 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5650 (exit $ac_status); }; }; then
5651 ac_hi=$ac_mid
5652else
5653 echo "$as_me: failed program was:" >&5
98d15063 5654sed 's/^/| /' conftest.$ac_ext >&5
5655
6a161fa9 5656ac_lo=`expr '(' $ac_mid ')' + 1`
5657fi
924b6140 5658rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6a161fa9 5659done
5660case $ac_lo in
5661?*) ac_cv_sizeof_long=$ac_lo;;
98d15063 5662'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
5663See \`config.log' for more details." >&5
5664echo "$as_me: error: cannot compute sizeof (long), 77
5665See \`config.log' for more details." >&2;}
6a161fa9 5666 { (exit 1); exit 1; }; } ;;
5667esac
5668else
5669 if test "$cross_compiling" = yes; then
144f1f98 5670 { { echo "$as_me:$LINENO: error: internal error: not reached in cross-compile" >&5
5671echo "$as_me: error: internal error: not reached in cross-compile" >&2;}
6a161fa9 5672 { (exit 1); exit 1; }; }
5673else
5674 cat >conftest.$ac_ext <<_ACEOF
98d15063 5675/* confdefs.h. */
5676_ACEOF
5677cat confdefs.h >>conftest.$ac_ext
5678cat >>conftest.$ac_ext <<_ACEOF
5679/* end confdefs.h. */
6a161fa9 5680$ac_includes_default
5681long longval () { return (long) (sizeof (long)); }
5682unsigned long ulongval () { return (long) (sizeof (long)); }
5683#include <stdio.h>
5684#include <stdlib.h>
6a161fa9 5685int
5686main ()
5687{
5688
5689 FILE *f = fopen ("conftest.val", "w");
5690 if (! f)
5691 exit (1);
5692 if (((long) (sizeof (long))) < 0)
5693 {
5694 long i = longval ();
5695 if (i != ((long) (sizeof (long))))
5696 exit (1);
5697 fprintf (f, "%ld\n", i);
5698 }
5699 else
5700 {
5701 unsigned long i = ulongval ();
5702 if (i != ((long) (sizeof (long))))
5703 exit (1);
5704 fprintf (f, "%lu\n", i);
5705 }
5706 exit (ferror (f) || fclose (f) != 0);
5707
5708 ;
5709 return 0;
5710}
5711_ACEOF
5712rm -f conftest$ac_exeext
5713if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5714 (eval $ac_link) 2>&5
5715 ac_status=$?
5716 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5717 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5718 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5719 (eval $ac_try) 2>&5
5720 ac_status=$?
5721 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5722 (exit $ac_status); }; }; then
5723 ac_cv_sizeof_long=`cat conftest.val`
5724else
5725 echo "$as_me: program exited with status $ac_status" >&5
5726echo "$as_me: failed program was:" >&5
98d15063 5727sed 's/^/| /' conftest.$ac_ext >&5
5728
6a161fa9 5729( exit $ac_status )
98d15063 5730{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
5731See \`config.log' for more details." >&5
5732echo "$as_me: error: cannot compute sizeof (long), 77
5733See \`config.log' for more details." >&2;}
6a161fa9 5734 { (exit 1); exit 1; }; }
5735fi
924b6140 5736rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6a161fa9 5737fi
5738fi
5739rm -f conftest.val
5740else
5741 ac_cv_sizeof_long=0
5742fi
5743fi
5744echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
5745echo "${ECHO_T}$ac_cv_sizeof_long" >&6
5746cat >>confdefs.h <<_ACEOF
5747#define SIZEOF_LONG $ac_cv_sizeof_long
5748_ACEOF
5749
5750
1f5ab428 5751
e56cdf21 5752# Check LZO when compiling for the i386.
5753if test "x$host_cpu" = xi386; then
4ac9bd04 5754 # There are three possibilities. LZO version 2 installed with the name
5755 # liblzo2, with the name liblzo, and LZO version 1.
5756 echo "$as_me:$LINENO: checking for __lzo_init_v2 in -llzo2" >&5
5757echo $ECHO_N "checking for __lzo_init_v2 in -llzo2... $ECHO_C" >&6
5758if test "${ac_cv_lib_lzo2___lzo_init_v2+set}" = set; then
5759 echo $ECHO_N "(cached) $ECHO_C" >&6
5760else
5761 ac_check_lib_save_LIBS=$LIBS
5762LIBS="-llzo2 $LIBS"
5763cat >conftest.$ac_ext <<_ACEOF
5764/* confdefs.h. */
5765_ACEOF
5766cat confdefs.h >>conftest.$ac_ext
5767cat >>conftest.$ac_ext <<_ACEOF
5768/* end confdefs.h. */
5769
5770/* Override any gcc2 internal prototype to avoid an error. */
5771#ifdef __cplusplus
5772extern "C"
5773#endif
5774/* We use char because int might match the return type of a gcc2
5775 builtin and then its argument prototype would still apply. */
5776char __lzo_init_v2 ();
5777int
5778main ()
5779{
5780__lzo_init_v2 ();
5781 ;
5782 return 0;
5783}
5784_ACEOF
5785rm -f conftest.$ac_objext conftest$ac_exeext
5786if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5787 (eval $ac_link) 2>conftest.er1
5788 ac_status=$?
5789 grep -v '^ *+' conftest.er1 >conftest.err
5790 rm -f conftest.er1
5791 cat conftest.err >&5
5792 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5793 (exit $ac_status); } &&
144f1f98 5794 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
4ac9bd04 5795 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5796 (eval $ac_try) 2>&5
5797 ac_status=$?
5798 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5799 (exit $ac_status); }; } &&
5800 { ac_try='test -s conftest$ac_exeext'
5801 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5802 (eval $ac_try) 2>&5
5803 ac_status=$?
5804 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5805 (exit $ac_status); }; }; then
5806 ac_cv_lib_lzo2___lzo_init_v2=yes
5807else
5808 echo "$as_me: failed program was:" >&5
5809sed 's/^/| /' conftest.$ac_ext >&5
5810
5811ac_cv_lib_lzo2___lzo_init_v2=no
5812fi
5813rm -f conftest.err conftest.$ac_objext \
5814 conftest$ac_exeext conftest.$ac_ext
5815LIBS=$ac_check_lib_save_LIBS
5816fi
5817echo "$as_me:$LINENO: result: $ac_cv_lib_lzo2___lzo_init_v2" >&5
5818echo "${ECHO_T}$ac_cv_lib_lzo2___lzo_init_v2" >&6
5819if test $ac_cv_lib_lzo2___lzo_init_v2 = yes; then
5820 LIBLZO="-llzo2"
5821else
5822 echo "$as_me:$LINENO: checking for __lzo_init_v2 in -llzo" >&5
5823echo $ECHO_N "checking for __lzo_init_v2 in -llzo... $ECHO_C" >&6
5824if test "${ac_cv_lib_lzo___lzo_init_v2+set}" = set; then
5825 echo $ECHO_N "(cached) $ECHO_C" >&6
5826else
5827 ac_check_lib_save_LIBS=$LIBS
5828LIBS="-llzo $LIBS"
5829cat >conftest.$ac_ext <<_ACEOF
5830/* confdefs.h. */
5831_ACEOF
5832cat confdefs.h >>conftest.$ac_ext
5833cat >>conftest.$ac_ext <<_ACEOF
5834/* end confdefs.h. */
1f5ab428 5835
4ac9bd04 5836/* Override any gcc2 internal prototype to avoid an error. */
5837#ifdef __cplusplus
5838extern "C"
5839#endif
5840/* We use char because int might match the return type of a gcc2
5841 builtin and then its argument prototype would still apply. */
5842char __lzo_init_v2 ();
5843int
5844main ()
5845{
5846__lzo_init_v2 ();
5847 ;
5848 return 0;
5849}
5850_ACEOF
5851rm -f conftest.$ac_objext conftest$ac_exeext
5852if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5853 (eval $ac_link) 2>conftest.er1
5854 ac_status=$?
5855 grep -v '^ *+' conftest.er1 >conftest.err
5856 rm -f conftest.er1
5857 cat conftest.err >&5
5858 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5859 (exit $ac_status); } &&
144f1f98 5860 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
4ac9bd04 5861 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5862 (eval $ac_try) 2>&5
5863 ac_status=$?
5864 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5865 (exit $ac_status); }; } &&
5866 { ac_try='test -s conftest$ac_exeext'
5867 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5868 (eval $ac_try) 2>&5
5869 ac_status=$?
5870 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5871 (exit $ac_status); }; }; then
5872 ac_cv_lib_lzo___lzo_init_v2=yes
5873else
5874 echo "$as_me: failed program was:" >&5
5875sed 's/^/| /' conftest.$ac_ext >&5
5876
5877ac_cv_lib_lzo___lzo_init_v2=no
5878fi
5879rm -f conftest.err conftest.$ac_objext \
5880 conftest$ac_exeext conftest.$ac_ext
5881LIBS=$ac_check_lib_save_LIBS
5882fi
5883echo "$as_me:$LINENO: result: $ac_cv_lib_lzo___lzo_init_v2" >&5
5884echo "${ECHO_T}$ac_cv_lib_lzo___lzo_init_v2" >&6
5885if test $ac_cv_lib_lzo___lzo_init_v2 = yes; then
5886 LIBLZO="-llzo"
5887else
5888 echo "$as_me:$LINENO: checking for __lzo_init2 in -llzo" >&5
1f5ab428 5889echo $ECHO_N "checking for __lzo_init2 in -llzo... $ECHO_C" >&6
5890if test "${ac_cv_lib_lzo___lzo_init2+set}" = set; then
5891 echo $ECHO_N "(cached) $ECHO_C" >&6
5892else
5893 ac_check_lib_save_LIBS=$LIBS
5894LIBS="-llzo $LIBS"
5895cat >conftest.$ac_ext <<_ACEOF
98d15063 5896/* confdefs.h. */
5897_ACEOF
5898cat confdefs.h >>conftest.$ac_ext
5899cat >>conftest.$ac_ext <<_ACEOF
5900/* end confdefs.h. */
1f5ab428 5901
5902/* Override any gcc2 internal prototype to avoid an error. */
5903#ifdef __cplusplus
5904extern "C"
5905#endif
5906/* We use char because int might match the return type of a gcc2
5907 builtin and then its argument prototype would still apply. */
5908char __lzo_init2 ();
1f5ab428 5909int
5910main ()
5911{
5912__lzo_init2 ();
5913 ;
5914 return 0;
5915}
5916_ACEOF
5917rm -f conftest.$ac_objext conftest$ac_exeext
5918if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
924b6140 5919 (eval $ac_link) 2>conftest.er1
1f5ab428 5920 ac_status=$?
924b6140 5921 grep -v '^ *+' conftest.er1 >conftest.err
5922 rm -f conftest.er1
5923 cat conftest.err >&5
1f5ab428 5924 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5925 (exit $ac_status); } &&
144f1f98 5926 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 5927 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5928 (eval $ac_try) 2>&5
5929 ac_status=$?
5930 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5931 (exit $ac_status); }; } &&
5932 { ac_try='test -s conftest$ac_exeext'
1f5ab428 5933 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5934 (eval $ac_try) 2>&5
5935 ac_status=$?
5936 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5937 (exit $ac_status); }; }; then
5938 ac_cv_lib_lzo___lzo_init2=yes
5939else
5940 echo "$as_me: failed program was:" >&5
98d15063 5941sed 's/^/| /' conftest.$ac_ext >&5
5942
1f5ab428 5943ac_cv_lib_lzo___lzo_init2=no
5944fi
924b6140 5945rm -f conftest.err conftest.$ac_objext \
5946 conftest$ac_exeext conftest.$ac_ext
1f5ab428 5947LIBS=$ac_check_lib_save_LIBS
5948fi
5949echo "$as_me:$LINENO: result: $ac_cv_lib_lzo___lzo_init2" >&5
5950echo "${ECHO_T}$ac_cv_lib_lzo___lzo_init2" >&6
5951if test $ac_cv_lib_lzo___lzo_init2 = yes; then
4ac9bd04 5952 LIBLZO="-llzo"
1f5ab428 5953else
5954 { { echo "$as_me:$LINENO: error: LZO library version 1.02 or later is required" >&5
5955echo "$as_me: error: LZO library version 1.02 or later is required" >&2;}
5956 { (exit 1); exit 1; }; }
5957fi
5958
4ac9bd04 5959fi
5960
5961fi
5962
5963
5964 LIBS="$LIBS $LIBLZO"
e56cdf21 5965 echo "$as_me:$LINENO: checking for lzo1x_999_compress" >&5
1f5ab428 5966echo $ECHO_N "checking for lzo1x_999_compress... $ECHO_C" >&6
5967if test "${ac_cv_func_lzo1x_999_compress+set}" = set; then
5968 echo $ECHO_N "(cached) $ECHO_C" >&6
5969else
5970 cat >conftest.$ac_ext <<_ACEOF
98d15063 5971/* confdefs.h. */
5972_ACEOF
5973cat confdefs.h >>conftest.$ac_ext
5974cat >>conftest.$ac_ext <<_ACEOF
5975/* end confdefs.h. */
924b6140 5976/* Define lzo1x_999_compress to an innocuous variant, in case <limits.h> declares lzo1x_999_compress.
5977 For example, HP-UX 11i <limits.h> declares gettimeofday. */
5978#define lzo1x_999_compress innocuous_lzo1x_999_compress
5979
1f5ab428 5980/* System header to define __stub macros and hopefully few prototypes,
98d15063 5981 which can conflict with char lzo1x_999_compress (); below.
5982 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5983 <limits.h> exists even on freestanding compilers. */
924b6140 5984
98d15063 5985#ifdef __STDC__
5986# include <limits.h>
5987#else
5988# include <assert.h>
5989#endif
924b6140 5990
5991#undef lzo1x_999_compress
5992
1f5ab428 5993/* Override any gcc2 internal prototype to avoid an error. */
5994#ifdef __cplusplus
5995extern "C"
98d15063 5996{
1f5ab428 5997#endif
5998/* We use char because int might match the return type of a gcc2
5999 builtin and then its argument prototype would still apply. */
6000char lzo1x_999_compress ();
1f5ab428 6001/* The GNU C library defines this for functions which it implements
6002 to always fail with ENOSYS. Some functions are actually named
6003 something starting with __ and the normal name is an alias. */
6004#if defined (__stub_lzo1x_999_compress) || defined (__stub___lzo1x_999_compress)
6005choke me
6006#else
98d15063 6007char (*f) () = lzo1x_999_compress;
6008#endif
6009#ifdef __cplusplus
6010}
1f5ab428 6011#endif
6012
98d15063 6013int
6014main ()
6015{
6016return f != lzo1x_999_compress;
1f5ab428 6017 ;
6018 return 0;
6019}
6020_ACEOF
6021rm -f conftest.$ac_objext conftest$ac_exeext
6022if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
924b6140 6023 (eval $ac_link) 2>conftest.er1
1f5ab428 6024 ac_status=$?
924b6140 6025 grep -v '^ *+' conftest.er1 >conftest.err
6026 rm -f conftest.er1
6027 cat conftest.err >&5
1f5ab428 6028 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6029 (exit $ac_status); } &&
144f1f98 6030 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
924b6140 6031 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6032 (eval $ac_try) 2>&5
6033 ac_status=$?
6034 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6035 (exit $ac_status); }; } &&
6036 { ac_try='test -s conftest$ac_exeext'
1f5ab428 6037 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6038 (eval $ac_try) 2>&5
6039 ac_status=$?
6040 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6041 (exit $ac_status); }; }; then
6042 ac_cv_func_lzo1x_999_compress=yes
6043else
6044 echo "$as_me: failed program was:" >&5
98d15063 6045sed 's/^/| /' conftest.$ac_ext >&5
6046
1f5ab428 6047ac_cv_func_lzo1x_999_compress=no
6048fi
924b6140 6049rm -f conftest.err conftest.$ac_objext \
6050 conftest$ac_exeext conftest.$ac_ext
1f5ab428 6051fi
6052echo "$as_me:$LINENO: result: $ac_cv_func_lzo1x_999_compress" >&5
6053echo "${ECHO_T}$ac_cv_func_lzo1x_999_compress" >&6
6054if test $ac_cv_func_lzo1x_999_compress = yes; then
6055 :
6056else
6057 { { echo "$as_me:$LINENO: error: LZO1X-999 must be enabled" >&5
6058echo "$as_me: error: LZO1X-999 must be enabled" >&2;}
6059 { (exit 1); exit 1; }; }
6060fi
6061
4ac9bd04 6062
6063 # LZO version 2 uses lzo/lzo1x.h, while LZO version 1 uses lzo1x.h.
6064
6065
6066for ac_header in lzo/lzo1x.h lzo1x.h
6067do
6068as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6069if eval "test \"\${$as_ac_Header+set}\" = set"; then
6070 echo "$as_me:$LINENO: checking for $ac_header" >&5
6071echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6072if eval "test \"\${$as_ac_Header+set}\" = set"; then
6073 echo $ECHO_N "(cached) $ECHO_C" >&6
6074fi
6075echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6076echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6077else
6078 # Is the header compilable?
6079echo "$as_me:$LINENO: checking $ac_header usability" >&5
6080echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
6081cat >conftest.$ac_ext <<_ACEOF
6082/* confdefs.h. */
6083_ACEOF
6084cat confdefs.h >>conftest.$ac_ext
6085cat >>conftest.$ac_ext <<_ACEOF
6086/* end confdefs.h. */
6087$ac_includes_default
6088#include <$ac_header>
6089_ACEOF
6090rm -f conftest.$ac_objext
6091if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6092 (eval $ac_compile) 2>conftest.er1
6093 ac_status=$?
6094 grep -v '^ *+' conftest.er1 >conftest.err
6095 rm -f conftest.er1
6096 cat conftest.err >&5
6097 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6098 (exit $ac_status); } &&
144f1f98 6099 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
4ac9bd04 6100 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6101 (eval $ac_try) 2>&5
6102 ac_status=$?
6103 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6104 (exit $ac_status); }; } &&
6105 { ac_try='test -s conftest.$ac_objext'
6106 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6107 (eval $ac_try) 2>&5
6108 ac_status=$?
6109 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6110 (exit $ac_status); }; }; then
6111 ac_header_compiler=yes
6112else
6113 echo "$as_me: failed program was:" >&5
6114sed 's/^/| /' conftest.$ac_ext >&5
6115
6116ac_header_compiler=no
6117fi
6118rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6119echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
6120echo "${ECHO_T}$ac_header_compiler" >&6
6121
6122# Is the header present?
6123echo "$as_me:$LINENO: checking $ac_header presence" >&5
6124echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
6125cat >conftest.$ac_ext <<_ACEOF
6126/* confdefs.h. */
6127_ACEOF
6128cat confdefs.h >>conftest.$ac_ext
6129cat >>conftest.$ac_ext <<_ACEOF
6130/* end confdefs.h. */
6131#include <$ac_header>
6132_ACEOF
6133if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6134 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6135 ac_status=$?
6136 grep -v '^ *+' conftest.er1 >conftest.err
6137 rm -f conftest.er1
6138 cat conftest.err >&5
6139 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6140 (exit $ac_status); } >/dev/null; then
6141 if test -s conftest.err; then
6142 ac_cpp_err=$ac_c_preproc_warn_flag
6143 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6144 else
6145 ac_cpp_err=
6146 fi
6147else
6148 ac_cpp_err=yes
6149fi
6150if test -z "$ac_cpp_err"; then
6151 ac_header_preproc=yes
6152else
6153 echo "$as_me: failed program was:" >&5
6154sed 's/^/| /' conftest.$ac_ext >&5
6155
6156 ac_header_preproc=no
6157fi
6158rm -f conftest.err conftest.$ac_ext
6159echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
6160echo "${ECHO_T}$ac_header_preproc" >&6
6161
6162# So? What about this header?
6163case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
6164 yes:no: )
6165 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
6166echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
6167 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
6168echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
6169 ac_header_preproc=yes
6170 ;;
6171 no:yes:* )
6172 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
6173echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
6174 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
6175echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
6176 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
6177echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
6178 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
6179echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
6180 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
6181echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
6182 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
6183echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
6184 (
6185 cat <<\_ASBOX
6186## ------------------------------- ##
6187## Report this to bug-grub@gnu.org ##
6188## ------------------------------- ##
6189_ASBOX
6190 ) |
6191 sed "s/^/$as_me: WARNING: /" >&2
6192 ;;
6193esac
6194echo "$as_me:$LINENO: checking for $ac_header" >&5
6195echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6196if eval "test \"\${$as_ac_Header+set}\" = set"; then
6197 echo $ECHO_N "(cached) $ECHO_C" >&6
6198else
6199 eval "$as_ac_Header=\$ac_header_preproc"
6200fi
6201echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6202echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6203
6204fi
6205if test `eval echo '${'$as_ac_Header'}'` = yes; then
6206 cat >>confdefs.h <<_ACEOF
6207#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6208_ACEOF
6209
6210fi
6211
6212done
6213
e56cdf21 6214fi
1f5ab428 6215
f4917dfd 6216# Check for curses.
6217echo "$as_me:$LINENO: checking for wgetch in -lncurses" >&5
6218echo $ECHO_N "checking for wgetch in -lncurses... $ECHO_C" >&6
6219if test "${ac_cv_lib_ncurses_wgetch+set}" = set; then
6220 echo $ECHO_N "(cached) $ECHO_C" >&6
6221else
6222 ac_check_lib_save_LIBS=$LIBS
6223LIBS="-lncurses $LIBS"
6224cat >conftest.$ac_ext <<_ACEOF
6225/* confdefs.h. */
6226_ACEOF
6227cat confdefs.h >>conftest.$ac_ext
6228cat >>conftest.$ac_ext <<_ACEOF
6229/* end confdefs.h. */
6230
6231/* Override any gcc2 internal prototype to avoid an error. */
6232#ifdef __cplusplus
6233extern "C"
6234#endif
6235/* We use char because int might match the return type of a gcc2
6236 builtin and then its argument prototype would still apply. */
6237char wgetch ();
6238int
6239main ()
6240{
6241wgetch ();
6242 ;
6243 return 0;
6244}
6245_ACEOF
6246rm -f conftest.$ac_objext conftest$ac_exeext
6247if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6248 (eval $ac_link) 2>conftest.er1
6249 ac_status=$?
6250 grep -v '^ *+' conftest.er1 >conftest.err
6251 rm -f conftest.er1
6252 cat conftest.err >&5
6253 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6254 (exit $ac_status); } &&
144f1f98 6255 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
f4917dfd 6256 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6257 (eval $ac_try) 2>&5
6258 ac_status=$?
6259 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6260 (exit $ac_status); }; } &&
6261 { ac_try='test -s conftest$ac_exeext'
6262 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6263 (eval $ac_try) 2>&5
6264 ac_status=$?
6265 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6266 (exit $ac_status); }; }; then
6267 ac_cv_lib_ncurses_wgetch=yes
6268else
6269 echo "$as_me: failed program was:" >&5
6270sed 's/^/| /' conftest.$ac_ext >&5
6271
6272ac_cv_lib_ncurses_wgetch=no
6273fi
6274rm -f conftest.err conftest.$ac_objext \
6275 conftest$ac_exeext conftest.$ac_ext
6276LIBS=$ac_check_lib_save_LIBS
6277fi
6278echo "$as_me:$LINENO: result: $ac_cv_lib_ncurses_wgetch" >&5
6279echo "${ECHO_T}$ac_cv_lib_ncurses_wgetch" >&6
6280if test $ac_cv_lib_ncurses_wgetch = yes; then
6281 LIBCURSES="-lncurses"
6282else
6283 echo "$as_me:$LINENO: checking for wgetch in -lcurses" >&5
6284echo $ECHO_N "checking for wgetch in -lcurses... $ECHO_C" >&6
6285if test "${ac_cv_lib_curses_wgetch+set}" = set; then
6286 echo $ECHO_N "(cached) $ECHO_C" >&6
6287else
6288 ac_check_lib_save_LIBS=$LIBS
6289LIBS="-lcurses $LIBS"
6290cat >conftest.$ac_ext <<_ACEOF
6291/* confdefs.h. */
6292_ACEOF
6293cat confdefs.h >>conftest.$ac_ext
6294cat >>conftest.$ac_ext <<_ACEOF
6295/* end confdefs.h. */
6296
6297/* Override any gcc2 internal prototype to avoid an error. */
6298#ifdef __cplusplus
6299extern "C"
6300#endif
6301/* We use char because int might match the return type of a gcc2
6302 builtin and then its argument prototype would still apply. */
6303char wgetch ();
6304int
6305main ()
6306{
6307wgetch ();
6308 ;
6309 return 0;
6310}
6311_ACEOF
6312rm -f conftest.$ac_objext conftest$ac_exeext
6313if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6314 (eval $ac_link) 2>conftest.er1
6315 ac_status=$?
6316 grep -v '^ *+' conftest.er1 >conftest.err
6317 rm -f conftest.er1
6318 cat conftest.err >&5
6319 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6320 (exit $ac_status); } &&
144f1f98 6321 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
f4917dfd 6322 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6323 (eval $ac_try) 2>&5
6324 ac_status=$?
6325 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6326 (exit $ac_status); }; } &&
6327 { ac_try='test -s conftest$ac_exeext'
6328 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6329 (eval $ac_try) 2>&5
6330 ac_status=$?
6331 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6332 (exit $ac_status); }; }; then
6333 ac_cv_lib_curses_wgetch=yes
6334else
6335 echo "$as_me: failed program was:" >&5
6336sed 's/^/| /' conftest.$ac_ext >&5
6337
6338ac_cv_lib_curses_wgetch=no
6339fi
6340rm -f conftest.err conftest.$ac_objext \
6341 conftest$ac_exeext conftest.$ac_ext
6342LIBS=$ac_check_lib_save_LIBS
6343fi
6344echo "$as_me:$LINENO: result: $ac_cv_lib_curses_wgetch" >&5
6345echo "${ECHO_T}$ac_cv_lib_curses_wgetch" >&6
6346if test $ac_cv_lib_curses_wgetch = yes; then
6347 LIBCURSES="-lcurses"
6348fi
6349
6350fi
6351
6352
6353
6354# Check for headers.
6355
6356
6357
6358for ac_header in ncurses/curses.h ncurses.h curses.h
6359do
6360as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6361if eval "test \"\${$as_ac_Header+set}\" = set"; then
6362 echo "$as_me:$LINENO: checking for $ac_header" >&5
6363echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6364if eval "test \"\${$as_ac_Header+set}\" = set"; then
6365 echo $ECHO_N "(cached) $ECHO_C" >&6
6366fi
6367echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6368echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6369else
6370 # Is the header compilable?
6371echo "$as_me:$LINENO: checking $ac_header usability" >&5
6372echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
6373cat >conftest.$ac_ext <<_ACEOF
6374/* confdefs.h. */
6375_ACEOF
6376cat confdefs.h >>conftest.$ac_ext
6377cat >>conftest.$ac_ext <<_ACEOF
6378/* end confdefs.h. */
6379$ac_includes_default
6380#include <$ac_header>
6381_ACEOF
6382rm -f conftest.$ac_objext
6383if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6384 (eval $ac_compile) 2>conftest.er1
6385 ac_status=$?
6386 grep -v '^ *+' conftest.er1 >conftest.err
6387 rm -f conftest.er1
6388 cat conftest.err >&5
6389 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6390 (exit $ac_status); } &&
144f1f98 6391 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
f4917dfd 6392 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6393 (eval $ac_try) 2>&5
6394 ac_status=$?
6395 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6396 (exit $ac_status); }; } &&
6397 { ac_try='test -s conftest.$ac_objext'
6398 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6399 (eval $ac_try) 2>&5
6400 ac_status=$?
6401 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6402 (exit $ac_status); }; }; then
6403 ac_header_compiler=yes
6404else
6405 echo "$as_me: failed program was:" >&5
6406sed 's/^/| /' conftest.$ac_ext >&5
6407
6408ac_header_compiler=no
6409fi
6410rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6411echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
6412echo "${ECHO_T}$ac_header_compiler" >&6
6413
6414# Is the header present?
6415echo "$as_me:$LINENO: checking $ac_header presence" >&5
6416echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
6417cat >conftest.$ac_ext <<_ACEOF
6418/* confdefs.h. */
6419_ACEOF
6420cat confdefs.h >>conftest.$ac_ext
6421cat >>conftest.$ac_ext <<_ACEOF
6422/* end confdefs.h. */
6423#include <$ac_header>
6424_ACEOF
6425if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6426 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6427 ac_status=$?
6428 grep -v '^ *+' conftest.er1 >conftest.err
6429 rm -f conftest.er1
6430 cat conftest.err >&5
6431 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6432 (exit $ac_status); } >/dev/null; then
6433 if test -s conftest.err; then
6434 ac_cpp_err=$ac_c_preproc_warn_flag
6435 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6436 else
6437 ac_cpp_err=
6438 fi
6439else
6440 ac_cpp_err=yes
6441fi
6442if test -z "$ac_cpp_err"; then
6443 ac_header_preproc=yes
6444else
6445 echo "$as_me: failed program was:" >&5
6446sed 's/^/| /' conftest.$ac_ext >&5
6447
6448 ac_header_preproc=no
6449fi
6450rm -f conftest.err conftest.$ac_ext
6451echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
6452echo "${ECHO_T}$ac_header_preproc" >&6
6453
6454# So? What about this header?
6455case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
6456 yes:no: )
6457 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
6458echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
6459 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
6460echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
6461 ac_header_preproc=yes
6462 ;;
6463 no:yes:* )
6464 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
6465echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
6466 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
6467echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
6468 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
6469echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
6470 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
6471echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
6472 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
6473echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
6474 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
6475echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
6476 (
6477 cat <<\_ASBOX
6478## ------------------------------- ##
6479## Report this to bug-grub@gnu.org ##
6480## ------------------------------- ##
6481_ASBOX
6482 ) |
6483 sed "s/^/$as_me: WARNING: /" >&2
6484 ;;
6485esac
6486echo "$as_me:$LINENO: checking for $ac_header" >&5
6487echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6488if eval "test \"\${$as_ac_Header+set}\" = set"; then
6489 echo $ECHO_N "(cached) $ECHO_C" >&6
6490else
6491 eval "$as_ac_Header=\$ac_header_preproc"
6492fi
6493echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6494echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6495
6496fi
6497if test `eval echo '${'$as_ac_Header'}'` = yes; then
6498 cat >>confdefs.h <<_ACEOF
6499#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6500_ACEOF
6501
6502fi
6503
6504done
6505
6506
9962ed99 6507CC="$tmp_CC"
6508CFLAGS="$tmp_CFLAGS"
6509CPPFLAGS="$tmp_CPPFLAGS"
6a161fa9 6510
6511# Output files.
4b13b216 6512 ac_config_links="$ac_config_links include/grub/cpu:include/grub/$host_cpu include/grub/machine:include/grub/$host_cpu/$host_vendor"
6a161fa9 6513
98d15063 6514 ac_config_files="$ac_config_files Makefile"
6a161fa9 6515
98d15063 6516 ac_config_files="$ac_config_files stamp-h"
6a161fa9 6517
6518cat >confcache <<\_ACEOF
6519# This file is a shell script that caches the results of configure
6520# tests run on this system so they can be shared between configure
6521# scripts and configure runs, see configure's option --config-cache.
6522# It is not useful on other systems. If it contains results you don't
6523# want to keep, you may remove or edit it.
6524#
6525# config.status only pays attention to the cache file if you give it
6526# the --recheck option to rerun configure.
6527#
98d15063 6528# `ac_cv_env_foo' variables (set or unset) will be overridden when
6a161fa9 6529# loading this file, other *unset* `ac_cv_foo' will be assigned the
6530# following values.
6531
6532_ACEOF
6533
6534# The following way of writing the cache mishandles newlines in values,
6535# but we know of no workaround that is simple, portable, and efficient.
6536# So, don't put newlines in cache variables' values.
6537# Ultrix sh set writes to stderr and can't be redirected directly,
6538# and sets the high bit in the cache file unless we assign to the vars.
6539{
6540 (set) 2>&1 |
6541 case `(ac_space=' '; set | grep ac_space) 2>&1` in
6542 *ac_space=\ *)
6543 # `set' does not quote correctly, so add quotes (double-quote
6544 # substitution turns \\\\ into \\, and sed turns \\ into \).
6545 sed -n \
924b6140 6546 "s/'/'\\\\''/g;
6547 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
6a161fa9 6548 ;;
6549 *)
6550 # `set' quotes correctly as required by POSIX, so do not add quotes.
6551 sed -n \
924b6140 6552 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
6a161fa9 6553 ;;
6554 esac;
6555} |
6556 sed '
6557 t clear
6558 : clear
6559 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
6560 t end
6561 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
6562 : end' >>confcache
98d15063 6563if diff $cache_file confcache >/dev/null 2>&1; then :; else
6a161fa9 6564 if test -w $cache_file; then
6565 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
6566 cat confcache >$cache_file
6567 else
6568 echo "not updating unwritable cache $cache_file"
6569 fi
6570fi
6571rm -f confcache
6572
6573test "x$prefix" = xNONE && prefix=$ac_default_prefix
6574# Let make expand exec_prefix.
6575test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6576
6577# VPATH may cause trouble with some makes, so we remove $(srcdir),
6578# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
6579# trailing colons and then remove the whole line if VPATH becomes empty
6580# (actually we leave an empty line to preserve line numbers).
6581if test "x$srcdir" = x.; then
924b6140 6582 ac_vpsub='/^[ ]*VPATH[ ]*=/{
6a161fa9 6583s/:*\$(srcdir):*/:/;
6584s/:*\${srcdir}:*/:/;
6585s/:*@srcdir@:*/:/;
924b6140 6586s/^\([^=]*=[ ]*\):*/\1/;
6a161fa9 6587s/:*$//;
924b6140 6588s/^[^=]*=[ ]*$//;
6a161fa9 6589}'
6590fi
6591
6592DEFS=-DHAVE_CONFIG_H
6593
98d15063 6594ac_libobjs=
6595ac_ltlibobjs=
6596for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
6597 # 1. Remove the extension, and $U if already installed.
6598 ac_i=`echo "$ac_i" |
924b6140 6599 sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
98d15063 6600 # 2. Add them.
6601 ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
6602 ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
6603done
6604LIBOBJS=$ac_libobjs
6605
6606LTLIBOBJS=$ac_ltlibobjs
6607
6608
6a161fa9 6609
6610: ${CONFIG_STATUS=./config.status}
6611ac_clean_files_save=$ac_clean_files
6612ac_clean_files="$ac_clean_files $CONFIG_STATUS"
6613{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
6614echo "$as_me: creating $CONFIG_STATUS" >&6;}
6615cat >$CONFIG_STATUS <<_ACEOF
6616#! $SHELL
6617# Generated by $as_me.
6618# Run this file to recreate the current configuration.
6619# Compiler output produced by configure, useful for debugging
6620# configure, is in config.log if it exists.
6621
6622debug=false
98d15063 6623ac_cs_recheck=false
6624ac_cs_silent=false
6a161fa9 6625SHELL=\${CONFIG_SHELL-$SHELL}
6626_ACEOF
6627
6628cat >>$CONFIG_STATUS <<\_ACEOF
6a161fa9 6629## --------------------- ##
6630## M4sh Initialization. ##
6631## --------------------- ##
6632
6633# Be Bourne compatible
6634if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
6635 emulate sh
6636 NULLCMD=:
98d15063 6637 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
6638 # is contrary to our usage. Disable this feature.
6639 alias -g '${1+"$@"}'='"$@"'
6a161fa9 6640elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
6641 set -o posix
6642fi
924b6140 6643DUALCASE=1; export DUALCASE # for MKS sh
6a161fa9 6644
6a161fa9 6645# Support unset when possible.
924b6140 6646if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
6a161fa9 6647 as_unset=unset
6648else
6649 as_unset=false
6650fi
6651
98d15063 6652
6653# Work around bugs in pre-3.0 UWIN ksh.
6654$as_unset ENV MAIL MAILPATH
6655PS1='$ '
6656PS2='> '
6657PS4='+ '
6658
6659# NLS nuisances.
6660for as_var in \
6661 LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
6662 LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
6663 LC_TELEPHONE LC_TIME
6664do
924b6140 6665 if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
98d15063 6666 eval $as_var=C; export $as_var
6667 else
6668 $as_unset $as_var
6669 fi
6670done
6671
6672# Required to use basename.
6673if expr a : '\(a\)' >/dev/null 2>&1; then
6674 as_expr=expr
6675else
6676 as_expr=false
6677fi
6678
6679if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
6680 as_basename=basename
6681else
6682 as_basename=false
6683fi
6a161fa9 6684
6685
6686# Name of the executable.
98d15063 6687as_me=`$as_basename "$0" ||
6a161fa9 6688$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
6689 X"$0" : 'X\(//\)$' \| \
6690 X"$0" : 'X\(/\)$' \| \
6691 . : '\(.\)' 2>/dev/null ||
6692echo X/"$0" |
6693 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
6694 /^X\/\(\/\/\)$/{ s//\1/; q; }
6695 /^X\/\(\/\).*/{ s//\1/; q; }
6696 s/.*/./; q'`
6697
98d15063 6698
6a161fa9 6699# PATH needs CR, and LINENO needs CR and PATH.
6700# Avoid depending upon Character Ranges.
6701as_cr_letters='abcdefghijklmnopqrstuvwxyz'
6702as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
6703as_cr_Letters=$as_cr_letters$as_cr_LETTERS
6704as_cr_digits='0123456789'
6705as_cr_alnum=$as_cr_Letters$as_cr_digits
6706
6707# The user is always right.
6708if test "${PATH_SEPARATOR+set}" != set; then
98d15063 6709 echo "#! /bin/sh" >conf$$.sh
6710 echo "exit 0" >>conf$$.sh
6711 chmod +x conf$$.sh
6712 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
6a161fa9 6713 PATH_SEPARATOR=';'
6714 else
6715 PATH_SEPARATOR=:
6716 fi
98d15063 6717 rm -f conf$$.sh
6a161fa9 6718fi
6719
6720
6721 as_lineno_1=$LINENO
6722 as_lineno_2=$LINENO
6723 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
6724 test "x$as_lineno_1" != "x$as_lineno_2" &&
6725 test "x$as_lineno_3" = "x$as_lineno_2" || {
6726 # Find who we are. Look in the path if we contain no path at all
6727 # relative or not.
6728 case $0 in
6729 *[\\/]* ) as_myself=$0 ;;
6730 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6731for as_dir in $PATH
6732do
6733 IFS=$as_save_IFS
6734 test -z "$as_dir" && as_dir=.
6735 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
6736done
6737
6738 ;;
6739 esac
6740 # We did not find ourselves, most probably we were run as `sh COMMAND'
6741 # in which case we are not to be found in the path.
6742 if test "x$as_myself" = x; then
6743 as_myself=$0
6744 fi
6745 if test ! -f "$as_myself"; then
6746 { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
6747echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
6748 { (exit 1); exit 1; }; }
6749 fi
6750 case $CONFIG_SHELL in
6751 '')
6752 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6753for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
6754do
6755 IFS=$as_save_IFS
6756 test -z "$as_dir" && as_dir=.
6757 for as_base in sh bash ksh sh5; do
6758 case $as_dir in
6759 /*)
6760 if ("$as_dir/$as_base" -c '
6761 as_lineno_1=$LINENO
6762 as_lineno_2=$LINENO
6763 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
6764 test "x$as_lineno_1" != "x$as_lineno_2" &&
6765 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
98d15063 6766 $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
6767 $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
6a161fa9 6768 CONFIG_SHELL=$as_dir/$as_base
6769 export CONFIG_SHELL
6770 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
6771 fi;;
6772 esac
6773 done
6774done
6775;;
6776 esac
6777
6778 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
6779 # uniformly replaced by the line number. The first 'sed' inserts a
6780 # line-number line before each line; the second 'sed' does the real
6781 # work. The second script uses 'N' to pair each line-number line
6782 # with the numbered line, and appends trailing '-' during
6783 # substitution so that $LINENO is not a special case at line end.
6784 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
6785 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
6786 sed '=' <$as_myself |
6787 sed '
6788 N
6789 s,$,-,
6790 : loop
6791 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
6792 t loop
6793 s,-$,,
6794 s,^['$as_cr_digits']*\n,,
6795 ' >$as_me.lineno &&
6796 chmod +x $as_me.lineno ||
6797 { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
6798echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
6799 { (exit 1); exit 1; }; }
6800
6801 # Don't try to exec as it changes $[0], causing all sort of problems
6802 # (the dirname of $[0] is not the place where we might find the
6803 # original and so on. Autoconf is especially sensible to this).
6804 . ./$as_me.lineno
6805 # Exit status is that of the last command.
6806 exit
6807}
6808
6809
6810case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
6811 *c*,-n*) ECHO_N= ECHO_C='
6812' ECHO_T=' ' ;;
6813 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
6814 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
6815esac
6816
6817if expr a : '\(a\)' >/dev/null 2>&1; then
6818 as_expr=expr
6819else
6820 as_expr=false
6821fi
6822
6823rm -f conf$$ conf$$.exe conf$$.file
6824echo >conf$$.file
6825if ln -s conf$$.file conf$$ 2>/dev/null; then
6826 # We could just check for DJGPP; but this test a) works b) is more generic
6827 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
6828 if test -f conf$$.exe; then
6829 # Don't use ln at all; we don't have any links
6830 as_ln_s='cp -p'
6831 else
6832 as_ln_s='ln -s'
6833 fi
6834elif ln conf$$.file conf$$ 2>/dev/null; then
6835 as_ln_s=ln
6836else
6837 as_ln_s='cp -p'
6838fi
6839rm -f conf$$ conf$$.exe conf$$.file
6840
98d15063 6841if mkdir -p . 2>/dev/null; then
6842 as_mkdir_p=:
6843else
924b6140 6844 test -d ./-p && rmdir ./-p
98d15063 6845 as_mkdir_p=false
6846fi
6847
6a161fa9 6848as_executable_p="test -f"
6849
6850# Sed expression to map a string onto a valid CPP name.
924b6140 6851as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
6a161fa9 6852
6853# Sed expression to map a string onto a valid variable name.
924b6140 6854as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
6a161fa9 6855
6856
6857# IFS
6858# We need space, tab and new line, in precisely that order.
6859as_nl='
6860'
6861IFS=" $as_nl"
6862
6863# CDPATH.
98d15063 6864$as_unset CDPATH
6a161fa9 6865
6866exec 6>&1
6867
6868# Open the log real soon, to keep \$[0] and so on meaningful, and to
6869# report actual input values of CONFIG_FILES etc. instead of their
6870# values after options handling. Logging --version etc. is OK.
6871exec 5>>config.log
6872{
6873 echo
6874 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
6875## Running $as_me. ##
6876_ASBOX
6877} >&5
6878cat >&5 <<_CSEOF
6879
5f97350b 6880This file was extended by GRUB $as_me 1.93, which was
924b6140 6881generated by GNU Autoconf 2.59. Invocation command line was
6a161fa9 6882
6883 CONFIG_FILES = $CONFIG_FILES
6884 CONFIG_HEADERS = $CONFIG_HEADERS
6885 CONFIG_LINKS = $CONFIG_LINKS
6886 CONFIG_COMMANDS = $CONFIG_COMMANDS
6887 $ $0 $@
6888
6889_CSEOF
6890echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
6891echo >&5
6892_ACEOF
6893
6894# Files that config.status was made for.
6895if test -n "$ac_config_files"; then
6896 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
6897fi
6898
6899if test -n "$ac_config_headers"; then
6900 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
6901fi
6902
6903if test -n "$ac_config_links"; then
6904 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
6905fi
6906
6907if test -n "$ac_config_commands"; then
6908 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
6909fi
6910
6911cat >>$CONFIG_STATUS <<\_ACEOF
6912
6913ac_cs_usage="\
6914\`$as_me' instantiates files from templates according to the
6915current configuration.
6916
6917Usage: $0 [OPTIONS] [FILE]...
6918
6919 -h, --help print this help, then exit
6920 -V, --version print version number, then exit
98d15063 6921 -q, --quiet do not print progress messages
6a161fa9 6922 -d, --debug don't remove temporary files
6923 --recheck update $as_me by reconfiguring in the same conditions
6924 --file=FILE[:TEMPLATE]
924b6140 6925 instantiate the configuration file FILE
6a161fa9 6926 --header=FILE[:TEMPLATE]
924b6140 6927 instantiate the configuration header FILE
6a161fa9 6928
6929Configuration files:
6930$config_files
6931
6932Configuration headers:
6933$config_headers
6934
6935Configuration links:
6936$config_links
6937
6938Report bugs to <bug-autoconf@gnu.org>."
6939_ACEOF
6940
6941cat >>$CONFIG_STATUS <<_ACEOF
6942ac_cs_version="\\
5f97350b 6943GRUB config.status 1.93
924b6140 6944configured by $0, generated by GNU Autoconf 2.59,
6a161fa9 6945 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
6946
924b6140 6947Copyright (C) 2003 Free Software Foundation, Inc.
6a161fa9 6948This config.status script is free software; the Free Software Foundation
6949gives unlimited permission to copy, distribute and modify it."
6950srcdir=$srcdir
6951INSTALL="$INSTALL"
6952_ACEOF
6953
6954cat >>$CONFIG_STATUS <<\_ACEOF
6955# If no file are specified by the user, then we need to provide default
6956# value. By we need to know if files were specified by the user.
6957ac_need_defaults=:
6958while test $# != 0
6959do
6960 case $1 in
6961 --*=*)
6962 ac_option=`expr "x$1" : 'x\([^=]*\)='`
6963 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
98d15063 6964 ac_shift=:
6965 ;;
6966 -*)
6967 ac_option=$1
6968 ac_optarg=$2
6969 ac_shift=shift
6a161fa9 6970 ;;
6a161fa9 6971 *) # This is not an option, so the user has probably given explicit
6972 # arguments.
98d15063 6973 ac_option=$1
6a161fa9 6974 ac_need_defaults=false;;
6975 esac
6976
98d15063 6977 case $ac_option in
6a161fa9 6978 # Handling of the options.
6979_ACEOF
6a161fa9 6980cat >>$CONFIG_STATUS <<\_ACEOF
98d15063 6981 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
6982 ac_cs_recheck=: ;;
6a161fa9 6983 --version | --vers* | -V )
6984 echo "$ac_cs_version"; exit 0 ;;
6985 --he | --h)
6986 # Conflict between --help and --header
6987 { { echo "$as_me:$LINENO: error: ambiguous option: $1
6988Try \`$0 --help' for more information." >&5
6989echo "$as_me: error: ambiguous option: $1
6990Try \`$0 --help' for more information." >&2;}
6991 { (exit 1); exit 1; }; };;
6992 --help | --hel | -h )
6993 echo "$ac_cs_usage"; exit 0 ;;
6994 --debug | --d* | -d )
6995 debug=: ;;
6996 --file | --fil | --fi | --f )
98d15063 6997 $ac_shift
6998 CONFIG_FILES="$CONFIG_FILES $ac_optarg"
6a161fa9 6999 ac_need_defaults=false;;
7000 --header | --heade | --head | --hea )
98d15063 7001 $ac_shift
7002 CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
6a161fa9 7003 ac_need_defaults=false;;
98d15063 7004 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
7005 | -silent | --silent | --silen | --sile | --sil | --si | --s)
7006 ac_cs_silent=: ;;
6a161fa9 7007
7008 # This is an error.
7009 -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
7010Try \`$0 --help' for more information." >&5
7011echo "$as_me: error: unrecognized option: $1
7012Try \`$0 --help' for more information." >&2;}
7013 { (exit 1); exit 1; }; } ;;
7014
7015 *) ac_config_targets="$ac_config_targets $1" ;;
7016
7017 esac
7018 shift
7019done
7020
98d15063 7021ac_configure_extra_args=
7022
7023if $ac_cs_silent; then
7024 exec 6>/dev/null
7025 ac_configure_extra_args="$ac_configure_extra_args --silent"
7026fi
7027
7028_ACEOF
7029cat >>$CONFIG_STATUS <<_ACEOF
7030if \$ac_cs_recheck; then
7031 echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
7032 exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
7033fi
7034
6a161fa9 7035_ACEOF
7036
7037
7038
7039
7040
7041cat >>$CONFIG_STATUS <<\_ACEOF
7042for ac_config_target in $ac_config_targets
7043do
7044 case "$ac_config_target" in
7045 # Handling of arguments.
7046 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
7047 "stamp-h" ) CONFIG_FILES="$CONFIG_FILES stamp-h" ;;
4b13b216 7048 "include/grub/cpu" ) CONFIG_LINKS="$CONFIG_LINKS include/grub/cpu:include/grub/$host_cpu" ;;
7049 "include/grub/machine" ) CONFIG_LINKS="$CONFIG_LINKS include/grub/machine:include/grub/$host_cpu/$host_vendor" ;;
6a161fa9 7050 "config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
7051 *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
7052echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
7053 { (exit 1); exit 1; }; };;
7054 esac
7055done
7056
7057# If the user did not use the arguments to specify the items to instantiate,
7058# then the envvar interface is used. Set only those that are not.
7059# We use the long form for the default assignment because of an extremely
7060# bizarre bug on SunOS 4.1.3.
7061if $ac_need_defaults; then
7062 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
7063 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
7064 test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
7065fi
7066
98d15063 7067# Have a temporary directory for convenience. Make it in the build tree
7068# simply because there is no reason to put it here, and in addition,
7069# creating and moving files from /tmp can sometimes cause problems.
6a161fa9 7070# Create a temporary directory, and hook for its removal unless debugging.
7071$debug ||
7072{
7073 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
7074 trap '{ (exit 1); exit 1; }' 1 2 13 15
7075}
7076
7077# Create a (secure) tmp directory for tmp files.
98d15063 7078
6a161fa9 7079{
98d15063 7080 tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
6a161fa9 7081 test -n "$tmp" && test -d "$tmp"
7082} ||
7083{
98d15063 7084 tmp=./confstat$$-$RANDOM
6a161fa9 7085 (umask 077 && mkdir $tmp)
7086} ||
7087{
98d15063 7088 echo "$me: cannot create a temporary directory in ." >&2
6a161fa9 7089 { (exit 1); exit 1; }
7090}
7091
7092_ACEOF
7093
7094cat >>$CONFIG_STATUS <<_ACEOF
7095
7096#
7097# CONFIG_FILES section.
7098#
7099
7100# No need to generate the scripts if there are no CONFIG_FILES.
7101# This happens for instance when ./config.status config.h
7102if test -n "\$CONFIG_FILES"; then
7103 # Protect against being on the right side of a sed subst in config.status.
7104 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
7105 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
7106s,@SHELL@,$SHELL,;t t
7107s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
7108s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
7109s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
7110s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
7111s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
7112s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
7113s,@exec_prefix@,$exec_prefix,;t t
7114s,@prefix@,$prefix,;t t
7115s,@program_transform_name@,$program_transform_name,;t t
7116s,@bindir@,$bindir,;t t
7117s,@sbindir@,$sbindir,;t t
7118s,@libexecdir@,$libexecdir,;t t
7119s,@datadir@,$datadir,;t t
7120s,@sysconfdir@,$sysconfdir,;t t
7121s,@sharedstatedir@,$sharedstatedir,;t t
7122s,@localstatedir@,$localstatedir,;t t
7123s,@libdir@,$libdir,;t t
7124s,@includedir@,$includedir,;t t
7125s,@oldincludedir@,$oldincludedir,;t t
7126s,@infodir@,$infodir,;t t
7127s,@mandir@,$mandir,;t t
7128s,@build_alias@,$build_alias,;t t
7129s,@host_alias@,$host_alias,;t t
7130s,@target_alias@,$target_alias,;t t
7131s,@DEFS@,$DEFS,;t t
7132s,@ECHO_C@,$ECHO_C,;t t
7133s,@ECHO_N@,$ECHO_N,;t t
7134s,@ECHO_T@,$ECHO_T,;t t
7135s,@LIBS@,$LIBS,;t t
7136s,@build@,$build,;t t
7137s,@build_cpu@,$build_cpu,;t t
7138s,@build_vendor@,$build_vendor,;t t
7139s,@build_os@,$build_os,;t t
7140s,@host@,$host,;t t
7141s,@host_cpu@,$host_cpu,;t t
7142s,@host_vendor@,$host_vendor,;t t
7143s,@host_os@,$host_os,;t t
7144s,@CC@,$CC,;t t
7145s,@CFLAGS@,$CFLAGS,;t t
7146s,@LDFLAGS@,$LDFLAGS,;t t
7147s,@CPPFLAGS@,$CPPFLAGS,;t t
7148s,@ac_ct_CC@,$ac_ct_CC,;t t
7149s,@EXEEXT@,$EXEEXT,;t t
7150s,@OBJEXT@,$OBJEXT,;t t
daac212a 7151s,@YACC@,$YACC,;t t
6a161fa9 7152s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
7153s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
7154s,@INSTALL_DATA@,$INSTALL_DATA,;t t
7155s,@SET_MAKE@,$SET_MAKE,;t t
7156s,@OBJCOPY@,$OBJCOPY,;t t
7157s,@ac_ct_OBJCOPY@,$ac_ct_OBJCOPY,;t t
7158s,@STRIP@,$STRIP,;t t
7159s,@ac_ct_STRIP@,$ac_ct_STRIP,;t t
7160s,@NM@,$NM,;t t
7161s,@ac_ct_NM@,$ac_ct_NM,;t t
9962ed99 7162s,@LD@,$LD,;t t
7163s,@ac_ct_LD@,$ac_ct_LD,;t t
6a161fa9 7164s,@RUBY@,$RUBY,;t t
7165s,@BUILD_CC@,$BUILD_CC,;t t
7166s,@CPP@,$CPP,;t t
98d15063 7167s,@EGREP@,$EGREP,;t t
4ac9bd04 7168s,@LIBLZO@,$LIBLZO,;t t
f4917dfd 7169s,@LIBCURSES@,$LIBCURSES,;t t
98d15063 7170s,@LIBOBJS@,$LIBOBJS,;t t
7171s,@LTLIBOBJS@,$LTLIBOBJS,;t t
6a161fa9 7172CEOF
7173
7174_ACEOF
7175
7176 cat >>$CONFIG_STATUS <<\_ACEOF
7177 # Split the substitutions into bite-sized pieces for seds with
7178 # small command number limits, like on Digital OSF/1 and HP-UX.
7179 ac_max_sed_lines=48
7180 ac_sed_frag=1 # Number of current file.
7181 ac_beg=1 # First line for current file.
7182 ac_end=$ac_max_sed_lines # Line after last line for current file.
7183 ac_more_lines=:
7184 ac_sed_cmds=
7185 while $ac_more_lines; do
7186 if test $ac_beg -gt 1; then
7187 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
7188 else
7189 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
7190 fi
7191 if test ! -s $tmp/subs.frag; then
7192 ac_more_lines=false
7193 else
7194 # The purpose of the label and of the branching condition is to
7195 # speed up the sed processing (if there are no `@' at all, there
7196 # is no need to browse any of the substitutions).
7197 # These are the two extra sed commands mentioned above.
7198 (echo ':t
7199 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
7200 if test -z "$ac_sed_cmds"; then
924b6140 7201 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
6a161fa9 7202 else
924b6140 7203 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
6a161fa9 7204 fi
7205 ac_sed_frag=`expr $ac_sed_frag + 1`
7206 ac_beg=$ac_end
7207 ac_end=`expr $ac_end + $ac_max_sed_lines`
7208 fi
7209 done
7210 if test -z "$ac_sed_cmds"; then
7211 ac_sed_cmds=cat
7212 fi
7213fi # test -n "$CONFIG_FILES"
7214
7215_ACEOF
7216cat >>$CONFIG_STATUS <<\_ACEOF
7217for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
7218 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
7219 case $ac_file in
7220 - | *:- | *:-:* ) # input from stdin
924b6140 7221 cat >$tmp/stdin
7222 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
7223 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
6a161fa9 7224 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
924b6140 7225 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
6a161fa9 7226 * ) ac_file_in=$ac_file.in ;;
7227 esac
7228
7229 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
7230 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
7231$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
924b6140 7232 X"$ac_file" : 'X\(//\)[^/]' \| \
7233 X"$ac_file" : 'X\(//\)$' \| \
7234 X"$ac_file" : 'X\(/\)' \| \
7235 . : '\(.\)' 2>/dev/null ||
6a161fa9 7236echo X"$ac_file" |
7237 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
7238 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
7239 /^X\(\/\/\)$/{ s//\1/; q; }
7240 /^X\(\/\).*/{ s//\1/; q; }
7241 s/.*/./; q'`
98d15063 7242 { if $as_mkdir_p; then
7243 mkdir -p "$ac_dir"
7244 else
7245 as_dir="$ac_dir"
7246 as_dirs=
7247 while test ! -d "$as_dir"; do
7248 as_dirs="$as_dir $as_dirs"
7249 as_dir=`(dirname "$as_dir") 2>/dev/null ||
7250$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
924b6140 7251 X"$as_dir" : 'X\(//\)[^/]' \| \
7252 X"$as_dir" : 'X\(//\)$' \| \
7253 X"$as_dir" : 'X\(/\)' \| \
7254 . : '\(.\)' 2>/dev/null ||
98d15063 7255echo X"$as_dir" |
7256 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
7257 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
7258 /^X\(\/\/\)$/{ s//\1/; q; }
7259 /^X\(\/\).*/{ s//\1/; q; }
7260 s/.*/./; q'`
7261 done
7262 test ! -n "$as_dirs" || mkdir $as_dirs
7263 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
7264echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
7265 { (exit 1); exit 1; }; }; }
6a161fa9 7266
7267 ac_builddir=.
7268
7269if test "$ac_dir" != .; then
7270 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
7271 # A "../" for each directory in $ac_dir_suffix.
7272 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
7273else
7274 ac_dir_suffix= ac_top_builddir=
7275fi
7276
7277case $srcdir in
7278 .) # No --srcdir option. We are building in place.
7279 ac_srcdir=.
7280 if test -z "$ac_top_builddir"; then
7281 ac_top_srcdir=.
7282 else
7283 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
7284 fi ;;
7285 [\\/]* | ?:[\\/]* ) # Absolute path.
7286 ac_srcdir=$srcdir$ac_dir_suffix;
7287 ac_top_srcdir=$srcdir ;;
7288 *) # Relative path.
7289 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
7290 ac_top_srcdir=$ac_top_builddir$srcdir ;;
7291esac
924b6140 7292
7293# Do not use `cd foo && pwd` to compute absolute paths, because
7294# the directories may not exist.
7295case `pwd` in
7296.) ac_abs_builddir="$ac_dir";;
7297*)
7298 case "$ac_dir" in
7299 .) ac_abs_builddir=`pwd`;;
7300 [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
7301 *) ac_abs_builddir=`pwd`/"$ac_dir";;
7302 esac;;
7303esac
7304case $ac_abs_builddir in
7305.) ac_abs_top_builddir=${ac_top_builddir}.;;
7306*)
7307 case ${ac_top_builddir}. in
7308 .) ac_abs_top_builddir=$ac_abs_builddir;;
7309 [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
7310 *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
7311 esac;;
7312esac
7313case $ac_abs_builddir in
7314.) ac_abs_srcdir=$ac_srcdir;;
7315*)
7316 case $ac_srcdir in
7317 .) ac_abs_srcdir=$ac_abs_builddir;;
7318 [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
7319 *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
7320 esac;;
7321esac
7322case $ac_abs_builddir in
7323.) ac_abs_top_srcdir=$ac_top_srcdir;;
7324*)
7325 case $ac_top_srcdir in
7326 .) ac_abs_top_srcdir=$ac_abs_builddir;;
7327 [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
7328 *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
7329 esac;;
7330esac
6a161fa9 7331
7332
7333 case $INSTALL in
7334 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
7335 *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
7336 esac
7337
6a161fa9 7338 # Let's still pretend it is `configure' which instantiates (i.e., don't
7339 # use $as_me), people would be surprised to read:
7340 # /* config.h. Generated by config.status. */
7341 if test x"$ac_file" = x-; then
7342 configure_input=
7343 else
7344 configure_input="$ac_file. "
7345 fi
7346 configure_input=$configure_input"Generated from `echo $ac_file_in |
924b6140 7347 sed 's,.*/,,'` by configure."
6a161fa9 7348
7349 # First look for the input files in the build tree, otherwise in the
7350 # src tree.
7351 ac_file_inputs=`IFS=:
7352 for f in $ac_file_in; do
7353 case $f in
7354 -) echo $tmp/stdin ;;
7355 [\\/$]*)
924b6140 7356 # Absolute (can't be DOS-style, as IFS=:)
7357 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
6a161fa9 7358echo "$as_me: error: cannot find input file: $f" >&2;}
7359 { (exit 1); exit 1; }; }
924b6140 7360 echo "$f";;
6a161fa9 7361 *) # Relative
924b6140 7362 if test -f "$f"; then
7363 # Build tree
7364 echo "$f"
7365 elif test -f "$srcdir/$f"; then
7366 # Source tree
7367 echo "$srcdir/$f"
7368 else
7369 # /dev/null tree
7370 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
6a161fa9 7371echo "$as_me: error: cannot find input file: $f" >&2;}
7372 { (exit 1); exit 1; }; }
924b6140 7373 fi;;
6a161fa9 7374 esac
7375 done` || { (exit 1); exit 1; }
144f1f98 7376
7377 if test x"$ac_file" != x-; then
7378 { echo "$as_me:$LINENO: creating $ac_file" >&5
7379echo "$as_me: creating $ac_file" >&6;}
7380 rm -f "$ac_file"
7381 fi
6a161fa9 7382_ACEOF
7383cat >>$CONFIG_STATUS <<_ACEOF
7384 sed "$ac_vpsub
7385$extrasub
7386_ACEOF
7387cat >>$CONFIG_STATUS <<\_ACEOF
7388:t
7389/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
7390s,@configure_input@,$configure_input,;t t
7391s,@srcdir@,$ac_srcdir,;t t
7392s,@abs_srcdir@,$ac_abs_srcdir,;t t
7393s,@top_srcdir@,$ac_top_srcdir,;t t
7394s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
7395s,@builddir@,$ac_builddir,;t t
7396s,@abs_builddir@,$ac_abs_builddir,;t t
7397s,@top_builddir@,$ac_top_builddir,;t t
7398s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
7399s,@INSTALL@,$ac_INSTALL,;t t
7400" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
7401 rm -f $tmp/stdin
7402 if test x"$ac_file" != x-; then
7403 mv $tmp/out $ac_file
7404 else
7405 cat $tmp/out
7406 rm -f $tmp/out
7407 fi
7408
7409 # Run the commands associated with the file.
7410 case $ac_file in
7411 stamp-h ) echo timestamp > stamp-h ;;
7412 esac
7413done
7414_ACEOF
7415cat >>$CONFIG_STATUS <<\_ACEOF
7416
7417#
7418# CONFIG_HEADER section.
7419#
7420
7421# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
7422# NAME is the cpp macro being defined and VALUE is the value it is being given.
7423#
7424# ac_d sets the value in "#define NAME VALUE" lines.
924b6140 7425ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
7426ac_dB='[ ].*$,\1#\2'
6a161fa9 7427ac_dC=' '
7428ac_dD=',;t'
7429# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
924b6140 7430ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
6a161fa9 7431ac_uB='$,\1#\2define\3'
7432ac_uC=' '
7433ac_uD=',;t'
7434
7435for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
7436 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
7437 case $ac_file in
7438 - | *:- | *:-:* ) # input from stdin
924b6140 7439 cat >$tmp/stdin
7440 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
7441 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
6a161fa9 7442 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
924b6140 7443 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
6a161fa9 7444 * ) ac_file_in=$ac_file.in ;;
7445 esac
7446
7447 test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
7448echo "$as_me: creating $ac_file" >&6;}
7449
7450 # First look for the input files in the build tree, otherwise in the
7451 # src tree.
7452 ac_file_inputs=`IFS=:
7453 for f in $ac_file_in; do
7454 case $f in
7455 -) echo $tmp/stdin ;;
7456 [\\/$]*)
924b6140 7457 # Absolute (can't be DOS-style, as IFS=:)
7458 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
6a161fa9 7459echo "$as_me: error: cannot find input file: $f" >&2;}
7460 { (exit 1); exit 1; }; }
924b6140 7461 # Do quote $f, to prevent DOS paths from being IFS'd.
7462 echo "$f";;
6a161fa9 7463 *) # Relative
924b6140 7464 if test -f "$f"; then
7465 # Build tree
7466 echo "$f"
7467 elif test -f "$srcdir/$f"; then
7468 # Source tree
7469 echo "$srcdir/$f"
7470 else
7471 # /dev/null tree
7472 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
6a161fa9 7473echo "$as_me: error: cannot find input file: $f" >&2;}
7474 { (exit 1); exit 1; }; }
924b6140 7475 fi;;
6a161fa9 7476 esac
7477 done` || { (exit 1); exit 1; }
7478 # Remove the trailing spaces.
924b6140 7479 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
6a161fa9 7480
7481_ACEOF
7482
7483# Transform confdefs.h into two sed scripts, `conftest.defines' and
7484# `conftest.undefs', that substitutes the proper values into
7485# config.h.in to produce config.h. The first handles `#define'
7486# templates, and the second `#undef' templates.
7487# And first: Protect against being on the right side of a sed subst in
7488# config.status. Protect against being in an unquoted here document
7489# in config.status.
7490rm -f conftest.defines conftest.undefs
7491# Using a here document instead of a string reduces the quoting nightmare.
7492# Putting comments in sed scripts is not portable.
7493#
7494# `end' is used to avoid that the second main sed command (meant for
7495# 0-ary CPP macros) applies to n-ary macro definitions.
7496# See the Autoconf documentation for `clear'.
7497cat >confdef2sed.sed <<\_ACEOF
7498s/[\\&,]/\\&/g
7499s,[\\$`],\\&,g
7500t clear
7501: clear
924b6140 7502s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*\)\(([^)]*)\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
6a161fa9 7503t end
924b6140 7504s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
6a161fa9 7505: end
7506_ACEOF
7507# If some macros were called several times there might be several times
7508# the same #defines, which is useless. Nevertheless, we may not want to
7509# sort them, since we want the *last* AC-DEFINE to be honored.
7510uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
7511sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
7512rm -f confdef2sed.sed
7513
7514# This sed command replaces #undef with comments. This is necessary, for
7515# example, in the case of _POSIX_SOURCE, which is predefined and required
7516# on some systems where configure will not decide to define it.
7517cat >>conftest.undefs <<\_ACEOF
924b6140 7518s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
6a161fa9 7519_ACEOF
7520
7521# Break up conftest.defines because some shells have a limit on the size
7522# of here documents, and old seds have small limits too (100 cmds).
7523echo ' # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
924b6140 7524echo ' if grep "^[ ]*#[ ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
6a161fa9 7525echo ' # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
7526echo ' :' >>$CONFIG_STATUS
7527rm -f conftest.tail
7528while grep . conftest.defines >/dev/null
7529do
7530 # Write a limited-size here document to $tmp/defines.sed.
7531 echo ' cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
7532 # Speed up: don't consider the non `#define' lines.
924b6140 7533 echo '/^[ ]*#[ ]*define/!b' >>$CONFIG_STATUS
6a161fa9 7534 # Work around the forget-to-reset-the-flag bug.
7535 echo 't clr' >>$CONFIG_STATUS
7536 echo ': clr' >>$CONFIG_STATUS
7537 sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
7538 echo 'CEOF
7539 sed -f $tmp/defines.sed $tmp/in >$tmp/out
7540 rm -f $tmp/in
7541 mv $tmp/out $tmp/in
7542' >>$CONFIG_STATUS
7543 sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
7544 rm -f conftest.defines
7545 mv conftest.tail conftest.defines
7546done
7547rm -f conftest.defines
98d15063 7548echo ' fi # grep' >>$CONFIG_STATUS
6a161fa9 7549echo >>$CONFIG_STATUS
7550
7551# Break up conftest.undefs because some shells have a limit on the size
7552# of here documents, and old seds have small limits too (100 cmds).
7553echo ' # Handle all the #undef templates' >>$CONFIG_STATUS
7554rm -f conftest.tail
7555while grep . conftest.undefs >/dev/null
7556do
7557 # Write a limited-size here document to $tmp/undefs.sed.
7558 echo ' cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
7559 # Speed up: don't consider the non `#undef'
924b6140 7560 echo '/^[ ]*#[ ]*undef/!b' >>$CONFIG_STATUS
6a161fa9 7561 # Work around the forget-to-reset-the-flag bug.
7562 echo 't clr' >>$CONFIG_STATUS
7563 echo ': clr' >>$CONFIG_STATUS
7564 sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
7565 echo 'CEOF
7566 sed -f $tmp/undefs.sed $tmp/in >$tmp/out
7567 rm -f $tmp/in
7568 mv $tmp/out $tmp/in
7569' >>$CONFIG_STATUS
7570 sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
7571 rm -f conftest.undefs
7572 mv conftest.tail conftest.undefs
7573done
7574rm -f conftest.undefs
7575
7576cat >>$CONFIG_STATUS <<\_ACEOF
7577 # Let's still pretend it is `configure' which instantiates (i.e., don't
7578 # use $as_me), people would be surprised to read:
7579 # /* config.h. Generated by config.status. */
7580 if test x"$ac_file" = x-; then
7581 echo "/* Generated by configure. */" >$tmp/config.h
7582 else
7583 echo "/* $ac_file. Generated by configure. */" >$tmp/config.h
7584 fi
7585 cat $tmp/in >>$tmp/config.h
7586 rm -f $tmp/in
7587 if test x"$ac_file" != x-; then
98d15063 7588 if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
6a161fa9 7589 { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
7590echo "$as_me: $ac_file is unchanged" >&6;}
7591 else
7592 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
7593$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
924b6140 7594 X"$ac_file" : 'X\(//\)[^/]' \| \
7595 X"$ac_file" : 'X\(//\)$' \| \
7596 X"$ac_file" : 'X\(/\)' \| \
7597 . : '\(.\)' 2>/dev/null ||
6a161fa9 7598echo X"$ac_file" |
7599 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
7600 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
7601 /^X\(\/\/\)$/{ s//\1/; q; }
7602 /^X\(\/\).*/{ s//\1/; q; }
7603 s/.*/./; q'`
98d15063 7604 { if $as_mkdir_p; then
7605 mkdir -p "$ac_dir"
7606 else
7607 as_dir="$ac_dir"
7608 as_dirs=
7609 while test ! -d "$as_dir"; do
7610 as_dirs="$as_dir $as_dirs"
7611 as_dir=`(dirname "$as_dir") 2>/dev/null ||
7612$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
924b6140 7613 X"$as_dir" : 'X\(//\)[^/]' \| \
7614 X"$as_dir" : 'X\(//\)$' \| \
7615 X"$as_dir" : 'X\(/\)' \| \
7616 . : '\(.\)' 2>/dev/null ||
98d15063 7617echo X"$as_dir" |
7618 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
7619 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
7620 /^X\(\/\/\)$/{ s//\1/; q; }
7621 /^X\(\/\).*/{ s//\1/; q; }
7622 s/.*/./; q'`
7623 done
7624 test ! -n "$as_dirs" || mkdir $as_dirs
7625 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
7626echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
7627 { (exit 1); exit 1; }; }; }
6a161fa9 7628
7629 rm -f $ac_file
7630 mv $tmp/config.h $ac_file
7631 fi
7632 else
7633 cat $tmp/config.h
7634 rm -f $tmp/config.h
7635 fi
7636done
7637_ACEOF
7638cat >>$CONFIG_STATUS <<\_ACEOF
7639
7640#
7641# CONFIG_LINKS section.
7642#
7643
7644for ac_file in : $CONFIG_LINKS; do test "x$ac_file" = x: && continue
7645 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
7646 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
7647
7648 { echo "$as_me:$LINENO: linking $srcdir/$ac_source to $ac_dest" >&5
7649echo "$as_me: linking $srcdir/$ac_source to $ac_dest" >&6;}
7650
7651 if test ! -r $srcdir/$ac_source; then
7652 { { echo "$as_me:$LINENO: error: $srcdir/$ac_source: file not found" >&5
7653echo "$as_me: error: $srcdir/$ac_source: file not found" >&2;}
7654 { (exit 1); exit 1; }; }
7655 fi
7656 rm -f $ac_dest
7657
7658 # Make relative symlinks.
7659 ac_dest_dir=`(dirname "$ac_dest") 2>/dev/null ||
7660$as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
924b6140 7661 X"$ac_dest" : 'X\(//\)[^/]' \| \
7662 X"$ac_dest" : 'X\(//\)$' \| \
7663 X"$ac_dest" : 'X\(/\)' \| \
7664 . : '\(.\)' 2>/dev/null ||
6a161fa9 7665echo X"$ac_dest" |
7666 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
7667 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
7668 /^X\(\/\/\)$/{ s//\1/; q; }
7669 /^X\(\/\).*/{ s//\1/; q; }
7670 s/.*/./; q'`
98d15063 7671 { if $as_mkdir_p; then
7672 mkdir -p "$ac_dest_dir"
7673 else
7674 as_dir="$ac_dest_dir"
7675 as_dirs=
7676 while test ! -d "$as_dir"; do
7677 as_dirs="$as_dir $as_dirs"
7678 as_dir=`(dirname "$as_dir") 2>/dev/null ||
7679$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
924b6140 7680 X"$as_dir" : 'X\(//\)[^/]' \| \
7681 X"$as_dir" : 'X\(//\)$' \| \
7682 X"$as_dir" : 'X\(/\)' \| \
7683 . : '\(.\)' 2>/dev/null ||
98d15063 7684echo X"$as_dir" |
7685 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
7686 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
7687 /^X\(\/\/\)$/{ s//\1/; q; }
7688 /^X\(\/\).*/{ s//\1/; q; }
7689 s/.*/./; q'`
7690 done
7691 test ! -n "$as_dirs" || mkdir $as_dirs
7692 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dest_dir\"" >&5
7693echo "$as_me: error: cannot create directory \"$ac_dest_dir\"" >&2;}
7694 { (exit 1); exit 1; }; }; }
6a161fa9 7695
7696 ac_builddir=.
7697
7698if test "$ac_dest_dir" != .; then
7699 ac_dir_suffix=/`echo "$ac_dest_dir" | sed 's,^\.[\\/],,'`
7700 # A "../" for each directory in $ac_dir_suffix.
7701 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
7702else
7703 ac_dir_suffix= ac_top_builddir=
7704fi
7705
7706case $srcdir in
7707 .) # No --srcdir option. We are building in place.
7708 ac_srcdir=.
7709 if test -z "$ac_top_builddir"; then
7710 ac_top_srcdir=.
7711 else
7712 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
7713 fi ;;
7714 [\\/]* | ?:[\\/]* ) # Absolute path.
7715 ac_srcdir=$srcdir$ac_dir_suffix;
7716 ac_top_srcdir=$srcdir ;;
7717 *) # Relative path.
7718 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
7719 ac_top_srcdir=$ac_top_builddir$srcdir ;;
7720esac
924b6140 7721
7722# Do not use `cd foo && pwd` to compute absolute paths, because
7723# the directories may not exist.
7724case `pwd` in
7725.) ac_abs_builddir="$ac_dest_dir";;
7726*)
7727 case "$ac_dest_dir" in
7728 .) ac_abs_builddir=`pwd`;;
7729 [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dest_dir";;
7730 *) ac_abs_builddir=`pwd`/"$ac_dest_dir";;
7731 esac;;
7732esac
7733case $ac_abs_builddir in
7734.) ac_abs_top_builddir=${ac_top_builddir}.;;
7735*)
7736 case ${ac_top_builddir}. in
7737 .) ac_abs_top_builddir=$ac_abs_builddir;;
7738 [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
7739 *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
7740 esac;;
7741esac
7742case $ac_abs_builddir in
7743.) ac_abs_srcdir=$ac_srcdir;;
7744*)
7745 case $ac_srcdir in
7746 .) ac_abs_srcdir=$ac_abs_builddir;;
7747 [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
7748 *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
7749 esac;;
7750esac
7751case $ac_abs_builddir in
7752.) ac_abs_top_srcdir=$ac_top_srcdir;;
7753*)
7754 case $ac_top_srcdir in
7755 .) ac_abs_top_srcdir=$ac_abs_builddir;;
7756 [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
7757 *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
7758 esac;;
7759esac
6a161fa9 7760
7761
7762 case $srcdir in
7763 [\\/$]* | ?:[\\/]* ) ac_rel_source=$srcdir/$ac_source ;;
7764 *) ac_rel_source=$ac_top_builddir$srcdir/$ac_source ;;
7765 esac
7766
98d15063 7767 # Try a symlink, then a hard link, then a copy.
6a161fa9 7768 ln -s $ac_rel_source $ac_dest 2>/dev/null ||
98d15063 7769 ln $srcdir/$ac_source $ac_dest 2>/dev/null ||
7770 cp -p $srcdir/$ac_source $ac_dest ||
7771 { { echo "$as_me:$LINENO: error: cannot link or copy $srcdir/$ac_source to $ac_dest" >&5
7772echo "$as_me: error: cannot link or copy $srcdir/$ac_source to $ac_dest" >&2;}
6a161fa9 7773 { (exit 1); exit 1; }; }
7774done
7775_ACEOF
7776
7777cat >>$CONFIG_STATUS <<\_ACEOF
7778
7779{ (exit 0); exit 0; }
7780_ACEOF
7781chmod +x $CONFIG_STATUS
7782ac_clean_files=$ac_clean_files_save
7783
7784
7785# configure is writing to config.log, and then calls config.status.
7786# config.status does its own redirection, appending to config.log.
7787# Unfortunately, on DOS this fails, as config.log is still kept open
7788# by configure, so config.status won't be able to write to it; its
7789# output is simply discarded. So we exec the FD to /dev/null,
7790# effectively closing config.log, so it can be properly (re)opened and
7791# appended to by config.status. When coming back to configure, we
7792# need to make the FD available again.
7793if test "$no_create" != yes; then
7794 ac_cs_success=:
98d15063 7795 ac_config_status_args=
7796 test "$silent" = yes &&
7797 ac_config_status_args="$ac_config_status_args --quiet"
6a161fa9 7798 exec 5>/dev/null
98d15063 7799 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
6a161fa9 7800 exec 5>>config.log
7801 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
7802 # would make configure fail if this is the last instruction.
7803 $ac_cs_success || { (exit 1); exit 1; }
7804fi
7805