]> git.ipfire.org Git - thirdparty/gcc.git/blame - libiberty/configure
* c-cppbuiltin.c (c_cpp_builtins): Define __cpp_structured_bindings.
[thirdparty/gcc.git] / libiberty / configure
CommitLineData
f0a93313 1#! /bin/sh
f0a93313 2# Guess values for system-dependent variables and create Makefiles.
cd9a469c 3# Generated by GNU Autoconf 2.64.
4#
5# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
6# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software
7# Foundation, Inc.
f0a93313 8#
9# This configure script is free software; the Free Software Foundation
10# gives unlimited permission to copy, distribute and modify it.
cd9a469c 11## -------------------- ##
12## M4sh Initialization. ##
13## -------------------- ##
a6089b1e 14
cd9a469c 15# Be more Bourne compatible
16DUALCASE=1; export DUALCASE # for MKS sh
17if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
a6089b1e 18 emulate sh
19 NULLCMD=:
cd9a469c 20 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
a6089b1e 21 # is contrary to our usage. Disable this feature.
22 alias -g '${1+"$@"}'='"$@"'
cd9a469c 23 setopt NO_GLOB_SUBST
24else
25 case `(set -o) 2>/dev/null` in #(
26 *posix*) :
27 set -o posix ;; #(
28 *) :
29 ;;
30esac
a6089b1e 31fi
32
cd9a469c 33
34as_nl='
35'
36export as_nl
37# Printing a long string crashes Solaris 7 /usr/bin/printf.
38as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
39as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
40as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
41# Prefer a ksh shell builtin over an external printf program on Solaris,
42# but without wasting forks for bash or zsh.
43if test -z "$BASH_VERSION$ZSH_VERSION" \
44 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
45 as_echo='print -r --'
46 as_echo_n='print -rn --'
47elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
48 as_echo='printf %s\n'
49 as_echo_n='printf %s'
50else
51 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
52 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
53 as_echo_n='/usr/ucb/echo -n'
54 else
55 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
56 as_echo_n_body='eval
57 arg=$1;
58 case $arg in #(
59 *"$as_nl"*)
60 expr "X$arg" : "X\\(.*\\)$as_nl";
61 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
62 esac;
63 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
64 '
65 export as_echo_n_body
66 as_echo_n='sh -c $as_echo_n_body as_echo'
67 fi
68 export as_echo_body
69 as_echo='sh -c $as_echo_body as_echo'
70fi
71
72# The user is always right.
73if test "${PATH_SEPARATOR+set}" != set; then
74 PATH_SEPARATOR=:
75 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
76 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
77 PATH_SEPARATOR=';'
78 }
a6089b1e 79fi
80
81
cd9a469c 82# IFS
83# We need space, tab and new line, in precisely that order. Quoting is
84# there to prevent editors from complaining about space-tab.
85# (If _AS_PATH_WALK were called with IFS unset, it would disable word
86# splitting by setting IFS to empty value.)
87IFS=" "" $as_nl"
88
89# Find who we are. Look in the path if we contain no directory separator.
90case $0 in #((
91 *[\\/]* ) as_myself=$0 ;;
92 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
93for as_dir in $PATH
94do
95 IFS=$as_save_IFS
96 test -z "$as_dir" && as_dir=.
97 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
98 done
99IFS=$as_save_IFS
100
101 ;;
102esac
103# We did not find ourselves, most probably we were run as `sh COMMAND'
104# in which case we are not to be found in the path.
105if test "x$as_myself" = x; then
106 as_myself=$0
107fi
108if test ! -f "$as_myself"; then
109 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
110 exit 1
111fi
112
113# Unset variables that we do not need and which cause bugs (e.g. in
114# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
115# suppresses any "Segmentation fault" message there. '((' could
116# trigger a bug in pdksh 5.2.14.
117for as_var in BASH_ENV ENV MAIL MAILPATH
118do eval test x\${$as_var+set} = xset \
119 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
120done
a6089b1e 121PS1='$ '
122PS2='> '
123PS4='+ '
124
125# NLS nuisances.
cd9a469c 126LC_ALL=C
127export LC_ALL
128LANGUAGE=C
129export LANGUAGE
130
131# CDPATH.
132(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
133
134if test "x$CONFIG_SHELL" = x; then
135 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
136 emulate sh
137 NULLCMD=:
138 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
139 # is contrary to our usage. Disable this feature.
140 alias -g '\${1+\"\$@\"}'='\"\$@\"'
141 setopt NO_GLOB_SUBST
142else
143 case \`(set -o) 2>/dev/null\` in #(
144 *posix*) :
145 set -o posix ;; #(
146 *) :
147 ;;
148esac
149fi
150"
151 as_required="as_fn_return () { (exit \$1); }
152as_fn_success () { as_fn_return 0; }
153as_fn_failure () { as_fn_return 1; }
154as_fn_ret_success () { return 0; }
155as_fn_ret_failure () { return 1; }
156
157exitcode=0
158as_fn_success || { exitcode=1; echo as_fn_success failed.; }
159as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
160as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
161as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
162if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
163
164else
165 exitcode=1; echo positional parameters were not saved.
166fi
167test x\$exitcode = x0 || exit 1"
168 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
169 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
170 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
171 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
172test \$(( 1 + 1 )) = 2 || exit 1"
173 if (eval "$as_required") 2>/dev/null; then :
174 as_have_required=yes
175else
176 as_have_required=no
177fi
178 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
179
180else
181 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
182as_found=false
183for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
a6089b1e 184do
cd9a469c 185 IFS=$as_save_IFS
186 test -z "$as_dir" && as_dir=.
187 as_found=:
188 case $as_dir in #(
189 /*)
190 for as_base in sh bash ksh sh5; do
191 # Try only shells that exist, to save several forks.
192 as_shell=$as_dir/$as_base
193 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
194 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
195 CONFIG_SHELL=$as_shell as_have_required=yes
196 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
197 break 2
198fi
199fi
200 done;;
201 esac
202 as_found=false
203done
204$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
205 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
206 CONFIG_SHELL=$SHELL as_have_required=yes
207fi; }
208IFS=$as_save_IFS
209
210
211 if test "x$CONFIG_SHELL" != x; then :
212 # We cannot yet assume a decent shell, so we have to provide a
213 # neutralization value for shells without unset; and this also
214 # works around shells that cannot unset nonexistent variables.
215 BASH_ENV=/dev/null
216 ENV=/dev/null
217 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
218 export CONFIG_SHELL
219 exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
220fi
221
222 if test x$as_have_required = xno; then :
223 $as_echo "$0: This script requires a shell more modern than all"
224 $as_echo "$0: the shells that I found on your system."
225 if test x${ZSH_VERSION+set} = xset ; then
226 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
227 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
a6089b1e 228 else
cd9a469c 229 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
230$0: including any error possibly output before this
231$0: message. Then install a modern shell, or manually run
232$0: the script under such a shell if you do have one."
a6089b1e 233 fi
cd9a469c 234 exit 1
235fi
236fi
237fi
238SHELL=${CONFIG_SHELL-/bin/sh}
239export SHELL
240# Unset more variables known to interfere with behavior of common tools.
241CLICOLOR_FORCE= GREP_OPTIONS=
242unset CLICOLOR_FORCE GREP_OPTIONS
243
244## --------------------- ##
245## M4sh Shell Functions. ##
246## --------------------- ##
247# as_fn_unset VAR
248# ---------------
249# Portably unset VAR.
250as_fn_unset ()
251{
252 { eval $1=; unset $1;}
253}
254as_unset=as_fn_unset
255
256# as_fn_set_status STATUS
257# -----------------------
258# Set $? to STATUS, without forking.
259as_fn_set_status ()
260{
261 return $1
262} # as_fn_set_status
263
264# as_fn_exit STATUS
265# -----------------
266# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
267as_fn_exit ()
268{
269 set +e
270 as_fn_set_status $1
271 exit $1
272} # as_fn_exit
273
274# as_fn_mkdir_p
275# -------------
276# Create "$as_dir" as a directory, including parents if necessary.
277as_fn_mkdir_p ()
278{
279
280 case $as_dir in #(
281 -*) as_dir=./$as_dir;;
282 esac
283 test -d "$as_dir" || eval $as_mkdir_p || {
284 as_dirs=
285 while :; do
286 case $as_dir in #(
287 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
288 *) as_qdir=$as_dir;;
289 esac
290 as_dirs="'$as_qdir' $as_dirs"
291 as_dir=`$as_dirname -- "$as_dir" ||
292$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
293 X"$as_dir" : 'X\(//\)[^/]' \| \
294 X"$as_dir" : 'X\(//\)$' \| \
295 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
296$as_echo X"$as_dir" |
297 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
298 s//\1/
299 q
300 }
301 /^X\(\/\/\)[^/].*/{
302 s//\1/
303 q
304 }
305 /^X\(\/\/\)$/{
306 s//\1/
307 q
308 }
309 /^X\(\/\).*/{
310 s//\1/
311 q
312 }
313 s/.*/./; q'`
314 test -d "$as_dir" && break
315 done
316 test -z "$as_dirs" || eval "mkdir $as_dirs"
317 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
318
319
320} # as_fn_mkdir_p
321# as_fn_append VAR VALUE
322# ----------------------
323# Append the text in VALUE to the end of the definition contained in VAR. Take
324# advantage of any shell optimizations that allow amortized linear growth over
325# repeated appends, instead of the typical quadratic growth present in naive
326# implementations.
327if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
328 eval 'as_fn_append ()
329 {
330 eval $1+=\$2
331 }'
332else
333 as_fn_append ()
334 {
335 eval $1=\$$1\$2
336 }
337fi # as_fn_append
338
339# as_fn_arith ARG...
340# ------------------
341# Perform arithmetic evaluation on the ARGs, and store the result in the
342# global $as_val. Take advantage of shells that can avoid forks. The arguments
343# must be portable across $(()) and expr.
344if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
345 eval 'as_fn_arith ()
346 {
347 as_val=$(( $* ))
348 }'
349else
350 as_fn_arith ()
351 {
352 as_val=`expr "$@" || test $? -eq 1`
353 }
354fi # as_fn_arith
355
356
357# as_fn_error ERROR [LINENO LOG_FD]
358# ---------------------------------
359# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
360# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
361# script with status $?, using 1 if that was 0.
362as_fn_error ()
363{
364 as_status=$?; test $as_status -eq 0 && as_status=1
365 if test "$3"; then
366 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
367 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
368 fi
369 $as_echo "$as_me: error: $1" >&2
370 as_fn_exit $as_status
371} # as_fn_error
a6089b1e 372
cd9a469c 373if expr a : '\(a\)' >/dev/null 2>&1 &&
374 test "X`expr 00001 : '.*\(...\)'`" = X001; then
a6089b1e 375 as_expr=expr
376else
377 as_expr=false
378fi
379
cd9a469c 380if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
a6089b1e 381 as_basename=basename
382else
383 as_basename=false
384fi
385
cd9a469c 386if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
387 as_dirname=dirname
388else
389 as_dirname=false
390fi
a6089b1e 391
cd9a469c 392as_me=`$as_basename -- "$0" ||
a6089b1e 393$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
394 X"$0" : 'X\(//\)$' \| \
cd9a469c 395 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
396$as_echo X/"$0" |
397 sed '/^.*\/\([^/][^/]*\)\/*$/{
398 s//\1/
399 q
400 }
401 /^X\/\(\/\/\)$/{
402 s//\1/
403 q
404 }
405 /^X\/\(\/\).*/{
406 s//\1/
407 q
408 }
409 s/.*/./; q'`
a6089b1e 410
a6089b1e 411# Avoid depending upon Character Ranges.
412as_cr_letters='abcdefghijklmnopqrstuvwxyz'
413as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
414as_cr_Letters=$as_cr_letters$as_cr_LETTERS
415as_cr_digits='0123456789'
416as_cr_alnum=$as_cr_Letters$as_cr_digits
417
a6089b1e 418
cd9a469c 419 as_lineno_1=$LINENO as_lineno_1a=$LINENO
420 as_lineno_2=$LINENO as_lineno_2a=$LINENO
421 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
422 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
423 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
424 sed -n '
425 p
426 /[$]LINENO/=
427 ' <$as_myself |
a6089b1e 428 sed '
cd9a469c 429 s/[$]LINENO.*/&-/
430 t lineno
431 b
432 :lineno
a6089b1e 433 N
cd9a469c 434 :loop
435 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
a6089b1e 436 t loop
cd9a469c 437 s/-\n.*//
a6089b1e 438 ' >$as_me.lineno &&
cd9a469c 439 chmod +x "$as_me.lineno" ||
440 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
a6089b1e 441
442 # Don't try to exec as it changes $[0], causing all sort of problems
443 # (the dirname of $[0] is not the place where we might find the
cd9a469c 444 # original and so on. Autoconf is especially sensitive to this).
445 . "./$as_me.lineno"
a6089b1e 446 # Exit status is that of the last command.
447 exit
448}
449
cd9a469c 450ECHO_C= ECHO_N= ECHO_T=
451case `echo -n x` in #(((((
452-n*)
453 case `echo 'xy\c'` in
454 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
455 xy) ECHO_C='\c';;
456 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
457 ECHO_T=' ';;
458 esac;;
459*)
460 ECHO_N='-n';;
a6089b1e 461esac
462
cd9a469c 463rm -f conf$$ conf$$.exe conf$$.file
464if test -d conf$$.dir; then
465 rm -f conf$$.dir/conf$$.file
a6089b1e 466else
cd9a469c 467 rm -f conf$$.dir
468 mkdir conf$$.dir 2>/dev/null
a6089b1e 469fi
cd9a469c 470if (echo >conf$$.file) 2>/dev/null; then
471 if ln -s conf$$.file conf$$ 2>/dev/null; then
a6089b1e 472 as_ln_s='ln -s'
cd9a469c 473 # ... but there are two gotchas:
474 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
475 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
476 # In both cases, we have to default to `cp -p'.
477 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
478 as_ln_s='cp -p'
479 elif ln conf$$.file conf$$ 2>/dev/null; then
480 as_ln_s=ln
481 else
482 as_ln_s='cp -p'
a6089b1e 483 fi
a6089b1e 484else
485 as_ln_s='cp -p'
486fi
cd9a469c 487rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
488rmdir conf$$.dir 2>/dev/null
a6089b1e 489
490if mkdir -p . 2>/dev/null; then
cd9a469c 491 as_mkdir_p='mkdir -p "$as_dir"'
a6089b1e 492else
ac09b42b 493 test -d ./-p && rmdir ./-p
a6089b1e 494 as_mkdir_p=false
495fi
496
cd9a469c 497if test -x / >/dev/null 2>&1; then
498 as_test_x='test -x'
499else
500 if ls -dL / >/dev/null 2>&1; then
501 as_ls_L_option=L
502 else
503 as_ls_L_option=
504 fi
505 as_test_x='
506 eval sh -c '\''
507 if test -d "$1"; then
508 test -d "$1/.";
509 else
510 case $1 in #(
511 -*)set "./$1";;
512 esac;
513 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
514 ???[sx]*):;;*)false;;esac;fi
515 '\'' sh
516 '
517fi
518as_executable_p=$as_test_x
a6089b1e 519
520# Sed expression to map a string onto a valid CPP name.
ac09b42b 521as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
a6089b1e 522
523# Sed expression to map a string onto a valid variable name.
ac09b42b 524as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
a6089b1e 525
526
cd9a469c 527exec 7<&0 </dev/null 6>&1
a6089b1e 528
529# Name of the host.
530# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
531# so uname gets run too.
532ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
533
a6089b1e 534#
535# Initializations.
536#
f0a93313 537ac_default_prefix=/usr/local
cd9a469c 538ac_clean_files=
a6089b1e 539ac_config_libobj_dir=.
cd9a469c 540LIBOBJS=
a6089b1e 541cross_compiling=no
542subdirs=
543MFLAGS=
544MAKEFLAGS=
a6089b1e 545
546# Identity of this package.
547PACKAGE_NAME=
548PACKAGE_TARNAME=
549PACKAGE_VERSION=
550PACKAGE_STRING=
551PACKAGE_BUGREPORT=
cd9a469c 552PACKAGE_URL=
a6089b1e 553
554ac_unique_file="xmalloc.c"
555# Factoring default headers for most tests.
556ac_includes_default="\
557#include <stdio.h>
cd9a469c 558#ifdef HAVE_SYS_TYPES_H
a6089b1e 559# include <sys/types.h>
560#endif
cd9a469c 561#ifdef HAVE_SYS_STAT_H
a6089b1e 562# include <sys/stat.h>
563#endif
cd9a469c 564#ifdef STDC_HEADERS
a6089b1e 565# include <stdlib.h>
566# include <stddef.h>
567#else
cd9a469c 568# ifdef HAVE_STDLIB_H
a6089b1e 569# include <stdlib.h>
570# endif
571#endif
cd9a469c 572#ifdef HAVE_STRING_H
573# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
a6089b1e 574# include <memory.h>
575# endif
576# include <string.h>
577#endif
cd9a469c 578#ifdef HAVE_STRINGS_H
a6089b1e 579# include <strings.h>
580#endif
cd9a469c 581#ifdef HAVE_INTTYPES_H
a6089b1e 582# include <inttypes.h>
a6089b1e 583#endif
cd9a469c 584#ifdef HAVE_STDINT_H
585# include <stdint.h>
586#endif
587#ifdef HAVE_UNISTD_H
a6089b1e 588# include <unistd.h>
589#endif"
590
cd9a469c 591ac_subst_vars='LTLIBOBJS
592INSTALL_DEST
593pexecute
594target_header_dir
595CHECK
596LIBOBJS
f945635a 597NOASANFLAG
cd9a469c 598PICFLAG
599INSTALL_DATA
600INSTALL_SCRIPT
601INSTALL_PROGRAM
cd9a469c 602OUTPUT_OPTION
603NO_MINUS_C_MINUS_O
604ac_libiberty_warn_cflags
19ecc7c1 605EGREP
606GREP
cd9a469c 607CPP
608OBJEXT
609EXEEXT
610ac_ct_CC
611CPPFLAGS
612LDFLAGS
613CFLAGS
614CC
615RANLIB
616AR
617host_os
618host_vendor
619host_cpu
620host
621build_os
622build_vendor
623build_cpu
624build
625HAVE_PERL
626PERL
627BUILD_INFO
628MAKEINFO
629NOTMAINT
630MAINT
631libiberty_topdir
632target_alias
633host_alias
634build_alias
635LIBS
636ECHO_T
637ECHO_N
638ECHO_C
639DEFS
640mandir
641localedir
642libdir
643psdir
644pdfdir
645dvidir
646htmldir
647infodir
648docdir
649oldincludedir
650includedir
651localstatedir
652sharedstatedir
653sysconfdir
654datadir
655datarootdir
656libexecdir
657sbindir
658bindir
659program_transform_name
660prefix
661exec_prefix
662PACKAGE_URL
663PACKAGE_BUGREPORT
664PACKAGE_STRING
665PACKAGE_VERSION
666PACKAGE_TARNAME
667PACKAGE_NAME
668PATH_SEPARATOR
669SHELL'
a6089b1e 670ac_subst_files='host_makefile_frag'
cd9a469c 671ac_user_opts='
672enable_option_checking
673with_target_subdir
674with_build_subdir
675with_cross_host
676with_newlib
677enable_maintainer_mode
678enable_multilib
cd9a469c 679enable_install_libiberty
d86ceed1 680enable_largefile
cd9a469c 681'
682 ac_precious_vars='build_alias
683host_alias
684target_alias
685CC
686CFLAGS
687LDFLAGS
688LIBS
689CPPFLAGS
690CPP'
691
f0a93313 692
693# Initialize some variables set by options.
a6089b1e 694ac_init_help=
695ac_init_version=false
cd9a469c 696ac_unrecognized_opts=
697ac_unrecognized_sep=
f0a93313 698# The variables have the same names as the options, with
699# dashes changed to underlines.
a6089b1e 700cache_file=/dev/null
f0a93313 701exec_prefix=NONE
f0a93313 702no_create=
f0a93313 703no_recursion=
704prefix=NONE
705program_prefix=NONE
706program_suffix=NONE
707program_transform_name=s,x,x,
708silent=
709site=
710srcdir=
f0a93313 711verbose=
712x_includes=NONE
713x_libraries=NONE
a6089b1e 714
715# Installation directory options.
716# These are left unexpanded so users can "make install exec_prefix=/foo"
717# and all the variables that are supposed to be based on exec_prefix
718# by default will actually change.
719# Use braces instead of parens because sh, perl, etc. also accept them.
cd9a469c 720# (The list follows the same order as the GNU Coding Standards.)
f0a93313 721bindir='${exec_prefix}/bin'
722sbindir='${exec_prefix}/sbin'
723libexecdir='${exec_prefix}/libexec'
cd9a469c 724datarootdir='${prefix}/share'
725datadir='${datarootdir}'
f0a93313 726sysconfdir='${prefix}/etc'
727sharedstatedir='${prefix}/com'
728localstatedir='${prefix}/var'
f0a93313 729includedir='${prefix}/include'
730oldincludedir='/usr/include'
cd9a469c 731docdir='${datarootdir}/doc/${PACKAGE}'
732infodir='${datarootdir}/info'
733htmldir='${docdir}'
734dvidir='${docdir}'
735pdfdir='${docdir}'
736psdir='${docdir}'
737libdir='${exec_prefix}/lib'
738localedir='${datarootdir}/locale'
739mandir='${datarootdir}/man'
f0a93313 740
f0a93313 741ac_prev=
cd9a469c 742ac_dashdash=
f0a93313 743for ac_option
744do
f0a93313 745 # If the previous option needs an argument, assign it.
746 if test -n "$ac_prev"; then
cd9a469c 747 eval $ac_prev=\$ac_option
f0a93313 748 ac_prev=
749 continue
750 fi
751
cd9a469c 752 case $ac_option in
753 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
754 *) ac_optarg=yes ;;
755 esac
f0a93313 756
757 # Accept the important Cygnus configure options, so we can diagnose typos.
758
cd9a469c 759 case $ac_dashdash$ac_option in
760 --)
761 ac_dashdash=yes ;;
f0a93313 762
763 -bindir | --bindir | --bindi | --bind | --bin | --bi)
764 ac_prev=bindir ;;
765 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
a6089b1e 766 bindir=$ac_optarg ;;
f0a93313 767
768 -build | --build | --buil | --bui | --bu)
a6089b1e 769 ac_prev=build_alias ;;
f0a93313 770 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
a6089b1e 771 build_alias=$ac_optarg ;;
f0a93313 772
773 -cache-file | --cache-file | --cache-fil | --cache-fi \
774 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
775 ac_prev=cache_file ;;
776 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
777 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
a6089b1e 778 cache_file=$ac_optarg ;;
779
780 --config-cache | -C)
781 cache_file=config.cache ;;
f0a93313 782
cd9a469c 783 -datadir | --datadir | --datadi | --datad)
f0a93313 784 ac_prev=datadir ;;
cd9a469c 785 -datadir=* | --datadir=* | --datadi=* | --datad=*)
a6089b1e 786 datadir=$ac_optarg ;;
f0a93313 787
cd9a469c 788 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
789 | --dataroo | --dataro | --datar)
790 ac_prev=datarootdir ;;
791 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
792 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
793 datarootdir=$ac_optarg ;;
794
f0a93313 795 -disable-* | --disable-*)
cd9a469c 796 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
f0a93313 797 # Reject names that are not valid shell variable names.
cd9a469c 798 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
799 as_fn_error "invalid feature name: $ac_useropt"
800 ac_useropt_orig=$ac_useropt
801 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
802 case $ac_user_opts in
803 *"
804"enable_$ac_useropt"
805"*) ;;
806 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
807 ac_unrecognized_sep=', ';;
808 esac
809 eval enable_$ac_useropt=no ;;
810
811 -docdir | --docdir | --docdi | --doc | --do)
812 ac_prev=docdir ;;
813 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
814 docdir=$ac_optarg ;;
815
816 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
817 ac_prev=dvidir ;;
818 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
819 dvidir=$ac_optarg ;;
f0a93313 820
821 -enable-* | --enable-*)
cd9a469c 822 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
f0a93313 823 # Reject names that are not valid shell variable names.
cd9a469c 824 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
825 as_fn_error "invalid feature name: $ac_useropt"
826 ac_useropt_orig=$ac_useropt
827 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
828 case $ac_user_opts in
829 *"
830"enable_$ac_useropt"
831"*) ;;
832 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
833 ac_unrecognized_sep=', ';;
f0a93313 834 esac
cd9a469c 835 eval enable_$ac_useropt=\$ac_optarg ;;
f0a93313 836
837 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
838 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
839 | --exec | --exe | --ex)
840 ac_prev=exec_prefix ;;
841 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
842 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
843 | --exec=* | --exe=* | --ex=*)
a6089b1e 844 exec_prefix=$ac_optarg ;;
f0a93313 845
846 -gas | --gas | --ga | --g)
847 # Obsolete; use --with-gas.
848 with_gas=yes ;;
849
a6089b1e 850 -help | --help | --hel | --he | -h)
851 ac_init_help=long ;;
852 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
853 ac_init_help=recursive ;;
854 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
855 ac_init_help=short ;;
f0a93313 856
857 -host | --host | --hos | --ho)
a6089b1e 858 ac_prev=host_alias ;;
f0a93313 859 -host=* | --host=* | --hos=* | --ho=*)
a6089b1e 860 host_alias=$ac_optarg ;;
f0a93313 861
cd9a469c 862 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
863 ac_prev=htmldir ;;
864 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
865 | --ht=*)
866 htmldir=$ac_optarg ;;
867
f0a93313 868 -includedir | --includedir | --includedi | --included | --include \
869 | --includ | --inclu | --incl | --inc)
870 ac_prev=includedir ;;
871 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
872 | --includ=* | --inclu=* | --incl=* | --inc=*)
a6089b1e 873 includedir=$ac_optarg ;;
f0a93313 874
875 -infodir | --infodir | --infodi | --infod | --info | --inf)
876 ac_prev=infodir ;;
877 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
a6089b1e 878 infodir=$ac_optarg ;;
f0a93313 879
880 -libdir | --libdir | --libdi | --libd)
881 ac_prev=libdir ;;
882 -libdir=* | --libdir=* | --libdi=* | --libd=*)
a6089b1e 883 libdir=$ac_optarg ;;
f0a93313 884
885 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
886 | --libexe | --libex | --libe)
887 ac_prev=libexecdir ;;
888 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
889 | --libexe=* | --libex=* | --libe=*)
a6089b1e 890 libexecdir=$ac_optarg ;;
f0a93313 891
cd9a469c 892 -localedir | --localedir | --localedi | --localed | --locale)
893 ac_prev=localedir ;;
894 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
895 localedir=$ac_optarg ;;
896
f0a93313 897 -localstatedir | --localstatedir | --localstatedi | --localstated \
cd9a469c 898 | --localstate | --localstat | --localsta | --localst | --locals)
f0a93313 899 ac_prev=localstatedir ;;
900 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
cd9a469c 901 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
a6089b1e 902 localstatedir=$ac_optarg ;;
f0a93313 903
904 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
905 ac_prev=mandir ;;
906 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
a6089b1e 907 mandir=$ac_optarg ;;
f0a93313 908
909 -nfp | --nfp | --nf)
910 # Obsolete; use --without-fp.
911 with_fp=no ;;
912
913 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
a6089b1e 914 | --no-cr | --no-c | -n)
f0a93313 915 no_create=yes ;;
916
917 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
918 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
919 no_recursion=yes ;;
920
921 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
922 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
923 | --oldin | --oldi | --old | --ol | --o)
924 ac_prev=oldincludedir ;;
925 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
926 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
927 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
a6089b1e 928 oldincludedir=$ac_optarg ;;
f0a93313 929
930 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
931 ac_prev=prefix ;;
932 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
a6089b1e 933 prefix=$ac_optarg ;;
f0a93313 934
935 -program-prefix | --program-prefix | --program-prefi | --program-pref \
936 | --program-pre | --program-pr | --program-p)
937 ac_prev=program_prefix ;;
938 -program-prefix=* | --program-prefix=* | --program-prefi=* \
939 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
a6089b1e 940 program_prefix=$ac_optarg ;;
f0a93313 941
942 -program-suffix | --program-suffix | --program-suffi | --program-suff \
943 | --program-suf | --program-su | --program-s)
944 ac_prev=program_suffix ;;
945 -program-suffix=* | --program-suffix=* | --program-suffi=* \
946 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
a6089b1e 947 program_suffix=$ac_optarg ;;
f0a93313 948
949 -program-transform-name | --program-transform-name \
950 | --program-transform-nam | --program-transform-na \
951 | --program-transform-n | --program-transform- \
952 | --program-transform | --program-transfor \
953 | --program-transfo | --program-transf \
954 | --program-trans | --program-tran \
955 | --progr-tra | --program-tr | --program-t)
956 ac_prev=program_transform_name ;;
957 -program-transform-name=* | --program-transform-name=* \
958 | --program-transform-nam=* | --program-transform-na=* \
959 | --program-transform-n=* | --program-transform-=* \
960 | --program-transform=* | --program-transfor=* \
961 | --program-transfo=* | --program-transf=* \
962 | --program-trans=* | --program-tran=* \
963 | --progr-tra=* | --program-tr=* | --program-t=*)
a6089b1e 964 program_transform_name=$ac_optarg ;;
f0a93313 965
cd9a469c 966 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
967 ac_prev=pdfdir ;;
968 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
969 pdfdir=$ac_optarg ;;
970
971 -psdir | --psdir | --psdi | --psd | --ps)
972 ac_prev=psdir ;;
973 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
974 psdir=$ac_optarg ;;
975
f0a93313 976 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
977 | -silent | --silent | --silen | --sile | --sil)
978 silent=yes ;;
979
980 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
981 ac_prev=sbindir ;;
982 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
983 | --sbi=* | --sb=*)
a6089b1e 984 sbindir=$ac_optarg ;;
f0a93313 985
986 -sharedstatedir | --sharedstatedir | --sharedstatedi \
987 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
988 | --sharedst | --shareds | --shared | --share | --shar \
989 | --sha | --sh)
990 ac_prev=sharedstatedir ;;
991 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
992 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
993 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
994 | --sha=* | --sh=*)
a6089b1e 995 sharedstatedir=$ac_optarg ;;
f0a93313 996
997 -site | --site | --sit)
998 ac_prev=site ;;
999 -site=* | --site=* | --sit=*)
a6089b1e 1000 site=$ac_optarg ;;
f0a93313 1001
1002 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1003 ac_prev=srcdir ;;
1004 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
a6089b1e 1005 srcdir=$ac_optarg ;;
f0a93313 1006
1007 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1008 | --syscon | --sysco | --sysc | --sys | --sy)
1009 ac_prev=sysconfdir ;;
1010 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1011 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
a6089b1e 1012 sysconfdir=$ac_optarg ;;
f0a93313 1013
1014 -target | --target | --targe | --targ | --tar | --ta | --t)
a6089b1e 1015 ac_prev=target_alias ;;
f0a93313 1016 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
a6089b1e 1017 target_alias=$ac_optarg ;;
f0a93313 1018
1019 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1020 verbose=yes ;;
1021
a6089b1e 1022 -version | --version | --versio | --versi | --vers | -V)
1023 ac_init_version=: ;;
f0a93313 1024
1025 -with-* | --with-*)
cd9a469c 1026 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
f0a93313 1027 # Reject names that are not valid shell variable names.
cd9a469c 1028 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1029 as_fn_error "invalid package name: $ac_useropt"
1030 ac_useropt_orig=$ac_useropt
1031 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1032 case $ac_user_opts in
1033 *"
1034"with_$ac_useropt"
1035"*) ;;
1036 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1037 ac_unrecognized_sep=', ';;
f0a93313 1038 esac
cd9a469c 1039 eval with_$ac_useropt=\$ac_optarg ;;
f0a93313 1040
1041 -without-* | --without-*)
cd9a469c 1042 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
f0a93313 1043 # Reject names that are not valid shell variable names.
cd9a469c 1044 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1045 as_fn_error "invalid package name: $ac_useropt"
1046 ac_useropt_orig=$ac_useropt
1047 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1048 case $ac_user_opts in
1049 *"
1050"with_$ac_useropt"
1051"*) ;;
1052 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1053 ac_unrecognized_sep=', ';;
1054 esac
1055 eval with_$ac_useropt=no ;;
f0a93313 1056
1057 --x)
1058 # Obsolete; use --with-x.
1059 with_x=yes ;;
1060
1061 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1062 | --x-incl | --x-inc | --x-in | --x-i)
1063 ac_prev=x_includes ;;
1064 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1065 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
a6089b1e 1066 x_includes=$ac_optarg ;;
f0a93313 1067
1068 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1069 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1070 ac_prev=x_libraries ;;
1071 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1072 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
a6089b1e 1073 x_libraries=$ac_optarg ;;
f0a93313 1074
cd9a469c 1075 -*) as_fn_error "unrecognized option: \`$ac_option'
1076Try \`$0 --help' for more information."
f0a93313 1077 ;;
1078
a6089b1e 1079 *=*)
1080 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1081 # Reject names that are not valid shell variable names.
cd9a469c 1082 case $ac_envvar in #(
1083 '' | [0-9]* | *[!_$as_cr_alnum]* )
1084 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1085 esac
1086 eval $ac_envvar=\$ac_optarg
a6089b1e 1087 export $ac_envvar ;;
1088
f0a93313 1089 *)
a6089b1e 1090 # FIXME: should be removed in autoconf 3.0.
cd9a469c 1091 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
a6089b1e 1092 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
cd9a469c 1093 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
a6089b1e 1094 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
f0a93313 1095 ;;
1096
1097 esac
1098done
1099
1100if test -n "$ac_prev"; then
a6089b1e 1101 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
cd9a469c 1102 as_fn_error "missing argument to $ac_option"
f0a93313 1103fi
f0a93313 1104
cd9a469c 1105if test -n "$ac_unrecognized_opts"; then
1106 case $enable_option_checking in
1107 no) ;;
1108 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1109 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
a6089b1e 1110 esac
cd9a469c 1111fi
f0a93313 1112
cd9a469c 1113# Check all directory arguments for consistency.
1114for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1115 datadir sysconfdir sharedstatedir localstatedir includedir \
1116 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1117 libdir localedir mandir
f0a93313 1118do
cd9a469c 1119 eval ac_val=\$$ac_var
1120 # Remove trailing slashes.
a6089b1e 1121 case $ac_val in
cd9a469c 1122 */ )
1123 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1124 eval $ac_var=\$ac_val;;
f0a93313 1125 esac
cd9a469c 1126 # Be sure to have absolute directory names.
1127 case $ac_val in
1128 [\\/$]* | ?:[\\/]* ) continue;;
1129 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1130 esac
1131 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
f0a93313 1132done
1133
a6089b1e 1134# There might be people who depend on the old broken behavior: `$host'
1135# used to hold the argument of --host etc.
1136# FIXME: To remove some day.
1137build=$build_alias
1138host=$host_alias
1139target=$target_alias
1140
1141# FIXME: To remove some day.
1142if test "x$host_alias" != x; then
1143 if test "x$build_alias" = x; then
1144 cross_compiling=maybe
cd9a469c 1145 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
a6089b1e 1146 If a cross compiler is detected then cross compile mode will be used." >&2
1147 elif test "x$build_alias" != "x$host_alias"; then
1148 cross_compiling=yes
1149 fi
1150fi
f0a93313 1151
a6089b1e 1152ac_tool_prefix=
1153test -n "$host_alias" && ac_tool_prefix=$host_alias-
1154
1155test "$silent" = yes && exec 6>/dev/null
f0a93313 1156
f0a93313 1157
cd9a469c 1158ac_pwd=`pwd` && test -n "$ac_pwd" &&
1159ac_ls_di=`ls -di .` &&
1160ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1161 as_fn_error "working directory cannot be determined"
1162test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1163 as_fn_error "pwd does not report name of working directory"
1164
1165
f0a93313 1166# Find the source files, if location was not specified.
1167if test -z "$srcdir"; then
1168 ac_srcdir_defaulted=yes
cd9a469c 1169 # Try the directory containing this script, then the parent directory.
1170 ac_confdir=`$as_dirname -- "$as_myself" ||
1171$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1172 X"$as_myself" : 'X\(//\)[^/]' \| \
1173 X"$as_myself" : 'X\(//\)$' \| \
1174 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1175$as_echo X"$as_myself" |
1176 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1177 s//\1/
1178 q
1179 }
1180 /^X\(\/\/\)[^/].*/{
1181 s//\1/
1182 q
1183 }
1184 /^X\(\/\/\)$/{
1185 s//\1/
1186 q
1187 }
1188 /^X\(\/\).*/{
1189 s//\1/
1190 q
1191 }
1192 s/.*/./; q'`
f0a93313 1193 srcdir=$ac_confdir
cd9a469c 1194 if test ! -r "$srcdir/$ac_unique_file"; then
f0a93313 1195 srcdir=..
1196 fi
1197else
1198 ac_srcdir_defaulted=no
1199fi
cd9a469c 1200if test ! -r "$srcdir/$ac_unique_file"; then
1201 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1202 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
1203fi
1204ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1205ac_abs_confdir=`(
1206 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
1207 pwd)`
1208# When building in place, set srcdir=.
1209if test "$ac_abs_confdir" = "$ac_pwd"; then
1210 srcdir=.
1211fi
1212# Remove unnecessary trailing slashes from srcdir.
1213# Double slashes in file names in object file debugging info
1214# mess up M-x gdb in Emacs.
1215case $srcdir in
1216*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1217esac
1218for ac_var in $ac_precious_vars; do
1219 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1220 eval ac_env_${ac_var}_value=\$${ac_var}
1221 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1222 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1223done
a6089b1e 1224
1225#
1226# Report the --help message.
1227#
1228if test "$ac_init_help" = "long"; then
1229 # Omit some internal or obsolete options to make the list less imposing.
1230 # This message is too long to be a string in the A/UX 3.1 sh.
1231 cat <<_ACEOF
1232\`configure' configures this package to adapt to many kinds of systems.
1233
1234Usage: $0 [OPTION]... [VAR=VALUE]...
1235
1236To assign environment variables (e.g., CC, CFLAGS...), specify them as
1237VAR=VALUE. See below for descriptions of some of the useful variables.
1238
1239Defaults for the options are specified in brackets.
1240
1241Configuration:
1242 -h, --help display this help and exit
1243 --help=short display options specific to this package
1244 --help=recursive display the short help of all the included packages
1245 -V, --version display version information and exit
1246 -q, --quiet, --silent do not print \`checking...' messages
1247 --cache-file=FILE cache test results in FILE [disabled]
1248 -C, --config-cache alias for \`--cache-file=config.cache'
1249 -n, --no-create do not create output files
1250 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1251
a6089b1e 1252Installation directories:
1253 --prefix=PREFIX install architecture-independent files in PREFIX
cd9a469c 1254 [$ac_default_prefix]
a6089b1e 1255 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
cd9a469c 1256 [PREFIX]
a6089b1e 1257
1258By default, \`make install' will install all the files in
1259\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1260an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1261for instance \`--prefix=\$HOME'.
1262
1263For better control, use the options below.
1264
1265Fine tuning of the installation directories:
cd9a469c 1266 --bindir=DIR user executables [EPREFIX/bin]
1267 --sbindir=DIR system admin executables [EPREFIX/sbin]
1268 --libexecdir=DIR program executables [EPREFIX/libexec]
1269 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1270 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1271 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1272 --libdir=DIR object code libraries [EPREFIX/lib]
1273 --includedir=DIR C header files [PREFIX/include]
1274 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1275 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1276 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1277 --infodir=DIR info documentation [DATAROOTDIR/info]
1278 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1279 --mandir=DIR man documentation [DATAROOTDIR/man]
1280 --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE]
1281 --htmldir=DIR html documentation [DOCDIR]
1282 --dvidir=DIR dvi documentation [DOCDIR]
1283 --pdfdir=DIR pdf documentation [DOCDIR]
1284 --psdir=DIR ps documentation [DOCDIR]
a6089b1e 1285_ACEOF
1286
1287 cat <<\_ACEOF
1288
1289System types:
1290 --build=BUILD configure for building on BUILD [guessed]
1291 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1292_ACEOF
1293fi
1294
1295if test -n "$ac_init_help"; then
1296
1297 cat <<\_ACEOF
1298
1299Optional Features:
cd9a469c 1300 --disable-option-checking ignore unrecognized --enable/--with options
a6089b1e 1301 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1302 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1303 --enable-maintainer-mode
1304 enable make rules and dependencies not useful
1305 (and sometimes confusing) to the casual installer
b88bcfca 1306 --enable-multilib build many library versions (default)
d86ceed1 1307 --enable-install-libiberty Install headers and library for end users
0a8f1add 1308 --disable-largefile omit support for large files
a6089b1e 1309
1310Optional Packages:
1311 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1312 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1313 --with-target-subdir=SUBDIR Configuring in a subdirectory for target
1314 --with-build-subdir=SUBDIR Configuring in a subdirectory for build
1315 --with-cross-host=HOST Configuring with a cross compiler
1316 --with-newlib Configuring with newlib
1317
1318Some influential environment variables:
1319 CC C compiler command
1320 CFLAGS C compiler flags
1321 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1322 nonstandard directory <lib dir>
cd9a469c 1323 LIBS libraries to pass to the linker, e.g. -l<library>
1324 CPPFLAGS C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1325 you have headers in a nonstandard directory <include dir>
a6089b1e 1326 CPP C preprocessor
1327
1328Use these variables to override the choices made by `configure' or to help
1329it to find libraries and programs with nonstandard names/locations.
1330
cd9a469c 1331Report bugs to the package provider.
a6089b1e 1332_ACEOF
cd9a469c 1333ac_status=$?
a6089b1e 1334fi
1335
1336if test "$ac_init_help" = "recursive"; then
1337 # If there are subdirs, report their specific --help.
a6089b1e 1338 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
cd9a469c 1339 test -d "$ac_dir" ||
1340 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1341 continue
a6089b1e 1342 ac_builddir=.
1343
cd9a469c 1344case "$ac_dir" in
1345.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1346*)
1347 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1348 # A ".." for each directory in $ac_dir_suffix.
1349 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1350 case $ac_top_builddir_sub in
1351 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1352 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1353 esac ;;
1354esac
1355ac_abs_top_builddir=$ac_pwd
1356ac_abs_builddir=$ac_pwd$ac_dir_suffix
1357# for backward compatibility:
1358ac_top_builddir=$ac_top_build_prefix
a6089b1e 1359
1360case $srcdir in
cd9a469c 1361 .) # We are building in place.
a6089b1e 1362 ac_srcdir=.
cd9a469c 1363 ac_top_srcdir=$ac_top_builddir_sub
1364 ac_abs_top_srcdir=$ac_pwd ;;
1365 [\\/]* | ?:[\\/]* ) # Absolute name.
a6089b1e 1366 ac_srcdir=$srcdir$ac_dir_suffix;
cd9a469c 1367 ac_top_srcdir=$srcdir
1368 ac_abs_top_srcdir=$srcdir ;;
1369 *) # Relative name.
1370 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1371 ac_top_srcdir=$ac_top_build_prefix$srcdir
1372 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
ac09b42b 1373esac
cd9a469c 1374ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1375
1376 cd "$ac_dir" || { ac_status=$?; continue; }
1377 # Check for guested configure.
1378 if test -f "$ac_srcdir/configure.gnu"; then
1379 echo &&
1380 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1381 elif test -f "$ac_srcdir/configure"; then
1382 echo &&
1383 $SHELL "$ac_srcdir/configure" --help=recursive
a6089b1e 1384 else
cd9a469c 1385 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1386 fi || ac_status=$?
1387 cd "$ac_pwd" || { ac_status=$?; break; }
a6089b1e 1388 done
1389fi
1390
cd9a469c 1391test -n "$ac_init_help" && exit $ac_status
a6089b1e 1392if $ac_init_version; then
1393 cat <<\_ACEOF
cd9a469c 1394configure
1395generated by GNU Autoconf 2.64
a6089b1e 1396
cd9a469c 1397Copyright (C) 2009 Free Software Foundation, Inc.
a6089b1e 1398This configure script is free software; the Free Software Foundation
1399gives unlimited permission to copy, distribute and modify it.
1400_ACEOF
cd9a469c 1401 exit
a6089b1e 1402fi
a6089b1e 1403
cd9a469c 1404## ------------------------ ##
1405## Autoconf initialization. ##
1406## ------------------------ ##
a6089b1e 1407
cd9a469c 1408# ac_fn_c_try_compile LINENO
1409# --------------------------
1410# Try to compile conftest.$ac_ext, and return whether this succeeded.
1411ac_fn_c_try_compile ()
a6089b1e 1412{
cd9a469c 1413 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1414 rm -f conftest.$ac_objext
1415 if { { ac_try="$ac_compile"
1416case "(($ac_try" in
1417 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1418 *) ac_try_echo=$ac_try;;
1419esac
1420eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1421$as_echo "$ac_try_echo"; } >&5
1422 (eval "$ac_compile") 2>conftest.err
1423 ac_status=$?
1424 if test -s conftest.err; then
1425 grep -v '^ *+' conftest.err >conftest.er1
1426 cat conftest.er1 >&5
1427 mv -f conftest.er1 conftest.err
1428 fi
1429 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1430 test $ac_status = 0; } && {
1431 test -z "$ac_c_werror_flag" ||
1432 test ! -s conftest.err
1433 } && test -s conftest.$ac_objext; then :
1434 ac_retval=0
1435else
1436 $as_echo "$as_me: failed program was:" >&5
1437sed 's/^/| /' conftest.$ac_ext >&5
a6089b1e 1438
cd9a469c 1439 ac_retval=1
1440fi
1441 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1442 return $ac_retval
a6089b1e 1443
cd9a469c 1444} # ac_fn_c_try_compile
a6089b1e 1445
cd9a469c 1446# ac_fn_c_try_cpp LINENO
1447# ----------------------
1448# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1449ac_fn_c_try_cpp ()
1450{
1451 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1452 if { { ac_try="$ac_cpp conftest.$ac_ext"
1453case "(($ac_try" in
1454 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1455 *) ac_try_echo=$ac_try;;
1456esac
1457eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1458$as_echo "$ac_try_echo"; } >&5
1459 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1460 ac_status=$?
1461 if test -s conftest.err; then
1462 grep -v '^ *+' conftest.err >conftest.er1
1463 cat conftest.er1 >&5
1464 mv -f conftest.er1 conftest.err
1465 fi
1466 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1467 test $ac_status = 0; } >/dev/null && {
1468 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1469 test ! -s conftest.err
1470 }; then :
1471 ac_retval=0
1472else
1473 $as_echo "$as_me: failed program was:" >&5
1474sed 's/^/| /' conftest.$ac_ext >&5
a6089b1e 1475
cd9a469c 1476 ac_retval=1
1477fi
1478 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1479 return $ac_retval
a6089b1e 1480
cd9a469c 1481} # ac_fn_c_try_cpp
a6089b1e 1482
19ecc7c1 1483# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1484# -------------------------------------------------------
1485# Tests whether HEADER exists, giving a warning if it cannot be compiled using
1486# the include files in INCLUDES and setting the cache variable VAR
1487# accordingly.
1488ac_fn_c_check_header_mongrel ()
1489{
1490 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1491 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1492 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1493$as_echo_n "checking for $2... " >&6; }
1494if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1495 $as_echo_n "(cached) " >&6
1496fi
1497eval ac_res=\$$3
1498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1499$as_echo "$ac_res" >&6; }
1500else
1501 # Is the header compilable?
1502{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1503$as_echo_n "checking $2 usability... " >&6; }
1504cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1505/* end confdefs.h. */
1506$4
1507#include <$2>
1508_ACEOF
1509if ac_fn_c_try_compile "$LINENO"; then :
1510 ac_header_compiler=yes
1511else
1512 ac_header_compiler=no
1513fi
1514rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1515{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1516$as_echo "$ac_header_compiler" >&6; }
1517
1518# Is the header present?
1519{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1520$as_echo_n "checking $2 presence... " >&6; }
1521cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1522/* end confdefs.h. */
1523#include <$2>
1524_ACEOF
1525if ac_fn_c_try_cpp "$LINENO"; then :
1526 ac_header_preproc=yes
1527else
1528 ac_header_preproc=no
1529fi
1530rm -f conftest.err conftest.$ac_ext
1531{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1532$as_echo "$ac_header_preproc" >&6; }
1533
1534# So? What about this header?
1535case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1536 yes:no: )
1537 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1538$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1539 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1540$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1541 ;;
1542 no:yes:* )
1543 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1544$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1545 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
1546$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
1547 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1548$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1549 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
1550$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
1551 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1552$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1553 ;;
1554esac
1555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1556$as_echo_n "checking for $2... " >&6; }
1557if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1558 $as_echo_n "(cached) " >&6
1559else
1560 eval "$3=\$ac_header_compiler"
1561fi
1562eval ac_res=\$$3
1563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1564$as_echo "$ac_res" >&6; }
1565fi
1566 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1567
1568} # ac_fn_c_check_header_mongrel
1569
cd9a469c 1570# ac_fn_c_try_run LINENO
1571# ----------------------
1572# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1573# that executables *can* be run.
1574ac_fn_c_try_run ()
1575{
1576 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1577 if { { ac_try="$ac_link"
1578case "(($ac_try" in
1579 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1580 *) ac_try_echo=$ac_try;;
1581esac
1582eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1583$as_echo "$ac_try_echo"; } >&5
1584 (eval "$ac_link") 2>&5
1585 ac_status=$?
1586 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1587 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1588 { { case "(($ac_try" in
1589 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1590 *) ac_try_echo=$ac_try;;
1591esac
1592eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1593$as_echo "$ac_try_echo"; } >&5
1594 (eval "$ac_try") 2>&5
1595 ac_status=$?
1596 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1597 test $ac_status = 0; }; }; then :
1598 ac_retval=0
1599else
1600 $as_echo "$as_me: program exited with status $ac_status" >&5
1601 $as_echo "$as_me: failed program was:" >&5
1602sed 's/^/| /' conftest.$ac_ext >&5
a6089b1e 1603
cd9a469c 1604 ac_retval=$ac_status
1605fi
1606 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1607 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1608 return $ac_retval
a6089b1e 1609
cd9a469c 1610} # ac_fn_c_try_run
f0a93313 1611
19ecc7c1 1612# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1613# -------------------------------------------------------
1614# Tests whether HEADER exists and can be compiled using the include files in
1615# INCLUDES, setting the cache variable VAR accordingly.
1616ac_fn_c_check_header_compile ()
1617{
1618 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1620$as_echo_n "checking for $2... " >&6; }
1621if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1622 $as_echo_n "(cached) " >&6
1623else
1624 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1625/* end confdefs.h. */
1626$4
1627#include <$2>
1628_ACEOF
1629if ac_fn_c_try_compile "$LINENO"; then :
1630 eval "$3=yes"
1631else
1632 eval "$3=no"
1633fi
1634rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1635fi
1636eval ac_res=\$$3
1637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1638$as_echo "$ac_res" >&6; }
1639 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1640
1641} # ac_fn_c_check_header_compile
1642
cd9a469c 1643# ac_fn_c_check_header_preproc LINENO HEADER VAR
1644# ----------------------------------------------
1645# Tests whether HEADER is present, setting the cache variable VAR accordingly.
1646ac_fn_c_check_header_preproc ()
1647{
1648 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1649 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1650$as_echo_n "checking for $2... " >&6; }
1651if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1652 $as_echo_n "(cached) " >&6
1653else
1654 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1655/* end confdefs.h. */
1656#include <$2>
a6089b1e 1657_ACEOF
cd9a469c 1658if ac_fn_c_try_cpp "$LINENO"; then :
1659 eval "$3=yes"
1660else
1661 eval "$3=no"
1662fi
1663rm -f conftest.err conftest.$ac_ext
1664fi
1665eval ac_res=\$$3
1666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1667$as_echo "$ac_res" >&6; }
1668 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
a6089b1e 1669
cd9a469c 1670} # ac_fn_c_check_header_preproc
a6089b1e 1671
cd9a469c 1672# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
1673# --------------------------------------------
1674# Tries to find the compile-time value of EXPR in a program that includes
1675# INCLUDES, setting VAR accordingly. Returns whether the value could be
1676# computed
1677ac_fn_c_compute_int ()
1678{
1679 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1680 if test "$cross_compiling" = yes; then
1681 # Depending upon the size, compute the lo and hi bounds.
1682cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1683/* end confdefs.h. */
1684$4
1685int
1686main ()
1687{
1688static int test_array [1 - 2 * !(($2) >= 0)];
1689test_array [0] = 0
a6089b1e 1690
cd9a469c 1691 ;
1692 return 0;
1693}
1694_ACEOF
1695if ac_fn_c_try_compile "$LINENO"; then :
1696 ac_lo=0 ac_mid=0
1697 while :; do
1698 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1699/* end confdefs.h. */
1700$4
1701int
1702main ()
a6089b1e 1703{
cd9a469c 1704static int test_array [1 - 2 * !(($2) <= $ac_mid)];
1705test_array [0] = 0
1706
1707 ;
1708 return 0;
a6089b1e 1709}
cd9a469c 1710_ACEOF
1711if ac_fn_c_try_compile "$LINENO"; then :
1712 ac_hi=$ac_mid; break
1713else
1714 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
1715 if test $ac_lo -le $ac_mid; then
1716 ac_lo= ac_hi=
1717 break
1718 fi
1719 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
1720fi
1721rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1722 done
1723else
1724 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1725/* end confdefs.h. */
1726$4
1727int
1728main ()
1729{
1730static int test_array [1 - 2 * !(($2) < 0)];
1731test_array [0] = 0
a6089b1e 1732
cd9a469c 1733 ;
1734 return 0;
1735}
1736_ACEOF
1737if ac_fn_c_try_compile "$LINENO"; then :
1738 ac_hi=-1 ac_mid=-1
1739 while :; do
1740 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1741/* end confdefs.h. */
1742$4
1743int
1744main ()
1745{
1746static int test_array [1 - 2 * !(($2) >= $ac_mid)];
1747test_array [0] = 0
a6089b1e 1748
cd9a469c 1749 ;
1750 return 0;
1751}
1752_ACEOF
1753if ac_fn_c_try_compile "$LINENO"; then :
1754 ac_lo=$ac_mid; break
1755else
1756 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
1757 if test $ac_mid -le $ac_hi; then
1758 ac_lo= ac_hi=
1759 break
1760 fi
1761 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
1762fi
1763rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1764 done
1765else
1766 ac_lo= ac_hi=
1767fi
1768rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1769fi
1770rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1771# Binary search between lo and hi bounds.
1772while test "x$ac_lo" != "x$ac_hi"; do
1773 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
1774 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1775/* end confdefs.h. */
1776$4
1777int
1778main ()
1779{
1780static int test_array [1 - 2 * !(($2) <= $ac_mid)];
1781test_array [0] = 0
a6089b1e 1782
cd9a469c 1783 ;
1784 return 0;
1785}
1786_ACEOF
1787if ac_fn_c_try_compile "$LINENO"; then :
1788 ac_hi=$ac_mid
1789else
1790 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
1791fi
1792rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
a6089b1e 1793done
cd9a469c 1794case $ac_lo in #((
1795?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
1796'') ac_retval=1 ;;
1797esac
1798 else
1799 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1800/* end confdefs.h. */
1801$4
1802static long int longval () { return $2; }
1803static unsigned long int ulongval () { return $2; }
1804#include <stdio.h>
1805#include <stdlib.h>
1806int
1807main ()
1808{
a6089b1e 1809
cd9a469c 1810 FILE *f = fopen ("conftest.val", "w");
1811 if (! f)
1812 return 1;
1813 if (($2) < 0)
1814 {
1815 long int i = longval ();
1816 if (i != ($2))
1817 return 1;
1818 fprintf (f, "%ld", i);
1819 }
1820 else
1821 {
1822 unsigned long int i = ulongval ();
1823 if (i != ($2))
1824 return 1;
1825 fprintf (f, "%lu", i);
1826 }
1827 /* Do not output a trailing newline, as this causes \r\n confusion
1828 on some platforms. */
1829 return ferror (f) || fclose (f) != 0;
a6089b1e 1830
cd9a469c 1831 ;
1832 return 0;
1833}
a6089b1e 1834_ACEOF
cd9a469c 1835if ac_fn_c_try_run "$LINENO"; then :
1836 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
1837else
1838 ac_retval=1
1839fi
1840rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
1841 conftest.$ac_objext conftest.beam conftest.$ac_ext
1842rm -f conftest.val
a6089b1e 1843
cd9a469c 1844 fi
1845 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1846 return $ac_retval
a6089b1e 1847
cd9a469c 1848} # ac_fn_c_compute_int
a6089b1e 1849
cd9a469c 1850# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
1851# -------------------------------------------
1852# Tests whether TYPE exists after having included INCLUDES, setting cache
1853# variable VAR accordingly.
1854ac_fn_c_check_type ()
1855{
1856 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1858$as_echo_n "checking for $2... " >&6; }
1859if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1860 $as_echo_n "(cached) " >&6
1861else
1862 eval "$3=no"
1863 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1864/* end confdefs.h. */
1865$4
1866int
1867main ()
1868{
1869if (sizeof ($2))
1870 return 0;
1871 ;
1872 return 0;
1873}
a6089b1e 1874_ACEOF
cd9a469c 1875if ac_fn_c_try_compile "$LINENO"; then :
1876 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1877/* end confdefs.h. */
1878$4
1879int
1880main ()
1881{
1882if (sizeof (($2)))
1883 return 0;
1884 ;
1885 return 0;
1886}
a6089b1e 1887_ACEOF
cd9a469c 1888if ac_fn_c_try_compile "$LINENO"; then :
a6089b1e 1889
cd9a469c 1890else
1891 eval "$3=yes"
1892fi
1893rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1894fi
1895rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1896fi
1897eval ac_res=\$$3
1898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1899$as_echo "$ac_res" >&6; }
1900 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
a6089b1e 1901
cd9a469c 1902} # ac_fn_c_check_type
a6089b1e 1903
cd9a469c 1904# ac_fn_c_try_link LINENO
1905# -----------------------
1906# Try to link conftest.$ac_ext, and return whether this succeeded.
1907ac_fn_c_try_link ()
1908{
1909 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1910 rm -f conftest.$ac_objext conftest$ac_exeext
1911 if { { ac_try="$ac_link"
1912case "(($ac_try" in
1913 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1914 *) ac_try_echo=$ac_try;;
1915esac
1916eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1917$as_echo "$ac_try_echo"; } >&5
1918 (eval "$ac_link") 2>conftest.err
1919 ac_status=$?
1920 if test -s conftest.err; then
1921 grep -v '^ *+' conftest.err >conftest.er1
1922 cat conftest.er1 >&5
1923 mv -f conftest.er1 conftest.err
f0a93313 1924 fi
cd9a469c 1925 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1926 test $ac_status = 0; } && {
1927 test -z "$ac_c_werror_flag" ||
1928 test ! -s conftest.err
1929 } && test -s conftest$ac_exeext && {
1930 test "$cross_compiling" = yes ||
1931 $as_test_x conftest$ac_exeext
1932 }; then :
1933 ac_retval=0
1934else
1935 $as_echo "$as_me: failed program was:" >&5
1936sed 's/^/| /' conftest.$ac_ext >&5
1937
1938 ac_retval=1
f0a93313 1939fi
cd9a469c 1940 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1941 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1942 # interfere with the next link command; also delete a directory that is
1943 # left behind by Apple's compiler. We do this before executing the actions.
1944 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1945 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1946 return $ac_retval
f0a93313 1947
cd9a469c 1948} # ac_fn_c_try_link
1949
1950# ac_fn_c_check_func LINENO FUNC VAR
1951# ----------------------------------
1952# Tests whether FUNC exists, setting the cache variable VAR accordingly
1953ac_fn_c_check_func ()
1954{
1955 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1957$as_echo_n "checking for $2... " >&6; }
1958if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1959 $as_echo_n "(cached) " >&6
f0a93313 1960else
cd9a469c 1961 if test x$gcc_no_link = xyes; then
1962 as_fn_error "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5
a6089b1e 1963fi
cd9a469c 1964cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1965/* end confdefs.h. */
73834184 1966/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
1967 For example, HP-UX 11i <limits.h> declares gettimeofday. */
1968#define $2 innocuous_$2
1969
cd9a469c 1970/* System header to define __stub macros and hopefully few prototypes,
1971 which can conflict with char $2 (); below.
1972 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
73834184 1973 <limits.h> exists even on freestanding compilers. */
1974
1975#ifdef __STDC__
cd9a469c 1976# include <limits.h>
1977#else
1978# include <assert.h>
1979#endif
73834184 1980
1981#undef $2
1982
1983/* Override any GCC internal prototype to avoid an error.
1984 Use char because int might match the return type of a GCC
1985 builtin and then its argument prototype would still apply. */
cd9a469c 1986#ifdef __cplusplus
1987extern "C"
cd9a469c 1988#endif
cd9a469c 1989char $2 ();
1990/* The GNU C library defines this for functions which it implements
1991 to always fail with ENOSYS. Some functions are actually named
1992 something starting with __ and the normal name is an alias. */
73834184 1993#if defined __stub_$2 || defined __stub___$2
cd9a469c 1994choke me
cd9a469c 1995#endif
a6089b1e 1996
cd9a469c 1997int
1998main ()
1999{
73834184 2000return $2 ();
cd9a469c 2001 ;
2002 return 0;
2003}
2004_ACEOF
2005if ac_fn_c_try_link "$LINENO"; then :
2006 eval "$3=yes"
2007else
2008 eval "$3=no"
f0a93313 2009fi
cd9a469c 2010rm -f core conftest.err conftest.$ac_objext \
2011 conftest$ac_exeext conftest.$ac_ext
2012fi
2013eval ac_res=\$$3
2014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2015$as_echo "$ac_res" >&6; }
2016 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
f0a93313 2017
cd9a469c 2018} # ac_fn_c_check_func
f0a93313 2019
cd9a469c 2020# ac_fn_c_check_decl LINENO SYMBOL VAR
2021# ------------------------------------
2022# Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2023ac_fn_c_check_decl ()
2024{
2025 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
050318d9 2026 as_decl_name=`echo $2|sed 's/ *(.*//'`
2027 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2029$as_echo_n "checking whether $as_decl_name is declared... " >&6; }
cd9a469c 2030if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2031 $as_echo_n "(cached) " >&6
2032else
2033 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2034/* end confdefs.h. */
2035$4
2036int
2037main ()
2038{
050318d9 2039#ifndef $as_decl_name
2040#ifdef __cplusplus
2041 (void) $as_decl_use;
2042#else
2043 (void) $as_decl_name;
2044#endif
cd9a469c 2045#endif
f0a93313 2046
cd9a469c 2047 ;
2048 return 0;
2049}
2050_ACEOF
2051if ac_fn_c_try_compile "$LINENO"; then :
2052 eval "$3=yes"
2053else
2054 eval "$3=no"
2055fi
2056rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2057fi
2058eval ac_res=\$$3
2059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2060$as_echo "$ac_res" >&6; }
2061 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
f0a93313 2062
cd9a469c 2063} # ac_fn_c_check_decl
2064cat >config.log <<_ACEOF
2065This file contains any messages produced by compilers while
2066running configure, to aid debugging if configure makes a mistake.
0b045cf7 2067
cd9a469c 2068It was created by $as_me, which was
2069generated by GNU Autoconf 2.64. Invocation command line was
f0a93313 2070
cd9a469c 2071 $ $0 $@
a6089b1e 2072
cd9a469c 2073_ACEOF
2074exec 5>>config.log
2075{
2076cat <<_ASUNAME
2077## --------- ##
2078## Platform. ##
2079## --------- ##
a6089b1e 2080
cd9a469c 2081hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2082uname -m = `(uname -m) 2>/dev/null || echo unknown`
2083uname -r = `(uname -r) 2>/dev/null || echo unknown`
2084uname -s = `(uname -s) 2>/dev/null || echo unknown`
2085uname -v = `(uname -v) 2>/dev/null || echo unknown`
a6089b1e 2086
cd9a469c 2087/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2088/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
a6089b1e 2089
cd9a469c 2090/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2091/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2092/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2093/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2094/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2095/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2096/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
a6089b1e 2097
cd9a469c 2098_ASUNAME
a6089b1e 2099
cd9a469c 2100as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2101for as_dir in $PATH
2102do
2103 IFS=$as_save_IFS
2104 test -z "$as_dir" && as_dir=.
2105 $as_echo "PATH: $as_dir"
2106 done
2107IFS=$as_save_IFS
a6089b1e 2108
cd9a469c 2109} >&5
a6089b1e 2110
cd9a469c 2111cat >&5 <<_ACEOF
a6089b1e 2112
2113
cd9a469c 2114## ----------- ##
2115## Core tests. ##
2116## ----------- ##
a6089b1e 2117
cd9a469c 2118_ACEOF
a6089b1e 2119
5b2c7553 2120
cd9a469c 2121# Keep a trace of the command line.
2122# Strip out --no-create and --no-recursion so they do not pile up.
2123# Strip out --silent because we don't want to record it for future runs.
2124# Also quote any args containing shell meta-characters.
2125# Make two passes to allow for proper duplicate-argument suppression.
2126ac_configure_args=
2127ac_configure_args0=
2128ac_configure_args1=
2129ac_must_keep_next=false
2130for ac_pass in 1 2
2131do
2132 for ac_arg
2133 do
2134 case $ac_arg in
2135 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2136 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2137 | -silent | --silent | --silen | --sile | --sil)
2138 continue ;;
2139 *\'*)
2140 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2141 esac
2142 case $ac_pass in
2143 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2144 2)
2145 as_fn_append ac_configure_args1 " '$ac_arg'"
2146 if test $ac_must_keep_next = true; then
2147 ac_must_keep_next=false # Got value, back to normal.
2148 else
2149 case $ac_arg in
2150 *=* | --config-cache | -C | -disable-* | --disable-* \
2151 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2152 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2153 | -with-* | --with-* | -without-* | --without-* | --x)
2154 case "$ac_configure_args0 " in
2155 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2156 esac
2157 ;;
2158 -* ) ac_must_keep_next=true ;;
2159 esac
2160 fi
2161 as_fn_append ac_configure_args " '$ac_arg'"
2162 ;;
2163 esac
2164 done
2165done
2166{ ac_configure_args0=; unset ac_configure_args0;}
2167{ ac_configure_args1=; unset ac_configure_args1;}
5b2c7553 2168
cd9a469c 2169# When interrupted or exit'd, cleanup temporary files, and complete
2170# config.log. We remove comments because anyway the quotes in there
2171# would cause problems or look ugly.
2172# WARNING: Use '\'' to represent an apostrophe within the trap.
2173# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2174trap 'exit_status=$?
2175 # Save into config.log some information that might help in debugging.
2176 {
2177 echo
5b2c7553 2178
cd9a469c 2179 cat <<\_ASBOX
2180## ---------------- ##
2181## Cache variables. ##
2182## ---------------- ##
2183_ASBOX
2184 echo
2185 # The following way of writing the cache mishandles newlines in values,
2186(
2187 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2188 eval ac_val=\$$ac_var
2189 case $ac_val in #(
2190 *${as_nl}*)
2191 case $ac_var in #(
2192 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2193$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2194 esac
2195 case $ac_var in #(
2196 _ | IFS | as_nl) ;; #(
2197 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2198 *) { eval $ac_var=; unset $ac_var;} ;;
2199 esac ;;
2200 esac
2201 done
2202 (set) 2>&1 |
2203 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2204 *${as_nl}ac_space=\ *)
2205 sed -n \
2206 "s/'\''/'\''\\\\'\'''\''/g;
2207 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2208 ;; #(
2209 *)
2210 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2211 ;;
2212 esac |
2213 sort
2214)
2215 echo
a6089b1e 2216
cd9a469c 2217 cat <<\_ASBOX
2218## ----------------- ##
2219## Output variables. ##
2220## ----------------- ##
2221_ASBOX
2222 echo
2223 for ac_var in $ac_subst_vars
2224 do
2225 eval ac_val=\$$ac_var
2226 case $ac_val in
2227 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2228 esac
2229 $as_echo "$ac_var='\''$ac_val'\''"
2230 done | sort
2231 echo
a6089b1e 2232
cd9a469c 2233 if test -n "$ac_subst_files"; then
2234 cat <<\_ASBOX
2235## ------------------- ##
2236## File substitutions. ##
2237## ------------------- ##
2238_ASBOX
2239 echo
2240 for ac_var in $ac_subst_files
2241 do
2242 eval ac_val=\$$ac_var
2243 case $ac_val in
2244 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2245 esac
2246 $as_echo "$ac_var='\''$ac_val'\''"
2247 done | sort
2248 echo
2249 fi
6c13736f 2250
cd9a469c 2251 if test -s confdefs.h; then
2252 cat <<\_ASBOX
2253## ----------- ##
2254## confdefs.h. ##
2255## ----------- ##
2256_ASBOX
2257 echo
2258 cat confdefs.h
2259 echo
2260 fi
2261 test "$ac_signal" != 0 &&
2262 $as_echo "$as_me: caught signal $ac_signal"
2263 $as_echo "$as_me: exit $exit_status"
2264 } >&5
2265 rm -f core *.core core.conftest.* &&
2266 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2267 exit $exit_status
2268' 0
2269for ac_signal in 1 2 13 15; do
2270 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2271done
2272ac_signal=0
a6089b1e 2273
cd9a469c 2274# confdefs.h avoids OS command line length limits that DEFS can exceed.
2275rm -f -r conftest* confdefs.h
a6089b1e 2276
cd9a469c 2277$as_echo "/* confdefs.h */" > confdefs.h
a6089b1e 2278
cd9a469c 2279# Predefined preprocessor variables.
a6089b1e 2280
cd9a469c 2281cat >>confdefs.h <<_ACEOF
2282#define PACKAGE_NAME "$PACKAGE_NAME"
2283_ACEOF
a6089b1e 2284
cd9a469c 2285cat >>confdefs.h <<_ACEOF
2286#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2287_ACEOF
a6089b1e 2288
cd9a469c 2289cat >>confdefs.h <<_ACEOF
2290#define PACKAGE_VERSION "$PACKAGE_VERSION"
2291_ACEOF
60d10194 2292
cd9a469c 2293cat >>confdefs.h <<_ACEOF
2294#define PACKAGE_STRING "$PACKAGE_STRING"
2295_ACEOF
a6089b1e 2296
cd9a469c 2297cat >>confdefs.h <<_ACEOF
2298#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2299_ACEOF
804ec1bf 2300
cd9a469c 2301cat >>confdefs.h <<_ACEOF
2302#define PACKAGE_URL "$PACKAGE_URL"
2303_ACEOF
f0a93313 2304
2305
cd9a469c 2306# Let the site file select an alternate cache file if it wants to.
2307# Prefer an explicitly selected file to automatically selected ones.
2308ac_site_file1=NONE
2309ac_site_file2=NONE
2310if test -n "$CONFIG_SITE"; then
2311 ac_site_file1=$CONFIG_SITE
2312elif test "x$prefix" != xNONE; then
2313 ac_site_file1=$prefix/share/config.site
2314 ac_site_file2=$prefix/etc/config.site
2315else
2316 ac_site_file1=$ac_default_prefix/share/config.site
2317 ac_site_file2=$ac_default_prefix/etc/config.site
2318fi
2319for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2320do
2321 test "x$ac_site_file" = xNONE && continue
2322 if test -r "$ac_site_file"; then
2323 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2324$as_echo "$as_me: loading site script $ac_site_file" >&6;}
2325 sed 's/^/| /' "$ac_site_file" >&5
2326 . "$ac_site_file"
2327 fi
2328done
2329
2330if test -r "$cache_file"; then
2331 # Some versions of bash will fail to source /dev/null (special
2332 # files actually), so we avoid doing that.
2333 if test -f "$cache_file"; then
2334 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2335$as_echo "$as_me: loading cache $cache_file" >&6;}
2336 case $cache_file in
2337 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2338 *) . "./$cache_file";;
2339 esac
2340 fi
2341else
2342 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2343$as_echo "$as_me: creating cache $cache_file" >&6;}
2344 >$cache_file
2345fi
2346
2347# Check that the precious variables saved in the cache have kept the same
2348# value.
2349ac_cache_corrupted=false
2350for ac_var in $ac_precious_vars; do
2351 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2352 eval ac_new_set=\$ac_env_${ac_var}_set
2353 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2354 eval ac_new_val=\$ac_env_${ac_var}_value
2355 case $ac_old_set,$ac_new_set in
2356 set,)
2357 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2358$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2359 ac_cache_corrupted=: ;;
2360 ,set)
2361 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2362$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2363 ac_cache_corrupted=: ;;
2364 ,);;
2365 *)
2366 if test "x$ac_old_val" != "x$ac_new_val"; then
2367 # differences in whitespace do not lead to failure.
2368 ac_old_val_w=`echo x $ac_old_val`
2369 ac_new_val_w=`echo x $ac_new_val`
2370 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2371 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2372$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2373 ac_cache_corrupted=:
2374 else
2375 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2376$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2377 eval $ac_var=\$ac_old_val
2378 fi
2379 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2380$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2381 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2382$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2383 fi;;
2384 esac
2385 # Pass precious variables to config.status.
2386 if test "$ac_new_set" = set; then
2387 case $ac_new_val in
2388 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2389 *) ac_arg=$ac_var=$ac_new_val ;;
2390 esac
2391 case " $ac_configure_args " in
2392 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
2393 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2394 esac
2395 fi
2396done
2397if $ac_cache_corrupted; then
2398 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2399$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2400 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2401$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2402 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2403fi
2404## -------------------- ##
2405## Main body of script. ##
2406## -------------------- ##
2407
2408ac_ext=c
2409ac_cpp='$CPP $CPPFLAGS'
2410ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2411ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2412ac_compiler_gnu=$ac_cv_c_compiler_gnu
2413
2414
2415
2416
2417
2418
2419
2420# This works around the fact that libtool configuration may change LD
2421# for this particular configuration, but some shells, instead of
2422# keeping the changes in LD private, export them just because LD is
2423# exported. We don't use libtool yet, but some day we might, so...
2424ORIGINAL_LD_FOR_MULTILIBS=$LD
2425
2426
2427# Check whether --with-target-subdir was given.
2428if test "${with_target_subdir+set}" = set; then :
2429 withval=$with_target_subdir;
2430fi
2431
2432
2433# Check whether --with-build-subdir was given.
2434if test "${with_build_subdir+set}" = set; then :
2435 withval=$with_build_subdir;
2436fi
2437
2438
2439# Check whether --with-cross-host was given.
2440if test "${with_cross_host+set}" = set; then :
2441 withval=$with_cross_host;
2442fi
2443
2444
2445# Check whether --with-newlib was given.
2446if test "${with_newlib+set}" = set; then :
2447 withval=$with_newlib;
2448fi
2449
2450
2451if test "${srcdir}" = "."; then
2452 if test -n "${with_build_subdir}"; then
2453 libiberty_topdir="${srcdir}/../.."
60d10194 2454 with_target_subdir=
2455 elif test -z "${with_target_subdir}"; then
f0a93313 2456 libiberty_topdir="${srcdir}/.."
2457 else
2458 if test "${with_target_subdir}" != "."; then
2459 libiberty_topdir="${srcdir}/${with_multisrctop}../.."
2460 else
2461 libiberty_topdir="${srcdir}/${with_multisrctop}.."
2462 fi
2463 fi
2464else
2465 libiberty_topdir="${srcdir}/.."
2466fi
7f13318a 2467
f0a93313 2468ac_aux_dir=
cd9a469c 2469for ac_dir in $libiberty_topdir "$srcdir"/$libiberty_topdir; do
2470 for ac_t in install-sh install.sh shtool; do
2471 if test -f "$ac_dir/$ac_t"; then
2472 ac_aux_dir=$ac_dir
2473 ac_install_sh="$ac_aux_dir/$ac_t -c"
2474 break 2
2475 fi
2476 done
f0a93313 2477done
2478if test -z "$ac_aux_dir"; then
cd9a469c 2479 as_fn_error "cannot find install-sh, install.sh, or shtool in $libiberty_topdir \"$srcdir\"/$libiberty_topdir" "$LINENO" 5
f0a93313 2480fi
f0a93313 2481
cd9a469c 2482# These three variables are undocumented and unsupported,
2483# and are intended to be withdrawn in a future Autoconf release.
2484# They can cause serious problems if a builder's source tree is in a directory
2485# whose full name contains unusual characters.
2486ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
2487ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
2488ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
f0a93313 2489
2490
cd9a469c 2491
2492
2493{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
2494$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
2495 # Check whether --enable-maintainer-mode was given.
2496if test "${enable_maintainer_mode+set}" = set; then :
2497 enableval=$enable_maintainer_mode; maintainer_mode=$enableval
614a23c6 2498else
2499 maintainer_mode=no
cd9a469c 2500fi
614a23c6 2501
cd9a469c 2502
2503{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $maintainer_mode" >&5
2504$as_echo "$maintainer_mode" >&6; }
614a23c6 2505
2506if test "$maintainer_mode" = "yes"; then
2507 MAINT=''
2508 NOTMAINT='#'
2509else
2510 MAINT='#'
2511 NOTMAINT=''
2512fi
2513
5b7836cc 2514# Do we have a single-tree copy of texinfo? Even if we do, we can't
2515# rely on it - libiberty is built before texinfo.
2516# Extract the first word of "makeinfo", so it can be a program name with args.
614a23c6 2517set dummy makeinfo; ac_word=$2
cd9a469c 2518{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2519$as_echo_n "checking for $ac_word... " >&6; }
2520if test "${ac_cv_prog_MAKEINFO+set}" = set; then :
2521 $as_echo_n "(cached) " >&6
614a23c6 2522else
2523 if test -n "$MAKEINFO"; then
2524 ac_cv_prog_MAKEINFO="$MAKEINFO" # Let the user override the test.
2525else
a6089b1e 2526as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2527for as_dir in $PATH
2528do
2529 IFS=$as_save_IFS
2530 test -z "$as_dir" && as_dir=.
cd9a469c 2531 for ac_exec_ext in '' $ac_executable_extensions; do
2532 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
a6089b1e 2533 ac_cv_prog_MAKEINFO="makeinfo"
cd9a469c 2534 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
a6089b1e 2535 break 2
2536 fi
2537done
cd9a469c 2538 done
2539IFS=$as_save_IFS
a6089b1e 2540
614a23c6 2541fi
2542fi
a6089b1e 2543MAKEINFO=$ac_cv_prog_MAKEINFO
614a23c6 2544if test -n "$MAKEINFO"; then
cd9a469c 2545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
2546$as_echo "$MAKEINFO" >&6; }
614a23c6 2547else
cd9a469c 2548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2549$as_echo "no" >&6; }
614a23c6 2550fi
2551
cd9a469c 2552
7c9e70dd 2553if test "x$MAKEINFO" = "x"; then
2554 MAKEINFO="@echo makeinfo missing; true"
5b7836cc 2555 BUILD_INFO=
7c9e70dd 2556else
2557 BUILD_INFO=info
40a84a93 2558 case "$MAKEINFO" in
2559 */missing\ makeinfo*)
7c9e70dd 2560 BUILD_INFO=
cd9a469c 2561 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
40a84a93 2562*** Makeinfo is missing. Info documentation will not be built." >&5
cd9a469c 2563$as_echo "$as_me: WARNING:
40a84a93 2564*** Makeinfo is missing. Info documentation will not be built." >&2;}
2565 ;;
2566 *)
2567 case x"`$MAKEINFO --version | grep 'GNU texinfo'`" in
2568 x*\ [1-3].* )
2569 MAKEINFO="@echo $MAKEINFO is too old, 4.0 or newer required; true"
2570 BUILD_INFO=
cd9a469c 2571 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
a6089b1e 2572*** Makeinfo is too old. Info documentation will not be built." >&5
cd9a469c 2573$as_echo "$as_me: WARNING:
a6089b1e 2574*** Makeinfo is too old. Info documentation will not be built." >&2;}
40a84a93 2575 ;;
2576 esac
7c9e70dd 2577 ;;
2578 esac
2579fi
5b7836cc 2580
614a23c6 2581
2582
2583# Extract the first word of "perl", so it can be a program name with args.
2584set dummy perl; ac_word=$2
cd9a469c 2585{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2586$as_echo_n "checking for $ac_word... " >&6; }
2587if test "${ac_cv_prog_PERL+set}" = set; then :
2588 $as_echo_n "(cached) " >&6
614a23c6 2589else
2590 if test -n "$PERL"; then
2591 ac_cv_prog_PERL="$PERL" # Let the user override the test.
2592else
a6089b1e 2593as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2594for as_dir in $PATH
2595do
2596 IFS=$as_save_IFS
2597 test -z "$as_dir" && as_dir=.
cd9a469c 2598 for ac_exec_ext in '' $ac_executable_extensions; do
2599 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
a6089b1e 2600 ac_cv_prog_PERL="perl"
cd9a469c 2601 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
a6089b1e 2602 break 2
2603 fi
2604done
cd9a469c 2605 done
2606IFS=$as_save_IFS
a6089b1e 2607
614a23c6 2608fi
2609fi
a6089b1e 2610PERL=$ac_cv_prog_PERL
614a23c6 2611if test -n "$PERL"; then
cd9a469c 2612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5
2613$as_echo "$PERL" >&6; }
614a23c6 2614else
cd9a469c 2615 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2616$as_echo "no" >&6; }
614a23c6 2617fi
2618
cd9a469c 2619
614a23c6 2620if test x"$PERL" = x""; then
2621 HAVE_PERL='#'
2622else
2623 HAVE_PERL=''
2624fi
2625
2626
f0a93313 2627# Make sure we can run config.sub.
cd9a469c 2628$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2629 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
2630
2631{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
2632$as_echo_n "checking build system type... " >&6; }
2633if test "${ac_cv_build+set}" = set; then :
2634 $as_echo_n "(cached) " >&6
2635else
2636 ac_build_alias=$build_alias
2637test "x$ac_build_alias" = x &&
2638 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2639test "x$ac_build_alias" = x &&
2640 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
2641ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2642 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
2643
2644fi
2645{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
2646$as_echo "$ac_cv_build" >&6; }
2647case $ac_cv_build in
2648*-*-*) ;;
2649*) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
2650esac
a6089b1e 2651build=$ac_cv_build
cd9a469c 2652ac_save_IFS=$IFS; IFS='-'
2653set x $ac_cv_build
2654shift
2655build_cpu=$1
2656build_vendor=$2
2657shift; shift
2658# Remember, the first character of IFS is used to create $*,
2659# except with old shells:
2660build_os=$*
2661IFS=$ac_save_IFS
2662case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
f0a93313 2663
2664
cd9a469c 2665{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
2666$as_echo_n "checking host system type... " >&6; }
2667if test "${ac_cv_host+set}" = set; then :
2668 $as_echo_n "(cached) " >&6
a6089b1e 2669else
cd9a469c 2670 if test "x$host_alias" = x; then
2671 ac_cv_host=$ac_cv_build
2672else
2673 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2674 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
2675fi
f0a93313 2676
a6089b1e 2677fi
cd9a469c 2678{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
2679$as_echo "$ac_cv_host" >&6; }
2680case $ac_cv_host in
2681*-*-*) ;;
2682*) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
2683esac
a6089b1e 2684host=$ac_cv_host
cd9a469c 2685ac_save_IFS=$IFS; IFS='-'
2686set x $ac_cv_host
2687shift
2688host_cpu=$1
2689host_vendor=$2
2690shift; shift
2691# Remember, the first character of IFS is used to create $*,
2692# except with old shells:
2693host_os=$*
2694IFS=$ac_save_IFS
2695case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
f0a93313 2696
f0a93313 2697
f0a93313 2698
f0a93313 2699
a6089b1e 2700if test -n "$ac_tool_prefix"; then
2701 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
f0a93313 2702set dummy ${ac_tool_prefix}ar; ac_word=$2
cd9a469c 2703{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2704$as_echo_n "checking for $ac_word... " >&6; }
2705if test "${ac_cv_prog_AR+set}" = set; then :
2706 $as_echo_n "(cached) " >&6
f0a93313 2707else
2708 if test -n "$AR"; then
2709 ac_cv_prog_AR="$AR" # Let the user override the test.
2710else
a6089b1e 2711as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2712for as_dir in $PATH
2713do
2714 IFS=$as_save_IFS
2715 test -z "$as_dir" && as_dir=.
cd9a469c 2716 for ac_exec_ext in '' $ac_executable_extensions; do
2717 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
a6089b1e 2718 ac_cv_prog_AR="${ac_tool_prefix}ar"
cd9a469c 2719 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
a6089b1e 2720 break 2
2721 fi
2722done
cd9a469c 2723 done
2724IFS=$as_save_IFS
a6089b1e 2725
f0a93313 2726fi
2727fi
a6089b1e 2728AR=$ac_cv_prog_AR
f0a93313 2729if test -n "$AR"; then
cd9a469c 2730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
2731$as_echo "$AR" >&6; }
f0a93313 2732else
cd9a469c 2733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2734$as_echo "no" >&6; }
a6089b1e 2735fi
2736
cd9a469c 2737
f0a93313 2738fi
a6089b1e 2739if test -z "$ac_cv_prog_AR"; then
2740 ac_ct_AR=$AR
2741 # Extract the first word of "ar", so it can be a program name with args.
2742set dummy ar; ac_word=$2
cd9a469c 2743{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2744$as_echo_n "checking for $ac_word... " >&6; }
2745if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
2746 $as_echo_n "(cached) " >&6
a6089b1e 2747else
2748 if test -n "$ac_ct_AR"; then
2749 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
2750else
2751as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2752for as_dir in $PATH
2753do
2754 IFS=$as_save_IFS
2755 test -z "$as_dir" && as_dir=.
cd9a469c 2756 for ac_exec_ext in '' $ac_executable_extensions; do
2757 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
a6089b1e 2758 ac_cv_prog_ac_ct_AR="ar"
cd9a469c 2759 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
a6089b1e 2760 break 2
2761 fi
2762done
cd9a469c 2763 done
2764IFS=$as_save_IFS
f0a93313 2765
a6089b1e 2766fi
2767fi
2768ac_ct_AR=$ac_cv_prog_ac_ct_AR
2769if test -n "$ac_ct_AR"; then
cd9a469c 2770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
2771$as_echo "$ac_ct_AR" >&6; }
a6089b1e 2772else
cd9a469c 2773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2774$as_echo "no" >&6; }
a6089b1e 2775fi
f0a93313 2776
cd9a469c 2777 if test "x$ac_ct_AR" = x; then
2778 AR=""
2779 else
2780 case $cross_compiling:$ac_tool_warned in
2781yes:)
2782{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2783$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2784ac_tool_warned=yes ;;
2785esac
2786 AR=$ac_ct_AR
2787 fi
a6089b1e 2788else
2789 AR="$ac_cv_prog_AR"
2790fi
f0a93313 2791
a6089b1e 2792if test -n "$ac_tool_prefix"; then
2793 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
f0a93313 2794set dummy ${ac_tool_prefix}ranlib; ac_word=$2
cd9a469c 2795{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2796$as_echo_n "checking for $ac_word... " >&6; }
2797if test "${ac_cv_prog_RANLIB+set}" = set; then :
2798 $as_echo_n "(cached) " >&6
f0a93313 2799else
2800 if test -n "$RANLIB"; then
2801 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
2802else
a6089b1e 2803as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2804for as_dir in $PATH
2805do
2806 IFS=$as_save_IFS
2807 test -z "$as_dir" && as_dir=.
cd9a469c 2808 for ac_exec_ext in '' $ac_executable_extensions; do
2809 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
a6089b1e 2810 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
cd9a469c 2811 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
a6089b1e 2812 break 2
2813 fi
2814done
cd9a469c 2815 done
2816IFS=$as_save_IFS
a6089b1e 2817
f0a93313 2818fi
2819fi
a6089b1e 2820RANLIB=$ac_cv_prog_RANLIB
f0a93313 2821if test -n "$RANLIB"; then
cd9a469c 2822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
2823$as_echo "$RANLIB" >&6; }
f0a93313 2824else
cd9a469c 2825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2826$as_echo "no" >&6; }
f0a93313 2827fi
2828
cd9a469c 2829
a6089b1e 2830fi
f0a93313 2831if test -z "$ac_cv_prog_RANLIB"; then
a6089b1e 2832 ac_ct_RANLIB=$RANLIB
f0a93313 2833 # Extract the first word of "ranlib", so it can be a program name with args.
2834set dummy ranlib; ac_word=$2
cd9a469c 2835{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2836$as_echo_n "checking for $ac_word... " >&6; }
2837if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
2838 $as_echo_n "(cached) " >&6
f0a93313 2839else
a6089b1e 2840 if test -n "$ac_ct_RANLIB"; then
2841 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
f0a93313 2842else
a6089b1e 2843as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2844for as_dir in $PATH
2845do
2846 IFS=$as_save_IFS
2847 test -z "$as_dir" && as_dir=.
cd9a469c 2848 for ac_exec_ext in '' $ac_executable_extensions; do
2849 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
a6089b1e 2850 ac_cv_prog_ac_ct_RANLIB="ranlib"
cd9a469c 2851 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
a6089b1e 2852 break 2
2853 fi
2854done
cd9a469c 2855 done
2856IFS=$as_save_IFS
a6089b1e 2857
f0a93313 2858fi
2859fi
a6089b1e 2860ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
2861if test -n "$ac_ct_RANLIB"; then
cd9a469c 2862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
2863$as_echo "$ac_ct_RANLIB" >&6; }
f0a93313 2864else
cd9a469c 2865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2866$as_echo "no" >&6; }
f0a93313 2867fi
2868
cd9a469c 2869 if test "x$ac_ct_RANLIB" = x; then
2870 RANLIB=":"
2871 else
2872 case $cross_compiling:$ac_tool_warned in
2873yes:)
2874{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2875$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2876ac_tool_warned=yes ;;
2877esac
2878 RANLIB=$ac_ct_RANLIB
2879 fi
f0a93313 2880else
a6089b1e 2881 RANLIB="$ac_cv_prog_RANLIB"
f0a93313 2882fi
2883
2884
b88bcfca 2885# Add --enable-multilib to configure.
2886# Default to --enable-multilib
cd9a469c 2887# Check whether --enable-multilib was given.
2888if test "${enable_multilib+set}" = set; then :
2889 enableval=$enable_multilib; case "$enableval" in
b88bcfca 2890 yes) multilib=yes ;;
2891 no) multilib=no ;;
cd9a469c 2892 *) as_fn_error "bad value $enableval for multilib option" "$LINENO" 5 ;;
b88bcfca 2893 esac
2894else
2895 multilib=yes
cd9a469c 2896fi
2897
b88bcfca 2898
2899# Even if the default multilib is not a cross compilation,
2900# it may be that some of the other multilibs are.
2901if test $cross_compiling = no && test $multilib = yes \
2902 && test "x${with_multisubdir}" != x ; then
2903 cross_compiling=maybe
2904fi
2905
d86ceed1 2906# We may wish to install the target headers somewhere.
2907{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to install libiberty headers and static library" >&5
2908$as_echo_n "checking whether to install libiberty headers and static library... " >&6; }
2909
2910# Check whether --enable-install-libiberty was given.
2911if test "${enable_install_libiberty+set}" = set; then :
2912 enableval=$enable_install_libiberty; enable_install_libiberty=$enableval
2913else
2914 enable_install_libiberty=no
2915fi
2916
2917# Option parsed, now set things appropriately.
2918case x"$enable_install_libiberty" in
2919 xyes|x)
2920 target_header_dir=libiberty
2921 ;;
2922 xno)
2923 target_header_dir=
2924 ;;
2925 *)
2926 # This could be sanity-checked in various ways...
2927 target_header_dir="${enable_install_libiberty}"
2928 ;;
2929esac
2930{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_install_libiberty" >&5
2931$as_echo "$enable_install_libiberty" >&6; }
2932{ $as_echo "$as_me:${as_lineno-$LINENO}: target_header_dir = $target_header_dir" >&5
2933$as_echo "$as_me: target_header_dir = $target_header_dir" >&6;}
2934
6d93ad38 2935
a6089b1e 2936ac_ext=c
2937ac_cpp='$CPP $CPPFLAGS'
2938ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2939ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2940ac_compiler_gnu=$ac_cv_c_compiler_gnu
2941if test -n "$ac_tool_prefix"; then
2942 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2943set dummy ${ac_tool_prefix}gcc; ac_word=$2
cd9a469c 2944{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2945$as_echo_n "checking for $ac_word... " >&6; }
2946if test "${ac_cv_prog_CC+set}" = set; then :
2947 $as_echo_n "(cached) " >&6
a6089b1e 2948else
2949 if test -n "$CC"; then
2950 ac_cv_prog_CC="$CC" # Let the user override the test.
2951else
2952as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2953for as_dir in $PATH
2954do
2955 IFS=$as_save_IFS
2956 test -z "$as_dir" && as_dir=.
cd9a469c 2957 for ac_exec_ext in '' $ac_executable_extensions; do
2958 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
a6089b1e 2959 ac_cv_prog_CC="${ac_tool_prefix}gcc"
cd9a469c 2960 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
a6089b1e 2961 break 2
2962 fi
2963done
cd9a469c 2964 done
2965IFS=$as_save_IFS
a6089b1e 2966
2967fi
2968fi
2969CC=$ac_cv_prog_CC
2970if test -n "$CC"; then
cd9a469c 2971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2972$as_echo "$CC" >&6; }
a6089b1e 2973else
cd9a469c 2974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2975$as_echo "no" >&6; }
a6089b1e 2976fi
2977
cd9a469c 2978
a6089b1e 2979fi
2980if test -z "$ac_cv_prog_CC"; then
2981 ac_ct_CC=$CC
2982 # Extract the first word of "gcc", so it can be a program name with args.
f0a93313 2983set dummy gcc; ac_word=$2
cd9a469c 2984{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2985$as_echo_n "checking for $ac_word... " >&6; }
2986if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
2987 $as_echo_n "(cached) " >&6
a6089b1e 2988else
2989 if test -n "$ac_ct_CC"; then
2990 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2991else
2992as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2993for as_dir in $PATH
2994do
2995 IFS=$as_save_IFS
2996 test -z "$as_dir" && as_dir=.
cd9a469c 2997 for ac_exec_ext in '' $ac_executable_extensions; do
2998 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
a6089b1e 2999 ac_cv_prog_ac_ct_CC="gcc"
cd9a469c 3000 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
a6089b1e 3001 break 2
3002 fi
3003done
cd9a469c 3004 done
3005IFS=$as_save_IFS
a6089b1e 3006
3007fi
3008fi
3009ac_ct_CC=$ac_cv_prog_ac_ct_CC
3010if test -n "$ac_ct_CC"; then
cd9a469c 3011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3012$as_echo "$ac_ct_CC" >&6; }
a6089b1e 3013else
cd9a469c 3014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3015$as_echo "no" >&6; }
a6089b1e 3016fi
3017
cd9a469c 3018 if test "x$ac_ct_CC" = x; then
3019 CC=""
3020 else
3021 case $cross_compiling:$ac_tool_warned in
3022yes:)
3023{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3024$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3025ac_tool_warned=yes ;;
3026esac
3027 CC=$ac_ct_CC
3028 fi
a6089b1e 3029else
3030 CC="$ac_cv_prog_CC"
3031fi
3032
3033if test -z "$CC"; then
cd9a469c 3034 if test -n "$ac_tool_prefix"; then
3035 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
a6089b1e 3036set dummy ${ac_tool_prefix}cc; ac_word=$2
cd9a469c 3037{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3038$as_echo_n "checking for $ac_word... " >&6; }
3039if test "${ac_cv_prog_CC+set}" = set; then :
3040 $as_echo_n "(cached) " >&6
f0a93313 3041else
3042 if test -n "$CC"; then
3043 ac_cv_prog_CC="$CC" # Let the user override the test.
3044else
a6089b1e 3045as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3046for as_dir in $PATH
3047do
3048 IFS=$as_save_IFS
3049 test -z "$as_dir" && as_dir=.
cd9a469c 3050 for ac_exec_ext in '' $ac_executable_extensions; do
3051 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
a6089b1e 3052 ac_cv_prog_CC="${ac_tool_prefix}cc"
cd9a469c 3053 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
a6089b1e 3054 break 2
3055 fi
3056done
cd9a469c 3057 done
3058IFS=$as_save_IFS
a6089b1e 3059
f0a93313 3060fi
3061fi
a6089b1e 3062CC=$ac_cv_prog_CC
f0a93313 3063if test -n "$CC"; then
cd9a469c 3064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3065$as_echo "$CC" >&6; }
f0a93313 3066else
cd9a469c 3067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3068$as_echo "no" >&6; }
f0a93313 3069fi
3070
a6089b1e 3071
cd9a469c 3072 fi
a6089b1e 3073fi
f0a93313 3074if test -z "$CC"; then
3075 # Extract the first word of "cc", so it can be a program name with args.
3076set dummy cc; ac_word=$2
cd9a469c 3077{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3078$as_echo_n "checking for $ac_word... " >&6; }
3079if test "${ac_cv_prog_CC+set}" = set; then :
3080 $as_echo_n "(cached) " >&6
f0a93313 3081else
3082 if test -n "$CC"; then
3083 ac_cv_prog_CC="$CC" # Let the user override the test.
3084else
f0a93313 3085 ac_prog_rejected=no
a6089b1e 3086as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3087for as_dir in $PATH
3088do
3089 IFS=$as_save_IFS
3090 test -z "$as_dir" && as_dir=.
cd9a469c 3091 for ac_exec_ext in '' $ac_executable_extensions; do
3092 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
a6089b1e 3093 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3094 ac_prog_rejected=yes
3095 continue
3096 fi
3097 ac_cv_prog_CC="cc"
cd9a469c 3098 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
a6089b1e 3099 break 2
3100 fi
3101done
cd9a469c 3102 done
3103IFS=$as_save_IFS
a6089b1e 3104
f0a93313 3105if test $ac_prog_rejected = yes; then
3106 # We found a bogon in the path, so make sure we never use it.
3107 set dummy $ac_cv_prog_CC
3108 shift
a6089b1e 3109 if test $# != 0; then
f0a93313 3110 # We chose a different compiler from the bogus one.
3111 # However, it has the same basename, so the bogon will be chosen
3112 # first if we set CC to just the basename; use the full file name.
3113 shift
a6089b1e 3114 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
f0a93313 3115 fi
3116fi
3117fi
3118fi
a6089b1e 3119CC=$ac_cv_prog_CC
f0a93313 3120if test -n "$CC"; then
cd9a469c 3121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3122$as_echo "$CC" >&6; }
f0a93313 3123else
cd9a469c 3124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3125$as_echo "no" >&6; }
f0a93313 3126fi
3127
cd9a469c 3128
f0a93313 3129fi
a6089b1e 3130if test -z "$CC"; then
3131 if test -n "$ac_tool_prefix"; then
cd9a469c 3132 for ac_prog in cl.exe
a6089b1e 3133 do
3134 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3135set dummy $ac_tool_prefix$ac_prog; ac_word=$2
cd9a469c 3136{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3137$as_echo_n "checking for $ac_word... " >&6; }
3138if test "${ac_cv_prog_CC+set}" = set; then :
3139 $as_echo_n "(cached) " >&6
f0a93313 3140else
a6089b1e 3141 if test -n "$CC"; then
3142 ac_cv_prog_CC="$CC" # Let the user override the test.
f0a93313 3143else
a6089b1e 3144as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3145for as_dir in $PATH
3146do
3147 IFS=$as_save_IFS
3148 test -z "$as_dir" && as_dir=.
cd9a469c 3149 for ac_exec_ext in '' $ac_executable_extensions; do
3150 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
a6089b1e 3151 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
cd9a469c 3152 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
a6089b1e 3153 break 2
3154 fi
3155done
cd9a469c 3156 done
3157IFS=$as_save_IFS
a6089b1e 3158
f0a93313 3159fi
3160fi
a6089b1e 3161CC=$ac_cv_prog_CC
3162if test -n "$CC"; then
cd9a469c 3163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3164$as_echo "$CC" >&6; }
f0a93313 3165else
cd9a469c 3166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3167$as_echo "no" >&6; }
f0a93313 3168fi
f0a93313 3169
cd9a469c 3170
a6089b1e 3171 test -n "$CC" && break
3172 done
f0a93313 3173fi
a6089b1e 3174if test -z "$CC"; then
3175 ac_ct_CC=$CC
cd9a469c 3176 for ac_prog in cl.exe
a6089b1e 3177do
3178 # Extract the first word of "$ac_prog", so it can be a program name with args.
3179set dummy $ac_prog; ac_word=$2
cd9a469c 3180{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3181$as_echo_n "checking for $ac_word... " >&6; }
3182if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
3183 $as_echo_n "(cached) " >&6
a6089b1e 3184else
3185 if test -n "$ac_ct_CC"; then
3186 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3187else
3188as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3189for as_dir in $PATH
3190do
3191 IFS=$as_save_IFS
3192 test -z "$as_dir" && as_dir=.
cd9a469c 3193 for ac_exec_ext in '' $ac_executable_extensions; do
3194 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
a6089b1e 3195 ac_cv_prog_ac_ct_CC="$ac_prog"
cd9a469c 3196 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
a6089b1e 3197 break 2
f0a93313 3198 fi
a6089b1e 3199done
cd9a469c 3200 done
3201IFS=$as_save_IFS
a6089b1e 3202
3203fi
3204fi
3205ac_ct_CC=$ac_cv_prog_ac_ct_CC
3206if test -n "$ac_ct_CC"; then
cd9a469c 3207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3208$as_echo "$ac_ct_CC" >&6; }
f0a93313 3209else
cd9a469c 3210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3211$as_echo "no" >&6; }
f0a93313 3212fi
3213
cd9a469c 3214
a6089b1e 3215 test -n "$ac_ct_CC" && break
3216done
f0a93313 3217
cd9a469c 3218 if test "x$ac_ct_CC" = x; then
3219 CC=""
3220 else
3221 case $cross_compiling:$ac_tool_warned in
3222yes:)
3223{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3224$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3225ac_tool_warned=yes ;;
3226esac
3227 CC=$ac_ct_CC
3228 fi
a6089b1e 3229fi
3230
3231fi
3232
3233
cd9a469c 3234test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3235$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3236as_fn_error "no acceptable C compiler found in \$PATH
3237See \`config.log' for more details." "$LINENO" 5; }
a6089b1e 3238
3239# Provide some information about the compiler.
cd9a469c 3240$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3241set X $ac_compile
3242ac_compiler=$2
3243for ac_option in --version -v -V -qversion; do
3244 { { ac_try="$ac_compiler $ac_option >&5"
3245case "(($ac_try" in
3246 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3247 *) ac_try_echo=$ac_try;;
3248esac
3249eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3250$as_echo "$ac_try_echo"; } >&5
3251 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
a6089b1e 3252 ac_status=$?
cd9a469c 3253 if test -s conftest.err; then
3254 sed '10a\
3255... rest of stderr output deleted ...
3256 10q' conftest.err >conftest.er1
3257 cat conftest.er1 >&5
3258 rm -f conftest.er1 conftest.err
3259 fi
3260 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3261 test $ac_status = 0; }
3262done
a6089b1e 3263
cd9a469c 3264cat confdefs.h - <<_ACEOF >conftest.$ac_ext
a6089b1e 3265/* end confdefs.h. */
ec255163 3266
a6089b1e 3267int
3268main ()
3269{
3270
3271 ;
3272 return 0;
3273}
3274_ACEOF
3275# FIXME: Cleanup?
cd9a469c 3276if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
a6089b1e 3277 (eval $ac_link) 2>&5
3278 ac_status=$?
cd9a469c 3279 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3280 test $ac_status = 0; }; then :
a6089b1e 3281 gcc_no_link=no
3282else
3283 gcc_no_link=yes
3284fi
a6089b1e 3285if test x$gcc_no_link = xyes; then
3286 # Setting cross_compile will disable run tests; it will
3287 # also disable AC_CHECK_FILE but that's generally
3288 # correct if we can't link.
3289 cross_compiling=yes
3290 EXEEXT=
3291else
cd9a469c 3292 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
a6089b1e 3293/* end confdefs.h. */
3294
3295int
3296main ()
3297{
3298
3299 ;
3300 return 0;
3301}
3302_ACEOF
3303ac_clean_files_save=$ac_clean_files
cd9a469c 3304ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out conftest.out"
a6089b1e 3305# Try to create an executable without -o first, disregard a.out.
3306# It will help us diagnose broken compilers, and finding out an intuition
3307# of exeext.
cd9a469c 3308{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3309$as_echo_n "checking for C compiler default output file name... " >&6; }
3310ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3311
3312# The possible output files:
3313ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3314
3315ac_rmfiles=
3316for ac_file in $ac_files
3317do
3318 case $ac_file in
3319 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3320 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3321 esac
3322done
3323rm -f $ac_rmfiles
3324
3325if { { ac_try="$ac_link_default"
3326case "(($ac_try" in
3327 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3328 *) ac_try_echo=$ac_try;;
3329esac
3330eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3331$as_echo "$ac_try_echo"; } >&5
3332 (eval "$ac_link_default") 2>&5
3333 ac_status=$?
3334 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3335 test $ac_status = 0; }; then :
3336 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3337# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3338# in a Makefile. We should not override ac_cv_exeext if it was cached,
3339# so that the user can short-circuit this test for compilers unknown to
3340# Autoconf.
3341for ac_file in $ac_files ''
a6089b1e 3342do
3343 test -f "$ac_file" || continue
3344 case $ac_file in
cd9a469c 3345 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
ac09b42b 3346 ;;
a6089b1e 3347 [ab].out )
ac09b42b 3348 # We found the default executable, but exeext='' is most
3349 # certainly right.
3350 break;;
a6089b1e 3351 *.* )
cd9a469c 3352 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3353 then :; else
3354 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3355 fi
3356 # We set ac_cv_exeext here because the later test for it is not
3357 # safe: cross compilers may not add the suffix if given an `-o'
3358 # argument, so we may need to know it at that point already.
3359 # Even if this section looks crufty: it has the advantage of
3360 # actually working.
ac09b42b 3361 break;;
a6089b1e 3362 * )
ac09b42b 3363 break;;
a6089b1e 3364 esac
3365done
cd9a469c 3366test "$ac_cv_exeext" = no && ac_cv_exeext=
3367
b2835908 3368else
cd9a469c 3369 ac_file=''
3370fi
3371{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3372$as_echo "$ac_file" >&6; }
3373if test -z "$ac_file"; then :
3374 $as_echo "$as_me: failed program was:" >&5
a6089b1e 3375sed 's/^/| /' conftest.$ac_ext >&5
3376
cd9a469c 3377{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3378$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3379{ as_fn_set_status 77
3380as_fn_error "C compiler cannot create executables
3381See \`config.log' for more details." "$LINENO" 5; }; }
a6089b1e 3382fi
a6089b1e 3383ac_exeext=$ac_cv_exeext
a6089b1e 3384
cd9a469c 3385# Check that the compiler produces executables we can run. If not, either
a6089b1e 3386# the compiler is broken, or we cross compile.
cd9a469c 3387{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3388$as_echo_n "checking whether the C compiler works... " >&6; }
a6089b1e 3389# If not cross compiling, check that we can run a simple program.
3390if test "$cross_compiling" != yes; then
3391 if { ac_try='./$ac_file'
cd9a469c 3392 { { case "(($ac_try" in
3393 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3394 *) ac_try_echo=$ac_try;;
3395esac
3396eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3397$as_echo "$ac_try_echo"; } >&5
3398 (eval "$ac_try") 2>&5
a6089b1e 3399 ac_status=$?
cd9a469c 3400 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3401 test $ac_status = 0; }; }; then
a6089b1e 3402 cross_compiling=no
3403 else
3404 if test "$cross_compiling" = maybe; then
3405 cross_compiling=yes
3406 else
cd9a469c 3407 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3408$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3409as_fn_error "cannot run C compiled programs.
a6089b1e 3410If you meant to cross compile, use \`--host'.
cd9a469c 3411See \`config.log' for more details." "$LINENO" 5; }
b2835908 3412 fi
3413 fi
a6089b1e 3414fi
cd9a469c 3415{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3416$as_echo "yes" >&6; }
a6089b1e 3417
cd9a469c 3418rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out conftest.out
a6089b1e 3419ac_clean_files=$ac_clean_files_save
cd9a469c 3420# Check that the compiler produces executables we can run. If not, either
a6089b1e 3421# the compiler is broken, or we cross compile.
cd9a469c 3422{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3423$as_echo_n "checking whether we are cross compiling... " >&6; }
3424{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3425$as_echo "$cross_compiling" >&6; }
3426
3427{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3428$as_echo_n "checking for suffix of executables... " >&6; }
3429if { { ac_try="$ac_link"
3430case "(($ac_try" in
3431 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3432 *) ac_try_echo=$ac_try;;
3433esac
3434eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3435$as_echo "$ac_try_echo"; } >&5
3436 (eval "$ac_link") 2>&5
a6089b1e 3437 ac_status=$?
cd9a469c 3438 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3439 test $ac_status = 0; }; then :
a6089b1e 3440 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3441# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3442# work properly (i.e., refer to `conftest.exe'), while it won't with
3443# `rm'.
3444for ac_file in conftest.exe conftest conftest.*; do
3445 test -f "$ac_file" || continue
3446 case $ac_file in
cd9a469c 3447 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
a6089b1e 3448 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
ac09b42b 3449 break;;
a6089b1e 3450 * ) break;;
3451 esac
3452done
b2835908 3453else
cd9a469c 3454 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3455$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3456as_fn_error "cannot compute suffix of executables: cannot compile and link
3457See \`config.log' for more details." "$LINENO" 5; }
b2835908 3458fi
a6089b1e 3459rm -f conftest$ac_cv_exeext
cd9a469c 3460{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3461$as_echo "$ac_cv_exeext" >&6; }
a6089b1e 3462
3463rm -f conftest.$ac_ext
3464EXEEXT=$ac_cv_exeext
3465ac_exeext=$EXEEXT
b2835908 3466fi
cd9a469c 3467{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3468$as_echo_n "checking for suffix of object files... " >&6; }
3469if test "${ac_cv_objext+set}" = set; then :
3470 $as_echo_n "(cached) " >&6
b2835908 3471else
cd9a469c 3472 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
a6089b1e 3473/* end confdefs.h. */
b2835908 3474
a6089b1e 3475int
3476main ()
3477{
b2835908 3478
a6089b1e 3479 ;
3480 return 0;
3481}
3482_ACEOF
3483rm -f conftest.o conftest.obj
cd9a469c 3484if { { ac_try="$ac_compile"
3485case "(($ac_try" in
3486 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3487 *) ac_try_echo=$ac_try;;
3488esac
3489eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3490$as_echo "$ac_try_echo"; } >&5
3491 (eval "$ac_compile") 2>&5
3492 ac_status=$?
3493 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3494 test $ac_status = 0; }; then :
3495 for ac_file in conftest.o conftest.obj conftest.*; do
3496 test -f "$ac_file" || continue;
a6089b1e 3497 case $ac_file in
cd9a469c 3498 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
a6089b1e 3499 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3500 break;;
3501 esac
3502done
b2835908 3503else
cd9a469c 3504 $as_echo "$as_me: failed program was:" >&5
a6089b1e 3505sed 's/^/| /' conftest.$ac_ext >&5
3506
cd9a469c 3507{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3508$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3509as_fn_error "cannot compute suffix of object files: cannot compile
3510See \`config.log' for more details." "$LINENO" 5; }
a6089b1e 3511fi
a6089b1e 3512rm -f conftest.$ac_cv_objext conftest.$ac_ext
b2835908 3513fi
cd9a469c 3514{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3515$as_echo "$ac_cv_objext" >&6; }
a6089b1e 3516OBJEXT=$ac_cv_objext
3517ac_objext=$OBJEXT
cd9a469c 3518{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3519$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3520if test "${ac_cv_c_compiler_gnu+set}" = set; then :
3521 $as_echo_n "(cached) " >&6
a6089b1e 3522else
cd9a469c 3523 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
a6089b1e 3524/* end confdefs.h. */
3525
3526int
3527main ()
3528{
3529#ifndef __GNUC__
3530 choke me
3531#endif
b2835908 3532
a6089b1e 3533 ;
3534 return 0;
3535}
3536_ACEOF
cd9a469c 3537if ac_fn_c_try_compile "$LINENO"; then :
a6089b1e 3538 ac_compiler_gnu=yes
3539else
cd9a469c 3540 ac_compiler_gnu=no
a6089b1e 3541fi
cd9a469c 3542rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
a6089b1e 3543ac_cv_c_compiler_gnu=$ac_compiler_gnu
3544
3545fi
cd9a469c 3546{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3547$as_echo "$ac_cv_c_compiler_gnu" >&6; }
3548if test $ac_compiler_gnu = yes; then
3549 GCC=yes
3550else
3551 GCC=
3552fi
a6089b1e 3553ac_test_CFLAGS=${CFLAGS+set}
3554ac_save_CFLAGS=$CFLAGS
cd9a469c 3555{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3556$as_echo_n "checking whether $CC accepts -g... " >&6; }
3557if test "${ac_cv_prog_cc_g+set}" = set; then :
3558 $as_echo_n "(cached) " >&6
3559else
3560 ac_save_c_werror_flag=$ac_c_werror_flag
3561 ac_c_werror_flag=yes
3562 ac_cv_prog_cc_g=no
3563 CFLAGS="-g"
3564 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
a6089b1e 3565/* end confdefs.h. */
b2835908 3566
a6089b1e 3567int
3568main ()
3569{
b2835908 3570
a6089b1e 3571 ;
3572 return 0;
3573}
3574_ACEOF
cd9a469c 3575if ac_fn_c_try_compile "$LINENO"; then :
a6089b1e 3576 ac_cv_prog_cc_g=yes
3577else
cd9a469c 3578 CFLAGS=""
3579 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3580/* end confdefs.h. */
3581
3582int
3583main ()
3584{
3585
3586 ;
3587 return 0;
3588}
3589_ACEOF
3590if ac_fn_c_try_compile "$LINENO"; then :
3591
3592else
3593 ac_c_werror_flag=$ac_save_c_werror_flag
3594 CFLAGS="-g"
3595 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3596/* end confdefs.h. */
3597
3598int
3599main ()
3600{
f0a93313 3601
cd9a469c 3602 ;
3603 return 0;
3604}
3605_ACEOF
3606if ac_fn_c_try_compile "$LINENO"; then :
3607 ac_cv_prog_cc_g=yes
3608fi
3609rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
a6089b1e 3610fi
cd9a469c 3611rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
a6089b1e 3612fi
cd9a469c 3613rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3614 ac_c_werror_flag=$ac_save_c_werror_flag
3615fi
3616{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3617$as_echo "$ac_cv_prog_cc_g" >&6; }
a6089b1e 3618if test "$ac_test_CFLAGS" = set; then
3619 CFLAGS=$ac_save_CFLAGS
3620elif test $ac_cv_prog_cc_g = yes; then
f0a93313 3621 if test "$GCC" = yes; then
a6089b1e 3622 CFLAGS="-g -O2"
f0a93313 3623 else
a6089b1e 3624 CFLAGS="-g"
f0a93313 3625 fi
3626else
a6089b1e 3627 if test "$GCC" = yes; then
3628 CFLAGS="-O2"
3629 else
3630 CFLAGS=
3631 fi
f0a93313 3632fi
cd9a469c 3633{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3634$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3635if test "${ac_cv_prog_cc_c89+set}" = set; then :
3636 $as_echo_n "(cached) " >&6
a6089b1e 3637else
cd9a469c 3638 ac_cv_prog_cc_c89=no
a6089b1e 3639ac_save_CC=$CC
cd9a469c 3640cat confdefs.h - <<_ACEOF >conftest.$ac_ext
a6089b1e 3641/* end confdefs.h. */
3642#include <stdarg.h>
3643#include <stdio.h>
3644#include <sys/types.h>
3645#include <sys/stat.h>
3646/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3647struct buf { int x; };
3648FILE * (*rcsopen) (struct buf *, struct stat *, int);
3649static char *e (p, i)
3650 char **p;
3651 int i;
3652{
3653 return p[i];
ec255163 3654}
a6089b1e 3655static char *f (char * (*g) (char **, int), char **p, ...)
3656{
3657 char *s;
3658 va_list v;
3659 va_start (v,p);
3660 s = g (p, va_arg (v,int));
3661 va_end (v);
3662 return s;
ec255163 3663}
ac09b42b 3664
3665/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3666 function prototypes and stuff, but not '\xHH' hex character constants.
3667 These don't provoke an error unfortunately, instead are silently treated
cd9a469c 3668 as 'x'. The following induces an error, until -std is added to get
ac09b42b 3669 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3670 array size at least. It's necessary to write '\x00'==0 to get something
cd9a469c 3671 that's true only with -std. */
ac09b42b 3672int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3673
cd9a469c 3674/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3675 inside strings and character constants. */
3676#define FOO(x) 'x'
3677int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3678
a6089b1e 3679int test (int i, double x);
3680struct s1 {int (*f) (int a);};
3681struct s2 {int (*f) (double a);};
3682int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3683int argc;
3684char **argv;
3685int
3686main ()
3687{
3688return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3689 ;
3690 return 0;
ec255163 3691}
a6089b1e 3692_ACEOF
cd9a469c 3693for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3694 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
a6089b1e 3695do
3696 CC="$ac_save_CC $ac_arg"
cd9a469c 3697 if ac_fn_c_try_compile "$LINENO"; then :
3698 ac_cv_prog_cc_c89=$ac_arg
a6089b1e 3699fi
cd9a469c 3700rm -f core conftest.err conftest.$ac_objext
3701 test "x$ac_cv_prog_cc_c89" != "xno" && break
a6089b1e 3702done
cd9a469c 3703rm -f conftest.$ac_ext
a6089b1e 3704CC=$ac_save_CC
3705
3706fi
cd9a469c 3707# AC_CACHE_VAL
3708case "x$ac_cv_prog_cc_c89" in
3709 x)
3710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3711$as_echo "none needed" >&6; } ;;
3712 xno)
3713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3714$as_echo "unsupported" >&6; } ;;
a6089b1e 3715 *)
cd9a469c 3716 CC="$CC $ac_cv_prog_cc_c89"
3717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3718$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
a6089b1e 3719esac
cd9a469c 3720if test "x$ac_cv_prog_cc_c89" != xno; then :
a6089b1e 3721
a6089b1e 3722fi
3723
a6089b1e 3724ac_ext=c
3725ac_cpp='$CPP $CPPFLAGS'
3726ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3727ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3728ac_compiler_gnu=$ac_cv_c_compiler_gnu
3729
0a8f1add 3730
19ecc7c1 3731ac_ext=c
3732ac_cpp='$CPP $CPPFLAGS'
3733ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3734ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3735ac_compiler_gnu=$ac_cv_c_compiler_gnu
3736{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
3737$as_echo_n "checking how to run the C preprocessor... " >&6; }
3738# On Suns, sometimes $CPP names a directory.
3739if test -n "$CPP" && test -d "$CPP"; then
3740 CPP=
cd9a469c 3741fi
19ecc7c1 3742if test -z "$CPP"; then
3743 if test "${ac_cv_prog_CPP+set}" = set; then :
cd9a469c 3744 $as_echo_n "(cached) " >&6
0a8f1add 3745else
19ecc7c1 3746 # Double quotes because CPP needs to be expanded
3747 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3748 do
3749 ac_preproc_ok=false
3750for ac_c_preproc_warn_flag in '' yes
3751do
3752 # Use a header file that comes with gcc, so configuring glibc
3753 # with a fresh cross-compiler works.
3754 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3755 # <limits.h> exists even on freestanding compilers.
3756 # On the NeXT, cc -E runs the code through the compiler's parser,
3757 # not just through cpp. "Syntax error" is here to catch this case.
3758 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
0a8f1add 3759/* end confdefs.h. */
19ecc7c1 3760#ifdef __STDC__
3761# include <limits.h>
3762#else
3763# include <assert.h>
3764#endif
3765 Syntax error
0a8f1add 3766_ACEOF
19ecc7c1 3767if ac_fn_c_try_cpp "$LINENO"; then :
3768
3769else
3770 # Broken: fails on valid input.
3771continue
0a8f1add 3772fi
19ecc7c1 3773rm -f conftest.err conftest.$ac_ext
3774
3775 # OK, works on sane cases. Now check whether nonexistent headers
3776 # can be detected and how.
3777 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3778/* end confdefs.h. */
3779#include <ac_nonexistent.h>
3780_ACEOF
3781if ac_fn_c_try_cpp "$LINENO"; then :
3782 # Broken: success on invalid input.
3783continue
3784else
3785 # Passes both tests.
3786ac_preproc_ok=:
3787break
0a8f1add 3788fi
19ecc7c1 3789rm -f conftest.err conftest.$ac_ext
3790
3791done
3792# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3793rm -f conftest.err conftest.$ac_ext
3794if $ac_preproc_ok; then :
3795 break
0a8f1add 3796fi
0a8f1add 3797
19ecc7c1 3798 done
3799 ac_cv_prog_CPP=$CPP
3800
3801fi
3802 CPP=$ac_cv_prog_CPP
0a8f1add 3803else
19ecc7c1 3804 ac_cv_prog_CPP=$CPP
3805fi
3806{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
3807$as_echo "$CPP" >&6; }
3808ac_preproc_ok=false
3809for ac_c_preproc_warn_flag in '' yes
3810do
3811 # Use a header file that comes with gcc, so configuring glibc
3812 # with a fresh cross-compiler works.
3813 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3814 # <limits.h> exists even on freestanding compilers.
3815 # On the NeXT, cc -E runs the code through the compiler's parser,
3816 # not just through cpp. "Syntax error" is here to catch this case.
cd9a469c 3817 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
0a8f1add 3818/* end confdefs.h. */
19ecc7c1 3819#ifdef __STDC__
3820# include <limits.h>
3821#else
3822# include <assert.h>
3823#endif
3824 Syntax error
0a8f1add 3825_ACEOF
19ecc7c1 3826if ac_fn_c_try_cpp "$LINENO"; then :
3827
3828else
3829 # Broken: fails on valid input.
3830continue
0a8f1add 3831fi
19ecc7c1 3832rm -f conftest.err conftest.$ac_ext
3833
3834 # OK, works on sane cases. Now check whether nonexistent headers
3835 # can be detected and how.
cd9a469c 3836 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
0a8f1add 3837/* end confdefs.h. */
19ecc7c1 3838#include <ac_nonexistent.h>
90305aaf 3839_ACEOF
cd9a469c 3840if ac_fn_c_try_cpp "$LINENO"; then :
90305aaf 3841 # Broken: success on invalid input.
3842continue
3843else
90305aaf 3844 # Passes both tests.
3845ac_preproc_ok=:
3846break
3847fi
3848rm -f conftest.err conftest.$ac_ext
3849
3850done
3851# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3852rm -f conftest.err conftest.$ac_ext
cd9a469c 3853if $ac_preproc_ok; then :
3854
90305aaf 3855else
cd9a469c 3856 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3857$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3858as_fn_error "C preprocessor \"$CPP\" fails sanity check
3859See \`config.log' for more details." "$LINENO" 5; }
90305aaf 3860fi
3861
3862ac_ext=c
3863ac_cpp='$CPP $CPPFLAGS'
3864ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3865ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3866ac_compiler_gnu=$ac_cv_c_compiler_gnu
3867
3868
19ecc7c1 3869{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
3870$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
3871if test "${ac_cv_path_GREP+set}" = set; then :
cd9a469c 3872 $as_echo_n "(cached) " >&6
ecefb1e5 3873else
19ecc7c1 3874 if test -z "$GREP"; then
3875 ac_path_GREP_found=false
3876 # Loop through the user's path and test for each of PROGNAME-LIST
3877 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3878for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3879do
3880 IFS=$as_save_IFS
3881 test -z "$as_dir" && as_dir=.
3882 for ac_prog in grep ggrep; do
3883 for ac_exec_ext in '' $ac_executable_extensions; do
3884 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
3885 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
3886# Check for GNU ac_path_GREP and select it if it is found.
3887 # Check for GNU $ac_path_GREP
3888case `"$ac_path_GREP" --version 2>&1` in
3889*GNU*)
3890 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
3891*)
3892 ac_count=0
3893 $as_echo_n 0123456789 >"conftest.in"
3894 while :
3895 do
3896 cat "conftest.in" "conftest.in" >"conftest.tmp"
3897 mv "conftest.tmp" "conftest.in"
3898 cp "conftest.in" "conftest.nl"
3899 $as_echo 'GREP' >> "conftest.nl"
3900 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3901 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3902 as_fn_arith $ac_count + 1 && ac_count=$as_val
3903 if test $ac_count -gt ${ac_path_GREP_max-0}; then
3904 # Best one so far, save it but keep looking for a better one
3905 ac_cv_path_GREP="$ac_path_GREP"
3906 ac_path_GREP_max=$ac_count
3907 fi
3908 # 10*(2^10) chars as input seems more than enough
3909 test $ac_count -gt 10 && break
3910 done
3911 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3912esac
3913
3914 $ac_path_GREP_found && break 3
3915 done
3916 done
3917 done
3918IFS=$as_save_IFS
3919 if test -z "$ac_cv_path_GREP"; then
3920 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3921 fi
f07d7f0f 3922else
19ecc7c1 3923 ac_cv_path_GREP=$GREP
3924fi
3925
3926fi
3927{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
3928$as_echo "$ac_cv_path_GREP" >&6; }
3929 GREP="$ac_cv_path_GREP"
3930
3931
3932{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
3933$as_echo_n "checking for egrep... " >&6; }
3934if test "${ac_cv_path_EGREP+set}" = set; then :
3935 $as_echo_n "(cached) " >&6
3936else
3937 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
3938 then ac_cv_path_EGREP="$GREP -E"
3939 else
3940 if test -z "$EGREP"; then
3941 ac_path_EGREP_found=false
3942 # Loop through the user's path and test for each of PROGNAME-LIST
3943 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3944for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3945do
3946 IFS=$as_save_IFS
3947 test -z "$as_dir" && as_dir=.
3948 for ac_prog in egrep; do
3949 for ac_exec_ext in '' $ac_executable_extensions; do
3950 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
3951 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
3952# Check for GNU ac_path_EGREP and select it if it is found.
3953 # Check for GNU $ac_path_EGREP
3954case `"$ac_path_EGREP" --version 2>&1` in
3955*GNU*)
3956 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
3957*)
3958 ac_count=0
3959 $as_echo_n 0123456789 >"conftest.in"
3960 while :
3961 do
3962 cat "conftest.in" "conftest.in" >"conftest.tmp"
3963 mv "conftest.tmp" "conftest.in"
3964 cp "conftest.in" "conftest.nl"
3965 $as_echo 'EGREP' >> "conftest.nl"
3966 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3967 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3968 as_fn_arith $ac_count + 1 && ac_count=$as_val
3969 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
3970 # Best one so far, save it but keep looking for a better one
3971 ac_cv_path_EGREP="$ac_path_EGREP"
3972 ac_path_EGREP_max=$ac_count
3973 fi
3974 # 10*(2^10) chars as input seems more than enough
3975 test $ac_count -gt 10 && break
3976 done
3977 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3978esac
3979
3980 $ac_path_EGREP_found && break 3
3981 done
3982 done
3983 done
3984IFS=$as_save_IFS
3985 if test -z "$ac_cv_path_EGREP"; then
3986 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3987 fi
3988else
3989 ac_cv_path_EGREP=$EGREP
3990fi
3991
3992 fi
3993fi
3994{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
3995$as_echo "$ac_cv_path_EGREP" >&6; }
3996 EGREP="$ac_cv_path_EGREP"
3997
3998
3999{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4000$as_echo_n "checking for ANSI C header files... " >&6; }
4001if test "${ac_cv_header_stdc+set}" = set; then :
4002 $as_echo_n "(cached) " >&6
4003else
4004 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
f07d7f0f 4005/* end confdefs.h. */
19ecc7c1 4006#include <stdlib.h>
4007#include <stdarg.h>
4008#include <string.h>
4009#include <float.h>
f07d7f0f 4010
4011int
4012main ()
4013{
4014
4015 ;
4016 return 0;
4017}
4018_ACEOF
cd9a469c 4019if ac_fn_c_try_compile "$LINENO"; then :
19ecc7c1 4020 ac_cv_header_stdc=yes
f07d7f0f 4021else
19ecc7c1 4022 ac_cv_header_stdc=no
f07d7f0f 4023fi
cd9a469c 4024rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19ecc7c1 4025
4026if test $ac_cv_header_stdc = yes; then
4027 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4028 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4029/* end confdefs.h. */
4030#include <string.h>
4031
4032_ACEOF
4033if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4034 $EGREP "memchr" >/dev/null 2>&1; then :
4035
4036else
4037 ac_cv_header_stdc=no
f07d7f0f 4038fi
19ecc7c1 4039rm -f conftest*
f07d7f0f 4040
f07d7f0f 4041fi
4042
19ecc7c1 4043if test $ac_cv_header_stdc = yes; then
4044 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4045 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4046/* end confdefs.h. */
4047#include <stdlib.h>
4048
4049_ACEOF
4050if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4051 $EGREP "free" >/dev/null 2>&1; then :
f07d7f0f 4052
a1ba1d98 4053else
19ecc7c1 4054 ac_cv_header_stdc=no
a1ba1d98 4055fi
19ecc7c1 4056rm -f conftest*
4057
4058fi
4059
4060if test $ac_cv_header_stdc = yes; then
4061 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4062 if test "$cross_compiling" = yes; then :
4063 :
a1ba1d98 4064else
cd9a469c 4065 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
a1ba1d98 4066/* end confdefs.h. */
19ecc7c1 4067#include <ctype.h>
4068#include <stdlib.h>
4069#if ((' ' & 0x0FF) == 0x020)
4070# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4071# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4072#else
4073# define ISLOWER(c) \
4074 (('a' <= (c) && (c) <= 'i') \
4075 || ('j' <= (c) && (c) <= 'r') \
4076 || ('s' <= (c) && (c) <= 'z'))
4077# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4078#endif
a1ba1d98 4079
19ecc7c1 4080#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
a1ba1d98 4081int
4082main ()
4083{
19ecc7c1 4084 int i;
4085 for (i = 0; i < 256; i++)
4086 if (XOR (islower (i), ISLOWER (i))
4087 || toupper (i) != TOUPPER (i))
4088 return 2;
a1ba1d98 4089 return 0;
4090}
4091_ACEOF
19ecc7c1 4092if ac_fn_c_try_run "$LINENO"; then :
4093
a1ba1d98 4094else
19ecc7c1 4095 ac_cv_header_stdc=no
4096fi
4097rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4098 conftest.$ac_objext conftest.beam conftest.$ac_ext
a1ba1d98 4099fi
a1ba1d98 4100
4101fi
19ecc7c1 4102fi
4103{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4104$as_echo "$ac_cv_header_stdc" >&6; }
4105if test $ac_cv_header_stdc = yes; then
a1ba1d98 4106
19ecc7c1 4107$as_echo "#define STDC_HEADERS 1" >>confdefs.h
a1ba1d98 4108
4109fi
4110
19ecc7c1 4111# On IRIX 5.3, sys/types and inttypes.h are conflicting.
4112for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4113 inttypes.h stdint.h unistd.h
4114do :
4115 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4116ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4117"
4118eval as_val=\$$as_ac_Header
4119 if test "x$as_val" = x""yes; then :
4120 cat >>confdefs.h <<_ACEOF
4121#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4122_ACEOF
4123
4124fi
4125
4126done
4127
4128
4129
4130 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4131if test "x$ac_cv_header_minix_config_h" = x""yes; then :
4132 MINIX=yes
a1ba1d98 4133else
19ecc7c1 4134 MINIX=
a1ba1d98 4135fi
4136
4137
19ecc7c1 4138 if test "$MINIX" = yes; then
a1ba1d98 4139
19ecc7c1 4140$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
4141
4142
4143$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
4144
4145
4146$as_echo "#define _MINIX 1" >>confdefs.h
4147
4148 fi
4149
4150
4151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4152$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4153if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
cd9a469c 4154 $as_echo_n "(cached) " >&6
0bc5435c 4155else
cd9a469c 4156 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
fdf7ca85 4157/* end confdefs.h. */
4158
19ecc7c1 4159# define __EXTENSIONS__ 1
4160 $ac_includes_default
fdf7ca85 4161int
4162main ()
4163{
fdf7ca85 4164
4165 ;
4166 return 0;
4167}
4168_ACEOF
cd9a469c 4169if ac_fn_c_try_compile "$LINENO"; then :
19ecc7c1 4170 ac_cv_safe_to_define___extensions__=yes
0bc5435c 4171else
19ecc7c1 4172 ac_cv_safe_to_define___extensions__=no
0bc5435c 4173fi
cd9a469c 4174rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
0bc5435c 4175fi
19ecc7c1 4176{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4177$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
4178 test $ac_cv_safe_to_define___extensions__ = yes &&
4179 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
4180
4181 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
4182
4183 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
4184
4185 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
4186
4187 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
4188
fdf7ca85 4189
0bc5435c 4190
19ecc7c1 4191# Check whether --enable-largefile was given.
4192if test "${enable_largefile+set}" = set; then :
4193 enableval=$enable_largefile;
0bc5435c 4194fi
fdf7ca85 4195
19ecc7c1 4196if test "$enable_largefile" != no; then
4197
4198 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
4199$as_echo_n "checking for special C compiler options needed for large files... " >&6; }
4200if test "${ac_cv_sys_largefile_CC+set}" = set; then :
cd9a469c 4201 $as_echo_n "(cached) " >&6
0bc5435c 4202else
19ecc7c1 4203 ac_cv_sys_largefile_CC=no
4204 if test "$GCC" != yes; then
4205 ac_save_CC=$CC
4206 while :; do
4207 # IRIX 6.2 and later do not support large files by default,
4208 # so use the C compiler's -n32 option if that helps.
4209 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4210/* end confdefs.h. */
4211#include <sys/types.h>
4212 /* Check that off_t can represent 2**63 - 1 correctly.
4213 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4214 since some C++ compilers masquerading as C compilers
4215 incorrectly reject 9223372036854775807. */
4216#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4217 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4218 && LARGE_OFF_T % 2147483647 == 1)
4219 ? 1 : -1];
4220int
4221main ()
4222{
4223
4224 ;
4225 return 0;
4226}
4227_ACEOF
4228 if ac_fn_c_try_compile "$LINENO"; then :
4229 break
4230fi
4231rm -f core conftest.err conftest.$ac_objext
4232 CC="$CC -n32"
4233 if ac_fn_c_try_compile "$LINENO"; then :
4234 ac_cv_sys_largefile_CC=' -n32'; break
4235fi
4236rm -f core conftest.err conftest.$ac_objext
4237 break
4238 done
4239 CC=$ac_save_CC
4240 rm -f conftest.$ac_ext
4241 fi
4242fi
4243{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
4244$as_echo "$ac_cv_sys_largefile_CC" >&6; }
4245 if test "$ac_cv_sys_largefile_CC" != no; then
4246 CC=$CC$ac_cv_sys_largefile_CC
4247 fi
4248
4249 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
4250$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
4251if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
4252 $as_echo_n "(cached) " >&6
4253else
4254 while :; do
cd9a469c 4255 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
fdf7ca85 4256/* end confdefs.h. */
19ecc7c1 4257#include <sys/types.h>
4258 /* Check that off_t can represent 2**63 - 1 correctly.
4259 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4260 since some C++ compilers masquerading as C compilers
4261 incorrectly reject 9223372036854775807. */
4262#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4263 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4264 && LARGE_OFF_T % 2147483647 == 1)
4265 ? 1 : -1];
4266int
4267main ()
4268{
a6089b1e 4269
19ecc7c1 4270 ;
4271 return 0;
4272}
fdf7ca85 4273_ACEOF
cd9a469c 4274if ac_fn_c_try_compile "$LINENO"; then :
19ecc7c1 4275 ac_cv_sys_file_offset_bits=no; break
0bc5435c 4276fi
cd9a469c 4277rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19ecc7c1 4278 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4279/* end confdefs.h. */
4280#define _FILE_OFFSET_BITS 64
4281#include <sys/types.h>
4282 /* Check that off_t can represent 2**63 - 1 correctly.
4283 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4284 since some C++ compilers masquerading as C compilers
4285 incorrectly reject 9223372036854775807. */
4286#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4287 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4288 && LARGE_OFF_T % 2147483647 == 1)
4289 ? 1 : -1];
4290int
4291main ()
4292{
fdf7ca85 4293
19ecc7c1 4294 ;
4295 return 0;
4296}
4297_ACEOF
4298if ac_fn_c_try_compile "$LINENO"; then :
4299 ac_cv_sys_file_offset_bits=64; break
0bc5435c 4300fi
19ecc7c1 4301rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4302 ac_cv_sys_file_offset_bits=unknown
4303 break
4304done
4305fi
4306{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
4307$as_echo "$ac_cv_sys_file_offset_bits" >&6; }
4308case $ac_cv_sys_file_offset_bits in #(
4309 no | unknown) ;;
4310 *)
4311cat >>confdefs.h <<_ACEOF
4312#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
fdf7ca85 4313_ACEOF
19ecc7c1 4314;;
fdf7ca85 4315esac
19ecc7c1 4316rm -rf conftest*
4317 if test $ac_cv_sys_file_offset_bits = unknown; then
4318 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
4319$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
4320if test "${ac_cv_sys_large_files+set}" = set; then :
4321 $as_echo_n "(cached) " >&6
4322else
4323 while :; do
4324 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4325/* end confdefs.h. */
4326#include <sys/types.h>
4327 /* Check that off_t can represent 2**63 - 1 correctly.
4328 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4329 since some C++ compilers masquerading as C compilers
4330 incorrectly reject 9223372036854775807. */
4331#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4332 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4333 && LARGE_OFF_T % 2147483647 == 1)
4334 ? 1 : -1];
4335int
4336main ()
4337{
0bc5435c 4338
19ecc7c1 4339 ;
4340 return 0;
4341}
4342_ACEOF
4343if ac_fn_c_try_compile "$LINENO"; then :
4344 ac_cv_sys_large_files=no; break
4345fi
4346rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4347 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4348/* end confdefs.h. */
4349#define _LARGE_FILES 1
4350#include <sys/types.h>
4351 /* Check that off_t can represent 2**63 - 1 correctly.
4352 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4353 since some C++ compilers masquerading as C compilers
4354 incorrectly reject 9223372036854775807. */
4355#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4356 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4357 && LARGE_OFF_T % 2147483647 == 1)
4358 ? 1 : -1];
4359int
4360main ()
4361{
cd9a469c 4362
19ecc7c1 4363 ;
4364 return 0;
4365}
4366_ACEOF
4367if ac_fn_c_try_compile "$LINENO"; then :
4368 ac_cv_sys_large_files=1; break
4369fi
4370rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4371 ac_cv_sys_large_files=unknown
4372 break
4373done
4374fi
4375{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
4376$as_echo "$ac_cv_sys_large_files" >&6; }
4377case $ac_cv_sys_large_files in #(
4378 no | unknown) ;;
4379 *)
4380cat >>confdefs.h <<_ACEOF
4381#define _LARGE_FILES $ac_cv_sys_large_files
4382_ACEOF
4383;;
4384esac
4385rm -rf conftest*
4386 fi
4387fi
4388
4389
4390ac_c_preproc_warn_flag=yes
4391
55b8da6f 4392ac_ext=c
4393ac_cpp='$CPP $CPPFLAGS'
4394ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4395ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4396ac_compiler_gnu=$ac_cv_c_compiler_gnu
4397
19ecc7c1 4398ac_libiberty_warn_cflags=
4399save_CFLAGS="$CFLAGS"
4400for real_option in -W -Wall -Wwrite-strings -Wc++-compat \
4401 -Wstrict-prototypes; do
4402 # Do the check with the no- prefix removed since gcc silently
4403 # accepts any -Wno-* option on purpose
4404 case $real_option in
4405 -Wno-*) option=-W`expr x$real_option : 'x-Wno-\(.*\)'` ;;
4406 *) option=$real_option ;;
4407 esac
4408 as_acx_Woption=`$as_echo "acx_cv_prog_cc_warning_$option" | $as_tr_sh`
4409
4410 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports $option" >&5
4411$as_echo_n "checking whether $CC supports $option... " >&6; }
4412if { as_var=$as_acx_Woption; eval "test \"\${$as_var+set}\" = set"; }; then :
cd9a469c 4413 $as_echo_n "(cached) " >&6
0bc5435c 4414else
19ecc7c1 4415 CFLAGS="$option"
4416 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4417/* end confdefs.h. */
cd9a469c 4418
19ecc7c1 4419int
4420main ()
4421{
4422
4423 ;
4424 return 0;
4425}
4426_ACEOF
4427if ac_fn_c_try_compile "$LINENO"; then :
4428 eval "$as_acx_Woption=yes"
4429else
4430 eval "$as_acx_Woption=no"
4431fi
4432rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4433
4434fi
4435eval ac_res=\$$as_acx_Woption
4436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
4437$as_echo "$ac_res" >&6; }
4438 if test `eval 'as_val=${'$as_acx_Woption'};$as_echo "$as_val"'` = yes; then :
4439 ac_libiberty_warn_cflags="$ac_libiberty_warn_cflags${ac_libiberty_warn_cflags:+ }$real_option"
4440fi
cd9a469c 4441 done
19ecc7c1 4442CFLAGS="$save_CFLAGS"
55b8da6f 4443ac_ext=c
4444ac_cpp='$CPP $CPPFLAGS'
4445ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4446ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4447ac_compiler_gnu=$ac_cv_c_compiler_gnu
4448
4449
4450ac_ext=c
4451ac_cpp='$CPP $CPPFLAGS'
4452ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4453ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4454ac_compiler_gnu=$ac_cv_c_compiler_gnu
19ecc7c1 4455
4456# Do the check with the no- prefix removed from the warning options
4457# since gcc silently accepts any -Wno-* option on purpose
4458if test "$GCC" = yes; then :
4459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -pedantic " >&5
4460$as_echo_n "checking whether $CC supports -pedantic ... " >&6; }
4461if test "${acx_cv_prog_cc_pedantic_+set}" = set; then :
4462 $as_echo_n "(cached) " >&6
cd9a469c 4463else
19ecc7c1 4464 save_CFLAGS="$CFLAGS"
4465CFLAGS="-pedantic "
4466cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4467/* end confdefs.h. */
4468
4469int
4470main ()
4471{
4472
4473 ;
4474 return 0;
4475}
4476_ACEOF
4477if ac_fn_c_try_compile "$LINENO"; then :
4478 acx_cv_prog_cc_pedantic_=yes
4479else
4480 acx_cv_prog_cc_pedantic_=no
4481fi
4482rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4483CFLAGS="$save_CFLAGS"
4484fi
4485{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_cv_prog_cc_pedantic_" >&5
4486$as_echo "$acx_cv_prog_cc_pedantic_" >&6; }
4487if test $acx_cv_prog_cc_pedantic_ = yes; then :
4488 ac_libiberty_warn_cflags="$ac_libiberty_warn_cflags${ac_libiberty_warn_cflags:+ }-pedantic "
cd9a469c 4489fi
4490
4491fi
55b8da6f 4492ac_ext=c
4493ac_cpp='$CPP $CPPFLAGS'
4494ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4495ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4496ac_compiler_gnu=$ac_cv_c_compiler_gnu
4497
cd9a469c 4498
4499
19ecc7c1 4500if test "x$CC" != xcc; then
4501 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
4502$as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
4503else
4504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
4505$as_echo_n "checking whether cc understands -c and -o together... " >&6; }
4506fi
4507set dummy $CC; ac_cc=`$as_echo "$2" |
4508 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
4509if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
cd9a469c 4510 $as_echo_n "(cached) " >&6
4511else
19ecc7c1 4512 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4513/* end confdefs.h. */
4514
4515int
4516main ()
4517{
4518
4519 ;
4520 return 0;
4521}
4522_ACEOF
4523# Make sure it works both with $CC and with simple cc.
4524# We do the test twice because some compilers refuse to overwrite an
4525# existing .o file with -o, though they will create one.
4526ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
4527rm -f conftest2.*
4528if { { case "(($ac_try" in
4529 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4530 *) ac_try_echo=$ac_try;;
4531esac
4532eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4533$as_echo "$ac_try_echo"; } >&5
4534 (eval "$ac_try") 2>&5
4535 ac_status=$?
4536 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4537 test $ac_status = 0; } &&
4538 test -f conftest2.$ac_objext && { { case "(($ac_try" in
4539 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4540 *) ac_try_echo=$ac_try;;
4541esac
4542eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4543$as_echo "$ac_try_echo"; } >&5
4544 (eval "$ac_try") 2>&5
4545 ac_status=$?
4546 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4547 test $ac_status = 0; };
4548then
4549 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
4550 if test "x$CC" != xcc; then
4551 # Test first that cc exists at all.
4552 if { ac_try='cc -c conftest.$ac_ext >&5'
4553 { { case "(($ac_try" in
4554 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4555 *) ac_try_echo=$ac_try;;
cd9a469c 4556esac
19ecc7c1 4557eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4558$as_echo "$ac_try_echo"; } >&5
4559 (eval "$ac_try") 2>&5
4560 ac_status=$?
4561 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4562 test $ac_status = 0; }; }; then
4563 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
4564 rm -f conftest2.*
4565 if { { case "(($ac_try" in
4566 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4567 *) ac_try_echo=$ac_try;;
4568esac
4569eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4570$as_echo "$ac_try_echo"; } >&5
4571 (eval "$ac_try") 2>&5
4572 ac_status=$?
4573 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4574 test $ac_status = 0; } &&
4575 test -f conftest2.$ac_objext && { { case "(($ac_try" in
4576 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4577 *) ac_try_echo=$ac_try;;
4578esac
4579eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4580$as_echo "$ac_try_echo"; } >&5
4581 (eval "$ac_try") 2>&5
4582 ac_status=$?
4583 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4584 test $ac_status = 0; };
4585 then
4586 # cc works too.
4587 :
4588 else
4589 # cc exists but doesn't like -o.
4590 eval ac_cv_prog_cc_${ac_cc}_c_o=no
4591 fi
4592 fi
cd9a469c 4593 fi
4594else
19ecc7c1 4595 eval ac_cv_prog_cc_${ac_cc}_c_o=no
cd9a469c 4596fi
19ecc7c1 4597rm -f core conftest*
cd9a469c 4598
cd9a469c 4599fi
19ecc7c1 4600if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
4601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4602$as_echo "yes" >&6; }
4603else
4604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4605$as_echo "no" >&6; }
4606
4607$as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
cd9a469c 4608
19ecc7c1 4609fi
cd9a469c 4610
19ecc7c1 4611# autoconf is lame and doesn't give us any substitution variable for this.
4612if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" = no"; then
4613 NO_MINUS_C_MINUS_O=yes
4614else
4615 OUTPUT_OPTION='-o $@'
4616fi
4617
4618
4619
4620{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
4621$as_echo_n "checking for an ANSI C-conforming const... " >&6; }
4622if test "${ac_cv_c_const+set}" = set; then :
cd9a469c 4623 $as_echo_n "(cached) " >&6
4624else
4625 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
fdf7ca85 4626/* end confdefs.h. */
1aa028ef 4627
fdf7ca85 4628int
4629main ()
4630{
19ecc7c1 4631/* FIXME: Include the comments suggested by Paul. */
4632#ifndef __cplusplus
4633 /* Ultrix mips cc rejects this. */
4634 typedef int charset[2];
4635 const charset cs;
4636 /* SunOS 4.1.1 cc rejects this. */
4637 char const *const *pcpcc;
4638 char **ppc;
4639 /* NEC SVR4.0.2 mips cc rejects this. */
4640 struct point {int x, y;};
4641 static struct point const zero = {0,0};
4642 /* AIX XL C 1.02.0.0 rejects this.
4643 It does not let you subtract one const X* pointer from another in
4644 an arm of an if-expression whose if-part is not a constant
4645 expression */
4646 const char *g = "string";
4647 pcpcc = &g + (g ? g-g : 0);
4648 /* HPUX 7.0 cc rejects these. */
4649 ++pcpcc;
4650 ppc = (char**) pcpcc;
4651 pcpcc = (char const *const *) ppc;
4652 { /* SCO 3.2v4 cc rejects this. */
4653 char *t;
4654 char const *s = 0 ? (char *) 0 : (char const *) 0;
4655
4656 *t++ = 0;
4657 if (s) return 0;
4658 }
4659 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
4660 int x[] = {25, 17};
4661 const int *foo = &x[0];
4662 ++foo;
4663 }
4664 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
4665 typedef const int *iptr;
4666 iptr p = 0;
4667 ++p;
4668 }
4669 { /* AIX XL C 1.02.0.0 rejects this saying
4670 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
4671 struct s { int j; const int *ap[3]; };
4672 struct s *b; b->j = 5;
4673 }
4674 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
4675 const int foo = 10;
4676 if (!foo) return 0;
4677 }
4678 return !cs[0] && !zero.x;
4679#endif
1aa028ef 4680
fdf7ca85 4681 ;
4682 return 0;
4683}
4684_ACEOF
cd9a469c 4685if ac_fn_c_try_compile "$LINENO"; then :
19ecc7c1 4686 ac_cv_c_const=yes
cd9a469c 4687else
19ecc7c1 4688 ac_cv_c_const=no
cd9a469c 4689fi
4690rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
cd9a469c 4691fi
19ecc7c1 4692{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
4693$as_echo "$ac_cv_c_const" >&6; }
4694if test $ac_cv_c_const = no; then
cd9a469c 4695
19ecc7c1 4696$as_echo "#define const /**/" >>confdefs.h
cd9a469c 4697
4698fi
4699
19ecc7c1 4700{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
4701$as_echo_n "checking for inline... " >&6; }
4702if test "${ac_cv_c_inline+set}" = set; then :
4703 $as_echo_n "(cached) " >&6
cd9a469c 4704else
19ecc7c1 4705 ac_cv_c_inline=no
4706for ac_kw in inline __inline__ __inline; do
cd9a469c 4707 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4708/* end confdefs.h. */
19ecc7c1 4709#ifndef __cplusplus
4710typedef int foo_t;
4711static $ac_kw foo_t static_foo () {return 0; }
4712$ac_kw foo_t foo () {return 0; }
a1ba1d98 4713#endif
1aa028ef 4714
a6089b1e 4715_ACEOF
19ecc7c1 4716if ac_fn_c_try_compile "$LINENO"; then :
4717 ac_cv_c_inline=$ac_kw
cd9a469c 4718fi
19ecc7c1 4719rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4720 test "$ac_cv_c_inline" != no && break
4721done
cd9a469c 4722
4723fi
19ecc7c1 4724{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
4725$as_echo "$ac_cv_c_inline" >&6; }
cd9a469c 4726
19ecc7c1 4727case $ac_cv_c_inline in
4728 inline | yes) ;;
4729 *)
4730 case $ac_cv_c_inline in
4731 no) ac_val=;;
4732 *) ac_val=$ac_cv_c_inline;;
4733 esac
4734 cat >>confdefs.h <<_ACEOF
4735#ifndef __cplusplus
4736#define inline $ac_val
4737#endif
cd9a469c 4738_ACEOF
19ecc7c1 4739 ;;
4740esac
cd9a469c 4741
4742 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
4743$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
4744if test "${ac_cv_c_bigendian+set}" = set; then :
4745 $as_echo_n "(cached) " >&6
4746else
1aa028ef 4747 ac_cv_c_bigendian=unknown
cd9a469c 4748 # See if we're dealing with a universal compiler.
4749 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4750/* end confdefs.h. */
4751#ifndef __APPLE_CC__
4752 not a universal capable compiler
4753 #endif
4754 typedef int dummy;
4755
4756_ACEOF
4757if ac_fn_c_try_compile "$LINENO"; then :
4758
4759 # Check for potential -arch flags. It is not universal unless
4760 # there are at least two -arch flags with different values.
4761 ac_arch=
4762 ac_prev=
4763 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
4764 if test -n "$ac_prev"; then
4765 case $ac_word in
4766 i?86 | x86_64 | ppc | ppc64)
4767 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
4768 ac_arch=$ac_word
4769 else
4770 ac_cv_c_bigendian=universal
4771 break
4772 fi
4773 ;;
4774 esac
4775 ac_prev=
4776 elif test "x$ac_word" = "x-arch"; then
4777 ac_prev=arch
4778 fi
4779 done
4780fi
4781rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4782 if test $ac_cv_c_bigendian = unknown; then
4783 # See if sys/param.h defines the BYTE_ORDER macro.
4784 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4785/* end confdefs.h. */
4786#include <sys/types.h>
4787 #include <sys/param.h>
4788
4789int
4790main ()
4791{
4792#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
4793 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
4794 && LITTLE_ENDIAN)
4795 bogus endian macros
4796 #endif
4797
4798 ;
4799 return 0;
4800}
1aa028ef 4801_ACEOF
cd9a469c 4802if ac_fn_c_try_compile "$LINENO"; then :
4803 # It does; now see whether it defined to BIG_ENDIAN or not.
4804 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1aa028ef 4805/* end confdefs.h. */
cd9a469c 4806#include <sys/types.h>
4807 #include <sys/param.h>
4808
1aa028ef 4809int
4810main ()
4811{
cd9a469c 4812#if BYTE_ORDER != BIG_ENDIAN
4813 not big endian
4814 #endif
4815
1aa028ef 4816 ;
4817 return 0;
4818}
4819_ACEOF
cd9a469c 4820if ac_fn_c_try_compile "$LINENO"; then :
1aa028ef 4821 ac_cv_c_bigendian=yes
cd9a469c 4822else
4823 ac_cv_c_bigendian=no
1aa028ef 4824fi
cd9a469c 4825rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1aa028ef 4826fi
cd9a469c 4827rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4828 fi
4829 if test $ac_cv_c_bigendian = unknown; then
4830 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
4831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4832/* end confdefs.h. */
4833#include <limits.h>
1aa028ef 4834
cd9a469c 4835int
4836main ()
4837{
4838#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
4839 bogus endian macros
4840 #endif
4841
4842 ;
4843 return 0;
4844}
a1ba1d98 4845_ACEOF
cd9a469c 4846if ac_fn_c_try_compile "$LINENO"; then :
4847 # It does; now see whether it defined to _BIG_ENDIAN or not.
4848 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
a1ba1d98 4849/* end confdefs.h. */
cd9a469c 4850#include <limits.h>
4851
1aa028ef 4852int
4853main ()
4854{
cd9a469c 4855#ifndef _BIG_ENDIAN
4856 not big endian
4857 #endif
4858
4859 ;
4860 return 0;
a1ba1d98 4861}
a6089b1e 4862_ACEOF
cd9a469c 4863if ac_fn_c_try_compile "$LINENO"; then :
4864 ac_cv_c_bigendian=yes
a1ba1d98 4865else
cd9a469c 4866 ac_cv_c_bigendian=no
b3552be1 4867fi
cd9a469c 4868rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
a1ba1d98 4869fi
cd9a469c 4870rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4871 fi
4872 if test $ac_cv_c_bigendian = unknown; then
4873 # Compile a test program.
4874 if test "$cross_compiling" = yes; then :
4875 # Try to guess by grepping values from an object file.
4876 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4877/* end confdefs.h. */
4878short int ascii_mm[] =
4879 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
4880 short int ascii_ii[] =
4881 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
4882 int use_ascii (int i) {
4883 return ascii_mm[i] + ascii_ii[i];
4884 }
4885 short int ebcdic_ii[] =
4886 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
4887 short int ebcdic_mm[] =
4888 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
4889 int use_ebcdic (int i) {
4890 return ebcdic_mm[i] + ebcdic_ii[i];
4891 }
4892 extern int foo;
4893
4894int
4895main ()
4896{
4897return use_ascii (foo) == use_ebcdic (foo);
4898 ;
4899 return 0;
4900}
4901_ACEOF
4902if ac_fn_c_try_compile "$LINENO"; then :
4903 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
4904 ac_cv_c_bigendian=yes
4905 fi
4906 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
4907 if test "$ac_cv_c_bigendian" = unknown; then
4908 ac_cv_c_bigendian=no
4909 else
4910 # finding both strings is unlikely to happen, but who knows?
4911 ac_cv_c_bigendian=unknown
4912 fi
4913 fi
4914fi
4915rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4916else
4917 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4918/* end confdefs.h. */
4919$ac_includes_default
4920int
4921main ()
4922{
4923
4924 /* Are we little or big endian? From Harbison&Steele. */
4925 union
4926 {
4927 long int l;
4928 char c[sizeof (long int)];
4929 } u;
4930 u.l = 1;
4931 return u.c[sizeof (long int) - 1] == 1;
4932
4933 ;
4934 return 0;
4935}
4936_ACEOF
4937if ac_fn_c_try_run "$LINENO"; then :
4938 ac_cv_c_bigendian=no
4939else
4940 ac_cv_c_bigendian=yes
a1ba1d98 4941fi
cd9a469c 4942rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4943 conftest.$ac_objext conftest.beam conftest.$ac_ext
a1ba1d98 4944fi
a6089b1e 4945
cd9a469c 4946 fi
4947fi
4948{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
4949$as_echo "$ac_cv_c_bigendian" >&6; }
4950 case $ac_cv_c_bigendian in #(
4951 yes)
4952 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
4953;; #(
4954 no)
4955 ;; #(
4956 universal)
4957
4958$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
4959
4960 ;; #(
4961 *)
4962 as_fn_error "unknown endianness
4963 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
4964 esac
b3552be1 4965
f0a93313 4966
4967
4968
cd9a469c 4969ac_config_headers="$ac_config_headers config.h:config.in"
f0a93313 4970
4971
4972
4973# Find a good install program. We prefer a C program (faster),
4974# so one script is as good as another. But avoid the broken or
4975# incompatible versions:
4976# SysV /etc/install, /usr/sbin/install
4977# SunOS /usr/etc/install
4978# IRIX /sbin/install
4979# AIX /bin/install
a6089b1e 4980# AmigaOS /C/install, which installs bootblocks on floppy discs
f0a93313 4981# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
4982# AFS /usr/afsws/bin/install, which mishandles nonexistent args
4983# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
ac09b42b 4984# OS/2's system install, which has a completely different semantic
f0a93313 4985# ./install, which can be erroneously created by make from ./install.sh.
cd9a469c 4986# Reject install programs that cannot install multiple files.
4987{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
4988$as_echo_n "checking for a BSD-compatible install... " >&6; }
f0a93313 4989if test -z "$INSTALL"; then
cd9a469c 4990if test "${ac_cv_path_install+set}" = set; then :
4991 $as_echo_n "(cached) " >&6
a6089b1e 4992else
4993 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4994for as_dir in $PATH
4995do
4996 IFS=$as_save_IFS
4997 test -z "$as_dir" && as_dir=.
cd9a469c 4998 # Account for people who put trailing slashes in PATH elements.
4999case $as_dir/ in #((
5000 ./ | .// | /[cC]/* | \
a6089b1e 5001 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
cd9a469c 5002 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
a6089b1e 5003 /usr/ucb/* ) ;;
5004 *)
5005 # OSF1 and SCO ODT 3.0 have their own names for install.
5006 # Don't use installbsd from OSF since it installs stuff as root
5007 # by default.
5008 for ac_prog in ginstall scoinst install; do
5009 for ac_exec_ext in '' $ac_executable_extensions; do
cd9a469c 5010 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
ac09b42b 5011 if test $ac_prog = install &&
5012 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
5013 # AIX install. It has an incompatible calling convention.
5014 :
5015 elif test $ac_prog = install &&
5016 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
5017 # program-specific install script used by HP pwplus--don't use.
5018 :
5019 else
cd9a469c 5020 rm -rf conftest.one conftest.two conftest.dir
5021 echo one > conftest.one
5022 echo two > conftest.two
5023 mkdir conftest.dir
5024 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
5025 test -s conftest.one && test -s conftest.two &&
5026 test -s conftest.dir/conftest.one &&
5027 test -s conftest.dir/conftest.two
5028 then
5029 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
5030 break 3
5031 fi
ac09b42b 5032 fi
5033 fi
f0a93313 5034 done
a6089b1e 5035 done
5036 ;;
5037esac
a6089b1e 5038
cd9a469c 5039 done
5040IFS=$as_save_IFS
5041
5042rm -rf conftest.one conftest.two conftest.dir
f0a93313 5043
5044fi
5045 if test "${ac_cv_path_install+set}" = set; then
a6089b1e 5046 INSTALL=$ac_cv_path_install
f0a93313 5047 else
cd9a469c 5048 # As a last resort, use the slow shell script. Don't cache a
5049 # value for INSTALL within a source directory, because that will
f0a93313 5050 # break other packages using the cache if that directory is
cd9a469c 5051 # removed, or if the value is a relative name.
a6089b1e 5052 INSTALL=$ac_install_sh
f0a93313 5053 fi
5054fi
cd9a469c 5055{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
5056$as_echo "$INSTALL" >&6; }
f0a93313 5057
5058# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
5059# It thinks the first close brace ends the variable substitution.
5060test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
5061
a6089b1e 5062test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
301e59c9 5063
f0a93313 5064test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
5065
5066
e744e148 5067# Don't build the shared library for build.
5068if [ -n "${with_build_subdir}" ]; then
5069 enable_shared=no
5070fi
5071
5072frag=
5073case "${host}" in
5074 rs6000-ibm-aix3.1 | rs6000-ibm-aix)
5075 frag=mh-aix ;;
5076 *-*-cxux7*) frag=mh-cxux7 ;;
5077 *-*-freebsd2.1.*) frag=mh-fbsd21 ;;
5078 *-*-freebsd2.2.[012]) frag=mh-fbsd21 ;;
5079 i370-*-opened*) frag=mh-openedition ;;
5080 i[34567]86-*-windows*) frag=mh-windows ;;
5081esac
5082
5083if [ -n "${frag}" ]; then
05f405cd 5084 frag=${libiberty_topdir}/libiberty/config/$frag
e744e148 5085fi
5086
d89b8910 5087
5088
5089
5090
5091case "${host}" in
5092 # PIC is the default on some targets or must not be used.
5093 *-*-darwin*)
fb5ccd6d 5094 # For darwin, common symbols are not allowed in MH_DYLIB files
5095 case "${CFLAGS}" in
5096 # If we are using a compiler supporting mdynamic-no-pic
5097 # and the option has been tested as safe to add, then cancel
5098 # it here, since the code generated is incompatible with shared
5099 # libs.
5100 *-mdynamic-no-pic*) PICFLAG='-fno-common -mno-dynamic-no-pic' ;;
5101 *) PICFLAG=-fno-common ;;
5102 esac
d89b8910 5103 ;;
5104 alpha*-dec-osf5*)
5105 # PIC is the default.
5106 ;;
5107 hppa*64*-*-hpux*)
5108 # PIC is the default for 64-bit PA HP-UX.
5109 ;;
919a02c0 5110 i[34567]86-*-cygwin* | x86_64-*-cygwin*)
5111 ;;
5112 i[34567]86-*-mingw* | x86_64-*-mingw*)
d89b8910 5113 ;;
af8e12d0 5114 i[34567]86-*-interix[3-9]*)
d89b8910 5115 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
5116 # Instead, we relocate shared libraries at runtime.
5117 ;;
5118 i[34567]86-*-nto-qnx*)
5119 # QNX uses GNU C++, but need to define -shared option too, otherwise
5120 # it will coredump.
5121 PICFLAG='-fPIC -shared'
5122 ;;
5123 i[34567]86-pc-msdosdjgpp*)
5124 # DJGPP does not support shared libraries at all.
5125 ;;
5126 ia64*-*-hpux*)
5127 # On IA64 HP-UX, PIC is the default but the pic flag
5128 # sets the default TLS model and affects inlining.
5129 PICFLAG=-fPIC
5130 ;;
5131 mips-sgi-irix6*)
5132 # PIC is the default.
5133 ;;
5134 rs6000-ibm-aix* | powerpc-ibm-aix*)
5135 # All AIX code is PIC.
5136 ;;
5137
5138 # Some targets support both -fPIC and -fpic, but prefer the latter.
5139 # FIXME: Why?
5140 i[34567]86-*-* | x86_64-*-*)
5141 PICFLAG=-fpic
5142 ;;
d89b8910 5143 # FIXME: Override -fPIC default in libgcc only?
5144 sh-*-linux* | sh[2346lbe]*-*-linux*)
5145 PICFLAG=-fpic
5146 ;;
5147 # FIXME: Simplify to sh*-*-netbsd*?
9a9b5abf 5148 sh-*-netbsdelf* | shl*-*-netbsdelf*)
d89b8910 5149 PICFLAG=-fpic
5150 ;;
5151 # Default to -fPIC unless specified otherwise.
5152 *)
5153 PICFLAG=-fPIC
5154 ;;
5155esac
5156
5157# If the user explicitly uses -fpic/-fPIC, keep that.
5158case "${CFLAGS}" in
5159 *-fpic*)
5160 PICFLAG=-fpic
5161 ;;
5162 *-fPIC*)
5163 PICFLAG=-fPIC
5164 ;;
5165esac
5166
5167
e744e148 5168# If they didn't specify --enable-shared, don't generate shared libs.
5169case "${enable_shared}" in
5170 yes) shared=yes ;;
5171 no) shared=no ;;
5172 "") shared=no ;;
5173 *) shared=yes ;;
5174esac
2bd17377 5175
5176# ...unless --enable-host-shared was passed from top-level config:
5177if [ "${enable_host_shared}" = "yes" ]; then
5178 shared=yes
5179fi
5180
d89b8910 5181if [ "${shared}" != "yes" ]; then
5182 PICFLAG=
e744e148 5183fi
5184
05f405cd 5185
f945635a 5186NOASANFLAG=
5187case " ${CFLAGS} " in
5188 *\ -fsanitize=address\ *) NOASANFLAG=-fno-sanitize=address ;;
5189esac
5190
5191
e744e148 5192echo "# Warning: this fragment is automatically generated" > temp-frag
5193
05f405cd 5194if [ -n "${frag}" ] && [ -f "${frag}" ]; then
5195 echo "Appending ${frag} to xhost-mkfrag"
5196 echo "# Following fragment copied from ${frag}" >> temp-frag
5197 cat ${frag} >> temp-frag
5198fi
e744e148 5199
5200# record if we want to build shared libs.
5201if [ "${shared}" = "yes" ]; then
5202 echo enable_shared = yes >> temp-frag
5203else
5204 echo enable_shared = no >> temp-frag
5205fi
5206
5207frag=xhost-mkfrag
5208${CONFIG_SHELL-/bin/sh} ${libiberty_topdir}/move-if-change temp-frag xhost-mkfrag
5209
f0a93313 5210host_makefile_frag=${frag}
5211
5212
5213# It's OK to check for header files. Although the compiler may not be
5214# able to link anything, it had better be able to at least compile
5215# something.
d0820ac0 5216for ac_header in sys/file.h sys/param.h limits.h stdlib.h malloc.h string.h unistd.h strings.h sys/time.h time.h sys/resource.h sys/stat.h sys/mman.h fcntl.h alloca.h sys/pstat.h sys/sysmp.h sys/sysinfo.h machine/hal_sysinfo.h sys/table.h sys/sysctl.h sys/systemcfg.h stdint.h stdio_ext.h process.h sys/prctl.h
cd9a469c 5217do :
5218 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
5219ac_fn_c_check_header_preproc "$LINENO" "$ac_header" "$as_ac_Header"
5220eval as_val=\$$as_ac_Header
5221 if test "x$as_val" = x""yes; then :
a6089b1e 5222 cat >>confdefs.h <<_ACEOF
cd9a469c 5223#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
a6089b1e 5224_ACEOF
5225
5226fi
a6089b1e 5227done
5228
cd9a469c 5229{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
5230$as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
5231if test "${ac_cv_header_sys_wait_h+set}" = set; then :
5232 $as_echo_n "(cached) " >&6
a6089b1e 5233else
cd9a469c 5234 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
a6089b1e 5235/* end confdefs.h. */
7b190504 5236#include <sys/types.h>
a6089b1e 5237#include <sys/wait.h>
5238#ifndef WEXITSTATUS
cd9a469c 5239# define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
b6477ce7 5240#endif
a6089b1e 5241#ifndef WIFEXITED
5242# define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
5243#endif
5244
5245int
5246main ()
5247{
5248 int s;
5249 wait (&s);
5250 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
5251 ;
5252 return 0;
5253}
5254_ACEOF
cd9a469c 5255if ac_fn_c_try_compile "$LINENO"; then :
a6089b1e 5256 ac_cv_header_sys_wait_h=yes
7b190504 5257else
cd9a469c 5258 ac_cv_header_sys_wait_h=no
7b190504 5259fi
cd9a469c 5260rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
a6089b1e 5261fi
cd9a469c 5262{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
5263$as_echo "$ac_cv_header_sys_wait_h" >&6; }
a6089b1e 5264if test $ac_cv_header_sys_wait_h = yes; then
5265
cd9a469c 5266$as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
90305aaf 5267
5268fi
5269
cd9a469c 5270{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
5271$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
5272if test "${ac_cv_header_time+set}" = set; then :
5273 $as_echo_n "(cached) " >&6
90305aaf 5274else
cd9a469c 5275 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
90305aaf 5276/* end confdefs.h. */
5277#include <sys/types.h>
5278#include <sys/time.h>
5279#include <time.h>
5280
5281int
5282main ()
5283{
5284if ((struct tm *) 0)
5285return 0;
5286 ;
5287 return 0;
5288}
5289_ACEOF
cd9a469c 5290if ac_fn_c_try_compile "$LINENO"; then :
90305aaf 5291 ac_cv_header_time=yes
5292else
cd9a469c 5293 ac_cv_header_time=no
90305aaf 5294fi
cd9a469c 5295rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
90305aaf 5296fi
cd9a469c 5297{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
5298$as_echo "$ac_cv_header_time" >&6; }
90305aaf 5299if test $ac_cv_header_time = yes; then
5300
cd9a469c 5301$as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
90305aaf 5302
5303fi
5304
5305
cd9a469c 5306{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether errno must be declared" >&5
5307$as_echo_n "checking whether errno must be declared... " >&6; }
5308if test "${libiberty_cv_declare_errno+set}" = set; then :
5309 $as_echo_n "(cached) " >&6
90305aaf 5310else
cd9a469c 5311 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
90305aaf 5312/* end confdefs.h. */
5313#include <errno.h>
5314int
5315main ()
5316{
5317int x = errno;
5318 ;
5319 return 0;
5320}
5321_ACEOF
cd9a469c 5322if ac_fn_c_try_compile "$LINENO"; then :
90305aaf 5323 libiberty_cv_declare_errno=no
5324else
cd9a469c 5325 libiberty_cv_declare_errno=yes
90305aaf 5326fi
cd9a469c 5327rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
90305aaf 5328fi
cd9a469c 5329{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libiberty_cv_declare_errno" >&5
5330$as_echo "$libiberty_cv_declare_errno" >&6; }
90305aaf 5331if test $libiberty_cv_declare_errno = yes
5332then
cd9a469c 5333$as_echo "#define NEED_DECLARATION_ERRNO 1" >>confdefs.h
90305aaf 5334
5335fi
5336
5337
5e1a5aba 5338# Determine sizes of some types.
cd9a469c 5339# The cast to long int works around a bug in the HP C Compiler
5340# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5341# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5342# This bug is HP SR number 8606223364.
5343{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
5344$as_echo_n "checking size of int... " >&6; }
5345if test "${ac_cv_sizeof_int+set}" = set; then :
5346 $as_echo_n "(cached) " >&6
5347else
5348 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then :
5349
5350else
5351 if test "$ac_cv_type_int" = yes; then
5352 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5353$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5354{ as_fn_set_status 77
5355as_fn_error "cannot compute sizeof (int)
5356See \`config.log' for more details." "$LINENO" 5; }; }
5357 else
5358 ac_cv_sizeof_int=0
5359 fi
90305aaf 5360fi
90305aaf 5361
cd9a469c 5362fi
5363{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
5364$as_echo "$ac_cv_sizeof_int" >&6; }
90305aaf 5365
90305aaf 5366
90305aaf 5367
cd9a469c 5368cat >>confdefs.h <<_ACEOF
5369#define SIZEOF_INT $ac_cv_sizeof_int
90305aaf 5370_ACEOF
90305aaf 5371
90305aaf 5372
5e1a5aba 5373# The cast to long int works around a bug in the HP C Compiler
5374# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5375# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5376# This bug is HP SR number 8606223364.
5377{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
5378$as_echo_n "checking size of long... " >&6; }
5379if test "${ac_cv_sizeof_long+set}" = set; then :
5380 $as_echo_n "(cached) " >&6
5381else
5382 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then :
5383
5384else
5385 if test "$ac_cv_type_long" = yes; then
5386 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5387$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5388{ as_fn_set_status 77
5389as_fn_error "cannot compute sizeof (long)
5390See \`config.log' for more details." "$LINENO" 5; }; }
5391 else
5392 ac_cv_sizeof_long=0
5393 fi
5394fi
5395
5396fi
5397{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
5398$as_echo "$ac_cv_sizeof_long" >&6; }
5399
5400
5401
5402cat >>confdefs.h <<_ACEOF
5403#define SIZEOF_LONG $ac_cv_sizeof_long
5404_ACEOF
5405
5406
55b8da6f 5407# The cast to long int 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{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5
5412$as_echo_n "checking size of size_t... " >&6; }
5413if test "${ac_cv_sizeof_size_t+set}" = set; then :
5414 $as_echo_n "(cached) " >&6
5415else
5416 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (size_t))" "ac_cv_sizeof_size_t" "$ac_includes_default"; then :
5417
5418else
5419 if test "$ac_cv_type_size_t" = yes; then
5420 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5421$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5422{ as_fn_set_status 77
5423as_fn_error "cannot compute sizeof (size_t)
5424See \`config.log' for more details." "$LINENO" 5; }; }
5425 else
5426 ac_cv_sizeof_size_t=0
5427 fi
5428fi
5429
5430fi
5431{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5
5432$as_echo "$ac_cv_sizeof_size_t" >&6; }
5433
5434
5435
5436cat >>confdefs.h <<_ACEOF
5437#define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
5438_ACEOF
5439
5440
5e1a5aba 5441
5442# Check for presense of long long
5443ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default"
5444if test "x$ac_cv_type_long_long" = x""yes; then :
5445
5446$as_echo "#define HAVE_LONG_LONG 1" >>confdefs.h
5447 # The cast to long int works around a bug in the HP C Compiler
5448# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5449# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5450# This bug is HP SR number 8606223364.
5451{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
5452$as_echo_n "checking size of long long... " >&6; }
5453if test "${ac_cv_sizeof_long_long+set}" = set; then :
5454 $as_echo_n "(cached) " >&6
5455else
5456 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then :
5457
5458else
5459 if test "$ac_cv_type_long_long" = yes; then
5460 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5461$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5462{ as_fn_set_status 77
5463as_fn_error "cannot compute sizeof (long long)
5464See \`config.log' for more details." "$LINENO" 5; }; }
5465 else
5466 ac_cv_sizeof_long_long=0
5467 fi
5468fi
5469
5470fi
5471{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
5472$as_echo "$ac_cv_sizeof_long_long" >&6; }
5473
5474
5475
5476cat >>confdefs.h <<_ACEOF
5477#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
5478_ACEOF
5479
5480
5481fi
5482
90305aaf 5483
cd9a469c 5484# Look for a 64-bit type.
5485{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a 64-bit type" >&5
5486$as_echo_n "checking for a 64-bit type... " >&6; }
5487if test "${liberty_cv_uint64+set}" = set; then :
5488 $as_echo_n "(cached) " >&6
a6089b1e 5489else
cd9a469c 5490 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5491/* end confdefs.h. */
5492#ifdef HAVE_STDINT_H
5493#include <stdint.h>
5494#endif
5495int
5496main ()
5497{
5498extern uint64_t foo;
5499 ;
5500 return 0;
5501}
a6089b1e 5502_ACEOF
cd9a469c 5503if ac_fn_c_try_compile "$LINENO"; then :
5504 liberty_cv_uint64=uint64_t
5505else
5506 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
a6089b1e 5507/* end confdefs.h. */
cd9a469c 5508#ifdef HAVE_LIMITS_H
5509#include <limits.h>
5510#endif
5511#ifndef CHAR_BIT
5512#define CHAR_BIT 8
90305aaf 5513#endif
a6089b1e 5514int
5515main ()
5516{
cd9a469c 5517extern char foo[sizeof(long) * CHAR_BIT >= 64 ? 1 : -1];
5518 ;
5519 return 0;
a6089b1e 5520}
5521_ACEOF
cd9a469c 5522if ac_fn_c_try_compile "$LINENO"; then :
5523 liberty_cv_uint64="unsigned long"
a6089b1e 5524else
cd9a469c 5525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5526/* end confdefs.h. */
5527#ifdef HAVE_LIMITS_H
5528#include <limits.h>
5529#endif
5530#ifndef CHAR_BIT
5531#define CHAR_BIT 8
5532#endif
5533int
5534main ()
5535{
5536extern char foo[sizeof(long long) * CHAR_BIT >= 64 ? 1 : -1];
5537 ;
5538 return 0;
5539}
5540_ACEOF
5541if ac_fn_c_try_compile "$LINENO"; then :
5542 liberty_cv_uint64="unsigned long long"
5543else
5544 liberty_cv_uint64=none
a6089b1e 5545fi
cd9a469c 5546rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
a6089b1e 5547fi
cd9a469c 5548rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
90305aaf 5549fi
cd9a469c 5550rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
90305aaf 5551fi
a6089b1e 5552
cd9a469c 5553{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $liberty_cv_uint64" >&5
5554$as_echo "$liberty_cv_uint64" >&6; }
5555if test "$liberty_cv_uint64" != none; then
5556
5557cat >>confdefs.h <<_ACEOF
5558#define UNSIGNED_64BIT_TYPE $liberty_cv_uint64
a6089b1e 5559_ACEOF
5560
5561fi
5562
65e17bf6 5563
5564 ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default"
5565if test "x$ac_cv_type_intptr_t" = x""yes; then :
5566
5567$as_echo "#define HAVE_INTPTR_T 1" >>confdefs.h
5568
5569else
5570 for ac_type in 'int' 'long int' 'long long int'; do
5571 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5572/* end confdefs.h. */
5573$ac_includes_default
5574int
5575main ()
5576{
5577static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
5578test_array [0] = 0
5579
5580 ;
5581 return 0;
5582}
5583_ACEOF
5584if ac_fn_c_try_compile "$LINENO"; then :
5585
5586cat >>confdefs.h <<_ACEOF
5587#define intptr_t $ac_type
5588_ACEOF
5589
5590 ac_type=
5591fi
5592rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5593 test -z "$ac_type" && break
5594 done
5595fi
5596
5597
5598
5599 ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default"
5600if test "x$ac_cv_type_uintptr_t" = x""yes; then :
5601
5602$as_echo "#define HAVE_UINTPTR_T 1" >>confdefs.h
5603
5604else
5605 for ac_type in 'unsigned int' 'unsigned long int' \
5606 'unsigned long long int'; do
5607 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5608/* end confdefs.h. */
5609$ac_includes_default
5610int
5611main ()
5612{
5613static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
5614test_array [0] = 0
5615
5616 ;
5617 return 0;
5618}
5619_ACEOF
5620if ac_fn_c_try_compile "$LINENO"; then :
5621
5622cat >>confdefs.h <<_ACEOF
5623#define uintptr_t $ac_type
5624_ACEOF
5625
5626 ac_type=
5627fi
5628rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5629 test -z "$ac_type" && break
5630 done
5631fi
5632
5633
ebb6c20c 5634ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default"
5635if test "x$ac_cv_type_ssize_t" = x""yes; then :
5636
5637else
5638
5639cat >>confdefs.h <<_ACEOF
5640#define ssize_t int
5641_ACEOF
5642
5643fi
5644
65e17bf6 5645
cd9a469c 5646# Given the above check, we always have uintptr_t or a fallback
5647# definition. So define HAVE_UINTPTR_T in case any imported code
5648# relies on it.
a6089b1e 5649
cd9a469c 5650$as_echo "#define HAVE_UINTPTR_T 1" >>confdefs.h
90305aaf 5651
5652
cd9a469c 5653ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
5654if test "x$ac_cv_type_pid_t" = x""yes; then :
90305aaf 5655
cd9a469c 5656else
90305aaf 5657
cd9a469c 5658cat >>confdefs.h <<_ACEOF
5659#define pid_t int
5660_ACEOF
90305aaf 5661
cd9a469c 5662fi
90305aaf 5663
5664
cd9a469c 5665# This is the list of functions which libiberty will provide if they
5666# are not available on the host.
90305aaf 5667
cd9a469c 5668funcs="asprintf"
5669funcs="$funcs atexit"
5670funcs="$funcs basename"
5671funcs="$funcs bcmp"
5672funcs="$funcs bcopy"
5673funcs="$funcs bsearch"
5674funcs="$funcs bzero"
5675funcs="$funcs calloc"
5676funcs="$funcs clock"
5677funcs="$funcs ffs"
5678funcs="$funcs getcwd"
5679funcs="$funcs getpagesize"
5680funcs="$funcs gettimeofday"
5681funcs="$funcs index"
5682funcs="$funcs insque"
5683funcs="$funcs memchr"
5684funcs="$funcs memcmp"
5685funcs="$funcs memcpy"
5686funcs="$funcs memmem"
5687funcs="$funcs memmove"
5688funcs="$funcs mempcpy"
5689funcs="$funcs memset"
5690funcs="$funcs mkstemps"
5691funcs="$funcs putenv"
5692funcs="$funcs random"
5693funcs="$funcs rename"
5694funcs="$funcs rindex"
5695funcs="$funcs setenv"
5696funcs="$funcs snprintf"
5697funcs="$funcs sigsetmask"
5698funcs="$funcs stpcpy"
5699funcs="$funcs stpncpy"
5700funcs="$funcs strcasecmp"
5701funcs="$funcs strchr"
5702funcs="$funcs strdup"
5703funcs="$funcs strncasecmp"
5704funcs="$funcs strndup"
c7babc8d 5705funcs="$funcs strnlen"
cd9a469c 5706funcs="$funcs strrchr"
5707funcs="$funcs strstr"
5708funcs="$funcs strtod"
5709funcs="$funcs strtol"
5710funcs="$funcs strtoul"
5e1a5aba 5711funcs="$funcs strtoll"
5712funcs="$funcs strtoull"
cd9a469c 5713funcs="$funcs strverscmp"
5714funcs="$funcs tmpnam"
5715funcs="$funcs vasprintf"
5716funcs="$funcs vfprintf"
5717funcs="$funcs vprintf"
5718funcs="$funcs vsnprintf"
5719funcs="$funcs vsprintf"
5720funcs="$funcs waitpid"
a3de1f55 5721funcs="$funcs setproctitle"
a6089b1e 5722
cd9a469c 5723# Also in the old function.def file: alloca, vfork, getopt.
5724
5725vars="sys_errlist sys_nerr sys_siglist"
5726
00dacc40 5727checkfuncs="__fsetlocking canonicalize_file_name dup3 getrlimit getrusage \
5728 getsysinfo gettimeofday on_exit psignal pstat_getdynamic pstat_getstatic \
5729 realpath setrlimit sbrk spawnve spawnvpe strerror strsignal sysconf sysctl \
5730 sysmp table times wait3 wait4"
cd9a469c 5731
5732# These are neither executed nor required, but they help keep
5733# autoheader happy without adding a bunch of text to acconfig.h.
5734if test "x" = "y"; then
3b79ad9b 5735 for ac_func in asprintf atexit \
5736 basename bcmp bcopy bsearch bzero \
5737 calloc canonicalize_file_name clock \
392b7e30 5738 dup3 \
3b79ad9b 5739 ffs __fsetlocking \
00dacc40 5740 getcwd getpagesize getrlimit getrusage getsysinfo gettimeofday \
3b79ad9b 5741 index insque \
5742 memchr memcmp memcpy memmem memmove memset mkstemps \
5743 on_exit \
5744 psignal pstat_getdynamic pstat_getstatic putenv \
5745 random realpath rename rindex \
00dacc40 5746 sbrk setenv setproctitle setrlimit sigsetmask snprintf spawnve spawnvpe \
392b7e30 5747 stpcpy stpncpy strcasecmp strchr strdup \
c7babc8d 5748 strerror strncasecmp strndup strnlen strrchr strsignal strstr strtod \
5e1a5aba 5749 strtol strtoul strtoll strtoull strverscmp sysconf sysctl sysmp \
3b79ad9b 5750 table times tmpnam \
5751 vasprintf vfprintf vprintf vsprintf \
5752 wait3 wait4 waitpid
cd9a469c 5753do :
5754 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
5755ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
5756eval as_val=\$$as_ac_var
5757 if test "x$as_val" = x""yes; then :
90305aaf 5758 cat >>confdefs.h <<_ACEOF
cd9a469c 5759#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
a6089b1e 5760_ACEOF
5761
5762fi
90305aaf 5763done
a6089b1e 5764
050318d9 5765 ac_fn_c_check_decl "$LINENO" "basename(char *)" "ac_cv_have_decl_basename_char_p_" "$ac_includes_default"
5766if test "x$ac_cv_have_decl_basename_char_p_" = x""yes; then :
cd9a469c 5767 ac_have_decl=1
4927c18d 5768else
cd9a469c 5769 ac_have_decl=0
5770fi
5771
5772cat >>confdefs.h <<_ACEOF
5773#define HAVE_DECL_BASENAME $ac_have_decl
4927c18d 5774_ACEOF
cd9a469c 5775ac_fn_c_check_decl "$LINENO" "ffs" "ac_cv_have_decl_ffs" "$ac_includes_default"
5776if test "x$ac_cv_have_decl_ffs" = x""yes; then :
5777 ac_have_decl=1
4927c18d 5778else
cd9a469c 5779 ac_have_decl=0
4927c18d 5780fi
cd9a469c 5781
5782cat >>confdefs.h <<_ACEOF
5783#define HAVE_DECL_FFS $ac_have_decl
5784_ACEOF
5785ac_fn_c_check_decl "$LINENO" "asprintf" "ac_cv_have_decl_asprintf" "$ac_includes_default"
5786if test "x$ac_cv_have_decl_asprintf" = x""yes; then :
5787 ac_have_decl=1
5788else
5789 ac_have_decl=0
4927c18d 5790fi
4927c18d 5791
cd9a469c 5792cat >>confdefs.h <<_ACEOF
5793#define HAVE_DECL_ASPRINTF $ac_have_decl
5794_ACEOF
5795ac_fn_c_check_decl "$LINENO" "vasprintf" "ac_cv_have_decl_vasprintf" "$ac_includes_default"
5796if test "x$ac_cv_have_decl_vasprintf" = x""yes; then :
5797 ac_have_decl=1
4927c18d 5798else
cd9a469c 5799 ac_have_decl=0
5800fi
5801
5802cat >>confdefs.h <<_ACEOF
5803#define HAVE_DECL_VASPRINTF $ac_have_decl
4927c18d 5804_ACEOF
cd9a469c 5805ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
5806if test "x$ac_cv_have_decl_snprintf" = x""yes; then :
5807 ac_have_decl=1
5808else
5809 ac_have_decl=0
5810fi
4927c18d 5811
cd9a469c 5812cat >>confdefs.h <<_ACEOF
5813#define HAVE_DECL_SNPRINTF $ac_have_decl
4927c18d 5814_ACEOF
cd9a469c 5815ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
5816if test "x$ac_cv_have_decl_vsnprintf" = x""yes; then :
5817 ac_have_decl=1
5818else
5819 ac_have_decl=0
5820fi
5821
5822cat >>confdefs.h <<_ACEOF
5823#define HAVE_DECL_VSNPRINTF $ac_have_decl
4927c18d 5824_ACEOF
5e1a5aba 5825ac_fn_c_check_decl "$LINENO" "strtol" "ac_cv_have_decl_strtol" "$ac_includes_default"
5826if test "x$ac_cv_have_decl_strtol" = x""yes; then :
5827 ac_have_decl=1
5828else
5829 ac_have_decl=0
5830fi
5831
5832cat >>confdefs.h <<_ACEOF
5833#define HAVE_DECL_STRTOL $ac_have_decl
5834_ACEOF
5835ac_fn_c_check_decl "$LINENO" "strtoul" "ac_cv_have_decl_strtoul" "$ac_includes_default"
5836if test "x$ac_cv_have_decl_strtoul" = x""yes; then :
5837 ac_have_decl=1
5838else
5839 ac_have_decl=0
5840fi
5841
5842cat >>confdefs.h <<_ACEOF
5843#define HAVE_DECL_STRTOUL $ac_have_decl
5844_ACEOF
5845ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
5846if test "x$ac_cv_have_decl_strtoll" = x""yes; then :
5847 ac_have_decl=1
5848else
5849 ac_have_decl=0
5850fi
5851
5852cat >>confdefs.h <<_ACEOF
5853#define HAVE_DECL_STRTOLL $ac_have_decl
5854_ACEOF
5855ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
5856if test "x$ac_cv_have_decl_strtoull" = x""yes; then :
5857 ac_have_decl=1
5858else
5859 ac_have_decl=0
5860fi
5861
5862cat >>confdefs.h <<_ACEOF
5863#define HAVE_DECL_STRTOULL $ac_have_decl
5864_ACEOF
4927c18d 5865
4927c18d 5866
cd9a469c 5867$as_echo "#define HAVE_SYS_ERRLIST 1" >>confdefs.h
4927c18d 5868
4927c18d 5869
cd9a469c 5870$as_echo "#define HAVE_SYS_NERR 1" >>confdefs.h
4927c18d 5871
4927c18d 5872
cd9a469c 5873$as_echo "#define HAVE_SYS_SIGLIST 1" >>confdefs.h
4927c18d 5874
4927c18d 5875fi
4927c18d 5876
cd9a469c 5877# For each of these functions, if the host does not provide the
5878# function we want to put FN.o in LIBOBJS, and if the host does
5879# provide the function, we want to define HAVE_FN in config.h.
4927c18d 5880
cd9a469c 5881setobjs=
5882CHECK=
cd9a469c 5883if test -n "${with_target_subdir}"; then
4927c18d 5884
cd9a469c 5885 # We are being configured as a target library. AC_REPLACE_FUNCS
5886 # may not work correctly, because the compiler may not be able to
5887 # link executables. Note that we may still be being configured
5888 # native.
4927c18d 5889
cd9a469c 5890 # If we are being configured for newlib, we know which functions
5891 # newlib provide and which ones we will be expected to provide.
4927c18d 5892
cd9a469c 5893 if test "x${with_newlib}" = "xyes"; then
5894 case " $LIBOBJS " in
5895 *" asprintf.$ac_objext "* ) ;;
5896 *) LIBOBJS="$LIBOBJS asprintf.$ac_objext"
5897 ;;
5898esac
4927c18d 5899
cd9a469c 5900 case " $LIBOBJS " in
5901 *" basename.$ac_objext "* ) ;;
5902 *) LIBOBJS="$LIBOBJS basename.$ac_objext"
5903 ;;
5904esac
4927c18d 5905
cd9a469c 5906 case " $LIBOBJS " in
5907 *" insque.$ac_objext "* ) ;;
5908 *) LIBOBJS="$LIBOBJS insque.$ac_objext"
5909 ;;
5910esac
4927c18d 5911
cd9a469c 5912 case " $LIBOBJS " in
5913 *" random.$ac_objext "* ) ;;
5914 *) LIBOBJS="$LIBOBJS random.$ac_objext"
5915 ;;
5916esac
7b190504 5917
cd9a469c 5918 case " $LIBOBJS " in
5919 *" strdup.$ac_objext "* ) ;;
5920 *) LIBOBJS="$LIBOBJS strdup.$ac_objext"
5921 ;;
5922esac
a6089b1e 5923
cd9a469c 5924 case " $LIBOBJS " in
5925 *" vasprintf.$ac_objext "* ) ;;
5926 *) LIBOBJS="$LIBOBJS vasprintf.$ac_objext"
5927 ;;
5928esac
5929
5930
5931 for f in $funcs; do
5932 case "$f" in
5933 asprintf | basename | insque | random | strdup | vasprintf)
5934 ;;
5935 *)
5936 n=HAVE_`echo $f | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5937 cat >>confdefs.h <<_ACEOF
5938#define $n 1
a6089b1e 5939_ACEOF
b6477ce7 5940
cd9a469c 5941 ;;
5942 esac
5943 done
a6089b1e 5944
cd9a469c 5945 # newlib doesnt provide any of the variables in $vars, so we
5946 # dont have to check them here.
a6089b1e 5947
cd9a469c 5948 # Of the functions in $checkfuncs, newlib only has strerror.
5949 $as_echo "#define HAVE_STRERROR 1" >>confdefs.h
a6089b1e 5950
5951
cd9a469c 5952 setobjs=yes
a6089b1e 5953
cd9a469c 5954 fi
a6089b1e 5955
cd9a469c 5956 # If we are being configured for Mingw, we know which functions
5957 # Mingw provides and which ones we will be expected to provide.
a6089b1e 5958
cd9a469c 5959 case "${host}" in
5960 *-*-mingw*)
5961 case " $LIBOBJS " in
5962 *" asprintf.$ac_objext "* ) ;;
5963 *) LIBOBJS="$LIBOBJS asprintf.$ac_objext"
5964 ;;
5965esac
a6089b1e 5966
cd9a469c 5967 case " $LIBOBJS " in
5968 *" basename.$ac_objext "* ) ;;
5969 *) LIBOBJS="$LIBOBJS basename.$ac_objext"
5970 ;;
5971esac
a6089b1e 5972
cd9a469c 5973 case " $LIBOBJS " in
5974 *" bcmp.$ac_objext "* ) ;;
5975 *) LIBOBJS="$LIBOBJS bcmp.$ac_objext"
5976 ;;
5977esac
a6089b1e 5978
cd9a469c 5979 case " $LIBOBJS " in
5980 *" bcopy.$ac_objext "* ) ;;
5981 *) LIBOBJS="$LIBOBJS bcopy.$ac_objext"
5982 ;;
5983esac
a6089b1e 5984
cd9a469c 5985 case " $LIBOBJS " in
5986 *" bzero.$ac_objext "* ) ;;
5987 *) LIBOBJS="$LIBOBJS bzero.$ac_objext"
5988 ;;
5989esac
a6089b1e 5990
cd9a469c 5991 case " $LIBOBJS " in
5992 *" clock.$ac_objext "* ) ;;
5993 *) LIBOBJS="$LIBOBJS clock.$ac_objext"
5994 ;;
5995esac
a6089b1e 5996
cd9a469c 5997 case " $LIBOBJS " in
5998 *" ffs.$ac_objext "* ) ;;
5999 *) LIBOBJS="$LIBOBJS ffs.$ac_objext"
6000 ;;
6001esac
a6089b1e 6002
cd9a469c 6003 case " $LIBOBJS " in
6004 *" getpagesize.$ac_objext "* ) ;;
6005 *) LIBOBJS="$LIBOBJS getpagesize.$ac_objext"
6006 ;;
6007esac
a6089b1e 6008
cd9a469c 6009 case " $LIBOBJS " in
6010 *" index.$ac_objext "* ) ;;
6011 *) LIBOBJS="$LIBOBJS index.$ac_objext"
6012 ;;
6013esac
a6089b1e 6014
cd9a469c 6015 case " $LIBOBJS " in
6016 *" insque.$ac_objext "* ) ;;
6017 *) LIBOBJS="$LIBOBJS insque.$ac_objext"
6018 ;;
6019esac
a6089b1e 6020
cd9a469c 6021 case " $LIBOBJS " in
6022 *" mempcpy.$ac_objext "* ) ;;
6023 *) LIBOBJS="$LIBOBJS mempcpy.$ac_objext"
6024 ;;
6025esac
a6089b1e 6026
cd9a469c 6027 case " $LIBOBJS " in
6028 *" mkstemps.$ac_objext "* ) ;;
6029 *) LIBOBJS="$LIBOBJS mkstemps.$ac_objext"
6030 ;;
6031esac
a6089b1e 6032
cd9a469c 6033 case " $LIBOBJS " in
6034 *" random.$ac_objext "* ) ;;
6035 *) LIBOBJS="$LIBOBJS random.$ac_objext"
6036 ;;
6037esac
a6089b1e 6038
cd9a469c 6039 case " $LIBOBJS " in
6040 *" rindex.$ac_objext "* ) ;;
6041 *) LIBOBJS="$LIBOBJS rindex.$ac_objext"
6042 ;;
6043esac
a6089b1e 6044
cd9a469c 6045 case " $LIBOBJS " in
6046 *" sigsetmask.$ac_objext "* ) ;;
6047 *) LIBOBJS="$LIBOBJS sigsetmask.$ac_objext"
6048 ;;
6049esac
a6089b1e 6050
cd9a469c 6051 case " $LIBOBJS " in
6052 *" stpcpy.$ac_objext "* ) ;;
6053 *) LIBOBJS="$LIBOBJS stpcpy.$ac_objext"
6054 ;;
6055esac
a6089b1e 6056
cd9a469c 6057 case " $LIBOBJS " in
6058 *" stpncpy.$ac_objext "* ) ;;
6059 *) LIBOBJS="$LIBOBJS stpncpy.$ac_objext"
6060 ;;
6061esac
a6089b1e 6062
cd9a469c 6063 case " $LIBOBJS " in
6064 *" strndup.$ac_objext "* ) ;;
6065 *) LIBOBJS="$LIBOBJS strndup.$ac_objext"
6066 ;;
6067esac
a6089b1e 6068
c7babc8d 6069 case " $LIBOBJS " in
6070 *" strnlen.$ac_objext "* ) ;;
6071 *) LIBOBJS="$LIBOBJS strnlen.$ac_objext"
6072 ;;
6073esac
6074
cd9a469c 6075 case " $LIBOBJS " in
6076 *" strverscmp.$ac_objext "* ) ;;
6077 *) LIBOBJS="$LIBOBJS strverscmp.$ac_objext"
6078 ;;
6079esac
a6089b1e 6080
cd9a469c 6081 case " $LIBOBJS " in
6082 *" vasprintf.$ac_objext "* ) ;;
6083 *) LIBOBJS="$LIBOBJS vasprintf.$ac_objext"
6084 ;;
6085esac
a6089b1e 6086
cd9a469c 6087 case " $LIBOBJS " in
6088 *" waitpid.$ac_objext "* ) ;;
6089 *) LIBOBJS="$LIBOBJS waitpid.$ac_objext"
6090 ;;
6091esac
a6089b1e 6092
6093
cd9a469c 6094 for f in $funcs; do
6095 case "$f" in
c7babc8d 6096 asprintf | basename | bcmp | bcopy | bzero | clock | ffs | getpagesize | index | insque | mempcpy | mkstemps | random | rindex | sigsetmask | stpcpy | stpncpy | strdup | strndup | strnlen | strverscmp | vasprintf | waitpid)
cd9a469c 6097 ;;
6098 *)
6099 n=HAVE_`echo $f | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6100 cat >>confdefs.h <<_ACEOF
6101#define $n 1
6102_ACEOF
a6089b1e 6103
cd9a469c 6104 ;;
6105 esac
6106 done
a6089b1e 6107
cd9a469c 6108 # Mingw doesnt provide any of the variables in $vars, so we
6109 # dont have to check them here.
a6089b1e 6110
cd9a469c 6111 # Of the functions in $checkfuncs, Mingw only has strerror.
6112 $as_echo "#define HAVE_STRERROR 1" >>confdefs.h
a6089b1e 6113
6114
cd9a469c 6115 setobjs=yes
6116 ;;
a6089b1e 6117
cd9a469c 6118 *-*-msdosdjgpp)
6119 case " $LIBOBJS " in
6120 *" vasprintf.$ac_objext "* ) ;;
6121 *) LIBOBJS="$LIBOBJS vasprintf.$ac_objext"
6122 ;;
6123esac
a6089b1e 6124
cd9a469c 6125 case " $LIBOBJS " in
6126 *" vsnprintf.$ac_objext "* ) ;;
6127 *) LIBOBJS="$LIBOBJS vsnprintf.$ac_objext"
6128 ;;
6129esac
a6089b1e 6130
cd9a469c 6131 case " $LIBOBJS " in
6132 *" snprintf.$ac_objext "* ) ;;
6133 *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
6134 ;;
6135esac
a6089b1e 6136
cd9a469c 6137 case " $LIBOBJS " in
6138 *" asprintf.$ac_objext "* ) ;;
6139 *) LIBOBJS="$LIBOBJS asprintf.$ac_objext"
6140 ;;
6141esac
a6089b1e 6142
6143
cd9a469c 6144 for f in atexit basename bcmp bcopy bsearch bzero calloc clock ffs \
6145 getcwd getpagesize getrusage gettimeofday \
6146 index insque memchr memcmp memcpy memmove memset psignal \
6147 putenv random rename rindex sbrk setenv stpcpy strcasecmp \
6148 strchr strdup strerror strncasecmp strrchr strstr strtod \
6149 strtol strtoul sysconf times tmpnam vfprintf vprintf \
6150 vsprintf waitpid
6151 do
6152 n=HAVE_`echo $f | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6153 cat >>confdefs.h <<_ACEOF
6154#define $n 1
6155_ACEOF
a6089b1e 6156
cd9a469c 6157 done
a6089b1e 6158
a2ef32b0 6159
cd9a469c 6160 setobjs=yes
6161 ;;
a2ef32b0 6162
cd9a469c 6163 esac
8e1547da 6164
f0a93313 6165else
a6089b1e 6166
cd9a469c 6167 # Not a target library, so we set things up to run the test suite.
6168 CHECK=really-check
f0a93313 6169
6170fi
6171
a6089b1e 6172
a6089b1e 6173
a6089b1e 6174
cd9a469c 6175case "${host}" in
6176 *-*-cygwin* | *-*-mingw*)
6177 $as_echo "#define HAVE_SYS_ERRLIST 1" >>confdefs.h
a6089b1e 6178
cd9a469c 6179 $as_echo "#define HAVE_SYS_NERR 1" >>confdefs.h
a6089b1e 6180
cd9a469c 6181 ;;
6182esac
f0a93313 6183
cd9a469c 6184if test -z "${setobjs}"; then
6185 case "${host}" in
f0a93313 6186
cd9a469c 6187 *-*-vxworks*)
6188 # Handle VxWorks configuration specially, since on VxWorks the
6189 # libraries are actually on the target board, not in the file
6190 # system.
6191 case " $LIBOBJS " in
6192 *" basename.$ac_objext "* ) ;;
6193 *) LIBOBJS="$LIBOBJS basename.$ac_objext"
6194 ;;
ac09b42b 6195esac
6196
cd9a469c 6197 case " $LIBOBJS " in
6198 *" getpagesize.$ac_objext "* ) ;;
6199 *) LIBOBJS="$LIBOBJS getpagesize.$ac_objext"
6200 ;;
6201esac
a6089b1e 6202
cd9a469c 6203 case " $LIBOBJS " in
6204 *" insque.$ac_objext "* ) ;;
6205 *) LIBOBJS="$LIBOBJS insque.$ac_objext"
6206 ;;
6207esac
31972771 6208
cd9a469c 6209 case " $LIBOBJS " in
6210 *" random.$ac_objext "* ) ;;
6211 *) LIBOBJS="$LIBOBJS random.$ac_objext"
6212 ;;
6213esac
a6089b1e 6214
cd9a469c 6215 case " $LIBOBJS " in
6216 *" strcasecmp.$ac_objext "* ) ;;
6217 *) LIBOBJS="$LIBOBJS strcasecmp.$ac_objext"
6218 ;;
6219esac
a6089b1e 6220
cd9a469c 6221 case " $LIBOBJS " in
6222 *" strncasecmp.$ac_objext "* ) ;;
6223 *) LIBOBJS="$LIBOBJS strncasecmp.$ac_objext"
6224 ;;
ac09b42b 6225esac
6226
cd9a469c 6227 case " $LIBOBJS " in
6228 *" strdup.$ac_objext "* ) ;;
6229 *) LIBOBJS="$LIBOBJS strdup.$ac_objext"
6230 ;;
6231esac
31972771 6232
cd9a469c 6233 case " $LIBOBJS " in
6234 *" vfork.$ac_objext "* ) ;;
6235 *) LIBOBJS="$LIBOBJS vfork.$ac_objext"
6236 ;;
6237esac
31972771 6238
cd9a469c 6239 case " $LIBOBJS " in
6240 *" waitpid.$ac_objext "* ) ;;
6241 *) LIBOBJS="$LIBOBJS waitpid.$ac_objext"
6242 ;;
6243esac
a6089b1e 6244
cd9a469c 6245 case " $LIBOBJS " in
6246 *" vasprintf.$ac_objext "* ) ;;
6247 *) LIBOBJS="$LIBOBJS vasprintf.$ac_objext"
6248 ;;
6249esac
98b6fc70 6250
cd9a469c 6251 for f in $funcs; do
6252 case "$f" in
6253 basename | getpagesize | insque | random | strcasecmp)
6254 ;;
6255 strncasecmp | strdup | vfork | waitpid | vasprintf)
6256 ;;
6257 *)
6258 n=HAVE_`echo $f | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6259 cat >>confdefs.h <<_ACEOF
6260#define $n 1
a6089b1e 6261_ACEOF
a6089b1e 6262
cd9a469c 6263 ;;
6264 esac
6265 done
98b6fc70 6266
cd9a469c 6267 # VxWorks doesn't provide any of the variables in $vars, so we
6268 # don't have to check them here.
98b6fc70 6269
cd9a469c 6270 # Of the functions in $checkfuncs, VxWorks only has strerror.
6271 $as_echo "#define HAVE_STRERROR 1" >>confdefs.h
31972771 6272
a6089b1e 6273
cd9a469c 6274 setobjs=yes
6275 ;;
6276
6277 esac
f0a93313 6278fi
6279
cd9a469c 6280if test -z "${setobjs}"; then
f0a93313 6281
cd9a469c 6282 case "${host}" in
5e90539e 6283
2ed4d1b7 6284 *-*-android*)
6285 # On android, getpagesize is defined in unistd.h as a static inline
6286 # function, which AC_CHECK_FUNCS does not handle properly.
6287 ac_cv_func_getpagesize=yes
6288 ;;
6289
cd9a469c 6290 *-*-mingw32*)
6291 # Under mingw32, sys_nerr and sys_errlist exist, but they are
6292 # macros, so the test below won't find them.
6293 libiberty_cv_var_sys_nerr=yes
6294 libiberty_cv_var_sys_errlist=yes
6295 ;;
a6089b1e 6296
cd9a469c 6297 *-*-msdosdjgpp*)
6298 # vfork and fork are stubs.
6299 ac_cv_func_vfork_works=no
6300 ;;
5e90539e 6301
cd9a469c 6302 *-*-uwin*)
6303 # Under some versions of uwin, vfork is notoriously buggy and the test
6304 # can hang configure; on other versions, vfork exists just as a stub.
6305 # FIXME: This should be removed once vfork in uwin's runtime is fixed.
6306 ac_cv_func_vfork_works=no
6307 # Under uwin 2.0+, sys_nerr and sys_errlist exist, but they are
6308 # macros (actually, these are imported from a DLL, but the end effect
6309 # is the same), so the test below won't find them.
6310 libiberty_cv_var_sys_nerr=yes
6311 libiberty_cv_var_sys_errlist=yes
6312 ;;
a6089b1e 6313
cd9a469c 6314 *-*-*vms*)
6315 # Under VMS, vfork works very different than on Unix. The standard test
6316 # won't work, and it isn't easily adaptable. It makes more sense to
6317 # just force it.
6318 ac_cv_func_vfork_works=yes
6319 ;;
a6089b1e 6320
cd9a469c 6321 esac
5e90539e 6322
cd9a469c 6323 # We haven't set the list of objects yet. Use the standard autoconf
6324 # tests. This will only work if the compiler works.
6325 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing strerror" >&5
6326$as_echo_n "checking for library containing strerror... " >&6; }
6327if test "${ac_cv_search_strerror+set}" = set; then :
6328 $as_echo_n "(cached) " >&6
a6089b1e 6329else
cd9a469c 6330 ac_func_search_save_LIBS=$LIBS
6331cat confdefs.h - <<_ACEOF >conftest.$ac_ext
a6089b1e 6332/* end confdefs.h. */
cd9a469c 6333
6334/* Override any GCC internal prototype to avoid an error.
6335 Use char because int might match the return type of a GCC
a6089b1e 6336 builtin and then its argument prototype would still apply. */
a6089b1e 6337#ifdef __cplusplus
cd9a469c 6338extern "C"
f0a93313 6339#endif
cd9a469c 6340char strerror ();
a6089b1e 6341int
6342main ()
6343{
cd9a469c 6344return strerror ();
a6089b1e 6345 ;
6346 return 0;
6347}
6348_ACEOF
cd9a469c 6349for ac_lib in '' cposix; do
6350 if test -z "$ac_lib"; then
6351 ac_res="none required"
6352 else
6353 ac_res=-l$ac_lib
6354 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
6355 fi
6356 if test x$gcc_no_link = xyes; then
6357 as_fn_error "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5
6358fi
6359if ac_fn_c_try_link "$LINENO"; then :
6360 ac_cv_search_strerror=$ac_res
6361fi
6362rm -f core conftest.err conftest.$ac_objext \
6363 conftest$ac_exeext
6364 if test "${ac_cv_search_strerror+set}" = set; then :
6365 break
6366fi
6367done
6368if test "${ac_cv_search_strerror+set}" = set; then :
a6089b1e 6369
cd9a469c 6370else
6371 ac_cv_search_strerror=no
a6089b1e 6372fi
cd9a469c 6373rm conftest.$ac_ext
6374LIBS=$ac_func_search_save_LIBS
6375fi
6376{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_strerror" >&5
6377$as_echo "$ac_cv_search_strerror" >&6; }
6378ac_res=$ac_cv_search_strerror
6379if test "$ac_res" != no; then :
6380 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6381
a6089b1e 6382fi
cd9a469c 6383
6384 for ac_func in $funcs
6385do :
6386 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
6387ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
6388eval as_val=\$$as_ac_var
6389 if test "x$as_val" = x""yes; then :
a6089b1e 6390 cat >>confdefs.h <<_ACEOF
cd9a469c 6391#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
a6089b1e 6392_ACEOF
f0a93313 6393
cd9a469c 6394else
6395 case " $LIBOBJS " in
6396 *" $ac_func.$ac_objext "* ) ;;
6397 *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
6398 ;;
6399esac
6400
f0a93313 6401fi
6402done
6403
cd9a469c 6404
6405 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether alloca needs Cray hooks" >&5
6406$as_echo_n "checking whether alloca needs Cray hooks... " >&6; }
6407if test "${ac_cv_os_cray+set}" = set; then :
6408 $as_echo_n "(cached) " >&6
9459c273 6409else
cd9a469c 6410 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9459c273 6411/* end confdefs.h. */
cd9a469c 6412#if defined(CRAY) && ! defined(CRAY2)
6413webecray
6414#else
6415wenotbecray
9459c273 6416#endif
6417
9459c273 6418_ACEOF
cd9a469c 6419if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6420 $EGREP "webecray" >/dev/null 2>&1; then :
6421 ac_cv_os_cray=yes
9459c273 6422else
cd9a469c 6423 ac_cv_os_cray=no
9459c273 6424fi
cd9a469c 6425rm -f conftest*
6426
9459c273 6427fi
cd9a469c 6428{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
6429$as_echo "$ac_cv_os_cray" >&6; }
6430if test $ac_cv_os_cray = yes; then
6431 for ac_func in _getb67 GETB67 getb67; do
6432 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
6433ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
6434eval as_val=\$$as_ac_var
6435 if test "x$as_val" = x""yes; then :
9459c273 6436
6437cat >>confdefs.h <<_ACEOF
cd9a469c 6438#define CRAY_STACKSEG_END $ac_func
9459c273 6439_ACEOF
cd9a469c 6440 break
6441fi
9459c273 6442
cd9a469c 6443 done
6444fi
9459c273 6445
cd9a469c 6446{ $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
6447$as_echo_n "checking stack direction for C alloca... " >&6; }
6448if test "${ac_cv_c_stack_direction+set}" = set; then :
6449 $as_echo_n "(cached) " >&6
9459c273 6450else
cd9a469c 6451 if test "$cross_compiling" = yes; then :
6452 ac_cv_c_stack_direction=0
9459c273 6453else
cd9a469c 6454 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9459c273 6455/* end confdefs.h. */
cd9a469c 6456find_stack_direction ()
6457{
6458 static char *addr = 0;
6459 auto char dummy;
6460 if (addr == 0)
6461 {
6462 addr = &dummy;
6463 return find_stack_direction ();
6464 }
6465 else
6466 return (&dummy > addr) ? 1 : -1;
6467}
9459c273 6468main ()
6469{
cd9a469c 6470 exit (find_stack_direction() < 0);
9459c273 6471}
6472_ACEOF
cd9a469c 6473if ac_fn_c_try_run "$LINENO"; then :
6474 ac_cv_c_stack_direction=1
9459c273 6475else
cd9a469c 6476 ac_cv_c_stack_direction=-1
6477fi
6478rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6479 conftest.$ac_objext conftest.beam conftest.$ac_ext
9459c273 6480fi
cd9a469c 6481
9459c273 6482fi
cd9a469c 6483{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
6484$as_echo "$ac_cv_c_stack_direction" >&6; }
9459c273 6485
6486cat >>confdefs.h <<_ACEOF
cd9a469c 6487#define STACK_DIRECTION $ac_cv_c_stack_direction
9459c273 6488_ACEOF
6489
6490
cd9a469c 6491 for ac_header in vfork.h
6492do :
6493 ac_fn_c_check_header_preproc "$LINENO" "vfork.h" "ac_cv_header_vfork_h"
6494if test "x$ac_cv_header_vfork_h" = x""yes; then :
9459c273 6495 cat >>confdefs.h <<_ACEOF
cd9a469c 6496#define HAVE_VFORK_H 1
9459c273 6497_ACEOF
6498
cd9a469c 6499fi
6500done
6501
6502for ac_func in fork vfork
6503do :
6504 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
6505ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
6506eval as_val=\$$as_ac_var
6507 if test "x$as_val" = x""yes; then :
6508 cat >>confdefs.h <<_ACEOF
6509#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
6510_ACEOF
9459c273 6511
6512fi
cd9a469c 6513done
6514
6515if test "x$ac_cv_func_fork" = xyes; then
6516 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
6517$as_echo_n "checking for working fork... " >&6; }
6518if test "${ac_cv_func_fork_works+set}" = set; then :
6519 $as_echo_n "(cached) " >&6
9459c273 6520else
cd9a469c 6521 if test "$cross_compiling" = yes; then :
6522 ac_cv_func_fork_works=cross
6523else
6524 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9459c273 6525/* end confdefs.h. */
6526$ac_includes_default
6527int
6528main ()
6529{
cd9a469c 6530
6531 /* By Ruediger Kuhlmann. */
6532 return fork () < 0;
9459c273 6533
6534 ;
6535 return 0;
6536}
6537_ACEOF
cd9a469c 6538if ac_fn_c_try_run "$LINENO"; then :
6539 ac_cv_func_fork_works=yes
9459c273 6540else
cd9a469c 6541 ac_cv_func_fork_works=no
9459c273 6542fi
cd9a469c 6543rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6544 conftest.$ac_objext conftest.beam conftest.$ac_ext
9459c273 6545fi
9459c273 6546
cd9a469c 6547fi
6548{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
6549$as_echo "$ac_cv_func_fork_works" >&6; }
9459c273 6550
6551else
cd9a469c 6552 ac_cv_func_fork_works=$ac_cv_func_fork
6553fi
6554if test "x$ac_cv_func_fork_works" = xcross; then
6555 case $host in
6556 *-*-amigaos* | *-*-msdosdjgpp*)
6557 # Override, as these systems have only a dummy fork() stub
6558 ac_cv_func_fork_works=no
6559 ;;
6560 *)
6561 ac_cv_func_fork_works=yes
6562 ;;
6563 esac
6564 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
6565$as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
9459c273 6566fi
cd9a469c 6567ac_cv_func_vfork_works=$ac_cv_func_vfork
6568if test "x$ac_cv_func_vfork" = xyes; then
6569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
6570$as_echo_n "checking for working vfork... " >&6; }
6571if test "${ac_cv_func_vfork_works+set}" = set; then :
6572 $as_echo_n "(cached) " >&6
9459c273 6573else
cd9a469c 6574 if test "$cross_compiling" = yes; then :
6575 ac_cv_func_vfork_works=cross
6576else
6577 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9459c273 6578/* end confdefs.h. */
cd9a469c 6579/* Thanks to Paul Eggert for this test. */
9459c273 6580$ac_includes_default
cd9a469c 6581#include <sys/wait.h>
6582#ifdef HAVE_VFORK_H
6583# include <vfork.h>
6584#endif
6585/* On some sparc systems, changes by the child to local and incoming
6586 argument registers are propagated back to the parent. The compiler
6587 is told about this with #include <vfork.h>, but some compilers
6588 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
6589 static variable whose address is put into a register that is
6590 clobbered by the vfork. */
6591static void
6592#ifdef __cplusplus
6593sparc_address_test (int arg)
6594# else
6595sparc_address_test (arg) int arg;
6596#endif
6597{
6598 static pid_t child;
6599 if (!child) {
6600 child = vfork ();
6601 if (child < 0) {
6602 perror ("vfork");
6603 _exit(2);
6604 }
6605 if (!child) {
6606 arg = getpid();
6607 write(-1, "", 0);
6608 _exit (arg);
6609 }
6610 }
6611}
6612
9459c273 6613int
6614main ()
6615{
cd9a469c 6616 pid_t parent = getpid ();
6617 pid_t child;
9459c273 6618
cd9a469c 6619 sparc_address_test (0);
9459c273 6620
cd9a469c 6621 child = vfork ();
9459c273 6622
cd9a469c 6623 if (child == 0) {
6624 /* Here is another test for sparc vfork register problems. This
6625 test uses lots of local variables, at least as many local
6626 variables as main has allocated so far including compiler
6627 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
6628 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
6629 reuse the register of parent for one of the local variables,
6630 since it will think that parent can't possibly be used any more
6631 in this routine. Assigning to the local variable will thus
6632 munge parent in the parent process. */
6633 pid_t
6634 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
6635 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
6636 /* Convince the compiler that p..p7 are live; otherwise, it might
6637 use the same hardware register for all 8 local variables. */
6638 if (p != p1 || p != p2 || p != p3 || p != p4
6639 || p != p5 || p != p6 || p != p7)
6640 _exit(1);
9459c273 6641
cd9a469c 6642 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
6643 from child file descriptors. If the child closes a descriptor
6644 before it execs or exits, this munges the parent's descriptor
6645 as well. Test for this by closing stdout in the child. */
6646 _exit(close(fileno(stdout)) != 0);
6647 } else {
6648 int status;
6649 struct stat st;
9459c273 6650
cd9a469c 6651 while (wait(&status) != child)
6652 ;
6653 return (
6654 /* Was there some problem with vforking? */
6655 child < 0
9459c273 6656
cd9a469c 6657 /* Did the child fail? (This shouldn't happen.) */
6658 || status
9459c273 6659
cd9a469c 6660 /* Did the vfork/compiler bug occur? */
6661 || parent != getpid()
71f27b28 6662
cd9a469c 6663 /* Did the file descriptor bug occur? */
6664 || fstat(fileno(stdout), &st) != 0
6665 );
6666 }
71f27b28 6667}
6668_ACEOF
cd9a469c 6669if ac_fn_c_try_run "$LINENO"; then :
6670 ac_cv_func_vfork_works=yes
71f27b28 6671else
cd9a469c 6672 ac_cv_func_vfork_works=no
6673fi
6674rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6675 conftest.$ac_objext conftest.beam conftest.$ac_ext
6676fi
71f27b28 6677
71f27b28 6678fi
cd9a469c 6679{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
6680$as_echo "$ac_cv_func_vfork_works" >&6; }
6681
6682fi;
6683if test "x$ac_cv_func_fork_works" = xcross; then
6684 ac_cv_func_vfork_works=$ac_cv_func_vfork
6685 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
6686$as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
71f27b28 6687fi
71f27b28 6688
cd9a469c 6689if test "x$ac_cv_func_vfork_works" = xyes; then
71f27b28 6690
cd9a469c 6691$as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
71f27b28 6692
6693else
71f27b28 6694
cd9a469c 6695$as_echo "#define vfork fork" >>confdefs.h
71f27b28 6696
6697fi
cd9a469c 6698if test "x$ac_cv_func_fork_works" = xyes; then
71f27b28 6699
cd9a469c 6700$as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
71f27b28 6701
71f27b28 6702fi
71f27b28 6703
cd9a469c 6704 if test $ac_cv_func_vfork_works = no; then
6705 case " $LIBOBJS " in
6706 *" vfork.$ac_objext "* ) ;;
6707 *) LIBOBJS="$LIBOBJS vfork.$ac_objext"
6708 ;;
6709esac
71f27b28 6710
cd9a469c 6711 fi
6712 # We only need _doprnt if we might use it to implement v*printf.
6713 if test $ac_cv_func_vprintf != yes \
6714 || test $ac_cv_func_vfprintf != yes \
6715 || test $ac_cv_func_vsprintf != yes; then
6716 for ac_func in _doprnt
6717do :
6718 ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt"
6719if test "x$ac_cv_func__doprnt" = x""yes; then :
71f27b28 6720 cat >>confdefs.h <<_ACEOF
cd9a469c 6721#define HAVE__DOPRNT 1
71f27b28 6722_ACEOF
6723
cd9a469c 6724else
6725 case " $LIBOBJS " in
6726 *" $ac_func.$ac_objext "* ) ;;
6727 *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
6728 ;;
6729esac
71f27b28 6730
f2d737fc 6731fi
cd9a469c 6732done
f2d737fc 6733
6734
cd9a469c 6735 else
6736 for ac_func in _doprnt
6737do :
6738 ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt"
6739if test "x$ac_cv_func__doprnt" = x""yes; then :
6740 cat >>confdefs.h <<_ACEOF
6741#define HAVE__DOPRNT 1
f2d737fc 6742_ACEOF
f2d737fc 6743
f2d737fc 6744fi
cd9a469c 6745done
f2d737fc 6746
cd9a469c 6747 fi
f2d737fc 6748
cd9a469c 6749 for v in $vars; do
6750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $v" >&5
6751$as_echo_n "checking for $v... " >&6; }
6752 if { as_var=libiberty_cv_var_$v; eval "test \"\${$as_var+set}\" = set"; }; then :
6753 $as_echo_n "(cached) " >&6
f2d737fc 6754else
cd9a469c 6755 if test x$gcc_no_link = xyes; then
6756 as_fn_error "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5
f2d737fc 6757fi
cd9a469c 6758cat confdefs.h - <<_ACEOF >conftest.$ac_ext
f2d737fc 6759/* end confdefs.h. */
cd9a469c 6760int *p;
f2d737fc 6761int
6762main ()
6763{
cd9a469c 6764extern int $v []; p = $v;
f2d737fc 6765 ;
6766 return 0;
6767}
6768_ACEOF
cd9a469c 6769if ac_fn_c_try_link "$LINENO"; then :
6770 eval "libiberty_cv_var_$v=yes"
f2d737fc 6771else
cd9a469c 6772 eval "libiberty_cv_var_$v=no"
f2d737fc 6773fi
cd9a469c 6774rm -f core conftest.err conftest.$ac_objext \
6775 conftest$ac_exeext conftest.$ac_ext
f2d737fc 6776fi
f2d737fc 6777
cd9a469c 6778 if eval "test \"`echo '$libiberty_cv_var_'$v`\" = yes"; then
6779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6780$as_echo "yes" >&6; }
6781 n=HAVE_`echo $v | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6782 cat >>confdefs.h <<_ACEOF
6783#define $n 1
f2d737fc 6784_ACEOF
6785
cd9a469c 6786 else
6787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6788$as_echo "no" >&6; }
6789 fi
6790 done
f2d737fc 6791
cd9a469c 6792 # special check for _system_configuration because AIX <4.3.2 do not
6793 # contain the `physmem' member.
6794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for external symbol _system_configuration" >&5
6795$as_echo_n "checking for external symbol _system_configuration... " >&6; }
6796 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
deef0ea6 6797/* end confdefs.h. */
cd9a469c 6798#include <sys/systemcfg.h>
deef0ea6 6799int
6800main ()
6801{
cd9a469c 6802double x = _system_configuration.physmem;
deef0ea6 6803 ;
6804 return 0;
6805}
6806_ACEOF
cd9a469c 6807if ac_fn_c_try_compile "$LINENO"; then :
6808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6809$as_echo "yes" >&6; }
deef0ea6 6810
cd9a469c 6811$as_echo "#define HAVE__SYSTEM_CONFIGURATION 1" >>confdefs.h
deef0ea6 6812
6813else
cd9a469c 6814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6815$as_echo "no" >&6; }
6816fi
6817rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6818
6819 for ac_func in $checkfuncs
6820do :
6821 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
6822ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
6823eval as_val=\$$as_ac_var
6824 if test "x$as_val" = x""yes; then :
deef0ea6 6825 cat >>confdefs.h <<_ACEOF
cd9a469c 6826#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
deef0ea6 6827_ACEOF
6828
f2d737fc 6829fi
cd9a469c 6830done
f2d737fc 6831
050318d9 6832 ac_fn_c_check_decl "$LINENO" "basename(char *)" "ac_cv_have_decl_basename_char_p_" "$ac_includes_default"
6833if test "x$ac_cv_have_decl_basename_char_p_" = x""yes; then :
cd9a469c 6834 ac_have_decl=1
f2d737fc 6835else
cd9a469c 6836 ac_have_decl=0
f2d737fc 6837fi
f2d737fc 6838
6839cat >>confdefs.h <<_ACEOF
cd9a469c 6840#define HAVE_DECL_BASENAME $ac_have_decl
f2d737fc 6841_ACEOF
cd9a469c 6842ac_fn_c_check_decl "$LINENO" "ffs" "ac_cv_have_decl_ffs" "$ac_includes_default"
6843if test "x$ac_cv_have_decl_ffs" = x""yes; then :
6844 ac_have_decl=1
f2d737fc 6845else
cd9a469c 6846 ac_have_decl=0
f2d737fc 6847fi
f2d737fc 6848
cd9a469c 6849cat >>confdefs.h <<_ACEOF
6850#define HAVE_DECL_FFS $ac_have_decl
f2d737fc 6851_ACEOF
cd9a469c 6852ac_fn_c_check_decl "$LINENO" "asprintf" "ac_cv_have_decl_asprintf" "$ac_includes_default"
6853if test "x$ac_cv_have_decl_asprintf" = x""yes; then :
6854 ac_have_decl=1
f2d737fc 6855else
cd9a469c 6856 ac_have_decl=0
f2d737fc 6857fi
f2d737fc 6858
6859cat >>confdefs.h <<_ACEOF
cd9a469c 6860#define HAVE_DECL_ASPRINTF $ac_have_decl
f2d737fc 6861_ACEOF
cd9a469c 6862ac_fn_c_check_decl "$LINENO" "vasprintf" "ac_cv_have_decl_vasprintf" "$ac_includes_default"
6863if test "x$ac_cv_have_decl_vasprintf" = x""yes; then :
6864 ac_have_decl=1
f2d737fc 6865else
cd9a469c 6866 ac_have_decl=0
f2d737fc 6867fi
f2d737fc 6868
cd9a469c 6869cat >>confdefs.h <<_ACEOF
6870#define HAVE_DECL_VASPRINTF $ac_have_decl
f2d737fc 6871_ACEOF
cd9a469c 6872ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
6873if test "x$ac_cv_have_decl_snprintf" = x""yes; then :
6874 ac_have_decl=1
f2d737fc 6875else
cd9a469c 6876 ac_have_decl=0
f2d737fc 6877fi
f2d737fc 6878
6879cat >>confdefs.h <<_ACEOF
cd9a469c 6880#define HAVE_DECL_SNPRINTF $ac_have_decl
f2d737fc 6881_ACEOF
cd9a469c 6882ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
6883if test "x$ac_cv_have_decl_vsnprintf" = x""yes; then :
6884 ac_have_decl=1
f2d737fc 6885else
cd9a469c 6886 ac_have_decl=0
28cc9eac 6887fi
6888
cd9a469c 6889cat >>confdefs.h <<_ACEOF
6890#define HAVE_DECL_VSNPRINTF $ac_have_decl
6891_ACEOF
28cc9eac 6892
cd9a469c 6893 ac_fn_c_check_decl "$LINENO" "calloc" "ac_cv_have_decl_calloc" "$ac_includes_default"
6894if test "x$ac_cv_have_decl_calloc" = x""yes; then :
6895 ac_have_decl=1
6896else
6897 ac_have_decl=0
28cc9eac 6898fi
cd9a469c 6899
6900cat >>confdefs.h <<_ACEOF
6901#define HAVE_DECL_CALLOC $ac_have_decl
6902_ACEOF
6903ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
6904if test "x$ac_cv_have_decl_getenv" = x""yes; then :
6905 ac_have_decl=1
6906else
6907 ac_have_decl=0
28cc9eac 6908fi
28cc9eac 6909
6910cat >>confdefs.h <<_ACEOF
cd9a469c 6911#define HAVE_DECL_GETENV $ac_have_decl
28cc9eac 6912_ACEOF
cd9a469c 6913ac_fn_c_check_decl "$LINENO" "getopt" "ac_cv_have_decl_getopt" "$ac_includes_default"
6914if test "x$ac_cv_have_decl_getopt" = x""yes; then :
6915 ac_have_decl=1
6916else
6917 ac_have_decl=0
6918fi
28cc9eac 6919
cd9a469c 6920cat >>confdefs.h <<_ACEOF
6921#define HAVE_DECL_GETOPT $ac_have_decl
6922_ACEOF
6923ac_fn_c_check_decl "$LINENO" "malloc" "ac_cv_have_decl_malloc" "$ac_includes_default"
6924if test "x$ac_cv_have_decl_malloc" = x""yes; then :
6925 ac_have_decl=1
6926else
6927 ac_have_decl=0
6928fi
28cc9eac 6929
cd9a469c 6930cat >>confdefs.h <<_ACEOF
6931#define HAVE_DECL_MALLOC $ac_have_decl
6932_ACEOF
6933ac_fn_c_check_decl "$LINENO" "realloc" "ac_cv_have_decl_realloc" "$ac_includes_default"
6934if test "x$ac_cv_have_decl_realloc" = x""yes; then :
6935 ac_have_decl=1
28cc9eac 6936else
cd9a469c 6937 ac_have_decl=0
6938fi
6939
6940cat >>confdefs.h <<_ACEOF
6941#define HAVE_DECL_REALLOC $ac_have_decl
28cc9eac 6942_ACEOF
cd9a469c 6943ac_fn_c_check_decl "$LINENO" "sbrk" "ac_cv_have_decl_sbrk" "$ac_includes_default"
6944if test "x$ac_cv_have_decl_sbrk" = x""yes; then :
6945 ac_have_decl=1
6946else
6947 ac_have_decl=0
6948fi
28cc9eac 6949
cd9a469c 6950cat >>confdefs.h <<_ACEOF
6951#define HAVE_DECL_SBRK $ac_have_decl
33922532 6952_ACEOF
6953
6954 ac_fn_c_check_decl "$LINENO" "strtol" "ac_cv_have_decl_strtol" "$ac_includes_default"
6955if test "x$ac_cv_have_decl_strtol" = x""yes; then :
6956 ac_have_decl=1
6957else
6958 ac_have_decl=0
6959fi
6960
6961cat >>confdefs.h <<_ACEOF
6962#define HAVE_DECL_STRTOL $ac_have_decl
6963_ACEOF
6964ac_fn_c_check_decl "$LINENO" "strtoul" "ac_cv_have_decl_strtoul" "$ac_includes_default"
6965if test "x$ac_cv_have_decl_strtoul" = x""yes; then :
6966 ac_have_decl=1
6967else
6968 ac_have_decl=0
6969fi
6970
6971cat >>confdefs.h <<_ACEOF
6972#define HAVE_DECL_STRTOUL $ac_have_decl
6973_ACEOF
6974ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
6975if test "x$ac_cv_have_decl_strtoll" = x""yes; then :
6976 ac_have_decl=1
6977else
6978 ac_have_decl=0
6979fi
6980
6981cat >>confdefs.h <<_ACEOF
6982#define HAVE_DECL_STRTOLL $ac_have_decl
6983_ACEOF
6984ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
6985if test "x$ac_cv_have_decl_strtoull" = x""yes; then :
6986 ac_have_decl=1
6987else
6988 ac_have_decl=0
6989fi
6990
6991cat >>confdefs.h <<_ACEOF
6992#define HAVE_DECL_STRTOULL $ac_have_decl
cd9a469c 6993_ACEOF
28cc9eac 6994
cd9a469c 6995 ac_fn_c_check_decl "$LINENO" "strverscmp" "ac_cv_have_decl_strverscmp" "$ac_includes_default"
6996if test "x$ac_cv_have_decl_strverscmp" = x""yes; then :
6997 ac_have_decl=1
6998else
6999 ac_have_decl=0
9459c273 7000fi
7001
cd9a469c 7002cat >>confdefs.h <<_ACEOF
7003#define HAVE_DECL_STRVERSCMP $ac_have_decl
7004_ACEOF
9459c273 7005
cd9a469c 7006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether canonicalize_file_name must be declared" >&5
7007$as_echo_n "checking whether canonicalize_file_name must be declared... " >&6; }
7008if test "${libiberty_cv_decl_needed_canonicalize_file_name+set}" = set; then :
7009 $as_echo_n "(cached) " >&6
846a645c 7010else
cd9a469c 7011 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
a6089b1e 7012/* end confdefs.h. */
846a645c 7013
7014#include "confdefs.h"
7015#include <stdio.h>
7016#ifdef HAVE_STRING_H
7017#include <string.h>
7018#else
7019#ifdef HAVE_STRINGS_H
7020#include <strings.h>
7021#endif
7022#endif
7023#ifdef HAVE_STDLIB_H
7024#include <stdlib.h>
7025#endif
7026#ifdef HAVE_UNISTD_H
7027#include <unistd.h>
7028#endif
a6089b1e 7029int
7030main ()
7031{
846a645c 7032char *(*pfn) = (char *(*)) canonicalize_file_name
a6089b1e 7033 ;
7034 return 0;
7035}
7036_ACEOF
cd9a469c 7037if ac_fn_c_try_compile "$LINENO"; then :
846a645c 7038 libiberty_cv_decl_needed_canonicalize_file_name=no
7039else
cd9a469c 7040 libiberty_cv_decl_needed_canonicalize_file_name=yes
846a645c 7041fi
cd9a469c 7042rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
846a645c 7043fi
7044
cd9a469c 7045{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libiberty_cv_decl_needed_canonicalize_file_name" >&5
7046$as_echo "$libiberty_cv_decl_needed_canonicalize_file_name" >&6; }
846a645c 7047if test $libiberty_cv_decl_needed_canonicalize_file_name = yes; then
a6089b1e 7048
cd9a469c 7049$as_echo "#define NEED_DECLARATION_CANONICALIZE_FILE_NAME 1" >>confdefs.h
846a645c 7050
7051fi
7052
f0a93313 7053fi
7054
8cb0536d 7055# Figure out which version of pexecute to use.
7056case "${host}" in
a16fe5d1 7057 *-*-mingw* | *-*-winnt*) pexecute=pex-win32 ;;
7058 *-*-msdosdjgpp*) pexecute=pex-djgpp ;;
7059 *-*-msdos*) pexecute=pex-msdos ;;
7060 *) pexecute=pex-unix ;;
8cb0536d 7061esac
7062
7063
a6089b1e 7064if test x$gcc_no_link = xyes; then
7065 if test "x${ac_cv_func_mmap_fixed_mapped+set}" != xset; then
7066 ac_cv_func_mmap_fixed_mapped=no
7067 fi
7068fi
28cc9eac 7069if test "x${ac_cv_func_mmap_fixed_mapped}" != xno; then
cd9a469c 7070 for ac_header in stdlib.h unistd.h
7071do :
7072 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7073ac_fn_c_check_header_preproc "$LINENO" "$ac_header" "$as_ac_Header"
7074eval as_val=\$$as_ac_Header
7075 if test "x$as_val" = x""yes; then :
a6089b1e 7076 cat >>confdefs.h <<_ACEOF
cd9a469c 7077#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
a6089b1e 7078_ACEOF
7079
b3524c8f 7080fi
7081done
7082
7083for ac_func in getpagesize
cd9a469c 7084do :
7085 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
7086if test "x$ac_cv_func_getpagesize" = x""yes; then :
a6089b1e 7087 cat >>confdefs.h <<_ACEOF
cd9a469c 7088#define HAVE_GETPAGESIZE 1
a6089b1e 7089_ACEOF
b3524c8f 7090
b3524c8f 7091fi
7092done
7093
cd9a469c 7094{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
7095$as_echo_n "checking for working mmap... " >&6; }
7096if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
7097 $as_echo_n "(cached) " >&6
b3524c8f 7098else
cd9a469c 7099 if test "$cross_compiling" = yes; then :
b3524c8f 7100 ac_cv_func_mmap_fixed_mapped=no
7101else
cd9a469c 7102 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
a6089b1e 7103/* end confdefs.h. */
7104$ac_includes_default
7105/* malloc might have been renamed as rpl_malloc. */
7106#undef malloc
b3524c8f 7107
7108/* Thanks to Mike Haertel and Jim Avera for this test.
7109 Here is a matrix of mmap possibilities:
7110 mmap private not fixed
7111 mmap private fixed at somewhere currently unmapped
7112 mmap private fixed at somewhere already mapped
7113 mmap shared not fixed
7114 mmap shared fixed at somewhere currently unmapped
7115 mmap shared fixed at somewhere already mapped
7116 For private mappings, we should verify that changes cannot be read()
7117 back from the file, nor mmap's back from the file at a different
7118 address. (There have been systems where private was not correctly
7119 implemented like the infamous i386 svr4.0, and systems where the
a6089b1e 7120 VM page cache was not coherent with the file system buffer cache
b3524c8f 7121 like early versions of FreeBSD and possibly contemporary NetBSD.)
7122 For shared mappings, we should conversely verify that changes get
a6089b1e 7123 propagated back to all the places they're supposed to be.
b3524c8f 7124
7125 Grep wants private fixed already mapped.
7126 The main things grep needs to know about mmap are:
7127 * does it exist and is it safe to write into the mmap'd area
7128 * how to use it (BSD variants) */
a6089b1e 7129
b3524c8f 7130#include <fcntl.h>
7131#include <sys/mman.h>
7132
cd9a469c 7133#if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
a6089b1e 7134char *malloc ();
c08775b2 7135#endif
7136
b3524c8f 7137/* This mess was copied from the GNU getpagesize.h. */
cd9a469c 7138#ifndef HAVE_GETPAGESIZE
b3524c8f 7139/* Assume that all systems that can run configure have sys/param.h. */
cd9a469c 7140# ifndef HAVE_SYS_PARAM_H
b3524c8f 7141# define HAVE_SYS_PARAM_H 1
7142# endif
7143
7144# ifdef _SC_PAGESIZE
7145# define getpagesize() sysconf(_SC_PAGESIZE)
7146# else /* no _SC_PAGESIZE */
cd9a469c 7147# ifdef HAVE_SYS_PARAM_H
b3524c8f 7148# include <sys/param.h>
7149# ifdef EXEC_PAGESIZE
7150# define getpagesize() EXEC_PAGESIZE
7151# else /* no EXEC_PAGESIZE */
7152# ifdef NBPG
7153# define getpagesize() NBPG * CLSIZE
7154# ifndef CLSIZE
7155# define CLSIZE 1
7156# endif /* no CLSIZE */
7157# else /* no NBPG */
7158# ifdef NBPC
7159# define getpagesize() NBPC
7160# else /* no NBPC */
7161# ifdef PAGESIZE
7162# define getpagesize() PAGESIZE
7163# endif /* PAGESIZE */
7164# endif /* no NBPC */
7165# endif /* no NBPG */
7166# endif /* no EXEC_PAGESIZE */
7167# else /* no HAVE_SYS_PARAM_H */
7168# define getpagesize() 8192 /* punt totally */
7169# endif /* no HAVE_SYS_PARAM_H */
7170# endif /* no _SC_PAGESIZE */
7171
7172#endif /* no HAVE_GETPAGESIZE */
7173
b3524c8f 7174int
a6089b1e 7175main ()
b3524c8f 7176{
a6089b1e 7177 char *data, *data2, *data3;
7178 int i, pagesize;
7179 int fd;
b3524c8f 7180
a6089b1e 7181 pagesize = getpagesize ();
7182
7183 /* First, make a file with some known garbage in it. */
7184 data = (char *) malloc (pagesize);
7185 if (!data)
cd9a469c 7186 return 1;
a6089b1e 7187 for (i = 0; i < pagesize; ++i)
7188 *(data + i) = rand ();
7189 umask (0);
7190 fd = creat ("conftest.mmap", 0600);
7191 if (fd < 0)
cd9a469c 7192 return 1;
a6089b1e 7193 if (write (fd, data, pagesize) != pagesize)
cd9a469c 7194 return 1;
a6089b1e 7195 close (fd);
7196
7197 /* Next, try to mmap the file at a fixed address which already has
7198 something else allocated at it. If we can, also make sure that
7199 we see the same garbage. */
7200 fd = open ("conftest.mmap", O_RDWR);
7201 if (fd < 0)
cd9a469c 7202 return 1;
a6089b1e 7203 data2 = (char *) malloc (2 * pagesize);
7204 if (!data2)
cd9a469c 7205 return 1;
7206 data2 += (pagesize - ((long int) data2 & (pagesize - 1))) & (pagesize - 1);
a6089b1e 7207 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
ac09b42b 7208 MAP_PRIVATE | MAP_FIXED, fd, 0L))
cd9a469c 7209 return 1;
a6089b1e 7210 for (i = 0; i < pagesize; ++i)
7211 if (*(data + i) != *(data2 + i))
cd9a469c 7212 return 1;
a6089b1e 7213
7214 /* Finally, make sure that changes to the mapped area do not
7215 percolate back to the file as seen by read(). (This is a bug on
7216 some variants of i386 svr4.0.) */
7217 for (i = 0; i < pagesize; ++i)
7218 *(data2 + i) = *(data2 + i) + 1;
7219 data3 = (char *) malloc (pagesize);
7220 if (!data3)
cd9a469c 7221 return 1;
a6089b1e 7222 if (read (fd, data3, pagesize) != pagesize)
cd9a469c 7223 return 1;
a6089b1e 7224 for (i = 0; i < pagesize; ++i)
7225 if (*(data + i) != *(data3 + i))
cd9a469c 7226 return 1;
a6089b1e 7227 close (fd);
cd9a469c 7228 return 0;
a6089b1e 7229}
7230_ACEOF
cd9a469c 7231if ac_fn_c_try_run "$LINENO"; then :
b3524c8f 7232 ac_cv_func_mmap_fixed_mapped=yes
7233else
cd9a469c 7234 ac_cv_func_mmap_fixed_mapped=no
b3524c8f 7235fi
cd9a469c 7236rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7237 conftest.$ac_objext conftest.beam conftest.$ac_ext
b3524c8f 7238fi
cd9a469c 7239
b3524c8f 7240fi
cd9a469c 7241{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
7242$as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
b3524c8f 7243if test $ac_cv_func_mmap_fixed_mapped = yes; then
a6089b1e 7244
cd9a469c 7245$as_echo "#define HAVE_MMAP 1" >>confdefs.h
b3524c8f 7246
7247fi
a6089b1e 7248rm -f conftest.mmap
b3524c8f 7249
a6089b1e 7250fi
b3524c8f 7251
cd9a469c 7252{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strncmp" >&5
7253$as_echo_n "checking for working strncmp... " >&6; }
7254if test "${ac_cv_func_strncmp_works+set}" = set; then :
7255 $as_echo_n "(cached) " >&6
b3524c8f 7256else
cd9a469c 7257 if test "$cross_compiling" = yes; then :
b3dd3949 7258 ac_cv_func_strncmp_works=yes
b3524c8f 7259else
cd9a469c 7260 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
a6089b1e 7261/* end confdefs.h. */
b3524c8f 7262
7263/* Test by Jim Wilson and Kaveh Ghazi.
7264 Check whether strncmp reads past the end of its string parameters. */
7265#include <sys/types.h>
7266
7267#ifdef HAVE_FCNTL_H
7268#include <fcntl.h>
7269#endif
7270
7271#ifdef HAVE_SYS_MMAN_H
7272#include <sys/mman.h>
7273#endif
7274
7275#ifndef MAP_ANON
7276#ifdef MAP_ANONYMOUS
7277#define MAP_ANON MAP_ANONYMOUS
7278#else
7279#define MAP_ANON MAP_FILE
7280#endif
7281#endif
7282
7283#ifndef MAP_FILE
7284#define MAP_FILE 0
7285#endif
7286#ifndef O_RDONLY
7287#define O_RDONLY 0
7288#endif
7289
7290#define MAP_LEN 0x10000
7291
7292main ()
7293{
7294#if defined(HAVE_MMAP) || defined(HAVE_MMAP_ANYWHERE)
7295 char *p;
7296 int dev_zero;
7297
7298 dev_zero = open ("/dev/zero", O_RDONLY);
7299 if (dev_zero < 0)
7300 exit (1);
a6089b1e 7301
b3524c8f 7302 p = (char *) mmap (0, MAP_LEN, PROT_READ|PROT_WRITE,
7303 MAP_ANON|MAP_PRIVATE, dev_zero, 0);
936c37fd 7304 if (p == (char *)-1)
7305 p = (char *) mmap (0, MAP_LEN, PROT_READ|PROT_WRITE,
7306 MAP_ANON|MAP_PRIVATE, -1, 0);
b3524c8f 7307 if (p == (char *)-1)
7308 exit (2);
7309 else
7310 {
7311 char *string = "__si_type_info";
7312 char *q = (char *) p + MAP_LEN - strlen (string) - 2;
7313 char *r = (char *) p + 0xe;
7314
7315 strcpy (q, string);
7316 strcpy (r, string);
7317 strncmp (r, q, 14);
7318 }
7319#endif /* HAVE_MMAP || HAVE_MMAP_ANYWHERE */
7320 exit (0);
7321}
7322
a6089b1e 7323_ACEOF
cd9a469c 7324if ac_fn_c_try_run "$LINENO"; then :
b3524c8f 7325 ac_cv_func_strncmp_works=yes
7326else
cd9a469c 7327 ac_cv_func_strncmp_works=no
b3524c8f 7328fi
cd9a469c 7329rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7330 conftest.$ac_objext conftest.beam conftest.$ac_ext
b3524c8f 7331fi
cd9a469c 7332
b3524c8f 7333rm -f core core.* *.core
7334fi
cd9a469c 7335{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strncmp_works" >&5
7336$as_echo "$ac_cv_func_strncmp_works" >&6; }
b3524c8f 7337if test $ac_cv_func_strncmp_works = no ; then
cd9a469c 7338 case " $LIBOBJS " in
ac09b42b 7339 *" strncmp.$ac_objext "* ) ;;
cd9a469c 7340 *) LIBOBJS="$LIBOBJS strncmp.$ac_objext"
7341 ;;
ac09b42b 7342esac
7343
b3524c8f 7344fi
7345
7346
f0a93313 7347# Install a library built with a cross compiler in $(tooldir) rather
7348# than $(libdir).
804ec1bf 7349if test -z "${with_cross_host}"; then
f0a93313 7350 INSTALL_DEST=libdir
7351else
7352 INSTALL_DEST=tooldir
7353fi
7354
7355
fdf7ca85 7356
7357L=""
7358for l in x $LIBOBJS; do
7359 case $l in
7360 x) ;;
7361 *) L="$L ./$l" ;;
7362 esac
7363done
7364LIBOBJS="$L"
7365
87d31c8b 7366
7367
7368
7369
f0a93313 7370# We need multilib support, but only if configuring for the target.
cd9a469c 7371ac_config_files="$ac_config_files Makefile testsuite/Makefile"
6c13736f 7372
cd9a469c 7373ac_config_commands="$ac_config_commands default"
6c13736f 7374
a6089b1e 7375cat >confcache <<\_ACEOF
f0a93313 7376# This file is a shell script that caches the results of configure
7377# tests run on this system so they can be shared between configure
a6089b1e 7378# scripts and configure runs, see configure's option --config-cache.
7379# It is not useful on other systems. If it contains results you don't
7380# want to keep, you may remove or edit it.
f0a93313 7381#
a6089b1e 7382# config.status only pays attention to the cache file if you give it
7383# the --recheck option to rerun configure.
f0a93313 7384#
a6089b1e 7385# `ac_cv_env_foo' variables (set or unset) will be overridden when
7386# loading this file, other *unset* `ac_cv_foo' will be assigned the
7387# following values.
7388
7389_ACEOF
7390
f0a93313 7391# The following way of writing the cache mishandles newlines in values,
7392# but we know of no workaround that is simple, portable, and efficient.
cd9a469c 7393# So, we kill variables containing newlines.
f0a93313 7394# Ultrix sh set writes to stderr and can't be redirected directly,
7395# and sets the high bit in the cache file unless we assign to the vars.
cd9a469c 7396(
7397 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
7398 eval ac_val=\$$ac_var
7399 case $ac_val in #(
7400 *${as_nl}*)
7401 case $ac_var in #(
7402 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
7403$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
7404 esac
7405 case $ac_var in #(
7406 _ | IFS | as_nl) ;; #(
7407 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
7408 *) { eval $ac_var=; unset $ac_var;} ;;
7409 esac ;;
7410 esac
7411 done
7412
a6089b1e 7413 (set) 2>&1 |
cd9a469c 7414 case $as_nl`(ac_space=' '; set) 2>&1` in #(
7415 *${as_nl}ac_space=\ *)
7416 # `set' does not quote correctly, so add quotes: double-quote
7417 # substitution turns \\\\ into \\, and sed turns \\ into \.
a6089b1e 7418 sed -n \
ac09b42b 7419 "s/'/'\\\\''/g;
7420 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
cd9a469c 7421 ;; #(
a6089b1e 7422 *)
7423 # `set' quotes correctly as required by POSIX, so do not add quotes.
cd9a469c 7424 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
a6089b1e 7425 ;;
cd9a469c 7426 esac |
7427 sort
7428) |
a6089b1e 7429 sed '
cd9a469c 7430 /^ac_cv_env_/b end
a6089b1e 7431 t clear
cd9a469c 7432 :clear
a6089b1e 7433 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
7434 t end
cd9a469c 7435 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
7436 :end' >>confcache
7437if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
7438 if test -w "$cache_file"; then
7439 test "x$cache_file" != "x/dev/null" &&
7440 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
7441$as_echo "$as_me: updating cache $cache_file" >&6;}
a6089b1e 7442 cat confcache >$cache_file
f0a93313 7443 else
cd9a469c 7444 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
7445$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
f0a93313 7446 fi
7447fi
7448rm -f confcache
7449
f0a93313 7450test "x$prefix" = xNONE && prefix=$ac_default_prefix
7451# Let make expand exec_prefix.
7452test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
7453
f0a93313 7454DEFS=-DHAVE_CONFIG_H
7455
a6089b1e 7456ac_libobjs=
7457ac_ltlibobjs=
7458for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
7459 # 1. Remove the extension, and $U if already installed.
cd9a469c 7460 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
7461 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
7462 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
7463 # will be set to the directory where LIBOBJS objects are built.
7464 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
7465 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
a6089b1e 7466done
7467LIBOBJS=$ac_libobjs
f0a93313 7468
a6089b1e 7469LTLIBOBJS=$ac_ltlibobjs
7470
7471
7472
cd9a469c 7473
a6089b1e 7474: ${CONFIG_STATUS=./config.status}
cd9a469c 7475ac_write_fail=0
a6089b1e 7476ac_clean_files_save=$ac_clean_files
7477ac_clean_files="$ac_clean_files $CONFIG_STATUS"
cd9a469c 7478{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
7479$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
7480as_write_fail=0
7481cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
a6089b1e 7482#! $SHELL
7483# Generated by $as_me.
f0a93313 7484# Run this file to recreate the current configuration.
f0a93313 7485# Compiler output produced by configure, useful for debugging
a6089b1e 7486# configure, is in config.log if it exists.
f0a93313 7487
a6089b1e 7488debug=false
7489ac_cs_recheck=false
7490ac_cs_silent=false
a6089b1e 7491
cd9a469c 7492SHELL=\${CONFIG_SHELL-$SHELL}
7493export SHELL
7494_ASEOF
7495cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
7496## -------------------- ##
7497## M4sh Initialization. ##
7498## -------------------- ##
7499
7500# Be more Bourne compatible
7501DUALCASE=1; export DUALCASE # for MKS sh
7502if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
a6089b1e 7503 emulate sh
7504 NULLCMD=:
cd9a469c 7505 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
a6089b1e 7506 # is contrary to our usage. Disable this feature.
7507 alias -g '${1+"$@"}'='"$@"'
cd9a469c 7508 setopt NO_GLOB_SUBST
7509else
7510 case `(set -o) 2>/dev/null` in #(
7511 *posix*) :
7512 set -o posix ;; #(
7513 *) :
7514 ;;
7515esac
a6089b1e 7516fi
7517
cd9a469c 7518
7519as_nl='
7520'
7521export as_nl
7522# Printing a long string crashes Solaris 7 /usr/bin/printf.
7523as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
7524as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
7525as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
7526# Prefer a ksh shell builtin over an external printf program on Solaris,
7527# but without wasting forks for bash or zsh.
7528if test -z "$BASH_VERSION$ZSH_VERSION" \
7529 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
7530 as_echo='print -r --'
7531 as_echo_n='print -rn --'
7532elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
7533 as_echo='printf %s\n'
7534 as_echo_n='printf %s'
7535else
7536 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
7537 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
7538 as_echo_n='/usr/ucb/echo -n'
7539 else
7540 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
7541 as_echo_n_body='eval
7542 arg=$1;
7543 case $arg in #(
7544 *"$as_nl"*)
7545 expr "X$arg" : "X\\(.*\\)$as_nl";
7546 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
7547 esac;
7548 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
7549 '
7550 export as_echo_n_body
7551 as_echo_n='sh -c $as_echo_n_body as_echo'
7552 fi
7553 export as_echo_body
7554 as_echo='sh -c $as_echo_body as_echo'
7555fi
7556
7557# The user is always right.
7558if test "${PATH_SEPARATOR+set}" != set; then
7559 PATH_SEPARATOR=:
7560 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
7561 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
7562 PATH_SEPARATOR=';'
7563 }
a6089b1e 7564fi
7565
7566
cd9a469c 7567# IFS
7568# We need space, tab and new line, in precisely that order. Quoting is
7569# there to prevent editors from complaining about space-tab.
7570# (If _AS_PATH_WALK were called with IFS unset, it would disable word
7571# splitting by setting IFS to empty value.)
7572IFS=" "" $as_nl"
7573
7574# Find who we are. Look in the path if we contain no directory separator.
7575case $0 in #((
7576 *[\\/]* ) as_myself=$0 ;;
7577 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7578for as_dir in $PATH
7579do
7580 IFS=$as_save_IFS
7581 test -z "$as_dir" && as_dir=.
7582 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
7583 done
7584IFS=$as_save_IFS
7585
7586 ;;
7587esac
7588# We did not find ourselves, most probably we were run as `sh COMMAND'
7589# in which case we are not to be found in the path.
7590if test "x$as_myself" = x; then
7591 as_myself=$0
7592fi
7593if test ! -f "$as_myself"; then
7594 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
7595 exit 1
7596fi
7597
7598# Unset variables that we do not need and which cause bugs (e.g. in
7599# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
7600# suppresses any "Segmentation fault" message there. '((' could
7601# trigger a bug in pdksh 5.2.14.
7602for as_var in BASH_ENV ENV MAIL MAILPATH
7603do eval test x\${$as_var+set} = xset \
7604 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
7605done
a6089b1e 7606PS1='$ '
7607PS2='> '
7608PS4='+ '
7609
7610# NLS nuisances.
cd9a469c 7611LC_ALL=C
7612export LC_ALL
7613LANGUAGE=C
7614export LANGUAGE
7615
7616# CDPATH.
7617(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
7618
7619
7620# as_fn_error ERROR [LINENO LOG_FD]
7621# ---------------------------------
7622# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
7623# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
7624# script with status $?, using 1 if that was 0.
7625as_fn_error ()
7626{
7627 as_status=$?; test $as_status -eq 0 && as_status=1
7628 if test "$3"; then
7629 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
7630 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
a6089b1e 7631 fi
cd9a469c 7632 $as_echo "$as_me: error: $1" >&2
7633 as_fn_exit $as_status
7634} # as_fn_error
7635
7636
7637# as_fn_set_status STATUS
7638# -----------------------
7639# Set $? to STATUS, without forking.
7640as_fn_set_status ()
7641{
7642 return $1
7643} # as_fn_set_status
7644
7645# as_fn_exit STATUS
7646# -----------------
7647# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
7648as_fn_exit ()
7649{
7650 set +e
7651 as_fn_set_status $1
7652 exit $1
7653} # as_fn_exit
7654
7655# as_fn_unset VAR
7656# ---------------
7657# Portably unset VAR.
7658as_fn_unset ()
7659{
7660 { eval $1=; unset $1;}
7661}
7662as_unset=as_fn_unset
7663# as_fn_append VAR VALUE
7664# ----------------------
7665# Append the text in VALUE to the end of the definition contained in VAR. Take
7666# advantage of any shell optimizations that allow amortized linear growth over
7667# repeated appends, instead of the typical quadratic growth present in naive
7668# implementations.
7669if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
7670 eval 'as_fn_append ()
7671 {
7672 eval $1+=\$2
7673 }'
7674else
7675 as_fn_append ()
7676 {
7677 eval $1=\$$1\$2
7678 }
7679fi # as_fn_append
7680
7681# as_fn_arith ARG...
7682# ------------------
7683# Perform arithmetic evaluation on the ARGs, and store the result in the
7684# global $as_val. Take advantage of shells that can avoid forks. The arguments
7685# must be portable across $(()) and expr.
7686if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
7687 eval 'as_fn_arith ()
7688 {
7689 as_val=$(( $* ))
7690 }'
7691else
7692 as_fn_arith ()
7693 {
7694 as_val=`expr "$@" || test $? -eq 1`
7695 }
7696fi # as_fn_arith
7697
f0a93313 7698
cd9a469c 7699if expr a : '\(a\)' >/dev/null 2>&1 &&
7700 test "X`expr 00001 : '.*\(...\)'`" = X001; then
a6089b1e 7701 as_expr=expr
7702else
7703 as_expr=false
7704fi
f0a93313 7705
cd9a469c 7706if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
a6089b1e 7707 as_basename=basename
7708else
7709 as_basename=false
7710fi
f0a93313 7711
cd9a469c 7712if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
7713 as_dirname=dirname
7714else
7715 as_dirname=false
7716fi
f0a93313 7717
cd9a469c 7718as_me=`$as_basename -- "$0" ||
a6089b1e 7719$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
7720 X"$0" : 'X\(//\)$' \| \
cd9a469c 7721 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
7722$as_echo X/"$0" |
7723 sed '/^.*\/\([^/][^/]*\)\/*$/{
7724 s//\1/
7725 q
7726 }
7727 /^X\/\(\/\/\)$/{
7728 s//\1/
7729 q
7730 }
7731 /^X\/\(\/\).*/{
7732 s//\1/
7733 q
7734 }
7735 s/.*/./; q'`
a6089b1e 7736
a6089b1e 7737# Avoid depending upon Character Ranges.
7738as_cr_letters='abcdefghijklmnopqrstuvwxyz'
7739as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
7740as_cr_Letters=$as_cr_letters$as_cr_LETTERS
7741as_cr_digits='0123456789'
7742as_cr_alnum=$as_cr_Letters$as_cr_digits
f0a93313 7743
cd9a469c 7744ECHO_C= ECHO_N= ECHO_T=
7745case `echo -n x` in #(((((
7746-n*)
7747 case `echo 'xy\c'` in
7748 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
7749 xy) ECHO_C='\c';;
7750 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
7751 ECHO_T=' ';;
7752 esac;;
7753*)
7754 ECHO_N='-n';;
a6089b1e 7755esac
7756
cd9a469c 7757rm -f conf$$ conf$$.exe conf$$.file
7758if test -d conf$$.dir; then
7759 rm -f conf$$.dir/conf$$.file
a6089b1e 7760else
cd9a469c 7761 rm -f conf$$.dir
7762 mkdir conf$$.dir 2>/dev/null
a6089b1e 7763fi
cd9a469c 7764if (echo >conf$$.file) 2>/dev/null; then
7765 if ln -s conf$$.file conf$$ 2>/dev/null; then
a6089b1e 7766 as_ln_s='ln -s'
cd9a469c 7767 # ... but there are two gotchas:
7768 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
7769 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
7770 # In both cases, we have to default to `cp -p'.
7771 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
7772 as_ln_s='cp -p'
7773 elif ln conf$$.file conf$$ 2>/dev/null; then
7774 as_ln_s=ln
7775 else
7776 as_ln_s='cp -p'
f0a93313 7777 fi
a6089b1e 7778else
7779 as_ln_s='cp -p'
7780fi
cd9a469c 7781rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
7782rmdir conf$$.dir 2>/dev/null
7783
7784
7785# as_fn_mkdir_p
7786# -------------
7787# Create "$as_dir" as a directory, including parents if necessary.
7788as_fn_mkdir_p ()
7789{
7790
7791 case $as_dir in #(
7792 -*) as_dir=./$as_dir;;
7793 esac
7794 test -d "$as_dir" || eval $as_mkdir_p || {
7795 as_dirs=
7796 while :; do
7797 case $as_dir in #(
7798 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
7799 *) as_qdir=$as_dir;;
7800 esac
7801 as_dirs="'$as_qdir' $as_dirs"
7802 as_dir=`$as_dirname -- "$as_dir" ||
7803$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
7804 X"$as_dir" : 'X\(//\)[^/]' \| \
7805 X"$as_dir" : 'X\(//\)$' \| \
7806 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
7807$as_echo X"$as_dir" |
7808 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
7809 s//\1/
7810 q
7811 }
7812 /^X\(\/\/\)[^/].*/{
7813 s//\1/
7814 q
7815 }
7816 /^X\(\/\/\)$/{
7817 s//\1/
7818 q
7819 }
7820 /^X\(\/\).*/{
7821 s//\1/
7822 q
7823 }
7824 s/.*/./; q'`
7825 test -d "$as_dir" && break
7826 done
7827 test -z "$as_dirs" || eval "mkdir $as_dirs"
7828 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
a6089b1e 7829
cd9a469c 7830
7831} # as_fn_mkdir_p
a6089b1e 7832if mkdir -p . 2>/dev/null; then
cd9a469c 7833 as_mkdir_p='mkdir -p "$as_dir"'
a6089b1e 7834else
ac09b42b 7835 test -d ./-p && rmdir ./-p
a6089b1e 7836 as_mkdir_p=false
7837fi
7838
cd9a469c 7839if test -x / >/dev/null 2>&1; then
7840 as_test_x='test -x'
7841else
7842 if ls -dL / >/dev/null 2>&1; then
7843 as_ls_L_option=L
7844 else
7845 as_ls_L_option=
7846 fi
7847 as_test_x='
7848 eval sh -c '\''
7849 if test -d "$1"; then
7850 test -d "$1/.";
7851 else
7852 case $1 in #(
7853 -*)set "./$1";;
7854 esac;
7855 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
7856 ???[sx]*):;;*)false;;esac;fi
7857 '\'' sh
7858 '
7859fi
7860as_executable_p=$as_test_x
a6089b1e 7861
7862# Sed expression to map a string onto a valid CPP name.
ac09b42b 7863as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
a6089b1e 7864
7865# Sed expression to map a string onto a valid variable name.
ac09b42b 7866as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
a6089b1e 7867
7868
a6089b1e 7869exec 6>&1
cd9a469c 7870## ----------------------------------- ##
7871## Main body of $CONFIG_STATUS script. ##
7872## ----------------------------------- ##
7873_ASEOF
7874test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
7875
7876cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
7877# Save the log message, to keep $0 and so on meaningful, and to
a6089b1e 7878# report actual input values of CONFIG_FILES etc. instead of their
cd9a469c 7879# values after options handling.
7880ac_log="
a6089b1e 7881This file was extended by $as_me, which was
cd9a469c 7882generated by GNU Autoconf 2.64. Invocation command line was
a6089b1e 7883
7884 CONFIG_FILES = $CONFIG_FILES
7885 CONFIG_HEADERS = $CONFIG_HEADERS
7886 CONFIG_LINKS = $CONFIG_LINKS
7887 CONFIG_COMMANDS = $CONFIG_COMMANDS
7888 $ $0 $@
7889
cd9a469c 7890on `(hostname || uname -n) 2>/dev/null | sed 1q`
7891"
7892
a6089b1e 7893_ACEOF
7894
cd9a469c 7895case $ac_config_files in *"
7896"*) set x $ac_config_files; shift; ac_config_files=$*;;
7897esac
a6089b1e 7898
cd9a469c 7899case $ac_config_headers in *"
7900"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
7901esac
a6089b1e 7902
a6089b1e 7903
cd9a469c 7904cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
7905# Files that config.status was made for.
7906config_files="$ac_config_files"
7907config_headers="$ac_config_headers"
7908config_commands="$ac_config_commands"
a6089b1e 7909
cd9a469c 7910_ACEOF
a6089b1e 7911
cd9a469c 7912cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
a6089b1e 7913ac_cs_usage="\
cd9a469c 7914\`$as_me' instantiates files and other configuration actions
7915from templates according to the current configuration. Unless the files
7916and actions are specified as TAGs, all are instantiated by default.
a6089b1e 7917
cd9a469c 7918Usage: $0 [OPTION]... [TAG]...
a6089b1e 7919
7920 -h, --help print this help, then exit
cd9a469c 7921 -V, --version print version number and configuration settings, then exit
7922 -q, --quiet, --silent
7923 do not print progress messages
a6089b1e 7924 -d, --debug don't remove temporary files
7925 --recheck update $as_me by reconfiguring in the same conditions
cd9a469c 7926 --file=FILE[:TEMPLATE]
7927 instantiate the configuration file FILE
7928 --header=FILE[:TEMPLATE]
7929 instantiate the configuration header FILE
a6089b1e 7930
7931Configuration files:
7932$config_files
7933
7934Configuration headers:
7935$config_headers
7936
7937Configuration commands:
7938$config_commands
7939
cd9a469c 7940Report bugs to the package provider."
a6089b1e 7941
cd9a469c 7942_ACEOF
7943cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
a6089b1e 7944ac_cs_version="\\
7945config.status
cd9a469c 7946configured by $0, generated by GNU Autoconf 2.64,
7947 with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
a6089b1e 7948
cd9a469c 7949Copyright (C) 2009 Free Software Foundation, Inc.
a6089b1e 7950This config.status script is free software; the Free Software Foundation
7951gives unlimited permission to copy, distribute and modify it."
cd9a469c 7952
7953ac_pwd='$ac_pwd'
7954srcdir='$srcdir'
7955INSTALL='$INSTALL'
7956test -n "\$AWK" || AWK=awk
a6089b1e 7957_ACEOF
7958
cd9a469c 7959cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
7960# The default lists apply if the user does not specify any file.
a6089b1e 7961ac_need_defaults=:
7962while test $# != 0
7963do
7964 case $1 in
7965 --*=*)
cd9a469c 7966 ac_option=`expr "X$1" : 'X\([^=]*\)='`
7967 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
a6089b1e 7968 ac_shift=:
7969 ;;
cd9a469c 7970 *)
a6089b1e 7971 ac_option=$1
7972 ac_optarg=$2
7973 ac_shift=shift
7974 ;;
a6089b1e 7975 esac
7976
7977 case $ac_option in
7978 # Handling of the options.
a6089b1e 7979 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
7980 ac_cs_recheck=: ;;
cd9a469c 7981 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
7982 $as_echo "$ac_cs_version"; exit ;;
7983 --debug | --debu | --deb | --de | --d | -d )
a6089b1e 7984 debug=: ;;
7985 --file | --fil | --fi | --f )
7986 $ac_shift
cd9a469c 7987 case $ac_optarg in
7988 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
7989 esac
7990 as_fn_append CONFIG_FILES " '$ac_optarg'"
a6089b1e 7991 ac_need_defaults=false;;
7992 --header | --heade | --head | --hea )
7993 $ac_shift
cd9a469c 7994 case $ac_optarg in
7995 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
7996 esac
7997 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
a6089b1e 7998 ac_need_defaults=false;;
cd9a469c 7999 --he | --h)
8000 # Conflict between --help and --header
8001 as_fn_error "ambiguous option: \`$1'
8002Try \`$0 --help' for more information.";;
8003 --help | --hel | -h )
8004 $as_echo "$ac_cs_usage"; exit ;;
a6089b1e 8005 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
8006 | -silent | --silent | --silen | --sile | --sil | --si | --s)
8007 ac_cs_silent=: ;;
8008
8009 # This is an error.
cd9a469c 8010 -*) as_fn_error "unrecognized option: \`$1'
8011Try \`$0 --help' for more information." ;;
a6089b1e 8012
cd9a469c 8013 *) as_fn_append ac_config_targets " $1"
8014 ac_need_defaults=false ;;
a6089b1e 8015
8016 esac
8017 shift
f0a93313 8018done
a6089b1e 8019
8020ac_configure_extra_args=
8021
8022if $ac_cs_silent; then
8023 exec 6>/dev/null
8024 ac_configure_extra_args="$ac_configure_extra_args --silent"
f0a93313 8025fi
f0a93313 8026
a6089b1e 8027_ACEOF
cd9a469c 8028cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
a6089b1e 8029if \$ac_cs_recheck; then
cd9a469c 8030 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
8031 shift
8032 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
8033 CONFIG_SHELL='$SHELL'
8034 export CONFIG_SHELL
8035 exec "\$@"
a6089b1e 8036fi
f0a93313 8037
a6089b1e 8038_ACEOF
cd9a469c 8039cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
8040exec 5>>config.log
8041{
8042 echo
8043 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
8044## Running $as_me. ##
8045_ASBOX
8046 $as_echo "$ac_log"
8047} >&5
a6089b1e 8048
cd9a469c 8049_ACEOF
8050cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
a6089b1e 8051#
cd9a469c 8052# INIT-COMMANDS
a6089b1e 8053#
a6089b1e 8054srcdir=${srcdir}
8055host=${host}
8056target=${target}
8057with_target_subdir=${with_target_subdir}
a6089b1e 8058with_multisubdir=${with_multisubdir}
8059ac_configure_args="--enable-multilib ${ac_configure_args}"
8060CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
8061ORIGINAL_LD_FOR_MULTILIBS="${ORIGINAL_LD_FOR_MULTILIBS}"
8062libiberty_topdir=${libiberty_topdir}
8063
8064
8065_ACEOF
8066
cd9a469c 8067cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
a6089b1e 8068
cd9a469c 8069# Handling of arguments.
a6089b1e 8070for ac_config_target in $ac_config_targets
8071do
cd9a469c 8072 case $ac_config_target in
8073 "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
8074 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
8075 "testsuite/Makefile") CONFIG_FILES="$CONFIG_FILES testsuite/Makefile" ;;
8076 "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
8077
8078 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
f0a93313 8079 esac
a6089b1e 8080done
f0a93313 8081
cd9a469c 8082
a6089b1e 8083# If the user did not use the arguments to specify the items to instantiate,
8084# then the envvar interface is used. Set only those that are not.
8085# We use the long form for the default assignment because of an extremely
8086# bizarre bug on SunOS 4.1.3.
8087if $ac_need_defaults; then
8088 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
8089 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
8090 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
8091fi
8092
8093# Have a temporary directory for convenience. Make it in the build tree
cd9a469c 8094# simply because there is no reason against having it here, and in addition,
a6089b1e 8095# creating and moving files from /tmp can sometimes cause problems.
cd9a469c 8096# Hook for its removal unless debugging.
8097# Note that there is a small window in which the directory will not be cleaned:
8098# after its creation but before its name has been assigned to `$tmp'.
a6089b1e 8099$debug ||
8100{
cd9a469c 8101 tmp=
8102 trap 'exit_status=$?
8103 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
8104' 0
8105 trap 'as_fn_exit 1' 1 2 13 15
a6089b1e 8106}
a6089b1e 8107# Create a (secure) tmp directory for tmp files.
8108
8109{
cd9a469c 8110 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
a6089b1e 8111 test -n "$tmp" && test -d "$tmp"
8112} ||
8113{
cd9a469c 8114 tmp=./conf$$-$RANDOM
8115 (umask 077 && mkdir "$tmp")
8116} || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
8117
8118# Set up the scripts for CONFIG_FILES section.
8119# No need to generate them if there are no CONFIG_FILES.
8120# This happens for instance with `./config.status config.h'.
8121if test -n "$CONFIG_FILES"; then
8122
8123if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
8124 ac_cs_awk_getline=:
8125 ac_cs_awk_pipe_init=
8126 ac_cs_awk_read_file='
8127 while ((getline aline < (F[key])) > 0)
8128 print(aline)
8129 close(F[key])'
8130 ac_cs_awk_pipe_fini=
8131else
8132 ac_cs_awk_getline=false
8133 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
8134 ac_cs_awk_read_file='
8135 print "|#_!!_#|"
8136 print "cat " F[key] " &&"
8137 '$ac_cs_awk_pipe_init
8138 # The final `:' finishes the AND list.
8139 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
8140fi
8141ac_cr=`echo X | tr X '\015'`
8142# On cygwin, bash can eat \r inside `` if the user requested igncr.
8143# But we know of no other shell where ac_cr would be empty at this
8144# point, so we can use a bashism as a fallback.
8145if test "x$ac_cr" = x; then
8146 eval ac_cr=\$\'\\r\'
8147fi
8148ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
8149if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
8150 ac_cs_awk_cr='\r'
8151else
8152 ac_cs_awk_cr=$ac_cr
8153fi
8154
8155echo 'BEGIN {' >"$tmp/subs1.awk" &&
8156_ACEOF
8157
8158# Create commands to substitute file output variables.
8159{
8160 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
8161 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
8162 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
8163 echo "_ACAWK" &&
8164 echo "_ACEOF"
8165} >conf$$files.sh &&
8166. ./conf$$files.sh ||
8167 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
8168rm -f conf$$files.sh
8169
a6089b1e 8170{
cd9a469c 8171 echo "cat >conf$$subs.awk <<_ACEOF" &&
8172 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
8173 echo "_ACEOF"
8174} >conf$$subs.sh ||
8175 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
8176ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
8177ac_delim='%!_!# '
8178for ac_last_try in false false false false false :; do
8179 . ./conf$$subs.sh ||
8180 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
8181
8182 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
8183 if test $ac_delim_n = $ac_delim_num; then
8184 break
8185 elif $ac_last_try; then
8186 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
8187 else
8188 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
8189 fi
8190done
8191rm -f conf$$subs.sh
8192
8193cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
8194cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
8195_ACEOF
8196sed -n '
8197h
8198s/^/S["/; s/!.*/"]=/
8199p
8200g
8201s/^[^!]*!//
8202:repl
8203t repl
8204s/'"$ac_delim"'$//
8205t delim
8206:nl
8207h
8208s/\(.\{148\}\).*/\1/
8209t more1
8210s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
8211p
8212n
8213b repl
8214:more1
8215s/["\\]/\\&/g; s/^/"/; s/$/"\\/
8216p
8217g
8218s/.\{148\}//
8219t nl
8220:delim
8221h
8222s/\(.\{148\}\).*/\1/
8223t more2
8224s/["\\]/\\&/g; s/^/"/; s/$/"/
8225p
8226b
8227:more2
8228s/["\\]/\\&/g; s/^/"/; s/$/"\\/
8229p
8230g
8231s/.\{148\}//
8232t delim
8233' <conf$$subs.awk | sed '
8234/^[^""]/{
8235 N
8236 s/\n//
a6089b1e 8237}
cd9a469c 8238' >>$CONFIG_STATUS || ac_write_fail=1
8239rm -f conf$$subs.awk
8240cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
8241_ACAWK
8242cat >>"\$tmp/subs1.awk" <<_ACAWK &&
8243 for (key in S) S_is_set[key] = 1
8244 FS = "\a"
8245 \$ac_cs_awk_pipe_init
8246}
8247{
8248 line = $ 0
8249 nfields = split(line, field, "@")
8250 substed = 0
8251 len = length(field[1])
8252 for (i = 2; i < nfields; i++) {
8253 key = field[i]
8254 keylen = length(key)
8255 if (S_is_set[key]) {
8256 value = S[key]
8257 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
8258 len += length(value) + length(field[++i])
8259 substed = 1
8260 } else
8261 len += 1 + keylen
8262 }
8263 if (nfields == 3 && !substed) {
8264 key = field[2]
8265 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
8266 \$ac_cs_awk_read_file
8267 next
8268 }
8269 }
8270 print line
8271}
8272\$ac_cs_awk_pipe_fini
8273_ACAWK
8274_ACEOF
8275cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
8276if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
8277 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
8278else
8279 cat
8280fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
8281 || as_fn_error "could not setup config files machinery" "$LINENO" 5
a6089b1e 8282_ACEOF
8283
cd9a469c 8284# VPATH may cause trouble with some makes, so we remove $(srcdir),
8285# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
8286# trailing colons and then remove the whole line if VPATH becomes empty
8287# (actually we leave an empty line to preserve line numbers).
8288if test "x$srcdir" = x.; then
8289 ac_vpsub='/^[ ]*VPATH[ ]*=/{
8290s/:*\$(srcdir):*/:/
8291s/:*\${srcdir}:*/:/
8292s/:*@srcdir@:*/:/
8293s/^\([^=]*=[ ]*\):*/\1/
8294s/:*$//
8295s/^[^=]*=[ ]*$//
8296}'
8297fi
a6089b1e 8298
cd9a469c 8299cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
8300fi # test -n "$CONFIG_FILES"
a6089b1e 8301
cd9a469c 8302# Set up the scripts for CONFIG_HEADERS section.
8303# No need to generate them if there are no CONFIG_HEADERS.
8304# This happens for instance with `./config.status Makefile'.
8305if test -n "$CONFIG_HEADERS"; then
8306cat >"$tmp/defines.awk" <<\_ACAWK ||
8307BEGIN {
8308_ACEOF
8309
8310# Transform confdefs.h into an awk script `defines.awk', embedded as
8311# here-document in config.status, that substitutes the proper values into
8312# config.h.in to produce config.h.
8313
8314# Create a delimiter string that does not exist in confdefs.h, to ease
8315# handling of long lines.
8316ac_delim='%!_!# '
8317for ac_last_try in false false :; do
8318 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
8319 if test -z "$ac_t"; then
8320 break
8321 elif $ac_last_try; then
8322 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
8323 else
8324 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
f0a93313 8325 fi
cd9a469c 8326done
f0a93313 8327
cd9a469c 8328# For the awk script, D is an array of macro values keyed by name,
8329# likewise P contains macro parameters if any. Preserve backslash
8330# newline sequences.
8331
8332ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
8333sed -n '
8334s/.\{148\}/&'"$ac_delim"'/g
8335t rset
8336:rset
8337s/^[ ]*#[ ]*define[ ][ ]*/ /
8338t def
8339d
8340:def
8341s/\\$//
8342t bsnl
8343s/["\\]/\\&/g
8344s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
8345D["\1"]=" \3"/p
8346s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
8347d
8348:bsnl
8349s/["\\]/\\&/g
8350s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
8351D["\1"]=" \3\\\\\\n"\\/p
8352t cont
8353s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
8354t cont
8355d
8356:cont
8357n
8358s/.\{148\}/&'"$ac_delim"'/g
8359t clear
8360:clear
8361s/\\$//
8362t bsnlc
8363s/["\\]/\\&/g; s/^/"/; s/$/"/p
8364d
8365:bsnlc
8366s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
8367b cont
8368' <confdefs.h | sed '
8369s/'"$ac_delim"'/"\\\
8370"/g' >>$CONFIG_STATUS || ac_write_fail=1
8371
8372cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
8373 for (key in D) D_is_set[key] = 1
8374 FS = "\a"
8375}
8376/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
8377 line = \$ 0
8378 split(line, arg, " ")
8379 if (arg[1] == "#") {
8380 defundef = arg[2]
8381 mac1 = arg[3]
8382 } else {
8383 defundef = substr(arg[1], 2)
8384 mac1 = arg[2]
8385 }
8386 split(mac1, mac2, "(") #)
8387 macro = mac2[1]
8388 prefix = substr(line, 1, index(line, defundef) - 1)
8389 if (D_is_set[macro]) {
8390 # Preserve the white space surrounding the "#".
8391 print prefix "define", macro P[macro] D[macro]
8392 next
8393 } else {
8394 # Replace #undef with comments. This is necessary, for example,
8395 # in the case of _POSIX_SOURCE, which is predefined and required
8396 # on some systems where configure will not decide to define it.
8397 if (defundef == "undef") {
8398 print "/*", prefix defundef, macro, "*/"
8399 next
8400 }
8401 }
8402}
8403{ print }
8404_ACAWK
a6089b1e 8405_ACEOF
cd9a469c 8406cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
8407 as_fn_error "could not setup config headers machinery" "$LINENO" 5
8408fi # test -n "$CONFIG_HEADERS"
8409
8410
8411eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
8412shift
8413for ac_tag
8414do
8415 case $ac_tag in
8416 :[FHLC]) ac_mode=$ac_tag; continue;;
8417 esac
8418 case $ac_mode$ac_tag in
8419 :[FHL]*:*);;
8420 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
8421 :[FH]-) ac_tag=-:-;;
8422 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
8423 esac
8424 ac_save_IFS=$IFS
8425 IFS=:
8426 set x $ac_tag
8427 IFS=$ac_save_IFS
8428 shift
8429 ac_file=$1
8430 shift
8431
8432 case $ac_mode in
8433 :L) ac_source=$1;;
8434 :[FH])
8435 ac_file_inputs=
8436 for ac_f
8437 do
8438 case $ac_f in
8439 -) ac_f="$tmp/stdin";;
8440 *) # Look for the file first in the build tree, then in the source tree
8441 # (if the path is not absolute). The absolute path cannot be DOS-style,
8442 # because $ac_f cannot contain `:'.
8443 test -f "$ac_f" ||
8444 case $ac_f in
8445 [\\/$]*) false;;
8446 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
8447 esac ||
8448 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
8449 esac
8450 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
8451 as_fn_append ac_file_inputs " '$ac_f'"
8452 done
8453
8454 # Let's still pretend it is `configure' which instantiates (i.e., don't
8455 # use $as_me), people would be surprised to read:
8456 # /* config.h. Generated by config.status. */
8457 configure_input='Generated from '`
8458 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
8459 `' by configure.'
8460 if test x"$ac_file" != x-; then
8461 configure_input="$ac_file. $configure_input"
8462 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
8463$as_echo "$as_me: creating $ac_file" >&6;}
8464 fi
8465 # Neutralize special characters interpreted by sed in replacement strings.
8466 case $configure_input in #(
8467 *\&* | *\|* | *\\* )
8468 ac_sed_conf_input=`$as_echo "$configure_input" |
8469 sed 's/[\\\\&|]/\\\\&/g'`;; #(
8470 *) ac_sed_conf_input=$configure_input;;
8471 esac
8472
8473 case $ac_tag in
8474 *:-:* | *:-) cat >"$tmp/stdin" \
8475 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
8476 esac
8477 ;;
f0a93313 8478 esac
8479
cd9a469c 8480 ac_dir=`$as_dirname -- "$ac_file" ||
a6089b1e 8481$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
ac09b42b 8482 X"$ac_file" : 'X\(//\)[^/]' \| \
8483 X"$ac_file" : 'X\(//\)$' \| \
cd9a469c 8484 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
8485$as_echo X"$ac_file" |
8486 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
8487 s//\1/
8488 q
8489 }
8490 /^X\(\/\/\)[^/].*/{
8491 s//\1/
8492 q
8493 }
8494 /^X\(\/\/\)$/{
8495 s//\1/
8496 q
8497 }
8498 /^X\(\/\).*/{
8499 s//\1/
8500 q
8501 }
8502 s/.*/./; q'`
8503 as_dir="$ac_dir"; as_fn_mkdir_p
a6089b1e 8504 ac_builddir=.
f0a93313 8505
cd9a469c 8506case "$ac_dir" in
8507.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
8508*)
8509 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
8510 # A ".." for each directory in $ac_dir_suffix.
8511 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
8512 case $ac_top_builddir_sub in
8513 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
8514 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
8515 esac ;;
8516esac
8517ac_abs_top_builddir=$ac_pwd
8518ac_abs_builddir=$ac_pwd$ac_dir_suffix
8519# for backward compatibility:
8520ac_top_builddir=$ac_top_build_prefix
a6089b1e 8521
8522case $srcdir in
cd9a469c 8523 .) # We are building in place.
a6089b1e 8524 ac_srcdir=.
cd9a469c 8525 ac_top_srcdir=$ac_top_builddir_sub
8526 ac_abs_top_srcdir=$ac_pwd ;;
8527 [\\/]* | ?:[\\/]* ) # Absolute name.
a6089b1e 8528 ac_srcdir=$srcdir$ac_dir_suffix;
cd9a469c 8529 ac_top_srcdir=$srcdir
8530 ac_abs_top_srcdir=$srcdir ;;
8531 *) # Relative name.
8532 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
8533 ac_top_srcdir=$ac_top_build_prefix$srcdir
8534 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
a6089b1e 8535esac
cd9a469c 8536ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
7f759422 8537
a6089b1e 8538
cd9a469c 8539 case $ac_mode in
8540 :F)
8541 #
8542 # CONFIG_FILE
8543 #
a6089b1e 8544
8545 case $INSTALL in
8546 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
cd9a469c 8547 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
f0a93313 8548 esac
cd9a469c 8549_ACEOF
f0a93313 8550
cd9a469c 8551cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
8552# If the template does not know about datarootdir, expand it.
8553# FIXME: This hack should be removed a few years after 2.60.
8554ac_datarootdir_hack=; ac_datarootdir_seen=
8555ac_sed_dataroot='
8556/datarootdir/ {
8557 p
8558 q
8559}
8560/@datadir@/p
8561/@docdir@/p
8562/@infodir@/p
8563/@localedir@/p
8564/@mandir@/p'
8565case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
8566*datarootdir*) ac_datarootdir_seen=yes;;
8567*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
8568 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
8569$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
8570_ACEOF
8571cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
8572 ac_datarootdir_hack='
8573 s&@datadir@&$datadir&g
8574 s&@docdir@&$docdir&g
8575 s&@infodir@&$infodir&g
8576 s&@localedir@&$localedir&g
8577 s&@mandir@&$mandir&g
8578 s&\\\${datarootdir}&$datarootdir&g' ;;
8579esac
a6089b1e 8580_ACEOF
cd9a469c 8581
8582# Neutralize VPATH when `$srcdir' = `.'.
8583# Shell code in configure.ac might set extrasub.
8584# FIXME: do we really want to maintain this feature?
8585cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
8586ac_sed_extra="$ac_vpsub
a6089b1e 8587$extrasub
8588_ACEOF
cd9a469c 8589cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
a6089b1e 8590:t
8591/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
cd9a469c 8592s|@configure_input@|$ac_sed_conf_input|;t t
8593s&@top_builddir@&$ac_top_builddir_sub&;t t
8594s&@top_build_prefix@&$ac_top_build_prefix&;t t
8595s&@srcdir@&$ac_srcdir&;t t
8596s&@abs_srcdir@&$ac_abs_srcdir&;t t
8597s&@top_srcdir@&$ac_top_srcdir&;t t
8598s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
8599s&@builddir@&$ac_builddir&;t t
8600s&@abs_builddir@&$ac_abs_builddir&;t t
8601s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
8602s&@INSTALL@&$ac_INSTALL&;t t
8603$ac_datarootdir_hack
8604"
8605eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
8606if $ac_cs_awk_getline; then
8607 $AWK -f "$tmp/subs.awk"
8608else
8609 $AWK -f "$tmp/subs.awk" | $SHELL
8610fi >$tmp/out \
8611 || as_fn_error "could not create $ac_file" "$LINENO" 5
8612
8613test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
8614 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
8615 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
8616 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
8617which seems to be undefined. Please make sure it is defined." >&5
8618$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
8619which seems to be undefined. Please make sure it is defined." >&2;}
8620
8621 rm -f "$tmp/stdin"
a6089b1e 8622 case $ac_file in
cd9a469c 8623 -) cat "$tmp/out" && rm -f "$tmp/out";;
8624 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
8625 esac \
8626 || as_fn_error "could not create $ac_file" "$LINENO" 5
8627 ;;
8628 :H)
8629 #
8630 # CONFIG_HEADER
8631 #
a6089b1e 8632 if test x"$ac_file" != x-; then
cd9a469c 8633 {
8634 $as_echo "/* $configure_input */" \
8635 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
8636 } >"$tmp/config.h" \
8637 || as_fn_error "could not create $ac_file" "$LINENO" 5
8638 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
8639 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
8640$as_echo "$as_me: $ac_file is unchanged" >&6;}
a6089b1e 8641 else
cd9a469c 8642 rm -f "$ac_file"
8643 mv "$tmp/config.h" "$ac_file" \
8644 || as_fn_error "could not create $ac_file" "$LINENO" 5
a6089b1e 8645 fi
8646 else
cd9a469c 8647 $as_echo "/* $configure_input */" \
8648 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
8649 || as_fn_error "could not create -" "$LINENO" 5
a6089b1e 8650 fi
cd9a469c 8651 ;;
7f759422 8652
cd9a469c 8653 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
8654$as_echo "$as_me: executing $ac_file commands" >&6;}
8655 ;;
8656 esac
a6089b1e 8657
8658
cd9a469c 8659 case $ac_file$ac_mode in
8660 "default":C) test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h
f0a93313 8661if test -n "$CONFIG_FILES"; then
b279e2c1 8662 if test -n "${with_target_subdir}"; then
f0a93313 8663 # FIXME: We shouldn't need to set ac_file
8664 ac_file=Makefile
0b045cf7 8665 LD="${ORIGINAL_LD_FOR_MULTILIBS}"
f0a93313 8666 . ${libiberty_topdir}/config-ml.in
8667 fi
a6089b1e 8668fi ;;
cd9a469c 8669
a6089b1e 8670 esac
cd9a469c 8671done # for ac_tag
a6089b1e 8672
a6089b1e 8673
cd9a469c 8674as_fn_exit 0
a6089b1e 8675_ACEOF
a6089b1e 8676ac_clean_files=$ac_clean_files_save
8677
cd9a469c 8678test $ac_write_fail = 0 ||
8679 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
8680
a6089b1e 8681
8682# configure is writing to config.log, and then calls config.status.
8683# config.status does its own redirection, appending to config.log.
8684# Unfortunately, on DOS this fails, as config.log is still kept open
8685# by configure, so config.status won't be able to write to it; its
8686# output is simply discarded. So we exec the FD to /dev/null,
8687# effectively closing config.log, so it can be properly (re)opened and
8688# appended to by config.status. When coming back to configure, we
8689# need to make the FD available again.
8690if test "$no_create" != yes; then
8691 ac_cs_success=:
8692 ac_config_status_args=
8693 test "$silent" = yes &&
8694 ac_config_status_args="$ac_config_status_args --quiet"
8695 exec 5>/dev/null
8696 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
8697 exec 5>>config.log
8698 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
8699 # would make configure fail if this is the last instruction.
cd9a469c 8700 $ac_cs_success || as_fn_exit $?
8701fi
8702if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
8703 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
8704$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
a6089b1e 8705fi
f0a93313 8706